Summary
Picklescan uses numpy.f2py.crackfortran.myeval, which is a function in numpy to execute remote pickle files.
Details
The attack payload executes in the following steps:
- First, the attacker crafts the payload by calling the numpy.f2py.crackfortran.myeval function in its reduce method
- Then, when the victim checks whether the pickle file is safe by using the Picklescan library and this library doesn't detect any dangerous functions, they decide to use pickle.load() on this malicious pickle file, thus leading to remote code execution.
PoC
class RCE:
def __reduce__(self):
from numpy.f2py.crackfortran import myeval
return (myeval, ("os.system('ls')",))
Report by
Pinji Chen ([email protected]) from the NISL lab (https://netsec.ccert.edu.cn/about) at Tsinghua University, Guanheng Liu ([email protected]).
Impact
Any organization or individual relying on picklescan to detect malicious pickle files inside PyTorch models.
Attackers can embed malicious code in pickle file that remains undetected but executes when the pickle file is loaded.
Attackers can distribute infected pickle files across ML models, APIs, or saved Python objects.
Untrusted input is evaluated as executable code within the application's runtime environment. Typical impact: arbitrary code execution within the application's privilege context.
Affected versions
Security releases
Kodem intelligence
Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.
Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.
Remediation advice
Kodem Kai can prioritize this vulnerability in your dependency tree and generate a fix recommendation.
Frequently Asked Questions
- What is GHSA-3329-GHMP-JMV5? GHSA-3329-GHMP-JMV5 is a high-severity code injection vulnerability in picklescan (pip), affecting versions < 0.0.33. It is fixed in 0.0.33. Untrusted input is evaluated as executable code within the application's runtime environment.
- Which versions of picklescan are affected by GHSA-3329-GHMP-JMV5? picklescan (pip) versions < 0.0.33 is affected.
- Is there a fix for GHSA-3329-GHMP-JMV5? Yes. GHSA-3329-GHMP-JMV5 is fixed in 0.0.33. Upgrade to this version or later.
- Is GHSA-3329-GHMP-JMV5 exploitable, and should I be worried? Whether GHSA-3329-GHMP-JMV5 is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
- What actually determines whether GHSA-3329-GHMP-JMV5 is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
- How do I fix GHSA-3329-GHMP-JMV5? Upgrade
picklescanto 0.0.33 or later.