@@ -1406,8 +1406,10 @@ void explodeClash(Node yamlnode, std::vector<Proxy> &nodes)
14061406 singleproxy[" path" ] >>= path;
14071407 break ;
14081408 }
1409- vlessConstruct (node, group, ps, server, port, uuid, sni, alpn, type, net, mode, host, path, fingerprint, flow, xtls, public_key, short_id, client_fingerprint, udp, tfo, scv, underlying_proxy) ;
1409+ tls = safe_as<std::string>(singleproxy[ " tls " ]) == " true " ? " tls " : " " ;
14101410
1411+ vlessConstruct (node, group, ps, server, port, uuid, sni, alpn, type, net, mode, host, path, fingerprint, flow, xtls, public_key, short_id, client_fingerprint, udp, tfo, scv, underlying_proxy);
1412+ node.TLSSecure = tls == " tls" ;
14111413 // Assign new parameters to node for VLESS
14121414 node.IpVersion = ip_version;
14131415 node.EchEnable = ech_enable;
@@ -2124,7 +2126,7 @@ void explodeAnyTLS(std::string anytls, Proxy &node) {
21242126}
21252127
21262128void explodeStdVLESS (std::string vless, Proxy &node) {
2127- std::string add, port, uuid, sni, alpn, net, type, mode, host, path, fingerprint, remarks, addition, flow, xtls, public_key, short_id;
2129+ std::string add, port, uuid, sni, alpn, net, type, mode, host, path, fingerprint, remarks, addition, flow, xtls, public_key, short_id, security, tls ;
21282130 tribool tfo, scv;
21292131 std::string decoded, userinfo, hostinfo;
21302132 string_array user_parts;
@@ -2185,6 +2187,7 @@ void explodeStdVLESS(std::string vless, Proxy &node) {
21852187 flow = getUrlArg (addition, " flow" );
21862188 xtls = getUrlArg (addition, " xtls" );
21872189 public_key = getUrlArg (addition, " pbk" );
2190+ security = getUrlArg (addition, " security" );
21882191 short_id = getUrlArg (addition, " sid" );
21892192 tfo = tribool (getUrlArg (addition, " tfo" ));
21902193 std::string insecure_val = getUrlArg (addition, " insecure" );
@@ -2224,7 +2227,7 @@ void explodeStdVLESS(std::string vless, Proxy &node) {
22242227
22252228 if (remarks.empty ())
22262229 remarks = add + " :" + port;
2227-
2230+ node. TLSSecure = security == " tls " || security == " reality " ;
22282231 vlessConstruct (node, VLESS_DEFAULT_GROUP, remarks, add, port, uuid, sni, alpn, type, net, mode, host, path, fingerprint, flow, xtls, public_key, short_id, " " , tribool (), tfo, scv, " " );
22292232}
22302233
0 commit comments