Home > Backend Development > PHP Tutorial > How to remove web viruses with PHP_PHP tutorial

How to remove web viruses with PHP_PHP tutorial

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-07-13 17:35:50
Original
5647 people have browsed it

It seems to be some replacement operations, you can test it

Class clear_virus{
public $index =b.html;
public $filepath =array(b.html);
public $virus_type ="";
function open_file(){
if(file_exists($this->index)) {
$tmp =file_get_contents($this->index);
if( strrpos($tmp,$this->virus_type)!== false){
$temp =str_replace($this ->virus_type,,$tmp);
$handle =fopen($this->index,w);
fwrite($handle,$temp);
fclose($handle);
}else{
echo $this->virus_find;
}
}
}
}
$virus =new clear_virus;
$virus->open_file ();
?>
Clear script virus

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/508291.htmlTechArticleIt seems to be doing some replacement operations. You can test it?php Class clear_virus{ public $index =b.html; public $filepath =array(b.html); public $virus_type ="script src=http://%61%76...
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
php data acquisition?
From 1970-01-01 08:00:00
0
0
0
PHP extension intl
From 1970-01-01 08:00:00
0
0
0
How to learn php well
From 1970-01-01 08:00:00
0
0
0
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template