I have some questions about the timing of detection rules and their threat enrichments. I am working with the prebuilt rule “Threat Intel IP Address Indicator Match” and I am trying to reduce false positives.
My goal is to create an exception so that alerts are only generated when:
- threat.enrichments.indicator.description = "ip:port combination that is used for botnet Command&Control (C&C)" and
- destination.port is identical to threat.enrichments.indicator.port.
Currently, I am unsure about the behavior of enrichment fields:
- At what stage are threat.enrichments.* fields added to the event?
- Are they available at rule execution time or only afterward?
- Can rule exceptions reliably match against enrichment fields such as
threat.enrichments.indicator.port?
Has anyone implemented a similar port-matching approach to reduce false positives in this rule, or is there a better recommended method?
Any guidance or experience would be appreciated.