Fix global buffer over-read in POP3 analyzer

Report and patch by Justin Azoff
This commit is contained in:
Jon Siwek 2020-05-06 10:00:58 -07:00
parent b749dda520
commit 280bf56786

View file

@ -864,7 +864,7 @@ int POP3_Analyzer::ParseCmd(std::string cmd)
if ( cmd.size() == 0 )
return -1;
for ( int code = POP3_CMD_OK; code <= POP3_CMD_END; ++code )
for ( int code = POP3_CMD_OK; code < POP3_CMD_END; ++code )
{
char c = cmd.c_str()[0];
if ( c == '+' || c == '-' )