Quantcast
Channel: Joomla! Forum - community, help and support
Viewing all articles
Browse latest Browse all 1569

Joomla! 4.x Coding • Re: PHP script coding question

$
0
0
I've been testing and have tried those algorithms that are NOT deprecated. You really have to be careful! Here's the coding which failed again. I'm beginning to think that I'm passing the wrong parameters?

// define algorithm
$algorithm = 'self::HASH_BCRYPT'; // ensure this is a supported algorithm

// if password is set use that
if ($data[23]!='') {
$crypt = UserHelper::hashPassword($data[23], $salt, $algorithm);
}
// otherwise, user first initial and last name
else {
$crypt = UserHelper::hashPassword(strtolower(substr($data[2], 0, 1)) . strtolower($data[4]), $salt, $algorithm);
}

function call:
hashPassword( password, string|int algorithm = self::HASH_BCRYPT, mixed||string|int options = [])

I've tried ARGON2I, and BCRYPT; all others are deprecated except for ARGON2ID

all ideas welcome!

Statistics: Posted by ktwatson — Tue Jul 23, 2024 10:11 pm



Viewing all articles
Browse latest Browse all 1569

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>