Scan files before uploading

Discussion in 'PHP' started by sponge.nika, Dec 28, 2010.

  1. #1
    I want to know how to scan the files before uploading it to the
    server in PHP applications.

    I also read that it is possible just check the file mime type, is it enough...... The permitted files that can be uploaded is txt, pdf, jpg, gif, png, doc, xls, zip, rar, docx, xlsx.
     
    sponge.nika, Dec 28, 2010 IP
  2. shopellor

    shopellor Peon

    Messages:
    3
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    You can do this using php-clamavlib. Here's a good how-to:
    http://www.howtoforge.com/scan_viruses_with_php_clamavlib
     
    shopellor, Dec 28, 2010 IP
  3. sponge.nika

    sponge.nika Peon

    Messages:
    6
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    If I do not use any program to scan the files and uploads files will be examined by administrators. And if they find something wrong the file will be deleted. Will this keep the system secure.
     
    sponge.nika, Jan 7, 2011 IP