Project

General

Profile

Actions

Bug #6663

closed
ES

Config rules does not disable logging.

Bug #6663: Config rules does not disable logging.

Added by Erik Sørli over 2 years ago. Updated 1 day ago.

Status:
Rejected
Priority:
Normal
Assignee:
-
Target version:
-
Affected Versions:
Effort:
Difficulty:
Label:

Description

Description

Considering the following rule, containing a config rule that when matches changes the configuration of a flow does not disable logging of traffic in Suricata:

config dns $IGNORE_DNS_CLIENT any -> any any (msg: "dns traffic disable"; config: logging disable, type tx, scope tx; flowbits: set, dns_traffic_disable; sid:1; rev:1;)

Current behaviour

When testing the disable logging functionality running suricata 7.0.2, the suricata engine does not disable transaction logging of the traffic defined in the config rule. When looking through the source code, the following code snippet does not handle flow logic as well:

if (this_tx) {
SCLogDebug("tx logic here: tx_id %"PRIu64, det_ctx->tx_id);
ConfigApplyTx(p->flow, det_ctx->tx_id, config);
} else if (this_flow) {
SCLogDebug("flow logic here");
}

Expected behaviour

Later versions of suricata is supposed to allow config rules, that when matching changes the configuration for a flow, transaction, packet or other unit, disabling records of eve.json and LUA output.

Notes

The rules does match the traffic, as it does tag the flow with the flowbit defined in the config rule, however as mentioned still logs the traffic in the eve.json file.
A pcap file is also added to ease replication of the issue.


Files

temp.pcapng (11.3 MB) temp.pcapng Erik Sørli, 01/05/2024 07:35 AM

Related issues 1 (1 open0 closed)

Related to Suricata - Bug #7391: detect/config: 'scope' can't be applied to 'flow'FeedbackOISF DevActions

ES Updated by Erik Sørli over 2 years ago Actions #1

  • Description updated (diff)

PA Updated by Philippe Antoine almost 2 years ago Actions #2

  • Target version set to 8.0.0-beta1

JF Updated by Juliana Fajardini Reichow over 1 year ago Actions #3

  • Related to Bug #7391: detect/config: 'scope' can't be applied to 'flow' added

PA Updated by Philippe Antoine about 1 year ago Actions #4

Did you mean config dns $IGNORE_DNS_CLIENT any -> any any (msg: "dns traffic disable"; config: logging disable, type tx, scope flow; flowbits: set, dns_traffic_disable; sid:1; rev:1;) instead of scope tx in the rule ?

VJ Updated by Victor Julien about 1 year ago Actions #5

  • Target version changed from 8.0.0-beta1 to 8.0.0-rc1

PA Updated by Philippe Antoine 11 months ago Actions #6

  • Status changed from New to Feedback

VJ Updated by Victor Julien 11 months ago Actions #7

  • Target version changed from 8.0.0-rc1 to 9.0.0-beta1

VJ Updated by Victor Julien 1 day ago Actions #8

  • Status changed from Feedback to Rejected
  • Assignee deleted (OISF Dev)
  • Target version deleted (9.0.0-beta1)

Ticket has gone stale, closing.

Actions

Also available in: PDF Atom