-
Notifications
You must be signed in to change notification settings - Fork 399
Comparing changes
Open a pull request
base repository: containers/image
base: v5.30.0
head repository: containers/image
compare: v5.30.1
- 8 commits
- 26 files changed
- 1 contributor
Commits on May 9, 2024
-
Validate digests before using them
If doing it makes sense at all, it should happen before the values are used. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
Configuration menu - View commit details
-
Copy full SHA for 2bcb834 - Browse repository at this point
Copy the full SHA 2bcb834View commit details -
Call .Validate() before digest.Hex() / digest.Encoded()
... to prevent panics if the value does not contain a :, or other unexpected values (e.g. a path traversal). Don't bother on paths where we computed the digest ourselves, or it is already trusted for other reasons. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
Configuration menu - View commit details
-
Copy full SHA for 39e7c91 - Browse repository at this point
Copy the full SHA 39e7c91View commit details -
Refactor the error handling path of saveStream
Use defer() to remove the temporary file, instead of duplicating the call. Should not change behavior. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
Configuration menu - View commit details
-
Copy full SHA for a802d65 - Browse repository at this point
Copy the full SHA a802d65View commit details -
Refactor the error handling further
Use defer, a nested function, and early returns. Besides being a bit more directly related to what we want to achieve, this now does not call decompressed.Close() on a nil value if DecompressStream fails. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
Configuration menu - View commit details
-
Copy full SHA for 4a3785d - Browse repository at this point
Copy the full SHA 4a3785dView commit details -
Call .Validate() before digest.Digest.String() if necessary
... to prevent unexpected behavior on invalid values. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
Configuration menu - View commit details
-
Copy full SHA for a9225e4 - Browse repository at this point
Copy the full SHA a9225e4View commit details -
Validate the tags returned by a registry
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
Configuration menu - View commit details
-
Copy full SHA for b724ee7 - Browse repository at this point
Copy the full SHA b724ee7View commit details -
Merge pull request #2404 from mtrmac/digest-unmarshal-5.30
[release-5.30] Fix CVE-2024-3727
Configuration menu - View commit details
-
Copy full SHA for 132678b - Browse repository at this point
Copy the full SHA 132678bView commit details -
This fixes CVE-2024-3727 . Digest values used throughout this library were not always validated. That allowed attackers to trigger, when pulling untrusted images, unexpected authenticated registry accesses on behalf of a victim user. In less common uses of this library (using other transports or not using the containers/image/v5/copy.Image API), an attacker could also trigger local path traversals or crashes. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
Configuration menu - View commit details
-
Copy full SHA for 56e750a - Browse repository at this point
Copy the full SHA 56e750aView commit details
This comparison is taking too long to generate.
Unfortunately it looks like we can’t render this comparison for you right now. It might be too big, or there might be something weird with your repository.
You can try running this command locally to see the comparison on your machine:
git diff v5.30.0...v5.30.1