-
Notifications
You must be signed in to change notification settings - Fork 597
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
505 merging of multiple bundles into a single matrix #613
505 merging of multiple bundles into a single matrix #613
Conversation
public get_technique_domain(stixSDO: any): string { | ||
return stixSDO.x_mitre_domains[0]; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- For techniques in multiple domains, this function would only check the first listed domain and disregard all other domains. While ATT&CK doesn't currently have cross-domain techniques, this should support custom datasets that do.
- I suggest removing the
stixSDO
parameter from this function, and instead update the Technique constructor (which already has access to thestixSDO
) to store thex_mitre_domain
field as a class property. This would enhance the accessibility of the data within the class.
if(domain.techniques[j].get_technique_domain(techniqueSDOslist[j]) == matricesList[i].external_references[0].external_id) { | ||
techniquesList.push(domain.techniques[j]); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This logic should be updated to check if the matrix ID matches any of the domains listed in the technique's x_mitre_domains
field. See other comment for more details.
matricesList[i].external_references[0].external_id == domain[techniques[j].x_mitre_domains
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks great. The functionality to view multiple bundles/matrices is working. I have one comment on the logic for checking if a technique is part of a matrix/domain.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Thanks for making these updates. Please take a look at the two issues reported by SonarCloud and see if they can be addressed. Once that's done, we can merge this in!
Quality Gate passedIssues Measures |
This PR addresses issue #505.