A vulnerability in MongoDB Database Tools mongofiles allows a user who can modify GridFS file metadata to cause file contents to be written to standard output instead of a local file during retrieval. This can lead to unauthorized disclosure of GridFS content if the output is captured in a location accessible to the attacker. Exploitation requires a higher-privileged operator to retrieve the file without specifying a local destination and attacker access to the captured output. The issue affects versions from 3.1.4 up to but not including 100.20.1.