Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
bukhari:6949al-Layth > Nāfiʿ > Ṣafiyyah Āb.ah Abū ʿUbayd

"A governmental male-slave tried to seduce a slave-girl from the Khumus of the war booty till he deflowered her by force against her will; therefore 'Umar flogged him according to the law, and exiled him, but he did not flog the female slave because the male-slave had committed illegal sexual intercourse by force, against her will." Az-Zuhri said regarding a virgin slave-girl raped by a free man: The judge has to fine the adulterer as much money as is equal to the price of the female slave and the adulterer has to be flogged (according to the Islamic Law); but if the slave woman is a matron, then, according to the verdict of the Imam, the adulterer is not fined but he has to receive the legal punishment (according to the Islamic Law).  

البخاري:٦٩٤٩وَقَالَ اللَّيْثُ حَدَّثَنِي نَافِعٌ أَنَّ صَفِيَّةَ ابْنَةَ أَبِي عُبَيْدٍ أَخْبَرَتْهُ

أَنَّ عَبْدًا مِنْ رَقِيقِ الإِمَارَةِ وَقَعَ عَلَى وَلِيدَةٍ مِنَ الْخُمُسِ فَاسْتَكْرَهَهَا حَتَّى افْتَضَّهَا فَجَلَدَهُ عُمَرُ الْحَدَّ وَنَفَاهُ وَلَمْ يَجْلِدِ الْوَلِيدَةَ مِنْ أَجْلِ أَنَّهُ اسْتَكْرَهَهَا قَالَ الزُّهْرِيُّ فِي الأَمَةِ الْبِكْرِ يَفْتَرِعُهَا الْحُرُّ يُقِيمُ ذَلِكَ الْحَكَمُ مِنَ الأَمَةِ الْعَذْرَاءِ بِقَدْرِ قِيمَتِهَا وَيُجْلَدُ وَلَيْسَ فِي الأَمَةِ الثَّيِّبِ فِي قَضَاءِ الأَئِمَّةِ غُرْمٌ وَلَكِنْ عَلَيْهِ الْحَدُّ