v1.2.18 Support AnyTLS URI in v2rayN v7.14.3+

This commit is contained in:
fscarmen
2025-08-27 07:54:16 +00:00
parent 85917ee7f4
commit 633623dfdf
3 changed files with 10 additions and 40 deletions
+2
View File
@@ -20,6 +20,8 @@
* * *
## 1.更新信息
2025.08.27 v1.2.18 Add support for AnyTLS URI in v2rayN v7.14.3+, including subscription integration; 支持 v2rayN v7.14.3+,新增 AnyTLS URI,并支持在订阅中使用
2025.04.25 v1.2.17 1. Added the ability to change CDNs online using [sb -d]; 2. Change GitHub proxy; 3. Optimize code; 1. 新增使用 [sb -d] 在线更换 CDN 功能; 2. 更改 GitHub 代理; 3. 优化代码
2025.04.06 v1.2.16 Use OpenRC on Alpine to replace systemctl (Python3-compatible version); 在 Alpine 系统中使用 OpenRC 取代兼容 Python3 的 systemctl 实现
+1
View File
@@ -0,0 +1 @@
1.13.0-alpha.5
+7 -40
View File
@@ -1,10 +1,10 @@
#!/usr/bin/env bash
# 当前脚本版本号
VERSION='v1.2.17 (2025.08.22)'
VERSION='v1.2.18 (2025.08.27)'
# 各变量默认值
GH_PROXY='https://gh-proxy.com/'
GH_PROXY='https://hub.glowp.xyz/'
TEMP_DIR='/tmp/sing-box'
WORK_DIR='/etc/sing-box'
START_PORT_DEFAULT='8881'
@@ -28,8 +28,8 @@ mkdir -p $TEMP_DIR
E[0]="Language:\n 1. English (default) \n 2. 简体中文"
C[0]="${E[0]}"
E[1]="1. Added the ability to change CDNs online using [sb -d]; 2. Change GitHub proxy; 3. Optimize code."
C[1]="1. 新增使用 [sb -d] 在线更换 CDN 功能; 2. 更改 GitHub 代理; 3. 优化代码"
E[1]="Add support for AnyTLS URI in v2rayN v7.14.3+, including subscription integration"
C[1]="支持 v2rayN v7.14.3+,新增 AnyTLS URI,并支持在订阅中使用"
E[2]="Downloading Sing-box. Please wait a seconds ..."
C[2]="下载 Sing-box 中,请稍等 ..."
E[3]="Input errors up to 5 times.The script is aborted."
@@ -228,8 +228,8 @@ E[99]="The \${SING_BOX_SCRIPT} is detected to be installed. Script exits."
C[99]="检测到已安装 \${SING_BOX_SCRIPT},脚本退出!"
E[100]="Can't get the official latest version. Script exits."
C[100]="获取不到官方的最新版本,脚本退出!"
E[101]="The contents of the AnyTLS configuration file need to be updated for the sing_box kernel."
C[101]="AnyTLS 配置文件内容,需要更新 sing_box 内核"
E[101]=""
C[101]=""
E[102]="Backing up old version sing-box to ${WORK_DIR}/sing-box.bak"
C[102]="已备份旧版本 sing-box 到 ${WORK_DIR}/sing-box.bak"
E[103]="New version \$ONLINE is running successfully, backup file deleted"
@@ -2571,40 +2571,7 @@ vless://${UUID[20]}@${SERVER_IP_1}:${PORT_GRPC_REALITY}?encryption=none&security
[ -n "$PORT_ANYTLS" ] && local V2RAYN_SUBSCRIBE+="
----------------------------
# $(text 101)
{
\"log\":{
\"level\":\"warn\"
},
\"inbounds\":[
{
\"listen\":\"127.0.0.1\",
\"listen_port\":${PORT_ANYTLS},
\"sniff\":true,
\"sniff_override_destination\":false,
\"tag\": \"${PROTOCOL_LIST[10]}\",
\"type\":\"mixed\"
}
],
\"outbounds\":[
{
\"type\": \"anytls\",
\"tag\": \"${NODE_NAME[21]} ${NODE_TAG[10]}\",
\"server\": \"${SERVER_IP}\",
\"server_port\": ${PORT_ANYTLS},
\"password\": \"${UUID[21]}\",
\"idle_session_check_interval\": \"30s\",
\"idle_session_timeout\": \"30s\",
\"min_idle_session\": 5,
\"tls\": {
\"enabled\": true,
\"insecure\": true,
\"server_name\": \"\"
}
}
]
}"
anytls://${UUID[21]}@${SERVER_IP_1}:${PORT_ANYTLS}?security=tls&fp=chrome&allowInsecure=1&type=tcp#${NODE_NAME[21]// /%20}%20${NODE_TAG[10]}"
echo -n "$V2RAYN_SUBSCRIBE" | sed -E '/^[ ]*#|^[ ]+|^--|^\{|^\}/d' | sed '/^$/d' | base64 -w0 > ${WORK_DIR}/subscribe/v2rayn