3x-ui/internal/web
Kirill Rudenko 6ab718f813
fix(sub): make Happ require auth on its local SOCKS/HTTP proxy (#6628)
Happ ships its local SOCKS5 (127.0.0.1:10808) and HTTP inbounds with
authorization disabled by default. Any app on the same device can then
connect to that proxy, bypassing Android's per-app VPN routing, and learn
the VPN server address - the leak publicly described in March-April 2026
for Happ, v2rayNG and other VLESS clients. Happ fixed its Xray API
exposure, but the unauthenticated local proxy remained.

Happ exposes a standard subscription header for this (no Provider ID
required): socks-auth-mode / http-auth-mode = auto|manual|from-json|
disable. A new subscription setting, subHappLocalProxyAuth (default
"auto"), sends both headers to Happ clients. Like every other Happ header
it is emitted only when Happ auto-detect is enabled and the User-Agent is
Happ, so panels that never opted into the Happ integration see no change.
An empty value sends nothing and keeps the client's own setting.

Verified on Happ Android 4.4.1 (Xray 26.7.28): a subscription carrying
socks-auth-mode manual + a test user/password switched the client's
Inbounds screen to Manual with those credentials on "refresh subscription",
and "auto" switched it to Auto with generated credentials.

Co-authored-by: Kirill Rudenko <rudenko@npp-energy.ru>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Sanaei <ho3ein.sanaei@gmail.com>
2026-09-26 22:03:20 +02:00
..
controller fix(sub): never use X-Real-IP as the subscription host (#6608) 2026-09-26 21:13:46 +02:00
entity fix(sub): make Happ require auth on its local SOCKS/HTTP proxy (#6628) 2026-09-26 22:03:20 +02:00
global refactor: focused service files, leaf subpackages, and an internal/ layout (#5167) 2026-06-10 15:19:22 +02:00
job fix(ip-limit): CAS-retry inbound_client_ips merges under Postgres (#6612) 2026-09-26 22:00:40 +02:00
locale feat(discord): add Discord notification bot service (#6486) 2026-09-13 14:04:53 +02:00
middleware fix(web): tighten database restore body-cap exemption (#5609) 2026-06-28 15:00:55 +02:00
network style: format struct literals and whitespace 2026-08-24 00:06:01 +02:00
runtime fix(node): release a deleted node's metric series and HTTP client 2026-09-15 20:39:32 +02:00
service fix(sub): make Happ require auth on its local SOCKS/HTTP proxy (#6628) 2026-09-26 22:03:20 +02:00
session refactor: focused service files, leaf subpackages, and an internal/ layout (#5167) 2026-06-10 15:19:22 +02:00
translation fix(sub): make Happ require auth on its local SOCKS/HTTP proxy (#6628) 2026-09-26 22:03:20 +02:00
websocket fix(nodes): keep the credential-presence flag on the node heartbeat push 2026-07-28 17:38:46 +02:00
cadence_test.go Add remote routing URL support (#6168) 2026-08-18 16:02:11 +02:00
routes_contract_test.go feat(panel): add sponsor slots fed from sponsors.sanaei.dev 2026-09-26 03:31:51 +02:00
web.go fix(nodes): say which half of node mTLS failed, and say it as an error (#6565) 2026-09-16 12:30:44 +02:00
web_mtls.go feat(node): node hardening — mTLS, hashed+zstd reconcile transport, per-node net metrics (#5382) 2026-06-16 12:19:33 +02:00
web_mtls_test.go feat(node): node hardening — mTLS, hashed+zstd reconcile transport, per-node net metrics (#5382) 2026-06-16 12:19:33 +02:00