Vulnerability · Published Feb 21, 2023 · Assigned by mongodb
CVE-2022-48282Deserializing compromised object with MongoDB .NET/C# Driver may cause remote code execution
Medium 6.6
In plain English
A medium-severity unsafe deserialization in MongoDB .NET/C# Driver from MongoDB Inc. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 1.4% (higher than 72% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
Under very specific circumstances (see Required configuration section below), a privileged user is able to cause arbitrary code to be executed which may cause further disruption to services. This is specific to applications written in C#. This affects all MongoDB .NET/C# Driver versions prior to and including v2.18.0 Following configuration must be true for the vulnerability to be applicable: * Application must written in C# taking arbitrary data from users and serializing data using _t without any validation AND * Application must be running on a Windows host using the full .NET Framework, not .NET Core AND * Application must have domain model class with a property/field explicitly of type System.Object or a collection of type System.Object (against MongoDB best practice) AND * Malicious attacker must have unrestricted insert access to target database to add a _t discriminator."Following configuration must be true for the vulnerability to be applicable
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| NuGet | mongodb.driver | 2.19.0 | GHSA-7j9m-j397-g4wx |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| MongoDB Inc | MongoDB .NET/C# Driver | 0 – through v2.18.0 |
Weakness: CWE-502 · Vector: CVSS:3.1/AV:N/AC:H/PR:H/UI:N/S:U/C:H/I:H/A:H