On December 3, 2025, the JFrog security research team revealed the discovery of three critical zero-day vulnerabilities in PickleScan, a widely adopted open-source tool for detecting malicious Python pickle files. These vulnerabilities carry a CVSS score of 9.3 (Critical) and introduce a severe software supply chain risk for the Artificial Intelligence and Machine Learning (AI/ML) ecosystem. An attacker can exploit these flaws to create a malicious AI model, often used with the PyTorch framework, that PickleScan will incorrectly flag as safe. When an unsuspecting developer or organization loads this trojanized model, it can trigger arbitrary code execution on their system. This attack vector allows for the covert distribution of malware through public model repositories, bypassing a key security control in the MLOps pipeline.
The vulnerabilities lie in the logic of PickleScan itself. The tool is designed to statically analyze a pickle file—a common format for serializing Python objects, heavily used for saving and loading AI models—to identify dangerous opcodes that could lead to code execution. The flaws discovered by JFrog represent bypass techniques, where a specially crafted pickle file can be constructed to appear benign to PickleScan's scanner while still containing a malicious payload that is executed upon deserialization by a standard Python pickle loader.
This creates a dangerous gap in the security supply chain: an organization may believe it is safely handling untrusted models by scanning them with PickleScan, but in reality, it remains vulnerable to exploitation. The end result is arbitrary code execution on the machine that loads the model, which could be a developer's workstation, a training server, or a production inference server.
pickle files or PyTorch models (.pt files).This is not a vulnerability in PyTorch itself, but in a security tool designed to protect its users. However, the vast popularity of PyTorch makes the impact of a faulty scanner particularly widespread.
These are zero-day vulnerabilities, meaning they were not publicly known before JFrog's disclosure and no patches were available at the time of announcement. While there is no public evidence of active exploitation in the wild, the disclosure of the technical details means that threat actors could quickly weaponize these bypass techniques. The risk is especially high for organizations that automatically pull and deploy models from public repositories like Hugging Face.
This vulnerability represents a critical threat to the security of the AI/ML software supply chain. A successful exploit could lead to:
This undermines the trust in shared AI models and highlights the immaturity of security tooling in the rapidly evolving MLOps space.
D3-DA: Dynamic Analysis.safetensors.Loading untrusted AI models in a sandboxed, isolated environment is the most effective way to contain potential code execution.
Be highly selective about the sources of AI models, preferring official, signed models from trusted repositories over unverified ones.
Since static analysis with PickleScan is proven to be unreliable, organizations must shift to dynamic analysis for untrusted models. Before a model is used, it should be loaded in a secure, isolated sandbox (e.g., a minimal Docker container with gVisor or a dedicated VM). This environment should have networking disabled and strict file system permissions. Monitor the deserialization process for any suspicious system calls, file I/O, or process creation attempts. If the model loading process triggers any behavior beyond expected memory allocation and computation, it should be flagged as malicious and rejected. This approach moves from trusting a scanner's verdict to a 'distrust and verify' model for AI supply chain security.
A key strategic mitigation is to reduce reliance on the inherently unsafe pickle format. Development and MLOps teams should prioritize migrating to safer model serialization formats like safetensors. This format is designed specifically to prevent arbitrary code execution during loading. Mandate the use of safetensors in your organization's MLOps policies for all new models. For existing models, create a plan to convert them. While this is a longer-term effort, it addresses the root cause of the problem rather than just trying to detect malicious pickles. It hardens the application stack against an entire class of vulnerability.

Cybersecurity professional with over 10 years of specialized experience in security operations, threat intelligence, incident response, and security automation. Expertise spans SOAR/XSOAR orchestration, threat intelligence platforms, SIEM/UEBA analytics, and building cyber fusion centers. Background includes technical enablement, solution architecture for enterprise and government clients, and implementing security automation workflows across IR, TIP, and SOC use cases.
Help others stay informed about cybersecurity threats