[GH-ISSUE #5404] [Bug]: Need separate client-facing configuration for inbound links/subscriptions #3782

Open
opened 2026-10-31 20:34:55 +07:00 by bsakaguchi · 2 comments
Owner

Originally created by @maralnet20-sudo on GitHub (Jun 17, 2026).
Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/5404

Describe the bug

Hello,

I think there is a problem in the way 3x-ui generates user links and subscription configs.

Currently, when we create an inbound in the panel, the panel shows/generates almost the exact same inbound configuration for users.

But in many real use cases, the admin needs to keep the server-side inbound configuration different from the client-facing configuration.

For example, we may need to change some fields before showing the config to users, such as:

allowInsecure: true / false
TLS-related options
SNI / Host
Path
Flow
Fingerprint
Other client-side options

The problem is that the panel does not provide a separate place to customize what should be displayed or exported to users.

Actual behavior:
The user receives almost the exact same configuration based on the inbound settings.

Expected behavior:
The panel should allow admins to define or override the client-facing config separately from the server-side inbound config.

Why this is important:
Sometimes the inbound must be configured in one way on the server, but the user link/subscription must contain different values to work correctly with reverse proxy, CDN, tunnel, fallback, or custom routing setups.

Please consider adding an option to customize the generated user links/subscription configs separately from the inbound configuration.

Thanks.

How to reproduce the problem

  1. Open the 3x-ui panel.

  2. Create a new inbound.

  3. Configure the inbound with normal server-side settings.

  4. Add a client/user to this inbound.

  5. Open the generated user link or subscription config.

  6. Check the generated config.

  7. The generated user config is almost the same as the inbound configuration.

  8. There is no separate option to change only the user-facing config, for example:

    • allowInsecure
    • SNI
    • Host
    • Path
    • Fingerprint
    • TLS/client-side options

Expected result:
The admin should be able to customize the generated user link/subscription config separately from the inbound settings.

Actual result:
The panel generates and shows the config based directly on the inbound settings.

Expected behavior

No response

Actual behavior

No response

Relevant logs


Screenshots

No response

3x-ui version

3.3.1

Xray-core version

No response

How did you install 3x-ui?

install.sh script

Operating system

22

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

  • I searched existing issues and this bug has not been reported.
  • I am running the latest released version of 3x-ui (or have verified the bug still exists on it).
  • This bug report is written in English.
  • I have redacted any sensitive data (tokens, real domains, client UUIDs).
Originally created by @maralnet20-sudo on GitHub (Jun 17, 2026). Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/5404 ### Describe the bug Hello, I think there is a problem in the way 3x-ui generates user links and subscription configs. Currently, when we create an inbound in the panel, the panel shows/generates almost the exact same inbound configuration for users. But in many real use cases, the admin needs to keep the server-side inbound configuration different from the client-facing configuration. For example, we may need to change some fields before showing the config to users, such as: allowInsecure: true / false TLS-related options SNI / Host Path Flow Fingerprint Other client-side options The problem is that the panel does not provide a separate place to customize what should be displayed or exported to users. Actual behavior: The user receives almost the exact same configuration based on the inbound settings. Expected behavior: The panel should allow admins to define or override the client-facing config separately from the server-side inbound config. Why this is important: Sometimes the inbound must be configured in one way on the server, but the user link/subscription must contain different values to work correctly with reverse proxy, CDN, tunnel, fallback, or custom routing setups. Please consider adding an option to customize the generated user links/subscription configs separately from the inbound configuration. Thanks. ### How to reproduce the problem 1. Open the 3x-ui panel. 2. Create a new inbound. 3. Configure the inbound with normal server-side settings. 4. Add a client/user to this inbound. 5. Open the generated user link or subscription config. 6. Check the generated config. 7. The generated user config is almost the same as the inbound configuration. 8. There is no separate option to change only the user-facing config, for example: * `allowInsecure` * SNI * Host * Path * Fingerprint * TLS/client-side options Expected result: The admin should be able to customize the generated user link/subscription config separately from the inbound settings. Actual result: The panel generates and shows the config based directly on the inbound settings. ### Expected behavior _No response_ ### Actual behavior _No response_ ### Relevant logs ```shell ``` ### Screenshots _No response_ ### 3x-ui version 3.3.1 ### Xray-core version _No response_ ### How did you install 3x-ui? install.sh script ### Operating system 22 ### 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 - [x] I searched [existing issues](../issues?q=is%3Aissue) and this bug has not been reported. - [x] I am running the latest released version of 3x-ui (or have verified the bug still exists on it). - [x] This bug report is written in English. - [x] I have redacted any sensitive data (tokens, real domains, client UUIDs).
Author
Owner

@github-actions[bot] commented on GitHub (Jun 17, 2026):

This is a feature request, not a bug. The panel generates subscription links directly from inbound settings by design. The behavior you describe is expected.

What already exists

The panel has an External Proxy mechanism built into the Stream tab of every inbound. When one or more entries are added there, the subscription and share-link generators produce a separate link per entry instead of a single inbound-derived link. Each entry can independently override the following client-facing fields (confirmed in frontend/src/schemas/protocols/stream/external-proxy.ts and internal/sub/service.go):

Field Effect on generated link
dest + port Client connects to this address/port instead of the server's
forceTls (same / tls / none) Override the security layer
sni Override server-name indication
fingerprint Override uTLS fingerprint
alpn Override ALPN list
pinnedPeerCertSha256 Override cert pin
echConfigList Override ECH config
remark Append a label suffix to the link name

This already covers many CDN/reverse-proxy scenarios where the client address, port, SNI, or cert details differ from the server configuration.

What is not yet supported

The fields you specifically listed that are not yet overridable per external proxy entry are:

  • allowInsecure — no allowInsecure field exists on ExternalProxyEntry (confirmed: ExternalProxyEntrySchema in frontend/src/schemas/protocols/stream/external-proxy.ts)
  • path / host header overrides for WebSocket/HTTPUpgrade/XHTTP transports
  • flow override per entry (currently the client's flow from the inbound is used globally; applyExternalProxyTLSParams in internal/sub/service.go does not read a per-entry flow)

A closely related request covering allowInsecure, flow, and transport-specific parameters was raised in #5196 (closed without a fix).

Summary

The externalProxy feature is the right hook for this use case. The gap is that several client-side parameters — primarily allowInsecure, per-entry flow, and transport-specific host/path overrides — are not yet fields on ExternalProxyEntry. Extending that schema and wiring it through buildExternalProxyURLLinks / applyExternalProxyTLSParams in internal/sub/service.go (and the parallel frontend generator in frontend/src/lib/xray/inbound-link.ts) would be the implementation path. This is accepted as a valid enhancement; scheduling depends on maintainer bandwidth.

This reply was generated automatically; a maintainer may follow up.

<!-- gh-comment-id:4727072195 --> @github-actions[bot] commented on GitHub (Jun 17, 2026): This is a feature request, not a bug. The panel generates subscription links directly from inbound settings by design. The behavior you describe is expected. **What already exists** The panel has an **External Proxy** mechanism built into the Stream tab of every inbound. When one or more entries are added there, the subscription and share-link generators produce a separate link per entry instead of a single inbound-derived link. Each entry can independently override the following client-facing fields (confirmed in `frontend/src/schemas/protocols/stream/external-proxy.ts` and `internal/sub/service.go`): | Field | Effect on generated link | |---|---| | `dest` + `port` | Client connects to this address/port instead of the server's | | `forceTls` (`same` / `tls` / `none`) | Override the security layer | | `sni` | Override server-name indication | | `fingerprint` | Override uTLS fingerprint | | `alpn` | Override ALPN list | | `pinnedPeerCertSha256` | Override cert pin | | `echConfigList` | Override ECH config | | `remark` | Append a label suffix to the link name | This already covers many CDN/reverse-proxy scenarios where the client address, port, SNI, or cert details differ from the server configuration. **What is not yet supported** The fields you specifically listed that are not yet overridable per external proxy entry are: - `allowInsecure` — no `allowInsecure` field exists on `ExternalProxyEntry` (confirmed: `ExternalProxyEntrySchema` in `frontend/src/schemas/protocols/stream/external-proxy.ts`) - `path` / `host` header overrides for WebSocket/HTTPUpgrade/XHTTP transports - `flow` override per entry (currently the client's `flow` from the inbound is used globally; `applyExternalProxyTLSParams` in `internal/sub/service.go` does not read a per-entry `flow`) A closely related request covering `allowInsecure`, `flow`, and transport-specific parameters was raised in #5196 (closed without a fix). **Summary** The `externalProxy` feature is the right hook for this use case. The gap is that several client-side parameters — primarily `allowInsecure`, per-entry `flow`, and transport-specific host/path overrides — are not yet fields on `ExternalProxyEntry`. Extending that schema and wiring it through `buildExternalProxyURLLinks` / `applyExternalProxyTLSParams` in `internal/sub/service.go` (and the parallel frontend generator in `frontend/src/lib/xray/inbound-link.ts`) would be the implementation path. This is accepted as a valid enhancement; scheduling depends on maintainer bandwidth. *This reply was generated automatically; a maintainer may follow up.*
Author
Owner

@maralnet20-sudo commented on GitHub (Jun 17, 2026):

Hi,

I want to clarify the problem with a real example.

This issue is not only about adding a new customization option. The current behavior is causing the generated user configs/subscription links to not work for my users.

For example, in Reality configs, 3x-ui generates a random spiderX value in the exported/generated user config.

When this spiderX value exists in the generated config, my user config does not work.

But when I manually remove spiderX from the generated config, the same config works correctly.

This problem happens in tunnel/proxy setups.

I also tested the same config in direct connection mode, and there was no problem there.

So the issue seems to happen when the panel generates client-facing configs for tunnel/proxy environments, because the exported user config contains values that should not be there, or should be customizable separately from the inbound/server-side config.

Actual result:
The panel generates a user config with a random spiderX value, and the generated config does not work in tunnel/proxy setups.

Expected result:
The generated user config should work correctly, or the admin should be able to customize/remove client-facing fields such as spiderX before users receive the link/subscription.

Because the current generated output can be broken and unusable for users, I believe this should be considered a bug, not only an enhancement.

Could you please reconsider changing the label from enhancement to bug?

Thanks.

<!-- gh-comment-id:4727113918 --> @maralnet20-sudo commented on GitHub (Jun 17, 2026): Hi, I want to clarify the problem with a real example. This issue is not only about adding a new customization option. The current behavior is causing the generated user configs/subscription links to not work for my users. For example, in Reality configs, 3x-ui generates a random `spiderX` value in the exported/generated user config. When this `spiderX` value exists in the generated config, my user config does not work. But when I manually remove `spiderX` from the generated config, the same config works correctly. This problem happens in tunnel/proxy setups. I also tested the same config in direct connection mode, and there was no problem there. So the issue seems to happen when the panel generates client-facing configs for tunnel/proxy environments, because the exported user config contains values that should not be there, or should be customizable separately from the inbound/server-side config. Actual result: The panel generates a user config with a random `spiderX` value, and the generated config does not work in tunnel/proxy setups. Expected result: The generated user config should work correctly, or the admin should be able to customize/remove client-facing fields such as `spiderX` before users receive the link/subscription. Because the current generated output can be broken and unusable for users, I believe this should be considered a bug, not only an enhancement. Could you please reconsider changing the label from `enhancement` to `bug`? Thanks.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
MHSanaei/3x-ui#3782
No description provided.