The Ramak (Rabbi Moshe Cordovero) is buried in the old cemetery of Safed, near the grave of the Arizal. According to tradition, when the Arizal arrived in Safed, he was present at the Ramak’s funeral. At that moment, the Arizal delivered a eulogy, quoting the verse, "And if a man has committed a sin deserving of death, and he is put to death, you must hang him on a tree." The Arizal explained the verse with a tone of amazement: "And if a man has committed a sin?"—these words express astonishment! How so? Usually, the title "man" in the Torah refers to a righteous person, as in "Noah was a righteous man, earnest in his generations" and "Can we find such a man, in whom is the spirit of God?" as well as, "Moses, the man of God."
Therefore, how could it be that "a man has committed a sin"? Our teacher Moshe who lies here before us is an exalted tzaddik. He is the "Moses of the generation," and thus it is impossible for him to have sinned. Yet, "he is put to death," despite being a righteous man, free from any sin, here he lies before us, dead. How can we understand the reason for his death?
The answer is, "you must hang him [blame the cause] on a tree." The cause of his death is linked to the sin of the Tree of Knowledge. In his own merit, he is a tzaddik and is not deserving of death at all. However, due to the sin of the Tree of Knowledge, the decree of death was imposed on all of humanity. As the sages say, "He died because of the bite of the serpent" (i.e., the consequence of the primordial serpent in the Garden of Eden).
4. Genesis 6:9.
5. Ibid. 41:38.
6. Deuteronomy 33:1.