]>
Commit | Line | Data |
---|---|---|
2832b228 | 1 | /** @file\r |
2 | UEFI 2.2 User Credential Protocol definition.\r | |
3 | \r | |
4 | Attached to a device handle, this protocol identifies a single means of identifying the user.\r | |
5 | \r | |
6 | Copyright (c) 2009, Intel Corporation \r | |
7 | All rights reserved. This program and the accompanying materials \r | |
8 | are licensed and made available under the terms and conditions of the BSD License \r | |
9 | which accompanies this distribution. The full text of the license may be found at \r | |
10 | http://opensource.org/licenses/bsd-license.php \r | |
11 | \r | |
12 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r | |
13 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r | |
14 | \r | |
15 | **/\r | |
16 | \r | |
17 | #ifndef __USER_CREDENTIAL_H__\r | |
18 | #define __USER_CREDENTIAL_H__\r | |
19 | \r | |
20 | #define EFI_USER_CREDENTIAL_PROTOCOL_GUID \\r | |
21 | { \\r | |
22 | 0x71ee5e94, 0x65b9, 0x45d5, { 0x82, 0x1a, 0x3a, 0x4d, 0x86, 0xcf, 0xe6, 0xbe } \\r | |
23 | }\r | |
24 | \r | |
25 | typedef VOID *EFI_USER_PROFILE_HANDLE;\r | |
26 | typedef VOID *EFI_USER_INFO_HANDLE;\r | |
27 | \r | |
28 | ///\r | |
29 | /// The attributes of the user profile information.\r | |
30 | ///\r | |
31 | typedef UINT16 EFI_USER_INFO_ATTRIBS;\r | |
32 | #define EFI_USER_INFO_STORAGE 0x000F\r | |
33 | #define EFI_USER_INFO_STORAGE_VOLATILE 0x0000\r | |
34 | #define EFI_USER_INFO_STORAGE_CREDENTIAL_NV 0x0001\r | |
35 | #define EFI_USER_INFO_STORAGE_PLATFORM_NV 0x0002\r | |
36 | \r | |
37 | #define EFI_USER_INFO_ACCESS 0x0070\r | |
38 | #define EFI_USER_INFO_PUBLIC 0x0010\r | |
39 | #define EFI_USER_INFO_PRIVATE 0x0020\r | |
40 | #define EFI_USER_INFO_PROTECTED 0x0030\r | |
41 | #define EFI_USER_INFO_EXCLUSIVE 0x0080\r | |
42 | \r | |
43 | ///\r | |
16c5446f | 44 | /// User information structure\r |
2832b228 | 45 | ///\r |
46 | typedef struct {\r | |
47 | ///\r | |
48 | /// The user credential identifier associated with this user information or else Nil if the \r | |
49 | /// information is not associated with any specific credential.\r | |
50 | ///\r | |
51 | EFI_GUID Credential;\r | |
52 | ///\r | |
53 | /// The type of user information.\r | |
54 | ///\r | |
55 | UINT8 InfoType;\r | |
56 | ///\r | |
57 | /// Must be set to 0.\r | |
58 | ///\r | |
59 | UINT8 Reserved1;\r | |
60 | ///\r | |
61 | /// The attributes of the user profile information.\r | |
62 | ///\r | |
63 | EFI_USER_INFO_ATTRIBS InfoAttribs;\r | |
64 | ///\r | |
65 | /// The size of the user information, in bytes, including this header.\r | |
66 | ///\r | |
67 | UINT32 InfoSize;\r | |
68 | } EFI_USER_INFO;\r | |
69 | \r | |
70 | ///\r | |
71 | /// User credential class GUIDs\r | |
72 | ///\r | |
73 | #define EFI_USER_CREDENTIAL_CLASS_UNKNOWN \\r | |
74 | { 0x5cf32e68, 0x7660, 0x449b, { 0x80, 0xe6, 0x7e, 0xa3, 0x6e, 0x3, 0xf6, 0xa8 } }\r | |
75 | #define EFI_USER_CREDENTIAL_CLASS_PASSWORD \\r | |
76 | { 0xf8e5058c, 0xccb6, 0x4714, { 0xb2, 0x20, 0x3f, 0x7e, 0x3a, 0x64, 0xb, 0xd1 } }\r | |
77 | #define EFI_USER_CREDENTIAL_CLASS_SMART_CARD \\r | |
78 | { 0x5f03ba33, 0x8c6b, 0x4c24, { 0xaa, 0x2e, 0x14, 0xa2, 0x65, 0x7b, 0xd4, 0x54 } }\r | |
79 | #define EFI_USER_CREDENTIAL_CLASS_FINGERPRINT \\r | |
80 | { 0x32cba21f, 0xf308, 0x4cbc, { 0x9a, 0xb5, 0xf5, 0xa3, 0x69, 0x9f, 0x4, 0x4a } }\r | |
81 | #define EFI_USER_CREDENTIAL_CLASS_HANDPRINT \\r | |
82 | { 0x5917ef16, 0xf723, 0x4bb9, { 0xa6, 0x4b, 0xd8, 0xc5, 0x32, 0xf4, 0xd8, 0xb5 } }\r | |
83 | #define EFI_USER_CREDENTIAL_CLASS_SECURE_CARD \\r | |
84 | { 0x8a6b4a83, 0x42fe, 0x45d2, { 0xa2, 0xef, 0x46, 0xf0, 0x6c, 0x7d, 0x98, 0x52 } }\r | |
85 | \r | |
86 | typedef UINT64 EFI_CREDENTIAL_CAPABILITIES;\r | |
87 | #define EFI_CREDENTIAL_CAPABILITIES_ENROLL 0x0000000000000001\r | |
88 | \r | |
89 | ///\r | |
90 | /// Credential logon flags \r | |
91 | ///\r | |
92 | typedef UINT32 EFI_CREDENTIAL_LOGON_FLAGS;\r | |
93 | #define EFI_CREDENTIAL_LOGON_FLAG_AUTO 0x00000001\r | |
94 | #define EFI_CREDENTIAL_LOGON_FLAG_DEFAULT 0x00000002\r | |
95 | \r | |
96 | ///\r | |
97 | /// User information record types\r | |
98 | ///\r | |
99 | \r | |
100 | ///\r | |
101 | /// No information.\r | |
102 | ///\r | |
103 | #define EFI_USER_INFO_EMPTY_RECORD 0x00\r | |
104 | ///\r | |
105 | /// Provide the user's name for the enrolled user.\r | |
106 | ///\r | |
107 | #define EFI_USER_INFO_NAME_RECORD 0x01\r | |
108 | typedef CHAR16 *EFI_USER_INFO_NAME;\r | |
109 | ///\r | |
110 | /// Provides the date and time when the user profile was created.\r | |
111 | ///\r | |
112 | #define EFI_USER_INFO_CREATE_DATE_RECORD 0x02\r | |
113 | typedef EFI_TIME EFI_USER_INFO_CREATE_DATE;\r | |
114 | ///\r | |
115 | /// Provides the date and time when the user profile was selected.\r | |
116 | ///\r | |
117 | #define EFI_USER_INFO_USAGE_DATE_RECORD 0x03\r | |
118 | typedef EFI_TIME EFI_USER_INFO_USAGE_DATE;\r | |
119 | ///\r | |
120 | /// Provides the number of times that the user profile has been selected.\r | |
121 | ///\r | |
122 | #define EFI_USER_INFO_USAGE_COUNT_RECORD 0x04\r | |
123 | typedef UINT64 EFI_USER_INFO_USAGE_COUNT;\r | |
124 | ///\r | |
125 | /// Provides a unique non-volatile user identifier for each enrolled user.\r | |
126 | ///\r | |
127 | #define EFI_USER_INFO_IDENTIFIER_RECORD 0x05\r | |
128 | typedef UINT8 EFI_USER_INFO_IDENTIFIER[16];\r | |
129 | ///\r | |
130 | /// Specifies the type of a particular credential associated with the user profile.\r | |
131 | ///\r | |
132 | #define EFI_USER_INFO_CREDENTIAL_TYPE_RECORD 0x06\r | |
133 | typedef EFI_GUID EFI_USER_INFO_CREDENTIAL_TYPE;\r | |
134 | ///\r | |
135 | /// Specifies the user-readable name of a particular credential type.\r | |
136 | ///\r | |
137 | #define EFI_USER_INFO_CREDENTIAL_TYPE_NAME_RECORD 0x07\r | |
138 | typedef CHAR16 *EFI_USER_INFO_CREDENTIAL_TYPE_NAME;\r | |
139 | ///\r | |
140 | /// Specifies the credential provider.\r | |
141 | ///\r | |
142 | #define EFI_USER_INFO_CREDENTIAL_PROVIDER_RECORD 0x08\r | |
143 | typedef EFI_GUID EFI_USER_INFO_CREDENTIAL_PROVIDER;\r | |
144 | ///\r | |
145 | /// Specifies the user-readable name of a particular credential's provider.\r | |
146 | ///\r | |
147 | #define EFI_USER_INFO_CREDENTIAL_PROVIDER_NAME_RECORD 0x09\r | |
148 | typedef CHAR16 *EFI_USER_INFO_CREDENTIAL_PROVIDER_NAME;\r | |
149 | ///\r | |
150 | /// Provides PKCS#11 credential information from a smart card.\r | |
151 | ///\r | |
152 | #define EFI_USER_INFO_PKCS11_RECORD 0x0A\r | |
153 | ///\r | |
154 | /// Provides standard biometric information in the format specified by the ISO 19785 (Common \r | |
155 | /// Biometric Exchange Formats Framework) specification.\r | |
156 | ///\r | |
157 | #define EFI_USER_INFO_CBEFF_RECORD 0x0B\r | |
158 | typedef VOID *EFI_USER_INFO_CBEFF;\r | |
159 | ///\r | |
160 | /// Indicates how close of a match the fingerprint must be in order to be considered a match.\r | |
161 | ///\r | |
162 | #define EFI_USER_INFO_FAR_RECORD 0x0C\r | |
163 | typedef UINT8 EFI_USER_INFO_FAR;\r | |
164 | ///\r | |
165 | /// Indicates how many attempts the user has to with a particular credential before the system prevents \r | |
166 | /// further attempts.\r | |
167 | ///\r | |
168 | #define EFI_USER_INFO_RETRY_RECORD 0x0D\r | |
169 | typedef UINT8 EFI_USER_INFO_RETRY;\r | |
170 | ///\r | |
171 | /// Provides the user's pre-OS access rights.\r | |
172 | ///\r | |
173 | #define EFI_USER_INFO_ACCESS_POLICY_RECORD 0x0E\r | |
174 | \r | |
175 | typedef struct {\r | |
176 | UINT32 Type; ///< Specifies the type of user access control.\r | |
177 | UINT32 Size; ///< Specifies the size of the user access control record, in bytes, including this header.\r | |
178 | } EFI_USER_INFO_ACCESS_CONTROL;\r | |
179 | \r | |
180 | typedef EFI_USER_INFO_ACCESS_CONTROL EFI_USER_INFO_ACCESS_POLICY;\r | |
181 | \r | |
182 | ///\r | |
183 | /// User Information access types\r | |
184 | ///\r | |
185 | \r | |
186 | ///\r | |
187 | /// Forbids the user from booting or loading executables from the specified device path or any child \r | |
188 | /// device paths.\r | |
189 | ///\r | |
190 | #define EFI_USER_INFO_ACCESS_FORBID_LOAD 0x00000001\r | |
191 | ///\r | |
2832b228 | 192 | /// Permits the user from booting or loading executables from the specified device path or any child \r |
193 | /// device paths.\r | |
ea4220e3 | 194 | /// Note: in-consistency between code and the UEFI 2.3 specification here.\r |
195 | /// The definition EFI_USER_INFO_ACCESS_PERMIT_BOOT in the specification should be typo and wait for\r | |
196 | /// spec update.\r | |
2832b228 | 197 | ///\r |
198 | #define EFI_USER_INFO_ACCESS_PERMIT_LOAD 0x00000002\r | |
199 | ///\r | |
200 | /// Presence of this record indicates that a user can update enrollment information.\r | |
201 | ///\r | |
202 | #define EFI_USER_INFO_ACCESS_ENROLL_SELF 0x00000003\r | |
203 | ///\r | |
204 | /// Presence of this record indicates that a user can enroll new users.\r | |
205 | ///\r | |
206 | #define EFI_USER_INFO_ACCESS_ENROLL_OTHERS 0x00000004\r | |
207 | ///\r | |
208 | /// Presence of this record indicates that a user can update the user information of any user.\r | |
209 | ///\r | |
210 | #define EFI_USER_INFO_ACCESS_MANAGE 0x00000005\r | |
211 | ///\r | |
212 | /// Describes permissions usable when configuring the platform.\r | |
213 | ///\r | |
214 | #define EFI_USER_INFO_ACCESS_SETUP 0x00000006\r | |
215 | ///\r | |
216 | /// Standard GUIDs for access to configure the platform.\r | |
217 | ///\r | |
218 | #define EFI_USER_INFO_ACCESS_SETUP_ADMIN_GUID \\r | |
219 | { 0x85b75607, 0xf7ce, 0x471e, { 0xb7, 0xe4, 0x2a, 0xea, 0x5f, 0x72, 0x32, 0xee } }\r | |
220 | #define EFI_USER_INFO_ACCESS_SETUP_NORMAL_GUID \\r | |
221 | { 0x1db29ae0, 0x9dcb, 0x43bc, { 0x8d, 0x87, 0x5d, 0xa1, 0x49, 0x64, 0xdd, 0xe2 } }\r | |
222 | #define EFI_USER_INFO_ACCESS_SETUP_RESTRICTED_GUID \\r | |
223 | { 0xbdb38125, 0x4d63, 0x49f4, { 0x82, 0x12, 0x61, 0xcf, 0x5a, 0x19, 0xa, 0xf8 } }\r | |
224 | \r | |
225 | ///\r | |
226 | /// Forbids UEFI drivers from being started from the specified device path(s) or any child device paths.\r | |
227 | ///\r | |
228 | #define EFI_USER_INFO_ACCESS_FORBID_CONNECT 0x00000007\r | |
229 | ///\r | |
230 | /// Permits UEFI drivers to be started on the specified device path(s) or any child device paths.\r | |
231 | ///\r | |
232 | #define EFI_USER_INFO_ACCESS_PERMIT_CONNECT 0x00000008\r | |
233 | ///\r | |
234 | /// Modifies the boot order.\r | |
235 | ///\r | |
236 | #define EFI_USER_INFO_ACCESS_BOOT_ORDER 0x00000009\r | |
237 | typedef UINT32 EFI_USER_INFO_ACCESS_BOOT_ORDER_HDR;\r | |
238 | \r | |
239 | #define EFI_USER_INFO_ACCESS_BOOT_ORDER_MASK 0x0000000F\r | |
240 | ///\r | |
241 | /// Insert new boot options at the beginning of the boot order.\r | |
242 | ///\r | |
243 | #define EFI_USER_INFO_ACCESS_BOOT_ORDER_INSERT 0x00000000\r | |
244 | ///\r | |
245 | /// Append new boot options to the end of the boot order.\r | |
246 | ///\r | |
247 | #define EFI_USER_INFO_ACCESS_BOOT_ORDER_APPEND 0x00000001\r | |
248 | ///\r | |
249 | /// Replace the entire boot order.\r | |
250 | ///\r | |
251 | #define EFI_USER_INFO_ACCESS_BOOT_ORDER_REPLACE 0x00000002\r | |
252 | ///\r | |
253 | /// The Boot Manager will not attempt find a default boot device \r | |
254 | /// when the default boot order is does not lead to a bootable device.\r | |
255 | ///\r | |
256 | #define EFI_USER_INFO_ACCESS_BOOT_ORDER_NODEFAULT 0x00000010\r | |
257 | \r | |
258 | ///\r | |
259 | /// Provides the expression which determines which credentials are required to assert user identity.\r | |
260 | ///\r | |
261 | #define EFI_USER_INFO_IDENTITY_POLICY_RECORD 0x0F\r | |
262 | \r | |
263 | typedef struct {\r | |
264 | UINT32 Type; ///< Specifies either an operator or a data item. \r | |
265 | UINT32 Length; ///< The length of this block, in bytes, including this header.\r | |
266 | } EFI_USER_INFO_IDENTITY_POLICY;\r | |
267 | \r | |
268 | ///\r | |
269 | /// User identity policy expression operators.\r | |
270 | ///\r | |
271 | #define EFI_USER_INFO_IDENTITY_FALSE 0x00\r | |
272 | #define EFI_USER_INFO_IDENTITY_TRUE 0x01\r | |
273 | #define EFI_USER_INFO_IDENTITY_CREDENTIAL_TYPE 0x02\r | |
274 | #define EFI_USER_INFO_IDENTITY_CREDENTIAL_PROVIDER 0x03\r | |
275 | #define EFI_USER_INFO_IDENTITY_NOT 0x10\r | |
276 | #define EFI_USER_INFO_IDENTITY_AND 0x11\r | |
277 | #define EFI_USER_INFO_IDENTITY_OR 0x12\r | |
278 | \r | |
279 | ///\r | |
280 | /// Provides placeholder for additional user profile information identified by a GUID.\r | |
281 | ///\r | |
282 | #define EFI_USER_INFO_GUID_RECORD 0xFF\r | |
283 | typedef EFI_GUID EFI_USER_INFO_GUID;\r | |
284 | \r | |
285 | ///\r | |
286 | /// User information table\r | |
287 | /// A collection of EFI_USER_INFO records, prefixed with this header.\r | |
288 | ///\r | |
289 | typedef struct {\r | |
290 | UINT64 Size; ///< Total size of the user information table, in bytes.\r | |
291 | } EFI_USER_INFO_TABLE;\r | |
292 | \r | |
293 | typedef struct _EFI_USER_CREDENTIAL_PROTOCOL EFI_USER_CREDENTIAL_PROTOCOL;\r | |
294 | \r | |
295 | /**\r | |
296 | Enroll a user on a credential provider.\r | |
297 | \r | |
298 | This function enrolls a user profile using this credential provider. If a user profile is successfully \r | |
299 | enrolled, it calls the User Manager Protocol function Notify() to notify the user manager driver \r | |
300 | that credential information has changed.\r | |
301 | \r | |
302 | @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL.\r | |
303 | @param[in] User The user profile to enroll.\r | |
304 | \r | |
305 | @retval EFI_SUCCESS User profile was successfully enrolled.\r | |
306 | @retval EFI_ACCESS_DENIED Current user profile does not permit enrollment on the user profile \r | |
307 | handle. Either the user profile cannot enroll on any user profile or \r | |
308 | cannot enroll on a user profile other than the current user profile.\r | |
309 | @retval EFI_UNSUPPORTED This credential provider does not support enrollment in the pre-OS.\r | |
310 | @retval EFI_DEVICE_ERROR The new credential could not be created because of a device error.\r | |
311 | @retval EFI_INVALID_PARAMETER User does not refer to a valid user profile handle.\r | |
312 | **/\r | |
313 | typedef\r | |
314 | EFI_STATUS\r | |
315 | (EFIAPI *EFI_CREDENTIAL_ENROLL)(\r | |
316 | IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This,\r | |
317 | IN EFI_USER_PROFILE_HANDLE User\r | |
318 | );\r | |
319 | \r | |
320 | /**\r | |
321 | Returns the user interface information used during user identification.\r | |
322 | \r | |
323 | This function returns information about the form used when interacting with the user during user \r | |
324 | identification. The form is the first enabled form in the form-set class \r | |
325 | EFI_HII_USER_CREDENTIAL_FORMSET_GUID installed on the HII handle HiiHandle. If \r | |
326 | the user credential provider does not require a form to identify the user, then this function should \r | |
327 | return EFI_NOT_FOUND.\r | |
328 | \r | |
329 | @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL.\r | |
330 | @param[out] Hii On return, holds the HII database handle.\r | |
331 | @param[out] FormSetId On return, holds the identifier of the form set which contains\r | |
332 | the form used during user identification.\r | |
333 | @param[out] FormId On return, holds the identifier of the form used during user identification.\r | |
334 | \r | |
335 | @retval EFI_SUCCESS Form returned successfully.\r | |
336 | @retval EFI_NOT_FOUND Form not returned.\r | |
337 | **/\r | |
338 | typedef\r | |
339 | EFI_STATUS\r | |
340 | (EFIAPI *EFI_CREDENTIAL_FORM)(\r | |
341 | IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This,\r | |
342 | OUT EFI_HII_HANDLE *Hii,\r | |
343 | OUT EFI_GUID *FormSetId,\r | |
344 | OUT EFI_FORM_ID *FormId\r | |
345 | );\r | |
346 | \r | |
347 | /**\r | |
348 | Returns bitmap used to describe the credential provider type.\r | |
349 | \r | |
350 | This optional function returns a bitmap which is less than or equal to the number of pixels specified \r | |
351 | by Width and Height. If no such bitmap exists, then EFI_NOT_FOUND is returned. \r | |
352 | \r | |
353 | @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL.\r | |
354 | @param[in,out] Width On entry, points to the desired bitmap width. If NULL then no bitmap information will \r | |
355 | be returned. On exit, points to the width of the bitmap returned.\r | |
356 | @param[in,out] Height On entry, points to the desired bitmap height. If NULL then no bitmap information will \r | |
357 | be returned. On exit, points to the height of the bitmap returned\r | |
358 | @param[out] Hii On return, holds the HII database handle. \r | |
359 | @param[out] Image On return, holds the HII image identifier. \r | |
360 | \r | |
361 | @retval EFI_SUCCESS Image identifier returned successfully.\r | |
362 | @retval EFI_NOT_FOUND Image identifier not returned.\r | |
363 | **/\r | |
364 | typedef\r | |
365 | EFI_STATUS\r | |
366 | (EFIAPI *EFI_CREDENTIAL_TILE)(\r | |
367 | IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This,\r | |
368 | IN OUT UINTN *Width,\r | |
369 | IN OUT UINTN *Height,\r | |
370 | OUT EFI_HII_HANDLE *Hii,\r | |
371 | OUT EFI_IMAGE_ID *Image\r | |
372 | );\r | |
373 | \r | |
374 | /**\r | |
375 | Returns string used to describe the credential provider type.\r | |
376 | \r | |
377 | This function returns a string which describes the credential provider. If no such string exists, then \r | |
378 | EFI_NOT_FOUND is returned. \r | |
379 | \r | |
380 | @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL.\r | |
381 | @param[out] Hii On return, holds the HII database handle.\r | |
382 | @param[out] String On return, holds the HII string identifier.\r | |
383 | \r | |
384 | @retval EFI_SUCCESS String identifier returned successfully.\r | |
385 | @retval EFI_NOT_FOUND String identifier not returned.\r | |
386 | **/\r | |
387 | typedef\r | |
388 | EFI_STATUS\r | |
389 | (EFIAPI *EFI_CREDENTIAL_TITLE)(\r | |
390 | IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This,\r | |
391 | OUT EFI_HII_HANDLE *Hii,\r | |
392 | OUT EFI_STRING_ID *String\r | |
393 | );\r | |
394 | \r | |
395 | /**\r | |
396 | Return the user identifier associated with the currently authenticated user.\r | |
397 | \r | |
398 | This function returns the user identifier of the user authenticated by this credential provider. This \r | |
399 | function is called after the credential-related information has been submitted on a form OR after a \r | |
400 | call to Default() has returned that this credential is ready to log on.\r | |
401 | \r | |
402 | @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL.\r | |
403 | @param[in] User The user profile handle of the user profile currently being considered by the user \r | |
404 | identity manager. If NULL, then no user profile is currently under consideration.\r | |
405 | @param[out] Identifier On return, points to the user identifier. \r | |
406 | \r | |
407 | @retval EFI_SUCCESS User identifier returned successfully.\r | |
408 | @retval EFI_NOT_READY No user identifier can be returned.\r | |
409 | @retval EFI_ACCESS_DENIED The user has been locked out of this user credential.\r | |
410 | **/\r | |
411 | typedef\r | |
412 | EFI_STATUS\r | |
413 | (EFIAPI *EFI_CREDENTIAL_USER)(\r | |
414 | IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This,\r | |
415 | IN EFI_USER_PROFILE_HANDLE User,\r | |
416 | OUT EFI_USER_INFO_IDENTIFIER *Identifier\r | |
417 | );\r | |
418 | \r | |
419 | /**\r | |
420 | Indicate that user interface interaction has begun for the specified credential.\r | |
421 | \r | |
422 | This function is called when a credential provider is selected by the user. If AutoLogon returns \r | |
423 | FALSE, then the user interface will be constructed by the User Identity Manager. \r | |
424 | \r | |
425 | @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL.\r | |
426 | @param[out] AutoLogon On return, points to the credential provider's capabilities after the credential provider \r | |
427 | has been selected by the user. \r | |
428 | \r | |
429 | @retval EFI_SUCCESS Credential provider successfully selected.\r | |
430 | **/\r | |
431 | typedef\r | |
432 | EFI_STATUS\r | |
433 | (EFIAPI *EFI_CREDENTIAL_SELECT)(\r | |
434 | IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This,\r | |
435 | OUT EFI_CREDENTIAL_LOGON_FLAGS *AutoLogon\r | |
436 | ); \r | |
437 | \r | |
438 | /**\r | |
439 | Indicate that user interface interaction has ended for the specified credential.\r | |
440 | \r | |
441 | This function is called when a credential provider is deselected by the user.\r | |
442 | \r | |
443 | @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL.\r | |
444 | \r | |
445 | @retval EFI_SUCCESS Credential provider successfully deselected.\r | |
446 | **/\r | |
447 | typedef\r | |
448 | EFI_STATUS\r | |
449 | (EFIAPI *EFI_CREDENTIAL_DESELECT)(\r | |
450 | IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This\r | |
451 | );\r | |
452 | \r | |
453 | /**\r | |
454 | Return the default logon behavior for this user credential.\r | |
455 | \r | |
456 | This function reports the default login behavior regarding this credential provider. \r | |
457 | \r | |
458 | @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL.\r | |
459 | @param[out] AutoLogon On return, holds whether the credential provider should be used by default to \r | |
460 | automatically log on the user. \r | |
461 | \r | |
462 | @retval EFI_SUCCESS Default information successfully returned.\r | |
463 | **/\r | |
464 | typedef \r | |
465 | EFI_STATUS\r | |
466 | (EFIAPI *EFI_CREDENTIAL_DEFAULT)(\r | |
467 | IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This,\r | |
468 | OUT EFI_CREDENTIAL_LOGON_FLAGS *AutoLogon\r | |
469 | );\r | |
470 | \r | |
471 | /**\r | |
472 | Return information attached to the credential provider.\r | |
473 | \r | |
474 | This function returns user information. \r | |
475 | \r | |
476 | @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL.\r | |
477 | @param[in] UserInfo Handle of the user information data record. \r | |
478 | @param[out] Info On entry, points to a buffer of at least *InfoSize bytes. On exit, holds the user \r | |
479 | information. If the buffer is too small to hold the information, then \r | |
480 | EFI_BUFFER_TOO_SMALL is returned and InfoSize is updated to contain the \r | |
481 | number of bytes actually required.\r | |
482 | @param[in,out] InfoSize On entry, points to the size of Info. On return, points to the size of the user \r | |
483 | information. \r | |
484 | \r | |
485 | @retval EFI_SUCCESS Information returned successfully.\r | |
486 | @retval EFI_ACCESS_DENIED The information about the specified user cannot be accessed by the \r | |
487 | current user.\r | |
488 | @retval EFI_BUFFER_TOO_SMALL The size specified by InfoSize is too small to hold all of the user \r | |
489 | information. The size required is returned in *InfoSize.\r | |
490 | **/\r | |
491 | typedef\r | |
492 | EFI_STATUS\r | |
493 | (EFIAPI *EFI_CREDENTIAL_GET_INFO)(\r | |
494 | IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This,\r | |
495 | IN EFI_USER_INFO_HANDLE UserInfo,\r | |
496 | OUT EFI_USER_INFO *Info,\r | |
497 | IN OUT UINTN *InfoSize\r | |
498 | );\r | |
499 | \r | |
500 | /**\r | |
501 | Enumerate all of the enrolled users on the platform.\r | |
502 | \r | |
503 | This function returns the next user information record. To retrieve the first user information record \r | |
504 | handle, point UserInfo at a NULL. Each subsequent call will retrieve another user information \r | |
505 | record handle until there are no more, at which point UserInfo will point to NULL. \r | |
506 | \r | |
507 | @param[in] This Points to this instance of the EFI_USER_CREDENTIAL_PROTOCOL.\r | |
508 | @param[in,out] UserInfo On entry, points to the previous user information handle or NULL to start \r | |
509 | enumeration. On exit, points to the next user information handle or NULL if there is \r | |
510 | no more user information.\r | |
511 | \r | |
512 | @retval EFI_SUCCESS User information returned.\r | |
513 | @retval EFI_NOT_FOUND No more user information found.\r | |
514 | **/\r | |
515 | typedef\r | |
516 | EFI_STATUS\r | |
517 | (EFIAPI *EFI_CREDENTIAL_GET_NEXT_INFO)(\r | |
518 | IN CONST EFI_USER_CREDENTIAL_PROTOCOL *This,\r | |
519 | IN OUT EFI_USER_INFO_HANDLE *UserInfo\r | |
520 | );\r | |
521 | \r | |
522 | ///\r | |
523 | /// This protocol provides support for a single class of credentials\r | |
524 | ///\r | |
525 | struct _EFI_USER_CREDENTIAL_PROTOCOL {\r | |
526 | EFI_GUID Identifier; ///< Uniquely identifies this credential provider.\r | |
527 | EFI_GUID Type; ///< Identifies this class of User Credential Provider.\r | |
528 | EFI_CREDENTIAL_ENROLL Enroll;\r | |
529 | EFI_CREDENTIAL_FORM Form;\r | |
530 | EFI_CREDENTIAL_TILE Tile;\r | |
531 | EFI_CREDENTIAL_TITLE Title;\r | |
532 | EFI_CREDENTIAL_USER User;\r | |
533 | EFI_CREDENTIAL_SELECT Select; \r | |
534 | EFI_CREDENTIAL_DESELECT Deselect;\r | |
535 | EFI_CREDENTIAL_DEFAULT Default;\r | |
536 | EFI_CREDENTIAL_GET_INFO GetInfo;\r | |
537 | EFI_CREDENTIAL_GET_NEXT_INFO GetNextInfo;\r | |
538 | EFI_CREDENTIAL_CAPABILITIES Capabilities;\r | |
539 | };\r | |
540 | \r | |
541 | extern EFI_GUID gEfiUserCredentialProtocolGuid;\r | |
542 | \r | |
543 | #endif\r |