Skip to content
Threat Feed
critical advisory updated

Remote Code Execution in Foreman via Safemode Sandbox Bypass

An authenticated, low-privileged attacker can achieve remote code execution in Foreman by bypassing the templating engine's safemode sandbox to invoke unauthorized functions.

CVE search metadata

CVE search record: CVE-2026-96658. Severity: critical. CVSS: 9.9. KEV: no. Product: Foreman. Brief: Remote Code Execution in Foreman via Safemode Sandbox Bypass. Brief link: https://feed.craftedsignal.io/briefs/2026-10-foreman-rce/

CVE search record: CVE-2026-96659. Severity: critical. CVSS: 9.1. KEV: no. Product: Foreman. Brief: Remote Code Execution in Foreman via Safemode Sandbox Bypass. Brief link: https://feed.craftedsignal.io/briefs/2026-10-foreman-rce/

CVE search record: CVE-2026-12540. Severity: high. CVSS: 8.2. KEV: no. Product: Foreman. Brief: Remote Code Execution in Foreman via Safemode Sandbox Bypass. Brief link: https://feed.craftedsignal.io/briefs/2026-10-foreman-rce/

CVE search record: CVE-2026-12544. Severity: high. CVSS: 7.7. KEV: no. Product: Foreman. Brief: Remote Code Execution in Foreman via Safemode Sandbox Bypass. Brief link: https://feed.craftedsignal.io/briefs/2026-10-foreman-rce/

What's new

  • 1. added CVE-2026-12540 +2 Oct 2, 14:20 via bsi
  • 2. added coverage for Foreman Oct 1, 18:13 via nvd
  • 3. added coverage for Foreman Oct 1, 18:13 via nvd
  • 4. added coverage for Foreman Oct 1, 18:12 via nvd

CVE-2026-96658 is a critical security vulnerability impacting Foreman, a lifecycle management tool for physical and virtual servers. The flaw exists within the application's templating engine, specifically regarding the implementation of the safemode sandbox designed to restrict untrusted code execution.

The vulnerability allows an authenticated attacker with low-level permissions to manipulate the templating engine by abusing the handling of delegated methods. By appending unauthorized functions to the application's allowed execution list, the attacker can break out of the sandbox environment. This results in the ability to execute arbitrary commands with the privileges of the underlying web server process. Given the core management capabilities of Foreman, successful exploitation provides a significant vector for full infrastructure compromise. Defenders should prioritize updating Foreman instances to the latest patched version once available.

Impact

The vulnerability allows authenticated attackers to move from low-level access to full remote code execution on the hosting server. This capability enables complete control over the Foreman instance, potential lateral movement into managed compute nodes, and access to stored credentials or system configuration data.

Recommendation

Prioritize patching Foreman as soon as the vendor releases the security update addressing CVE-2026-96658. Until a patch is available, audit user access levels and restrict template management permissions to trusted administrative roles to minimize the pool of potential attackers.


Immediate actions

Review access logs for template modifications by low-privileged user accounts

Security Operations 48h

Mitigations

Monitor vendor channels for security patches addressing CVE-2026-96658 and apply to all instances

immediate IT Operations

CVE-2026-96658