System.Security.Cryptography.Pkcs.Pkcs12Builder
Enables the creation of PKCS#12 PFX data values. This class cannot be inherited.
Gets a value that indicates whether the PFX data has been sealed.
public Pkcs12Builder()
Initializes a new value of the Pkcs12Builder class.
public void AddSafeContentsEncrypted(Pkcs12SafeContents safeContents, byte[] passwordBytes, PbeParameters pbeParameters)
Add contents to the PFX in an bundle encrypted with a byte-based password from a byte array.
public void AddSafeContentsEncrypted(Pkcs12SafeContents safeContents, ReadOnlySpan<byte> passwordBytes, PbeParameters pbeParameters)
Add contents to the PFX in an bundle encrypted with a byte-based password from a span.
public void AddSafeContentsEncrypted(Pkcs12SafeContents safeContents, string password, PbeParameters pbeParameters)
Add contents to the PFX in an bundle encrypted with a char-based password from a string.
public void AddSafeContentsEncrypted(Pkcs12SafeContents safeContents, ReadOnlySpan<char> password, PbeParameters pbeParameters)
Add contents to the PFX in an bundle encrypted with a char-based password from a span.
Add contents to the PFX without encrypting them.
Encodes the contents of a sealed PFX and returns it as a byte array.
Seals the PFX against further changes by applying a password-based Message Authentication Code (MAC) over the contents with a password from a string.
public void SealWithMac(ReadOnlySpan<char> password, HashAlgorithmName hashAlgorithm, int iterationCount)
Seals the PFX against further changes by applying a password-based Message Authentication Code (MAC) over the contents with a password from a span.
Seals the PFX from further changes without applying tamper-protection.
Attempts to encode the contents of a sealed PFX into a provided buffer.