]>
git.ipfire.org Git - thirdparty/knot-dns.git/log
Daniel Salzman [Mon, 11 May 2020 06:10:14 +0000 (08:10 +0200)]
xdp: add KNOT_XDP_LOAD_BPF_ALWAYS_UNLOAD mode
Daniel Salzman [Sat, 9 May 2020 07:31:41 +0000 (09:31 +0200)]
modupd: fix heap-buffer-overflow for XDP access
Daniel Salzman [Tue, 5 May 2020 11:34:22 +0000 (13:34 +0200)]
udp-handler: add missing return to a non-void function
Daniel Salzman [Tue, 5 May 2020 11:24:25 +0000 (13:24 +0200)]
libknot: fix not-installed libknot.h
Daniel Salzman [Sat, 2 May 2020 06:16:27 +0000 (08:16 +0200)]
Merge branch 'zone_size_xfr' into 'master'
refresh: removed redundant size check (better in zone_update_commit)
See merge request knot/knot-dns!1131
Daniel Salzman [Sat, 2 May 2020 06:05:56 +0000 (08:05 +0200)]
tests-extra: fix ddns/ttl after ANY changes
Libor Peltan [Fri, 1 May 2020 19:02:31 +0000 (21:02 +0200)]
rename test
Libor Peltan [Fri, 1 May 2020 16:50:51 +0000 (18:50 +0200)]
refresh: removed redundant size check (better in zone_update_commit)
Daniel Salzman [Fri, 1 May 2020 18:20:51 +0000 (20:20 +0200)]
Merge branch 'minimize_any' into 'master'
ANY: when UDP, always answer with one RRSet
Closes #676
See merge request knot/knot-dns!1129
Libor Peltan [Fri, 1 May 2020 10:22:03 +0000 (12:22 +0200)]
ANY: when UDP, always answer with one RRSet
Daniel Salzman [Fri, 1 May 2020 15:26:26 +0000 (17:26 +0200)]
Merge branch 'kjournalprint_rdonly' into 'master'
kjournalprint: open LMDB completely RDONLY
See merge request knot/knot-dns!1130
Daniel Salzman [Fri, 1 May 2020 15:21:58 +0000 (17:21 +0200)]
Merge branch 'fix_skip_crypto' into 'master'
bugfix: skip_crypto not effective after FULL update
See merge request knot/knot-dns!1128
Libor Peltan [Fri, 1 May 2020 12:56:40 +0000 (14:56 +0200)]
kjournalprint: open LMDB completely RDONLY
Libor Peltan [Thu, 30 Apr 2020 15:35:19 +0000 (17:35 +0200)]
bugfix: skip_crypto not effective after FULL update
David Vašek [Fri, 17 Apr 2020 12:23:44 +0000 (14:23 +0200)]
tests-extra: when starting the server, make sure that all port bindings were successfull
David Vašek [Wed, 15 Apr 2020 09:44:36 +0000 (11:44 +0200)]
tests-extra: config generator -- allow separator chars in the include path
White spaces and #'s are now possible.
Fixes "runtests.py -n xxx" for the test "contrib/include".
David Vašek [Mon, 13 Apr 2020 11:13:49 +0000 (13:13 +0200)]
tests-extra: ixfr/ixfr_merge -- raise some TCP timeouts to make the test stable under Valgrind
David Vašek [Thu, 5 Mar 2020 13:57:55 +0000 (14:57 +0100)]
contrib/net: try to catch misbehaving Valgrind
David Vašek [Thu, 5 Mar 2020 13:57:27 +0000 (14:57 +0100)]
contrib/net: when sending data, reflect other transient errors as well
David Vašek [Thu, 5 Mar 2020 12:07:34 +0000 (13:07 +0100)]
tests-extra: dnssec/ixfr_diff -- raise tcp_remote_io_timeout to make the test stable under Valgrind
Daniel Salzman [Wed, 29 Apr 2020 12:38:51 +0000 (14:38 +0200)]
Merge branch 'xfr_no_edns' into 'master'
xfr: secret option to send XFR w/o EDNS
See merge request knot/knot-dns!1125
Libor Peltan [Wed, 29 Apr 2020 09:12:54 +0000 (11:12 +0200)]
xfr: secret option to send XFR w/o EDNS
Libor Peltan [Mon, 27 Apr 2020 12:49:17 +0000 (14:49 +0200)]
tests-extra: compatibility with new Bind9-utils and Python 3.8
Daniel Salzman [Wed, 29 Apr 2020 08:26:34 +0000 (10:26 +0200)]
Merge branch 'fix_revert_nsec3_creation' into 'master'
bugfix: proper handling of nsec3 tree created during incremental update
See merge request knot/knot-dns!1124
Libor Peltan [Tue, 28 Apr 2020 15:03:37 +0000 (17:03 +0200)]
bugfix: proper handling of nsec3 tree created during incremental update
Daniel Salzman [Tue, 28 Apr 2020 13:51:52 +0000 (15:51 +0200)]
Revert "xdp: remove KNOT_XDP_LOAD_BPF_NEVER mode, which is not used"
This reverts commit
588e384d4a33dba8d3e97d9d571a778fdc9f7def .
The mode really is used!
Daniel Salzman [Tue, 28 Apr 2020 13:51:31 +0000 (15:51 +0200)]
xdp-gun: mute 'warning: suggest braces around initialization of subobject'
Daniel Salzman [Tue, 28 Apr 2020 13:49:52 +0000 (15:49 +0200)]
xdp: mute 'warning: unused variable' if NDEBUG
David Vašek [Tue, 28 Apr 2020 06:43:55 +0000 (08:43 +0200)]
geoip: don't process another geoip module if a CNAME/DNAME record has been found
David Vašek [Tue, 21 Apr 2020 08:57:56 +0000 (10:57 +0200)]
doc/geoip: fix a typo
Daniel Salzman [Sat, 25 Apr 2020 17:57:36 +0000 (19:57 +0200)]
Merge branch 'bitfehler/geoip-cname' into 'master'
geoip: trigger CNAME chain resolution
See merge request knot/knot-dns!1122
Daniel Salzman [Sat, 25 Apr 2020 17:26:19 +0000 (19:26 +0200)]
ctl: increase listen backlog to 5
When a control client reaches its timeout or is interrupted, the connection isn't
closed by the server immediately. So another connection attempts can be forbiden
with the error "OS lacked necessary resources". By increasing the listen backlog
such a situation is less probable to happen.
Daniel Salzman [Thu, 23 Apr 2020 19:33:57 +0000 (21:33 +0200)]
scripts: add 'xxd' to debian:latest/Dockerfile - make dist needs it
Daniel Salzman [Thu, 23 Apr 2020 19:16:35 +0000 (21:16 +0200)]
scripts: add 'clang' to debian:latest/Dockerfile - make dist needs it
Daniel Salzman [Thu, 23 Apr 2020 19:02:20 +0000 (21:02 +0200)]
scripts: add 'llvm' to debian:latest/Dockerfile - make dist needs it
Conrad Hoffmann [Thu, 23 Apr 2020 17:29:50 +0000 (19:29 +0200)]
geoip: trigger CNAME chain resolution
Currently, when the geoip module returns a CNAME, knot will not resolve
it any further, even if it is within its authority. This forces clients
or recursors to issue an additional request to resolve the CNAME.
This commit enables the module to take advantage of knot's chain
resolution by updating the query data with the returned CNAME and
returning KNOT_IN_STATE_FOLLOW instead of KNOT_IN_STATE_HIT, which will
let knot to continue with the processing as it would for regular CNAME
results.
Conrad Hoffmann [Thu, 23 Apr 2020 07:59:14 +0000 (09:59 +0200)]
geoip: stricter validation of CNAME usage
The geoip module does not validate the semantic validity of views, such
as that a CNAME cannot occur along with any other record. It will take
care to only return the right type in any given response, but this can
still lead to inconsistent results. Furthermore, one can supply two
CNAMEs in a view, and the module will write both of them into a
response.
This adds some input validation to tighten the rules of what the module
will accept as valid configuration, specifically that a CNAME cannot
occur along any other record in a view. This prevents ambiguities that
might otherwise arise in the query processing.
The additional storing of the domain name in case of a CNAME was chosen
in anticipation of using it for enabling CNAME chaing resolution,
implemented seperately.
Daniel Salzman [Thu, 23 Apr 2020 14:27:10 +0000 (16:27 +0200)]
xdp-gun: some fixes (Coverity)
Daniel Salzman [Thu, 23 Apr 2020 13:28:43 +0000 (15:28 +0200)]
xdp: remove KNOT_XDP_LOAD_BPF_NEVER mode, which is not used
Daniel Salzman [Wed, 22 Apr 2020 09:16:15 +0000 (11:16 +0200)]
tests-extra: set initial listen port to 53 since 0 is no longer permitted
Daniel Salzman [Wed, 22 Apr 2020 09:14:47 +0000 (11:14 +0200)]
tests-extra: store keymgr outputs in keymgr.out and keymgr.err
Daniel Salzman [Tue, 21 Apr 2020 17:05:25 +0000 (19:05 +0200)]
Merge branch 'xdp_gun'
Daniel Salzman [Thu, 16 Apr 2020 09:28:16 +0000 (11:28 +0200)]
doc: update XDP-related information
Daniel Salzman [Wed, 15 Apr 2020 19:44:03 +0000 (21:44 +0200)]
conf: disallow binding to port 0
Libor Peltan [Wed, 15 Apr 2020 16:39:17 +0000 (18:39 +0200)]
xdp-gun: support for target IP in other subnet
Daniel Salzman [Sat, 11 Apr 2020 15:12:14 +0000 (17:12 +0200)]
ddns: return SERVFAIL to updates over XDP (not supported)
Daniel Salzman [Fri, 10 Apr 2020 16:16:28 +0000 (18:16 +0200)]
knotd: add XDP message context to qdata, fix module queryacl
Daniel Salzman [Tue, 7 Apr 2020 10:41:29 +0000 (12:41 +0200)]
libknot: fix conditional includes in libknot.h
Daniel Salzman [Tue, 7 Apr 2020 17:39:15 +0000 (19:39 +0200)]
knotd: server improvements relating XDP
Daniel Salzman [Fri, 3 Apr 2020 10:59:51 +0000 (12:59 +0200)]
knotd: XDP cleanup; improved configuration; resolved TODOs
Daniel Salzman [Wed, 1 Apr 2020 13:34:11 +0000 (15:34 +0200)]
xdp-gun: remove dead code
Daniel Salzman [Wed, 1 Apr 2020 12:52:16 +0000 (14:52 +0200)]
xdp-gun: replace strncpy with strlcpy
Daniel Salzman [Tue, 31 Mar 2020 11:57:17 +0000 (13:57 +0200)]
xdp: move if_queue from knot_xdp_socket to kxsk_iface
Daniel Salzman [Wed, 1 Apr 2020 10:06:46 +0000 (12:06 +0200)]
xdp: rename xsk_umem_info kxsk_umem
Daniel Salzman [Mon, 30 Mar 2020 18:15:27 +0000 (20:15 +0200)]
xdp: code cleanup and unification
Vladimír Čunát [Thu, 26 Mar 2020 13:21:08 +0000 (14:21 +0100)]
xdp checksums: unify and explain endianness
Tested briefly, to be sure.
Daniel Salzman [Wed, 25 Mar 2020 12:04:06 +0000 (13:04 +0100)]
xdp: refactor knot_xdp_send()
Daniel Salzman [Wed, 25 Mar 2020 09:57:57 +0000 (10:57 +0100)]
xdp: add output file parameter to knot_xdp_info()
Daniel Salzman [Wed, 25 Mar 2020 09:48:16 +0000 (10:48 +0100)]
xdp: rework rx_desc to reflect filter checks
Daniel Salzman [Tue, 24 Mar 2020 20:09:24 +0000 (21:09 +0100)]
xdp: drop malformed packets directly by the filter (recompiled with clang-9)
Daniel Salzman [Tue, 24 Mar 2020 20:07:40 +0000 (21:07 +0100)]
xdp: make the filter endian independent
Daniel Salzman [Tue, 24 Mar 2020 20:03:49 +0000 (21:03 +0100)]
xdp: improve coding style of the filter
Daniel Salzman [Tue, 24 Mar 2020 19:57:13 +0000 (20:57 +0100)]
xdp: move BPF constants to extra header + add endianity detection
Daniel Salzman [Mon, 23 Mar 2020 14:36:15 +0000 (15:36 +0100)]
xdp: polish the API
Daniel Salzman [Thu, 19 Mar 2020 17:18:41 +0000 (18:18 +0100)]
server: remove duplicate strings
Daniel Salzman [Thu, 19 Mar 2020 17:14:57 +0000 (18:14 +0100)]
server: add check for changed 'listen-xdp'
Daniel Salzman [Sat, 14 Mar 2020 19:23:39 +0000 (20:23 +0100)]
xdp: code cleanup
Libor Peltan [Tue, 17 Mar 2020 12:36:30 +0000 (13:36 +0100)]
xdp_gun: avoid division by zero
Vladimír Čunát [Tue, 17 Mar 2020 11:45:09 +0000 (12:45 +0100)]
xdp: accept more error codes from sendto()
Vladimír Čunát [Tue, 17 Mar 2020 09:05:00 +0000 (10:05 +0100)]
xdp: add missing comment
(before I forget all about it)
Libor Peltan [Mon, 16 Mar 2020 17:57:22 +0000 (18:57 +0100)]
xdp gun: support for IPv6
Vladimír Čunát [Mon, 16 Mar 2020 14:55:52 +0000 (15:55 +0100)]
xdp: make an assertion less strict
Libor was running into that.
Vladimír Čunát [Fri, 13 Mar 2020 12:29:27 +0000 (13:29 +0100)]
xdp: load the BPF program without a temporary file
Daniel Salzman [Fri, 13 Mar 2020 10:35:49 +0000 (11:35 +0100)]
xdp: use 'struct sockaddr_in6' instead of 'struct sockaddr_storage' inside 'knot_xsk_msg_t'
Daniel Salzman [Thu, 5 Mar 2020 13:07:37 +0000 (14:07 +0100)]
xdp: unify code + cleanup
Daniel Salzman [Mon, 9 Mar 2020 17:25:58 +0000 (18:25 +0100)]
xdp: decrease FRAME_SIZE to 2048
Vladimír Čunát [Thu, 12 Mar 2020 10:30:30 +0000 (11:30 +0100)]
xdp: handle "bad" messages in knot_xsk_sendmmsg()
Daniel Salzman [Thu, 12 Mar 2020 08:52:44 +0000 (09:52 +0100)]
xdp: rework knot_xsk_sendmmsg()
Vladimír Čunát [Tue, 10 Mar 2020 13:28:08 +0000 (14:28 +0100)]
xdp: add a debug-print function
Vladimír Čunát [Fri, 6 Mar 2020 17:02:14 +0000 (18:02 +0100)]
knot_xsk_sendmsg_finish(): improve inner logic
Some of the conditions were clearly mistakes,
but overall I'm unsure about what to do in some cases.
Vladimír Čunát [Fri, 6 Mar 2020 16:45:41 +0000 (17:45 +0100)]
xdp: split knot_xsk_check() into two functions
No functional changes inside. This implements one of the TODOs.
It seems suitable to execute the two phases at different points
in time. In particular, I didn't like the fact that in knotd
_prepare_alloc() was "missing" between poll() and _alloc_packet().
Vladimír Čunát [Fri, 6 Mar 2020 15:14:41 +0000 (16:14 +0100)]
xdp: save a bit memory (in CPU caches)
Daniel Salzman [Fri, 6 Mar 2020 14:45:29 +0000 (15:45 +0100)]
udp-handerl: increase XDP_BATCHLEN to 32
Daniel Salzman [Tue, 25 Feb 2020 10:49:42 +0000 (11:49 +0100)]
libknot/xdp: extend filter configuration with DROP mode
Daniel Salzman [Thu, 12 Mar 2020 21:06:00 +0000 (22:06 +0100)]
xdp-gun: fix initial allocation error
Libor Peltan [Tue, 11 Feb 2020 08:40:07 +0000 (09:40 +0100)]
utils: add xdp-gun
Vladimír Čunát [Wed, 4 Mar 2020 16:19:13 +0000 (17:19 +0100)]
xdp bugfix: avoid buffer leak opportunity
I had looked at this case before but I didn't see the problem;
fortunately Dan pointed me to it again.
When we bail out due to error, we can't just __release the indices
that we haven't processed; they would need to do at least
kxsk_dealloc_umem_frame()
Libor Peltan [Mon, 17 Feb 2020 14:30:03 +0000 (15:30 +0100)]
bugfix: libbpf expects at least IFNAMSIZ length of iface name
Vladimír Čunát [Mon, 17 Feb 2020 13:04:04 +0000 (14:04 +0100)]
xdp: separate RX and TX umem frame processing
Vladimír Čunát [Wed, 12 Feb 2020 15:20:12 +0000 (16:20 +0100)]
xdp: add a third way of loading the BPF program
We need that in kresd, as overwriting the program would detach
all the AF_XDP sockets and only the last kresd could receive.
It's not perfect, but I suppose we can bear that extraneous message.
Vladimír Čunát [Thu, 6 Feb 2020 18:12:21 +0000 (19:12 +0100)]
xdp: drop assertions that are problematic in kresd
Vladimír Čunát [Wed, 12 Feb 2020 12:42:30 +0000 (13:42 +0100)]
xdp: trivial clean up
- mempools don't seem used here
- outdated comments
Vladimír Čunát [Wed, 12 Feb 2020 12:05:47 +0000 (13:05 +0100)]
xdp: also avoid leaks when knot_xsk_init() fails
Vladimír Čunát [Fri, 7 Feb 2020 14:07:39 +0000 (15:07 +0100)]
xdp: plug memory leaked in knot_xsk_deinit()
Daniel Salzman [Fri, 31 Jan 2020 11:36:23 +0000 (12:36 +0100)]
libknot: update Makefile and libknot.h
Libor Peltan [Wed, 29 Jan 2020 09:58:12 +0000 (10:58 +0100)]
xdp: listen on configured ifaces with workers=RXqueues
Daniel Salzman [Wed, 29 Jan 2020 09:46:23 +0000 (10:46 +0100)]
conf: add 'server.listen-xdp' option + allow port specification for UNIX sockets
Daniel Salzman [Tue, 28 Jan 2020 16:54:13 +0000 (17:54 +0100)]
stats: add protocol counters for XDP
Libor Peltan [Fri, 24 Jan 2020 11:45:00 +0000 (12:45 +0100)]
xdp: sendmmsg returns number of really sent
Libor Peltan [Wed, 22 Jan 2020 09:26:13 +0000 (10:26 +0100)]
xdp: enable listening on all ports