Add detections/ registry for stable cross-project rule-ID linkage - #218
Open
eeee2345 wants to merge 1 commit into
Open
Add detections/ registry for stable cross-project rule-ID linkage#218eeee2345 wants to merge 1 commit into
eeee2345 wants to merge 1 commit into
Conversation
Implements the cross-project detection coverage registry proposed in issue secure-agentic-framework#207: one YAML file per SAF-T ID listing upstream detection rules with maintainer-of-record, semver version range, and last-validated date. SAFE-MCP records the pointer; upstream projects own rule correctness. Initial batch: 7 techniques, 12 entries. Each mapping was verified by reading both the technique description and the upstream rule's detection logic; the notes field records what each rule matches. detections/validate.py checks filename/ID consistency, technique directory existence, rule-ID formats, semver ranges, maintainer handles, and dates; --online additionally resolves rule IDs against the upstream repository. Exits non-zero for CI use. Signed-off-by: Agent Threat Rules <adam@agentthreatrule.org>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements the detections/ registry proposed in #207: a new top-level directory mapping SAF techniques to detection rules maintained by upstream projects, one YAML file per SAF-T ID. SAFE-MCP records the pointer; upstream projects own rule correctness. Each entry carries a GitHub handle as maintainer-of-record, a semver range of upstream releases containing the rule, and a last-validated date.
Initial batch: 7 techniques, 12 entries (SAF-T1001, SAF-T1008, SAF-T1101, SAF-T1102, SAF-T1105, SAF-T1501, SAF-T1503). Every mapping was verified by reading both the technique description and the upstream rule's detection logic, not by keyword match; the notes field on each entry records what the rule actually matches so reviewers can check the mapping without leaving the file.
Also includes detections/validate.py (Apache 2.0, Python 3.9+, PyYAML): validates filename/ID consistency, technique directory existence, per-project rule-ID formats, semver ranges, maintainer handles, and dates. With --online it additionally resolves every rule ID against the upstream repository. Exits non-zero on any failure, so it can run in CI on every PR touching detections/. Happy to add a workflow file for that in this PR or a follow-up, whichever the maintainers prefer.
Registry entries follow the shape discussed in #207 and the boundary it proposes: entries are community-contributed pointers, do not touch technique content, and do not block taxonomy releases. Stale entries have an owner to bump or remove. The registry is project-neutral; other projects (Sigma, etc.) can add entries under the same schema.
Conflict-of-interest disclosure: I maintain ATR, the upstream project referenced by all initial entries, and I am the maintainer-of-record on each of them, so staleness pings land on me.
Type of Contribution
Checklist
git commit -s)Related Issues
Closes #207