Ask for copies of the references. It's strange that both your last two employers gave you bad references. It does make it seem as if there was something wrong.
If the references are correct then there's nothing you can do. If they are incorrect then you may have a case against the company who provided them.
Your last employer was entitled to terminate your contract without giving you a reason as you'd been employed less than 12 months, so you would have no case against them.
Personally, I'd give a bit more thought as to what went wrong with the previous two companies.