Analyzing Void Dokkaebi’s Cython-Compiled InvisibleFerret Malware

Analyzing Void Dokkaebi’s Cython-Compiled InvisibleFerret Malware
Void Dokkaebi, also tracked as Famous Chollima, has updated InvisibleFerret by shifting it from readable Python scripts to Cython-compiled binaries distributed as .pyd and .so files to evade script-based detections. The campaign also expands BeaverTail into multiple overlapping modules for credential theft, backdoor access, and trojanized wallet installation, while defenders can still recover useful artifacts and C2 clues through binary analysis. #VoidDokkaebi #FamousChollima #InvisibleFerret #BeaverTail #Cython

Keypoints

  • Void Dokkaebi, a North Korea-aligned intrusion set, is using Cython to convert InvisibleFerret from Python scripts into native extension binaries.
  • The malware is now distributed as .pyd files on Windows and .so files on macOS, reducing the effectiveness of script-only detections.
  • BeaverTail has evolved into multiple variants with overlapping capabilities, including downloader, backdoor, browser-stealer, and wallet-trojanization functions.
  • The campaign targets software developers, cryptocurrency users, and organizations with access to wallet credentials, signing keys, CI/CD pipelines, and production systems.
  • Attackers use layered obfuscation methods such as array shuffling, junk-byte Base64 encoding, XOR encryption, and split-and-swap IP encoding.
  • Defenders can still extract useful artifacts from the binaries, including module names, build paths, embedded strings, and some C2 information.
  • The mc.so component targets wallet extensions such as MetaMask, Coinbase Wallet, and Phantom and can downgrade Chrome on macOS to retain Manifest V2 support.

MITRE Techniques

  • [T1059 ] Command and Scripting Interpreter – Used to execute Python-based payloads and run the .mod execution scripts that load Cython-obfuscated modules (‘the infection chain generates a Python execution script to run the Cython-obfuscated InvisibleFerret’).
  • [T1027 ] Obfuscated Files or Information – Used Cython compilation, Base64 stripping, XOR encryption, array shuffling, and compressed string storage to hide code and data (‘obfuscated using Cython’, ‘XOR-encrypted’, ‘Zlib-compressed’).
  • [T1562.001 ] Disable or Modify Tools – Downgraded Chrome on macOS to bypass Manifest V3 protections and retain wallet-extension functionality (‘they downgrade Chrome to a version that still supports Manifest V2’).
  • [T1070.004 ] Indicator Removal: File Deletion – One module deletes its execution Python script after use to hide traces (‘At present, only mc.so deletes its execution Python script’).
  • [T1547.001 ] Boot or Logon AutoStart Execution: Registry Run Key / Startup Folder – Persistence-related execution is implied by modules that create and run scripts for next-stage payloads on system startup contexts (‘creates Python scripts pad0 and brw0 for executing the next-stage payloads’).
  • [T1053.005 ] Scheduled Task/Job: Scheduled Task – Execution of next-stage payloads through generated scripts is consistent with scheduled or scripted tasking (‘creates Python scripts pad0 and brw0 for executing the next-stage payloads’).
  • [T1082 ] System Information Discovery – Collected OS and network information and geolocation data (‘collects system and network information’, ‘gather geolocation data based on the IP address’).
  • [T1083 ] File and Directory Discovery – Sought file paths and build artifacts within binaries and likely on target systems (‘searching the binary could uncover embedded string references to source files’).
  • [T1518 ] Software Discovery – Targeted browser versions, extensions, and wallet-related software (‘downloads and installs trojanized browser extensions’, ‘downgrade the version of Chrome’).
  • [T1057 ] Process Discovery – Identified by capabilities around environment inspection and execution flow (‘collects system and network information’).
  • [T1555.003 ] Credentials from Password Stores: Credentials from Web Browser – Stole browser credentials, passwords, and wallet data (‘Steals information stored in web browsers’, ‘steals … passwords’).
  • [T1056.001 ] Input Capture: Keylogging – Keylogging was included in the malware capabilities (‘clipboard monitoring, keylogging’).
  • [T1115 ] Clipboard Data – Monitored clipboard contents to capture sensitive data (‘clipboard monitoring’).
  • [T1071.001 ] Application Layer Protocol: Web Protocols – Contacted web services such as ip-api for geolocation and used HTTP-based C2 traffic (‘accesses hxxp://ip-api[.]com/json’).
  • [T1071.002 ] Application Layer Protocol: File Transfer Protocols – Used file download and execution flows to stage payloads (‘Downloads … InvisibleFerret’, ‘downloads and executes’).
  • [T1219.002 ] Remote Access Software: Remote Desktop Software – Used AnyDesk-related components and backdoor execution behavior (‘configure the AnyDesk execution environment’, ‘backdoor capabilities’).
  • [T1102.001 ] Web Service: Dead Drop Resolver – Retrieved geolocation data from a web service and used remote infrastructure to resolve operational details (‘accesses hxxp://ip-api[.]com/json’).
  • [T1571 ] Non-Standard Port – The malware embeds or passes port numbers alongside encoded IPs for C2 setup (‘passing … a port number’).
  • [T1048 ] Exfiltration Over Alternative Protocol – Data theft and credential harvesting were performed through malware channels other than standard file uploads (‘steals … credit card details’, ‘cryptocurrency wallet data’).
  • [T1041 ] Exfiltration Over C&C Channel – Stolen data was sent via the command-and-control workflow described in the infection chain (‘C&C server’, ‘downloads and executes’).

Indicators of Compromise

  • [File names ] Cython modules and execution scripts used in the infection chain – mod.pyd, pad.so, .mod
  • [File names ] Next-stage payload and browser-stealer components – pad0, brw0, mc.so
  • [URL paths ] Payload download paths and geolocation lookup – /clw/{sType}, /clw1/{sType}, hxxp://ip-api[.]com/json
  • [IP address ] C2 and embedded decoded destination examples – 45[.]59[.]160[.]199, 91d840f599206f13
  • [Domains ] Infrastructure referenced in the campaign – ip-api[.]com, portal.xdr.trendmicro.com
  • [File paths ] Suspicious hunting paths for dropped artifacts – .vscodemod.pyd, /.vscode/mod.so
  • [Browser extensions / wallet targets ] Trojanized extension targets – MetaMask, Coinbase Wallet, Phantom
  • [Build paths ] macOS compilation artifact paths embedded in binaries – /Users/administrator/Pictures/Work/py_module_work/build/temp.macosx-10.13-universal2-cpython-312/mod.o, /Users/administrator/Pictures/Work/py_module_work/build/temp.macosx-10.13-universal2-cpython-312/pad.o


Read more: https://www.trendmicro.com/en_us/research/26/e/analyzing-void-dokkaebi-invisibleferret-malware.html