Scrypt key derivation function

see
see
package Default

 Methods

Execute the scrypt algorithm

calc(string $password, string $salt, integer $n, integer $r, integer $p, integer $length) : string
Static

Parameters

$password

string

$salt

string

$n

integer

CPU cost

$r

integer

Memory cost

$p

integer

parallelization cost

$length

integer

size of the output key

Returns

string

Convert hex string in a binary string

hex2bin(string $hex) : string
Static

Parameters

$hex

string

Returns

string

Integerify

integerify(string $b) : integer
Static

Integerify (B[0] ... B[2 r - 1]) is defined as the result of interpreting B[2 r - 1] as a little-endian integer. Each block B is a string of 64 bytes.

see

Parameters

$b

string

Returns

integer

Salsa 20/8 core (32 bit version)

salsa208Core32(string $b) : string
Static
see
see

Parameters

$b

string

Returns

string

Salsa 20/8 core (64 bit version)

salsa208Core64(string $b) : string
Static
see
see

Parameters

$b

string

Returns

string

scryptBlockMix

scryptBlockMix(string $b, integer $r) : string
Static
see

Parameters

$b

string

$r

integer

Returns

string

scryptROMix

scryptROMix(string $b, integer $n, integer $r) : string
Static
see

Parameters

$b

string

$n

integer

$r

integer

Returns

string