Changeset 59803 for trunk/src/wp-includes/pluggable.php
- Timestamp:
- 02/11/2025 11:12:03 AM (2 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/pluggable.php
r59754 r59803 773 773 $key = wp_hash( $username . '|' . $pass_frag . '|' . $expiration . '|' . $token, $scheme ); 774 774 775 // If ext/hash is not present, compat.php's hash_hmac() does not support sha256. 776 $algo = function_exists( 'hash' ) ? 'sha256' : 'sha1'; 777 $hash = hash_hmac( $algo, $username . '|' . $expiration . '|' . $token, $key ); 775 $hash = hash_hmac( 'sha256', $username . '|' . $expiration . '|' . $token, $key ); 778 776 779 777 if ( ! hash_equals( $hash, $hmac ) ) { … … 876 874 $key = wp_hash( $user->user_login . '|' . $pass_frag . '|' . $expiration . '|' . $token, $scheme ); 877 875 878 // If ext/hash is not present, compat.php's hash_hmac() does not support sha256. 879 $algo = function_exists( 'hash' ) ? 'sha256' : 'sha1'; 880 $hash = hash_hmac( $algo, $user->user_login . '|' . $expiration . '|' . $token, $key ); 876 $hash = hash_hmac( 'sha256', $user->user_login . '|' . $expiration . '|' . $token, $key ); 881 877 882 878 $cookie = $user->user_login . '|' . $expiration . '|' . $token . '|' . $hash;
Note: See TracChangeset
for help on using the changeset viewer.