4 ms·
It uses SHA-256 right? My understanding is that there isn't yet a workable collision attack on the SHA-2 family. Regardless, I think it's certainly an excellen
by gtsteve 7y ago
It uses SHA-256 right? My understanding is that there isn't yet a workable collision attack on the SHA-2 family.
Regardless, I think it's certainly an excellent hardening step.
- blattimwind 7y agoInfosec in 2019: The server I download code from telling me the hash of said code is "certainly an excellent hardening step".
- ithkuil 7y agoCan't the hash be verified by the client too?
- subway 7y agoSure, but who tells the client what the correct hash is?
- krferriter 7y agoIf you're the entity who created the image you can retain the original hash and verify it against the downloaded copies. But that kind of defeats the purpose of being able to download docker images across distributed hosts. They'd really need to be signatures attached to the images, not just hashes.
- gtsteve 7y agoWell I was approaching it from the point of view that you verify the image is correct and then you guarantee you'll always use that image and not some other version given that tags are mutable.
- darkarmani 7y agoWhy do you need a collision? If you control the build, you control the sha-256 hash. But you can't sign it with a key that you don't have.
- kbirkeland 7y agoA hash only provides integrity. A signature provides integirty and authentication.
- jjeaff 7y agoIntegrity is all you need as long as you have verified the original image that you have saved the hash for.
- kbirkeland 7y agoIs your argument that you only need integrity if you verified the authenticity out of band?
- jjeaff 7y agoNo, I'm saying you only need integrity to validate you are getting the same thing each time. If I checked and made sure an image is safe, then I can save that hash and know that as long as the has matches, I'm always getting that same safe image.
- kbirkeland 7y agoThis is useless without authentication though. You're opening yourself up to attacks on the first retrieve. Sure, you can make sure you're getting the file they want you to have, but you don't know _who_ is giving you that file.