mirror of
https://git.mirrors.martin98.com/https://github.com/sub-store-org/Sub-Store.git
synced 2025-08-03 05:50:35 +08:00
feat: 兼容不规范的 VLESS URI
This commit is contained in:
parent
88e52f9787
commit
9bb06bf438
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "sub-store",
|
"name": "sub-store",
|
||||||
"version": "2.14.177",
|
"version": "2.14.178",
|
||||||
"description": "Advanced Subscription Manager for QX, Loon, Surge, Stash and ShadowRocket.",
|
"description": "Advanced Subscription Manager for QX, Loon, Surge, Stash and ShadowRocket.",
|
||||||
"main": "src/main.js",
|
"main": "src/main.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
@ -409,8 +409,10 @@ function URI_VLESS() {
|
|||||||
proxy[`${params.security}-opts`] = opts;
|
proxy[`${params.security}-opts`] = opts;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
proxy.network = params.type;
|
proxy.network = params.type;
|
||||||
|
if (proxy.network === 'tcp' && params.headerType === 'http') {
|
||||||
|
proxy.network = 'http';
|
||||||
|
}
|
||||||
if (!proxy.network && isShadowrocket && params.obfs) {
|
if (!proxy.network && isShadowrocket && params.obfs) {
|
||||||
proxy.network = params.obfs;
|
proxy.network = params.obfs;
|
||||||
}
|
}
|
||||||
@ -915,7 +917,8 @@ function Surge_External() {
|
|||||||
line,
|
line,
|
||||||
)?.[2];
|
)?.[2];
|
||||||
}
|
}
|
||||||
|
// args = "-m", args = "rc4-md5"
|
||||||
|
// args = -m, args = rc4-md5
|
||||||
const argsRegex = /(,|^)\s*?args\s*?=\s*("(.*?)"|(.*?))(?=\s*?(,|$))/g;
|
const argsRegex = /(,|^)\s*?args\s*?=\s*("(.*?)"|(.*?))(?=\s*?(,|$))/g;
|
||||||
let argsMatch;
|
let argsMatch;
|
||||||
const args = [];
|
const args = [];
|
||||||
@ -926,6 +929,8 @@ function Surge_External() {
|
|||||||
args.push(argsMatch[4]);
|
args.push(argsMatch[4]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// addresses = "[ipv6]",,addresses = "ipv6", addresses = "ipv4"
|
||||||
|
// addresses = [ipv6], addresses = ipv6, addresses = ipv4
|
||||||
const addressesRegex =
|
const addressesRegex =
|
||||||
/(,|^)\s*?addresses\s*?=\s*("(.*?)"|(.*?))(?=\s*?(,|$))/g;
|
/(,|^)\s*?addresses\s*?=\s*("(.*?)"|(.*?))(?=\s*?(,|$))/g;
|
||||||
let addressesMatch;
|
let addressesMatch;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user