]> git.ipfire.org Git - thirdparty/suricata.git/log
thirdparty/suricata.git
4 months agoaf-packet: use actual snaplen in bpf 12783/head
Victor Julien [Wed, 19 Mar 2025 06:03:01 +0000 (07:03 +0100)] 
af-packet: use actual snaplen in bpf

Avoids setting a 0 snaplen in BPF, leading to an error.

Fixes: b8b6ed550a6f ("af-packet: delay setting default-packet-size for af-packet")
Ticket: #7618.

4 months agodatasets: work around scan-build warning
Victor Julien [Tue, 18 Mar 2025 21:26:53 +0000 (22:26 +0100)] 
datasets: work around scan-build warning

datasets.c:493:27: warning: Dereference of null pointer [core.NullDereference]
  493 |     DEBUG_VALIDATE_BUG_ON(set->hash->config.hash_size != hashsize);
      |                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~
./util-validate.h:95:44: note: expanded from macro 'DEBUG_VALIDATE_BUG_ON'
   95 | #define DEBUG_VALIDATE_BUG_ON(exp) BUG_ON((exp))
      |                                            ^~~
./suricata-common.h:307:36: note: expanded from macro 'BUG_ON'
  307 |         #define BUG_ON(x) assert(!(x))
      |                                    ^
/usr/include/assert.h:109:7: note: expanded from macro 'assert'
  109 |     ((expr)                                                             \
      |       ^~~~
1 warning generated.

4 months agodoc: explain priority port setting
Shivani Bhardwaj [Tue, 25 Feb 2025 06:30:36 +0000 (12:00 +0530)] 
doc: explain priority port setting

Ticket 7329

4 months agodoc: format and align suricata.yaml section
Shivani Bhardwaj [Tue, 25 Feb 2025 06:07:12 +0000 (11:37 +0530)] 
doc: format and align suricata.yaml section

4 months agoupgrade: list inspection recursion default limit
Juliana Fajardini [Mon, 17 Mar 2025 15:54:49 +0000 (08:54 -0700)] 
upgrade: list inspection recursion default limit

As the yaml indicated before that if no value was specified there were
no limits, and now there will be one.

4 months agodoc/upgrade: add datasets hash size limit note
Juliana Fajardini [Mon, 17 Mar 2025 15:52:20 +0000 (08:52 -0700)] 
doc/upgrade: add datasets hash size limit note

4 months agodetect: add configurable limits for datasets
Philippe Antoine [Tue, 18 Mar 2025 09:55:39 +0000 (10:55 +0100)] 
detect: add configurable limits for datasets

Ticket: 7615

Avoids signatures setting extreme hash sizes, which would lead to very
high memory use.

Default to allowing:
- 65536 per dataset
16777216 total

To override these built-in defaults:

```yaml
datasets:
  # Limits for per rule dataset instances to avoid rules using too many
  # resources.
  limits:
    # Max value for per dataset `hashsize` setting
    #single-hashsize: 65536
    # Max combined hashsize values for all datasets.
    #total-hashsizes: 16777216
```

4 months agodatasets: improve default hashsize handling
Victor Julien [Tue, 18 Mar 2025 09:55:39 +0000 (10:55 +0100)] 
datasets: improve default hashsize handling

Make hashsize default local to dataset code, instead of relying on the
thash code.

Use the same default value as before.

4 months agodoc/userguide: af-packet upgrade notes
Jason Ish [Mon, 17 Mar 2025 15:35:16 +0000 (09:35 -0600)] 
doc/userguide: af-packet upgrade notes

Add note about increased block size and how to change it back to old
defaults if needed.

Ticket: #7458

4 months agoaf-packet: delay setting default-packet-size for af-packet
Jason Ish [Mon, 17 Mar 2025 16:35:57 +0000 (10:35 -0600)] 
af-packet: delay setting default-packet-size for af-packet

AF_PACKET needs more information about its configuration before we can
set the default packet size, so on startup, leave unset in suricata.c
if in AF_PACKET mode.

If defrag is enabled, use a default packet size of 9k for tpacket-v2.
This can still lead to truncation events, then the user can increase
their 'default-packet-size'.

Tpacket-v3 does not need an increased packet size as it will handle
any size of packet that is smaller than the configured block size
which now has a default of 128k.

9k for the snap is somewhat arbitrary but is large enough for the
common 9000 jumbo frame plus some extra headers including tpacket
headers.

Ticket: #7458

4 months agoaf-packet: warn that tpacket-v3 is better for non-inline usage
Jason Ish [Thu, 13 Mar 2025 18:14:26 +0000 (12:14 -0600)] 
af-packet: warn that tpacket-v3 is better for non-inline usage

Ticket: #7458

4 months agoaf-packet: add event for packets truncated by af-packet
Jason Ish [Thu, 13 Mar 2025 16:36:08 +0000 (10:36 -0600)] 
af-packet: add event for packets truncated by af-packet

Ticket: #7458

4 months agoaf-packet: warn if v3 block size is not large enough for defrag
Jason Ish [Wed, 12 Mar 2025 22:20:38 +0000 (16:20 -0600)] 
af-packet: warn if v3 block size is not large enough for defrag

If using tpacket-v3 and defrag, warn if the block size is not large
enough for a fully defragmented packet.

Ticket: #7458

4 months agoaf-packet: warn if v2 block size not large enough for defrag
Jason Ish [Wed, 12 Mar 2025 22:13:40 +0000 (16:13 -0600)] 
af-packet: warn if v2 block size not large enough for defrag

If using tpacket-v2, defrag and a user provided v2-block-size, warn if
the block size is not large enough to hold one fully defragmented
packet.

Ticket: #7458

4 months agoaf-packet: make tpacket-v2 block size configurable
Jason Ish [Wed, 12 Mar 2025 21:58:43 +0000 (15:58 -0600)] 
af-packet: make tpacket-v2 block size configurable

With the change of the default tpacket-v2 block size from 32k to 128k,
allow it to be configurable for users who may want to make it larger,
or revert it back to the pre 7.0.9 default of 32k.

Ticket: #7458

4 months agoaf-packet: increase default block size
Jason Ish [Wed, 12 Mar 2025 21:56:40 +0000 (15:56 -0600)] 
af-packet: increase default block size

Increase the default block size from 32k to 128k. This allows for a
fully defragmented packet to fit in the buffer.

Ticket: #7458

4 months agoaf-packet: warn if defrag not suitable for mode
Jason Ish [Wed, 12 Mar 2025 18:34:31 +0000 (12:34 -0600)] 
af-packet: warn if defrag not suitable for mode

AF_PACKET defrag should not be used for inline modes. Its possible that
a packet received could be larger than can be set when defrag is
enabled, so warn if disabled for inline use.

Likewise, warn if defrag is disabled for IDS use, or non-inline mode.

Ticket: #7458

4 months agoaf-packet: check defrag value even if cluster-type not set
Jason Ish [Wed, 12 Mar 2025 18:31:08 +0000 (12:31 -0600)] 
af-packet: check defrag value even if cluster-type not set

If cluster-type was not set we default to "cluster_flow" with defrag
always on. Instead check for defrag value and disable defrag if disabled
by the user.

Ticket: #7458

4 months agodetect: limit base64_decode `bytes` to 64KiB
Philippe Antoine [Tue, 17 Dec 2024 14:06:25 +0000 (15:06 +0100)] 
detect: limit base64_decode `bytes` to 64KiB

Ticket: 7613

Avoids potential large per-thread memory allocation. A buffer with the
size of the largest decode_base64 buffer size setting would be allocated
per thread. As this was a u32, it could mean a per-thread 4GiB memory
allocation.

64KiB was already the built-in default for cases where bytes size wasn't
specified.

4 months agodetect: non infinite default value for inspection-recursion-limit
Philippe Antoine [Thu, 20 Feb 2025 22:40:08 +0000 (23:40 +0100)] 
detect: non infinite default value for inspection-recursion-limit

So that empty config are protected by this setting as was intended.

Set to unlimited for fuzz testing.

4 months agodetect/pcre: avoid infinite loop after negated pcre
Philippe Antoine [Tue, 28 Jan 2025 14:02:45 +0000 (15:02 +0100)] 
detect/pcre: avoid infinite loop after negated pcre

Ticket: 7526

The usage of negated pcre, followed by other relative payload
content keywords could lead to an infinite loop.

This is because regular (not negated) pcre can test multiple
occurences, but negated pcre should be tried only once.

4 months agorust: pin once_cell to work with Rust 1.67.1 12752/head 12757/head
Jason Ish [Tue, 11 Mar 2025 12:16:28 +0000 (06:16 -0600)] 
rust: pin once_cell to work with Rust 1.67.1

Clap uses once_cell which recently released v1.20 which updated its
MSRV to 1.70. Locally pin once_cell to 1.20.3 to maintain our MSRV.

4 months agopcap: skip pcap-config if pkgconfig in use 12749/head
Victor Julien [Mon, 10 Mar 2025 09:01:04 +0000 (10:01 +0100)] 
pcap: skip pcap-config if pkgconfig in use

4 months agodetect/action: minor action parsing cleanup
Victor Julien [Thu, 27 Feb 2025 11:21:50 +0000 (12:21 +0100)] 
detect/action: minor action parsing cleanup

Preparation for explicit action scope parsing.

4 months agodetect/loader: minor code cleanup
Victor Julien [Wed, 26 Feb 2025 10:38:21 +0000 (11:38 +0100)] 
detect/loader: minor code cleanup

4 months agodetect: constify rule file and lines in parsing and analyzer
Victor Julien [Wed, 26 Feb 2025 10:37:54 +0000 (11:37 +0100)] 
detect: constify rule file and lines in parsing and analyzer

4 months agotls: fix handshake handling being too strict
Victor Julien [Fri, 17 Jan 2025 06:00:51 +0000 (07:00 +0100)] 
tls: fix handshake handling being too strict

e.g. server hello done has no data

4 months agoapp-layer: constify AppLayerGetProtoByName
Victor Julien [Mon, 13 Jan 2025 19:46:58 +0000 (20:46 +0100)] 
app-layer: constify AppLayerGetProtoByName

4 months agodetect/tls: don't double register tls_validity generic list
Victor Julien [Thu, 13 Feb 2025 09:32:32 +0000 (10:32 +0100)] 
detect/tls: don't double register tls_validity generic list

4 months agodetect/nfs: don't double register nfs_request generic list
Victor Julien [Mon, 27 Jan 2025 10:17:34 +0000 (11:17 +0100)] 
detect/nfs: don't double register nfs_request generic list

4 months agodetect: don't register duplicate app inspect engines
Victor Julien [Mon, 27 Jan 2025 09:55:46 +0000 (10:55 +0100)] 
detect: don't register duplicate app inspect engines

4 months agodetect/analyzer: add policy
Victor Julien [Thu, 25 May 2023 08:37:05 +0000 (10:37 +0200)] 
detect/analyzer: add policy

Example output:

    "match_policy": {
        "actions": [
            "alert",
            "drop"
        ],
        "scope": "flow"
    },

4 months agosmtp/events: set direction on rules
Victor Julien [Sat, 15 Feb 2025 10:23:44 +0000 (11:23 +0100)] 
smtp/events: set direction on rules

Several rules matched on both directions even if events are set in a single direction.

4 months agogithub-ci: don't run builds on PR if only docs changed
Jason Ish [Sun, 9 Mar 2025 09:27:18 +0000 (10:27 +0100)] 
github-ci: don't run builds on PR if only docs changed

4 months agogithub-ci: stop caching system packages
Jason Ish [Sun, 9 Mar 2025 09:19:28 +0000 (10:19 +0100)] 
github-ci: stop caching system packages

4 months agolua: remove script_api_ver 12747/head
Victor Julien [Sun, 9 Mar 2025 19:19:53 +0000 (20:19 +0100)] 
lua: remove script_api_ver

Not documented and never set to new values despite updates.

Ticket: #7492.

4 months agocontrib: remove suri-graphite
Victor Julien [Sun, 9 Mar 2025 14:07:57 +0000 (15:07 +0100)] 
contrib: remove suri-graphite

Built for py2.

Remove now empty contrib dir.

Ticket: #6888.

4 months agocontrib: remove file_processor
Victor Julien [Sun, 9 Mar 2025 14:02:23 +0000 (15:02 +0100)] 
contrib: remove file_processor

Has been developed for a now obsolete file log format.

Ticket: #6888.

4 months agodetect/dcerpc.iface: remove commented out unittest
Victor Julien [Sun, 9 Mar 2025 13:54:16 +0000 (14:54 +0100)] 
detect/dcerpc.iface: remove commented out unittest

4 months agoeve/schema: map tls fields to keywords
Victor Julien [Fri, 7 Mar 2025 16:42:04 +0000 (17:42 +0100)] 
eve/schema: map tls fields to keywords

4 months agoschema: add rule keyword mapping for dcerpc
Shivani Bhardwaj [Fri, 7 Mar 2025 11:06:56 +0000 (16:36 +0530)] 
schema: add rule keyword mapping for dcerpc

4 months agouserguide/header-keywords: fix typos, adjust format
Juliana Fajardini [Mon, 17 Feb 2025 15:58:53 +0000 (12:58 -0300)] 
userguide/header-keywords: fix typos, adjust format

4 months agodoc/rule-types: remove trailing underscore
Juliana Fajardini [Mon, 17 Feb 2025 15:26:39 +0000 (12:26 -0300)] 
doc/rule-types: remove trailing underscore

And other minor fixes that were overseen.

4 months agouserguide/suricatactl: use suricata community page
Juliana Fajardini [Fri, 7 Mar 2025 08:31:58 +0000 (05:31 -0300)] 
userguide/suricatactl: use suricata community page

We were mentioning "Suricata Support" page, which could be a bit
misleading -- and also used a link that is actually redirected to the
Suricata Community page, anyways.

4 months agogithub-ci: pin rust version for clippy tests 12743/head
Jason Ish [Sat, 8 Mar 2025 16:12:50 +0000 (17:12 +0100)] 
github-ci: pin rust version for clippy tests

Prevents CI breakage after a new Rust release until we're ready to make
the changes.

4 months agogithub-ci: update rpm builder to fedora 41
Jason Ish [Thu, 6 Mar 2025 13:49:25 +0000 (14:49 +0100)] 
github-ci: update rpm builder to fedora 41

4 months agogithub-ci: update Fedora non-root build to Fedora 41
Jason Ish [Thu, 6 Mar 2025 13:48:09 +0000 (14:48 +0100)] 
github-ci: update Fedora non-root build to Fedora 41

4 months agogithub-ci: remove fedora 40 builds where 41 exists
Jason Ish [Thu, 6 Mar 2025 13:46:48 +0000 (14:46 +0100)] 
github-ci: remove fedora 40 builds where 41 exists

Remove Fedora 40 builds where there is a Fedora 41 equivalent.

4 months agoeve-parity: merge $ref props into current object
Jason Ish [Fri, 7 Mar 2025 17:05:05 +0000 (18:05 +0100)] 
eve-parity: merge $ref props into current object

Allows for a "suricata" entry along with a "$ref".

4 months agoeve-parity: handle arrays of scalars
Jason Ish [Fri, 7 Mar 2025 16:55:50 +0000 (17:55 +0100)] 
eve-parity: handle arrays of scalars

And add an example with "client_alpns".

4 months agorust: Update sawp dependencies to 0.13.1 due to SPDX license compatibility.
Bryan Benson [Wed, 8 Jan 2025 17:54:06 +0000 (09:54 -0800)] 
rust: Update sawp dependencies to 0.13.1 due to SPDX license compatibility.

4 months agodetect/lua: Fix max value displayed in error msg
Jeff Lucovsky [Wed, 8 Jan 2025 14:27:10 +0000 (09:27 -0500)] 
detect/lua: Fix max value displayed in error msg

This commit corrects an error message displayed when the key length is
out of range.

4 months agovar: Use 16-bit container for type
Jeff Lucovsky [Fri, 1 Nov 2024 14:45:56 +0000 (10:45 -0400)] 
var: Use 16-bit container for type

Issue: 6855: Match sigmatch type field in var and bit structs

Align the size and datatype of type, idx, and next members across:
- FlowVarThreshold
- FlowBit
- FlowVar
- GenericVar
- XBit
- DetectVarList

Note that the FlowVar structure has been intentionally constrained to
match the structure size prior to this commit. To achieve this, the
keylen member was restricted to 8 bits after it was confirmed its value
is checked against a max of 0xff.

4 months agodetect: delay tx cleanup in some edge case 12730/head
Philippe Antoine [Tue, 25 Feb 2025 09:54:13 +0000 (10:54 +0100)] 
detect: delay tx cleanup in some edge case

Ticket: 7552

f->sgh_toserver may be NULL but because FLOW_SGH_TOSERVER is unset
and thus, we want to delay cleanup until detection has really been
run with the right signature group head.

This may happen for a rule using
`alert tcp any any -> any any` and
a app-layer keyword to client
with a app-layer supporting both udp and tcp
with stream.midstream=true
and with the first packet of a flow being a server response

In this case, we swap the flow and reset its signature group heads

4 months agodetect: reset signature groups when reversing flow
Philippe Antoine [Tue, 25 Feb 2025 09:49:41 +0000 (10:49 +0100)] 
detect: reset signature groups when reversing flow

Ticket: 7552

When we use midstream, and the first packet we see of a flow is
a response from server, and we want to match on some signature
to client :
- we had first set sgh_toserver/FLOW_SGH_TOSERVER as we first
  thought this was a packet to server
- we then swap/reverse the flow, so sgh_toclient becomes sgh_toserver
  but it contains signatures to server and cannot match our
  to_client signature

The detect engine with DetectRunSetup will set again the
signatures group heads properly

4 months agoeve-parity: skip transform keywords 12717/head
Jason Ish [Fri, 21 Feb 2025 20:58:47 +0000 (14:58 -0600)] 
eve-parity: skip transform keywords

4 months agoschema: mark dns.version and dns.grouped as having no keywords
Jason Ish [Thu, 20 Feb 2025 22:13:03 +0000 (16:13 -0600)] 
schema: mark dns.version and dns.grouped as having no keywords

4 months agoschema: mark "stats" and "drop" as having no keywords
Jason Ish [Thu, 20 Feb 2025 22:05:03 +0000 (16:05 -0600)] 
schema: mark "stats" and "drop" as having no keywords

4 months agodetect-dns-response: remove unit tests
Jason Ish [Thu, 20 Feb 2025 18:05:44 +0000 (12:05 -0600)] 
detect-dns-response: remove unit tests

Should have coverage by S-V now.

4 months agoscript/eve-parity: add script for checking eve/keyword parity
Jason Ish [Wed, 19 Feb 2025 22:36:57 +0000 (16:36 -0600)] 
script/eve-parity: add script for checking eve/keyword parity

Currently this script has two commands: "missing" and "having".

"missing" will show eve fields that do not map to any keywords.

"having" will sohw eve fields along with their keyword mappsings,
while also validating that those keywords really exist.

Related to tickets: #6463, #4772

4 months agoschema: add an object for mapping fields to keywords
Jason Ish [Wed, 19 Feb 2025 22:34:22 +0000 (16:34 -0600)] 
schema: add an object for mapping fields to keywords

To some EVE fields and a "suricata" object that contains an array of
keywords. These are the keywords that map directly to this field, or
somehow cover this field.

This is an attempt at tooling to help with EVE and keyword parity.

Related to tickets: #5642, #6463, #4772

4 months agodns: add keywords for additionals and authorities rrnames
Jason Ish [Tue, 28 Jan 2025 23:21:00 +0000 (17:21 -0600)] 
dns: add keywords for additionals and authorities rrnames

Add keywords dns.additionals.rrname and dns.authorities.rrname. Along
the way, consolidate dns.query.name and dns.answer.name into a single file
and register them altogether since there is a lot of common code.

4 months agodetect: split new keyword id from registration
Jason Ish [Fri, 17 Jan 2025 20:46:07 +0000 (14:46 -0600)] 
detect: split new keyword id from registration

Split DetectHelperKeywordRegister into 2 functions, one for acquiring
a new keyword ID, and another to perform the registration.

This makes it easier to do the traditional C keyword initialization
with a dynamic ID.

4 months agodns: refactor function to get rrname to be safe
Jason Ish [Tue, 28 Jan 2025 22:34:07 +0000 (16:34 -0600)] 
dns: refactor function to get rrname to be safe

Make the function safe by returning a reference to the DNSName object,
the unsafe C wrapper can do the conversion to pointers.

4 months agodetect-dns-response: disable clang-format around byte arrays
Jason Ish [Tue, 28 Jan 2025 22:19:37 +0000 (16:19 -0600)] 
detect-dns-response: disable clang-format around byte arrays

These arrays are manually formatted for readability.

4 months agodns: rename dns.response keyword to dns.response.rrname
Jason Ish [Tue, 28 Jan 2025 22:15:00 +0000 (16:15 -0600)] 
dns: rename dns.response keyword to dns.response.rrname

This is a better name as the keyword is looking at all rrname type
fields in the response.

4 months agodoc/userguide: document dns.response
Nathan Scrivens [Tue, 20 Aug 2024 02:45:02 +0000 (22:45 -0400)] 
doc/userguide: document dns.response

Feature: 7012

4 months agodns: add dns.response sticky buffer
Nathan Scrivens [Mon, 19 Aug 2024 18:01:21 +0000 (14:01 -0400)] 
dns: add dns.response sticky buffer

Feature: 7012
Add dns.response sticky buffer to match on dns response fields.
Add rust functions to return dns response packet data.
Unit tests verifying signature matching.

4 months agofiles: append data on closing even with FILE_NOSTORE
Philippe Antoine [Tue, 4 Mar 2025 15:30:19 +0000 (16:30 +0100)] 
files: append data on closing even with FILE_NOSTORE

Ticket: 7577

When HTTP1 post multipart handles a small file, it will call
HTPFileClose with some data
This data needs to be appended to the streaming buffer for usage
by file.data keyword even if we do not end up storing the file

4 months agodetect: add ldap.responses.message
Alice Akaki [Tue, 11 Feb 2025 08:20:33 +0000 (04:20 -0400)] 
detect: add ldap.responses.message

ldap.responses.message matches on LDAPResult error message
This keyword maps the following eve fields:
ldap.responses[].bind_response.message
ldap.responses[].search_result_done.message
ldap.responses[].modify_response.message
ldap.responses[].add_response.message
ldap.responses[].del_response.message
ldap.responses[].mod_dn_response.message
ldap.responses[].compare_response.message
ldap.responses[].extended_response.message
It is a sticky buffer
Supports prefiltering

Ticket: #7532

4 months agodetect: add ldap.responses.result_code
Alice Akaki [Thu, 6 Feb 2025 06:07:05 +0000 (02:07 -0400)] 
detect: add ldap.responses.result_code

ldap.responses.result_code matches on LDAP result code
This keyword maps the following eve fields:
ldap.responses[].bind_response.result_code
ldap.responses[].search_result_done.result_code
ldap.responses[].modify_response.result_code
ldap.responses[].add_response.result_code
ldap.responses[].del_response.result_code
ldap.responses[].mod_dn_response.result_code
ldap.responses[].compare_response.result_code
ldap.responses[].extended_response.result_code
It is an unsigned 32-bit integer
Doesn't support prefiltering

Ticket: #7532

4 months agoldap: create a generic funtion to match integer responses
Alice Akaki [Thu, 27 Feb 2025 23:38:07 +0000 (19:38 -0400)] 
ldap: create a generic funtion to match integer responses

4 months agoldap: refactor function aux_ldap_parse_protocol_resp_op
Alice Akaki [Thu, 20 Feb 2025 22:32:35 +0000 (18:32 -0400)] 
ldap: refactor function aux_ldap_parse_protocol_resp_op

Split code to create a generic function that parses LdapIndex

4 months agoldap: rename DetectLdapRespData struct to be more specific
Alice Akaki [Mon, 10 Feb 2025 15:56:23 +0000 (11:56 -0400)] 
ldap: rename DetectLdapRespData struct to be more specific

4 months agoldap: return empty buffer in ldap_tx_get_responses_dn
Alice Akaki [Mon, 3 Mar 2025 22:52:39 +0000 (18:52 -0400)] 
ldap: return empty buffer in ldap_tx_get_responses_dn

Funciton ldap_tx_get_responses_dn returns empty buffer in case
the response doesn't contain the distinguished name field

Fixes: 73ae6e997f6c ("detect: add ldap.responses.dn")
4 months agoldap: fix LDAPDN nits
Alice Akaki [Fri, 28 Feb 2025 00:09:17 +0000 (20:09 -0400)] 
ldap: fix LDAPDN nits

Change variable name 'req' to 'resp' in function ldap_tx_get_responses_dn and documentation nits

Fixes:
73ae6e997f6c ("detect: add ldap.responses.dn")
16dcee46fc8a ("detect: add ldap.request.dn")

4 months agoldap: apply rustfmt
Alice Akaki [Mon, 3 Mar 2025 22:57:41 +0000 (18:57 -0400)] 
ldap: apply rustfmt

Fixes: 4554c4778d67 ("rust: use AppProto from generated bindings instead of duplicating")
4 months agoci: fix clusterfuzzlite build 12711/head 12712/head
Philippe Antoine [Tue, 4 Mar 2025 10:11:58 +0000 (11:11 +0100)] 
ci: fix clusterfuzzlite build

5 months agogithub-actions: bump actions/upload-artifact from 4.6.0 to 4.6.1 12706/head
dependabot[bot] [Sat, 1 Mar 2025 19:22:33 +0000 (19:22 +0000)] 
github-actions: bump actions/upload-artifact from 4.6.0 to 4.6.1

Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4.6.0 to 4.6.1.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08...4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
5 months agogithub-actions: bump codecov/codecov-action from 5.3.1 to 5.4.0
dependabot[bot] [Sat, 1 Mar 2025 19:22:31 +0000 (19:22 +0000)] 
github-actions: bump codecov/codecov-action from 5.3.1 to 5.4.0

Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 5.3.1 to 5.4.0.
- [Release notes](https://github.com/codecov/codecov-action/releases)
- [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/codecov/codecov-action/compare/13ce06bfc6bbe3ecf90edbbf1bc32fe5978ca1d3...0565863a31f2c772f9f0395002a31e3f06189574)

---
updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
5 months agogithub-actions: bump github/codeql-action from 3.28.8 to 3.28.10
dependabot[bot] [Sat, 1 Mar 2025 19:22:28 +0000 (19:22 +0000)] 
github-actions: bump github/codeql-action from 3.28.8 to 3.28.10

Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.28.8 to 3.28.10.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Commits](https://github.com/github/codeql-action/compare/v3.28.8...v3.28.10)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
5 months agogithub-actions: bump actions/download-artifact from 4.1.8 to 4.1.9
dependabot[bot] [Sat, 1 Mar 2025 19:22:13 +0000 (19:22 +0000)] 
github-actions: bump actions/download-artifact from 4.1.8 to 4.1.9

Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 4.1.8 to 4.1.9.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/fa0a91b85d4f404e444e00e005971372dc801d16...cc203385981b70ca67e1cc392babf9cc229d5806)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
5 months agogithub-actions: bump ossf/scorecard-action from 2.4.0 to 2.4.1 12701/head
dependabot[bot] [Sat, 1 Mar 2025 19:22:11 +0000 (19:22 +0000)] 
github-actions: bump ossf/scorecard-action from 2.4.0 to 2.4.1

Bumps [ossf/scorecard-action](https://github.com/ossf/scorecard-action) from 2.4.0 to 2.4.1.
- [Release notes](https://github.com/ossf/scorecard-action/releases)
- [Changelog](https://github.com/ossf/scorecard-action/blob/main/RELEASE.md)
- [Commits](https://github.com/ossf/scorecard-action/compare/62b2cac7ed8198b15735ed49ab1e5cf35480ba46...f49aabe0b5af0936a0987cfb85d86b75731b0186)

---
updated-dependencies:
- dependency-name: ossf/scorecard-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
5 months agomqtt: naming and visibility cleanups 12693/head
Jason Ish [Thu, 27 Feb 2025 21:23:25 +0000 (15:23 -0600)] 
mqtt: naming and visibility cleanups

- remove rs_prefix, replace with SC if needed
- remove pub and no_mangle where not needed
- remove some unused functions and fields

Related to ticket: #7498

5 months agoenip: remove rs_ prefix
Jason Ish [Thu, 27 Feb 2025 21:14:38 +0000 (15:14 -0600)] 
enip: remove rs_ prefix

Related to ticket: #7498

5 months agodcerpc: visibility and naming cleanups
Jason Ish [Thu, 27 Feb 2025 21:09:12 +0000 (15:09 -0600)] 
dcerpc: visibility and naming cleanups

- replace rs_ prefixed names with SC
- remove no_mangle and pub where not needed
- remove some unused functions

Related to ticket: #7498

5 months agobittorrent: no_mangle, pub and naming cleanups
Jason Ish [Thu, 27 Feb 2025 17:30:07 +0000 (11:30 -0600)] 
bittorrent: no_mangle, pub and naming cleanups

- Remove rs_prefix
- Remove no_mangle and pub when not needed

Related to ticket: #7498

5 months agorust: use CBINDGEN variable and not "cbindgen"
Jason Ish [Thu, 27 Feb 2025 17:05:26 +0000 (11:05 -0600)] 
rust: use CBINDGEN variable and not "cbindgen"

This uses the cbindgen found during ./configure, and not the one
found on the path during "make", which while often the same, aren't
always the same.

Ticket: #6384

5 months agogithub-ci: re-enable RPM builds
Jason Ish [Thu, 27 Feb 2025 16:02:23 +0000 (10:02 -0600)] 
github-ci: re-enable RPM builds

The RPM has been updated to handle the conversion of suricatasc and
suricatactl to Rust.

Also fixes the "if" expression to prevent one job running both upload
sections.

5 months agoapplayer/ftp: Misc cleanup 12687/head
Jeff Lucovsky [Thu, 27 Feb 2025 16:49:05 +0000 (11:49 -0500)] 
applayer/ftp: Misc cleanup

Issue: 4082

Small fixups.

5 months agoapplayer/ftp: Move MPM declaration
Jeff Lucovsky [Thu, 27 Feb 2025 16:48:16 +0000 (11:48 -0500)] 
applayer/ftp: Move MPM declaration

This commit moves the MPM fn declaration into core.rs making it
available for other Rust modules.

Issue: 4082

5 months agoapp-layer/ftp: Fixup state values
Jeff Lucovsky [Thu, 27 Feb 2025 16:41:53 +0000 (11:41 -0500)] 
app-layer/ftp: Fixup state values

Issue: 4082

Fixup the incorrect state values -- they should be the default enum
values to match the pre-Rust implementation.

5 months agogithub-ci: skip rpm builds for now 12685/head
Jason Ish [Tue, 25 Feb 2025 16:53:44 +0000 (10:53 -0600)] 
github-ci: skip rpm builds for now

RPMs will need to be fixed after merge.

5 months agogithub-ci: add var to disable rpm builds
Jason Ish [Tue, 11 Feb 2025 23:09:23 +0000 (17:09 -0600)] 
github-ci: add var to disable rpm builds

There will be changes in our development branch that the RPMs need to
adapt to, but that can't be done until the changes have been merged to
master, then the RPM can catchup.

This gives us a single variable to turn off RPM building.

5 months agodoc: add upgrade note about suricatasc and suricatactl
Jason Ish [Mon, 10 Feb 2025 22:09:23 +0000 (16:09 -0600)] 
doc: add upgrade note about suricatasc and suricatactl

5 months agodist: include generate-evedoc.sh
Jason Ish [Mon, 10 Feb 2025 21:21:20 +0000 (15:21 -0600)] 
dist: include generate-evedoc.sh

Without this script `make distcheck` fails on a system with
documentation tooling installed, as its required to build the EVE
appendix.

5 months agogithub-ci: add check for update to date Cargo.lock.in
Jason Ish [Mon, 10 Feb 2025 19:47:57 +0000 (13:47 -0600)] 
github-ci: add check for update to date Cargo.lock.in

After a build, check if Cargo.lock.in and Cargo.lock differ, if so,
Cargo.lock.in needs an update as part of a depedency update.

5 months agodoc: remove python references related to suricatasc
Jason Ish [Thu, 6 Feb 2025 21:12:39 +0000 (15:12 -0600)] 
doc: remove python references related to suricatasc

These should probably be removed even without the rewrite, and
suricatasc has been installed as a proper program for many releases.

5 months agoqa: fix suricatasc path
Jason Ish [Sun, 22 Dec 2024 16:46:28 +0000 (10:46 -0600)] 
qa: fix suricatasc path

5 months agopython: remove python implementation of suricatasc/suricatactl
Jason Ish [Thu, 16 Nov 2023 22:19:23 +0000 (16:19 -0600)] 
python: remove python implementation of suricatasc/suricatactl