حَدَّثَنَا مُحَمَّدُ بْنُ رُمْحٍ الْمِصْرِيُّ، أَنْبَأَنَا اللَّيْثُ بْنُ سَعْدٍ، عَنْ أَبِي الزُّبَيْرِ، عَنْ جَابِرِ بْنِ عَبْدِ اللَّهِ، عَنْ رَسُولِ اللَّهِ ـ صلى الله عليه وسلم ـ أَنَّهُ قَالَ ‏"‏ إِذَا رَأَى أَحَدُكُمُ الرُّؤْيَا يَكْرَهُهَا فَلْيَبْصُقْ عَنْ يَسَارِهِ ثَلاَثًا وَلْيَسْتَعِذْ بِاللَّهِ مِنَ الشَّيْطَانِ ثَلاَثًا وَلْيَتَحَوَّلْ عَنْ جَنْبِهِ الَّذِي كَانَ عَلَيْهِ ‏"‏ ‏.‏

It wasnarrated from Jabir bin ‘Abdullah that the Messenger of Allah(PBUH)said: “If anyone of you sees a dream that he dislikes, let himspitdryly to his left three times and seek refuge with Allah fromSatanthree times, and turn over onto his other side.” Translation Not Available

Book Ref: Sunan Ibn Majah Book 35 Hadith 3908
Web Ref:  Sunan Ibn Majah Vol 5 Book 35 Hadith 3908