[master 3/3] Handle signature verification errors
marmarek
installerbot-noreply at redhat.com
Thu Oct 1 12:20:06 UTC 2015
From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?=
<marmarek at invisiblethingslab.com>
---
pyanaconda/packaging/dnfpayload.py | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/pyanaconda/packaging/dnfpayload.py b/pyanaconda/packaging/dnfpayload.py
index 292420e..697b30c 100644
--- a/pyanaconda/packaging/dnfpayload.py
+++ b/pyanaconda/packaging/dnfpayload.py
@@ -728,7 +728,13 @@ def install(self):
_failure_limbo()
# Verify GPG signatures
- self.gpgsigcheck(pkgs_to_download)
+ try:
+ self.gpgsigcheck(pkgs_to_download)
+ except dnf.exceptions.Error as e:
+ msg = 'Signature verification failed: %s' % str(e)
+ exc = packaging.PayloadInstallError(msg)
+ if errors.errorHandler.cb(exc) == errors.ERROR_RAISE:
+ _failure_limbo()
log.info('Downloading packages finished.')
--
To view this commit on github, visit https://github.com/rhinstaller/anaconda/commit/778779939552154c93a06b8b2d71c0c62ab8b276
More information about the anaconda-patches
mailing list