# CVE-2025-46814: FastAPI Guard Remote Header Injection via X-Forwarded-For Manipulation

- Severity: Low 3.4 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:N/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.35%, higher than 30% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2025-05-06T14:55:48.766Z
- Modified: 2026-07-13T07:15:25.026Z
- Also known as: PYSEC-2025-242, GHSA-77q8-qmj7-x7pp
- Weaknesses: CWE-74
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

FastAPI Guard is a security library for FastAPI that provides middleware to control IPs, log requests, and detect penetration attempts. An HTTP header injection vulnerability has been identified in versions prior to 2.0.0. By manipulating the X-Forwarded-For header, an attacker can potentially inject arbitrary IP addresses into the request. This vulnerability can allow attackers to bypass IP-based access controls, mislead logging systems, and impersonate trusted clients. It is especially impactful when the application relies on the X-Forwarded-For header for IP-based authorization or authentication. Users should upgrade to FastAPI Guard version 2.0.0 to receive a fix.

(As written by CVE List.)

## Affected

- rennf93 fastapi-guard: < 2.0.0
- fastapi-guard fastapi_guard: before 2.0.0
- fastapi-guard (PyPI): before 2.0.0

## Every score

- GitHub_M: CVSS:3.1 3.4 Low `CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:N/A:N`
- NVD: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N`
- PyPA Advisory Database: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N`

## References

- <https://github.com/rennf93/fastapi-guard/security/advisories/GHSA-77q8-qmj7-x7pp> (exploit, evidence, vendor-advisory)
- <https://github.com/rennf93/fastapi-guard/commit/0b003fda4c678c1b514e95f319aee88113e9bf4b> (fix, patch)

## Sources

- CVE List: [CVE-2025-46814](https://www.cve.org/CVERecord?id=CVE-2025-46814), CVE Terms of Use, modified 2025-05-06
- NVD: [CVE-2025-46814](https://nvd.nist.gov/vuln/detail/CVE-2025-46814), Public domain, modified 2026-06-17
- PyPA Advisory Database: [PYSEC-2025-242](https://osv.dev/vulnerability/PYSEC-2025-242), CC-BY-4.0, modified 2026-07-13

---

Page: https://cve.day/CVE-2025-46814 · Whole record: https://cve.day/CVE-2025-46814.json · Rebuilt by cve.day 2026-11-25T22:58:57.658Z
