mirror of https://github.com/2dust/v2rayN
bug fix for test shadowsocks
parent
ff91a5dad9
commit
d7c1516ec2
|
@ -158,6 +158,7 @@ namespace v2rayN
|
|||
public static readonly List<string> SsSecuritys = new() { "aes-256-gcm", "aes-128-gcm", "chacha20-poly1305", "chacha20-ietf-poly1305", "none", "plain" };
|
||||
public static readonly List<string> SsSecuritysInSagerNet = new() { "none", "2022-blake3-aes-128-gcm", "2022-blake3-aes-256-gcm", "2022-blake3-chacha20-poly1305", "aes-128-gcm", "aes-192-gcm", "aes-256-gcm", "chacha20-ietf-poly1305", "xchacha20-ietf-poly1305", "rc4", "rc4-md5", "aes-128-ctr", "aes-192-ctr", "aes-256-ctr", "aes-128-cfb", "aes-192-cfb", "aes-256-cfb", "aes-128-cfb8", "aes-192-cfb8", "aes-256-cfb8", "aes-128-ofb", "aes-192-ofb", "aes-256-ofb", "bf-cfb", "cast5-cfb", "des-cfb", "idea-cfb", "rc2-cfb", "seed-cfb", "camellia-128-cfb", "camellia-192-cfb", "camellia-256-cfb", "camellia-128-cfb8", "camellia-192-cfb8", "camellia-256-cfb8", "salsa20", "chacha20", "chacha20-ietf", "xchacha20" };
|
||||
public static readonly List<string> SsSecuritysInXray = new() { "aes-256-gcm", "aes-128-gcm", "chacha20-poly1305", "chacha20-ietf-poly1305", "xchacha20-poly1305", "xchacha20-ietf-poly1305", "none", "plain", "2022-blake3-aes-128-gcm", "2022-blake3-aes-256-gcm", "2022-blake3-chacha20-poly1305" };
|
||||
public static readonly List<string> SsSecuritysInSingbox = new() { "aes-256-gcm", "aes-192-gcm", "aes-128-gcm", "chacha20-ietf-poly1305", "xchacha20-ietf-poly1305", "none", "2022-blake3-aes-128-gcm", "2022-blake3-aes-256-gcm", "2022-blake3-chacha20-poly1305", "aes-128-ctr", "aes-192-ctr", "aes-256-ctr", "aes-128-cfb", "aes-192-cfb", "aes-256-cfb", "rc4-md5", "chacha20-ietf", "xchacha20" };
|
||||
public static readonly List<string> Flows = new() { "", "xtls-rprx-vision", "xtls-rprx-vision-udp443" };
|
||||
public static readonly List<string> Networks = new() { "tcp", "kcp", "ws", "h2", "quic", "grpc" };
|
||||
public static readonly List<string> KcpHeaderTypes = new() { "srtp", "utp", "wechat-video", "dtls", "wireguard" };
|
||||
|
@ -172,7 +173,7 @@ namespace v2rayN
|
|||
public static readonly List<string> AllowInsecures = new() { "true", "false", "" };
|
||||
public static readonly List<string> DomainStrategy4Freedoms = new() { "AsIs", "UseIP", "UseIPv4", "UseIPv6", "" };
|
||||
public static readonly List<string> Languages = new() { "zh-Hans", "zh-Hant", "en", "fa-Ir", "ru" };
|
||||
public static readonly List<string> Alpns = new() { "h3", "h2", "http/1.1", "h3,h2,http/1.1", "h3,h2", "h2,http/1.1", "" };
|
||||
public static readonly List<string> Alpns = new() { "h3", "h2", "http/1.1", "h3,h2,http/1.1", "h3,h2", "h2,http/1.1", "" };
|
||||
public static readonly List<string> LogLevels = new() { "debug", "info", "warning", "error", "none" };
|
||||
public static readonly List<string> InboundTags = new() { "socks", "http", "socks2", "http2" };
|
||||
public static readonly List<string> RuleProtocols = new() { "http", "tls", "bittorrent" };
|
||||
|
|
|
@ -931,7 +931,7 @@ namespace v2rayN.Handler
|
|||
continue;
|
||||
}
|
||||
if (item.configType == EConfigType.Shadowsocks
|
||||
&& !Global.SsSecuritysInXray.Contains(item.security))
|
||||
&& !Global.SsSecuritysInSingbox.Contains(item.security))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
|
|
@ -164,15 +164,18 @@ namespace v2rayN.Handler
|
|||
|
||||
public List<string> GetShadowsocksSecuritys(ProfileItem profileItem)
|
||||
{
|
||||
if (GetCoreType(profileItem, EConfigType.Shadowsocks) == ECoreType.v2fly)
|
||||
var coreType = GetCoreType(profileItem, EConfigType.Shadowsocks);
|
||||
switch (coreType)
|
||||
{
|
||||
return Global.SsSecuritys;
|
||||
}
|
||||
if (GetCoreType(profileItem, EConfigType.Shadowsocks) == ECoreType.Xray)
|
||||
{
|
||||
return Global.SsSecuritysInXray;
|
||||
}
|
||||
case ECoreType.v2fly:
|
||||
return Global.SsSecuritys;
|
||||
|
||||
case ECoreType.Xray:
|
||||
return Global.SsSecuritysInXray;
|
||||
|
||||
case ECoreType.sing_box:
|
||||
return Global.SsSecuritysInSingbox;
|
||||
}
|
||||
return Global.SsSecuritysInSagerNet;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue