mirror of
https://github.com/asdlokj1qpi233/subconverter.git
synced 2026-11-01 17:25:02 +00:00
Use Host as SNI field if exists in Surge configs (#674)
This commit is contained in:
1 parent
05a542c4f1
commit
fdf983bc1b
1 file changed
+4
-1
@@ -722,7 +722,10 @@ std::string proxyToSurge(std::vector<Proxy> &nodes, const std::string &base_conf
|
||||
case "tcp"_hash:
|
||||
break;
|
||||
case "ws"_hash:
|
||||
proxy += ", ws=true, ws-path=" + path + ", sni=" + hostname;
|
||||
if(host.empty())
|
||||
proxy += ", ws=true, ws-path=" + path + ", sni=" + hostname;
|
||||
else
|
||||
proxy += ", ws=true, ws-path=" + path + ", sni=" + host;
|
||||
if(!host.empty())
|
||||
headers.push_back("Host:" + host);
|
||||
if(!edge.empty())
|
||||
|
||||
Reference in new issue
Block a user