AnonSec Shell
Server IP : 172.67.157.199  /  Your IP : 3.142.54.94   [ Reverse IP ]
Web Server : Apache
System : Linux b70eb322-3aee-0c53-7c82-0db91281f2c6.secureserver.net 6.1.90-1.el9.elrepo.x86_64 #1 SMP PREEMPT_DYNAMIC Thu May 2 12:09:22 EDT 2024 x86_64
User : root ( 0)
PHP Version : 8.0.30.2
Disable Function : NONE
Domains : 0 Domains
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /var/chroot/var/www/wp-content/plugins/defender-security/src/controller/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     [ BACKUP SHELL ]     [ JUMPING ]     [ MASS DEFACE ]     [ SCAN ROOT ]     [ SYMLINK ]     

Current File : /var/chroot/var/www/wp-content/plugins/defender-security/src/controller/class-general-notice.php
<?php
/**
 * Displays common data on different plugin pages, such as a notice about extended IP detection logic.
 *
 * @package WP_Defender\Controller
 */

namespace WP_Defender\Controller;

use WP_Defender\Controller;
use Calotes\Component\Response;

/**
 * Displays common data on different plugin pages, e.g. a notice about extended IP detection logic.
 *
 * @since 4.4.2
 */
class General_Notice extends Controller {

	public const IP_DETECTION_SLUG = 'wd_show_ip_detection_notice';

	/**
	 * Initializes the model and service, registers routes, and sets up scheduled events if the model is active.
	 */
	public function __construct() {
		$this->register_routes();
	}

	/**
	 * Get the notice data.
	 *
	 * @return array
	 */
	public function get_notice_data(): array {
		$result = $this->dump_routes_and_nonces();

		return array(
			'routes' => $result['routes'],
			'nonces' => $result['nonces'],
		);
	}

	/**
	 * Close the IP detection notice.
	 *
	 * @return Response
	 * @defender_route
	 */
	public function close_ip_detection_notice(): Response {
		self::delete_slugs();

		return new Response( true, array() );
	}

	/**
	 * Delete the IP detection slug.
	 */
	public static function delete_slugs(): void {
		delete_site_option( self::IP_DETECTION_SLUG );
	}

	/**
	 * Check if the notice should be shown.
	 *
	 * @return bool
	 */
	public function show_notice(): bool {
		return (bool) get_site_option( self::IP_DETECTION_SLUG );
	}


	/**
	 * Delete all the data & the cache.
	 */
	public function remove_data() {
	}

	/**
	 * Exports strings.
	 *
	 * @return array An array of strings.
	 */
	public function export_strings(): array {
		return array();
	}

	/**
	 * Converts the current object state to an array.
	 *
	 * @return array The array representation of the object.
	 */
	public function to_array(): array {
		return array();
	}

	/**
	 * Imports data into the model.
	 *
	 * @param  array $data  Data to be imported into the model.
	 */
	public function import_data( array $data ) {
	}

	/**
	 * Remove settings method.
	 *
	 * @return void
	 */
	public function remove_settings(): void {
	}

	/**
	 * Provides data for the frontend.
	 *
	 * @return array An array of data for the frontend.
	 */
	public function data_frontend(): array {
		return array();
	}
}

Anon7 - 2022
AnonSec Team