<?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>Osx.mokes — CraftedSignal Threat Feed</title><link>https://feed.craftedsignal.io/tags/osx.mokes/</link><description>Trending threats, MITRE ATT&amp;CK coverage, and detection metadata. Fed continuously.</description><generator>Hugo</generator><language>en</language><managingEditor>hello@craftedsignal.io</managingEditor><webMaster>hello@craftedsignal.io</webMaster><lastBuildDate>Mon, 29 Jan 2024 12:00:00 +0000</lastBuildDate><atom:link href="https://feed.craftedsignal.io/tags/osx.mokes/feed.xml" rel="self" type="application/rss+xml"/><item><title>Firefox 0-day Drops OSX.Mokes.B Backdoor on macOS</title><link>https://feed.craftedsignal.io/briefs/2024-01-29-firefox-0day-mokes/</link><pubDate>Mon, 29 Jan 2024 12:00:00 +0000</pubDate><author>hello@craftedsignal.io</author><guid isPermaLink="true">https://feed.craftedsignal.io/briefs/2024-01-29-firefox-0day-mokes/</guid><description>A Firefox 0-day exploit was used to target Mac users, dropping a second backdoor identified as a new variant of the cross-platform Mokes malware (OSX.Mokes.B) with screen capture, audio capture, and document exfiltration capabilities.</description><content:encoded><![CDATA[<p>In June 2019, a Firefox 0-day exploit was leveraged to target employees at various cryptocurrency exchanges, deploying a previously unknown variant of the OSX.Mokes backdoor. This new variant, dubbed OSX.Mokes.B, shares significant code overlap and capabilities with the original OSX.Mokes discovered by Kaspersky in 2016. The malware, a 13MB 64-bit Mach-O binary, was initially undetected by VirusTotal engines. It installs itself under various names (quicklookd, storeaccountd), persists via launch agents, and communicates with a command and control server. The malware possesses capabilities including screen capture, audio recording, and the ability to discover and exfiltrate documents. The binaries are often very large due to statically linked libraries like OpenSSL. This campaign highlights the continued relevance of older malware families adapted for modern exploits and the importance of behavior-based detection to supplement signature-based AV.</p>
<h2 id="attack-chain">Attack Chain</h2>
<ol>
<li>Initial Access: A Firefox 0-day exploit is used to compromise a macOS system.</li>
<li>Malware Dropper: The exploit drops a Mach-O executable (mac) to the /Users/<user>/Desktop/ directory.</li>
<li>Installation: The malware copies itself to a location in the user&rsquo;s Library directory, such as ~/Library/Dropbox/quicklookd or ~/Library/App Store/storeaccountd.</li>
<li>Persistence: A launch agent plist file (e.g., quicklookd.plist or storeaccountd.plist) is created in ~/Library/LaunchAgents/ to ensure persistence across reboots. The plist file sets the &ldquo;RunAtLoad&rdquo; key to 1.</li>
<li>Execution: The malware executes the copied binary from its new location using execve.</li>
<li>Command and Control: The malware initiates an outbound TCP connection to the C2 server at 185.49.69.210 over HTTP.</li>
<li>Data Collection: The malware leverages AVFoundation frameworks to capture screen and audio recordings.</li>
<li>Data Exfiltration: The malware searches for and exfiltrates documents with extensions like *.doc, *.docx, *.xls, and *.xlsx.</li>
</ol>
<h2 id="impact">Impact</h2>
<p>Successful infection leads to persistent remote access, allowing the attacker to capture sensitive information, including screen recordings, audio, and documents. This can result in financial loss, intellectual property theft, and reputational damage. While the specific number of victims is unknown, the targeting of cryptocurrency exchanges suggests a focus on high-value targets. The malware&rsquo;s capabilities align with those of a fully-featured backdoor, providing extensive control over compromised systems.</p>
<h2 id="recommendation">Recommendation</h2>
<ul>
<li>Monitor process creations for executables running from non-standard directories like ~/Library/Dropbox/ or ~/Library/App Store/ using the &ldquo;Process Created from User Library Directory&rdquo; Sigma rule.</li>
<li>Deploy the &ldquo;OSX.Mokes C2 Communication&rdquo; Sigma rule to detect network connections to the identified C2 server IP address (185.49.69.210).</li>
<li>Monitor for the creation of LaunchAgent plists that execute binaries from atypical installation paths, especially those masquerading as common system processes or applications based on the persistence steps described above.</li>
<li>Inspect network traffic for connections to 185.49.69.210 on port 80, and analyze the HTTP traffic for command and control patterns.</li>
</ul>
]]></content:encoded><category domain="severity">high</category><category domain="type">threat</category><category>malware</category><category>backdoor</category><category>osx.mokes</category><category>macos</category><category>firefox</category></item></channel></rss>