hunt

hunt is a command for Claude Code from mukul975/Threatswarm. It costs 12 tokens per session (754 once invoked), scanned A, original, MIT.

A command for running a threat hunt from a stated hypothesis. A threat hunt is a structured search through system and security logs for signs of an attacker, using MITRE ATT&CK technique codes to organize the investigation.

In plain words
What is it for?
Use it to investigate suspicious behavior over a chosen time period, map the behavior to ATT&CK, query available logs, and save the investigation evidence and results.
Why use it?
It turns a broad suspicion into recorded hypotheses, queries, evidence, and findings. It also connects common activity such as script execution or credential theft to standard ATT&CK techniques.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/mukul975/threatswarm/hunt
Clone the repo
git clone --depth 1 https://github.com/mukul975/Threatswarm

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for hunt

README.md
[![agentmods](https://agentmods.dev/badge/commands/mukul975/threatswarm/hunt.svg)](https://agentmods.dev/commands/mukul975/threatswarm/hunt)
Your own site
<a href="https://agentmods.dev/commands/mukul975/threatswarm/hunt"><img src="https://agentmods.dev/badge/commands/mukul975/threatswarm/hunt.svg" alt="Measured on agentmods" height="20"></a>
Per session 12 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 754 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00012 $0.00754
Opus 5 $0.00006 $0.00377
Sonnet 5 $0.00002 $0.00151
Haiku 4.5 $0.00001 $0.00075

Measured 6d ago against content hash a3466dbdc923, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

hunt scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/hunt.md · 70 lines

What it actually says

Run threat hunt with hypothesis: $ARGUMENTS

Parse $ARGUMENTS for: hypothesis text, optional timeframe (e.g., "last 7 days"), affected systems.

  1. Hunt Setup:

    ═══════════════════════════════════════════════
    THREAT HUNT START
    Hypothesis: $ARGUMENTS
    Timestamp:  $(date -u +%Y-%m-%dT%H:%M:%SZ)
    Log dir:    evidence/$(date +%Y%m%d)/hunt/
    ═══════════════════════════════════════════════
    

    Create: mkdir -p evidence/$(date +%Y%m%d)/hunt/{hypotheses,queries,findings}

  2. Map Hypothesis to ATT&CK: Identify relevant TTPs from the hypothesis:

    • PowerShell / script execution → T1059.001, T1059.003
    • Lateral movement → T1021.001 (RDP), T1021.002 (SMB), T1021.006 (WinRM)
    • Credential dumping → T1003.001 (LSASS), T1003.003 (NTDS)
    • Persistence → T1547.001 (Run Keys), T1053.005 (Scheduled Task)
    • C2 beaconing → T1071.001 (HTTP/S), T1071.004 (DNS)
    • Data exfiltration → T1041 (exfil over C2), T1048 (exfil via protocol)
  3. Invoke threat-hunter Agent: Delegate with:

    • Full hypothesis text from $ARGUMENTS
    • ATT&CK TTP mapping
    • Available log sources (auth.log, syslog, nginx access, Windows Event Logs, pcaps)
    • Timeframe context
  4. Query Execution: The threat-hunter agent runs ATT&CK-aligned queries:

    • Linux auth log pattern matching
    • Web server log anomaly detection
    • Network traffic analysis (if pcaps available in evidence/)
    • Windows Event Log correlation (if accessible)
  5. Cross-Source Correlation: Correlate findings across log sources:

    • Match IP addresses across auth, web, and network logs
    • Timeline reconstruction of suspicious activity
    • Confidence scoring per finding
  6. Write Hunt Report: Output to evidence/$(date +%Y%m%d)/hunt/hunt_report.md:

    • Hypothesis tested
    • Queries run with results
    • Confirmed/likely/possible findings
    • IOCs extracted (IPs, domains, hashes)
    • Recommended follow-up hunts
  7. Print Summary:

    ═══ HUNT RESULTS ═══════════════════
    Hypothesis: [text]
    ATT&CK TTPs: [T1234, T1235...]
    Findings Confirmed: X
    Findings Possible:  X
    IOCs Extracted:     X
    Report: evidence/$(date +%Y%m%d)/hunt/hunt_report.md
    ════════════════════════════════════
    

If no evidence/ files exist and no log access is configured, output:

⚠ No log sources found. Configure log paths or run recon first.
Available: /var/log/auth.log, /var/log/nginx/access.log, pcap files in evidence/
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 6d ago First seen · 70 lines · 12 tokens per session scan A a3466dbdc923

Subscribe to this mod's changes

hunt is a command published in the GitHub repository mukul975/Threatswarm (77 stars, last pushed 4mo ago), licensed MIT. It adds 12 tokens to every session and 754 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other commands, from other repositories

bypass-403

Probe a 403/401 endpoint with the most-paid bypass tricks (header injection, path encoding, method swap, WAF fingerprint, vendor-specific). Wraps byp4xx when installed; otherwise runs a built-in matrix of 38+ techniques. Usage: /bypass-403 | /bypass-403 -l.

Awarexone/Agentic-Bug-Hunter · 0 tokens

spray

Password spray with hard guards — typed-hostname confirmation, lockout warning, audit log. Modes: http-form (custom login page), oauth (password grant), o365 + okta (via TREVORspray). Default delay 30min/round + 60s jitter. Usage /spray --mode --users --passes.

Awarexone/Agentic-Bug-Hunter · 0 tokens

report

Write a submission-ready bug bounty report. Generates H1/Bugcrowd/Intigriti/Immunefi format with CVSS 3.1 score, proof of concept, impact statement, and remediation. Run /validate first. Usage: /report.

Awarexone/Agentic-Bug-Hunter · 0 tokens

triage

Quick 7-Question Gate triage on a finding before writing a report. Kills N/A submissions before they happen. Faster than /validate — for quick go/no-go decisions. Usage: /triage.

Awarexone/Agentic-Bug-Hunter · 0 tokens

validate

Validate a finding — runs 7-Question Gate + 4-gate checklist. Kills weak findings before report writing. Prevents N/A submissions that hurt validity ratio. Usage: /validate.

Awarexone/Agentic-Bug-Hunter · 0 tokens

llm-redteam

LLM red-team corpus runner — fires categorized prompt-injection / jailbreak / system-prompt-leak / data-exfil / indirect-injection / guardrail-bypass payloads at a chat endpoint and canary-detects which land. Usage: /llm-redteam --url --field message [--category jailbreak].

Awarexone/Agentic-Bug-Hunter · 0 tokens