One of Wall Street’s biggest investment and securities firms, Goldman Sachs, has been accused of betting against its clients. The firm allegedly sold securities backed by mortgages to clients, while reducing its own exposure to similar instruments in a bid to lower its risk.

In its 8-page annual shareholder letter, the firm maintained that it had gone about its business executing transactions on instruments that held both long term and short term risks in order to seek returns.

The letter also carried a denial that the large revenue generated despite the financial crisis came from betting against its clients. In the period before the crash, the company was keen on expanding holdings in housing but by the end of the year, mortgages began to go bottom up. Following these indications of a decline in the housing market, Goldman pulled out of that exposure to retain profitability, the management claims. Sound judgment helped the company keep its head above water even as some other companies were overwhelmed by falling housing rates and defaults in mortgages, according to company sources.

The firm credited the government’s timely assistance for its ability to hold its own during the financial meltdown and said it had lost lesser money during the sub-prime crisis due to a decision to limit its exposure to potentially risky mortgages.

Goldman was one of many lending institutions that received relief funds from the government. The bailout money caused a furor among the public. Widespread protests led to labor unions demanding the cancellation of bonus payouts within the company. Goldman’s Chief Executive Lloyd Blankfein also came under scrutiny and was called by the Financial Crisis Inquiry Commission to explain the firm’s actions.

Over the past year, the company has been at the receiving end for its pay packages and bonuses. Goldman showed a $4.79 billion profit towards the end of 2009, thanks to the revenue earned from its investment banking division. This made it one of US’s most profitable investment banks. Blankfein and other top executives received stock awards worth an estimated $8.9 billion in 2009. They attributed the bonus payments to the extraordinary events that took place last year.

Goldman is now carrying out some damage control to counter the bad publicity it has been receiving. The firm repaid the bailout money and gave $500 million in bonus funds to charity. In addition, a team of lobbyists is working on ensuring that Goldman gains all the leverage it can get by making campaign contributions.