MLDsa.TryExportEncryptedPkcs8PrivateKey 메서드

정의

오버로드

Name Description
TryExportEncryptedPkcs8PrivateKey(ReadOnlySpan<Byte>, PbeParameters, Span<Byte>, Int32)

바이트 기반 암호를 사용하여 PKCS#8 EncryptedPrivateKeyInfo 형식의 현재 키를 제공된 버퍼로 내보내려고 시도합니다.

TryExportEncryptedPkcs8PrivateKey(ReadOnlySpan<Char>, PbeParameters, Span<Byte>, Int32)

문자 기반 암호를 사용하여 PKCS#8 EncryptedPrivateKeyInfo 형식의 현재 키를 제공된 버퍼로 내보내려고 시도합니다.

TryExportEncryptedPkcs8PrivateKey(String, PbeParameters, Span<Byte>, Int32)

문자 기반 암호를 사용하여 PKCS#8 EncryptedPrivateKeyInfo 형식의 현재 키를 제공된 버퍼로 내보내려고 시도합니다.

TryExportEncryptedPkcs8PrivateKey(ReadOnlySpan<Byte>, PbeParameters, Span<Byte>, Int32)

Source:
MLDsa.cs
Source:
MLDsa.cs
Source:
MLDsa.cs

바이트 기반 암호를 사용하여 PKCS#8 EncryptedPrivateKeyInfo 형식의 현재 키를 제공된 버퍼로 내보내려고 시도합니다.

public:
 bool TryExportEncryptedPkcs8PrivateKey(ReadOnlySpan<System::Byte> passwordBytes, System::Security::Cryptography::PbeParameters ^ pbeParameters, Span<System::Byte> destination, [Runtime::InteropServices::Out] int % bytesWritten);
[System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public bool TryExportEncryptedPkcs8PrivateKey(ReadOnlySpan<byte> passwordBytes, System.Security.Cryptography.PbeParameters pbeParameters, Span<byte> destination, out int bytesWritten);
public bool TryExportEncryptedPkcs8PrivateKey(ReadOnlySpan<byte> passwordBytes, System.Security.Cryptography.PbeParameters pbeParameters, Span<byte> destination, out int bytesWritten);
[<System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
member this.TryExportEncryptedPkcs8PrivateKey : ReadOnlySpan<byte> * System.Security.Cryptography.PbeParameters * Span<byte> * int -> bool
member this.TryExportEncryptedPkcs8PrivateKey : ReadOnlySpan<byte> * System.Security.Cryptography.PbeParameters * Span<byte> * int -> bool
Public Function TryExportEncryptedPkcs8PrivateKey (passwordBytes As ReadOnlySpan(Of Byte), pbeParameters As PbeParameters, destination As Span(Of Byte), ByRef bytesWritten As Integer) As Boolean

매개 변수

passwordBytes
ReadOnlySpan<Byte>

키 자료를 암호화할 때 암호로 사용할 바이트입니다.

pbeParameters
PbeParameters

키 자료를 암호화할 때 사용할 PBE(암호 기반 암호화) 매개 변수입니다.

destination
Span<Byte>

PKCS#8 EncryptedPrivateKeyInfo 값을 받을 버퍼입니다.

bytesWritten
Int32

이 메서드가 반환되면 버퍼에 기록 destination 된 바이트 수를 포함합니다.

이 매개 변수는 초기화되지 않은 것으로 처리됩니다.

반품

결과를 저장할 수 있을 만큼 크면 /&이고, 그렇지 않으면 .

특성

예외

pbeParametersnull입니다.

이 인스턴스가 삭제되었습니다.

pbeParameters 는 문자 기반 암호가 필요한 KDF를 지정합니다.

-또는-

pbeParameters 는 유효한 암호 기반 암호화 알고리즘을 나타내지 않습니다.

-또는-

이 인스턴스는 공개 키만 나타냅니다.

-또는-

프라이빗 키를 내보낼 수 없습니다.

-또는-

키를 내보내는 동안 오류가 발생했습니다.

적용 대상

TryExportEncryptedPkcs8PrivateKey(ReadOnlySpan<Char>, PbeParameters, Span<Byte>, Int32)

Source:
MLDsa.cs
Source:
MLDsa.cs
Source:
MLDsa.cs

문자 기반 암호를 사용하여 PKCS#8 EncryptedPrivateKeyInfo 형식의 현재 키를 제공된 버퍼로 내보내려고 시도합니다.

public:
 bool TryExportEncryptedPkcs8PrivateKey(ReadOnlySpan<char> password, System::Security::Cryptography::PbeParameters ^ pbeParameters, Span<System::Byte> destination, [Runtime::InteropServices::Out] int % bytesWritten);
[System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public bool TryExportEncryptedPkcs8PrivateKey(ReadOnlySpan<char> password, System.Security.Cryptography.PbeParameters pbeParameters, Span<byte> destination, out int bytesWritten);
public bool TryExportEncryptedPkcs8PrivateKey(ReadOnlySpan<char> password, System.Security.Cryptography.PbeParameters pbeParameters, Span<byte> destination, out int bytesWritten);
[<System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
member this.TryExportEncryptedPkcs8PrivateKey : ReadOnlySpan<char> * System.Security.Cryptography.PbeParameters * Span<byte> * int -> bool
member this.TryExportEncryptedPkcs8PrivateKey : ReadOnlySpan<char> * System.Security.Cryptography.PbeParameters * Span<byte> * int -> bool
Public Function TryExportEncryptedPkcs8PrivateKey (password As ReadOnlySpan(Of Char), pbeParameters As PbeParameters, destination As Span(Of Byte), ByRef bytesWritten As Integer) As Boolean

매개 변수

password
ReadOnlySpan<Char>

키 자료를 암호화할 때 사용할 암호입니다.

pbeParameters
PbeParameters

키 자료를 암호화할 때 사용할 PBE(암호 기반 암호화) 매개 변수입니다.

destination
Span<Byte>

PKCS#8 EncryptedPrivateKeyInfo 값을 받을 버퍼입니다.

bytesWritten
Int32

이 메서드가 반환되면 버퍼에 기록 destination 된 바이트 수를 포함합니다.

이 매개 변수는 초기화되지 않은 것으로 처리됩니다.

반품

결과를 저장할 수 있을 만큼 크면 /&이고, 그렇지 않으면 .

특성

예외

pbeParametersnull입니다.

이 인스턴스가 삭제되었습니다.

pbeParameters 는 유효한 암호 기반 암호화 알고리즘을 나타내지 않습니다.

-또는-

이 인스턴스는 공개 키만 나타냅니다.

-또는-

프라이빗 키를 내보낼 수 없습니다.

-또는-

키를 내보내는 동안 오류가 발생했습니다.

적용 대상

TryExportEncryptedPkcs8PrivateKey(String, PbeParameters, Span<Byte>, Int32)

Source:
MLDsa.cs
Source:
MLDsa.cs
Source:
MLDsa.cs

문자 기반 암호를 사용하여 PKCS#8 EncryptedPrivateKeyInfo 형식의 현재 키를 제공된 버퍼로 내보내려고 시도합니다.

public:
 bool TryExportEncryptedPkcs8PrivateKey(System::String ^ password, System::Security::Cryptography::PbeParameters ^ pbeParameters, Span<System::Byte> destination, [Runtime::InteropServices::Out] int % bytesWritten);
[System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public bool TryExportEncryptedPkcs8PrivateKey(string password, System.Security.Cryptography.PbeParameters pbeParameters, Span<byte> destination, out int bytesWritten);
public bool TryExportEncryptedPkcs8PrivateKey(string password, System.Security.Cryptography.PbeParameters pbeParameters, Span<byte> destination, out int bytesWritten);
[<System.Diagnostics.CodeAnalysis.Experimental("SYSLIB5006", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
member this.TryExportEncryptedPkcs8PrivateKey : string * System.Security.Cryptography.PbeParameters * Span<byte> * int -> bool
member this.TryExportEncryptedPkcs8PrivateKey : string * System.Security.Cryptography.PbeParameters * Span<byte> * int -> bool
Public Function TryExportEncryptedPkcs8PrivateKey (password As String, pbeParameters As PbeParameters, destination As Span(Of Byte), ByRef bytesWritten As Integer) As Boolean

매개 변수

password
String

키 자료를 암호화할 때 사용할 암호입니다.

pbeParameters
PbeParameters

키 자료를 암호화할 때 사용할 PBE(암호 기반 암호화) 매개 변수입니다.

destination
Span<Byte>

PKCS#8 EncryptedPrivateKeyInfo 값을 받을 버퍼입니다.

bytesWritten
Int32

이 메서드가 반환되면 버퍼에 기록 destination 된 바이트 수를 포함합니다.

이 매개 변수는 초기화되지 않은 것으로 처리됩니다.

반품

결과를 저장할 수 있을 만큼 크면 /&이고, 그렇지 않으면 .

특성

예외

password 또는 pbeParameters .입니다 null.

적용 대상