CVE-2026-96658: Foreman: safemode bypass leading to rce

Published Sep 15, 2026
·
Updated

A flaw was found in Foreman. An authenticated attacker with low-level permissions can achieve remote code execution (RCE) by bypassing the safemode sandbox within the templating engine. Due to improper handling of delegated methods, an attacker can append unauthorized functions to the allowed execution list, enabling them to run arbitrary commands on the hosting server.

Other sources

A Safemode bypass attack has been identified that exposes a number of weaknesses in Foreman leading to low-privilege (i.e. minimum "view" permissions) to be able to perform limited Remote Code Execution (RCE). It appears that a copy of the delegatemethods to the local scope allows an adversary to append eval to the permitted methods list leveraged by safemode, thus permitting RCE through the templating engine.

— Red Hat

Affected Software

1 affected component
Foreman Foreman

Event History

Sep 15, 2026
Data Sourced
via Red Hat·08:00 PM
DescriptionSeverityAffected Software
Oct 1, 2026
CVE Published
via MITRE·04:23 PM
Data Sourced
via MITRE·04:23 PM
DescriptionSeverity
Data Sourced
via NVD·05:17 PM
DescriptionSeverityWeakness

Frequently Asked Questions

1

Who can exploit this issue?

An authenticated Foreman user with minimum view_* permissions can exploit it. No user interaction is required.

2

What level of access can exploitation provide?

The flaw permits limited remote code execution through Foreman’s templating engine, allowing arbitrary commands to run on the hosting server. The reported impact includes high confidentiality, integrity, and availability consequences.

3

What component or condition is required for exploitation?

Exploitation relies on access to the templating engine and the safemode sandbox. The attacker abuses delegated-method handling to add eval to the methods permitted by safemode.

4

How can I determine whether my deployment is exposed?

Review whether low-privilege authenticated users with view_* permissions can access functionality that processes templates through Foreman’s safemode templating engine. The supplied information does not identify affected versions or a specific detection method.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203