From b7ae9722867f1550a94a759c27ba14f470b5dc75 Mon Sep 17 00:00:00 2001 From: Simo Sorce Date: Fri, 6 Nov 2015 20:34:05 -0500 Subject: Silence broad-except warnings Signed-off-by: Simo Sorce --- custodia/httpd/authenticators.py | 2 +- custodia/httpd/server.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/custodia/httpd/authenticators.py b/custodia/httpd/authenticators.py index ecd3d30..88b6136 100644 --- a/custodia/httpd/authenticators.py +++ b/custodia/httpd/authenticators.py @@ -112,7 +112,7 @@ class SimpleAuthKeys(HTTPAuthenticator): if constant_time.bytes_eq(val.encode('utf-8'), key.encode('utf-8')): validated = True - except Exception: + except Exception: # pylint: disable=broad-except self.audit_svc_access(log.AUDIT_SVC_AUTH_FAIL, request['client_id'], name) return False diff --git a/custodia/httpd/server.py b/custodia/httpd/server.py index 4b16edc..47c69ed 100644 --- a/custodia/httpd/server.py +++ b/custodia/httpd/server.py @@ -160,7 +160,7 @@ class HTTPRequestHandler(BaseHTTPRequestHandler): creds = self.request.getsockopt(socket.SOL_SOCKET, SO_PEERSEC, SELINUX_CONTEXT_LEN) context = creds.decode('utf-8') - except Exception: + except Exception: # pylint: disable=broad-except logger.debug("Couldn't retrieve SELinux Context", exc_info=True) context = None -- cgit