Is it allowed to work for a tech company that develops social media data gathering software to be used by the government to monitor its people?
If you know that your work will be used to harm people by any way or by any one, it will then not allowed for you to do such work. Monitoring has many types and aims which includes harming people as well as preventing crime. Preventing crime is allowed but harming people is not allowed.
Wassalam.
Wassalam.