Sunan an-Nasa'i, Book 4, Hadith 47 (In-Book)

Abu Hurairah said: "The Messenger of Allah said: 'When any one of you gets up after (sleeping) at night, let him not put his hand into the vessel until he has poured water on it two or three times, for none of you knows where his hand spent the night.'"

أَخْبَرَنَا عِمْرَانُ بْنُ يَزِيدَ، قَالَ حَدَّثَنَا إِسْمَاعِيلُ بْنُ عَبْدِ اللَّهِ، قَالَ حَدَّثَنَا الأَوْزَاعِيُّ، قَالَ حَدَّثَنَا مُحَمَّدُ بْنُ مُسْلِمٍ الزُّهْرِيُّ، قَالَ حَدَّثَنِي سَعِيدُ بْنُ الْمُسَيَّبِ، قَالَ حَدَّثَنِي أَبُو هُرَيْرَةَ، قَالَ قَالَ رَسُولُ اللَّهِ صلى الله عليه وسلم ‏ "‏ إِذَا قَامَ أَحَدُكُمْ مِنَ اللَّيْلِ فَلاَ يُدْخِلْ يَدَهُ فِي الإِنَاءِ حَتَّى يُفْرِغَ عَلَيْهَا مَرَّتَيْنِ أَوْ ثَلاَثًا فَإِنَّ أَحَدَكُمْ لاَ يَدْرِي أَيْنَ بَاتَتْ يَدُهُ ‏" ‏ ‏.‏

sunnah.com