Sahih Muslim , Book 4, Hadith 1125 (USC-MSA) ⓘ
Shu'ba reported: I asked Qatada about spitting, in the mosque. He said: I heard Anas b. Malik say: I heard the Messenger of Allah say: Spitting in the mosque is a sin, and its expiation is that it should be buried.
حَدَّثَنَا يَحْيَى بْنُ حَبِيبٍ الْحَارِثِيُّ، حَدَّثَنَا خَالِدٌ، - يَعْنِي ابْنَ الْحَارِثِ - حَدَّثَنَا شُعْبَةُ، قَالَ سَأَلْتُ قَتَادَةَ عَنِ التَّفْلِ، فِي الْمَسْجِدِ فَقَالَ سَمِعْتُ أَنَسَ بْنَ مَالِكٍ، يَقُولُ سَمِعْتُ رَسُولَ اللَّهِ صلى الله عليه وسلم يَقُولُ " التَّفْلُ فِي الْمَسْجِدِ خَطِيئَةٌ وَكَفَّارَتُهَا دَفْنُهَا " .
also referenced under: Book 5, Hadith 70 (In-Book) & Hadith 552 (Reference)