mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-12-03 21:18:19 +07:00
[GH-ISSUE #5157] [Bug]: VLESS+XHTTP with vless encryption supports XTLS Vision #3626
Labels
No labels
backlog
bug
clarification needed
documentation
duplicate
enhancement
github_actions
good first issue
invalid
javascript
New Feature
PR welcomed
pull-request
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
MHSanaei/3x-ui#3626
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @maxbranson64-eng on GitHub (Jun 10, 2026).
Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/5157
Describe the bug
When VLEES is combined with XHTTP and vless encryption (vlessenc) it supports flow: "xtls-rprx-vision", but in 3xui flow is not set automatically. Also if you set it manually it remains but vless:// links generated by 3xui lacks flow field
How to reproduce the problem
Expected behavior
No response
Actual behavior
No response
Relevant logs
Screenshots
No response
3x-ui version
3.3.0
Xray-core version
No response
How did you install 3x-ui?
Docker / Docker Compose
Operating system
Debian 13
Which parts of the panel are affected?
No response
Browser (only if it is a UI bug)
No response
Is the panel behind a reverse proxy or CDN?
None
Before submitting
@github-actions[bot] commented on GitHub (Jun 10, 2026):
Thanks for the detailed report. I dug into the source to verify each part.
What the code actually does
Link generation (
sub/subService.go, lines 474–487):The
genVlessLinkfunction only appends theflowparameter whenstreamNetwork == "tcp"andsecurityis"tls"or"reality". For a VLESS+XHTTP inbound withsecurity = "none"(which is the case when using vlessenc/ML-KEM), the code falls into thedefaultbranch, which only writessecurity=noneand never emitsflow— even if the client has it set. This confirms the second part of your report: manually-set flow is silently dropped from the generatedvless://link.UI / flow selector (
frontend/src/lib/xray/protocol-capabilities.ts, lines 42–47):canEnableTlsFlowreturnsfalsefor any network other than"tcp", and also for any security other than"tls"or"reality". XHTTP with no security therefore never shows the flow selector at all.Xray config generation (
web/service/xray.go, lines 162–164):When 3x-ui builds the config it sends to xray-core, it does include
flowfor VLESS clients regardless of transport — no TCP/XHTTP check here. So if you savedflow: "xtls-rprx-vision"on the client record (e.g., via direct API or the JSON editor), xray-core would receive it.Where clarification is needed
The UI/link restrictions mirror the established xray-core constraint: XTLS Vision is designed for raw TCP transport (it operates by detecting TLS records in the TCP stream). XHTTP wraps traffic in HTTP, which works differently. This is why 3x-ui's
inboundCanEnableTlsFlowcomment (web/service/inbound.go:550) explicitly states "XTLS Vision is only valid for VLESS on TCP with tls or reality."However, you're combining it with vlessenc / ML-KEM (VLESS-level post-quantum encryption, not transport TLS), and claim xray-core accepts the combination. This is the part we need to verify:
flow: "xtls-rprx-vision"to the client via e.g. the JSON editor and restarting).flow=xtls-rprx-visionin its outbound actually work end-to-end?x-ui version.If xray-core genuinely accepts this combination without errors, there are two real bugs here:
flowfor XHTTP transport (even when set)Knowing whether xray-core actually supports it will determine the right fix.