CVE-2025-10157: mmaitre314 PickleScan protection bypass via subclass imports

CVE-2025-10157 · Severity: high · CVSS 8.3 · Published 2025-09-10

PickleScan is a security tool used to scan Python pickle files and AI models for malicious code. A vulnerability in its scanning logic allows attackers to bypass security checks by using specific module naming techniques. If a user scans a specially crafted malicious model, the tool may fail to detect the threat, potentially leading to the execution of unauthorized code on the user's system.

Technologies: picklescan (PyPI). Vendors: PyPI.

Quick answers

Is CVE-2025-10157 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2025-10157 being exploited in the wild.
How severe is CVE-2025-10157?
High severity, with a CVSS score of 8.3, published 10 September 2025.
Which products and versions are affected?
picklescan (PyPI) <= 0.0.30, ECOSYSTEM:introduced=0,fixed=0.0.31.
Is there a fix for CVE-2025-10157?
Yes. picklescan (PyPI): upgrade to 0.0.31 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2025-10157 attacked?
It is attacked over the network, in a software library.
Am I affected by CVE-2025-10157?
Check whether you run picklescan (PyPI) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • picklescan (PyPI): upgrade to 0.0.31 or later
    pip install "picklescan>=0.0.31"

Technical details

PickleScan (up to version 0.0.30) is vulnerable to a protection mechanism failure (CWE-693) in its unsafe globals check. The scanner performs a strict string match against full module names in its '_unsafe_globals' list. Attackers can bypass this by using submodules or subclasses of dangerous imports (e.g., specific sub-events in 'asyncio') that do not exactly match the blocked strings. This allows malicious pickle payloads to be flagged as 'Suspicious' rather than 'Dangerous' or blocked entirely. An attacker can exploit this by distributing crafted PyTorch models or ZIP archives containing malicious pickle files. The issue is fixed in version 0.0.31 by implementing more robust module and submodule matching logic.

Affected products

  • mmaitre314 picklescan <= 0.0.30

Identifiers

  • CVE-2025-10157
  • GHSA-f7qq-56ww-84cr
  • PYSEC-2025-153

Timeline

  • 2025-09-08: disclosed: Advisory published by maintainer
  • 2025-09-10: advisory: GitHub Advisory published
  • 2025-09-10: patched: Version 0.0.31 released

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.