VirtualBox

source: vbox/trunk/src/VBox/Devices/EFI/FirmwareNew/MdePkg/Include/Protocol/EapConfiguration.h@ 77662

最後變更 在這個檔案從77662是 77662,由 vboxsync 提交於 6 年 前

EFI: First step in UDK2018 merge. Does not build yet.

  • 屬性 svn:eol-style 設為 native
檔案大小: 5.3 KB
 
1/** @file
2 This file defines the EFI EAP Configuration protocol.
3
4 Copyright (c) 2015, Intel Corporation. All rights reserved.<BR>
5 This program and the accompanying materials
6 are licensed and made available under the terms and conditions of the BSD License
7 which accompanies this distribution. The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php
9
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
12
13 @par Revision Reference:
14 This Protocol is introduced in UEFI Specification 2.5
15
16**/
17
18#ifndef __EFI_EAP_CONFIGURATION_PROTOCOL_H__
19#define __EFI_EAP_CONFIGURATION_PROTOCOL_H__
20
21///
22/// EFI EAP Configuration protocol provides a way to set and get EAP configuration.
23///
24#define EFI_EAP_CONFIGURATION_PROTOCOL_GUID \
25 { \
26 0xe5b58dbb, 0x7688, 0x44b4, {0x97, 0xbf, 0x5f, 0x1d, 0x4b, 0x7c, 0xc8, 0xdb } \
27 }
28
29typedef struct _EFI_EAP_CONFIGURATION_PROTOCOL EFI_EAP_CONFIGURATION_PROTOCOL;
30
31///
32/// Make sure it not conflict with any real EapTypeXXX
33///
34#define EFI_EAP_TYPE_ATTRIBUTE 0
35
36typedef enum {
37 ///
38 /// EFI_EAP_TYPE_ATTRIBUTE
39 ///
40 EfiEapConfigEapAuthMethod,
41 EfiEapConfigEapSupportedAuthMethod,
42 ///
43 /// EapTypeIdentity
44 ///
45 EfiEapConfigIdentityString,
46 ///
47 /// EapTypeEAPTLS/EapTypePEAP
48 ///
49 EfiEapConfigEapTlsCACert,
50 EfiEapConfigEapTlsClientCert,
51 EfiEapConfigEapTlsClientPrivateKeyFile,
52 EfiEapConfigEapTlsClientPrivateKeyFilePassword, // ASCII format, Volatile
53 EfiEapConfigEapTlsCipherSuite,
54 EfiEapConfigEapTlsSupportedCipherSuite,
55 ///
56 /// EapTypeMSChapV2
57 ///
58 EfiEapConfigEapMSChapV2Password, // UNICODE format, Volatile
59 ///
60 /// EapTypePEAP
61 ///
62 EfiEapConfigEap2ndAuthMethod,
63 ///
64 /// More...
65 ///
66} EFI_EAP_CONFIG_DATA_TYPE;
67
68///
69/// EFI_EAP_TYPE
70///
71typedef UINT8 EFI_EAP_TYPE;
72#define EFI_EAP_TYPE_ATTRIBUTE 0
73#define EFI_EAP_TYPE_IDENTITY 1
74#define EFI_EAP_TYPE_NOTIFICATION 2
75#define EFI_EAP_TYPE_NAK 3
76#define EFI_EAP_TYPE_MD5CHALLENGE 4
77#define EFI_EAP_TYPE_OTP 5
78#define EFI_EAP_TYPE_GTC 6
79#define EFI_EAP_TYPE_EAPTLS 13
80#define EFI_EAP_TYPE_EAPSIM 18
81#define EFI_EAP_TYPE_TTLS 21
82#define EFI_EAP_TYPE_PEAP 25
83#define EFI_EAP_TYPE_MSCHAPV2 26
84#define EFI_EAP_TYPE_EAP_EXTENSION 33
85
86/**
87 Set EAP configuration data.
88
89 The SetData() function sets EAP configuration to non-volatile storage or volatile
90 storage.
91
92 @param[in] This Pointer to the EFI_EAP_CONFIGURATION_PROTOCOL instance.
93 @param[in] EapType EAP type.
94 @param[in] DataType Configuration data type.
95 @param[in] Data Pointer to configuration data.
96 @param[in] DataSize Total size of configuration data.
97
98 @retval EFI_SUCCESS The EAP configuration data is set successfully.
99 @retval EFI_INVALID_PARAMETER One or more of the following conditions is TRUE:
100 Data is NULL.
101 DataSize is 0.
102 @retval EFI_UNSUPPORTED The EapType or DataType is unsupported.
103 @retval EFI_OUT_OF_RESOURCES Required system resources could not be allocated.
104**/
105typedef
106EFI_STATUS
107(EFIAPI *EFI_EAP_CONFIGURATION_SET_DATA) (
108 IN EFI_EAP_CONFIGURATION_PROTOCOL *This,
109 IN EFI_EAP_TYPE EapType,
110 IN EFI_EAP_CONFIG_DATA_TYPE DataType,
111 IN VOID *Data,
112 IN UINTN DataSize
113 );
114
115/**
116 Get EAP configuration data.
117
118 The GetData() function gets EAP configuration.
119
120 @param[in] This Pointer to the EFI_EAP_CONFIGURATION_PROTOCOL instance.
121 @param[in] EapType EAP type.
122 @param[in] DataType Configuration data type.
123 @param[in, out] Data Pointer to configuration data.
124 @param[in, out] DataSize Total size of configuration data. On input, it means
125 the size of Data buffer. On output, it means the size
126 of copied Data buffer if EFI_SUCCESS, and means the
127 size of desired Data buffer if EFI_BUFFER_TOO_SMALL.
128
129 @retval EFI_SUCCESS The EAP configuration data is got successfully.
130 @retval EFI_INVALID_PARAMETER One or more of the following conditions is TRUE:
131 Data is NULL.
132 DataSize is NULL.
133 @retval EFI_UNSUPPORTED The EapType or DataType is unsupported.
134 @retval EFI_NOT_FOUND The EAP configuration data is not found.
135 @retval EFI_BUFFER_TOO_SMALL The buffer is too small to hold the buffer.
136**/
137typedef
138EFI_STATUS
139(EFIAPI *EFI_EAP_CONFIGURATION_GET_DATA) (
140 IN EFI_EAP_CONFIGURATION_PROTOCOL *This,
141 IN EFI_EAP_TYPE EapType,
142 IN EFI_EAP_CONFIG_DATA_TYPE DataType,
143 IN OUT VOID *Data,
144 IN OUT UINTN *DataSize
145 );
146
147///
148/// The EFI_EAP_CONFIGURATION_PROTOCOL
149/// is designed to provide a way to set and get EAP configuration, such as Certificate,
150/// private key file.
151///
152struct _EFI_EAP_CONFIGURATION_PROTOCOL {
153 EFI_EAP_CONFIGURATION_SET_DATA SetData;
154 EFI_EAP_CONFIGURATION_GET_DATA GetData;
155};
156
157extern EFI_GUID gEfiEapConfigurationProtocolGuid;
158
159#endif
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette