Add an "id:" tag to the baseline .yaml files for easier distinction between baselines versus using the "title:" tag #251

Closed
opened 2026-01-19 18:29:48 +00:00 by michael · 1 comment
Owner

Originally created by @liquidoshin on GitHub.

Problem to solve

My software I'm writing gathers all the baseline files, parses each file and stores each files sections/tags into an object. It would be easier to have a separate tag called, for instance, "id:" with just the baseline name and not all the other contents that exists in the title tag. This would make for easier string comparison to make sure the application is looking at the right baseline by doing a simple
if id == "800-53-r5" ......
versus having to get into using regex on the title to get the baseline that it actually is.

Intended users

Anyone writing software that utilizes this macOS_security repo. Adding this new tag wouldn't (to my knowledge) ruin anyone's pre-existing code as it's just an additional tag (unless someone was using the exact format of the yaml file in a way that any changes altered their object etc).

Further details

Proposal

Just add an id: tag to each baseline with the value of that tag being the guidance name. Essentially the id tag value would be the yaml file's name minus the .yaml so 800-53r5_high or DISA-STIG or cnssi-1253 etc...

Documentation

Testing

What does success look like, and how can we measure that?

Originally created by @liquidoshin on GitHub. ### Problem to solve My software I'm writing gathers all the baseline files, parses each file and stores each files sections/tags into an object. It would be easier to have a separate tag called, for instance, "id:" with just the baseline name and not all the other contents that exists in the title tag. This would make for easier string comparison to make sure the application is looking at the right baseline by doing a simple if id == "800-53-r5" ...... versus having to get into using regex on the title to get the baseline that it actually is. ### Intended users Anyone writing software that utilizes this macOS_security repo. Adding this new tag wouldn't (to my knowledge) ruin anyone's pre-existing code as it's just an additional tag (unless someone was using the exact format of the yaml file in a way that any changes altered their object etc). ### Further details <!-- Include use cases, benefits, and/or goals (contributes to our vision?) --> ### Proposal Just add an id: tag to each baseline with the value of that tag being the guidance name. Essentially the id tag value would be the yaml file's name minus the .yaml so 800-53r5_high or DISA-STIG or cnssi-1253 etc... ### Documentation <!-- Relevant documentation to the feature--> ### Testing <!-- What risks does this change pose? How might it affect the quality of the product? What additional test coverage or changes to tests will be needed? --> ### What does success look like, and how can we measure that? <!-- Define both the success metrics and acceptance criteria. Note that success metrics indicate the desired business outcomes, while acceptance criteria indicate when the solution is working correctly. If there is no way to measure success, link to an issue that will implement a way to measure this. --> ### Links / references <!-- Any relevant links or references -->
Author
Owner

@brodjieski commented on GitHub:

Since the id: tag you are suggesting is just the file name minus the .yaml, would you be able to just read the file name and use that for your needs?

@brodjieski commented on GitHub: Since the id: tag you are suggesting is just the file name minus the .yaml, would you be able to just read the file name and use that for your needs?
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: usnistgov/macos_security#251