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 UVYqo; nRdQg: openssl_free_key($pubkeyid); goto o0IzZ; lJJhg: echo $data; got..

Decoded Output download

<?php 
 goto UVYqo; nRdQg: openssl_free_key($pubkeyid); goto o0IzZ; lJJhg: echo $data; goto K4WTH; g_bTe: if (isset($_GET["sig"])) { $sig_get = base64_decode($_GET["sig"]); $ok = openssl_verify($data, $sig_get, $pubkeyid, "RSA-SHA256"); if ($ok == 1) { echo "good, the flag is flag{f84ef4f0d7ee}"; } elseif ($ok == 0) { echo "The signature is not correct"; } else { echo "ugly, error checking signature"; } } goto nRdQg; RSDXX: $data = "Thank you for agreeing the payment, the SWIFT code is NUBVQW and the IBAN number is UV 17 002 00122 0000001200527611
"; goto JxxEX; qMqHa: echo "<hr>"; goto RSDXX; ODEKa: echo "<hr>"; goto g_bTe; K4WTH: $sig_get = ''; goto ODEKa; JxxEX: echo "The text you have to sign using the GET parameter "sig" with the private key you have been provided is:<br>"; goto lJJhg; UVYqo: $pubkeyid = file_get_contents("public.pem"); goto qMqHa; o0IzZ: ?>

Did this file decode correctly?

Original Code

<?php
 goto UVYqo; nRdQg: openssl_free_key($pubkeyid); goto o0IzZ; lJJhg: echo $data; goto K4WTH; g_bTe: if (isset($_GET["\163\151\x67"])) { $sig_get = base64_decode($_GET["\163\151\147"]); $ok = openssl_verify($data, $sig_get, $pubkeyid, "\122\x53\x41\55\123\110\101\x32\x35\66"); if ($ok == 1) { echo "\x67\157\157\144\54\x20\x74\150\x65\x20\146\x6c\x61\147\x20\x69\163\40\146\154\x61\x67\x7b\146\x38\x34\145\146\x34\146\60\x64\x37\x65\145\x7d"; } elseif ($ok == 0) { echo "\x54\x68\x65\40\x73\151\x67\156\141\x74\x75\162\145\x20\151\163\40\x6e\x6f\x74\x20\x63\x6f\x72\162\x65\x63\164"; } else { echo "\x75\x67\154\171\54\x20\145\x72\162\x6f\162\40\x63\x68\x65\x63\x6b\151\x6e\x67\x20\x73\x69\x67\x6e\x61\x74\165\162\145"; } } goto nRdQg; RSDXX: $data = "\124\150\x61\x6e\x6b\40\171\157\x75\x20\x66\x6f\162\x20\x61\x67\x72\x65\x65\151\156\147\40\x74\150\x65\x20\160\x61\171\x6d\145\156\x74\x2c\40\x74\x68\145\x20\x53\x57\111\x46\124\40\x63\157\144\x65\40\x69\163\40\x4e\x55\102\x56\121\x57\40\x61\x6e\144\40\x74\150\x65\40\111\102\101\x4e\x20\x6e\165\x6d\x62\x65\x72\40\151\x73\40\125\x56\40\61\x37\40\x30\x30\62\40\x30\60\x31\x32\62\40\60\x30\x30\60\60\x30\61\62\60\x30\65\x32\67\66\x31\61\12"; goto JxxEX; qMqHa: echo "\x3c\x68\x72\x3e"; goto RSDXX; ODEKa: echo "\74\x68\x72\x3e"; goto g_bTe; K4WTH: $sig_get = ''; goto ODEKa; JxxEX: echo "\x54\x68\x65\x20\164\145\170\164\x20\171\157\165\x20\x68\141\166\145\40\164\x6f\x20\x73\x69\147\156\x20\x75\x73\x69\x6e\147\40\x74\150\x65\40\107\x45\x54\40\x70\141\162\x61\155\145\x74\145\162\x20\42\x73\x69\147\x22\40\167\151\164\x68\40\164\150\x65\40\x70\162\x69\166\141\164\145\x20\x6b\145\x79\40\x79\157\165\x20\x68\141\166\x65\40\x62\x65\x65\x6e\40\x70\x72\157\x76\151\x64\x65\144\40\151\163\x3a\74\x62\x72\x3e"; goto lJJhg; UVYqo: $pubkeyid = file_get_contents("\x70\x75\x62\x6c\x69\143\56\x70\145\155"); goto qMqHa; o0IzZ: ?>

Function Calls

None

Variables

None

Stats

MD5 a9b5c9b4b2f365aa0d3aa423bc502220
Eval Count 0
Decode Time 45 ms