News · 10 November 2026

Laravel TokenGuard authentication bypass: update to 12.68 or 13.29

In October 2026 Laravel published a critical advisory, CVE-2026-114509 (CVSS 9.2): an authentication bypass in TokenGuard, the simple token-based guard that Laravel offers for API routes.

What it is. According to the advisory, when TokenGuard is configured as a standard token-based API guard, it can be bypassed to authenticate as an arbitrary existing user without knowing that user's API token. Under certain database configurations (MySQL or MariaDB) an attacker can submit a specially crafted, non-string credential that is mishandled during the lookup, so the query matches an unintended user record instead of failing. The impact is account takeover on any route protected by the affected guard, without authentication.

Who is affected. Applications that use TokenGuard (for example routes under auth:api that read an api_token) on laravel/framework before 12.68.0, and on Laravel 13 before 13.29.0. The advisory does not mention Sanctum or Passport, which use their own guards; check your configuration in config/auth.php to be sure.

What to do.

  1. Open config/auth.php and look at the driver of each guard. If you see token, you are using TokenGuard.
  2. Update laravel/framework to 12.68.0 or 13.29.0 or later, and deploy.
  3. If you cannot update straight away, limit those routes to trusted networks with a firewall or proxy rule.
  4. Look at your API logs since October for requests whose token field is not a plain string, and for logins as users who were not active.
  5. Consider replacing TokenGuard. It is a basic mechanism, with tokens stored as they are. Sanctum gives hashed tokens, abilities and expiry.

If your project is on an older major version, no fix will arrive for it: Laravel 13 is current and 12 receives only security fixes.

Sources:

All news