summaryrefslogtreecommitdiffstats
path: root/resources/scripts/helpers/download/grub
diff options
context:
space:
mode:
authorFrancis Rowe <info@gluglug.org.uk>2015-07-12 11:02:39 (EDT)
committer Francis Rowe <info@gluglug.org.uk>2015-07-12 11:15:17 (EDT)
commit6fb9ffefdd9cc64c08cf7627efd8a87a894b0419 (patch)
treea2966652720335b697d68f1e0ac9a7987d679064 /resources/scripts/helpers/download/grub
parentaaab9127058293da378b2639a9907a1d83326514 (diff)
downloadlibreboot-6fb9ffefdd9cc64c08cf7627efd8a87a894b0419.zip
libreboot-6fb9ffefdd9cc64c08cf7627efd8a87a894b0419.tar.gz
libreboot-6fb9ffefdd9cc64c08cf7627efd8a87a894b0419.tar.bz2
download/grub: verify checksums of downloaded files
Diffstat (limited to 'resources/scripts/helpers/download/grub')
-rwxr-xr-xresources/scripts/helpers/download/grub7
1 files changed, 7 insertions, 0 deletions
diff --git a/resources/scripts/helpers/download/grub b/resources/scripts/helpers/download/grub
index 45414dc..8349d93 100755
--- a/resources/scripts/helpers/download/grub
+++ b/resources/scripts/helpers/download/grub
@@ -47,6 +47,13 @@ cd "grub/"
git reset --hard afd0f21b2027310fda52b00ac1b964041d39a363
+# Verify checksums of the downloaded files
+# ------------------------------------------------------------------------------
+
+sha512sum -c "../resources/scripts/helpers/sha512sums/grub" || (cd "../" && rm -Rf "grub/" && printf "Invalid checksums for GRUB\n" && exit 1)
+
+printf "Valid checksums for GRUB\n"
+
# Apply patches
# ------------------------------------------------------------------------------