See
https://incompleteness.me/blog/2005/09/28/writing-malicious-code-in-java/