text: A day after the story broke, the news remains stunning — CIA director and retired Gen. David Petraeus resigns in a lightning stroke, admitting he used extremely poor judgment by engaging in an extramarital affair. It's shocking because Petraeus is considered an extremely able leader who's been judged by this single word, says NPR's Tom Bowman: Iraq.  "He's one of the few national leaders who came out looking good from the Iraq War, " Tom tells Weekend Edition Saturday. "He took over command in 2007 when people thought this Iraq War was doomed. What he did was changed the way they looked at the war. ... He focused on the population, rather than just capturing and killing insurgents. He pushed for security of the population, worked with tribal elders, built roads and schools, and tied the people to their government. That's how you deal with insurgencies."  But this extremely experienced general was tripped up by an investigation launched by the FBI. Tom tells NPR's Scott Simon while the former director is not a target of inquiry, his paramour, Paula Broadwell, is; that led to concerns that classified information was being leaked.  "She was the one having an affair with Gen. Petraeus. She's a West Point grad, a researcher, wrote this glowing biography of Petraeus. And the FBI found hundreds — if not thousands — of emails between the two, and clearly from the emails there was an affair going on here, between the two. But there were no criminal charges so the FBI just kind of notified Petraeus, you know, we have all this information and that led to him going to the president and resigning."  It isn't clear why the FBI opened its investigation into Broadwell. But the change in the former director's fortunes was swift: His biography, available yesterday on the CIA website, has been removed. Broadwell is a co-author of Petraeus' biography, All In: The Education of General David Petraeus. The book notes from Amazon indicate Broadwell spent hundreds of hours in Afghanistan with Petraeus and members of his staff to research the book. She has not issued a public statement. But it doesn't change his past achievements. Petraeus succeeded in Iraq because he shifted focus from simply finding and killing insurgents to broadening the U.S. military's engagement with Iraqi civilians. Tom points out Petraeus took over in Iraq in 2007; he focused on talking with tribal elders, and building roads and schools in an effort to limit the Iraqi insurgency's power. After Iraq, he was shifted to Afghanistan in June 2010 to assume command of U.S. and NATO troops in the war there. He was seen as a steady hand; he took over from the clumsy Gen. Stanley McChrystal, ousted after making critical remarks to a reporter about the Obama administration's handling of the Afghan war. But Petraeus didn't stay long in Afghanistan; in September 2011, he left the military to take the job as Obama's CIA director. Now the CIA is being led by Petraeus' former deputy, Mike Morrell. Next week, it's Morell who'll apparently appear in place of Petraeus at a scheduled hearing into the attack against the U.S. consulate in Benghazi, Libya, according to Politico. Update at 4:43 p.m. ET: Threatening Emails Spark FBI Probe Sources familiar with the investigation tell NPR's Dina Temple-Raston that this began as a simple harassment case. A third person went to an FBI field office and reported harassment. Officials told The Washington Post that the person had received threatening emails and "was so frightened that she went to the FBI for protection and help tracking down the sender." It turned out Paula Broadwell was behind the emails. During the course of the investigation, the agency found messages from Petraeus that it couldn't believe he would write, so the case was turned over to the FBI's national security division. Investigators thought Petraeus' email account was hacked — turns out it wasn't. Officials told The Washington Post that "the sexual nature of the e-mails led them to conclude that Petraeus and Broadwell were engaged in an affair." It is unclear if Petraeus was also having an affair with the third person or whether Broadwell just suspected it.