It was narrated from Abu Ubaidah that his father said: "We were with the Messenger of Allah on the night of Arafat which is before Arafat, when he heard a snake. The Messenger of Allah said: “Kill it.' It went into a crack in a rock, and we put a stick in and broke part of the hole, then we took some palm tree leave and set them ablaze in the hole. The Messenger of Allah: “Allah protected it from your evil and protected you from its evil””"
Sahih LighairihiSahihSahihBook 24 · Hadith 267