Sahih Muslim Book 23, Hadith Number 4991.

Chapter : Command pertaining to the covering of vessels, and tightening (the mouths) of waterskins, etc.

Jabir reported Allah’s Messenger (may peace be upon him) as saying: Cover vessels, water-skins, close the doors and extinguish the lamps, for the Satan does not loosen the water-skin, does not open the door and does not uncover the vessels. And if one amongst you fails to find (something) to cover it well, he should cover it by placing (a piece of) wood across it. Qutaiba did not mention the closing of the doors in the hadith transmitted by him.