@profullstack/threatcrush 0.13.3 → 0.13.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +35 -26
- package/dist/daemon.js +32 -0
- package/dist/daemon.js.map +1 -1
- package/dist/index.js +43 -12
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -25115,6 +25115,38 @@ var DEFAULT_RULES = [
|
|
|
25115
25115
|
},
|
|
25116
25116
|
enabled: true
|
|
25117
25117
|
},
|
|
25118
|
+
{
|
|
25119
|
+
// A 402 is a paywall saying "pay first". A caller that means to pay gets
|
|
25120
|
+
// one and pays; a podcast app polling a paid feed gets a handful an hour.
|
|
25121
|
+
// Thirty in a minute from one address is a scraper that ignores the answer
|
|
25122
|
+
// and keeps walking URLs: GoogleOther did ~40/min per IP against r4ck's
|
|
25123
|
+
// /api/v1/search on dev2, 2026-09-25. `web-scanner-detection` saw it too,
|
|
25124
|
+
// but it is `medium`, and auto-defence bans at `high` and above, so it fired
|
|
25125
|
+
// every minute and never banned. This one is `high` on purpose.
|
|
25126
|
+
//
|
|
25127
|
+
// It cannot see a proxy swarm that asks once per address; nothing per-IP can.
|
|
25128
|
+
id: "paywall-hammering",
|
|
25129
|
+
title: "Paywall Hammering",
|
|
25130
|
+
description: "Repeated 402 Payment Required responses to the same source",
|
|
25131
|
+
version: "1.0.0",
|
|
25132
|
+
category: "web",
|
|
25133
|
+
severity: "high",
|
|
25134
|
+
source_types: ["log-watcher", "web"],
|
|
25135
|
+
match: {
|
|
25136
|
+
field: "message",
|
|
25137
|
+
operator: "regex",
|
|
25138
|
+
value: "Client error 402:"
|
|
25139
|
+
},
|
|
25140
|
+
threshold: 30,
|
|
25141
|
+
window_seconds: 60,
|
|
25142
|
+
cooldown_seconds: 600,
|
|
25143
|
+
tags: ["web", "scraper", "x402", "paywall"],
|
|
25144
|
+
remediation: {
|
|
25145
|
+
action: "block",
|
|
25146
|
+
description: "Block a scraper that keeps walking a paywall without paying"
|
|
25147
|
+
},
|
|
25148
|
+
enabled: true
|
|
25149
|
+
},
|
|
25118
25150
|
{
|
|
25119
25151
|
id: "port-scan-indicator",
|
|
25120
25152
|
title: "Port Scan Indicators",
|
|
@@ -27919,8 +27951,8 @@ var program2 = new Command();
|
|
|
27919
27951
|
program2.name("threatcrush").description(
|
|
27920
27952
|
`${source_default.green("\u26A1 ThreatCrush")} \u2014 All-in-one security agent
|
|
27921
27953
|
|
|
27922
|
-
|
|
27923
|
-
scan your code,
|
|
27954
|
+
Read your logs and watch inbound connections for live attacks,
|
|
27955
|
+
scan your code, spot-check your URLs, and alert you in real-time.
|
|
27924
27956
|
|
|
27925
27957
|
${source_default.dim("Website:")} ${source_default.green("https://threatcrush.com")}
|
|
27926
27958
|
${source_default.dim("GitHub:")} ${source_default.green("https://github.com/profullstack/threatcrush")}
|
|
@@ -27931,26 +27963,25 @@ ${source_default.dim("Examples:")}
|
|
|
27931
27963
|
${source_default.green("$")} threatcrush monitor ${source_default.dim("# Real-time monitoring")}
|
|
27932
27964
|
${source_default.green("$")} threatcrush tui ${source_default.dim("# Interactive dashboard")}
|
|
27933
27965
|
${source_default.green("$")} threatcrush scan ./src ${source_default.dim("# Scan code for vulns")}
|
|
27934
|
-
${source_default.green("$")} threatcrush pentest URL ${source_default.dim("#
|
|
27966
|
+
${source_default.green("$")} threatcrush pentest URL ${source_default.dim("# Quick web checks on a URL")}
|
|
27935
27967
|
${source_default.green("$")} threatcrush modules install ${source_default.dim("# Install a module")}
|
|
27936
27968
|
${source_default.green("$")} threatcrush update ${source_default.dim("# Update to latest")}
|
|
27937
27969
|
${source_default.green("$")} threatcrush remove ${source_default.dim("# Uninstall completely")}`
|
|
27938
27970
|
).version(PKG_VERSION, "-v, --version", "Show version number").helpOption("-h, --help", "Show this help").addHelpText("after", `
|
|
27939
27971
|
${source_default.dim("\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500")}
|
|
27940
27972
|
${source_default.dim("Modules:")}
|
|
27941
|
-
ThreatCrush uses pluggable security modules.
|
|
27942
|
-
${source_default.green("
|
|
27943
|
-
${source_default.green("
|
|
27944
|
-
${source_default.green("
|
|
27945
|
-
${source_default.green("
|
|
27946
|
-
${source_default.green("pentest-engine")} SQLi, XSS, SSRF, API fuzzing
|
|
27973
|
+
ThreatCrush uses pluggable security modules. Built in:
|
|
27974
|
+
${source_default.green("log-watcher")} nginx access log + syslog, attack signatures
|
|
27975
|
+
${source_default.green("ssh-guard")} Failed logins, brute force, root logins, user enumeration
|
|
27976
|
+
${source_default.green("user-journal")} journald
|
|
27977
|
+
${source_default.green("network-monitor")} Inbound connections (conntrack/ss): port scans, SYN floods
|
|
27947
27978
|
${source_default.green("dns-monitor")} DNS tunneling, DGA detection
|
|
27948
|
-
${source_default.green("
|
|
27949
|
-
|
|
27979
|
+
Plus: ${source_default.green("scan")} (code, secrets, dependency CVEs), ${source_default.green("pentest")} (web checks),
|
|
27980
|
+
auto-defend (fail2ban/nftables/iptables) and alerts (Slack, Discord, email, webhook, PagerDuty).
|
|
27950
27981
|
|
|
27951
27982
|
Browse community modules: ${source_default.green("threatcrush store")}
|
|
27952
27983
|
`);
|
|
27953
|
-
program2.command("monitor").description("
|
|
27984
|
+
program2.command("monitor").description("Watch nginx, auth and syslog for attacks in the foreground").option("-m, --module <modules>", "Comma-separated module filter (e.g. ssh-guard,log-watcher)").option("--tui", "Launch the interactive TUI dashboard").option("--demo", "Run the dashboard on canned events (screenshots, no daemon)").action(async (opts) => {
|
|
27954
27985
|
await monitorCommand({
|
|
27955
27986
|
module: opts.module,
|
|
27956
27987
|
tui: opts.tui,
|