← Back to ThreatCrush

// DOCS

ThreatCrush Docs

How to install ThreatCrush, run the daemon, and use every CLI command. Run threatcrush help <command> for the full options of any command.

Install

Preferred install: curl -fsSL https://threatcrush.com/install.sh | sh

  • Linux server → installs the CLI, which includes the daemon.
  • Desktop (Linux, macOS, Windows) → installs the CLI and points you to the desktop app, a separate download from GitHub Releases. The desktop app talks to a ThreatCrush daemon on the same machine; log monitoring and firewall bans need Linux.

After install, lifecycle commands are threatcrush update and threatcrush remove.

// QUICK START

Protect a Linux server

  1. threatcrush init — optionally sign in, and write a config for the services on this host.
  2. sudo threatcrush install-service — run the daemon under systemd. It detects attacks and bans their source IPs on its own; no account is needed for that.
  3. threatcrush servers link — optional: send this server's detections, findings and bans to your organization's dashboard.

// COMMANDS

Command reference

Everything below ships in the CLI on npm, except commands marked New, which arrive in the next release.

Set up

threatcrush init

Offers to sign you in, detects SSH, nginx, Apache, PostgreSQL, MySQL, Redis and BIND on this host, and writes a config for them.

Shipped
threatcrush login [-e <email>]

Sign in to your threatcrush.com account.

Shipped
threatcrush logout

Clear the stored threatcrush.com credentials.

Shipped
threatcrush whoami

Show the account you are signed in as.

Shipped

Detect and run the daemon

threatcrush monitor [-m <modules>] [--tui]

Watch nginx, auth, syslog and journald for attacks in the foreground. -m limits it to some modules (e.g. ssh-guard,log-watcher).

Shipped
threatcrush tui [--demo]

Interactive dashboard connected to the daemon (alias: dashboard). --demo runs on canned events.

Shipped
sudo threatcrush install-service

Install the threatcrushd systemd unit so the daemon starts on boot. uninstall-service removes it.

Shipped
threatcrush start | stop | restart

Start the daemon in the background, stop it, or restart it.

Shipped
threatcrush daemon

Run threatcrushd in the foreground — the ExecStart for systemd or Docker.

Shipped
threatcrush status

Show daemon status and loaded modules.

Shipped
threatcrush logs

Tail the daemon logs.

Shipped
threatcrush rules [list | show <id>]

List the detection rules, or show one. Add your own JSON rules in /etc/threatcrush/rules.d.

Shipped

Respond

threatcrush block <ip> [--ttl <duration>]

Ban an IP at the firewall (nftables, iptables or fail2ban), optionally for a time such as 30m, 1h or 1d.

Shipped
threatcrush unblock <ip>

Lift a ban.

Shipped
threatcrush blocklist

Show active bans.

Shipped
threatcrush allowlist [list | add <ip/cidr> | remove <ip/cidr>]

Manage the addresses the daemon will never ban.

Shipped
threatcrush harden [--json]

Check SSH password and root login, sshd weaknesses, automatic security updates, an active firewall, risky exposed ports and fail2ban.

Shipped

Scan

threatcrush scan [path]

Scan a codebase for secrets and risky code patterns. Options: -f text|json|sarif, -o <file>, --fail-on <severities>, --deps (check lockfile versions against OSV.dev), --exclude <glob>, --missing-controls, --path-prefix <prefix>.

Shipped
threatcrush pentest <url>

Check a URL's security headers, CSP, CORS, cookie flags, banners, directory listings and error leaks, then probe for SQL errors, path traversal and unsafe HTTP methods.

Shipped

Organizations and the cloud dashboard

threatcrush orgs [list | create <name> | use <slug>]

List your organizations, create one, or switch the current one (alias: org).

Shipped
threatcrush servers list

List the servers in the current organization (alias: server).

Shipped
threatcrush servers link [--org <id|slug>] [--name <name>]

Link this machine to a server in your organization, reusing one with the same hostname or creating it. While signed in and linked, the daemon sends detections, hardening findings, bans and heartbeats to the dashboard, and carries out bans you queue there.

New
threatcrush servers unlink

Stop sending this machine's data to the dashboard. threatcrush status shows whether a machine is linked.

New
threatcrush properties [list | add | remove | run | runs | import]

Manage the targets (URLs, APIs, domains, IPs, repos) in the current organization, run scans and pentest checks against them, see run history, and bulk-import from .json, .csv or .tsv (alias: props).

Shipped
threatcrush connect [target]

Open an SSH session to a server in your organization (--org, -u, -p, -i).

Shipped

Modules

threatcrush modules [list | install | remove | available] [name]

Manage security modules.

Shipped
threatcrush store

Browse the module marketplace.

Shipped
threatcrush store search <query>

Search the marketplace.

Shipped
threatcrush store publish <url>

Submit a module from a git or web URL. Publishing is free; listings go live after review.

Shipped

Install lifecycle

threatcrush update [--cli | --modules | --desktop]

Update the CLI and the installed bundle.

Shipped
threatcrush remove

Uninstall ThreatCrush and the installed bundle (alias: uninstall).

Shipped

// NOT YET

Not available yet

  • Code-signed macOS and Windows desktop builds — today they trigger Gatekeeper and SmartScreen warnings
  • The mobile app in the App Store and Google Play
  • The browser extension in the Chrome, Firefox and Edge stores — sideload it from source for now
  • The @threatcrush/sdk package on npm

// MODULE AUTHORS

Building and publishing modules

If you want to contribute to the marketplace, start with the module author docs. They explain how the store works today, what metadata we fetch, and how to publish through the web UI or CLI.

ThreatCrush