From a8902fe119593f826b2b510311efccc85ef20d44 Mon Sep 17 00:00:00 2001 From: Baojun Wang Date: Thu, 18 May 2017 21:00:14 -0700 Subject: [PATCH] remove redundant condition test on ``hashLen /= B.length mHash`` --- Crypto/PubKey/RSA/PSS.hs | 1 - 1 file changed, 1 deletion(-) diff --git a/Crypto/PubKey/RSA/PSS.hs b/Crypto/PubKey/RSA/PSS.hs index 71102d6..8abd228 100644 --- a/Crypto/PubKey/RSA/PSS.hs +++ b/Crypto/PubKey/RSA/PSS.hs @@ -70,7 +70,6 @@ signDigestWithSalt :: HashAlgorithm hash -> Either Error ByteString signDigestWithSalt salt blinder params pk digest | k < hashLen + saltLen + 2 = Left InvalidParameters - | hashLen /= B.length mHash = Left InvalidParameters | otherwise = Right $ dp blinder pk em where k = private_size pk mHash = B.convert digest