Facebook's 400 million users have been targeted by a spam run that could infect their computers with malicious software designed to steals passwords and other data, according to security researchers at McAfee.

Over the last two days, millions of messages have been sent, which McAfee detected through customers running the company's security software, said Dave Marcus, McAfee's director of security research and communication.

The messages appear to come from Facebook, with a return address that looks legitimate but has been spoofed, such as "help@facebook.com," Marcus said.

The attachment is actually a Trojan horse program, which infects a computer without any visible signs. Marcus said the spam run contained a variety of malware programs, including password stealers, rogue antivirus programs or botnet code.

No Web site would automatically reset someone's password and send the new one in an e-mail, Marcus said. Facebook's high number of users makes it a prime target for spammers and hackers.

"There's a huge victim pool to go after," Marcus said.

Although it's unknown how many people may have been inadvertently duped, "I'd assume a lot of people would fall for something like that," Marcus said.

The spam is believed to have been sent from botnets called Cutwail and Rustock. Botnets are groups of computers that are controlled by hackers and often used for malicious activity such as sending spam or conducting denial-of-service attacks against Web sites.

Security analysts have been experimenting with different ways to shut down botnets. Over the last few weeks, two botnets called Mariposa and Waledac were shut down after security experts were able to commandeer the command-and-control servers used to communicate with infected computers.

But botnets have become more and more sophisticated and harder to combat. Many computer users don't even know their computers are infected, and the botnet code is engineered to avoid detection by antivirus programs.