detect: fix overflow for files protocol

CID 1640392

Would happen only if we reached 15 protocols handling files
pull/12965/head
Philippe Antoine 10 months ago committed by Victor Julien
parent 6afad1af51
commit 58a8559440

@ -119,8 +119,10 @@ void DetectFileRegisterProto(
al_protocols[i].direction = direction;
al_protocols[i].to_client_progress = to_client_progress;
al_protocols[i].to_server_progress = to_server_progress;
if (i + 1 < ALPROTO_WITHFILES_MAX) {
al_protocols[i + 1].alproto = ALPROTO_UNKNOWN;
}
}
void DetectFileRegisterFileProtocols(DetectFileHandlerTableElmt *reg)
{

Loading…
Cancel
Save