←
Moonlock Lab663 posts
Moonlock Lab avatar

Moonlock Lab

@moonlock_lab

Malware research lab @moonlock_com Assembled by @macpaw to detect and study cybersecurity threats.

◷ Joined June 2023▧ 330 Photos and videos
Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Nov 12

IOCs 🧙 398734fdf3782026cdc15b49cf70363064f0a129ebbf0e757e6405216f8a4fdf d0599edfb98dbc82dab92eb6322f53ef39e14aefe5abdb3d1b2ffdf0cf1b9ec5 78d0dcec876573f0f34988613904ea250873332872bef434523a76f460e78696 138.226.247[.]154 147.189.173[.]61:7276 hxxp://138.226.247[.]154:80/session/101caba147663afe TRON wallet: TYvH1r8AMJjjGsjMpQPoBW3TDCJ5CWWD47 TRON memo: 9c59f5bd119004e6e335af486ef80df65a3881546e9c85cdd2e4a10ef7d12fa3 BSC tx: 0x5a3881546e9c85cdd2e4a10ef7d12fa39c59f5bd119004e6e335af486ef80df6 ~/.vs_cache/loader.log Persistence: ~/Library/Application Support/AppleAccountSync/AppleAccountSync.app ~/Library/LaunchAgents/com.AppleAccountSync.plist

Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Nov 12

10/ Persistence: Windows Run key + wscript ("Microsoft Realtime Agreegator"), macOS LaunchAgent com.AppleAccountSync, Linux autostart "unixkernalloader". A child process can also bulk-upload files to a 2nd server, 147.189.173[.]61:7276.

Post attachment
Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Nov 12

9/ A few minutes after start it downloads a keylogger agent from hxxp://138.226.247[.]154:443/download-app (macOS/Linux) or /download-win-key (Windows), plain HTTP on port 443. On command, Windows hosts can also get a hidden remote-admin tool (client32.ini config).

Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Nov 12

8/ Platform tricks: on Windows it fetches /download-abe-payload to recover Chrome's app-bound encryption key. On macOS a LaunchAgent starts headless Chrome with remote debugging, and the malware reads files, incl. login.keychain-db, through it.

Post attachmentPost attachment
Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Nov 12

7/ Theft targets: browser logins, cookies and data of 70 wallet extensions (MetaMask etc.); ~/.ssh, ~/.aws, ~/.azure, ~/.config/gcloud; shell history; files named like seed, mnemonic, wallet, private key, *.pem. Cloud and SSH folders go up right after the first connect.

Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Nov 12

6/ Another related sample is a Node.js client (v1.6.20). It registers the host with the C2 over socket\.io, then takes operator commands: shell (incl. SSH, MySQL, Docker sessions), file browsing and upload, disk search for secrets, keylogger, kill browsers, update, self-delete.

Post attachment
Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Nov 12

5/ Stage 2 ("tiny loader", 4.7 KB) does one thing: GET hxxp://138.226.247[.]154/session/<token> .. and run whatever comes back with new Function, as raw JS or JSON {"sessions": "<js>"}. That's Stage 3. Both stages log errors to ~/.vs_cache/loader.log.

Post attachment
Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Nov 12

4/ That's a two-hop dead drop resolver: • TRON memo = pointer • BSC tx input = encrypted payload The operator swaps Stage 2 by posting a new BSC tx + memo. The Stage 1 file never changes, and the loader reads plain transaction data, no contract call.

Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Nov 12

3/ Next it asks a public BSC node (eth_getTransactionByHash) for that transaction and reads its input data (~3.3 KB of hex). Decode: hex → reverse → XOR with a hardcoded GUID key → marker "BCGZ1|" → base64 → gunzip. Result: Stage 2 JavaScript, run via new Function.

Post attachmentPost attachment
Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Nov 12

2/ Stage 1 is an obfuscated script (obfuscator\.io). It asks TronGrid for the latest outgoing transaction of a hardcoded TRON wallet and reads its memo. The memo isn't the payload, it's a pointer. Swap its two halves, hex-decode and get a BSC transaction hash.

Post attachment
Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Nov 12

1/ We analyzed few stages of a Node.js #macOS loader that hides its next stage on public blockchains and pulls it only at runtime: Stage 1 → TRON memo → BSC tx → Stage 2 → HTTP C2 → Stage 3 FUD on VT static engines as of now, shared by @malwrhunterteam. More info below👇

Post attachmentPost attachment
Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Oct 29

IOCs 🧙 a1be741da7083f06e2e67b2ea5e854af4b780bc1af077b9d1220b288abee2584 172.197.216[.]135

Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Oct 29

11/ Later, @malwrhunterteam also shared that there is an IP: 172.197.216[.]135 - which does not have any related macOS samples (yet?), but we can clearly see "Jocky" files communicating with it being Win/Linux executables.

Post attachment
Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Oct 29

10/ The cross-platform tell. A macOS binary ships Windows-forensics parsers: _j_evtx_parse, _j_lnk_parse, _j_mft_parse, _j_usn_parse, _j_regf_parse, _j_prefetch_parse. Plus a built-in _j_yara_scan / _j_sigma_hunt engine. Looks like a collection/hunting framework, not a smash-and-grab stealer .. We cannot however exclude red-teaming operations here, but still something of this kind is not expected on regular user's endpoint.

Moonlock Lab avatar
Moonlock Lab@moonlock_lab·Oct 29

9/ It won't run where it's watched. A 15-function sandbox suite:  _j_sandbox_hypervisor, _j_sandbox_vm_mac, _j_sandbox_time_accel, _j_sandbox_debugger, _j_sandbox_short_uptime → _j_sandbox_verdict. Plus self-morphing: _j_morph_mutate / _j_morph_gen / _j_morph_exec.