CVE-2025-71367: picklescan <0.0.34 Detection Bypass—RCE via _operator.attrgetter
picklescan, a security tool designed to scan Python pickle files for malicious code, has a bypass vulnerability in versions before 0.0.34. The tool fails to recognize a specific Python operator function (_operator.attrgetter) when it appears in crafted pickle payloads. An attacker can exploit this gap by embedding this function in a pickle file's reduce method—the mechanism pickle uses to reconstruct Python objects. When a developer or application uses pickle.load() to deserialize such a file, the malicious code executes because picklescan never flagged it as dangerous. This is particularly concerning because picklescan is often used as a front-line defense against pickle deserialization attacks.
Source data · NVD / CISA · public domain
- CVSS
- 3.1 · 8.1 HIGH · CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:N
- Weaknesses (CWE)
- CWE-502
- Affected products
- 0 configuration(s)
- Published / Modified
- 2026-07-04 / 2026-07-06
NVD description (verbatim)
picklescan before 0.0.34 fails to detect _operator.attrgetter function calls in pickle payloads, allowing attackers to bypass security checks. Remote attackers can craft malicious pickle files using _operator.attrgetter in reduce methods to execute arbitrary code when pickle.load() processes the file.
3 reference(s) · View on NVD →
SEC.co analysis · AI-assisted, reviewed against source
Technical summary
CVE-2025-71367 is a detection bypass in picklescan (versions <0.0.34) affecting its ability to identify unsafe callable objects in pickle streams. The vulnerability exploits picklescan's incomplete opcode and callable-name coverage: the tool does not detect _operator.attrgetter when used within pickle reduce operations. An attacker crafts a malicious pickle file where the reduce method specifies _operator.attrgetter as the callable, paired with arguments designed to access and invoke dangerous code paths. During pickle deserialization, Python's pickle module processes the reduce opcode, instantiates _operator.attrgetter with attacker-controlled arguments, and executes the resulting operation. Because picklescan's validation logic omits this specific function from its detection patterns, the file passes validation. The root cause is CWE-502 (Deserialization of Untrusted Data), compounded by incomplete whitelisting or blacklisting in the scanner's callable-detection logic.
Business impact
Organizations relying on picklescan as part of their Python application security posture face an unexpected vulnerability in their defensive layer. Any service that validates pickle data before loading it—to prevent remote code execution from untrusted sources—may unknowingly allow crafted payloads through. This is especially critical for: (1) applications deserializing pickles from user uploads, API endpoints, or message queues; (2) security teams using picklescan to audit third-party Python packages or artifacts; (3) MLOps and data science pipelines where pickled models or serialized data objects flow between systems. A breach could grant remote code execution in production environments with the privileges of the Python process, potentially leading to lateral movement, data exfiltration, or service disruption. The trust placed in picklescan's validation creates a false sense of security.
Affected systems
Any deployment using picklescan versions prior to 0.0.34 to validate or scan pickle files before deserialization is affected. This includes: applications that import picklescan and call its scanning functions; security tools or CI/CD pipelines that invoke picklescan as a command-line utility; development teams using picklescan during code review or artifact scanning. Systems not using picklescan, or those already updated to 0.0.34 or later, are not affected by this specific bypass. Note that the vulnerability does not affect pickle security in general—it affects the ability of picklescan to detect this particular attack vector. Standard pickle deserialization from untrusted sources remains unsafe regardless of picklescan version.
Exploitability
This vulnerability requires user interaction (UI:R in the CVSS vector): an attacker must trick a user or system into loading a malicious pickle file. However, exploitation is otherwise straightforward. No authentication is required (PR:N), the attack is network-accessible (AV:N), and no complex conditions must be met (AC:L). Crafting a pickle file with _operator.attrgetter in the reduce method is trivial for anyone with Python knowledge. The barrier to entry is low, and the impact is severe (arbitrary code execution with process privileges). The CVSS 8.1 (HIGH) score reflects the high impact but acknowledges that delivery of the malicious pickle requires social engineering or a compromised data source. In real-world scenarios, pickles are often downloaded, deserialized in automated pipelines, or accepted from seemingly trusted sources, making the
Remediation
Immediate action: update picklescan to version 0.0.34 or later, which closes the detection gap by recognizing _operator.attrgetter and other overlooked callables in reduce methods. Verify the update in your dependency management tool (pip, poetry, etc.) and re-run picklescan scans across your artifact inventory. Longer-term measures: (1) treat picklescan as a layer of defense, not a complete solution—do not rely on it as the sole gatekeeper for pickle deserialization; (2) whenever possible, replace pickle with safer serialization formats (JSON, Protocol Buffers, MessagePack) in new code; (3) deserialize pickle data only from fully trusted sources in controlled environments; (4) run pickle deserialization in isolated sandboxes or containers with minimal privileges; (5) implement network segmentation so that code execution in one tier cannot easily pivot to sensitive systems. For applications that cannot migrate away from pickle, update picklescan immediately and combine it with additional runtime controls (e.g., restrictive pickle.Unpickler configurations or custom Unpickler subclasses that constrain which modules and classes can be instantiated).
Patch guidance
Update picklescan to version 0.0.34 or later. Verify the upgrade with `pip show picklescan` or equivalent and confirm the version number. If you are using picklescan as a pinned dependency in a requirements.txt, pyproject.toml, or similar, change the version specifier to >=0.0.34 (or, after testing, to a specific newer version). Re-run picklescan against any stored pickle files or artifacts in your environment to catch payloads that may have passed the old, vulnerable scanner. If you are using picklescan in a CI/CD pipeline, ensure the updated version is pulled in your next build. There are no known breaking changes in 0.0.34, but review the changelog to confirm compatibility with your call patterns.
Detection guidance
Monitor for the use of _operator.attrgetter in pickle files or pickle-like byte streams. Network-based detection is difficult without decoding the pickle protocol, but you can inspect pickles at rest or in transit by: (1) decoding them with a tool that extracts opcode and callable names without full deserialization (e.g., pickletools.dis() in Python); (2) scanning logs for warnings from picklescan versions <0.0.34 that may have false-negatives; (3) auditing which applications deserialize pickles and verifying they are running picklescan 0.0.34+. Behavioral detection: watch for unexpected process spawning or system calls originating from Python processes that are known to deserialize pickle data. If you have not explicitly enabled picklescan or do not validate pickles before loading, assume all pickle deserialization from untrusted sources is a risk and implement immediate controls.
Why prioritize this
This vulnerability should be patched with high urgency. While the CVSS score is 8.1 (HIGH), not CRITICAL, the practical risk is elevated because: (1) picklescan is a security tool relied upon for assurance, so its failure undermines a key defensive control; (2) the bypass is trivial to exploit and requires no special tools or skills; (3) exploitation grants arbitrary code execution in the context of the running process; (4) the vulnerability directly affects the integrity of Python artifact supply chains and deserialization workflows. Organizations should treat this as a critical defect in their intake validation layer and patch within days, not weeks. If you use picklescan in production or continuous integration, this is a priority fix.
Risk score, explained
The CVSS 8.1 score reflects a HIGH-severity vulnerability with a high base risk: (C:H) confidentiality impact from arbitrary code execution; (I:H) integrity impact from the same; (A:N) no direct availability impact, though availability can be affected indirectly via DoS or service disruption. The attack vector is network-accessible (AV:N), requires low complexity (AC:L), no privileges (PR:N), and some user interaction (UI:R). The user interaction requirement (loading or validating a specific file) prevents a CRITICAL rating, but the combination of straightforward exploitation, severe impact, and the fact that picklescan is supposed to prevent exactly this type of attack justifies the 8.1 score. The real-world risk to any organization using picklescan may feel higher than the numeric score suggests, because the vulnerability undermines a trusted tool.
Frequently asked questions
Do I need to update picklescan immediately?
Yes. If you are using picklescan versions before 0.0.34, update immediately. This vulnerability allows attackers to craft pickle files that bypass picklescan's detection, leading to arbitrary code execution when the pickle is loaded. There is no practical workaround other than upgrading.
Does this vulnerability affect Python's pickle module itself?
No. The pickle module is not the root cause; the vulnerability is a detection gap in picklescan. However, pickle deserialization from untrusted sources has always been unsafe by design. This CVE highlights why you should not rely solely on picklescan for security—use safer serialization formats where possible, and treat pickle as a legacy format for trusted data only.
How do I know if my application is affected?
Check your application's dependencies for picklescan. Run `pip show picklescan` or inspect your requirements.txt / pyproject.toml for picklescan entries. If you find picklescan at any version before 0.0.34, you are affected. If you do not use picklescan, you are not directly affected by this CVE, but you should still ensure all pickle deserialization is from trusted sources only.
Can I work around this by avoiding picklescan?
Not really. The issue is that picklescan version <0.0.34 provides false assurance that it detects malicious pickles—it does not catch this particular bypass. Removing picklescan without replacing it with a safer serialization format leaves you vulnerable to standard pickle attacks. The correct fix is to upgrade picklescan and, over time, migrate to JSON, Protocol Buffers, or other safer formats.
This analysis is provided for informational purposes and is based on the CVE record and public information available as of the publication date. Security vulnerabilities are complex, and real-world impact can vary based on deployment, configuration, and threat model. Organizations should consult the official picklescan project advisory and release notes for authoritative guidance. This document does not constitute professional security advice; engage qualified security professionals for your specific environment. No exploit code or weaponized proof-of-concept is provided or endorsed. Always test patches in a non-production environment before deployment. Source: NVD (public-domain), retrieved 2026-08-12. Analysis generated by SEC.co (claude-haiku-4-5).
Weaknesses (CWE)
Related vulnerabilities
- CVE-2025-11993HIGHWooCommerce Infinite Scroll Plugin PHP Object Injection – HIGH Severity
- CVE-2025-27511HIGHGeoServer DB2 JNDI Injection Remote Code Execution
- CVE-2025-69130HIGHPHP Object Injection in Entrepreneur WordPress Booking Theme ≤3.1.3
- CVE-2025-71339HIGHPicklescan Gadget Bypass Allows Arbitrary Code Execution
- CVE-2025-71340HIGHPicklescan Evasion via idlelib.pyshell.ModifiedInterpreter
- CVE-2025-71341HIGHPicklescan Bypass Enables Remote Code Execution via profile.Profile.runctx
- CVE-2025-71342HIGHPicklescan Evasion Enables Remote Code Execution in PyTorch Models
- CVE-2025-71343HIGHpicklescan Detection Bypass Allows Remote Code Execution