Conhost Proxy Execution for Defense Evasion
Adversaries abuse the Console Window Host (conhost.exe) with the `--headless` argument to proxy execution of malicious commands, evading detection by blending in with legitimate Windows software.
Attackers are leveraging the Console Window Host (conhost.exe) to proxy execution of commands, using the --headless argument to hide malicious activity. This technique allows adversaries to blend in with legitimate Windows processes, making detection more challenging. This behavior, often associated with defense evasion, involves using conhost.exe to execute commands such as PowerShell, cmd.exe, mshta, curl, and scripts. The activity can be seen across multiple environments including endpoints, Windows systems, and cloud platforms like Microsoft Defender XDR and SentinelOne. Defenders must differentiate between legitimate uses of conhost.exe, such as those by Winget-AutoUpdate or OpenSSH, and malicious proxy executions, which could indicate broader compromise.
Attack Chain
- An attacker gains initial access to the system, possibly through phishing or exploiting a vulnerability.
- The attacker executes a command that calls conhost.exe with the
--headlessargument. - Conhost.exe is used to proxy the execution of a malicious command, such as PowerShell, cmd.exe, or mshta.
- The proxied command downloads a malicious payload from a remote server using tools like curl or bitsadmin.
- The downloaded payload is executed, establishing persistence on the compromised system.
- The attacker uses the compromised system to move laterally within the network, compromising additional systems.
- Sensitive data is exfiltrated from the network to a remote server controlled by the attacker.
- The attacker achieves their final objective, such as deploying ransomware or stealing intellectual property.
Impact
Successful exploitation can lead to a complete compromise of the targeted system and potentially the entire network. This can result in data theft, financial loss, and reputational damage. The use of conhost.exe for proxy execution makes it difficult to detect malicious activity, potentially allowing attackers to remain undetected for extended periods. The impact could range from individual workstation compromises to large-scale network breaches, affecting potentially hundreds or thousands of systems within an organization.
Recommendation
- Deploy the “Proxy Execution via Console Window Host” Sigma rule to your SIEM and tune for your environment to detect suspicious
conhost.exeactivity. - Monitor process creation events for
conhost.exewith the--headlessargument, focusing on the command-line arguments to identify potentially malicious commands. - Investigate any instances of
conhost.exeexecuting suspicious scripts, downloaders, or task scheduler modifications to identify potential threats. - Enable Sysmon process creation logging (Event ID 1) to capture detailed process execution information, as recommended in the setup instructions linked in the overview.
- Review the investigation fields in the brief to understand the key data points for analyzing potential proxy execution attempts.
Detection coverage 3
Conhost Headless Execution with Suspicious Arguments
highDetects conhost.exe executing with the --headless argument and suspicious command-line arguments indicative of malicious activity.
Conhost with Headless and Caret-Escaped Characters
mediumDetects conhost.exe executing with the --headless argument and caret-escaped characters in the command line, often used to bypass security restrictions.
Conhost Proxying Remote File Retrieval
mediumDetects conhost.exe with --headless proxying commands commonly used for remote file retrieval.
Detection queries are kept inside the platform. Get full rules →