Multi Commander > Support and Feedback

File Verifier does NOT check sha files

(1/3) > >>

SwissKnife64:
Observation: when clicking on SHA checksum file, the "File Verifier" opens. I can add the corresponding file for check. Pressing the start button for the SHA check , 0 (zero) files are checked.
Using the dialog with only a MD5 checksum, the dialog adds the corresponding fiel automatically and check works fine.

Expectation: the SHA check works the same way as the MD5 check.

Version: (x64) v16.2 (build 3205)

Mathias (Author):
What kind of checksum file..  .md5 file ?  .sha1 ? how do the file look like ? any error message in logview (Ctrl+L ) ?


SwissKnife64:
The "File Verifier" works for

* .MD5 file with binary mark (after check sum a "space" and a "*") and file name

* .SHA1 file with text mark (after check sum 1 or 2 "space" ) and file name.
The specification allows for all checksum files .MD5, .SHA1, .SHA256 and SHA512 the binary make " *" or the text mark "  ".

The extension .SHA is recognized as checksum file, but no calculations are done

If the file name is missing in the checksum file, I can drop a file in the "File Verifier". I expect that the calculation is then done with this fiel. No calculation is done.

Examples of accepted and not accepted check sum files are attached

Powershell 7 command to  generate a accepted .MD5 checksum
$hashObj = Get-FileHash -Path .\LoreIpsum.txt -Algorithm MD5
"{0} *{1}" -f $hashObj.Hash, (Split-Path $hashObj.Path -Leaf) | Out-File -FilePath ".\LoreIpsum.md5"

Powershell 7 command to  generate a accepted .SHA1 checksum (no * in output, but it is calculated as binary)
$hashObj = Get-FileHash -Path .\LoreIpsum.txt -Algorithm SHA1
"{0}  {1}" -f $hashObj.Hash, (Split-Path $hashObj.Path -Leaf) | Out-File -FilePath ".\LoreIpsum.SHA1"

Mathias (Author):
I'm not sure I understand everything you trying to say?

So if the checksum file has 2 or more space between checksum and filename it does not work ?
if file does not contain filename it does not work..
and .SHA does work ?



SwissKnife64:
The specification for a checksum file are
[checksum][space][format][filename]

The format is a space for text or a * for binary, resulting in a 2 spaces separator "  " or a space and * separator " *"

Following the specifications, a file that is calculated as text has 2 spaces between checksum and file name, a file that is calculated as binary input has a space and a * between checksum and filename

Your "File Verifier" only accepts the " *" separator for .MD5 files
Your "File Verifier" only accepts the " " or "  " separator for .SHA1, .SHA256 or .SHA512 files

https://share.google/aimode/iNfBL2kQlHTPmklSb

Navigation

[0] Message Index

[#] Next page

Go to full version