Redirects can change who receives a header
CVE-2026-91766 affects PHP’s HTTP stream wrapper when it follows redirects. The PHP project says the wrapper could forward Authorization, Cookie and Proxy-Authorization headers unchanged, even when the redirect moved to a different host, port or from HTTPS to HTTP. A destination that controls a redirect could receive credentials meant for the original service.
The upstream advisory lists fixed versions 8.2.34, 8.3.35, 8.4.26 and 8.5.11. Later security releases include these fixes. Check the exact package and branch rather than relying only on the date of the advisory.
Review code that sends credentials
Search PHP applications for stream contexts that set Authorization, Cookie or Proxy-Authorization headers and allow redirects. Check integrations that send a token to a partner API, document service or webhook endpoint. Review whether the first URL can be changed by a user or an administrator.
Avoid forwarding credentials across origins. Use a fixed destination allowlist and handle redirects with an explicit policy. Consider whether the remote service needs redirects at all.
Upgrade and review credentials
Install the supported PHP build containing the fix. Check runtime versions on web and background workers. If logs or request records show that a credential may have been sent to another origin, rotate it and review the destination service’s access logs.
Test redirects between the expected origin and a different host after the update. Confirm that sensitive headers do not leave the intended service boundary.
