wphooks.info - auth_cookie_bad_username

auth_cookie_bad_username

(trunk - 5.0-alpha-43304)

The hook occurs in the following file:

wp-includes/pluggable.php:
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
		$user = get_user_by( 'login', $username );
		if ( ! $user ) {
			/**
			 * Fires if a bad username is entered in the user authentication process.
			 *
			 * @since 2.7.0
			 *
			 * @param array $cookie_elements An array of data for the authentication cookie.
			 */
			do_action( 'auth_cookie_bad_username', $cookie_elements );
			return false;
		}

		$pass_frag = substr( $user->user_pass, 8, 4 );

		$key = wp_hash( $username . '|' . $pass_frag . '|' . $expiration . '|' . $token, $scheme );

		// If ext/hash is not present, compat.php's hash_hmac() does not support sha256.
		$algo = function_exists( 'hash' ) ? 'sha256' : 'sha1';