Skip to content

armgit / AiSOC

Public Imported from GitHub
0

Open-source AI Security Operations Center: alert fusion, LLM-agent triage, MITRE ATT&CK investigation, and a replayable decision ledger for every agent step. Self-hostable, runs with no API keys, MIT licensed. Ships an MCP server for Claude, Cursor and Continue.

fix(detections): a rule id named one rule in the engine and another in the catalogue (#722)

Beenu Arora2ebeda144015
diff --git a/.github/workflows/validate-detections.yml b/.github/workflows/validate-detections.yml
index 8ae98b966..e5734857d 100644
--- a/.github/workflows/validate-detections.yml
+++ b/.github/workflows/validate-detections.yml
@@ -38,6 +38,15 @@ jobs:
python3 -m pip install --quiet pytest
python3 -m pytest tests/test_detection_id_stability.py -q
+ - name: The committed pack must be what the generator emits
+ # The lock made ids position-independent but nothing reconciled it
+ # against the YAML already on disk, and no gate compared the two. The
+ # committed pack fell 45 network ids behind, so the id the engine
+ # stamps onto an alert and the id the catalogue publishes for the same
+ # rule named different rules. Unreviewed drift in a generated artifact
+ # is not cosmetic when the artifact is a join key.
+ run: python3 scripts/generate_detections.py --check
+
- name: Run detection rule validator (strict fixture replay)
run: python3 scripts/validate_detections.py --strict-fixtures
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 752e5968c..5aef4e794 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -365,24 +365,41 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
eval, not code. Marking it done would be the exact failure the program exists
to prevent.
-### Known
-
-- `scripts/generate_detections.py` still does not reproduce the committed
- detection pack, and the reason changed. Ids are no longer positional — #697
- pinned `(category, slug) → rule_id` in `detections/rule-ids.lock.json` — but
- **nothing reconciled the lock against the YAML already on disk**, and the
- `--check` mode that would have caught it was never written (nothing outside
- the generator references the lock). Running the generator on a clean checkout
- rewrites 57 files and moves 45 network rule ids.
- The consequence is worse than a regeneration hazard: the engine
- (`services/fusion/app/data/detection_ruleset.json`, which fires and stamps
- the id onto the alert) and the published projection **disagree about which
- rule owns those 45 ids**. `det-network-037` is "DNS TXT Response Over 250
- Bytes From Non-Resolver Host" to the engine and "DNS Tunnel Indicator: Long
- Hex Subdomain Sequence" in the YAML and `marketplace/index.json`, so an
- analyst who takes a rule id off an alert and looks it up in the catalogue
- reads a different rule's description, false-positive notes and playbook. This
- is precisely the harm the lock's own docstring warns about.
+- **A rule id named one rule in the engine and a different one in the
+ catalogue.** #697 made ids position-independent by pinning
+ `(category, slug) → rule_id` in `detections/rule-ids.lock.json`, but nothing
+ reconciled the lock against the YAML already on disk and the `--check` mode
+ was never written, so the committed pack fell **45 network rule ids** behind
+ the generator. Because the id is the join key between an alert and its
+ catalogue entry, the effect was not a stale file: `det-network-037` fired as
+ "DNS TXT Response Over 250 Bytes From Non-Resolver Host" and published — in
+ the YAML, `marketplace/index.json` and the curated coverage manifest — as
+ "DNS Tunnel Indicator: Long Hex Subdomain Sequence". An analyst taking a rule
+ id off an alert and looking it up read a different rule's description,
+ false-positive notes and playbook. Precisely the harm the lock's own
+ docstring warns about.
+ Three things were wrong at once, and each hid the next:
+ - `export_detection_ruleset.py` still computed ids **positionally**
+ (`seen[category] += 1`) under a comment saying it mirrored
+ `generate_detections.py` — true when written, false once the generator
+ moved to the lock. Two generators with two numbering schemes. It reads the
+ lock now, so there is one source of id truth, and inserting a spec no
+ longer moves an id the alert table already references.
+ - `generate_detections.py` had no `--check`, so nobody could see the drift.
+ It has one, it reports moved ids separately from other changes because a
+ moved id is the serious case, and it runs in
+ `validate-detections.yml`.
+ - `tests/test_detection_id_stability.py` compared `assign_ids()` output
+ against the lock — and `assign_ids()` reads the lock, so for the property
+ that matters the comparison was circular. Six tests passed throughout,
+ under a docstring describing this exact failure. Four new tests compare the
+ published surfaces against **each other** in both directions: YAML against
+ the lock, the engine against the lock, and — stating the user-visible
+ property directly — that an id names the same rule in the engine and in the
+ catalogue. The reordering test had to *reorder* specs rather than assert a
+ re-export is a no-op, because the lock was seeded from the current spec
+ order, so the two schemes agree until the day someone inserts a rule; it
+ moves 81 engine ids against the old exporter.
## [8.0.0] — 2026-09-22
diff --git a/apps/docs/docs/detections/coverage.md b/apps/docs/docs/detections/coverage.md
index 0e73dbb9b..75309b659 100644
--- a/apps/docs/docs/detections/coverage.md
+++ b/apps/docs/docs/detections/coverage.md
@@ -11,7 +11,7 @@ sidebar_position: 2
# Detection Coverage
-Generated: `2026-09-22T15:54:13Z`
+Generated: `2026-09-23T14:16:45Z`
## Headline numbers
diff --git a/apps/web/public/marketplace/curated.json b/apps/web/public/marketplace/curated.json
index f3368bd94..270a3324f 100644
--- a/apps/web/public/marketplace/curated.json
+++ b/apps/web/public/marketplace/curated.json
@@ -1,7 +1,7 @@
{
"$schema": "https://aisoc.example.com/schemas/curated/v1.json",
"version": "1.0.0",
- "generated": "2026-09-22T15:54:13Z",
+ "generated": "2026-09-23T14:16:45Z",
"stats": {
"considered": 1054,
"eligible": 1051,
@@ -160,7 +160,7 @@
"det-identity-160",
"det-network-004",
"det-network-026",
- "det-network-075",
+ "det-network-076",
"mitre-car-car-2013-04-002",
"mitre-car-car-2013-07-001",
"mitre-car-car-2013-09-003",
@@ -197,10 +197,10 @@
"det-network-005",
"det-network-022",
"det-network-030",
- "det-network-063",
"det-network-064",
"det-network-065",
- "det-network-069",
+ "det-network-066",
+ "det-network-070",
"mitre-car-car-2013-01-003",
"mitre-car-car-2013-04-002",
"mitre-car-car-2013-05-003",
@@ -264,7 +264,7 @@
"det-endpoint-175",
"det-endpoint-270",
"det-identity-152",
- "det-network-054",
+ "det-network-055",
"mitre-car-car-2013-04-002",
"sigmahq-sigma-b593fd50-7335-4682-a36c-4edcb68e4641"
],
@@ -10301,7 +10301,7 @@
"has_executable_body": true
},
{
- "id": "det-network-054",
+ "id": "det-network-055",
"name": "Large HTTP POST From Workstation To Public IP",
"path": "detections/network/net-http-large-post-from-workstation.yaml",
"tier": "native",
@@ -10326,7 +10326,7 @@
"has_executable_body": true
},
{
- "id": "det-network-063",
+ "id": "det-network-064",
"name": "SMB Version 1 Negotiated In Network Flow",
"path": "detections/network/net-smbv1-egress.yaml",
"tier": "native",
@@ -10351,7 +10351,7 @@
"has_executable_body": true
},
{
- "id": "det-network-064",
+ "id": "det-network-065",
"name": "SMB Write To NETLOGON Share",
"path": "detections/network/net-smb-write-netlogon.yaml",
"tier": "native",
@@ -10376,7 +10376,7 @@
"has_executable_body": true
},
{
- "id": "det-network-065",
+ "id": "det-network-066",
"name": "SMB Write To SYSVOL Share From Non-DC",
"path": "detections/network/net-smb-write-sysvol.yaml",
"tier": "native",
@@ -10401,7 +10401,7 @@
"has_executable_body": true
},
{
- "id": "det-network-069",
+ "id": "det-network-070",
"name": "WinRM HTTPS From Workstation To DC",
"path": "detections/network/net-winrm-ssl-from-workstation.yaml",
"tier": "native",
@@ -10426,7 +10426,7 @@
"has_executable_body": true
},
{
- "id": "det-network-075",
+ "id": "det-network-076",
"name": "RADIUS Authentication Used PAP (Cleartext Password)",
"path": "detections/network/net-radius-pap-clear.yaml",
"tier": "native",
diff --git a/apps/web/public/marketplace/index.json b/apps/web/public/marketplace/index.json
index c5834bd98..e1bd31249 100644
--- a/apps/web/public/marketplace/index.json
+++ b/apps/web/public/marketplace/index.json
@@ -1,7 +1,7 @@
{
"$schema": "https://example.com/schemas/marketplace/v1.json",
"version": "1.0.0",
- "generated": "2026-09-22T15:54:12Z",
+ "generated": "2026-09-23T14:14:28Z",
"categories": [
{
"id": "playbooks",
@@ -47840,6 +47840,30 @@
{
"id": "det-network-037",
"type": "detection",
+ "name": "DNS TXT Response Over 250 Bytes From Non-Resolver Host",
+ "description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS TXT Response Over 250 Bytes From Non-Resolver Host'. Watch the 1 documented false-positive case before tuning.",
+ "version": "1.0.0",
+ "author": "AiSOC",
+ "tags": [
+ "tlp.white"
+ ],
+ "severity": "medium",
+ "category": "network",
+ "mitre_techniques": [
+ "T1071.004",
+ "T1048.003"
+ ],
+ "log_source": "dns",
+ "playbook": "tpl-command-and-control",
+ "verified": true,
+ "source": "core",
+ "tier": "stable",
+ "enabled": true,
+ "path": "detections/network/dns-txt-record.yaml"
+ },
+ {
+ "id": "det-network-038",
+ "type": "detection",
"name": "DNS Tunnel Indicator: Long Hex Subdomain Sequence",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS Tunnel Indicator: Long Hex Subdomain Sequence'. Watch the 1 documented false-positive case before tuning.",
"version": "1.0.0",
@@ -47861,7 +47885,7 @@
"path": "detections/network/net-dns-tunnel-pattern-len.yaml"
},
{
- "id": "det-network-038",
+ "id": "det-network-039",
"type": "detection",
"name": "DNS-Over-HTTPS Egress To Non-Sanctioned Resolver",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS-Over-HTTPS Egress To Non-Sanctioned Resolver'. Watch the 1 documented false-positive case before tuning.",
@@ -47884,7 +47908,7 @@
"path": "detections/network/net-dns-doh-non-resolver.yaml"
},
{
- "id": "det-network-039",
+ "id": "det-network-040",
"type": "detection",
"name": "DNS-Over-TLS Egress To Public IP",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS-Over-TLS Egress To Public IP'. Watch the 1 documented false-positive case before tuning.",
@@ -47907,7 +47931,7 @@
"path": "detections/network/net-dns-dot-non-resolver.yaml"
},
{
- "id": "det-network-040",
+ "id": "det-network-041",
"type": "detection",
"name": "DNS Query For .onion Address",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS Query For .onion Address'. Watch the 1 documented false-positive case before tuning.",
@@ -47930,7 +47954,7 @@
"path": "detections/network/net-dns-tor-onion.yaml"
},
{
- "id": "det-network-041",
+ "id": "det-network-042",
"type": "detection",
"name": "DNS Fast-Flux Pattern (Many A Records, Short TTL)",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS Fast-Flux Pattern (Many A Records, Short TTL)'. Watch the 1 documented false-positive case before tuning.",
@@ -47953,7 +47977,7 @@
"path": "detections/network/net-dns-fast-flux.yaml"
},
{
- "id": "det-network-042",
+ "id": "det-network-043",
"type": "detection",
"name": "DNS Rebinding Indicator (Public\u2192RFC1918 In Same TTL Window)",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS Rebinding Indicator (Public\u2192RFC1918 In Same TTL Window)'. Watch the 1 documented false-positive case before tuning.",
@@ -47976,7 +48000,7 @@
"path": "detections/network/net-dns-rebinding.yaml"
},
{
- "id": "det-network-043",
+ "id": "det-network-044",
"type": "detection",
"name": "HTTP CONNECT Method Toward Public IP",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'HTTP CONNECT Method Toward Public IP'. Watch the 1 documented false-positive case before tuning.",
@@ -47999,7 +48023,7 @@
"path": "detections/network/net-http-connect-public-ip.yaml"
},
{
- "id": "det-network-044",
+ "id": "det-network-045",
"type": "detection",
"name": "HTTP User-Agent Matches PowerShell Default",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'HTTP User-Agent Matches PowerShell Default'. Watch the 1 documented false-positive case before tuning.",
@@ -48022,7 +48046,7 @@
"path": "detections/network/net-http-userag-powershell.yaml"
},
{
- "id": "det-network-045",
+ "id": "det-network-046",
"type": "detection",
"name": "curl/wget User-Agent From Workstation Subnet",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'curl/wget User-Agent From Workstation Subnet'. Watch the 1 documented false-positive case before tuning.",
@@ -48045,7 +48069,7 @@
"path": "detections/network/net-http-userag-curl-internal.yaml"
},
{
- "id": "det-network-046",
+ "id": "det-network-047",
"type": "detection",
"name": "HTTP Host Header Is IP Literal",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'HTTP Host Header Is IP Literal'. Watch the 1 documented false-positive case before tuning.",
@@ -48068,7 +48092,7 @@
"path": "detections/network/net-http-host-header-ip.yaml"
},
{
- "id": "det-network-047",
+ "id": "det-network-048",
"type": "detection",
"name": "TLS Client Offered TLS 1.0 Or 1.1",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'TLS Client Offered TLS 1.0 Or 1.1'. Watch the 1 documented false-positive case before tuning.",
@@ -48091,7 +48115,7 @@
"path": "detections/network/net-tls-old-client-version.yaml"
},
{
- "id": "det-network-048",
+ "id": "det-network-049",
"type": "detection",
"name": "HTTPS Connection To IP Without SNI",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'HTTPS Connection To IP Without SNI'. Watch the 1 documented false-positive case before tuning.",
@@ -48114,7 +48138,7 @@
"path": "detections/network/net-tls-no-sni.yaml"
},
{
- "id": "det-network-049",
+ "id": "det-network-050",
"type": "detection",
"name": "Self-Signed Certificate Presented On Public IP",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Self-Signed Certificate Presented On Public IP'. Watch the 1 documented false-positive case before tuning.",
@@ -48137,7 +48161,7 @@
"path": "detections/network/net-tls-self-signed-egress.yaml"
},
{
- "id": "det-network-050",
+ "id": "det-network-051",
"type": "detection",
"name": "TLS Negotiated Weak Cipher Suite",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'TLS Negotiated Weak Cipher Suite'. Watch the 1 documented false-positive case before tuning.",
@@ -48160,7 +48184,7 @@
"path": "detections/network/net-tls-suspicious-cipher.yaml"
},
{
- "id": "det-network-051",
+ "id": "det-network-052",
"type": "detection",
"name": "JARM Fingerprint Matches Known Cobalt Strike Profile",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'JARM Fingerprint Matches Known Cobalt Strike Profile'. Watch the 1 documented false-positive case before tuning.",
@@ -48183,7 +48207,7 @@
"path": "detections/network/net-jarm-cobalt-strike.yaml"
},
{
- "id": "det-network-052",
+ "id": "det-network-053",
"type": "detection",
"name": "JARM Fingerprint Matches Known Sliver Profile",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'JARM Fingerprint Matches Known Sliver Profile'. Watch the 1 documented false-positive case before tuning.",
@@ -48206,7 +48230,7 @@
"path": "detections/network/net-jarm-sliver.yaml"
},
{
- "id": "det-network-053",
+ "id": "det-network-054",
"type": "detection",
"name": "HTTP Response MIME And Content-Encoding Mismatch",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'HTTP Response MIME And Content-Encoding Mismatch'. Watch the 1 documented false-positive case before tuning.",
@@ -48229,7 +48253,7 @@
"path": "detections/network/net-http-gzip-mime-mismatch.yaml"
},
{
- "id": "det-network-054",
+ "id": "det-network-055",
"type": "detection",
"name": "Large HTTP POST From Workstation To Public IP",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Large HTTP POST From Workstation To Public IP'. Watch the 1 documented false-positive case before tuning.",
@@ -48252,7 +48276,7 @@
"path": "detections/network/net-http-large-post-from-workstation.yaml"
},
{
- "id": "det-network-055",
+ "id": "det-network-056",
"type": "detection",
"name": "Outbound SSH With -R Reverse-Tunnel Flag",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Outbound SSH With -R Reverse-Tunnel Flag'. Watch the 1 documented false-positive case before tuning.",
@@ -48275,7 +48299,7 @@
"path": "detections/network/net-ssh-reverse-tunnel.yaml"
},
{
- "id": "det-network-056",
+ "id": "det-network-057",
"type": "detection",
"name": "Tor Connection From Corporate Workstation",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Tor Connection From Corporate Workstation'. Watch the 1 documented false-positive case before tuning.",
@@ -48298,7 +48322,7 @@
"path": "detections/network/net-tor-egress-corp.yaml"
},
{
- "id": "det-network-057",
+ "id": "det-network-058",
"type": "detection",
"name": "ICMP Echo With Unusually Large Payload",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'ICMP Echo With Unusually Large Payload'. Watch the 1 documented false-positive case before tuning.",
@@ -48321,7 +48345,7 @@
"path": "detections/network/net-icmp-large-payload.yaml"
},
{
- "id": "det-network-058",
+ "id": "det-network-059",
"type": "detection",
"name": "GRE Tunnel Initiated By Non-Network Host",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'GRE Tunnel Initiated By Non-Network Host'. Watch the 1 documented false-positive case before tuning.",
@@ -48344,7 +48368,7 @@
"path": "detections/network/net-gre-from-non-network-device.yaml"
},
{
- "id": "det-network-059",
+ "id": "det-network-060",
"type": "detection",
"name": "WireGuard Handshake From User Workstation",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'WireGuard Handshake From User Workstation'. Watch the 1 documented false-positive case before tuning.",
@@ -48367,7 +48391,7 @@
"path": "detections/network/net-wireguard-handshake-from-user.yaml"
},
{
- "id": "det-network-060",
+ "id": "det-network-061",
"type": "detection",
"name": "Corporate VPN Login Originating From Datacenter ASN",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Corporate VPN Login Originating From Datacenter ASN'. Watch the 1 documented false-positive case before tuning.",
@@ -48390,7 +48414,7 @@
"path": "detections/network/net-vpn-from-datacenter.yaml"
},
{
- "id": "det-network-061",
+ "id": "det-network-062",
"type": "detection",
"name": "Tor Introduction To Hidden Service From Corp Host",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Tor Introduction To Hidden Service From Corp Host'. Watch the 1 documented false-positive case before tuning.",
@@ -48413,7 +48437,7 @@
"path": "detections/network/net-tor-introduction-onion.yaml"
},
{
- "id": "det-network-062",
+ "id": "det-network-063",
"type": "detection",
"name": "Cloudflared Tunnel Started From Workstation",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Cloudflared Tunnel Started From Workstation'. Watch the 1 documented false-positive case before tuning.",
@@ -48436,7 +48460,7 @@
"path": "detections/network/net-cloudflared-tunnel-egress.yaml"
},
{
- "id": "det-network-063",
+ "id": "det-network-064",
"type": "detection",
"name": "SMB Version 1 Negotiated In Network Flow",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'SMB Version 1 Negotiated In Network Flow'. Watch the 1 documented false-positive case before tuning.",
@@ -48459,7 +48483,7 @@
"path": "detections/network/net-smbv1-egress.yaml"
},
{
- "id": "det-network-064",
+ "id": "det-network-065",
"type": "detection",
"name": "SMB Write To NETLOGON Share",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'SMB Write To NETLOGON Share'. Watch the 1 documented false-positive case before tuning.",
@@ -48482,7 +48506,7 @@
"path": "detections/network/net-smb-write-netlogon.yaml"
},
{
- "id": "det-network-065",
+ "id": "det-network-066",
"type": "detection",
"name": "SMB Write To SYSVOL Share From Non-DC",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'SMB Write To SYSVOL Share From Non-DC'. Watch the 1 documented false-positive case before tuning.",
@@ -48505,7 +48529,7 @@
"path": "detections/network/net-smb-write-sysvol.yaml"
},
{
- "id": "det-network-066",
+ "id": "det-network-067",
"type": "detection",
"name": "NTLM Relay Indicator (Same Challenge Reused Across Hosts)",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'NTLM Relay Indicator (Same Challenge Reused Across Hosts)'. Watch the 1 documented false-positive case before tuning.",
@@ -48528,7 +48552,7 @@
"path": "detections/network/net-ntlm-relay-pattern.yaml"
},
{
- "id": "det-network-067",
+ "id": "det-network-068",
"type": "detection",
"name": "RPC Remote Registry Write From Workstation Subnet",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'RPC Remote Registry Write From Workstation Subnet'. Watch the 1 documented false-positive case before tuning.",
@@ -48551,7 +48575,7 @@
"path": "detections/network/net-rpc-remote-registry.yaml"
},
{
- "id": "det-network-068",
+ "id": "det-network-069",
"type": "detection",
"name": "RPC Task Scheduler Create From Workstation",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'RPC Task Scheduler Create From Workstation'. Watch the 1 documented false-positive case before tuning.",
@@ -48574,7 +48598,7 @@
"path": "detections/network/net-rpc-task-scheduler-remote.yaml"
},
{
- "id": "det-network-069",
+ "id": "det-network-070",
"type": "detection",
"name": "WinRM HTTPS From Workstation To DC",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'WinRM HTTPS From Workstation To DC'. Watch the 1 documented false-positive case before tuning.",
@@ -48597,7 +48621,7 @@
"path": "detections/network/net-winrm-ssl-from-workstation.yaml"
},
{
- "id": "det-network-070",
+ "id": "det-network-071",
"type": "detection",
"name": "Cobalt Strike Default Named Pipe Pattern",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Cobalt Strike Default Named Pipe Pattern'. Watch the 1 documented false-positive case before tuning.",
@@ -48620,7 +48644,7 @@
"path": "detections/network/net-cobalt-strike-named-pipe.yaml"
},
{
- "id": "det-network-071",
+ "id": "det-network-072",
"type": "detection",
"name": "Sliver Default Named Pipe Pattern",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Sliver Default Named Pipe Pattern'. Watch the 1 documented false-positive case before tuning.",
@@ -48643,7 +48667,7 @@
"path": "detections/network/net-sliver-named-pipe.yaml"
},
{
- "id": "det-network-072",
+ "id": "det-network-073",
"type": "detection",
"name": "Empire C2 Default URI Pattern Observed",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Empire C2 Default URI Pattern Observed'. Watch the 1 documented false-positive case before tuning.",
@@ -48666,7 +48690,7 @@
"path": "detections/network/net-empire-default-uri.yaml"
},
{
- "id": "det-network-073",
+ "id": "det-network-074",
"type": "detection",
"name": "Kerberos Service Ticket Issued With RC4 Encryption",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Kerberos Service Ticket Issued With RC4 Encryption'. Watch the 1 documented false-positive case before tuning.",
@@ -48689,7 +48713,7 @@
"path": "detections/network/net-kerberos-rc4-ticket.yaml"
},
{
- "id": "det-network-074",
+ "id": "det-network-075",
"type": "detection",
"name": "Kerberos Account With Pre-Auth Disabled Used",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Kerberos Account With Pre-Auth Disabled Used'. Watch the 1 documented false-positive case before tuning.",
@@ -48712,7 +48736,7 @@
"path": "detections/network/net-kerberos-pre-auth-disabled.yaml"
},
{
- "id": "det-network-075",
+ "id": "det-network-076",
"type": "detection",
"name": "RADIUS Authentication Used PAP (Cleartext Password)",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'RADIUS Authentication Used PAP (Cleartext Password)'. Watch the 1 documented false-positive case before tuning.",
@@ -48735,7 +48759,7 @@
"path": "detections/network/net-radius-pap-clear.yaml"
},
{
- "id": "det-network-076",
+ "id": "det-network-077",
"type": "detection",
"name": "LDAP Signing Disabled On Domain Controller",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'LDAP Signing Disabled On Domain Controller'. Watch the 1 documented false-positive case before tuning.",
@@ -48758,7 +48782,7 @@
"path": "detections/network/net-ldap-signing-disabled.yaml"
},
{
- "id": "det-network-077",
+ "id": "det-network-078",
"type": "detection",
"name": "LDAP Search Pattern Matches BloodHound Collection",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'LDAP Search Pattern Matches BloodHound Collection'. Watch the 1 documented false-positive case before tuning.",
@@ -48781,7 +48805,7 @@
"path": "detections/network/net-ldap-bloodhound-pattern.yaml"
},
{
- "id": "det-network-078",
+ "id": "det-network-079",
"type": "detection",
"name": "ICMP Echo With High-Entropy Payload",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'ICMP Echo With High-Entropy Payload'. Watch the 1 documented false-positive case before tuning.",
@@ -48804,7 +48828,7 @@
"path": "detections/network/net-icmp-high-entropy-payload.yaml"
},
{
- "id": "det-network-079",
+ "id": "det-network-080",
"type": "detection",
"name": "DHCP Starvation: Rapid Lease Churn From Single MAC Range",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DHCP Starvation: Rapid Lease Churn From Single MAC Range'. Watch the 1 documented false-positive case before tuning.",
@@ -48827,7 +48851,7 @@
"path": "detections/network/net-dhcp-starvation.yaml"
},
{
- "id": "det-network-080",
+ "id": "det-network-081",
"type": "detection",
"name": "STP Topology Change Advertised By Edge Port",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'STP Topology Change Advertised By Edge Port'. Watch the 1 documented false-positive case before tuning.",
@@ -48849,30 +48873,6 @@
"enabled": true,
"path": "detections/network/net-stp-topology-change-from-edge.yaml"
},
- {
- "id": "det-network-081",
- "type": "detection",
- "name": "DNS TXT Response Over 250 Bytes From Non-Resolver Host",
- "description": "Triggers on the network signal described by 'DNS TXT Response Over 250 Bytes From Non-Resolver Host'. Watch the 1 documented false-positive case before tuning.",
- "version": "1.0.0",
- "author": "Josh Fishman",
- "tags": [
- "tlp.white"
- ],
- "severity": "medium",
- "category": "network",
- "mitre_techniques": [
- "T1071.004",
- "T1048.003"
- ],
- "log_source": "dns",
- "playbook": "tpl-command-and-control",
- "verified": true,
- "source": "core",
- "tier": "stable",
- "enabled": true,
- "path": "detections/network/dns-txt-record.yaml"
- },
{
"id": "dlp-violation-response-v1",
"type": "detection",
diff --git a/detections/application/app-ci-workflow-modified-by-non-owner.yaml b/detections/application/app-ci-workflow-modified-by-non-owner.yaml
index 6e33c496d..45f6fa2bd 100644
--- a/detections/application/app-ci-workflow-modified-by-non-owner.yaml
+++ b/detections/application/app-ci-workflow-modified-by-non-owner.yaml
@@ -15,7 +15,7 @@ detection:
condition: |
event_type == "push"
AND path CONTAINS ".github/workflows/"
- AND approver_role_neq == "codeowner"
+ AND approver_role != "codeowner"
false_positives:
- Bootstrap of new repository
playbook: tpl-supply-chain
diff --git a/detections/endpoint/linux-docker-socket-read-non-root.yaml b/detections/endpoint/linux-docker-socket-read-non-root.yaml
index 7bab36f0b..e3b74d2cf 100644
--- a/detections/endpoint/linux-docker-socket-read-non-root.yaml
+++ b/detections/endpoint/linux-docker-socket-read-non-root.yaml
@@ -15,7 +15,7 @@ detection:
condition: |
syscall == "connect"
AND path == "/var/run/docker.sock"
- AND actor_uid_neq == 0
+ AND actor_uid != 0
false_positives:
- docker group user (deprecated, must be ticketed)
playbook: tpl-privilege-escalation
diff --git a/detections/endpoint/linux-ebpf-prog-load-non-root.yaml b/detections/endpoint/linux-ebpf-prog-load-non-root.yaml
index 583fbb9dc..a86a53044 100644
--- a/detections/endpoint/linux-ebpf-prog-load-non-root.yaml
+++ b/detections/endpoint/linux-ebpf-prog-load-non-root.yaml
@@ -15,7 +15,7 @@ detection:
condition: |
syscall == "bpf"
AND cmd == "BPF_PROG_LOAD"
- AND actor_uid_neq == 0
+ AND actor_uid != 0
false_positives:
- Sanctioned observability agent
playbook: tpl-defense-evasion
diff --git a/detections/endpoint/linux-shadow-read.yaml b/detections/endpoint/linux-shadow-read.yaml
index 1b97b0a85..6465ada64 100644
--- a/detections/endpoint/linux-shadow-read.yaml
+++ b/detections/endpoint/linux-shadow-read.yaml
@@ -15,7 +15,7 @@ detection:
condition: |
syscall == "openat"
AND path == "/etc/shadow"
- AND actor_uid_neq == 0
+ AND actor_uid != 0
false_positives:
- Approved security scanner running with sudo
playbook: tpl-credential-access
diff --git a/detections/fixtures/negative/azure-ad-pim-role-eligibility-self-assigned.json b/detections/fixtures/negative/azure-ad-pim-role-eligibility-self-assigned.json
index 532f942af..6f3d777fd 100644
--- a/detections/fixtures/negative/azure-ad-pim-role-eligibility-self-assigned.json
+++ b/detections/fixtures/negative/azure-ad-pim-role-eligibility-self-assigned.json
@@ -1,4 +1,5 @@
{
- "actor_eq_target": true,
- "operation_name": "not-Add eligible member to role"
+ "actor": "principal-a",
+ "operation_name": "Add eligible member to role",
+ "target": "other-principal-a"
}
diff --git a/detections/fixtures/negative/ident-duo-admin-added-from-self.json b/detections/fixtures/negative/ident-duo-admin-added-from-self.json
index 3f0ab9994..4c4a6f235 100644
--- a/detections/fixtures/negative/ident-duo-admin-added-from-self.json
+++ b/detections/fixtures/negative/ident-duo-admin-added-from-self.json
@@ -1,4 +1,5 @@
{
- "actor_eq_target": true,
- "event_type": "not-admin_create"
+ "actor": "principal-a",
+ "event_type": "admin_create",
+ "target": "other-principal-a"
}
diff --git a/detections/fixtures/negative/ident-pim-activation-self-approval.json b/detections/fixtures/negative/ident-pim-activation-self-approval.json
index c2395865f..913de265d 100644
--- a/detections/fixtures/negative/ident-pim-activation-self-approval.json
+++ b/detections/fixtures/negative/ident-pim-activation-self-approval.json
@@ -1,4 +1,5 @@
{
- "approver_eq_actor": true,
- "event_type": "not-pim_activation"
+ "actor": "other-principal-a",
+ "approver": "principal-a",
+ "event_type": "pim_activation"
}
diff --git a/detections/fixtures/negative/ident-self-grant-priv-role.json b/detections/fixtures/negative/ident-self-grant-priv-role.json
index 1f867e1a1..97dc4f400 100644
--- a/detections/fixtures/negative/ident-self-grant-priv-role.json
+++ b/detections/fixtures/negative/ident-self-grant-priv-role.json
@@ -1,5 +1,6 @@
{
- "actor_eq_target": true,
- "event_type": "not-role_grant",
- "role_priv": true
+ "actor": "principal-a",
+ "event_type": "role_grant",
+ "role_priv": true,
+ "target": "other-principal-a"
}
diff --git a/detections/fixtures/positive/azure-ad-pim-role-eligibility-self-assigned.json b/detections/fixtures/positive/azure-ad-pim-role-eligibility-self-assigned.json
index 43c71b2e5..dc2a67b54 100644
--- a/detections/fixtures/positive/azure-ad-pim-role-eligibility-self-assigned.json
+++ b/detections/fixtures/positive/azure-ad-pim-role-eligibility-self-assigned.json
@@ -1,4 +1,5 @@
{
- "actor_eq_target": true,
- "operation_name": "Add eligible member to role"
+ "actor": "principal-a",
+ "operation_name": "Add eligible member to role",
+ "target": "principal-a"
}
diff --git a/detections/fixtures/positive/ident-duo-admin-added-from-self.json b/detections/fixtures/positive/ident-duo-admin-added-from-self.json
index 13713976e..fbc4b0d7d 100644
--- a/detections/fixtures/positive/ident-duo-admin-added-from-self.json
+++ b/detections/fixtures/positive/ident-duo-admin-added-from-self.json
@@ -1,4 +1,5 @@
{
- "actor_eq_target": true,
- "event_type": "admin_create"
+ "actor": "principal-a",
+ "event_type": "admin_create",
+ "target": "principal-a"
}
diff --git a/detections/fixtures/positive/ident-pim-activation-self-approval.json b/detections/fixtures/positive/ident-pim-activation-self-approval.json
index 42bccd68e..aa4e74b25 100644
--- a/detections/fixtures/positive/ident-pim-activation-self-approval.json
+++ b/detections/fixtures/positive/ident-pim-activation-self-approval.json
@@ -1,4 +1,5 @@
{
- "approver_eq_actor": true,
+ "actor": "principal-a",
+ "approver": "principal-a",
"event_type": "pim_activation"
}
diff --git a/detections/fixtures/positive/ident-self-grant-priv-role.json b/detections/fixtures/positive/ident-self-grant-priv-role.json
index 104c50dc2..b15449346 100644
--- a/detections/fixtures/positive/ident-self-grant-priv-role.json
+++ b/detections/fixtures/positive/ident-self-grant-priv-role.json
@@ -1,5 +1,6 @@
{
- "actor_eq_target": true,
+ "actor": "principal-a",
"event_type": "role_grant",
- "role_priv": true
+ "role_priv": true,
+ "target": "principal-a"
}
diff --git a/detections/network/dns-txt-record.yaml b/detections/network/dns-txt-record.yaml
index 8fa3357f7..768f13995 100644
--- a/detections/network/dns-txt-record.yaml
+++ b/detections/network/dns-txt-record.yaml
@@ -1,13 +1,13 @@
-id: det-network-081
+id: det-network-037
name: DNS TXT Response Over 250 Bytes From Non-Resolver Host
-description: Triggers on the network signal described by 'DNS TXT Response
+description: AiSOC v1 curated detection. Triggers on the network signal described by 'DNS TXT Response
Over 250 Bytes From Non-Resolver Host'. Watch the 1 documented false-positive case before tuning.
version: 1.0.0
severity: medium
tags:
- - mitre.attack.t1071.004
- - mitre.attack.t1048.003
- - tlp.white
+- mitre.attack.t1071.004
+- mitre.attack.t1048.003
+- tlp.white
category: network
log_source:
product: dns
@@ -19,9 +19,9 @@ detection:
AND response_size_bytes > 250
AND src_role NOT IN ["resolver"]
false_positives:
- - Approved DNS telemetry or resolver health checks
+- Approved DNS telemetry or resolver health checks
playbook: tpl-command-and-control
enabled: true
-author: Josh Fishman
-created: "2026-05-03"
-modified: "2026-05-03"
+author: AiSOC
+created: '2026-05-03'
+modified: '2026-05-03'
diff --git a/detections/network/net-cloudflared-tunnel-egress.yaml b/detections/network/net-cloudflared-tunnel-egress.yaml
index d2c9dcf00..eeaafd721 100644
--- a/detections/network/net-cloudflared-tunnel-egress.yaml
+++ b/detections/network/net-cloudflared-tunnel-egress.yaml
@@ -1,4 +1,4 @@
-id: det-network-062
+id: det-network-063
name: Cloudflared Tunnel Started From Workstation
description: AiSOC v1 curated detection. Triggers on the network signal described by 'Cloudflared Tunnel
Started From Workstation'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-cobalt-strike-named-pipe.yaml b/detections/network/net-cobalt-strike-named-pipe.yaml
index d98cfe808..020d77a3d 100644
--- a/detections/network/net-cobalt-strike-named-pipe.yaml
+++ b/detections/network/net-cobalt-strike-named-pipe.yaml
@@ -1,4 +1,4 @@
-id: det-network-070
+id: det-network-071
name: Cobalt Strike Default Named Pipe Pattern
description: AiSOC v1 curated detection. Triggers on the network signal described by 'Cobalt Strike Default
Named Pipe Pattern'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-dhcp-starvation.yaml b/detections/network/net-dhcp-starvation.yaml
index e71187194..252ad8110 100644
--- a/detections/network/net-dhcp-starvation.yaml
+++ b/detections/network/net-dhcp-starvation.yaml
@@ -1,4 +1,4 @@
-id: det-network-079
+id: det-network-080
name: 'DHCP Starvation: Rapid Lease Churn From Single MAC Range'
description: 'AiSOC v1 curated detection. Triggers on the network signal described by ''DHCP Starvation:
Rapid Lease Churn From Single MAC Range''. Watch the 1 documented false-positive case before tuning.'
diff --git a/detections/network/net-dns-doh-non-resolver.yaml b/detections/network/net-dns-doh-non-resolver.yaml
index 9495f9aa6..b89ee5597 100644
--- a/detections/network/net-dns-doh-non-resolver.yaml
+++ b/detections/network/net-dns-doh-non-resolver.yaml
@@ -1,4 +1,4 @@
-id: det-network-038
+id: det-network-039
name: DNS-Over-HTTPS Egress To Non-Sanctioned Resolver
description: AiSOC v1 curated detection. Triggers on the network signal described by 'DNS-Over-HTTPS Egress
To Non-Sanctioned Resolver'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-dns-dot-non-resolver.yaml b/detections/network/net-dns-dot-non-resolver.yaml
index 7b6e28122..54df85f41 100644
--- a/detections/network/net-dns-dot-non-resolver.yaml
+++ b/detections/network/net-dns-dot-non-resolver.yaml
@@ -1,4 +1,4 @@
-id: det-network-039
+id: det-network-040
name: DNS-Over-TLS Egress To Public IP
description: AiSOC v1 curated detection. Triggers on the network signal described by 'DNS-Over-TLS Egress
To Public IP'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-dns-fast-flux.yaml b/detections/network/net-dns-fast-flux.yaml
index a6aa0cc73..da4c0efe7 100644
--- a/detections/network/net-dns-fast-flux.yaml
+++ b/detections/network/net-dns-fast-flux.yaml
@@ -1,4 +1,4 @@
-id: det-network-041
+id: det-network-042
name: DNS Fast-Flux Pattern (Many A Records, Short TTL)
description: AiSOC v1 curated detection. Triggers on the network signal described by 'DNS Fast-Flux Pattern
(Many A Records, Short TTL)'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-dns-rebinding.yaml b/detections/network/net-dns-rebinding.yaml
index 7809fb3e1..beb543f9e 100644
--- a/detections/network/net-dns-rebinding.yaml
+++ b/detections/network/net-dns-rebinding.yaml
@@ -1,4 +1,4 @@
-id: det-network-042
+id: det-network-043
name: DNS Rebinding Indicator (Public→RFC1918 In Same TTL Window)
description: AiSOC v1 curated detection. Triggers on the network signal described by 'DNS Rebinding Indicator
(Public→RFC1918 In Same TTL Window)'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-dns-tor-onion.yaml b/detections/network/net-dns-tor-onion.yaml
index c60857b92..6a285be58 100644
--- a/detections/network/net-dns-tor-onion.yaml
+++ b/detections/network/net-dns-tor-onion.yaml
@@ -1,4 +1,4 @@
-id: det-network-040
+id: det-network-041
name: DNS Query For .onion Address
description: AiSOC v1 curated detection. Triggers on the network signal described by 'DNS Query For .onion
Address'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-dns-tunnel-pattern-len.yaml b/detections/network/net-dns-tunnel-pattern-len.yaml
index b8b82bfb8..18c48f131 100644
--- a/detections/network/net-dns-tunnel-pattern-len.yaml
+++ b/detections/network/net-dns-tunnel-pattern-len.yaml
@@ -1,4 +1,4 @@
-id: det-network-037
+id: det-network-038
name: 'DNS Tunnel Indicator: Long Hex Subdomain Sequence'
description: 'AiSOC v1 curated detection. Triggers on the network signal described by ''DNS Tunnel Indicator:
Long Hex Subdomain Sequence''. Watch the 1 documented false-positive case before tuning.'
diff --git a/detections/network/net-empire-default-uri.yaml b/detections/network/net-empire-default-uri.yaml
index fbd921e8d..7d32d8001 100644
--- a/detections/network/net-empire-default-uri.yaml
+++ b/detections/network/net-empire-default-uri.yaml
@@ -1,4 +1,4 @@
-id: det-network-072
+id: det-network-073
name: Empire C2 Default URI Pattern Observed
description: AiSOC v1 curated detection. Triggers on the network signal described by 'Empire C2 Default
URI Pattern Observed'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-gre-from-non-network-device.yaml b/detections/network/net-gre-from-non-network-device.yaml
index bfb3eeffd..39b9deb84 100644
--- a/detections/network/net-gre-from-non-network-device.yaml
+++ b/detections/network/net-gre-from-non-network-device.yaml
@@ -1,4 +1,4 @@
-id: det-network-058
+id: det-network-059
name: GRE Tunnel Initiated By Non-Network Host
description: AiSOC v1 curated detection. Triggers on the network signal described by 'GRE Tunnel Initiated
By Non-Network Host'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-http-connect-public-ip.yaml b/detections/network/net-http-connect-public-ip.yaml
index 25ba77cf3..ecab8bae7 100644
--- a/detections/network/net-http-connect-public-ip.yaml
+++ b/detections/network/net-http-connect-public-ip.yaml
@@ -1,4 +1,4 @@
-id: det-network-043
+id: det-network-044
name: HTTP CONNECT Method Toward Public IP
description: AiSOC v1 curated detection. Triggers on the network signal described by 'HTTP CONNECT Method
Toward Public IP'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-http-gzip-mime-mismatch.yaml b/detections/network/net-http-gzip-mime-mismatch.yaml
index df3fe986d..614abf182 100644
--- a/detections/network/net-http-gzip-mime-mismatch.yaml
+++ b/detections/network/net-http-gzip-mime-mismatch.yaml
@@ -1,4 +1,4 @@
-id: det-network-053
+id: det-network-054
name: HTTP Response MIME And Content-Encoding Mismatch
description: AiSOC v1 curated detection. Triggers on the network signal described by 'HTTP Response MIME
And Content-Encoding Mismatch'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-http-host-header-ip.yaml b/detections/network/net-http-host-header-ip.yaml
index 6d919732a..7c6fe6ca7 100644
--- a/detections/network/net-http-host-header-ip.yaml
+++ b/detections/network/net-http-host-header-ip.yaml
@@ -1,4 +1,4 @@
-id: det-network-046
+id: det-network-047
name: HTTP Host Header Is IP Literal
description: AiSOC v1 curated detection. Triggers on the network signal described by 'HTTP Host Header
Is IP Literal'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-http-large-post-from-workstation.yaml b/detections/network/net-http-large-post-from-workstation.yaml
index 062e86c45..d8aa97c3d 100644
--- a/detections/network/net-http-large-post-from-workstation.yaml
+++ b/detections/network/net-http-large-post-from-workstation.yaml
@@ -1,4 +1,4 @@
-id: det-network-054
+id: det-network-055
name: Large HTTP POST From Workstation To Public IP
description: AiSOC v1 curated detection. Triggers on the network signal described by 'Large HTTP POST
From Workstation To Public IP'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-http-userag-curl-internal.yaml b/detections/network/net-http-userag-curl-internal.yaml
index ffd7fd99f..e92cf6b4e 100644
--- a/detections/network/net-http-userag-curl-internal.yaml
+++ b/detections/network/net-http-userag-curl-internal.yaml
@@ -1,4 +1,4 @@
-id: det-network-045
+id: det-network-046
name: curl/wget User-Agent From Workstation Subnet
description: AiSOC v1 curated detection. Triggers on the network signal described by 'curl/wget User-Agent
From Workstation Subnet'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-http-userag-powershell.yaml b/detections/network/net-http-userag-powershell.yaml
index b775857b7..15d00ed75 100644
--- a/detections/network/net-http-userag-powershell.yaml
+++ b/detections/network/net-http-userag-powershell.yaml
@@ -1,4 +1,4 @@
-id: det-network-044
+id: det-network-045
name: HTTP User-Agent Matches PowerShell Default
description: AiSOC v1 curated detection. Triggers on the network signal described by 'HTTP User-Agent
Matches PowerShell Default'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-icmp-high-entropy-payload.yaml b/detections/network/net-icmp-high-entropy-payload.yaml
index 02ba304ce..4c6d465a2 100644
--- a/detections/network/net-icmp-high-entropy-payload.yaml
+++ b/detections/network/net-icmp-high-entropy-payload.yaml
@@ -1,4 +1,4 @@
-id: det-network-078
+id: det-network-079
name: ICMP Echo With High-Entropy Payload
description: AiSOC v1 curated detection. Triggers on the network signal described by 'ICMP Echo With High-Entropy
Payload'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-icmp-large-payload.yaml b/detections/network/net-icmp-large-payload.yaml
index 634c67a09..e9b170a7a 100644
--- a/detections/network/net-icmp-large-payload.yaml
+++ b/detections/network/net-icmp-large-payload.yaml
@@ -1,4 +1,4 @@
-id: det-network-057
+id: det-network-058
name: ICMP Echo With Unusually Large Payload
description: AiSOC v1 curated detection. Triggers on the network signal described by 'ICMP Echo With Unusually
Large Payload'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-jarm-cobalt-strike.yaml b/detections/network/net-jarm-cobalt-strike.yaml
index cde9a9201..63e8ce49e 100644
--- a/detections/network/net-jarm-cobalt-strike.yaml
+++ b/detections/network/net-jarm-cobalt-strike.yaml
@@ -1,4 +1,4 @@
-id: det-network-051
+id: det-network-052
name: JARM Fingerprint Matches Known Cobalt Strike Profile
description: AiSOC v1 curated detection. Triggers on the network signal described by 'JARM Fingerprint
Matches Known Cobalt Strike Profile'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-jarm-sliver.yaml b/detections/network/net-jarm-sliver.yaml
index cb8b9fe30..580c834c0 100644
--- a/detections/network/net-jarm-sliver.yaml
+++ b/detections/network/net-jarm-sliver.yaml
@@ -1,4 +1,4 @@
-id: det-network-052
+id: det-network-053
name: JARM Fingerprint Matches Known Sliver Profile
description: AiSOC v1 curated detection. Triggers on the network signal described by 'JARM Fingerprint
Matches Known Sliver Profile'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-kerberos-pre-auth-disabled.yaml b/detections/network/net-kerberos-pre-auth-disabled.yaml
index e2bbdf3b9..ecea75e88 100644
--- a/detections/network/net-kerberos-pre-auth-disabled.yaml
+++ b/detections/network/net-kerberos-pre-auth-disabled.yaml
@@ -1,4 +1,4 @@
-id: det-network-074
+id: det-network-075
name: Kerberos Account With Pre-Auth Disabled Used
description: AiSOC v1 curated detection. Triggers on the network signal described by 'Kerberos Account
With Pre-Auth Disabled Used'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-kerberos-rc4-ticket.yaml b/detections/network/net-kerberos-rc4-ticket.yaml
index 89d5f0c85..7da893c03 100644
--- a/detections/network/net-kerberos-rc4-ticket.yaml
+++ b/detections/network/net-kerberos-rc4-ticket.yaml
@@ -1,4 +1,4 @@
-id: det-network-073
+id: det-network-074
name: Kerberos Service Ticket Issued With RC4 Encryption
description: AiSOC v1 curated detection. Triggers on the network signal described by 'Kerberos Service
Ticket Issued With RC4 Encryption'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-ldap-bloodhound-pattern.yaml b/detections/network/net-ldap-bloodhound-pattern.yaml
index 845a5d719..24eb1e38f 100644
--- a/detections/network/net-ldap-bloodhound-pattern.yaml
+++ b/detections/network/net-ldap-bloodhound-pattern.yaml
@@ -1,4 +1,4 @@
-id: det-network-077
+id: det-network-078
name: LDAP Search Pattern Matches BloodHound Collection
description: AiSOC v1 curated detection. Triggers on the network signal described by 'LDAP Search Pattern
Matches BloodHound Collection'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-ldap-signing-disabled.yaml b/detections/network/net-ldap-signing-disabled.yaml
index a63c8c836..ef81b416c 100644
--- a/detections/network/net-ldap-signing-disabled.yaml
+++ b/detections/network/net-ldap-signing-disabled.yaml
@@ -1,4 +1,4 @@
-id: det-network-076
+id: det-network-077
name: LDAP Signing Disabled On Domain Controller
description: AiSOC v1 curated detection. Triggers on the network signal described by 'LDAP Signing Disabled
On Domain Controller'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-ntlm-relay-pattern.yaml b/detections/network/net-ntlm-relay-pattern.yaml
index 7c5cb2cc5..7d8168a95 100644
--- a/detections/network/net-ntlm-relay-pattern.yaml
+++ b/detections/network/net-ntlm-relay-pattern.yaml
@@ -1,4 +1,4 @@
-id: det-network-066
+id: det-network-067
name: NTLM Relay Indicator (Same Challenge Reused Across Hosts)
description: AiSOC v1 curated detection. Triggers on the network signal described by 'NTLM Relay Indicator
(Same Challenge Reused Across Hosts)'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-radius-pap-clear.yaml b/detections/network/net-radius-pap-clear.yaml
index 3fef84dc8..291c71bb2 100644
--- a/detections/network/net-radius-pap-clear.yaml
+++ b/detections/network/net-radius-pap-clear.yaml
@@ -1,4 +1,4 @@
-id: det-network-075
+id: det-network-076
name: RADIUS Authentication Used PAP (Cleartext Password)
description: AiSOC v1 curated detection. Triggers on the network signal described by 'RADIUS Authentication
Used PAP (Cleartext Password)'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-rpc-remote-registry.yaml b/detections/network/net-rpc-remote-registry.yaml
index 3bc0dee43..bfb96f4d5 100644
--- a/detections/network/net-rpc-remote-registry.yaml
+++ b/detections/network/net-rpc-remote-registry.yaml
@@ -1,4 +1,4 @@
-id: det-network-067
+id: det-network-068
name: RPC Remote Registry Write From Workstation Subnet
description: AiSOC v1 curated detection. Triggers on the network signal described by 'RPC Remote Registry
Write From Workstation Subnet'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-rpc-task-scheduler-remote.yaml b/detections/network/net-rpc-task-scheduler-remote.yaml
index 269c88a3a..f7e77122f 100644
--- a/detections/network/net-rpc-task-scheduler-remote.yaml
+++ b/detections/network/net-rpc-task-scheduler-remote.yaml
@@ -1,4 +1,4 @@
-id: det-network-068
+id: det-network-069
name: RPC Task Scheduler Create From Workstation
description: AiSOC v1 curated detection. Triggers on the network signal described by 'RPC Task Scheduler
Create From Workstation'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-sliver-named-pipe.yaml b/detections/network/net-sliver-named-pipe.yaml
index 962db68b3..6754dbf5d 100644
--- a/detections/network/net-sliver-named-pipe.yaml
+++ b/detections/network/net-sliver-named-pipe.yaml
@@ -1,4 +1,4 @@
-id: det-network-071
+id: det-network-072
name: Sliver Default Named Pipe Pattern
description: AiSOC v1 curated detection. Triggers on the network signal described by 'Sliver Default Named
Pipe Pattern'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-smb-write-netlogon.yaml b/detections/network/net-smb-write-netlogon.yaml
index 35adc989c..88b537498 100644
--- a/detections/network/net-smb-write-netlogon.yaml
+++ b/detections/network/net-smb-write-netlogon.yaml
@@ -1,4 +1,4 @@
-id: det-network-064
+id: det-network-065
name: SMB Write To NETLOGON Share
description: AiSOC v1 curated detection. Triggers on the network signal described by 'SMB Write To NETLOGON
Share'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-smb-write-sysvol.yaml b/detections/network/net-smb-write-sysvol.yaml
index b4ef269f5..99ab97a57 100644
--- a/detections/network/net-smb-write-sysvol.yaml
+++ b/detections/network/net-smb-write-sysvol.yaml
@@ -1,4 +1,4 @@
-id: det-network-065
+id: det-network-066
name: SMB Write To SYSVOL Share From Non-DC
description: AiSOC v1 curated detection. Triggers on the network signal described by 'SMB Write To SYSVOL
Share From Non-DC'. Watch the 1 documented false-positive case before tuning.
@@ -15,7 +15,7 @@ detection:
condition: |
event_type == "smb_write"
AND share_name == "SYSVOL"
- AND src_role_neq == "domain-controller"
+ AND src_role != "domain-controller"
false_positives:
- Authorised AD migration tool
playbook: tpl-lateral-movement
diff --git a/detections/network/net-smbv1-egress.yaml b/detections/network/net-smbv1-egress.yaml
index c94c56b56..15a9c0dc2 100644
--- a/detections/network/net-smbv1-egress.yaml
+++ b/detections/network/net-smbv1-egress.yaml
@@ -1,4 +1,4 @@
-id: det-network-063
+id: det-network-064
name: SMB Version 1 Negotiated In Network Flow
description: AiSOC v1 curated detection. Triggers on the network signal described by 'SMB Version 1 Negotiated
In Network Flow'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-ssh-reverse-tunnel.yaml b/detections/network/net-ssh-reverse-tunnel.yaml
index 397cc1cda..e63d7f0bc 100644
--- a/detections/network/net-ssh-reverse-tunnel.yaml
+++ b/detections/network/net-ssh-reverse-tunnel.yaml
@@ -1,4 +1,4 @@
-id: det-network-055
+id: det-network-056
name: Outbound SSH With -R Reverse-Tunnel Flag
description: AiSOC v1 curated detection. Triggers on the network signal described by 'Outbound SSH With
-R Reverse-Tunnel Flag'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-stp-topology-change-from-edge.yaml b/detections/network/net-stp-topology-change-from-edge.yaml
index af0e4c49a..f86d5b3de 100644
--- a/detections/network/net-stp-topology-change-from-edge.yaml
+++ b/detections/network/net-stp-topology-change-from-edge.yaml
@@ -1,4 +1,4 @@
-id: det-network-080
+id: det-network-081
name: STP Topology Change Advertised By Edge Port
description: AiSOC v1 curated detection. Triggers on the network signal described by 'STP Topology Change
Advertised By Edge Port'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-tls-no-sni.yaml b/detections/network/net-tls-no-sni.yaml
index 737fdb379..949d6bc4e 100644
--- a/detections/network/net-tls-no-sni.yaml
+++ b/detections/network/net-tls-no-sni.yaml
@@ -1,4 +1,4 @@
-id: det-network-048
+id: det-network-049
name: HTTPS Connection To IP Without SNI
description: AiSOC v1 curated detection. Triggers on the network signal described by 'HTTPS Connection
To IP Without SNI'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-tls-old-client-version.yaml b/detections/network/net-tls-old-client-version.yaml
index 8453efcf1..f724a198f 100644
--- a/detections/network/net-tls-old-client-version.yaml
+++ b/detections/network/net-tls-old-client-version.yaml
@@ -1,4 +1,4 @@
-id: det-network-047
+id: det-network-048
name: TLS Client Offered TLS 1.0 Or 1.1
description: AiSOC v1 curated detection. Triggers on the network signal described by 'TLS Client Offered
TLS 1.0 Or 1.1'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-tls-self-signed-egress.yaml b/detections/network/net-tls-self-signed-egress.yaml
index a0ca3c3cd..ac5955054 100644
--- a/detections/network/net-tls-self-signed-egress.yaml
+++ b/detections/network/net-tls-self-signed-egress.yaml
@@ -1,4 +1,4 @@
-id: det-network-049
+id: det-network-050
name: Self-Signed Certificate Presented On Public IP
description: AiSOC v1 curated detection. Triggers on the network signal described by 'Self-Signed Certificate
Presented On Public IP'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-tls-suspicious-cipher.yaml b/detections/network/net-tls-suspicious-cipher.yaml
index 2f04b2fbe..6fa4ac4e5 100644
--- a/detections/network/net-tls-suspicious-cipher.yaml
+++ b/detections/network/net-tls-suspicious-cipher.yaml
@@ -1,4 +1,4 @@
-id: det-network-050
+id: det-network-051
name: TLS Negotiated Weak Cipher Suite
description: AiSOC v1 curated detection. Triggers on the network signal described by 'TLS Negotiated Weak
Cipher Suite'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-tor-egress-corp.yaml b/detections/network/net-tor-egress-corp.yaml
index 5c45c5148..9637e6fa9 100644
--- a/detections/network/net-tor-egress-corp.yaml
+++ b/detections/network/net-tor-egress-corp.yaml
@@ -1,4 +1,4 @@
-id: det-network-056
+id: det-network-057
name: Tor Connection From Corporate Workstation
description: AiSOC v1 curated detection. Triggers on the network signal described by 'Tor Connection From
Corporate Workstation'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-tor-introduction-onion.yaml b/detections/network/net-tor-introduction-onion.yaml
index 881fb65be..95337b7bc 100644
--- a/detections/network/net-tor-introduction-onion.yaml
+++ b/detections/network/net-tor-introduction-onion.yaml
@@ -1,4 +1,4 @@
-id: det-network-061
+id: det-network-062
name: Tor Introduction To Hidden Service From Corp Host
description: AiSOC v1 curated detection. Triggers on the network signal described by 'Tor Introduction
To Hidden Service From Corp Host'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-vpn-from-datacenter.yaml b/detections/network/net-vpn-from-datacenter.yaml
index 10e1f31d2..1134a2a32 100644
--- a/detections/network/net-vpn-from-datacenter.yaml
+++ b/detections/network/net-vpn-from-datacenter.yaml
@@ -1,4 +1,4 @@
-id: det-network-060
+id: det-network-061
name: Corporate VPN Login Originating From Datacenter ASN
description: AiSOC v1 curated detection. Triggers on the network signal described by 'Corporate VPN Login
Originating From Datacenter ASN'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-winrm-ssl-from-workstation.yaml b/detections/network/net-winrm-ssl-from-workstation.yaml
index 3e98a8e2f..da625fe9c 100644
--- a/detections/network/net-winrm-ssl-from-workstation.yaml
+++ b/detections/network/net-winrm-ssl-from-workstation.yaml
@@ -1,4 +1,4 @@
-id: det-network-069
+id: det-network-070
name: WinRM HTTPS From Workstation To DC
description: AiSOC v1 curated detection. Triggers on the network signal described by 'WinRM HTTPS From
Workstation To DC'. Watch the 1 documented false-positive case before tuning.
diff --git a/detections/network/net-wireguard-handshake-from-user.yaml b/detections/network/net-wireguard-handshake-from-user.yaml
index 904b84883..7d0bcaf6d 100644
--- a/detections/network/net-wireguard-handshake-from-user.yaml
+++ b/detections/network/net-wireguard-handshake-from-user.yaml
@@ -1,4 +1,4 @@
-id: det-network-059
+id: det-network-060
name: WireGuard Handshake From User Workstation
description: AiSOC v1 curated detection. Triggers on the network signal described by 'WireGuard Handshake
From User Workstation'. Watch the 1 documented false-positive case before tuning.
diff --git a/marketplace/curated.json b/marketplace/curated.json
index f3368bd94..270a3324f 100644
--- a/marketplace/curated.json
+++ b/marketplace/curated.json
@@ -1,7 +1,7 @@
{
"$schema": "https://aisoc.example.com/schemas/curated/v1.json",
"version": "1.0.0",
- "generated": "2026-09-22T15:54:13Z",
+ "generated": "2026-09-23T14:16:45Z",
"stats": {
"considered": 1054,
"eligible": 1051,
@@ -160,7 +160,7 @@
"det-identity-160",
"det-network-004",
"det-network-026",
- "det-network-075",
+ "det-network-076",
"mitre-car-car-2013-04-002",
"mitre-car-car-2013-07-001",
"mitre-car-car-2013-09-003",
@@ -197,10 +197,10 @@
"det-network-005",
"det-network-022",
"det-network-030",
- "det-network-063",
"det-network-064",
"det-network-065",
- "det-network-069",
+ "det-network-066",
+ "det-network-070",
"mitre-car-car-2013-01-003",
"mitre-car-car-2013-04-002",
"mitre-car-car-2013-05-003",
@@ -264,7 +264,7 @@
"det-endpoint-175",
"det-endpoint-270",
"det-identity-152",
- "det-network-054",
+ "det-network-055",
"mitre-car-car-2013-04-002",
"sigmahq-sigma-b593fd50-7335-4682-a36c-4edcb68e4641"
],
@@ -10301,7 +10301,7 @@
"has_executable_body": true
},
{
- "id": "det-network-054",
+ "id": "det-network-055",
"name": "Large HTTP POST From Workstation To Public IP",
"path": "detections/network/net-http-large-post-from-workstation.yaml",
"tier": "native",
@@ -10326,7 +10326,7 @@
"has_executable_body": true
},
{
- "id": "det-network-063",
+ "id": "det-network-064",
"name": "SMB Version 1 Negotiated In Network Flow",
"path": "detections/network/net-smbv1-egress.yaml",
"tier": "native",
@@ -10351,7 +10351,7 @@
"has_executable_body": true
},
{
- "id": "det-network-064",
+ "id": "det-network-065",
"name": "SMB Write To NETLOGON Share",
"path": "detections/network/net-smb-write-netlogon.yaml",
"tier": "native",
@@ -10376,7 +10376,7 @@
"has_executable_body": true
},
{
- "id": "det-network-065",
+ "id": "det-network-066",
"name": "SMB Write To SYSVOL Share From Non-DC",
"path": "detections/network/net-smb-write-sysvol.yaml",
"tier": "native",
@@ -10401,7 +10401,7 @@
"has_executable_body": true
},
{
- "id": "det-network-069",
+ "id": "det-network-070",
"name": "WinRM HTTPS From Workstation To DC",
"path": "detections/network/net-winrm-ssl-from-workstation.yaml",
"tier": "native",
@@ -10426,7 +10426,7 @@
"has_executable_body": true
},
{
- "id": "det-network-075",
+ "id": "det-network-076",
"name": "RADIUS Authentication Used PAP (Cleartext Password)",
"path": "detections/network/net-radius-pap-clear.yaml",
"tier": "native",
diff --git a/marketplace/index.json b/marketplace/index.json
index c5834bd98..e1bd31249 100644
--- a/marketplace/index.json
+++ b/marketplace/index.json
@@ -1,7 +1,7 @@
{
"$schema": "https://example.com/schemas/marketplace/v1.json",
"version": "1.0.0",
- "generated": "2026-09-22T15:54:12Z",
+ "generated": "2026-09-23T14:14:28Z",
"categories": [
{
"id": "playbooks",
@@ -47840,6 +47840,30 @@
{
"id": "det-network-037",
"type": "detection",
+ "name": "DNS TXT Response Over 250 Bytes From Non-Resolver Host",
+ "description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS TXT Response Over 250 Bytes From Non-Resolver Host'. Watch the 1 documented false-positive case before tuning.",
+ "version": "1.0.0",
+ "author": "AiSOC",
+ "tags": [
+ "tlp.white"
+ ],
+ "severity": "medium",
+ "category": "network",
+ "mitre_techniques": [
+ "T1071.004",
+ "T1048.003"
+ ],
+ "log_source": "dns",
+ "playbook": "tpl-command-and-control",
+ "verified": true,
+ "source": "core",
+ "tier": "stable",
+ "enabled": true,
+ "path": "detections/network/dns-txt-record.yaml"
+ },
+ {
+ "id": "det-network-038",
+ "type": "detection",
"name": "DNS Tunnel Indicator: Long Hex Subdomain Sequence",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS Tunnel Indicator: Long Hex Subdomain Sequence'. Watch the 1 documented false-positive case before tuning.",
"version": "1.0.0",
@@ -47861,7 +47885,7 @@
"path": "detections/network/net-dns-tunnel-pattern-len.yaml"
},
{
- "id": "det-network-038",
+ "id": "det-network-039",
"type": "detection",
"name": "DNS-Over-HTTPS Egress To Non-Sanctioned Resolver",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS-Over-HTTPS Egress To Non-Sanctioned Resolver'. Watch the 1 documented false-positive case before tuning.",
@@ -47884,7 +47908,7 @@
"path": "detections/network/net-dns-doh-non-resolver.yaml"
},
{
- "id": "det-network-039",
+ "id": "det-network-040",
"type": "detection",
"name": "DNS-Over-TLS Egress To Public IP",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS-Over-TLS Egress To Public IP'. Watch the 1 documented false-positive case before tuning.",
@@ -47907,7 +47931,7 @@
"path": "detections/network/net-dns-dot-non-resolver.yaml"
},
{
- "id": "det-network-040",
+ "id": "det-network-041",
"type": "detection",
"name": "DNS Query For .onion Address",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS Query For .onion Address'. Watch the 1 documented false-positive case before tuning.",
@@ -47930,7 +47954,7 @@
"path": "detections/network/net-dns-tor-onion.yaml"
},
{
- "id": "det-network-041",
+ "id": "det-network-042",
"type": "detection",
"name": "DNS Fast-Flux Pattern (Many A Records, Short TTL)",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS Fast-Flux Pattern (Many A Records, Short TTL)'. Watch the 1 documented false-positive case before tuning.",
@@ -47953,7 +47977,7 @@
"path": "detections/network/net-dns-fast-flux.yaml"
},
{
- "id": "det-network-042",
+ "id": "det-network-043",
"type": "detection",
"name": "DNS Rebinding Indicator (Public\u2192RFC1918 In Same TTL Window)",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DNS Rebinding Indicator (Public\u2192RFC1918 In Same TTL Window)'. Watch the 1 documented false-positive case before tuning.",
@@ -47976,7 +48000,7 @@
"path": "detections/network/net-dns-rebinding.yaml"
},
{
- "id": "det-network-043",
+ "id": "det-network-044",
"type": "detection",
"name": "HTTP CONNECT Method Toward Public IP",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'HTTP CONNECT Method Toward Public IP'. Watch the 1 documented false-positive case before tuning.",
@@ -47999,7 +48023,7 @@
"path": "detections/network/net-http-connect-public-ip.yaml"
},
{
- "id": "det-network-044",
+ "id": "det-network-045",
"type": "detection",
"name": "HTTP User-Agent Matches PowerShell Default",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'HTTP User-Agent Matches PowerShell Default'. Watch the 1 documented false-positive case before tuning.",
@@ -48022,7 +48046,7 @@
"path": "detections/network/net-http-userag-powershell.yaml"
},
{
- "id": "det-network-045",
+ "id": "det-network-046",
"type": "detection",
"name": "curl/wget User-Agent From Workstation Subnet",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'curl/wget User-Agent From Workstation Subnet'. Watch the 1 documented false-positive case before tuning.",
@@ -48045,7 +48069,7 @@
"path": "detections/network/net-http-userag-curl-internal.yaml"
},
{
- "id": "det-network-046",
+ "id": "det-network-047",
"type": "detection",
"name": "HTTP Host Header Is IP Literal",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'HTTP Host Header Is IP Literal'. Watch the 1 documented false-positive case before tuning.",
@@ -48068,7 +48092,7 @@
"path": "detections/network/net-http-host-header-ip.yaml"
},
{
- "id": "det-network-047",
+ "id": "det-network-048",
"type": "detection",
"name": "TLS Client Offered TLS 1.0 Or 1.1",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'TLS Client Offered TLS 1.0 Or 1.1'. Watch the 1 documented false-positive case before tuning.",
@@ -48091,7 +48115,7 @@
"path": "detections/network/net-tls-old-client-version.yaml"
},
{
- "id": "det-network-048",
+ "id": "det-network-049",
"type": "detection",
"name": "HTTPS Connection To IP Without SNI",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'HTTPS Connection To IP Without SNI'. Watch the 1 documented false-positive case before tuning.",
@@ -48114,7 +48138,7 @@
"path": "detections/network/net-tls-no-sni.yaml"
},
{
- "id": "det-network-049",
+ "id": "det-network-050",
"type": "detection",
"name": "Self-Signed Certificate Presented On Public IP",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Self-Signed Certificate Presented On Public IP'. Watch the 1 documented false-positive case before tuning.",
@@ -48137,7 +48161,7 @@
"path": "detections/network/net-tls-self-signed-egress.yaml"
},
{
- "id": "det-network-050",
+ "id": "det-network-051",
"type": "detection",
"name": "TLS Negotiated Weak Cipher Suite",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'TLS Negotiated Weak Cipher Suite'. Watch the 1 documented false-positive case before tuning.",
@@ -48160,7 +48184,7 @@
"path": "detections/network/net-tls-suspicious-cipher.yaml"
},
{
- "id": "det-network-051",
+ "id": "det-network-052",
"type": "detection",
"name": "JARM Fingerprint Matches Known Cobalt Strike Profile",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'JARM Fingerprint Matches Known Cobalt Strike Profile'. Watch the 1 documented false-positive case before tuning.",
@@ -48183,7 +48207,7 @@
"path": "detections/network/net-jarm-cobalt-strike.yaml"
},
{
- "id": "det-network-052",
+ "id": "det-network-053",
"type": "detection",
"name": "JARM Fingerprint Matches Known Sliver Profile",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'JARM Fingerprint Matches Known Sliver Profile'. Watch the 1 documented false-positive case before tuning.",
@@ -48206,7 +48230,7 @@
"path": "detections/network/net-jarm-sliver.yaml"
},
{
- "id": "det-network-053",
+ "id": "det-network-054",
"type": "detection",
"name": "HTTP Response MIME And Content-Encoding Mismatch",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'HTTP Response MIME And Content-Encoding Mismatch'. Watch the 1 documented false-positive case before tuning.",
@@ -48229,7 +48253,7 @@
"path": "detections/network/net-http-gzip-mime-mismatch.yaml"
},
{
- "id": "det-network-054",
+ "id": "det-network-055",
"type": "detection",
"name": "Large HTTP POST From Workstation To Public IP",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Large HTTP POST From Workstation To Public IP'. Watch the 1 documented false-positive case before tuning.",
@@ -48252,7 +48276,7 @@
"path": "detections/network/net-http-large-post-from-workstation.yaml"
},
{
- "id": "det-network-055",
+ "id": "det-network-056",
"type": "detection",
"name": "Outbound SSH With -R Reverse-Tunnel Flag",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Outbound SSH With -R Reverse-Tunnel Flag'. Watch the 1 documented false-positive case before tuning.",
@@ -48275,7 +48299,7 @@
"path": "detections/network/net-ssh-reverse-tunnel.yaml"
},
{
- "id": "det-network-056",
+ "id": "det-network-057",
"type": "detection",
"name": "Tor Connection From Corporate Workstation",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Tor Connection From Corporate Workstation'. Watch the 1 documented false-positive case before tuning.",
@@ -48298,7 +48322,7 @@
"path": "detections/network/net-tor-egress-corp.yaml"
},
{
- "id": "det-network-057",
+ "id": "det-network-058",
"type": "detection",
"name": "ICMP Echo With Unusually Large Payload",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'ICMP Echo With Unusually Large Payload'. Watch the 1 documented false-positive case before tuning.",
@@ -48321,7 +48345,7 @@
"path": "detections/network/net-icmp-large-payload.yaml"
},
{
- "id": "det-network-058",
+ "id": "det-network-059",
"type": "detection",
"name": "GRE Tunnel Initiated By Non-Network Host",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'GRE Tunnel Initiated By Non-Network Host'. Watch the 1 documented false-positive case before tuning.",
@@ -48344,7 +48368,7 @@
"path": "detections/network/net-gre-from-non-network-device.yaml"
},
{
- "id": "det-network-059",
+ "id": "det-network-060",
"type": "detection",
"name": "WireGuard Handshake From User Workstation",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'WireGuard Handshake From User Workstation'. Watch the 1 documented false-positive case before tuning.",
@@ -48367,7 +48391,7 @@
"path": "detections/network/net-wireguard-handshake-from-user.yaml"
},
{
- "id": "det-network-060",
+ "id": "det-network-061",
"type": "detection",
"name": "Corporate VPN Login Originating From Datacenter ASN",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Corporate VPN Login Originating From Datacenter ASN'. Watch the 1 documented false-positive case before tuning.",
@@ -48390,7 +48414,7 @@
"path": "detections/network/net-vpn-from-datacenter.yaml"
},
{
- "id": "det-network-061",
+ "id": "det-network-062",
"type": "detection",
"name": "Tor Introduction To Hidden Service From Corp Host",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Tor Introduction To Hidden Service From Corp Host'. Watch the 1 documented false-positive case before tuning.",
@@ -48413,7 +48437,7 @@
"path": "detections/network/net-tor-introduction-onion.yaml"
},
{
- "id": "det-network-062",
+ "id": "det-network-063",
"type": "detection",
"name": "Cloudflared Tunnel Started From Workstation",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Cloudflared Tunnel Started From Workstation'. Watch the 1 documented false-positive case before tuning.",
@@ -48436,7 +48460,7 @@
"path": "detections/network/net-cloudflared-tunnel-egress.yaml"
},
{
- "id": "det-network-063",
+ "id": "det-network-064",
"type": "detection",
"name": "SMB Version 1 Negotiated In Network Flow",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'SMB Version 1 Negotiated In Network Flow'. Watch the 1 documented false-positive case before tuning.",
@@ -48459,7 +48483,7 @@
"path": "detections/network/net-smbv1-egress.yaml"
},
{
- "id": "det-network-064",
+ "id": "det-network-065",
"type": "detection",
"name": "SMB Write To NETLOGON Share",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'SMB Write To NETLOGON Share'. Watch the 1 documented false-positive case before tuning.",
@@ -48482,7 +48506,7 @@
"path": "detections/network/net-smb-write-netlogon.yaml"
},
{
- "id": "det-network-065",
+ "id": "det-network-066",
"type": "detection",
"name": "SMB Write To SYSVOL Share From Non-DC",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'SMB Write To SYSVOL Share From Non-DC'. Watch the 1 documented false-positive case before tuning.",
@@ -48505,7 +48529,7 @@
"path": "detections/network/net-smb-write-sysvol.yaml"
},
{
- "id": "det-network-066",
+ "id": "det-network-067",
"type": "detection",
"name": "NTLM Relay Indicator (Same Challenge Reused Across Hosts)",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'NTLM Relay Indicator (Same Challenge Reused Across Hosts)'. Watch the 1 documented false-positive case before tuning.",
@@ -48528,7 +48552,7 @@
"path": "detections/network/net-ntlm-relay-pattern.yaml"
},
{
- "id": "det-network-067",
+ "id": "det-network-068",
"type": "detection",
"name": "RPC Remote Registry Write From Workstation Subnet",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'RPC Remote Registry Write From Workstation Subnet'. Watch the 1 documented false-positive case before tuning.",
@@ -48551,7 +48575,7 @@
"path": "detections/network/net-rpc-remote-registry.yaml"
},
{
- "id": "det-network-068",
+ "id": "det-network-069",
"type": "detection",
"name": "RPC Task Scheduler Create From Workstation",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'RPC Task Scheduler Create From Workstation'. Watch the 1 documented false-positive case before tuning.",
@@ -48574,7 +48598,7 @@
"path": "detections/network/net-rpc-task-scheduler-remote.yaml"
},
{
- "id": "det-network-069",
+ "id": "det-network-070",
"type": "detection",
"name": "WinRM HTTPS From Workstation To DC",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'WinRM HTTPS From Workstation To DC'. Watch the 1 documented false-positive case before tuning.",
@@ -48597,7 +48621,7 @@
"path": "detections/network/net-winrm-ssl-from-workstation.yaml"
},
{
- "id": "det-network-070",
+ "id": "det-network-071",
"type": "detection",
"name": "Cobalt Strike Default Named Pipe Pattern",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Cobalt Strike Default Named Pipe Pattern'. Watch the 1 documented false-positive case before tuning.",
@@ -48620,7 +48644,7 @@
"path": "detections/network/net-cobalt-strike-named-pipe.yaml"
},
{
- "id": "det-network-071",
+ "id": "det-network-072",
"type": "detection",
"name": "Sliver Default Named Pipe Pattern",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Sliver Default Named Pipe Pattern'. Watch the 1 documented false-positive case before tuning.",
@@ -48643,7 +48667,7 @@
"path": "detections/network/net-sliver-named-pipe.yaml"
},
{
- "id": "det-network-072",
+ "id": "det-network-073",
"type": "detection",
"name": "Empire C2 Default URI Pattern Observed",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Empire C2 Default URI Pattern Observed'. Watch the 1 documented false-positive case before tuning.",
@@ -48666,7 +48690,7 @@
"path": "detections/network/net-empire-default-uri.yaml"
},
{
- "id": "det-network-073",
+ "id": "det-network-074",
"type": "detection",
"name": "Kerberos Service Ticket Issued With RC4 Encryption",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Kerberos Service Ticket Issued With RC4 Encryption'. Watch the 1 documented false-positive case before tuning.",
@@ -48689,7 +48713,7 @@
"path": "detections/network/net-kerberos-rc4-ticket.yaml"
},
{
- "id": "det-network-074",
+ "id": "det-network-075",
"type": "detection",
"name": "Kerberos Account With Pre-Auth Disabled Used",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'Kerberos Account With Pre-Auth Disabled Used'. Watch the 1 documented false-positive case before tuning.",
@@ -48712,7 +48736,7 @@
"path": "detections/network/net-kerberos-pre-auth-disabled.yaml"
},
{
- "id": "det-network-075",
+ "id": "det-network-076",
"type": "detection",
"name": "RADIUS Authentication Used PAP (Cleartext Password)",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'RADIUS Authentication Used PAP (Cleartext Password)'. Watch the 1 documented false-positive case before tuning.",
@@ -48735,7 +48759,7 @@
"path": "detections/network/net-radius-pap-clear.yaml"
},
{
- "id": "det-network-076",
+ "id": "det-network-077",
"type": "detection",
"name": "LDAP Signing Disabled On Domain Controller",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'LDAP Signing Disabled On Domain Controller'. Watch the 1 documented false-positive case before tuning.",
@@ -48758,7 +48782,7 @@
"path": "detections/network/net-ldap-signing-disabled.yaml"
},
{
- "id": "det-network-077",
+ "id": "det-network-078",
"type": "detection",
"name": "LDAP Search Pattern Matches BloodHound Collection",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'LDAP Search Pattern Matches BloodHound Collection'. Watch the 1 documented false-positive case before tuning.",
@@ -48781,7 +48805,7 @@
"path": "detections/network/net-ldap-bloodhound-pattern.yaml"
},
{
- "id": "det-network-078",
+ "id": "det-network-079",
"type": "detection",
"name": "ICMP Echo With High-Entropy Payload",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'ICMP Echo With High-Entropy Payload'. Watch the 1 documented false-positive case before tuning.",
@@ -48804,7 +48828,7 @@
"path": "detections/network/net-icmp-high-entropy-payload.yaml"
},
{
- "id": "det-network-079",
+ "id": "det-network-080",
"type": "detection",
"name": "DHCP Starvation: Rapid Lease Churn From Single MAC Range",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'DHCP Starvation: Rapid Lease Churn From Single MAC Range'. Watch the 1 documented false-positive case before tuning.",
@@ -48827,7 +48851,7 @@
"path": "detections/network/net-dhcp-starvation.yaml"
},
{
- "id": "det-network-080",
+ "id": "det-network-081",
"type": "detection",
"name": "STP Topology Change Advertised By Edge Port",
"description": "AiSOC v1 curated detection. Triggers on the network signal described by 'STP Topology Change Advertised By Edge Port'. Watch the 1 documented false-positive case before tuning.",
@@ -48849,30 +48873,6 @@
"enabled": true,
"path": "detections/network/net-stp-topology-change-from-edge.yaml"
},
- {
- "id": "det-network-081",
- "type": "detection",
- "name": "DNS TXT Response Over 250 Bytes From Non-Resolver Host",
- "description": "Triggers on the network signal described by 'DNS TXT Response Over 250 Bytes From Non-Resolver Host'. Watch the 1 documented false-positive case before tuning.",
- "version": "1.0.0",
- "author": "Josh Fishman",
- "tags": [
- "tlp.white"
- ],
- "severity": "medium",
- "category": "network",
- "mitre_techniques": [
- "T1071.004",
- "T1048.003"
- ],
- "log_source": "dns",
- "playbook": "tpl-command-and-control",
- "verified": true,
- "source": "core",
- "tier": "stable",
- "enabled": true,
- "path": "detections/network/dns-txt-record.yaml"
- },
{
"id": "dlp-violation-response-v1",
"type": "detection",
diff --git a/scripts/export_detection_ruleset.py b/scripts/export_detection_ruleset.py
index 53681d50a..33da37308 100644
--- a/scripts/export_detection_ruleset.py
+++ b/scripts/export_detection_ruleset.py
@@ -32,17 +32,34 @@ OUT = ROOT / "services" / "fusion" / "app" / "data" / "detection_ruleset.json"
def _build() -> list[dict]:
from detection_specs_index import all_specs # noqa: PLC0415
-
+ from generate_detections import load_id_lock # noqa: PLC0415
+
+ # The id comes from detections/rule-ids.lock.json, the same lookup
+ # generate_detections.py uses for the YAML projection. This used to be
+ # computed positionally here (`seen[category] += 1`) under a comment
+ # claiming it mirrored the generator — which stopped being true when the
+ # generator moved to the lock. The two then numbered rules differently, so
+ # the id the engine stamps onto an alert and the id the catalogue publishes
+ # for the same rule drifted apart, and an analyst looking up a rule id off
+ # an alert read a different rule's description and playbook.
+ #
+ # Positional ids are also unstable by construction: inserting a spec
+ # anywhere but the end shifts every id after it, so an alert's rule id
+ # would not survive a release.
+ id_lock = load_id_lock()
rules: list[dict] = []
- seen: dict[str, int] = {}
for category, spec in all_specs():
match_when = spec.get("match_when")
if not match_when:
continue
slug = spec["slug"]
- # Rule id mirrors generate_detections.py: det-{category}-{NNN}.
- seen[category] = seen.get(category, 0) + 1
- rule_id = f"det-{category}-{seen[category]:03d}"
+ rule_id = id_lock.get(f"{category}/{slug}")
+ if rule_id is None:
+ raise SystemExit(
+ f"error: no rule id locked for {category}/{slug}.\n"
+ "Run `python3 scripts/generate_detections.py` first — it "
+ "allocates ids for new slugs and writes the lock."
+ )
log_source = spec.get("log_source") or {}
rules.append(
{
diff --git a/scripts/generate_detections.py b/scripts/generate_detections.py
index 69a133ed0..2c032d34a 100644
--- a/scripts/generate_detections.py
+++ b/scripts/generate_detections.py
@@ -36,6 +36,7 @@ Design notes
from __future__ import annotations
+import argparse
import json
import re
from datetime import datetime
@@ -639,52 +640,136 @@ def requested_derived_fields(rules: list[dict[str, Any]]) -> set[str]:
return names
-def write_pack(*, dry_run: bool = False) -> dict[str, int]:
- """Generate the full pack to disk. Returns counts per category."""
- id_lock, newly_assigned = assign_ids(CATEGORIES)
- if newly_assigned and not dry_run:
- ID_LOCK.write_text(json.dumps(id_lock, indent=2, sort_keys=True) + "\n", encoding="utf-8")
- print(f" assigned {len(newly_assigned)} new rule id(s)")
+def render_pack(id_lock: dict[str, str]) -> tuple[dict[Path, str], dict[str, int]]:
+ """Render every artifact in memory. Returns (path → content, counts).
+ Rendering is separated from writing so ``--check`` compares exactly the
+ bytes ``main()`` would have written, rather than re-deriving them through a
+ second code path that can disagree with the first.
+ """
+ artifacts: dict[Path, str] = {}
counts: dict[str, int] = {}
+ pos_dir = DETECTIONS_DIR / "fixtures" / "positive"
+ neg_dir = DETECTIONS_DIR / "fixtures" / "negative"
+
for category, specs in sorted(CATEGORIES.items()):
cat_dir = DETECTIONS_DIR / category
- pos_dir = DETECTIONS_DIR / "fixtures" / "positive"
- neg_dir = DETECTIONS_DIR / "fixtures" / "negative"
- if not dry_run:
- _ensure_dir(cat_dir)
- _ensure_dir(pos_dir)
- _ensure_dir(neg_dir)
-
for spec in specs:
slug = spec["slug"]
# Looked up, not computed from position. See ID_LOCK.
rule_id = id_lock[f"{category}/{slug}"]
- yaml_text = render_rule_yaml(rule_id=rule_id, category=category, spec=spec)
- yaml_path = cat_dir / f"{slug}.yaml"
+ artifacts[cat_dir / f"{slug}.yaml"] = render_rule_yaml(
+ rule_id=rule_id, category=category, spec=spec
+ )
+ artifacts[pos_dir / f"{slug}.json"] = json.dumps(spec["positive"], indent=2, sort_keys=True) + "\n"
+ artifacts[neg_dir / f"{slug}.json"] = json.dumps(spec["negative"], indent=2, sort_keys=True) + "\n"
- pos_path = pos_dir / f"{slug}.json"
- neg_path = neg_dir / f"{slug}.json"
+ counts[category] = len(specs)
+ return artifacts, counts
- if dry_run:
- continue
- yaml_path.write_text(yaml_text, encoding="utf-8")
- pos_path.write_text(
- json.dumps(spec["positive"], indent=2, sort_keys=True) + "\n",
- encoding="utf-8",
- )
- neg_path.write_text(
- json.dumps(spec["negative"], indent=2, sort_keys=True) + "\n",
- encoding="utf-8",
- )
+def write_pack(*, dry_run: bool = False) -> dict[str, int]:
+ """Generate the full pack to disk. Returns counts per category."""
+ id_lock, newly_assigned = assign_ids(CATEGORIES)
+ if newly_assigned and not dry_run:
+ ID_LOCK.write_text(json.dumps(id_lock, indent=2, sort_keys=True) + "\n", encoding="utf-8")
+ print(f" assigned {len(newly_assigned)} new rule id(s)")
+
+ artifacts, counts = render_pack(id_lock)
+ if dry_run:
+ return counts
+
+ for path in {DETECTIONS_DIR / c for c in counts} | {
+ DETECTIONS_DIR / "fixtures" / "positive",
+ DETECTIONS_DIR / "fixtures" / "negative",
+ }:
+ _ensure_dir(path)
+ for path, content in artifacts.items():
+ path.write_text(content, encoding="utf-8")
- counts[category] = len(specs)
return counts
+def check_pack() -> int:
+ """Fail if regenerating would change anything already committed.
+
+ Without this, the generator and the committed pack drift silently, and the
+ drift is not cosmetic: the id is the join key between an alert and its
+ catalogue entry. The committed projection had fallen 45 rule ids out of
+ step with the lock, so a rule id taken off an alert resolved to a different
+ rule's description, false-positive notes and playbook.
+ """
+ id_lock, newly_assigned = assign_ids(CATEGORIES)
+ if newly_assigned:
+ print(f"error: {len(newly_assigned)} spec(s) have no locked rule id:")
+ for key in sorted(newly_assigned)[:10]:
+ print(f" {key}")
+ print("Run `python3 scripts/generate_detections.py` and commit the result.")
+ return 1
+
+ artifacts, _ = render_pack(id_lock)
+ moved: list[tuple[str, str, str]] = []
+ changed: list[Path] = []
+ missing: list[Path] = []
+
+ for path, content in sorted(artifacts.items()):
+ if not path.exists():
+ missing.append(path)
+ continue
+ on_disk = path.read_text(encoding="utf-8")
+ if on_disk == content:
+ continue
+ changed.append(path)
+ if path.suffix == ".yaml":
+ before = _yaml_id(on_disk)
+ after = _yaml_id(content)
+ if before and after and before != after:
+ moved.append((str(path.relative_to(ROOT)), before, after))
+
+ if not (moved or changed or missing):
+ print(f"generate_detections --check: OK — {len(artifacts)} artifacts match the specs")
+ return 0
+
+ if moved:
+ print(f"error: regenerating would MOVE {len(moved)} rule id(s).")
+ print("An id is the join key between an alert and its catalogue entry, so")
+ print("moving one makes historical alerts reference the wrong rule.")
+ for rel, before, after in moved[:10]:
+ print(f" {rel}: {before} -> {after}")
+ if len(moved) > 10:
+ print(f" ... and {len(moved) - 10} more")
+ if missing:
+ print(f"error: {len(missing)} generated artifact(s) are not committed, e.g.")
+ for path in missing[:5]:
+ print(f" {path.relative_to(ROOT)}")
+ other = [p for p in changed if str(p.relative_to(ROOT)) not in {m[0] for m in moved}]
+ if other:
+ print(f"error: {len(other)} committed artifact(s) differ from the specs, e.g.")
+ for path in other[:5]:
+ print(f" {path.relative_to(ROOT)}")
+ print("Run `python3 scripts/generate_detections.py` and commit the result.")
+ return 1
+
+
+def _yaml_id(text: str) -> str | None:
+ for line in text.splitlines():
+ if line.startswith("id:"):
+ return line.split(":", 1)[1].strip()
+ return None
+
+
def main() -> int:
+ parser = argparse.ArgumentParser(description="Generate the AiSOC detection pack.")
+ parser.add_argument(
+ "--check",
+ action="store_true",
+ help="fail if regenerating would change the committed pack",
+ )
+ args = parser.parse_args()
+ if args.check:
+ return check_pack()
+
counts = write_pack(dry_run=False)
total = sum(counts.values())
print("AiSOC detection pack regenerated:")
diff --git a/tests/test_detection_id_stability.py b/tests/test_detection_id_stability.py
index 1a557885d..df75b6849 100644
--- a/tests/test_detection_id_stability.py
+++ b/tests/test_detection_id_stability.py
@@ -116,3 +116,139 @@ def test_a_corrupt_lock_refuses_rather_than_renumbering(tmp_path: Path, monkeypa
with pytest.raises(SystemExit, match="unreadable"):
generate_detections.load_id_lock()
+
+
+# ── The lock against what is actually published ────────────────────────────
+#
+# Every test above compares `assign_ids()` output against the lock — and
+# `assign_ids()` reads the lock, so for the property that matters the
+# comparison is circular. None of them looks at what is *published*: the YAML
+# catalogue, the engine ruleset the live worker loads, or the marketplace
+# index. So the lock sat 45 network ids out of step with the committed YAML,
+# the engine and the catalogue named different rules for the same id, and this
+# file passed throughout — under a docstring stating that exact failure.
+#
+# These compare the surfaces against each other, in both directions.
+
+ENGINE_RULESET = REPO_ROOT / "services" / "fusion" / "app" / "data" / "detection_ruleset.json"
+DETECTIONS_DIR = REPO_ROOT / "detections"
+
+
[email protected](scope="module")
+def engine_rules() -> list[dict]:
+ if not ENGINE_RULESET.exists():
+ pytest.skip("detection_ruleset.json not present in this checkout")
+ return list(json.loads(ENGINE_RULESET.read_text(encoding="utf-8"))["rules"])
+
+
[email protected](scope="module")
+def committed_yaml() -> list[dict]:
+ yaml = pytest.importorskip("yaml")
+ rules = []
+ for path in sorted(DETECTIONS_DIR.glob("*/*.yaml")):
+ if "_quarantine" in path.parts or "fixtures" in path.parts:
+ continue
+ loaded = yaml.safe_load(path.read_text(encoding="utf-8"))
+ if isinstance(loaded, dict) and "id" in loaded:
+ rules.append({"path": path, "id": loaded["id"], "name": loaded.get("name", "")})
+ if not rules:
+ pytest.skip("no committed detection YAML in this checkout")
+ return rules
+
+
+def test_engine_ids_come_from_the_lock(engine_rules: list[dict], lock: dict[str, str]) -> None:
+ """The exporter used to number rules positionally.
+
+ Its comment said the id "mirrors generate_detections.py" — true when
+ written, false once the generator moved to the lock. Two generators with
+ two numbering schemes means the id on an alert and the id in the catalogue
+ describe different rules.
+ """
+ wrong = [
+ (rule["id"], lock[f"{rule['category']}/{rule['slug']}"])
+ for rule in engine_rules
+ if lock.get(f"{rule['category']}/{rule['slug']}") not in (None, rule["id"])
+ ]
+ assert not wrong, f"{len(wrong)} engine rule id(s) disagree with the lock: {wrong[:3]}"
+
+
+def test_reordering_specs_does_not_renumber_the_engine(monkeypatch: pytest.MonkeyPatch) -> None:
+ """Position-independence has to hold for the engine, not just the YAML.
+
+ Asserting that a plain re-export is a no-op would not catch a positional
+ exporter, because the lock was seeded from the current spec order — the two
+ schemes agree until the day someone inserts a rule. So this reorders the
+ specs and asserts every id stays put. A positional exporter shifts all of
+ them; a lock-based one shifts none.
+ """
+ import detection_specs_index
+ import export_detection_ruleset
+
+ original = list(detection_specs_index.all_specs())
+ network = [pair for pair in original if pair[0] == "network"]
+ if len(network) < 2:
+ pytest.skip("need at least two network specs to reorder")
+ rest = [pair for pair in original if pair[0] != "network"]
+ reordered = rest + [network[-1]] + network[:-1]
+
+ monkeypatch.setattr(detection_specs_index, "all_specs", lambda: iter(reordered))
+
+ resolved = {f"{r['category']}/{r['slug']}": r["id"] for r in export_detection_ruleset._build()}
+ baseline = {f"{r['category']}/{r['slug']}": r["id"] for r in _build_from(original)}
+ moved = {k: (baseline[k], resolved[k]) for k in baseline if resolved.get(k) != baseline[k]}
+ assert not moved, f"reordering the spec list moved {len(moved)} engine rule id(s): {list(moved.items())[:3]}"
+
+
+def _build_from(specs: list[tuple[str, dict]]) -> list[dict]:
+ """Export the ruleset from an explicit spec order."""
+ import detection_specs_index
+ import export_detection_ruleset
+
+ saved = detection_specs_index.all_specs
+ detection_specs_index.all_specs = lambda: iter(specs)
+ try:
+ return list(export_detection_ruleset._build())
+ finally:
+ detection_specs_index.all_specs = saved
+
+
+def test_committed_yaml_ids_match_the_lock(committed_yaml: list[dict], lock: dict[str, str]) -> None:
+ """The published catalogue must carry the locked id, not a stale one."""
+ by_slug = {}
+ for rule in committed_yaml:
+ by_slug[f"{rule['path'].parent.name}/{rule['path'].stem}"] = rule["id"]
+ wrong = [(slug, rid, lock[slug]) for slug, rid in by_slug.items() if slug in lock and lock[slug] != rid]
+ assert not wrong, (
+ f"{len(wrong)} committed YAML rule id(s) differ from the lock: {wrong[:3]}. "
+ f"Run scripts/generate_detections.py and commit the result."
+ )
+
+
+def test_an_id_names_the_same_rule_in_the_engine_and_the_catalogue(
+ engine_rules: list[dict], committed_yaml: list[dict]
+) -> None:
+ """The user-visible property, stated directly.
+
+ An analyst takes a rule id off an alert (stamped by the engine) and looks
+ it up in the catalogue. If the two disagree they read the wrong rule's
+ description, false-positive notes and playbook. This was live for 45
+ network rules: det-network-037 fired as "DNS TXT Response Over 250 Bytes
+ From Non-Resolver Host" and published as "DNS Tunnel Indicator: Long Hex
+ Subdomain Sequence".
+ """
+ engine_names = {r["id"]: r.get("name", "") for r in engine_rules}
+ disagree = [
+ (rule["id"], rule["name"], engine_names[rule["id"]])
+ for rule in committed_yaml
+ if rule["id"] in engine_names and engine_names[rule["id"]].strip() != rule["name"].strip()
+ ]
+ assert not disagree, f"{len(disagree)} id(s) name a different rule in the engine than in the catalogue: {disagree[:3]}"
+
+
+def test_the_committed_pack_is_what_the_generator_emits() -> None:
+ """`--check` must pass on a clean checkout.
+
+ Drift here is how the id disagreement arose: the generator was correct and
+ the committed pack was months behind it, with nothing comparing the two.
+ """
+ assert generate_detections.check_pack() == 0, "the committed detection pack differs from the specs; run scripts/generate_detections.py"