ReDoS in fastapi-guard's penetration attempts detector
FastAPI Guard is a security library for FastAPI that provides middleware to control IPs, log requests, and detect penetration attempts. fastapi-guard's penetration attempts detection uses regex to scan incoming requests. However, some of the regex patterns used in detection are extremely inefficient and can cause polynomial complexity backtracks when handling specially crafted inputs. This vulnerability is fixed in 3.0.1.
- Products
- Not specified
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2025-53539
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 3 Nov 2026, 18:42 UTC · Revision 1
Source evidence
ReDoS in fastapi-guard's penetration attempts detector
core-osv · Original sourcePublished 7 Jul 2025, 19:16 UTC
FastAPI Guard is a security library for FastAPI that provides middleware to control IPs, log requests, and detect penetration attempts. fastapi-guard's penetration attempts detection uses regex to scan incoming requests. However, some of the regex patterns used in detection are extremely inefficient and can cause polynomial complexity backtracks when handling specially crafted inputs. This vulnerability is fixed in 3.0.1.
osv:CVE-2025-53539
Complete source record
{
"id": "ed797e8568c9d465452437db9c551f045b5a602e8451228edea235920c279241",
"url": "https://osv.dev/vulnerability/CVE-2025-53539",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "ReDoS in fastapi-guard's penetration attempts detector",
"summary": "FastAPI Guard is a security library for FastAPI that provides middleware to control IPs, log requests, and detect penetration attempts. fastapi-guard's penetration attempts detection uses regex to scan incoming requests. However, some of the regex patterns used in detection are extremely inefficient and can cause polynomial complexity backtracks when handling specially crafted inputs. This vulnerability is fixed in 3.0.1.",
"evidence": "osv:CVE-2025-53539",
"products": [],
"severity": "medium",
"structured": {
"id": "CVE-2025-53539",
"aliases": [
"CVE-2025-53539",
"GHSA-j47q-rc62-w448",
"PYSEC-2026-1359"
],
"metrics": [
{
"type": "CVSS_V4",
"score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N"
}
],
"affected": [
{
"ranges": [
{
"repo": "https://github.com/Guard-Core/fastapi-guard",
"type": "GIT",
"events": [
{
"introduced": "0"
},
{
"fixed": "783c8fafd1dd4fb2f30c7f1a296a386b1dee638b"
}
],
"database_specific": {
"extracted_events": [
{
"range": [
{
"introduced": "0"
},
{
"fixed": "3.0.1"
}
],
"source": "AFFECTED_FIELD",
"strategy": "StringRangeExpression"
},
{
"range": [
{
"fixed": "d9d50e8130b7b434cdc1b001b8cfd03a06729f7f"
}
],
"source": "REFERENCES_COMMIT"
}
]
}
}
],
"versions": [
"3.0.0",
"2.1.3",
"2.1.2",
"2.1.1",
"2.1.0",
"2.0.1",
"2.0.0",
"1.5.0",
"1.4.0",
"1.3.2",
"1.2.2",
"1.2.1",
"1.2.0",
"1.1.0",
"1.0.0",
"0.4.0",
"0.3.4",
"0.3.3",
"0.3.2",
"0.3.1",
"0.3.0",
"0.2.0",
"v0.1.0"
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-53539.json"
}
}
],
"modified": "2026-10-28T02:30:31.377393684Z",
"provider": "osv",
"references": [
"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/53xxx/CVE-2025-53539.json",
"https://github.com/rennf93/fastapi-guard/security/advisories/GHSA-j47q-rc62-w448",
"https://nvd.nist.gov/vuln/detail/CVE-2025-53539",
"https://github.com/rennf93/fastapi-guard/commit/d9d50e8130b7b434cdc1b001b8cfd03a06729f7f"
],
"provider_metadata": {
"cwe_ids": [
"CWE-1333"
],
"cna_assigner": "GitHub_M",
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/53xxx/CVE-2025-53539.json"
}
},
"related_cves": [
{
"value": "CVE-2025-53539",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 498524,
"published_at": "2025-07-07T19:16:02.559+00:00"
}