Commit aed3731e authored by Antoine Ténart's avatar Antoine Ténart Committed by Herbert Xu

crypto: inside-secure - use hmac ipad/opad constants

Replace the hmac ipad/opad values by their defined constants.
Signed-off-by: default avatarAntoine Tenart <antoine.tenart@free-electrons.com>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 14c19b17
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
* warranty of any kind, whether express or implied. * warranty of any kind, whether express or implied.
*/ */
#include <crypto/hmac.h>
#include <crypto/sha.h> #include <crypto/sha.h>
#include <linux/device.h> #include <linux/device.h>
#include <linux/dma-mapping.h> #include <linux/dma-mapping.h>
...@@ -774,8 +775,8 @@ static int safexcel_hmac_init_pad(struct ahash_request *areq, ...@@ -774,8 +775,8 @@ static int safexcel_hmac_init_pad(struct ahash_request *areq,
memcpy(opad, ipad, blocksize); memcpy(opad, ipad, blocksize);
for (i = 0; i < blocksize; i++) { for (i = 0; i < blocksize; i++) {
ipad[i] ^= 0x36; ipad[i] ^= HMAC_IPAD_VALUE;
opad[i] ^= 0x5c; opad[i] ^= HMAC_OPAD_VALUE;
} }
return 0; return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment