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

Add IRI Validation for externalReference URL #1140

Merged
merged 4 commits into from
Jun 5, 2024

Conversation

timmyteo
Copy link
Collaborator

@timmyteo timmyteo commented Jun 5, 2024

Per @prabhu, this pull request is to address #1107 and is an alternative to the open pull request #1130

This adds the validate-iri dependency to be used to filter out invalid IRI in the BOM for externalReferences

const result = validateIri(iri, IriValidationStrategy.Strict);

if (result instanceof Error) {
return false;
Copy link
Collaborator

Choose a reason for hiding this comment

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

Maybe log the url in debug mode?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Added!

@prabhu prabhu merged commit 061ce91 into CycloneDX:master Jun 5, 2024
19 checks passed
@timmyteo timmyteo deleted the feature/issue-1107-simple branch June 10, 2024 13:25
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.

2 participants