Skip to content

Commit

Permalink
added feature of tag output reducing to agg condition #477
Browse files Browse the repository at this point in the history
  • Loading branch information
hitenkoku committed Apr 14, 2022
1 parent 9da46b9 commit 5f13b04
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/detections/detection.rs
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,8 @@ impl Detection {
.as_vec()
.unwrap_or(&Vec::default())
.iter()
.map(|info| info.as_str().unwrap_or("").replace("attack.", ""))
.filter_map(|info| TAGS_CONFIG.get(info.as_str().unwrap_or(&String::default())))
.map(|str| str.to_owned())
.collect();
let output = Detection::create_count_output(rule, &agg_result);
let rec_info = if configs::CONFIG.read().unwrap().args.is_present("full-data") {
Expand Down

0 comments on commit 5f13b04

Please sign in to comment.