Show / Hide Table of Contents

CreateFromPkcs8 Method

CreateFromPkcs8(ReadOnlyMemory<byte>)

Creates an instance of IPublicKey from a DER-encoded public key.

C#
public static IPublicKey CreateFromPkcs8(ReadOnlyMemory<byte> encodedKey)

Parameters

Type Name Description
ReadOnlyMemory<byte> encodedKey

The DER-encoded public key.

Returns

IPublicKey

An instance of IPublicKey.

Exceptions

Type Condition
CryptographicException

Thrown if the public key is invalid.

In this article
Back to top Generated by DocFX