MLKem.ImportEncryptedPkcs8PrivateKey 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.
Importe une clé privée ML-KEM à partir d’une structure PKCS#8 EncryptedPrivateKeyInfo.
Surcharges
| Nom | Description |
|---|---|
| ImportEncryptedPkcs8PrivateKey(ReadOnlySpan<Byte>, ReadOnlySpan<Byte>) |
Importe une clé privée ML-KEM à partir d’une structure PKCS#8 EncryptedPrivateKeyInfo. |
| ImportEncryptedPkcs8PrivateKey(ReadOnlySpan<Char>, ReadOnlySpan<Byte>) |
Importe une clé privée ML-KEM à partir d’une structure PKCS#8 EncryptedPrivateKeyInfo. |
| ImportEncryptedPkcs8PrivateKey(String, Byte[]) |
Importe une clé privée ML-KEM à partir d’une structure PKCS#8 EncryptedPrivateKeyInfo. |
ImportEncryptedPkcs8PrivateKey(ReadOnlySpan<Byte>, ReadOnlySpan<Byte>)
- Source:
- MLKem.cs
- Source:
- MLKem.cs
- Source:
- MLKem.cs
Importe une clé privée ML-KEM à partir d’une structure PKCS#8 EncryptedPrivateKeyInfo.
public:
static System::Security::Cryptography::MLKem ^ ImportEncryptedPkcs8PrivateKey(ReadOnlySpan<System::Byte> passwordBytes, ReadOnlySpan<System::Byte> source);
[System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public static System.Security.Cryptography.MLKem ImportEncryptedPkcs8PrivateKey(ReadOnlySpan<byte> passwordBytes, ReadOnlySpan<byte> source);
public static System.Security.Cryptography.MLKem ImportEncryptedPkcs8PrivateKey(ReadOnlySpan<byte> passwordBytes, ReadOnlySpan<byte> source);
[<System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
static member ImportEncryptedPkcs8PrivateKey : ReadOnlySpan<byte> * ReadOnlySpan<byte> -> System.Security.Cryptography.MLKem
static member ImportEncryptedPkcs8PrivateKey : ReadOnlySpan<byte> * ReadOnlySpan<byte> -> System.Security.Cryptography.MLKem
Public Shared Function ImportEncryptedPkcs8PrivateKey (passwordBytes As ReadOnlySpan(Of Byte), source As ReadOnlySpan(Of Byte)) As MLKem
Paramètres
- passwordBytes
- ReadOnlySpan<Byte>
Octets à utiliser comme mot de passe lors du déchiffrement du matériel de clé.
- source
- ReadOnlySpan<Byte>
Octets d’une structure PKCS#8 EncryptedPrivateKeyInfo dans l’encodage ASN.1-BER.
Retours
Clé importée.
- Attributs
Exceptions
Le contenu de source ne représente pas une structure PKCS#8 EncryptedPrivateKeyInfo encodée ASN.1-BER.
- ou -
Le mot de passe spécifié est incorrect.
- ou -
EncryptedPrivateKeyInfo indique que la fonction de dérivation de clé (KDF) à appliquer est la fonction PKCS#12 KDF héritée, qui nécessite Chardes mots de passe basés sur des mots de passe.
- ou -
La valeur ne représente pas de clé ML-KEM.
- ou -
L’importation spécifique à l’algorithme a échoué.
La plateforme ne prend pas en charge ML-KEM. Les appelants peuvent utiliser la IsSupported propriété pour déterminer si la plateforme prend en charge ML-KEM.
S’applique à
ImportEncryptedPkcs8PrivateKey(ReadOnlySpan<Char>, ReadOnlySpan<Byte>)
- Source:
- MLKem.cs
- Source:
- MLKem.cs
- Source:
- MLKem.cs
Importe une clé privée ML-KEM à partir d’une structure PKCS#8 EncryptedPrivateKeyInfo.
public:
static System::Security::Cryptography::MLKem ^ ImportEncryptedPkcs8PrivateKey(ReadOnlySpan<char> password, ReadOnlySpan<System::Byte> source);
[System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public static System.Security.Cryptography.MLKem ImportEncryptedPkcs8PrivateKey(ReadOnlySpan<char> password, ReadOnlySpan<byte> source);
public static System.Security.Cryptography.MLKem ImportEncryptedPkcs8PrivateKey(ReadOnlySpan<char> password, ReadOnlySpan<byte> source);
[<System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
static member ImportEncryptedPkcs8PrivateKey : ReadOnlySpan<char> * ReadOnlySpan<byte> -> System.Security.Cryptography.MLKem
static member ImportEncryptedPkcs8PrivateKey : ReadOnlySpan<char> * ReadOnlySpan<byte> -> System.Security.Cryptography.MLKem
Public Shared Function ImportEncryptedPkcs8PrivateKey (password As ReadOnlySpan(Of Char), source As ReadOnlySpan(Of Byte)) As MLKem
Paramètres
- password
- ReadOnlySpan<Char>
Mot de passe à utiliser lors du déchiffrement du matériel de clé.
- source
- ReadOnlySpan<Byte>
Octets d’une structure PKCS#8 EncryptedPrivateKeyInfo dans l’encodage ASN.1-BER.
Retours
Clé importée.
- Attributs
Exceptions
Le contenu de source ne représente pas une structure PKCS#8 EncryptedPrivateKeyInfo encodée ASN.1-BER.
- ou -
Le mot de passe spécifié est incorrect.
- ou -
La valeur ne représente pas de clé ML-KEM.
- ou -
L’importation spécifique à l’algorithme a échoué.
La plateforme ne prend pas en charge ML-KEM. Les appelants peuvent utiliser la IsSupported propriété pour déterminer si la plateforme prend en charge ML-KEM.
S’applique à
ImportEncryptedPkcs8PrivateKey(String, Byte[])
- Source:
- MLKem.cs
- Source:
- MLKem.cs
- Source:
- MLKem.cs
Importe une clé privée ML-KEM à partir d’une structure PKCS#8 EncryptedPrivateKeyInfo.
public:
static System::Security::Cryptography::MLKem ^ ImportEncryptedPkcs8PrivateKey(System::String ^ password, cli::array <System::Byte> ^ source);
[System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public static System.Security.Cryptography.MLKem ImportEncryptedPkcs8PrivateKey(string password, byte[] source);
public static System.Security.Cryptography.MLKem ImportEncryptedPkcs8PrivateKey(string password, byte[] source);
[<System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
static member ImportEncryptedPkcs8PrivateKey : string * byte[] -> System.Security.Cryptography.MLKem
static member ImportEncryptedPkcs8PrivateKey : string * byte[] -> System.Security.Cryptography.MLKem
Public Shared Function ImportEncryptedPkcs8PrivateKey (password As String, source As Byte()) As MLKem
Paramètres
- password
- String
Mot de passe à utiliser lors du déchiffrement du matériel de clé.
- source
- Byte[]
Octets d’une structure PKCS#8 EncryptedPrivateKeyInfo dans l’encodage ASN.1-BER.
Retours
Clé importée.
- Attributs
Exceptions
password ou source est null.
Le contenu de source ne représente pas une structure PKCS#8 EncryptedPrivateKeyInfo encodée ASN.1-BER.
- ou -
Le mot de passe spécifié est incorrect.
- ou -
La valeur ne représente pas de clé ML-KEM.
- ou -
L’importation spécifique à l’algorithme a échoué.
La plateforme ne prend pas en charge ML-KEM. Les appelants peuvent utiliser la IsSupported propriété pour déterminer si la plateforme prend en charge ML-KEM.