diff --git a/contentctl/objects/detection_tags.py b/contentctl/objects/detection_tags.py index 73849de6..87667c29 100644 --- a/contentctl/objects/detection_tags.py +++ b/contentctl/objects/detection_tags.py @@ -31,7 +31,7 @@ def risk_score(self)->int: return round((self.confidence * self.impact)/100) - mitre_attack_id: List[Annotated[str, Field(pattern="^T\d{4}(.\d{3})?$")]] = [] + mitre_attack_id: List[Annotated[str, Field(pattern="^T[0-9]{4}(.[0-9]{3})?$")]] = [] nist: list[NistCategory] = [] observable: List[Observable] = [] message: Optional[str] = Field(...) @@ -138,6 +138,7 @@ def serialize_model(self): "risk_score": self.risk_score, "security_domain": self.security_domain, "risk_severity": self.risk_severity, + "mitre_attack_id": self.mitre_attack_id, "mitre_attack_enrichments": self.mitre_attack_enrichments } @@ -248,4 +249,4 @@ def mapAtomicGuidsToAtomicTests(cls, v:List[UUID4], info:ValidationInfo)->List[A print(missing_tests_string) return matched_tests + [AtomicTest.AtomicTestWhenTestIsMissing(test) for test in missing_tests] - \ No newline at end of file +