Description
guzzlehttp/psr7 is a PSR-7 HTTP message library implementation in PHP. Prior to 2.12.3, Uri::assertValidHost() does not reject URI host components containing authority delimiters, embedded ports, or malformed IPv6 brackets, allowing Uri::getHost() to disagree with the URI authority used for security or routing decisions. This issue is fixed in version 2.12.3.
Published: 2026-07-08
Score: 4.2 Medium
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

Uri::assertValidHost() in guzzle:psr7 versions older than 2.12.3 fails to reject host components that contain authority delimiters, embedded ports, or malformed IPv6 brackets, allowing Uri::getHost() to return a host that differs from the URI authority. This mismatch—representing a Host Confusion flaw (CWE‑436)—can lead to host confusion attacks that cause requests to be routed to unintended destinations or bypass host‑based access controls.

Affected Systems

All installations of guzzle:psr7 earlier than version 2.12.3 are affected. Any PHP application that depends on the library—directly or indirectly—is at risk; the issue pertains only to the URI parsing functionality.

Risk and Exploitability

Based on the description, it is inferred that attackers can supply a crafted URI that passes validation but contains a conflicting host, typically through user input or manipulated data sources. The CVSS score of 4.2 indicates moderate severity; EPSS is reported as <1%, and the vulnerability is not listed in CISA KEV. While the likelihood of exploitation appears low, the impact of misrouting or improper access control could compromise confidentiality or integrity in systems that depend heavily on the host value for security decisions.

Generated by OpenCVE AI on July 29, 2026 at 13:55 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade guzzlehttp/psr7 to version 2.12.3 or later
  • If an upgrade cannot be performed immediately, add explicit host validation checks to reject authority delimiters, ports, and malformed IPv6 before using the URI for routing or security decisions
  • Monitor request handling for unexpected host values that could indicate attempts to exploit host confusion

Generated by OpenCVE AI on July 29, 2026 at 13:55 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-c2w2-prh8-qm98 guzzlehttp/psr7: Host Confusion via Weak URI Host Validation
History

Fri, 10 Jul 2026 09:30:00 +0000

Type Values Removed Values Added
First Time appeared Guzzlephp
Guzzlephp psr-7
Vendors & Products Guzzlephp
Guzzlephp psr-7

Wed, 08 Jul 2026 17:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Wed, 08 Jul 2026 16:30:00 +0000

Type Values Removed Values Added
Description guzzlehttp/psr7 is a PSR-7 HTTP message library implementation in PHP. Prior to 2.12.3, Uri::assertValidHost() does not reject URI host components containing authority delimiters, embedded ports, or malformed IPv6 brackets, allowing Uri::getHost() to disagree with the URI authority used for security or routing decisions. This issue is fixed in version 2.12.3.
Title guzzlehttp/psr7: Host Confusion via Weak URI Host Validation
Weaknesses CWE-436
References
Metrics cvssV3_1

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


cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-07-08T17:00:22.945Z

Reserved: 2026-07-07T16:40:07.982Z

Link: CVE-2026-59882

cve-icon Vulnrichment

Updated: 2026-07-08T16:50:29.367Z

cve-icon NVD

No data.

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-07-29T14:00:03Z

Weaknesses