]> git.ipfire.org Git - thirdparty/suricata.git/log
thirdparty/suricata.git
2 years agorequirements: use suricata-update 1.3.0rc1 8501/head
Jason Ish [Mon, 30 Jan 2023 17:15:37 +0000 (11:15 -0600)] 
requirements: use suricata-update 1.3.0rc1

2 years agodoc: warn IPS users on new exception policy default
Victor Julien [Mon, 30 Jan 2023 17:42:38 +0000 (18:42 +0100)] 
doc: warn IPS users on new exception policy default

2 years agoexception/policy: add more info on defaults
Victor Julien [Mon, 30 Jan 2023 17:28:04 +0000 (18:28 +0100)] 
exception/policy: add more info on defaults

Be more informative where a exception value came from: defaults,
master switch or an explicit setting.

2 years agostream/midstream: add bug number to policy warning
Victor Julien [Mon, 30 Jan 2023 17:02:39 +0000 (18:02 +0100)] 
stream/midstream: add bug number to policy warning

2 years agoexception/policy: 'auto' sets IPS to 'drop-flow'
Victor Julien [Mon, 30 Jan 2023 16:15:49 +0000 (17:15 +0100)] 
exception/policy: 'auto' sets IPS to 'drop-flow'

In IPS mode set all exception policies to drop-flow by default, both
in the default yaml and if no `exception-policy` is defined.

2 years agoexception/policy: fix formatting issues
Victor Julien [Mon, 30 Jan 2023 16:06:10 +0000 (17:06 +0100)] 
exception/policy: fix formatting issues

2 years agodecoder: mention removal of udp.hlen_invalid sig
Victor Julien [Mon, 30 Jan 2023 13:32:28 +0000 (14:32 +0100)] 
decoder: mention removal of udp.hlen_invalid sig

2 years agorules/decoder: fix sid for udp.len_invalid rule
Shivani Bhardwaj [Mon, 30 Jan 2023 09:44:06 +0000 (15:14 +0530)] 
rules/decoder: fix sid for udp.len_invalid rule

2 years agoflow: enforce flow assumption 8495/head
Victor Julien [Mon, 30 Jan 2023 10:27:37 +0000 (11:27 +0100)] 
flow: enforce flow assumption

Enforce assumption that packets in ThreadVars::decode_pq have no flow
attached to it because this is only true for packets while they are
in the FlowWorker.

2 years agoflow/mgr: remove flows_timeout_inuse counter
Victor Julien [Mon, 30 Jan 2023 10:07:45 +0000 (11:07 +0100)] 
flow/mgr: remove flows_timeout_inuse counter

2 years agoflow: rearrange Flow struct to be more compact
Victor Julien [Sun, 29 Jan 2023 09:47:53 +0000 (10:47 +0100)] 
flow: rearrange Flow struct to be more compact

2 years agoflow: remove use_cnt
Victor Julien [Fri, 27 Jan 2023 19:47:46 +0000 (20:47 +0100)] 
flow: remove use_cnt

Packets only ever reference the flow while holding its lock. This
means than any code possibly evicting the flow will have to wait
for the existing users to complete their work. Therefore the use_cnt
serves no function anymore and can be removed.

2 years agoflowworker: don't keep unnecessary flow reference
Victor Julien [Fri, 27 Jan 2023 19:30:20 +0000 (20:30 +0100)] 
flowworker: don't keep unnecessary flow reference

Flow stream/detect/log flush packets, don't hold on to the flow
beyond the flow worker module.

2 years agostream: remove unused pseudo packet function
Victor Julien [Fri, 27 Jan 2023 19:22:44 +0000 (20:22 +0100)] 
stream: remove unused pseudo packet function

2 years agogithub-ci: dump github context and pr body 8489/head
Jason Ish [Wed, 25 Jan 2023 21:41:50 +0000 (15:41 -0600)] 
github-ci: dump github context and pr body

For debugging the parsing of suricata-verify-pr.

2 years agogithub-ci: annotate job with s-v info
Jason Ish [Wed, 25 Jan 2023 18:48:57 +0000 (12:48 -0600)] 
github-ci: annotate job with s-v info

2 years agorfb: remove duplicate logging of depth
Jason Ish [Wed, 25 Jan 2023 17:07:19 +0000 (11:07 -0600)] 
rfb: remove duplicate logging of depth

The "depth" field in the "pixel_format" object was being logged twice.

Issue: 5813

2 years agosmb: fix duplicate interface logging
Jason Ish [Wed, 25 Jan 2023 17:53:08 +0000 (11:53 -0600)] 
smb: fix duplicate interface logging

An array of interfaces was being logged without creating an array,
resulting in duplicate "interface" objects being logged. Instead put
these interfaces into an array like already done elsewhere.

Issue: 5814

2 years agoeve: remove dcerpc.interface from schema
Jason Ish [Wed, 25 Jan 2023 17:52:07 +0000 (11:52 -0600)] 
eve: remove dcerpc.interface from schema

Looks like this was due to an error in the dcerpc logging where the
interfaces should have been logged to the "interfaces" array that was
already defined.

Issue: 5814

2 years agosmb: remove duplicate tree_id logging
Jason Ish [Wed, 25 Jan 2023 18:02:27 +0000 (12:02 -0600)] 
smb: remove duplicate tree_id logging

Remove the second occurrence of tree_id logging which appears to
always be a duplicate of the first tree_id logged, even though they
come from different data structures.

Issue: 5811

2 years agogithub-ci/rust: display clippy diff
Jason Ish [Sat, 28 Jan 2023 18:54:36 +0000 (12:54 -0600)] 
github-ci/rust: display clippy diff

2 years agorust: utility function to copy Rust strings to C strings
Jason Ish [Fri, 27 Jan 2023 06:58:58 +0000 (00:58 -0600)] 
rust: utility function to copy Rust strings to C strings

As there are a few places where a Rust string is copied into a provided
C string buffer, create a utility function to take care of these
details.

2 years agotls: fix date logging for dates before 1970
Jason Ish [Fri, 27 Jan 2023 05:03:22 +0000 (23:03 -0600)] 
tls: fix date logging for dates before 1970

The Rust time crate used by the x509-parser crate represents dates
before 1970 as negative numbers which do not survive the conversion to
SCTime_t and formatting with the current time formatting functions.

Instead of fixing our formatting functions to handle such dates,
create a Rust function for logging TLS dates directly to JSON using
the time crate that handles such dates properly.

Also add a FFI function for formatting to a provided C buffer for the
legacy tls-log.

Issue: 5817

2 years agoschema: add regular expression for tls date format
Jason Ish [Thu, 26 Jan 2023 20:37:54 +0000 (14:37 -0600)] 
schema: add regular expression for tls date format

2 years agodetect/frames: improve IPS and GAP handling 8482/head
Victor Julien [Thu, 26 Jan 2023 14:40:49 +0000 (15:40 +0100)] 
detect/frames: improve IPS and GAP handling

Inspect individual chunks in lossy traffic.

Don't use the frame idx as the inspection buffer idx. Engines are running
per frame, so multi inspection can be used for stream chunks instead.

Ticket: #4977.

2 years agodetect/frames: handle duplicate sigs in candidates
Victor Julien [Fri, 27 Jan 2023 11:37:32 +0000 (12:37 +0100)] 
detect/frames: handle duplicate sigs in candidates

Prefilter engines run on each stream chunk in a lossy stream, so
we can get the same sid in the list multiple times.

2 years agostream: add util to get absolute right edge of data
Victor Julien [Thu, 26 Jan 2023 14:39:45 +0000 (15:39 +0100)] 
stream: add util to get absolute right edge of data

2 years agodetect/frames: reduce scope of private function
Victor Julien [Thu, 26 Jan 2023 11:00:14 +0000 (12:00 +0100)] 
detect/frames: reduce scope of private function

2 years agooutput: move function name in non-release output
Victor Julien [Thu, 26 Jan 2023 14:46:08 +0000 (15:46 +0100)] 
output: move function name in non-release output

2 years agodetect/tls.certs: improve buffer init logic
Victor Julien [Sat, 28 Jan 2023 10:40:53 +0000 (11:40 +0100)] 
detect/tls.certs: improve buffer init logic

2 years agodetect/quic: update buffer initialization logic
Victor Julien [Sat, 28 Jan 2023 10:33:00 +0000 (11:33 +0100)] 
detect/quic: update buffer initialization logic

2 years agodetect/mqtt: update buffer initialization logic
Victor Julien [Sat, 28 Jan 2023 10:30:22 +0000 (11:30 +0100)] 
detect/mqtt: update buffer initialization logic

2 years agodetect/krb5.sname: update buffer initialization logic
Victor Julien [Sat, 28 Jan 2023 10:29:20 +0000 (11:29 +0100)] 
detect/krb5.sname: update buffer initialization logic

2 years agodetect/krb5.cname: update buffer initialization logic
Victor Julien [Sat, 28 Jan 2023 10:28:23 +0000 (11:28 +0100)] 
detect/krb5.cname: update buffer initialization logic

2 years agodetect/ike.vendor: update buffer initialization logic
Victor Julien [Sat, 28 Jan 2023 10:26:46 +0000 (11:26 +0100)] 
detect/ike.vendor: update buffer initialization logic

2 years agodetect/http2: update buffer initialization logic
Victor Julien [Sat, 28 Jan 2023 10:25:11 +0000 (11:25 +0100)] 
detect/http2: update buffer initialization logic

2 years agodetect/file.name: update buffer initialization logic
Victor Julien [Sat, 28 Jan 2023 10:23:08 +0000 (11:23 +0100)] 
detect/file.name: update buffer initialization logic

2 years agodetect/file.magic: update buffer initialization logic
Victor Julien [Sat, 28 Jan 2023 10:21:59 +0000 (11:21 +0100)] 
detect/file.magic: update buffer initialization logic

2 years agodetect/file.data: update buffer initialization logic
Victor Julien [Sat, 28 Jan 2023 09:15:58 +0000 (10:15 +0100)] 
detect/file.data: update buffer initialization logic

2 years agodetect/http.uri: update buffer initialization logic
Victor Julien [Sat, 28 Jan 2023 09:10:54 +0000 (10:10 +0100)] 
detect/http.uri: update buffer initialization logic

2 years agodetect/dce.stub_data: update buffer initialization logic
Victor Julien [Sat, 28 Jan 2023 09:09:30 +0000 (10:09 +0100)] 
detect/dce.stub_data: update buffer initialization logic

2 years agodetect/dns: update buffer initialization logic
Victor Julien [Sat, 28 Jan 2023 09:08:29 +0000 (10:08 +0100)] 
detect/dns: update buffer initialization logic

2 years agodetect/buffer: add initialized flag to simplify buffer logic
Victor Julien [Sat, 28 Jan 2023 08:57:44 +0000 (09:57 +0100)] 
detect/buffer: add initialized flag to simplify buffer logic

2 years agodecode/stat: Add decode counters for unknown/arp 8479/head
Jeff Lucovsky [Fri, 16 Dec 2022 14:11:05 +0000 (09:11 -0500)] 
decode/stat: Add decode counters for unknown/arp

Issue: 5761

This commit adds statistics for ARP and unknown ethertype packets for
diagnostic purposes.

2 years agoftp: adds a config option ftp-hash for autofp-scheduler
Philippe Antoine [Mon, 14 Mar 2022 10:55:08 +0000 (11:55 +0100)] 
ftp: adds a config option ftp-hash for autofp-scheduler

This allows ftp-data and ftp flows to be processed by the same
thread. Otherwise, there may be a concurrency issue where the
would-be ftp-data flow is first processed, and thus not recognized
as such. And the ftp flow gets processed later and the expectation
coming from it is never found.

To do so, the flow hash gets used as usual, except for flows that
may be either ftp or ftp-data, that is either one port is 21, or
both ports are high ones.

Ticket: #5205

2 years agosrc: fix coverity warning about sizeof
Philippe Antoine [Fri, 27 Jan 2023 12:28:57 +0000 (13:28 +0100)] 
src: fix coverity warning about sizeof

CID: 1520601
CID: 1520602

> In this particular case sizeof (char **) happens to be equal to
sizeof (char *), but this is not a portable assumption.

2 years agoconfig: check return value of dotted override 8477/head
Jason Ish [Fri, 27 Jan 2023 17:40:28 +0000 (11:40 -0600)] 
config: check return value of dotted override

Fixes commit fbb0d2b0f4ccc873b74ec5db97c08cfa8a9ce251.

2 years agorust: suppress specific manual_flatten list 8468/head
Jason Ish [Thu, 26 Jan 2023 17:29:55 +0000 (11:29 -0600)] 
rust: suppress specific manual_flatten list

In this case of debug code, the explicit iterator seems to make more
sense.

2 years agorust: remove explicit lifetimes where not needed
Jason Ish [Thu, 26 Jan 2023 17:26:18 +0000 (11:26 -0600)] 
rust: remove explicit lifetimes where not needed

2 years agorust: fix needless borrows of references
Jason Ish [Thu, 26 Jan 2023 17:13:14 +0000 (11:13 -0600)] 
rust: fix needless borrows of references

Fixed automatically by cargo clippy --fix.

2 years agorust: allow uninlined_format_args
Jason Ish [Thu, 26 Jan 2023 17:02:36 +0000 (11:02 -0600)] 
rust: allow uninlined_format_args

Newer versions of Rust/clippy are getting picky about format strings.
We should allow and use the new style, but also not prevent the old
style.

2 years agorules/readme: document sid ranges in source tree 8467/head
Jason Ish [Fri, 20 Jan 2023 22:31:00 +0000 (16:31 -0600)] 
rules/readme: document sid ranges in source tree

2 years agoftp: add events for command too long
Jason Ish [Fri, 20 Jan 2023 22:12:54 +0000 (16:12 -0600)] 
ftp: add events for command too long

Issue: 5235

2 years agorust/derive: allow event name to be set as attribute
Jason Ish [Mon, 23 Jan 2023 17:21:09 +0000 (11:21 -0600)] 
rust/derive: allow event name to be set as attribute

When deriving AppLayerEvent, allow the event name to be set with the
"name" attribute in cases where the transformed name is not suitable.

This allows us to use enum variant names like
"FtpEventRequestCommandTooLong" for direct use in C, but is also a
name that doesn't transform well to an event name in rules, where we
want to see "request_command_too_long".

2 years agodoc/userguide: document --include command line option
Jason Ish [Mon, 17 Oct 2022 21:40:43 +0000 (15:40 -0600)] 
doc/userguide: document --include command line option

2 years agosuricata: allow additional include files on command line
Jason Ish [Mon, 17 Oct 2022 21:10:48 +0000 (15:10 -0600)] 
suricata: allow additional include files on command line

Add a new command line option, --include. This will merge additional
configuration files into the configuration specified in the main
suricata.yaml.  It can be provided multiple times and the files will be
included in the order they appear on the command line.

Ticket: 3912

2 years agoyaml-loader: add test for fully qualified override
Jason Ish [Tue, 24 Jan 2023 23:26:29 +0000 (17:26 -0600)] 
yaml-loader: add test for fully qualified override

Also set the parent node for regular nodes on creation as this is
useful in unit-tests to verify the parent of a node.

2 years agoconfig: allow fully qualified overrides
Jason Ish [Tue, 24 Jan 2023 22:57:47 +0000 (16:57 -0600)] 
config: allow fully qualified overrides

Allow configuration parameters to be overrided usually a fully
qualified name such as:

vars.address-groups.HOME_NET: "7.1.2.0/24"

In configuration files (including "include" files).  This allows the
overriding of a specific value deeply nested in the configuration
without having to redefine the complete top-layer object.

Ticket: 4783

2 years agoutil/landlock: check return values for ConfGet 8462/head
Philippe Antoine [Wed, 25 Jan 2023 14:25:59 +0000 (15:25 +0100)] 
util/landlock: check return values for ConfGet

CID 1514671
CID 1514669

2 years agodcerpc: config limit maximum number of live transactions 8459/head
Philippe Antoine [Tue, 10 Jan 2023 10:08:36 +0000 (11:08 +0100)] 
dcerpc: config limit maximum number of live transactions

As is done for other protocols

Ticket: #5779

2 years agorules/decoder: add udp.len_invalid rule
Shivani Bhardwaj [Wed, 18 Jan 2023 01:35:08 +0000 (07:05 +0530)] 
rules/decoder: add udp.len_invalid rule

2 years agoeve/schema: add udp.len_invalid
Shivani Bhardwaj [Wed, 18 Jan 2023 01:24:55 +0000 (06:54 +0530)] 
eve/schema: add udp.len_invalid

2 years agodecode/udp: fix payload_len calculation
Shivani Bhardwaj [Wed, 4 Jan 2023 06:30:13 +0000 (12:00 +0530)] 
decode/udp: fix payload_len calculation

Fix payload_len calculation post removal of the condition that returned
error code if the length to the decode fn did not match the length of
header from the UDP packet.

Bug 5379

2 years agodecode/events: add event type UDP_LEN_INVALID
Shivani Bhardwaj [Wed, 18 Jan 2023 00:53:13 +0000 (06:23 +0530)] 
decode/events: add event type UDP_LEN_INVALID

2 years agodecode-udp: Allow shorter UDP packets than the remaining payload length
Lukas Sismis [Fri, 18 Nov 2022 15:13:58 +0000 (16:13 +0100)] 
decode-udp:  Allow shorter UDP packets than the remaining payload length

If the packet is shorter than IP payload length we no longer flag it as an
invalid UDP packet. UDP packet can be therefore shorter than IP payload.
Keyword "udp.hlen_invalid" became outdated as we no longer flag short UDP
packets as invalid.

Redmine ticket: #5693

2 years agohttp2: fix leak with range files
Philippe Antoine [Sat, 21 Jan 2023 17:19:47 +0000 (18:19 +0100)] 
http2: fix leak with range files

Ticket: #5808

May have been introduced by a24d7dc45c818054f97448ce42ca9ba270b3b8e4

Function http2_range_open expects to be called only when
tx.file_range is nil. One condition to ensure this is to check
that we are beginning the files contents. The filetracker field
file_open is not fit for this, as it may be reset to false.

2 years agolog-pcap: fix inverse logic error
Jason Ish [Tue, 24 Jan 2023 22:27:00 +0000 (16:27 -0600)] 
log-pcap: fix inverse logic error

We shouldn't early initialize when *offline*.  Instead this accidentally
delayed initializing when if an online mode, however its likely not to
have been noticed as delaying initializing in online mode is supported
as well.

2 years agorunmodes: fix memory leak
Philippe Antoine [Wed, 25 Jan 2023 14:01:52 +0000 (15:01 +0100)] 
runmodes: fix memory leak

By using constant for string instead of allocating and leaking it

CID: 1520497
CID: 1520500

2 years agotest: do not output non ascii character 8444/head
Philippe Antoine [Thu, 15 Sep 2022 13:26:46 +0000 (15:26 +0200)] 
test: do not output non ascii character

The unit test for content |aa bz| transforms in place the string
str to replace the 2 characters aa by one character 0xaa
Then, when z is not recognized as a valid hexadeicmal character,
the whole modified string is printed out, inclusing the non-ascii
0xaa

Ticket: #5558

2 years agostreaming: fix possible use after free
Victor Julien [Wed, 25 Jan 2023 11:29:09 +0000 (12:29 +0100)] 
streaming: fix possible use after free

Don't use ptr after freeing it. Reported by Coverity Scan.

2 years agostreaming: remove dead code
Victor Julien [Wed, 25 Jan 2023 10:58:11 +0000 (11:58 +0100)] 
streaming: remove dead code

As reported by Coverity Scan.

2 years agoflow: make next_ts unsigned
Victor Julien [Tue, 24 Jan 2023 19:54:40 +0000 (20:54 +0100)] 
flow: make next_ts unsigned

To silence a coverity warning.

2 years agotime: fix various time issues
Victor Julien [Tue, 24 Jan 2023 19:29:52 +0000 (20:29 +0100)] 
time: fix various time issues

Found by Coverity Scan.

2 years agodetect/ftp: use AppLayerResult API 8434/head
Shivani Bhardwaj [Mon, 23 Jan 2023 08:12:43 +0000 (13:42 +0530)] 
detect/ftp: use AppLayerResult API

2 years agostream: remove unused retval from fn description
Juliana Fajardini [Tue, 10 Jan 2023 22:23:47 +0000 (19:23 -0300)] 
stream: remove unused retval from fn description

2 years agouserguide/config: update log format symbols list
Juliana Fajardini [Tue, 10 Jan 2023 22:14:08 +0000 (19:14 -0300)] 
userguide/config: update log format symbols list

There were some possible format options missing after the recent changes
in the log format.

2 years agotls: accept validity before 1970
Philippe Antoine [Fri, 6 Jan 2023 09:42:56 +0000 (10:42 +0100)] 
tls: accept validity before 1970

modify TLS certificate decoding of validity timestamps
to support times between 1950 and 2049,
as per RFC 5280

Ticket: #3253

2 years agodetect: config keyword transaction logic fix
Philippe Antoine [Mon, 25 Jul 2022 08:33:42 +0000 (10:33 +0200)] 
detect: config keyword transaction logic fix

When the keyword config:logging disable,type tx is used,
OutputTxLog checks a flag to skip the transaction without logging
it, but AppLayerParserTransactionsCleanup waits for the
transaction to be marked as logged to clean it.

So, OutputTxLog now marks the tx as logged, so that it can
get cleaned away.

Ticket: #5456

2 years agosmb: set defaults for file transfer limits
Victor Julien [Tue, 24 Jan 2023 11:38:21 +0000 (12:38 +0100)] 
smb: set defaults for file transfer limits

Ticket: #5782.

2 years agostream/tcp: fix typos, update copyright year 8430/head
Juliana Fajardini [Thu, 19 Jan 2023 14:21:10 +0000 (11:21 -0300)] 
stream/tcp: fix typos, update copyright year

Bug #5765

2 years agoexceptions: ignore policy if stream.midstream=true
Juliana Fajardini [Thu, 19 Jan 2023 14:18:16 +0000 (11:18 -0300)] 
exceptions: ignore policy if stream.midstream=true

Set the engine to ignore the stream.midstream-policy if stream.midstream
is enabled.

If we had both stream.midstream AND stream.midstream_policy enabled,
this could lead to midstream flows being dropped (or bypassed, or...)
instead of being accepted by the engine, as it was probably meant when
the user enabled midstream flows.

Bug #5765

2 years agoexceptions: add master switch config option
Juliana Fajardini [Tue, 6 Dec 2022 21:29:34 +0000 (18:29 -0300)] 
exceptions: add master switch config option

This allows all traffic Exception Policies to be set from one
configuration point. All exception policy options are available in IPS
mode. Bypass, pass and auto (disabled) are also available in iDS mode

Exception Policies set up individually will overwrite this setup for the
given traffic exception.

Task #5219

2 years agodns: never return error on UDP DNS
Jason Ish [Sun, 15 Jan 2023 16:05:29 +0000 (10:05 -0600)] 
dns: never return error on UDP DNS

UDP parsers should never return error as it should indicate to Suricata
that an unrecoverable error has occurred.  UDP being record based for
the most part is almost always recoverable, at least for protocols like
DNS.

2 years agodns: split header and body parsing
Jason Ish [Wed, 21 Dec 2022 15:35:19 +0000 (09:35 -0600)] 
dns: split header and body parsing

As part of extra header validation, split out DNS body parsing to
avoid the overhead of parsing the header twice.

2 years agodns: validate header on every incoming message
Jason Ish [Wed, 21 Dec 2022 01:30:29 +0000 (19:30 -0600)] 
dns: validate header on every incoming message

As UDP streams getting probed, a stream that does not appear to be DNS
at first, may have a single packet that does look close enough to DNS
to be picked up as DNS causing every subsequent packet to result in a
parser error.

To mitigate this, probe every incoming DNS message header for validity
before continuing onto the body.  If the header doesn't validate as
DNS, just ignore the packet so no parse error is registered.

2 years agodns: parse and alert on invalid opcodes
Jason Ish [Wed, 21 Dec 2022 01:17:38 +0000 (19:17 -0600)] 
dns: parse and alert on invalid opcodes

Accept DNS messages with an invalid opcode that are otherwise
valid. Such DNS message will create a parser event.

This is a change of behavior, previously an invalid opcode would cause
the DNS message to not be detected or parsed as DNS.

Issue: #5444

2 years agogithub-ci: fedora non-root: suricata-verify -q
Jason Ish [Tue, 20 Dec 2022 19:37:58 +0000 (13:37 -0600)] 
github-ci: fedora non-root: suricata-verify -q

Run Suricata-Verify in quiet mode for the non-root build to more
easily find the error when fails.

2 years agodns: rustfmt
Jason Ish [Wed, 21 Dec 2022 15:02:00 +0000 (09:02 -0600)] 
dns: rustfmt

2 years agodns: mark test buffers with rustfmt::skip
Jason Ish [Wed, 21 Dec 2022 15:01:15 +0000 (09:01 -0600)] 
dns: mark test buffers with rustfmt::skip

2 years agolog-pcap: remove early output initializing if offline
Jason Ish [Wed, 18 Jan 2023 18:33:48 +0000 (12:33 -0600)] 
log-pcap: remove early output initializing if offline

Remove early opening of output files if running in an offline mode, as
we don't yet know the timestamp to use.

Prevents the first pcap files being opened with a timestamp of 0,
bringing us back to the same behvaviour of pcap logging in 6.0.

Issue: 5374

2 years agolog-pcap: fix typo in multi-mode error message
Jason Ish [Wed, 18 Jan 2023 17:59:26 +0000 (11:59 -0600)] 
log-pcap: fix typo in multi-mode error message

2 years agolog-pcap: display mininum limit on error
Jason Ish [Wed, 18 Jan 2023 17:45:44 +0000 (11:45 -0600)] 
log-pcap: display mininum limit on error

On fatal error due to limit being less than the allowed minimum,
display the minimum value in bytes.

2 years agoutil-debug: clang-format required change
Lukas Sismis [Wed, 18 Jan 2023 06:33:03 +0000 (13:33 +0700)] 
util-debug: clang-format required change

2 years agorunmodes: Determine engine's copy-mode as early as possible
Lukas Sismis [Wed, 28 Dec 2022 04:49:02 +0000 (11:49 +0700)] 
runmodes: Determine engine's copy-mode as early as possible

Configuration and behavior of HTP app layer depends on the copy
mode of Suricata engine. Copy mode was set after the app layer setup.
Decision of engine's copy mode operation is now made earlier.

Ticket: #5706

2 years agorunmodes: remove misleading commment
Lukas Sismis [Tue, 22 Nov 2022 22:51:45 +0000 (23:51 +0100)] 
runmodes: remove misleading commment

2 years agodpdk: add support for enabling IPS support in DPDK mode
Lukas Sismis [Wed, 19 Oct 2022 21:18:59 +0000 (23:18 +0200)] 
dpdk: add support for enabling IPS support in DPDK mode

2 years agoutil-device: remove unused functions
Lukas Sismis [Wed, 18 Jan 2023 05:32:00 +0000 (12:32 +0700)] 
util-device: remove unused functions

2 years agorunmodes: change function prototype of runmode init functions
Lukas Sismis [Wed, 19 Oct 2022 21:17:49 +0000 (23:17 +0200)] 
runmodes: change function prototype of runmode init functions

Commit contains prototype changes of RunModeSetLiveCaptureAutoFp and
RunModeSetLiveCaptureWorkers functions to move the IPS enable logic
out of suricata.c file.

2 years agodpdk: port deprecated DPDK macros to the newer forms
Lukas Sismis [Thu, 13 Oct 2022 13:12:27 +0000 (15:12 +0200)] 
dpdk: port deprecated DPDK macros to the newer forms

2 years agodpdk: add Github action to build Suricata with all available (LTS) DPDK versions
Lukas Sismis [Wed, 12 Oct 2022 06:23:58 +0000 (08:23 +0200)] 
dpdk: add Github action to build Suricata with all available (LTS) DPDK versions