+++ /dev/null
-/** @file\r
- IKE Packet related definitions and function declarations.\r
-\r
- Copyright (c) 2010 - 2018, Intel Corporation. All rights reserved.<BR>\r
-\r
- SPDX-License-Identifier: BSD-2-Clause-Patent\r
-\r
-**/\r
-\r
-#ifndef _IKE_V1_PACKET_H_\r
-#define _IKE_V1_PACKET_H_\r
-\r
-#include "Ike.h"\r
-\r
-#define IKE_PACKET_REF(p) ((p)->RefCount++)\r
-\r
-/**\r
- Allocate a buffer for the IKE_PACKET and intitalize its Header and payloadlist.\r
-\r
- @return The pointer of the IKE_PACKET.\r
-\r
-**/\r
-IKE_PACKET *\r
-IkePacketAlloc (\r
- VOID\r
- );\r
-\r
-\r
-/**\r
- Free the IkePacket by the specified IKE_PACKET pointer.\r
-\r
- @param[in] IkePacket The pointer of the IKE_PACKET to be freed.\r
-\r
-**/\r
-VOID\r
-IkePacketFree (\r
- IN IKE_PACKET *IkePacket\r
- );\r
-\r
-\r
-/**\r
- Copy the NetBuf into a IKE_PACKET sturcture.\r
-\r
- Create a IKE_PACKET and fill the received IKE header into the header of IKE_PACKET\r
- and copy the recieved packet without IKE HEADER to the PayloadBuf of IKE_PACKET.\r
-\r
- @param[in] Netbuf The pointer of the Netbuf which contains the whole received\r
- IKE packet.\r
-\r
- @return The pointer of the IKE_PACKET which contains the received packet.\r
-\r
-**/\r
-IKE_PACKET *\r
-IkePacketFromNetbuf (\r
- IN NET_BUF *Netbuf\r
- );\r
-\r
-/**\r
- Convert the format from IKE_PACKET to NetBuf.\r
-\r
- @param[in] SessionCommon Pointer of related IKE_COMMON_SESSION\r
- @param[in] IkePacket Pointer of IKE_PACKET to be copy to NetBuf\r
- @param[in] IkeType The IKE type to pointer the packet is for which IKE\r
- phase. Now it supports IKE_SA_TYPE, IKE_CHILDSA_TYPE,\r
- IKE_INFO_TYPE.\r
-\r
- @return A pointer of Netbuff which contains the contents of the IKE_PACKE in network order.\r
-**/\r
-NET_BUF *\r
-IkeNetbufFromPacket (\r
- IN UINT8 *SessionCommon,\r
- IN IKE_PACKET *IkePacket,\r
- IN UINTN IkeType\r
- );\r
-\r
-#endif\r