|Think about Loose Coupling|
read directly the code to find what it does:
Why are you wasting our time with a code submission if you aren't going to describe it? I don't know what it is and I don't know why should I care! I'm not going to waste my time figuring it out, and I'm sure as hell not going to run the code on my machine when it seems like its some sort of DDoser.I sincerely apologize: had I known the consequences of this post of mine I would have never ever submitted it.
I thought that the code would have been both (fundamentally) self explanatory and also kinda funny because of the expressive names given to variables and subs.
However you're right: it's some sort of DoSer, but for quite a relaxed meaning of the term. In fact it does NOT do DoS, "only" it puts the machine under heavy load iff a condition is realized, precisely that a certain user is logged.
As was implicitly implied, it would be natural to consider this "project" unethical rather than ethical as stated... however let me explain: this particular user is an unbearable arrogant idiot.
I could exhibit tons of anecdotes to support the claim above, and I'm sure that in the end you would fundamentally agree with me. However I fear that this would be OT here.
For those who want to know, this program sits down sleeping most of the time checking who is locked on the machine it's running on. If all the users are "bad", then it starts an harassing phase by forking 127 copies of itself each of which will basically just do rand() all of the time. The original copy continues to check who is logged and if the harassing condition does not hold any more (e.g. a "normal" user logs in) then it kills all the harassing copies and turns back to the "waiting in the shadow" phase.