<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Amsi-Bypass — CraftedSignal Threat Feed</title><link>https://feed.craftedsignal.io/tags/amsi-bypass/</link><description>Trending threats, MITRE ATT&amp;CK coverage, and detection metadata — refreshed continuously.</description><generator>Hugo</generator><language>en</language><managingEditor>hello@craftedsignal.io</managingEditor><webMaster>hello@craftedsignal.io</webMaster><lastBuildDate>Wed, 03 Jan 2024 15:00:00 +0000</lastBuildDate><atom:link href="https://feed.craftedsignal.io/tags/amsi-bypass/feed.xml" rel="self" type="application/rss+xml"/><item><title>Suspicious Antimalware Scan Interface DLL Creation</title><link>https://feed.craftedsignal.io/briefs/2024-01-amsi-dll-hijack/</link><pubDate>Wed, 03 Jan 2024 15:00:00 +0000</pubDate><author>hello@craftedsignal.io</author><guid isPermaLink="true">https://feed.craftedsignal.io/briefs/2024-01-amsi-dll-hijack/</guid><description>An adversary may attempt to bypass AMSI by creating a rogue AMSI DLL in an unusual location to evade detection.</description><content:encoded><![CDATA[<p>The Antimalware Scan Interface (AMSI) is a Windows interface that allows applications and services to integrate with antimalware products. Attackers may attempt to bypass AMSI to execute malicious code without detection. This detection identifies the creation of the AMSI DLL (<code>amsi.dll</code>) in unusual locations, which is a common technique used to load a rogue AMSI module instead of the legitimate one. This technique can be used to evade detection by security products that rely on AMSI for scanning potentially malicious scripts and code. The rule is designed to work with data from Winlogbeat, Elastic Endpoint, Sysmon, Endgame, SentinelOne Cloud Funnel, Microsoft Defender XDR, and Crowdstrike.</p>
<h2 id="attack-chain">Attack Chain</h2>
<ol>
<li>An attacker gains initial access to a Windows system through various means (e.g., phishing, exploit).</li>
<li>The attacker determines the location of the legitimate <code>amsi.dll</code> file.</li>
<li>The attacker identifies a writable directory where a malicious <code>amsi.dll</code> can be placed. This location must be in the search order of applications that use AMSI, such as PowerShell or other scripting hosts.</li>
<li>The attacker copies or creates a malicious <code>amsi.dll</code> in the identified location. This rogue DLL is designed to bypass or disable AMSI functionality.</li>
<li>A process like PowerShell or another scripting host is launched. Because the malicious <code>amsi.dll</code> is in a higher-priority directory, it is loaded instead of the legitimate AMSI library.</li>
<li>The launched process executes malicious code (e.g., PowerShell script).</li>
<li>Because the rogue <code>amsi.dll</code> is loaded, AMSI scans are bypassed, allowing the malicious code to execute without detection.</li>
</ol>
<h2 id="impact">Impact</h2>
<p>A successful AMSI bypass can allow attackers to execute malicious code, such as malware, scripts, or exploits, without detection by antimalware products. This can lead to system compromise, data theft, or other malicious activities. The impact can range from a single compromised endpoint to a wider breach of an organization&rsquo;s network.</p>
<h2 id="recommendation">Recommendation</h2>
<ul>
<li>Enable file creation monitoring with Sysmon or Elastic Defend to detect the creation of files, specifically DLLs, in unusual locations.</li>
<li>Deploy the Sigma rule &ldquo;Suspicious Antimalware Scan Interface DLL Creation&rdquo; to your SIEM to detect the creation of <code>amsi.dll</code> in non-standard paths. Tune the rule for your environment.</li>
<li>Investigate any alerts generated by the Sigma rule by examining the parent process, file path, and user context to determine if the activity is malicious.</li>
</ul>
]]></content:encoded><category domain="severity">high</category><category domain="type">advisory</category><category>defense-evasion</category><category>amsi-bypass</category><category>dll-hijacking</category><category>windows</category></item></channel></rss>