CVE-2024-51996: Authentication Bypass via persisted RememberMe cookie
Description
When consuming a persisted remember-me cookie, Symfony does not check if the username persisted in the database matches the username attached with the cookie, leading to authentication bypass.
Resolution
The PersistentRememberMeHandler class now ensures the submitted username is the cookie owner.
The patch for this issue is available here for branch 5.4.
Credits
We would like to thank Moritz Rauch - Pentryx AG for reporting the issue and Jérémy Derussé for providing the fix.
Other sources
CVE-2024-51996: Authentication Bypass via persisted RememberMe cookie
— Packagist
Symphony process is a module for the Symphony PHP framework which executes commands in sub-processes. When consuming a persisted remember-me cookie, Symfony does not check if the username persisted in the database matches the username attached with the cookie, leading to authentication bypass. This vulnerability is fixed in 5.4.47, 6.4.15, and 7.1.8.
— NVD
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
composer/symfony/security-httpto a version that resolves this vulnerability.Fixed in 7.1.8 - Upgrade
Upgrade
composer/symfony/security-httpto a version that resolves this vulnerability.Fixed in 6.4.15 - Upgrade
Upgrade
composer/symfony/security-httpto a version that resolves this vulnerability.Fixed in 5.4.47 - Upgrade
Upgrade
composer/symfony/symfonyto a version that resolves this vulnerability.Fixed in 5.4.47 - Upgrade
Upgrade
composer/symfony/symfonyto a version that resolves this vulnerability.Fixed in 6.4.15 - Upgrade
Upgrade
composer/symfony/symfonyto a version that resolves this vulnerability.Fixed in 7.1.8 - Upgrade
Upgrade
debian/symfonyto a version that resolves this vulnerability.Fixed in 5.4.23+dfsg-1+deb12u4 - Upgrade
Upgrade
debian/symfonyto a version that resolves this vulnerability.Fixed in 6.4.15+dfsg-1 - Upgrade
Upgrade
debian/symfonyto a version that resolves this vulnerability.Fixed in 5.4.53+dfsg-0+deb12u1Fixed in 6.4.41+dfsg-0+deb13u1Fixed in 6.4.50+dfsg-0+deb13u1Fixed in 7.4.23+dfsg-1 - Upgrade
Upgrade
Symfonyto a version that resolves this vulnerability.Patch 81354d392c5f0b7a52bcbd729d6f82501e94135a
Event History
Frequently Asked Questions
What is the severity of CVE-2024-51996?
CVE-2024-51996 is classified as a high severity vulnerability due to its potential for authentication bypass.
How do I fix CVE-2024-51996?
To resolve CVE-2024-51996, upgrade the symfony/security-http package to version 7.1.8, 6.4.15, or 5.4.47.
What causes CVE-2024-51996?
CVE-2024-51996 is caused by Symfony not verifying if the username in a persisted remember-me cookie matches the username in the database.
Which versions of Symfony are affected by CVE-2024-51996?
Versions of Symfony between 7.0.0-BETA1 and 7.1.8, 6.0.0-BETA1 and 6.4.15, and 5.3.0 and 5.4.47 are affected by CVE-2024-51996.
Is CVE-2024-51996 a persistent vulnerability?
Yes, CVE-2024-51996 is considered persistent as it affects the functioning of persisted remember-me cookies in Symfony.