A computer virus its a computer program, malware that can copy itself and infect a computer. It is written specifically for corrupting of computer files and programs and can carry out its tasks based on the users activities with the computer. It attaches itself to our files and programs and spread exponentially throughout a computer or a network if not controlled. They infect only computer software. That excludes monitors and chips. A virus created for windows affects only windows systems and not other systems.
Here are types of computer viruses;
Boot Virus These viruses infect floppy disk boot records in hard disks.It attacks when the computer at the booting process. examples are antiEXE, Michelangelo, etc
Overwrite virus eg trivial.88.D,
Resident virus, Polymorphic virus, Directory virus and various types with
detailed explanation.
Worms
Similar to a virus, a computer worm is a self-replicating computer program. It can use a network to send copies of itself to other computers on the network without any user intervention. it can self-replicate sending out hundreds or thousands of copies of itself to mails or contacts in your messenger.
Types are;
Instant Messaging/Email Worms
They spread by means of sending links like pictures signups or adverts of corrupt websites to the contact list of an instant messenger.
IRC Worms
They spread through chat channels.
File-sharing Networks Worms etc
Trojan Horse
The Trojan horse behaves exactly like the mythological Trojan horse in the the battle of troy. It comes to you as a good software (haha a gift from the gods) on activation, it serves as a backdoor for intruders(greeks) It depends on what the intruder wants, but he fulfills a lot with a Trojan. From tampering with files, to what you may think of.