diff --git a/src/saml2/response.py b/src/saml2/response.py index c40997a..8c6332c 100644 --- a/src/saml2/response.py +++ b/src/saml2/response.py @@ -850,9 +850,13 @@ class AuthnResponse(StatusResponse): """ try: - self._verify() - except AssertionError: + res = self._verify() + except AssertionError as err: + logger.error("Verification error on the response: %s" % err) raise + else: + if res is None: + return None if not isinstance(self.response, samlp.Response): return self