mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-12-03 21:18:19 +07:00
[PR #6849] [CLOSED] feat(xray): add supervised multi-region Psiphon outbound sidecars #6483
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#6483
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/6849
Author: @rqzbeh
Created: 10/15/2026
Status: ❌ Closed
Base:
main← Head:feat/psiphon-outbound📝 Commits (2)
0e43258feat(xray): add supervised multi-region Psiphon outbound sidecars5b0ea68fix(psiphon): address golangci-lint goimports and noctx findings📊 Changes
51 files changed (+3812 additions, -14 deletions)
View changed files
📝
DockerInit.sh(+19 -0)📝
frontend/public/openapi.json(+468 -0)📝
frontend/src/generated/examples.ts(+28 -0)📝
frontend/src/generated/schemas.ts(+124 -0)📝
frontend/src/generated/types.ts(+30 -0)📝
frontend/src/generated/zod.ts(+36 -0)📝
frontend/src/pages/api-docs/endpoints.ts(+74 -0)📝
frontend/src/pages/xray/XrayPage.tsx(+8 -1)📝
frontend/src/pages/xray/outbounds/OutboundsTab.tsx(+8 -0)➕
frontend/src/pages/xray/overrides/PsiphonModal.css(+38 -0)➕
frontend/src/pages/xray/overrides/PsiphonModal.tsx(+422 -0)📝
frontend/src/pages/xray/overrides/index.ts(+1 -0)📝
frontend/src/schemas/protocols/outbound/index.ts(+1 -0)➕
frontend/src/schemas/protocols/outbound/psiphon.ts(+40 -0)➕
frontend/src/test/psiphon-modal.test.tsx(+21 -0)📝
internal/database/db.go(+1 -0)📝
internal/database/migrate_data.go(+1 -0)📝
internal/database/model/model.go(+14 -0)➕
internal/psiphon/manager.go(+398 -0)➕
internal/psiphon/manager_test.go(+162 -0)...and 31 more files
📄 Description
Summary
Adds multi-region Psiphon outbound support to 3x-ui by supervising standalone
psiphon-tunnel-coreConsoleClientdaemons as isolated loopback SOCKS5 sidecars per country, integrated into Xray outbounds, routing balancers, and panel UI.Why
Unlike NordVPN or Cloudflare WARP which expose static WireGuard endpoints, Psiphon is a multi-hop, highly-obfuscated anti-censorship tunnel (SSH, Meek, Tapdance, TLS, and QUIC). Embedding
psiphon-tunnel-coredirectly in 3x-ui produces Go dependency conflicts due to heavyreplacedirectives. Supervising the standalone ConsoleClient binary as a managed local daemon (similar tointernal/mtproto) enables running isolated egress country instances without dependency conflicts or connection instability.Type of change
Areas affected
How was this tested?
internal/psiphon: port allocation in range 40001-40099, config rendering with protected overrides (EgressRegion,LocalSocksProxyPort,DataRootDirectory), notice parsing, and probe RTT/IP measurement.internal/psiphon/multi_instance_test.go: verified concurrent execution of 3 country instances (US, DE, JP), independent loopback SOCKS port binding, and clean stop.internal/database: verifiedPsiphonInstancemodel migration,allModels/migrationModelscross-database parity.internal/web/service/xray_psiphon_inject_test.go: verified injection of SOCKS outbounds,psiphon-balancercreation (withleastPingstrategy when observatory is active), and UDP/443 bypass for client TCP fallback.internal/web/routes_contract_test.go: verified all/panel/api/psiphon/*endpoints match the API documentation registry.npm run typecheck: clean (0 errors).npm run lint: clean with oxlint.npm run format:check: all files formatted correctly.psiphon-modal.test.tsx: tested modal rendering, controls, and closed state.npm run build: built all three Vite bundles (index.html,login.html,subpage.html) intointernal/web/dist/.make gen: generated OpenAPI spec and Zod schemas.3x-ui-psiphon-testviaDockerfileandDockerInit.sh.psiphon-linux-amd64binary extraction into/app/bin/alongsidexrayandmtg./app/x-ui settingexecution inside container.Credits & Acknowledgments
psiphon-tunnel-coreandConsoleClient.Breaking changes
None
Checklist
go build ./...and the test suite pass locally.npm run lint,npm run typecheck, andnpm run buildpass.🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.