-
Notifications
You must be signed in to change notification settings - Fork 632
fix: use namespace with name when purl is ecosystem golang in purl decoder #2586
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
fix: use namespace with name when purl is ecosystem golang in purl decoder #2586
Conversation
4becce0
to
31b3c74
Compare
@goatwu1993 thank you for the pull request! 🙏 Please could you sign-off the changes. There's some documentation here about the process. |
…cve because namespace not handled Signed-off-by: goatwu1993 <goatwu1993@gmail.com>
31b3c74
to
4e0dfff
Compare
grype/pkg/purl_provider.go
Outdated
// copy to avoid mutating the original purl object | ||
name := purl.Name | ||
if purl.Namespace != "" { | ||
name = fmt.Sprintf("%s/%s", purl.Namespace, purl.Name) |
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.
I think this is an ecosystem specific decision -- that is, in some cases the namespace should be added (e.g. golang, maven, etc) where as in others it should not (e.g. rpm, deb, etc).
I'll pull changes from #2636 into this so we can get this across the finish line. |
Signed-off-by: Christopher Phillips <32073428+spiffcs@users.noreply.github.com>
@wagoodman since I contributed the other PR and the extra commit on this one can I get your review on this? Feels a little awkward piggy backing on a PR to review code I contributed to 😄 |
Signed-off-by: Christopher Phillips <32073428+spiffcs@users.noreply.github.com>
not sure what i am doing. but this seems to fix #2580