What types of protections should have been in place to prevent the sub-prime crisis? What can we do in the future?
There are many ways to look at this and the answer that one chooses depends to a great deal on one's political orientation.
For conservatives, the answer is that government should be less involved in the markets. A conservative would argue that much of the sub-prime lending was caused by government intervention. The government distorted the market through such institutions as Fannie Mae which made it more possible for people with poor credit to get loans.
Some conservatives might also look at the need for more safeguards within the banking business (but not imposed by the government). They would argue that the lending industry needs to be more transparent about the kinds of loans that it is making and the kinds of securities it is selling. This would make it easier for investors to know exactly what they are buying. They would also say that bankers need to do much more in the way of managing risk so that they do not get into such deep trouble.
By contrast, liberals would favor a regulatory approach. They would want to do things like giving regulators the power to "pop" bubbles that are occuring like that in the housing market. They would like to have more regulation of the derivatives market so that it would be harder to issue the sorts of complex financial products that helped to cause the crisis.
There is no consensus on this question, then. Conservatives call for less government regulation and liberals call for more.
It might be useful to compare the US and Canada. Canadian banks did not engage in sub-prime lending and did not go through a crisis in the recent recession. No Canadian bank required a bailout, and the "big 5" remained profitable despite the world economic crisis. This suggests that a well-regulated banking system with strong consumer protections benefits a country more than a deregulation.
The Basil rules and US stress tests will help prevent future collapses, but over the long run, the US government must focus on reducing taxes and regulations that favor the wealthy and focus on protecting the average consumer.