Hash configuration

This commit is contained in:
Marcin Łojewski
2018-07-10 22:19:50 +02:00
parent 50da49c820
commit 924886dd9a
9 changed files with 105 additions and 2 deletions

View File

@@ -100,6 +100,27 @@ class CryptArgon2 extends AbstractAlgorithm
);
}
/**
* @inheritdoc
*/
public function configuration()
{
return [
[
"name" => "memoryCost", "visible_name" => "Memory cost (KiB)",
"default" => PASSWORD_ARGON2_DEFAULT_MEMORY_COST, "min" => 1, "max" => 1048576
],
[
"name" => "timeCost", "visible_name" => "Time cost",
"default" => PASSWORD_ARGON2_DEFAULT_TIME_COST, "min" => 1, "max" => 1024
],
[
"name" => "threads", "visible_name" => "Threads",
"default" => PASSWORD_ARGON2_DEFAULT_THREADS, "min" => 1, "max" => 1024
]
];
}
/**
* @inheritdoc
*/