Legality is itself location-sensitive
It's legal according to US law for the US to use StingRay in non-US places; doesn't mean it's legal according to the law of those places. What it means is that the US government won't act to prevent itself using such tech outside the US.
Remember, according to US law, US law applies over the entire universe. Really.