Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessCraft pickle invoking ShapeEnv.evaluate_guards_expression
-
DeliveryPublish/deliver malicious model file
-
ExploitBypass picklescan (<0.0.28) scan as clean
-
ExecutionVictim unpickles trusted-looking model
-
ImpactExecute arbitrary code on victim host
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A08:2025 - Software or Data Integrity Failures
ASVS 5.0
V1 - Encoding and Sanitization Safe deserialization, type allowlists
MITRE ATT&CK
2 techniques across 2 tactics: Execution, Initial Access The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires that the victim uses picklescan (any version before 0.0.28) as their safety check on an untrusted pickle/model file AND then deserializes that file (UI:P), typically via PyTorch, so that the embedded torch.fx.experimental.symbolic_shapes.ShapeEnv.evaluate_guards_expression call runs. The specific technical prerequisite is a pickle crafted to invoke that exact function, which the pre-0.0.28 denylist does not recognize. Limiting factors: no code runs from scanning alone - the malicious file must actually be loaded/unpickled; the PyTorch (torch.fx) gadget must be importable in the victim's environment; and the attacker gains nothing against users who avoid pickles or use safetensors. There is no authentication requirement on the attacker side (PR:N) since the attack is delivered as a file, but exploitation is gated entirely on victim-side actions rather than a directly reachable service. |
| Impact | The supplied CVSS 4.0 vector (AV:N/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:N, base 7.6) is internally consistent with a supply-chain scanner bypass: network delivery of a malicious model, no privileges, but two real dampeners - AT:P (a specific attack requirement, i.e. the victim must actually use picklescan as their gate and then unpickle the file) and UI:P (the victim must load the file). No EPSS score was provided, this CVE is not in CISA KEV, and no proof-of-concept is referenced, so all real-world-exploitation signals are absent - the risk is currently theoretical/technique-level rather than evidence of active campaigns. The nuance that raises priority despite this is that picklescan is a security control: its failure silently converts a 'scanned and clean' verdict into false assurance, which is exactly the kind of gap targeted attackers seeking ML supply-chain footholds would exploit. Net: patch-worthy for anyone relying on picklescan as a gate, but not an emergency drop-everything issue absent exploitation evidence. |
| Exploit ScenarioDerived | An attacker publishes a poisoned PyTorch model to a model hub or sends it to a victim who runs it through picklescan (< 0.0.28) first; the file embeds a ShapeEnv.evaluate_guards_expression call that the scanner does not flag, so the model is reported clean. When the victim subsequently loads the model with torch/pickle, the embedded code executes on their machine. No public proof-of-concept is referenced, and success requires the victim to both rely on picklescan and then deserialize the file (UI:P/AT:P). |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jul 04, 2026
Security scanner bypass in picklescan before 0.0.28 allows attackers to smuggle arbitrary code past the tool's malware detection by abusing torch.fx.experimental.symbolic_shapes.ShapeEnv.evaluate_guards_expression, which is not on picklescan's dangerous-globals blocklist. Because picklescan is a defensive tool used to vet untrusted ML pickle files (notably in the Hugging Face ecosystem), a bypass causes a malicious model to be marked safe and then execute remote code when the victim deserializes it. There is no public exploit identified at time of analysis and this CVE is not listed in CISA KEV, but the technique is fully described in the VulnCheck advisory.
RemediationAI
Upgrade picklescan to version 0.0.28 or later, which adds detection for the torch.fx.experimental.symbolic_shapes.ShapeEnv.evaluate_guards_expression gadget (Vendor-released patch: 0.0.28); see GHSA-f4x7-rfwp-v3xw. Because this is a denylist-completeness bug, treat picklescan's verdict as advisory rather than authoritative: where feasible, avoid loading untrusted pickles entirely and prefer non-executable serialization such as safetensors for model weights, which eliminates the deserialization code-execution class rather than merely scanning for it. As compensating controls until every scanning host is upgraded, unpickle untrusted files only inside a sandboxed/network-isolated process with least privilege so that a bypass yields no useful execution context, and quarantine or re-scan already-ingested models that passed an older picklescan version - the trade-off is added pipeline latency and, for safetensors migration, re-exporting existing model artifacts.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in pypi
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
picklescan is a Python static-analysis utility that inspects Python pickle streams for references to dangerous callables (globals) before a user unpickles an untrusted file, a common defense for machine-learning model files (.pt/.bin/.pkl) that are natively pickle-serialized. CWE-502 (Deserialization of Untrusted Data) is the root class: Python's pickle can invoke arbitrary importable callables during load via REDUCE/GLOBAL opcodes. picklescan works from a denylist of known-dangerous functions, and this flaw is a denylist gap - torch.fx.experimental.symbolic_shapes.ShapeEnv.evaluate_guards_expression evaluates attacker-controllable expressions but was not recognized as dangerous, so pickles invoking it pass the scan yet still achieve code execution when loaded through PyTorch. The affected component is picklescan itself (cpe:2.3:a:picklescan:picklescan), not PyTorch; PyTorch is merely the vehicle supplying the abusable gadget.
Know when Picklescan gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N
Network-delivered malicious file with high confidentiality/integrity impact, but AC:H and UI:R because success depends on the victim relying on picklescan and then unpickling the file.
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
Lifecycle Timeline
1DescriptionCVE.org
picklescan before 0.0.28 fails to detect malicious torch.fx.experimental.symbolic_shapes.ShapeEnv.evaluate_guards_expression function calls in pickle files. Attackers can embed undetected code in pickle files that executes remote code when loaded by victims.
Executive ViewAI
Picklescan, a defensive security tool widely used to vet untrusted ML models in the Hugging Face ecosystem and beyond, contains a bypass vulnerability allowing attackers to smuggle malicious code past detection. Models crafted to exploit this bypass will be marked safe by picklescan but execute remote code when deserialized, converting a security control into a supply-chain attack vector. Organizations using picklescan as a primary security gate for external model validation require immediate compensating measures.
No vendor-released patch identified at time of analysis. Interim mitigations: disable picklescan for untrusted external models; substitute with manual pickle file inspection or alternative scanning tools; require sandboxed evaluation environments for external models before production use; establish strict source-verification policies for ML model acquisition; implement network segmentation to limit RCE lateral movement; monitor ML inference pipeline executions for anomalous behavior and unauthorized network connections.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Insecure deserialization occurs when an application converts serialized data (a stream of bytes representing an object's state) back into a living object without proper validation.
Related Vulnerabilities in picklescan Malicious Pickle Detection Bypass
View all 16More in Picklescan
View allRemote code execution against users of picklescan versions prior to 1.0.4 is achievable by smuggling any blocked functio
An Improper Handling of Exceptional Conditions vulnerability in the ZIP archive scanning component of mmaitre314 pickles
A Protection Mechanism Failure vulnerability in mmaitre314 picklescan versions up to and including 0.0.30 allows a remot
An Improper Input Validation vulnerability in the scanning logic of mmaitre314 picklescan versions up to and including 0
Detection bypass in picklescan prior to 0.0.29 allows attackers to smuggle remote code execution payloads through pickle
Detection bypass in picklescan versions before 0.0.25 allows attackers to embed remote code execution payloads in pickle
Detection bypass in picklescan before 0.0.28 allows attackers to embed malicious torch.jit.unsupported_tensor_ops.execWr
Detection bypass in picklescan before 0.0.28 allows attackers to smuggle arbitrary code through pickle files by abusing
Detection bypass in picklescan before 0.0.29 allows malicious pickle files to evade scanning by abusing the undetected i
Detection bypass in picklescan versions before 0.0.30 allows malicious pickle files to evade security scanning by using
Detection bypass in picklescan versions prior to 0.0.29 allows attackers to smuggle arbitrary code execution payloads th
Detection bypass in picklescan before 0.0.33 allows attackers to smuggle arbitrary code through malicious pickle files b
EUVD-2025-210415
GHSA-gpmh-464g-j3r8
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB