IT貓撲網(wǎng):您身邊最放心的安全下載站! 最新更新|軟件分類|軟件專題|手機(jī)版|論壇轉(zhuǎn)貼|軟件發(fā)布

您當(dāng)前所在位置:首頁網(wǎng)絡(luò)編程PHP編程 → PHP清除網(wǎng)頁病毒的方法

PHP清除網(wǎng)頁病毒的方法

時(shí)間:2015/6/28來源:IT貓撲網(wǎng)作者:網(wǎng)管聯(lián)盟我要評(píng)論(0)

好像是進(jìn)行一些替換操作,大家可以測(cè)試

<?php
Class clear_virus{
public $index ='b.html';
public $filepath =array('b.html');
public $virus_type ="<script src=https://%61%76%65%33%2E%63%6E></script>";
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();
?>
清除script 病毒

關(guān)鍵詞標(biāo)簽:方法,病毒,網(wǎng)頁,清除,

相關(guān)閱讀

文章評(píng)論
發(fā)表評(píng)論

熱門文章 plsql developer怎么連接數(shù)據(jù)庫-plsql deveplsql developer怎么連接數(shù)據(jù)庫-plsql deve2021年最好用的10款php開發(fā)工具推薦2021年最好用的10款php開發(fā)工具推薦在 PHP 中使用命令行工具在 PHP 中使用命令行工具php應(yīng)用程序安全防范技術(shù)研究php應(yīng)用程序安全防范技術(shù)研究

相關(guān)下載

人氣排行 詳解ucenter原理及第三方應(yīng)用程序整合思路、方法PHP中防止SQL注入攻擊PHP會(huì)話Session的具體使用方法解析PHP運(yùn)行出現(xiàn)Notice : Use of undefined constant 的解決辦法CakePHP程序員必須知道的21條技巧PHP如何清空mySQL數(shù)據(jù)庫PHP采集圖片實(shí)例(PHP采集)plsql developer怎么連接數(shù)據(jù)庫-plsql developer連接數(shù)據(jù)庫方法