guzzlehttp/psr7 security advisory
CVE-2026-55766: CRLF injection in HTTP start-line serialization in guzzlehttp/psr7
CVE-2026-55766 is a medium-severity header injection vulnerability in the PHP package guzzlehttp/psr7 (CVSS 4.8), published 23 June 2026. It is fixed in 2.12.1; earlier versions are affected. It can be exploited without an account.
medium 4.8 published 2026-06-23 · updated 2026-10-25
- Affected versions
- < 2.12.1
- Fixed in
- 2.12.1
- Newest release
- 3.2.0
- Severity
- Medium · CVSS 4.8
- Type
- Header injection
CWE-93, CWE-113 - Exploited in the wild
- Not on the CISA KEV list
checked 2026-11-04
Is your guzzlehttp/psr7 version affected?
Who can exploit CVE-2026-55766
- Access: No account. Anyone who can send a request to an app that uses the affected code.
- Conditions: It only works under specific conditions the attacker does not fully control (CVSS rates the attack as high complexity).
CVSS vector (scored by GitHub): CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N
How to fix CVE-2026-55766 in guzzlehttp/psr7
- Find the installed version:
composer show guzzlehttp/psr7. If you never required it yourself,composer why guzzlehttp/psr7shows which package pulls it in. - Update it:
composer update guzzlehttp/psr7 --with-all-dependencies. You need 2.12.1 or newer. - If Composer will not go that high, your composer.json constraint is holding it back. Widen it (for example
"guzzlehttp/psr7": "^2.12.1"if you can take that version), or upgrade the package that requires it. - Run
composer audit. It reads the same advisory data and should no longer list CVE-2026-55766. - Commit composer.lock and deploy it. On the server, run
composer install --no-devfrom the lock file, notcomposer update.
If you cannot upgrade yet
- Strip CR and LF characters from any user input that ends up in mail or HTTP headers, including parameter names.
- If your app does not use the affected feature, note that in your audit, but still plan the upgrade.
The CVE-2026-55766 advisory
guzzlehttp/psr7 is a PSR-7 HTTP message library implementation in PHP. Prior to 2.12.1, guzzlehttp/psr7 did not reject CR/LF characters in certain first-party HTTP start-line fields: the request method, protocol version, and response reason phrase. If an application placed attacker-controlled data into one of those fields and later serialized the PSR-7 message as raw HTTP/1.x, for example with Message::toString() or an equivalent serializer, the serialized message could contain attacker-controlled header lines. The issue can also be reached through Message::parseRequest() or Message::parseResponse() when malformed raw messages are parsed into first-party PSR-7 objects and then serialized again. Creating or modifying a Request, Response, or other PSR-7 object alone is not sufficient. The issue requires the malformed message to be serialized and written to the network, forwarded, replayed, or otherwise processed by software that does not independently reject the malformed start line. This vulnerability is fixed in 2.12.1.
References
- GitHub security advisory GHSA-vm85-hxw5-5432 github.com
Other guzzlehttp/psr7 advisories
- medium CVE-2026-59882: Guzzlehttp/psr7: Host Confusion via Weak URI Host Validation 2026-07-21
- medium CVE-2026-48998: Host confusion via authority reinterpretation 2026-05-25
- medium CVE-2026-49214: CRLF injection via URI host component 2026-05-25
- medium CVE-2023-29197: Improper header validation 2023-04-17
- medium CVE-2022-24775: Inproper parsing of HTTP headers 2022-03-20
Related
Need help patching or upgrading? Laskyr does PHP and Laravel security fixes and upgrades. Tell us what you run and we reply with a plan and a price.
Ask about a fixWhere this data comes from
- Affected and fixed versions: the Packagist security advisories API (GitHub Advisory Database and FriendsOfPHP), the same data
composer audituses. Synced 2026-11-03. - Description, score, weakness and references: NIST National Vulnerability Database (NVD), checked 2026-11-04. This product uses data from the NVD API but is not endorsed or certified by the NVD.
- Exploited-in-the-wild status: the CISA Known Exploited Vulnerabilities catalog, checked 2026-11-04.
- Compiled by Daniel Lasek at Laskyr from the sources above. The summary, “who can exploit it”, “how to fix it” and hardening sections are our plain-English reading of the record and are generated from it. The quoted description is the record's own text. Spot an error? Tell us.