rhaist/marq / skills/malware/malware-maldoc
malware-maldoc
VerifiedGuides analysis of a malicious Office or RTF document by extracting VBA macros with olevba, finding the auto-exec trigger, decoding obfuscation, and recovering the dropped payload URL for pivoting. Use when the user has a suspicious .doc/.docm/.xls/.xlsm/.rtf attachment, asks to analyze a phishing document or macro, or needs the second-stage URL from a maldoc.
Malicious document analysis
Static only: extracting a macro does not run it. Stage the doc under /work.
Threat-landscape note: since Microsoft blocked internet-sourced VBA/XL4 macros
by default (2022), classic macro maldocs have declined sharply. Modern "document"
lures now lean on containers + LOLBins that dodge Mark-of-the-Web and macro policy:
LNK inside ISO/IMG/VHD or ZIP, OneNote (.one) with embedded scripts/attachments,
and HTML-smuggling pages that assemble the payload in-browser. Treat a plain
macro-bearing .doc(m)/.xls(m) as one branch, not the default. For the
LNK/HTA/JS/HTML-smuggling/ClickFix lures themselves, load_skill malware-scripts;
if the document arrived by email, load_skill phishing-email-analysis for the
headers and recipient scope. oletools doesn't
parse OneNote (its ftguess only identifies .one); carve the embedded files
off-box with Didier Stevens' onedump.py or pyOneNote (neither is in this image).
LNK/HTML lures are extraction-and-string work, not VBA: pull the embedded command
line / smuggled blob and pivot on it.
Extract & read (olevba, oletools)
olevba <file>dumps the VBA, flags auto-exec triggers and suspicious keywords, and attempts deobfuscation. Read the analysis summary first, then the deobfuscated code.- The kill-chain you're reconstructing: auto-exec → obfuscated builder → network fetch → execution of the next stage.
What to look for
- Auto-exec:
AutoOpen,Document_Open,Workbook_Open,Document_Close, which is where execution starts. - Exec/download primitives:
Shell,WScript.Shell,CreateObject,MSXML2.XMLHTTP/WinHttp,URLDownloadToFile,powershell -enc,mshta,certutil -decode. - Obfuscation:
Chr()/Ch&concatenation,StrReverse, hex/base64 blobs, form/textbox properties used as string storage (olevba--deobfhelps; if a blob survives, decode it withbase64 -dor python3).
Other document types
- RTF:
rtfobj(oletools) for embedded objects/OLE exploits. - PDF: look for
/OpenAction,/JavaScript,/Launch, embedded files. Use the Didier Stevens tools if present, else grep the raw.
Recover & pivot
- Pull the stage-2 URL/IP and any dropped filename; these are your IOCs.
- Run them through
load_skill ioc-pivoting(ORKL, urlscan viasecurity-apis); fetch the stage-2 only from an authorized analysis host. report_finding: evidence = the auto-exec trigger + deobfuscated download line + the C2 URL. Don't fetch live payloads from a production/engagement box.
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack." | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read. | Stars: 196k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report. | Stars: 196k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt. | Stars: 196k | Updated | Claude CodeCodex | Verified | Install |