Obligatory link to Isaac Asimov's Three Laws of Robotics:
This trick also works on humans: you can often circumvent their "protect humans" programming by simply messing with their classification system to label a human as "terrorist", "infidel", or even "unemployed".