All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad is His slave and Messenger. We ask Allaah to exalt his mention as well as that of his family and all his companions.
If your father in-law is as you mentioned in the question, then he has committed an evil act and is sinful, as he acted against the Fitrah (natural disposition upon which Allaah created mankind). A father in-law is a Mahram (i.e. a spouse or a person whom one is permanently prohibited from marrying due to suckling, marital, or blood relations). He is a Mahram for the wife of his son by the text of the Quran. Allaah Says (what means): {...or their husband's fathers.}[Quran 24:31]; which means that he is among the Mahaarim (plural of Mahram) of a woman. Therefore, he should protect his son in his honour, and respect the dignity of his daughter in-law, and not be a reason of despising them.
Thus, we advise you to wear Hijab in front of him and not allow him to be in seclusion with you. You should also advise him and remind him of Allaah, as he may repent. If he persists in doing so and does not listen to the advice, then you may threaten him to inform his son [i.e. your husband], or whoever may deter him like the authorities and the like. For more benefit, please refer to Fatwa 88782.
Finally, it should be noted that it is your right on your husband to provide you with a separate accommodation where you would feel more comfortable and safe. It is understood from the question that you live with your husband's family; if this is the case, then you have the right to ask him to provide you with a separate accommodation as this may be a solution to the problem. Rather, you are obliged to ask him to provide you with a separate accommodation if living with your father in-law leads to what you mentioned.
Allaah knows best.