CVE-2026-12540: Foreman - Command Injection
- Cve: CVE-2026-12540
- Name: Foreman - Command Injection
- Description: A flaw was found in Foreman. A command injection vulnerability exists in the foreman-rake errors:fetch_log task. The request_id parameter is passed to an underlying system command (typically grep) without adequate shell neutralization. While the task is intended to fetch specific log entries, an attacker with sudo permissions to execute this rake task can inject shell metacharacters (such as ;, ", or |) to break out of the intended command and execute arbitrary code.
- Impact: Attackers with sudo permissions can execute arbitrary code, potentially leading to full system compromise.
- Remediation: Update to the latest version with the fix or apply patches that properly sanitize input.
- Vulnerability type: command_injection
- Vulnerability impact: remote_code_execution
- Requirement type: admin_privileges
- Requirements: Attacker needs sudo permissions to execute the rake task
- Labels source: projectdiscovery
- Severity: high
- Cvss score: 8.2
- Cvss vector: CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:C/C:H/I:H/A:H
- Epss score: 0.01236
- Epss percentile: 0.6983
- Assignee: [email protected]
- Published at: 2026-10-01T17:17:20Z
- Age in days: 53
- Modified at: 2026-10-08T13:16:09Z
- Patch available: yes
- References total: 7
- Products total: 2
- Advisory url: https://nvd.nist.gov/vuln/detail/CVE-2026-12540
- Nvd status: analyzed
- Checked, none or zero: known exploited entries, nuclei templates, public exploits total, public exploits capped, public exploits, oss, projects total, projects, rejected by nvd
- Not known: hackerone
Cwe
| Id | Name |
|---|---|
| CWE-78 | Improper Neutralization of Special Elements used in an OS Command |
References
Same in every row:
- Source: nvd
| Url | Tags |
|---|---|
| https://access.redhat.com/errata/RHSA-2026:74503 | Vendor Advisory |
| https://access.redhat.com/errata/RHSA-2026:74504 | Vendor Advisory |
| https://access.redhat.com/errata/RHSA-2026:74505 | Vendor Advisory |
| https://access.redhat.com/errata/RHSA-2026:74506 | Vendor Advisory |
| https://access.redhat.com/security/cve/CVE-2026-12540 | Vendor Advisory |
| https://bugzilla.redhat.com/show_bug.cgi?id=2489969 | Issue Tracking, Mitigation, Vendor Advisory |
| http://www.openwall.com/lists/oss-security/2026/10/07/9 | Third Party Advisory |
Products
| Product | Affected | Platform bound | Sources | Url |
|---|---|---|---|---|
| theforeman:foreman | all versions | no | nvd | /v1/products/theforeman/foreman |
| redhat:satellite | >= 6.19, < 6.19.5; >= 6.18, < 6.18.10; >= 6.17, < 6.17.12; >= 6.16, < 6.16.4; = 6.0 | no | nvd | /v1/products/redhat/satellite |
Index
- Checked, none or zero: repositories, repositories high signal, packages
Exploitation
- Authentication required: yes
- Exposed hosts: 33
- Checked, none or zero: known exploited, known exploited by, exploitation seen, public exploit, public exploit count, initial access, remote
- Not known: known exploited since, vulncheck known exploited since, public exploit first date, nuclei template, initial access since, hackerone reports