Cooperation among unrelated individuals is pervasive in human societies, while natural selection favors the survival of the fittest. The theoretical explanation for this puzzle is a challenge across disciplines. Among other mechanisms that can promote cooperation is costly punishment, in which altruistic individuals privately bear the cost to punish defection. But it decreases the welfare of both the punisher and the punished, and defectors are hard and costly to be caught in many cases. Moreover, punishment may trigger a chain of retaliation between the punisher and the punished and induce second-order free riding - those who never punish will be better off than punishers. In this article we aim to get rid of these drawbacks by refining th...