A smith called Poverty is granted 3 wishes by God and St. Peter. He wishes for 3 of his property to become a trap for anyone who uses them because he has suffered from dishonest people before. The Devil comes and offers him money for 20 years, after which he will come for him. But when his time comes, he traps all the devils through his magic objects and beats them up. When he dies, he is refused in Heaven because he foolishly did not wish for a place there, and he is refused a place in Hell because the devils are scared of him. So he is stuck on earth.