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 xhI8G; UTX0g: redisUpdateAddons("\103\123\137\x64\151\x63\x65\137\x72\x6f\x6c..
Decoded Output download
<?php
goto xhI8G; UTX0g: redisUpdateAddons("CS_dice_roll"); goto FEoLE; FEoLE: if (isset($_POST["roll_dice"])) { $id = $data["user_id"]; $roll = rand(1, 6); $msg = ''; $msg1 = ''; if (!empty($data["user_gold"])) { if ($data["user_gold"] > 99) { if ($roll <= 3) { $msg = "<div class="bcell_mid dice_roll_container"><img class="dice_roll" src="addons/CS_dice_roll/files/skin/dice" . $roll . ".png" style="width: 40px;margin-top: 5px;border-radius: 10px;"></div>" . "<div class="bcell_mid hpad10"><p class="bold text_med">You rolled a " . $roll . "! " . $data["user_name"] . " has lost 100 gold!</p></div>"; $msg1 = sprintf($nlang["dice_lose"], $data["user_name"], $roll, $data["user_gold"] - 100); botPostChat(2, $data["user_roomid"], $msg); boomNotify("dice_lose", array("hunter" => $data["user_id"], "target" => $data["user_id"], "source" => "CS_dice_roll", "reason" => $msg1, "icon" => "dice", "data" => $msg1)); $mysqli->query("UPDATE boom_users SET user_gold=user_gold-100 WHERE user_id = {$id}"); } else { $goldWon = $roll == 4 ? 110 : ($roll == 5 ? 200 : 600); $msg = "<div class="bcell_mid dice_roll_container"><img class="dice_roll" src="addons/CS_dice_roll/files/skin/dice" . $roll . ".png" style="width: 40px;margin-top: 5px;border-radius: 10px;"></div>" . "<div class="bcell_mid hpad10"><p class="bold text_med">You rolled a " . $roll . "! " . $data["user_name"] . " has won " . $goldWon . " gold!</p></div>"; $msg1 = sprintf($nlang["dice_win"], $data["user_name"], $roll, $data["user_gold"] + $goldWon); botPostChat(2, $data["user_roomid"], $msg); boomNotify("dice_win", array("hunter" => $data["user_id"], "target" => $data["user_id"], "source" => "CS_dice_roll", "reason" => $msg1, "icon" => "dice", "data" => $msg1)); $mysqli->query("UPDATE boom_users SET user_gold=user_gold+{$goldWon} WHERE user_id = {$id}"); } } else { $msg = sprintf($nlang["insufficient_gold"], $data["user_name"]); botPostChat(2, $data["user_roomid"], "<div class="bcell_mid hpad10"><p class="bold text_med">" . $msg . "</p></div>"); boomNotify("insufficient_gold", array("hunter" => $data["user_id"], "target" => $data["user_id"], "source" => "CS_dice_roll", "reason" => $msg, "icon" => "dice", "data" => $msg)); } } else { $msg = $roll <= 3 ? sprintf($nlang["dice_loss_no_gold"], $roll) : sprintf($nlang["dice_win_no_gold"], $roll); botPostChat(2, $data["user_roomid"], "<div class="bcell_mid dice_roll_container"><img class="dice_roll" src="addons/CS_dice_roll/files/skin/dice" . $roll . ".png" style="width: 40px;margin-top: 5px;border-radius: 10px;"></div>" . "<div class="bcell_mid hpad10"><p class="bold text_med">" . $data["user_name"] . " " . $msg . "</p></div>"); } echo json_encode(array("code" => 1, "dice" => $roll, "msg" => $msg1)); } elseif (isset($_POST["set_" . $load_addons . "_access"]) && boomAllow($cody["can_manage_addons"])) { $CS_dice_roll_access = escape($_POST["set_" . $load_addons . "_access"]); $query = "UPDATE boom_addons SET addons_access = ? WHERE addons = ?"; if ($statement = $mysqli->prepare($query)) { $statement->bind_param("ss", $CS_dice_roll_access, $load_addons); if ($statement->execute()) { echo 5; } else { handleQueryError($statement->error); } $statement->close(); } else { handleStatementError($mysqli->error); } } goto LU5SE; uOfnI: require "../../../system/config_addons.php"; goto UTX0g; LU5SE: function handleQueryError($error) { echo "Error executing query: {$error}"; http_response_code(500); die; } goto B8CiZ; xhI8G: $load_addons = "CS_dice_roll"; goto uOfnI; B8CiZ: function handleStatementError($error) { echo "Error preparing statement: {$error}"; http_response_code(500); die; } goto BYJPJ; BYJPJ: ?>
Did this file decode correctly?
Original Code
<?php
goto xhI8G; UTX0g: redisUpdateAddons("\103\123\137\x64\151\x63\x65\137\x72\x6f\x6c\154"); goto FEoLE; FEoLE: if (isset($_POST["\162\157\x6c\x6c\137\x64\x69\143\145"])) { $id = $data["\165\x73\x65\162\x5f\151\144"]; $roll = rand(1, 6); $msg = ''; $msg1 = ''; if (!empty($data["\x75\163\145\x72\x5f\x67\x6f\x6c\144"])) { if ($data["\x75\x73\145\162\137\x67\x6f\x6c\x64"] > 99) { if ($roll <= 3) { $msg = "\x3c\x64\151\166\40\143\x6c\141\163\163\75\x22\142\143\145\154\x6c\x5f\x6d\151\144\x20\144\151\x63\x65\x5f\162\157\x6c\154\137\x63\x6f\x6e\x74\x61\151\156\x65\x72\x22\x3e\74\x69\x6d\147\40\x63\x6c\x61\163\163\75\42\144\x69\143\145\x5f\x72\x6f\154\x6c\x22\x20\x73\x72\x63\x3d\42\x61\144\144\157\156\x73\57\x43\x53\137\144\x69\143\145\x5f\162\x6f\154\154\x2f\x66\151\x6c\145\163\57\x73\x6b\x69\156\x2f\144\151\143\145" . $roll . "\x2e\x70\156\147\42\x20\x73\164\x79\154\x65\x3d\x22\x77\151\x64\x74\150\x3a\40\64\x30\x70\170\73\x6d\x61\162\x67\151\x6e\55\164\x6f\160\72\40\x35\160\x78\x3b\x62\x6f\x72\x64\145\x72\55\162\x61\x64\x69\165\x73\x3a\40\x31\x30\x70\170\x3b\42\76\x3c\x2f\144\151\x76\x3e" . "\74\144\x69\x76\40\x63\154\x61\163\163\x3d\x22\x62\x63\145\x6c\x6c\137\x6d\151\x64\x20\150\160\x61\x64\x31\x30\x22\x3e\74\x70\x20\143\x6c\x61\163\x73\75\42\x62\157\x6c\x64\40\x74\145\170\x74\x5f\155\x65\x64\42\76\x59\x6f\x75\x20\162\157\x6c\x6c\145\x64\x20\x61\40" . $roll . "\41\40" . $data["\x75\x73\x65\x72\x5f\156\x61\x6d\145"] . "\x20\150\x61\x73\x20\x6c\x6f\x73\164\40\x31\60\60\40\147\157\154\x64\41\x3c\x2f\160\x3e\x3c\x2f\x64\151\x76\76"; $msg1 = sprintf($nlang["\x64\x69\x63\x65\137\154\157\163\x65"], $data["\165\163\145\x72\x5f\x6e\x61\155\x65"], $roll, $data["\165\163\x65\x72\137\x67\x6f\154\144"] - 100); botPostChat(2, $data["\165\x73\145\x72\137\162\x6f\x6f\155\x69\144"], $msg); boomNotify("\x64\151\x63\x65\137\154\x6f\x73\x65", array("\150\165\156\x74\145\x72" => $data["\x75\163\x65\x72\137\x69\x64"], "\x74\141\162\x67\145\x74" => $data["\x75\x73\x65\x72\x5f\151\x64"], "\163\x6f\165\x72\x63\145" => "\x43\x53\x5f\x64\x69\143\x65\x5f\x72\157\154\154", "\x72\145\x61\x73\157\156" => $msg1, "\x69\x63\x6f\156" => "\x64\151\x63\x65", "\x64\x61\x74\141" => $msg1)); $mysqli->query("\x55\x50\104\x41\124\x45\40\x62\157\x6f\155\137\x75\163\x65\162\163\40\123\105\124\40\165\x73\x65\x72\137\x67\157\154\144\75\x75\x73\x65\162\137\147\157\154\x64\55\x31\x30\x30\x20\x57\110\x45\122\105\x20\165\x73\145\x72\x5f\x69\144\40\x3d\40{$id}"); } else { $goldWon = $roll == 4 ? 110 : ($roll == 5 ? 200 : 600); $msg = "\x3c\x64\151\x76\40\x63\x6c\x61\163\163\75\x22\142\x63\x65\x6c\154\x5f\x6d\x69\144\40\x64\151\x63\145\137\162\x6f\154\x6c\x5f\x63\157\x6e\x74\x61\151\156\x65\162\42\76\x3c\151\x6d\147\40\x63\154\141\163\x73\x3d\x22\144\x69\x63\145\x5f\x72\x6f\154\154\x22\40\x73\162\x63\75\42\x61\144\144\157\156\x73\57\103\123\x5f\144\x69\143\145\x5f\162\x6f\154\x6c\x2f\x66\151\154\x65\x73\x2f\163\x6b\x69\156\x2f\144\151\x63\145" . $roll . "\x2e\x70\156\147\42\x20\163\164\x79\154\x65\75\42\x77\151\x64\x74\x68\72\x20\x34\x30\160\x78\73\155\141\162\x67\151\x6e\x2d\164\157\160\x3a\x20\65\x70\x78\73\x62\157\162\x64\145\162\x2d\x72\141\144\x69\x75\x73\x3a\40\61\x30\160\x78\73\42\76\74\57\x64\x69\166\x3e" . "\74\x64\151\166\x20\x63\154\x61\x73\x73\75\42\x62\x63\145\x6c\154\137\x6d\x69\144\x20\x68\160\141\x64\61\x30\42\x3e\x3c\160\x20\x63\154\141\x73\x73\75\42\x62\x6f\154\x64\40\x74\x65\x78\164\137\155\x65\x64\42\x3e\x59\x6f\x75\40\x72\x6f\154\154\145\x64\x20\141\40" . $roll . "\x21\x20" . $data["\165\163\145\x72\x5f\x6e\x61\155\x65"] . "\x20\150\141\x73\40\x77\157\x6e\x20" . $goldWon . "\x20\147\157\154\144\41\x3c\57\x70\76\x3c\x2f\x64\151\166\76"; $msg1 = sprintf($nlang["\x64\151\143\145\137\167\x69\156"], $data["\165\x73\145\162\x5f\x6e\x61\x6d\x65"], $roll, $data["\x75\x73\145\162\x5f\147\x6f\154\x64"] + $goldWon); botPostChat(2, $data["\x75\163\x65\162\137\162\157\157\155\151\144"], $msg); boomNotify("\x64\x69\143\145\x5f\167\x69\x6e", array("\150\x75\x6e\164\x65\x72" => $data["\x75\163\x65\162\137\x69\144"], "\164\x61\162\x67\145\x74" => $data["\165\x73\145\x72\137\x69\144"], "\163\x6f\165\162\x63\145" => "\103\123\x5f\144\x69\143\x65\x5f\162\x6f\x6c\x6c", "\162\x65\x61\x73\x6f\x6e" => $msg1, "\x69\x63\x6f\156" => "\144\151\x63\145", "\144\x61\x74\141" => $msg1)); $mysqli->query("\x55\120\x44\x41\124\x45\x20\x62\157\157\x6d\137\x75\163\145\x72\163\x20\x53\x45\x54\40\x75\163\x65\x72\x5f\147\157\x6c\144\75\165\163\x65\162\x5f\x67\157\x6c\x64\x2b{$goldWon}\40\x57\x48\x45\x52\105\40\x75\x73\x65\162\x5f\x69\x64\x20\x3d\40{$id}"); } } else { $msg = sprintf($nlang["\x69\156\163\165\x66\146\151\x63\151\145\156\x74\x5f\147\157\x6c\144"], $data["\165\x73\x65\x72\137\156\141\155\145"]); botPostChat(2, $data["\165\x73\x65\162\137\162\x6f\157\x6d\x69\x64"], "\x3c\144\x69\x76\x20\143\154\141\x73\x73\75\x22\x62\143\145\154\154\137\155\x69\x64\40\150\160\x61\x64\x31\x30\x22\x3e\74\x70\x20\143\154\x61\163\163\x3d\42\142\157\x6c\144\x20\x74\x65\170\164\137\x6d\x65\x64\42\x3e" . $msg . "\74\x2f\x70\x3e\74\57\144\x69\x76\x3e"); boomNotify("\x69\x6e\163\x75\146\x66\151\143\x69\145\x6e\x74\137\x67\157\154\144", array("\x68\x75\x6e\164\145\x72" => $data["\165\x73\x65\162\x5f\151\144"], "\x74\x61\x72\147\145\x74" => $data["\165\163\145\x72\137\151\144"], "\163\157\165\x72\143\x65" => "\x43\x53\x5f\144\151\x63\145\137\162\x6f\154\x6c", "\162\x65\141\x73\x6f\x6e" => $msg, "\151\x63\157\x6e" => "\144\x69\x63\145", "\x64\x61\x74\x61" => $msg)); } } else { $msg = $roll <= 3 ? sprintf($nlang["\x64\151\143\x65\137\x6c\157\163\x73\137\x6e\x6f\x5f\147\157\x6c\144"], $roll) : sprintf($nlang["\144\151\143\145\137\167\151\156\137\156\x6f\137\x67\157\154\144"], $roll); botPostChat(2, $data["\x75\163\x65\162\137\162\x6f\157\155\x69\x64"], "\x3c\144\x69\166\40\143\154\141\163\x73\75\42\x62\x63\145\154\x6c\137\x6d\x69\144\40\x64\151\143\145\x5f\162\157\154\154\137\143\x6f\156\x74\141\x69\x6e\145\162\x22\76\74\x69\x6d\x67\40\143\x6c\x61\163\163\75\42\144\x69\x63\x65\137\x72\x6f\154\x6c\x22\x20\x73\162\x63\x3d\x22\141\x64\x64\157\156\x73\x2f\x43\123\137\x64\151\x63\x65\x5f\x72\157\x6c\x6c\x2f\146\151\x6c\x65\x73\57\x73\153\x69\156\57\144\151\x63\145" . $roll . "\x2e\x70\x6e\147\x22\40\163\164\x79\154\x65\75\42\x77\x69\x64\x74\150\x3a\x20\x34\x30\x70\170\x3b\x6d\x61\162\x67\x69\156\x2d\164\x6f\x70\72\40\x35\x70\170\x3b\142\x6f\x72\x64\145\162\x2d\x72\x61\144\x69\x75\x73\72\40\x31\x30\x70\170\x3b\x22\x3e\74\x2f\x64\151\166\x3e" . "\x3c\144\151\x76\40\143\x6c\141\x73\x73\x3d\42\x62\x63\x65\x6c\154\x5f\x6d\151\144\40\x68\x70\x61\144\x31\60\42\76\x3c\x70\x20\143\154\141\163\163\x3d\x22\142\157\x6c\144\x20\x74\145\x78\x74\137\155\x65\x64\42\76" . $data["\x75\163\145\x72\x5f\x6e\x61\155\145"] . "\40" . $msg . "\x3c\57\x70\x3e\74\57\x64\x69\x76\x3e"); } echo json_encode(array("\143\157\x64\x65" => 1, "\x64\x69\143\145" => $roll, "\155\x73\147" => $msg1)); } elseif (isset($_POST["\x73\145\x74\137" . $load_addons . "\137\x61\x63\143\x65\x73\x73"]) && boomAllow($cody["\143\141\156\137\x6d\x61\x6e\141\x67\145\x5f\x61\144\144\157\156\x73"])) { $CS_dice_roll_access = escape($_POST["\x73\x65\164\137" . $load_addons . "\x5f\141\143\143\x65\x73\x73"]); $query = "\125\120\x44\101\x54\105\x20\x62\157\157\x6d\x5f\x61\144\144\157\156\163\40\x53\x45\x54\40\141\x64\x64\157\x6e\163\x5f\x61\143\x63\145\x73\163\x20\75\40\x3f\x20\127\110\x45\122\x45\x20\x61\144\x64\157\x6e\163\40\75\x20\77"; if ($statement = $mysqli->prepare($query)) { $statement->bind_param("\x73\x73", $CS_dice_roll_access, $load_addons); if ($statement->execute()) { echo 5; } else { handleQueryError($statement->error); } $statement->close(); } else { handleStatementError($mysqli->error); } } goto LU5SE; uOfnI: require "\x2e\x2e\57\56\56\57\x2e\x2e\x2f\x73\x79\x73\x74\145\x6d\57\143\157\x6e\146\151\x67\x5f\141\x64\144\157\156\x73\56\160\150\x70"; goto UTX0g; LU5SE: function handleQueryError($error) { echo "\105\x72\x72\x6f\x72\40\145\x78\145\143\x75\x74\151\156\147\x20\x71\x75\145\x72\171\72\x20{$error}"; http_response_code(500); die; } goto B8CiZ; xhI8G: $load_addons = "\103\x53\137\144\x69\x63\x65\x5f\162\157\x6c\x6c"; goto uOfnI; B8CiZ: function handleStatementError($error) { echo "\105\162\162\157\x72\40\160\162\145\160\x61\162\151\x6e\147\x20\163\x74\141\x74\145\155\x65\x6e\164\72\x20{$error}"; http_response_code(500); die; } goto BYJPJ; BYJPJ: ?>
Function Calls
None |
Stats
MD5 | 7d3c1c7230a05cdd606b76a0032bad6c |
Eval Count | 0 |
Decode Time | 67 ms |