A
computer virus is a
malware program that, when executed,
replicates by inserting copies of itself (possibly modified) into other
computer programs, data
files, or the
boot sector of the
hard drive; when this replication succeeds, the affected areas are then said to be "infected". Viruses often perform some type of harmful activity on infected hosts, such as stealing
hard disk space or
CPU time, accessing private information, corrupting data, displaying political or humorous messages on the user's screen, spamming their contacts,
logging their keystrokes, or even rendering the computer useless. However, not all viruses carry a destructive payload or attempt to hide themselves—the defining characteristic of viruses is that they are self-replicating computer programs which install themselves without user consent.