Skip to content

Commit

Permalink
fix hash check
Browse files Browse the repository at this point in the history
trusted_hash = upper case, archive_hash = lower case
We need conversion
  • Loading branch information
zpc0 committed Aug 13, 2024
1 parent ce36cf7 commit 3e7091c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion p2pool.spec
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ gpgv --keyring ./SChernykh-keyring.gpg %{SOURCE1}

# calc hashes
trusted_hash=$(sed -n '/Name:\sp2pool_source.tar.xz/,/SHA256:\s/p' %{SOURCE1} | tail -c 65 | head -c 64)
archive_hash=$(sha256sum %{SOURCE0} | head -c 64)
archive_hash=$(sha256sum %{SOURCE0} | head -c 64 | tr '[:lower:]' '[:upper:]')

# check against correct hash
if ! [ $trusted_hash = $archive_hash ]; then
Expand Down

0 comments on commit 3e7091c

Please sign in to comment.