]> git.proxmox.com Git - mirror_edk2.git/blame - SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigImpl.h
Update all the code to consume the ConvertDevicePathToText, ConvertDevicePathNodeToTe...
[mirror_edk2.git] / SecurityPkg / VariableAuthenticated / SecureBootConfigDxe / SecureBootConfigImpl.h
CommitLineData
beda2356 1/** @file\r
2 The header file of HII Config Access protocol implementation of SecureBoot\r
3 configuration module.\r
4\r
ecc722ad 5Copyright (c) 2011 - 2012, Intel Corporation. All rights reserved.<BR>\r
bc0c99b3 6This program and the accompanying materials\r
7are licensed and made available under the terms and conditions of the BSD License\r
8which accompanies this distribution. The full text of the license may be found at\r
beda2356 9http://opensource.org/licenses/bsd-license.php\r
10\r
bc0c99b3 11THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
beda2356 12WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
13\r
14**/\r
15\r
16#ifndef __SECUREBOOT_CONFIG_IMPL_H__\r
17#define __SECUREBOOT_CONFIG_IMPL_H__\r
18\r
19#include <Uefi.h>\r
20\r
21#include <Protocol/HiiConfigAccess.h>\r
22#include <Protocol/HiiConfigRouting.h>\r
ecc722ad 23#include <Protocol/SimpleFileSystem.h>\r
24#include <Protocol/BlockIo.h>\r
25#include <Protocol/DevicePath.h>\r
ecc722ad 26#include <Protocol/DebugPort.h>\r
27#include <Protocol/LoadFile.h>\r
beda2356 28\r
29#include <Library/BaseLib.h>\r
30#include <Library/BaseMemoryLib.h>\r
31#include <Library/DebugLib.h>\r
32#include <Library/MemoryAllocationLib.h>\r
33#include <Library/UefiBootServicesTableLib.h>\r
34#include <Library/UefiRuntimeServicesTableLib.h>\r
35#include <Library/UefiHiiServicesLib.h>\r
36#include <Library/UefiLib.h>\r
37#include <Library/HiiLib.h>\r
38#include <Library/DevicePathLib.h>\r
bc0c99b3 39#include <Library/PrintLib.h>\r
ecc722ad 40#include <Library/PlatformSecureLib.h>\r
41#include <Library/BaseCryptLib.h>\r
beda2356 42#include <Guid/MdeModuleHii.h>\r
43#include <Guid/AuthenticatedVariableFormat.h>\r
ecc722ad 44#include <Guid/FileSystemVolumeLabelInfo.h>\r
45#include <Guid/ImageAuthentication.h>\r
46#include <Guid/FileInfo.h>\r
beda2356 47\r
48#include "SecureBootConfigNvData.h"\r
49\r
50//\r
51// Tool generated IFR binary data and String package data\r
52//\r
ecc722ad 53extern UINT8 SecureBootConfigBin[];\r
54extern UINT8 SecureBootConfigDxeStrings[];\r
55\r
56//\r
57// Shared IFR form update data\r
58//\r
59extern VOID *mStartOpCodeHandle;\r
60extern VOID *mEndOpCodeHandle;\r
61extern EFI_IFR_GUID_LABEL *mStartLabel;\r
62extern EFI_IFR_GUID_LABEL *mEndLabel;\r
63\r
64#define MAX_CHAR 480\r
65#define TWO_BYTE_ENCODE 0x82\r
66\r
67//\r
68// SHA-1 digest size in bytes.\r
69//\r
70#define SHA1_DIGEST_SIZE 20\r
71//\r
72// SHA-256 digest size in bytes\r
73//\r
74#define SHA256_DIGEST_SIZE 32\r
75//\r
76// Set max digest size as SHA256 Output (32 bytes) by far\r
77//\r
78#define MAX_DIGEST_SIZE SHA256_DIGEST_SIZE\r
79\r
80#define WIN_CERT_UEFI_RSA2048_SIZE 256\r
81\r
82//\r
83// Support hash types\r
84//\r
85#define HASHALG_SHA1 0x00000000\r
86#define HASHALG_SHA224 0x00000001\r
87#define HASHALG_SHA256 0x00000002\r
88#define HASHALG_SHA384 0x00000003\r
89#define HASHALG_SHA512 0x00000004\r
90#define HASHALG_MAX 0x00000005\r
91\r
92\r
93#define SECUREBOOT_MENU_OPTION_SIGNATURE SIGNATURE_32 ('S', 'b', 'M', 'u')\r
94#define SECUREBOOT_MENU_ENTRY_SIGNATURE SIGNATURE_32 ('S', 'b', 'M', 'r')\r
95\r
96typedef struct {\r
97 EFI_DEVICE_PATH_PROTOCOL Header;\r
98 EFI_GUID Guid;\r
99 UINT8 VendorDefinedData[1];\r
100} VENDOR_DEVICE_PATH_WITH_DATA;\r
101\r
102typedef struct {\r
103 EFI_DEVICE_PATH_PROTOCOL Header;\r
104 UINT16 NetworkProtocol;\r
105 UINT16 LoginOption;\r
106 UINT64 Lun;\r
107 UINT16 TargetPortalGroupTag;\r
108 CHAR16 TargetName[1];\r
109} ISCSI_DEVICE_PATH_WITH_NAME;\r
110\r
111typedef enum _FILE_EXPLORER_DISPLAY_CONTEXT {\r
112 FileExplorerDisplayFileSystem,\r
113 FileExplorerDisplayDirectory,\r
114 FileExplorerDisplayUnknown\r
115} FILE_EXPLORER_DISPLAY_CONTEXT;\r
116\r
117typedef enum _FILE_EXPLORER_STATE {\r
118 FileExplorerStateInActive = 0,\r
119 FileExplorerStateEnrollPkFile,\r
120 FileExplorerStateEnrollKekFile,\r
121 FileExplorerStateEnrollSignatureFileToDb,\r
122 FileExplorerStateEnrollSignatureFileToDbx,\r
123 FileExplorerStateUnknown\r
124} FILE_EXPLORER_STATE;\r
125\r
126typedef struct {\r
127 CHAR16 *Str;\r
128 UINTN Len;\r
129 UINTN Maxlen;\r
130} POOL_PRINT;\r
131\r
132typedef\r
133VOID\r
134(*DEV_PATH_FUNCTION) (\r
135 IN OUT POOL_PRINT *Str,\r
136 IN VOID *DevPath\r
137 );\r
138\r
139typedef struct {\r
140 UINT8 Type;\r
141 UINT8 SubType;\r
142 DEV_PATH_FUNCTION Function;\r
143} DEVICE_PATH_STRING_TABLE;\r
144\r
145typedef struct {\r
146 UINTN Signature;\r
147 LIST_ENTRY Head;\r
148 UINTN MenuNumber;\r
149} SECUREBOOT_MENU_OPTION;\r
150\r
151extern SECUREBOOT_MENU_OPTION FsOptionMenu;\r
152extern SECUREBOOT_MENU_OPTION DirectoryMenu;\r
153\r
154typedef struct {\r
155 UINTN Signature;\r
156 LIST_ENTRY Link;\r
157 UINTN OptionNumber;\r
158 UINT16 *DisplayString;\r
159 UINT16 *HelpString;\r
160 EFI_STRING_ID DisplayStringToken;\r
161 EFI_STRING_ID HelpStringToken;\r
162 VOID *FileContext;\r
163} SECUREBOOT_MENU_ENTRY;\r
164\r
165typedef struct {\r
166 EFI_HANDLE Handle;\r
167 EFI_DEVICE_PATH_PROTOCOL *DevicePath;\r
168 EFI_FILE_HANDLE FHandle;\r
169 UINT16 *FileName;\r
170 EFI_FILE_SYSTEM_VOLUME_LABEL *Info;\r
171\r
172 BOOLEAN IsRoot;\r
173 BOOLEAN IsDir;\r
174 BOOLEAN IsRemovableMedia;\r
175 BOOLEAN IsLoadFile;\r
176 BOOLEAN IsBootLegacy;\r
177} SECUREBOOT_FILE_CONTEXT;\r
178\r
179\r
180//\r
181// We define another format of 5th directory entry: security directory\r
182//\r
183typedef struct {\r
184 UINT32 Offset; // Offset of certificate\r
185 UINT32 SizeOfCert; // size of certificate appended\r
186} EFI_IMAGE_SECURITY_DATA_DIRECTORY;\r
187\r
188typedef enum{\r
189 ImageType_IA32,\r
190 ImageType_X64\r
191} IMAGE_TYPE;\r
beda2356 192\r
193///\r
194/// HII specific Vendor Device Path definition.\r
195///\r
196typedef struct {\r
197 VENDOR_DEVICE_PATH VendorDevicePath;\r
198 EFI_DEVICE_PATH_PROTOCOL End;\r
199} HII_VENDOR_DEVICE_PATH;\r
200\r
201typedef struct {\r
202 UINTN Signature;\r
203\r
204 EFI_HII_CONFIG_ACCESS_PROTOCOL ConfigAccess;\r
205 EFI_HII_HANDLE HiiHandle;\r
206 EFI_HANDLE DriverHandle;\r
207\r
ecc722ad 208 FILE_EXPLORER_STATE FeCurrentState;\r
209 FILE_EXPLORER_DISPLAY_CONTEXT FeDisplayContext;\r
210\r
211 SECUREBOOT_MENU_ENTRY *MenuEntry;\r
212 SECUREBOOT_FILE_CONTEXT *FileContext;\r
213\r
214 EFI_GUID *SignatureGUID;\r
beda2356 215} SECUREBOOT_CONFIG_PRIVATE_DATA;\r
216\r
217extern SECUREBOOT_CONFIG_PRIVATE_DATA mSecureBootConfigPrivateDateTemplate;\r
218\r
219#define SECUREBOOT_CONFIG_PRIVATE_DATA_SIGNATURE SIGNATURE_32 ('S', 'E', 'C', 'B')\r
bc0c99b3 220#define SECUREBOOT_CONFIG_PRIVATE_FROM_THIS(a) CR (a, SECUREBOOT_CONFIG_PRIVATE_DATA, ConfigAccess, SECUREBOOT_CONFIG_PRIVATE_DATA_SIGNATURE)\r
221\r
ecc722ad 222//\r
223// Cryptograhpic Key Information\r
224//\r
1413b8e9 225#pragma pack(1)\r
ecc722ad 226typedef struct _CPL_KEY_INFO {\r
227 UINT32 KeyLengthInBits; // Key Length In Bits\r
228 UINT32 BlockSize; // Operation Block Size in Bytes\r
229 UINT32 CipherBlockSize; // Output Cipher Block Size in Bytes\r
230 UINT32 KeyType; // Key Type\r
231 UINT32 CipherMode; // Cipher Mode for Symmetric Algorithm\r
232 UINT32 Flags; // Additional Key Property Flags\r
233} CPL_KEY_INFO;\r
1413b8e9 234#pragma pack()\r
ecc722ad 235\r
236\r
237/**\r
238 Retrieves the size, in bytes, of the context buffer required for hash operations.\r
239\r
240 @return The size, in bytes, of the context buffer required for hash operations.\r
241\r
242**/\r
243typedef\r
244EFI_STATUS\r
245(EFIAPI *HASH_GET_CONTEXT_SIZE)(\r
246 VOID\r
247 );\r
248\r
249/**\r
250 Initializes user-supplied memory pointed by HashContext as hash context for\r
251 subsequent use.\r
252\r
253 If HashContext is NULL, then ASSERT().\r
254\r
255 @param[in, out] HashContext Pointer to Context being initialized.\r
256\r
257 @retval TRUE HASH context initialization succeeded.\r
258 @retval FALSE HASH context initialization failed.\r
259\r
260**/\r
261typedef\r
262BOOLEAN\r
263(EFIAPI *HASH_INIT)(\r
264 IN OUT VOID *HashContext\r
265 );\r
266\r
267\r
268/**\r
269 Performs digest on a data buffer of the specified length. This function can\r
270 be called multiple times to compute the digest of long or discontinuous data streams.\r
271\r
272 If HashContext is NULL, then ASSERT().\r
273\r
274 @param[in, out] HashContext Pointer to the MD5 context.\r
275 @param[in] Data Pointer to the buffer containing the data to be hashed.\r
276 @param[in] DataLength Length of Data buffer in bytes.\r
277\r
278 @retval TRUE HASH data digest succeeded.\r
279 @retval FALSE Invalid HASH context. After HashFinal function has been called, the\r
280 HASH context cannot be reused.\r
281\r
282**/\r
283typedef\r
284BOOLEAN\r
285(EFIAPI *HASH_UPDATE)(\r
286 IN OUT VOID *HashContext,\r
287 IN CONST VOID *Data,\r
288 IN UINTN DataLength\r
289 );\r
290\r
291/**\r
292 Completes hash computation and retrieves the digest value into the specified\r
293 memory. After this function has been called, the context cannot be used again.\r
294\r
295 If HashContext is NULL, then ASSERT().\r
296 If HashValue is NULL, then ASSERT().\r
297\r
298 @param[in, out] HashContext Pointer to the MD5 context\r
299 @param[out] HashValue Pointer to a buffer that receives the HASH digest\r
300 value (16 bytes).\r
301\r
302 @retval TRUE HASH digest computation succeeded.\r
303 @retval FALSE HASH digest computation failed.\r
304\r
305**/\r
306typedef\r
307BOOLEAN\r
308(EFIAPI *HASH_FINAL)(\r
309 IN OUT VOID *HashContext,\r
310 OUT UINT8 *HashValue\r
311 );\r
312\r
313//\r
314// Hash Algorithm Table\r
315//\r
316typedef struct {\r
317 CHAR16 *Name; ///< Name for Hash Algorithm\r
318 UINTN DigestLength; ///< Digest Length\r
319 UINT8 *OidValue; ///< Hash Algorithm OID ASN.1 Value \r
320 UINTN OidLength; ///< Length of Hash OID Value\r
321 HASH_GET_CONTEXT_SIZE GetContextSize; ///< Pointer to Hash GetContentSize function\r
322 HASH_INIT HashInit; ///< Pointer to Hash Init function\r
323 HASH_UPDATE HashUpdate; ///< Pointer to Hash Update function\r
324 HASH_FINAL HashFinal; ///< Pointer to Hash Final function\r
325} HASH_TABLE;\r
326\r
327typedef struct {\r
328 WIN_CERTIFICATE Hdr;\r
329 UINT8 CertData[1];\r
330} WIN_CERTIFICATE_EFI_PKCS;\r
331\r
beda2356 332\r
333/**\r
334 This function publish the SecureBoot configuration Form.\r
335\r
336 @param[in, out] PrivateData Points to SecureBoot configuration private data.\r
337\r
ecc722ad 338 @retval EFI_SUCCESS HII Form is installed successfully.\r
beda2356 339 @retval EFI_OUT_OF_RESOURCES Not enough resource for HII Form installation.\r
340 @retval Others Other errors as indicated.\r
341\r
342**/\r
343EFI_STATUS\r
344InstallSecureBootConfigForm (\r
345 IN OUT SECUREBOOT_CONFIG_PRIVATE_DATA *PrivateData\r
346 );\r
347\r
ecc722ad 348\r
beda2356 349/**\r
350 This function removes SecureBoot configuration Form.\r
351\r
352 @param[in, out] PrivateData Points to SecureBoot configuration private data.\r
353\r
354**/\r
beda2356 355VOID\r
356UninstallSecureBootConfigForm (\r
357 IN OUT SECUREBOOT_CONFIG_PRIVATE_DATA *PrivateData\r
358 );\r
359\r
ecc722ad 360\r
beda2356 361/**\r
362 This function allows a caller to extract the current configuration for one\r
363 or more named elements from the target driver.\r
364\r
365 @param[in] This Points to the EFI_HII_CONFIG_ACCESS_PROTOCOL.\r
366 @param[in] Request A null-terminated Unicode string in\r
367 <ConfigRequest> format.\r
368 @param[out] Progress On return, points to a character in the Request\r
369 string. Points to the string's null terminator if\r
370 request was successful. Points to the most recent\r
371 '&' before the first failing name/value pair (or\r
372 the beginning of the string if the failure is in\r
373 the first name/value pair) if the request was not\r
374 successful.\r
375 @param[out] Results A null-terminated Unicode string in\r
376 <ConfigAltResp> format which has all values filled\r
377 in for the names in the Request string. String to\r
378 be allocated by the called function.\r
379\r
380 @retval EFI_SUCCESS The Results is filled with the requested values.\r
381 @retval EFI_OUT_OF_RESOURCES Not enough memory to store the results.\r
382 @retval EFI_INVALID_PARAMETER Request is illegal syntax, or unknown name.\r
383 @retval EFI_NOT_FOUND Routing data doesn't match any storage in this\r
384 driver.\r
385\r
386**/\r
387EFI_STATUS\r
388EFIAPI\r
389SecureBootExtractConfig (\r
390 IN CONST EFI_HII_CONFIG_ACCESS_PROTOCOL *This,\r
391 IN CONST EFI_STRING Request,\r
392 OUT EFI_STRING *Progress,\r
393 OUT EFI_STRING *Results\r
394 );\r
395\r
ecc722ad 396\r
beda2356 397/**\r
398 This function processes the results of changes in configuration.\r
399\r
400 @param[in] This Points to the EFI_HII_CONFIG_ACCESS_PROTOCOL.\r
401 @param[in] Configuration A null-terminated Unicode string in <ConfigResp>\r
402 format.\r
403 @param[out] Progress A pointer to a string filled in with the offset of\r
404 the most recent '&' before the first failing\r
405 name/value pair (or the beginning of the string if\r
406 the failure is in the first name/value pair) or\r
407 the terminating NULL if all was successful.\r
408\r
409 @retval EFI_SUCCESS The Results is processed successfully.\r
410 @retval EFI_INVALID_PARAMETER Configuration is NULL.\r
411 @retval EFI_NOT_FOUND Routing data doesn't match any storage in this\r
412 driver.\r
413\r
414**/\r
415EFI_STATUS\r
416EFIAPI\r
417SecureBootRouteConfig (\r
418 IN CONST EFI_HII_CONFIG_ACCESS_PROTOCOL *This,\r
419 IN CONST EFI_STRING Configuration,\r
420 OUT EFI_STRING *Progress\r
421 );\r
422\r
ecc722ad 423\r
beda2356 424/**\r
425 This function processes the results of changes in configuration.\r
426\r
427 @param[in] This Points to the EFI_HII_CONFIG_ACCESS_PROTOCOL.\r
428 @param[in] Action Specifies the type of action taken by the browser.\r
429 @param[in] QuestionId A unique value which is sent to the original\r
430 exporting driver so that it can identify the type\r
431 of data to expect.\r
432 @param[in] Type The type of value for the question.\r
433 @param[in] Value A pointer to the data being sent to the original\r
434 exporting driver.\r
435 @param[out] ActionRequest On return, points to the action requested by the\r
436 callback function.\r
437\r
438 @retval EFI_SUCCESS The callback successfully handled the action.\r
439 @retval EFI_OUT_OF_RESOURCES Not enough storage is available to hold the\r
440 variable and its data.\r
441 @retval EFI_DEVICE_ERROR The variable could not be saved.\r
442 @retval EFI_UNSUPPORTED The specified Action is not supported by the\r
443 callback.\r
444\r
445**/\r
446EFI_STATUS\r
447EFIAPI\r
448SecureBootCallback (\r
449 IN CONST EFI_HII_CONFIG_ACCESS_PROTOCOL *This,\r
450 IN EFI_BROWSER_ACTION Action,\r
451 IN EFI_QUESTION_ID QuestionId,\r
452 IN UINT8 Type,\r
453 IN EFI_IFR_TYPE_VALUE *Value,\r
454 OUT EFI_BROWSER_ACTION_REQUEST *ActionRequest\r
455 );\r
456\r
ecc722ad 457\r
458/**\r
459 This function converts an input device structure to a Unicode string.\r
460\r
461 @param[in] DevPath A pointer to the device path structure.\r
462\r
463 @return A new allocated Unicode string that represents the device path.\r
464\r
465**/\r
466CHAR16 *\r
467EFIAPI\r
468DevicePathToStr (\r
469 IN EFI_DEVICE_PATH_PROTOCOL *DevPath\r
470 );\r
471\r
472\r
473/**\r
474 Clean up the dynamic opcode at label and form specified by both LabelId. \r
475\r
476 @param[in] LabelId It is both the Form ID and Label ID for opcode deletion.\r
477 @param[in] PrivateData Module private data.\r
478\r
479**/\r
480VOID\r
481CleanUpPage (\r
482 IN UINT16 LabelId,\r
483 IN SECUREBOOT_CONFIG_PRIVATE_DATA *PrivateData\r
484 );\r
485\r
486\r
487/**\r
488 Update the file explorer page with the refreshed file system.\r
489\r
490 @param[in] PrivateData Module private data.\r
491 @param[in] KeyValue Key value to identify the type of data to expect.\r
492\r
493 @retval TRUE Inform the caller to create a callback packet to exit file explorer.\r
494 @retval FALSE Indicate that there is no need to exit file explorer.\r
495\r
496**/\r
497BOOLEAN\r
498UpdateFileExplorer (\r
499 IN SECUREBOOT_CONFIG_PRIVATE_DATA *PrivateData,\r
500 IN UINT16 KeyValue\r
501 );\r
502\r
503\r
504/**\r
505 Free resources allocated in Allocate Rountine.\r
506\r
507 @param[in, out] MenuOption Menu to be freed\r
508 \r
509**/\r
510VOID\r
511FreeMenu (\r
512 IN OUT SECUREBOOT_MENU_OPTION *MenuOption\r
513 );\r
514\r
515\r
516/**\r
517 Read file content into BufferPtr, the size of the allocate buffer \r
518 is *FileSize plus AddtionAllocateSize.\r
519\r
520 @param[in] FileHandle The file to be read.\r
521 @param[in, out] BufferPtr Pointers to the pointer of allocated buffer.\r
522 @param[out] FileSize Size of input file\r
523 @param[in] AddtionAllocateSize Addtion size the buffer need to be allocated. \r
524 In case the buffer need to contain others besides the file content.\r
525 \r
526 @retval EFI_SUCCESS The file was read into the buffer.\r
527 @retval EFI_INVALID_PARAMETER A parameter was invalid.\r
528 @retval EFI_OUT_OF_RESOURCES A memory allocation failed.\r
529 @retval others Unexpected error.\r
530\r
531**/\r
532EFI_STATUS\r
533ReadFileContent (\r
534 IN EFI_FILE_HANDLE FileHandle,\r
535 IN OUT VOID **BufferPtr,\r
536 OUT UINTN *FileSize,\r
537 IN UINTN AddtionAllocateSize\r
538 );\r
539\r
540\r
541/**\r
542 Close an open file handle.\r
543\r
544 @param[in] FileHandle The file handle to close.\r
545 \r
546**/\r
547VOID\r
548CloseFile (\r
549 IN EFI_FILE_HANDLE FileHandle\r
550 );\r
551\r
552\r
553/**\r
554 Converts a nonnegative integer to an octet string of a specified length.\r
555\r
556 @param[in] Integer Pointer to the nonnegative integer to be converted\r
557 @param[in] IntSizeInWords Length of integer buffer in words\r
558 @param[out] OctetString Converted octet string of the specified length \r
559 @param[in] OSSizeInBytes Intended length of resulting octet string in bytes\r
560\r
561Returns:\r
562\r
563 @retval EFI_SUCCESS Data conversion successfully\r
564 @retval EFI_BUFFER_TOOL_SMALL Buffer is too small for output string\r
565\r
566**/\r
567EFI_STATUS\r
568EFIAPI\r
569Int2OctStr (\r
570 IN CONST UINTN *Integer,\r
571 IN UINTN IntSizeInWords,\r
572 OUT UINT8 *OctetString,\r
573 IN UINTN OSSizeInBytes\r
574 );\r
575\r
576\r
577/**\r
578 Convert a String to Guid Value.\r
579\r
580 @param[in] Str Specifies the String to be converted.\r
581 @param[in] StrLen Number of Unicode Characters of String (exclusive \0)\r
582 @param[out] Guid Return the result Guid value.\r
583\r
584 @retval EFI_SUCCESS The operation is finished successfully.\r
585 @retval EFI_NOT_FOUND Invalid string.\r
586\r
587**/\r
588EFI_STATUS\r
589StringToGuid (\r
590 IN CHAR16 *Str, \r
591 IN UINTN StrLen, \r
592 OUT EFI_GUID *Guid\r
593 );\r
594\r
595\r
596/**\r
597 Worker function that prints an EFI_GUID into specified Buffer.\r
598\r
599 @param[in] Guid Pointer to GUID to print.\r
600 @param[in] Buffer Buffer to print Guid into.\r
601 @param[in] BufferSize Size of Buffer.\r
602 \r
603 @retval Number of characters printed.\r
604\r
605**/\r
606UINTN\r
607GuidToString (\r
608 IN EFI_GUID *Guid,\r
609 IN CHAR16 *Buffer,\r
610 IN UINTN BufferSize\r
611 );\r
612\r
beda2356 613#endif\r