]> git.ipfire.org Git - thirdparty/suricata.git/log
thirdparty/suricata.git
3 years agodetect: track prefilter by progress, not engine
Victor Julien [Tue, 14 Sep 2021 08:35:18 +0000 (10:35 +0200)] 
detect: track prefilter by progress, not engine

Fix FNs in case of too many prefilter engines. A transaction was tracking
which engines have run using a u64 bit array. The engines 'local_id' was
used to set and check this bit. However the bit checking code didn't
handle int types correctly, leading to an incorrect left shift result of
a u32 to a u64 bit value.

This commit addresses that by fixing the int handling, but also by
changing how the engines are tracked.

To avoid wasting prefilter engine tracking bit space, track what
ran by the progress they are registered at, instead of the individual
engine id's. While we can have many engines, the protocols use far
fewer unique progress values. So instead of tracking for dozens of
prefilter id's, we track for the handful of progress values.

To allow for this the engine array is sorted by tx_min_progress, then
app_proto and finally local_id. A new field is added to "know" when
the last relevant engine for a progress value is reached, so that we
can set the prefilter bit then.

A consquence is that the progress values have a ceiling now that
needs to fit in a 64 bit bitarray. The values used by parsers currently
does not exceed 5, so that seems to be ok.

Bug: #4685.

3 years agoflow: log action applied to all packets
Victor Julien [Fri, 10 Sep 2021 12:07:49 +0000 (14:07 +0200)] 
flow: log action applied to all packets

Log if action applied to whole flow is drop or pass.

3 years agotests: fix drop test; cleanup
Victor Julien [Fri, 10 Sep 2021 11:43:26 +0000 (13:43 +0200)] 
tests: fix drop test; cleanup

SigTestDropFlow04 was incorrectly expecting an alert in the packet
following a "drop" packet. The first drop is applied to the flow, so
it should lead to the 2nd packet being dropped before inspection is
run.

Clean up the test as well.

3 years agodetect/tests: improve detection entry
Victor Julien [Fri, 10 Sep 2021 11:42:15 +0000 (13:42 +0200)] 
detect/tests: improve detection entry

Lots of tests still use SigMatchSignatures as their main detection
entry function, which bypassed some logic. Make it match main logic
more closely.

3 years agotests: clean up drop test
Victor Julien [Fri, 10 Sep 2021 11:03:26 +0000 (13:03 +0200)] 
tests: clean up drop test

3 years agodetect: enforce flow drops earlier
Victor Julien [Fri, 10 Sep 2021 10:35:13 +0000 (12:35 +0200)] 
detect: enforce flow drops earlier

Enforcing flow drops is now done earlier in the detection engine and
moved out of the IP-only engine where it didn't belong.

3 years agodetect: unify alert handling; fix bugs
Victor Julien [Fri, 3 Sep 2021 15:04:02 +0000 (17:04 +0200)] 
detect: unify alert handling; fix bugs

Unify handling of signature matches between various rule types and
between noalert and regular rules.

"noalert" sigs are added to the alert queue initially, but removed
from it after handling their actions. This way all actions are applied
from a single place.

Make sure flow drop and pass are mutually exclusive.

The above addresses issue with pass and drops not getting applied
correctly in various cases.

Bug: #4663
Bug: #4670

3 years agodetect: remove dead code
Victor Julien [Fri, 10 Sep 2021 08:19:50 +0000 (10:19 +0200)] 
detect: remove dead code

3 years agodetect/lua: use BIT_U32 for flags
Victor Julien [Tue, 14 Sep 2021 09:46:58 +0000 (11:46 +0200)] 
detect/lua: use BIT_U32 for flags

3 years agodetect/lua: minor cleanup
Victor Julien [Tue, 14 Sep 2021 09:46:28 +0000 (11:46 +0200)] 
detect/lua: minor cleanup

3 years agooutput/tx: check flags using BIT_U32
Victor Julien [Tue, 14 Sep 2021 09:39:26 +0000 (11:39 +0200)] 
output/tx: check flags using BIT_U32

3 years agopacket: use BIT_U32 for flags
Victor Julien [Tue, 14 Sep 2021 09:25:58 +0000 (11:25 +0200)] 
packet: use BIT_U32 for flags

3 years agodetect/mpm: micro optimization for initialization
Victor Julien [Tue, 14 Sep 2021 08:20:58 +0000 (10:20 +0200)] 
detect/mpm: micro optimization for initialization

Do less expensive check first.

3 years agodetect: remove ticker 6371/head
Victor Julien [Sat, 11 Sep 2021 07:50:36 +0000 (09:50 +0200)] 
detect: remove ticker

Last consumer of it has been converted.

3 years agodetect/http: clean up header buffer logic
Victor Julien [Sat, 11 Sep 2021 07:47:31 +0000 (09:47 +0200)] 
detect/http: clean up header buffer logic

Simplify and clean up header buffer management. The code was designed
to track buffers for several transactions in parallel, from when the
detection engine wasn't aware of transactions.

For http.start and http.header_names use generic mpm and inspect
functions.

3 years agoipv6: decoder event on invalid length 6336/head
Philippe Antoine [Mon, 19 Jul 2021 15:31:32 +0000 (17:31 +0200)] 
ipv6: decoder event on invalid length

From RFC 2460, section 4.5,
each fragment, except the last one, must have a length
which is a multiple of 8

3 years agohttp2: better rust style
Philippe Antoine [Fri, 4 Jun 2021 13:18:32 +0000 (15:18 +0200)] 
http2: better rust style

3 years agohttp2: concatenate one headers multiple values
Philippe Antoine [Mon, 31 May 2021 14:17:22 +0000 (16:17 +0200)] 
http2: concatenate one headers multiple values

For detection, as is done with HTTP1

3 years agohttp2: generic http2_header_blocks
Philippe Antoine [Mon, 31 May 2021 09:40:42 +0000 (11:40 +0200)] 
http2: generic http2_header_blocks

so as not to forget continuation and push promise
when iterating over headers

3 years agohttp2: http.header keyword now works for HTTP2
Philippe Antoine [Mon, 31 May 2021 08:50:38 +0000 (10:50 +0200)] 
http2: http.header keyword now works for HTTP2

As well as http.header.raw

3 years agohttp2: http.header_names keyword now works for HTTP2
Philippe Antoine [Mon, 31 May 2021 08:11:27 +0000 (10:11 +0200)] 
http2: http.header_names keyword now works for HTTP2

3 years agohttp2: http.host normalized keyword now works for HTTP2
Philippe Antoine [Wed, 26 May 2021 19:45:30 +0000 (21:45 +0200)] 
http2: http.host normalized keyword now works for HTTP2

3 years agohttp2: turn Host header into authority during upgrade
Philippe Antoine [Wed, 26 May 2021 18:54:01 +0000 (20:54 +0200)] 
http2: turn Host header into authority during upgrade

HTTP1 uses Host, but HTTP2 uses rather :authority cf HPACK

3 years agohttp2: better file tracking 6332/head
Philippe Antoine [Thu, 2 Sep 2021 14:31:20 +0000 (16:31 +0200)] 
http2: better file tracking

If an HTTP2 file was within only ont DATA frame, the filetracker
would open it and close it in the same call, preventing the
firther call to incr_files_opened

Also includes rustfmt again for all HTTP2 files

3 years agohttp2: support deflate decompression
Philippe Antoine [Mon, 5 Jul 2021 09:18:26 +0000 (11:18 +0200)] 
http2: support deflate decompression

cf #4556

3 years agoftp: support per-tx file accounting 6324/head
Victor Julien [Thu, 18 Mar 2021 12:47:26 +0000 (13:47 +0100)] 
ftp: support per-tx file accounting

3 years agosmtp: support per-tx file accounting
Victor Julien [Thu, 18 Mar 2021 07:38:03 +0000 (08:38 +0100)] 
smtp: support per-tx file accounting

3 years agosmb: add debug validation on file counts
Victor Julien [Thu, 18 Mar 2021 12:06:22 +0000 (13:06 +0100)] 
smb: add debug validation on file counts

3 years agosmb: count files in tx
Victor Julien [Thu, 18 Mar 2021 07:37:08 +0000 (08:37 +0100)] 
smb: count files in tx

3 years agohttp2: support per-tx file accounting
Victor Julien [Thu, 18 Mar 2021 07:36:22 +0000 (08:36 +0100)] 
http2: support per-tx file accounting

3 years agonfs: add debug validation on file counts
Victor Julien [Thu, 18 Mar 2021 12:06:34 +0000 (13:06 +0100)] 
nfs: add debug validation on file counts

3 years agonfs: support per-tx file accounting
Victor Julien [Thu, 18 Mar 2021 10:09:01 +0000 (11:09 +0100)] 
nfs: support per-tx file accounting

3 years agonfs: don't reuse file transactions
Victor Julien [Thu, 18 Mar 2021 10:05:35 +0000 (11:05 +0100)] 
nfs: don't reuse file transactions

After a file has been closed (CLOSE, COMMIT command or EOF/SYNC part of
READ/WRITE data block) mark it as such so that new file commands on that
file do not reuse the transaction.

When a file transfer is completed it will be flagged as such and not be
found anymore by the NFSState::get_file_tx_by_handle() method. This forces
a new transaction to be created.

3 years agohttp: support per-tx file accounting
Victor Julien [Thu, 18 Mar 2021 09:57:48 +0000 (10:57 +0100)] 
http: support per-tx file accounting

3 years agofilestore: track files getting stored per tx
Victor Julien [Tue, 23 Mar 2021 10:08:33 +0000 (11:08 +0100)] 
filestore: track files getting stored per tx

Avoid evicting a tx before the filedata logger has decided it is
done.

3 years agofilestore: store chunks in packet direction
Victor Julien [Thu, 18 Mar 2021 13:38:33 +0000 (14:38 +0100)] 
filestore: store chunks in packet direction

Storing too early can lead to files being considered TRUNCATED if the
TCP state is not yet CLOSED when logging is triggered. This has been
observed with FTP-DATA and might also be an issue with simple HTTP.

3 years agoapp-layer/transactions: track files opens and logs
Victor Julien [Thu, 18 Mar 2021 09:55:50 +0000 (10:55 +0100)] 
app-layer/transactions: track files opens and logs

To make sure a transaction is not evicted before all file logging is complete.

3 years agoeve/files: log in packet direction only
Victor Julien [Thu, 18 Mar 2021 09:52:44 +0000 (10:52 +0100)] 
eve/files: log in packet direction only

Bug: #3703.

Don't log files too soon.

3 years agoGRE: Handling pptp without payload
Vladimir Ivchenko [Thu, 10 Dec 2020 15:05:15 +0000 (20:05 +0500)] 
GRE: Handling pptp without payload

If one of the ppp peers sends a packet with an acknowledge flag,
the ppp payload will be empty and DecodePPP will return TM_ECODE_FAILED.
To handle this case, the packet_length field in the GRE extended header (https://tools.ietf.org/html/rfc2637#section-4.1) is used.
DecodeGRE no longer tries to parse PPP payload if packet_length is zero.

3 years agoscripts: bundle script for requirements
Jason Ish [Thu, 29 Oct 2020 23:05:01 +0000 (17:05 -0600)] 
scripts: bundle script for requirements

Add a bundle.sh script to bundle the requirements of libhtp
and suricata-update. This uses a Python like requirements.txt
file to specify the URL to download for libhtp and suricata-update.

3 years agodoc: Update public-data-sets.rst
Lukas Sismis [Tue, 27 Oct 2020 10:21:06 +0000 (11:21 +0100)] 
doc: Update public-data-sets.rst

Replace dead link

Dataset on ll.mit.edu returns 404. Link updated with a search result of more datasets.

3 years agodetect-dsize: Add ! operator for dsize matching
Joshua Lumb [Tue, 9 Jun 2020 16:12:26 +0000 (12:12 -0400)] 
detect-dsize: Add ! operator for dsize matching

3 years agosmb: get file name in case of chained commands
Philippe Antoine [Tue, 13 Jul 2021 11:30:00 +0000 (13:30 +0200)] 
smb: get file name in case of chained commands

3 years agosmb: fix parsing of file deletion over SMB1
Philippe Antoine [Tue, 13 Jul 2021 08:00:48 +0000 (10:00 +0200)] 
smb: fix parsing of file deletion over SMB1

3 years agosmb: recognizes file deletion over SMB2
Philippe Antoine [Tue, 13 Jul 2021 06:40:42 +0000 (08:40 +0200)] 
smb: recognizes file deletion over SMB2

using set_info_level == SMB2_FILE_DISPOSITION_INFO

3 years agoike: use derive macro from app-layer events
Jason Ish [Mon, 30 Aug 2021 21:49:58 +0000 (15:49 -0600)] 
ike: use derive macro from app-layer events

3 years agomodbus: use derive macro from app-layer events
Jason Ish [Mon, 30 Aug 2021 21:45:15 +0000 (15:45 -0600)] 
modbus: use derive macro from app-layer events

3 years agoapp-layer template: use derived app-layer event
Jason Ish [Wed, 18 Nov 2020 22:26:18 +0000 (16:26 -0600)] 
app-layer template: use derived app-layer event

3 years agohttp2: use derived app-layer event
Jason Ish [Wed, 18 Nov 2020 22:23:49 +0000 (16:23 -0600)] 
http2: use derived app-layer event

3 years agokrb5: use derived app-layer event
Jason Ish [Wed, 18 Nov 2020 22:17:31 +0000 (16:17 -0600)] 
krb5: use derived app-layer event

3 years agontp: use derived app-layer event
Jason Ish [Wed, 18 Nov 2020 22:14:14 +0000 (16:14 -0600)] 
ntp: use derived app-layer event

3 years agorfb: register None for get_event_info/get_event_info_by_id
Jason Ish [Wed, 18 Nov 2020 22:11:48 +0000 (16:11 -0600)] 
rfb: register None for get_event_info/get_event_info_by_id

Implementations are not required if they're just going to return
-1. We allow None to be registered for that.

3 years agosip: use derived app-layer event
Jason Ish [Wed, 18 Nov 2020 22:07:52 +0000 (16:07 -0600)] 
sip: use derived app-layer event

3 years agosnmp: use derived app-layer event
Jason Ish [Wed, 18 Nov 2020 22:03:50 +0000 (16:03 -0600)] 
snmp: use derived app-layer event

3 years agossh: use derived app-layer event
Jason Ish [Wed, 18 Nov 2020 22:01:04 +0000 (16:01 -0600)] 
ssh: use derived app-layer event

3 years agodhcp: use derived app-layer event
Jason Ish [Wed, 18 Nov 2020 21:57:53 +0000 (15:57 -0600)] 
dhcp: use derived app-layer event

3 years agosmb: use derived get_event_info/get_event_info_by_id
Jason Ish [Mon, 19 Oct 2020 18:28:15 +0000 (12:28 -0600)] 
smb: use derived get_event_info/get_event_info_by_id

3 years agomqtt: derive AppLayerEvent for MQTTEvent
Jason Ish [Fri, 16 Oct 2020 21:45:37 +0000 (15:45 -0600)] 
mqtt: derive AppLayerEvent for MQTTEvent

3 years agodns: use derive macro for DNSEvent
Jason Ish [Mon, 13 Jan 2020 05:13:54 +0000 (23:13 -0600)] 
dns: use derive macro for DNSEvent

3 years agoapplayerevent: derive get_event_info and get_event_info_by_id
Jason Ish [Mon, 19 Oct 2020 17:17:48 +0000 (11:17 -0600)] 
applayerevent: derive get_event_info and get_event_info_by_id

Add generation of wrapper functions for get_event_info
and get_event_info_by_id to the derive macro. Eliminates
the need for the wrapper method to be created by the parser
author.

3 years agorust/applayer: provide generic event info functions
Jason Ish [Wed, 18 Nov 2020 17:57:22 +0000 (11:57 -0600)] 
rust/applayer: provide generic event info functions

Provide generic functions for get_event_info and
get_event_info_by_id. These functions can be used by any app-layer
event enum that implements AppLayerEvent.

Unfortunately the parser registration cannot use these functions
directly as generic functions cannot be #[no_mangle]. So they
do need small extern "C" wrappers around them.

3 years agorust: derive crate: for custom derives
Jason Ish [Mon, 13 Jan 2020 04:56:47 +0000 (22:56 -0600)] 
rust: derive crate: for custom derives

Currently has one derive, AppLayerEvent to be used like:

  #[derive(AppLayerEvent)]
  pub enum DNSEvent {
      MalformedData,
      NotRequest,
      NotResponse,
      ZFlagSet,
  }

Code will be generated to:
- Convert enum to a c type string
- Convert string to enum variant
- Convert id to enum variant

3 years agorust/applayer: define AppLayerEvent trait
Jason Ish [Mon, 19 Oct 2020 16:30:29 +0000 (10:30 -0600)] 
rust/applayer: define AppLayerEvent trait

The derive macro will implement this trait for app-layer
event enums.

3 years agomacset: adjust test to pass after fix
Victor Julien [Mon, 30 Aug 2021 19:56:24 +0000 (21:56 +0200)] 
macset: adjust test to pass after fix

3 years agoci: dummy git configuration for rebase
Philippe Antoine [Fri, 27 Aug 2021 15:36:50 +0000 (17:36 +0200)] 
ci: dummy git configuration for rebase

3 years agomacset: fix memory size check
Eric Leblond [Fri, 20 Aug 2021 12:41:20 +0000 (14:41 +0200)] 
macset: fix memory size check

3 years agoflow: be sure to check hash till the end
Eric Leblond [Fri, 20 Aug 2021 08:42:13 +0000 (10:42 +0200)] 
flow: be sure to check hash till the end

3 years agoflow: add comment on flow handling
Eric Leblond [Thu, 19 Aug 2021 14:30:50 +0000 (16:30 +0200)] 
flow: add comment on flow handling

3 years agostream: increase memcap on memory errors
Eric Leblond [Thu, 19 Aug 2021 09:22:06 +0000 (11:22 +0200)] 
stream: increase memcap on memory errors

3 years agoutil/streaming: improve error handling
Eric Leblond [Thu, 19 Aug 2021 09:21:21 +0000 (11:21 +0200)] 
util/streaming: improve error handling

It differentiates memory error than regular ones.

3 years agoflow: fix a debug assert
Eric Leblond [Sun, 15 Aug 2021 10:17:23 +0000 (12:17 +0200)] 
flow: fix a debug assert

As the FlowBypassedTimeout function is interacting with the capture
method it is possible that the return changes between the call that
did trigger the timeout and the actual state (ie if packets arrive
in between the two calls). So we should not use the call to
FlowBypassedTimeout in the assert.

3 years agoflow: document FlowBypassedTimeout
Eric Leblond [Sat, 14 Aug 2021 21:08:01 +0000 (23:08 +0200)] 
flow: document FlowBypassedTimeout

Main point is to document it is interacting with the capture
layer.

3 years agoflow: more accurate flow counters
Eric Leblond [Sat, 14 Aug 2021 21:05:03 +0000 (23:05 +0200)] 
flow: more accurate flow counters

Don't increment the flow timeout counter for flows that are not
really timeout (as use_cnt is non zero). And also don't take into
account bypassed flows in the counter for flow timeout in use.

3 years agoflow/worker: handle timeout edge case
Victor Julien [Mon, 30 Aug 2021 08:53:49 +0000 (10:53 +0200)] 
flow/worker: handle timeout edge case

In the flow worker timeout path it is assumed that we can hand off
flows to the recycler after processing, implying that `Flow::use_cnt` is 0.
However, there was a case where this assumption was incorrect.

When during flow timeout handling the last processed data would trigger a
protocol upgrade, two additional pseudo packets would be created that were
then pushed all the way through the engine packet paths. This would mean
they both took a flow reference and would hold that until after the flow
was handed off to the recycler. Thread safety implementation would make
sure this didn't lead to crashes.

This patch handles this case returning these packets to the pool from
the timeout handling.

3 years agoflow/worker: set proper end flag
Victor Julien [Fri, 30 Jul 2021 19:15:28 +0000 (21:15 +0200)] 
flow/worker: set proper end flag

3 years agoflow/manager: set proper end flag
Victor Julien [Fri, 30 Jul 2021 18:12:05 +0000 (20:12 +0200)] 
flow/manager: set proper end flag

3 years agodetect: debug validation for list ids overflows
Philippe Antoine [Mon, 30 Aug 2021 20:01:18 +0000 (22:01 +0200)] 
detect: debug validation for list ids overflows

3 years agodetect: move init only array to init data
Victor Julien [Fri, 19 Feb 2021 10:57:57 +0000 (11:57 +0100)] 
detect: move init only array to init data

3 years agodetect/analyzer: use rule style pretty print for patterns
Victor Julien [Thu, 18 Feb 2021 14:03:47 +0000 (15:03 +0100)] 
detect/analyzer: use rule style pretty print for patterns

3 years agodetect/content: generalize pattern pretty printing
Victor Julien [Thu, 18 Feb 2021 13:22:41 +0000 (14:22 +0100)] 
detect/content: generalize pattern pretty printing

3 years agodetect/profile: add support for tx inspection
Victor Julien [Thu, 18 Feb 2021 09:03:53 +0000 (10:03 +0100)] 
detect/profile: add support for tx inspection

Add 'inspect_type' "packet" and "tx" for the two record types. Add more metadata
when available.

3 years agodetect/analyze: dump patterns facility
Victor Julien [Tue, 16 Feb 2021 16:43:08 +0000 (17:43 +0100)] 
detect/analyze: dump patterns facility

Dump all patterns to `patterns.json`, with the pattern, a total count (`cnt`),
count of how many times this pattern is the mpm (`mpm`) and some of the flags.

Patterns are listed per buffer. So payload, http_uri, etc.

3 years agodetect/content: add some more dsize tests
Victor Julien [Mon, 15 Feb 2021 08:50:03 +0000 (09:50 +0100)] 
detect/content: add some more dsize tests

3 years agodetect/dsize: set depth flag when applying dsize as depth
Victor Julien [Fri, 5 Feb 2021 21:01:55 +0000 (22:01 +0100)] 
detect/dsize: set depth flag when applying dsize as depth

3 years agodetect/analyzer: count mpm with depth, endswith
Victor Julien [Sat, 6 Feb 2021 09:35:14 +0000 (10:35 +0100)] 
detect/analyzer: count mpm with depth, endswith

3 years agodetect/analyzer: show payload separately in group dumping
Victor Julien [Mon, 8 Feb 2021 21:06:41 +0000 (22:06 +0100)] 
detect/analyzer: show payload separately in group dumping

3 years agodetect/analyzer: add icmp to rule group output
Victor Julien [Mon, 8 Feb 2021 08:41:22 +0000 (09:41 +0100)] 
detect/analyzer: add icmp to rule group output

3 years agodetect/analyzer: display per rule prefilter details
Victor Julien [Mon, 8 Feb 2021 07:28:37 +0000 (08:28 +0100)] 
detect/analyzer: display per rule prefilter details

3 years agodetect/analyzer: count prefilter per rule group
Victor Julien [Mon, 8 Feb 2021 07:28:09 +0000 (08:28 +0100)] 
detect/analyzer: count prefilter per rule group

3 years agodetect/analyzer: add per rule mpm block to rules.json
Victor Julien [Sat, 6 Feb 2021 20:38:31 +0000 (21:38 +0100)] 
detect/analyzer: add per rule mpm block to rules.json

3 years agodetect/analyzer: support buffer names in sgh dump
Victor Julien [Sat, 6 Feb 2021 07:47:58 +0000 (08:47 +0100)] 
detect/analyzer: support buffer names in sgh dump

3 years agoflow: determine packet direction once per packet
Victor Julien [Tue, 26 Feb 2019 09:43:58 +0000 (10:43 +0100)] 
flow: determine packet direction once per packet

3 years agodecode: convert 'action' macros to inline funcs
Victor Julien [Sat, 16 Nov 2019 18:20:31 +0000 (19:20 +0100)] 
decode: convert 'action' macros to inline funcs

Make sure most common branch is handled first to assist branch
prediction.

Macros still play a small role to please our 'action' cocci check.

3 years agodetect/mpm: turn factory array into list
Victor Julien [Mon, 8 Feb 2021 21:08:49 +0000 (22:08 +0100)] 
detect/mpm: turn factory array into list

3 years agodetect/stream: don't run mpm on packet if stream is available
Victor Julien [Tue, 9 Feb 2021 19:22:54 +0000 (20:22 +0100)] 
detect/stream: don't run mpm on packet if stream is available

3 years agodoc: escape dot in pcre 6306/head
myr463 [Wed, 9 Dec 2020 16:48:34 +0000 (17:48 +0100)] 
doc: escape dot in pcre

3 years agounix-socket: Avoid spurious logs on close
Michael Smith [Tue, 22 Jun 2021 02:33:47 +0000 (22:33 -0400)] 
unix-socket: Avoid spurious logs on close

Avoid spurious logs when suricatasc closes connection.

Use SCLogDebug for control connection EOF, and SCLogError for an error.

As Chandan Chowdhury described in redmine 3685. This makes the logging
consistent with the older `if (client->version <= UNIX_PROTO_V1)` block
about 20 lines above, and avoids polluting the logs with
`Unix socket: lost connection with client`.

3 years agoci: rebase specified s-v pr
Philippe Antoine [Mon, 5 Jul 2021 14:37:03 +0000 (16:37 +0200)] 
ci: rebase specified s-v pr

So that CI does not fail, if suricata PR got upgraded in a new
version, but S-V PR did not get upgraded, and S-V changed
in master

3 years agodnp3: regenerate object decoding code
Philippe Antoine [Thu, 8 Jul 2021 13:02:50 +0000 (15:02 +0200)] 
dnp3: regenerate object decoding code

Ticket: #4558
So as to avoid intra-structure overflow

3 years agodnp3: adds bounds check for prefix chararray
Philippe Antoine [Thu, 8 Jul 2021 13:01:15 +0000 (15:01 +0200)] 
dnp3: adds bounds check for prefix chararray

Ticket: #4558
Avoids intra structure overflow