Skip to content
AI Security Wire

Published

- 8 min read

By

MONAI Label CVE-2026-133968: How an Image ID Became Code Execution

img of MONAI Label CVE-2026-133968: How an Image ID Became Code Execution

MONAI Label, an open-source server for annotating medical images with AI assistance, shipped with authentication off by default and an upload endpoint that trusted the caller’s image ID as part of a file path. CVE-2026-133968 is the result: through version 0.8.5, a request to PUT /datastore/image could write a file outside the datastore, and a file write on a Python server is a short step from code execution. CISA added the flaw to its Known Exploited Vulnerabilities (KEV) catalog on 23 November 2026. This article walks through the mechanism, the evidence of exploitation and what the 0.8.6 fix changes. For the intrusion in which AI agents used the flaw against a university server, see our incident report on Amazon’s Cairn findings.

Background

MONAI Label is part of Project MONAI, an open-source medical imaging AI ecosystem. The server stores images and labels in a datastore on disk, serves them to clients such as 3D Slicer and OHIF, and exposes training and inference endpoints. It is research software; where it is deployed is not something the sources describe, but the AWS case involved a university server.

Two defaults matter here. The 0.8.6 release notes state that authentication is disabled by default (MONAI_LABEL_AUTH_ENABLE=False), so the affected endpoints were reachable by any client that can connect to the server. The project advisory adds that with authentication enabled, the ANNOTATOR role is sufficient to reach the endpoint.

Technical Mechanism

The CVE record, assigned by MITRE as CNA, describes the bug as directory traversal “via the image parameter to the PUT /datastore/image endpoint” in monailabel before 0.8.6. Its weakness class is CWE-24, path traversal using ../filedir.

We compared this with the 0.8.5 source on GitHub. The flow, as we read it:

  1. The endpoint takes an optional image query parameter. If present, it becomes the image ID unchanged; if absent, the ID is derived from the uploaded file’s base name.
  2. The datastore’s add_image builds a file name by concatenating the ID and the file extension (id + ext).
  3. It then joins that name onto the datastore’s image directory and resolves it with os.path.realpath, and copies the uploaded file to that destination.

Because realpath only normalises the path and nothing compared the result with the datastore directory, an ID such as ../../some/dir/name resolves to a location outside it. The file content is the uploaded body, so the attacker controls both where the file lands and what it contains. The extension comes from the upload’s file name, which the caller also supplies. The release notes say the label endpoint had the same problem, building its path from the label tag.

From file write to code execution

A file write becomes code execution when the written file is something the server later runs. Amazon Threat Intelligence describes one such route in its report: writing a Python reverse shell to sitecustomize.py, which Python imports on interpreter start, then calling a training API endpoint that spawned a new Python process, which loaded the payload and opened a root reverse shell. AWS says only that the payload was written to sitecustomize.py; that chain needed the server process to be able to write to a location Python imports from (our inference) and a training endpoint that starts new Python processes. The advisory describes other routes, since a write can land “any location the process can write”, such as application code, authorized_keys or cron entries; which of these apply depends on the host.

The Fix in 0.8.6

Pull request 1915 adds confinement. From the patch:

  • A helper resolves both the destination and the allowed base with realpath and raises an error unless os.path.commonpath of the two equals the base.
  • The endpoint reduces the image ID to its base name and returns HTTP 400 for empty IDs, ., .. and IDs starting with a dot.

The release also fixes a second, separate issue: PUT /session/?uncompress=true extracted uploaded tar archives without checking member names, and session IDs were used as paths without validation (pull request 1942). Release 0.8.6 also rejects tar archives containing links or device files. The session-upload fix is a separate issue from CVE-2026-133968; check that you upgrade for both.

Real-World Exploitation Evidence

  • CISA KEV: the feed (catalogVersion 2026.11.30, released 30 November 2026) lists CVE-2026-133968 as “Project MONAI MONAI Label Path Traversal Vulnerability”, added 2026-11-23, due 2026-11-26. Its short description says an unauthenticated remote attacker can write arbitrary files outside the intended datastore directory. Known ransomware campaign use is listed as “Unknown”.
  • CISA SSVC: the CISA-ADP entry, timestamped 24 November 2026, lists Exploitation as active, Automatable as yes and Technical Impact as total.
  • CVE record: says the flaw was “exploited in the wild starting in September 2026”.
  • Amazon Threat Intelligence: reports that AI agents in the Cairn framework found and exploited a path traversal in “an open-source medical imaging AI application” with an upload endpoint and a “filename parameter”, assessed with high confidence as a zero-day, with attribution to a Chinese-nexus actor at moderate confidence. AWS’s post does not name MONAI Label or a CVE. The product name comes from The Register’s coverage, and the CVE record cites the AWS post in its references. The CVE record names the image parameter where AWS says “filename parameter”. AWS does not date the MONAI session itself; the 8 to 10 September dates are for the campaign. The advisory says the flaw was originally reported by @aws-sec-vdp (that this is AWS’s disclosure account is our inference). AWS is the only source for the campaign.

Impact Assessment

In the default configuration (authentication off), a successful request lets any network client that can reach the server write a chosen file with the server’s privileges; with authentication on, an ANNOTATOR credential is enough (advisory). On a server running as root, as the AWS case did, that means full host compromise. AWS reports that the actor later used a proxy into a second university network whose server ran the same software, so our assessment is that lateral movement is a realistic concern, not only the one host. Medical imaging deployments may also hold patient-derived data, though the sources we reviewed do not say what, if anything, was taken.

Affected Versions

ComponentStatus
monailabel through 0.8.5Affected (release notes; CVE record says before 0.8.6)
monailabel 0.8.6Fixed, security release published 22 November 2026
Docker image projectmonai/monailabel:0.8.6Fixed, per release notes

PyPI listed 0.8.8 as the newest release when we checked on 2 December 2026; any release at or above 0.8.6 includes the fix, as far as we can tell from the release notes, which we did not test against later versions.

Remediation Steps

  1. Upgrade: pip install -U monailabel==0.8.6 or a later release, or pull projectmonai/monailabel:0.8.6.
  2. Keep the server off untrusted networks, as the project advises.
  3. Enable authentication (MONAI_LABEL_AUTH_ENABLE=True) and grant roles only to trusted users.
  4. Run the server as an unprivileged user whose write access is limited to the datastore.
  5. Check your Python version first: the release notes say 0.8.6 drops Python 3.9 and 3.10, and PyPI lists Python 3.11 or newer as required.
  6. If a 0.8.5 or older server was reachable from an untrusted network, review it for unexpected file changes before returning it to service, as the release notes advise. CISA’s KEV entry flags forensic triage as required.

Detection Guidance

These are our suggestions, not from the vendor:

  • Search web or reverse-proxy logs for PUT /datastore/image and PUT /datastore/label requests whose image or tag value contains .., %2e%2e or path separators.
  • Look for a sitecustomize.py or other unexpected recently modified files in Python site-packages directories on MONAI Label hosts.
  • Alert on Python child processes started by the training endpoint that make outbound network connections.
  • AWS lists two addresses seen in records dated 8 to 10 September 2026: 142[.]4.98.145 and 142[.]4.107.34. AWS does not state their role, so use them for hunting, not attribution.

Timeline

DateEvent
8 to 10 September 2026Cairn-driven activity against university servers, per AWS
19 October 2026Pull request 1915 (the fix) merged, per GitHub
20 November 2026CVE record published; AWS publishes its report
22 November 2026MONAI Label 0.8.6 security release published
23 November 2026CISA adds CVE-2026-133968 to KEV (due date 26 November)
24 November 2026CISA-ADP SSVC entry lists active exploitation

Severity and Score Provenance

The 9.8 Critical CVSS 3.1 score (AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H) is set by the CNA, MITRE. NVD, which has the record as Analyzed, shows it as a Secondary score from [email protected] and, when we checked on 2 December 2026, showed no NVD-primary score. The release notes also describe the issue as critical. The GHSA calls the issue Critical without a score and lists CWE-22, while the CVE record and NVD list CWE-24. The advisory is linked below.

References

Frequently Asked Questions

What exactly is the flaw in MONAI Label?
In versions through 0.8.5, the upload endpoints PUT /datastore/image and PUT /datastore/label built the destination path from a caller-supplied image ID and label tag without confining it to the datastore. A caller could therefore write a file anywhere the server process can write. The CVE record classifies it as CWE-24 and says it leads to remote code execution.
Is CVE-2026-133968 in CISA's KEV catalog?
Yes. The CISA KEV feed (catalogVersion 2026.11.30) lists it with a dateAdded of 2026-11-23 and a dueDate of 2026-11-26, and the entry describes an unauthenticated remote attacker writing arbitrary files outside the datastore directory.
Which version fixes it?
MONAI Label 0.8.6, published on GitHub on 22 November 2026, is the security release that fixes it (pull request 1915). The project's release notes say all server deployments should upgrade, and also list a separate path traversal in session upload fixed in the same release.
Is upgrading enough?
The project's advice is to upgrade and also to keep the server off untrusted networks, enable authentication and run it as an unprivileged user limited to the datastore. It adds that a 0.8.5 or older server reachable from an untrusted network should be reviewed for unexpected file changes before it returns to service.