A Computer Virus is another type of malware which when executed tries to replicate itself into other executable code which is available in the infected computer. If the virus was able to replicate it to other executable code, it is then infected with the computer virus. When the infected executable code is executed can infect again other executable codes. The key difference between virus and other malwares is this self-replication capability.
Normally, viruses propagate within a single computer, or may travel from one computer to another using storage media like CD-ROM, DVD-ROM, USB flash drive etc.
A Computer Virus program normally has the following mechanisms.
• A propagation mechanism that allows the virus to move from one computer to another computer.
• A replication mechanism that allows the virus to attach itself to another executable program.
• A trigger mechanism that is designed to execute the replication mechanism of the virus.
• A different tasks to perform the mischievous activities on the victim computer.