TianoCore EDK2 master
Loading...
Searching...
No Matches
DxeCryptLib.c File Reference

Go to the source code of this file.

Functions

VOID * GetCryptoServices (VOID)
 
EFI_STATUS EFIAPI DxeCryptLibConstructor (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable)
 

Variables

EDKII_CRYPTO_PROTOCOLmCryptoProtocol = NULL
 

Detailed Description

Implements the GetCryptoServices() API that retuns a pointer to the EDK II Crypto Protocol.

Copyright (C) Microsoft Corporation. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file DxeCryptLib.c.

Function Documentation

◆ DxeCryptLibConstructor()

EFI_STATUS EFIAPI DxeCryptLibConstructor ( IN EFI_HANDLE  ImageHandle,
IN EFI_SYSTEM_TABLE SystemTable 
)

Locate the valid Crypto Protocol.

Parameters
ImageHandleThe firmware allocated handle for the EFI image.
SystemTableA pointer to the EFI System Table.
Return values
EFI_SUCCESSThe constructor executed correctly.
EFI_NOT_FOUNDFound no valid Crypto Protocol.

Definition at line 46 of file DxeCryptLib.c.

◆ GetCryptoServices()

VOID * GetCryptoServices ( VOID  )

Internal worker function that returns the pointer to an EDK II Crypto Protocol/PPI. The layout of the PPI, DXE Protocol, and SMM Protocol are identical which allows the implementation of the BaseCryptLib functions that call through a Protocol/PPI to be shared for the PEI, DXE, and SMM implementations.

This DXE implementation returns the pointer to the EDK II Crypto Protocol that was found in the library constructor DxeCryptLibConstructor().

Definition at line 28 of file DxeCryptLib.c.

Variable Documentation

◆ mCryptoProtocol

EDKII_CRYPTO_PROTOCOL* mCryptoProtocol = NULL

Definition at line 15 of file DxeCryptLib.c.