diff --git a/v2rayN/ServiceLib/Global.cs b/v2rayN/ServiceLib/Global.cs index 312140d6..8de3d925 100644 --- a/v2rayN/ServiceLib/Global.cs +++ b/v2rayN/ServiceLib/Global.cs @@ -691,14 +691,6 @@ public class Global "" ]; - public static readonly List EchForceQuerys = - [ - "none", - "half", - "full", - "" - ]; - public static readonly List TunIcmpRoutingPolicies = [ "rule", diff --git a/v2rayN/ServiceLib/Handler/ConfigHandler.cs b/v2rayN/ServiceLib/Handler/ConfigHandler.cs index d319118f..12523ddf 100644 --- a/v2rayN/ServiceLib/Handler/ConfigHandler.cs +++ b/v2rayN/ServiceLib/Handler/ConfigHandler.cs @@ -256,7 +256,6 @@ public static class ConfigHandler item.Cert = profileItem.Cert; item.CertSha = profileItem.CertSha; item.EchConfigList = profileItem.EchConfigList; - item.EchForceQuery = profileItem.EchForceQuery; item.Finalmask = profileItem.Finalmask; item.ProtoExtra = profileItem.ProtoExtra; item.TransportExtra = profileItem.TransportExtra; diff --git a/v2rayN/ServiceLib/Models/ProfileItem.cs b/v2rayN/ServiceLib/Models/ProfileItem.cs index 6fe44a3b..ae5f77ad 100644 --- a/v2rayN/ServiceLib/Models/ProfileItem.cs +++ b/v2rayN/ServiceLib/Models/ProfileItem.cs @@ -191,7 +191,6 @@ public class ProfileItem public string Cert { get; set; } public string CertSha { get; set; } public string EchConfigList { get; set; } - public string EchForceQuery { get; set; } public string Finalmask { get; set; } public string ProtoExtra { get; set; } diff --git a/v2rayN/ServiceLib/Resx/ResUI.Designer.cs b/v2rayN/ServiceLib/Resx/ResUI.Designer.cs index 4ffb8efa..56f95191 100644 --- a/v2rayN/ServiceLib/Resx/ResUI.Designer.cs +++ b/v2rayN/ServiceLib/Resx/ResUI.Designer.cs @@ -2943,15 +2943,6 @@ namespace ServiceLib.Resx { } } - /// - /// 查找类似 EchForceQuery 的本地化字符串。 - /// - public static string TbEchForceQuery { - get { - return ResourceManager.GetString("TbEchForceQuery", resourceCulture); - } - } - /// /// 查找类似 Edit 的本地化字符串。 /// diff --git a/v2rayN/ServiceLib/Resx/ResUI.fa-Ir.resx b/v2rayN/ServiceLib/Resx/ResUI.fa-Ir.resx index 8b81572c..f2818543 100644 --- a/v2rayN/ServiceLib/Resx/ResUI.fa-Ir.resx +++ b/v2rayN/ServiceLib/Resx/ResUI.fa-Ir.resx @@ -1581,9 +1581,6 @@ The "Get Certificate" action may fail if a self-signed certificate is used or if EchConfigList - - EchForceQuery - Full certificate (chain), PEM format diff --git a/v2rayN/ServiceLib/Resx/ResUI.fr.resx b/v2rayN/ServiceLib/Resx/ResUI.fr.resx index b9fa9ffd..1a782f98 100644 --- a/v2rayN/ServiceLib/Resx/ResUI.fr.resx +++ b/v2rayN/ServiceLib/Resx/ResUI.fr.resx @@ -1587,9 +1587,6 @@ The "Get Certificate" action may fail if a self-signed certificate is used or if EchConfigList - - EchForceQuery - Certificat complet (chaîne), format PEM diff --git a/v2rayN/ServiceLib/Resx/ResUI.hu.resx b/v2rayN/ServiceLib/Resx/ResUI.hu.resx index a3e99129..dbd24707 100644 --- a/v2rayN/ServiceLib/Resx/ResUI.hu.resx +++ b/v2rayN/ServiceLib/Resx/ResUI.hu.resx @@ -1581,9 +1581,6 @@ The "Get Certificate" action may fail if a self-signed certificate is used or if EchConfigList - - EchForceQuery - Full certificate (chain), PEM format diff --git a/v2rayN/ServiceLib/Resx/ResUI.resx b/v2rayN/ServiceLib/Resx/ResUI.resx index 2cc7929e..b3cbc87e 100644 --- a/v2rayN/ServiceLib/Resx/ResUI.resx +++ b/v2rayN/ServiceLib/Resx/ResUI.resx @@ -1590,9 +1590,6 @@ The "Get Certificate" action may fail if a self-signed certificate is used or if EchConfigList - - EchForceQuery - Full certificate (chain), PEM format diff --git a/v2rayN/ServiceLib/Resx/ResUI.ru.resx b/v2rayN/ServiceLib/Resx/ResUI.ru.resx index c1dc1b35..f394c23b 100644 --- a/v2rayN/ServiceLib/Resx/ResUI.ru.resx +++ b/v2rayN/ServiceLib/Resx/ResUI.ru.resx @@ -1581,9 +1581,6 @@ EchConfigList - - EchForceQuery - Полный сертификат (цепочка) в формате PEM diff --git a/v2rayN/ServiceLib/Resx/ResUI.zh-Hans.resx b/v2rayN/ServiceLib/Resx/ResUI.zh-Hans.resx index 06d07da0..4e2bd39d 100644 --- a/v2rayN/ServiceLib/Resx/ResUI.zh-Hans.resx +++ b/v2rayN/ServiceLib/Resx/ResUI.zh-Hans.resx @@ -1587,9 +1587,6 @@ EchConfigList - - EchForceQuery - 完整证书(链),PEM 格式 diff --git a/v2rayN/ServiceLib/Resx/ResUI.zh-Hant.resx b/v2rayN/ServiceLib/Resx/ResUI.zh-Hant.resx index e12e3f39..14cbec63 100644 --- a/v2rayN/ServiceLib/Resx/ResUI.zh-Hant.resx +++ b/v2rayN/ServiceLib/Resx/ResUI.zh-Hant.resx @@ -1578,9 +1578,6 @@ EchConfigList - - EchForceQuery - 完整憑證(鏈),PEM 格式 diff --git a/v2rayN/ServiceLib/Services/CoreConfig/V2ray/V2rayOutboundService.cs b/v2rayN/ServiceLib/Services/CoreConfig/V2ray/V2rayOutboundService.cs index 4d88b1b5..d8985ccc 100644 --- a/v2rayN/ServiceLib/Services/CoreConfig/V2ray/V2rayOutboundService.cs +++ b/v2rayN/ServiceLib/Services/CoreConfig/V2ray/V2rayOutboundService.cs @@ -383,7 +383,6 @@ public partial class CoreConfigV2rayService alpn = _node.GetAlpn(), fingerprint = _node.Fingerprint.IsNullOrEmpty() ? _config.CoreBasicItem.DefFingerprint : _node.Fingerprint, echConfigList = _node.EchConfigList.NullIfEmpty(), - echForceQuery = _node.EchForceQuery.NullIfEmpty() }; if (sni.IsNotEmpty()) { @@ -393,6 +392,11 @@ public partial class CoreConfigV2rayService { tlsSettings.serverName = Utils.String2List(host)?.First(); } + if (!tlsSettings.echConfigList.IsNullOrEmpty()) + { + // For legacy xray compatibility, remove this in the future + tlsSettings.echForceQuery = "full"; + } var certs = CertPemManager.ParsePemChain(_node.Cert); if (certs.Count > 0) { diff --git a/v2rayN/v2rayN.Desktop/Views/AddServerWindow.axaml b/v2rayN/v2rayN.Desktop/Views/AddServerWindow.axaml index 00bcff1b..3ab748b1 100644 --- a/v2rayN/v2rayN.Desktop/Views/AddServerWindow.axaml +++ b/v2rayN/v2rayN.Desktop/Views/AddServerWindow.axaml @@ -306,7 +306,7 @@ x:Name="txtSecurity5" Grid.Row="3" Grid.Column="1" - Width="200" + Width="400" Margin="{StaticResource Margin4}" HorizontalAlignment="Left" /> @@ -1115,19 +1115,6 @@ Margin="{StaticResource Margin4}" HorizontalAlignment="Left" /> - - - cmbFingerprint2.ItemsSource = Global.Fingerprints; cmbAllowInsecure.ItemsSource = Global.AllowInsecure; cmbAlpn.ItemsSource = Global.Alpns; - cmbEchForceQuery.ItemsSource = Global.EchForceQuerys; - var lstStreamSecurity = new List(); - lstStreamSecurity.Add(string.Empty); - lstStreamSecurity.Add(Global.StreamSecurity); + var lstStreamSecurity = new List { string.Empty, Global.StreamSecurity }; switch (profileItem.ConfigType) { @@ -246,7 +243,6 @@ public partial class AddServerWindow : WindowBase this.Bind(ViewModel, vm => vm.AllowInsecureCertFetch, v => v.togAllowInsecureCertFetch.IsChecked).DisposeWith(disposables); this.Bind(ViewModel, vm => vm.AllowInsecureCertFetch, v => v.txtAllowInsecureCertFetchTips.IsVisible).DisposeWith(disposables); this.Bind(ViewModel, vm => vm.SelectedSource.EchConfigList, v => v.txtEchConfigList.Text).DisposeWith(disposables); - this.Bind(ViewModel, vm => vm.SelectedSource.EchForceQuery, v => v.cmbEchForceQuery.SelectedValue).DisposeWith(disposables); //reality this.Bind(ViewModel, vm => vm.SelectedSource.Sni, v => v.txtSNI2.Text).DisposeWith(disposables); diff --git a/v2rayN/v2rayN/Views/AddServerWindow.xaml b/v2rayN/v2rayN/Views/AddServerWindow.xaml index 4efb6b94..047d32e4 100644 --- a/v2rayN/v2rayN/Views/AddServerWindow.xaml +++ b/v2rayN/v2rayN/Views/AddServerWindow.xaml @@ -415,7 +415,7 @@ x:Name="txtSecurity5" Grid.Row="3" Grid.Column="1" - Width="200" + Width="400" Margin="{StaticResource Margin4}" HorizontalAlignment="Left" Style="{StaticResource DefTextBox}" /> @@ -1444,21 +1444,6 @@ HorizontalAlignment="Left" Style="{StaticResource DefTextBox}" /> - - - (); - lstStreamSecurity.Add(string.Empty); - lstStreamSecurity.Add(Global.StreamSecurity); + var lstStreamSecurity = new List { string.Empty, Global.StreamSecurity }; switch (profileItem.ConfigType) { @@ -247,7 +244,6 @@ public partial class AddServerWindow .BindTo(this, v => v.txtAllowInsecureCertFetchTips.Visibility); this.Bind(ViewModel, vm => vm.Cert, v => v.txtCert.Text).DisposeWith(disposables); this.Bind(ViewModel, vm => vm.SelectedSource.EchConfigList, v => v.txtEchConfigList.Text).DisposeWith(disposables); - this.Bind(ViewModel, vm => vm.SelectedSource.EchForceQuery, v => v.cmbEchForceQuery.Text).DisposeWith(disposables); //reality this.Bind(ViewModel, vm => vm.SelectedSource.Sni, v => v.txtSNI2.Text).DisposeWith(disposables);