-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Golang stdlib vulnerabilities #4133
Comments
can you please try |
Thanks @itaysk , it tried but it does not work. Details and observations.
This binary was compiled with
but did not provide known CVEs for Golang runtime environment used during binary compilation, e.g. I was not able no find CVE-2023-24538 in Trivy output:
|
It is not supported now. I think we have the same issue in our GitHub Issues, but I couldn't find it... |
Did you mean #3786 ? Can confirm that |
This issue is not about the whole Trivy ability to detect Go binaries and find CVEs, but only about ability to find CVEs in Golang runtime environment used during binary compilation. As mentioned in one of the previous comments Trivy with Therefore, if your Go binary is compiled with e.g. I checked the latest Trivy v0.44 with |
i will be happy to work on this . If trivy team can provide some guidance on how they would like to see this implemented , that would be great .Thanks 😃 |
Just informative, but the image below is how we got aware of the issue: Prometheus quay.io/prometheus/prometheus:v2.44.0) Other tools like Grype were able to detect golang vulnerabilities in it. |
It plans to be included in v0.52.0. |
Adding some notes (cc: @DmitriyLewen) We switched from the Go Vulnerability Database to the GitHub Advisory Database (GHSA) as GHSA imports data from the Go Vulnerability Database, and both use the OSV format, so their data should be consistent. However, I noticed that there are discrepancies between the GitHub Advisory Database and the Go Vulnerability Database. Specifically, there are differences in the package paths. In GHSA, the "affected[].package.name" field includes package names like "net/http", whereas in the Go Vulnerability Database, it is listed as "stdlib", and "net/http" is mentioned under "ecosystem_specific". We added the Go toolchain version as |
@knqyf263 created aquasecurity/vuln-list-update#288 for this task. |
Thanks. We'll discuss the specific implementation there. |
Hello! Thank you for the great tool!
I am wondering, is it possible with Trivy to detect known CVEs in Golang runtime environment used during binary compilation while scanning it with (with
trivy rootfs /path/to/binary
)?Let's say I have a binary compiled with <go1.19.8: is there any way to ask Trivy to provide me an information that used runtime has known issues (like https://pkg.go.dev/vuln/GO-2023-1703 / https://avd.aquasec.com/nvd/2023/cve-2023-24538) ?
As far as I understand from this article Trivy fetches information about dependencies from binary (something like
go version -m
) and provides information about known issues. Although information about runtime version is available in binary (if it is not stripped), I was not able to find a way how to ask Trivy to output known issues in go runtime for some testing binaries, e.g. rakkess (with go1.13.7) from raesene/alpine-containertools image mentioned in the article.I definitely missing something, thanks for you support!
The text was updated successfully, but these errors were encountered: