Sunan Ibn Majah, Book 21, Hadith 59 (Ibn Majah 2675)

It was narrated from Abu Hurairah that the Allah's Messenger (ﷺ) said:

“The injuries caused by the beast are without liability, and wells are without liability, and mines are without liability.”