From dee69a236f67b99e87746fee5894c915682623ee Mon Sep 17 00:00:00 2001 From: nagendra modadugu Date: Fri, 12 May 2017 15:01:54 -0700 Subject: [PATCH] CR50: remove duplicate SHA #defines Include the appropriate SHA header files and remove duplicate #defines. BRANCH=none BUG=none TEST=compilation succeeds Change-Id: I15b77c3f40a07af8ea397f41d671386f303287eb Signed-off-by: nagendra modadugu Reviewed-on: https://chromium-review.googlesource.com/505200 Commit-Ready: Nagendra Modadugu Tested-by: Nagendra Modadugu Reviewed-by: Andrey Pronin --- chip/g/dcrypto/rsa.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/chip/g/dcrypto/rsa.c b/chip/g/dcrypto/rsa.c index dc86006fae..4aa1ef281e 100644 --- a/chip/g/dcrypto/rsa.c +++ b/chip/g/dcrypto/rsa.c @@ -13,6 +13,8 @@ #include "cryptoc/sha.h" #include "cryptoc/sha256.h" +#include "cryptoc/sha384.h" +#include "cryptoc/sha512.h" #include "cryptoc/util.h" /* Extend the MSB throughout the word. */ @@ -275,12 +277,6 @@ static const uint8_t SHA512_DER[] = { 0x00, 0x04, 0x40 }; -/* TODO(ngm): move these #defines to third_party/cryptoc once SHA-384 - * & 512 support is available. - */ -#define SHA384_DIGEST_SIZE 48 -#define SHA512_DIGEST_SIZE 64 - static int pkcs1_get_der(enum hashing_mode hashing, const uint8_t **der, uint32_t *der_size, uint32_t *hash_size) {