GitHub Advisoryadvisory · Go
GHSA-wvvq-wgcr-9q48 Traefik has a Potential mTLS Bypass via Fragmented TLS ClientHello Causing Pre-SNI Sniff Fallback to Default Non-mTLS TLS Config
HIGH
Official page ↗
- Aliases
- CVE-2026-32305
- Ecosystem
- Go
- Packages
- github.com/traefik/traefik/v3, github.com/traefik/traefik/v2, github.com/traefik/traefik
- Severity
- High
- CVSS vector
- CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:N/SC:H/SI:H/SA:N
- Weaknesses
- CWE-287
- Reviewed
- 2026-03-20
Affected packages
• Go github.com/traefik/traefik/v3: >= 3.7.0-ea.1, < 3.7.0-ea.2 → fixed in 3.7.0-ea.2
• Go github.com/traefik/traefik/v3: < 3.6.11 → fixed in 3.6.11
• Go github.com/traefik/traefik/v2: < 2.11.41 → fixed in 2.11.41
• Go github.com/traefik/traefik: <= 1.7.34 (no fix yet)
Description
Summary
There is a potential vulnerability in Traefik's TLS SNI pre-sniffing logic related to fragmented ClientHello packets.
When a TLS ClientHello is fragmented across multiple records, Traefik's SNI extraction may fail with an EOF and return an empty SNI. The TCP router then falls back to the default TLS configuration, which does not require client certificates by default. This allows an attacker to bypass route-level mTLS enforcement and access services that should require mutual TLS authentication.
Patches
• https://github.com/traefik/traefik/releases/tag/v2.11.41
• https://github.com/traefik/traefik/releases/tag/v3.6.11
• https://github.com/traefik/traefik/releases/tag/v3.7.0-ea.2
For more information
If you have any questions or comments about this advisory, please open an issue.
Original Description
Summary
I found a behavior in Traefik's latest version where fragmented ClientHello packets can cause pre-sniff SNI extraction to not find the sni (EOF during sniff), which makes the TCP router fall back to default routing TLS config.
If the default TLS config does not require client certificates (which is NoClientCert by default), the handshake succeeds without client auth, and the request is later routed to the HTTP Host which should be the protected with client certificate authentication (RequireAndVerifyClientCert tls config).
Details
The vulnerability is caused by a mismatch between where Traefik decides the TLS policy per host and where Go TLS can finally parse the full ClientHello.
1. In router.go, ServeTCP function calls clientHelloInfo.
2. clientHelloInfo peeks only one TLS record length (recLen) and then peeks exactly 5 + recLen bytes.
It runs a temporary TLS parse on those bytes to extract the SNI.
If ClientHello is fragmented, pre-sniff may return empty SNI (With fragmentation, first record can be incomplete for full ClientHello parsing).
4. clientHelloInfo still returns isTLS=true and empty SNI (it thinks there is no sni so it applies the default tls config (Which is by default NoClientCert which is permissive)
5. Real Go TLS handshake succeeds later without requiring the client cert.
6. Request is routed to the host that should have been protected.
Conditions required for impact:
• Route-level TLS options enforce mTLS for a host.
• Default TLS config is weaker (noClientCert, which is the default default).
• Pre-sniff fails to extract SNI (due to fragmented ClientHello).
A workaround for this is to set the default tls config to RequireAndVerifyClientCert (but then you need to explicitly define for each permissive host the NoClientCert TLS config).
A suggestion to fix is to parse the complete ClientHello before tls config decision (handle multi-record fragmentation).
PoC
```python
prerequisites (ubuntu/debian, in rhel/fedora you need to run only the install command (dnf) but with "docker" instead of docker.io and podman will emulate it)
sudo apt update
sudo apt install -y docker.io openssl git python3 python3-venv
sudo usermod -aG docker "$USER"
in debian/ubuntu run newgrp docker to apply the new group to the user
mkdir -p /tmp/traefik-frag-poc/{certs,config/dynamic}
cd /tmp/traefik-frag-poc
CA
openssl genrsa -out certs/ca.key 4096
openssl req -x509 -new -nodes -key certs/ca.key -sha256 -days 3650 \
-subj "/CN=PoC-CA" -out certs/ca.crt
Server cert (whoami.home.arpa)
cat > certs/server.cnf config/traefik.yml config/dynamic/dynamic.yml frag_clienthello.py = 3:
text_cert = str(text_cert, "utf-8")
cert = X509()
cert.parse(text_cert)
if key_path:
text_key = open(key_path, "rb").read()
if sys.version_info[0] >= 3:
text_key = str(text_key, "utf-8")
key = parsePEMKey(text_key, private=True)
return cert, key
def main():
p = argparse.ArgumentParser()
p.add_argument("--connect-host", default="127.0…
Related
Alias · CVE (1)
- CVE-2026-32305 Traefik is an HTTP reverse proxy and load balancer. vulnerability
Weakness · CWE (1)
- CWE-287 Improper Authentication weakness
References
- https://github.com/traefik/traefik/security/advisories/GHSA-wvvq-wgcr-9q48 web
- https://nvd.nist.gov/vuln/detail/CVE-2026-32305 advisory
- https://github.com/traefik/traefik package
- https://github.com/traefik/traefik/releases/tag/v2.11.41 web
- https://github.com/traefik/traefik/releases/tag/v3.6.11 web
- https://github.com/traefik/traefik/releases/tag/v3.7.0-ea.2 web