Failure to strip the Cookie header on change in host or HTTP downgrade
CVE-2022-31042GHSA-f2wf-25xc-69c9
What to do
Vendor fix available. Upgrade each affected package to the fixed version on its release line (guzzlehttp/guzzle 7.4.4, 6.5.7), redeploy, then verify what is actually installed.
This page has no inventory attached, so it cannot say whether you are affected. A vendor fix is not proof that your deployment is fixed.
Affected packages
Packagist guzzlehttp/guzzle
- Affected
- >= 7.0.0, < 7.4.4>= 4.0.0, < 6.5.7
- Fixed in
- 6.5.7, 7.4.4
Sources
- GitHub Advisory Database and maintainer security advisories on GitHub
GitHub-reviewed advisory GHSA-f2wf-25xc-69c9 lists affected ranges: Packagist guzzlehttp/guzzle >=7.0.0 =4.0.0 <6.5.7
VerifiedObserved Structured GitHub Advisory Database record (type=reviewed) from the GitHub REST API.
Severity and exploitation
- Exploitation
- No confirmed exploitation recorded. Patch Next marks exploitation only from CISA KEV.
- CVSS
- 7.5 · CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
- EPSS
- CVE-2022-31042: 1.99% estimated exploitation activity in the next 30 days; percentile 80.70 (FIRST EPSS, 2026-11-03). This is a model estimate, not proof of exploitation or customer exposure.
Source description
As published by the source; long descriptions are shortened.
Impact Cookie headers on requests are sensitive information. On making a request using the https scheme to a server which responds with a redirect to a URI with the http scheme, or on making a request to a server which responds with a redirect to a a URI to a different host, we should not forward the Cookie header on. Prior to this fix, only cookies that were managed by our cookie middleware would be safely removed, and any Cookie header manually added to the initial request would not be stripped. We now always strip it, and allow the cookie middleware to re-add any cookies that it deems should be there. Patches Affected Guzzle 7 users should upgrade to Guzzle 7.4.4 as soon as possible. Affected users using any earlier series of Guzzle should upgrade to Guzzle 6.5.7 or 7.4.4. Workarounds An alternative approach would be to use your own redirect middleware, rather than ours, if you are unable to upgrade. If you do not require or expect redirects to be followed, one should simply…
Dates and revisions
- Published by the source
- Last modified by the source
- Source last checked
- Revision 1 · created ·
Published from ghsa record GHSA-f2wf-25xc-69c9
Agent brief
Preview the exact text before you copy it. Commands are read-only suggestions; review them before running anything.
# Patch Next advisory brief: CVE-2022-31042 Advisory: Failure to strip the Cookie header on change in host or HTTP downgrade IDs: CVE-2022-31042, GHSA-f2wf-25xc-69c9 Record: https://patchnext.com/advisories/cve-2022-31042 (revision 1, source checked 26 Oct 2026, 14:06 UTC) Inventory: none attached. This brief comes from a public page and does not say whether any deployment is affected. Severity: High (CVSS 7.5) Exploitation: no confirmed exploitation recorded. Patch Next confirms exploitation only from CISA KEV. Vendor response: Vendor fix available; fixed versions by package: guzzlehttp/guzzle 7.4.4, 6.5.7. A vendor fix does not mean a deployment is fixed. ## Affected components - Packagist guzzlehttp/guzzle: affected >= 7.0.0, < 7.4.4; >= 4.0.0, < 6.5.7; fixed in 6.5.7, 7.4.4 ## Suggested inspection (read-only) - Packagist guzzlehttp/guzzle: check the installed version with your package manager. ## Supported action Upgrade each affected component to a fixed version on its release line. For a transitive dependency, upgrade the parent package or add an override or constraint, then regenerate the lockfile. Redeploy every environment that ran an affected version. ## Required regression checks - Run the test suite and a production build. - Exercise the features that depend on guzzlehttp/guzzle. - Repeat the inspection and confirm that only fixed versions remain installed. ## Rollback considerations - Keep the previous lockfile and deployment artifact. Rolling back reinstates the vulnerable version, so apply any documented mitigation while you fix forward. ## Unresolved questions - Which deployments run an affected version? - Exploitation status can change. Check again before lowering the priority. - Mark the work resolved only after the fixed version is verified in production. ## Sources - Verified: https://github.com/advisories/GHSA-f2wf-25xc-69c9 (GitHub-reviewed advisory GHSA-f2wf-25xc-69c9 lists affected ranges: Packagist guzzlehttp/guzzle >=7.0.0 =4.0.0 <6.5.7) Commands are suggestions: review each one before running it.
Loading voting…