CVE-2022-31090
CURLOPT_HTTPAUTH option not cleared on change of origin in Guzzle
Guzzle, an extensible PHP HTTP client. Authorization headers on requests are sensitive information. In affected versions when using our Curl handler, it is possible to use the CURLOPT_HTTPAUTH option to specify an Authorization header. On making a request which responds with a redirect to a URI with a different origin (change in host, scheme or port), if we choose to follow it, we should remove the CURLOPT_HTTPAUTH option before continuing, stopping curl from appending the Authorization header to the new request. Affected Guzzle 7 users should upgrade to Guzzle 7.4.5 as soon as possible. Affected users using any earlier series of Guzzle should upgrade to Guzzle 6.5.8 or 7.4.5. Note that a partial fix was implemented in Guzzle 7.4.2, where a change in host would trigger removal of the curl-added Authorization header, however this earlier fix did not cover change in scheme or change in port. If you do not require or expect redirects to be followed, one should simply disable redirects all together. Alternatively, one can specify to use the Guzzle steam handler backend, rather than curl.
Attack profile
How easy it is to exploit
- Attack vector
- Network
- Complexity
- Low
- Privileges needed
- Low
- User interaction
- None
What an attacker can affect
- Confidentiality
- High
- Integrity
- None
- Availability
- None
Exploit likelihood
What each source reports
CVE List Score used
7.7
CURLOPT_HTTPAUTH option not cleared on change of origin in Guzzle
Guzzle, an extensible PHP HTTP client. Authorization headers on requests are sensitive information. In affected versions when using our Curl handler, it is possible to use the CURLOPT_HTTPAUTH option to specify an Authorization header. On making a request which responds with a redirect to a URI with a different origin (change in host, scheme or port), if we choose to follow it, we should remove the CURLOPT_HTTPAUTH option before continuing, stopping curl from appending the Authorization header to the new request. Affected Guzzle 7 users should upgrade to Guzzle 7.4.5 as soon as possible. Affected users using any earlier series of Guzzle should upgrade to Guzzle 6.5.8 or 7.4.5. Note that a partial fix was implemented in Guzzle 7.4.2, where a change in host would trigger removal of the curl-added Authorization header, however this earlier fix did not cover change in scheme or change in port. If you do not require or expect redirects to be followed, one should simply disable redirects all together. Alternatively, one can specify to use the Guzzle steam handler backend, rather than curl.
- Record
CVE-2022-31090- CVSS 3.1
- 7.7 High
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N - Weakness
- CWE-200
- Updated
- 2026-11-02
EUVDEUVD-2022-5884
7.7
Guzzle, an extensible PHP HTTP client. Authorization headers on requests are sensitive information. In affected versions when using our Curl handler, it is possible to use the CURLOPT_HTTPAUTH option to specify an Authorization header. On making a request which responds with a redirect to a URI with a different origin (change in host, scheme or port), if we choose to follow it, we should remove the CURLOPT_HTTPAUTH option before continuing, stopping curl from appending the Authorization header to the new request. Affected Guzzle 7 users should upgrade to Guzzle 7.4.5 as soon as possible. Affected users using any earlier series of Guzzle should upgrade to Guzzle 6.5.8 or 7.4.5. Note that a partial fix was implemented in Guzzle 7.4.2, where a change in host would trigger removal of the curl-added Authorization header, however this earlier fix did not cover change in scheme or change in port. If you do not require or expect redirects to be followed, one should simply disable redirects all together. Alternatively, one can specify to use the Guzzle steam handler backend, rather than curl.
- Record
EUVD-2022-5884- CVSS 3.1
- 7.7 High
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N - Updated
- 2026-11-02
GitHub AdvisoriesGHSA-25mq-v84q-4j7r
7.7
CURLOPT_HTTPAUTH option not cleared on change of origin
Impact
Authorization headers on requests are sensitive information. When using our Curl handler, it is possible to use the CURLOPT_HTTPAUTH option to specify an Authorization header. On making a request which responds with a redirect to a URI with a different origin, if we choose to follow it, we should remove the CURLOPT_HTTPAUTH and CURLOPT_USERPWD options before continuing, stopping curl from appending the Authorization header to the new request. Previously, we would only consider a change in host. Now, we consider any change in host, port or scheme to be a change in origin.
Patches
Affected Guzzle 7 users should upgrade to Guzzle 7.4.5 as soon as possible. Affected users using any earlier series of Guzzle should upgrade to Guzzle 6.5.8 or 7.4.5. Note that a partial fix was implemented in Guzzle 7.4.2, where a change in host would trigger removal of the curl-added Authorization header, however this earlier fix did not cover change in scheme or change in port.
Workarounds
If you do not require or expect redirects to be followed, one should simply disable redirects all together. Alternatively, one can specify to use the Guzzle stream handler backend, rather than curl.
References
For more information
If you have any questions or comments about this advisory, please get in touch with us in #guzzle on the PHP HTTP Slack. Do not report additional security advisories in that public channel, however - please follow our vulnerability reporting process.
- Record
GHSA-25mq-v84q-4j7r- CVSS 3.1
- 7.7 High
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N - Weakness
- CWE-200, CWE-212
- Updated
- 2026-11-02
NVD
7.7
Guzzle, an extensible PHP HTTP client. Authorization headers on requests are sensitive information. In affected versions when using our Curl handler, it is possible to use the CURLOPT_HTTPAUTH option to specify an Authorization header. On making a request which responds with a redirect to a URI with a different origin (change in host, scheme or port), if we choose to follow it, we should remove the CURLOPT_HTTPAUTH option before continuing, stopping curl from appending the Authorization header to the new request. Affected Guzzle 7 users should upgrade to Guzzle 7.4.5 as soon as possible. Affected users using any earlier series of Guzzle should upgrade to Guzzle 6.5.8 or 7.4.5. Note that a partial fix was implemented in Guzzle 7.4.2, where a change in host would trigger removal of the curl-added Authorization header, however this earlier fix did not cover change in scheme or change in port. If you do not require or expect redirects to be followed, one should simply disable redirects all together. Alternatively, one can specify to use the Guzzle steam handler backend, rather than curl.
- Record
CVE-2022-31090- CVSS 3.1
- 7.7 High
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N - CVSS 2.0
- 4.0 Medium
AV:N/AC:L/Au:S/C:P/I:N/A:N - Weakness
- CWE-200, CWE-212
- Updated
- 2026-11-02
OSV
7.7
CURLOPT_HTTPAUTH option not cleared on change of origin in Guzzle
Guzzle, an extensible PHP HTTP client. Authorization headers on requests are sensitive information. In affected versions when using our Curl handler, it is possible to use the CURLOPT_HTTPAUTH option to specify an Authorization header. On making a request which responds with a redirect to a URI with a different origin (change in host, scheme or port), if we choose to follow it, we should remove the CURLOPT_HTTPAUTH option before continuing, stopping curl from appending the Authorization header to the new request. Affected Guzzle 7 users should upgrade to Guzzle 7.4.5 as soon as possible. Affected users using any earlier series of Guzzle should upgrade to Guzzle 6.5.8 or 7.4.5. Note that a partial fix was implemented in Guzzle 7.4.2, where a change in host would trigger removal of the curl-added Authorization header, however this earlier fix did not cover change in scheme or change in port. If you do not require or expect redirects to be followed, one should simply disable redirects all together. Alternatively, one can specify to use the Guzzle steam handler backend, rather than curl.
- Record
CVE-2022-31090- CVSS 3.1
- 7.7 High
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N - Weakness
- CWE-200
- Updated
- 2026-11-02
OSVDEBIAN-CVE-2022-31090
7.7
Guzzle, an extensible PHP HTTP client. Authorization headers on requests are sensitive information. In affected versions when using our Curl handler, it is possible to use the CURLOPT_HTTPAUTH option to specify an Authorization header. On making a request which responds with a redirect to a URI with a different origin (change in host, scheme or port), if we choose to follow it, we should remove the CURLOPT_HTTPAUTH option before continuing, stopping curl from appending the Authorization header to the new request. Affected Guzzle 7 users should upgrade to Guzzle 7.4.5 as soon as possible. Affected users using any earlier series of Guzzle should upgrade to Guzzle 6.5.8 or 7.4.5. Note that a partial fix was implemented in Guzzle 7.4.2, where a change in host would trigger removal of the curl-added Authorization header, however this earlier fix did not cover change in scheme or change in port. If you do not require or expect redirects to be followed, one should simply disable redirects all together. Alternatively, one can specify to use the Guzzle steam handler backend, rather than curl.
- Record
DEBIAN-CVE-2022-31090- CVSS 3.1
- 7.7 High
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N - Updated
- 2026-11-03
Show 5 moreShow less
OSVGHSA-25mq-v84q-4j7r
7.7
CURLOPT_HTTPAUTH option not cleared on change of origin
Impact
Authorization headers on requests are sensitive information. When using our Curl handler, it is possible to use the CURLOPT_HTTPAUTH option to specify an Authorization header. On making a request which responds with a redirect to a URI with a different origin, if we choose to follow it, we should remove the CURLOPT_HTTPAUTH and CURLOPT_USERPWD options before continuing, stopping curl from appending the Authorization header to the new request. Previously, we would only consider a change in host. Now, we consider any change in host, port or scheme to be a change in origin.
Patches
Affected Guzzle 7 users should upgrade to Guzzle 7.4.5 as soon as possible. Affected users using any earlier series of Guzzle should upgrade to Guzzle 6.5.8 or 7.4.5. Note that a partial fix was implemented in Guzzle 7.4.2, where a change in host would trigger removal of the curl-added Authorization header, however this earlier fix did not cover change in scheme or change in port.
Workarounds
If you do not require or expect redirects to be followed, one should simply disable redirects all together. Alternatively, one can specify to use the Guzzle stream handler backend, rather than curl.
References
For more information
If you have any questions or comments about this advisory, please get in touch with us in #guzzle on the PHP HTTP Slack. Do not report additional security advisories in that public channel, however - please follow our vulnerability reporting process.
- Record
GHSA-25mq-v84q-4j7r- CVSS 3.1
- 7.7 High
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N - Weakness
- CWE-200, CWE-212
- Updated
- 2026-11-02
OSVUBUNTU-CVE-2022-31090
7.7
Guzzle, an extensible PHP HTTP client. Authorization headers on requests are sensitive information. In affected versions when using our Curl handler, it is possible to use the CURLOPT_HTTPAUTH option to specify an Authorization header. On making a request which responds with a redirect to a URI with a different origin (change in host, scheme or port), if we choose to follow it, we should remove the CURLOPT_HTTPAUTH option before continuing, stopping curl from appending the Authorization header to the new request. Affected Guzzle 7 users should upgrade to Guzzle 7.4.5 as soon as possible. Affected users using any earlier series of Guzzle should upgrade to Guzzle 6.5.8 or 7.4.5. Note that a partial fix was implemented in Guzzle 7.4.2, where a change in host would trigger removal of the curl-added Authorization header, however this earlier fix did not cover change in scheme or change in port. If you do not require or expect redirects to be followed, one should simply disable redirects all together. Alternatively, one can specify to use the Guzzle steam handler backend, rather than curl.
- Record
UBUNTU-CVE-2022-31090- CVSS 3.1
- 7.7 High
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N - Updated
- 2026-11-02
OSVCLSA-2026-1779065200 No score
TuxCare security update for guzzlehttp/guzzle (5 CVEs)
TuxCare rebuilt guzzlehttp/guzzle to address 5 CVEs. Fixed in 6.3.3-p1+tuxcare.
- Record
CLSA-2026-1779065200- Updated
- 2026-11-02
OSVCLSA-2026-1783991062 No score
TuxCare security update for guzzlehttp/guzzle (3 CVEs)
TuxCare rebuilt guzzlehttp/guzzle to address 3 CVEs. Fixed in 6.0.2-p3+tuxcare.
- Record
CLSA-2026-1783991062- Updated
- 2026-11-02
OSVMGASA-2022-0338 No score
Updated mediawiki packages fix security vulnerability
Username is not escaped in the "welcomeuser" message (T308471).
Bundled guzzlehttp/guzzle has been updated to 6.5.8, fixing several issues (CVE-2022-29248, CVE-2022-31042, CVE-2022-31043, CVE-2022-31090, CVE-2022-31091).
- Record
MGASA-2022-0338- Updated
- 2026-11-02
Affected products
Affected packages
| Package | Affected | Fixed |
|---|---|---|
guzzlehttp/guzzlePackagist |
before 6.5.8 | 6.5.8 |
guzzlehttp/guzzlePackagist |
7.0.0 up to 7.4.5 | 7.4.5 |
guzzlehttp/guzzleTuxCare:Packagist From an advisory covering 5 CVEs |
6.3.3 up to 6.3.3-p1+tuxcare | 6.3.3-p1+tuxcare |
guzzlehttp/guzzleTuxCare:Packagist From an advisory covering 3 CVEs |
6.0.2 up to 6.0.2-p3+tuxcare, plus listed versions 6.0.2-p1+tuxcare6.0.2-p2+tuxcare |
6.0.2-p3+tuxcare |
guzzleDebian:12 |
before 7.4.5-1 | 7.4.5-1 |
guzzleDebian:13 |
before 7.4.5-1 | 7.4.5-1 |
guzzleDebian:14 |
before 7.4.5-1 | 7.4.5-1 |
mediawikiDebian:12 |
before 1:1.35.7-1 | 1:1.35.7-1 |
mediawikiDebian:13 |
before 1:1.35.7-1 | 1:1.35.7-1 |
mediawikiDebian:14 |
before 1:1.35.7-1 | 1:1.35.7-1 |
Show 21 moreShow less
| Package | Affected | Fixed |
|---|---|---|
mediawikiDebian:11 From an advisory covering 15 CVEs |
before 1:1.35.8-1~deb11u1, plus listed versions 1:1.35.2-11:1.35.3-11:1.35.4-11:1.35.4-1+deb11u21:1.35.4-1~deb11u1 Show 4 moreShow less1:1.35.5-11:1.35.5-21:1.35.6-11:1.35.7-1 |
1:1.35.8-1~deb11u1 |
guzzlehttp/guzzlePackagist |
before 6.5.8, plus listed versions 4.0.04.0.0-rc.14.0.0-rc.24.0.14.0.2 Show 45 moreShow less4.1.04.1.14.1.24.1.34.1.44.1.54.1.64.1.74.1.84.2.04.2.14.2.24.2.34.2.45.0.05.0.15.0.25.0.35.1.05.2.05.3.05.3.15.3.25.3.35.3.46.0.06.0.16.0.26.1.06.1.16.2.06.2.16.2.26.2.36.3.06.3.16.3.26.3.36.4.06.4.16.5.06.5.16.5.26.5.36.5.4 |
6.5.8 |
guzzlehttp/guzzlePackagist |
7.0.0 up to 7.4.5, plus listed versions 7.0.17.1.07.1.17.2.07.3.0 Show 5 moreShow less7.4.07.4.17.4.27.4.37.4.4 |
7.4.5 |
mediawikiMageia:8 From an advisory covering 5 CVEs |
before 1.35.7-1.mga8 | 1.35.7-1.mga8 |
civicrmUbuntu:Pro:16.04:LTS |
All versions, plus listed versions 4.7.1+dfsg-14.7.1+dfsg-24.7.1+dfsg-2ubuntu14.7.1+dfsg-2ubuntu1+esm1 |
None known |
civicrmUbuntu:Pro:18.04:LTS |
All versions, plus listed versions 4.7.23+dfsg-1ubuntu14.7.24+dfsg-1ubuntu14.7.30+dfsg-1ubuntu14.7.30+dfsg-1ubuntu1+esm1 |
None known |
mediawikiUbuntu:18.04:LTS |
All versions, plus listed versions 1:1.27.3-11:1.27.4-11:1.27.4-21:1.27.4-3 |
None known |
civicrmUbuntu:Pro:20.04:LTS |
All versions, plus listed versions 5.11.0+dfsg-15.18.1+dfsg-15.20.3+dfsg-15.21.0+dfsg-15.21.1+dfsg-15.21.2+dfsg-15.21.2+dfsg-1ubuntu0.1~esm1 |
None known |
mediawikiUbuntu:Pro:20.04:LTS |
All versions, plus listed versions 1:1.31.2-1ubuntu11:1.31.5-11:1.31.5-1ubuntu11:1.31.5-21:1.31.5-3 Show 4 moreShow less1:1.31.5-3ubuntu11:1.31.6-11:1.31.7-11:1.31.7-1ubuntu0.1~esm1 |
None known |
icinga-php-thirdpartyUbuntu:22.04:LTS |
All versions, plus listed versions 0.10.0-1 |
None known |
icingaweb2-module-reactbundleUbuntu:22.04:LTS |
All versions, plus listed versions 0.8.0-1.10.9.0-1 |
None known |
civicrmUbuntu:Pro:22.04:LTS |
All versions, plus listed versions 5.33.2+dfsg1-15.33.2+dfsg1-1build15.33.2+dfsg1-1ubuntu15.33.2+dfsg1-1ubuntu1+esm1 |
None known |
mediawikiUbuntu:Pro:22.04:LTS |
All versions, plus listed versions 1:1.35.3-11:1.35.4-11:1.35.5-11:1.35.5-1ubuntu11:1.35.5-1ubuntu21:1.35.5-1ubuntu31:1.35.6-11:1.35.6-1ubuntu0.1~esm1 |
None known |
icinga-php-thirdpartyUbuntu:24.04:LTS |
All versions, plus listed versions 0.11.0-20.12.0+ds-10.12.1+ds-1 |
None known |
icingaweb2-module-reactbundleUbuntu:24.04:LTS |
All versions, plus listed versions 0.9.0-1 |
None known |
icinga-php-thirdpartyUbuntu:25.10 |
All versions, plus listed versions 0.12.1+ds-1 |
None known |
icingaweb2-module-reactbundleUbuntu:25.10 |
All versions, plus listed versions 0.9.0-1 |
None known |
icinga-php-thirdpartyUbuntu:26.10 |
All versions, plus listed versions 0.14.0+ds-10.15.2-10.15.3-11.0.0-1 |
None known |
icingaweb2-module-reactbundleUbuntu:26.10 |
All versions, plus listed versions 0.9.0-1build1 |
None known |
icinga-php-thirdpartyUbuntu:26.04:LTS |
All versions, plus listed versions 0.12.1+ds-10.13.1+ds-10.14.0+ds-1 |
None known |
icingaweb2-module-reactbundleUbuntu:26.04:LTS |
All versions, plus listed versions 0.9.0-10.9.0-1build1 |
None known |
History
| Recorded | Changed | Sources |
|---|---|---|
| affected, facts | OSV | |
| first indexed | CVE List, EUVD, GitHub Advisories, NVD, OSV |
Dates are when Every CVE recorded each change. Upstream dates may differ.
In short
CVE-2022-31090 is a high vulnerability (CVSS 7.7) in Guzzle, published June 21, 2022. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 1.92%, the 79th percentile. Fixed in guzzlehttp/guzzle 6.5.8.
References
github.com/guzzle/guzzle/security/advisories/GHSA-25mq-v84q-4j7r
github.com/guzzle/guzzle/commit/1dd98b0564cb3f6bd16ce683cb755f94c10fbd82
debian.org/security/2022/dsa-5246
security.gentoo.org/glsa/202305-24
github.com/guzzle/guzzle/blob/6.5.8/CHANGELOG.md
github.com/guzzle/guzzle/blob/7.4.5/CHANGELOG.md
Show 15 moreShow less
github.com/FriendsOfPHP/security-advisories/blob/master/guzzlehttp/guzzle/CVE-2022-31090.yaml
nvd.nist.gov/vuln/detail/CVE-2022-31090
github.com/advisories/GHSA-25mq-v84q-4j7r
github.com/CVEProject/cvelistV5/tree/main/cves/2022/31xxx/CVE-2022-31090.json
security-tracker.debian.org/tracker/CVE-2022-31090
github.com/guzzle/guzzle
advisories.mageia.org/MGASA-2022-0338.html
bugs.mageia.org/show_bug.cgi?id=30837
github.com/guzzle/guzzle/security/advisories/GHSA-cwmx-hcrq-mhc3
github.com/guzzle/guzzle/security/advisories/GHSA-w248-ffj2-4v5q
github.com/guzzle/guzzle/security/advisories/GHSA-f2wf-25xc-69c9
github.com/guzzle/guzzle/security/advisories/GHSA-q559-8m2m-g699
lists.wikimedia.org/hyperkitty/list/[email protected]/thread/PIPYDRSHXOYW5DB7X755QDNUV5EZWPWB
ubuntu.com/security/CVE-2022-31090
cve.org/CVERecord?id=CVE-2022-31090
Left out here: 71 versions. The JSON record has them.