Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-111212 Overview
CVE-2026-111212 is a code injection vulnerability [CWE-94] in ImprintLab Medical-SAM-Adapter versions 0.1.0-alpha and 0.1.0. The flaw resides in the session.get_modelmeta.custom_metadata_map function inside models/MobileSAMv2/ultralytics/nn/autobackend.py, part of the AutoBackend Model Loading component. Attackers can manipulate the imgsz, names, or kpt_shape arguments to inject directives that are improperly neutralized during dynamic code evaluation. Exploitation requires local access and user interaction. A public exploit exists, and the project maintainers have not yet responded to the disclosure.
Critical Impact
Local attackers can execute arbitrary code within the Medical-SAM-Adapter process by supplying crafted model metadata that is evaluated at load time.
Affected Products
- ImprintLab Medical-SAM-Adapter 0.1.0-alpha
- ImprintLab Medical-SAM-Adapter 0.1.0
- MobileSAMv2 AutoBackend model loader component
Discovery Timeline
- 2026-10-16 - CVE-2026-111212 published to the National Vulnerability Database
- 2026-10-16 - Last updated in NVD database
Technical Details for CVE-2026-111212
Vulnerability Analysis
The vulnerability lives in the AutoBackend model loader that handles serialized model metadata when a Medical-SAM-Adapter session loads a model file. The custom_metadata_map logic within session.get_modelmeta processes the imgsz, names, and kpt_shape attributes retrieved from the model artifact. These values are passed into a dynamic evaluation routine without proper neutralization of embedded directives. Any attacker able to supply or substitute a model file consumed by the loader can embed Python expressions in those metadata fields and have them executed in the host process. Because the loader runs with the same privileges as the invoking user, successful exploitation yields local code execution within the machine learning workflow.
Root Cause
The root cause is improper neutralization of directives in dynamically evaluated code [CWE-94]. Metadata read from the model artifact is forwarded to a dynamic evaluation primitive without input validation, allow-listing, or safe parsing. Trusting attacker-controllable serialized attributes as safe code input is the central defect.
Attack Vector
The attack vector is local and requires user interaction. An attacker places or distributes a malicious model file and persuades a user to load it through the Medical-SAM-Adapter session. The crafted imgsz, names, or kpt_shape entries are evaluated during AutoBackend initialization, triggering arbitrary code execution.
// No verified exploit code is published alongside this advisory.
// Refer to the external references for technical details on the
// vulnerable metadata fields and loading path.
Stop Remote Code Execution Before It Runs
Singularity™ Endpoint detects and blocks exploit attempts at machine speed, including zero-days and novel attack techniques.
Stop Exploit AttemptsDetection Methods for CVE-2026-111212
Indicators of Compromise
- Unexpected child processes spawned by Python interpreters executing Medical-SAM-Adapter or MobileSAMv2 workflows.
- Model files sourced from untrusted locations whose metadata attributes (imgsz, names, kpt_shape) contain Python expressions or non-standard string encodings.
- Outbound network connections initiated by the model loading process shortly after invocation of AutoBackend.
Detection Strategies
- Inspect model artifacts prior to loading and flag entries where imgsz, names, or kpt_shape deviate from expected numeric or list structures.
- Instrument the Python runtime to log calls to dynamic evaluation primitives originating from autobackend.py.
- Correlate process-execution telemetry from data science hosts with model load events to identify anomalous command execution.
Monitoring Recommendations
- Monitor file integrity on directories that store MobileSAMv2 model weights and metadata.
- Alert on process lineage where a Python machine learning job spawns shells, interpreters, or network utilities.
- Capture command-line arguments for all Medical-SAM-Adapter sessions to retain forensic context.
How to Mitigate CVE-2026-111212
Immediate Actions Required
- Restrict Medical-SAM-Adapter usage to trusted operators and isolate loading hosts from production networks.
- Load only model files obtained from verified sources with cryptographic checksums.
- Review the GitHub Issue #145 tracking the report for any maintainer updates.
Patch Information
No vendor patch is available at the time of publication. The project was notified through an issue report but has not responded. Consult the ImprintLab Medical-SAM-Adapter repository and VulDB CVE-2026-111212 entry for status updates.
Workarounds
- Run Medical-SAM-Adapter inside a sandboxed container or virtual machine without access to credentials or sensitive data.
- Pre-validate model metadata with a safe parser (for example, ast.literal_eval) before invoking the AutoBackend loader.
- Apply least-privilege execution for the user account running model loading tasks and disable outbound network access where feasible.
# Example container isolation for untrusted model loading
docker run --rm \
--network none \
--read-only \
--user 1000:1000 \
-v /models:/models:ro \
medical-sam-adapter:isolated
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

