Track a key the engine can supply on three correlations - #733
Merged
CGoggins56 merged 1 commit intoSep 11, 2026
Merged
Conversation
`after: track by_username` groups on the username Sagan resolved for the event. Three rules ask for it without giving the engine any way to resolve one: no `json_map: "username"`, no `normalize`. The key is then empty for every event, they all share one counter, and the rule counts globally instead of per user. Measured against Sagan built from 3b9b0fa, each arm sending the count the rule asks for: rule events ships patched 5008553 one user, one address alert alert 5008553 a different user each time alert alert 5008553 a different address each time alert silent 5008760 one user, one address alert alert 5008760 a different user each time alert alert 5008760 a different address each time alert silent The third row is the defect: twenty-five failures spread across twenty-five hosts and twenty-five accounts raise "Possible Windows Broken Domain Trust", which is the shape the rule exists to rule out. sid 5008760 does the same on five unrelated RDPV.exe events, and its `threshold: type limit` tracks the same empty key. Both rules already carry `parse_src_ip: 1`, so `by_src` is a key the engine fills. If the source carries a user field these rules should bind it with `json_map: "username"` instead, which is the better fix and needs someone who knows the schema. sid 5015220 is the same shape with no consequence: it tracks `by_src&by_username` and binds src_ip, so the empty half changes nothing and the rule already groups per address, which is what its own title says. The dead half is dropped so the line reads as it behaves. Measured: identical on all three arms, before and after. All three have their rev incremented.
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.
after: track by_usernamegroups on the username Sagan resolved for the event. Three rules ask for it without giving the engine any way to resolve one: nojson_map: "username", nonormalize. The key is then empty for every event, they all share one counter, and the rule counts globally instead of per user.Measured against Sagan built from 3b9b0fa, each arm sending the count the rule asks for:
rule events ships patched
5008553 one user, one address alert alert
5008553 a different user each time alert alert
5008553 a different address each time alert silent
5008760 one user, one address alert alert
5008760 a different user each time alert alert
5008760 a different address each time alert silent
The third row is the defect: twenty-five failures spread across twenty-five hosts and twenty-five accounts raise "Possible Windows Broken Domain Trust", which is the shape the rule exists to rule out. sid 5008760 does the same on five unrelated RDPV.exe events, and its
threshold: type limittracks the same empty key.Both rules already carry
parse_src_ip: 1, soby_srcis a key the engine fills. If the source carries a user field these rules should bind it withjson_map: "username"instead, which is the better fix and needs someone who knows the schema.sid 5015220 is the same shape with no consequence: it tracks
by_src&by_usernameand binds src_ip, so the empty half changes nothing and the rule already groups per address, which is what its own title says. The dead half is dropped so the line reads as it behaves. Measured: identical on all three arms, before and after.All three have their rev incremented.