-
Notifications
You must be signed in to change notification settings - Fork 1.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
Multiple vulnerabilities reported by image scan #802
Comments
Thanks for reporting the issue! I'd merge a PR to update the alpine linux docker base image. Another approach that would prevent this issue from occurring would be to use a scratch base image for the final docker image/build. The main issues with this are bundling certs and static builds. We shouldn't be using protobufs directly so that's probably due to a dependency. If you can track that down and update the offending dependency, I'd also merge that PR. |
Yeah, using scratch would be ideal, or at least using maybe something like distroless. It requires some more testing thus I consider it the next step |
I've built and tested an image locally to fix these. I can fix everything but protobuf. When scanning with grype with the The others are all solved in the PR I'm about to submit.
The CVEs listed in the screenshot are fixed by #814 |
Describe the Bug
Multiple vulnerabilities were reported by image scan. I've scanned migrate/migrate:v4.15.2 (current
latest
) with Grype and I saw some vulnerabilities reported.Some are related to the outdated base image alpine:3.13.0 and some are specific for used Go packages. When the migrate/migrate:v4.15.2 image is used in a regulated environment that kind of problem slows down releases, etc. because scanning is part of a CI/CI pipeline. It has to be carefully assessed.
Steps to Reproduce
Just scan the image with some tools for finding vulnerabilities.
Expected Behavior
No vulnerabilities are reported for the newest image.
Additional context
Updating Go, Alpine, and packages will fix it, but only for now. Security bugs are discovered all the time.
As a more robust solution, I propose configuring Dependabot for keeping dependency like a base image and Go packages up to date. For Go packages, I advise enabling dependency graph - security vulnerabilities will be reported automatically (unfortunately it doesn't work for images).
I'll be happy to prepare PRs for the things proposed above. Please let me know what you think about it.
Similar issue #777.
The text was updated successfully, but these errors were encountered: