Updated

President Barack Obama's top lawyer at the White House, Bob Bauer, is quitting to return to his political law practice and represent Obama as his personal attorney and counsel to his re-election campaign.

Bauer will be replaced by his top deputy, Kathy Ruemmler, a former assistant U.S. attorney best known as a lead prosecutor in the Enron financial fraud case. At 40, Ruemmler will be one of the youngest lawyers to serve as the chief White House counsel to the president.

The move, announced Thursday, means Bauer will still play a central but outside role in advising a president who is seeking re-election in a time of divided government. The development was met without surprise. Bauer, a specialist in campaign finance, election law and ethics, is returning to the role as campaign counsel that he held when Obama ran for the presidency in 2008.

Ruemmler will take over the job as Obama's top in-house counsel and manager of a White House law office charged with juggling the domestic, national security and congressional oversight challenges confronting the president. She served as prosecutor, private attorney and an associate counsel in President Bill Clinton's White House.

In a statement, Obama praised Bauer as a friend with exceptional judgment. As to his new White House-based counsel, Obama said: "Kathy is an outstanding lawyer with impeccable judgment. Together, Bob and Kathy have led the White House Counsel's office, and Kathy will assure that it continues to successfully manage its wide variety of responsibilities."

Bauer has been part of Obama's circle since Obama was a freshman senator in Washington. He has long been a go-to lawyer for Democrats and is married to Anita Dunn, a Democratic operative who formerly served as Obama's communications director.

Bauer will leave his White House post at the end of June. He will also serve as counsel to the Democratic National Committee.

In a style typifying the low-key nature of transitions in the counsel's office, the news came in the form of a news release.

Ruemmler's fast rise in the legal community was cemented by her role in the successful federal prosecution of the Enron executives whose company imploded because of accounting tricks and shady business deals that cost people thousands of jobs and tens of billions in stock value. She was the co-lead prosecutor and delivered the closing argument on behalf of the government in the trial, and later won the Justice Department's highest award for her work in the Enron investigation.

Ruemmler (pronounced RUHM'-luhr) has been the primary deputy counsel at the White House since January 2010.

The counsel's position is known as one of the more brutally consuming jobs in the West Wing.

Beth Nolan, a former White House counsel who hired Ruemmler into Clinton's White House, said Ruemmler has a "strong ethical compass with a broad practical streak."

The counsel's job is often to sort through conflicting views in forming the best legal position for the president.

"She's not only a straight shooter, but she's also very open about her process and her thinking," said Nolan, the general counsel at George Washington University. "People know where they stand with her. You get to make your arguments, you get to make your views known, and she'll be clear about what she's deciding and why."

Ruemmler joined the Obama administration in 2009 as the principal associate deputy attorney general at the Justice Department. Before that, she was a litigation partner at Latham & Watkins in Washington from 2007-2009, and an assistant U.S. attorney in the District of Columbia from 2001-2007. Ruemmler worked for Clinton's White House counsel's office from 2000-2001.

She will be Obama's third White House counsel. His first, Greg Craig, resigned in 2009 amid questions over his handling of the president's promised closure of the Guantanamo Bay, Cuba, military prison, which remains open despite that pledge.