Assalamualaikum w.b.t. I’ve always heard of the term temporary mahram. Can you explain what is meant by temporary mahram? And what are the effects and the rulings of a person with a relationship with another of temporary mahram? Thank you.
Alhamdulillah, praise and gratitude to Allah SWT for His countless blessings for us all. Praise and salutations to our beloved Prophet Muhammad PBUH, his family, companions and all those who follow his footsteps until the Last Day.
Islam places the limits of association between a man and woman who aren’t mahram that one should be mindful of. This is based on the statement of Allah SWT:
قُل لِّلْمُؤْمِنِينَ يَغُضُّوا مِنْ أَبْصَارِهِمْ وَيَحْفَظُوا فُرُوجَهُمْ ۚ ذَٰلِكَ أَزْكَىٰ لَهُمْ ۗ إِنَّ اللَّـهَ خَبِيرٌ بِمَا يَصْنَعُونَ ﴿٣٠﴾ وَقُل لِّلْمُؤْمِنَاتِ يَغْضُضْنَ مِنْ أَبْصَارِهِنَّ وَيَحْفَظْنَ فُرُوجَهُنَّ وَلَا يُبْدِينَ زِينَتَهُنَّ إِلَّا مَا ظَهَرَ مِنْهَا ۖ
“Tell the believing men to reduce [some] of their vision and guard their private parts. That is purer for them. Indeed, Allah is Acquainted with what they do. And tell the believing women to reduce [some] of their vision and guard their private parts and not expose their adornment except that which [necessarily] appears thereof,” 
Among the limitations that should be mindful of is a man and woman should not be alone without the accompaniment of the mahram of the man or woman. In a hadith narrated by Ibn ‘Abbas, Rasullullah PBUH said:
لاَ يَخْلُوَنَّ رَجُلٌ بِامْرَأَةٍ إِلاَّ وَمَعَهَا ذُو مَحْرَمٍ
” No person (man) should be alone with a woman except when there is a Mahram with her.” 
Imam al-Nawawi when commenting on this hadith said that when a man is together with a woman and there isn’t a third person with them, then the act is prohibited according to the ijma’ of scholars. 
Definition of mahram
Lexically, mahram means a prohibition. Ibn Manzur in his book stated that mahram are the individuals that are prohibited to be married.  This is the meaning of mahram that is presented by jurists.
According to the terminology, the jurists state that mahram means: “A person that is prohibited for us to marry and the prohibition is in the form of al-ta’bid (forever) with mubah reasons and not due to the honour and also not due to something that prevents it that may disappear.” 
In the phrase “in the form of al-ta’bid” means: it doesn’t include the female siblings of one’s wife. Likewise for the paternal and maternal aunts of the wife. The reason is their prohibition is in terms of when they are gathered (that is marrying them concurrently, whether the wife and her aunt or sister).
While the phrase “not due to the honour” refers to the wives of the Prophet PBUH. The reason for their prohibition is due to their honour. They are prohibited to be married to for the whole ummah and even to other prophets.
And the phrase “not due to something that prevents it that can disappear” is like for the majus women, or women who have denounced Islam. The reason is the prohibition is due to something that prohibits it that cannot disappear. Hence, they can be married (permissible to be married) at other times (such as when they embrace Islam).
The explanation regarding these groups of people considered as mahram is stated in Allah SWT’s statement:
حُرِّمَتْ عَلَيْكُمْ أُمَّهَاتُكُمْ وَبَنَاتُكُمْ وَأَخَوَاتُكُمْ وَعَمَّاتُكُمْ وَخَالَاتُكُمْ وَبَنَاتُ الْأَخِ وَبَنَاتُ الْأُخْتِ وَأُمَّهَاتُكُمُ اللَّاتِي أَرْضَعْنَكُمْ وَأَخَوَاتُكُم مِّنَ الرَّضَاعَةِ وَأُمَّهَاتُ نِسَائِكُمْ وَرَبَائِبُكُمُ اللَّاتِي فِي حُجُورِكُم مِّن نِّسَائِكُمُ اللَّاتِي دَخَلْتُم بِهِنَّ فَإِن لَّمْ تَكُونُوا دَخَلْتُم بِهِنَّ فَلَا جُنَاحَ عَلَيْكُمْ وَحَلَائِلُ أَبْنَائِكُمُ الَّذِينَ مِنْ أَصْلَابِكُمْ وَأَن تَجْمَعُوا بَيْنَ الْأُخْتَيْنِ إِلَّا مَا قَدْ سَلَفَ ۗ إِنَّ اللَّهَ كَانَ غَفُورًا رَّحِيمًا
“Prohibited to you [for marriage] are your mothers, your daughters, your sisters, your father’s sisters, your mother’s sisters, your brother’s daughters, your sister’s daughters, your [milk] mothers who nursed you, your sisters through nursing, your wives’ mothers, and your step-daughters under your guardianship [born] of your wives unto whom you have gone in. But if you have not gone in unto them, there is no sin upon you. And [also prohibited are] the wives of your sons who are from your [own] loins, and that you take [in marriage] two sisters simultaneously, except for what has already occurred. Indeed, Allah is ever Forgiving and Merciful.” 
This long verse explains several manners and limitations that one should be mindful of and maintain by every believer regardless of whether it is a man or woman. Among them is to cover the awrah from getting exposed to a non-mahram. Likewise, it is impermissible to look at what has been prohibited even more so that one transgresses the limitations set by Allah SWT.
Syeikh Mustafa al-Maraghi said that men should always take care of their eyes from looking at the prohibited and if they accidentally look to immediately look away, for the wisdom of the prohibition is to stop evil matters and prevent them from committing sins and transgressions. He further stated that women are impermissible to display their adornments that they should keep hidden and it is also impermissible to expose their awrah to others that have been mentioned. 
Imam al-Nawawi said in explaining who is “your female siblings” in the above verse: “Your sisters (that you are prohibited from marrying) is every woman that is given birth by your parents or one of them.” 
Imam al-Mawardi cited the words of Imam al-Syafi’e who said: “The original matters that make a woman mahram are two parts. The first is ansab (nasab/lineage/familial ties) and the next asbab (reasons) are by marriage or nursing (breastfeeding).”
Then, Imam al-Mawardi further explained this through his words: There are two categories of mahram women:
First: The division where an individual is forever prohibited. This part is further categorized into two that is through nasab and asbab (marriage and nursing).
Second: The division who are prohibited when they are gathered (married simultaneously). 
The implication of the nasab and asbab (marriage and nursing) category are as the following:
- It is prohibited to marry her.
- Permissible to shake hands with her.
- Permissible to stay alone (together) with her.
In the book Nihayah al-Matlab  it is explained: Mahram is a person who is prohibited to be married and have intercourse. Scholars explained that marriage is an akad that permits intercourse, if the individual has a mahram relationship with another, then it is also prohibited to marry her. Likewise, it is also prohibited to have intercourse with her. Mahram may occur due to blood relationships, nursing and marriage. Among those who are prohibited to be married due to marriage are the mother, daughters, sisters, aunts and nieces. 
The rulings with a muaqqat (certain times) mahram
According to the question presented, we state that if a man married a woman, then the sisters of his wife, whether it is the younger or older sister are not the mahram of the man. This means that his older or younger sister-in-law is included in the prohibited category (to be married) in muaqqat (certain times).
In other words, they are prohibited only because of the prohibition in the statement of Allah SWT:
وَأَن تَجْمَعُوا بَيْنَ الْأُخْتَيْنِ
“(And [also prohibited are]) that you take [in marriage] two sisters simultaneously,” 
Hence, if the married wife passed away, then her sister is no longer prohibited for him to marry. This is what is considered haram muaqqat (certain times).
The same applies to the situation when a woman marries a man. Thus, all the brothers of her husband regardless of whether they are younger or older are prohibited in muaqqat (certain times) for her to marry.
Among the people who are in this category other than the brothers of a husband or sisters of a wife are the uncles of a husband or aunts of the wife, regardless of whether they are from the paternal or maternal side of the family. This is based on a hadith narrated by Abu Hurairah RA, he said, Rasullullah PBUH said:
لاَ يُجْمَعُ بَيْنَ الْمَرْأَةِ وَعَمَّتِهَا وَلاَ بَيْنَ الْمَرْأَةِ وَخَالَتِهَا
“A man may not marry a woman and her paternal aunt, or a woman and her maternal aunt.” 
To conclude, we state that basically, there isn’t such a term as temporary mahram, except that mahram is due to three factors which are nasab, nursing or musaharah that the implication from this is making them mahram forever that also means they are prohibited to be married, permissible to have physical contact and can be alone with the now mahram person.
However, there is a prohibition that occurs only at certain times (temporary) or also known as haram muaqqat in terms that it is impermissible to marry the individual in this category for only a certain duration.
The implication, when interacting with people in this category of haram muaqqat, a person should cover the awrah the same as with other non-mahram. Khalwah (being alone together) is impermissible, it is prohibited for them to have physical contact and it is permissible to marry them when the reason preventing it is no longer present.
 Surah al-Nur: 30-31
 Narrated by Muslim (1341)
 See Syarh al-Nawawi ‘ala Sahih Muslim, 9/109
 See Lisan al-Arab, 12/119
 See Kasyifah al-Saja, pg. 114
 Surah al-Nisa’: 23
 See Tafsir al-Maraghi, 18/97
 See Raudhah al-Talibin, 7/108
 See al-Hawi al-Kabir, 9/196
 See Nihayah al-Matlab, 12/222
 Surah al-Nisa’ (23)
 Narrated by al-Nasaie (3288)