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.
muslim:827eMuḥammad b. al-Muthanná > Muḥammad b. Jaʿfar > Shuʿbah > ʿAbd al-Malik b. ʿUmayr > Qazaʿah > Abū Saʿīd al-Khudrī

I heard Abu Sa'id al-Khudri (Allah be pleased with him) saying: I heard four things from Messenger of Allah ﷺ which impressed me and captivated me (and one out of these is this), that he forbade a woman to undertake journey extending over two days but with her husband, or with a Mahram; and he then narrated the rest of the hadith.  

مسلم:٨٢٧eوَحَدَّثَنَا مُحَمَّدُ بْنُ الْمُثَنَّى حَدَّثَنَا مُحَمَّدُ بْنُ جَعْفَرٍ حَدَّثَنَا شُعْبَةُ عَنْ عَبْدِ الْمَلِكِ بْنِ عُمَيْرٍ قَالَ سَمِعْتُ قَزَعَةَ قَالَ سَمِعْتُ أَبَا سَعِيدٍ الْخُدْرِيَّ قَالَ

سَمِعْتُ مِنْ رَسُولِ اللَّهِ ﷺ أَرْبَعًا فَأَعْجَبْنَنِي وَآنَقْنَنِي نَهَى أَنْ تُسَافِرَ الْمَرْأَةُ مَسِيرَةَ يَوْمَيْنِ إِلاَّ وَمَعَهَا زَوْجُهَا أَوْ ذُو مَحْرَمٍ وَاقْتَصَّ بَاقِيَ الْحَدِيثِ