lib/crypto: support sha384/sha512 in x509/pkcs7
authorDhananjay Phadke <dphadke@linux.microsoft.com>
Tue, 15 Mar 2022 17:19:32 +0000 (10:19 -0700)
committerTom Rini <trini@konsulko.com>
Mon, 11 Apr 2022 15:39:19 +0000 (11:39 -0400)
commite146a2c12ff1e9138f564ae6815a131bd850d8ef
treedb1784dcb98974b8f70e8126c0d02e68571d41be
parent067cfc1c2ea382b0820d995f476e2a26713a3200
lib/crypto: support sha384/sha512 in x509/pkcs7

Set digest_size SHA384 and SHA512 algorithms in pkcs7 and x509,
(not set by ported linux code, but needed by __UBOOT__ part).

EFI_CAPSULE_AUTHENTICATE doesn't select these algos but required for
correctness if certificates contain sha384WithRSAEncryption or
sha512WithRSAEncryption OIDs.

Signed-off-by: Dhananjay Phadke <dphadke@linux.microsoft.com>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
lib/crypto/pkcs7_verify.c
lib/crypto/x509_public_key.c