You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
MongoDB: enforce Safe Mode reads in the plugin host, not only in the classifier #3293
Safe Mode and read-only external clients trust the MongoDB classifier's read verdict since #3292. The verdict covers the statement text, not the shell it runs in.
The plugin keeps one JavaScript context per connection (MongoScriptRuntime).
A statement Safe Mode allowed as a write can redefine a prelude function, for example DBCollection.prototype.find = DBCollection.prototype.drop.
A later db.users.find({}) then passes as a read and drops the collection, at Read-Only or for a read-only MCP token, until reconnect.
Fix: carry read-only intent to the driver (a PluginKit addition with a default) and have MongoScriptHost.perform refuse write ops and $out/$merge pipelines for a statement sent as a read. Needs a plugin-mongodb release.
Activity