commit:     ef01e3d9373cb64320df290494c13e3f2cf6a0c0
Author:     Zac Medico <zmedico <AT> gentoo <DOT> org>
AuthorDate: Mon Jul 23 04:26:25 2018 +0000
Commit:     Zac Medico <zmedico <AT> gentoo <DOT> org>
CommitDate: Fri Jul 27 16:08:26 2018 +0000
URL:        https://gitweb.gentoo.org/proj/portage.git/commit/?id=ef01e3d9

emerge-webrsync: exit early for signature problem (bug 661838)

Exit early after signature verification failure, since it's
typically inappropriate to try other mirrors in this case
(it may indicate a keyring problem).

Bug: https://bugs.gentoo.org/661838
Reviewed-by: Brian Dolbec <dolsen <AT> gentoo.org>

 bin/emerge-webrsync | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/bin/emerge-webrsync b/bin/emerge-webrsync
index 560dd0236..b135567b7 100755
--- a/bin/emerge-webrsync
+++ b/bin/emerge-webrsync
@@ -191,6 +191,13 @@ check_file_signature() {
                                        fi
                                done <<< "${gnupg_status}"
                        fi
+                       if [[ ${r} -ne 0 ]]; then
+                               # Exit early since it's typically inappropriate 
to
+                               # try other mirrors in this case (it may 
indicate
+                               # a keyring problem).
+                               eecho "signature verification failed"
+                               exit 1
+                       fi
                else
                        eecho "cannot check signature: gpg binary not found"
                        exit 1

Reply via email to