From 01f0ee1faedcd8e7d1cf8cf606a67d5b6a896f7d Mon Sep 17 00:00:00 2001 From: gianluca-mascolo Date: Sun, 6 May 2018 20:23:51 +0200 Subject: [PATCH] error when download keysign via ipv6 When you try to `make release` keys.gnupg.net may be resolved to an IPv6 address. Under some circumstances (e.g. an internet connection that does not support IPv6) the build sistematically fail with message: "gpg: keyserver receive failed: Cannot assign requested address" I created a fallback to an IPv4 version of keyserver. --- scripts/download | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/download b/scripts/download index 1696def..ae4d665 100755 --- a/scripts/download +++ b/scripts/download @@ -16,7 +16,11 @@ curl -sL ${KERNEL_URL}${KERNEL_SIGN} > ${KERNEL_SIGN} # grab gregkh's stable signing key GPG_KEY="6092693E" +set +e gpg2 --keyserver hkp://keys.gnupg.net --recv-keys $GPG_KEY +[ $? -ne 0 ] && echo "gpg2 key sign download failed. trying second mirror" +set -e +gpg2 --keyserver hkp://ipv4.pool.sks-keyservers.net --recv-keys $GPG_KEY if ! xz -cd ${KERNEL_TAR} | gpg2 --verify ${KERNEL_SIGN} - ; then echo "ERROR: ${KERNEL_TAR} signing error" 1>&2