updated plugin Jetpack Protect
version 2.0.0
This commit is contained in:
wp-content/plugins/jetpack-protect
CHANGELOG.mdi18n-map.phpreadme.txt
build
composer.jsonjetpack-protect.phpjetpack_vendor
automattic
jetpack-a8c-mc-stats
jetpack-admin-ui
jetpack-assets
jetpack-backup-helper-script-manager
jetpack-config
jetpack-connection
jetpack-constants
jetpack-device-detection
jetpack-identity-crisis
jetpack-ip
jetpack-jitm
jetpack-licensing
jetpack-logo
jetpack-my-jetpack
CHANGELOG.mdcomposer.json
build
images
jetpack-ai-1a265a198f75543e342e.pngjetpack-ai-29e60474d5890cbb6889.pngjetpack-manage-3a7ecaa604823c98c3cf.svgsite-cards-143fca7aec7a8c370e82.pngsocial-e3fb80b2f32534fefe63.pngstats-9802380852610a4d5908.png
index.asset.phpindex.cssindex.jsindex.rtl.csssrc
jetpack-partner
jetpack-password-checker
jetpack-plugins-installer
jetpack-redirect
jetpack-roles
jetpack-status
jetpack-sync
CHANGELOG.mdcomposer.json
src
jetpack-transport-helper
jetpack-waf
src
vendor
autoload.phpautoload_packages.php
automattic
jetpack-plans
composer
autoload_classmap.phpautoload_real.phpautoload_static.phpinstalled.jsoninstalled.phpjetpack_autoload_classmap.phpjetpack_autoload_filemap.phpplatform_check.php
jetpack-autoloader
class-autoloader-handler.phpclass-autoloader-locator.phpclass-autoloader.phpclass-container.phpclass-hook-manager.phpclass-latest-autoloader-guard.phpclass-manifest-reader.phpclass-path-processor.phpclass-php-autoloader.phpclass-plugin-locator.phpclass-plugins-handler.phpclass-shutdown-handler.phpclass-version-loader.phpclass-version-selector.php
18
wp-content/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/CHANGELOG.md
18
wp-content/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/CHANGELOG.md
@ -5,6 +5,20 @@ 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).
|
||||
|
||||
## [2.0.1] - 2023-11-21
|
||||
### Changed
|
||||
- Added a note of non-usage of PHP8+ functions yet. [#34137]
|
||||
|
||||
## [2.0.0] - 2023-11-20
|
||||
### Changed
|
||||
- Updated required PHP version to >= 7.0. [#34192]
|
||||
|
||||
## [1.5.1] - 2023-11-14
|
||||
|
||||
## [1.5.0] - 2023-11-13
|
||||
### Added
|
||||
- Added 'cookieinformationscanner' and 'facebookexternalhit' to the bot user agent list. [#34026]
|
||||
|
||||
## [1.4.27] - 2023-08-23
|
||||
### Changed
|
||||
- Updated package dependencies. [#32605]
|
||||
@ -163,6 +177,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
|
||||
- Moving jetpack_is_mobile into a package
|
||||
|
||||
[2.0.1]: https://github.com/Automattic/jetpack-device-detection/compare/v2.0.0...v2.0.1
|
||||
[2.0.0]: https://github.com/Automattic/jetpack-device-detection/compare/v1.5.1...v2.0.0
|
||||
[1.5.1]: https://github.com/Automattic/jetpack-device-detection/compare/v1.5.0...v1.5.1
|
||||
[1.5.0]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.27...v1.5.0
|
||||
[1.4.27]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.26...v1.4.27
|
||||
[1.4.26]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.25...v1.4.26
|
||||
[1.4.25]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.24...v1.4.25
|
||||
|
13
wp-content/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/SECURITY.md
13
wp-content/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/SECURITY.md
@ -4,11 +4,20 @@ Full details of the Automattic Security Policy can be found on [automattic.com](
|
||||
|
||||
## Supported Versions
|
||||
|
||||
Generally, only the latest version of Jetpack has continued support. If a critical vulnerability is found in the current version of Jetpack, we may opt to backport any patches to previous versions.
|
||||
Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions.
|
||||
|
||||
## Reporting a Vulnerability
|
||||
|
||||
[Jetpack](https://jetpack.com/) is an open-source plugin for WordPress. Our HackerOne program covers the plugin software, as well as a variety of related projects and infrastructure.
|
||||
Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure:
|
||||
|
||||
* [Jetpack](https://jetpack.com/)
|
||||
* Jetpack Backup
|
||||
* Jetpack Boost
|
||||
* Jetpack CRM
|
||||
* Jetpack Protect
|
||||
* Jetpack Search
|
||||
* Jetpack Social
|
||||
* Jetpack VideoPress
|
||||
|
||||
**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.**
|
||||
|
||||
|
8
wp-content/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/composer.json
8
wp-content/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/composer.json
@ -3,10 +3,12 @@
|
||||
"description": "A way to detect device types based on User-Agent header.",
|
||||
"type": "jetpack-library",
|
||||
"license": "GPL-2.0-or-later",
|
||||
"require": {},
|
||||
"require": {
|
||||
"php": ">=7.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"yoast/phpunit-polyfills": "1.1.0",
|
||||
"automattic/jetpack-changelogger": "^3.3.8"
|
||||
"automattic/jetpack-changelogger": "^4.0.2"
|
||||
},
|
||||
"suggest": {
|
||||
"automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package."
|
||||
@ -33,7 +35,7 @@
|
||||
"link-template": "https://github.com/Automattic/jetpack-device-detection/compare/v${old}...v${new}"
|
||||
},
|
||||
"branch-alias": {
|
||||
"dev-trunk": "1.4.x-dev"
|
||||
"dev-trunk": "2.0.x-dev"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -17,6 +17,9 @@ use function Automattic\Jetpack\Device_Detection\wp_unslash;
|
||||
* Class Device_Detection
|
||||
*
|
||||
* Determine if the current User Agent matches the passed $kind.
|
||||
*
|
||||
* Note: str_contains() and other PHP8+ functions that have a polyfill in core are not used here,
|
||||
* as wp-includes/compat.php may not be loaded yet.
|
||||
*/
|
||||
class Device_Detection {
|
||||
|
||||
|
@ -17,6 +17,9 @@ require_once __DIR__ . '/functions.php';
|
||||
|
||||
/**
|
||||
* A class providing device properties detection.
|
||||
*
|
||||
* Note: str_contains() and other PHP8+ functions that have a polyfill in core are not used here,
|
||||
* as wp-includes/compat.php may not be loaded yet.
|
||||
*/
|
||||
class User_Agent_Info {
|
||||
|
||||
@ -147,63 +150,63 @@ class User_Agent_Info {
|
||||
* @return string The matched User Agent name, false otherwise.
|
||||
*/
|
||||
public function get_mobile_user_agent_name() {
|
||||
if ( $this->is_chrome_for_iOS() ) { // Keep this check before the safari rule.
|
||||
if ( static::is_chrome_for_iOS() ) { // Keep this check before the safari rule.
|
||||
return 'chrome-for-ios';
|
||||
} elseif ( $this->is_iphone_or_ipod( 'iphone-safari' ) ) {
|
||||
} elseif ( static::is_iphone_or_ipod( 'iphone-safari' ) ) {
|
||||
return 'iphone';
|
||||
} elseif ( $this->is_ipad( 'ipad-safari' ) ) {
|
||||
} elseif ( static::is_ipad( 'ipad-safari' ) ) {
|
||||
return 'ipad';
|
||||
} elseif ( $this->is_android_tablet() ) { // Keep this check before the android rule.
|
||||
} elseif ( static::is_android_tablet() ) { // Keep this check before the android rule.
|
||||
return 'android_tablet';
|
||||
} elseif ( $this->is_android() ) {
|
||||
} elseif ( static::is_android() ) {
|
||||
return 'android';
|
||||
} elseif ( $this->is_blackberry_10() ) {
|
||||
} elseif ( static::is_blackberry_10() ) {
|
||||
return 'blackberry_10';
|
||||
} elseif ( $this->is_blackbeberry() ) {
|
||||
} elseif ( static::is_blackbeberry() ) {
|
||||
return 'blackberry';
|
||||
} elseif ( $this->is_WindowsPhone7() ) {
|
||||
} elseif ( static::is_WindowsPhone7() ) {
|
||||
return 'win7';
|
||||
} elseif ( $this->is_windows_phone_8() ) {
|
||||
} elseif ( static::is_windows_phone_8() ) {
|
||||
return 'winphone8';
|
||||
} elseif ( $this->is_opera_mini() ) {
|
||||
} elseif ( static::is_opera_mini() ) {
|
||||
return 'opera-mini';
|
||||
} elseif ( $this->is_opera_mini_dumb() ) {
|
||||
} elseif ( static::is_opera_mini_dumb() ) {
|
||||
return 'opera-mini-dumb';
|
||||
} elseif ( $this->is_opera_mobile() ) {
|
||||
} elseif ( static::is_opera_mobile() ) {
|
||||
return 'opera-mobi';
|
||||
} elseif ( $this->is_blackberry_tablet() ) {
|
||||
} elseif ( static::is_blackberry_tablet() ) {
|
||||
return 'blackberry_tablet';
|
||||
} elseif ( $this->is_kindle_fire() ) {
|
||||
} elseif ( static::is_kindle_fire() ) {
|
||||
return 'kindle-fire';
|
||||
} elseif ( $this->is_PalmWebOS() ) {
|
||||
} elseif ( static::is_PalmWebOS() ) {
|
||||
return 'webos';
|
||||
} elseif ( $this->is_S60_OSSBrowser() ) {
|
||||
} elseif ( static::is_S60_OSSBrowser() ) {
|
||||
return 'series60';
|
||||
} elseif ( $this->is_firefox_os() ) {
|
||||
} elseif ( static::is_firefox_os() ) {
|
||||
return 'firefoxOS';
|
||||
} elseif ( $this->is_firefox_mobile() ) {
|
||||
} elseif ( static::is_firefox_mobile() ) {
|
||||
return 'firefox_mobile';
|
||||
} elseif ( $this->is_MaemoTablet() ) {
|
||||
} elseif ( static::is_MaemoTablet() ) {
|
||||
return 'maemo';
|
||||
} elseif ( $this->is_MeeGo() ) {
|
||||
} elseif ( static::is_MeeGo() ) {
|
||||
return 'meego';
|
||||
} elseif ( $this->is_TouchPad() ) {
|
||||
} elseif ( static::is_TouchPad() ) {
|
||||
return 'hp_tablet';
|
||||
} elseif ( $this->is_facebook_for_iphone() ) {
|
||||
} elseif ( static::is_facebook_for_iphone() ) {
|
||||
return 'facebook-for-iphone';
|
||||
} elseif ( $this->is_facebook_for_ipad() ) {
|
||||
} elseif ( static::is_facebook_for_ipad() ) {
|
||||
return 'facebook-for-ipad';
|
||||
} elseif ( $this->is_twitter_for_iphone() ) {
|
||||
} elseif ( static::is_twitter_for_iphone() ) {
|
||||
return 'twitter-for-iphone';
|
||||
} elseif ( $this->is_twitter_for_ipad() ) {
|
||||
} elseif ( static::is_twitter_for_ipad() ) {
|
||||
return 'twitter-for-ipad';
|
||||
} elseif ( $this->is_wordpress_for_ios() ) {
|
||||
} elseif ( static::is_wordpress_for_ios() ) {
|
||||
return 'ios-app';
|
||||
} elseif ( $this->is_iphone_or_ipod( 'iphone-not-safari' ) ) {
|
||||
} elseif ( static::is_iphone_or_ipod( 'iphone-not-safari' ) ) {
|
||||
return 'iphone-unknown';
|
||||
} elseif ( $this->is_ipad( 'ipad-not-safari' ) ) {
|
||||
} elseif ( static::is_ipad( 'ipad-not-safari' ) ) {
|
||||
return 'ipad-unknown';
|
||||
} elseif ( $this->is_Nintendo_3DS() ) {
|
||||
} elseif ( static::is_Nintendo_3DS() ) {
|
||||
return 'nintendo-3ds';
|
||||
} else {
|
||||
$agent = $this->useragent;
|
||||
@ -245,26 +248,26 @@ class User_Agent_Info {
|
||||
} elseif ( strpos( $this->useragent, 'iphone' ) !== false ) {
|
||||
$this->platform = self::PLATFORM_IPHONE;
|
||||
} elseif ( strpos( $this->useragent, 'android' ) !== false ) {
|
||||
if ( $this->is_android_tablet() ) {
|
||||
if ( static::is_android_tablet() ) {
|
||||
$this->platform = self::PLATFORM_ANDROID_TABLET;
|
||||
} else {
|
||||
$this->platform = self::PLATFORM_ANDROID;
|
||||
}
|
||||
} elseif ( $this->is_kindle_fire() ) {
|
||||
} elseif ( static::is_kindle_fire() ) {
|
||||
$this->platform = self::PLATFORM_ANDROID_TABLET;
|
||||
} elseif ( $this->is_blackberry_10() ) {
|
||||
} elseif ( static::is_blackberry_10() ) {
|
||||
$this->platform = self::PLATFORM_BLACKBERRY_10;
|
||||
} elseif ( strpos( $this->useragent, 'blackberry' ) !== false ) {
|
||||
$this->platform = self::PLATFORM_BLACKBERRY;
|
||||
} elseif ( $this->is_blackberry_tablet() ) {
|
||||
} elseif ( static::is_blackberry_tablet() ) {
|
||||
$this->platform = self::PLATFORM_BLACKBERRY;
|
||||
} elseif ( $this->is_symbian_platform() ) {
|
||||
} elseif ( static::is_symbian_platform() ) {
|
||||
$this->platform = self::PLATFORM_SYMBIAN;
|
||||
} elseif ( $this->is_symbian_s40_platform() ) {
|
||||
} elseif ( static::is_symbian_s40_platform() ) {
|
||||
$this->platform = self::PLATFORM_SYMBIAN_S40;
|
||||
} elseif ( $this->is_J2ME_platform() ) {
|
||||
} elseif ( static::is_J2ME_platform() ) {
|
||||
$this->platform = self::PLATFORM_J2ME_MIDP;
|
||||
} elseif ( $this->is_firefox_os() ) {
|
||||
} elseif ( static::is_firefox_os() ) {
|
||||
$this->platform = self::PLATFORM_FIREFOX_OS;
|
||||
} else {
|
||||
$this->platform = false;
|
||||
@ -286,77 +289,77 @@ class User_Agent_Info {
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_android() ) {
|
||||
} elseif ( static::is_android() ) {
|
||||
$this->matched_agent = 'android';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_windows_phone_8() ) {
|
||||
} elseif ( static::is_windows_phone_8() ) {
|
||||
$this->matched_agent = 'winphone8';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_WindowsPhone7() ) {
|
||||
} elseif ( static::is_WindowsPhone7() ) {
|
||||
$this->matched_agent = 'win7';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_blackberry_10() ) {
|
||||
} elseif ( static::is_blackberry_10() ) {
|
||||
$this->matched_agent = 'blackberry-10';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_blackbeberry() && 'blackberry-webkit' === $this->detect_blackberry_browser_version() ) {
|
||||
} elseif ( static::is_blackbeberry() && 'blackberry-webkit' === static::detect_blackberry_browser_version() ) {
|
||||
$this->matched_agent = 'blackberry-webkit';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_blackberry_tablet() ) {
|
||||
} elseif ( static::is_blackberry_tablet() ) {
|
||||
$this->matched_agent = 'blackberry_tablet';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_PalmWebOS() ) {
|
||||
} elseif ( static::is_PalmWebOS() ) {
|
||||
$this->matched_agent = 'webos';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_TouchPad() ) {
|
||||
} elseif ( static::is_TouchPad() ) {
|
||||
$this->matched_agent = 'hp_tablet';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_firefox_os() ) {
|
||||
} elseif ( static::is_firefox_os() ) {
|
||||
$this->matched_agent = 'firefoxOS';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_firefox_mobile() ) {
|
||||
} elseif ( static::is_firefox_mobile() ) {
|
||||
$this->matched_agent = 'fennec';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_opera_mobile() ) {
|
||||
} elseif ( static::is_opera_mobile() ) {
|
||||
$this->matched_agent = 'opera-mobi';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_MaemoTablet() ) {
|
||||
} elseif ( static::is_MaemoTablet() ) {
|
||||
$this->matched_agent = 'maemo';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_MeeGo() ) {
|
||||
} elseif ( static::is_MeeGo() ) {
|
||||
$this->matched_agent = 'meego';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_kindle_touch() ) {
|
||||
} elseif ( static::is_kindle_touch() ) {
|
||||
$this->matched_agent = 'kindle-touch';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_Nintendo_3DS() ) {
|
||||
} elseif ( static::is_Nintendo_3DS() ) {
|
||||
$this->matched_agent = 'nintendo-3ds';
|
||||
$this->isTierIphone = true;
|
||||
$this->isTierRichCss = false;
|
||||
@ -381,18 +384,18 @@ class User_Agent_Info {
|
||||
}
|
||||
|
||||
// The following devices are explicitly ok.
|
||||
if ( $this->is_S60_OSSBrowser() ) {
|
||||
if ( static::is_S60_OSSBrowser() ) {
|
||||
$this->matched_agent = 'series60';
|
||||
$this->isTierIphone = false;
|
||||
$this->isTierRichCss = true;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_opera_mini() ) {
|
||||
} elseif ( static::is_opera_mini() ) {
|
||||
$this->matched_agent = 'opera-mini';
|
||||
$this->isTierIphone = false;
|
||||
$this->isTierRichCss = true;
|
||||
$this->isTierGenericMobile = false;
|
||||
} elseif ( $this->is_blackbeberry() ) {
|
||||
$detectedDevice = $this->detect_blackberry_browser_version();
|
||||
} elseif ( static::is_blackbeberry() ) {
|
||||
$detectedDevice = static::detect_blackberry_browser_version();
|
||||
if (
|
||||
'blackberry-5' === $detectedDevice
|
||||
|| 'blackberry-4.7' === $detectedDevice
|
||||
@ -1559,6 +1562,8 @@ class User_Agent_Info {
|
||||
'domaintunocrawler',
|
||||
'grapeshotcrawler',
|
||||
'cloudflare-alwaysonline',
|
||||
'cookieinformationscanner', // p1699315886066389-slack-C0438NHCLSY
|
||||
'facebookexternalhit', // https://www.facebook.com/externalhit_uatext.php
|
||||
);
|
||||
|
||||
foreach ( $bot_agents as $bot_agent ) {
|
||||
|
Reference in New Issue
Block a user