Where
-Infinity
0
Severity
9.1
AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:L/A:L

A flaw was found in Foreman. This vulnerability allows an authenticated user with low-level Viewer permissions to cause unauthorized information disclosure by submitting requests to template preview endpoints. By exploiting this issue, the user can access sensitive data, such as host root passwords. Furthermore, under insecure system configurations where Safemode protections are disabled, the flaw may allow the user to execute arbitrary commands as the Foreman system account.

1 / 2
Source: MITRE
First published (updated )
Severity
8.8
Command Injection, OS Command Injection
AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H

A flaw was found in Foreman. A remote attacker could exploit a command injection vulnerability in Foreman's WebSocket proxy implementation. This vulnerability arises from the system's use of unsanitized hostname values from compute resource providers when constructing shell commands. By operating a malicious compute resource server, an attacker could achieve remote code execution on the Foreman server when a user accesses VM VNC console functionality. This could lead to the compromise of sensitive credentials and the entire managed infrastructure.

1 / 2
Source: MITRE
First published (updated )
Severity
8.8
AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

A flaw was found in Foreman. The Usergroup model in Foreman does not properly validate role assignments against the calling user's permissions. This allows an authenticated user with usergroup management permissions to attach arbitrary roles, including administrative roles, to a user group and then add themselves as a member. Successful exploitation of this vulnerability leads to full privilege escalation, granting the attacker administrator-level access.

1 / 2
Source: MITRE
First published (updated )
Severity
8.8
Code Injection
AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

A flaw was found in Foreman. This vulnerability allows an authenticated remote attacker with low-level read permissions to achieve arbitrary code execution on the underlying server. By manipulating the permitted methods list within the template rendering engine, an attacker can bypass the safemode sandbox isolation and execute unauthorized commands directly on the host system.

1 / 2
Source: MITRE
First published (updated )
Severity
8.8
AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

A flaw was found in Foreman’s Api::V2::PersonalAccessTokensController, where Foreman::Controller::UserAware#finduser resolves the target account using User.find(params[:userid]) without applying the required parent-user authorization check. An attacker with the createpersonalaccesstokens permission can therefore invoke POST /api/v2/users/:userid/personalaccesstokens with another user’s ID and create a Personal Access Token on their behalf. The resulting plaintext token is returned in the API response, while PersonalAccessToken#checkpermissionsaftersave only validates createpersonalaccesstokens on the token and does not enforce editusers authorization on the target user. The attacker can then use the forged token to authenticate as the victim, potentially resulting in complete account takeover, including administrator accounts.

1 / 2
Source: MITRE
First published (updated )
Severity
8.2
OS Command Injection, Command Injection
AV:L/AC:L/PR:H/UI:N/S:C/C:H/I:H/A:H

A flaw was found in Foreman. A command injection vulnerability exists in the foreman-rake errors:fetchlog task. The requestid 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.

1 / 2
Source: MITRE
First published (updated )
Severity
8
Command Injection, OS Command Injection
AV:N/AC:H/PR:H/UI:N/S:C/C:H/I:H/A:H

A command injection flaw was found in Red Hat Satellite 6.16.5.2 (Foreman 3.12.0.8-1). Although a whitelist for CoreOS Transpiler Command and Fedora CoreOS Transpiler Command is implemented, the whitelist is only enforced on the client-side and is not validated on the server-side. This flaw allows an authenticated user with editsettings permissions to modify these parameters to achieve arbitrary command execution on underlying operating system and bypass safe mode rendering.

1 / 2
Source: Red Hat
First published (updated )
Severity
7.8
AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

A flaw was found in the foreman-mcp-server. A session management vulnerability in the MCP Server allows unauthenticated attackers to hijack active administrative sessions due to an improper cache of authenticated client connections, by trusting a non-secret session ID without re-validating authentication tokens and by logging all newly created session IDs to standard logs. This issue can result in privilege escalation and infrastructure-wide code execution.

1 / 2
Source: MITRE
First published (updated )
Severity
7.8
Input Validation, Command Injection, OS Command Injection
AV:L/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L

A flaw was found in Foreman. The foreman-tail utility is vulnerable to OS command injection due to the unsafe use of the eval command. The script takes user-supplied arguments and incorporates them directly into a string that is then executed by eval to expand file paths. Because the input is not sanitized or quoted, a local attacker can inject shell metacharacters (e.g., ;, &, |) to execute arbitrary system commands.

1 / 2
Source: MITRE
First published (updated )
Severity
7.7
Command Injection, OS Command Injection
AV:L/AC:L/PR:H/UI:R/S:C/C:H/I:H/A:H

A flaw was found in Foreman. The foreman-rake initialization logic in /usr/share/foreman/config/settings.rb contains a vulnerable code pattern where configuration data is processed through two distinct executable layers. This creates a multi-stage execution chain that allows for both Server-Side Template Injection (SSTI) and insecure deserialization. This vulnerability can lead to remote code execution, total infrastructure compromise and supply chain risk.

1 / 2
Source: MITRE
First published (updated )
Severity
7.7
AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N

A flaw was found in Foreman. An authenticated user with viewhosts privileges can retrieve rendered provisioning template content for a host via the hosts template API endpoint, disclosing sensitive data such as the host root password. This is an incomplete fix of CVE-2026-96659, which hardened the web UI preview path but left the API host-template render path authorized for Viewer-level users.

1 / 2
Source: MITRE
First published (updated )
Severity
7.5
Infoleak
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

A disclosure of sensitive information flaw was found in foreman via the GraphQL API. If the introspection feature is enabled, it is possible for attackers to retrieve sensitive admin authentication keys which could result in a compromise of the entire product's API.

1 / 2
Source: NVD
First published (updated )
Severity
7.5
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

A flaw was found in Foreman. The Red Hat Satellite /unattended/provision API endpoint is vulnerable to an authentication bypass due to a semantic logic flaw in hostverifier.rb. The application verifies the database state of a provisioning token rather than its actual presence in the incoming HTTP request. Because a host actively undergoing provisioning has an unexpired token in the database, the server's validhosttoken? method evaluates to true, granting access to the kickstart template even if the requester provides no token at all in the URL.

1 / 2
Source: MITRE
First published (updated )
Severity
7

A flaw was found in foreman before version 3.3. The server exposes a GraphQL API with limited access. If introspection is enabled (usually by default), it allow attackers to query a settings type without any authentication and retrieve the product settings, including the OAuth consumerkey and OAuth consumersecret properties. These elements can be used to authenticate as foremanapiadmin and gain full control of the product's REST API.

First published (updated )
Severity
7
Command Injection

Summary: A critical command injection vulnerability exists in Foreman's WebSocket proxy implementation (lib/wsproxy.rb). The vulnerability occurs when constructing shell commands using unsanitized hostname values from compute resource providers. An attacker operating a malicious compute resource server (VMware vSphere, Libvirt, etc.) can achieve remote code execution on the Foreman server when an administrator accesses VM console functionality.

Requirements to exploit: An attacker needs to operate a malicious compute resource server (such as a fake vSphere server) that returns poisoned hostname values. The Foreman administrator must then configure this malicious server as a compute resource and attempt to access the VM console through the normal workflow.

Component affected: foreman

Version affected: Foreman <= 3.17.0 (confirmed), likely all versions from the past 4+ years (wsproxy.rb unchanged since 2020)

Patch available: Yes (need to be reviewed and verified)

Line 44 - Sanitize host parameter safehost = Shellwords.escape(host) Use array form to prevent shell injection cmdarray = [ 'websockify', '--daemon', "--idle-timeout=#{idletimeout}", "--timeout=#{timeout}", port.tos, "#{safehost}:#{hostport}" ] Add SSL options cmdarray += ['--ssl-target'] if ssltarget if Setting[:websocketsencrypt] cmdarray += ['--cert', Setting[:websocketssslcert]] if Setting[:websocketssslcert] cmdarray += ['--key', Setting[:websocketssslkey]] if Setting[:websocketssslkey] end Execute without shell interpretation Open3.popen3(cmdarray) do |stdin, stdout, stderr| # ... existing error handling End Version fixed (if any already): N/A

CVSS: Proposed by reporter - CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H (Base Score: 8.8 High)

My understanding of the situation (6.8 Medium/High; Still serious, but not "internet critical" – CVSS:3.1/AV:A/AC:H/PR:H/UI:R/S:U/C:H/I:H/A:H) Impact (optional): This vulnerability allows remote code execution as the foreman user, providing direct access to Foreman's database credentials and encryption keys. This enables decryption of all stored infrastructure credentials (vCenter, AWS, SSH keys, API tokens), allowing the attacker to pivot and compromise the entire managed infrastructure. Based on Red Hat's classification, this would be considered Critical impact due to the potential for complete infrastructure compromise. Embargo needed: Yes Reason: Given it is command injection Public date: Need to set default 90-days. There is no date received from the reporter.

Acknowledgement: Houssam Sahli

Steps to reproduce if available: 1. Start malicious vSphere server (attacker system): python3 maliciousvsphereserver.py 2. Configure Foreman compute resource (Foreman UI): - Navigate to: Infrastructure → Compute Resources → Create Compute Resource - Provider: VMware - VCenter/Server: <attackerip> (malicious server address) - Username: user - Password: pass - Load Datacenters (it will load EvilDatacenter) - Display Type: VNC - Uncheck "VNC Console Passwords" and "Enable Caching" - Click "Submit" 3. Trigger exploitation: - Navigate to Virtual Machines tab - Locate "TestVM" in the list - Click Actions → Console 4. Verify RCE (Foreman server): find /tmp -name "vsphererce.txt" 2>/dev/null cat /tmp/systemd-private-/tmp/vsphererce.txt Expected output: foreman

First published (updated )
Severity
7
Command Injection, OS Command Injection

Description

The foreman-rake initialization logic in /usr/share/foreman/config/settings.rb contains a vulnerable code pattern where configuration data is processed through two distinct executable layers. This creates a Multi-Stage Execution Chain that allows for both Server-Side Template Injection (SSTI) and Insecure Deserialization.

The vulnerability execution chain has two stages:

Template Injection (ERB): The first stage uses ERB.new(...).result. This evaluates the file as a Ruby template. Any code inside <%= ... %> is executed by the Ruby interpreter to generate a string. This is an SSTI that allows for direct OS command injection.

Insecure Deserialization (YAML): The second stage takes the rendered string and passes it to YAML.load. Because this is an unsafe parser, it allows for object injection. Even if an attacker cannot use ERB tags, they can craft YAML that instantiates malicious Ruby "gadget chains" to achieve code execution.

The vulnerability exists in two different application functionalities, thus it can be exploited in two different ways:

Primary config:

SETTINGS.merge! YAML.load(ERB.new(File.read(settingsfile)).result) allows an attacker to craft a malicious /etc/foreman-maintain/foremanmaintain.yml file that will be loaded and executed by foreman-rake on start.

Plugins config:

SETTINGS.merge! YAML.load(ERB.new(File.read(f)).result) allows an attacker to craft a malicious file that will be executed from /usr/share/foreman/config/settings.plugins.d/ by foreman-rake on start.

Impact

Indirect Triggering & Privileged RCE: foreman-rake exposes underlying execution primitives that higher-level orchestration tools (like foreman-maintain or foreman-installer) rely on to interact with the application. Because these tools implicitly pass commands down, the vulnerability can be triggered indirectly during routine administrative operations, resulting in Remote Code Execution (RCE) in a high-trust context (often foreman or root).

Total Infrastructure Compromise: Compromising the management plane (Satellite server) allows an attacker to pivot and execute arbitrary code across all Satellite Managed Hosts.

Supply Chain Risk: While direct local exploitation requires prior root access, this flaw presents a critical supply chain risk. An adversary could distribute malicious plugins or compromised configuration files through public repositories (e.g., RubyGems, GitHub). Note: The CVSS vector and severity are based on this supply chain attack vector.

RECOMMENDATIONS

Replace YAML.load with YAML.safeload(content, permittedclasses: [Symbol]) in both locations in settings.rb.

Remove the ERB.new().result evaluation. Configuration files must be treated as static data, never as executable templates.

First published (updated )
Severity
7

When accessing certain API endpoints (e.g. POSTing to /template/preview) a user with the Viewer role is able to access information they should not be able to (i.e. @host.rootpass). When the system is configured insecurely (i.e. Safemode is disabled), or a Safemode bypass vulnerability exists, then the Viewer is able to perform Remote Code Execution on the system as the foreman system account.

First published (updated )
Severity
7

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.

First published (updated )
Severity
7

Foreman contains an authorization flaw in the Foreman::Controller::UserAware#finduser handling used by Api::V2::PersonalAccessTokensController. The controller resolves the target account directly with User.find(params[:userid]) without enforcing the parent-user authorization that normally restricts access to the target user. As a result, a user who has the createpersonalaccesstokens permission can create a Personal Access Token for another user whose account is accessible by ID within the user's taxonomy scope.

The vulnerable endpoint is POST /api/v2/users/:userid/personalaccesstokens. During token creation, the controller builds the Personal Access Token from the attacker-supplied userid and returns the plaintext token value in the API response.

The PersonalAccessToken#checkpermissionsaftersave model validation does not prevent this cross-user operation: when the token belongs to another user, it verifies the createpersonalaccesstokens permission on the token itself but does not require editusers authorization on the target user.

An attacker with the required createpersonalaccesstokens permission can therefore forge a valid PAT belonging to another user and subsequently authenticate as that user using the generated token. This can result in complete account takeover, including takeover of administrator accounts that are visible within the attacker's taxonomy scope.

First published (updated )
Severity
7

Proxy::Dynflow::Core.webconsole mounts the Dynflow web console at /dynflow/console and, when consoleauth is true (the default), calls doauthorizewithsslclient only. That helper rejects an empty SSLCLIENTCERT and does not compare the certificate subject with trustedhosts or the certificate serial with acceptedcertserial. The serial is still computed in Core#initialize, with a comment that only the proxy’s own certificate should be trusted, and nothing reads it.

Before the merge, smartproxydynflowcore’s authorizewithsslclient halted unless the client serial matched the proxy certificate (added in commit 444cc84, Ivan Necas, 2016-06-20, “to avoid being able to use any valid certificate”). Commit e205e19 (2021-06-03) switched the console to the proxy-wide helper and dropped that comparison. First release carrying the drop is 0.4.0. The installer text for consoleauth says it enables trusted hosts and SSL. The code does not check trusted hosts.

The console is the Dynflow 2.x web UI (dynflow >= 1.6, < 3). Its index lists every execution plan. The step view runs YAML.dump on action input and output with no redaction. A remote-execution action input includes the script, hostname, effective user, and the secrets hash (sshpassword, keypassphrase, effectiveuserpassword) when those are set. The same before filter covers POST /:id/resume, POST /:id/cancel, POST /:id/skip/:stepid, and POST /:id/cancel/:stepid. Resume requires a paused plan. Skip requires a paused plan and a failed step. Cancel works when the plan or step is cancellable.

The proxy listens with SSLVerifyClient = VERIFYPEER and without FAILIFNOPEERCERT, so a missing certificate still completes the handshake and then fails this check. A presented certificate must chain to sslcafile. On Satellite that file is the Katello CA, which also issues content-host consumer certificates, so a registered host that is not in trustedhosts passes. consoleauth: false removes the check. The dynflow plugin listens on HTTPS by default. The proxy HTTP port is off by default (foremanproxy::http defaults to false). If HTTP is enabled, this SSL check does not run.

Current puppet default for the dynflow database is in-memory. Plans remain until the execution-plan cleaner (default 30 minutes) or a proxy restart. Secrets of in-flight and recent jobs are in the console during that window.

First published (updated )
Severity
7

A flaw was found in Foreman. The remediation for CVE-2026-96659 restricted only the web UI TemplatesController#preview action to edit/create privileges. The REST API endpoint GET /api/v2/hosts/:id/template/:kind remains authorized by the low-privilege viewhosts permission and still renders the host's provisioning template in host scope. An authenticated Viewer can therefore obtain sensitive values rendered by provisioning templates, including the host root password via the rootpass helper, in the HTTP 200 JSON response.

Reported via PSIRTSUPT-25114. Credit: Sun Kimsroul (@SunKimsroul). Related: CVE-2026-96659 (UI preview path fixed; this flaw covers the remaining API host-template sink).

First published (updated )
Severity
7

Marek Hulan <mhulan> reports:

Hello,

today it was discovered a community member (Daniel Lobato) that users can manage hosts via API even when they shouldn't have access to them (works right in UI). The app/controllers/api/v1/hostscontroller.rb does not honor user privileges at all.

First published (updated )
Severity
6.8
EPSS
0.04%
AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:N

A vulnerability was found in Satellite. When running a remote execution job on a host, the host's SSH key is not being checked. When the key changes, the Satellite still connects it because it uses "-o StrictHostKeyChecking=no". This flaw can lead to a man-in-the-middle attack (MITM), denial of service, leaking of secrets the remote execution job contains, or other issues that may arise from the attacker's ability to forge an SSH key. This issue does not directly allow unauthorized remote execution on the Satellite, although it can leak secrets that may lead to it.

1 / 2
Source: NVD
First published (updated )
Severity
6.5
AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:N/A:N

n authorization flaw in Foreman's GraphQL API allows low-privileged users to access metadata beyond their assigned permissions. Unlike the REST API, which correctly enforces access controls, the GraphQL endpoint does not apply proper filtering, leading to an authorization bypass.

1 / 2
Source: MITRE
First published (updated )
Severity
6.5
AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N

A flaw has been found in permission filters in the foreman package. The API loads a filter by its identifier and does not apply the search limit on the caller's permission. A low-privileged network attacker or user must already be allowed to delete filters for one role only. They can delete filters that belong to other unlocked roles. Those other roles then lose the access the deleted filters had granted.

1 / 2
Source: MITRE
First published (updated )
Severity
6.3
EPSS
0.07%
Infoleak
AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L

A vulnerability was found in Foreman's loader macros introduced with report templates. These macros may allow an authenticated user with permissions to view and create templates to read any field from Foreman's database. By using specific strings in the loader macros, users can bypass permissions and access sensitive information.

1 / 2
Source: NVD
First published (updated )
Severity
6.2
EPSS
0.21%
AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

A flaw was found in foreman-mcp-server. This component utilizes two distinct logging mechanisms that can expose sensitive session and authentication data. One mechanism logs session identifiers, which are treated as authentication credentials, at an informational level. The other, when debug logging is enabled, incompletely sanitizes HTTP request headers, leading to the cleartext logging of sensitive information such as authorization tokens and API keys. This vulnerability can result in a confidentiality breach, as sensitive authentication data is persisted in plain text within container logs, increasing the risk if logs are forwarded to a centralized platform.

1 / 2
Source: MITRE
First published (updated )
Severity
5.4
AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N

An incorrect authorization flaw has been found in network interface handling in the Foreman package. The domain and subnet interface API checks only that the caller holds a host permission. It does not apply the search limit on that permission, so the request is answered from every interface on the domain or subnet. A low-privileged network attacker or user must already be allowed to view some hosts and to view a domain or subnet shared with other hosts. They can request that domain or subnet's interfaces. The response includes interface records of hosts they are not allowed to view. If the attacker or user is also allowed to edit some hosts, they can submit a change to one of those interfaces. The interface is then saved with that change.

1 / 2
Source: MITRE
First published (updated )
Severity
4.3
EPSS
0.28%
AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N

A flaw was found in the foremanansible plugin's Ansible inventory API. The controller builds its host query using an unscoped Host.where call that does not enforce the search filter associated with the caller's viewhosts permission. An authenticated user whose host visibility is restricted by a permission filter can supply arbitrary host IDs within their organization and receive the full Ansible inventory for those hosts, including parameter values marked as hidden.

1 / 2
Source: MITRE
First published (updated )
Severity
4.3
AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N

A flaw was found in Foreman’s Api::V2::MailNotificationsController, where authorization checks on user-specific mail-notification resources are insufficient. The GET /api/v2/users/:id/mailnotifications endpoint resolves the target account using User.find(params[:id]) without verifying that the authenticated user is authorized to access that user’s notification configuration. Additionally, the POST and PUT /api/v2/users/:userid/mailnotifications paths call denyaccess when the requester is unauthorized but fail to halt execution, allowing the request to continue and persist the unauthorized change despite a 403 response or subsequent DoubleRenderError. This can allow a user to disclose another user’s mail-notification configuration, including mailquery values, and, where write permissions apply, modify or create notification settings for another user.

1 / 2
Source: MITRE
First published (updated )

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