{"id":"CVE-2022-24895","aliases":["CVE-2022-24895","GHSA-3gv2-29qc-v67m","BIT-SYMFONY-2022-24895"],"related":[],"kind":"vulnerability","state":"published","title":"Symfony vulnerable to Session Fixation of CSRF tokens","summary":"Symfony is a PHP framework for web and console applications and a set of reusable PHP components. When authenticating users Symfony by default regenerates the session ID upon login, but preserves the rest of session attributes. Because this does not clear CSRF tokens upon login, this might enables same-site attackers to bypass the CSRF protection mechanism by performing an attack similar to a session-fixation. This issue has been fixed in the 4.4 branch.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Symfony is a PHP framework for web and console applications and a set of reusable PHP components. When authenticating users Symfony by default regenerates the session ID upon login, but preserves the rest of session attributes. Because this does not clear CSRF tokens upon login, this might enables same-site attackers to bypass the CSRF protection mechanism by performing an attack similar to a session-fixation. This issue has been fixed in the 4.4 branch.","source":"cvelist"},{"lang":"en","text":"Description\n-----------\n\nWhen authenticating users Symfony by default regenerates the session ID upon login, but preserves the rest of session attributes. Because this does not clear CSRF tokens upon login, this might enables [same-site attackers](https://canitakeyoursubdomain.name/) to bypass the CSRF protection mechanism by performing an attack similar to a session-fixation.\n\nResolution\n----------\n\nSymfony removes all CSRF tokens from the session on successful login.\n\nThe patch for this issue is available [here](https://github.com/symfony/symfony/commit/5909d74ecee359ea4982fcf4331aaf2e489a1fd4) for branch 4.4.\n\nCredits\n-------\n\nWe would like to thank Marco Squarcina for reporting the issue and Nicolas Grekas for fixing it.","format":"markdown","source":"ghsa"}],"published":"2023-02-01T18:48:06.000Z","modified":"2026-06-17T04:32:45.110Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:L","score":6.3,"rating":"MEDIUM"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:L","score":6.3,"rating":"MEDIUM"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:L","score":6.3,"rating":"MEDIUM"},{"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:H","score":8.8,"rating":"HIGH"},{"scorer":"Bitnami Vulnerability Database","scheme":"rating","rating":"HIGH"}],"cwes":["CWE-384","CWE-613"],"affected":[{"ranges":[{"version":">= 2.0.0, < 4.4.50","status":"affected"},{"version":">= 5.0.0, < 5.4.20","status":"affected"},{"version":">= 6.0.0, < 6.0.20","status":"affected"},{"version":">= 6.1.0, < 6.1.12","status":"affected"},{"version":">= 6.2.0, < 6.2.6","status":"affected"}],"vendor":"symfony","product":"symfony","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"2.0.0","status":"affected","fixed":"4.4.50"}],"ecosystem":"Packagist","package":"symfony/security-bundle","purl":"pkg:composer/symfony/security-bundle","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"5.0.0","status":"affected","fixed":"5.4.20"}],"ecosystem":"Packagist","package":"symfony/security-bundle","purl":"pkg:composer/symfony/security-bundle","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"6.0.0","status":"affected","fixed":"6.0.20"}],"ecosystem":"Packagist","package":"symfony/security-bundle","purl":"pkg:composer/symfony/security-bundle","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"6.1.0","status":"affected","fixed":"6.1.12"}],"ecosystem":"Packagist","package":"symfony/security-bundle","purl":"pkg:composer/symfony/security-bundle","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"6.2.0","status":"affected","fixed":"6.2.6"}],"ecosystem":"Packagist","package":"symfony/security-bundle","purl":"pkg:composer/symfony/security-bundle","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"2.0.0","status":"affected","fixed":"4.4.50"}],"ecosystem":"Packagist","package":"symfony/symfony","purl":"pkg:composer/symfony/symfony","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"5.0.0","status":"affected","fixed":"5.4.20"}],"ecosystem":"Packagist","package":"symfony/symfony","purl":"pkg:composer/symfony/symfony","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"6.0.0","status":"affected","fixed":"6.0.20"}],"ecosystem":"Packagist","package":"symfony/symfony","purl":"pkg:composer/symfony/symfony","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"6.1.0","status":"affected","fixed":"6.1.12"}],"ecosystem":"Packagist","package":"symfony/symfony","purl":"pkg:composer/symfony/symfony","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"6.2.0","status":"affected","fixed":"6.2.6"}],"ecosystem":"Packagist","package":"symfony/symfony","purl":"pkg:composer/symfony/symfony","source":"ghsa"},{"ranges":[{"status":"affected","introduced":"2.0.0","fixed":"4.4.50"},{"status":"affected","introduced":"5.0.0","fixed":"5.4.20"},{"status":"affected","introduced":"6.0.0","fixed":"6.0.20"},{"status":"affected","introduced":"6.1.0","fixed":"6.1.12"},{"status":"affected","introduced":"6.2.0","fixed":"6.2.6"}],"vendor":"sensiolabs","product":"symfony","cpe":"cpe:2.3:a:sensiolabs:symfony:*:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"type":"semver","introduced":"2.0.0","status":"affected","fixed":"4.4.50"},{"type":"semver","introduced":"5.0.0","status":"affected","fixed":"5.4.20"},{"type":"semver","introduced":"6.0.0","status":"affected","fixed":"6.0.20"},{"type":"semver","introduced":"6.1.0","status":"affected","fixed":"6.1.12"},{"type":"semver","introduced":"6.2.0","status":"affected","fixed":"6.2.6"}],"ecosystem":"Bitnami","package":"symfony","purl":"pkg:bitnami/symfony","source":"bitnami"}],"references":[{"url":"https://github.com/symfony/symfony/security/advisories/GHSA-3gv2-29qc-v67m","tags":["patch","third-party-advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","nvd","bitnami"]},{"url":"https://github.com/symfony/security-bundle/commit/076fd2088ada33d760758d98ff07ddedbf567946","tags":["patch","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd","bitnami"]},{"url":"https://github.com/symfony/symfony/commit/5909d74ecee359ea4982fcf4331aaf2e489a1fd4","tags":["patch","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd","bitnami"]},{"url":"https://github.com/FriendsOfPHP/security-advisories/blob/master/symfony/security-bundle/CVE-2022-24895.yaml","tags":["issue-tracking","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd","bitnami"]},{"url":"https://lists.debian.org/debian-lts-announce/2023/07/msg00014.html","tags":["web","x-transferred"],"sources":["cvelist","ghsa","nvd","bitnami"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-24895","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/FriendsOfPHP/security-advisories/blob/master/symfony/symfony/CVE-2022-24895.yaml","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/symfony/symfony","tags":["package"],"sources":["ghsa"]},{"url":"https://symfony.com/cve-2022-24895","tags":["web"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2025-03-10T20:58:32.328Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-24895","url":"https://www.cve.org/CVERecord?id=CVE-2022-24895","licence":"CVE Terms of Use","modified":"2025-03-10T21:16:31.513Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-3gv2-29qc-v67m","url":"https://github.com/advisories/GHSA-3gv2-29qc-v67m","licence":"CC-BY-4.0","modified":"2025-02-13T18:50:25.319Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-24895","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-24895","licence":"Public domain","modified":"2026-06-17T04:32:45.110Z"},{"source":"bitnami","name":"Bitnami Vulnerability Database","id":"BIT-SYMFONY-2022-24895","url":"https://osv.dev/vulnerability/BIT-SYMFONY-2022-24895","licence":"Apache-2.0","modified":"2024-03-06T11:25:28.861Z"}],"updatedAt":"2026-11-25T22:58:18.503Z","epss":{"score":0.00812,"percentile":0.5814,"date":"2026-12-01T12:00:22.000Z"}}