{"id":"CVE-2022-29248","aliases":["CVE-2022-29248","GHSA-cwmx-hcrq-mhc3","BIT-DRUPAL-2022-29248","DRUPAL-CORE-2022-010"],"related":[],"kind":"vulnerability","state":"published","title":"Cross-domain cookie leakage in Guzzle","summary":"Guzzle is a PHP HTTP client. Guzzle prior to versions 6.5.6 and 7.4.3 contains a vulnerability with the cookie middleware. The vulnerability is that it is not checked if the cookie domain equals the domain of the server which sets the cookie via the Set-Cookie header, allowing a malicious server to set cookies for unrelated domains. The cookie middleware is disabled by default, so most library consumers will not be affected by this issue. Only those who manually add the cookie middleware to the handler stack or construct the client with ['cookies' => true] are affected. Moreover, those who do not use the same Guzzle client to call multiple domains and have disabled redirect forwarding are not affected by this vulnerability. Guzzle versions 6.5.6 and 7.4.3 contain a patch for this issue. As a workaround, turn off the cookie middleware.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Guzzle is a PHP HTTP client. Guzzle prior to versions 6.5.6 and 7.4.3 contains a vulnerability with the cookie middleware. The vulnerability is that it is not checked if the cookie domain equals the domain of the server which sets the cookie via the Set-Cookie header, allowing a malicious server to set cookies for unrelated domains. The cookie middleware is disabled by default, so most library consumers will not be affected by this issue. Only those who manually add the cookie middleware to the handler stack or construct the client with ['cookies' => true] are affected. Moreover, those who do not use the same Guzzle client to call multiple domains and have disabled redirect forwarding are not affected by this vulnerability. Guzzle versions 6.5.6 and 7.4.3 contain a patch for this issue. As a workaround, turn off the cookie middleware.","source":"cvelist"},{"lang":"en","text":"### Impact\n\nPrevious version of Guzzle contain a vulnerability with the cookie middleware. The vulnerability is that it is not checked if the cookie domain equals the domain of the server which sets the cookie via the `Set-Cookie` header, allowing a malicious server to set cookies for unrelated domains. For example an attacker at `www.example.com` might set a session cookie for `api.example.net`, logging the Guzzle client into their account and retrieving private API requests from the security log of their account.\n\nNote that our cookie middleware is disabled by default, so most library consumers will not be affected by this issue. Only those who manually add the cookie middleware to the handler stack or construct the client with `['cookies' => true]` are affected. Moreover, those who do not use the same Guzzle client to call multiple domains and have disabled redirect forwarding are not affected by this vulnerability.\n\n### Patches\n\nAffected Guzzle 7 users should upgrade to Guzzle 7.4.3 as soon as possible. Affected users using any earlier series of Guzzle should upgrade to Guzzle 6.5.6 or 7.4.3.\n\n### Workarounds\n\nIf you do not need support for cookies, turn off the cookie middleware. It is already off by default, but if you have turned it on and no longer need it, turn it off.\n\n### References\n\n* [RFC6265 Section 5.3](https://datatracker.ietf.org/doc/html/rfc6265#section-5.3)\n* [RFC9110 Section 15.4](https://www.rfc-editor.org/rfc/rfc9110.html#name-redirection-3xx)\n\n### For more information\n\nIf you have any questions or comments about this advisory, please get in touch with us in `#guzzle` on the [PHP HTTP Slack](https://php-http.slack.com/). Do not report additional security advisories in that public channel, however - please follow our [vulnerability reporting process](https://github.com/guzzle/guzzle/security/policy).","format":"markdown","source":"ghsa"},{"lang":"en","text":"Drupal uses the third-party Guzzle library for handling HTTP requests and responses to external services. [Guzzle has released a security update](https://github.com/guzzle/guzzle/security/advisories/GHSA-cwmx-hcrq-mhc3) which does not affect Drupal core, but may affect some contributed projects or custom code on Drupal sites.\n\nWe are issuing this security advisory outside our regular [Drupal security release window schedule](https://www.drupal.org/node/1173280) since Guzzle has already published information about the vulnerability, and vulnerabilities might exist in contributed modules or custom modules that use Guzzle for outgoing requests. Guzzle has rated this vulnerability as high-risk.\n\nThis advisory is not covered by Drupal Steward.","format":"markdown","source":"drupal"},{"lang":"es","text":"Guzzle es un cliente PHP HTTP. Guzzle versiones anteriores a 6.5.6 y 7.4.3, contienen una vulnerabilidad con el middleware de cookies. La vulnerabilidad consiste en que no es comprobado si el dominio de la cookie es igual al dominio del servidor que establece la cookie por medio del encabezado Set-Cookie, lo que permite a un servidor malicioso establecer cookies para dominios no relacionados. El middleware de cookies está deshabilitado por defecto, por lo que la mayoría de los consumidores de la biblioteca no estarán afectados por este problema. Sólo aquellos que añaden manualmente el middleware de cookies a la pila de manejadores o construyen el cliente con [\"cookies\" =) true] están afectados. Además, aquellos que no usen el mismo cliente Guzzle para llamar a múltiples dominios y hayan deshabilitado el reenvío de redirecciones no estarán afectados por esta vulnerabilidad. Guzzle versiones 6.5.6 y 7.4.3, contienen un parche para este problema. Como mitigación, deshabilite el middleware de cookies","source":"nvd"}],"published":"2022-05-25T00:00:00.000Z","modified":"2026-09-19T16:27:58.000Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:N","score":8,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:N","score":8,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:N","score":8,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:N","score":8.1,"rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:2.0","vector":"AV:N/AC:M/Au:N/C:P/I:P/A:N","score":5.8,"rating":"MEDIUM"},{"scorer":"Bitnami Vulnerability Database","scheme":"rating","rating":"HIGH"}],"cwes":["CWE-200","CWE-565"],"affected":[{"ranges":[{"version":"< 6.5.6","status":"affected"},{"version":">= 7.0.0, < 7.4.3","status":"affected"}],"vendor":"guzzle","product":"guzzle","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"6.5.6"}],"ecosystem":"Packagist","package":"guzzlehttp/guzzle","purl":"pkg:composer/guzzlehttp/guzzle","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"7.0.0","status":"affected","fixed":"7.4.3"}],"ecosystem":"Packagist","package":"guzzlehttp/guzzle","purl":"pkg:composer/guzzlehttp/guzzle","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"8.0.0","status":"affected","fixed":"9.2.20"},{"type":"ecosystem","introduced":"9.3.0","status":"affected","fixed":"9.3.14"}],"ecosystem":"Packagist","package":"drupal/core","purl":"pkg:composer/drupal/core","source":"drupal"},{"ranges":[{"status":"affected","fixed":"6.5.6"},{"status":"affected","introduced":"7.0.0","fixed":"7.4.3"}],"vendor":"guzzlephp","product":"guzzle","cpe":"cpe:2.3:a:guzzlephp:guzzle:*:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"status":"affected","introduced":"9.2.0","fixed":"9.2.20"},{"status":"affected","introduced":"9.3.0","fixed":"9.3.14"}],"vendor":"drupal","product":"drupal","cpe":"cpe:2.3:a:drupal:drupal:*:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"status":"affected","version":"11.0"}],"vendor":"debian","product":"debian_linux","cpe":"cpe:2.3:o:debian:debian_linux:11.0:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"type":"semver","introduced":"9.2.0","status":"affected","fixed":"9.2.20"},{"type":"semver","introduced":"9.3.0","status":"affected","fixed":"9.3.14"}],"ecosystem":"Bitnami","package":"drupal","purl":"pkg:bitnami/drupal","source":"bitnami"}],"references":[{"url":"https://github.com/guzzle/guzzle/security/advisories/GHSA-cwmx-hcrq-mhc3","tags":["advisory","third-party-advisory","web","x-transferred"],"sources":["cvelist","ghsa","nvd","bitnami"]},{"url":"https://github.com/guzzle/guzzle/pull/3018","tags":["advisory","issue-tracking","patch","third-party-advisory","web","x-transferred"],"sources":["cvelist","ghsa","nvd","bitnami"]},{"url":"https://github.com/guzzle/guzzle/commit/74a8602c6faec9ef74b7a9391ac82c5e65b1cdab","tags":["advisory","patch","third-party-advisory","web","x-transferred"],"sources":["cvelist","ghsa","nvd","bitnami"]},{"url":"https://www.drupal.org/sa-core-2022-010","tags":["advisory","patch","third-party-advisory","web","x-transferred"],"sources":["cvelist","ghsa","drupal","nvd","bitnami"]},{"url":"https://www.debian.org/security/2022/dsa-5246","tags":["advisory","third-party-advisory","vendor-advisory","web","x-transferred"],"sources":["cvelist","ghsa","nvd","bitnami"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-29248","tags":["advisory","web"],"sources":["ghsa","bitnami"]},{"url":"https://github.com/FriendsOfPHP/security-advisories/blob/master/guzzlehttp/guzzle/CVE-2022-29248.yaml","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/guzzle/guzzle","tags":["package"],"sources":["ghsa"]}],"credits":["Dezső BICZÓ","mayela"],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"total","date":"2025-04-23T15:52:51.158Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-29248","url":"https://www.cve.org/CVERecord?id=CVE-2022-29248","licence":"CVE Terms of Use","modified":"2025-04-23T18:21:56.089Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-cwmx-hcrq-mhc3","url":"https://github.com/advisories/GHSA-cwmx-hcrq-mhc3","licence":"CC-BY-4.0","modified":"2025-12-10T23:41:02.272Z"},{"source":"drupal","name":"Drupal Security Team","id":"DRUPAL-CORE-2022-010","url":"https://osv.dev/vulnerability/DRUPAL-CORE-2022-010","licence":"MIT","modified":"2026-09-19T16:27:58.000Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-29248","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-29248","licence":"Public domain","modified":"2026-06-17T04:39:54.950Z"},{"source":"bitnami","name":"Bitnami Vulnerability Database","id":"BIT-DRUPAL-2022-29248","url":"https://osv.dev/vulnerability/BIT-DRUPAL-2022-29248","licence":"Apache-2.0","modified":"2026-09-08T08:47:02.593Z"}],"updatedAt":"2026-11-25T22:58:11.935Z","epss":{"score":0.01351,"percentile":0.72316,"date":"2026-12-01T12:00:22.000Z"}}