[(Lev. 14:2:) THIS SHALL BE THE LAW OF THE LEPER.] Our Rabbis said: Plagues come upon a person only on account of the evil speech that goes out of his mouth. And the Holy Spirit cries out (Eccl. 5:5): "Do not let your mouth bring guilt upon your flesh" — to scourge your body; "[and do not say before the angel that it was an error]" (ibid.) — and do not say before the angel appointed over you, "It was unintentionally that I brought forth the word from my mouth," for every word that goes out of your mouth is written down in a book, whether good or evil, whether unintentional or deliberate. And how do we know that this is so? As it is said (Mal. 3:16): "Then those who feared the LORD spoke with one another, [and the LORD took note and heard, and a book of remembrance was written before Him, etc.]." And likewise, with the measure of punishment, David said (Ps. 139:2): "You know my sitting down and my rising up, etc." And Job said (Job 13:27): "You trace out the roots of my feet." "Why should God be angry at your voice and destroy the work of your hands?" (Eccl. 5:5) — these are the hands and the body, which are afflicted with plagues.
Why Leprosy Strikes - Evil Speech and the Book of Words
Midrash Tanchuma Buber, Metzora 2:1
[זאת תהיה תורת המצורע]. אמרו רבותינו אין הנגעים באדם אלא על לשון הרע שיוצא מפיו, ורוח הקודש צווחת, אל תתן את פיך לחטיא את בשרך (קהלת ה ה), להלקות את גופך, [ואל תאמר לפני המלאך כי שגגה היא] (שם שם), ואל תאמר לפני המלאך הממונה עליך, בשגגה הוצאתי מפי את הדבור, שכל דבור שיצא מפיך בספר נכתבין, בין טוטב ובין רע בשוגג ובין במזיד, ומנין שהוא כן, שנאמר אז נדברו יראי ה' איש אל רעהו [ויקשב ה' וישמע ויכתב ספר זכרון לפניו וגו'] (מלאכי ג טז), וכן במדת פורענות אמר דוד אתה ידעת שבתי וקומי וגו' (תהלים קלט ב), ואמר איוב על שרשי רגלי תתחקה (איוב יג כז), למה יקצוף האלהים על קולך וחבל את מעשה ידיך (קהלת שם), אלו הידים והגוף שהן לוקין בנגעים.