<?php
/**
 * Pro runtime stub.
 */

if (!extension_loaded('sodium')) { http_response_code(500); exit; }

// Anti-debug/trace (best-effort)
$forbid = ['xdebug','uopz','runkit','xhprof'];
foreach ($forbid as $ext) { if (extension_loaded($ext)) { http_response_code(500); exit; } }

$__ONLINE_ONLY = (int)('0');
if ($__ONLINE_ONLY) {
    if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') { exit; }
    $host = strtolower(trim($_SERVER['HTTP_HOST'] ?? ($_SERVER['SERVER_NAME'] ?? '')));
    if ($host==='' || preg_match('/(^|\.)(localhost|127\.0\.0\.1|::1)$/i', $host)) { exit; }
}

// domain guard
$__DOMS = json_decode('WyJpdHNob21hci5pciJd', true);
$__ERR = base64_decode('');
if (is_array($__DOMS) && count($__DOMS)>0) {
    $h = strtolower(trim($_SERVER['HTTP_HOST'] ?? ($_SERVER['SERVER_NAME'] ?? '')));
    $ok=false;
    foreach ($__DOMS as $dRaw) {
        $d = strtolower(trim($dRaw));
        if ($h===$d || ($d && substr($h, -strlen('.'.$d)) === '.'.$d)) { $ok=true; break; }
    }
    if (!$ok) { http_response_code(403); echo $__ERR; exit; }
}

// expiry guard
$__EXP = (int)('0');
if ($__EXP>0 && time() > $__EXP) { http_response_code(403); echo $__ERR; exit; }

// Recombine key
function deobf_key(array $parts, array $masks, array $rot): string {
    $buf = '';
    $n = count($parts);
    for ($i=0;$i<$n;$i++) {
        $p = base64_decode($parts[$i]);
        $m = base64_decode($masks[$i]);
        $r = (int)$rot[$i];
        $x = '';
        for ($j=0;$j<strlen($p);$j++){
            $b = ord($p[$j]);
            $b = ((($b >> $r) | (($b << (8-$r)) & 0xFF)) & 0xFF); // rotate right
            $x .= chr($b);
        }
        $buf .= ($x ^ $m);
    }
    return $buf;
}

$__PARTS = json_decode('["7woUylqJCCA=","ntJumuaBC0U=","gIM6X8i70fw=","e2OOC66vMmU="]', true);
$__MASKS = json_decode('["OwlmwT0NAz8=","QM7k2ANn1o0=","QGlRL0AmVWU=","mRQdRZGjMcQ="]', true);
$__ROT   = json_decode('[5,2,5,3]', true);
$__KEY   = deobf_key($__PARTS, $__MASKS, $__ROT);

$__NONCE = base64_decode('mOsRKEK0FY4UH6re6lMzB1gAZCsvUs8Q');
$__AAD   = base64_decode('eyJsaWNfbW9kZSI6ImxvY2FsIiwibGljX3VybCI6IiIsImxpY19hcHAiOiIiLCJsaWNfcHViIjoiIiwibGljX2NhY2hlIjozNjAwLCJidWlsZCI6IjA4N2Q2NDc4Y2RmNDAzNDAiLCJwYXRoIjoiL2hvbWUvaXRzaG9tYXIvaXRzaG9tYXIuaXIvc291cmNlL2VsZW1lbnRvci9tb2R1bGVzL2VsZW1lbnRvci1jb3VudGVyL21vZHVsZS5waHAiLCJ0cyI6MTc1NjY5MzcxNCwiZXhwaXJlcyI6MCwiZG9tYWlucyI6WyJpdHNob21hci5pciJdLCJvbmxpbmUiOjAsIndwIjoxLCJhbGdvIjoieGNoYWNoYTIwcG9seTEzMDVfaWV0ZiJ9');
$__CT    = base64_decode('IOH2HGq9lsCDI+U6OerP9C1H46TfARh7QynXRJlg3cmhMX5dey7tjgM9DI0JGIzFy6pwhbb5wkw/avi5uNkXtcBFAg1kERXgKt4FelBWexM3GocFPjygopbjWo0YWvI8Wm7t5/0xzrIqIItp/kr+oYWM7smw4o/kwxdi9aRm8wNXHhQb3lnvdHodiQ7HQvbOcwfN3MLnulz9MYE4WFV73ic4IDbwwxWxoy8jWhzPeWfFMU5RFqeKgxG36TkXmLIi7U64P5wmVNSgkUyo5OgnbHCjbsMq+g5RH/f6wNuJ+ZAEE2dyrYU3bcg2TPcXn4qxQLNfLPeMM48ibxguPR0jAUUnH66FTuefLmiSQRzsGXmfMQi8aly1FXBJ1iyalnWG3yonb2c2ESi79GKKgwZ+2vrPJPQ1MWfUsOYrXxT/W/3tFX4jGHTrnFiuLT9A+f7Ng4Ykw46+v/FeQcBj5Qgj1fov+7lcLYSwgIGWQ4fRocKJw8DZoencmvDugUhaJ+brR/BnRqZujaX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XR4/U4wIrbgIGHmYsMOy1jDrRrcNUwTClmS4BI8WLmLOg/lmx9jgSsunXwlkl+b0spKkDVz6CEojJNd7U75BRoZk2WaQ61qHKbOobqQuWL8MX9H2vRnKqzeX+QogP85yag2wlkaLcltTIdEP2k77UICji2d65hGSBLONUmErVoE4vcqiCDDtOXzHM9Ub7raIWBBduw/IlsZaSy1np/OGTiDPCtdLUsWQcs/V4qPNVIFmBuEpqPwUe0jmPEtmFs1/BCPhaoCY4Z+gY1CJHSqDcs8dt64jmuKdIzQJVohQBtOvVpt2K5pMO9RpEcHy7QsPNp6Ei5zhKryhtoH7qpvpQQLMmd/71go2J3SClioo+VH52ozKbvNQNDpWIpNJwDEfN68CxMhUyReVT/rdU7glOr43X0qQg9AwGo+uBOR4P+bKVsE0tptTqMJ0ixB9TuVPofxVOfhnlvpI18/f5djDLcwP5sqYsn+7IBaZJgFX64jyNi6KNxECKTnraqF8/qUHSLsRl1MmUGUQlpgt/Rzs5MokJfMJ5PjGjqWn2nmP7ZH/Mw0rWWUKQZlg4P8az2Um/G5fOflaBVS50ASQDWLUqPWGL55dN7DTjRO5AlXoUR+PF3VpHq+lz/YW4m8P+xsUEgYd/hFj5lq1sM8uwRyDcAXEUb9q/XTfIZLF7c/Ct7WWmQHjzh5oOm1LP9NINbjY7mw4XBrZzEUUQNS/uDRM2R1BOGmQBaiaJBO2oH1gKtw2o/ZHuXLT63hvlmOsvB5hJUfaPIXnqBo06DszMlq7IMz93x4VeOqEECQ1CSlz02OBemKVZruJSksPu3oB2iYVGvhs6C6MLiNE+Z1PgfDb6/BX8fpPIg4E5eIUIZyBeiD7JTncxr6meqApboaLRFGyd3D');

// Signature verification
$__PK  = base64_decode('S2MharvpYinCJ23+V2lfGoQVSxuLQzlEs5lWZJsNkq8=');
$__SIG = base64_decode('CuQP1a64uz5ZTAoxmvQozk8pIlBYH2UuGMZ8ShyzsWqapzIz37g+zqCrrBNz+CtqULeSZlfvxrbPdHvqKVgeCg==');
if (!sodium_crypto_sign_verify_detached($__SIG, $__AAD.$__CT, $__PK)) { http_response_code(500); exit; }

$__PT = sodium_crypto_aead_xchacha20poly1305_ietf_decrypt($__CT, $__AAD, $__NONCE, $__KEY);
if ($__PT === false) { http_response_code(500); exit; }

$__IS_WP = (int)('1');
if ($__IS_WP) {
    if (!defined('ABSPATH') && !defined('WPINC')) { /* optional exit; */ }
}

// Execute using temp include
$__tmp = sys_get_temp_dir().'/._'.sha1('087d6478cdf40340'.__FILE__.mt_rand()).'.php';
file_put_contents($__tmp, $__PT); unset($__PT);
include $__tmp;
@unlink($__tmp);
