|
|
@ -71,8 +71,8 @@ uuid=$(cat /proc/sys/kernel/random/uuid) |
|
|
|
old_id="e55c8d17-2cf3-b21a-bcf1-eeacb011ed79" |
|
|
|
old_id="e55c8d17-2cf3-b21a-bcf1-eeacb011ed79" |
|
|
|
v2ray_server_config="/etc/v2ray/config.json" |
|
|
|
v2ray_server_config="/etc/v2ray/config.json" |
|
|
|
v2ray_client_config="/etc/v2ray/233blog_v2ray_config.json" |
|
|
|
v2ray_client_config="/etc/v2ray/233blog_v2ray_config.json" |
|
|
|
v2ray_pid=$(ps ux | grep "/usr/bin/v2ray/v2ray" | grep -v grep | awk '{print $2}') |
|
|
|
v2ray_pid=$(pgrep -f /usr/bin/v2ray/v2ray) |
|
|
|
caddy_pid=$(pgrep "caddy") |
|
|
|
caddy_pid=$(pgrep -f /usr/local/bin/caddy) |
|
|
|
_v2ray_sh="/usr/local/sbin/v2ray" |
|
|
|
_v2ray_sh="/usr/local/sbin/v2ray" |
|
|
|
v2ray_ver="$(/usr/bin/v2ray/v2ray -version | head -n 1 | cut -d " " -f2)" |
|
|
|
v2ray_ver="$(/usr/bin/v2ray/v2ray -version | head -n 1 | cut -d " " -f2)" |
|
|
|
. /etc/v2ray/233boy/v2ray/src/init.sh |
|
|
|
. /etc/v2ray/233boy/v2ray/src/init.sh |
|
|
@ -346,7 +346,7 @@ shadowsocks_config() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_shadowsocks_config_info |
|
|
|
view_shadowsocks_config_info |
|
|
|
get_shadowsocks_config_qr_ask |
|
|
|
# get_shadowsocks_config_qr_ask |
|
|
|
break |
|
|
|
break |
|
|
|
elif [[ "$install_shadowsocks" == [Nn] ]]; then |
|
|
|
elif [[ "$install_shadowsocks" == [Nn] ]]; then |
|
|
|
echo |
|
|
|
echo |
|
|
@ -531,7 +531,7 @@ change_shadowsocks_port() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_shadowsocks_config_info |
|
|
|
view_shadowsocks_config_info |
|
|
|
get_shadowsocks_config_qr_ask |
|
|
|
# get_shadowsocks_config_qr_ask |
|
|
|
break |
|
|
|
break |
|
|
|
fi |
|
|
|
fi |
|
|
|
;; |
|
|
|
;; |
|
|
@ -572,7 +572,7 @@ change_shadowsocks_password() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_shadowsocks_config_info |
|
|
|
view_shadowsocks_config_info |
|
|
|
get_shadowsocks_config_qr_ask |
|
|
|
# get_shadowsocks_config_qr_ask |
|
|
|
break |
|
|
|
break |
|
|
|
;; |
|
|
|
;; |
|
|
|
esac |
|
|
|
esac |
|
|
@ -612,7 +612,7 @@ change_shadowsocks_ciphers() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_shadowsocks_config_info |
|
|
|
view_shadowsocks_config_info |
|
|
|
get_shadowsocks_config_qr_ask |
|
|
|
# get_shadowsocks_config_qr_ask |
|
|
|
break |
|
|
|
break |
|
|
|
;; |
|
|
|
;; |
|
|
|
*) |
|
|
|
*) |
|
|
@ -800,7 +800,7 @@ change_v2ray_port() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
break |
|
|
|
break |
|
|
|
fi |
|
|
|
fi |
|
|
|
;; |
|
|
|
;; |
|
|
@ -940,7 +940,7 @@ change_v2ray_transport() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
else |
|
|
|
else |
|
|
|
old_transport |
|
|
|
old_transport |
|
|
|
backup_config v2ray_transport |
|
|
|
backup_config v2ray_transport |
|
|
@ -948,7 +948,7 @@ change_v2ray_transport() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
fi |
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
@ -1053,7 +1053,7 @@ tls_config() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
else |
|
|
|
else |
|
|
|
if [[ $v2ray_transport_opt == 5 ]]; then |
|
|
|
if [[ $v2ray_transport_opt == 5 ]]; then |
|
|
|
path_config_ask |
|
|
|
path_config_ask |
|
|
@ -1079,7 +1079,7 @@ tls_config() { |
|
|
|
caddy=true |
|
|
|
caddy=true |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
else |
|
|
|
else |
|
|
|
auto_tls_config |
|
|
|
auto_tls_config |
|
|
|
fi |
|
|
|
fi |
|
|
@ -1135,7 +1135,7 @@ auto_tls_config() { |
|
|
|
caddy=true |
|
|
|
caddy=true |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
break |
|
|
|
break |
|
|
|
elif [[ "$auto_install_caddy" == [Nn] ]]; then |
|
|
|
elif [[ "$auto_install_caddy" == [Nn] ]]; then |
|
|
|
echo |
|
|
|
echo |
|
|
@ -1156,7 +1156,7 @@ auto_tls_config() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
break |
|
|
|
break |
|
|
|
else |
|
|
|
else |
|
|
|
error |
|
|
|
error |
|
|
@ -1557,7 +1557,7 @@ change_v2ray_id() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
break |
|
|
|
break |
|
|
|
elif [[ $y_n == [Nn] ]]; then |
|
|
|
elif [[ $y_n == [Nn] ]]; then |
|
|
|
echo |
|
|
|
echo |
|
|
@ -1621,7 +1621,7 @@ change_domain() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
break |
|
|
|
break |
|
|
|
else |
|
|
|
else |
|
|
|
error |
|
|
|
error |
|
|
@ -1683,7 +1683,7 @@ change_path_config() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
elif [[ $v2ray_transport == [45] ]] && [[ $caddy ]]; then |
|
|
|
elif [[ $v2ray_transport == [45] ]] && [[ $caddy ]]; then |
|
|
|
path_config_ask |
|
|
|
path_config_ask |
|
|
|
if [[ $new_path ]]; then |
|
|
|
if [[ $new_path ]]; then |
|
|
@ -1695,7 +1695,7 @@ change_path_config() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
else |
|
|
|
else |
|
|
|
echo |
|
|
|
echo |
|
|
|
echo |
|
|
|
echo |
|
|
@ -1772,7 +1772,7 @@ change_proxy_site_config() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
else |
|
|
|
else |
|
|
|
echo |
|
|
|
echo |
|
|
|
echo |
|
|
|
echo |
|
|
@ -1835,7 +1835,7 @@ disable_path() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
break |
|
|
|
break |
|
|
|
elif [[ "$y_n" == [Nn] ]]; then |
|
|
|
elif [[ "$y_n" == [Nn] ]]; then |
|
|
|
echo |
|
|
|
echo |
|
|
@ -1971,7 +1971,7 @@ change_v2ray_alterId() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
break |
|
|
|
break |
|
|
|
;; |
|
|
|
;; |
|
|
|
*) |
|
|
|
*) |
|
|
@ -2015,7 +2015,7 @@ custom_uuid() { |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
break |
|
|
|
break |
|
|
|
;; |
|
|
|
;; |
|
|
|
esac |
|
|
|
esac |
|
|
@ -2964,7 +2964,7 @@ reuuid) |
|
|
|
config |
|
|
|
config |
|
|
|
clear |
|
|
|
clear |
|
|
|
view_v2ray_config_info |
|
|
|
view_v2ray_config_info |
|
|
|
download_v2ray_config_ask |
|
|
|
# download_v2ray_config_ask |
|
|
|
;; |
|
|
|
;; |
|
|
|
v | version) |
|
|
|
v | version) |
|
|
|
echo |
|
|
|
echo |
|
|
|