Click or drag to resize

PbeScrypt(Int32, String, String, Int32, Int32, Int32) Method

Derives a key in hex format from a password with the salt in hex format

Namespace: CryptoSysPKI
Assembly: diCrSysPKINet (in diCrSysPKINet.dll) Version: 23.0.0.30549 (23.1.0.0)
Syntax
public static string Scrypt(
	int dkLen,
	string pwdStr,
	string saltHex,
	int N,
	int r,
	int p
)

Parameters

dkLen  Int32
Required length of key in bytes
pwdStr  String
Password (normal text)
saltHex  String
Salt in hex format
N  Int32
CPU/Memory cost parameter, a number greater than one and a power of 2.
r  Int32
Block size r
p  Int32
Parallelization parameter p

Return Value

String
Key in hex format
Remarks
Password pwdStr is normal text, not hexadecimal
Example
C#
string keyHex = Pbe.Scrypt(64, "password", "4E61436C", 1024, 8, 16);
See Also