computer virus, rogue computer program, typically a short program designed to disperse copies of itself to other computers and disrupt those computers' normal operations. A computer virus usually attaches to or inserts itself in an executable file or the boot sector (the area that contains the first instructions executed by a computer when it is started or restarted) of a disk; those that infect both files and boot records are called bimodal viruses. Although some viruses are merely disruptive, others can destroy or corrupt data or cause an operating system or applications program to malfunction.
Millions of computer malware programs are known; they can be spread via removable disks or drives, networks, or Internet websites and services. Although the term virus is commonly used for almost all computer malware, a distinction should be made between a true virus—which must attach itself to another program to be transmitted—and a bomb, a worm, and a trojan (or Trojan horse). A bomb is a program that resides silently in a computer's memory until it is triggered by a specific condition, such as a date. A worm is a destructive program that propagates itself over a network, reproducing as it goes. A trojan is a malicious program that passes itself off as a benign application; it cannot reproduce itself and, like a virus, must be distributed by a USB drive, an external disk, Internet downloads, electronic mail, or the like. Virus programs can also infect advanced cellular telephones (smartphones). Computer malware has been used since the early 21st cent. to steal sensitive information from government, business, and personal computers and to blackmail computer users.
Antivirus programs and hardware have been developed to combat malware. These search for evidence of a malware program (by checking for appearances or behavior that are characteristic of viruses, trojans, and the like), isolate infected files, and remove malware from a computer's software. Researchers are working to sidestep the tedious process of manually analyzing malware and creating protections against each program by developing an automated immune system for computers patterned after biological processes. In 1995 Israel became the first country to legislate penalties both for those who write malware and those who spread the programs.
See F. B. Cohen, A Short Course on Computer Viruses (2d ed. 1994); G. Smith, The Virus Creation Labs: A Journey into the Underground (1994); W. T. Polk et al., Anti-Virus Tools and Techniques for Computer Systems (1995); M. A. Ludwig. The Giant Black Book of Computer Viruses (2d ed. 1998); P. E. Fites, P. Johnston, and M. P. J. Kratz, The Computer Virus Crisis (1999).