fastapi-guard patch contains bypassable RegEx

CVE Details

Basic Information

Title fastapi-guard patch contains bypassable RegEx
Type cve
Published 2025-07-23T22:11:36.441Z
Modified 2025-07-23T22:11:36.441Z

Product Information

Vendor rennf93
Product fastapi-guard
Version >= 3.0.1, < 3.0.2

CVSS Information

Base Score 7.8 (HIGH)
Attack 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

AI Analysis

AI Description A vulnerability in fastapi-guard version 3.0.1 allows bypassing of regex patterns due to ineffective string length limits, which could lead to security breaches. This issue was fixed in version 3.0.2.
AI Severity High
AI Vendor rennf93
AI Product fastapi-guard
AI Version 3.0.1

Affected Products

  • rennf93 fastapi-guard >= 3.0.1, < 3.0.2

Additional Information

CWE List CWE-20, CWE-185
Source GitHub_M

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