Skip to contentSkip to conversation

suricata: update 7.0.13 -> 8.0.4

PATCH Superseded Clayton Casciato 1 participant 2 messages Apr 23

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 suricata: update 7.0.13 -> 8.0.4

8.0.0 [1]:
Increased Rust use (including libhtp, suricatactl, and suricatasc) More protocols
Lua sandboxed and available by default

8.0.4 [2]: security, performance, accuracy, and stability fixes

Resolve startup warning [3]:
W: af-packet: eth0: AF_PACKET tpacket-v3 is recommended for non-inline operation

Add "ja4" option for fingerprinting TLS and QUIC clients [4]

CFLAGS modification for (see [5]):
do_package_qa: QA Issue: File /usr/bin/.debug/suricata in package suricata-dbg contains reference to TMPDIR [buildpaths]

SURICATA_LUA_SYS_HEADER_DST [6]

[1] https://suricata.io/2025/07/08/suricata-8-0-0-released/
[2] https://suricata.io/2026/03/17/suricata-8-0-4-and-7-0-15-released/
[3] https://docs.suricata.io/en/suricata-8.0.4/upgrade.html#id1
[4] https://github.com/OISF/suricata/pull/10836
[5] https://git.openembedded.org/openembedded-core/commit/?id=3239961e35434592c06ec2cae2885ab464d35744
[6] https://github.com/OISF/suricata/commit/3a7eef812198118fa0b96059e70074bec5a8cdbe

---
Sponsor: 21SoftWare LLC

v2:
Add PACKAGECONFIG[ja4]
Drop "lua" DEPENDS
Fix SURICATA_LUA_SYS_HEADER_DST

v1: https://lists.yoctoproject.org/g/yocto-patches/topic/meta_security_patch_1_1/118427618

 ...kefile-from-using-its-own-rust-steps.patch |   36 +-
 recipes-ids/suricata/libhtp_0.5.52.bb         |   23 -
 recipes-ids/suricata/suricata-crates.inc      | 3282 +++++++++++++----
 .../{suricata_7.0.13.bb => suricata_8.0.4.bb} |   30 +-
 4 files changed, 2680 insertions(+), 691 deletions(-)
 delete mode 100644 recipes-ids/suricata/libhtp_0.5.52.bb
 rename recipes-ids/suricata/{suricata_7.0.13.bb => suricata_8.0.4.bb} (86%)
recipes-ids/suricata/files/0001-Skip-pkg-Makefile-from-using-its-own-rust-steps.patch +18 -18
index 12cb096..59954aa 100644
@@ -1,6 +1,6 @@
-From a59708a9300df8116867ac77f7829f7fd647325e Mon Sep 17 00:00:00 2001
+From 28ab6ce1da3d095fdcdd66621329d2a204b4fc2e Mon Sep 17 00:00:00 2001
 From: Clayton Casciato <[email protected]>
-Date: Mon, 3 Nov 2025 10:30:26 -0700
+Date: Thu, 19 Mar 2026 21:24:50 -0600
 Subject: [PATCH] Skip pkg Makefile from using its own rust steps
 
 Upstream-Status: Inappropriate [OE Specific]
@@ -13,28 +13,28 @@ Signed-off-by: Clayton Casciato <[email protected]>
  2 files changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/Makefile.am b/Makefile.am
-index d0d3d09..a572912 100644
+index e99cea8..23e4d08 100644
 --- a/Makefile.am
 +++ b/Makefile.am
-@@ -10,7 +10,7 @@ EXTRA_DIST = ChangeLog COPYING LICENSE suricata.yaml.in \
- 	     scripts/generate-images.sh \
- 	     scripts/docs-almalinux9-minimal-build.sh \
- 	     scripts/docs-ubuntu-debian-minimal-build.sh
--SUBDIRS = $(HTP_DIR) rust src qa rules doc contrib etc python ebpf \
-+SUBDIRS = $(HTP_DIR) src qa rules doc contrib etc python ebpf \
+@@ -12,7 +12,7 @@ EXTRA_DIST = ChangeLog COPYING LICENSE suricata.yaml.in \
+ 	     scripts/docs-ubuntu-debian-minimal-build.sh \
+        scripts/evedoc.py \
+ 	     examples/plugins
+-SUBDIRS = rust src plugins qa rules doc etc python ebpf \
++SUBDIRS = src plugins qa rules doc etc python ebpf \
            $(SURICATA_UPDATE_DIR)
- 
- CLEANFILES = stamp-h[0-9]*
+ DIST_SUBDIRS = $(SUBDIRS) examples/lib/simple examples/lib/custom \
+ 		examples/lib/live
 diff --git a/Makefile.in b/Makefile.in
-index 7a89353..3864613 100644
+index a27d8b7..4bd2fc8 100644
 --- a/Makefile.in
 +++ b/Makefile.in
-@@ -428,7 +428,7 @@ EXTRA_DIST = ChangeLog COPYING LICENSE suricata.yaml.in \
- 	     scripts/docs-almalinux9-minimal-build.sh \
- 	     scripts/docs-ubuntu-debian-minimal-build.sh
+@@ -430,7 +430,7 @@ EXTRA_DIST = ChangeLog COPYING LICENSE suricata.yaml.in \
+        scripts/evedoc.py \
+ 	     examples/plugins
  
--SUBDIRS = $(HTP_DIR) rust src qa rules doc contrib etc python ebpf \
-+SUBDIRS = $(HTP_DIR) src qa rules doc contrib etc python ebpf \
+-SUBDIRS = rust src plugins qa rules doc etc python ebpf \
++SUBDIRS = src plugins qa rules doc etc python ebpf \
            $(SURICATA_UPDATE_DIR)
  
- CLEANFILES = stamp-h[0-9]*
+ DIST_SUBDIRS = $(SUBDIRS) examples/lib/simple examples/lib/custom \
recipes-ids/suricata/libhtp_0.5.52.bb deleted +0 -23
deleted file mode 100644
index f5e7138..0000000
@@ -1,23 +0,0 @@
-SUMMARY = "LibHTP is a security-aware parser for the HTTP protocol and the related bits and pieces."
-
-require suricata.inc
-
-LIC_FILES_CHKSUM = "file://LICENSE;beginline=1;endline=2;md5=596ab7963a1a0e5198e5a1c4aa621843"
-
-SRC_URI = "git://github.com/OISF/libhtp.git;protocol=https;branch=0.5.x"
-SRCREV = "314ca7360e141a1e40be58707b3abeefe32258c9"
-
-DEPENDS = "zlib"
-
-inherit autotools-brokensep pkgconfig
-
-CFLAGS += "-D_DEFAULT_SOURCE"
-
-do_configure () {
-    cd ${S}
-    ./autogen.sh
-    oe_runconf
-}
-
-RDEPENDS:${PN} += "zlib"
-
recipes-ids/suricata/suricata-crates.inc +2645 -637

2,925 lines not on this page · raw message

recipes-ids/suricata/suricata_8.0.4.bb renamed from recipes-ids/suricata/suricata_7.0.13.bb +17 -13
similarity index 86%
rename from recipes-ids/suricata/suricata_7.0.13.bb
rename to recipes-ids/suricata/suricata_8.0.4.bb
index 936c057..3e1734e 100644

Lines of this file are not shown. View the raw message.

The rest of this diff is not shown. View the raw message.

Part of the diff is not shown here. View the raw message.

#1 lore raw
Quoted 6 lines

It looks like the Lua 5.5.0 upgrade in oe-core has non-trivially broken the 8.0.x suricata build. There's a somewhat straightforward issue with a new argument to lua_newstate, but after that there are link errors that the more I poked around the more I'm thinking there's some oddness wrt their vendoring a copy of Lua (5.4.8) for the Rust side of things. I don't see any signs of the build process for the .c files under src

Quoted 8 lines

pointing at that source, but then AFAICT everything kind of gets lumped together when linking the final suricata binary... If you have the time to try to untangle this, please do so, as I cannot guarantee that I get to it in the next week or two.
@
Thanks,
@
Scott

Thanks for the hint, Scott!

It appears an external Lua implementation is not required at build time.

I instead configured a variable ("SURICATA_LUA_SYS_HEADER_DST") for v2:
https://lists.yoctoproject.org/g/yocto-patches/topic/meta_security_patch_v2_0_1/118966848
https://lists.yoctoproject.org/g/yocto-patches/topic/meta_security_patch_v2_1_1/118966849

Clayton Casciato