Suicide: Getting killed and killing oneself
It is well known that suicide is forbidden, but what about a woman who kills herself in order to save her honor?
Suicide, as you say, is strictly forbidden. No matter how miserable one is, one must to kill oneself for any reason, because such an action indicates despair of receiving Gods grace. God says in the Quran:
"Only those who are non-believers despair of Gods mercy."
However, the case you ask about is not that of someone who wants to kill herself, but she does so in defense of her honor. No one can judge such a situation. It is only God who determines judgment.
Having said that, I add that it is much better for a Muslim woman who finds herself in such a situation to resist her attacker with all the means at her disposal. If he kills her during her struggle to prevent him reaching her, then she is a martyr and she secures her place in heaven. Anyone who dies while defending his/her life, honor, family, or property earns the reward of a martyr.
Suicide: Islamic view on suicide?
Should a woman commit suicide rather than submit to a rapist? Is there any situation which permits suicide?
Islam views suicide very very seriously, because it is an affront to Allah, the giver of life. A person who commits suicide actually puts himself on the same level as Allah, saying to Him, in effect: "You have given me life and I take it way." This is totally unacceptable. In a Qudsi Hadith, Allah is quoted by His messenger as saying: "My servant has affronted me with regard to his life and I, therefore, forbid him entry into heaven."
Committing suicide is a grave sin. Many scholars view a person who has committed suicide as someone who has turned his back on Islam altogether. However, a man committed suicide at the time of the Prophet. The Prophet did not offer the prayer for the deceased person (i.e. janazah prayer for him), but told his companions to offer it. When they did, they obviously prayed Allah to forgive him. Therefore, it is permissible to mention a person who has committed suicide in our supplication and pray Allah to forgive him.
In some Muslim societies, a common notion is held that a woman should sacrifice her life rather than submit to a rapist. The Islamic ruling is not so. A woman is not required to sacrifice her life for that. If she is forced, either by brute force or by other means, to submit to rape, she is not punished for that. However, it is very difficult to regulate how a woman may behave when faced with such an extreme situation. It is Allah who judges everyone of us on the basis of His knowledge of our intentions and the factors that influence our actions.
Perhaps the only situation which may be exempted from this strict prohibition is in a case of war when a group of Muslims are besieged by the enemy and threatened with certain death. If one of them sacrifices his life to give the rest a chance to survive, then it is a case of sacrificing one or two lives in order to save many others.
Sunnah is something that has been recommended to us by the Prophet. Voluntary prayers are sunnah, some of which have been given more emphasis than others, and these are called "moakkedah". In prayer, certain voluntary prayers were observed by the Prophet, and these are termed as moakkedah. Others were done only occasionally by the Prophet and these are termed 'ghair moakkedah."