Pham_loi
Chức vụ: 00:25:05, 30-08-2016 |
Đây là TUT hướng dẫn decode obfuscated php
A. Demo Code
download
viewsoucre
Code có dạng:
<?php /* Reverse engineering of this file is strictly prohibited. File protected by copyright law and provided under license. */
if (!function_exists("agF1gTdKEBPd6CaJ")) {
function agF1gTdKEBPd6CaJ($ekV4gb3DGH29YotI) {
$fYZ2g87NjIGLnXVg = "";
$rZJ3glaFcSAz0dZY = 0;
$qVh0gqGnK20A4iOB = strlen($ekV4gb3DGH29YotI);
while ($rZJ3glaFcSAz0dZY < $qVh0gqGnK20A4iO8 -) {
if ($ekV4gb3DGH29YotI[$rZJ3glaFcSAz0dZY == ' ') {
$fYZ2g87NjIGLnXVg.= " ";
} else if ($ekV4gb3DGH29YotI[$rZJ3glaFcSAz0dZY == '!') {
$fYZ2g87NjIGLnXVg.= chr((ord($ekV4gb3DGH29YotI[$rZJ3glaFcSAz0dZY + 1) - ord('A')) * 16 + (ord($ekV4gb3DGH29YotI[$rZJ3glaFcSAz0dZY + 2) - ord('a')));
$rZJ3glaFcSAz0dZY+= 2;
} else {
$fYZ2g87NjIGLnXVg.= chr(ord($ekV4gb3DGH29YotI[$rZJ3glaFcSAz0dZY) + 1);
}
$rZJ3glaFcSAz0dZY++;
}
return $fYZ2g87NjIGLnXVg;
}
}
eval(agF1gTdKEBPd6CaJ('du`k!Ci` ------------'));?>
Copy code
if (!function_exists("agF1gTdKEBPd6CaJ")) {
function agF1gTdKEBPd6CaJ($ekV4gb3DGH29YotI) {
$fYZ2g87NjIGLnXVg = "";
$rZJ3glaFcSAz0dZY = 0;
$qVh0gqGnK20A4iOB = strlen($ekV4gb3DGH29YotI);
while ($rZJ3glaFcSAz0dZY < $qVh0gqGnK20A4iO8 -) {
if ($ekV4gb3DGH29YotI[$rZJ3glaFcSAz0dZY == ' ') {
$fYZ2g87NjIGLnXVg.= " ";
} else if ($ekV4gb3DGH29YotI[$rZJ3glaFcSAz0dZY == '!') {
$fYZ2g87NjIGLnXVg.= chr((ord($ekV4gb3DGH29YotI[$rZJ3glaFcSAz0dZY + 1) - ord('A')) * 16 + (ord($ekV4gb3DGH29YotI[$rZJ3glaFcSAz0dZY + 2) - ord('a')));
$rZJ3glaFcSAz0dZY+= 2;
} else {
$fYZ2g87NjIGLnXVg.= chr(ord($ekV4gb3DGH29YotI[$rZJ3glaFcSAz0dZY) + 1);
}
$rZJ3glaFcSAz0dZY++;
}
return $fYZ2g87NjIGLnXVg;
}
}
eval(agF1gTdKEBPd6CaJ('du`k!Ci` ------------'));?>
Copy code
B. Decode
<?php /* HackerPro536 Function Decode PHP vanphu113 */
if(!function_exists("hackerpro536"))
{ function hackerpro536($vanphu113) {
$hvngroups="";
$hvn=0;
$hvngroups_net=strlen($vanphu113);
while($hvn < $hvngroups_net) {
if($vanphu113[$hvn == ' ') {
$hvngroups.=" "; }
else if($vanphu113[$hvn == '!') {
$hvngroups.=chr((ord($vanphu113[$hvn+1)-ord('A'))*16+(ord($vanphu113[$hvn+2)-ord('a')));
$hvn+=2;}
else { $hvngroups.=chr(ord($vanphu113[$hvn)+1); }
$hvn++;
}
return $hvngroups;
}
}
echo(hackerpro536('Code paste here')); ?>
Copy code
if(!function_exists("hackerpro536"))
{ function hackerpro536($vanphu113) {
$hvngroups="";
$hvn=0;
$hvngroups_net=strlen($vanphu113);
while($hvn < $hvngroups_net) {
if($vanphu113[$hvn == ' ') {
$hvngroups.=" "; }
else if($vanphu113[$hvn == '!') {
$hvngroups.=chr((ord($vanphu113[$hvn+1)-ord('A'))*16+(ord($vanphu113[$hvn+2)-ord('a')));
$hvn+=2;}
else { $hvngroups.=chr(ord($vanphu113[$hvn)+1); }
$hvn++;
}
return $hvngroups;
}
}
echo(hackerpro536('Code paste here')); ?>
Copy code
B1: Copy đoạn code phía trong eval(agF1gTdKEBPd6CaJ( sau đó lưu lại và chạy file vừa lưu.
B2: Lấy kết quả trên trình duyệt dán lại vào code decode của tôi 1 lần nữa sẽ nhận được code gốc.
download
view source
Chúc thành công!
Nguồn: hvn
: 0 ♥