LowGHSA-8f57-m8wj-x65wCVE-2026-123746

Symfony: Programmatic Logins Skip the checkPostAuth() Method of User Checkers

Published 1 Dec 2026 · Updated 1 Dec 2026

Affected packages

Affected
<5.4.56
Fixed in
5.4.56
Update to the fixed version for your release line, for example:composer require symfony/security-http:^5.4.56
Affected
>=6.0.0 <6.4.50
Fixed in
6.4.50
Update to the fixed version for your release line, for example:composer require symfony/security-http:^6.4.50
Affected
>=7.0.0 <7.4.23
Fixed in
7.4.23
Update to the fixed version for your release line, for example:composer require symfony/security-http:^7.4.23
Affected
>=8.0.0 <8.1.11
Fixed in
8.1.11
Update to the fixed version for your release line, for example:composer require symfony/security-http:^8.1.11
Affected
<5.4.56
Fixed in
5.4.56
Update to the fixed version for your release line, for example:composer require symfony/symfony:^5.4.56
Affected
>=6.0.0 <6.4.50
Fixed in
6.4.50
Update to the fixed version for your release line, for example:composer require symfony/symfony:^6.4.50
Affected
>=7.0.0 <7.4.23
Fixed in
7.4.23
Update to the fixed version for your release line, for example:composer require symfony/symfony:^7.4.23
Affected
>=8.0.0 <8.1.11
Fixed in
8.1.11
Update to the fixed version for your release line, for example:composer require symfony/symfony:^8.1.11

We confirm your address first. See our privacy policy.

Which symfony/security-http does your project really install?

Drop your composer.lock hereWe find the exact symfony/security-http version you install, even when another package pulls it in, and tell you if it’s affected and what to run. Free, no sign-up.

Works for private projects: the file is read in memory to run the scan and then dropped. Also reads composer.json.

Public repo?

Look after several Laravel or PHP apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie

Details

Description

Security::login() and UserAuthenticatorInterface::authenticateUser() log a user in programmatically, for example after a password reset or after an email verification link. The fix for CVE-2024-50341 made Security::login() call the checkPreAuth() method of the user checker of the firewall. But neither method ran checkPostAuth(): this method runs on the security.authentication.success event, which AuthenticatorManager::authenticateUser() did not dispatch.

As a consequence, an account that a user checker rejects in checkPostAuth(), such as an expired account, was refused by form login and the other authenticators of the firewall, but could still be logged in through these methods.

Applications are affected when they use a custom user checker that rejects users in checkPostAuth() and log users in programmatically. On 6.4 and up, the default user checker does nothing in checkPostAuth(). On 5.4, it rejects users of the deprecated User class whose credentials expired.

Resolution

AuthenticatorManager::authenticateUser() now dispatches the security.authentication.success event once the token is created and before it is stored, as authentications through the firewall do. checkPostAuth() runs on this event and can reject the user.

As a consequence, an exception thrown by checkPostAuth() now comes out of Security::login() and authenticateUser(). Code that logs users in programmatically, such as a registration controller, may need to catch it.

UserAuthenticatorInterface::authenticateUser() still doesn't call checkPreAuth(), on purpose. That's where checks like "the email isn't verified yet" usually are, and registration controllers use this method to log in users that just registered.

The patches for this issue are available here for branch 5.4 (and forward-ported to 6.4, 7.4, 8.1 and 8.2).

Credits

Symfony would like to thank Vincent Cassiau (CyberVanguard) for reporting the issue and Nicolas Grekas for providing the fix.

Symfony would also like to thank Bruno Dias from Checkmarx for their help getting a CVE assigned.

Is GHSA-8f57-m8wj-x65w in any of your client repos?

Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected symfony/security-http, and gives you the command that fixes it.

More advisories for symfony/security-http

  • HighCVE-2026-118513Symfony: X509Authenticator and X509AuthenticationListener Read Escaped RFC 2253 Commas and Bare Slashes Inside a DN Value as RDN Boundaries · 1 Dec 2026
  • HighCVE-2026-48489Symfony: Security Firewall Bypass via failure_forward Subrequest: Unauthenticated Access to access_control-Protected GET Routes · 15 Jun 2026
  • HighCVE-2026-45075Symfony's HEAD Request Bypasses methods: ['GET'] Filter in #[IsGranted] / #[IsSignatureValid] / #[IsCsrfTokenValid] · 27 May 2026
  • MediumCVE-2026-45074Symfony's Cas2Handler Derives CAS service URL from Client Host Header → Cross-Service Ticket Replay · 27 May 2026
  • MediumCVE-2026-45069Symfony's OidcTokenHandler Accepts JWTs Missing aud/iss/exp Claims · 27 May 2026
  • HighCVE-2026-45063Symfony Vulnerable to Identity Spoofing via Unanchored DN Regex in X509Authenticator · 27 May 2026
All 22 advisories for symfony/security-http

References

Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.