# TLS client authentication can be bypassed due to ticket resumption

TLS session tickets weren't isolated per virtual host in nginx, letting a client authenticated to one vhost resume that session on another and bypass its client-cert auth.

- Payout: $2,162
- Severity: medium
- Program: Internet Bug Bounty
- Found by (vendor credit): Sven Hebrok, Felix Cramer, Tim Storm, Maximilian Radoy, Juraj Somorovsky
- Found by: snhebrok
- Disclosed: 2025-05-27
- CVE: CVE-2025-23419
- Write-up quality: 8/10
- Original: https://hackerone.com/reports/2978267
- Library page: https://bugbountylibrary.com/r/h1%3A2978267
- Tags: area:cloud domain:infra impact:internal-access impact:privesc kind:bounty platform:hackerone sev:medium tech:nginx technique:chained vuln:access-control vuln:auth-bypass vuln:misconfiguration

**Target:** nginx TLS session resumption across name-based virtual hosts (http and stream modules)
**Root cause:** TLS session tickets are not isolated per virtual host sharing the same IP:port, so a ticket issued for one vhost is accepted at another; the wrong key material is also used on the second vhost.
**Steps:**
1. Configure two name-based vhosts A and B on same IP:port, both requiring client cert auth with different configs, TLS 1.3 + OpenSSL, tickets/session cache on default server.
2. Connect to A with a valid client cert, complete handshake, obtain a TLS session ticket.
3. Reconnect to B resuming with that ticket, setting SNI to A's host (or omitting SNI) while sending `Host: B` header.
4. Server resumes the session and serves B despite no authorization for B.
**How found:** Observed that tickets are always resumed across vhosts; noticed that when Host header and SNI diverge nginx returns 421 under client auth, but choosing SNI to match the resumption host (or omitting it) lets the Host header select the second site.
**Exploitation:** Attacker authorized only for vhost A connects to A, harvests a session ticket, then resumes that ticket against vhost B with SNI matching A (or omitted) and Host header for B, gaining access to B without valid client cert for B.
**Escalation:** Privilege escalation: user permitted only on A gains access to B which requires separate client authentication.
**Insight:** When testing TLS client-auth on shared-IP vhosts, try resuming a session ticket from an authorized vhost against a different vhost while controlling SNI vs Host header divergence—SNI/Host mismatch checks can be sidestepped by aligning SNI to the ticket's origin.

