ECAlgorithm.TryExportECPrivateKeyPem(Span<Char>, Int32) Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Tente d’exporter la clé actuelle au format ECPrivateKey encodé en PEM dans une mémoire tampon fournie.
public:
bool TryExportECPrivateKeyPem(Span<char> destination, [Runtime::InteropServices::Out] int % charsWritten);
public bool TryExportECPrivateKeyPem(Span<char> destination, out int charsWritten);
member this.TryExportECPrivateKeyPem : Span<char> * int -> bool
Public Function TryExportECPrivateKeyPem (destination As Span(Of Char), ByRef charsWritten As Integer) As Boolean
Paramètres
Étendue de caractères pour recevoir les données ECPrivateKey encodées par PEM.
- charsWritten
- Int32
Lorsque cette méthode est retournée, contient une valeur qui indique le nombre de caractères écrits dans destination. Ce paramètre est traité comme non initialisé.
Retours
true s’il destination est assez grand pour recevoir la sortie ; sinon, false.
Exceptions
Impossible d’exporter la clé.
Remarques
Une clé ECPrivateKey codée en PEM commence par -----BEGIN EC PRIVATE KEY----- et se termine -----END EC PRIVATE KEY-----par , avec le contenu DER codé en base64 de la clé entre les limites PEM.
The PEM is encoded according to the IETF RFC 7468 "strict"
encoding rules.