The three main firms that rate financial instruments, which failed so badly during the Housing Bubble at rating mortgage-backed securities have notoriously had a conflict of interest since the early 1970s. They used to be paid by buyers of financial instruments, who thus wanted honest evaluations, but Information Wants to Be Free! (In other words, the spread of the photocopier made it hard to make money out of being paid by buyers.)
So, for over 35 years, Moody's, D&B, and Fitch been paid by sellers who have incentives to demand softball evaluations. The rating firms' old school culture of honesty carried them along fairly well, but eventually it broke down under the lucrativeness and complexity of Housing Bubble mortgage-related instruments. Lots of street level petty fraud was going on between borrowers and mortgage brokers, but nobody — the clients, the feds, the media, the GOP, the Democrats — wanted to hear that "underserved" borrowers weren't going to be able to pay back their mortgages. So, instead of doing things like hiring private detectives to check for fraud, the ratings agencies just rubber stamped the crud concocted by the people paying their bills.
Here's a simple suggestion for fixing the ratings firms: barter. Only allow them to be compensated by the sellers of financial instruments in those exact financial instruments they rated. Then make the rating firms hold 100% of everything they rate for the lifetime of the asset. (They can borrow against those assets for the cash they need to carry on their businesses.)