hashdeep
hashdeep copied to clipboard
Inconsistent file ordering when generating checksums
Performed md5deep -r folder/
several consecutive times, my surprise is that each time the file order may differ, even if the contents are exactly the same. For example:
First checksum generation:
md5deep -r folder/ > 1.md5
xxxx clonezilla.iso
xxxx debian.iso
xxxx gparted.iso
xxxx Mac.iso
xxxx archlinux.iso
xxxx memtest86-usb.zip
Second checksum generation:
md5deep -r folder/ > 2.md5
xxxx clonezilla.iso
xxxx gparted.iso
xxxx debian.iso
xxxx Mac.iso
xxxx memtest86-usb.zip
xxxx Microsoft.exe
I can't perform any diff 1.md5 2.md5
because the order differs, have to sort them first. Can this be fixed or the file list is randomly generated then checksum is performed?
Maybe it's because of this: https://github.com/jessek/hashdeep/issues/394
Do this: diff <(sort 1.md5) <(sort 2.md5)