CVE-2026-142636 - Laravel: Sanctum guard can resolve the lowest-ID user when evaluated inside an eager-loaded Eloquent relation definition
Vulnerability · Reported by NVD · · CWE-863
- Severity
- Medium Risk score 68/100
- CVSS
- 6.8 v3.1 · from NVD
- Exploit chance (EPSS)
- – Not available yet
- Known exploited
- No Not in CISA KEV
Summary
Laravel is a web application framework. Prior to 12.73.0, When an authenticated user is first resolved while Eloquent is initializing an eager-loaded relation, Eloquent's relation constraints are temporarily disabled. A lazy key-constrained lookup made during that window, such as Sanctum's token owner lookup, runs without its key restriction. The guard can then return the lowest-ID user (often an administrator) instead of the token's owner. This affects applications that call the guard inside a relation definition used with eager loading, for example in optional-authentication routes. A low-privilege token could then read that user's data, and the wrong user remains cached for the rest of the request. Routes where authentication middleware resolves the user first were not affected in testing. This issue is fixed in version 12.73.0.
How this vulnerability can be exploited
This is a incorrect authorization flaw (CWE-863). An attacker can exploit this vulnerability remotely over the network, with a low-privileged account, and without any action from a user. Attack complexity is high, meaning specific conditions must exist first. If successful, the attacker could read sensitive data and modify data or code.
Is it being exploited?
There is no public evidence of active exploitation yet. Monitor for exploit releases, especially if the product is internet-facing.
Patch priority and what to do
Patch during routine updates. Lower severity, but keep it on your list. 1) Check whether you run the affected product and version. 2) Apply the vendor update or patch listed in the advisory. 3) Until patched, restrict network access to the service (firewall, VPN, WAF rules). 4) Review logs for signs of exploitation since the publication date.
CVSS vector
CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:N
Tags
CVE-2026-142636
Sources & references
- Original article / advisory (NVD) ↗
- NIST NVD: CVE-2026-142636 ↗
- CVE.org record ↗
- FIRST.org EPSS model ↗
How this data is collected: methodology & sources.