ECDiffieHellmanCngPublicKey.FromByteArray(Byte[], CngKeyBlobFormat) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
根據指定的格式,將包含公開金鑰的位元組陣列轉換成 ECDiffieHellmanCngPublicKey 物件。
public:
static System::Security::Cryptography::ECDiffieHellmanPublicKey ^ FromByteArray(cli::array <System::Byte> ^ publicKeyBlob, System::Security::Cryptography::CngKeyBlobFormat ^ format);
public static System.Security.Cryptography.ECDiffieHellmanPublicKey FromByteArray (byte[] publicKeyBlob, System.Security.Cryptography.CngKeyBlobFormat format);
[System.Runtime.Versioning.SupportedOSPlatform("windows")]
public static System.Security.Cryptography.ECDiffieHellmanPublicKey FromByteArray (byte[] publicKeyBlob, System.Security.Cryptography.CngKeyBlobFormat format);
[System.Security.SecurityCritical]
public static System.Security.Cryptography.ECDiffieHellmanPublicKey FromByteArray (byte[] publicKeyBlob, System.Security.Cryptography.CngKeyBlobFormat format);
static member FromByteArray : byte[] * System.Security.Cryptography.CngKeyBlobFormat -> System.Security.Cryptography.ECDiffieHellmanPublicKey
[<System.Runtime.Versioning.SupportedOSPlatform("windows")>]
static member FromByteArray : byte[] * System.Security.Cryptography.CngKeyBlobFormat -> System.Security.Cryptography.ECDiffieHellmanPublicKey
[<System.Security.SecurityCritical>]
static member FromByteArray : byte[] * System.Security.Cryptography.CngKeyBlobFormat -> System.Security.Cryptography.ECDiffieHellmanPublicKey
Public Shared Function FromByteArray (publicKeyBlob As Byte(), format As CngKeyBlobFormat) As ECDiffieHellmanPublicKey
參數
- publicKeyBlob
- Byte[]
包含 Elliptic Curve Diffie-Hellman (ECDH) 公開金鑰的位元組陣列。
- format
- CngKeyBlobFormat
指定金鑰 BLOB 格式的物件。
傳回
包含在位元組陣列中序列化的 ECDH 公開金鑰的物件。
- 屬性
例外狀況
publicKeyBlob
或 format
參數為 null
。
publicKeyBlob
參數未包含 ECDiffieHellman 金鑰。
備註
此靜態方法會在所有 ECDiffieHellmanCngPublicKey 實例之間共用。