It's still arguably better than dictatorships, where your citizens don't matter either, as long as you have a good police system.
We act surprised when we notice such things but we shouldn't be, it is a mistake to apply the same standards that we, as the lucky citizens of "free countries" enjoy, to any other system of power.
From a less cynical point of view, as an Israeli, I am not happy at all to see this kind of export products from my country. It is in great part because of the conflict. Te SIGINT units are huge and among the people who graduate from the army with this kind of knowledge you will certainly find many who will turn a blind eye to ethics for a huge paycheck. Not to mention that the research itself that the defense apparatus needs attracts capitals from other countries that will buy some of it and use it for unorthodox means. I wish we exported less of these things, especially to autocratic countries. I agree it's horrible.