Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Present new binary for checking hashes #2766

Merged
merged 18 commits into from
Mar 11, 2019
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix bug with other algorithm type
  • Loading branch information
Ash258 committed Jan 17, 2019
commit 2ffcf4a40ff35723128ef76873f64e0ddc6f0d54
7 changes: 7 additions & 0 deletions bin/checkhashes.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,13 @@ $MANIFESTS | ForEach-Object {

$to_check = fullpath (cache_path $current.app $version $_)
$actual_hash = compute_hash $to_check $algorithm

# Append type of algorithm to both expected and actual if it's not sha256
if ($algorithm -ne 'sha256') {
$actual_hash = "$algorithm`:$actual_hash"
$expected = "$algorithm`:$expected"
}

$actuals += $actual_hash
if ($actual_hash -ne $expected) {
$mismatched += $count
Expand Down