Disclaimer: I'm not an attorney, but my knowledge comes from 22 years experience doing Manhattan sales and rentals, as well as 18 years of being a landlord in Manhattan and Long Island.
NMLS # 6395
Financing Kentucky One Home at a Time
You said Condo, then said Co-op. Some condos do need board approval. And if it is a co-op, you do need board approval unless your potential landlord owns unsold shares.
Based on what you said, asking for 5 months' rent is not illegal. At that point, you should get a good lawyer who specializes in landlord-tenant matters. Good luck!
Often there are limits on the amount of a security deposit that can be requested (often 1-2 times the monthly rent), and there are sometimes requirements that the security deposit be kept in a separate account. Again, I don't know specifically about New York.
However, that's not what the landlord is asking for. He's asking for the last 5 months of RENT. In many areas of the country, that's perfectly permissible. I could ask for an entire year's worth of rent up-front on a rental property I have.
A security deposit has to be returned if conditions are met--thus, the logic behind an escrow account. Rent isn't returned; it goes straight into the owner's pocket. Thus, few if any localities (none I'm aware of) require an escrow account for pre-paid rent.
What if you have to leave the apartment 6 months into the lease? Fine. You've paid for the last 5 months, so it's your decision whether you leave or not.
What if the building burns down? Read your lease. There should be provisions in there about what happens if the unit becomes uninhabitable. And that could include refund of rent for the period the property is uninhabitable. If there aren't any such provisions, you can ask that he include them.
As another answer correctly notes, there's a big difference between a condo and a coop. It may or may not be important in relation to your concerns, but you should know the difference and you should know which type of building (legal structure) you'll be living in.
For more information, see a lawyer.
Hope that helps.