WASHINGTON Sources say CIA Director David Petraeus was never the target of an FBI investigation, but when his name surfaced in another probe, agents became concerned that Petraeus - or his email accounts - may have been compromised.
It all began a few months ago, when a female acquaintance of the CIA Director received a series of harassing emails, which apparently referenced Petraeus. The woman, who sources say is not a government official, notified the FBI.
Federal agents quickly traced the emails back to Petraeus' biographer Paula Broadwell, co-author of the 2012 book "All In: The Education of General David Petraeus."
A further investigation then revealed evidence of an extra-marital affair, including numerous cryptic emails between the retired four-star general and Broadwell.
Broadwell spent time with Petraeus when he commanded forces in Afghanistan, doing research for her book, which was co-written with Washington Post editor Vernon Loeb.
On a publicity tour last February, the married mother of two children made this comment:
"I'm not in love with David Petraeus, but I think he does present a terrific role model for young people, for executives, for men and women. No matter what, there's a great role model there."
Petraeus, who is also a married father of two, publicly praised his wife Holly during his Senate confirmation hearing:
"I have been blessed to have had her in my corner for some 37 years and 23 moves, and I appreciate the opportunity this morning to recognize her publicly."
But in his resignation letter to the CIA workforce, Petraeus confessed a moral failing, saying he used "extremely poor judgment" which was "unacceptable, both as a husband and as the leader of an organization such as ours."
The FBI investigation now is winding down.
There's no evidence that any sensitive CIA information was ever compromised, and no one is expected to face criminal charges.
To watch Jeff Glor's "Author Talk" interview with Petraeus biographer Paula Broadwell, who has been linked to the CIA Director's resignation, click on the video at left.