02-19-2010, 09:51 AM
I am trying to make a file scanner to check if it has viruses with php. I made the upload form already. Can someone help me with the code? I heard you can do it with clamscan. I tried:
exec("clamscan /var/www/upload", $file, $return)
if ($return == 0)
{
echo "clean"
}
else
{
echo "virus!"
}
But it always comes out as infected, even if it is not. Help please? show me the right path or somethnig. Or just the right code.
thanks
exec("clamscan /var/www/upload", $file, $return)
if ($return == 0)
{
echo "clean"
}
else
{
echo "virus!"
}
But it always comes out as infected, even if it is not. Help please? show me the right path or somethnig. Or just the right code.
thanks