Skip to main content
Question

How to define the same index array

  • April 6, 2026
  • 2 replies
  • 38 views

Alex3Lee5
Forum|alt.badge.img+2

I have an Azure log that contains multiple policy validations. Each validation generates an object inside an array with rule_name and result.

All this information is parsed in SecOps as security_result, so now I have a security_result field with two or more objects.

For example:

 

security_result: (2)

0:
rule_name: "rule_1"
result: "success"

1:
rule_name: "rule_2"
result: "notApplied"

How can I, in Search and YARA-L, perform a validation where rule_name = "rule_1" and the result of that policy is "notApplied", without using a predefined index? The position of rule_name = "rule_1" can change depending on the log.

2 replies

cmorris
Staff
Forum|alt.badge.img+16
  • Staff
  • April 7, 2026

How is the result key value pair being mapped to UDM? Is it something like security_result.rule_labels["result"]  = "notApplied"? Will the rule_name always be rule_1 in this example or does that change with the index?


AymanC
Forum|alt.badge.img+14
  • Bronze 5
  • April 9, 2026

Hi ​@Alex3Lee5,

 

I don’t think there’s this capability in Secops today, might be worth mapping both the rule_name and result into a udm field with a separator, and then call the UDM field, for example:

Values mapped to:
 

security_result.about.labels.key
rule_1

security_result.about.labels.value

rule_1:success

security_result.about.labels.key
rule_2
security_result.about.labels.value

rule_2:notApplied


And then maybe try using:
 

any security_result.about.labels.value = /notApplied/

$RuleNames = re.capture_all(security_result.about.labels.value, “^.*(:)”)

The above should work (not tested)

 

Kind Regards,

Ayman