mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-12-03 21:18:19 +07:00
[GH-ISSUE #6261] [Feature]: Improve HTTP proxy configuration and usage #4250
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#4250
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 @Heshmatkhah on GitHub (Aug 19, 2026).
Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/6261
Is your feature request related to a problem?
Hi,
Thanks for the great work.
It would be useful to manage HTTP Proxy users like other protocols.
I know HTTP Proxy is easier to detect, but in some setups this can be handled through an intermediary server.
Its main advantage is that it requires no special client and can be configured natively on almost any device.
This would make HTTP Proxy management consistent with the other protocols and simplify traffic management.
Describe the solution you'd like
Alternatives you've considered
No response
Concrete use case
No response
Mockups, screenshots, or examples
No response
Which parts of the panel would this affect?
No response
Are you willing to help?
Before submitting
@github-actions[bot] commented on GitHub (Aug 19, 2026):
HTTP and Mixed inbounds are modelled as inbound-level accounts today, not as panel clients, so each of the three points needs new plumbing rather than a flag. Here is what I confirmed in the source, point by point.
1. Per-client credentials
An HTTP/Mixed inbound stores
accounts: [{ user, pass }](frontend/src/schemas/protocols/inbound/http.ts:7, defaults atfrontend/src/lib/xray/inbound-defaults.ts:189), and the schema comment records the intent: "No client tracking (no email/limits) at the Xray settings level". The panel's client layer reads only theclientsarray out of inbound settings (internal/web/service/inbound_settings_clients.go:11), and the client UI and Telegram bot filter these protocols out (frontend/src/pages/clients/ClientFormModal.tsx:42,frontend/src/pages/clients/ClientBulkAddModal.tsx:20,internal/web/service/tgbot/tgbot_inbound.go:157). Several accounts per HTTP inbound are already supported — they are simply not clients.2. Per-user quota and usage tracking
Per-client usage comes from Xray stat names of the form
user>>>{email}>>>traffic>>>uplink|downlink(regex atinternal/xray/api.go:47, aggregation atinternal/xray/api.go:875), and quota/expiry enforcement runs off the resultingclient_trafficsrows (internal/web/service/inbound_disable.go:46). An HTTP/Mixed account has no email, so there is no key to attribute a counter to. Live user add/remove is a no-op as well:buildUserAccount(internal/xray/api.go:533) builds a typed account only for vmess, vless, trojan, shadowsocks, hysteria and wireguard and returnsnilotherwise, andAddUserreturns early on that nil (internal/xray/api.go:668). Inbound-level counters do work for these inbounds, sincestatsInboundUplink/statsInboundDownlinkare on by default (internal/web/service/config.json:52).3. Inclusion in the subscription
The subscription query selects only
vmess,vless,trojan,shadowsocks,hysteria,wireguardandmtproto(internal/sub/service.go:486), andGetLinkreturns an empty string for http/mixed (internal/sub/service.go:621); the Clash builder has no http branch either (internal/sub/clash_service.go:248). This is documented on the client-URL endpoint indocs/content/docs/en/reference/api/clients.mdx.Precedent worth noting. MTProto is not an Xray protocol either, yet it does get per-client credentials, per-client quota/expiry and per-client traffic — through a sidecar whose stats endpoint the panel scrapes and folds into the normal accounting (
internal/web/job/mtproto_job.go:44-78,internal/mtproto/manager.go). So the architecture can carry per-client accounting for a non-Xray-metered protocol, but it took purpose-built metering. For HTTP the same question would have to be answered first: I could not verify from this checkout whether Xray-core emitsuser>>>counters for http/socks inbounds, and on the panel side no email is ever registered for them, so today nothing arrives regardless.What is possible right now as an approximation: one HTTP or Mixed inbound per user, each with its own port, its own single account, and its own Total (GB) and expiry date. Inbound-level quota and expiry are enforced for every protocol —
internal/web/service/inbound_disable.go:14disables any inbound whereup + down >= totalor the expiry time has passed. What cannot be approximated is subscription delivery, since an HTTP proxy has no share-link form in the panel.Related: #4852 covers the display half of this (HTTP/Mixed accounts shown in the Clients window). This issue stays open as an enhancement, since the quota and subscription parts go beyond that request.
This reply was generated automatically; a maintainer may follow up.