fastapi-guard is a security library for FastAPI that provides middleware to control IPs, log requests, detect penetration attempts and more. In version 3.0.1, the regular expression patched to mitigate the ReDoS vulnerability by limiting the length of string fails to catch inputs that exceed this limit. This type of patch fails to detect cases in which the string representing the attributes of a <script> tag exceeds 100 characters. As a result, most of the regex patterns present in version 3.0.1 can be bypassed. This is fixed in version 3.0.2.
History

Thu, 09 Oct 2025 16:00:00 +0000

Type Values Removed Values Added
First Time appeared Fastapi-guard
Fastapi-guard fastapi Guard
Weaknesses CWE-1333
CPEs cpe:2.3:a:fastapi-guard:fastapi_guard:3.0.1:*:*:*:*:*:*:*
Vendors & Products Fastapi-guard
Fastapi-guard fastapi Guard
Metrics cvssV3_1

{'score': 7.5, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H'}


Thu, 24 Jul 2025 14:15:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'poc', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Wed, 23 Jul 2025 22:30:00 +0000

Type Values Removed Values Added
Description fastapi-guard is a security library for FastAPI that provides middleware to control IPs, log requests, detect penetration attempts and more. In version 3.0.1, the regular expression patched to mitigate the ReDoS vulnerability by limiting the length of string fails to catch inputs that exceed this limit. This type of patch fails to detect cases in which the string representing the attributes of a <script> tag exceeds 100 characters. As a result, most of the regex patterns present in version 3.0.1 can be bypassed. This is fixed in version 3.0.2.
Title fastapi-guard patch contains bypassable RegEx
Weaknesses CWE-185
CWE-20
References
Metrics cvssV4_0

{'score': 7.8, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:L/VA:H/SC:N/SI:N/SA:N/E:P'}


cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2025-07-24T13:36:52.638Z

Reserved: 2025-07-21T16:12:20.731Z

Link: CVE-2025-54365

cve-icon Vulnrichment

Updated: 2025-07-24T13:13:17.202Z

cve-icon NVD

Status : Analyzed

Published: 2025-07-23T23:15:24.050

Modified: 2025-10-09T15:46:38.457

Link: CVE-2025-54365

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

No data.