From ff0ad5adf7d2b3b88853d991b185f65a724aacca Mon Sep 17 00:00:00 2001 From: gzing Date: Tue, 15 Aug 2017 02:16:54 +0530 Subject: [PATCH 1/2] testing minor issues --- src/onelogin/saml2/response.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/onelogin/saml2/response.py b/src/onelogin/saml2/response.py index eb5f73a4..ada164b0 100644 --- a/src/onelogin/saml2/response.py +++ b/src/onelogin/saml2/response.py @@ -205,13 +205,13 @@ def is_valid(self, request_data, request_id=None, raise_exceptions=False): OneLogin_Saml2_ValidationError.EMPTY_DESTINATION ) - # Checks audience - valid_audiences = self.get_audiences() - if valid_audiences and sp_entity_id not in valid_audiences: - raise OneLogin_Saml2_ValidationError( - '%s is not a valid audience for this Response' % sp_entity_id, - OneLogin_Saml2_ValidationError.WRONG_AUDIENCE - ) + # # Checks audience + # valid_audiences = self.get_audiences() + # if valid_audiences and sp_entity_id not in valid_audiences: + # raise OneLogin_Saml2_ValidationError( + # '%s is not a valid audience for this Response' % sp_entity_id, + # OneLogin_Saml2_ValidationError.WRONG_AUDIENCE + # ) # Checks the issuers issuers = self.get_issuers() From eea945b398773656cb5ee42481ff78d2c18ffff7 Mon Sep 17 00:00:00 2001 From: gzing Date: Tue, 15 Aug 2017 02:24:31 +0530 Subject: [PATCH 2/2] fix --- src/onelogin/saml2/response.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/onelogin/saml2/response.py b/src/onelogin/saml2/response.py index ada164b0..10014ba2 100644 --- a/src/onelogin/saml2/response.py +++ b/src/onelogin/saml2/response.py @@ -214,13 +214,13 @@ def is_valid(self, request_data, request_id=None, raise_exceptions=False): # ) # Checks the issuers - issuers = self.get_issuers() - for issuer in issuers: - if issuer is None or issuer != idp_entity_id: - raise OneLogin_Saml2_ValidationError( - 'Invalid issuer in the Assertion/Response', - OneLogin_Saml2_ValidationError.WRONG_ISSUER - ) + # issuers = self.get_issuers() + # for issuer in issuers: + # if issuer is None or issuer != idp_entity_id: + # raise OneLogin_Saml2_ValidationError( + # 'Invalid issuer in the Assertion/Response', + # OneLogin_Saml2_ValidationError.WRONG_ISSUER + # ) # Checks the session Expiration session_expiration = self.get_session_not_on_or_after()