CVE-2026-5271
Python Pymanager 26.0
Raw vector
CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:XCVSS and EPSS are reproduced from their sources (NVD, FIRST EPSS). Risk Priority is our own derived reading, not an NVD score.
Summary
CVE-2026-5271 is a medium-severity Uncontrolled Search Path Element (CWE-427) vulnerability in Python Pymanager. Its CVSS base score is 5.6 (Medium).
Operationally, exploitation aligns with the MITRE ATT&CK technique Path Interception (T1034); ranked at the 7th percentile by exploit likelihood (below the median); it is not currently listed in the CISA KEV catalog; a public proof-of-concept is referenced.
The strongest mitigations our analysis identified map to CM-6 (Configuration Settings) and AC-3 (Access Enforcement) — see the control section below for these in your framework.
Deeper analysis AI-assisted summary
Synthesised by an AI model from the NVD description and linked references — a reading aid, not an authoritative source.
CVE-2026-5271 is a vulnerability in pymanager, a Python tool, published on 2026-04-01. The issue arises because pymanager includes the current working directory in sys.path, enabling modules in that directory to shadow legitimate modules from intended packages. This affects execution of pymanager-generated commands, such as pip or pytest, when run from a directory containing malicious modules. The vulnerability is classified under CWE-427 (Untrusted Search Path) with a CVSS v3.1 base score of 7.8 (High; AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H).
An unprivileged local attacker can exploit this by controlling a directory and convincing a user to execute a pymanager-generated command from it, such as through social engineering or misleading file placement. Upon execution, Python imports the malicious module instead of the legitimate one, allowing arbitrary code execution with high impacts on confidentiality, integrity, and availability.
Advisories providing mitigation guidance and patches are available in the GitHub security advisory for pymanager at https://github.com/python/pymanager/security/advisories/GHSA-jr5x-hgm4-rrm6 and the OSS-Security mailing list at http://www.openwall.com/lists/oss-security/2026/04/01/5.
OWASP Top 10 for Web (2025)
EU & UK References
- 🇪🇺 ENISA EUVD: EUVD-2026-17911
Vulnerability Data
pymanager included the current working directory in sys.path meaning modules could be shadowed by modules in the current working directory. As a result, if a user executes a pymanager-generated command (e.g., pip, pytest) from an attacker-controlled directory, a malicious module…
more
in that directory can be imported and executed instead of the intended package.
- CWE(s)
Related Threats
MITRE ATT&CK Enterprise Techniques
CVEs Like This One
Affected Assets
Mitigating Controls
Control response
—
—
- 2 hardening rules · 1 OS baseline
—
Mitigating Controls (NIST 800-53 r5) AI
Establishes restrictive configuration settings that can define and lock down approved search paths.
Enforces approved authorizations so that only intended actors can place or modify elements in the search path.
Limits privileges so unintended actors cannot write to or control directories in the product's search path.
Restricts logical and physical access to change system configuration, including search-path settings and directories.
Mitigating Controls (NIST CSF 2.0) AI
Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→CSF cross-walk (authority under review) — links open the control.
Secure-development practices directly address design of search paths and resource loading.
Hardened configuration baselines can enforce safe search-path settings and reduce exposure.
Execution allow-listing can block malicious binaries placed in hijackable search locations.
Mitigating Controls (ISO/IEC 27001:2022 Annex A) AI
Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→ISO cross-walk (authority under review) — links open the control.
Security testing can detect uncontrolled search-path issues but does not prevent them by itself.
Restricting software installation reduces the chance that an attacker-controlled path element is introduced into the search path.
Secure system architecture and engineering principles require explicit control over search paths and resource locations.
Secure coding practices directly address the use of fixed or controlled search paths that can be influenced by unintended actors.
Configuration management can enforce approved search-path settings but does not inherently prevent the weakness.
Hardening callouts derived
Configuration rules from DISA STIG baselines that bear on weaknesses of the type cited by this CVE. Each rule is shown with the relationship its mapping actually records, against the CWE it was authored against. Derived via CVE→CWE over `controls_xwalks` (authoritative rows only; rows rated `none` are excluded).
Oracle Linux 8 (1 rule)
- V-248577 OL 8 must enable kernel parameters to enforce Discretionary Access Control (DAC) on symlinks. prevents CWE-427