XenForo::authenticate_pass( $password, $serialized_pass )
This method is to take the pass out of the database and compare to a pass the user has typed in.
Description
Source
File: bp-forums/admin/converters/XenForo.php
public function authenticate_pass( $password, $serialized_pass )
{
$pass_array = unserialize( $serialized_pass );
switch( $pass_array['hashFunc'] )
{
case 'sha256':
return ( $pass_array['hash'] == hash( 'sha256', hash( 'sha256', $password ) . $pass_array['salt'] ) );
case 'sha1':
return ( $pass_array['hash'] == sha1( sha1( $password ) . $pass_array['salt'] ) );
}
}
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.