CVE-2026-91766
Description
A flaw was found in PHP. When following a redirect, the built-in HTTP (Hypertext Transfer Protocol) stream wrapper forwards sensitive request headers—such as authentication tokens and session cookies—unchanged, even when directed to a different host, port, or unencrypted connection. A malicious server capable of steering redirects can exploit this flaw to capture sensitive credentials intended only for the original destination.
Statement
This vulnerability is rated Moderate because PHP's HTTP stream wrapper can forward Authorization, Cookie, and Proxy-Authorization headers across cross-origin redirects, exposing credentials to an attacker-controlled redirect target. Attack complexity is elevated because the initial destination must issue a redirect that the client follows.
Mitigation
Avoid placing long-lived credentials in HTTP stream context headers when follow_location is enabled; prefer short-lived tokens and same-origin redirect expectations. Restrict outbound HTTP(S) destinations from PHP applications to trusted hosts.
Common Vulnerability Scoring System (CVSS) Score Details
Info alert:Important note
CVSS scores for open source components depend on vendor-specific factors (e.g. version or build chain). Therefore, Red Hat's score and impact rating can be different from NVD and other vendors. Red Hat remains the authoritative CVE Naming Authority (CNA) source for its products and services (see Red Hat classifications).
CVSS v3 Score Breakdown
| Red Hat | NVD | cve.org | |
|---|---|---|---|
| Base Score | 5.9 | 5.9 | 5.9 |
| Attack Vector | Network | Network | Network |
| Attack Complexity | High | High | High |
| Privileges Required | None | None | None |
| User Interaction | None | None | None |
| Scope | Unchanged | Unchanged | Unchanged |
| Confidentiality | High | High | High |
| Integrity Impact | None | None | None |
| Availability Impact | None | None | None |
Vector
Red Hat: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N
NVD: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N
cve.org: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:N
Understanding the Weakness (CWE)
Confidentiality
Technical Impact: Read Application Data
Frequently Asked Questions
Not sure what something means? Check out our Security Glossary.
Want to get errata notifications? Sign up here.