I am so sorry that you are in such a dilema - many other tenants are experiencing the same all over the country. As Realtors we can't advice you on legal matters, so a real estate attorney will be the right person to contact regarding your legal rights.
However we have been working with some banks and have had to deliver such bad news to other tenants. The reality is that you will most likely lose your deposits. If it was me, I probably would stop paying the landlord and try to live out my deposit while I am looking for another place to rent.
If you have not received a formal notice to vacate, you have some time. I can't speak for every bank or every company, but I can tell you the procedures followed by the institutions we work with.
You will receive a first notice that the property has been foreclosed. First you should ask for identification from the person delivering the notice. Ask for written notice that he/she is authorized to act on behalf of the foreclosing lender. Then ask for written proof that the property was foreclosed. Ask for all these actions individually - this will buy you time. If you are dealing with an experienced agent, he/she will bring everything at one time, but sometimes you get a green agent and you may have him/her going back and forth for a couple of weeks.
Once it is official that the property is foreclosed, you will likely receive a cash for keys offer. The bank wants you to vacate volutarily, so they may offer you $500 to give up the keys and leave the apartment clean. You can negotiate that amount - the most I've heard anyone get is $1500 for a larger family. The banks will ask you to move in two weeks, but you can negotiate up to a month. Do not get angry or become agressive with the person delivering the bad news. Most agents doing this type of work want to help you and will bend over backward to assist you as long as communications remain open and amicable.
You are going to receive three offers from the bank... if you have not negotiated an exit by the third offer, the bank will start eviction proceedings. That may take 3 to 6 weeks. At this point they will not pay you anything and the next notice will be from a sheriff knocking at your door with a moving crew. They will move all your possessions to the dumpster area or public sidewalk and leave it there for others to steal or to be rained on.
What is most important in this process is the following. DO NOT IGNORE THE WARNINGS. NEGOTIATE A SETTLEMENT BY THE THIRD OFFER. TRY TO BUY TIME, but be in control by being proactive. If you ignore the situation, you will get no notice and it will cost you more and you have no recourse. The Realtor who brings you the notice is not your enemy - he/she can help you find another home very quickly. Good luck...
Lars Kier 813-333-9930