Browse Source

irc: fix read out of bounds in case of malformed AUTHENTICATE message (issue #1679)

master
Sébastien Helleu 2 years ago
parent
commit
79d50837c9
  1. 2
      src/plugins/irc/irc-protocol.c

2
src/plugins/irc/irc-protocol.c

@ -408,6 +408,8 @@ IRC_PROTOCOL_CALLBACK(authenticate) @@ -408,6 +408,8 @@ IRC_PROTOCOL_CALLBACK(authenticate)
return WEECHAT_RC_OK;
arg_data = (argv[0][0] == ':') ? 2 : 1;
if (arg_data >= argc)
return WEECHAT_RC_OK;
ptr_data = (argv_eol[arg_data][0] == ':') ?
argv_eol[arg_data] + 1 : argv_eol[arg_data];

Loading…
Cancel
Save