X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=blobdiff_plain;f=CryptoPkg%2FInclude%2FProtocol%2FRuntimeCrypt.h;h=bb03a622e9f5064af3676b72b1e815a16d4e4c33;hp=bb97d9102e2c81cf9e115a23a3633e6dd20c050b;hb=16d2c32c4dff7fd8b0ee19e3ba908c0121f6636e;hpb=bd0de3963b8e09ccded4b6922d5e6f0146a2f63f diff --git a/CryptoPkg/Include/Protocol/RuntimeCrypt.h b/CryptoPkg/Include/Protocol/RuntimeCrypt.h index bb97d9102e..bb03a622e9 100644 --- a/CryptoPkg/Include/Protocol/RuntimeCrypt.h +++ b/CryptoPkg/Include/Protocol/RuntimeCrypt.h @@ -3,7 +3,7 @@ Only limited crypto primitives (SHA-256 and RSA) are provided for runtime authenticated variable service. -Copyright (c) 2010, Intel Corporation. All rights reserved.
+Copyright (c) 2010 - 2012, Intel Corporation. All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at @@ -44,7 +44,7 @@ UINTN Initializes user-supplied memory pointed by Sha256Context as SHA-256 hash context for subsequent use. - If Sha256Context is NULL, then ASSERT(). + If Sha256Context is NULL, then return FALSE. @param[in, out] Sha256Context Pointer to SHA-256 Context being initialized. @@ -63,7 +63,7 @@ BOOLEAN Performs SHA-256 digest on a data buffer of the specified length. This function can be called multiple times to compute the digest of long or discontinuous data streams. - If Sha256Context is NULL, then ASSERT(). + If Sha256Context is NULL, then return FALSE. @param[in, out] Sha256Context Pointer to the SHA-256 context. @param[in] Data Pointer to the buffer containing the data to be hashed. @@ -87,8 +87,8 @@ BOOLEAN Completes SHA-256 hash computation and retrieves the digest value into the specified memory. After this function has been called, the SHA-256 context cannot be used again. - If Sha256Context is NULL, then ASSERT(). - If HashValue is NULL, then ASSERT(). + If Sha256Context is NULL, then return FALSE. + If HashValue is NULL, then return FALSE. @param[in, out] Sha256Context Pointer to SHA-256 context @param[out] HashValue Pointer to a buffer that receives the SHA-256 digest @@ -136,7 +136,7 @@ VOID the user-specified nonnegative integer (octet string format represented in RSA PKCS#1). - If RsaContext is NULL, then ASSERT(). + If RsaContext is NULL, then return FALSE. @param[in, out] RsaContext Pointer to RSA context being set. @param[in] KeyTag Tag of RSA key component being set. @@ -160,10 +160,10 @@ BOOLEAN Verifies the RSA-SSA signature with EMSA-PKCS1-v1_5 encoding scheme defined in RSA PKCS#1. - If RsaContext is NULL, then ASSERT(). - If MessageHash is NULL, then ASSERT(). - If Signature is NULL, then ASSERT(). - If HashLength is not equal to the size of MD5, SHA-1 or SHA-256 digest, then ASSERT(). + If RsaContext is NULL, then return FALSE. + If MessageHash is NULL, then return FALSE. + If Signature is NULL, then return FALSE. + If HashLength is not equal to the size of MD5, SHA-1 or SHA-256 digest, then return FALSE. @param[in] RsaContext Pointer to RSA context for signature verification. @param[in] MessageHash Pointer to octet message hash to be checked.