eBPF-based security platform
testing: fuzz the Beefile parser
Daniel Borkmanna7e1e1f4d0c2
diff --git a/Makefile.shirudo b/Makefile.shirudoindex 00328eb2..44782e03 100644--- a/Makefile.shirudo+++ b/Makefile.shirudo@@ -701,6 +701,10 @@ testing/fuzz/fuzz-bpm-tar: testing/fuzz/fuzz-bpm-tar.c $(FUZZ_BASE) \$(FUZZ_PACKAGE)testing/fuzz/fuzz-bpm-package: testing/fuzz/fuzz-bpm-package.c $(FUZZ_BASE) \$(FUZZ_PACKAGE)+testing/fuzz/fuzz-beefile: testing/fuzz/fuzz-beefile.c $(FUZZ_BASE) \+ tools/shirudo-build/bpm-build.c util/upatch.c \+ util/timefmt.c util/paths.c util/crypto_openssl.c \+ util/io.c util/version_id.ctesting/fuzz/fuzz-oci-http: testing/fuzz/fuzz-oci-http.c $(FUZZ_BASE) \$(FUZZ_OCI)testing/fuzz/fuzz-oci-ref: testing/fuzz/fuzz-oci-ref.c $(FUZZ_BASE) \diff --git a/testing/fuzz/corpus/beefile/kernel-cve b/testing/fuzz/corpus/beefile/kernel-cvenew file mode 100644index 00000000..e4e8c9c7--- /dev/null+++ b/testing/fuzz/corpus/beefile/kernel-cve@@ -0,0 +1,531 @@+[package]+name = "kernel-cve-upatches"+description = "Exported Shirudo kernel CVE upatch sources"+license = "GPL-2.0 OR BSD-2-Clause"+authors = ["Shirudo Campaign Export"]++[[upatches]]+source = "sources/cve-2025-71093-e1000-oob-e1000-tbi-should-accept/observability/cve-2025-71093-e1000-tbi-detector.bpf.c"+load_target = "upatches/cve-2025-71093-e1000-oob-e1000-tbi-should-accept.upatch"++[upatches.tree]+id = "cve-2025-71093-e1000-oob-e1000-tbi-should-accept"+load_artifact = "upatches/cve-2025-71093-e1000-oob-e1000-tbi-should-accept.upatch"+unload_artifact = "upatches/cve-2025-71093-e1000-oob-e1000-tbi-should-accept.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_E1000 = ["y", "m"]++[[upatches]]+source = "sources/cve-2025-71116-libceph-make-decode-pool-more-resilient-against-corrupted/observability/cve_2025_71116-offset-predicate.bpf.c"+load_target = "upatches/cve-2025-71116-libceph-make-decode-pool-more-resilient-against-corrupted.upatch"++[upatches.tree]+id = "cve-2025-71116-libceph-make-decode-pool-more-resilient-against-corrupted"+load_artifact = "upatches/cve-2025-71116-libceph-make-decode-pool-more-resilient-against-corrupted.upatch"+unload_artifact = "upatches/cve-2025-71116-libceph-make-decode-pool-more-resilient-against-corrupted.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_CEPH_LIB = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-23003-ip6-tunnel-skb-vlan-inet-prepare-ip6-tnl/observability/cve-2026-23003-caller-offset.bpf.c"+load_target = "upatches/cve-2026-23003-ip6-tunnel-skb-vlan-inet-prepare-ip6-tnl.upatch"++[upatches.tree]+id = "cve-2026-23003-ip6-tunnel-skb-vlan-inet-prepare-ip6-tnl"+load_artifact = "upatches/cve-2026-23003-ip6-tunnel-skb-vlan-inet-prepare-ip6-tnl.upatch"+unload_artifact = "upatches/cve-2026-23003-ip6-tunnel-skb-vlan-inet-prepare-ip6-tnl.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_IPV6_TUNNEL = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-23315-wifi-mt76-oob-access-mt76-connac2-mac-write/observability/cve-2026-23315-caller-predicate.bpf.c"+load_target = "upatches/cve-2026-23315-wifi-mt76-oob-access-mt76-connac2-mac-write.upatch"++[upatches.tree]+id = "cve-2026-23315-wifi-mt76-oob-access-mt76-connac2-mac-write"+load_artifact = "upatches/cve-2026-23315-wifi-mt76-oob-access-mt76-connac2-mac-write.upatch"+unload_artifact = "upatches/cve-2026-23315-wifi-mt76-oob-access-mt76-connac2-mac-write.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_MT76_CORE = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-31393-bluetooth-l2cap-validate-l2cap-info-rsp-payload-length/observability/cve-2026-31393-caller-predicate.bpf.c"+load_target = "upatches/cve-2026-31393-bluetooth-l2cap-validate-l2cap-info-rsp-payload-length.upatch"++[upatches.tree]+id = "cve-2026-31393-bluetooth-l2cap-validate-l2cap-info-rsp-payload-length"+load_artifact = "upatches/cve-2026-31393-bluetooth-l2cap-validate-l2cap-info-rsp-payload-length.upatch"+unload_artifact = "upatches/cve-2026-31393-bluetooth-l2cap-validate-l2cap-info-rsp-payload-length.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_BT = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-31674-netfilter-ip6t-rt-reject-oversized-addrnr-rt-mt6/observability/cve-2026-31674-rt-mt6-detector.bpf.c"+load_target = "upatches/cve-2026-31674-netfilter-ip6t-rt-reject-oversized-addrnr-rt-mt6.upatch"++[upatches.tree]+id = "cve-2026-31674-netfilter-ip6t-rt-reject-oversized-addrnr-rt-mt6"+load_artifact = "upatches/cve-2026-31674-netfilter-ip6t-rt-reject-oversized-addrnr-rt-mt6.upatch"+unload_artifact = "upatches/cve-2026-31674-netfilter-ip6t-rt-reject-oversized-addrnr-rt-mt6.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_IP6_NF_MATCH_RT = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-31675-net-sched-sch-netem-oob-access-packet-corruption/observability/cve-2026-31675-netem-detector.bpf.c"+load_target = "upatches/cve-2026-31675-net-sched-sch-netem-oob-access-packet-corruption.upatch"++[upatches.tree]+id = "cve-2026-31675-net-sched-sch-netem-oob-access-packet-corruption"+load_artifact = "upatches/cve-2026-31675-net-sched-sch-netem-oob-access-packet-corruption.upatch"+unload_artifact = "upatches/cve-2026-31675-net-sched-sch-netem-oob-access-packet-corruption.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_NET_SCH_NETEM = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-31682-bridge-br-nd-send-linearize-skb-parsing-nd/observability/cve_2026_31682-offset-predicate.bpf.c"+load_target = "upatches/cve-2026-31682-bridge-br-nd-send-linearize-skb-parsing-nd.upatch"++[upatches.tree]+id = "cve-2026-31682-bridge-br-nd-send-linearize-skb-parsing-nd"+load_artifact = "upatches/cve-2026-31682-bridge-br-nd-send-linearize-skb-parsing-nd.upatch"+unload_artifact = "upatches/cve-2026-31682-bridge-br-nd-send-linearize-skb-parsing-nd.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_BRIDGE = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-31685-netfilter-ip6t-eui64-reject-invalid-mac-header-all/observability/cve-2026-31685-eui64-detector.bpf.c"+load_target = "upatches/cve-2026-31685-netfilter-ip6t-eui64-reject-invalid-mac-header-all.upatch"++[upatches.tree]+id = "cve-2026-31685-netfilter-ip6t-eui64-reject-invalid-mac-header-all"+load_artifact = "upatches/cve-2026-31685-netfilter-ip6t-eui64-reject-invalid-mac-header-all.upatch"+unload_artifact = "upatches/cve-2026-31685-netfilter-ip6t-eui64-reject-invalid-mac-header-all.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_IP6_NF_MATCH_EUI64 = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-31694-fuse-reject-oversized-dirents-page-cache/observability/cve-2026-31694-fuse-emit-detector.bpf.c"+load_target = "upatches/cve-2026-31694-fuse-reject-oversized-dirents-page-cache.upatch"++[upatches.tree]+id = "cve-2026-31694-fuse-reject-oversized-dirents-page-cache"+load_artifact = "upatches/cve-2026-31694-fuse-reject-oversized-dirents-page-cache.upatch"+unload_artifact = "upatches/cve-2026-31694-fuse-reject-oversized-dirents-page-cache.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_FUSE_FS = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-43062-bluetooth-l2cap-type-confusion-l2cap-ecred-reconf-rsp/observability/cve-2026-43062-caller-predicate.bpf.c"+load_target = "upatches/cve-2026-43062-bluetooth-l2cap-type-confusion-l2cap-ecred-reconf-rsp.upatch"++[upatches.tree]+id = "cve-2026-43062-bluetooth-l2cap-type-confusion-l2cap-ecred-reconf-rsp"+load_artifact = "upatches/cve-2026-43062-bluetooth-l2cap-type-confusion-l2cap-ecred-reconf-rsp.upatch"+unload_artifact = "upatches/cve-2026-43062-bluetooth-l2cap-type-confusion-l2cap-ecred-reconf-rsp.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_BT = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-43281-mailbox-oob-access-fw-mbox-index-xlate/observability/cve-2026-43281-mailbox-detector.bpf.c"+load_target = "upatches/cve-2026-43281-mailbox-oob-access-fw-mbox-index-xlate.upatch"++[upatches.tree]+id = "cve-2026-43281-mailbox-oob-access-fw-mbox-index-xlate"+load_artifact = "upatches/cve-2026-43281-mailbox-oob-access-fw-mbox-index-xlate.upatch"+unload_artifact = "upatches/cve-2026-43281-mailbox-oob-access-fw-mbox-index-xlate.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_MAILBOX = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-52906-9p-access-mode-flags-being-ored-instead-replaced/observability/cve_2026_52906-offset-predicate.bpf.c"+load_target = "upatches/cve-2026-52906-9p-access-mode-flags-being-ored-instead-replaced.upatch"++[upatches.tree]+id = "cve-2026-52906-9p-access-mode-flags-being-ored-instead-replaced"+load_artifact = "upatches/cve-2026-52906-9p-access-mode-flags-being-ored-instead-replaced.upatch"+unload_artifact = "upatches/cve-2026-52906-9p-access-mode-flags-being-ored-instead-replaced.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_9P_FS = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-52915-netfilter-ip6t-hbh-reject-oversized-option-lists/observability/cve-2026-52915-hbh-check-detector.bpf.c"+load_target = "upatches/cve-2026-52915-netfilter-ip6t-hbh-reject-oversized-option-lists.upatch"++[upatches.tree]+id = "cve-2026-52915-netfilter-ip6t-hbh-reject-oversized-option-lists"+load_artifact = "upatches/cve-2026-52915-netfilter-ip6t-hbh-reject-oversized-option-lists.upatch"+unload_artifact = "upatches/cve-2026-52915-netfilter-ip6t-hbh-reject-oversized-option-lists.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_IP6_NF_MATCH_OPTS = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-52942-netfilter-nf-log-validate-mac-header-was-set/observability/cve-2026-52942-mac-header-detector.bpf.c"+load_target = "upatches/cve-2026-52942-netfilter-nf-log-validate-mac-header-was-set.upatch"++[upatches.tree]+id = "cve-2026-52942-netfilter-nf-log-validate-mac-header-was-set"+load_artifact = "upatches/cve-2026-52942-netfilter-nf-log-validate-mac-header-was-set.upatch"+unload_artifact = "upatches/cve-2026-52942-netfilter-nf-log-validate-mac-header-was-set.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_NF_LOG_SYSLOG = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-52974-net-tls-strparser-anchor-skb-leak-offload-rx/observability/cve-2026-52974-caller-predicate.bpf.c"+load_target = "upatches/cve-2026-52974-net-tls-strparser-anchor-skb-leak-offload-rx.upatch"++[upatches.tree]+id = "cve-2026-52974-net-tls-strparser-anchor-skb-leak-offload-rx"+load_artifact = "upatches/cve-2026-52974-net-tls-strparser-anchor-skb-leak-offload-rx.upatch"+unload_artifact = "upatches/cve-2026-52974-net-tls-strparser-anchor-skb-leak-offload-rx.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_TLS = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-53043-ocfs2-dlm-validate-qr-numregions-dlm-match-regions/observability/cve-2026-53043-caller-predicate.bpf.c"+load_target = "upatches/cve-2026-53043-ocfs2-dlm-validate-qr-numregions-dlm-match-regions.upatch"++[upatches.tree]+id = "cve-2026-53043-ocfs2-dlm-validate-qr-numregions-dlm-match-regions"+load_artifact = "upatches/cve-2026-53043-ocfs2-dlm-validate-qr-numregions-dlm-match-regions.upatch"+unload_artifact = "upatches/cve-2026-53043-ocfs2-dlm-validate-qr-numregions-dlm-match-regions.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_OCFS2_FS_O2CB = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-53078-bpf-same-register-dst-src-oob-read-pointer/observability/cve-2026-53078-caller-predicate.bpf.c"+load_target = "upatches/cve-2026-53078-bpf-same-register-dst-src-oob-read-pointer.upatch"++[upatches.tree]+id = "cve-2026-53078-bpf-same-register-dst-src-oob-read-pointer"+load_artifact = "upatches/cve-2026-53078-bpf-same-register-dst-src-oob-read-pointer.upatch"+unload_artifact = "upatches/cve-2026-53078-bpf-same-register-dst-src-oob-read-pointer.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_BPF_SYSCALL = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-53092-bpf-linked-reg-delta-tracking-src-reg-dst/observability/cve-2026-53092-caller-predicate.bpf.c"+load_target = "upatches/cve-2026-53092-bpf-linked-reg-delta-tracking-src-reg-dst.upatch"++[upatches.tree]+id = "cve-2026-53092-bpf-linked-reg-delta-tracking-src-reg-dst"+load_artifact = "upatches/cve-2026-53092-bpf-linked-reg-delta-tracking-src-reg-dst.upatch"+unload_artifact = "upatches/cve-2026-53092-bpf-linked-reg-delta-tracking-src-reg-dst.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_BPF_SYSCALL = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-53194-usb-serial-kl5kusb105-bulk-out-buffer-overflow/observability/cve-2026-53194-candidate.bpf.c"+load_target = "upatches/cve-2026-53194-usb-serial-kl5kusb105-bulk-out-buffer-overflow.upatch"++[upatches.tree]+id = "cve-2026-53194-usb-serial-kl5kusb105-bulk-out-buffer-overflow"+load_artifact = "upatches/cve-2026-53194-usb-serial-kl5kusb105-bulk-out-buffer-overflow.upatch"+unload_artifact = "upatches/cve-2026-53194-usb-serial-kl5kusb105-bulk-out-buffer-overflow.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_USB_SERIAL_KLSI = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-53255-bluetooth-mgmt-validate-advertising-tlv-type-checks/observability/cve-2026-53255-tlv-detector.bpf.c"+load_target = "upatches/cve-2026-53255-bluetooth-mgmt-validate-advertising-tlv-type-checks.upatch"++[upatches.tree]+id = "cve-2026-53255-bluetooth-mgmt-validate-advertising-tlv-type-checks"+load_artifact = "upatches/cve-2026-53255-bluetooth-mgmt-validate-advertising-tlv-type-checks.upatch"+unload_artifact = "upatches/cve-2026-53255-bluetooth-mgmt-validate-advertising-tlv-type-checks.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_BT = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-63915-nfc-hci-oob-read-hcp-header-parsing/observability/cve-2026-63915-hcp-detector.bpf.c"+load_target = "upatches/cve-2026-63915-nfc-hci-oob-read-hcp-header-parsing.upatch"++[upatches.tree]+id = "cve-2026-63915-nfc-hci-oob-read-hcp-header-parsing"+load_artifact = "upatches/cve-2026-63915-nfc-hci-oob-read-hcp-header-parsing.upatch"+unload_artifact = "upatches/cve-2026-63915-nfc-hci-oob-read-hcp-header-parsing.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_NFC = ["y", "m"]+CONFIG_NFC_DIGITAL = ["y", "m"]+CONFIG_NFC_HCI = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-63947-bluetooth-hidp-missing-length-checks-hidp-input-report/observability/cve-2026-63947-candidate.bpf.c"+load_target = "upatches/cve-2026-63947-bluetooth-hidp-missing-length-checks-hidp-input-report.upatch"++[upatches.tree]+id = "cve-2026-63947-bluetooth-hidp-missing-length-checks-hidp-input-report"+load_artifact = "upatches/cve-2026-63947-bluetooth-hidp-missing-length-checks-hidp-input-report.upatch"+unload_artifact = "upatches/cve-2026-63947-bluetooth-hidp-missing-length-checks-hidp-input-report.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_BT = ["y", "m"]+CONFIG_BT_HIDP = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-63976-bluetooth-l2cap-clear-chan-ident-ecred-reconfiguration-success/observability/cve-2026-63976-caller-predicate.bpf.c"+load_target = "upatches/cve-2026-63976-bluetooth-l2cap-clear-chan-ident-ecred-reconfiguration-success.upatch"++[upatches.tree]+id = "cve-2026-63976-bluetooth-l2cap-clear-chan-ident-ecred-reconfiguration-success"+load_artifact = "upatches/cve-2026-63976-bluetooth-l2cap-clear-chan-ident-ecred-reconfiguration-success.upatch"+unload_artifact = "upatches/cve-2026-63976-bluetooth-l2cap-clear-chan-ident-ecred-reconfiguration-success.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_BT = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-63984-ipv6-rpl-hdrlen-overflow-ipv6-rpl-srh-decompress/observability/cve-2026-63984-rpl-detector.bpf.c"+load_target = "upatches/cve-2026-63984-ipv6-rpl-hdrlen-overflow-ipv6-rpl-srh-decompress.upatch"++[upatches.tree]+id = "cve-2026-63984-ipv6-rpl-hdrlen-overflow-ipv6-rpl-srh-decompress"+load_artifact = "upatches/cve-2026-63984-ipv6-rpl-hdrlen-overflow-ipv6-rpl-srh-decompress.upatch"+unload_artifact = "upatches/cve-2026-63984-ipv6-rpl-hdrlen-overflow-ipv6-rpl-srh-decompress.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_IPV6 = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-63992-tunnels-not-assume-transport-header-iptunnel-pmtud-check/observability/cve-2026-63992-caller-predicate.bpf.c"+load_target = "upatches/cve-2026-63992-tunnels-not-assume-transport-header-iptunnel-pmtud-check.upatch"++[upatches.tree]+id = "cve-2026-63992-tunnels-not-assume-transport-header-iptunnel-pmtud-check"+load_artifact = "upatches/cve-2026-63992-tunnels-not-assume-transport-header-iptunnel-pmtud-check.upatch"+unload_artifact = "upatches/cve-2026-63992-tunnels-not-assume-transport-header-iptunnel-pmtud-check.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_INET = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-64036-cgroup-rstat-validate-cpu-css-rstat-cpu-access/observability/cve-2026-64036-caller-predicate.bpf.c"+load_target = "upatches/cve-2026-64036-cgroup-rstat-validate-cpu-css-rstat-cpu-access.upatch"++[upatches.tree]+id = "cve-2026-64036-cgroup-rstat-validate-cpu-css-rstat-cpu-access"+load_artifact = "upatches/cve-2026-64036-cgroup-rstat-validate-cpu-css-rstat-cpu-access.upatch"+unload_artifact = "upatches/cve-2026-64036-cgroup-rstat-validate-cpu-css-rstat-cpu-access.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_CGROUPS = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-64116-ipv6-ioam-add-null-check-idev-ipv6-hop/observability/cve_2026_64116-offset-predicate.bpf.c"+load_target = "upatches/cve-2026-64116-ipv6-ioam-add-null-check-idev-ipv6-hop.upatch"++[upatches.tree]+id = "cve-2026-64116-ipv6-ioam-add-null-check-idev-ipv6-hop"+load_artifact = "upatches/cve-2026-64116-ipv6-ioam-add-null-check-idev-ipv6-hop.upatch"+unload_artifact = "upatches/cve-2026-64116-ipv6-ioam-add-null-check-idev-ipv6-hop.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_IPV6 = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-64133-alsa-asihpi-oob-array-access-at-reading-cache/observability/cve-2026-64133-caller-predicate.bpf.c"+load_target = "upatches/cve-2026-64133-alsa-asihpi-oob-array-access-at-reading-cache.upatch"++[upatches.tree]+id = "cve-2026-64133-alsa-asihpi-oob-array-access-at-reading-cache"+load_artifact = "upatches/cve-2026-64133-alsa-asihpi-oob-array-access-at-reading-cache.upatch"+unload_artifact = "upatches/cve-2026-64133-alsa-asihpi-oob-array-access-at-reading-cache.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_SND_ASIHPI = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-80725-net-gro-properly-validate-big-tcp-aggregation-criteria/observability/cve-2026-80725-big-tcp-gro-observe.bpf.c"+load_target = "upatches/cve-2026-80725-net-gro-properly-validate-big-tcp-aggregation-criteria.upatch"++[upatches.tree]+id = "cve-2026-80725-net-gro-properly-validate-big-tcp-aggregation-criteria"+load_artifact = "upatches/cve-2026-80725-net-gro-properly-validate-big-tcp-aggregation-criteria.upatch"+unload_artifact = "upatches/cve-2026-80725-net-gro-properly-validate-big-tcp-aggregation-criteria.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["7.2"]+kernel_build_id = ["534043106db415bc0a983a3393e06c81b431bd39"]+architecture = ["x86_64"]++[upatches.tree.selector.kconfig]+CONFIG_NET = ["y", "m"]++[[upatches]]+source = "sources/cve-2026-68118-tcp-challenge-ack-non-exact-rst-syn-received/observability/cve_2026_68118-6.1-offset-predicate.bpf.c"+load_target = "upatches/cve-2026-68118-tcp-challenge-ack-non-exact-rst-syn-received.upatch"++[upatches.tree]+id = "cve-2026-68118-tcp-challenge-ack-non-exact-rst-syn-received"+load_artifact = "upatches/cve-2026-68118-tcp-challenge-ack-non-exact-rst-syn-received.upatch"+unload_artifact = "upatches/cve-2026-68118-tcp-challenge-ack-non-exact-rst-syn-received.unload.upatch"++[upatches.tree.selector]+kernel_release_prefix = ["6.1"]+architecture = ["x86_64"]diff --git a/testing/fuzz/corpus/beefile/kernel-obs b/testing/fuzz/corpus/beefile/kernel-obsnew file mode 100644index 00000000..e5ec48f6--- /dev/null+++ b/testing/fuzz/corpus/beefile/kernel-obs@@ -0,0 +1,96 @@+[package]+name = "kernel-obs"+description = "shirudo kernel observability: exec, network, DNS, listeners, watched destinations, executable mappings, privilege and sensitive file access"+license = "GPL-2.0 OR BSD-2-Clause"+authors = ["Authors of shirudo"]++[[files]]+source = "kernel-obs.bpf.c"+target = "kernel-obs.bpf.c"++[[files]]+source = "obs_common.h"+target = "obs_common.h"++[[files]]+source = "obs_table.h"+target = "obs_table.h"++[[files]]+source = "obs_priv.bpf.c"+target = "obs_priv.bpf.c"++[[files]]+source = "obs_exec.bpf.c"+target = "obs_exec.bpf.c"++[[files]]+source = "obs_net.bpf.c"+target = "obs_net.bpf.c"++[[files]]+source = "obs_dns.bpf.c"+target = "obs_dns.bpf.c"++[[files]]+source = "obs_file.bpf.c"+target = "obs_file.bpf.c"++[[files]]+source = "watch.list"+target = "watch.list"++[[files]]+source = "watch_generated.h"+target = "watch_generated.h"++[[files]]+source = "gen_watch.py"+target = "gen_watch.py"++[[files]]+source = "file-watch.list"+target = "file-watch.list"++[[files]]+source = "file_watch_generated.h"+target = "file_watch_generated.h"++[[files]]+source = "gen_file_watch.py"+target = "gen_file_watch.py"++[[files]]+source = "decoders/exec.lua"+target = "decoders/exec.lua"++[[files]]+source = "decoders/net.lua"+target = "decoders/net.lua"++[[files]]+source = "decoders/listen.lua"+target = "decoders/listen.lua"++[[files]]+source = "decoders/watch.lua"+target = "decoders/watch.lua"++[[files]]+source = "decoders/watch_stat.lua"+target = "decoders/watch_stat.lua"++[[files]]+source = "decoders/dns.lua"+target = "decoders/dns.lua"++[[files]]+source = "decoders/priv.lua"+target = "decoders/priv.lua"++[[files]]+source = "decoders/file.lua"+target = "decoders/file.lua"++[[upatches]]+source = "kernel-obs.bpf.c"diff --git a/testing/fuzz/fuzz-beefile.c b/testing/fuzz/fuzz-beefile.cnew file mode 100644index 00000000..bf4f455c--- /dev/null+++ b/testing/fuzz/fuzz-beefile.c@@ -0,0 +1,70 @@+// SPDX-License-Identifier: BSD-2-Clause+/*+ * Copyright (c) 2026 Authors of shirudo+ *+ * bpm_build_parse_beefile() on a Beefile, which bpm build reads from the+ * package source and bpm tree append from a package archive.+ */++#include <errno.h>++#include "fuzz.h"+#include "tools/shirudo-build/bpm.h"+#include "tools/shirudo-build/compile.h"+#include "tools/shirudo-build/package.h"+#include "tools/shirudo-build/vmlinux.h"+/* Last: it poisons the libc allocators the headers above declare. */+#include "malloc.h"++/* What bpm build does with a parsed Beefile is out of reach from here. */+int shirudo_build_bpm_push(int argc, char **argv)+{+ return -ENOSYS;+}++int shirudo_build_bpm_tree(int argc, char **argv)+{+ return -ENOSYS;+}++int shirudo_build_check_keys(const char *pkey, const char *cert)+{+ return -ENOSYS;+}++int shirudo_build_compile(const char *source, const char *output,+ const char *vmlinux_h, const char *extra_cflags)+{+ return -ENOSYS;+}++const char *shirudo_build_locate_vmlinux(const char *override)+{+ return NULL;+}++int shirudo_build_package_load(const char *bpf_o, const char *src_path,+ const char *out_upatch, const char *upatch_name,+ const char *pkey_path, const char *cert_path)+{+ return -ENOSYS;+}++int shirudo_build_package_unload(const char *name,+ const __u8 payload_sha256[32],+ const char *out_upatch,+ const char *pkey_path, const char *cert_path)+{+ return -ENOSYS;+}++int LLVMFuzzerTestOneInput(const __u8 *data, size_t size)+{+ struct bpm_build_spec *spec = xcalloc(1, sizeof(*spec));++ if (!spec)+ return 0;+ bpm_build_parse_beefile(data, size, spec);+ bpm_build_spec_free(spec);+ return 0;+}