Skip to content

Commit

Permalink
v4.37.2
Browse files Browse the repository at this point in the history
  • Loading branch information
cary-sas committed May 26, 2023
1 parent bc00d5f commit 5634489
Show file tree
Hide file tree
Showing 15 changed files with 2,487 additions and 2,951 deletions.
1 change: 1 addition & 0 deletions 380_armv5_packge/4.37.2/md5sum.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
64e59c6a927c34878c231ed2ea02dd60
Binary file added 380_armv5_packge/4.37.2/shadowsocks.tar.gz
Binary file not shown.
8 changes: 4 additions & 4 deletions 380_armv5_packge/config.json.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"build_date":"2023-03-25_20:42:45",
"build_date":"2023-05-26_22:50:03",
"description":"科学上网",
"home_url":"Main_Ss_Content.asp",
"md5":"ea82f65ed869e130e227fe229c9eb7ea",
"md5":"64e59c6a927c34878c231ed2ea02dd60",
"name":"shadowsocks",
"tar_url": "https://github.com/cary-sas/v2ray_bin/raw/main/380_armv5_packge/4.37.1/shadowsocks.tar.gz",
"version":"4.37.1"
"tar_url": "https://github.com/cary-sas/v2ray_bin/raw/main/380_armv5_packge/4.37.2/shadowsocks.tar.gz",
"version":"4.37.2"
}
2 changes: 1 addition & 1 deletion 380_armv5_packge/latest.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
4.37.1
4.37.2
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ fixed many historical legacy issues

除插件原有功能外,另外

* 支持xray, vless, xtls, trojan, trojan-go, NaiveProxy 等协议及更新,
* 支持xray, vless, xtls, reality, trojan, trojan-go, NaiveProxy 等协议及更新,
* 支持ss + v2ray plugin,
* 支持混合节点订阅,
* 支持同时订阅多个链接,回车隔开,
Expand Down
23 changes: 22 additions & 1 deletion shadowsocks/res/ss-menu.js
Original file line number Diff line number Diff line change
Expand Up @@ -596,14 +596,35 @@ function openssHint(itemNum) {
statusmenu = "<b>传输层安全性协议</b>"
statusmenu += "</br></br>建议为 xtls-rprx-direct"
_caption = "流控 (flow)";
return overlib(statusmenu, OFFSETX, -560, OFFSETY, -90, LEFT, STICKY, WIDTH, 'width', CAPTION, _caption, CLOSETITLE, '');
} else if (itemNum == 112) {
width = "750px";
statusmenu = "勾选后,不会检查远端主机所提供的 TLS 证书的有效性</b>"
statusmenu += "</br>自建节点,服务端证书不可以是 Let's Encrypt证书,因为设备已经不再受支持"
statusmenu += "</br></br>如果是用机场,建议勾选"
_caption = "是否允许不安全连接";
return overlib(statusmenu, OFFSETX, -560, OFFSETY, -90, LEFT, STICKY, WIDTH, 'width', CAPTION, _caption, CLOSETITLE, '');
} else if (itemNum == 31) {
} else if (itemNum == 113) {
width = "750px";
statusmenu = "<b>必填,服务端私钥对应的公钥。</b>"
statusmenu += "</br></br>使用 ./xray x25519 -i \"服务器私钥\" 生成。"
_caption = "公钥 (publicKey)";
return overlib(statusmenu, OFFSETX, -560, OFFSETY, -90, LEFT, STICKY, WIDTH, 'width', CAPTION, _caption, CLOSETITLE, '');
} else if (itemNum == 114) {
width = "750px";
statusmenu = "<b>启用后,Xray 将通过 uTLS 库 模拟 TLS 指纹,或随机生成。</b>"
statusmenu += "</br></br>TrojanGo的指纹和Xray的不完全一样,reality协议中需要开启指纹"
statusmenu += "</br></br>其他协议包括 xray ws, H2, gRPC, tls 都支持开启指纹"
_caption = "指纹 (fingerprint)";
return overlib(statusmenu, OFFSETX, -560, OFFSETY, -90, LEFT, STICKY, WIDTH, 'width', CAPTION, _caption, CLOSETITLE, '');
} else if (itemNum == 115) {
width = "750px";
statusmenu = "<b>服务端 shortIds 之一</b>"
statusmenu += "</br></br> 服务端 shortIds 中若有此项 \"\" ,客户端 shortId 可为空"
statusmenu += "</br></br>\"0123456789abcdef\" 0 到 f,长度为 2 的倍数,长度上限为 16"
_caption = "shortId";
return overlib(statusmenu, OFFSETX, -560, OFFSETY, -90, LEFT, STICKY, WIDTH, 'width', CAPTION, _caption, CLOSETITLE, '');
} else if (itemNum == 31) {
width = "400px";
statusmenu = "<b>此处控制开启或者关闭多路复用 (Mux)</b>"
statusmenu += "</br></br>此参数在客户端json配置文件的【outbound → mux → enabled】位置"
Expand Down
44 changes: 38 additions & 6 deletions shadowsocks/scripts/ss_online_update.sh
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,8 @@ SOCKS_FLAG=0
# ssconf_basic_fingerprint_
# ssconf_basic_naive_protocol_
# ssconf_basic_naive_user_
# ssconf_basic_xray_publicKey_
# ssconf_basic_xray_shortId_
# ==============================

set_lock(){
Expand Down Expand Up @@ -950,6 +952,9 @@ get_vless_config(){
v2ray_host=$(echo "$decode_link" | tr '?&#' '\n' | grep 'host=' | awk -F'=' '{print $2}')
v2ray_tlshost=$(echo "$decode_link" | tr '?&#' '\n' | grep 'sni=' | awk -F'=' '{print $2}')
v2ray_serviceName=$(echo "$decode_link" | tr '?&#' '\n' | grep 'serviceName=' | awk -F'=' '{print $2}')
fingerprint=$(echo "$decode_link" | tr '?&#' '\n' | grep 'fp=' | awk -F'=' '{print $2}')
xray_publicKey=$(echo "$decode_link" | tr '?&#' '\n' | grep 'pbk=' | awk -F'=' '{print $2}')
xray_shortId=$(echo "$decode_link" | tr '?&#' '\n' | grep 'sid=' | awk -F'=' '{print $2}')
#把全部服务器节点编码后写入文件 /usr/share/shadowsocks/serverconfig/all_onlineservers
[ -n "$vless_group" ] && group_base64=`echo $vless_group | base64_encode | sed 's/ -//g'`
[ -n "$v2ray_add" ] && server_base64=`echo $v2ray_add | base64_encode | sed 's/ -//g'`
Expand Down Expand Up @@ -997,15 +1002,28 @@ add_vless_servers(){
dbus set ssconf_basic_v2ray_uuid_$v2rayindex=$v2ray_id
dbus set ssconf_basic_v2ray_network_security_$v2rayindex=$v2ray_tls
dbus set ssconf_basic_v2ray_network_$v2rayindex=$v2ray_net

[ -n "$fingerprint" ] && dbus set ssconf_basic_fingerprint_$v2rayindex=$fingerprint

[ -n "$v2ray_tlshost" ] && dbus set ssconf_basic_v2ray_network_tlshost_$v2rayindex=$v2ray_tlshost

case $v2ray_net in
tcp)
# tcp协议设置【 tcp伪装类型 (type)】和【tls/xtls域名 (SNI)】
# tcp + xtls 会比较多,别的组合不熟悉
dbus set ssconf_basic_v2ray_headtype_tcp_$v2rayindex="$v2ray_type"
[ "${v2ray_tls#*x}" = "tls" ] && dbus set ssconf_basic_v2ray_network_flow_$v2rayindex=$v2ray_flow
case "$v2ray_tls" in
tls|xtls)
dbus set ssconf_basic_v2ray_network_flow_$v2rayindex=$v2ray_flow
;;
reality)
dbus set ssconf_basic_v2ray_network_flow_$v2rayindex=$v2ray_flow
dbus set ssconf_basic_xray_publicKey_$v2rayindex=$xray_publicKey
dbus set ssconf_basic_xray_shortId_$v2rayindex=$xray_shortId
;;
*)

;;
esac

# @@ 不确定这个变量是否需要添加
# [ -n "$v2ray_host" ] && dbus set ssconf_basic_v2ray_network_host_$v2rayindex=$v2ray_host
Expand Down Expand Up @@ -1056,14 +1074,20 @@ update_vless_config(){
[ "$local_v2ray_net" != "$v2ray_net" ] && dbus set ssconf_basic_v2ray_network_$index=$v2ray_net && let i+=1
local_v2ray_tlshost=$(dbus get ssconf_basic_v2ray_network_tlshost_$index)
[ "$local_v2ray_tlsthost" != "$v2ray_tlshost" ] && dbus set ssconf_basic_v2ray_network_tlshost_$index=$v2ray_tlshost && let i+=1

local_fingerprint=$(dbus get ssconf_basic_fingerprint_$index)
[ "$local_v2ray_tlsthost" != "$fingerprint" ] && dbus set ssconf_basic_fingerprint_$index=$fingerprint && let i+=1

case $local_v2ray_net in
tcp)
# tcp协议
local_v2ray_type=$(dbus get ssconf_basic_v2ray_headtype_tcp_$index)
[ "$local_v2ray_type" != "$v2ray_type" ] && dbus set ssconf_basic_v2ray_headtype_tcp_$index=$v2ray_type && let i+=1
local_v2ray_flow=$(dbus get ssconf_basic_v2ray_network_flow_$index)
[ "$local_v2ray_flow" != "$v2ray_flow" ] && dbus set ssconf_basic_v2ray_network_flow_$index=$v2ray_flow && let i+=1
local_xray_publicKey=$(dbus get ssconf_basic_xray_publicKey_$index)
[ "$local_xray_publicKey" != "$xray_publicKey" ] && dbus set ssconf_basic_xray_publicKey_$index=$xray_publicKey && let i+=1
local_xray_shortId=$(dbus get ssconf_basic_xray_shortId_$index)
[ "$local_xray_shortId" != "$xray_shortId" ] && dbus set ssconf_basic_xray_shortId_$index=$xray_shortId && let i+=1

# local_v2ray_host=$(dbus get ssconf_basic_v2ray_network_host_$index)
# [ "$local_v2ray_host" != "$v2ray_host" ] && dbus set ssconf_basic_v2ray_network_host_$index=$v2ray_host && let i+=1
Expand Down Expand Up @@ -1124,8 +1148,9 @@ get_trojan_go_config(){
v2ray_path=$(echo "$decode_link" | tr '?&#' '\n' | grep 'path=' | awk -F'=' '{print $2}')
v2ray_host=$(echo "$decode_link" | tr '?&#' '\n' | grep 'host=' | awk -F'=' '{print $2}')
sni=$(echo "$decode_link" | tr '?&#' '\n' | grep 'sni=' | awk -F'=' '{print $2}')
fingerprint=$(echo "$decode_link" | tr '?&#' '\n' | grep 'fp=' | awk -F'=' '{print $2}')
binary="Trojan-Go"
fingerprint="none"
#20201024---
ss_kcp_support_tmp="0"
ss_udp_support_tmp="0"
Expand Down Expand Up @@ -1344,7 +1369,8 @@ del_none_exist(){
dbus remove ssconf_basic_weight_$localindex
dbus remove ssconf_basic_naive_protocol_$localindex
dbus remove ssconf_basic_naive_user_$localindex

dbus remove ssconf_basic_xray_publicKey_$localindex
dbus remove ssconf_basic_xray_shortId_$localindex
let delnum+=1
fi
done
Expand Down Expand Up @@ -1428,7 +1454,9 @@ remove_node_gap(){
[ -n "$(dbus get ssconf_basic_v2ray_network_flow_$nu)" ] && dbus set ssconf_basic_v2ray_network_flow_"$y"="$(dbus get ssconf_basic_v2ray_network_flow_$nu)" && dbus remove ssconf_basic_v2ray_network_flow_$nu
[ -n "$(dbus get ssconf_basic_naive_protocol_$nu)" ] && dbus set ssconf_basic_naive_protocol_"$y"="$(dbus get ssconf_basic_naive_protocol_$nu)" && dbus remove ssconf_basic_naive_protocol_$nu
[ -n "$(dbus get ssconf_basic_naive_user_$nu)" ] && dbus set ssconf_basic_naive_user_"$y"="$(dbus get ssconf_basic_naive_user_$nu)" && dbus remove ssconf_basic_naive_user_$nu

[ -n "$(dbus get ssconf_basic_xray_publicKey_$nu)" ] && dbus set ssconf_basic_xray_publicKey_"$y"="$(dbus get ssconf_basic_xray_publicKey_$nu)" && dbus remove ssconf_basic_xray_publicKey_$nu
[ -n "$(dbus get ssconf_basic_xray_shortId_$nu)" ] && dbus set ssconf_basic_xray_shortId_"$y"="$(dbus get ssconf_basic_xray_shortId_$nu)" && dbus remove ssconf_basic_xray_shortId_$nu

usleep 100000
# change node nu
if [ "$nu" == "$ssconf_basic_node" ];then
Expand Down Expand Up @@ -1767,6 +1795,8 @@ start_update(){
dbus remove ssconf_basic_weight_$conf_nu
dbus remove ssconf_basic_naive_protocol_$conf_nu
dbus remove ssconf_basic_naive_user_$conf_nu
dbus remove ssconf_basic_xray_publicKey_$conf_nu
dbus remove ssconf_basic_xray_shortId_$conf_nu
done
# 删除不再订阅节点的group信息
confs_nu_2=`dbus list ss_online_group_|grep "$local_group"| cut -d "=" -f 1|cut -d "_" -f 4`
Expand Down Expand Up @@ -1928,6 +1958,8 @@ remove_online(){
dbus remove ssconf_basic_weight_$remove_nu
dbus remove ssconf_basic_naive_protocol_$remove_nu
dbus remove ssconf_basic_naive_user_$remove_nu
dbus remove ssconf_basic_xray_publicKey_$remove_nu
dbus remove ssconf_basic_xray_shortId_$remove_nu
done
}

Expand Down
42 changes: 38 additions & 4 deletions shadowsocks/scripts/ss_webtest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,21 @@ get_path(){
fi
}

get_fingerprint(){
if [ -n "$1" ];then
echo \"$1\"
else
echo "null"
fi
}
get_tgfingerprint(){
if [ -n "$1" ];then
echo "$1"
else
echo "null"
fi
}

create_v2ray_json(){

rm -f /tmp/tmp_v2ray.json
Expand All @@ -87,6 +102,7 @@ rm -f /tmp/tmp_v2ray.json
local grpc="null"
local tls="null"
local xtls="null"
local reality="null"
local vless_flow=""

# tcp和kcp下tlsSettings为null,ws和h2下tlsSettings
Expand All @@ -97,10 +113,13 @@ rm -f /tmp/tmp_v2ray.json
local ssconf_basic_v2ray_network_tlshost_$nu="$(eval echo \$ssconf_basic_v2ray_network_host_$nu)"
fi

local local_fingerprint=$(eval echo \$ssconf_basic_fingerprint_$nu)

case "$(eval echo \$ssconf_basic_v2ray_network_security_$nu)" in
tls)
local tls="{
\"allowInsecure\": $(get_function_switch $(eval echo \$ssconf_basic_allowinsecure_$nu)),
\"fingerprint\": $(get_fingerprint $local_fingerprint),
\"serverName\": \"$(eval echo \$ssconf_basic_v2ray_network_tlshost_$nu)\"
}"
[ "$(eval echo \$ssconf_basic_v2ray_network_flow_$nu)" != "none" -a "$(eval echo \$ssconf_basic_v2ray_network_flow_$nu)" != "" ] && local vless_flow="\"flow\": \"$(eval echo \$ssconf_basic_v2ray_network_flow_$nu)\"," || local vless_flow=""
Expand All @@ -112,9 +131,20 @@ rm -f /tmp/tmp_v2ray.json
}"
local vless_flow="\"flow\": \"$(eval echo \$ssconf_basic_v2ray_network_flow_$nu)\","
;;
reality)
local reality="{
\"serverName\": \"$(eval echo \$ssconf_basic_v2ray_network_tlshost_$nu)\",
\"fingerprint\": $(get_fingerprint $local_fingerprint),
\"publicKey\": \"$(eval echo \$ssconf_basic_xray_publicKey_$nu)\",
\"shortId\": \"$(eval echo \$ssconf_basic_xray_shortId_$nu)\",
\"spiderX\": \"\"
}"
local vless_flow="\"flow\": \"$(eval echo \$ssconf_basic_v2ray_network_flow_$nu)\","
;;
*)
local tls="null"
local xtls="null"
local reality="null"
;;
esac
#fi
Expand Down Expand Up @@ -183,6 +213,7 @@ rm -f /tmp/tmp_v2ray.json
local local_header=$(eval echo \$ssconf_basic_v2ray_network_host_$nu)
local ws="{
\"connectionReuse\": true,
\"fingerprint\": $(get_fingerprint $local_fingerprint),
\"path\": $(get_path $local_path),
\"headers\": $(get_ws_header local_header)
}"
Expand All @@ -191,6 +222,7 @@ rm -f /tmp/tmp_v2ray.json
local local_path=$(eval echo \$ssconf_basic_v2ray_network_path_$nu)
local local_header=$(eval echo \$ssconf_basic_v2ray_network_host_$nu)
local h2="{
\"fingerprint\": $(get_fingerprint $local_fingerprint),
\"path\": $(get_path $local_path),
\"host\": $(get_h2_host $local_header)
}"
Expand All @@ -200,6 +232,7 @@ rm -f /tmp/tmp_v2ray.json
local grpc="{
\"multiMode\": true,
\"idle_timeout\": 13,
\"fingerprint\": $(get_fingerprint $local_fingerprint),
\"serviceName\": $(get_path $local_serviceName)
}"
;;
Expand Down Expand Up @@ -309,6 +342,7 @@ rm -f /tmp/tmp_v2ray.json
"security": "$(eval echo \$ssconf_basic_v2ray_network_security_$nu)",
"tlsSettings": $tls,
"xtlsSettings": $xtls,
"realitySettings": $reality,
"tcpSettings": $tcp,
"kcpSettings": $kcp,
"wsSettings": $ws,
Expand Down Expand Up @@ -406,7 +440,7 @@ create_trojango_json(){
}"
fi
[ -z "$(eval echo \$ssconf_basic_v2ray_mux_concurrency_$nu)" ] && local ssconf_basic_v2ray_mux_concurrency=8 || local ssconf_basic_v2ray_mux_concurrency=$(eval echo \$ssconf_basic_v2ray_mux_concurrency_$nu)
[ "$(eval echo \$ssconf_basic_fingerprint_$nu)" == "none" ] && local ssconf_basic_fingerprint="" || local ssconf_basic_fingerprint=$(eval echo \$ssconf_basic_fingerprint_$nu)
local local_fingerprint=$(eval echo \$ssconf_basic_fingerprint_$nu)
#trojan go
# 3335 for nat
cat >"/tmp/tmp_trojango.json" <<-EOF
Expand All @@ -432,7 +466,7 @@ create_trojango_json(){
],
"session_ticket": true,
"reuse_session": true,
"fingerprint": "$ssconf_basic_fingerprint"
"fingerprint": $(get_tgfingerprint $ss_basic_fingerprint)
},
"tcp": {
"no_delay": true,
Expand Down Expand Up @@ -479,7 +513,7 @@ create_trojango_json(){
],
"session_ticket": true,
"reuse_session": true,
"fingerprint": "$ssconf_basic_fingerprint"
"fingerprint": $(get_tgfingerprint $ss_basic_fingerprint)
},
"tcp": {
"no_delay": true,
Expand Down Expand Up @@ -598,7 +632,7 @@ start_webtest(){

if [ "$array12" == "0" ];then
case $array4 in
2022-blake3-aes-128-gcm|2022-blake3-aes-256-gcm|2022-blake3-chacha20-poly1305) SS2022_webtest="Y";;
2022-blake3-aes-128-gcm|2022-blake3-aes-256-gcm|2022-blake3-chacha20-poly1305|none) SS2022_webtest="Y";;
*) SS2022_webtest="N";;
esac
fi
Expand Down
Loading

0 comments on commit 5634489

Please sign in to comment.