CVSROOT: /cvs
Module name: src
Changes by: [email protected] 2026/09/07 03:07:47
Modified files:
lib/libpcap : pcap-int.h pcap.c savefile.c
sys/net : bpf.c bpf.h bpf_filter.c if_ppp.c
Log message:
Add proper program bound checks to the bpf engine
Introduce new bpf functions _bpf_lfilter and bpf_lfilter which properly
bound check the bpf program and ensure that no jump instruction goes
out of bound. The old bpf_filter and _bpf_filter functions pass a len of
zero and bypass the bound checks.
In the kernel bpf_mfilter now uses the bpf_program (which includes the len)
and by that all calls are bounded.
In userland pcap_offline_filter uses now bpf_lfilter and is bounded.
Direct calls to bpf_filter and _bpf_filter don't do bound checking and
should no longer be used. These functions will be removed from our libpcap
soon.
Fix for libpcap CVE-2026-31912.