seeker89 / chaos-engineering-book

Chaos Engineering: Crash test your applications - the source code
https://www.manning.com/books/chaos-engineering?a_aid=chaos&a_bid=d3243216
47 stars 19 forks source link

Checksums on releases page do not match #24

Open MalcolmAnderson opened 3 years ago

MalcolmAnderson commented 3 years ago

On the resources page https://github.com/seeker89/chaos-engineering-book/releases Not sure what I'm doing wrong

Issue 1 - there is no "parts.sha256" file to check the zip parts against

Issue 2 - The checksums that I get on the files (running cmd on Win10) are as follows D:\Resources\VM_Images\chaos-engineering>CertUtil -hashfile chaos-engineering-VM\chaos-ubuntu-20.04-amd64.ovf SHA1 hash of chaos-engineering-VM\chaos-ubuntu-20.04-amd64.ovf: 48a2af756577969b857b65d0832b0066a75d03e0

My results: Win10 CMD D:\Resources\VM_Images\chaos-engineering>CertUtil -hashfile chaos-engineering-VM\chaos-ubuntu-20.04-amd64-disk001.vmdk SHA1 hash of chaos-engineering-VM\chaos-ubuntu-20.04-amd64-disk001.vmdk: 52c28009bc3cbe445f3b19faa18581c559fd50ac

This does not match the checksums listed on the releases page 699986a4ae32ef15d5f6a9cb67913bcebbad21464289c803c207594b1753a79f ./chaos-engineering-VM/chaos-ubuntu-20.04-amd64-disk001.vmdk 52fe9dbfd826cdd30ea4561e21c1abc991b7214d75c48cf33936b465debe7f6d ./chaos-engineering-VM/chaos-ubuntu-20.04-amd64.ovf

But when I run them on WSL (Ubuntu 20.04) I get slightly different results 00:10:39 mba@Ubuntu:/mnt/d/Resources/VM_Images/chaos-engineering$ shasum -a 256 -c chaos-engineering-VM.sha256 ./chaos-engineering-VM/chaos-ubuntu-20.04-amd64-disk001.vmdk: FAILED ./chaos-engineering-VM/chaos-ubuntu-20.04-amd64.ovf: OK shasum: WARNING: 1 computed checksum did NOT match

seeker89 commented 3 years ago

Hi @MalcolmAnderson thanks for the issue!

1) You're right - the file in the recent releases has been called chaos-engineering-VM.sha256 - thanks for pointing that out, I'll make sure it's fixed in the future releases.

2) Your command in Win10 CMD is producing sha1 - the hashes are sha246. The command you're running in WSL is correct (sha256), but it's saying that the .vmdk file doesn't match the hash (but the .ovf does) - most likely due to a damaged download. Have you tried downloading it again?

Thanks!

MalcolmAnderson commented 3 years ago

First off, re-downloading the parts worked to correct the checksum issue I had.

Added a PR that I hope will make it easier on the next person running on windows. On my screen the sha256 part of the line was on the next line, and, well, it was about 2 am and I wasn't tracking as well as I would have liked. As mentioned in the PR, (in theory) putting the code in a code block will enable github's "copy to clipboard" feature on code blocks.

It would have really been nice to have the parts.sha256 file so I didn't have to download all 3 of them again. Because of this, I created a parts.sha256 file (and validated that it worked in WSL) I had no idea where to put assets, so I put file in the project root, next to the getting-started.md file.

Please let me know what I can do to improve the related PR.

MalcolmAnderson commented 2 years ago

How do I update the assets page in github?

parts.sha256 is now in the root directory of the code, but it doesn't show up on the release.

Also, the release page (https://github.com/seeker89/chaos-engineering-book/releases) has the current instructions tagged as "Pre-release"

Updating the asset instructions would be all that's required to close this issue.