CVE-2026-135139: Incorrect authorization in has_many delete_all in Mongoid
Mongoid contains an incorrect authorization weakness in the handling of caller-supplied filters for bulk removal through a referenced association. Conditions already attached to the association can take precedence over the filter the caller supplied, so records the caller did not select may be removed. A user with basic privileges in an application built on the library may cause unintended removal of records belonging to the same parent record.
Affected Software
Event History
Frequently Asked Questions
Which applications are exposed to unintended record deletion?
Applications built on Mongoid are exposed when they perform bulk removal through a referenced association using caller-supplied filters. The issue applies where conditions already attached to that association can override or take precedence over the caller's intended selection.
What level of access would an attacker need?
An attacker needs basic privileges in the application. No user interaction is required according to the supplied severity vector.
How far can unintended deletions extend?
The described impact is removal of records that the caller did not select but that belong to the same parent record. The provided data does not indicate deletion across different parent records.