use crypto params

This commit is contained in:
Marcin Łojewski
2018-12-26 12:38:37 +01:00
parent 2da835b017
commit 3b586365a7

View File

@@ -343,7 +343,12 @@ final class UserBackend extends ABackend implements
private function getPasswordAlgorithm() private function getPasswordAlgorithm()
{ {
$cryptoType = $this->properties[Opt::CRYPTO_CLASS]; $cryptoType = $this->properties[Opt::CRYPTO_CLASS];
$passwordAlgorithm = new $cryptoType($this->localization); $cryptoParam0 = $this->properties[Opt::CRYPTO_PARAM_0];
$cryptoParam1 = $this->properties[Opt::CRYPTO_PARAM_1];
$cryptoParam2 = $this->properties[Opt::CRYPTO_PARAM_2];
$passwordAlgorithm = new $cryptoType(
$this->localization, $cryptoParam0, $cryptoParam1, $cryptoParam2
);
if ($passwordAlgorithm === null) { if ($passwordAlgorithm === null) {
$this->logger->error( $this->logger->error(