The Sermon on the Mount is not a set of principles to be obeyed apart from identification with Jesus Christ. The Sermon on the Mount is a statement of the life we will live when the Holy Spirit is getting his way with us.
The Japanese bombing of Pearl Harbor led to many very good things. If you follow the trail, it led to kicking Europeans out of Asia - that saved tens of millions of lives in India alone.