Malware is a blanket term for any malicious software that infects a computer or network. A virus is a type of malware, but malware also includes worms, Trojan horses, spyware, keyloggers and any other program designed to harm a computer or spy on usage of the machine.
Malware infects a computer in a variety of ways, most often through email and clicking infected links on the Internet. The goal of a malware program isn't always to disrupt a computer's operations; many sophisticated modern malware programs can run relatively undetected on a machine. They are designed to log keystrokes on the computer or steal sensitive personal or financial information from the user in other ways. Other programs may hijack the computer for revenue-generating purposes by sending spam email or making it appear that the computer is clicking on an ad link.
In 2008, Symantec estimated that there was currently more malware being released each day than legitimate programs. This makes it difficult for companies that produce anti-malware programs to keep their products current. A relatively new development that makes malware even harder for the average user to avoid is a method of embedding malware code in an otherwise legitimate computer application.