… is from page 293 of the 1992 collection of some of William Graham Sumner’s best essays, On Liberty, Society, and Politics (Roger C. Bannister, ed.); specifically, this quotation is from Sumner’s brilliant 1898 essay “The Conquest of the United States by Spain“:
The time when a maxim or principle is worth something is when you are tempted to violate it.