Documentation

ArgonHashing extends AbstractHashing

Table of Contents

$memory  : int
The default memory cost.
$threads  : int
The default threads cost.
$time  : int
The default time cost.
$verifyAlgorithm  : bool
Determine whether to perform an algorithm check.
__construct()  : mixed
__construct.
getMemory()  : int
Get the memory.
getThreads()  : int
Get the threads.
getTime()  : int
Get the time.
info()  : array<string|int, mixed>
Get information about the given hash.
make()  : string
Generate the hash.
needsRehash()  : bool
Check if the given hash has been hashed using the given options.
setMemory()  : object
Set the memory.
setThreads()  : object
Set the threads.
setTime()  : object
Set the time.
verify()  : bool
Verify the hash value.
algorithm()  : Constant
Get the algroithm.
algorithmKeys()  : string
Get the algroithm keys.

Properties

$memory

The default memory cost.

private int $memory = 1024
Tags
since
1.0.0

$threads

The default threads cost.

private int $threads = 2
Tags
since
1.0.0

$time

The default time cost.

private int $time = 2
Tags
since
1.0.0

$verifyAlgorithm

Determine whether to perform an algorithm check.

private bool $verifyAlgorithm = false
Tags
since
1.0.0

Methods

__construct()

__construct.

public __construct([array<string|int, mixed> $options = null ]) : mixed
Parameters
$options : array<string|int, mixed> = null
Tags
since
1.0.0
Return values
mixed

getMemory()

Get the memory.

public getMemory() : int
Tags
since
1.0.0
Return values
int

getThreads()

Get the threads.

public getThreads() : int
Tags
since
1.0.0
Return values
int

getTime()

Get the time.

public getTime() : int
Tags
since
1.0.0
Return values
int

info()

Get information about the given hash.

public info((string) $hash) : array<string|int, mixed>
Parameters
$hash : (string)
Tags
since
1.0.0
Return values
array<string|int, mixed>

make()

Generate the hash.

public make(string $original[, array<string|int, mixed> $options = null ]) : string
Parameters
$original : string
$options : array<string|int, mixed> = null
Tags
since
1.0.0
Return values
string

needsRehash()

Check if the given hash has been hashed using the given options.

public needsRehash(string $hash[, array<string|int, mixed> $options = null ]) : bool
Parameters
$hash : string
$options : array<string|int, mixed> = null
Tags
since
1.0.0
Return values
bool

setMemory()

Set the memory.

public setMemory(int $memory) : object
Parameters
$memory : int
Tags
since
1.0.0
Return values
object

setThreads()

Set the threads.

public setThreads(int $threads) : object
Parameters
$threads : int
Tags
since
1.0.0
Return values
object

setTime()

Set the time.

public setTime(int $time) : object
Parameters
$time : int
Tags
since
1.0.0
Return values
object

verify()

Verify the hash value.

public verify(string $original, string $hash) : bool
Parameters
$original : string
$hash : string
Tags
since
1.0.0
Return values
bool

algorithm()

Get the algroithm.

protected algorithm() : Constant
Tags
since
1.0.0
Return values
Constant

algorithmKeys()

Get the algroithm keys.

protected algorithmKeys() : string
Tags
since
1.0.0
Return values
string

Search results