Skip to content
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

Ensuring that the evidence.identity format is maintained after components are trimmed #1591

Merged
merged 2 commits into from
Jan 23, 2025

Conversation

emcfins
Copy link
Contributor

@emcfins emcfins commented Jan 22, 2025

Closes #1541

With spec version 1.5, some evidence.identity objects are cast to arrays and failing the format validation. This change checks if the original evidence.identity is an array, if it's not, it casts it back into the original object.

This change saves the original Array.isArray check as a variable. After the logic required is completed and if the value of the variable is false, then it sets the value back to the original object.

Tested on a codebase where the validation had previously failed and it now passes the validation.

erinmcgill and others added 2 commits January 22, 2025 11:57
Ensuring that the evidence.identity format is maintained after components are trimmed
@emcfins emcfins requested a review from prabhu as a code owner January 22, 2025 19:02
Copy link
Collaborator

@prabhu prabhu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@prabhu
Copy link
Collaborator

prabhu commented Jan 23, 2025

Could you kindly sign the commits by following the instructions here? https://github.com/CycloneDX/cdxgen/pull/1591/checks?check_run_id=36016547177

@prabhu prabhu merged commit 3d35d2a into CycloneDX:master Jan 23, 2025
21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unable to create SBOM with CDXGen 11
3 participants