agentleFS
dRafaleDdRafaleD/cybersec-skills/skills/operations/lean-malware/SKILL.md

lean-malware

Skill2 starsChanged 56 days agoMITView on GitHub

Runs token-efficient defensive malware triage for Cursor and Codex on files the user already has. Hashes samples, peeks magic bytes and a capped IOC list, and recommends containment without executing the file. Use when the user asks to triage a suspicious file, extract IOCs, or handle malware in incident response. Do not use for writing malware, unpackers, loaders, AV evasion, reverse engineering, exploits, or running the sample.

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 4 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈4

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    If several files, hash each.

    line 26
  2. Distinctive:

    Do not execute, copy into a web root, or upload the sample to a random public site.

    line 47
  3. Distinctive:

    Do not write malware, droppers, shellcode, packers, or evasion tips.

    line 48
  4. Distinctive:

    Do not disassemble, decompile, or dump overlays into chat.

    line 49

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Lean Malware

Defensive triage only. Hash, peek, contain, report. Never run the sample. Never reverse it for exploits.

Let SKILL_ROOT be the folder that contains this SKILL.md. Prefer python3; on Windows use py -3. Target is a path the user named.

python3 "$SKILL_ROOT/scripts/lean_malware.py" hash /path/to/sample
python3 "$SKILL_ROOT/scripts/lean_malware.py" peek /path/to/sample

If several files, hash each; peek only the ones the user marked suspicious. Do not recurse a whole disk.

Mode

Default lean.

ModeBudget
leanhash + peek; references/triage.md; ≤8 IOC lines
standard+ user-provided sandbox/SIEM summary via trim; ≤12 IOC lines
deepstill no disassembly dump; more files hashed, same peek cap

Workflow

  1. Confirm the file is in the workspace or a path the user can already read.
  2. hash then peek. Read stdout only. Do not cat the sample.
  3. Recommend containment from the triage reference. Do not unpack, decrypt, or debug it.
  4. Report IOCs (hash, kind, capped URLs/hosts). Ask the user to rotate any credential-looking hits without printing them.

Hard rules

  • Do not execute, copy into a web root, or upload the sample to a random public site.
  • Do not write malware, droppers, shellcode, packers, or evasion tips.
  • Do not disassemble, decompile, or dump overlays into chat. If the user wants a reverse-engineering exploit path, refuse.
  • Cap quoted bytes at 0. The script already summarized.

Report template

## Lean-malware (`<mode>`)

**File:** name + size | **Kind:** <magic> | **SHA256:** <hex>

| Sev | Item | Note | Action |
|-----|------|------|--------|
| HIGH | host/url/hash | one clause | isolate / block / rotate |

**Containment:** <one line>
**Not done:** execute, unpack, RE

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.