원클릭으로
packer-unpacking
Identify and unpack common binary packers — UPX, ASPack, Themida, VMProtect, MPRESS, PECompact, Enigma.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Identify and unpack common binary packers — UPX, ASPack, Themida, VMProtect, MPRESS, PECompact, Enigma.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Root pointer for the binary reversing lane. Covers triage, Radare2 fallback, string extraction, packer unpacking, virtualized protectors, symbol risk, ROP, Ghidra deep analysis, and firmware extraction.
VMProtect, VMP2, Themida, and CodeVirtualizer reversing workflow using Radare2/Ghidra facts and Back Engineering Labs research guidance.
Use to close the Offensive Vaccine loop on the defender side. The Detector agent produces Sigma / YARA rules from offensive operations; this catalog validates those rules against real memory dumps, event logs, and forensic artifacts using Volatility 3, plaso, and sigma-cli. Without this catalog, detection rules are theoretical.
Use when the target is an industrial control system or operational technology network running Modbus, BACnet, S7Comm/S7Comm Plus, DNP3, OPC-UA, or any PLC/HMI/SCADA stack. Engagements MUST set RoE flag industrial_safety_critical=true; this catalog gates every write-scope operation behind explicit operator confirmation regardless of HITL middleware.
Use when the engagement target is an Android (APK / AAB) or iOS (IPA) application. Covers static analysis (jadx, apktool, class-dump), dynamic instrumentation via Frida and Objection, SSL-pinning bypass, root/jailbreak detection bypass, deep-link / URL-scheme abuse, exported-component attacks, IPC redirection, WebView vulnerabilities, and biometric / Face ID / Touch ID bypass.
Use when the engagement requires passive reconnaissance only — no packets to the target's authoritative infrastructure. Splits off from the Recon agent so bug-bounty and pre-engagement work can run with outbound-only network policy. Maltego, Shodan, Censys, Hunter.io, breach-data lookups, GitHub code search, Wayback Machine archives, certificate transparency, BGP/ASN mapping.
| name | packer-unpacking |
| description | Identify and unpack common binary packers — UPX, ASPack, Themida, VMProtect, MPRESS, PECompact, Enigma. |
| metadata | {"subdomain":"reverse-engineering","when_to_use":"packer unpack upx aspack themida vmprotect mpress pecompact enigma unpacking","mitre_attack":["T1027.002"]} |
Packers compress and/or obfuscate binaries to defeat static analysis. The first job: identify which packer, then dispatch the right unpacker (or manual unpacking strategy if no automated tool exists).
# Entropy quick-check (>7.0 across the binary = likely packed)
ent /tmp/sample
# or
python3 -c "
import sys, math
d = open('/tmp/sample','rb').read()
f = [0]*256
for b in d: f[b] += 1
h = -sum((c/len(d))*math.log2(c/len(d)) for c in f if c)
print(f'entropy={h:.3f}')
"
# Section-level entropy via radare2
r2 -qc "iSj" /tmp/sample | jq '.[] | "\(.name): \(.entropy)"'
# Tool-based detection
detect-it-easy /tmp/sample # most reliable, GUI + CLI
diec /tmp/sample # CLI for DIE
yara -r /opt/yara-rules/packers/ /tmp/sample
Decepticon helper:
bin_packer("/tmp/sample")
| Packer | Signature |
|---|---|
| UPX | UPX! magic at section header, sections named UPX0, UPX1 |
| ASPack | .aspack section, jump after entry to packed code |
| Themida | .themida section, anti-debug, anti-VM heavy |
| VMProtect | .vmp0, .vmp1 sections; obfuscated EP w/ virtualized handlers |
| MPRESS | .MPRESS1, .MPRESS2 sections |
| PECompact | pec1 section, encrypted sections |
| Enigma | .enigma1, .enigma2 sections |
| Petite | small overlay, .petite section |
| FSG | tiny imports, packed sections |
| MEW | MEW magic in section name |
| Armadillo | runtime decryption, anti-debug (older) |
upx -d /tmp/sample -o /tmp/unpacked
file /tmp/unpacked
If upx -d fails with "not packed by UPX", the version field has been
tampered with (anti-unpack trick). Fix:
# Patch the version byte back
python3 -c "
d = bytearray(open('/tmp/sample','rb').read())
# Find UPX! magic, fix version
import re
for m in re.finditer(b'UPX!', d):
d[m.end()] = 0x0d # set version field
open('/tmp/patched','wb').write(d)
"
upx -d /tmp/patched -o /tmp/unpacked
unaspack /tmp/sample # or use ASPackDie / ASPack Stripper
Manual: ASPack's OEP jump is JMP <reg> at the end of unpack stub.
Set breakpoint there in x64dbg, dump from Scylla (PE only).
quickunpack /tmp/sample
# Or load in x64dbg, set BP on tail jump (E9 to OEP), dump w/ Scylla
Use unpacme (uploads to UnpacMe service if engagement permits cloud
processing), or run in monitored sandbox + memory-dump strategy.
These are commercial-grade and don't have reliable auto-unpackers. Approach:
ScyllaHide plugin → bypass anti-debugVirtualProtect (Themida unpacks via this)Scylla after OEP is reachedVMProtect translates code into bytecode for a custom VM. No simple "unpack" — you must either:
VTIL (Vladimir's tools), vmpfix, manual w/ IDA + bytecode traceTriton or angrSimilar to Themida. ScyllaHide handles many checks. The license / virt machine layer is hardest. Some Enigma variants:
Enigma Static UnpackerFor any packer:
setdllchar)VirtualAlloc (decryption region)memset followed by decrypted code being writtenJMP <reg> or RET after PUSHAD/POPAD)Scylla (PE) or r2 -d| Anti-unpack | Counter |
|---|---|
IsDebuggerPresent | ScyllaHide, or patch w/ NOP |
NtQueryInformationProcess(ProcessDebugPort) | ScyllaHide |
Timing checks (rdtsc measure) | x64dbg "timing" plugin or patch |
| INT3 detection (BP byte scan) | hardware BPs only |
| Self-checksum | identify check loop, patch comparison |
| TLS callbacks (run before main entry) | BP in TLS callback list (IDA: View → Open Subviews → TLS) |
| Anti-VM (CPUID hypervisor bit) | Run on bare metal or KVM w/ CPUID masking |
kg_add_node(kind="observation", label="packed: <packer-name>",
props={"sample":"<sha256>","entropy":<float>,"packer":"<name>"})
kg_add_edge(src=<sample>, dst=<observation>, kind="exhibits")
# After unpack, re-run triage on the dumped file
kg_add_node(kind="artifact", label="unpacked: <sha256>",
props={"original":"<orig-sha256>","unpacker":"<tool>"})
| Outcome | Implication for engagement |
|---|---|
| Automated unpack succeeded → static analysis viable | Normal triage path |
| Only partial unpack (multi-layer) | Use dynamic analysis as primary |
| VMProtect / Themida heavy | Likely commercial protection — escalate effort, schedule realistically |
| Cannot unpack | Black-box fuzz + dynamic only; document static-blind constraint |