CVE-2026-18706 Use-After-Free in MongoDB $graphLookup Aggregation Stage Leads to Denial of Service and Potential Remote Code Execution

High 7.5 Published Updated

An authenticated user can trigger a use-after-free in the $graphLookup stage, causing server crashes or potential remote code execution.

Exploited in the wild
Not known
Login needed
An administrator
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2026-18706?

CVE-2026-18706 is a high-severity use after free vulnerability in Mongodb Mongodb, published on 11 Aug 2026. An attacker needs administrator access to exploit it, with no action from the victim.

Official description

An issue in MongoDB Server's $graphLookup aggregation stage could allow an authenticated user able to issue aggregation and memory-management commands to cause an internal reference to be used after the underlying memory has been freed. This could result in a server crash or, potentially, execution of unintended code.

Weakness: CWE-416

Which versions are affected by CVE-2026-18706?

1 open source package ship an affected version, including mongodb. It affects 1 product.

PackageAffectedFixed in
mongodb BitnamiFrom 8.3.08.3.8, 9.0.2

Products include Mongodb Mongodb.

How do I fix CVE-2026-18706?

Upgrade mongodb to a fixed version for your release line: 8.3.8 or 9.0.2.

Upgrade to the fixed version. These bugs are found with fuzzing and sanitisers and avoided by memory-safe languages. More about Use after free.

Is CVE-2026-18706 being exploited?

There is no known exploitation of CVE-2026-18706 in the wild and no public exploit code.

All Mongodb Mongodb vulnerabilities

Sources

Also known as BIT-mongodb-2026-18706, GHSA-pv5p-66r3-9fq9, MINI-mjcw-cj6g-3f47, UBUNTU-CVE-2026-18706.

Is CVE-2026-18706 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free