The FBI commonly declines to pursue cyberstalking cases without compelling evidence of serious or imminent harm to an individual, victims of online harassment, advocacy groups and computer crime experts told The Associated Press.
But in the sensational episode that uncovered the spy chief's adulterous affair, the FBI's cyberdivision devoted months of tedious investigative work to uncover who had sent insulting and anonymous messages about Kelley, the Florida socialite who was friendly with Petraeus and Allen - and friends with a veteran FBI counterterrorism agent in Tampa.
The bureau probably would have ignored Kelley's complaint had it not been for information in the emails that indicated the sender was aware of the travel schedules of Petraeus and Allen, the top U.S. commander in Afghanistan. Instead, the FBI considered this from the earliest stages to be an exceptional case, and one so sensitive that FBI Director Robert Mueller and Attorney General Eric Holder were kept notified of its progress.
How the FBI's investigation unfolded - especially its decision not to alert the White House, the director of national intelligence or Congress about its discovery of Petraeus's sexual affair until Election Day - is under scrutiny, especially because there is no indication so far that any criminal charges will be filed.
Mueller and his deputy, Sean Joyce, have met privately with lawmakers to defend how the inquiry was handled. Holder said on Thursday that law enforcement officials did not inform the president and Congress about the probe because it did not uncover any threat to national security.
President Barack Obama said he was withholding judgment until he learns more. "You know, we don't have all the information yet," Obama said at a White House news conference. "But I want to say that I have a lot of confidence generally in the FBI." He added that it was "best right now for us to just see how this whole process is unfolding."
The FBI's cybersquads, like the one in Tampa that investigated the Petraeus case, are primarily focused on blocking criminals and terrorists from using the Internet to threaten national security or steal valuable information stored in government and corporate computers.
An AP review of court records found only nine cases over the past two years that identified cyberstalking or cyberharassment as the underlying crime in federal criminal complaints. In one recent case, a Michigan man was charged with cyberstalking after using the Internet and text messages to contact female victims, many of them minors, in an effort to obtain pornographic pictures. In another case, the FBI arrested a man for sending emails threatening to kill Los Angeles model Kourtney Reppert and her family.
"They turn people away all the time on the grounds that (cyberstalking) is a civil matter, not a criminal one," said Danielle Citron, a professor at the University of Maryland School of Law who studies cyberharassment issues.
In one such incident, a woman told the AP that her ex-boyfriend posted online an intimate video and nude photos of her with her name and email address, and she complained to the FBI. Speaking on condition of anonymity because she feared personal and professional repercussions, the woman said she had been deluged with offensive messages from strangers who viewed the photos and video. Her personal and professional reputation had been ruined. She changed her name.
The FBI's advice to her: hire a lawyer.
But the FBI considered Kelley's complaint significant. And for good reason, said David Laufman, a former federal prosecutor who handled national security cases. "Most cases aren't going to get this level of attention or resources," he said. "But most cases don't involve the incumbent director of the CIA or the head of U.S. military forces in Afghanistan."
The first anonymous emails, which the FBI ultimately traced to Paula Broadwell, an Army reservist and Petraeus's biographer, were sent in May to Allen and several other generals warning them to stay away from Kelley. The emails came from the pseudonym "Kelleypatrol" and included notes on Allen's plans to see Kelley in Washington the following week. Concerned about how anyone else would know about his personal plans, Allen forwarded the emails to Kelley to see whether she was playing a prank on them. Other generals also forward to Kelley copies of emails they received.
In early June, Kelley herself received the first of as many as five emails sent from different anonymous accounts alleging that she was up to no good. One of messages cited Petraeus by name and mentioned an upcoming social visit they had planned in Washington. The mysterious emails were sent to Kelley's personal account and to a separate account she jointly monitored with her husband.
Kelley contacted an FBI agent in Tampa she had met years earlier. The bureau believed the emails were serious because they suggested the mysterious sender knew about upcoming meetings of the CIA director and a Marine Corps general.
Agents examined the digital fingerprints that emails leave behind and eventually determined Broadwell had sent the messages from an account set up with a fictitious name. As the agents looked further, they came across a private Gmail account that used an alias name. It turned out to be Petraeus'. The contents of several of the exchanges between Petraeus and Broadwell indicated they were having an affair. A search of Broadwell's computers also found classified documents.
Most cyberstalking allegations are handled by state and local law enforcement organizations, said Michelle Garcia, director of the Stalking Resource Center at the National Center for Victims of Crime. "Given the variety of crimes that the FBI is responsible for addressing, I think often some of the stalking ones don't elevate to the top of the priority list," she said.
State police agencies have little contact with the FBI in responding to cyberstalking cases, Garcia said. "In our work with local law enforcement, very rarely do they talk about working with federal authorities on these cases."
The Petraeus case has drawn attention to how easy it is for the government to examine emails and computer files if they believe a law was broken. The FBI and other investigating agencies armed with subpoenas and warrants routinely gain access to email accounts offered by Google, Yahoo and other Internet providers.
Civil liberties groups have criticized the FBI for pursuing the investigation of the emails to Kelley because there is no indication the messages contained any threatening language or classified information. The episode underscores the need to strengthen the legal protections for electronic communications, according to the American Civil Liberties Union.
Federal agencies can obtain a substantial amount of information about the online activities of an individual without getting a warrant from a judge. A subpoena approved by a federal prosecutor is usually sufficient to get access to stored emails and login data.
"These are invasive powers that need to have a check against overuse and abuse," said Chris Soghoian, a senior policy analyst at the ACLU. "And that check should be a judge."
The Senate Judiciary Committee is meeting later this month to consider legislation that would do just that. The bill would require a warrant for all Internet communications. Law enforcement officials have resisted the change. But all the attention from the Petraeus case could give proponents of the legislation the momentum they need to push the bill through.
"If we learn nothing else from the Petraeus scandal, it should be that our private digital lives can become all too public when over-eager federal agents aren't held to rigorous legal standards," staff attorneys for the Electronic Frontier Foundation wrote in a blog post.
Associated Press writers Pete Yost, Adam Goldman and Eileen Sullivan and Associated Press researcher Julie Reed contributed to this report.