-
Notifications
You must be signed in to change notification settings - Fork 931
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
Trivy vulnerability scanning #14145
Trivy vulnerability scanning #14145
Conversation
@simondeziel @tomponline Notice how it is possible to filter the alerts by tool. Unfortunately, since GitHub does not support setting custom filters for alerts and we do not use tags nor branches to mark the versions used in each snap channel, we can't filter alerts from each snap channel scan easily. |
Lets check its actually working on the snap scan first, we need to confirm its actually recognising the deps inside the snap. |
Works for me! Another option would also be appending the channel in the beginning of the alert name. For example: |
can you do that too so its clear its coming from a snap alert |
17740fc
to
4442aa5
Compare
Ready for review? |
80fb66a
to
93dbcf4
Compare
@tomponline Now it is! Example of alerts for the snap scanner, the repo scanner alerts are the same. |
93dbcf4
to
297e0ec
Compare
One more image to ilustrate one particular behavior, if more than one version has the same vulnerability, the most recent is shown in the alert title, I believe this is because the alert ID is the same so the title should stay constant across branches. They are still filtered by branch and have the indicator on the side so in my view this doesn't hurt the UX. |
Does the repo scan generate the vuln cache dir? If so can we get it to update the cache when it finishes and then have the snap task depend on it? |
Yes, we can! |
297e0ec
to
b687ae4
Compare
@tomponline @simondeziel Requested changes made |
Signed-off-by: hamistao <[email protected]>
Signed-off-by: hamistao <[email protected]>
b687ae4
to
5f9f0cf
Compare
uses: github/codeql-action/upload-sarif@v3 | ||
with: | ||
sarif_file: "${{ matrix.version }}-stable.sarif" | ||
sha: ${{ github.sha }} |
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.
do we need to provide this line at all?
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 also find it confusing but I get an error if I don't provide both sha
and ref
. The error explicitly says both are needed here.
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.
can parse the version from the snap somehow, and use the ref of the associated tag perhaps?
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 will try and see if I can get something like this working
The PRs for microcloud and microcluster will be ready soon. |
This adds two jobs to our workflows. One uses Trivy to scan LXD's dependencies and the other scans the snap.