Created
December 29, 2023 15:16
-
-
Save rm5248/b2abba4bb4f1d9cf518be49d064a0be1 to your computer and use it in GitHub Desktop.
Validate Apache Release
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -e | |
# BASE_DL example: https://dist.apache.org/repos/dist/dev/logging/log4cxx/ | |
# ARCHIVE example: apache-log4cxx-1.2.0 | |
BASE_DL=$1 | |
ARCHIVE=$2 | |
FULL_DL="$1/$2" | |
wget "$FULL_DL.tar.gz" | |
wget "$FULL_DL.tar.gz.asc" | |
wget "$FULL_DL.tar.gz.sha512" | |
wget "$FULL_DL.zip" | |
wget "$FULL_DL.zip.asc" | |
wget "$FULL_DL.zip.sha512" | |
echo "Validating SHA512..." | |
sha512sum --check $ARCHIVE.tar.gz.sha512 | |
sha512sum --check $ARCHIVE.zip.sha512 | |
echo "Validating signature..." | |
gpg --verify $ARCHIVE.tar.gz.asc | |
gpg --verify $ARCHIVE.zip.asc |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment