Gen. David Petraeus has resigned as director of the Central Intelligence Agency, MSNBC reports.
MSNBC host Andrea Mitchell broke the news Friday afternoon, reading Petraeus' resignation letter on air.
Petraeus wrote in the letter to the CIA staff on Friday that he had gone to the White House on Thursday and asked the president "for personal reasons" to resign.
"After being married for more than 37 years I showed extremely poor judgment by engaging in an extramarital affair," Petraeus wrote in his letter. "Such behavior is unacceptable, both as a husband and as a leader of an organization such as ours."
He was reportedly having an affair with Paula Broadwell, the author of his biography.
The retired four-star general led the U.S. military in Iraq and Afghanistan. President Barack Obama appointed him to direct the CIA in September 2011.
Petraeus said that the president accepted his resignation on Thursday.
The full text of Petraeus' resignation letter is below, courtesy of CNN.
According to the New York Times, some senior members of Congress were told about Petraeus' resignation six hours before it was announced. White House officials said they knew he was considering resignation as early as Wednesday night.
The FBI learned of the affair after officials monitored Petraeus' email, officials told the AP. They were investigating claims that Broadwell had access to his email.
The president also released a statement on Petraeus' resignation Friday. "David Petraeus has provided extraordinary service to the United States for decades. 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."
The president said that Michael Morrell, the CIA's deputy director, would serve as acting director.
As for who will replace Petraeus in the longterm, a former senior intelligence official told AOL Defense that Mike Vickers is a leading candidate.
"The prevailing wisdom is that Mike Vickers wants this with all his heart and soul," the official told AOL Defense. Vickers, now the Undersecretary of Defense for Intelligence, is the legendary former CIA operative who led the war against the Soviets in Afghanistan chronicled in the book, Charlie Wilson's War. Another candidate is Stephanie O'Sullivan, the principal Deputy Director of National Intelligence.
Petraeus's resignation came at a time when his office was under extraordinary pressure over its role in the attack in Benghazi, Libya, when four Americans, including the U.S. ambassador, were killed.
For many weeks the White House had come under intense pressure for the attack, before it finally emerged that the CIA had actually played a central role in the episode. Two of the Americans killed were identified as undercover agents for the CIA, and the vast majority of Americans on the ground that night turned out to be with the agency.
In a Wall Street Journal article a week before the election, several administration officials pointed to Petraeus specifically and accused him of mishandling the controversy, by appearing to be aloof and delivering misinformation to the White House in the early days after that attacks.
Congress intends to continue to investigate the incident, and Petraeus was expected to testify during a closed-door hearing next week before the Senate Intelligence Committee.
Sen. Dianne Feinstein (D-Calif.), the head of the Senate Intelligence Committee, released a statement responding to Petraeus' resignation. "I wish President Obama had not accepted this resignation," Feinstein said, "but I understand and respect the decision."
Speaking on CNN, former CIA operative Bob Baer noted that while resignations from extramarital affairs are not unheard of at the agency, they are almost never the announced reason for giving up the post.
"I think there's a big story behind it," Baer said.
Full text of Petraeus' resignation letter:
Yesterday afternoon, I went to the White House and asked the President to be allowed, for personal reasons, to resign from my position as D/CIA. 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. This afternoon, the President graciously accepted my resignation.
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. 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.
Teddy Roosevelt once observed that life’s greatest gift is the opportunity to work hard at work worth doing. I will always treasure my opportunity to have done that with you and I will always regret the circumstances that brought that work with you to an end.
Thank you for your extraordinary service to our country, and best wishes for continued success in the important endeavors that lie ahead for our country and our Agency.
With admiration and appreciation,
David H. Petraeus
Joshua Hersh contributed reporting.
Watch BuzzFeed reporter Michael Hastings, who has covered Petraeus for years, discuss the affair on HuffPost Live below.