/* structure to store the sids/gids/etc the detection engine
* found in this packet */
typedef struct PacketAlert_ {
- SigIntId iid; /* Internal ID, used for sorting */
+ SigIntId iid; /* Internal ID, used for sorting */
uint8_t action; /* Internal num, used for thresholding */
uint8_t flags;
const struct Signature_ *s;
for (Signature *s = de_ctx->sig_list; s != NULL; s = s->next) {
de_ctx->sig_array[s->iid] = s;
- SCLogDebug("Signature %" PRIu32 ", internal id %" PRIu32 ", ptrs %p %p ", s->id, s->iid, s, de_ctx->sig_array[s->iid]);
+ SCLogDebug("Signature %" PRIu32 ", internal id %" PRIu32 ", ptrs %p %p ", s->id, s->iid, s,
+ de_ctx->sig_array[s->iid]);
if (s->type == SIG_TYPE_PDONLY) {
SCLogDebug("Signature %"PRIu32" is considered \"PD only\"", s->id);
if (cd->flags & DETECT_CONTENT_NOCASE) {
if (chop) {
- MpmAddPatternCI(mpm_ctx,
- cd->content + cd->fp_chop_offset, cd->fp_chop_len,
- pat_offset, pat_depth,
- cd->id, s->iid, flags|MPM_PATTERN_CTX_OWNS_ID);
+ MpmAddPatternCI(mpm_ctx, cd->content + cd->fp_chop_offset, cd->fp_chop_len, pat_offset,
+ pat_depth, cd->id, s->iid, flags | MPM_PATTERN_CTX_OWNS_ID);
} else {
- MpmAddPatternCI(mpm_ctx,
- cd->content, cd->content_len,
- pat_offset, pat_depth,
- cd->id, s->iid, flags|MPM_PATTERN_CTX_OWNS_ID);
+ MpmAddPatternCI(mpm_ctx, cd->content, cd->content_len, pat_offset, pat_depth, cd->id,
+ s->iid, flags | MPM_PATTERN_CTX_OWNS_ID);
}
} else {
if (chop) {
- MpmAddPatternCS(mpm_ctx,
- cd->content + cd->fp_chop_offset, cd->fp_chop_len,
- pat_offset, pat_depth,
- cd->id, s->iid, flags|MPM_PATTERN_CTX_OWNS_ID);
+ MpmAddPatternCS(mpm_ctx, cd->content + cd->fp_chop_offset, cd->fp_chop_len, pat_offset,
+ pat_depth, cd->id, s->iid, flags | MPM_PATTERN_CTX_OWNS_ID);
} else {
- MpmAddPatternCS(mpm_ctx,
- cd->content, cd->content_len,
- pat_offset, pat_depth,
- cd->id, s->iid, flags|MPM_PATTERN_CTX_OWNS_ID);
+ MpmAddPatternCS(mpm_ctx, cd->content, cd->content_len, pat_offset, pat_depth, cd->id,
+ s->iid, flags | MPM_PATTERN_CTX_OWNS_ID);
}
}
}
for (u = 0; u < (sgh->init->sig_size * 8); u++) {
if (sgh->init->sig_array[u / 8] & (1 << (u % 8))) {
SCLogDebug("%" PRIu32, u);
- printf("s->iid %"PRIu32" ", u);
+ printf("s->iid %" PRIu32 " ", u);
}
}
/* threat detect rules will be inspected */
}
- SCLogDebug("%p/%"PRIu64" inspecting: sid %u (%u), flags %08x",
- tx.tx_ptr, tx.tx_id, s->id, s->iid, inspect_flags ? *inspect_flags : 0);
+ SCLogDebug("%p/%" PRIu64 " inspecting: sid %u (%u), flags %08x", tx.tx_ptr, tx.tx_id,
+ s->id, s->iid, inspect_flags ? *inspect_flags : 0);
if (inspect_flags) {
if (*inspect_flags & DE_STATE_FLAG_FULL_INSPECT) {
alert_flags |= PACKET_ALERT_FLAG_APPLY_ACTION_TO_PACKET;
}
- SCLogDebug("%p/%"PRIu64" sig %u (%u) matched", tx.tx_ptr, tx.tx_id, s->id, s->iid);
+ SCLogDebug(
+ "%p/%" PRIu64 " sig %u (%u) matched", tx.tx_ptr, tx.tx_id, s->id, s->iid);
AlertQueueAppend(det_ctx, s, p, tx.tx_id, alert_flags);
if ((s->flags & SIG_FLAG_FIREWALL) && (s->action & ACTION_ACCEPT)) {