-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
About purl namespace and version fields for rpm #3485
Comments
This issue is stale because it has been labeled with inactivity. |
Hmm. I still prefer embedding epochs into versions as it is how to show versions in Red Hat-based distributions. But we can change it if they agree on that. |
We changed it, but in the document, deb embeds epoch into the version... it is confusing. |
Description
I hit this question when analyzing reports from several tools and comparing the PURL computed by each.
This is more a question rather than an issue.
So for a given image I get the following identification being made on a RedHat UBI based image:
Other tools (commercial) are just for example. Yes one references a centos in a RedHat Distro.
I'll follow only with Syft as comparison as they are my main tools.
As can be seen between Syft and Trivy the differences are :
What did you expect to happen?
All tools shall report the same PURL for the same package.
What happened instead?
Trivy is reporting different PURL than Syft (note: the "small" difference has low if no impact on the vulnerability analysis, it is more a SBOM concern).
Output of run with
-debug
:Output of
trivy -v
:using docker image (aquasec/trivy)
Additional details (base image name, container registry info...):
Namespace question
Comparing rpm to other packager (maven, ...) there isn't really an entity describing the "namespace".
Thus finding the right namespace is left to the SBOM producer... Leaving a decision open leads to inconsistent results.
I initially tought that Trivy naming was better as I would rather have the provider (or packager) being the namespace: hence redhat sounds more appropriate.
I made a rapid study of the information provided by various OS and the computed purl for the same package.
Results are in the below table (purl for both tools, then some info extracted from the packages
rpm -qi
, and information for/etc/os-release
file).This raises indeed a question :
ID
variable onlyCPE_NAME
and probably so does Trivy -- though I am not sure as there is something wrong in the namespace for Almalinux (don't know wherealma
is coming from).CPE_NAME
have precedence and be used as source if provided ?The 1st question is more a global agreement (let say) on which information is expected in order to create the "most" reliable SBOM.
The 2nd one is more for the user of such tool to be alerted when something is detected. It could help greatly to understand the differences we may have in the end.
Version question
This question indeed relates to package-url/purl-spec#69
Again I thought initially that handling Epoch as part of version was better. But reading the thread led me also to the opposite.
So for this part it is more a bug of Trivy (to me now -- thinking differently previously) which shall probably fix and put the epoch as a qualifier and not part of the version number.
The text was updated successfully, but these errors were encountered: