From d0a6c7e0043e7af8504e9adb71dbc192638dd590 Mon Sep 17 00:00:00 2001
From: Olav Morken <olav.morken@uninett.no>
Date: Mon, 7 Mar 2011 13:27:28 +0000
Subject: [PATCH] SAML2_SOAPClient: Don't throw exception when https key isn't
 included in metadata.

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@2766 44740490-163a-0410-bde0-09ae8108e29a
---
 lib/SAML2/SOAPClient.php | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/SAML2/SOAPClient.php b/lib/SAML2/SOAPClient.php
index 15b0690a9..0ba6ebea8 100644
--- a/lib/SAML2/SOAPClient.php
+++ b/lib/SAML2/SOAPClient.php
@@ -189,7 +189,8 @@ class SAML2_SOAPClient {
 		}
 
 		if ($keyInfo['key'] !== $data) {
-			throw new Exception('Key on SSL connection did not match key we validated against.');
+			SimpleSAML_Logger::debug('Key on SSL connection did not match key we validated against.');
+			return FALSE;
 		}
 
 		SimpleSAML_Logger::debug('Message validated based on SSL certificate.');
-- 
GitLab