예제 #1
0
        //传递所选择的参数与模板方案
        private void ButtondDecide_Click(object sender, RoutedEventArgs e)
        {
            bool preDomainMask  = ClassModel.PreDomainMask(TextBoxMaskSites.Text);
            bool domainNotEmpty = true;

            #region TCP 传输协议(VMESS)

            //TCP模式被选中
            if (RadioButtonTCP.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "TCP";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonTCP.Content.ToString();
            }

            //TCP+http伪装模式被选中
            else if (RadioButtonTCPhttp.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "TCPhttp";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonTCPhttp.Content.ToString();
                //伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "http";
            }

            //TCP+TLS模式被选中
            else if (RadioButtonTCP2TLS.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomain.Text);

                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "tcpTLS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonTCP2TLS.Content.ToString();

                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
            }

            //tcp+TLS(自签证书)模式被选中
            else if (RadioButtonTcpTLS2SelfSigned.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "tcpTLSselfSigned";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonTcpTLS2SelfSigned.Content.ToString();

                //传递域名
                // MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
            }

            #endregion

            #region VLESS协议

            //VLESS+TCP+XTLS+Web模式选中
            else if (RadioButtonVlessXtlsTcp.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomain.Text);

                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "VlessXtlsTcp";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonVlessXtlsTcp.Content.ToString();

                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
                //传递伪装网站
                MainWindow.ReceiveConfigurationParameters[7] = ClassModel.DisguiseURLprocessing(PreTrim(TextBoxMaskSites.Text));
            }

            //VLESS+TCP+TLS+Web模式选中
            else if (RadioButtonVlessTcpTlsWeb.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomain.Text);

                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "VlessTcpTlsWeb";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonVlessTcpTlsWeb.Content.ToString();

                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
                //传递伪装网站
                MainWindow.ReceiveConfigurationParameters[7] = ClassModel.DisguiseURLprocessing(PreTrim(TextBoxMaskSites.Text));
            }

            //VLESS+WebSocket+TLS+Web模式选中
            else if (RadioButtonVlessWebSocketTlsWeb.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomain.Text);

                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "VlessWebSocketTlsWeb";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonVlessWebSocketTlsWeb.Content.ToString();

                //传递路径
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxPath.Text);
                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
                //传递伪装网站
                MainWindow.ReceiveConfigurationParameters[7] = ClassModel.DisguiseURLprocessing(PreTrim(TextBoxMaskSites.Text));
            }

            //VLESS+http2+TLS+Web模式选中
            else if (RadioButtonVlessHttp2Web.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomain.Text);

                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "VlessHttp2Web";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonVlessHttp2Web.Content.ToString();

                //传递路径
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxPath.Text);
                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
                //传递伪装网站
                MainWindow.ReceiveConfigurationParameters[7] = ClassModel.DisguiseURLprocessing(PreTrim(TextBoxMaskSites.Text));
            }

            //VLESS+VMESS+Trojan+XTLS+TCP+WebSocket+Web模式被选中
            else if (RadioButtonVlessVmessXtlsTcpWebSocketHot.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomain.Text);
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "VlessVmessXtlsTcpWebSocketWeb";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonVlessVmessXtlsTcpWebSocketHot.Content.ToString();
                //传递路径
                MainWindow.ReceiveConfigurationParameters[3] = PreTrim(TextBoxPathVlessWS.Text);  //VLESS ws Path
                MainWindow.ReceiveConfigurationParameters[9] = PreTrim(TextBoxPathVmessTcp.Text); //VMESS tcp Path
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxPathVmessWS.Text);  //VMESS ws Path

                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
                //传递混淆方式(VMESS TCP Path方式所用)
                MainWindow.ReceiveConfigurationParameters[5] = "http";
                //传递伪装网站
                MainWindow.ReceiveConfigurationParameters[7] = ClassModel.DisguiseURLprocessing(PreTrim(TextBoxMaskSites.Text));
            }

            #endregion

            #region WebSocket传输协议(VMESS)

            //webSocket模式被选中
            else if (RadioButtonWebSocket.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "webSocket";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonWebSocket.Content.ToString();
            }

            //WebSocket+TLS模式被选中
            else if (RadioButtonWebSocketTLS.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomain.Text);

                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "WebSocketTLS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonWebSocketTLS.Content.ToString();
                //传递路径
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxPath.Text);
                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
            }

            //WebSocket+TLS+Web模式被选中
            else if (RadioButtonWebSocketTLS2Web.IsChecked == true || RadioButtonWebSocketTLS2WebHot.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomain.Text);

                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "WebSocketTLS2Web";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonWebSocketTLS2Web.Content.ToString();

                //传递路径
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxPath.Text);
                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
                //传递伪装网站
                MainWindow.ReceiveConfigurationParameters[7] = ClassModel.DisguiseURLprocessing(PreTrim(TextBoxMaskSites.Text));
            }

            //WebSocket+TLS(自签证书)模式被选中
            else if (RadioButtonWebSocketTLSselfSigned.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "WebSocketTLSselfSigned";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonWebSocketTLSselfSigned.Content.ToString();

                //传递路径
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxPath.Text);
                //传递域名
                //MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
            }

            #endregion

            #region http2传输协议(VMESS)

            //http2模式被选中
            else if (RadioButtonHTTP2.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomain.Text);

                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "Http2";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonHTTP2.Content.ToString();

                //传递路径
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxPath.Text);
                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
            }

            //http2+TLS+Web模式被选中
            else if (RadioButtonHTTP2Web.IsChecked == true || RadioButtonHTTP2WebHot.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomain.Text);

                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "http2Web";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonHTTP2Web.Content.ToString();

                //传递路径
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxPath.Text);
                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
                //传递伪装网站
                MainWindow.ReceiveConfigurationParameters[7] = ClassModel.DisguiseURLprocessing(PreTrim(TextBoxMaskSites.Text));
            }

            //http2(自签证书)模式被选中
            else if (RadioButtonHTTP2selfSigned.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "http2selfSigned";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonHTTP2selfSigned.Content.ToString();

                //传递路径
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxPath.Text);
                //传递域名
                //MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomain.Text);
            }

            #endregion

            #region mKCP 传输协议 (VMESS)

            //mKCP无伪装模式被选中
            else if (RadioButtonMkcpNone.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "mKCPNone";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonMkcpNone.Content.ToString();
                //传递伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "none";
                //传递mKCP Seed
                if (String.IsNullOrEmpty(PreTrim(TextBoxQuicAndMkcpSeedUUID.Text)) == false)
                {
                    MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxQuicAndMkcpSeedUUID.Text);
                }
            }

            //mKCP+srtp伪装模式被选中
            else if (RadioButton2mKCP2SRTP.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "mKCP2SRTP";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButton2mKCP2SRTP.Content.ToString();
                //传递伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "srtp";
                //传递mKCP Seed
                if (String.IsNullOrEmpty(PreTrim(TextBoxQuicAndMkcpSeedUUID.Text)) == false)
                {
                    MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxQuicAndMkcpSeedUUID.Text);
                }
            }

            //mKCP+utp伪装模式被选中
            else if (RadioButton2mKCPuTP.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "mKCPuTP";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButton2mKCPuTP.Content.ToString();
                //传递伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "utp";
                //传递mKCP Seed
                if (String.IsNullOrEmpty(PreTrim(TextBoxQuicAndMkcpSeedUUID.Text)) == false)
                {
                    MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxQuicAndMkcpSeedUUID.Text);
                }
            }

            //mKCP+wechat-video伪装模式被选中
            else if (RadioButton2mKCP2WechatVideo.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "mKCP2WechatVideo";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButton2mKCP2WechatVideo.Content.ToString();
                //传递伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "wechat-video";
                //传递mKCP Seed
                if (String.IsNullOrEmpty(PreTrim(TextBoxQuicAndMkcpSeedUUID.Text)) == false)
                {
                    MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxQuicAndMkcpSeedUUID.Text);
                }
            }

            //mKCP+dtls伪装模式被选中
            else if (RadioButton2mKCP2DTLS.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "mKCP2DTLS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButton2mKCP2DTLS.Content.ToString();
                //传递伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "dtls";
                //传递mKCP Seed
                if (String.IsNullOrEmpty(PreTrim(TextBoxQuicAndMkcpSeedUUID.Text)) == false)
                {
                    MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxQuicAndMkcpSeedUUID.Text);
                }
            }

            //mKCP+wireguard伪装模式被选中
            else if (RadioButton2mKCP2WireGuard.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "mKCP2WireGuard";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButton2mKCP2WireGuard.Content.ToString();
                //传递伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "wireguard";
                //传递mKCP Seed
                if (String.IsNullOrEmpty(PreTrim(TextBoxQuicAndMkcpSeedUUID.Text)) == false)
                {
                    MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxQuicAndMkcpSeedUUID.Text);
                }
            }

            #endregion

            #region QUIC传输协议(VMESS)

            //QUIC无伪装模式被选中
            else if (RadioButtonQuicNone.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "QuicNone";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonQuicNone.Content.ToString();
                //传递伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "none";
                //QUIC 密钥
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxQuicAndMkcpSeedUUID.Text);
                //QUIC加密方法
                MainWindow.ReceiveConfigurationParameters[3] = GetEncryptionMethodSS();
            }

            //QUIC+srtp伪装模式被选中
            else if (RadioButtonQuicSRTP.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "QuicSRTP";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonQuicSRTP.Content.ToString();
                //传递伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "srtp";
                //QUIC 密钥
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxQuicAndMkcpSeedUUID.Text);
                //QUIC加密方法
                MainWindow.ReceiveConfigurationParameters[3] = GetEncryptionMethodSS();
            }

            //QUIC+utp伪装模式被选中
            else if (RadioButtonQuic2uTP.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "Quic2uTP";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonQuic2uTP.Content.ToString();
                //传递伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "utp";
                //QUIC 密钥
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxQuicAndMkcpSeedUUID.Text);
                //QUIC加密方法
                MainWindow.ReceiveConfigurationParameters[3] = GetEncryptionMethodSS();
            }

            //QUIC+wechat-video伪装模式被选中
            else if (RadioButtonQuicWechatVideo.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "QuicWechatVideo";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonQuicWechatVideo.Content.ToString();
                //传递伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "wechat-video";
                //QUIC 密钥
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxQuicAndMkcpSeedUUID.Text);
                //QUIC加密方法
                MainWindow.ReceiveConfigurationParameters[3] = GetEncryptionMethodSS();
            }

            //QUIC+dtls伪装模式被选中
            else if (RadioButtonQuicDTLS.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "QuicDTLS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonQuicDTLS.Content.ToString();
                //传递伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "dtls";
                //QUIC 密钥
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxQuicAndMkcpSeedUUID.Text);
                //QUIC加密方法
                MainWindow.ReceiveConfigurationParameters[3] = GetEncryptionMethodSS();
            }

            //QUIC+wireguard伪装模式被选中
            else if (RadioButtonQuicWireGuard.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "QuicWireGuard";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonQuicWireGuard.Content.ToString();
                //传递伪装类型
                MainWindow.ReceiveConfigurationParameters[5] = "wireguard";
                //QUIC 密钥
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxQuicAndMkcpSeedUUID.Text);
                //QUIC加密方法
                MainWindow.ReceiveConfigurationParameters[3] = GetEncryptionMethodSS();
            }

            #endregion

            //传递服务端口
            MainWindow.ReceiveConfigurationParameters[1] = PreTrim(TextBoxServerListenPort.Text);
            //传递uuid
            MainWindow.ReceiveConfigurationParameters[2] = PreTrim(TextBoxNewUUID.Text);

            if (RadioButtonVLESSmKCP.IsChecked == true)
            {
                MainWindow.mKCPvlessIsSet = true;
            }
            else
            {
                MainWindow.mKCPvlessIsSet = false;
            }

            if (domainNotEmpty == true && preDomainMask == true)
            {
                this.Close();
            }
        }
예제 #2
0
        //伪装网站处理
        //private string DisguiseURLprocessing(string fakeUrl)
        //{
        //var uri = new Uri(fakeUrl);
        //return uri.Host;
        //处理伪装网站域名中的前缀
        //if (fakeUrl.Length >= 7)
        //{
        //    string testDomainMask = fakeUrl.Substring(0, 7);
        //    if (String.Equals(testDomainMask, "https:/") || String.Equals(testDomainMask, "http://"))
        //    {
        //        string[] tmpUrl = fakeUrl.Split('/');
        //        fakeUrl = tmpUrl[2];
        //    }

        //}
        //return fakeUrl;
        // }

        private void ButtondDecide_Click(object sender, RoutedEventArgs e)
        {
            bool preDomainMask  = ClassModel.PreDomainMask(TextBoxMaskSites.Text);
            bool domainNotEmpty = true;

            //UncheckLayouts(TabControlTemplate);
            //SS 经典模式被选中
            if (RadioButtonNonePluginSS.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "NonePluginSS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonNonePluginSS.Content.ToString();
            }
            //SS+obfs+http+web伪装模式被选中
            else if (RadioButtonObfsPluginHttpWebSS.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "ObfsPluginHttpWebSS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonObfsPluginHttpWebSS.Content.ToString();
            }
            //SS+obfs+TLS+web模式被选中
            else if (RadioButtonObfsPluginHttpsWebSS.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomainSS.Text);
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "ObfsPluginHttpsWebSS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonObfsPluginHttpsWebSS.Content.ToString();
                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomainSS.Text);
                //传递伪装网站
                MainWindow.ReceiveConfigurationParameters[7] = ClassModel.DisguiseURLprocessing(PreTrim(TextBoxMaskSites.Text));
            }

            //V2Ray-Plugin SS+WebSocket 无TLS模式被选中
            else if (RadioButtonWebSocketSS.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "WebSocketSS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonWebSocketSS.Content.ToString();
                //传递路径
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxWebSocketPathSS.Text);
            }

            //V2Ray-Plugin SS+WebSocket+TLS+Web模式被选中
            else if (RadioButtonWebSocketTLSWebFrontSS.IsChecked == true || RadioButtonWebSocketTLSWebFrontSSHot.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomainSS.Text);
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "WebSocketTLSWebFrontSS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonWebSocketTLSWebFrontSS.Content.ToString();

                //传递路径
                MainWindow.ReceiveConfigurationParameters[6] = PreTrim(TextBoxWebSocketPathSS.Text);
                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomainSS.Text);
                //传递伪装网站
                MainWindow.ReceiveConfigurationParameters[7] = ClassModel.DisguiseURLprocessing(PreTrim(TextBoxMaskSites.Text));
            }
            //V2Ray-Plugin SS+QUIC模式被选中
            else if (RadioButtonQuicSS.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomainSS.Text);
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "QuicSS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonQuicSS.Content.ToString();

                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomainSS.Text);
            }
            //SS+kcptun-plugin模式被选中
            else if (RadioButtonKcptunPluginSS.IsChecked == true)
            {
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "KcptunPluginSS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonKcptunPluginSS.Content.ToString();
            }
            //SS+GoQuiet-Plugin模式被选中
            else if (RadioButtonGoQuietPluginSS.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomainSS.Text);
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "GoQuietPluginSS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonGoQuietPluginSS.Content.ToString();
                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomainSS.Text);
            }
            //SS+Cloak-Plugin模式被选中
            else if (RadioButtonCloakPluginSS.IsChecked == true)
            {
                domainNotEmpty = ClassModel.TestDomainIsEmpty(TextBoxDomainSS.Text);
                //传递模板类型
                MainWindow.ReceiveConfigurationParameters[0] = "CloakPluginSS";
                //传递方案名称
                MainWindow.ReceiveConfigurationParameters[8] = RadioButtonCloakPluginSS.Content.ToString();
                //传递域名
                MainWindow.ReceiveConfigurationParameters[4] = PreTrim(TextBoxDomainSS.Text);
            }

            //传递服务端口
            MainWindow.ReceiveConfigurationParameters[1] = PreTrim(TextBoxServerListenPortSS.Text);
            //传递uuid密码
            MainWindow.ReceiveConfigurationParameters[2] = PreTrim(TextBoxNewUUIDSS.Text);
            //传递加密方式
            MainWindow.ReceiveConfigurationParameters[3] = GetEncryptionMethodSS();

            if (domainNotEmpty == true && preDomainMask == true)
            {
                this.Close();
            }
        }