Save an internal RSA key string to an encrypted key file.
public static int SaveEncKey( string outputFile, string privateKey, string password, Rsa.PbeOptions pbeOption, string paramString = "", Rsa.Format format = Rsa.Format.Default )
Public Shared Function SaveEncKey ( outputFile As String, privateKey As String, password As String, pbeOption As Rsa.PbeOptions, Optional paramString As String = "", Optional format As Rsa.Format = Rsa.Format.Default ) As Integer
Valid name-value pairs for paramString are:
| Parameter | Description |
|---|---|
| count=integer | To set the iteration count used in the PBKDF2 method, e.g. "count=5000;" [default=2048]. |
| prf=hmac-name | To change the HMAC algorithm used in the PBKDF2 method, e.g. "prf=hmacwithSHA256;" [default=hmacwithSHA1]. |
Valid values for hmac-name are one of {hmacWithSHA1, hmacWithSHA224, hmacWithSHA256, hmacWithSHA384, hmacWithSHA512}.
VB6/C equivalent: RSA_SaveEncKey