Um the military doesn't give a person power to harm others. Anyone with Authority is expected to treat all subordinates decently. and in the US at least we have no power over civilians unless the President activates the Army or Gaurd for a civil situation like natural disaster and riots.
I really respect our military and its foundational principals and if one checks any improper things done by people inour uniform was done by people vbiolating those principals. "Our" being the US military since this is a world wide organization.
I would guess that this is the situation in all countries where the military takes over. It is the courage of the individual soldier to say no to improper orders that keeps the military in check.
As Mark Twain once quipped, history may not repeat itself, but it does rhyme.