Functions | |
UINT64 | IkeGenerateCookie (VOID) |
UINT8 * | IkeGenerateNonce (IN UINTN NonceSize) |
VOID | IkeHdrNetToHost (IN OUT IKE_HEADER *Header) |
VOID | IkeHdrHostToNet (IN OUT IKE_HEADER *Header) |
IKE_PAYLOAD * | IkePayloadAlloc (VOID) |
VOID | IkePayloadFree (IN IKE_PAYLOAD *IkePayload) |
UINT32 | IkeGenerateSpi (VOID) |
EFI_STATUS | IkeGenerateIv (IN UINT8 *IvBuffer, IN UINTN IvSize) |
IPSEC_SPD_ENTRY * | IkeSearchSpdEntry (IN EFI_IPSEC_SPD_SELECTOR *SpdSel) |
UINT8 | IkeGetVersionFromSession (IN UINT8 *Session) |
Variables | |
UINT32 | mNextSpi = IKE_SPI_BASE |
Copyright (c) 2010 - 2015, 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 http://opensource.org/licenses/bsd-license.php.
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
UINT64 IkeGenerateCookie | ( | VOID | ) |
Call Crypto Lib to generate a random value with eight-octet length.
References IpSecCryptoIoGenerateRandomBytes().
Referenced by Ikev2InitPskParser(), and Ikev2SaSessionAlloc().
EFI_STATUS IkeGenerateIv | ( | IN UINT8 * | IvBuffer, | |
IN UINTN | IvSize | |||
) |
Generate a random data for IV
[in] | IvBuffer | The pointer of the IV buffer. |
[in] | IvSize | The IV size. |
EFI_SUCCESS | Create a random data for IV. | |
otherwise | Failed. |
References IpSecCryptoIoGenerateRandomBytes().
Referenced by Ikev2EncryptPacket().
UINT8* IkeGenerateNonce | ( | IN UINTN | NonceSize | ) |
Generate the random data for Nonce payload.
[in] | NonceSize | Size of the data in bytes. |
References IpSecCryptoIoGenerateRandomBytes().
Referenced by Ikev2InitPskGenerator(), and Ikev2InitPskParser().
UINT32 IkeGenerateSpi | ( | VOID | ) |
Generate an new SPI.
References mNextSpi.
Referenced by Ikev2ChildSaSessionAlloc().
UINT8 IkeGetVersionFromSession | ( | IN UINT8 * | Session | ) |
Get the IKE Version from the IKE_SA_SESSION.
[in] | Session | Pointer of the IKE_SA_SESSION. |
References IKEV2_SA_SESSION_SIGNATURE.
Referenced by IkeDeleteAllSas(), and IkeNegotiate().
VOID IkeHdrHostToNet | ( | IN OUT IKE_HEADER * | Header | ) |
Convert the IKE Header from Host order to Network order.
[in,out] | Header | The pointer of the IKE_HEADER. |
Referenced by Ikev2DecryptPacket(), Ikev2EncodePacket(), and Ikev2EncryptPacket().
VOID IkeHdrNetToHost | ( | IN OUT IKE_HEADER * | Header | ) |
Convert the IKE Header from Network order to Host order.
[in,out] | Header | The pointer of the IKE_HEADER. |
Referenced by IkePacketFromNetbuf(), and Ikev2DecodePacket().
IKE_PAYLOAD* IkePayloadAlloc | ( | VOID | ) |
Allocate a buffer of IKE_PAYLOAD and set its Signature.
References IKE_PAYLOAD_SIGNATURE, and IKE_PAYLOAD::Signature.
Referenced by Ikev2CertGenerateAuthPayload(), Ikev2DecodePacket(), Ikev2EncryptPacket(), Ikev2GenerateCertIdPayload(), Ikev2GenerateCertificatePayload(), Ikev2GenerateCpPayload(), Ikev2GenerateDeletePayload(), Ikev2GenerateIdPayload(), Ikev2GenerateKePayload(), Ikev2GenerateNoncePayload(), Ikev2GenerateNotifyPayload(), Ikev2GenerateSaPayload(), Ikev2GenerateTsPayload(), and Ikev2PskGenerateAuthPayload().
VOID IkePayloadFree | ( | IN IKE_PAYLOAD * | IkePayload | ) |
Free a specified IKE_PAYLOAD buffer.
[in] | IkePayload | Pointer of IKE_PAYLOAD to be freed. |
Referenced by ClearAllPayloads(), IkePacketFree(), Ikev2AuthCertParser(), Ikev2CertGenerateAuthPayload(), Ikev2GenerateTsPayload(), Ikev2InitPskGenerator(), and Ikev2PskGenerateAuthPayload().
IPSEC_SPD_ENTRY* IkeSearchSpdEntry | ( | IN EFI_IPSEC_SPD_SELECTOR * | SpdSel | ) |
Find SPD entry by a specified SPD selector.
[in] | SpdSel | Point to SPD Selector to be searched for. |
Point | to SPD Entry if the SPD entry found. | |
NULL | if not found. |
References CompareSpdSelector(), IPSEC_SPD_ENTRY_FROM_LIST, mConfigData, and _IPSEC_SPD_ENTRY::Selector.
Referenced by Ikev2MatchSpdEntry().
UINT32 mNextSpi = IKE_SPI_BASE |
Referenced by IkeGenerateSpi().