Skip to main content
1 of 5
Martin Ender
  • 198.3k
  • 14
  • 181
  • 311

Should asking for malicious code be on topic?

We're occasionally getting questions which ask people to write harmful code. This used to be big when code trolling was a thing, but it's not limited to that. Every now and then there are challenges or which ask participants to write malicious code (which may or may not be disguised as harmless code). And in principle, there's nothing stopping someone from posting a to wreck the PC the submission is run on.

The most recent example included explicit instructions like "Do Harm. Be Evil."

I tend to downvote these, because I think it's generally not a good idea to produce this kind of code here. Furthermore, no one can even really test the answers, because you'd have to properly sandbox the environment which can be either near impossible or just way too much effort.

But should these actually be on topic to begin with? Do we want questions like that? And if not, could we get a new close vote reason?

Martin Ender
  • 198.3k
  • 14
  • 181
  • 311