mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-09-24 08:12:19 +07:00
fix(sub): bake Host VLESS Route into subscription UUIDs
The Host VLESS Route field was stored and shown in the panel but never applied to any generated subscription (raw, JSON, Clash), so the UUID was emitted unmodified (#5655). Xray reads the route from the UUID's 3rd group (bytes 6-7, net.PortFromBytes) and masks those bytes to zero before authenticating, so a value can be baked into the share/JSON/Clash UUIDs without breaking the user match. A shared applyVlessRoute helper encodes a single 0-65535 value as the 3rd group; empty/invalid/non-UUID input is left unchanged, so legacy data never yields a broken link and no DB migration is needed. The field was wrongly validated as a multi-segment port spec (that form belongs to the separate server-side routing rule). It is now a single value 0-65535, with frontend validation, link-preview parity (genVlessLink/hostToExternalProxyEntry), hint + error translations across all 13 locales, and tests on every path. Closes #5655
This commit is contained in:
@@ -1901,7 +1901,7 @@
|
||||
"nodeGuids": "選擇由此 Host 解析而來的節點。僅為視覺上的指派。",
|
||||
"serverDescription": "顯示於備註下方的選填註記。",
|
||||
"allowInsecure": "略過 TLS 憑證驗證(allowInsecure / skip-cert-verify)。",
|
||||
"vlessRoute": "透過 VLESS 路由的連接埠/範圍,例如 53,443,1000-2000。留空表示無。",
|
||||
"vlessRoute": "嵌入 UUID 的單一 VLESS 路由值(0-65535),例如 443。留空表示無。",
|
||||
"remark": "此 Host 的純文字標籤。僅當入站本身沒有備註時,才作為配置名稱顯示。"
|
||||
},
|
||||
"remarkVars": {
|
||||
@@ -1951,7 +1951,7 @@
|
||||
"update": "更新 Host",
|
||||
"delete": "刪除 Host",
|
||||
"badTag": "無效的標籤",
|
||||
"badVlessRoute": "請使用連接埠/範圍,例如 53,443,1000-2000"
|
||||
"badVlessRoute": "請輸入 0 到 65535 之間的單一數字"
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user