Salama bin Akwa reported,

We went on a campaign with Abu Bakr against Hawazin during the time of the Messenger of Allah ﷺ. He awarded me as a special prize a young woman from the tribe of Banu Fazara, one of the most beautiful of the Arabs, who wore a coarse outer garment. I did not so much as lift her garment until I reached Medina.The Prophet ﷺ met me in the market and said, "By your father, give her to me as a gift."So I gave her to him, and he sent her off and used her to ransom Muslim captives who were being held in Mecca.

Ibn Majah 2846

Sahih

حدثنا علي بن محمد ومحمد بن إسمعيل قالا حدثنا وكيع عن عكرمة بن عمار

عن إياس بن سلمة بن الأكوع عن أبيه قال

غزونا مع أبي بكر هوازن على عهد رسول الله ﷺ فنفلني جارية من بني فزارة من أجمل العرب عليها قشع لها فما كشفت لها عن ثوب حتى أتيت المدينة فلقيني النبي ﷺ في السوق فقال لله أبوك هبها لي فوهبتها له فبعث بها ففادى بها أسارى من أسارى المسلمين كانوا بمكة

ابن ماجه 2846صحيح
Contents
Reference
Commentary
Ayat
Collection
Sunan Ibn Majah
Book
Jihad
Chapter
Ransoming captives
Numbering
Darussalam 2846
Ibn Majah 2846