
Cloud Vulnerability DB
A community-led vulnerabilities database
CVE-2025-15616 is a set of shell injection and untrusted search path vulnerabilities in Wazuh's wazuh-agent and wazuh-manager components, affecting versions 2.1.0 through 4.7.x (before 4.8.0). The flaws allow authenticated administrators to execute arbitrary OS commands by injecting malicious payloads through logcollector configuration, the maild SMTP server tag, and Kaspersky AR script --custom_flags parameters. The vulnerability was published on March 27, 2026, with the underlying advisory originally disclosed by Wazuh on January 13, 2025. It carries a CVSS v3.1 base score of 7.2 (High) and a CVSS v4.0 base score of 7.1 (High) (GitHub Advisory, Red Hat CVE).
The root cause is classified as CWE-94 (Improper Control of Generation of Code / Code Injection), with an additional untrusted search path component. Three distinct attack surfaces are identified: (1) wazuh-logcollector executes commands directly as read from configuration files without sufficient sanitization; (2) wazuh-maild in local server mode executes the command specified in the smtp_server configuration tag, and invokes system binaries (e.g., net.exe on Windows) without specifying their full path, enabling path hijacking by placing a malicious executable in the ossec-agent folder; (3) the Kaspersky AR script passes user-controlled --custom_flags values to extra_args without sanitization, enabling direct code injection. Exploitation requires network-accessible administrative privileges and no user interaction, and is triggered upon Wazuh service restart (GitHub Advisory).
Successful exploitation grants an attacker full remote code execution on affected Wazuh agent and manager hosts, with high impact to confidentiality, integrity, and availability. An attacker with administrative access can execute arbitrary OS commands, potentially compromising the entire monitored environment since Wazuh agents are typically deployed across many systems. This could enable lateral movement, credential theft, log tampering, or complete takeover of the security monitoring infrastructure (GitHub Advisory, Red Hat CVE).
ossec.conf configuration file to set the smtp_server tag to a malicious shell command (e.g., smtp_server = $(malicious_command)). Upon Wazuh service restart, the command is executed by wazuh-maild.net.exe inside the Wazuh ossec-agent installation folder. When Wazuh invokes the net command without a full path, Windows resolves it to the malicious binary in the current application directory first, executing the attacker's payload.--custom_flags parameter in extra_args. Upon service restart, the injected code is executed as part of the script invocation.net.exe or similarly named executable in the Wazuh ossec-agent installation directory on Windows hosts; unexpected files created in /tmp or other writable directories following Wazuh service restarts.wazuh-maild or the Kaspersky AR script; configuration file (ossec.conf) modification timestamps inconsistent with authorized change windows.wazuh-maild, wazuh-logcollector, or Kaspersky AR script processes (e.g., shells, network tools, or reverse shell utilities).Upgrade wazuh-agent and wazuh-manager to version 4.8.0 or later, which contains fixes for all identified shell injection and path hijacking issues. As interim mitigations, restrict administrative access to Wazuh configuration files and the Wazuh API, and validate/sanitize all configuration inputs — particularly smtp_server tags, logcollector command entries, and Kaspersky AR extra_args parameters. Apply the principle of least privilege to accounts with configuration modification capabilities, and monitor the ossec-agent directory on Windows hosts for unexpected executables (GitHub Advisory).
The vulnerability was internally discovered and disclosed by Wazuh researcher vikman90 as part of an internal security review (issue #15052), and the advisory was published on the Wazuh GitHub repository. No significant external researcher commentary or broad media coverage has been identified beyond standard vulnerability database aggregation (GitHub Advisory).
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."