mirror of
https://github.com/asdlokj1qpi233/subconverter.git
synced 2025-10-26 02:42:25 +00:00
fix: some vless nodes not exported on loon
This commit is contained in:
@@ -37,7 +37,7 @@ RUN set -xe && \
|
||||
cmake -DCMAKE_CXX_STANDARD=11 . && \
|
||||
make install -j $THREADS && \
|
||||
cd .. && \
|
||||
git clone https://github.com/asdlokj1qpi233/subconverter --depth=1 && \
|
||||
git clone https://github.com/ionull/subconverter --depth=1 && \
|
||||
cd subconverter && \
|
||||
[ -n "$SHA" ] && sed -i 's/\(v[0-9]\.[0-9]\.[0-9]\)/\1-'"$SHA"'/' src/version.h;\
|
||||
python3 -m ensurepip && \
|
||||
|
||||
@@ -2260,18 +2260,30 @@ proxyToLoon(std::vector<Proxy> &nodes, const std::string &base_conf,
|
||||
break;
|
||||
case ProxyType::VLESS:
|
||||
if (flow != "xtls-rprx-vision") {
|
||||
continue;
|
||||
if (transproto == "ws") {
|
||||
proxy = "VLESS," + hostname + "," + port + ",\"" + id + "\"" +
|
||||
",path=" + path + ",host=" + host + ",transproto=" + transproto +
|
||||
",udp=" + (udp.get() ? "true" : "false") + ",over-tls=" + (
|
||||
tlssecure ? "true" : "false") + ",sni=" + sni;
|
||||
} else {
|
||||
continue;
|
||||
}
|
||||
} else {
|
||||
proxy = "VLESS," + hostname + "," + port + ",\"" + id + "\",flow=" + flow + ",public-key=\"" + pk +
|
||||
"\",short-id=" + shortId + ",udp=" + (udp.get() ? "true" : "false") + ",over-tls=" + (
|
||||
tlssecure ? "true" : "false") + ",sni=" + sni;
|
||||
}
|
||||
proxy = "VLESS," + hostname + "," + port + ",\"" + id + "\",flow=" + flow + ",public-key=\"" + pk +
|
||||
"\",short-id=" + shortId + ",udp=" + (udp.get() ? "true" : "false") + ",over-tls=" + (
|
||||
tlssecure ? "true" : "false") + ",sni=" + sni;
|
||||
|
||||
switch (hash_(transproto)) {
|
||||
case "tcp"_hash:
|
||||
proxy += ",transport=tcp";
|
||||
break;
|
||||
default:
|
||||
continue;
|
||||
if (transproto != "ws") {
|
||||
continue;
|
||||
} else {
|
||||
break;;
|
||||
}
|
||||
}
|
||||
if (!scv.is_undef())
|
||||
proxy += ",skip-cert-verify=" + std::string(scv.get() ? "true" : "false");
|
||||
|
||||
Reference in New Issue
Block a user