PluginProbe
Jetpack – WP Security, Backup, Speed, & Growth / 6.3.7
Jetpack – WP Security, Backup, Speed, & Growth v6.3.7
16.2-beta 12.0.3 12.1.3 12.2.3 12.3.2 12.4.2 12.5.2 12.6.4 12.7.3 12.8.3 12.9.5 13.0.2 13.1.5 13.2.4 13.3.3 13.4.5 13.5.2 13.6.2 13.7.2 13.8.3 13.9.2 14.0.1 14.1.1 14.2.2 14.3.1 All 501 releases
jetpack / sync / class.jetpack-sync-module-protect.php

class.jetpack-sync-module-protect.php in Jetpack – WP Security, Backup, Speed, & Growth 6.3.7, at sync/class.jetpack-sync-module-protect.php

24 lines 652 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 /**
4 * logs bruteprotect failed logins via sync
5 */
6 class Jetpack_Sync_Module_Protect extends Jetpack_Sync_Module {
7
8 function name() {
9 return 'protect';
10 }
11
12 function init_listeners( $callback ) {
13 add_action( 'jpp_log_failed_attempt', array( $this, 'maybe_log_failed_login_attempt' ) );
14 add_action( 'jetpack_valid_failed_login_attempt', $callback );
15 }
16
17 function maybe_log_failed_login_attempt( $failed_attempt ) {
18 $protect = Jetpack_Protect_Module::instance();
19 if ( $protect->has_login_ability() && ! Jetpack_Constants::is_true( 'XMLRPC_REQUEST' ) ) {
20 do_action( 'jetpack_valid_failed_login_attempt', $failed_attempt );
21 }
22 }
23 }
24