]> git.proxmox.com Git - mirror_edk2.git/blob - CryptoPkg/Library/BaseCryptLibNull/Pk/CryptRsaPssNull.c
CryptoPkg: add new X509 function definition.
[mirror_edk2.git] / CryptoPkg / Library / BaseCryptLibNull / Pk / CryptRsaPssNull.c
1 /** @file
2 RSA-PSS Asymmetric Cipher Wrapper Implementation over OpenSSL.
3
4 This file does not provide real capabilities for following APIs in RSA handling:
5 1) RsaPssVerify
6
7 Copyright (c) 2021, Intel Corporation. All rights reserved.<BR>
8 SPDX-License-Identifier: BSD-2-Clause-Patent
9
10 **/
11
12 #include "InternalCryptLib.h"
13
14 /**
15 Verifies the RSA signature with RSASSA-PSS signature scheme defined in RFC 8017.
16 Implementation determines salt length automatically from the signature encoding.
17 Mask generation function is the same as the message digest algorithm.
18 Salt length should be equal to digest length.
19
20 @param[in] RsaContext Pointer to RSA context for signature verification.
21 @param[in] Message Pointer to octet message to be verified.
22 @param[in] MsgSize Size of the message in bytes.
23 @param[in] Signature Pointer to RSASSA-PSS signature to be verified.
24 @param[in] SigSize Size of signature in bytes.
25 @param[in] DigestLen Length of digest for RSA operation.
26 @param[in] SaltLen Salt length for PSS encoding.
27
28 @retval TRUE Valid signature encoded in RSASSA-PSS.
29 @retval FALSE Invalid signature or invalid RSA context.
30
31 **/
32 BOOLEAN
33 EFIAPI
34 RsaPssVerify (
35 IN VOID *RsaContext,
36 IN CONST UINT8 *Message,
37 IN UINTN MsgSize,
38 IN CONST UINT8 *Signature,
39 IN UINTN SigSize,
40 IN UINT16 DigestLen,
41 IN UINT16 SaltLen
42 )
43 {
44 ASSERT (FALSE);
45 return FALSE;
46 }