CVE-2026-135145: MongoDB PHP Driver

High severity, CVSS 8.1. EPSS: 0.6% probability of exploitation activity in the next 30 days.

A polymorphic relationship query helper in the MongoDB Eloquent integration for Laravel resolves a record's type identifier inconsistently between the code that stores a relationship link and the code that searches for one. An application that relies on a relationship-absence query to restrict which records a request may see or change can therefore have that restriction silently fail, allowing a user with basic application privileges to read and to modify or remove records the restriction was meant to cover.

What to do

The record states a fixed version for the versions it affects. If you run one, update to it.

  • MongoDB PHP Driver, from 4.1.0, before 5.12.2: fixed in 5.12.2

Affected products

Published 2026-11-25. Last modified 2026-11-25.