dect
/
libpcap
Archived
13
0
Fork 0
This repository has been archived on 2022-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
libpcap/bpf/net
guy 0446821e49 Make some arguments const pointers if that makes sense.
Add some additional checks to bpf_validate(), from OpenBSD.

Use bpf_validate() in install_bpf_program(), so we validate programs
even when they're being processed by userland filters; we make
bpf_validate() not reject backward branches, as we use them for the
protochain operator.

For BPF, don't assume that, just because no_optimize was set, we have a
program that we can't hand to the kernel; the user of the application
might have specified no optimization (e.g., tcpdump with -O), or we
might have generated code to handle 802.11 headers (the optimizer can't
handle that code).  Instead, try handing the filter to the kernel and,
if that fails, try it in userland.

Get rid of BPF_MAXINSNS - we don't have a limit on program size in
libpcap.
2008-01-02 04:16:46 +00:00
..
bpf_filter.c Make some arguments const pointers if that makes sense. 2008-01-02 04:16:46 +00:00