Antivirus|Multimedia Tools|Burning Tools|Internet Tools|Recovery Tools|Converter|PC Games|Full Version Software|Mediafire|Ebooks english...

Thursday, April 19, 2012

Create Your Own Anti-Virus Program

Ever wanted to create your own anti-virus program? Follow this tutorial and you will got your own anti-virus in a few minutes.
Visual basic 2008 express edition needed!

First, let’s start a new project and put a listbox and a button on your form. Insert the following code in the click event of your button:

—–

Private

If My.Computer.FileSystem.DirectoryExists(”c:Program Files180search Assistant”) Then ListBox1.Items.Add(”Adware.180Search”)

—–

‘ This will add the item ‘Adware.180search to the listbox if c:Program files180search Assistant exists. If you want to search for a file you will have to do this:

—–

If My.Computer.FileSystem.FileExists(”c:Program Files180search Assistantsomething”) Then ListBox1.Items.Add(”Adware.180Search”)

‘ So if you want to search for a directory you have to use DirectoryExists, and if you want to search for a file you have to use FileExists.

Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click

Congratulations! You created an anti-virus that scans for files or folders. If you want to have an anti-virus that scans for processes, you will have to use this code: (Remember to type the process with uppercase characters!)

—–

strFoundProcess =

Dim AllProcessDim ProcessDim strFoundProcessFalse

AllProcess = GetObject(

“winmgmts:”)

strFoundProcess =

For Each Process In AllProcess.InstancesOf(”Win32_process”) If (InStr(UCase(Process.Name), “THEPROCESS.EXE“) = 1) Then ListBox1.Items.Add(”THENAMEOFTHEVIRUS“) True Exit For End If Next If strFoundProcess = False Then End If

AllProcess =

Nothing

—–

strFoundProcess =

False

AllProcess = GetObject(

“winmgmts:”)

If (InStr(UCase(Process.Name), “THEPROCESS.EXE“) = 1) Then

ListBox1.Items.Add(

strFoundProcess =

THENAMEOFTHEVIRUS“)True Exit For End If Next If strFoundProcess = False Then End If

AllProcess =

Nothing

For Each Process In AllProcess.InstancesOf(”Win32_process”)

You only need to that once! After you did that once, you can use this code:

False

AllProcess = GetObject(

“winmgmts:”)

‘create object For Each Process In AllProcess.InstancesOf(”Win32_process”)

‘Get all the processes running in your PC If (InStr(UCase(Process.Name), “AUPDATE.EXE”) = 1) Then

‘Made all uppercase to remove ambiguity. Replace TASKMGR.EXE with your application name in CAPS.

ListBox1.Items.Add(

“Spyware.W32.123bar”

)

strFoundProcess =

TrueExit

ForEnd

If

NextIf strFoundProcess = False

ThenEnd

If

AllProcess =

Nothing

Congrats! You completed this tutorial and know how to create your own anti-virus!

strFoundProcess =

 

 

----------------------------------------------------------------------------------------------------------




Share this post
  • Share to Facebook
  • Share to Twitter
  • Share to Google+
  • Share to Stumble Upon
  • Share to Evernote
  • Share to Blogger
  • Share to Email
  • Share to Yahoo Messenger
  • More...

0 comments

:) :-) :)) =)) :( :-( :(( :d :-d @-) :p :o :>) (o) [-( :-? (p) :-s (m) 8-) :-t :-b b-( :-# =p~ :-$ (b) (f) x-) (k) (h) (c) cheer

 
© 2011 English Software Collection
Designed by BlogThietKe Cooperated with Duy Pham
Released under Creative Commons 3.0 CC BY-NC 3.0
Posts RSSComments RSS
Back to top