4yrs for conventional loans
3yrs for FHA
You would need to have re-established credit....with at least 3tradelines.
Other than this...you're going to be looking at a hardmoney loan or subprime.
That's if you can find one or if your state will allow it
Everybody deserves a second chance and there are many programs available. The best thing you can do is find a reputable lender. If they cannot find financing for you now, don't get discouraged. Aske them what you will need to do to get back on track.