Sahih Muslim, Book 46, Hadith 45 (Muslim 6693)

Ubayy b. Ka'b reported that Allah's Messenger (ﷺ) said:

The young man whom Khadir killed was a non-believer by his very nature and had he survived he would have involved his parents in defiance and unbelief.