Add `'wp_verify_nonce_failed'` action that fires when nonce verification fails.
props johnbillion, garza, Shelob9. fixes #24030. Built from https://develop.svn.wordpress.org/trunk@33744 git-svn-id: http://core.svn.wordpress.org/trunk@33712 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
b34af5586a
commit
1f4ae40c03
|
@ -1812,6 +1812,18 @@ function wp_verify_nonce( $nonce, $action = -1 ) {
|
|||
return 2;
|
||||
}
|
||||
|
||||
/**
|
||||
* Fires when nonce verification fails.
|
||||
*
|
||||
* @since 4.4.0
|
||||
*
|
||||
* @param string $nonce The invalid nonce.
|
||||
* @param string|int $action The nonce action.
|
||||
* @param WP_User $user The current user object.
|
||||
* @param string $token The user's session token.
|
||||
*/
|
||||
do_action( 'wp_verify_nonce_failed', $nonce, $action, $user, $token );
|
||||
|
||||
// Invalid nonce
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '4.4-alpha-33743';
|
||||
$wp_version = '4.4-alpha-33744';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue