mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-12-03 21:18:19 +07:00
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#5964
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?
📋 Pull Request Information
Original PR: https://github.com/MHSanaei/3x-ui/pull/5698
Author: @FZ1010
Created: 6/30/2026
Status: ✅ Merged
Merged: 8/15/2026
Merged by: @MHSanaei
Base:
main← Head:feat/inbound-disable-flow📝 Commits (10+)
6f90191feat(inbound): add DisableFlow to opt an inbound out of auto XTLS Vision605e8a9feat(inbound): DisableFlow toggle in the inbound form (frontend)a38a1bbfix(inbound): honor DisableFlow in all emitters + on toggle; regen OpenAPIc3a07f6fix(inbound): make DisableFlow durable, clamp on create, guard live confige16acf4style(inbound): drop // line comments per repo CLAUDE.md0a66cb2Merge remote-tracking branch 'origin/main' into feat/inbound-disable-flow74d30b4Merge remote-tracking branch 'origin/main' into feat/inbound-disable-flow04d0807Merge branch 'main' into feat/inbound-disable-flowde08a2eMerge branch 'main' into feat/inbound-disable-flow897059bMerge branch 'main' into feat/inbound-disable-flow📊 Changes
41 files changed (+428 additions, -10 deletions)
View changed files
📝
frontend/public/openapi.json(+6 -0)📝
frontend/src/generated/examples.ts(+1 -0)📝
frontend/src/generated/schemas.ts(+5 -0)📝
frontend/src/generated/types.ts(+1 -0)📝
frontend/src/generated/zod.ts(+1 -0)📝
frontend/src/lib/xray/inbound-form-adapter.ts(+4 -0)📝
frontend/src/models/dbinbound.ts(+3 -0)📝
frontend/src/pages/inbounds/form/InboundFormModal.tsx(+13 -0)📝
frontend/src/schemas/forms/inbound-form.ts(+1 -0)📝
frontend/src/test/inbound-form-adapter.test.ts(+30 -0)📝
internal/database/model/model.go(+2 -0)📝
internal/sub/clash_service.go(+1 -1)📝
internal/sub/clash_service_test.go(+25 -0)📝
internal/sub/json_service.go(+1 -1)📝
internal/sub/json_service_test.go(+10 -0)📝
internal/sub/service.go(+2 -2)📝
internal/sub/service_flow_test.go(+10 -0)📝
internal/web/runtime/remote.go(+1 -0)📝
internal/web/runtime/remote_test.go(+11 -0)📝
internal/web/service/client_bulk.go(+2 -1)...and 21 more files
📄 Description
Closes #5689.
Problem
A VLESS client attached to multiple inbounds carries a single client-level
flow. The panel clamps that flow onto every flow-capable inbound the client is on, so you cannot keepxtls-rprx-visionon a Reality inbound while turning it off on a tunneled XHTTP + VLESS-encryption inbound for the same client. Vision over a CDN/tunneled transport is frequently undesirable, but today it is all-or-nothing.Approach — per-inbound
DisableFlowAn inbound flagged
DisableFlownever advertises or expects XTLS flow, regardless of the client's flow on its other inbounds.Backend
model.Inbound.DisableFlow— additive column (AutoMigrate;default:false, so no behavior change on upgrade).AddInbound/UpdateInbound: when set, strip each client's flow from the stored settings (and the parsed clients fed toSyncInbound) so the live Xray config never expects Vision.GetXrayConfig: forceflow=""forDisableFlowinbounds (VLESS + Trojan) — authoritative on the read side too, so a strayflow_overridecannot cause a server/client handshake mismatch.genTrojanLinksuppress the flow for such inbounds, keeping Xray and the subscription in agreement.MigrationRestoreVisionFlowskipsDisableFlowinbounds, so the boot/edit Vision-restore pass never re-injects the flow.Frontend
DBInboundmodel, the form schema, and the adapter in both directions); cleared automatically when the protocol is changed away from VLESS.disableFlow/disableFlowHelpadded to all 13 locale files.Tests
stripClientFlowstable-driven unit cases.AddInboundclamps flow on a disabled inbound;UpdateInboundpersistsDisableFlow+ strips flow + the result survivesMigrationRestoreVisionFlow(a regression test that fails without the persist fix).DBInbound+ adapter round-trip (fails without the model field).make verify— ✅verify: OKRan the full CI-mirroring gate locally (CGO sqlite via MinGW; golangci-lint built for go 1.26.4):
gen-checklint(golangci-lint + eslint)typecheck(tsc --noEmit)test—go test -shuffle=on ./...test— frontend vitestbuild(Vite bundles +go build ./...)No
//line comments in committed Go/TS, per the repo guidelines.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.