{"cve":"CVE-2026-23996","nvd":{"published":"2026-01-21T23:15:53.090","modified":"2026-06-17T10:22:26.950","status":"Analyzed","description":"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.","cvss_v4":null,"cvss_v3":{"version":"3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:N","score":3.7},"cwes":["CWE-208"],"references":["https://github.com/Athroniaeth/fastapi-api-key/commit/310b2c5c77305f38c63c0b917539a0344071dfd8","https://github.com/Athroniaeth/fastapi-api-key/releases/tag/1.1.0","https://github.com/Athroniaeth/fastapi-api-key/security/advisories/GHSA-95c6-p277-p87g"],"products":["athroniaeth:fastapi_api_key"],"source":"nvd","synced_at":"2026-10-19T22:21:16.563232421+00:00"},"epss":{"cve":"CVE-2026-23996","score":0.00291,"percentile":0.2175,"date":"2026-11-01"},"kev":null,"osv":[{"id":"GHSA-95c6-p277-p87g","url":"https://osv.dev/vulnerability/GHSA-95c6-p277-p87g","summary":"FastAPI Api Key has a timing side-channel in verify_key that allows statistical key validity detection","modified":"2026-07-07T17:57:38.313530202Z","packages":[{"ecosystem":"PyPI","name":"fastapi-api-key","purl":"pkg:pypi/fastapi-api-key","ranges":["<1.1.0"],"fixed":["1.1.0"]}]},{"id":"PYSEC-2026-1358","url":"https://osv.dev/vulnerability/PYSEC-2026-1358","summary":"FastAPI Api Key has a timing side-channel in verify_key that allows statistical key validity detection","modified":"2026-07-07T17:47:35.926091029Z","packages":[{"ecosystem":"PyPI","name":"fastapi-api-key","purl":"pkg:pypi/fastapi-api-key","ranges":["<1.1.0"],"fixed":["1.1.0"]}]}],"attribution":["This product uses the NVD API but is not endorsed or certified by the NVD.","EPSS scores: FIRST Exploit Prediction Scoring System, https://www.first.org/epss","Known exploited vulnerabilities: CISA Known Exploited Vulnerabilities Catalog, https://www.cisa.gov/known-exploited-vulnerabilities-catalog","Package advisories: OSV (https://osv.dev), from the GitHub Advisory Database, PyPA, Go, RustSec and other ecosystem databases, under CC-BY 4.0 or CC0","CVE records: the CVE Program's CVE List (https://www.cve.org), under its terms of use (https://www.cve.org/Legal/TermsOfUse). CVE is a registered trademark of The MITRE Corporation; this product is not affiliated with the CVE Program."]}