Open mustafaqasim opened 5 years ago
+1 to this issue. I am facing the same issue and seem to hit the roadblock.
the select_json path doesn't accept the valid expression. For e.g. to parse id.orig_h we can use $["id.orig_h"] however, the rule rejects double quote and single quote altogether on this. let new_fields = select_jsonpath(m, { ts: "$.ts", uid : "$.uid", id_orig_h: '$["id.orig_h"]' }
has someone figured this part out yet?
I'm trying to use only Pipelines to process logs from Zeek (Bro IDS) and has hit a dead end. The JSON log has key pairs that have dot "." in their name. The JSON log I get in $message.message is as following
I'm parsing that JSON blob with parse_json() and then picking each json object individually and placing into a new field. The nested JSON objects that have another . in them as
id.orig_h
will fail and won't work.Expected Behavior
I should be able to pick the object
id.orig_h
by escaping the . character.Current Behavior
The particular set_fields() having such objects will just not work and those fields won't appear at all. Rest set_fields() works as expected.
Possible Solution
Enable select_jsonselect() to deal with such object having dot "." in their names by escaping it.
Steps to Reproduce (for bugs)
Context
Zeek is a network security monitoring application which generates metadata logs on network connections.
Your Environment