Updated

New York Times reporter Judith Miller (search) left a federal courthouse Friday after testifiying before a grand jury about her sources in the investigation into the White House role in the leak of a CIA operative's identity.

Miller, who spent 85 days in jail for refusing to reveal her sources to authorities, said she agreed to testify after receiving a personal waiver and narrow testimony agreement reached through special counsel Patrick Fitzgerald (search).

"Believe me, I did not want to be in jail. But I would have stayed even longer," Miller said, escorted by her lawyers and New York Times Publisher Arthur O. Sulzberger Jr., adding that she was looking forward to seeing her dog and spending time with her family.

Miller said she agreed to testify before the grand jury and cooperate with the investigation after she received a personal letter and telephone call "directly from my source."

“I served 85 days in jail because of my belief in the importance of upholding the confidential relationship that journalists have with their sources,” Miller told reporters outside the federal courthouse.

Miller left an Alexandria, Va., detention center Thursday evening once her source, identified by the Times as I. Lewis "Scooter" Libby (search), Vice President Dick Cheney's chief of staff, had released her from a promise of confidentiality. Miller was jailed in July for civil contempt of court when she refused to testify.

She spent more than four hours in the federal courthouse Friday, testifying about interviews in July 2003 with Libby before a federal grand jury convened by Fitzgerald.

Robert Bennett, Miller's attorney, accompanied Miller to the courthouse, where she arrived at 8:30 a.m. Friday.

Prosecutors are investigating White House involvement in the leaking of the identity of Valerie Plame (search), a CIA operative. Former Ambassador Joseph Wilson (search), Plame's husband, had publicly criticized the Bush administration and claims the White House retaliated by leaking Plame's name to reporters.

Wilson's criticism drew on the White House's position on weapons of mass destruction after none had been found in Iraq. Those weapons of mass destruction were the basis of President Bush's public reasoning for going to war.

Libby met with Miller days after Wilson's comments were printed in a Times op-ed piece.

Libby's attorney said he wondered why Miller needed a second waiver of confidentiality since Libby gave one to Miller's attorneys last year. Miller would not accept that waiver until she talked to Libby directly, according to the Times.

"We had signed a waiver more than a year ago," Attorney Joseph Tate said. "We didn't think this had anything to do with Scooter. I was under the impression from talking to [Miller attorney Floyd] Abrams that she was protecting a number of other sources."

Tate said Miller's lawyers told him that Miller wanted to speak directly to Libby.

Dick Thornburgh (search), former attorney general, told FOX News that the leak could have come from someone other than Libby.

"The prosecutor has pursued it relentlessly and we'll see how it plays out," Thornburgh said.

Times magazine reporter Matthew Cooper (search) has testified that top Bush adviser Karl Rove and Libby had spoken to him about Wilson's wife the same week that Libby met with Miller.

In October 2003, White House spokesman Scott McClellan (search) denied that Rove or Libby had any involvement.

Vic Fazio (search), former Democratic Congressional Campaign Committee chairman, told FOX News that the impact on the White House will depend on if Fitzgerald indicts Libby or Rove.

"If he decides to indict … then I think this is another major problem for the president," Fazio said, adding that the issue would fade away if there were no indictments.

"Chasing down leaks is a favorite sport in Washington. Generally, it's a fool's errand," added Thornburgh.

The president has gone back and forth on comments regarding the investigation, responding with various degrees of severity on how he would deal with anyone on his staff who was involved in the Plame investigation.

In September 2003, Bush said, "We'll take the appropriate action" concerning the case. His spokesman later said any leakers "would no longer be in this administration."

In June 2004, Bush reiterated that second pledge, answering "yes" when asked in a two-part question whether he would fire anyone in his administration who leaked Plame's name.

In July, amid revelations that Rove and Libby had been involved in the leaks, Bush said that "if someone committed a crime," he would be fired.

A criminal investigation followed the disclosure of Plame's identity by syndicated columnist Robert Novak on July 14, 2003, in his column. The column reported that two senior administration officials told Novak that Plame wanted to send Wilson to the African nation of Niger on behalf of the CIA to investigate possible Iraqi purchases of yellowcake uranium.

Wilson's article in the Times, titled "What I Didn't Find In Africa," had stated it was highly doubtful that any such transaction had ever taken place.

Miller remains the only reporter involved in the investigation who has gone to jail.

The federal grand jury expires Oct. 28.

FOX News' Melissa Drosjack and the Associated Press contributed to this report.