Unfortunately, many countries have already signed bad contracts that give a disproportionate share of the resources’ value to private foreign companies. But there is a simple answer: renegotiate; if that is impossible, impose a windfall-profit tax.