"And the priest shall look" (Leviticus 14:3) — this is Jeremiah, of whom it is said, "of the priests who were in Anathoth" (Jeremiah 1:1). "And behold, the plague of leprosy is healed" — that he exiled them to Babylon. After they had been exiled, Nebuchadnezzar said to them that they should bow down to the image, as it is said, "and whoever does not fall down and worship" (Daniel 3:6). They said to him, "We do not serve your god" (Daniel 3:18). What did he do? "And the priest shall take cedar wood and crimson thread and hyssop" (compare Numbers 19:6) — these are Hananiah, Mishael, and Azariah; "and he shall cast them into the midst of the burning of the heifer" — that he cast them into the fire, as it is said, "and they were thrown into the midst of the burning fiery furnace" (Daniel 3:21). The Holy One, blessed be He, said to them: In this world, on account of your iniquities, you were being afflicted and purified, and again afflicted; but in the time to come, it is I who will purify you from above, as it is said, "And I will sprinkle clean water upon you, and you shall be clean; from all your uncleannesses and from all your idols I will purify you" (Ezekiel 36:25).
The Priest Jeremiah and the Three Youths in Nebuchadnezzar's Furnace
Midrash Tanchuma Buber, Metzora 9:2
וראה הכהן. זה ירמיה, שנאמר מן הכהנים אשר בענתות וגו' (ירמיה א א). והנה נרפא נגע הצרעת. שהגלה אותן לבבל, משגלו א"ל נבוכדנצר שיכרעו לצלם, שנאמר ומן די לא יפול ויסגוד (דניאל ג ו), א"ל לאלהך (לית אנחנא) [לא איתנא] פלחין וגו' (שם שם יח), מה עשה. ולקח הכהן עץ ארז ושני תולעת ואזוב, זה חנניה מישאל ועזריה, והשליך אל תוך שרפת הפרה, שהשליכן לאש, שנאמר ורמיו לגו אתון נורא וגו' (שם שם כא), א"ל הקב"ה בעולם הזה מפני העונות הייתם מתיסרין ומטהרין וחוזרין ומתיסרין, לעתיד לבא אני הוא שמטהר אתכם מלמעלן, שנאמר וזרקתי עליכם מים טהורים וטהרתם מכל טומאותיכם ומכל גלוליכם אטהר אתכם (יחזקאל לו כה).