Skip to content

POST /v1/query - returns wrong results for probably malformed purl (helmv3) #4484

@idangur-cglx

Description

@idangur-cglx

Describe the bug
When using the API I am getting all of the vulnerabilities that ever existed for helmv3 for the following purl:
pkg:golang/helm.sh/helm/[email protected] (v3.19.2 / latest)
that purl was fetched from an SBOM generated by Syft and there is no alias with the proper version, when using the purl:
pkg:golang/helm.sh/helm/[email protected]
it returns no vulnerabilities as expected

To Reproduce
Steps to reproduce the behavior:

  1. POST /v1/query - data: {"package": {"purl": "pkg:golang/helm.sh/helm/[email protected]"}}
  2. See results returned
  3. POST /v1/query - data: {"package": {"purl": "pkg:golang/helm.sh/helm/[email protected]"}}
  4. No vulnerabilities

Expected behavior
To receive no vulnerabilities when querying this or a malformed version instead of all of them

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions