git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11247
6f19259b-4bc3-4df7-8a09-
765794883524
//\r
Print (L"\n- Retrieve RSA Private Key for PEM ...");\r
Status = RsaGetPrivateKeyFromPem (TestKeyPem, sizeof (TestKeyPem), PemPass, &RsaPrivKey);\r
//\r
Print (L"\n- Retrieve RSA Private Key for PEM ...");\r
Status = RsaGetPrivateKeyFromPem (TestKeyPem, sizeof (TestKeyPem), PemPass, &RsaPrivKey);\r
- if (Status == FALSE) {\r
Print (L"[Fail]");\r
return EFI_ABORTED;\r
} else {\r
Print (L"[Fail]");\r
return EFI_ABORTED;\r
} else {\r
Print (L"\n- Retrieve RSA Public Key from X509 ... ");\r
RsaPubKey = NULL;\r
Status = RsaGetPublicKeyFromX509 (TestCert, sizeof (TestCert), &RsaPubKey);\r
Print (L"\n- Retrieve RSA Public Key from X509 ... ");\r
RsaPubKey = NULL;\r
Status = RsaGetPublicKeyFromX509 (TestCert, sizeof (TestCert), &RsaPubKey);\r
- if (Status == FALSE) {\r
Print (L"[Fail]");\r
return EFI_ABORTED;\r
} else {\r
Print (L"[Fail]");\r
return EFI_ABORTED;\r
} else {\r
/** @file\r
PEM (Privacy Enhanced Mail) Format Handler Wrapper Implementation over OpenSSL.\r
\r
/** @file\r
PEM (Privacy Enhanced Mail) Format Handler Wrapper Implementation over OpenSSL.\r
\r
-Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2010 - 2011, Intel Corporation. All rights reserved.<BR>\r
This program and the accompanying materials\r
are licensed and made available under the terms and conditions of the BSD License\r
which accompanies this distribution. The full text of the license may be found at\r
This program and the accompanying materials\r
are licensed and made available under the terms and conditions of the BSD License\r
which accompanies this distribution. The full text of the license may be found at\r
//\r
// Duplicate key phrase directly.\r
//\r
//\r
// Duplicate key phrase directly.\r
//\r
- KeyLength = AsciiStrLen ((CHAR8 *)Key);\r
+ KeyLength = (INTN) AsciiStrLen ((CHAR8 *)Key);\r
KeyLength = (KeyLength > Size ) ? Size : KeyLength;\r
KeyLength = (KeyLength > Size ) ? Size : KeyLength;\r
- CopyMem (Buf, Key, KeyLength);\r
+ CopyMem (Buf, Key, (UINTN) KeyLength);\r
return KeyLength;\r
} else {\r
return 0;\r
return KeyLength;\r
} else {\r
return 0;\r