I heard the Messenger of Allah ﷺ say during the Farewell Pilgrimage, "No offender commits a crime except against himself. A father shall not be held accountable for his child's offense, nor a child for his father's."
حدثنا أبو بكر بن أبي شيبة حدثنا أبو الأحوص عن شبيب بن غرقدة
سمعت رسول الله ﷺ يقول في حجة الوداع ألا لا يجني جان إلا على نفسه لا يجني والد على ولده ولا مولود على والده