Security mailing lists by PureSourceCode

CVE-2021-21291

MEDIUM 6.1CVSS 3.1

Subdomain checking of whitelisted domains could allow unintended redirects in oauth2-proxy

OAuth2 Proxy is an open-source reverse proxy and static file server that provides authentication using Providers (Google, GitHub, and others) to validate accounts by email, domain or group. In OAuth2 Proxy before version 7.0.0, for users that use the whitelist domain feature, a domain that ended in a similar way to the intended domain could have been allowed as a redirect. For example, if a whitelist domain was configured for ".example.com", the intention is that subdomains of example.com are allowed. Instead, "example.com" and "badexample.com" could also match. This is fixed in version 7.0.0 onwards. As a workaround, one can disable the whitelist domain feature and run separate OAuth2 Proxy instances for each subdomain.

Published
2 Feb 2021
Last modified
10 Sep 2026
Assigned by
security-advisories@github.com
NVD status
Modified
Weakness
CWE-601
Also known as
BIT-oauth2-proxy-2021-21291GHSA-4mf2-f3wh-gvf2GO-2022-0790
Sources
NVDJSONOSV GHSA-4mf2-f3wh-gvf2JSONOSV GO-2022-0790JSON

Scores

SourceScored byVersionScoreVector / decision
NVD nvd@nist.gov (Primary) CVSS 3.1 MEDIUM 6.1 CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
OSV GitHub CVSS 3.1 MEDIUM 5.4 CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N
NVD security-advisories@github.com (Secondary) CVSS 3.1 MEDIUM 4.7 CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:N
NVD nvd@nist.gov (Primary) CVSS 2.0 MEDIUM 5.8 AV:N/AC:M/Au:N/C:P/I:P/A:N

Affected

SourceVendor / ecosystemProduct / packageAffected versionsFixed in
NVD oauth2_proxy_project oauth2_proxy
cpe:2.3:a:oauth2_proxy_project:oauth2_proxy:*:*:*:*:*:*:*:*
< 7.0.0 7.0.0
OSV Go github.com/oauth2-proxy/oauth2-proxy/v7 < 7.0.0 7.0.0
OSV Go github.com/oauth2-proxy/oauth2-proxy <= 3.2.0
OSV Go github.com/oauth2-proxy/oauth2-proxy all versions

References

History

  • 25 Nov 2026 20:32 UTC · NVD: first stored (published 2 Feb 2021)
  • 25 Nov 2026 20:14 UTC · OSV: first stored (published 21 Aug 2024)
  • 25 Nov 2026 20:13 UTC · OSV: first stored (published 25 May 2021)
An unhandled error has occurred. Reload ×

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.