CVE-2023-48228
JSON

7.5high

OAuth2: PKCE can be fully circumvented

Severity
7.5high CVSS:3.1 by GitHub_M
Exploit likelihood
1.54% (higher than 75% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
GitHub_M
Also known as
BIT-AUTHENTIK-2023-48228GHSA-fm34-v8xq-f2c3

Description

authentik is an open-source identity provider. When initialising a oauth2 flow with a `code_challenge` and `code_method` (thus requesting PKCE), the single sign-on provider (authentik) must check if there is a matching and existing `code_verifier` during the token step. Prior to versions 2023.10.4 and 2023.8.5, authentik checks if the contents of `code_verifier` is matching only when it is provided. When it is left out completely, authentik simply accepts the token request with out it; even when the flow was started with a `code_challenge`. authentik 2023.8.5 and 2023.10.4 fix this issue.

Affected

Product or packageVersionsReported by
goauthentik authentik< 2023.10.4, < 2023.8.5, before 2023.8.5, from 2023.10.0 before 2023.10.4CVE List, NVD
authentik (Bitnami)before 2023.8.5, from 2023.10.0 before 2023.10.4Bitnami Vulnerability Database

All scores

GitHub_M7.5high CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
NVD9.8critical CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Bitnami Vulnerability Databasecritical rating

Classification

What each source says

CVE List

authentik is an open-source identity provider. When initialising a oauth2 flow with a `code_challenge` and `code_method` (thus requesting PKCE), the single sign-on provider (authentik) must check if there is a matching and existing `code_verifier` during the token step. Prior to versions 2023.10.4 and 2023.8.5, authentik checks if the contents of `code_verifier` is matching only when it is provided. When it is left out completely, authentik simply accepts the token request with out it; even when the flow was started with a `code_challenge`. authentik 2023.8.5 and 2023.10.4 fix this issue.

NVD (es)

authentik es un proveedor de identidad de código abierto. Al inicializar un flujo oauth2 con un `code_challenge` y un `code_method` (solicitando así PKCE), el proveedor de inicio de sesión único (authentik) debe verificar si hay un `code_verifier` coincidente y existente durante el paso del token. Antes de las versiones 2023.10.4 y 2023.8.5, authentik verifica si el contenido de `code_verifier` coincide solo cuando se proporciona. Cuando se omite por completo, authentik simplemente acepta la solicitud del token sin él; incluso cuando el flujo se inició con un "code_challenge". authentik 2023.8.5 y 2023.10.4 solucionan este problema.

References

https://github.com/goauthentik/authentik/security/advisories/GHSA-fm34-v8xq-f2c3advisory, exploit, vendor-advisory
https://github.com/goauthentik/authentik/pull/7666fix, patch
https://github.com/goauthentik/authentik/pull/7668fix, patch
https://github.com/goauthentik/authentik/pull/7669fix, patch
https://github.com/goauthentik/authentik/commit/3af77ab3821fe9c7df8055ba5eade3d1ecea03a6fix, patch
https://github.com/goauthentik/authentik/commit/6b9afed21f7c39f171a4a445654cfe415bba37d5fix, patch
https://github.com/goauthentik/authentik/commit/b88e39411c12e3f9e04125a7887f12354f760a14fix, patch
https://github.com/goauthentik/authentik/blob/dd4e9030b4e667d3720be2feda24c08972602274/authentik/providers/oauth2/views/token.py#L225product, web
https://github.com/goauthentik/authentik/releases/tag/version%2F2023.10.4article, release-notes
https://github.com/goauthentik/authentik/releases/tag/version%2F2023.8.5article, release-notes
https://nvd.nist.gov/vuln/detail/CVE-2023-48228web

Sources

SourceRecordLicence
CVE ListCVE-2023-48228 changed 2024-08-02CVE Terms of Use
NVDCVE-2023-48228 changed 2026-06-17Public domain
Bitnami Vulnerability DatabaseBIT-AUTHENTIK-2023-48228 changed 2026-09-08Apache-2.0