Thanks for your enquiry.
I am afraid that as you have a CCJ, this will remain on your credit history for a period of 6 years, so during this period, you are unlikely to be able to obtain a new Mortgage from any of the high street Banks.
However, there are other Lenders out there who may be able to assist you, although the interest rate they offer is not likely to be as attractive as ones offered by HSBC or Lloyds. GE Money are probably your best bet to approach, but there are other Lenders out there who may be able to help.
I hope this answers your question, and if so, I would be grateful if you could leave positive feedback.