Samyukta Āgama (2) 21
Bhikkhu Saṃyutta A forest spirit admonishes a monk
The simile of the ulcer
Thus have I heard, once, the Buddha was staying at Sāvatthī in the Jeta Grove, the Anāthapiṇḍika Park.
At that time a certain monk put on his robes, took his begging-bowl and entered the town to beg for food. When he had eaten and returned, he washed his feet, took up his sitting mat and went into the Forest of Regained Sight. Having spread out grass beneath a tree he sat down to meditate. But evil thoughts arose in his mind, desire for the five sensual pleasures. The spirit of the Forest of Regained Sight knew the monks thoughts and saw that they were impure. “In this forest one should not have evil inclinations,” the spirit thought, “I will wake him up.” And he said: “Monk, monk, why do you have an ulcer?” The monk answered: “I will bandage it.” The forest spirit spoke again: “Your ulcer is as big as a pot. How will you bandage it?” The monk answered: “I will bandage my ulcer with right thought.” The forest spirit praised him, saying: “Very good, very good! This monk knows well how to bandage his ulcer, how truly to bandage his ulcer.” The Buddha, with his divine hearing, heard the exchange between the forest spirit and the monk.
At that time the World-honored One spoke this verse:
“Worldly desires / are born of evil thoughts. Once an ulcer has grown / it nurtures swarms of flies; desire is this ulcer / thought and reflection are the flies.
Because of greed, arrogance / pierces our heart. Because of greed for fame and profit / we are caught in doubts,
do not know how to escape / One whose mind is trained in concentration trained in the supernormal powers / does not grow ulcers but in peace and stability beholds the Buddha / and attains Nirvāṇa.”
When the Buddha had finished speaking, the monks, having listened to what he had said, were happy and remembered it well.