diff --git a/install.sh b/install.sh index ce52db6..e086e81 100644 --- a/install.sh +++ b/install.sh @@ -1743,12 +1743,8 @@ initDNSAPIConfig() { exit 0 fi read -r -p "是否使用*.${dnsTLSDomain}进行API申请通配符证书?[y/n]:" dnsAPIStatus - # if [[ "${dnsAPIStatus}" != "y" ]]; then - # exit 0 - # fi fi elif [[ "$1" == "aliyun" ]]; then - # echoContent yellow "\n CF_Token参考配置教程:https://www.v2ray-agent.com/archives/1701160377972\n" read -r -p "请输入Ali Key:" aliKey read -r -p "请输入Ali Secret:" aliSecret if [[ -z "${aliKey}" || -z "${aliSecret}" ]]; then @@ -1761,9 +1757,6 @@ initDNSAPIConfig() { exit 0 fi read -r -p "是否使用*.${dnsTLSDomain}进行API申请通配符证书?[y/n]:" dnsAPIStatus - if [[ "${dnsAPIStatus}" != "y" ]]; then - exit 0 - fi fi fi } @@ -1828,10 +1821,10 @@ acmeInstallSSL() { if [[ "${dnsAPIType}" == "cloudflare" ]]; then echoContent green " ---> DNS API 生成证书中" - sudo CF_Token="${cfAPIToken}" "$HOME/.acme.sh/acme.sh" --issue -d "${dnsAPIDomain}" --dns dns_cf -k ec-256 --server "${sslType}" ${sslIPv6} 2>&1 | tee -a /etc/v2ray-agent/tls/acme.log >/dev/null + sudo CF_Token="${cfAPIToken}" "$HOME/.acme.sh/acme.sh" --issue -d "${dnsAPIDomain}" -d "${dnsTLSDomain}" --dns dns_cf -k ec-256 --server "${sslType}" ${sslIPv6} 2>&1 | tee -a /etc/v2ray-agent/tls/acme.log >/dev/null elif [[ "${dnsAPIType}" == "aliyun" ]]; then echoContent green " ---> DNS API 生成证书中" - sudo Ali_Key="${aliKey}" Ali_Secret="${aliSecret}" "$HOME/.acme.sh/acme.sh" --issue -d "${dnsAPIDomain}" --dns dns_ali -k ec-256 --server "${sslType}" ${sslIPv6} 2>&1 | tee -a /etc/v2ray-agent/tls/acme.log >/dev/null + sudo Ali_Key="${aliKey}" Ali_Secret="${aliSecret}" "$HOME/.acme.sh/acme.sh" --issue -d "${dnsAPIDomain}" -d "${dnsTLSDomain}" --dns dns_ali -k ec-256 --server "${sslType}" ${sslIPv6} 2>&1 | tee -a /etc/v2ray-agent/tls/acme.log >/dev/null else echoContent green " ---> 生成证书中" sudo "$HOME/.acme.sh/acme.sh" --issue -d "${tlsDomain}" --standalone -k ec-256 --server "${sslType}" ${sslIPv6} 2>&1 | tee -a /etc/v2ray-agent/tls/acme.log >/dev/null @@ -3979,67 +3972,65 @@ singBoxMergeConfig() { } # 初始化Xray Trojan XTLS 配置文件 -initXrayFrontingConfig() { - echoContent red " ---> Trojan暂不支持 xtls-rprx-vision" - exit 0 - if [[ -z "${configPath}" ]]; then - echoContent red " ---> 未安装,请使用脚本安装" - menu - exit 0 - fi - if [[ "${coreInstallType}" != "1" ]]; then - echoContent red " ---> 未安装可用类型" - fi - local xtlsType= - if echo ${currentInstallProtocolType} | grep -q trojan; then - xtlsType=VLESS - else - xtlsType=Trojan - - fi - - echoContent skyBlue "\n功能 1/${totalProgress} : 前置切换为${xtlsType}" - echoContent red "\n==============================================================" - echoContent yellow "# 注意事项\n" - echoContent yellow "会将前置替换为${xtlsType}" - echoContent yellow "如果前置是Trojan,查看账号时则会出现两个Trojan协议的节点,有一个不可用xtls" - echoContent yellow "再次执行可切换至上一次的前置\n" - - echoContent yellow "1.切换至${xtlsType}" - echoContent red "==============================================================" - read -r -p "请选择:" selectType - if [[ "${selectType}" == "1" ]]; then - - if [[ "${xtlsType}" == "Trojan" ]]; then - - local VLESSConfig - VLESSConfig=$(cat ${configPath}${frontingType}.json) - VLESSConfig=${VLESSConfig//"id"/"password"} - VLESSConfig=${VLESSConfig//VLESSTCP/TrojanTCPXTLS} - VLESSConfig=${VLESSConfig//VLESS/Trojan} - VLESSConfig=${VLESSConfig//"vless"/"trojan"} - VLESSConfig=${VLESSConfig//"id"/"password"} - - echo "${VLESSConfig}" | jq . >${configPath}02_trojan_TCP_inbounds.json - rm ${configPath}${frontingType}.json - elif [[ "${xtlsType}" == "VLESS" ]]; then - - local VLESSConfig - VLESSConfig=$(cat ${configPath}02_trojan_TCP_inbounds.json) - VLESSConfig=${VLESSConfig//"password"/"id"} - VLESSConfig=${VLESSConfig//TrojanTCPXTLS/VLESSTCP} - VLESSConfig=${VLESSConfig//Trojan/VLESS} - VLESSConfig=${VLESSConfig//"trojan"/"vless"} - VLESSConfig=${VLESSConfig//"password"/"id"} - - echo "${VLESSConfig}" | jq . >${configPath}02_VLESS_TCP_inbounds.json - rm ${configPath}02_trojan_TCP_inbounds.json - fi - reloadCore - fi - - exit 0 -} +#initXrayFrontingConfig() { +# echoContent red " ---> Trojan暂不支持 xtls-rprx-vision" +# if [[ -z "${configPath}" ]]; then +# echoContent red " ---> 未安装,请使用脚本安装" +# menu +# exit 0 +# fi +# if [[ "${coreInstallType}" != "1" ]]; then +# echoContent red " ---> 未安装可用类型" +# fi +# local xtlsType= +# if echo ${currentInstallProtocolType} | grep -q trojan; then +# xtlsType=VLESS +# else +# xtlsType=Trojan +# fi +# +# echoContent skyBlue "\n功能 1/${totalProgress} : 前置切换为${xtlsType}" +# echoContent red "\n==============================================================" +# echoContent yellow "# 注意事项\n" +# echoContent yellow "会将前置替换为${xtlsType}" +# echoContent yellow "如果前置是Trojan,查看账号时则会出现两个Trojan协议的节点,有一个不可用xtls" +# echoContent yellow "再次执行可切换至上一次的前置\n" +# +# echoContent yellow "1.切换至${xtlsType}" +# echoContent red "==============================================================" +# read -r -p "请选择:" selectType +# if [[ "${selectType}" == "1" ]]; then +# +# if [[ "${xtlsType}" == "Trojan" ]]; then +# +# local VLESSConfig +# VLESSConfig=$(cat ${configPath}${frontingType}.json) +# VLESSConfig=${VLESSConfig//"id"/"password"} +# VLESSConfig=${VLESSConfig//VLESSTCP/TrojanTCPXTLS} +# VLESSConfig=${VLESSConfig//VLESS/Trojan} +# VLESSConfig=${VLESSConfig//"vless"/"trojan"} +# VLESSConfig=${VLESSConfig//"id"/"password"} +# +# echo "${VLESSConfig}" | jq . >${configPath}02_trojan_TCP_inbounds.json +# rm ${configPath}${frontingType}.json +# elif [[ "${xtlsType}" == "VLESS" ]]; then +# +# local VLESSConfig +# VLESSConfig=$(cat ${configPath}02_trojan_TCP_inbounds.json) +# VLESSConfig=${VLESSConfig//"password"/"id"} +# VLESSConfig=${VLESSConfig//TrojanTCPXTLS/VLESSTCP} +# VLESSConfig=${VLESSConfig//Trojan/VLESS} +# VLESSConfig=${VLESSConfig//"trojan"/"vless"} +# VLESSConfig=${VLESSConfig//"password"/"id"} +# +# echo "${VLESSConfig}" | jq . >${configPath}02_VLESS_TCP_inbounds.json +# rm ${configPath}02_trojan_TCP_inbounds.json +# fi +# reloadCore +# fi +# +# exit 0 +#} # 初始化sing-box端口 initSingBoxPort() { @@ -9733,7 +9724,7 @@ menu() { cd "$HOME" || exit echoContent red "\n==============================================================" echoContent green "作者:mack-a" - echoContent green "当前版本:v3.4.11" + echoContent green "当前版本:v3.4.12" echoContent green "Github:https://github.com/mack-a/v2ray-agent" echoContent green "描述:八合一共存脚本\c" showInstallStatus @@ -9780,9 +9771,9 @@ menu() { 2) selectCoreInstall ;; - 3) - initXrayFrontingConfig 1 - ;; +# 3) +# initXrayFrontingConfig 1 +# ;; 4) manageHysteria ;;