mirror of
https://github.com/cedar2025/Xboard.git
synced 2025-01-22 10:38:14 -05:00
fix: 修复vless 使用Tls时sni不下发的问题
This commit is contained in:
parent
3a4efcc1f8
commit
9939f2c2e1
@ -199,8 +199,8 @@ class ClashMeta
|
||||
$tlsSettings = $server['tls_settings'];
|
||||
if (isset($tlsSettings['allowInsecure']) && !empty($tlsSettings['allowInsecure']))
|
||||
$array['skip-cert-verify'] = ($tlsSettings['allowInsecure'] ? true : false);
|
||||
if (isset($tlsSettings['serverName']) && !empty($tlsSettings['serverName']))
|
||||
$array['servername'] = $tlsSettings['serverName'];
|
||||
if (isset($tlsSettings['server_name']) && !empty($tlsSettings['server_name']))
|
||||
$array['servername'] = $tlsSettings['server_name'];
|
||||
}
|
||||
break;
|
||||
case 2: //开启reality
|
||||
|
@ -126,8 +126,8 @@ class General
|
||||
case 1:
|
||||
if ($server['tls_settings']) {
|
||||
$tlsSettings = $server['tls_settings'];
|
||||
if (isset($tlsSettings['serverName']) && !empty($tlsSettings['serverName']))
|
||||
$config['sni'] = $tlsSettings['serverName'];
|
||||
if (isset($tlsSettings['server_name']) && !empty($tlsSettings['server_name']))
|
||||
$config['sni'] = $tlsSettings['server_name'];
|
||||
$config['security'] = "tls";
|
||||
}
|
||||
break;
|
||||
|
@ -114,8 +114,8 @@ class Passwall
|
||||
case 1:
|
||||
if ($server['tls_settings']) {
|
||||
$tlsSettings = $server['tls_settings'];
|
||||
if (isset($tlsSettings['serverName']) && !empty($tlsSettings['serverName']))
|
||||
$config['sni'] = $tlsSettings['serverName'];
|
||||
if (isset($tlsSettings['server_name']) && !empty($tlsSettings['server_name']))
|
||||
$config['sni'] = $tlsSettings['server_name'];
|
||||
$config['security'] = "tls";
|
||||
}
|
||||
break;
|
||||
|
@ -102,8 +102,8 @@ class SSRPlus
|
||||
case 1:
|
||||
if ($server['tls_settings']) {
|
||||
$tlsSettings = $server['tls_settings'];
|
||||
if (isset($tlsSettings['serverName']) && !empty($tlsSettings['serverName']))
|
||||
$config['sni'] = $tlsSettings['serverName'];
|
||||
if (isset($tlsSettings['server_name']) && !empty($tlsSettings['server_name']))
|
||||
$config['sni'] = $tlsSettings['server_name'];
|
||||
$config['security'] = "tls";
|
||||
}
|
||||
break;
|
||||
|
@ -158,8 +158,8 @@ class Shadowrocket
|
||||
$tlsSettings = $server['tls_settings'];
|
||||
if (isset($tlsSettings['allowInsecure']) && !empty($tlsSettings['allowInsecure']))
|
||||
$config['allowInsecure'] = (int)$tlsSettings['allowInsecure'];
|
||||
if (isset($tlsSettings['serverName']) && !empty($tlsSettings['serverName']))
|
||||
$config['peer'] = $tlsSettings['serverName'];
|
||||
if (isset($tlsSettings['server_name']) && !empty($tlsSettings['server_name']))
|
||||
$config['peer'] = $tlsSettings['server_name'];
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
|
@ -130,8 +130,8 @@ class V2rayN
|
||||
case 1:
|
||||
if ($server['tls_settings']) {
|
||||
$tlsSettings = $server['tls_settings'];
|
||||
if (isset($tlsSettings['serverName']) && !empty($tlsSettings['serverName']))
|
||||
$config['sni'] = $tlsSettings['serverName'];
|
||||
if (isset($tlsSettings['server_name']) && !empty($tlsSettings['server_name']))
|
||||
$config['sni'] = $tlsSettings['server_name'];
|
||||
$config['security'] = "tls";
|
||||
}
|
||||
break;
|
||||
|
@ -114,8 +114,8 @@ class V2rayNG
|
||||
case 1:
|
||||
if ($server['tls_settings']) {
|
||||
$tlsSettings = $server['tls_settings'];
|
||||
if (isset($tlsSettings['serverName']) && !empty($tlsSettings['serverName']))
|
||||
$config['sni'] = $tlsSettings['serverName'];
|
||||
if (isset($tlsSettings['server_name']) && !empty($tlsSettings['server_name']))
|
||||
$config['sni'] = $tlsSettings['server_name'];
|
||||
$config['security'] = "tls";
|
||||
}
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user