Michael Harris has written some blog posts on ethical aspects of mathematics.
There is also an opinion piece by Tom Leinster about ethical questions arising for mathematicians working for intelligence agencies. More on mathematics and mass surveillance can be found here.