Command Palette

Search for a command to run...

UnylyUnyly
Browse all

Ttphunt

FreeNot checked

Hunt MITRE ATT&CK techniques across logs with a rule pack

GitHubEmbed

About

Hunt MITRE ATT&CK techniques across logs with a rule pack

README

TTPHUNT

TTPHUNT

Hunt MITRE ATT&CK techniques across logs with a rule pack

PyPI CI License: COCL 1.0 Suite

Part of the Cognis Neural Suite.

pip install cognis-ttphunt
ttphunt scan .            # → prioritized findings in seconds

🔎 Example output

Real, reproducible output from the tool — runs offline:

$ ttphunt-emit --version
ttphunt 0.1.0
$ ttphunt-emit --help
usage: ttphunt [-h] [--version] {hunt,rules} ...

Hunt MITRE ATT&CK techniques across logs with a rule pack.

positional arguments:
  {hunt,rules}
    hunt        Scan a log file for ATT&CK techniques.
    rules       List rules in the active pack.

options:
  -h, --help    show this help message and exit
  --version     show program's version number and exit
$ ttphunt-emit rules
ttphunt: 12 rule(s)
  [HIGH    ] T1059.001    ttp-powershell-encoded           PowerShell Encoded Command
  [HIGH    ] T1059.001    ttp-powershell-download-cradle   PowerShell Download Cradle
  [HIGH    ] T1105        ttp-certutil-download            Certutil Used to Download/Decode
  [MEDIUM  ] T1047        ttp-wmic-process-call            WMIC Remote/Local Process Creation
  [CRITICAL] T1490        ttp-bcdedit-recovery-disable     Inhibit System Recovery (bcdedit/vssadmin/wbadmin)
  [MEDIUM  ] T1547.001    ttp-registry-run-key             Run Key Persistence via reg.exe
  [MEDIUM  ] T1053.005    ttp-scheduled-task-create        Scheduled Task Creation
  [HIGH    ] T1218.005    ttp-mshta-execution              Mshta Remote Script Execution
  [MEDIUM  ] T1218.011    ttp-rundll32-suspicious          Rundll32 Proxy Execution
  [HIGH    ] T1070.001    ttp-clear-event-logs             Windows Event Log Cleared
  [MEDIUM  ] T1136.001    ttp-net-user-add                 Local Account Created via net user
  [LOW     ] T1110        ttp-failed-logon-burst           Failed Logon (Brute Force Candidate)

Blocks above are real ttphunt output — reproduce them from a clone.

Usage — step by step

  1. Install (Python 3.9+):

    pip install ttphunt
    
  2. Hunt ATT&CK techniques in a log file (JSON array or JSONL) using the built-in rule pack:

    ttphunt hunt auth.jsonl
    
  3. Tune the hunt. Raise the floor with --min-severity, scope to specific techniques, or supply your own rule pack:

    ttphunt hunt auth.jsonl --min-severity high -t T1110 -t T1078 -r my_rules.json
    
  4. Read or export the output. Emit JSON for tooling, or write an HTML report to a file:

    ttphunt hunt auth.jsonl --format json -o findings.json
    ttphunt hunt auth.jsonl --format html -o report.html
    
  5. Inspect the rules in CI. List the active rule pack to verify coverage as part of a pipeline:

    ttphunt rules --format json | jq '.[].technique'
    

Contents

Why ttphunt?

Hunt MITRE ATT&CK techniques across logs with a rule pack — without standing up heavyweight infrastructure.

ttphunt is single-purpose, scriptable, and self-hostable: point it at a target, get prioritized results in the format your workflow already speaks (table · JSON · SARIF), gate CI on it, and let agents drive it over MCP.

Features

  • ✅ Load Events
  • ✅ Load Events From Text
  • ✅ Load Rules
  • ✅ Hunt
  • ✅ Summarize
  • ✅ Runs on Linux/macOS/Windows · Docker · devcontainer
  • ✅ Ports in Python, JavaScript, Go, and Rust (ports/)

Quick start

pip install cognis-ttphunt
ttphunt --version
ttphunt scan .                       # scan current project
ttphunt scan . --format json         # machine-readable
ttphunt scan . --fail-on high        # CI gate (non-zero exit)

Example

$ ttphunt scan .
  [HIGH    ] TTP-001  example finding             (./src/app.py)
  [MEDIUM  ] TTP-002  another signal              (./config.yaml)

  2 findings · risk score 5 · 38ms

Architecture

flowchart LR
  IN[input] --> P[ttphunt<br/>analyze + score]
  P --> OUT[report]

Use it from any AI stack

ttphunt is interoperable with every popular way of using AI:

  • MCP serverttphunt mcp (Claude Desktop, Cursor, Cognis.Studio, uncensored-fleet)
  • OpenAI-compatible / JSON — pipe ttphunt scan . --format json into any agent or LLM
  • LangChain · CrewAI · AutoGen · LlamaIndex — wrap the CLI/JSON as a tool in one line
  • CI / scripts — exit codes + SARIF for non-AI pipelines

How it compares

Cognis ttphunt typical tools
Self-hostable, no account varies
Single command, zero config ⚠️
JSON + SARIF for CI varies
MCP-native (AI agents)
Polyglot ports (JS/Go/Rust)
Open license ✅ COCL varies

Integrations

Pipes into your stack: SARIF for code-scanning, JSON for anything, an MCP server (ttphunt mcp) for AI agents, and a webhook forwarder for SIEM/Slack/Jira. See docs/INTEGRATIONS.md.

Install — every way, every platform

pip install "git+https://github.com/cognis-digital/ttphunt.git"    # pip (works today)
pipx install "git+https://github.com/cognis-digital/ttphunt.git"   # isolated CLI
uv tool install "git+https://github.com/cognis-digital/ttphunt.git" # uv
pip install cognis-ttphunt                                          # PyPI (when published)
docker run --rm ghcr.io/cognis-digital/ttphunt:latest --help        # Docker
brew install cognis-digital/tap/ttphunt                             # Homebrew tap
curl -fsSL https://raw.githubusercontent.com/cognis-digital/ttphunt/main/install.sh | sh
Linux macOS Windows Docker Cloud
scripts/setup-linux.sh scripts/setup-macos.sh scripts/setup-windows.ps1 docker run ghcr.io/cognis-digital/ttphunt DEPLOY.md (AWS/Azure/GCP/k8s)

Related Cognis tools

Explore the suite → 🗂️ all 170+ tools · ⭐ awesome-cognis · 🔗 cognis-sources · 🤖 uncensored-fleet · 🧠 engram

Contributing

PRs, new rules, and demo scenarios are welcome under the collaboration-pull model — see CONTRIBUTING.md and SECURITY.md.

⭐ If ttphunt saved you time, star it — it genuinely helps others find it.

Interoperability

{} composes with the 300+ tool Cognis suite — JSON in/out and a shared OpenAI-compatible /v1 backbone. See INTEROP.md for the suite map, composition patterns, and reference stacks.

License

Source-available under the Cognis Open Collaboration License (COCL) v1.0 — free for personal, internal-evaluation, research, and educational use; commercial / production use requires a license ([email protected]). See LICENSE.


Cognis Digital · one of 170+ tools in the Cognis Neural Suite · Making Tomorrow Better Today

from github.com/cognis-digital/ttphunt

Installing Ttphunt

This server has no published package — it is built from source. Open the repository and follow its README.

▸ github.com/cognis-digital/ttphunt

FAQ

Is Ttphunt MCP free?

Yes, Ttphunt MCP is free — one-click install via Unyly at no cost.

Does Ttphunt need an API key?

No, Ttphunt runs without API keys or environment variables.

Is Ttphunt hosted or self-hosted?

Self-hosted: the server runs locally on your machine via the install command above.

How do I install Ttphunt in Claude Desktop, Claude Code or Cursor?

Open Ttphunt on unyly.org, pick your client tab (Claude Desktop, Claude Code, Cursor) and press Install — the config is generated automatically, no JSON editing.

Related MCPs

Compare Ttphunt with

Not sure what to pick?

Find your stack in 60 seconds

Author?

Embed badge for your README

Browse similar

All development MCPs