Welcome to cc.
As it is written in Romans that magistrates are often the administrator of God's wrath against evil doer,. As for the numerous punishments through out the Leviticus and Deuteronomy, that were capital crimes it was as God said, " in this way you put evil away from you."
I don't see anywhere that God was ok with rape. I think that was a stoning offence.
In other words there is a huge difference in murdering someone and engaging in the administration of justice.