Petraeus said that Obama had accepted his resignation. Citing affair, Petraeus resigns at CIA

David Petraeus resigned his post as director of the Central Intelligence Agency on Friday, citing an extramarital affair.

Petraeus visited the White House on Thursday to ask President Barack Obama to accept his resignation “for personal reasons,” he said in a statement to CIA staff. “After being married for over 37 years, I showed extremely poor judgment by engaging in an extramarital affair. Such behavior is unacceptable, both as a husband and as the leader of an organization such as ours.”


( PHOTOS: Gen. David Petraeus)

The FBI is investigating Paula Broadwell, author of the biography “All In: The Education of General David Petraeus,” for improperly attempting to access his email, law enforcement officials tell NBC News.

An intelligence source confirms to POLITICO that the FBI had been investigating Petraeus after accidentally learning of the affair. He was pushed to exit before it all came out in detail.

“Director Petraeus was encouraged to get ahead of it and take control of the situation because it would eventually come out,” the source said.

A White House official told POLITICO that the White House was informed of the issue Wednesday, and Obama was told Thursday.

“The president met with General Petraeus yesterday. In that meeting, Petraeus offered his resignation and explained the circumstances behind it,” the official said. “The president accepted [Petraeus’s] resignation in a phone call this afternoon.”

( Also on POLITICO: 10 fast facts about Gen. Petraeus)

The resignation comes as the intelligence community remains under pressure over the attack in Benghazi that killed Ambassador Chris Stevens and three others. Petraeus was slated to testify next Thursday at a closed Senate Intelligence Committee hearing on Benghazi.

In a statement, Obama said he accepted Petraeus’s resignation and expressed confidence in Michael Morell, the agency’s deputy director, to take over as acting director. Morell will testify in Petraeus’s place next week.

( See also: Gen. Petaeus’s full resignation letter)

Petraeus “provided extraordinary service to the United States for decades,” Obama said. “By any measure, he was one of the outstanding General officers of his generation, helping our military adapt to new challenges, and leading our men and women in uniform through a remarkable period of service in Iraq and Afghanistan, where he helped our nation put those wars on a path to a responsible end. As Director of the Central Intelligence Agency, he has continued to serve with characteristic intellectual rigor, dedication, and patriotism.

“By any measure, through his lifetime of service David Petraeus has made our country safer and stronger,” Obama said.

"Going forward, my thoughts and prayers are with Dave and Holly Petraeus, who has done so much to help military families through her own work. I wish them the very best at this difficult time,” Obama said.

( Also on POLITICO: Obama: My thoughts, prayers with Petraeus family)

“As I depart Langley, I want you to know that it has been the greatest of privileges to have served with you, the officers of our Nation’s Silent Service, a work force that is truly exceptional in every regard,” Petraeus said in his statement to CIA staff. “Indeed, you did extraordinary work on a host of critical missions during my time as director, and I am deeply grateful to you for that.”

Holly Petraeus works at the Consumer Financial Protection Bureau, where she established the Office of Servicemember Affairs. In that role, she worked closely with first lady Michelle Obama and Dr. Jill Biden on improving financial protections for military families.

In a statement, Director of National Intelligence James Clapper praised Petraeus.

“Since he took over as Director in September of last year, he and I have worked together to tackle some of the most challenging issues faced by the Intelligence Community in more than a decade,” Clapper said.

“Under his leadership, the CIA remained instrumental in providing our policy makers decision advantage through the best possible intelligence. I’m particularly thankful for Dave’s unwavering support and personal commitment to my efforts to lead the Intelligence Community and integrate our intelligence enterprise.”

Congressional leaders quickly thanked Petraeus for his work.

“This is an enormous loss for our nation’s intelligence community and for our country.”

“General Petraeus is one of America’s most outstanding and distinguished military leaders and a true American patriot,” House Homeland Security Committee Chairman Peter King (R-N.Y.) said. “I hold General Petraeus in the highest regard, regret his resignation and wish him and his family the very best.”

Sen. Dianne Feinstein (D-Calif.), the chairwoman of the Senate Intelligence Committee, said that Petraeus’s resignation was “an enormous loss for our nation’s intelligence community and for our country.”

She added that she “wish[ed] President Obama had not accepted this resignation, but I understand and respect the decision. David Petraeus is one of America’s best and brightest, and all Americans should be grateful for his service.”

Sen. John McCain (R-Ariz.) joined in the praise.

“His inspirational leadership and his genius were directly responsible – after years of failure – for the success of the surge in Iraq,” McCain said in a statement. “General Petraeus has devoted his life to serving the country he loves, and America is so much the better for it.”

Petraeus spent nearly four decades in the Army, before retiring last summer to take the job heading the CIA. Before Friday’s revelation, his name had been under some discussion as a potential replacement for Leon Panetta as secretary of defense.

Petraeus was also seen as a possible presidential or vice presidential candidate and had even been talked about as a potential Republican presidential candidate for 2012.

Rumors that Petraeus might be interested in a political career date back to at least 2008, when there was speculation that Sen. John McCain (R-Ariz.) was considering the four-star general as his running mate. There was a movement to draft Petraeus to run for the White House in 2012, and the Drudge Report suggested this summer that Mitt Romney might pick the CIA director as his running mate. All those rumors were denied by Petraeus, most recently, by the CIA.

Petraeus did, though, express some interest in becoming president of Princeton University, where he earned a Ph.D. in international relations in 1987.

Seung Min Kim contributed to this report.