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

feat: adopt proper handling of npm manifest repository #1119

Closed
jkowalleck opened this issue Jul 10, 2024 · 0 comments · Fixed by #1120
Closed

feat: adopt proper handling of npm manifest repository #1119

jkowalleck opened this issue Jul 10, 2024 · 0 comments · Fixed by #1120
Assignees
Labels
enhancement New feature or request

Comments

@jkowalleck
Copy link
Member

https://github.com/CycloneDX/cyclonedx-node-npm/releases/edit/v1.19.2 introduced a fix

CycloneDX externalReferences for vcs type (#1198 via #1202)


this was a quick fix to a larger problem: NPM manifest's repository is not guaranteed to be a URL.
see https://docs.npmjs.com/cli/v10/configuring-npm/package-json#repository

The URL should be a publicly available (perhaps read-only) URL that can be handed directly to a VCS program without any modification.

so valid values could be like git@gitlab.example.com:user/project.git.

the shortcuts with alternative protocols (github:, gitlab:, etc) are out of scope, they are expected to be normalized before processing.

@jkowalleck jkowalleck added the enhancement New feature or request label Jul 10, 2024
@jkowalleck jkowalleck self-assigned this Jul 10, 2024
jkowalleck added a commit that referenced this issue Jul 15, 2024
Changed: `Factories.FromNodePackageJson.ExternalReferenceFactory.makeVcs()` tries to canonicalize git-URLs

fixes #1119

---------

Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant