Early Preview
This is currently very much a preview. Please feel free to try things out,
but don't be upset if anything is not yet working. Feedback is welcome over on our
GitHub Dicussions page.
class System.​Security.​Cryptography.​PasswordDeriveBytes
Assembly: System.Security.Cryptography
Inheritance: object → DeriveBytes → PasswordDeriveBytes
Derives a key from a password using an extension of the PBKDF1 algorithm.
Properties
public
string
HashName
Gets or sets the name of the hash algorithm for the operation.
public
int
IterationCount
Gets or sets the number of iterations for the operation.
public
byte[]
Salt
Gets or sets the key salt value for the operation.
Methods
public
byte[]
CryptDeriveKey​(string algname,
string alghashname,
int keySize,
byte[] rgbIV)
algname
The algorithm name for which to derive the key.
alghashname
The hash algorithm name to use to derive the key.
keySize
The size of the key, in bits, to derive.
rgbIV
The initialization vector (IV) to use to derive the key.
Returns The derived key.
Derives a cryptographic key from the <see cref="T:System.Security.Cryptography.PasswordDeriveBytes" /> object.
protected
void
Dispose​(bool disposing)
disposing
<see langword="true" /> to release both managed and unmanaged resources; <see langword="false" /> to release only unmanaged resources.
Releases the unmanaged resources used by the <see cref="T:System.Security.Cryptography.PasswordDeriveBytes" /> class and optionally releases the managed resources.
public
byte[]
GetBytes​(int cb)
cb
The number of pseudo-random key bytes to generate.
Returns A byte array filled with pseudo-random key bytes.
Returns pseudo-random key bytes.
public
void
Reset​()
Resets the state of the operation.
When overridden in a derived class, releases all resources used by the current instance of the <see cref="T:System.Security.Cryptography.DeriveBytes" /> class.
public
bool
Equals​(object obj)
Inherited from object
protected
void
Finalize​()
Inherited from object
public
int
GetHashCode​()
Inherited from object
protected
object
MemberwiseClone​()
Inherited from object
public
string
ToString​()
Inherited from object