Hashes the given session token for storage.
Parameters
$token
stringrequired- Session token to hash.
Source
private function hash_token( $token ) {
// If ext/hash is not present, use sha1() instead.
if ( function_exists( 'hash' ) ) {
return hash( 'sha256', $token );
} else {
return sha1( $token );
}
}
Changelog
Version | Description |
---|---|
4.0.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.