Project

General

Profile

Bug #452 » 0001-bug-452-fix-detection-bug-for-sigs-that-don-t-have-a.patch

Anoop Saldanha, 04/20/2012 12:22 AM

View differences:

src/detect.c
// continue;
//}
if (det_ctx->smsg_pmq[pmq_idx].pattern_id_bitarray != NULL) {
//if (det_ctx->smsg_pmq[pmq_idx].pattern_id_bitarray != NULL) {
/* filter out sigs that want pattern matches, but
* have no matches */
if (!(det_ctx->smsg_pmq[pmq_idx].pattern_id_bitarray[(s->mpm_pattern_id_div_8)] & s->mpm_pattern_id_mod_8) &&
(s->flags & SIG_FLAG_MPM_STREAM) && !(s->flags & SIG_FLAG_MPM_STREAM_NEG)) {
if ((s->flags & SIG_FLAG_MPM_STREAM) && !(s->flags & SIG_FLAG_MPM_STREAM_NEG) &&
!(det_ctx->smsg_pmq[pmq_idx].pattern_id_bitarray[(s->mpm_pattern_id_div_8)] & s->mpm_pattern_id_mod_8)) {
SCLogDebug("no match in this smsg");
continue;
}
......
break;
}
}
//}
}
} /* if (smsg != NULL) */
(3-3/5)