]> git.ipfire.org Git - thirdparty/pdns.git/commit - pdns/bpf-filter.ebpf.src
eBPF: eBPF case-insensitive qname filtering
authorRemi Gacogne <remi.gacogne@powerdns.com>
Thu, 16 Jun 2016 10:29:31 +0000 (12:29 +0200)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Thu, 16 Jun 2016 12:12:12 +0000 (14:12 +0200)
commitd45189b7f898bd8702e7b51947ed6b885860d7e3
tree07a9ca75862a2635234d0bed8402b98796d1df49
parent87b515ed042fc042df83e8601f8b2a36a462a32c
eBPF: eBPF case-insensitive qname filtering

Split address and qname filtering into separate functions,
process the first bytes of the qname in the first function
to keep the second one under 4096 instructions.
The `imm` field of `struct bpf_insn` is signed, fix the cast.
Wrap FDs so they are released when we throw an exception in the ctor.
12 files changed:
ext/libbpf/libbpf.h
pdns/README-dnsdist.md
pdns/bpf-filter.cc
pdns/bpf-filter.ebpf [deleted file]
pdns/bpf-filter.ebpf.src
pdns/bpf-filter.hh
pdns/bpf-filter.main.ebpf [new file with mode: 0644]
pdns/bpf-filter.qname.ebpf [new file with mode: 0644]
pdns/dnsdistdist/Makefile.am
pdns/dnsdistdist/bpf-filter.ebpf [deleted symlink]
pdns/dnsdistdist/bpf-filter.main.ebpf [new symlink]
pdns/dnsdistdist/bpf-filter.qname.ebpf [new symlink]