Find this useful? Enter your email to receive occasional updates for securing PHP code.
Signing you up...
Thank you for signing up!
PHP Decode
<?php goto ySkCh; jSsG_: if (!isset($_SESSION["\163\x65\163\x73\137\x68\x61\163\150\13..
Decoded Output download
<?php
goto ySkCh; jSsG_: if (!isset($_SESSION["sess_hash_a"])) { $_SESSION["sess_hash_a"] = ''; } goto Ew0H9; F84VN: if (!isset($_SESSION["user_id_a"])) { $_SESSION["user_id_a"] = ''; } goto jSsG_; I43EK: $shop_data = array(); goto EnD8v; Mb0bU: function encPass($str) { $encrypted = md5(sha1($str)); return $encrypted; } goto SbZVv; YGl3u: $user_data_query->bindParam("user_id", $_SESSION["user_id_a"]); goto zFFGD; RGlnx: $password = "Rev@mpDB@Passw0rd2023"; goto LAIBn; TmtbE: $dbo->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_ASSOC); goto Avg3R; S9Ur2: $dbname = "revamp_pos"; goto F84VN; EnD8v: $user_data_query = $dbo->prepare("SELECT u.u_id, u.u_full_name, u.role_id, r.role_name \xa FROM users u, roles r \xa WHERE u.role_id = r.role_id AND u.u_status = 1
AND u.u_id = :user_id"); goto YGl3u; Ew0H9: if (!isset($_SESSION["user_login_a"])) { $_SESSION["user_login_a"] = ''; } goto ezuye; Dvdia: $user_id = $user_data["u_id"] ?? "0"; goto CcJKq; xtvPH: $qryShop = $dbo->query("SELECT * FROM shop_detail"); goto Goq4p; Avg3R: $dbo->setAttribute(PDO::ATTR_PERSISTENT, true); goto VDTyX; wYY28: $user_data = $user_data_query->fetch(PDO::FETCH_ASSOC); goto xtvPH; ySkCh: session_start(); goto I1kLE; BizuF: $dbo = new PDO("mysql:host={$host}; dbname={$dbname}; charset=utf8", $username, $password); goto H1QfD; LAIBn: $username = "revamp_db_user"; goto S9Ur2; iiONb: date_default_timezone_set("Asia/Karachi"); goto Mb0bU; olb8q: $user_name = ''; goto BizuF; Goq4p: $shop_data = $qryShop->fetch(PDO::FETCH_ASSOC); goto Dvdia; I1kLE: error_reporting(E_ALL); goto RGlnx; M1i1O: $host = "88.218.28.56"; goto olb8q; H1QfD: $dbo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); goto TmtbE; ezuye: if ($_SESSION["user_login_a"] != "Admin" && $_SESSION["user_id_a"] == '' && $_SESSION["sess_hash_a"] == '' && $pageName != "Login") { $_SESSION["user_id_a"] = ''; $_SESSION["sess_hash_a"] = ''; $_SESSION["user_login_a"] = ''; header("location: login.php?m=2"); } goto M1i1O; OVLbo: if (count((array) $user_data) != 0 && $user_id > 0) { $qryGetPages = $dbo->prepare("SELECT p.* \xa FROM pages p, role_pages rp, icons il\xa WHERE p.page_id = rp.pages_id AND p.icon_id = il.icon_id \xa AND rp.role_id = :role_id
ORDER BY p.page_id"); $qryGetPages->bindParam("role_id", $user_data["role_id"]); $qryGetPages->execute(); while ($rowGetPages = $qryGetPages->fetch(PDO::FETCH_ASSOC)) { $pagesArray[] = $rowGetPages["page_link"]; } $fileName = explode("/", $_SERVER["PHP_SELF"]); $last = count((array) $fileName) - 1; if (strpos($fileName[$last], "ajax") === false && strpos($fileName[$last], "save") === false && strpos($fileName[$last], "export") === false && strpos($fileName[$last], "print") === false) { if (!in_array($fileName[$last], $pagesArray)) { echo "<script>window.location = 'restricted.php';</script>"; } } $user_name = $user_data["u_full_name"]; $month[0] = "January"; $month[1] = "February"; $month[2] = "March"; $month[3] = "April"; $month[4] = "May"; $month[5] = "June"; $month[6] = "July"; $month[7] = "August"; $month[8] = "September"; $month[9] = "October"; $month[10] = "November"; $month[11] = "December"; } goto iiONb; CcJKq: $pagesArray = array(); goto OVLbo; VDTyX: $user_data = array(); goto I43EK; zFFGD: $user_data_query->execute(); goto wYY28; SbZVv:
error_reporting(0);
?>
Did this file decode correctly?
Original Code
<?php
goto ySkCh; jSsG_: if (!isset($_SESSION["\163\x65\163\x73\137\x68\x61\163\150\137\x61"])) { $_SESSION["\x73\145\163\x73\137\x68\141\x73\150\137\x61"] = ''; } goto Ew0H9; F84VN: if (!isset($_SESSION["\165\163\145\x72\137\x69\x64\137\141"])) { $_SESSION["\x75\163\x65\162\x5f\151\x64\x5f\141"] = ''; } goto jSsG_; I43EK: $shop_data = array(); goto EnD8v; Mb0bU: function encPass($str) { $encrypted = md5(sha1($str)); return $encrypted; } goto SbZVv; YGl3u: $user_data_query->bindParam("\x75\163\145\x72\137\x69\x64", $_SESSION["\x75\x73\145\x72\x5f\x69\x64\x5f\141"]); goto zFFGD; RGlnx: $password = "\x52\145\166\100\x6d\160\x44\102\x40\x50\141\x73\163\x77\60\162\144\x32\x30\62\x33"; goto LAIBn; TmtbE: $dbo->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_ASSOC); goto Avg3R; S9Ur2: $dbname = "\162\x65\166\141\x6d\x70\137\x70\x6f\x73"; goto F84VN; EnD8v: $user_data_query = $dbo->prepare("\x53\x45\x4c\105\x43\124\40\165\x2e\x75\137\151\x64\x2c\40\165\x2e\x75\137\146\165\154\154\x5f\x6e\x61\155\145\54\40\x75\x2e\162\x6f\154\145\137\151\x64\x2c\x20\x72\x2e\162\x6f\x6c\x65\x5f\x6e\141\155\145\x20\xa\x20\40\40\x20\40\x20\x20\x20\106\122\117\115\40\x75\163\145\162\x73\40\165\x2c\40\x72\157\154\x65\x73\x20\x72\x20\40\xa\40\x20\40\40\40\x20\40\x20\x57\x48\105\x52\x45\40\165\56\162\x6f\x6c\x65\137\151\x64\x20\75\40\x72\56\x72\157\x6c\145\137\151\x64\x20\101\x4e\x44\40\x75\x2e\165\137\x73\x74\x61\x74\165\163\40\75\40\x31\12\40\x20\x20\x20\40\40\40\40\x41\116\x44\x20\x75\x2e\x75\x5f\151\x64\x20\x3d\x20\x3a\165\x73\145\x72\137\x69\x64"); goto YGl3u; Ew0H9: if (!isset($_SESSION["\165\x73\x65\162\x5f\x6c\x6f\x67\x69\x6e\x5f\141"])) { $_SESSION["\165\163\145\x72\137\x6c\x6f\x67\x69\156\137\x61"] = ''; } goto ezuye; Dvdia: $user_id = $user_data["\x75\x5f\x69\x64"] ?? "\x30"; goto CcJKq; xtvPH: $qryShop = $dbo->query("\123\105\114\105\x43\x54\40\x2a\x20\x46\122\x4f\x4d\40\x73\150\x6f\160\x5f\144\145\x74\141\x69\154"); goto Goq4p; Avg3R: $dbo->setAttribute(PDO::ATTR_PERSISTENT, true); goto VDTyX; wYY28: $user_data = $user_data_query->fetch(PDO::FETCH_ASSOC); goto xtvPH; ySkCh: session_start(); goto I1kLE; BizuF: $dbo = new PDO("\155\171\x73\161\x6c\x3a\150\157\163\x74\x3d{$host}\73\x20\x20\x64\142\x6e\141\x6d\145\x3d{$dbname}\x3b\40\x63\150\x61\162\x73\145\x74\75\x75\x74\x66\x38", $username, $password); goto H1QfD; LAIBn: $username = "\162\x65\x76\x61\155\160\137\144\x62\x5f\x75\x73\x65\x72"; goto S9Ur2; iiONb: date_default_timezone_set("\101\163\x69\x61\x2f\113\141\162\141\143\x68\151"); goto Mb0bU; olb8q: $user_name = ''; goto BizuF; Goq4p: $shop_data = $qryShop->fetch(PDO::FETCH_ASSOC); goto Dvdia; I1kLE: error_reporting(E_ALL); goto RGlnx; M1i1O: $host = "\70\x38\x2e\x32\x31\70\56\x32\70\56\65\66"; goto olb8q; H1QfD: $dbo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); goto TmtbE; ezuye: if ($_SESSION["\165\163\x65\x72\x5f\154\x6f\147\x69\156\x5f\141"] != "\101\x64\x6d\x69\x6e" && $_SESSION["\165\163\145\x72\x5f\151\144\137\141"] == '' && $_SESSION["\163\x65\x73\x73\137\x68\x61\163\x68\137\x61"] == '' && $pageName != "\x4c\157\147\x69\x6e") { $_SESSION["\165\163\x65\x72\x5f\151\x64\x5f\x61"] = ''; $_SESSION["\163\x65\163\163\x5f\150\x61\x73\x68\137\141"] = ''; $_SESSION["\165\163\x65\x72\x5f\154\x6f\x67\151\156\x5f\x61"] = ''; header("\x6c\157\143\141\x74\x69\157\156\72\40\154\157\147\x69\156\56\160\150\160\77\155\75\62"); } goto M1i1O; OVLbo: if (count((array) $user_data) != 0 && $user_id > 0) { $qryGetPages = $dbo->prepare("\x53\105\x4c\105\103\x54\x20\160\x2e\52\x20\xa\x20\40\40\x20\x20\x20\x20\x20\x20\40\x20\x20\x46\x52\x4f\115\40\x70\141\147\145\163\x20\x70\x2c\x20\x72\157\x6c\x65\137\x70\141\x67\x65\x73\40\162\x70\x2c\40\x69\143\x6f\x6e\x73\x20\x69\154\xa\x20\40\40\x20\x20\40\x20\40\x20\x20\40\x20\x57\x48\x45\122\105\x20\x70\x2e\x70\x61\147\x65\x5f\x69\x64\x20\x3d\40\x72\x70\x2e\x70\x61\x67\145\x73\x5f\x69\x64\40\x41\x4e\104\40\x70\56\x69\x63\x6f\156\137\x69\x64\40\75\40\151\154\56\151\143\157\x6e\137\151\144\x20\xa\40\x20\40\x20\x20\40\x20\40\x20\40\x20\40\x41\116\104\x20\162\160\56\162\x6f\x6c\x65\137\151\x64\x20\x3d\40\72\x72\x6f\154\145\137\151\144\12\40\x20\40\x20\40\x20\40\x20\40\x20\40\x20\x4f\x52\104\x45\x52\40\x42\131\40\x70\x2e\160\x61\x67\145\137\151\x64"); $qryGetPages->bindParam("\x72\x6f\x6c\x65\x5f\x69\x64", $user_data["\162\x6f\x6c\x65\x5f\x69\144"]); $qryGetPages->execute(); while ($rowGetPages = $qryGetPages->fetch(PDO::FETCH_ASSOC)) { $pagesArray[] = $rowGetPages["\x70\x61\147\x65\x5f\x6c\x69\x6e\153"]; } $fileName = explode("\x2f", $_SERVER["\x50\x48\x50\137\123\105\x4c\x46"]); $last = count((array) $fileName) - 1; if (strpos($fileName[$last], "\141\x6a\x61\x78") === false && strpos($fileName[$last], "\163\x61\x76\x65") === false && strpos($fileName[$last], "\145\x78\x70\157\x72\x74") === false && strpos($fileName[$last], "\160\x72\x69\x6e\164") === false) { if (!in_array($fileName[$last], $pagesArray)) { echo "\x3c\x73\x63\x72\x69\x70\164\76\167\151\156\x64\157\167\56\154\x6f\143\x61\x74\151\x6f\x6e\40\x3d\x20\x27\162\x65\163\x74\x72\151\143\x74\145\x64\56\160\150\160\47\x3b\74\57\163\143\x72\x69\160\164\76"; } } $user_name = $user_data["\165\x5f\x66\165\154\154\137\x6e\x61\x6d\145"]; $month[0] = "\x4a\141\156\165\141\x72\171"; $month[1] = "\x46\x65\x62\162\165\141\162\171"; $month[2] = "\x4d\141\162\x63\150"; $month[3] = "\101\160\x72\x69\154"; $month[4] = "\x4d\141\x79"; $month[5] = "\x4a\165\x6e\x65"; $month[6] = "\x4a\165\154\x79"; $month[7] = "\101\165\x67\x75\x73\x74"; $month[8] = "\123\x65\160\164\x65\x6d\x62\145\x72"; $month[9] = "\117\143\164\x6f\142\x65\x72"; $month[10] = "\116\157\x76\145\155\x62\x65\162"; $month[11] = "\x44\x65\x63\x65\155\142\x65\162"; } goto iiONb; CcJKq: $pagesArray = array(); goto OVLbo; VDTyX: $user_data = array(); goto I43EK; zFFGD: $user_data_query->execute(); goto wYY28; SbZVv:
error_reporting(0);
?>
Function Calls
None |
Stats
MD5 | 72b19ea5883952193fe2edf59884ed03 |
Eval Count | 0 |
Decode Time | 62 ms |