Hadithcore
Hadith #2115790

Anas (RAA) narrated that The Messenger of Allah (ﷺ) entered Makkah with a helmet on his head, and when he took it off, a man came to him and said, ‘lbn Khattal is hanging on to the curtains of the Ka'bah.’ The Prophet (ﷺ) thereupon said, “Kill him.” Agreed upon.

وَعَنْ أَنَسٍ ‏- رضى الله عنه ‏- { أَنَّ اَلنَّبِيَّ ‏- صلى الله عليه وسلم ‏-دَخَلَ مَكَّةَ وَعَلَى رَأْسِهِ اَلْمِغْفَرُ, فَلَمَّا نَزَعَهُ جَاءَهُ رَجُلٌ, فَقَالَ: ابْنُ خَطَلٍ مُتَعَلِّقٌ بِأَسْتَارِ اَلْكَعْبَةِ, فَقَالَ:

اُقْتُلُوهُ

} مُتَّفَقٌ عَلَيْهِ [1]‏ .‏

References2 variants
Sunnah.com reference
Book 11, Hadith 26
Arabic/English book reference
Book 11, Hadith 1322