updated plugin Jetpack Protect version 1.4.0

This commit is contained in:
2023-06-05 11:21:22 +00:00
committed by Gitium
parent b7bbe6d733
commit 63d1d30fa8
115 changed files with 3634 additions and 726 deletions

View File

@ -5,6 +5,14 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [1.47.4] - 2023-03-28
### Changed
- Move brute force protection into WAF package. [#28401]
## [1.47.3] - 2023-03-20
### Changed
- Updated package dependencies. [#29480]
## [1.47.2] - 2023-02-20
### Changed
- Minor internal updates.
@ -818,6 +826,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Packages: Move sync to a classmapped package
[1.47.4]: https://github.com/Automattic/jetpack-sync/compare/v1.47.3...v1.47.4
[1.47.3]: https://github.com/Automattic/jetpack-sync/compare/v1.47.2...v1.47.3
[1.47.2]: https://github.com/Automattic/jetpack-sync/compare/v1.47.1...v1.47.2
[1.47.1]: https://github.com/Automattic/jetpack-sync/compare/v1.47.0...v1.47.1
[1.47.0]: https://github.com/Automattic/jetpack-sync/compare/v1.46.1...v1.47.0

View File

@ -4,12 +4,13 @@
"type": "jetpack-library",
"license": "GPL-2.0-or-later",
"require": {
"automattic/jetpack-connection": "^1.51.0",
"automattic/jetpack-connection": "^1.51.3",
"automattic/jetpack-constants": "^1.6.21",
"automattic/jetpack-identity-crisis": "^0.8.38",
"automattic/jetpack-password-checker": "^0.2.11",
"automattic/jetpack-identity-crisis": "^0.8.40",
"automattic/jetpack-password-checker": "^0.2.12",
"automattic/jetpack-ip": "^0.1.1",
"automattic/jetpack-roles": "^1.4.22",
"automattic/jetpack-status": "^1.16.2"
"automattic/jetpack-status": "^1.16.3"
},
"require-dev": {
"automattic/jetpack-changelogger": "^3.3.2",

View File

@ -8,6 +8,7 @@
namespace Automattic\Jetpack\Sync;
use Automattic\Jetpack\Connection\Manager as Connection_Manager;
use Automattic\Jetpack\IP\Utils as IP_Utils;
use Automattic\Jetpack\Roles;
/**
@ -426,15 +427,9 @@ class Listener {
);
if ( $this->should_send_user_data_with_actor( $current_filter ) ) {
$ip = isset( $_SERVER['REMOTE_ADDR'] ) ? filter_var( wp_unslash( $_SERVER['REMOTE_ADDR'] ) ) : '';
if ( defined( 'JETPACK__PLUGIN_DIR' ) ) {
if ( ! function_exists( 'jetpack_protect_get_ip' ) ) {
require_once JETPACK__PLUGIN_DIR . 'modules/protect/shared-functions.php';
}
$ip = jetpack_protect_get_ip();
}
$ip = IP_Utils::get_ip();
$actor['ip'] = $ip;
$actor['ip'] = $ip ? $ip : '';
$actor['user_agent'] = isset( $_SERVER['HTTP_USER_AGENT'] ) ? filter_var( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ) : 'unknown';
}

View File

@ -12,7 +12,7 @@ namespace Automattic\Jetpack\Sync;
*/
class Package_Version {
const PACKAGE_VERSION = '1.47.2';
const PACKAGE_VERSION = '1.47.4';
const PACKAGE_SLUG = 'sync';

View File

@ -45,8 +45,7 @@ class Protect extends Module {
* @param array $failed_attempt Failed attempt data.
*/
public function maybe_log_failed_login_attempt( $failed_attempt ) {
$protect = \Jetpack_Protect_Module::instance();
if ( $protect->has_login_ability() && ! Jetpack_Constants::is_true( 'XMLRPC_REQUEST' ) ) {
if ( $failed_attempt['has_login_ability'] && ! Jetpack_Constants::is_true( 'XMLRPC_REQUEST' ) ) {
do_action( 'jetpack_valid_failed_login_attempt', $failed_attempt );
}
}