Action hook 'application_password_failed_authentication'

in WP Core File wp-includes/user.php at line 508

View Source

application_password_failed_authentication

Action Hook
Description
Fires after an application password was used for authentication.

Hook Information

File Location wp-includes/user.php View on GitHub
Hook Type Action
Line Number 508

Hook Parameters

Type Name Description
WP_User $user The user who was authenticated.
array $item The application password used.

Usage Examples

Basic Usage
<?php
// Hook into application_password_failed_authentication
add_action('application_password_failed_authentication', 'my_custom_function', 10, 2);

function my_custom_function($user, $item) {
    // Your custom code here
}

Source Code Context

wp-includes/user.php:508 - How this hook is used in WordPress core
<?php
 503  		'incorrect_password',
 504  		__( 'The provided password is an invalid application password.' )
 505  	);
 506  
 507  	/** This action is documented in wp-includes/user.php */
 508  	do_action( 'application_password_failed_authentication', $error );
 509  
 510  	return $error;
 511  }
 512  
 513  /**

PHP Documentation

<?php
/**
		 * Fires after an application password was used for authentication.
		 *
		 * @since 5.6.0
		 *
		 * @param WP_User $user The user who was authenticated.
		 * @param array   $item The application password used.
		 */
Quick Info
  • Hook Type: Action
  • Parameters: 2
  • File: wp-includes/user.php
Related Hooks

Related hooks will be displayed here in future updates.