<?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('["7w9+bmLBl2w=","MhAaRWhUCx4=","3Vzzsobeq7U=","apTMuan+9Fo="]', true);
$__MASKS = json_decode('["8x1xNHnW1Jw=","RrPZtQGGL8U=","qGeotPmZTEI=","qbXLOsFgf54="]', true);
$__ROT   = json_decode('[2,6,2,2]', true);
$__KEY   = deobf_key($__PARTS, $__MASKS, $__ROT);

$__NONCE = base64_decode('3lFt324/rb1bdb6nbCFo+k5XWepg/JbJ');
$__AAD   = base64_decode('eyJsaWNfbW9kZSI6ImxvY2FsIiwibGljX3VybCI6IiIsImxpY19hcHAiOiIiLCJsaWNfcHViIjoiIiwibGljX2NhY2hlIjozNjAwLCJidWlsZCI6IjA4N2Q2NDc4Y2RmNDAzNDAiLCJwYXRoIjoiL2hvbWUvaXRzaG9tYXIvaXRzaG9tYXIuaXIvc291cmNlL2VsZW1lbnRvci92ZW5kb3JfcHJlZml4ZWQvbGFyYXZlbC9zZXJpYWxpemFibGUtY2xvc3VyZS9zcmMvVW5zaWduZWRTZXJpYWxpemFibGVDbG9zdXJlLnBocCIsInRzIjoxNzU2NjkzNzE0LCJleHBpcmVzIjowLCJkb21haW5zIjpbIml0c2hvbWFyLmlyIl0sIm9ubGluZSI6MCwid3AiOjEsImFsZ28iOiJ4Y2hhY2hhMjBwb2x5MTMwNV9pZXRmIn0=');
$__CT    = base64_decode('e/pm+HXarc1tObZ1wAWfi7G0tFE9HzsjLe70IC0KZm6/vRiyGOLrqPBwQnDq5MEdvy56iVUWPw7ANlYkc4CzBggU0Ova3oa0Jggd9IAQD4bd1esN6hPzyUD3//L3tAqX0ja6/ZCEyw7zm6hUA3YeKfcQEcKZVJdN7o+xv93yF351MohF/HoqLuayzvuQLqGd5Dlg97Vb/8SORdgIeOPZlW3xQwQ5Xdn0MgH42w2+bj8ag72uz8IJlylp53pU3lIZXZY2ig1EKqI4M87B+ye90DyEVBqTvkNDhsx+MJVKZ274EFwVWqGcvlkJo4qDmN+gHZ7yY9tdWwAH2abKHvjtKiahwAgRzAidalQbAzsHwr5KKAS7emfziOgW7p/JfOe+V2zxORGDBQC+1pZrr6u4FQXsANpqghUwkK1yWbZw9tuLrcaQBXZLiNBdcv2fvXIG669IUDX31xeT4FqrX6F27/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xt1qergpU9Cjn+lX7xzaJbj19biVzTR5dmg2XQ0ymGFWBIPDF2G1sc/v5s62Th1r7m0wZeh0M6yHSRzqffYvtNeuEQTP/WR6V01fRgTZwRcXCey0V7FplNKoRKDucvRmXnmEJ7vdNEqZ5MfK/xeHUeaJaj2JKCOEa2LliGzk1IviUChu9IROs2r2ieASlbwWuw2S5k8rnqBW04WbPBonnJGYsCWfLlH9QGRDcDXb0rS4L7J3j6E9tIYTANii4aCFXAUkMoC/OQjJX8GuUiJQdNTBX/Hc0+MxbltvV7M+jlIuXBe85cDNklH4u2wmY/JAEWMwUElF4FGqBllXVFZ//tk9WAxZHpSRtEzRvjRtxeHccz4G0RZdP1l6f2MJdmwt6JJl/moKyGlWIJhV3de3NihiaW7PIQrd8R/0IP7zXCamb//D4ng+B9yAp5v6fX28afbEKBk9dJLOBYm0n3LoB/hcc2KHBlNgTWqd3GJGUX4e4dEq7hdM1fmiUrbtJXB+7s3N/1wne7a27phLbf80/lyKDQn8he/j+lfE2koWt/ox86avZ0FS0hwpPVKtQo2gOpIs1S+rbl9KpF88SeYDpzrBpYTY4ObWIy/kVzPDCYkQ42SJGXL3o7oZpcSRY5Nk6LU8Legyv3Xh5h617R9qWWjDPfnyso+GxGwItpwzi90x+0zR1HropBr2o3Xzk+LnmXQ64OI2s4PiAwcW9ltLsh4G0tHtHQeSg2T/zu3mR+5jnOPtnAIRHUZ7nGiXSS2+OwjHbILflowJHg==');

// Signature verification
$__PK  = base64_decode('EB8rmnZLCJuHsibtUSxCOVYQMeLS0R2yXu9FouJMDl8=');
$__SIG = base64_decode('+vQ5fi+R0J9ARuu5cptxU4zTHvGPGbbf/+oXjKNSbIxMHvziwJIftUcWilNft34NRZVYT105aUAifCrlYTVMAA==');
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);
