共用方式為


SafeEvpPKeyHandle.OpenPublicKeyFromEngine(String, String) 方法

定義

使用名為 OpenSSL ENGINE 的 來開啟具名公開金鑰。

public:
 static System::Security::Cryptography::SafeEvpPKeyHandle ^ OpenPublicKeyFromEngine(System::String ^ engineName, System::String ^ keyId);
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
[System.Runtime.Versioning.UnsupportedOSPlatform("browser")]
[System.Runtime.Versioning.UnsupportedOSPlatform("ios")]
[System.Runtime.Versioning.UnsupportedOSPlatform("tvos")]
[System.Runtime.Versioning.UnsupportedOSPlatform("windows")]
public static System.Security.Cryptography.SafeEvpPKeyHandle OpenPublicKeyFromEngine (string engineName, string keyId);
[<System.Runtime.Versioning.UnsupportedOSPlatform("android")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("browser")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("ios")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("tvos")>]
[<System.Runtime.Versioning.UnsupportedOSPlatform("windows")>]
static member OpenPublicKeyFromEngine : string * string -> System.Security.Cryptography.SafeEvpPKeyHandle
Public Shared Function OpenPublicKeyFromEngine (engineName As String, keyId As String) As SafeEvpPKeyHandle

參數

engineName
String

要處理公開金鑰開啟要求的 名稱 ENGINE

keyId
String

要開啟的金鑰名稱。

傳回

已開啟的金鑰。

屬性

例外狀況

engineNamekeyIdnull

engineNamekeyId 是空字串。

無法透過指定的 ENGINE 開啟金鑰。

備註

如果 OpenSSL 無法成功載入具名的 ,或如果具名 ENGINE 無法載入具名 ENGINE 索引鍵,這項作業將會失敗。

ENGINE並非所有都支援載入公開金鑰,甚至是支援載入私密金鑰的公開金鑰。

的語法 keyId 是由每個個別 ENGINE 的 所決定。

適用於