Wearing a grey suit, white shirt and dark tie, Bernanke provided mostly curt answers to questions from the lead plaintiff's attorney, David Boies. Bernanke defended the government's bailout package for AIG, including an equity stake taken by the government.

"I knew that the equity component was additional compensation to the taxpayer for the risk being taken" he said, when asked if he knew the basis for the government taking what became a 92 percent stake in the insurance giant.

Boies spent a good part of the more than two hours Bernanke was on the stand, asking about that equity stake. He asked Bernanke if he had sought other opinions, or asked on what basis an equity stake needed to be taken in AIG. He also asked Bernanke if he had asked for any additional analysis on why the rates on the loans to AIG were so high.

Bernanke said he had not. Boies asked Bernanke if he had asked about the basis of various fees that were part of the bailout package. Bernanke said he had not.

What Bernanke did say was that in approving the deal along with the rest of the Fed's Board of Governors he relied on the judgment of the New York Federal Reserve Bank, which was providing the initial commitments to AIG.

"All I recall is that the package needed to minimize the windfall to shareholders and protect the taxpayers," Bernanke said.

The lawsuit, which is being heard in a six-week bench trial, was brought by Starr International, once AIG's biggest shareholder and the investment firm of AIG's former CEO Hank Greenberg.

Greenberg ran AIG for 40 years before stepping down in 2005 amid an accounting investigation.

The lawsuit alleges the government violated AIG and its shareholders Fifth Amendment rights by treating the firm unfairly, and improperly compensating shareholders for the equity stake the government took.

With his questioning, Boies is trying to paint a picture of government exceeding its scope of emergency powers to force a slap dash rescue package on AIG that failed to properly value the company, a rescue package down without the appropriate due diligence to justify the terms of the agreement.

The government has maintained as the lender of last resort to a failing AIG, the terms were appropriate given the risk it was taking, and that the terms were needed to discourage other firms from seeking similar bailouts.

Bernanke was called to the stand following the conclusion of more than two days of testimony from former Treasury Secretary Tim Geithner, who ran the New York Federal Reserve at the time of the financial crisis.

The last of the "big three" witnesses to take the stand this week, Bernanke appeared to be the most put out at being in court. Monday's testimony from former Treasury Secretary Hank Paulson was short, only two hours long, and marked by the easiness of the exchanges between Paulson and the plaintiff's attorney David Boies.

Even Geithner, who faced far more extensive questioning from Boies, punctuated his answers with some lighter replies and was affable during most his time on the stand.

Bernanke, Paulson and Geithner were the architects of the government's response to the financial crisis, including the AIG bailout in 2008.