CVE-2026-88029: GridFS data disclosure and deletion via query-operator injection in file IDs in the MongoDB Python Driver
Improper neutralization of special elements in data query logic in the GridFS component of the MongoDB Python Driver can cause a caller-supplied structured file identifier to be interpreted as a query condition rather than as a literal identifier. An authenticated user who can influence the identifier passed by an affected application may obtain stored file content beyond the intended target or cause all GridFS file chunks in the affected bucket to be removed, rendering stored file content unreadable. The affected rename operation may also rename a stored file other than the intended target.
Affected Software
Event History
Frequently Asked Questions
Who is exposed to this issue?
Applications using the MongoDB Python Driver's GridFS component are exposed if an authenticated user can influence the file identifier passed into affected GridFS operations. The attacker does not need user interaction and can exploit the issue remotely through the application.
What could an attacker do with control of a GridFS file identifier?
A structured identifier can be interpreted as a query condition instead of a literal ID. This may allow access to file content beyond the intended file, deletion of all file chunks in the affected bucket so stored content becomes unreadable, or renaming a different stored file.
How can we tell whether our application is at risk?
Review application paths that pass caller-controlled values as GridFS file identifiers, particularly operations that read, delete, or rename files. Risk exists when those values can be structured rather than being constrained to a literal identifier before they reach GridFS.