Skip to content

feat(subscription): add alpn, ech and fp fallback to VLESS TLS subscription links#914

Open
KissSkyOneMoreTime wants to merge 3 commits into
cedar2025:masterfrom
KissSkyOneMoreTime:feat/vless-subscription-alpn-ech-fp
Open

feat(subscription): add alpn, ech and fp fallback to VLESS TLS subscription links#914
KissSkyOneMoreTime wants to merge 3 commits into
cedar2025:masterfrom
KissSkyOneMoreTime:feat/vless-subscription-alpn-ech-fp

Conversation

@KissSkyOneMoreTime
Copy link
Copy Markdown

Problem

When a VLESS node uses TLS with ECH and custom ALPN values, these settings are
stored in protocol_settings but are never included in the generated
subscription link. Users must manually add fp, alpn, and ech parameters
in their client after importing.

Root Cause

General::buildVless() TLS case 1 handles fp via getTlsFingerprint() but
returns null when the uTLS toggle is disabled. There is no fallback to read
fingerprint from network_settings.extra.downloadSettings.tlsSettings.
Similarly, alpn and ech stored in the same path are never read.

Changes

In app/Protocols/General.php, buildVless(), TLS case 1:

  • fp: add elseif fallback to read fingerprint from
    network_settings.extra.downloadSettings.tlsSettings.fingerprint when uTLS
    toggle is disabled
  • alpn: read from
    network_settings.extra.downloadSettings.tlsSettings.alpn and serialize as
    comma-separated string
  • ech: read from tls_settings.ech; when enabled, use the raw base64
    config as echConfigList, falling back to query_server_name for DoH
    lookup

Testing

Tested with VLESS + XHTTP + TLS + Cloudflare CDN node with ECH enabled.
Before: generated link contains no alpn, ech, or fp parameter.
After: all three parameters are present and the node connects without any
manual client configuration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant