mirror of
https://github.com/lkddi/Xboard.git
synced 2026-04-28 06:47:24 +08:00
fix(clash-meta): support custom SNI configuration for anytls protocol
This commit is contained in:
@@ -472,8 +472,13 @@ class ClashMeta extends AbstractProtocol
|
|||||||
'password' => $password,
|
'password' => $password,
|
||||||
'udp' => true,
|
'udp' => true,
|
||||||
];
|
];
|
||||||
$array['skip-cert-verify'] = (bool) data_get($protocol_settings, 'tls.allow_insecure', false);
|
|
||||||
|
|
||||||
|
if ($serverName = data_get($protocol_settings, 'tls.server_name')) {
|
||||||
|
$array['sni'] = $serverName;
|
||||||
|
}
|
||||||
|
if ($allowInsecure = data_get($protocol_settings, 'tls.allow_insecure')) {
|
||||||
|
$array['skip-cert-verify'] = (bool) $allowInsecure;
|
||||||
|
}
|
||||||
|
|
||||||
return $array;
|
return $array;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user