From 93fef13dea9c46dc238eb59e414d3ae76559d8c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jaime=20Pe=CC=81rez=20Crespo?= Date: Fri, 2 Mar 2018 15:28:28 +0100 Subject: [PATCH] Be strict when checking return values. --- src/SAML2/HTTPRedirect.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/SAML2/HTTPRedirect.php b/src/SAML2/HTTPRedirect.php index 0854c08d7..bbb04c47f 100644 --- a/src/SAML2/HTTPRedirect.php +++ b/src/SAML2/HTTPRedirect.php @@ -222,7 +222,7 @@ public static function validateSignature(array $data, XMLSecurityKey $key) $key = SAML2_Utils::castKey($key, $sigAlg); } - if (!$key->verifySignature($query, $signature)) { + if ($key->verifySignature($query, $signature) !== 1) { throw new Exception('Unable to validate signature on query string.'); } }