projects
/
erlbot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
488b8e0
)
Fix DoS where any IRC user can crash the bot.
author
Matt Mullins
<mmullins@mmlx.us>
Tue, 13 Dec 2011 06:33:13 +0000
(22:33 -0800)
committer
Matt Mullins
<mmullins@mmlx.us>
Tue, 13 Dec 2011 06:33:13 +0000
(22:33 -0800)
irc/irc_command.erl
patch
|
blob
|
history
diff --git
a/irc/irc_command.erl
b/irc/irc_command.erl
index
1b39b19
..
87463eb
100644
(file)
--- a/
irc/irc_command.erl
+++ b/
irc/irc_command.erl
@@
-16,8
+16,6
@@
do_privmsg_command(Text, From) ->
middles = [From],
trailing = element(Index, Choices)},
irc_conn:send_command(self(), NewCommand);
- "crash" ->
- throw(crash);
"random" ++ Choices ->
Response = random_choice(Choices),
NewCommand = #irc_command{command = "PRIVMSG",