CVE-2026-95168 Details
Description
An issue in nvbn thefuck v.3.32 allows a local attacker to execute arbitrary code via the get_rules_import_paths in thefuck/corrector.py and Rule.from_path in thefuck/types.py
A vulnerability in nvbn thefuck version 3.32 allows local attackers to execute arbitrary code. This issue arises because the 'get_rules_import_paths' function in 'thefuck/corrector.py' scans all entries in 'sys.path' for 'thefuck_contrib_*' packages. It then yields the 'rules/' directories of these packages. The 'Rule.from_path' method in 'thefuck/types.py' executes each rule module before any enable-gating settings are applied. As a result, any writable 'sys.path' entry can lead to unauthorized code execution during thefuck command invocations.
To address this vulnerability, the 'load_source' function should be deferred until after a rule's 'is_enabled' check. Alternatively, the discovery of contrib packages could be restricted to explicitly configured paths, rather than scanning the entire 'sys.path'.
Metrics
CVSS 4.0 Severity and Vector Strings:
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
Volerion
Assessed Oct 20, 2026CISA-ADP
Assessed Oct 21, 2026References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://github.com/nvbn/thefuck/issues/1623 | CISA-ADP | ExploitIssue TrackingTechnical DescriptionVendor |
| https://github.com/REYu6/python-vuln/blob/main/reports-v2/thefuck/03-contrib-pregate-exec.md | CISA-ADP | ExploitTechnical Analysis |
| https://github.com/nvbn/thefuck/issues/1623 | [email protected] | ExploitIssue TrackingTechnical DescriptionVendor |
| https://github.com/REYu6/python-vuln/blob/main/reports-v2/thefuck/03-contrib-pregate-exec.md | [email protected] | ExploitTechnical Analysis |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-94 | Improper Control of Generation of Code ('Code Injection') | CISA-ADP |
Affected Products
| Product | Versions |
|---|---|
| nvbn thefuck | 3.32 |
CPE
Remediation
| |
Change History
2 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Oct 21, 2026 | CVE Modified | CISA-ADP |
| Oct 20, 2026 | New CVE Received | [email protected] |
Volerion