FKIE_CVE-2026-23996
Vulnerability from fkie_nvd - Published: 2026-01-21 23:15 - Updated: 2026-02-27 14:52
Severity ?
Summary
FastAPI Api Key provides a backend-agnostic library that provides an API key system. Version 1.1.0 has a timing side-channel vulnerability in verify_key(). The method applied a random delay only on verification failures, allowing an attacker to statistically distinguish valid from invalid API keys by measuring response latencies. With enough repeated requests, an adversary could infer whether a key_id corresponds to a valid key, potentially accelerating brute-force or enumeration attacks. All users relying on verify_key() for API key authentication prior to the fix are affected. Users should upgrade to version 1.1.0 to receive a patch. The patch applies a uniform random delay (min_delay to max_delay) to all responses regardless of outcome, eliminating the timing correlation. Some workarounds are available. Add an application-level fixed delay or random jitter to all authentication responses (success and failure) before the fix is applied and/or use rate limiting to reduce the feasibility of statistical timing attacks.
References
Impacted products
| Vendor | Product | Version | |
|---|---|---|---|
| athroniaeth | fastapi_api_key | * |
{
"configurations": [
{
"nodes": [
{
"cpeMatch": [
{
"criteria": "cpe:2.3:a:athroniaeth:fastapi_api_key:*:*:*:*:*:python:*:*",
"matchCriteriaId": "9E32065D-0671-42EB-8A49-1434ECD4EE54",
"versionEndExcluding": "1.1.0",
"vulnerable": true
}
],
"negate": false,
"operator": "OR"
}
]
}
],
"cveTags": [],
"descriptions": [
{
"lang": "en",
"value": "FastAPI Api Key provides a backend-agnostic library that provides an API key system. Version 1.1.0 has a timing side-channel vulnerability in verify_key(). The method applied a random delay only on verification failures, allowing an attacker to statistically distinguish valid from invalid API keys by measuring response latencies. With enough repeated requests, an adversary could infer whether a key_id corresponds to a valid key, potentially accelerating brute-force or enumeration attacks. All users relying on verify_key() for API key authentication prior to the fix are affected. Users should upgrade to version 1.1.0 to receive a patch. The patch applies a uniform random delay (min_delay to max_delay) to all responses regardless of outcome, eliminating the timing correlation. Some workarounds are available. Add an application-level fixed delay or random jitter to all authentication responses (success and failure) before the fix is applied and/or use rate limiting to reduce the feasibility of statistical timing attacks."
},
{
"lang": "es",
"value": "FastAPI Api Key proporciona una librer\u00eda agn\u00f3stica al backend que proporciona un sistema de claves API. La versi\u00f3n 1.1.0 tiene una vulnerabilidad de canal lateral de temporizaci\u00f3n en verify_key(). El m\u00e9todo aplic\u00f3 un retraso aleatorio solo en fallos de verificaci\u00f3n, permitiendo a un atacante distinguir estad\u00edsticamente las claves API v\u00e1lidas de las inv\u00e1lidas midiendo las latencias de respuesta. Con suficientes solicitudes repetidas, un adversario podr\u00eda inferir si un key_id corresponde a una clave v\u00e1lida, acelerando potencialmente los ataques de fuerza bruta o enumeraci\u00f3n. Todos los usuarios que dependen de verify_key() para la autenticaci\u00f3n de claves API antes de la correcci\u00f3n se ven afectados. Los usuarios deben actualizar a la versi\u00f3n 1.1.0 para recibir un parche. El parche aplica un retraso aleatorio uniforme (min_delay a max_delay) a todas las respuestas independientemente del resultado, eliminando la correlaci\u00f3n de temporizaci\u00f3n. Hay disponibles algunas soluciones alternativas. A\u00f1adir un retraso fijo a nivel de aplicaci\u00f3n o fluctuaci\u00f3n aleatoria a todas las respuestas de autenticaci\u00f3n (\u00e9xito y fallo) antes de que se aplique la correcci\u00f3n y/o usar la limitaci\u00f3n de velocidad para reducir la viabilidad de los ataques de temporizaci\u00f3n estad\u00edsticos."
}
],
"id": "CVE-2026-23996",
"lastModified": "2026-02-27T14:52:40.820",
"metrics": {
"cvssMetricV31": [
{
"cvssData": {
"attackComplexity": "HIGH",
"attackVector": "NETWORK",
"availabilityImpact": "NONE",
"baseScore": 3.7,
"baseSeverity": "LOW",
"confidentialityImpact": "LOW",
"integrityImpact": "NONE",
"privilegesRequired": "NONE",
"scope": "UNCHANGED",
"userInteraction": "NONE",
"vectorString": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:N",
"version": "3.1"
},
"exploitabilityScore": 2.2,
"impactScore": 1.4,
"source": "security-advisories@github.com",
"type": "Secondary"
}
]
},
"published": "2026-01-21T23:15:53.090",
"references": [
{
"source": "security-advisories@github.com",
"tags": [
"Patch"
],
"url": "https://github.com/Athroniaeth/fastapi-api-key/commit/310b2c5c77305f38c63c0b917539a0344071dfd8"
},
{
"source": "security-advisories@github.com",
"tags": [
"Product",
"Release Notes"
],
"url": "https://github.com/Athroniaeth/fastapi-api-key/releases/tag/1.1.0"
},
{
"source": "security-advisories@github.com",
"tags": [
"Mitigation",
"Patch",
"Vendor Advisory"
],
"url": "https://github.com/Athroniaeth/fastapi-api-key/security/advisories/GHSA-95c6-p277-p87g"
}
],
"sourceIdentifier": "security-advisories@github.com",
"vulnStatus": "Analyzed",
"weaknesses": [
{
"description": [
{
"lang": "en",
"value": "CWE-208"
}
],
"source": "security-advisories@github.com",
"type": "Primary"
}
]
}
Loading…
Loading…
Sightings
| Author | Source | Type | Date |
|---|
Nomenclature
- Seen: The vulnerability was mentioned, discussed, or observed by the user.
- Confirmed: The vulnerability has been validated from an analyst's perspective.
- Published Proof of Concept: A public proof of concept is available for this vulnerability.
- Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
- Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
- Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
- Not confirmed: The user expressed doubt about the validity of the vulnerability.
- Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.
Loading…
Loading…