mirror of
https://github.com/2dust/v2rayN.git
synced 2026-05-02 04:15:50 +00:00
Remove EchForceQuery (#9214)
This commit is contained in:
parent
05e349e45c
commit
b6f2912f29
16 changed files with 9 additions and 81 deletions
|
|
@ -691,14 +691,6 @@ public class Global
|
||||||
""
|
""
|
||||||
];
|
];
|
||||||
|
|
||||||
public static readonly List<string> EchForceQuerys =
|
|
||||||
[
|
|
||||||
"none",
|
|
||||||
"half",
|
|
||||||
"full",
|
|
||||||
""
|
|
||||||
];
|
|
||||||
|
|
||||||
public static readonly List<string> TunIcmpRoutingPolicies =
|
public static readonly List<string> TunIcmpRoutingPolicies =
|
||||||
[
|
[
|
||||||
"rule",
|
"rule",
|
||||||
|
|
|
||||||
|
|
@ -256,7 +256,6 @@ public static class ConfigHandler
|
||||||
item.Cert = profileItem.Cert;
|
item.Cert = profileItem.Cert;
|
||||||
item.CertSha = profileItem.CertSha;
|
item.CertSha = profileItem.CertSha;
|
||||||
item.EchConfigList = profileItem.EchConfigList;
|
item.EchConfigList = profileItem.EchConfigList;
|
||||||
item.EchForceQuery = profileItem.EchForceQuery;
|
|
||||||
item.Finalmask = profileItem.Finalmask;
|
item.Finalmask = profileItem.Finalmask;
|
||||||
item.ProtoExtra = profileItem.ProtoExtra;
|
item.ProtoExtra = profileItem.ProtoExtra;
|
||||||
item.TransportExtra = profileItem.TransportExtra;
|
item.TransportExtra = profileItem.TransportExtra;
|
||||||
|
|
|
||||||
|
|
@ -191,7 +191,6 @@ public class ProfileItem
|
||||||
public string Cert { get; set; }
|
public string Cert { get; set; }
|
||||||
public string CertSha { get; set; }
|
public string CertSha { get; set; }
|
||||||
public string EchConfigList { get; set; }
|
public string EchConfigList { get; set; }
|
||||||
public string EchForceQuery { get; set; }
|
|
||||||
public string Finalmask { get; set; }
|
public string Finalmask { get; set; }
|
||||||
|
|
||||||
public string ProtoExtra { get; set; }
|
public string ProtoExtra { get; set; }
|
||||||
|
|
|
||||||
9
v2rayN/ServiceLib/Resx/ResUI.Designer.cs
generated
9
v2rayN/ServiceLib/Resx/ResUI.Designer.cs
generated
|
|
@ -2943,15 +2943,6 @@ namespace ServiceLib.Resx {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// 查找类似 EchForceQuery 的本地化字符串。
|
|
||||||
/// </summary>
|
|
||||||
public static string TbEchForceQuery {
|
|
||||||
get {
|
|
||||||
return ResourceManager.GetString("TbEchForceQuery", resourceCulture);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 查找类似 Edit 的本地化字符串。
|
/// 查找类似 Edit 的本地化字符串。
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
|
||||||
|
|
@ -1581,9 +1581,6 @@ The "Get Certificate" action may fail if a self-signed certificate is used or if
|
||||||
<data name="TbEchConfigList" xml:space="preserve">
|
<data name="TbEchConfigList" xml:space="preserve">
|
||||||
<value>EchConfigList</value>
|
<value>EchConfigList</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="TbEchForceQuery" xml:space="preserve">
|
|
||||||
<value>EchForceQuery</value>
|
|
||||||
</data>
|
|
||||||
<data name="TbFullCertTips" xml:space="preserve">
|
<data name="TbFullCertTips" xml:space="preserve">
|
||||||
<value>Full certificate (chain), PEM format</value>
|
<value>Full certificate (chain), PEM format</value>
|
||||||
</data>
|
</data>
|
||||||
|
|
|
||||||
|
|
@ -1587,9 +1587,6 @@ The "Get Certificate" action may fail if a self-signed certificate is used or if
|
||||||
<data name="TbEchConfigList" xml:space="preserve">
|
<data name="TbEchConfigList" xml:space="preserve">
|
||||||
<value>EchConfigList</value>
|
<value>EchConfigList</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="TbEchForceQuery" xml:space="preserve">
|
|
||||||
<value>EchForceQuery</value>
|
|
||||||
</data>
|
|
||||||
<data name="TbFullCertTips" xml:space="preserve">
|
<data name="TbFullCertTips" xml:space="preserve">
|
||||||
<value>Certificat complet (chaîne), format PEM</value>
|
<value>Certificat complet (chaîne), format PEM</value>
|
||||||
</data>
|
</data>
|
||||||
|
|
|
||||||
|
|
@ -1581,9 +1581,6 @@ The "Get Certificate" action may fail if a self-signed certificate is used or if
|
||||||
<data name="TbEchConfigList" xml:space="preserve">
|
<data name="TbEchConfigList" xml:space="preserve">
|
||||||
<value>EchConfigList</value>
|
<value>EchConfigList</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="TbEchForceQuery" xml:space="preserve">
|
|
||||||
<value>EchForceQuery</value>
|
|
||||||
</data>
|
|
||||||
<data name="TbFullCertTips" xml:space="preserve">
|
<data name="TbFullCertTips" xml:space="preserve">
|
||||||
<value>Full certificate (chain), PEM format</value>
|
<value>Full certificate (chain), PEM format</value>
|
||||||
</data>
|
</data>
|
||||||
|
|
|
||||||
|
|
@ -1590,9 +1590,6 @@ The "Get Certificate" action may fail if a self-signed certificate is used or if
|
||||||
<data name="TbEchConfigList" xml:space="preserve">
|
<data name="TbEchConfigList" xml:space="preserve">
|
||||||
<value>EchConfigList</value>
|
<value>EchConfigList</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="TbEchForceQuery" xml:space="preserve">
|
|
||||||
<value>EchForceQuery</value>
|
|
||||||
</data>
|
|
||||||
<data name="TbFullCertTips" xml:space="preserve">
|
<data name="TbFullCertTips" xml:space="preserve">
|
||||||
<value>Full certificate (chain), PEM format</value>
|
<value>Full certificate (chain), PEM format</value>
|
||||||
</data>
|
</data>
|
||||||
|
|
|
||||||
|
|
@ -1581,9 +1581,6 @@
|
||||||
<data name="TbEchConfigList" xml:space="preserve">
|
<data name="TbEchConfigList" xml:space="preserve">
|
||||||
<value>EchConfigList</value>
|
<value>EchConfigList</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="TbEchForceQuery" xml:space="preserve">
|
|
||||||
<value>EchForceQuery</value>
|
|
||||||
</data>
|
|
||||||
<data name="TbFullCertTips" xml:space="preserve">
|
<data name="TbFullCertTips" xml:space="preserve">
|
||||||
<value>Полный сертификат (цепочка) в формате PEM</value>
|
<value>Полный сертификат (цепочка) в формате PEM</value>
|
||||||
</data>
|
</data>
|
||||||
|
|
|
||||||
|
|
@ -1587,9 +1587,6 @@
|
||||||
<data name="TbEchConfigList" xml:space="preserve">
|
<data name="TbEchConfigList" xml:space="preserve">
|
||||||
<value>EchConfigList</value>
|
<value>EchConfigList</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="TbEchForceQuery" xml:space="preserve">
|
|
||||||
<value>EchForceQuery</value>
|
|
||||||
</data>
|
|
||||||
<data name="TbFullCertTips" xml:space="preserve">
|
<data name="TbFullCertTips" xml:space="preserve">
|
||||||
<value>完整证书(链),PEM 格式</value>
|
<value>完整证书(链),PEM 格式</value>
|
||||||
</data>
|
</data>
|
||||||
|
|
|
||||||
|
|
@ -1578,9 +1578,6 @@
|
||||||
<data name="TbEchConfigList" xml:space="preserve">
|
<data name="TbEchConfigList" xml:space="preserve">
|
||||||
<value>EchConfigList</value>
|
<value>EchConfigList</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="TbEchForceQuery" xml:space="preserve">
|
|
||||||
<value>EchForceQuery</value>
|
|
||||||
</data>
|
|
||||||
<data name="TbFullCertTips" xml:space="preserve">
|
<data name="TbFullCertTips" xml:space="preserve">
|
||||||
<value>完整憑證(鏈),PEM 格式</value>
|
<value>完整憑證(鏈),PEM 格式</value>
|
||||||
</data>
|
</data>
|
||||||
|
|
|
||||||
|
|
@ -383,7 +383,6 @@ public partial class CoreConfigV2rayService
|
||||||
alpn = _node.GetAlpn(),
|
alpn = _node.GetAlpn(),
|
||||||
fingerprint = _node.Fingerprint.IsNullOrEmpty() ? _config.CoreBasicItem.DefFingerprint : _node.Fingerprint,
|
fingerprint = _node.Fingerprint.IsNullOrEmpty() ? _config.CoreBasicItem.DefFingerprint : _node.Fingerprint,
|
||||||
echConfigList = _node.EchConfigList.NullIfEmpty(),
|
echConfigList = _node.EchConfigList.NullIfEmpty(),
|
||||||
echForceQuery = _node.EchForceQuery.NullIfEmpty()
|
|
||||||
};
|
};
|
||||||
if (sni.IsNotEmpty())
|
if (sni.IsNotEmpty())
|
||||||
{
|
{
|
||||||
|
|
@ -393,6 +392,11 @@ public partial class CoreConfigV2rayService
|
||||||
{
|
{
|
||||||
tlsSettings.serverName = Utils.String2List(host)?.First();
|
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);
|
var certs = CertPemManager.ParsePemChain(_node.Cert);
|
||||||
if (certs.Count > 0)
|
if (certs.Count > 0)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -306,7 +306,7 @@
|
||||||
x:Name="txtSecurity5"
|
x:Name="txtSecurity5"
|
||||||
Grid.Row="3"
|
Grid.Row="3"
|
||||||
Grid.Column="1"
|
Grid.Column="1"
|
||||||
Width="200"
|
Width="400"
|
||||||
Margin="{StaticResource Margin4}"
|
Margin="{StaticResource Margin4}"
|
||||||
HorizontalAlignment="Left" />
|
HorizontalAlignment="Left" />
|
||||||
|
|
||||||
|
|
@ -1115,19 +1115,6 @@
|
||||||
Margin="{StaticResource Margin4}"
|
Margin="{StaticResource Margin4}"
|
||||||
HorizontalAlignment="Left" />
|
HorizontalAlignment="Left" />
|
||||||
|
|
||||||
<TextBlock
|
|
||||||
Grid.Row="6"
|
|
||||||
Grid.Column="0"
|
|
||||||
Margin="{StaticResource Margin4}"
|
|
||||||
VerticalAlignment="Center"
|
|
||||||
Text="{x:Static resx:ResUI.TbEchForceQuery}" />
|
|
||||||
<ComboBox
|
|
||||||
x:Name="cmbEchForceQuery"
|
|
||||||
Grid.Row="6"
|
|
||||||
Grid.Column="1"
|
|
||||||
Width="200"
|
|
||||||
Margin="{StaticResource Margin4}" />
|
|
||||||
|
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Grid.Row="7"
|
Grid.Row="7"
|
||||||
Grid.Column="0"
|
Grid.Column="0"
|
||||||
|
|
|
||||||
|
|
@ -39,11 +39,8 @@ public partial class AddServerWindow : WindowBase<AddServerViewModel>
|
||||||
cmbFingerprint2.ItemsSource = Global.Fingerprints;
|
cmbFingerprint2.ItemsSource = Global.Fingerprints;
|
||||||
cmbAllowInsecure.ItemsSource = Global.AllowInsecure;
|
cmbAllowInsecure.ItemsSource = Global.AllowInsecure;
|
||||||
cmbAlpn.ItemsSource = Global.Alpns;
|
cmbAlpn.ItemsSource = Global.Alpns;
|
||||||
cmbEchForceQuery.ItemsSource = Global.EchForceQuerys;
|
|
||||||
|
|
||||||
var lstStreamSecurity = new List<string>();
|
var lstStreamSecurity = new List<string> { string.Empty, Global.StreamSecurity };
|
||||||
lstStreamSecurity.Add(string.Empty);
|
|
||||||
lstStreamSecurity.Add(Global.StreamSecurity);
|
|
||||||
|
|
||||||
switch (profileItem.ConfigType)
|
switch (profileItem.ConfigType)
|
||||||
{
|
{
|
||||||
|
|
@ -246,7 +243,6 @@ public partial class AddServerWindow : WindowBase<AddServerViewModel>
|
||||||
this.Bind(ViewModel, vm => vm.AllowInsecureCertFetch, v => v.togAllowInsecureCertFetch.IsChecked).DisposeWith(disposables);
|
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.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.EchConfigList, v => v.txtEchConfigList.Text).DisposeWith(disposables);
|
||||||
this.Bind(ViewModel, vm => vm.SelectedSource.EchForceQuery, v => v.cmbEchForceQuery.SelectedValue).DisposeWith(disposables);
|
|
||||||
|
|
||||||
//reality
|
//reality
|
||||||
this.Bind(ViewModel, vm => vm.SelectedSource.Sni, v => v.txtSNI2.Text).DisposeWith(disposables);
|
this.Bind(ViewModel, vm => vm.SelectedSource.Sni, v => v.txtSNI2.Text).DisposeWith(disposables);
|
||||||
|
|
|
||||||
|
|
@ -415,7 +415,7 @@
|
||||||
x:Name="txtSecurity5"
|
x:Name="txtSecurity5"
|
||||||
Grid.Row="3"
|
Grid.Row="3"
|
||||||
Grid.Column="1"
|
Grid.Column="1"
|
||||||
Width="200"
|
Width="400"
|
||||||
Margin="{StaticResource Margin4}"
|
Margin="{StaticResource Margin4}"
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
Style="{StaticResource DefTextBox}" />
|
Style="{StaticResource DefTextBox}" />
|
||||||
|
|
@ -1444,21 +1444,6 @@
|
||||||
HorizontalAlignment="Left"
|
HorizontalAlignment="Left"
|
||||||
Style="{StaticResource DefTextBox}" />
|
Style="{StaticResource DefTextBox}" />
|
||||||
|
|
||||||
<TextBlock
|
|
||||||
Grid.Row="6"
|
|
||||||
Grid.Column="0"
|
|
||||||
Margin="{StaticResource Margin4}"
|
|
||||||
VerticalAlignment="Center"
|
|
||||||
Style="{StaticResource ToolbarTextBlock}"
|
|
||||||
Text="{x:Static resx:ResUI.TbEchForceQuery}" />
|
|
||||||
<ComboBox
|
|
||||||
x:Name="cmbEchForceQuery"
|
|
||||||
Grid.Row="6"
|
|
||||||
Grid.Column="1"
|
|
||||||
Width="200"
|
|
||||||
Margin="{StaticResource Margin4}"
|
|
||||||
Style="{StaticResource DefComboBox}" />
|
|
||||||
|
|
||||||
<TextBlock
|
<TextBlock
|
||||||
Grid.Row="7"
|
Grid.Row="7"
|
||||||
Grid.Column="0"
|
Grid.Column="0"
|
||||||
|
|
|
||||||
|
|
@ -38,11 +38,8 @@ public partial class AddServerWindow
|
||||||
cmbFingerprint2.ItemsSource = Global.Fingerprints;
|
cmbFingerprint2.ItemsSource = Global.Fingerprints;
|
||||||
cmbAllowInsecure.ItemsSource = Global.AllowInsecure;
|
cmbAllowInsecure.ItemsSource = Global.AllowInsecure;
|
||||||
cmbAlpn.ItemsSource = Global.Alpns;
|
cmbAlpn.ItemsSource = Global.Alpns;
|
||||||
cmbEchForceQuery.ItemsSource = Global.EchForceQuerys;
|
|
||||||
|
|
||||||
var lstStreamSecurity = new List<string>();
|
var lstStreamSecurity = new List<string> { string.Empty, Global.StreamSecurity };
|
||||||
lstStreamSecurity.Add(string.Empty);
|
|
||||||
lstStreamSecurity.Add(Global.StreamSecurity);
|
|
||||||
|
|
||||||
switch (profileItem.ConfigType)
|
switch (profileItem.ConfigType)
|
||||||
{
|
{
|
||||||
|
|
@ -247,7 +244,6 @@ public partial class AddServerWindow
|
||||||
.BindTo(this, v => v.txtAllowInsecureCertFetchTips.Visibility);
|
.BindTo(this, v => v.txtAllowInsecureCertFetchTips.Visibility);
|
||||||
this.Bind(ViewModel, vm => vm.Cert, v => v.txtCert.Text).DisposeWith(disposables);
|
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.EchConfigList, v => v.txtEchConfigList.Text).DisposeWith(disposables);
|
||||||
this.Bind(ViewModel, vm => vm.SelectedSource.EchForceQuery, v => v.cmbEchForceQuery.Text).DisposeWith(disposables);
|
|
||||||
|
|
||||||
//reality
|
//reality
|
||||||
this.Bind(ViewModel, vm => vm.SelectedSource.Sni, v => v.txtSNI2.Text).DisposeWith(disposables);
|
this.Bind(ViewModel, vm => vm.SelectedSource.Sni, v => v.txtSNI2.Text).DisposeWith(disposables);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue