Goldman Sachs Group Inc , Morgan Stanley , JPMorgan Chase & Co and several other big U.S. banks said they were in a position to quickly repay Treasury capital injections after regulators released bank stress test results.

Officials assessed the financial strength of 19 financial institutions to see how much capital they would need over the next two years to survive a deep and extended recession.

A number of banks were found to have sufficient capital, paving the way for them to repay capital injected by the Treasury under the Troubled Asset Relief Program (TARP).

Though the money provided critical support during the darkest days of last year's financial crisis, it also carried restrictions, including limits on bonuses.

Goldman, which passed the test, said it believed it had met all requirements and was highly confident that we will soon repay the government's investment from the TARP's Capital Purchase Program.

Goldman shares, down 4 percent during regular trading on the New York Stock Exchange trade, rose 2 percent after the results of the stress tests were announced.

Goldman, which received $10 billion in TARP funds, last month announced the sale of $5 billion of common stock and $2 billion of debt that was not guaranteed by the U.S. Federal Deposit Insurance Corp (FDIC).

JPMorgan also believes it is eligible to repay the $25 billion it has received in taxpayer money, Chief Executive Jamie Dimon said on a conference call with analysts.

We will be in that process as soon as we can, said Dimon, who has repeatedly said that the bank did not want to take the funds in the first place.

Shares in the second largest U.S. bank sank more than 5 percent to $35.24 in regular trading and climbed slightly after hours to $35.85.

Morgan Stanley, even as it was directed to boost capital by $1.8 billion, said it too expected to repay its $10 billion in TARP funds as soon as possible.

Morgan announced it would sell $2 billion in stock and $3 billion in 5- and 10-year notes not guaranteed by the FDIC. The debt sale is multiple times oversubscribed, sources said.

Morgan Stanley shares, down 4.8 percent in regular trading, fell another 1.4 percent after the bell.

A number of banks that were found to be adequately capitalized also rushed to say they wanted to free themselves of the Treasury as an investor as quickly as possible.

American Express Co , Bank of New York Mellon , State Street Corp , U.S. Bancorp and BB&T Corp said they would seek to repay TARP as soon as they were permitted by regulators.

Citigroup , which was found to have a $5.5 billion capital shortfall, said it would repay the $45 billion it got from Treasury as soon as soon as possible.

Shares of American Express, which received $3.4 billion in TARP funds, rose 3 percent in after-market trade after it was deemed adequately capitalized by the stress test.

On Wednesday, federal officials said TARP recipients had to prove they had sufficient capital, could issue common stock and sell long-term debt without government guarantees before they could seek to return the TARP money.

State Street, down 3.3 percent in regular trading, also passed the test and its shares rose 8.8 percent in after-hours trade.

(Additional reporting by Elinor Comlay; Editing by Ted Kerr, Bernard Orr)