Question

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?

Was it helpful?

Solution

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.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top