Changed MitreTechniques alias to MitreTags due to MitreTags is included
tags expect techniques.
This commit is contained in:
@@ -5,8 +5,8 @@ Channel: "%Channel%"
|
||||
Level: "%Level%"
|
||||
EventID: "%EventID%"
|
||||
MitreAttack: "%MitreTactics%"
|
||||
MitreTechnique: "%MitreTechniques%"
|
||||
Tags: "%OtherTags%"
|
||||
MitreTags: "%MitreTags%"
|
||||
OtherTags: "%OtherTags%"
|
||||
RecordID: "%RecordID%"
|
||||
RuleTitle: "%RuleTitle%"
|
||||
Details: "%Details%"
|
||||
|
||||
@@ -325,7 +325,7 @@ impl Detection {
|
||||
.collect();
|
||||
profile_converter.insert("%MitreTactics%".to_string(), tactics.join(" : "));
|
||||
}
|
||||
"%MitreTechniques%" => {
|
||||
"%MitreTags%" => {
|
||||
let techniques: &Vec<String> = &tag_info
|
||||
.iter()
|
||||
.filter(|x| {
|
||||
@@ -336,13 +336,11 @@ impl Detection {
|
||||
})
|
||||
.map(|y| {
|
||||
let mut replaced_tag = y.replace("attack.", "");
|
||||
let (head, _) = replaced_tag.split_at_mut(1);
|
||||
head.make_ascii_uppercase();
|
||||
replaced_tag.to_owned()
|
||||
make_ascii_titlecase(&mut replaced_tag)
|
||||
})
|
||||
.collect();
|
||||
profile_converter
|
||||
.insert("%MitreTechniques%".to_string(), techniques.join(" : "));
|
||||
.insert("%MitreTags%".to_string(), techniques.join(" : "));
|
||||
}
|
||||
"%OtherTags%" => {
|
||||
let tags: &Vec<String> = &tag_info
|
||||
@@ -459,7 +457,7 @@ impl Detection {
|
||||
.collect();
|
||||
profile_converter.insert("%MitreTactics%".to_string(), tactics.join(" : "));
|
||||
}
|
||||
"%MitreTechniques%" => {
|
||||
"%MitreTags%" => {
|
||||
let techniques: &Vec<String> = &tag_info
|
||||
.iter()
|
||||
.filter(|x| {
|
||||
@@ -470,13 +468,11 @@ impl Detection {
|
||||
})
|
||||
.map(|y| {
|
||||
let mut replaced_tag = y.replace("attack.", "");
|
||||
let (head, _) = replaced_tag.split_at_mut(1);
|
||||
head.make_ascii_uppercase();
|
||||
replaced_tag.to_owned()
|
||||
make_ascii_titlecase(&mut replaced_tag)
|
||||
})
|
||||
.collect();
|
||||
profile_converter
|
||||
.insert("%MitreTechniques%".to_string(), techniques.join(" : "));
|
||||
.insert("%MitreTags%".to_string(), techniques.join(" : "));
|
||||
}
|
||||
"%OtherTags%" => {
|
||||
let tags: &Vec<String> = &tag_info
|
||||
|
||||
@@ -42,7 +42,7 @@ lazy_static! {
|
||||
"%RuleFile%",
|
||||
"%EvtxFile%",
|
||||
"%MitreTactics%",
|
||||
"%MitreTechniques%",
|
||||
"%MitreTags%",
|
||||
"%OtherTags%"
|
||||
];
|
||||
pub static ref PRELOAD_PROFILE_REGEX: RegexSet = RegexSet::new(&*PRELOAD_PROFILE).unwrap();
|
||||
|
||||
Reference in New Issue
Block a user