Sahih Bukhari · Hadith 6907
Punishment of Disbelievers at War with Allah and His Apostle - كتاب المحاربين من أهل الكفر والردة
حدثنا آدم، حدثنا شعبة، حدثنا محمد بن زياد، قال سمعت أبا هريرة، قال النبي صلى الله عليه وسلم " الولد للفراش، وللعاهر الحجر ".
Narrated Abu Huraira: The Prophet said, "The boy is for (the owner of) the bed and the stone is for the person who commits illegal sexual intercourse.'
Gradings are classical jarḥ-wa-taʿdīl, name-matched to a rijāl index (not individually re-verified).