CVSS 3.1
9.1 criticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:NCritical (9.1) in oauth2 proxy project oauth2 proxy. EPSS 0.5% estimated probability of exploitation activity in the next 30 days. Fixed in github.com/oauth2-proxy/oauth2-proxy/v7 7.15.2.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:Ngithub.com/oauth2-proxy/oauth2-proxy/v7 (Go): fixed in 7.15.2Explain CVE-2026-40575 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2026-40575?via=ask-ai-copy and https://cve.bz/cve/CVE-2026-40575?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2026-40575 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.
From the NVD's CPE matches.
| Product | Affected |
|---|---|
| oauth2_proxy_project:oauth2_proxy | from 7.5.0 before 7.15.2 |
| Advisory | Ecosystem | Package | Affected | Fixed in |
|---|---|---|---|---|
| GHSA-7x63-xv5r-3p2x | Go | github.com/oauth2-proxy/oauth2-proxy/v7 | >=7.5.0 <7.15.2 | 7.15.2 |
| GO-2026-5236 | Go | github.com/oauth2-proxy/oauth2-proxy | all versions | no fix published |
| GO-2026-5236 | Go | github.com/oauth2-proxy/oauth2-proxy/v7 | >=7.5.0 <7.15.2 | 7.15.2 |
| Distribution | Release | Package | Fixed in | Advisory |
|---|---|---|---|---|
| Red Hat | hummingbird:1 | oauth2-proxy | 0:7.15.4-0.1.hum1 | RHSA-2026:58471 |
| openSUSE | Leap 16.0 | govulncheck-vulndb | 0.0.20260723T184607-160000.1.1 | openSUSE-SU-2026:21483-1 |
From the distributions' data via OSV.dev: Red Hat Security Data © Red Hat, Inc., CC BY 4.0; SUSE security data, CC BY 4.0. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Red Hat · openSUSE.
Red Hat rates this Important.
There's an Important flaw in `oauth2-proxy` software where it trusts a client supplied `X-Forwarded-Uri` request header. This header is used by `oauth2-proxy` to identify the original URI from the incoming request it's currently handling. An attacker which manages to spoof the requests sent to it when it's running behind a reverse-proxy may change this header field to match the routes or the regular expressions configured to have authentication skipped, as a consequence the attacker may manage to have access to protected resources or internal routes without any kind of authentication being required resulting in a high impact for data confidentiality and integrity for the services positioned behind the reverse proxy.
Red Hat Product Security team has rated this vulnerability as having a impact of Important as for a `oauth2-proxy` being considered vulnerable it should be being executed with the following specific configuration options enabled:
1) `--reverse-proxy`
2) `--skip-auth-regex` or `--skip-auth-route`
Additionally to exploit this vulnerability the attacker should be able to change the headers in the request being sent (either via a local proxy or by performing a Man-In-The-Middle attack before) and should have previous knowledge about the routes or patterns of URI which the authentication are being skipped by the `oauth2-proxy` deployment.
This issue can be mitigated by one of the options bellow:
1) Strip any client-provided `X-Forwarded-Uri` header at any layer before it reaches `oauth2-proxy`;
2) Overwrite the `X-Forwarded-Uri` header with the actual request URI before the request reaches `oauth2-proxy`. If you are using NGINX you can use the following example to create your tailored mitigation:
~~~
location /internal-auth/ {
internal; # Ensure external users can't access this path
# Make sure the OAuth2 Proxy knows where the original request came from.
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
# set the value to the actual $request_uri and therefore strip any user provided X-Forwarded-Uri
proxy_set_header X-Forwarded-Uri $request_uri;
proxy_pass http://oauth2-proxy:4180/;
}
~~~
3) Restrict direct client access to OAuth2 Proxy so it can only be reached through a trusted reverse proxy;
4) Remove or narrow --skip-auth-route / --skip-auth-regex rules where possible;
| Product | Package | State | Advisory |
|---|---|---|---|
| Red Hat Hardened Images | oauth2-proxy-main-7.15.4-0.1.hum1 | Fixed 2026-08-22 | RHSA-2026:58471 |
| Red Hat Ceph Storage 9 | rhceph/oauth2-proxy-rhel9 | Affected |
Contains Red Hat Security Data © Red Hat, Inc., licensed under CC BY 4.0. Source: https://access.redhat.com/security/data. Modified: reformatted. Red Hat's page for CVE-2026-40575.
The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits.