Mostly it was a matter of criminal investigators not getting assistance and documentation from regulators - in this case the Office of the Comptroller of the Currency, the Office of Thrift Supervision and the Fed. From the NYT:
"When regulators don't believe in regulation and don't get what is going on at the companies they oversee, there can be no major white-collar crime prosecutions," said Henry N. Pontell, professor of criminology, law and society in the School of Social Ecology at the University of California, Irvine. "If they don't understand what we call collective embezzlement, where people are literally looting their own firms, then it's impossible to bring cases."
Enforcement agencies traditionally depend heavily on referrals from bank regulators, who are more savvy on complex financial matters. But data supplied by the Justice Department and compiled by a group at Syracuse University show that over the last decade, regulators have referred substantially fewer cases to criminal investigators than previously.
Wait, it gets worse. The NYT story notes that oversight for Countrywide was switched from the comptroller and Federal Reserve to the office of the thrift supervisor, at the time run by John Reich, a former banker appointed by George W. Bush. Robert Gnaizda, former general counsel at the Greenlining Institute, said he had spoken often with Reich about Countrywide's reckless lending.
"I told John, 'This is what any police chief does if he wants to solve a crime,' " Mr. Gnaizda said in an interview. "John was uninterested. He told me he was a good friend of [CEO Angelo] Mozilo's." In an e-mail message, Mr. Reich said he did not recall the conversation with Mr. Gnaizda, and his relationships with the chief executives of banks overseen by his agency were strictly professional. "I met with Mr. Mozilo only a few times, always in a business environment, and any insinuation of a personal friendship is simply false," he wrote.
Last month, the U.S. attorney's office in Los Angeles dropped its investigation of Mozilo.