I want to upload media and textual files inside the database for my personal use. I have been successful in adding all the files to the database, but I want to scan each file for viruses before uploading it into the database so that a infected file could not be stored inside the database.
How would I scan a file for viruses before upload in VB.NET?
Use System.Diagnostics.Process and start a command-line anti-virus program, such as clam-av.
Of course, that means you need to save the file in a temporary directory first.