CVE-2023-29197 Improper header name validation in guzzlehttp/psr7

Medium 5.3 Published Updated

Attackers can inject newlines into HTTP headers due to improper validation, potentially bypassing security controls in applications using this PHP library.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2023-29197?

CVE-2023-29197 is a medium-severity vulnerability in Fedoraproject Fedora, published on 17 Apr 2023. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

guzzlehttp/psr7 is a PSR-7 HTTP message library implementation in PHP. Affected versions are subject to improper header parsing. An attacker could sneak in a newline (\n) into both the header names and values. While the specification states that \r\n\r\n is used to terminate the header list, many servers in the wild will also accept \n\n. This is a follow-up to CVE-2022-24775 where the fix was incomplete. The issue has been patched in versions 1.9.1 and 2.4.5. There are no known workarounds for this vulnerability. Users are advised to upgrade.

Weakness: CWE-436

Which versions are affected by CVE-2023-29197?

4 open source packages ship an affected version, including guzzlehttp/psr7. It affects 2 products.

PackageAffectedFixed in
guzzlehttp/psr7 PackagistAll versions1.9.1
guzzlehttp/psr7 PackagistAll versions1.9.1
guzzlehttp/psr7 PackagistFrom 2.0.02.4.5
guzzlehttp/psr7 PackagistFrom 2.0.02.4.5

Products include Fedoraproject Fedora, Guzzlephp Psr-7.

How do I fix CVE-2023-29197?

Upgrade guzzlehttp/psr7 to a fixed version for your release line: 1.9.1 or 2.4.5.

Is CVE-2023-29197 being exploited?

There is no known exploitation of CVE-2023-29197 in the wild and no public exploit code.

All Fedoraproject Fedora vulnerabilities

Sources

Also known as CLSA-2026-1788333194, DEBIAN-CVE-2023-29197, DLA-3705-1, GHSA-wxmh-65f7-jcvw, UBUNTU-CVE-2023-29197, USN-6671-1.

Is CVE-2023-29197 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free