Repository navigation
Conversation
|
Reviewed against the slice's acceptance criteria. The rule logic is right: it reuses the One blocking process item: this branch was cut before #530 merged, so master has moved. The typosquat corpus entries and the README counts now conflict with yours. Merge master into this branch (or rebase), resolve I am approving the CI workflows so you can see the current head's matrix; the merge gate is the replay against recorded history, same as #521 and #530. |
|
CI confirms what the gates check locally: the only failing test is test_every_shipped_rule_is_on_the_sentinel_page. Every shipped rule needs an entry in docs/integrations/detections-sentinel.md, so add the Sentinel section for self-config-edit-then-action alongside the detection-rules.md and Sigma entries you already wrote. Together with the master merge from my earlier comment, that clears the red matrix. |
blitzcrieg1
left a comment
There was a problem hiding this comment.
Thanks for working on this detection slice. The Ubuntu CI run fails tests/test_sentinel.py::test_every_shipped_rule_is_on_the_sentinel_page: self-config-edit-then-action is registered as a shipped rule but is missing from docs/integrations/detections-sentinel.md. Please add the Sentinel entry or document why it is unsupported, then rerun the full suite. This PR is also based on e6d3ae8; current master is 0bb56a3, so please update the branch before the final CI run. Once CI and the benchmark are green, I will run the private historical replay required before merge.
Implements the
edits_self_configsequence detection slice from #317 under the community detection program (#454).Summary
rule_self_config_edit_then_action(self-config-edit-then-action, severityhigh,TA0005/T1562) inapps/orchestrator/agentmetry/core/audit/detection/rules.pyusing_first_pairso a successful write to agent-governing config/hook files (~/.claude/settings.json,~/.cursor/hooks.json,~/.codex/hooks.json, etc.) followed by any subsequenttool_calledaction withinsequence_window_minutesfires a finding. Supports both default redacted privacy mode (edits_self_configtrait) and unredacted write/shell fallback.shell_writes_self_configinapps/orchestrator/agentmetry/core/audit/mitre.pyso mixed credential-exfil + self-config write commands preserveT1552.001.attack_self_config_edit_then_action.jsonl) and benign (benign_project_settings_write_then_action.jsonl) corpus cases incorpus.yaml.docs/integrations/sigma/agentmetry_rule_self_config_edit_then_action.yml) and updateddocs/detection-rules.md,README.md, andtests/test_readme_claims.py.apps/orchestrator/tests/test_detection_self_config.pycovering fires, redacted mode, unredacted fallback, no follow-up action, denied write, reversed order, benign project settings, read-only access, sequence window expiration, and mixed exfil preservation.Verification
python -m agentmetry.cli benchmark:124 cases (62 attack, 62 benign), 22 rules covered, 65 expected / 65 detected, 0 missed, 0 false positivespython -m pytest -q tests/test_detection_self_config.py tests/test_detection_benchmark.py tests/test_sigma_pack.py tests/test_readme_claims.py:68 passedRefs #317