A deep dive into a malware sample hiding inside a fake PDF — emoji-obfuscated batch scripts, C2 communication, and payloads embedded in JPEGs using steganography. I received a suspicious file that didn’t look right. Embedded files weren’t structured normally — so I spun up a Windows sandbox VM and started digging. The sample arrived disguised as a PDF. It was actually an LZH archive — a pretty uncommon format, which is exactly the point. The compression also uses encryption to slip past automatic detection. First anti-detection measure: check. Inside: a The first thing the batch script does is copy itself into the Windows Startup folder: Simple, effective. Every time the system boots, You can detect or disable this manually by checking The batch file itself is obfuscated using emoji substitution — variables are named with emojis, making the script unreadable at a glance: At the bottom of the file, those emojis get substituted out: Which resolves to a base64 string, and ultimately the C2 server address. Weirdly enough, the server’s directory was fully exposed. Inside it: the same There was also a Death Note reference apparently left on purpose. Either a flex or a lure for curious analysts. Following the chain leads to an HTML file and This is a classic JSFuck-style encoding — constructing strings character by character from array property names. The file is massive and still needs full deobfuscation. Running the sample through Hybrid Analysis confirmed: Collected files: Something felt off about the image files. Running 4.3 MB for a 1080p JPEG. That’s not normal. Running There’s hidden data embedded inside the image. The Death Note JPEG isn’t just bait — it’s carrying a payload. Classic steganography. The other images likely carry data too. The executables in the C2 directory look like honeypots — meant to catch analysts who poke around carelessly. This is just the surface. Still pending: The actual payload is probably inside those JPEGs. I’ll cover the extraction and reverse engineering in a follow-up article. Full Hybrid Analysis scan: View report Malware Analysis: Persistence, Obfuscation & Steganography
The File
.bat file. The entry point.
Persistence via Startup Folder
@echo off
setlocal
set "scriptPath=%~f0"
set "desiredName=slappers.bat"
set "startupFile=%APPDATA%\Microsoft\Windows\Start Menu\Programs\Startup\%desiredName%"
copy "%scriptPath%" "%startupFile%" >nul 2>&1
endlocalslappers.bat runs. No payload is stored locally — it gets pulled from a C2 server at runtime. This keeps the disk footprint clean and makes static detection harder.
%APPDATA%\Microsoft\Windows\Start Menu\Programs\Startup\.
Obfuscation with Emojis
@%additive%e%bigwiggery%c%erraticalness%h%maize%o%aromochelys% %pings%o%Gg%f%superfamilies%f%enouncement%set "misdirection=%misdirection:🖼💪😋🖹🎆⚞🐴🍬🔆🔗♌🔷🌄♡🍏=%"
Exposed C2 Directory
opa.bat file we were analyzing, a bunch of .txt, .vbs, .js files, and several images.
JavaScript Obfuscation
rems2.js, which points to a Pastebin-like site hosting heavily obfuscated JavaScript:var Ummon = ([]+[
([]["hierarchically"]+[])[0] + ([]["saone"]+[])[1] + ([]["twinchargers"]+[])[2] +
([]["downstage"]+[])[3] + ([]["saltiered"]+[])[4] + ([]["nonmodern"]+[])[5] +
([]["Feisal"]+[])[6] + ([]["saoneMap"]+[])[7] + ([]["marbleized"]+[])[8] +
([]["slice"]+[])[9]]["saltiered"])[0];
Hybrid Analysis Results
Finding Detail File types .bat, .js, .vbsPurpose Persistence, remote file fetching, C2 setup Suspicious files .txt, .vbs, and image files potentially hiding payloadsObfuscated scripts Especially rems2.js
opa.batrems2.js, asim.js4sar.vbs, OK.vbs4sar.txt, ascn.txt, ast0603.txt, and more01.jpg, n01.jpg, new_image.jpg, and others
Steganography in the Images
exiftool on n02.jpg:File Name : n02.jpg
File Size : 4.3 MiB
File Type : JPEG
Image Width : 1920
Image Height : 1080
Megapixels : 2.1binwalk confirmed it:DECIMAL HEXADECIMAL DESCRIPTION
--------------------------------------------------------------------------------
0 0x0 JPEG image data, JFIF standard 1.01
748616 0xB6C48 Sega MegaDrive/Genesis raw ROM dump, Name: "3sAAApv9wAACgoFL"
1415119 0x1597CF ZBOOT firmware header, header size: 32 bytes, load address: 0x47415151
What’s Next
rems2.js and 4sar.vbs
malware reverse-engineering steganography obfuscation security