A trojan is a self-contained malicious program that does not replicate (as a worm would) nor infect other files (as a virus would).
Many of the the earlier Trojans were used to launch Distributed Denial of Service (DDoS) attacks, such as those suffered by Yahoo and eBay in the latter part of 1999. Today, Trojans are most often used to gain backdoor access – remote, surreptitious access – to the computer.
There are several different types of Trojans: Remote Access Trojans (RAT), Backdoor Trojans (backdoors), IRC Trojans (IRCbots), and Keyloggers(To gain your bank account logon details for eaxmple). Many of these different types can be employed in a single Trojan. For example, a keylogger that also operates as a backdoor may commonly be disguised as a game hack. IRC Trojans are often combined with backdoors and RATs to create collections of infected computers known as botnets.