Virus
Virus
Virus
Virus Definition
Viruses are malicious software programs that have been designed by other computer users to
cause destruction and havoc on a computer and spread themselves to other computers where they
can repeat the process.
It is different from worms. A worm is structured as a complete stand alone program, a virus is a
fragmented code embedded in a legitimate program.
Viruses are a major problem to users of micro computer systems(single user systems).
Multi user systems generally are not prone to viruses because the executable programs are
protected from writing by the operating system.
Programs must always have an extent of “COM”, “EXE”, or “SYS”.
Infection Sources
It is often distributed through shareware, pirated software, e-mail, p2p programs, infected storage
media or other programs where users share data.
Number of Viruses
There are currently over 50,000 known computer viruses and that number is growing rapidly.
Fortunately, only a small percentage of these are circulating widely. There are more MS-
DOS/Windows viruses than all other types of viruses combined (by a large margin).
Types
There are three major types of viruses, each very different from the other.
• Boot Sector Infectors: Also sometimes called boot record infectors, system viruses, or
boot viruses, these programs attack the vulnerable boot program that is stored on every
bootable floppy disk or hard disk. This code is executed by the system when the PC is
started up, by installing themselves here they guarantee that their code will be executed
whenever the system is started up, giving them full control over the system to do what
they wish. They are spread most commonly through infected bootable floppy disks.
• File Infectors: These viruses directly attack and modify program files, which are
usually .EXE or .COM files. When the program is run, the virus executes and does
whatever it wants to do. Usually it loads itself into memory and waits for a trigger to find
and infect other program files. These viruses are commonly spread through infected
floppy disks, over networks, and over the Internet.
• Macro Viruses: The newest type of virus, these clever programs make use of the built-in
programming languages in popular programs such as Microsoft Word and Microsoft
Excel. These programs allow users to create programs that automate tasks, called macros.
As the macro languages have become more powerful, virus writers have created
malevolent macros that, when opened unwittingly, duplicate themselves into other
documents and spread just like a conventional virus would. These programs can cause just
as much damage as regular viruses, despite the fact that they are very different: regular
viruses are low-level machine language programs, while macro viruses are actually high-
level interpreted BASIC programs! The most common type of macro virus right now
infects Microsoft Word documents. In computing terminology, a macro virus is a virus
that is written in a macro language: that is to say, a language built into a software
application such as a word processor. Since some applications (notably, but not
exclusively, the parts of Microsoft Office) allow macro programs to be embedded in
documents, so that the programs may be run automatically when the document is opened,
this provides a distinct mechanism by which viruses can be spread. This is why it may be
dangerous to open unexpected attachments in e-mails.
Virus types based on What they infect
• System Sector Viruses
These infect control information on the disk itself.
• File Viruses
These infect program (COM and EXE) files.
• Macro Viruses
• Companion Viruses
A special type that adds files that run first to your disk. Companion viruses can be considered file
infector viruses like resident or direct action types. They are known as companion viruses
because once they get into the system they "accompany" the other files that already exist. In
other words, in order to carry out their infection routines, companion viruses can wait in memory
until a program is run (resident viruses) or act immediately by making copies of themselves
(direct action viruses).
Some examples include: Stator, Asimov.1539, Terrax.1069.
• Directory viruses An operating system finds files by looking up the path (composed of the
disk drive and directory) in which each file is stored.
Directory viruses change the paths that indicate the location of a file. By executing a program
(file with the extension .EXE or .COM) which has been infected by a virus, you are unwittingly
running the virus program, while the original file and program have been previously moved by
the virus.
• Batch File Viruses
These use text batch files to infect. The first line causes batch file commands to not display on
the screen so you won't see what's going on. The second line is a label as far as the batch file is
concerned. In reality, this label is what makes the whole thing work so, of course, we're not going
to show any examples. The third line copies the batch file itself to an executable file named
Q.COM in the root directory of the C: drive. The output of the COPY command is directed to the
NUL device so you see nothing on the screen that indicates this copy took place. Finally, the
fourth line executes the newly created Q.COM file.
• Source Code Viruses
These add code to actual program source code. Source code comes in many forms because of the
many different types of compilers and languages available. This is one reason why source code
viruses are not particularly common. The other is that so few people actually write programs it
becomes difficult for a source code-only virus to find victims to infect.
• Visual Basic Worms
These worms use the Visual Basic language to control the computer and perform tasks.
Protection Strategies
● Keep your computer up-to-date with the latest patches: We know this sounds obvious but,
we are still amazed at the number of machines we deal with that don't have the most
recent patches on them. These patches seal up security holes that viruses take advantage
of, so it's in your best interest to stay as recent as possible with patches.
● Update AV Software.
● Safe Boot Disk.
● Hard Disk Boot. Change your boot sequence so that the hard disk is the first boot disk
instead of the floppy disk.
● Use RTF Not DOC.
Consider Alternate Software. In the politest sense this would be a recommendation to
switch to software that is not as likely to be affected by viruses/worms. For many offices a
switch away from Word, Excel, and Outlook/Outlook Express would be difficult as these
programs came as standard software on many systems. But it's worth consideration.
● Don't Open Attachments.
● Disable Scripting. Turn off the Windows Scripting Host if you don't need it. Scripts are
just fancy macros that can apply across programs and are a major vehicle for worms.
Instructions here.
● Show Extensions. Set all programs to show you the full file name, particularly E-mail
programs. If your program drops the extension you don't really know if the attachment is
executable or not.
● Be smart in the websites you choose to visit: There are a lot of bad websites out there that
actually have viruses programmed right into the website. Through a process called
malicious scripting, viruses can be installed onto your computer just by visiting a website.
● Protect Floppies.
● Backup. Finally, but most importantly: backup, backup, backup!
References:
The Little Black Book of Computer Viruses, Electronic Edition, by Mark Ludwig
http://www.virusportal.com/com/training/train_dat3.shtml
http://www.essentialcomputersecurity.com/Viruses.html
http://www.pcguide.com/care/data/virus/bgTypes-c.html
http://www.cknow.com/vtutor
Joby K James
Roll No.13
S4 MCA, RIT
Computer Viruses