at path:
ROOT
/
wp-content
/
plugins
/
jetpack
/
class.jetpack-client-server.php
run:
R
W
Run
3rd-party
DIR
2026-04-17 06:07:54
R
W
Run
_inc
DIR
2026-04-17 06:07:56
R
W
Run
css
DIR
2026-04-17 06:07:54
R
W
Run
extensions
DIR
2026-04-17 06:07:53
R
W
Run
images
DIR
2026-04-17 06:07:55
R
W
Run
jetpack_vendor
DIR
2026-04-17 06:07:58
R
W
Run
json-endpoints
DIR
2026-04-17 06:07:59
R
W
Run
modules
DIR
2026-04-17 06:07:59
R
W
Run
sal
DIR
2026-04-17 06:07:59
R
W
Run
src
DIR
2026-04-17 06:07:59
R
W
Run
vendor
DIR
2026-04-17 06:07:59
R
W
Run
views
DIR
2026-04-17 06:07:54
R
W
Run
CHANGELOG.md
766.64 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
LICENSE.txt
18.2 KB
2026-04-17 06:07:59
R
W
Run
Delete
Rename
SECURITY.md
2.45 KB
2026-04-17 06:07:59
R
W
Run
Delete
Rename
class-jetpack-connection-status.php
728 By
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class-jetpack-gallery-settings.php
3.47 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class-jetpack-newsletter-dashboard-widget.php
436 By
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class-jetpack-pre-connection-jitms.php
2.34 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class-jetpack-stats-dashboard-widget.php
7.46 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class-jetpack-xmlrpc-methods.php
7.38 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.frame-nonce-preview.php
3.22 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-admin.php
21.09 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-autoupdate.php
9.93 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-cli.php
74.32 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-client-server.php
2.62 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-gutenberg.php
45.32 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-heartbeat.php
4.44 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-modules-list-table.php
14.81 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-network-sites-list-table.php
6.03 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-network.php
22.19 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-plan.php
4.09 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-post-images.php
11.72 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-twitter-cards.php
5.69 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack-user-agent.php
25.3 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.jetpack.php
204.86 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.json-api-endpoints.php
91.36 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.json-api.php
38.3 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
class.photon.php
1.74 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
composer.json
4.25 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
enhanced-open-graph.php
4.71 KB
2026-04-17 06:07:54
R
W
Run
Delete
Rename
functions.compat.php
4.34 KB
2026-04-17 06:07:55
R
W
Run
Delete
Rename
functions.cookies.php
2.04 KB
2026-04-17 06:07:55
R
W
Run
Delete
Rename
functions.global.php
13.91 KB
2026-04-17 06:07:55
R
W
Run
Delete
Rename
functions.is-mobile.php
2.47 KB
2026-04-17 06:07:55
R
W
Run
Delete
Rename
functions.opengraph.php
30.99 KB
2026-04-17 06:07:55
R
W
Run
Delete
Rename
functions.photon.php
3.04 KB
2026-04-17 06:07:55
R
W
Run
Delete
Rename
jetpack.php
8.92 KB
2026-04-17 06:07:56
R
W
Run
Delete
Rename
json-api-config.php
338 By
2026-04-17 06:07:58
R
W
Run
Delete
Rename
json-endpoints.php
6.92 KB
2026-04-17 06:07:59
R
W
Run
Delete
Rename
load-jetpack.php
3.69 KB
2026-04-17 06:07:59
R
W
Run
Delete
Rename
locales.php
371 By
2026-04-17 06:07:59
R
W
Run
Delete
Rename
readme.txt
33.15 KB
2026-04-17 06:07:59
R
W
Run
Delete
Rename
unauth-file-upload.php
5.85 KB
2026-04-17 06:07:59
R
W
Run
Delete
Rename
uninstall.php
1.65 KB
2026-04-17 06:07:59
R
W
Run
Delete
Rename
wpml-config.xml
1.26 KB
2026-04-17 06:07:59
R
W
Run
Delete
Rename
error_log
up
📄
class.jetpack-client-server.php
Save
<?php // phpcs:ignore WordPress.Files.FileName.InvalidClassFileName /** * Client = Plugin * Client Server = API Methods the Plugin must respond to * * @package automattic/jetpack */ /** * Client = Plugin * Client Server = API Methods the Plugin must respond to */ class Jetpack_Client_Server { /** * Whether the class has been initialized. * * @var bool */ private static $did_init = false; /** * Initialize the hooks, but only once. * * @return void */ public static function init() { if ( static::$did_init ) { return; } add_filter( 'jetpack_rest_connection_check_response', array( static::class, 'connection_check' ) ); static::$did_init = true; } /** * Handle the client authorization error. * * @param WP_Error $error The error object. */ public static function client_authorize_error( $error ) { if ( $error instanceof WP_Error ) { Jetpack::state( 'error', $error->get_error_code() ); } } /** * The user is already authorized, we set the Jetpack state and adjust the redirect URL. * * @return string */ public static function client_authorize_already_authorized_url() { Jetpack::state( 'message', 'already_authorized' ); return Jetpack::admin_url(); } /** * The authorization processing has started. */ public static function client_authorize_processing() { Jetpack::log( 'authorize' ); } /** * The authorization has completed (successfully or not), and the redirect URL is empty. * We set the Jetpack Dashboard as the default URL. * * @return string */ public static function client_authorize_fallback_url() { return Jetpack::admin_url(); } /** * Deactivate a plugin. * * @param string $probable_file Expected plugin file. * @param string $probable_title Expected plugin title. * @return int 1 if a plugin was deactivated, 0 if not. */ public static function deactivate_plugin( $probable_file, $probable_title ) { include_once ABSPATH . 'wp-admin/includes/plugin.php'; if ( is_plugin_active( $probable_file ) ) { deactivate_plugins( $probable_file ); return 1; } else { // If the plugin is not in the usual place, try looking through all active plugins. $active_plugins = Jetpack::get_active_plugins(); foreach ( $active_plugins as $plugin ) { $data = get_plugin_data( WP_PLUGIN_DIR . '/' . $plugin ); if ( $data['Name'] === $probable_title ) { deactivate_plugins( $plugin ); return 1; } } } return 0; } /** * Filters the result of test_connection REST method * * @return string The current Jetpack version number */ public static function connection_check() { return JETPACK__VERSION; } }