summaryrefslogtreecommitdiff
path: root/Cryptlib/Hmac/CryptHmacSha1.c
diff options
context:
space:
mode:
Diffstat (limited to 'Cryptlib/Hmac/CryptHmacSha1.c')
-rw-r--r--Cryptlib/Hmac/CryptHmacSha1.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Cryptlib/Hmac/CryptHmacSha1.c b/Cryptlib/Hmac/CryptHmacSha1.c
index 58da2f3a..881d26cf 100644
--- a/Cryptlib/Hmac/CryptHmacSha1.c
+++ b/Cryptlib/Hmac/CryptHmacSha1.c
@@ -30,7 +30,7 @@ HmacSha1GetContextSize (
//
// Retrieves the OpenSSL HMAC-SHA1 Context Size
//
- return (UINTN)(sizeof (HMAC_CTX));
+ return (UINTN) (sizeof (HMAC_CTX));
}
/**
@@ -58,7 +58,7 @@ HmacSha1Init (
//
// Check input parameters.
//
- if (HmacSha1Context == NULL) {
+ if (HmacSha1Context == NULL || KeySize > INT_MAX) {
return FALSE;
}