Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

$host = '64.53.200.156'; $rbl = 'sbl-xbl.spamhaus.org'; // valid query format is: 156.2..

Decoded Output download

<?  $host = '64.53.200.156'; 
$rbl  = 'sbl-xbl.spamhaus.org'; 
// valid query format is: 156.200.53.64.sbl-xbl.spamhaus.org 
$rev = array_reverse(explode('.', $host)); 
$lookup = implode('.', $rev) . '.' . $rbl; 
if ($lookup != gethostbyname($lookup)) { 
    echo "ip: $host is listed in $rbl
"; 
} else { 
    echo "ip: $host NOT listed in $rbl
"; 
} 
 ?>

Did this file decode correctly?

Original Code

$host = '64.53.200.156';
$rbl  = 'sbl-xbl.spamhaus.org';
// valid query format is: 156.200.53.64.sbl-xbl.spamhaus.org
$rev = array_reverse(explode('.', $host));
$lookup = implode('.', $rev) . '.' . $rbl;
if ($lookup != gethostbyname($lookup)) {
    echo "ip: $host is listed in $rbl\n";
} else {
    echo "ip: $host NOT listed in $rbl\n";
}

Function Calls

explode 1
array_reverse 1

Variables

$rbl sbl-xbl.spamhaus.org
$host 64.53.200.156

Stats

MD5 d7aa0a862045ec839d9b0b58e8864c3a
Eval Count 0
Decode Time 91 ms