21#define EDKII_CRYPTO_PCD ((const PCD_CRYPTO_SERVICE_FAMILY_ENABLE *)\
22 (FixedPcdGetPtr (PcdCryptoServiceFamilyEnable)))
41#define CALL_BASECRYPTLIB(Enable, Function, Args, ErrorReturnValue) \
42 EDKII_CRYPTO_PCD->Enable \
44 : (BaseCryptLibServiceNotEnabled (#Function), ErrorReturnValue)
61#define CALL_VOID_BASECRYPTLIB(Enable, Function, Args) \
62 EDKII_CRYPTO_PCD->Enable \
64 : BaseCryptLibServiceNotEnabled (#Function)
81BaseCryptLibServiceNotEnabled (
85 DEBUG ((DEBUG_ERROR,
"[%a] Function %a() is not enabled\n", gEfiCallerBaseName, FunctionName));
99BaseCryptLibServiceDeprecated (
103 DEBUG ((DEBUG_ERROR,
"[%a] Function %a() is deprecated and unsupported any longer\n", gEfiCallerBaseName, FunctionName));
139 return BaseCryptLibServiceDeprecated (
"Md4GetContextSize"), 0;
157 return BaseCryptLibServiceDeprecated (
"Md4Init"),
FALSE;
174 OUT VOID *NewMd4Context
177 return BaseCryptLibServiceDeprecated (
"Md4Duplicate"),
FALSE;
194 IN OUT VOID *Md4Context,
199 return BaseCryptLibServiceDeprecated (
"Md4Update"),
FALSE;
216 IN OUT VOID *Md4Context,
220 return BaseCryptLibServiceDeprecated (
"Md4Final"),
FALSE;
243 return BaseCryptLibServiceDeprecated (
"Md4HashAll"),
FALSE;
246#ifndef ENABLE_MD5_DEPRECATED_INTERFACES
262 return BaseCryptLibServiceDeprecated (
"Md5GetContextSize"), 0;
283 return BaseCryptLibServiceDeprecated (
"Md5Init"),
FALSE;
303 OUT VOID *NewMd5Context
306 return BaseCryptLibServiceDeprecated (
"Md5Init"),
FALSE;
330 IN OUT VOID *Md5Context,
335 return BaseCryptLibServiceDeprecated (
"Md5Init"),
FALSE;
361 IN OUT VOID *Md5Context,
365 return BaseCryptLibServiceDeprecated (
"Md5Final"),
FALSE;
392 return BaseCryptLibServiceDeprecated (
"Md5HashAll"),
FALSE;
408CryptoServiceMd5GetContextSize (
431CryptoServiceMd5Init (
455CryptoServiceMd5Duplicate (
457 OUT VOID *NewMd5Context
485CryptoServiceMd5Update (
486 IN OUT VOID *Md5Context,
518CryptoServiceMd5Final (
519 IN OUT VOID *Md5Context,
546CryptoServiceMd5HashAll (
557#ifdef DISABLE_SHA1_DEPRECATED_INTERFACES
569DeprecatedCryptoServiceSha1GetContextSize (
573 return BaseCryptLibServiceDeprecated (
"Sha1GetContextSize"), 0;
592DeprecatedCryptoServiceSha1Init (
593 OUT VOID *Sha1Context
596 return BaseCryptLibServiceDeprecated (
"Sha1Init"),
FALSE;
614DeprecatedCryptoServiceSha1Duplicate (
616 OUT VOID *NewSha1Context
619 return BaseCryptLibServiceDeprecated (
"Sha1Duplicate"),
FALSE;
642DeprecatedCryptoServiceSha1Update (
643 IN OUT VOID *Sha1Context,
648 return BaseCryptLibServiceDeprecated (
"Sha1Update"),
FALSE;
673DeprecatedCryptoServiceSha1Final (
674 IN OUT VOID *Sha1Context,
678 return BaseCryptLibServiceDeprecated (
"Sha1Final"),
FALSE;
699DeprecatedCryptoServiceSha1HashAll (
705 return BaseCryptLibServiceDeprecated (
"Sha1HashAll"),
FALSE;
745 OUT VOID *Sha1Context
770 OUT VOID *NewSha1Context
799 IN OUT VOID *Sha1Context,
832 IN OUT VOID *Sha1Context,
900 OUT VOID *Sha256Context
925 OUT VOID *NewSha256Context
952 IN OUT VOID *Sha256Context,
983 IN OUT VOID *Sha256Context,
1013 OUT UINT8 *HashValue
1049 OUT VOID *Sha384Context
1074 OUT VOID *NewSha384Context
1101 IN OUT VOID *Sha384Context,
1132 IN OUT VOID *Sha384Context,
1133 OUT UINT8 *HashValue
1162 OUT UINT8 *HashValue
1198 OUT VOID *Sha512Context
1223 OUT VOID *NewSha512Context
1250 IN OUT VOID *Sha512Context,
1281 IN OUT VOID *Sha512Context,
1282 OUT UINT8 *HashValue
1311 OUT UINT8 *HashValue
1347 OUT VOID *Sm3Context
1372 OUT VOID *NewSm3Context
1399 IN OUT VOID *Sm3Context,
1430 IN OUT VOID *Sm3Context,
1431 OUT UINT8 *HashValue
1460 OUT UINT8 *HashValue
1483 return BaseCryptLibServiceDeprecated (
"HmacMd5New"),
NULL;
1499 BaseCryptLibServiceDeprecated (
"HmacMd5Free");
1516 OUT VOID *HmacMd5Context,
1521 return BaseCryptLibServiceDeprecated (
"HmacMd5SetKey"),
FALSE;
1537 IN CONST VOID *HmacMd5Context,
1538 OUT VOID *NewHmacMd5Context
1541 return BaseCryptLibServiceDeprecated (
"HmacMd5Duplicate"),
FALSE;
1558 IN OUT VOID *HmacMd5Context,
1563 return BaseCryptLibServiceDeprecated (
"HmacMd5Update"),
FALSE;
1580 IN OUT VOID *HmacMd5Context,
1581 OUT UINT8 *HmacValue
1584 return BaseCryptLibServiceDeprecated (
"HmacMd5Final"),
FALSE;
1600 return BaseCryptLibServiceDeprecated (
"HmacSha1New"),
NULL;
1613 IN VOID *HmacSha1Ctx
1616 BaseCryptLibServiceDeprecated (
"HmacSha1Free");
1633 OUT VOID *HmacSha1Context,
1638 return BaseCryptLibServiceDeprecated (
"HmacSha1SetKey"),
FALSE;
1654 IN CONST VOID *HmacSha1Context,
1655 OUT VOID *NewHmacSha1Context
1658 return BaseCryptLibServiceDeprecated (
"HmacSha1Duplicate"),
FALSE;
1675 IN OUT VOID *HmacSha1Context,
1680 return BaseCryptLibServiceDeprecated (
"HmacSha1Update"),
FALSE;
1697 IN OUT VOID *HmacSha1Context,
1698 OUT UINT8 *HmacValue
1701 return BaseCryptLibServiceDeprecated (
"HmacSha1Final"),
FALSE;
1729 IN VOID *HmacSha256Ctx
1754 OUT VOID *HmacSha256Context,
1780 IN CONST VOID *HmacSha256Context,
1781 OUT VOID *NewHmacSha256Context
1810 IN OUT VOID *HmacSha256Context,
1843 IN OUT VOID *HmacSha256Context,
1844 OUT UINT8 *HmacValue
1877 OUT UINT8 *HmacValue
1908 IN VOID *HmacSha384Ctx
1933 OUT VOID *HmacSha384Context,
1959 IN CONST VOID *HmacSha384Context,
1960 OUT VOID *NewHmacSha384Context
1989 IN OUT VOID *HmacSha384Context,
2022 IN OUT VOID *HmacSha384Context,
2023 OUT UINT8 *HmacValue
2056 OUT UINT8 *HmacValue
2079 return BaseCryptLibServiceDeprecated (
"TdesGetContextSize"), 0;
2096 OUT VOID *TdesContext,
2101 return BaseCryptLibServiceDeprecated (
"TdesInit"),
FALSE;
2119 IN VOID *TdesContext,
2125 return BaseCryptLibServiceDeprecated (
"TdesEcbEncrypt"),
FALSE;
2143 IN VOID *TdesContext,
2149 return BaseCryptLibServiceDeprecated (
"TdesEcbDecrypt"),
FALSE;
2168 IN VOID *TdesContext,
2175 return BaseCryptLibServiceDeprecated (
"TdesCbcEncrypt"),
FALSE;
2194 IN VOID *TdesContext,
2201 return BaseCryptLibServiceDeprecated (
"TdesCbcDecrypt"),
FALSE;
2247 OUT VOID *AesContext,
2270 IN VOID *AesContext,
2276 return BaseCryptLibServiceDeprecated (
"AesEcbEncrypt"),
FALSE;
2294 IN VOID *AesContext,
2300 return BaseCryptLibServiceDeprecated (
"AesEcbDecrypt"),
FALSE;
2335 IN VOID *AesContext,
2377 IN VOID *AesContext,
2400 return BaseCryptLibServiceDeprecated (
"Arc4GetContextSize"), 0;
2417 OUT VOID *Arc4Context,
2422 return BaseCryptLibServiceDeprecated (
"Arc4Init"),
FALSE;
2440 IN OUT VOID *Arc4Context,
2446 return BaseCryptLibServiceDeprecated (
"Arc4Encrypt"),
FALSE;
2464 IN OUT VOID *Arc4Context,
2470 return BaseCryptLibServiceDeprecated (
"Arc4Decrypt"),
FALSE;
2485 IN OUT VOID *Arc4Context
2488 return BaseCryptLibServiceDeprecated (
"Arc4Reset"),
FALSE;
2553 IN OUT VOID *RsaContext,
2593 IN OUT VOID *RsaContext,
2595 OUT UINT8 *BigNumber,
2628 IN OUT VOID *RsaContext,
2630 IN CONST UINT8 *PublicExponent,
2697 IN VOID *RsaContext,
2700 OUT UINT8 *Signature,
2729 IN VOID *RsaContext,
2764 OUT VOID **RsaContext
2793 OUT VOID **RsaContext
2823 OUT UINT8 *CertSubject,
2861 OUT CHAR8 *CommonName OPTIONAL,
2899 OUT CHAR8 *NameBuffer OPTIONAL,
2957 OUT UINT8 **SingleX509Cert
2985 IN OUT UINT8 **X509Stack,
3013 IN OUT UINT8 **X509Stack,
3082 OUT UINT8 **TBSCert,
3144 OUT UINT8 *SerialNumber, OPTIONAL
3175 OUT UINT8 *CertIssuer,
3205 OUT UINT8 *Oid, OPTIONAL
3239 OUT UINT8 *ExtensionData,
3497 UINT8 *BasicConstraints,
3498 UINTN *BasicConstraintsSize
3544 return CALL_BASECRYPTLIB (Pkcs.Services.Pkcs5HashPassword,
Pkcs5HashPassword, (PasswordLength, Password, SaltLength, Salt, IterationCount, DigestSize, KeyLength, OutKey),
FALSE);
3583 IN CONST UINT8 *PrngSeed OPTIONAL,
3584 IN UINTN PrngSeedSize OPTIONAL,
3585 OUT UINT8 **EncryptedData,
3589 return CALL_BASECRYPTLIB (Pkcs.Services.Pkcs1v2Encrypt,
Pkcs1v2Encrypt, (PublicKey, PublicKeySize, InData, InDataSize, PrngSeed, PrngSeedSize, EncryptedData, EncryptedDataSize),
FALSE);
3628 IN VOID *RsaContext,
3631 IN CONST UINT8 *PrngSeed OPTIONAL,
3632 IN UINTN PrngSeedSize OPTIONAL,
3633 IN UINT16 DigestLen OPTIONAL,
3634 OUT UINT8 **EncryptedData,
3638 return CALL_BASECRYPTLIB (Rsa.Services.RsaOaepEncrypt,
RsaOaepEncrypt, (RsaContext, InData, InDataSize, PrngSeed, PrngSeedSize, DigestLen, EncryptedData, EncryptedDataSize),
FALSE);
3667 IN UINT8 *EncryptedData,
3669 OUT UINT8 **OutData,
3706 IN VOID *RsaContext,
3707 IN UINT8 *EncryptedData,
3709 IN UINT16 DigestLen OPTIONAL,
3710 OUT UINT8 **OutData,
3748 OUT UINT8 **CertStack,
3750 OUT UINT8 **TrustedCert,
3801 OUT UINT8 **SignerChainCerts,
3803 OUT UINT8 **UnchainCerts,
3846 IN UINT8 *OtherCerts OPTIONAL,
3847 OUT UINT8 **SignedData,
3851 return CALL_BASECRYPTLIB (Pkcs.Services.Pkcs7Sign,
Pkcs7Sign, (PrivateKey, PrivateKeySize, KeyPassword, InData, InDataSize, SignCert, OtherCerts, SignedData, SignedDataSize),
FALSE);
3925 IN CONST UINT8 *Pkcs7Signature,
3926 IN CONST UINT32 SignatureSize,
3927 IN CONST CHAR8 *RequiredEKUs[],
3928 IN CONST UINT32 RequiredEKUsSize,
3929 IN BOOLEAN RequireAllPresent
4103 IN OUT VOID *DhContext,
4138 IN OUT VOID *DhContext,
4174 IN OUT VOID *DhContext,
4175 OUT UINT8 *PublicKey,
4211 IN OUT VOID *DhContext,
4212 IN CONST UINT8 *PeerPublicKey,
4246 IN CONST UINT8 *Seed OPTIONAL,
4310 return CALL_BASECRYPTLIB (Hkdf.Services.Sha256ExtractAndExpand,
HkdfSha256ExtractAndExpand, (Key, KeySize, Salt, SaltSize, Info, InfoSize, Out, OutSize),
FALSE);
4398 return CALL_BASECRYPTLIB (Hkdf.Services.Sha384ExtractAndExpand,
HkdfSha384ExtractAndExpand, (Key, KeySize, Salt, SaltSize, Info, InfoSize, Out, OutSize),
FALSE);
4603 IN UINT8 *BufferIn OPTIONAL,
4604 IN UINTN BufferInSize OPTIONAL,
4605 OUT UINT8 *BufferOut OPTIONAL,
4641 IN UINT8 *BufferIn OPTIONAL,
4642 IN UINTN BufferInSize OPTIONAL,
4643 OUT UINT8 *BufferOut OPTIONAL,
4672 IN OUT UINT8 *Buffer,
4697 IN OUT VOID *Buffer,
4748 IN OUT VOID *Buffer,
4873 IN UINT16 *CipherId,
4914 IN UINT32 VerifyMode
4962 IN UINT8 *SessionId,
4963 IN UINT16 SessionIdLen
5049 IN VOID *Password OPTIONAL
5221 IN OUT UINT16 *CipherId
5247 IN OUT UINT8 *CompressionId
5294 IN OUT UINT8 *SessionId,
5295 IN OUT UINT16 *SessionIdLen
5316 IN OUT UINT8 *ClientRandom
5337 IN OUT UINT8 *ServerRandom
5361 IN OUT UINT8 *KeyMaterial
5499 OUT VOID *KeyBuffer,
5504 TlsGet.Services.ExportKey,
5506 (Tls, Label, Context, ContextLen,
5507 KeyBuffer, KeyBufferLen),
5547 IN VOID *RsaContext,
5550 IN UINT16 DigestLen,
5552 OUT UINT8 *Signature,
5580 IN VOID *RsaContext,
5585 IN UINT16 DigestLen,
5665 return CALL_BASECRYPTLIB (AeadAesGcm.Services.Encrypt,
AeadAesGcmEncrypt, (Key, KeySize, Iv, IvSize, AData, ADataSize, DataIn, DataInSize, TagOut, TagSize, DataOut, DataOutSize),
FALSE);
5710 return CALL_BASECRYPTLIB (AeadAesGcm.Services.Decrypt,
AeadAesGcmDecrypt, (Key, KeySize, Iv, IvSize, AData, ADataSize, DataIn, DataInSize, Tag, TagSize, DataOut, DataOutSize),
FALSE);
6395 OUT VOID *EcPointResult,
6421 OUT VOID *EcPointResult,
6444 IN OUT VOID *EcPoint,
6608 IN OUT VOID *EcContext,
6609 OUT UINT8 *PublicKey,
6633 IN OUT VOID *EcContext,
6634 OUT UINT8 *PublicKey,
6669 IN OUT VOID *EcContext,
6701 OUT VOID **EcContext
6730 OUT VOID **EcContext
6772 OUT UINT8 *Signature,
6847 #ifndef ENABLE_MD5_DEPRECATED_INTERFACES
6857 CryptoServiceMd5GetContextSize,
6858 CryptoServiceMd5Init,
6859 CryptoServiceMd5Duplicate,
6860 CryptoServiceMd5Update,
6861 CryptoServiceMd5Final,
6862 CryptoServiceMd5HashAll,
6898 #ifdef DISABLE_SHA1_DEPRECATED_INTERFACES
6900 DeprecatedCryptoServiceSha1GetContextSize,
6901 DeprecatedCryptoServiceSha1Init,
6902 DeprecatedCryptoServiceSha1Duplicate,
6903 DeprecatedCryptoServiceSha1Update,
6904 DeprecatedCryptoServiceSha1Final,
6905 DeprecatedCryptoServiceSha1HashAll,
BOOLEAN EFIAPI RsaPssSign(IN VOID *RsaContext, IN CONST UINT8 *Message, IN UINTN MsgSize, IN UINT16 DigestLen, IN UINT16 SaltLen, OUT UINT8 *Signature, IN OUT UINTN *SigSize)
BOOLEAN EFIAPI X509GetSerialNumber(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 *SerialNumber, OPTIONAL IN OUT UINTN *SerialNumberSize)
BOOLEAN EFIAPI HmacSha384Update(IN OUT VOID *HmacSha384Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI EcPointInvert(IN CONST VOID *EcGroup, IN OUT VOID *EcPoint, IN VOID *BnCtx)
BOOLEAN EFIAPI RsaCheckKey(IN VOID *RsaContext)
BOOLEAN EFIAPI EcPointSetCompressedCoordinates(IN CONST VOID *EcGroup, IN VOID *EcPoint, IN CONST VOID *BnX, IN UINT8 YBit, IN VOID *BnCtx)
BOOLEAN EFIAPI BigNumExpMod(IN CONST VOID *BnA, IN CONST VOID *BnP, IN CONST VOID *BnM, OUT VOID *BnRes)
INT32 EFIAPI X509CompareDateTime(IN CONST VOID *DateTime1, IN CONST VOID *DateTime2)
BOOLEAN EFIAPI AesInit(OUT VOID *AesContext, IN CONST UINT8 *Key, IN UINTN KeyLength)
BOOLEAN EFIAPI EcPointMul(IN CONST VOID *EcGroup, OUT VOID *EcPointResult, IN CONST VOID *EcPoint, IN CONST VOID *BnPScalar, IN VOID *BnCtx)
UINTN EFIAPI Sha256GetContextSize(VOID)
BOOLEAN EFIAPI HmacSha384SetKey(OUT VOID *HmacSha384Context, IN CONST UINT8 *Key, IN UINTN KeySize)
BOOLEAN EFIAPI HkdfSha256Extract(IN CONST UINT8 *Key, IN UINTN KeySize, IN CONST UINT8 *Salt, IN UINTN SaltSize, OUT UINT8 *PrkOut, UINTN PrkOutSize)
BOOLEAN EFIAPI EcPointAdd(IN CONST VOID *EcGroup, OUT VOID *EcPointResult, IN CONST VOID *EcPointA, IN CONST VOID *EcPointB, IN VOID *BnCtx)
BOOLEAN EFIAPI EcGenerateKey(IN OUT VOID *EcContext, OUT UINT8 *PublicKey, IN OUT UINTN *PublicKeySize)
BOOLEAN EFIAPI EcPointIsOnCurve(IN CONST VOID *EcGroup, IN CONST VOID *EcPoint, IN VOID *BnCtx)
BOOLEAN EFIAPI DhGenerateParameter(IN OUT VOID *DhContext, IN UINTN Generator, IN UINTN PrimeLength, OUT UINT8 *Prime)
BOOLEAN EFIAPI Pkcs5HashPassword(IN UINTN PasswordLength, IN CONST CHAR8 *Password, IN UINTN SaltLength, IN CONST UINT8 *Salt, IN UINTN IterationCount, IN UINTN DigestSize, IN UINTN KeyLength, OUT UINT8 *OutKey)
VOID *EFIAPI HmacSha256New(VOID)
BOOLEAN EFIAPI BigNumMulMod(IN CONST VOID *BnA, IN CONST VOID *BnB, IN CONST VOID *BnM, OUT VOID *BnRes)
UINTN EFIAPI Sha384GetContextSize(VOID)
BOOLEAN EFIAPI Sha512HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
BOOLEAN EFIAPI Sm3Duplicate(IN CONST VOID *Sm3Context, OUT VOID *NewSm3Context)
BOOLEAN EFIAPI HmacSha256Duplicate(IN CONST VOID *HmacSha256Context, OUT VOID *NewHmacSha256Context)
BOOLEAN EFIAPI Sha512Final(IN OUT VOID *Sha512Context, OUT UINT8 *HashValue)
BOOLEAN EFIAPI BigNumInverseMod(IN CONST VOID *BnA, IN CONST VOID *BnM, OUT VOID *BnRes)
VOID *EFIAPI HmacSha384New(VOID)
VOID *EFIAPI BigNumFromBin(IN CONST UINT8 *Buf, IN UINTN Len)
BOOLEAN EFIAPI X509GetVersion(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINTN *Version)
BOOLEAN EFIAPI X509GetExtensionData(IN CONST UINT8 *Cert, IN UINTN CertSize, IN CONST UINT8 *Oid, IN UINTN OidSize, OUT UINT8 *ExtensionData, IN OUT UINTN *ExtensionDataSize)
BOOLEAN EFIAPI BigNumDiv(IN CONST VOID *BnA, IN CONST VOID *BnB, OUT VOID *BnRes)
BOOLEAN EFIAPI EcPointIsAtInfinity(IN CONST VOID *EcGroup, IN CONST VOID *EcPoint)
BOOLEAN EFIAPI EcGetPubKey(IN OUT VOID *EcContext, OUT UINT8 *PublicKey, IN OUT UINTN *PublicKeySize)
BOOLEAN EFIAPI Pkcs7Sign(IN CONST UINT8 *PrivateKey, IN UINTN PrivateKeySize, IN CONST UINT8 *KeyPassword, IN UINT8 *InData, IN UINTN InDataSize, IN UINT8 *SignCert, IN UINT8 *OtherCerts OPTIONAL, OUT UINT8 **SignedData, OUT UINTN *SignedDataSize)
BOOLEAN EFIAPI Sha384Duplicate(IN CONST VOID *Sha384Context, OUT VOID *NewSha384Context)
BOOLEAN EFIAPI HmacSha384All(IN CONST VOID *Data, IN UINTN DataSize, IN CONST UINT8 *Key, IN UINTN KeySize, OUT UINT8 *HmacValue)
UINTN EFIAPI Sm3GetContextSize(VOID)
BOOLEAN EFIAPI X509GetIssuerName(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 *CertIssuer, IN OUT UINTN *CertIssuerSize)
VOID *EFIAPI RsaNew(VOID)
BOOLEAN EFIAPI AeadAesGcmDecrypt(IN CONST UINT8 *Key, IN UINTN KeySize, IN CONST UINT8 *Iv, IN UINTN IvSize, IN CONST UINT8 *AData, IN UINTN ADataSize, IN CONST UINT8 *DataIn, IN UINTN DataInSize, IN CONST UINT8 *Tag, IN UINTN TagSize, OUT UINT8 *DataOut, OUT UINTN *DataOutSize)
BOOLEAN EFIAPI RsaGetPrivateKeyFromPem(IN CONST UINT8 *PemData, IN UINTN PemSize, IN CONST CHAR8 *Password, OUT VOID **RsaContext)
BOOLEAN EFIAPI BigNumSqrMod(IN CONST VOID *BnA, IN CONST VOID *BnM, OUT VOID *BnRes)
UINTN EFIAPI BigNumBits(IN CONST VOID *Bn)
UINTN EFIAPI Sha512GetContextSize(VOID)
BOOLEAN EFIAPI Sha1Final(IN OUT VOID *Sha1Context, OUT UINT8 *HashValue)
BOOLEAN EFIAPI Sm3Update(IN OUT VOID *Sm3Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI EcDsaSign(IN VOID *EcContext, IN UINTN HashNid, IN CONST UINT8 *MessageHash, IN UINTN HashSize, OUT UINT8 *Signature, IN OUT UINTN *SigSize)
VOID EFIAPI HmacSha384Free(IN VOID *HmacSha384Ctx)
BOOLEAN EFIAPI DhGenerateKey(IN OUT VOID *DhContext, OUT UINT8 *PublicKey, IN OUT UINTN *PublicKeySize)
BOOLEAN EFIAPI X509FormatDateTime(IN CONST CHAR8 *DateTimeStr, OUT VOID *DateTime, IN OUT UINTN *DateTimeSize)
BOOLEAN EFIAPI X509VerifyCert(IN CONST UINT8 *Cert, IN UINTN CertSize, IN CONST UINT8 *CACert, IN UINTN CACertSize)
VOID EFIAPI HmacSha256Free(IN VOID *HmacSha256Ctx)
VOID EFIAPI DhFree(IN VOID *DhContext)
BOOLEAN EFIAPI Sha512Init(OUT VOID *Sha512Context)
BOOLEAN EFIAPI DhSetParameter(IN OUT VOID *DhContext, IN UINTN Generator, IN UINTN PrimeLength, IN CONST UINT8 *Prime)
BOOLEAN EFIAPI Sm3Final(IN OUT VOID *Sm3Context, OUT UINT8 *HashValue)
BOOLEAN EFIAPI RandomBytes(OUT UINT8 *Output, IN UINTN Size)
UINTN EFIAPI AesGetContextSize(VOID)
BOOLEAN EFIAPI Sha256Init(OUT VOID *Sha256Context)
VOID *EFIAPI BigNumNewContext(VOID)
BOOLEAN EFIAPI X509GetSignatureAlgorithm(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 *Oid, OPTIONAL IN OUT UINTN *OidSize)
BOOLEAN EFIAPI RsaGetPublicKeyFromX509(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT VOID **RsaContext)
RETURN_STATUS EFIAPI X509GetOrganizationName(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT CHAR8 *NameBuffer OPTIONAL, IN OUT UINTN *NameBufferSize)
VOID EFIAPI X509StackFree(IN VOID *X509Stack)
VOID EFIAPI BigNumFree(IN VOID *Bn, IN BOOLEAN Clear)
BOOLEAN EFIAPI Pkcs7GetSigners(IN CONST UINT8 *P7Data, IN UINTN P7Length, OUT UINT8 **CertStack, OUT UINTN *StackLength, OUT UINT8 **TrustedCert, OUT UINTN *CertLength)
BOOLEAN EFIAPI Sha1Duplicate(IN CONST VOID *Sha1Context, OUT VOID *NewSha1Context)
BOOLEAN EFIAPI ParallelHash256HashAll(IN CONST VOID *Input, IN UINTN InputByteLen, IN UINTN BlockSize, OUT VOID *Output, IN UINTN OutputByteLen, IN CONST VOID *Customization, IN UINTN CustomByteLen)
BOOLEAN EFIAPI AuthenticodeVerify(IN CONST UINT8 *AuthData, IN UINTN DataSize, IN CONST UINT8 *TrustedCert, IN UINTN CertSize, IN CONST UINT8 *ImageHash, IN UINTN HashSize)
BOOLEAN EFIAPI X509GetExtendedKeyUsage(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 *Usage, IN OUT UINTN *UsageSize)
BOOLEAN EFIAPI Sha384HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
VOID *EFIAPI EcNewByNid(IN UINTN Nid)
BOOLEAN EFIAPI Sha256Final(IN OUT VOID *Sha256Context, OUT UINT8 *HashValue)
BOOLEAN EFIAPI HkdfSha384ExtractAndExpand(IN CONST UINT8 *Key, IN UINTN KeySize, IN CONST UINT8 *Salt, IN UINTN SaltSize, IN CONST UINT8 *Info, IN UINTN InfoSize, OUT UINT8 *Out, IN UINTN OutSize)
BOOLEAN EFIAPI Pkcs1v2Encrypt(IN CONST UINT8 *PublicKey, IN UINTN PublicKeySize, IN UINT8 *InData, IN UINTN InDataSize, IN CONST UINT8 *PrngSeed OPTIONAL, IN UINTN PrngSeedSize OPTIONAL, OUT UINT8 **EncryptedData, OUT UINTN *EncryptedDataSize)
BOOLEAN EFIAPI X509GetValidity(IN CONST UINT8 *Cert, IN UINTN CertSize, IN UINT8 *From, IN OUT UINTN *FromSize, IN UINT8 *To, IN OUT UINTN *ToSize)
BOOLEAN EFIAPI HmacSha384Final(IN OUT VOID *HmacSha384Context, OUT UINT8 *HmacValue)
BOOLEAN EFIAPI Sm3HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
BOOLEAN EFIAPI BigNumIsWord(IN CONST VOID *Bn, IN UINTN Num)
INTN EFIAPI BigNumCmp(IN CONST VOID *BnA, IN CONST VOID *BnB)
VOID *EFIAPI EcPointInit(IN CONST VOID *EcGroup)
VOID *EFIAPI EcGroupInit(IN UINTN CryptoNid)
BOOLEAN EFIAPI Sha384Update(IN OUT VOID *Sha384Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI BigNumAdd(IN CONST VOID *BnA, IN CONST VOID *BnB, OUT VOID *BnRes)
BOOLEAN EFIAPI Sha256Duplicate(IN CONST VOID *Sha256Context, OUT VOID *NewSha256Context)
BOOLEAN EFIAPI HmacSha256SetKey(OUT VOID *HmacSha256Context, IN CONST UINT8 *Key, IN UINTN KeySize)
BOOLEAN EFIAPI EcGetPrivateKeyFromPem(IN CONST UINT8 *PemData, IN UINTN PemSize, IN CONST CHAR8 *Password, OUT VOID **EcContext)
BOOLEAN EFIAPI Sm3Init(OUT VOID *Sm3Context)
BOOLEAN EFIAPI HmacSha256Update(IN OUT VOID *HmacSha256Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI DhComputeKey(IN OUT VOID *DhContext, IN CONST UINT8 *PeerPublicKey, IN UINTN PeerPublicKeySize, OUT UINT8 *Key, IN OUT UINTN *KeySize)
BOOLEAN EFIAPI Sha1Init(OUT VOID *Sha1Context)
BOOLEAN EFIAPI HkdfSha384Extract(IN CONST UINT8 *Key, IN UINTN KeySize, IN CONST UINT8 *Salt, IN UINTN SaltSize, OUT UINT8 *PrkOut, UINTN PrkOutSize)
BOOLEAN EFIAPI Sha256HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
VOID EFIAPI BigNumConstTime(IN VOID *Bn)
CONST VOID *EFIAPI BigNumValueOne(VOID)
BOOLEAN EFIAPI Sha512Duplicate(IN CONST VOID *Sha512Context, OUT VOID *NewSha512Context)
BOOLEAN EFIAPI Asn1GetTag(IN OUT UINT8 **Ptr, IN CONST UINT8 *End, OUT UINTN *Length, IN UINT32 Tag)
BOOLEAN EFIAPI RsaGetKey(IN OUT VOID *RsaContext, IN RSA_KEY_TAG KeyTag, OUT UINT8 *BigNumber, IN OUT UINTN *BnSize)
BOOLEAN EFIAPI BigNumSetUint(IN VOID *Bn, IN UINTN Val)
VOID EFIAPI BigNumContextFree(IN VOID *BnCtx)
BOOLEAN EFIAPI EcPointEqual(IN CONST VOID *EcGroup, IN CONST VOID *EcPointA, IN CONST VOID *EcPointB, IN VOID *BnCtx)
BOOLEAN EFIAPI BigNumIsOdd(IN CONST VOID *Bn)
BOOLEAN EFIAPI BigNumSub(IN CONST VOID *BnA, IN CONST VOID *BnB, OUT VOID *BnRes)
BOOLEAN EFIAPI RandomSeed(IN CONST UINT8 *Seed OPTIONAL, IN UINTN SeedSize)
BOOLEAN EFIAPI RsaOaepEncrypt(IN VOID *RsaContext, IN UINT8 *InData, IN UINTN InDataSize, IN CONST UINT8 *PrngSeed OPTIONAL, IN UINTN PrngSeedSize OPTIONAL, IN UINT16 DigestLen OPTIONAL, OUT UINT8 **EncryptedData, OUT UINTN *EncryptedDataSize)
BOOLEAN EFIAPI RsaOaepDecrypt(IN VOID *RsaContext, IN UINT8 *EncryptedData, IN UINTN EncryptedDataSize, IN UINT16 DigestLen OPTIONAL, OUT UINT8 **OutData, OUT UINTN *OutDataSize)
BOOLEAN EFIAPI RsaSetKey(IN OUT VOID *RsaContext, IN RSA_KEY_TAG KeyTag, IN CONST UINT8 *BigNumber, IN UINTN BnSize)
BOOLEAN EFIAPI Pkcs7Verify(IN CONST UINT8 *P7Data, IN UINTN P7Length, IN CONST UINT8 *TrustedCert, IN UINTN CertLength, IN CONST UINT8 *InData, IN UINTN DataLength)
RETURN_STATUS EFIAPI VerifyEKUsInPkcs7Signature(IN CONST UINT8 *Pkcs7Signature, IN CONST UINT32 SignatureSize, IN CONST CHAR8 *RequiredEKUs[], IN CONST UINT32 RequiredEKUsSize, IN BOOLEAN RequireAllPresent)
BOOLEAN EFIAPI Sha256Update(IN OUT VOID *Sha256Context, IN CONST VOID *Data, IN UINTN DataSize)
VOID *EFIAPI BigNumCopy(OUT VOID *BnDst, IN CONST VOID *BnSrc)
BOOLEAN EFIAPI EcGroupGetCurve(IN CONST VOID *EcGroup, OUT VOID *BnPrime, OUT VOID *BnA, OUT VOID *BnB, IN VOID *BnCtx)
BOOLEAN EFIAPI HmacSha256All(IN CONST VOID *Data, IN UINTN DataSize, IN CONST UINT8 *Key, IN UINTN KeySize, OUT UINT8 *HmacValue)
BOOLEAN EFIAPI BigNumAddMod(IN CONST VOID *BnA, IN CONST VOID *BnB, IN CONST VOID *BnM, OUT VOID *BnRes)
BOOLEAN EFIAPI EcGetPublicKeyFromX509(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT VOID **EcContext)
BOOLEAN EFIAPI HkdfSha256Expand(IN CONST UINT8 *Prk, IN UINTN PrkSize, IN CONST UINT8 *Info, IN UINTN InfoSize, OUT UINT8 *Out, IN UINTN OutSize)
VOID EFIAPI RsaFree(IN VOID *RsaContext)
BOOLEAN EFIAPI HkdfSha256ExtractAndExpand(IN CONST UINT8 *Key, IN UINTN KeySize, IN CONST UINT8 *Salt, IN UINTN SaltSize, IN CONST UINT8 *Info, IN UINTN InfoSize, OUT UINT8 *Out, IN UINTN OutSize)
VOID EFIAPI Pkcs7FreeSigners(IN UINT8 *Certs)
BOOLEAN EFIAPI BigNumMod(IN CONST VOID *BnA, IN CONST VOID *BnB, OUT VOID *BnRes)
BOOLEAN EFIAPI Pkcs7GetAttachedContent(IN CONST UINT8 *P7Data, IN UINTN P7Length, OUT VOID **Content, OUT UINTN *ContentSize)
VOID EFIAPI EcPointDeInit(IN VOID *EcPoint, IN BOOLEAN Clear)
BOOLEAN EFIAPI EcDsaVerify(IN VOID *EcContext, IN UINTN HashNid, IN CONST UINT8 *MessageHash, IN UINTN HashSize, IN CONST UINT8 *Signature, IN UINTN SigSize)
BOOLEAN EFIAPI Sha1HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
BOOLEAN EFIAPI ImageTimestampVerify(IN CONST UINT8 *AuthData, IN UINTN DataSize, IN CONST UINT8 *TsaCert, IN UINTN CertSize, OUT EFI_TIME *SigningTime)
VOID EFIAPI X509Free(IN VOID *X509Cert)
VOID *EFIAPI BigNumInit(VOID)
UINTN EFIAPI Sha1GetContextSize(VOID)
BOOLEAN EFIAPI BigNumRShift(IN CONST VOID *Bn, IN UINTN N, OUT VOID *BnRes)
BOOLEAN EFIAPI Sha384Final(IN OUT VOID *Sha384Context, OUT UINT8 *HashValue)
BOOLEAN EFIAPI X509ConstructCertificateStackV(IN OUT UINT8 **X509Stack, IN VA_LIST Args)
BOOLEAN EFIAPI Pkcs1v2Decrypt(IN CONST UINT8 *PrivateKey, IN UINTN PrivateKeySize, IN UINT8 *EncryptedData, IN UINTN EncryptedDataSize, OUT UINT8 **OutData, OUT UINTN *OutDataSize)
BOOLEAN EFIAPI X509GetCertFromCertChain(IN CONST UINT8 *CertChain, IN UINTN CertChainLength, IN CONST INT32 CertIndex, OUT CONST UINT8 **Cert, OUT UINTN *CertLength)
BOOLEAN EFIAPI EcGroupGetOrder(IN VOID *EcGroup, OUT VOID *BnOrder)
UINTN EFIAPI BigNumBytes(IN CONST VOID *Bn)
BOOLEAN EFIAPI X509GetSubjectName(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 *CertSubject, IN OUT UINTN *SubjectSize)
BOOLEAN EFIAPI AeadAesGcmEncrypt(IN CONST UINT8 *Key, IN UINTN KeySize, IN CONST UINT8 *Iv, IN UINTN IvSize, IN CONST UINT8 *AData, IN UINTN ADataSize, IN CONST UINT8 *DataIn, IN UINTN DataInSize, OUT UINT8 *TagOut, IN UINTN TagSize, OUT UINT8 *DataOut, OUT UINTN *DataOutSize)
BOOLEAN EFIAPI RsaPssVerify(IN VOID *RsaContext, IN CONST UINT8 *Message, IN UINTN MsgSize, IN CONST UINT8 *Signature, IN UINTN SigSize, IN UINT16 DigestLen, IN UINT16 SaltLen)
BOOLEAN EFIAPI EcDhComputeKey(IN OUT VOID *EcContext, IN CONST UINT8 *PeerPublic, IN UINTN PeerPublicSize, IN CONST INT32 *CompressFlag, OUT UINT8 *Key, IN OUT UINTN *KeySize)
BOOLEAN EFIAPI Sha384Init(OUT VOID *Sha384Context)
BOOLEAN EFIAPI X509GetKeyUsage(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINTN *Usage)
BOOLEAN EFIAPI Pkcs7GetCertificatesList(IN CONST UINT8 *P7Data, IN UINTN P7Length, OUT UINT8 **SignerChainCerts, OUT UINTN *ChainLength, OUT UINT8 **UnchainCerts, OUT UINTN *UnchainLength)
VOID EFIAPI EcGroupFree(IN VOID *EcGroup)
BOOLEAN EFIAPI AesCbcEncrypt(IN VOID *AesContext, IN CONST UINT8 *Input, IN UINTN InputSize, IN CONST UINT8 *Ivec, OUT UINT8 *Output)
BOOLEAN EFIAPI RsaPkcs1Verify(IN VOID *RsaContext, IN CONST UINT8 *MessageHash, IN UINTN HashSize, IN CONST UINT8 *Signature, IN UINTN SigSize)
BOOLEAN EFIAPI X509GetTBSCert(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 **TBSCert, OUT UINTN *TBSCertSize)
BOOLEAN EFIAPI X509GetExtendedBasicConstraints(CONST UINT8 *Cert, UINTN CertSize, UINT8 *BasicConstraints, UINTN *BasicConstraintsSize)
BOOLEAN EFIAPI Sha512Update(IN OUT VOID *Sha512Context, IN CONST VOID *Data, IN UINTN DataSize)
RETURN_STATUS EFIAPI X509GetCommonName(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT CHAR8 *CommonName OPTIONAL, IN OUT UINTN *CommonNameSize)
BOOLEAN EFIAPI HmacSha256Final(IN OUT VOID *HmacSha256Context, OUT UINT8 *HmacValue)
BOOLEAN EFIAPI HkdfSha384Expand(IN CONST UINT8 *Prk, IN UINTN PrkSize, IN CONST UINT8 *Info, IN UINTN InfoSize, OUT UINT8 *Out, IN UINTN OutSize)
BOOLEAN EFIAPI EcPointGetAffineCoordinates(IN CONST VOID *EcGroup, IN CONST VOID *EcPoint, OUT VOID *BnX, OUT VOID *BnY, IN VOID *BnCtx)
BOOLEAN EFIAPI Sha1Update(IN OUT VOID *Sha1Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI EcPointSetAffineCoordinates(IN CONST VOID *EcGroup, IN VOID *EcPoint, IN CONST VOID *BnX, IN CONST VOID *BnY, IN VOID *BnCtx)
INTN EFIAPI BigNumToBin(IN CONST VOID *Bn, OUT UINT8 *Buf)
BOOLEAN EFIAPI RsaGenerateKey(IN OUT VOID *RsaContext, IN UINTN ModulusLength, IN CONST UINT8 *PublicExponent, IN UINTN PublicExponentSize)
BOOLEAN EFIAPI X509VerifyCertChain(IN CONST UINT8 *RootCert, IN UINTN RootCertLength, IN CONST UINT8 *CertChain, IN UINTN CertChainLength)
BOOLEAN EFIAPI X509ConstructCertificate(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 **SingleX509Cert)
BOOLEAN EFIAPI RsaPkcs1Sign(IN VOID *RsaContext, IN CONST UINT8 *MessageHash, IN UINTN HashSize, OUT UINT8 *Signature, IN OUT UINTN *SigSize)
VOID EFIAPI EcFree(IN VOID *EcContext)
BOOLEAN EFIAPI AesCbcDecrypt(IN VOID *AesContext, IN CONST UINT8 *Input, IN UINTN InputSize, IN CONST UINT8 *Ivec, OUT UINT8 *Output)
BOOLEAN EFIAPI CryptoServiceSha512Update(IN OUT VOID *Sha512Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI CryptoServiceBigNumMod(IN CONST VOID *BnA, IN CONST VOID *BnB, OUT VOID *BnRes)
BOOLEAN EFIAPI CryptoServiceAuthenticodeVerify(IN CONST UINT8 *AuthData, IN UINTN DataSize, IN CONST UINT8 *TrustedCert, IN UINTN CertSize, IN CONST UINT8 *ImageHash, IN UINTN HashSize)
UINT16 EFIAPI CryptoServiceTlsGetVersion(IN VOID *Tls)
BOOLEAN EFIAPI CryptoServiceX509GetTBSCert(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 **TBSCert, OUT UINTN *TBSCertSize)
BOOLEAN EFIAPI CryptoServiceParallelHash256HashAll(IN CONST VOID *Input, IN UINTN InputByteLen, IN UINTN BlockSize, OUT VOID *Output, IN UINTN OutputByteLen, IN CONST VOID *Customization, IN UINTN CustomByteLen)
UINTN EFIAPI CryptoServiceBigNumBytes(IN CONST VOID *Bn)
VOID EFIAPI DeprecatedCryptoServiceHmacSha1Free(IN VOID *HmacSha1Ctx)
BOOLEAN EFIAPI CryptoServiceAesCbcEncrypt(IN VOID *AesContext, IN CONST UINT8 *Input, IN UINTN InputSize, IN CONST UINT8 *Ivec, OUT UINT8 *Output)
BOOLEAN EFIAPI CryptoServiceBigNumAddMod(IN CONST VOID *BnA, IN CONST VOID *BnB, IN CONST VOID *BnM, OUT VOID *BnRes)
UINTN EFIAPI CryptoServiceSm3GetContextSize(VOID)
BOOLEAN EFIAPI CryptoServiceEcPointGetAffineCoordinates(IN CONST VOID *EcGroup, IN CONST VOID *EcPoint, OUT VOID *BnX, OUT VOID *BnY, IN VOID *BnCtx)
BOOLEAN EFIAPI CryptoServiceDhGenerateKey(IN OUT VOID *DhContext, OUT UINT8 *PublicKey, IN OUT UINTN *PublicKeySize)
BOOLEAN EFIAPI CryptoServiceSha512Final(IN OUT VOID *Sha512Context, OUT UINT8 *HashValue)
BOOLEAN EFIAPI CryptoServiceBigNumSqrMod(IN CONST VOID *BnA, IN CONST VOID *BnM, OUT VOID *BnRes)
VOID EFIAPI CryptoServiceX509Free(IN VOID *X509Cert)
BOOLEAN EFIAPI CryptoServiceX509VerifyCertChain(IN CONST UINT8 *RootCert, IN UINTN RootCertLength, IN CONST UINT8 *CertChain, IN UINTN CertChainLength)
INTN EFIAPI CryptoServiceTlsCtrlTrafficOut(IN VOID *Tls, IN OUT VOID *Buffer, IN UINTN BufferSize)
BOOLEAN EFIAPI CryptoServiceEcPointIsOnCurve(IN CONST VOID *EcGroup, IN CONST VOID *EcPoint, IN VOID *BnCtx)
INTN EFIAPI CryptoServiceBigNumToBin(IN CONST VOID *Bn, OUT UINT8 *Buf)
BOOLEAN EFIAPI CryptoServiceSha384Duplicate(IN CONST VOID *Sha384Context, OUT VOID *NewSha384Context)
EFI_STATUS EFIAPI CryptoServiceTlsSetHostPublicCert(IN VOID *Tls, IN VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI CryptoServiceBigNumSetUint(IN VOID *Bn, IN UINTN Val)
BOOLEAN EFIAPI CryptoServiceSha1Final(IN OUT VOID *Sha1Context, OUT UINT8 *HashValue)
EFI_STATUS EFIAPI CryptoServiceTlsSetVersion(IN VOID *Tls, IN UINT8 MajorVer, IN UINT8 MinorVer)
EFI_STATUS EFIAPI CryptoServiceTlsHandleAlert(IN VOID *Tls, IN UINT8 *BufferIn OPTIONAL, IN UINTN BufferInSize OPTIONAL, OUT UINT8 *BufferOut OPTIONAL, IN OUT UINTN *BufferOutSize)
BOOLEAN EFIAPI CryptoServiceX509GetSignatureAlgorithm(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 *Oid, OPTIONAL IN OUT UINTN *OidSize)
VOID *EFIAPI CryptoServiceTlsNew(IN VOID *TlsCtx)
BOOLEAN EFIAPI CryptoServiceEcPointMul(IN CONST VOID *EcGroup, OUT VOID *EcPointResult, IN CONST VOID *EcPoint, IN CONST VOID *BnPScalar, IN VOID *BnCtx)
BOOLEAN EFIAPI CryptoServiceHmacSha256Duplicate(IN CONST VOID *HmacSha256Context, OUT VOID *NewHmacSha256Context)
INT32 EFIAPI CryptoServiceX509CompareDateTime(IN CONST VOID *DateTime1, IN CONST VOID *DateTime2)
BOOLEAN EFIAPI CryptoServicePkcs1v2Encrypt(IN CONST UINT8 *PublicKey, IN UINTN PublicKeySize, IN UINT8 *InData, IN UINTN InDataSize, IN CONST UINT8 *PrngSeed OPTIONAL, IN UINTN PrngSeedSize OPTIONAL, OUT UINT8 **EncryptedData, OUT UINTN *EncryptedDataSize)
EFI_STATUS EFIAPI CryptoServiceTlsGetKeyMaterial(IN VOID *Tls, IN OUT UINT8 *KeyMaterial)
BOOLEAN EFIAPI CryptoServiceAeadAesGcmEncrypt(IN CONST UINT8 *Key, IN UINTN KeySize, IN CONST UINT8 *Iv, IN UINTN IvSize, IN CONST UINT8 *AData, IN UINTN ADataSize, IN CONST UINT8 *DataIn, IN UINTN DataInSize, OUT UINT8 *TagOut, IN UINTN TagSize, OUT UINT8 *DataOut, OUT UINTN *DataOutSize)
EFI_STATUS EFIAPI CryptoServiceTlsGetCurrentCompressionId(IN VOID *Tls, IN OUT UINT8 *CompressionId)
VOID EFIAPI CryptoServiceX509StackFree(IN VOID *X509Stack)
EFI_STATUS EFIAPI CryptoServiceTlsSetCaCertificate(IN VOID *Tls, IN VOID *Data, IN UINTN DataSize)
EFI_STATUS EFIAPI CryptoServiceTlsSetSignatureAlgoList(IN VOID *Tls, IN UINT8 *Data, IN UINTN DataSize)
UINTN EFIAPI CryptoServiceGetCryptoVersion(VOID)
BOOLEAN EFIAPI CryptoServiceHmacSha384Final(IN OUT VOID *HmacSha384Context, OUT UINT8 *HmacValue)
EFI_STATUS EFIAPI CryptoServiceTlsGetCurrentCipher(IN VOID *Tls, IN OUT UINT16 *CipherId)
VOID *EFIAPI CryptoServiceBigNumNewContext(VOID)
BOOLEAN EFIAPI CryptoServiceDhComputeKey(IN OUT VOID *DhContext, IN CONST UINT8 *PeerPublicKey, IN UINTN PeerPublicKeySize, OUT UINT8 *Key, IN OUT UINTN *KeySize)
BOOLEAN EFIAPI CryptoServiceRsaGetPublicKeyFromX509(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT VOID **RsaContext)
BOOLEAN EFIAPI CryptoServiceRsaPssSign(IN VOID *RsaContext, IN CONST UINT8 *Message, IN UINTN MsgSize, IN UINT16 DigestLen, IN UINT16 SaltLen, OUT UINT8 *Signature, IN OUT UINTN *SigSize)
BOOLEAN EFIAPI DeprecatedCryptoServiceHmacSha1SetKey(OUT VOID *HmacSha1Context, IN CONST UINT8 *Key, IN UINTN KeySize)
EFI_STATUS EFIAPI CryptoServiceTlsSetSessionId(IN VOID *Tls, IN UINT8 *SessionId, IN UINT16 SessionIdLen)
BOOLEAN EFIAPI DeprecatedCryptoServiceHmacSha1Duplicate(IN CONST VOID *HmacSha1Context, OUT VOID *NewHmacSha1Context)
BOOLEAN EFIAPI CryptoServiceSha384HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
VOID EFIAPI CryptoServiceBigNumContextFree(IN VOID *BnCtx)
BOOLEAN EFIAPI DeprecatedCryptoServiceArc4Decrypt(IN OUT VOID *Arc4Context, IN UINT8 *Input, IN UINTN InputSize, OUT UINT8 *Output)
BOOLEAN EFIAPI CryptoServiceX509FormatDateTime(IN CONST CHAR8 *DateTimeStr, OUT VOID *DateTime, IN OUT UINTN *DateTimeSize)
VOID *EFIAPI CryptoServiceEcGroupInit(IN UINTN CryptoNid)
VOID EFIAPI CryptoServiceTlsGetClientRandom(IN VOID *Tls, IN OUT UINT8 *ClientRandom)
EFI_STATUS EFIAPI CryptoServiceTlsSetVerifyHost(IN VOID *Tls, IN UINT32 Flags, IN CHAR8 *HostName)
VOID *EFIAPI CryptoServiceBigNumCopy(OUT VOID *BnDst, IN CONST VOID *BnSrc)
BOOLEAN EFIAPI CryptoServiceHkdfSha384Extract(IN CONST UINT8 *Key, IN UINTN KeySize, IN CONST UINT8 *Salt, IN UINTN SaltSize, OUT UINT8 *PrkOut, UINTN PrkOutSize)
BOOLEAN EFIAPI CryptoServiceHkdfSha384Expand(IN CONST UINT8 *Prk, IN UINTN PrkSize, IN CONST UINT8 *Info, IN UINTN InfoSize, OUT UINT8 *Out, IN UINTN OutSize)
UINTN EFIAPI CryptoServiceSha1GetContextSize(VOID)
BOOLEAN EFIAPI CryptoServiceHmacSha384All(IN CONST VOID *Data, IN UINTN DataSize, IN CONST UINT8 *Key, IN UINTN KeySize, OUT UINT8 *HmacValue)
EFI_STATUS EFIAPI CryptoServiceTlsSetCertRevocationList(IN VOID *Data, IN UINTN DataSize)
VOID EFIAPI CryptoServiceTlsSetVerify(IN VOID *Tls, IN UINT32 VerifyMode)
UINTN EFIAPI CryptoServiceSha384GetContextSize(VOID)
VOID EFIAPI CryptoServicePkcs7FreeSigners(IN UINT8 *Certs)
VOID EFIAPI CryptoServiceRsaFree(IN VOID *RsaContext)
BOOLEAN EFIAPI CryptoServiceRsaGenerateKey(IN OUT VOID *RsaContext, IN UINTN ModulusLength, IN CONST UINT8 *PublicExponent, IN UINTN PublicExponentSize)
EFI_STATUS EFIAPI CryptoServiceTlsGetCaCertificate(IN VOID *Tls, OUT VOID *Data, IN OUT UINTN *DataSize)
BOOLEAN EFIAPI DeprecatedCryptoServiceMd4Update(IN OUT VOID *Md4Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI CryptoServiceSm3Init(OUT VOID *Sm3Context)
BOOLEAN EFIAPI CryptoServicePkcs7GetCertificatesList(IN CONST UINT8 *P7Data, IN UINTN P7Length, OUT UINT8 **SignerChainCerts, OUT UINTN *ChainLength, OUT UINT8 **UnchainCerts, OUT UINTN *UnchainLength)
BOOLEAN EFIAPI CryptoServiceEcGetPrivateKeyFromPem(IN CONST UINT8 *PemData, IN UINTN PemSize, IN CONST CHAR8 *Password, OUT VOID **EcContext)
BOOLEAN EFIAPI CryptoServiceRsaGetKey(IN OUT VOID *RsaContext, IN RSA_KEY_TAG KeyTag, OUT UINT8 *BigNumber, IN OUT UINTN *BnSize)
VOID *EFIAPI CryptoServiceEcPointInit(IN CONST VOID *EcGroup)
INTN EFIAPI CryptoServiceTlsCtrlTrafficIn(IN VOID *Tls, IN VOID *Buffer, IN UINTN BufferSize)
EFI_STATUS EFIAPI CryptoServiceTlsSetCompressionMethod(IN UINT8 CompMethod)
BOOLEAN EFIAPI DeprecatedCryptoServiceMd4HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
BOOLEAN EFIAPI CryptoServiceTlsInitialize(VOID)
EFI_STATUS EFIAPI CryptoServiceTlsDoHandshake(IN VOID *Tls, IN UINT8 *BufferIn OPTIONAL, IN UINTN BufferInSize OPTIONAL, OUT UINT8 *BufferOut OPTIONAL, IN OUT UINTN *BufferOutSize)
BOOLEAN EFIAPI DeprecatedCryptoServiceTdesInit(OUT VOID *TdesContext, IN CONST UINT8 *Key, IN UINTN KeyLength)
BOOLEAN EFIAPI CryptoServiceX509GetCertFromCertChain(IN CONST UINT8 *CertChain, IN UINTN CertChainLength, IN CONST INT32 CertIndex, OUT CONST UINT8 **Cert, OUT UINTN *CertLength)
BOOLEAN EFIAPI CryptoServiceRsaOaepDecrypt(IN VOID *RsaContext, IN UINT8 *EncryptedData, IN UINTN EncryptedDataSize, IN UINT16 DigestLen OPTIONAL, OUT UINT8 **OutData, OUT UINTN *OutDataSize)
BOOLEAN EFIAPI DeprecatedCryptoServiceMd5Update(IN OUT VOID *Md5Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI CryptoServiceSha1Init(OUT VOID *Sha1Context)
BOOLEAN EFIAPI CryptoServiceEcPointEqual(IN CONST VOID *EcGroup, IN CONST VOID *EcPointA, IN CONST VOID *EcPointB, IN VOID *BnCtx)
UINTN EFIAPI DeprecatedCryptoServiceMd4GetContextSize(VOID)
VOID *EFIAPI CryptoServiceTlsCtxNew(IN UINT8 MajorVer, IN UINT8 MinorVer)
BOOLEAN EFIAPI CryptoServiceBigNumIsWord(IN CONST VOID *Bn, IN UINTN Num)
BOOLEAN EFIAPI DeprecatedCryptoServiceMd5HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
BOOLEAN EFIAPI CryptoServiceSha1HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
BOOLEAN EFIAPI CryptoServiceHmacSha384Update(IN OUT VOID *HmacSha384Context, IN CONST VOID *Data, IN UINTN DataSize)
EFI_STATUS EFIAPI CryptoServiceTlsGetSessionId(IN VOID *Tls, IN OUT UINT8 *SessionId, IN OUT UINT16 *SessionIdLen)
VOID EFIAPI CryptoServiceTlsCtxFree(IN VOID *TlsCtx)
BOOLEAN EFIAPI DeprecatedCryptoServiceAesEcbEncrypt(IN VOID *AesContext, IN CONST UINT8 *Input, IN UINTN InputSize, OUT UINT8 *Output)
BOOLEAN EFIAPI CryptoServiceSha384Update(IN OUT VOID *Sha384Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI DeprecatedCryptoServiceTdesCbcDecrypt(IN VOID *TdesContext, IN CONST UINT8 *Input, IN UINTN InputSize, IN CONST UINT8 *Ivec, OUT UINT8 *Output)
BOOLEAN EFIAPI DeprecatedCryptoServiceArc4Init(OUT VOID *Arc4Context, IN CONST UINT8 *Key, IN UINTN KeySize)
BOOLEAN EFIAPI DeprecatedCryptoServiceAesEcbDecrypt(IN VOID *AesContext, IN CONST UINT8 *Input, IN UINTN InputSize, OUT UINT8 *Output)
VOID EFIAPI CryptoServiceTlsFree(IN VOID *Tls)
BOOLEAN EFIAPI CryptoServiceX509ConstructCertificateStackV(IN OUT UINT8 **X509Stack, IN VA_LIST Args)
BOOLEAN EFIAPI DeprecatedCryptoServiceHmacMd5Final(IN OUT VOID *HmacMd5Context, OUT UINT8 *HmacValue)
BOOLEAN EFIAPI CryptoServiceHmacSha256All(IN CONST VOID *Data, IN UINTN DataSize, IN CONST UINT8 *Key, IN UINTN KeySize, OUT UINT8 *HmacValue)
BOOLEAN EFIAPI DeprecatedCryptoServiceTdesCbcEncrypt(IN VOID *TdesContext, IN CONST UINT8 *Input, IN UINTN InputSize, IN CONST UINT8 *Ivec, OUT UINT8 *Output)
BOOLEAN EFIAPI CryptoServiceAesCbcDecrypt(IN VOID *AesContext, IN CONST UINT8 *Input, IN UINTN InputSize, IN CONST UINT8 *Ivec, OUT UINT8 *Output)
VOID *EFIAPI DeprecatedCryptoServiceHmacSha1New(VOID)
BOOLEAN EFIAPI CryptoServiceX509GetExtendedKeyUsage(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 *Usage, IN OUT UINTN *UsageSize)
VOID *EFIAPI CryptoServiceDhNew(VOID)
BOOLEAN EFIAPI CryptoServiceSm3Update(IN OUT VOID *Sm3Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI CryptoServiceHmacSha256SetKey(OUT VOID *HmacSha256Context, IN CONST UINT8 *Key, IN UINTN KeySize)
BOOLEAN EFIAPI CryptoServiceEcPointIsAtInfinity(IN CONST VOID *EcGroup, IN CONST VOID *EcPoint)
UINT8 EFIAPI CryptoServiceTlsGetConnectionEnd(IN VOID *Tls)
BOOLEAN EFIAPI CryptoServiceX509GetIssuerName(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 *CertIssuer, IN OUT UINTN *CertIssuerSize)
BOOLEAN EFIAPI CryptoServiceRsaPkcs1Verify(IN VOID *RsaContext, IN CONST UINT8 *MessageHash, IN UINTN HashSize, IN CONST UINT8 *Signature, IN UINTN SigSize)
BOOLEAN EFIAPI CryptoServiceRsaPkcs1Sign(IN VOID *RsaContext, IN CONST UINT8 *MessageHash, IN UINTN HashSize, OUT UINT8 *Signature, IN OUT UINTN *SigSize)
BOOLEAN EFIAPI CryptoServiceSha384Final(IN OUT VOID *Sha384Context, OUT UINT8 *HashValue)
VOID *EFIAPI CryptoServiceRsaNew(VOID)
BOOLEAN EFIAPI CryptoServiceImageTimestampVerify(IN CONST UINT8 *AuthData, IN UINTN DataSize, IN CONST UINT8 *TsaCert, IN UINTN CertSize, OUT EFI_TIME *SigningTime)
BOOLEAN EFIAPI DeprecatedCryptoServiceHmacMd5Duplicate(IN CONST VOID *HmacMd5Context, OUT VOID *NewHmacMd5Context)
BOOLEAN EFIAPI CryptoServicePkcs7GetAttachedContent(IN CONST UINT8 *P7Data, IN UINTN P7Length, OUT VOID **Content, OUT UINTN *ContentSize)
BOOLEAN EFIAPI CryptoServiceSm3HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
BOOLEAN EFIAPI CryptoServiceHkdfSha256ExtractAndExpand(IN CONST UINT8 *Key, IN UINTN KeySize, IN CONST UINT8 *Salt, IN UINTN SaltSize, IN CONST UINT8 *Info, IN UINTN InfoSize, OUT UINT8 *Out, IN UINTN OutSize)
BOOLEAN EFIAPI DeprecatedCryptoServiceHmacMd5SetKey(OUT VOID *HmacMd5Context, IN CONST UINT8 *Key, IN UINTN KeySize)
BOOLEAN EFIAPI CryptoServiceX509GetSubjectName(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 *CertSubject, IN OUT UINTN *SubjectSize)
BOOLEAN EFIAPI CryptoServiceRandomSeed(IN CONST UINT8 *Seed OPTIONAL, IN UINTN SeedSize)
#define CALL_VOID_BASECRYPTLIB(Enable, Function, Args)
BOOLEAN EFIAPI CryptoServiceEcDhComputeKey(IN OUT VOID *EcContext, IN CONST UINT8 *PeerPublic, IN UINTN PeerPublicSize, IN CONST INT32 *CompressFlag, OUT UINT8 *Key, IN OUT UINTN *KeySize)
BOOLEAN EFIAPI CryptoServiceSha256Init(OUT VOID *Sha256Context)
VOID EFIAPI CryptoServiceEcGroupFree(IN VOID *EcGroup)
BOOLEAN EFIAPI CryptoServiceEcGenerateKey(IN OUT VOID *EcContext, OUT UINT8 *PublicKey, IN OUT UINTN *PublicKeySize)
BOOLEAN EFIAPI CryptoServiceEcPointSetAffineCoordinates(IN CONST VOID *EcGroup, IN VOID *EcPoint, IN CONST VOID *BnX, IN CONST VOID *BnY, IN VOID *BnCtx)
EFI_STATUS EFIAPI CryptoServiceTlsSetEcCurve(IN VOID *Tls, IN UINT8 *Data, IN UINTN DataSize)
BOOLEAN EFIAPI CryptoServiceSm3Final(IN OUT VOID *Sm3Context, OUT UINT8 *HashValue)
UINTN EFIAPI DeprecatedCryptoServiceMd5GetContextSize(VOID)
BOOLEAN EFIAPI DeprecatedCryptoServiceHmacSha1Update(IN OUT VOID *HmacSha1Context, IN CONST VOID *Data, IN UINTN DataSize)
VOID EFIAPI CryptoServiceEcPointDeInit(IN VOID *EcPoint, IN BOOLEAN Clear)
BOOLEAN EFIAPI CryptoServiceSha1Duplicate(IN CONST VOID *Sha1Context, OUT VOID *NewSha1Context)
BOOLEAN EFIAPI DeprecatedCryptoServiceMd5Duplicate(IN CONST VOID *Md5Context, OUT VOID *NewMd5Context)
BOOLEAN EFIAPI CryptoServiceSha1Update(IN OUT VOID *Sha1Context, IN CONST VOID *Data, IN UINTN DataSize)
EFI_STATUS EFIAPI CryptoServiceTlsCloseNotify(IN VOID *Tls, IN OUT UINT8 *Buffer, IN OUT UINTN *BufferSize)
BOOLEAN EFIAPI CryptoServiceBigNumMulMod(IN CONST VOID *BnA, IN CONST VOID *BnB, IN CONST VOID *BnM, OUT VOID *BnRes)
EFI_STATUS EFIAPI CryptoServiceTlsSetCipherList(IN VOID *Tls, IN UINT16 *CipherId, IN UINTN CipherNum)
BOOLEAN EFIAPI CryptoServiceSha512HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
BOOLEAN EFIAPI CryptoServiceEcGroupGetCurve(IN CONST VOID *EcGroup, OUT VOID *BnPrime, OUT VOID *BnA, OUT VOID *BnB, IN VOID *BnCtx)
EFI_STATUS EFIAPI CryptoServiceTlsShutdown(IN VOID *Tls)
BOOLEAN EFIAPI DeprecatedCryptoServiceTdesEcbDecrypt(IN VOID *TdesContext, IN CONST UINT8 *Input, IN UINTN InputSize, OUT UINT8 *Output)
BOOLEAN EFIAPI CryptoServiceX509ConstructCertificateStack(IN OUT UINT8 **X509Stack,...)
VOID EFIAPI CryptoServiceDhFree(IN VOID *DhContext)
VOID EFIAPI CryptoServiceBigNumConstTime(IN VOID *Bn)
BOOLEAN EFIAPI CryptoServicePkcs5HashPassword(IN UINTN PasswordLength, IN CONST CHAR8 *Password, IN UINTN SaltLength, IN CONST UINT8 *Salt, IN UINTN IterationCount, IN UINTN DigestSize, IN UINTN KeyLength, OUT UINT8 *OutKey)
UINTN EFIAPI CryptoServiceSha256GetContextSize(VOID)
BOOLEAN EFIAPI CryptoServiceEcGetPublicKeyFromX509(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT VOID **EcContext)
BOOLEAN EFIAPI DeprecatedCryptoServiceMd5Init(OUT VOID *Md5Context)
BOOLEAN EFIAPI DeprecatedCryptoServiceMd4Init(OUT VOID *Md4Context)
RETURN_STATUS EFIAPI CryptoServiceVerifyEKUsInPkcs7Signature(IN CONST UINT8 *Pkcs7Signature, IN CONST UINT32 SignatureSize, IN CONST CHAR8 *RequiredEKUs[], IN CONST UINT32 RequiredEKUsSize, IN BOOLEAN RequireAllPresent)
BOOLEAN EFIAPI DeprecatedCryptoServiceMd4Duplicate(IN CONST VOID *Md4Context, OUT VOID *NewMd4Context)
EFI_STATUS EFIAPI CryptoServiceTlsGetHostPrivateKey(IN VOID *Tls, OUT VOID *Data, IN OUT UINTN *DataSize)
BOOLEAN EFIAPI CryptoServiceHkdfSha384ExtractAndExpand(IN CONST UINT8 *Key, IN UINTN KeySize, IN CONST UINT8 *Salt, IN UINTN SaltSize, IN CONST UINT8 *Info, IN UINTN InfoSize, OUT UINT8 *Out, IN UINTN OutSize)
EFI_STATUS EFIAPI CryptoServiceTlsGetCertRevocationList(OUT VOID *Data, IN OUT UINTN *DataSize)
BOOLEAN EFIAPI CryptoServicePkcs7GetSigners(IN CONST UINT8 *P7Data, IN UINTN P7Length, OUT UINT8 **CertStack, OUT UINTN *StackLength, OUT UINT8 **TrustedCert, OUT UINTN *CertLength)
VOID *EFIAPI CryptoServiceEcNewByNid(IN UINTN Nid)
BOOLEAN EFIAPI DeprecatedCryptoServiceMd4Final(IN OUT VOID *Md4Context, OUT UINT8 *HashValue)
VOID EFIAPI CryptoServiceHmacSha384Free(IN VOID *HmacSha384Ctx)
BOOLEAN EFIAPI CryptoServiceSha256Update(IN OUT VOID *Sha256Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI CryptoServiceSm3Duplicate(IN CONST VOID *Sm3Context, OUT VOID *NewSm3Context)
UINTN EFIAPI DeprecatedCryptoServiceArc4GetContextSize(VOID)
BOOLEAN EFIAPI CryptoServicePkcs7Sign(IN CONST UINT8 *PrivateKey, IN UINTN PrivateKeySize, IN CONST UINT8 *KeyPassword, IN UINT8 *InData, IN UINTN InDataSize, IN UINT8 *SignCert, IN UINT8 *OtherCerts OPTIONAL, OUT UINT8 **SignedData, OUT UINTN *SignedDataSize)
VOID *EFIAPI CryptoServiceHmacSha256New(VOID)
BOOLEAN EFIAPI CryptoServicePkcs1v2Decrypt(IN CONST UINT8 *PrivateKey, IN UINTN PrivateKeySize, IN UINT8 *EncryptedData, IN UINTN EncryptedDataSize, OUT UINT8 **OutData, OUT UINTN *OutDataSize)
VOID *EFIAPI DeprecatedCryptoServiceHmacMd5New(VOID)
BOOLEAN EFIAPI CryptoServicePkcs7Verify(IN CONST UINT8 *P7Data, IN UINTN P7Length, IN CONST UINT8 *TrustedCert, IN UINTN CertLength, IN CONST UINT8 *InData, IN UINTN DataLength)
BOOLEAN EFIAPI CryptoServiceX509GetSerialNumber(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 *SerialNumber, OPTIONAL IN OUT UINTN *SerialNumberSize)
BOOLEAN EFIAPI CryptoServiceHmacSha384Duplicate(IN CONST VOID *HmacSha384Context, OUT VOID *NewHmacSha384Context)
BOOLEAN EFIAPI CryptoServiceEcPointSetCompressedCoordinates(IN CONST VOID *EcGroup, IN VOID *EcPoint, IN CONST VOID *BnX, IN UINT8 YBit, IN VOID *BnCtx)
BOOLEAN EFIAPI CryptoServiceAesInit(OUT VOID *AesContext, IN CONST UINT8 *Key, IN UINTN KeyLength)
BOOLEAN EFIAPI CryptoServiceX509GetVersion(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINTN *Version)
VOID EFIAPI DeprecatedCryptoServiceHmacMd5Free(IN VOID *HmacMd5Ctx)
BOOLEAN EFIAPI CryptoServiceRsaPssVerify(IN VOID *RsaContext, IN CONST UINT8 *Message, IN UINTN MsgSize, IN CONST UINT8 *Signature, IN UINTN SigSize, IN UINT16 DigestLen, IN UINT16 SaltLen)
BOOLEAN EFIAPI CryptoServiceBigNumSub(IN CONST VOID *BnA, IN CONST VOID *BnB, OUT VOID *BnRes)
INTN EFIAPI CryptoServiceTlsRead(IN VOID *Tls, IN OUT VOID *Buffer, IN UINTN BufferSize)
BOOLEAN EFIAPI CryptoServiceX509GetExtendedBasicConstraints(CONST UINT8 *Cert, UINTN CertSize, UINT8 *BasicConstraints, UINTN *BasicConstraintsSize)
VOID *EFIAPI CryptoServiceHmacSha384New(VOID)
BOOLEAN EFIAPI CryptoServiceX509ConstructCertificate(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINT8 **SingleX509Cert)
BOOLEAN EFIAPI CryptoServiceHmacSha384SetKey(OUT VOID *HmacSha384Context, IN CONST UINT8 *Key, IN UINTN KeySize)
UINT32 EFIAPI CryptoServiceTlsGetVerify(IN VOID *Tls)
UINTN EFIAPI CryptoServiceSha512GetContextSize(VOID)
BOOLEAN EFIAPI CryptoServiceHkdfSha256Expand(IN CONST UINT8 *Prk, IN UINTN PrkSize, IN CONST UINT8 *Info, IN UINTN InfoSize, OUT UINT8 *Out, IN UINTN OutSize)
BOOLEAN EFIAPI DeprecatedCryptoServiceArc4Reset(IN OUT VOID *Arc4Context)
EFI_STATUS EFIAPI CryptoServiceTlsSetHostPrivateKeyEx(IN VOID *Tls, IN VOID *Data, IN UINTN DataSize, IN VOID *Password OPTIONAL)
BOOLEAN EFIAPI CryptoServiceBigNumAdd(IN CONST VOID *BnA, IN CONST VOID *BnB, OUT VOID *BnRes)
BOOLEAN EFIAPI CryptoServiceBigNumInverseMod(IN CONST VOID *BnA, IN CONST VOID *BnM, OUT VOID *BnRes)
VOID EFIAPI CryptoServiceEcFree(IN VOID *EcContext)
BOOLEAN EFIAPI CryptoServiceHmacSha256Update(IN OUT VOID *HmacSha256Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI CryptoServiceEcGetPubKey(IN OUT VOID *EcContext, OUT UINT8 *PublicKey, IN OUT UINTN *PublicKeySize)
BOOLEAN EFIAPI CryptoServiceSha512Duplicate(IN CONST VOID *Sha512Context, OUT VOID *NewSha512Context)
BOOLEAN EFIAPI CryptoServiceEcPointAdd(IN CONST VOID *EcGroup, OUT VOID *EcPointResult, IN CONST VOID *EcPointA, IN CONST VOID *EcPointB, IN VOID *BnCtx)
RETURN_STATUS EFIAPI CryptoServiceX509GetOrganizationName(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT CHAR8 *NameBuffer OPTIONAL, IN OUT UINTN *NameBufferSize)
BOOLEAN EFIAPI DeprecatedCryptoServiceArc4Encrypt(IN OUT VOID *Arc4Context, IN CONST UINT8 *Input, IN UINTN InputSize, OUT UINT8 *Output)
UINTN EFIAPI CryptoServiceBigNumBits(IN CONST VOID *Bn)
VOID *EFIAPI CryptoServiceBigNumInit(VOID)
EFI_STATUS EFIAPI CryptoServiceTlsSetConnectionEnd(IN VOID *Tls, IN BOOLEAN IsServer)
BOOLEAN EFIAPI CryptoServiceSha256Duplicate(IN CONST VOID *Sha256Context, OUT VOID *NewSha256Context)
BOOLEAN EFIAPI CryptoServiceBigNumExpMod(IN CONST VOID *BnA, IN CONST VOID *BnP, IN CONST VOID *BnM, OUT VOID *BnRes)
BOOLEAN EFIAPI CryptoServiceRsaCheckKey(IN VOID *RsaContext)
BOOLEAN EFIAPI DeprecatedCryptoServiceHmacMd5Update(IN OUT VOID *HmacMd5Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI CryptoServiceRandomBytes(OUT UINT8 *Output, IN UINTN Size)
BOOLEAN EFIAPI CryptoServiceEcDsaVerify(IN VOID *EcContext, IN UINTN HashNid, IN CONST UINT8 *MessageHash, IN UINTN HashSize, IN CONST UINT8 *Signature, IN UINTN SigSize)
VOID EFIAPI CryptoServiceHmacSha256Free(IN VOID *HmacSha256Ctx)
BOOLEAN EFIAPI CryptoServiceTlsInHandshake(IN VOID *Tls)
BOOLEAN EFIAPI CryptoServiceBigNumRShift(IN CONST VOID *Bn, IN UINTN N, OUT VOID *BnRes)
INTN EFIAPI CryptoServiceTlsWrite(IN VOID *Tls, IN VOID *Buffer, IN UINTN BufferSize)
BOOLEAN EFIAPI CryptoServiceEcGroupGetOrder(IN VOID *EcGroup, OUT VOID *BnOrder)
BOOLEAN EFIAPI CryptoServiceRsaGetPrivateKeyFromPem(IN CONST UINT8 *PemData, IN UINTN PemSize, IN CONST CHAR8 *Password, OUT VOID **RsaContext)
BOOLEAN EFIAPI DeprecatedCryptoServiceHmacSha1Final(IN OUT VOID *HmacSha1Context, OUT UINT8 *HmacValue)
BOOLEAN EFIAPI CryptoServiceSha384Init(OUT VOID *Sha384Context)
VOID EFIAPI CryptoServiceTlsGetServerRandom(IN VOID *Tls, IN OUT UINT8 *ServerRandom)
UINTN EFIAPI DeprecatedCryptoServiceTdesGetContextSize(VOID)
BOOLEAN EFIAPI CryptoServiceX509GetExtensionData(IN CONST UINT8 *Cert, IN UINTN CertSize, IN CONST UINT8 *Oid, IN UINTN OidSize, OUT UINT8 *ExtensionData, IN OUT UINTN *ExtensionDataSize)
BOOLEAN EFIAPI CryptoServiceHkdfSha256Extract(IN CONST UINT8 *Key, IN UINTN KeySize, IN CONST UINT8 *Salt, IN UINTN SaltSize, OUT UINT8 *PrkOut, UINTN PrkOutSize)
BOOLEAN EFIAPI CryptoServiceSha512Init(OUT VOID *Sha512Context)
#define CALL_BASECRYPTLIB(Enable, Function, Args, ErrorReturnValue)
EFI_STATUS EFIAPI CryptoServiceTlsGetExportKey(IN VOID *Tls, IN CONST VOID *Label, IN CONST VOID *Context, IN UINTN ContextLen, OUT VOID *KeyBuffer, IN UINTN KeyBufferLen)
VOID *EFIAPI CryptoServiceBigNumFromBin(IN CONST UINT8 *Buf, IN UINTN Len)
BOOLEAN EFIAPI CryptoServiceX509VerifyCert(IN CONST UINT8 *Cert, IN UINTN CertSize, IN CONST UINT8 *CACert, IN UINTN CACertSize)
RETURN_STATUS EFIAPI CryptoServiceX509GetCommonName(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT CHAR8 *CommonName OPTIONAL, IN OUT UINTN *CommonNameSize)
BOOLEAN EFIAPI CryptoServiceX509GetValidity(IN CONST UINT8 *Cert, IN UINTN CertSize, IN UINT8 *From, IN OUT UINTN *FromSize, IN UINT8 *To, IN OUT UINTN *ToSize)
BOOLEAN EFIAPI CryptoServiceBigNumIsOdd(IN CONST VOID *Bn)
BOOLEAN EFIAPI DeprecatedCryptoServiceTdesEcbEncrypt(IN VOID *TdesContext, IN CONST UINT8 *Input, IN UINTN InputSize, OUT UINT8 *Output)
BOOLEAN EFIAPI CryptoServiceBigNumDiv(IN CONST VOID *BnA, IN CONST VOID *BnB, OUT VOID *BnRes)
BOOLEAN EFIAPI CryptoServiceDhGenerateParameter(IN OUT VOID *DhContext, IN UINTN Generator, IN UINTN PrimeLength, OUT UINT8 *Prime)
EFI_STATUS EFIAPI CryptoServiceTlsGetHostPublicCert(IN VOID *Tls, OUT VOID *Data, IN OUT UINTN *DataSize)
EFI_STATUS EFIAPI CryptoServiceTlsSetHostPrivateKey(IN VOID *Tls, IN VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI CryptoServiceAsn1GetTag(IN OUT UINT8 **Ptr, IN CONST UINT8 *End, OUT UINTN *Length, IN UINT32 Tag)
CONST VOID *EFIAPI CryptoServiceBigNumValueOne(VOID)
BOOLEAN EFIAPI CryptoServiceSha256HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
BOOLEAN EFIAPI DeprecatedCryptoServiceMd5Final(IN OUT VOID *Md5Context, OUT UINT8 *HashValue)
UINTN EFIAPI CryptoServiceAesGetContextSize(VOID)
BOOLEAN EFIAPI CryptoServiceX509GetKeyUsage(IN CONST UINT8 *Cert, IN UINTN CertSize, OUT UINTN *Usage)
BOOLEAN EFIAPI CryptoServiceAeadAesGcmDecrypt(IN CONST UINT8 *Key, IN UINTN KeySize, IN CONST UINT8 *Iv, IN UINTN IvSize, IN CONST UINT8 *AData, IN UINTN ADataSize, IN CONST UINT8 *DataIn, IN UINTN DataInSize, IN CONST UINT8 *Tag, IN UINTN TagSize, OUT UINT8 *DataOut, OUT UINTN *DataOutSize)
BOOLEAN EFIAPI CryptoServiceEcPointInvert(IN CONST VOID *EcGroup, IN OUT VOID *EcPoint, IN VOID *BnCtx)
INTN EFIAPI CryptoServiceBigNumCmp(IN CONST VOID *BnA, IN CONST VOID *BnB)
BOOLEAN EFIAPI CryptoServiceEcDsaSign(IN VOID *EcContext, IN UINTN HashNid, IN CONST UINT8 *MessageHash, IN UINTN HashSize, OUT UINT8 *Signature, IN OUT UINTN *SigSize)
BOOLEAN EFIAPI CryptoServiceSha256Final(IN OUT VOID *Sha256Context, OUT UINT8 *HashValue)
BOOLEAN EFIAPI CryptoServiceHmacSha256Final(IN OUT VOID *HmacSha256Context, OUT UINT8 *HmacValue)
BOOLEAN EFIAPI CryptoServiceDhSetParameter(IN OUT VOID *DhContext, IN UINTN Generator, IN UINTN PrimeLength, IN CONST UINT8 *Prime)
VOID EFIAPI CryptoServiceBigNumFree(IN VOID *Bn, IN BOOLEAN Clear)
BOOLEAN EFIAPI CryptoServiceRsaOaepEncrypt(IN VOID *RsaContext, IN UINT8 *InData, IN UINTN InDataSize, IN CONST UINT8 *PrngSeed OPTIONAL, IN UINTN PrngSeedSize OPTIONAL, IN UINT16 DigestLen OPTIONAL, OUT UINT8 **EncryptedData, OUT UINTN *EncryptedDataSize)
BOOLEAN EFIAPI CryptoServiceRsaSetKey(IN OUT VOID *RsaContext, IN RSA_KEY_TAG KeyTag, IN CONST UINT8 *BigNumber, IN UINTN BnSize)
VOID EFIAPI Input(IN CHAR16 *Prompt OPTIONAL, OUT CHAR16 *InStr, IN UINTN StrLen)
BOOLEAN EFIAPI Md5Duplicate(IN CONST VOID *Md5Context, OUT VOID *NewMd5Context)
BOOLEAN EFIAPI Md5Final(IN OUT VOID *Md5Context, OUT UINT8 *HashValue)
BOOLEAN EFIAPI Md5Update(IN OUT VOID *Md5Context, IN CONST VOID *Data, IN UINTN DataSize)
BOOLEAN EFIAPI Md5Init(OUT VOID *Md5Context)
BOOLEAN EFIAPI Md5HashAll(IN CONST VOID *Data, IN UINTN DataSize, OUT UINT8 *HashValue)
UINTN EFIAPI Md5GetContextSize(VOID)
#define RETURN_UNSUPPORTED
#define VA_START(Marker, Parameter)
#define ASSERT_EFI_ERROR(StatusParameter)
#define DEBUG(Expression)
#define EDKII_CRYPTO_VERSION
VOID EFIAPI TlsGetServerRandom(IN VOID *Tls, IN OUT UINT8 *ServerRandom)
EFI_STATUS EFIAPI TlsGetHostPublicCert(IN VOID *Tls, OUT VOID *Data, IN OUT UINTN *DataSize)
EFI_STATUS EFIAPI TlsDoHandshake(IN VOID *Tls, IN UINT8 *BufferIn OPTIONAL, IN UINTN BufferInSize OPTIONAL, OUT UINT8 *BufferOut OPTIONAL, IN OUT UINTN *BufferOutSize)
EFI_STATUS EFIAPI TlsSetVerifyHost(IN VOID *Tls, IN UINT32 Flags, IN CHAR8 *HostName)
INTN EFIAPI TlsCtrlTrafficIn(IN VOID *Tls, IN VOID *Buffer, IN UINTN BufferSize)
EFI_STATUS EFIAPI TlsGetKeyMaterial(IN VOID *Tls, IN OUT UINT8 *KeyMaterial)
UINT32 EFIAPI TlsGetVerify(IN VOID *Tls)
EFI_STATUS EFIAPI TlsGetCurrentCipher(IN VOID *Tls, IN OUT UINT16 *CipherId)
EFI_STATUS EFIAPI TlsSetCertRevocationList(IN VOID *Data, IN UINTN DataSize)
VOID *EFIAPI TlsCtxNew(IN UINT8 MajorVer, IN UINT8 MinorVer)
EFI_STATUS EFIAPI TlsGetCertRevocationList(OUT VOID *Data, IN OUT UINTN *DataSize)
INTN EFIAPI TlsCtrlTrafficOut(IN VOID *Tls, IN OUT VOID *Buffer, IN UINTN BufferSize)
EFI_STATUS EFIAPI TlsSetCompressionMethod(IN UINT8 CompMethod)
VOID EFIAPI TlsFree(IN VOID *Tls)
EFI_STATUS EFIAPI TlsSetCaCertificate(IN VOID *Tls, IN VOID *Data, IN UINTN DataSize)
EFI_STATUS EFIAPI TlsSetCipherList(IN VOID *Tls, IN UINT16 *CipherId, IN UINTN CipherNum)
VOID *EFIAPI TlsNew(IN VOID *TlsCtx)
EFI_STATUS EFIAPI TlsGetCurrentCompressionId(IN VOID *Tls, IN OUT UINT8 *CompressionId)
EFI_STATUS EFIAPI TlsSetConnectionEnd(IN VOID *Tls, IN BOOLEAN IsServer)
EFI_STATUS EFIAPI TlsSetSessionId(IN VOID *Tls, IN UINT8 *SessionId, IN UINT16 SessionIdLen)
EFI_STATUS EFIAPI TlsSetHostPrivateKey(IN VOID *Tls, IN VOID *Data, IN UINTN DataSize)
EFI_STATUS EFIAPI TlsSetHostPublicCert(IN VOID *Tls, IN VOID *Data, IN UINTN DataSize)
UINT8 EFIAPI TlsGetConnectionEnd(IN VOID *Tls)
VOID EFIAPI TlsSetVerify(IN VOID *Tls, IN UINT32 VerifyMode)
VOID EFIAPI TlsCtxFree(IN VOID *TlsCtx)
VOID EFIAPI TlsGetClientRandom(IN VOID *Tls, IN OUT UINT8 *ClientRandom)
INTN EFIAPI TlsRead(IN VOID *Tls, IN OUT VOID *Buffer, IN UINTN BufferSize)
EFI_STATUS EFIAPI TlsShutdown(IN VOID *Tls)
BOOLEAN EFIAPI TlsInHandshake(IN VOID *Tls)
EFI_STATUS EFIAPI TlsSetVersion(IN VOID *Tls, IN UINT8 MajorVer, IN UINT8 MinorVer)
EFI_STATUS EFIAPI TlsSetHostPrivateKeyEx(IN VOID *Tls, IN VOID *Data, IN UINTN DataSize, IN VOID *Password OPTIONAL)
EFI_STATUS EFIAPI TlsHandleAlert(IN VOID *Tls, IN UINT8 *BufferIn OPTIONAL, IN UINTN BufferInSize OPTIONAL, OUT UINT8 *BufferOut OPTIONAL, IN OUT UINTN *BufferOutSize)
EFI_STATUS EFIAPI TlsCloseNotify(IN VOID *Tls, IN OUT UINT8 *Buffer, IN OUT UINTN *BufferSize)
BOOLEAN EFIAPI TlsInitialize(VOID)
EFI_STATUS EFIAPI TlsGetSessionId(IN VOID *Tls, IN OUT UINT8 *SessionId, IN OUT UINT16 *SessionIdLen)
UINT16 EFIAPI TlsGetVersion(IN VOID *Tls)
EFI_STATUS EFIAPI TlsSetEcCurve(IN VOID *Tls, IN UINT8 *Data, IN UINTN DataSize)
EFI_STATUS EFIAPI TlsGetExportKey(IN VOID *Tls, IN CONST VOID *Label, IN CONST VOID *Context, IN UINTN ContextLen, OUT VOID *KeyBuffer, IN UINTN KeyBufferLen)
INTN EFIAPI TlsWrite(IN VOID *Tls, IN VOID *Buffer, IN UINTN BufferSize)
EFI_STATUS EFIAPI TlsGetCaCertificate(IN VOID *Tls, OUT VOID *Data, IN OUT UINTN *DataSize)
EFI_STATUS EFIAPI TlsGetHostPrivateKey(IN VOID *Tls, OUT VOID *Data, IN OUT UINTN *DataSize)
EFI_STATUS EFIAPI TlsSetSignatureAlgoList(IN VOID *Tls, IN UINT8 *Data, IN UINTN DataSize)