The Companions of the Prophet (ﷺ) told us that they were travelling with the Prophet (ﷺ). A man of them slept, and one of them went to the rope which he had with him. He took it, by which he was frightened. The Prophet (ﷺ) said: It is not lawful for a Muslim that he frightens a Muslim.
Sunan Abi Dawud Book 43, Hadith 232