]> git.ipfire.org Git - thirdparty/knot-resolver.git/log
thirdparty/knot-resolver.git
10 years agolib/iterate: pair stype/m12n stype as well
Marek Vavruša [Wed, 13 May 2015 10:04:58 +0000 (12:04 +0200)] 
lib/iterate: pair stype/m12n stype as well

10 years agoMerge branch 'master' of gitlab.labs.nic.cz:knot/resolver
Marek Vavruša [Wed, 13 May 2015 09:54:52 +0000 (11:54 +0200)] 
Merge branch 'master' of gitlab.labs.nic.cz:knot/resolver

10 years agolib/layer: answer both m12n/full names from cache
Marek Vavruša [Wed, 13 May 2015 09:52:16 +0000 (11:52 +0200)] 
lib/layer: answer both m12n/full names from cache

previously only queried names were resolved from cache, this meant that if the target name was present in cache but a server on the search path dropped from it, it would refetch it - this is a problem when a loadbalancer with very short TTL was in search path

10 years agoFirst try autotools then cmake
Ondřej Surý [Wed, 13 May 2015 09:50:55 +0000 (11:50 +0200)] 
First try autotools then cmake

10 years agolib/rrcache: commit after cache prune
Marek Vavruša [Wed, 13 May 2015 09:36:57 +0000 (11:36 +0200)] 
lib/rrcache: commit after cache prune

10 years agodaemon/worker: synchronous send
Marek Vavruša [Wed, 13 May 2015 05:24:19 +0000 (07:24 +0200)] 
daemon/worker: synchronous send

10 years agobuild: bumped libuv version
Marek Vavruša [Tue, 12 May 2015 22:29:02 +0000 (00:29 +0200)] 
build: bumped libuv version

10 years agoMerge branch 'uv-closefail-cache-errors'
Marek Vavruša [Tue, 12 May 2015 22:08:58 +0000 (00:08 +0200)] 
Merge branch 'uv-closefail-cache-errors'

10 years agolib/pktcache: base ttl (fallback), cache IN only
Marek Vavruša [Tue, 12 May 2015 22:05:32 +0000 (00:05 +0200)] 
lib/pktcache: base ttl (fallback), cache IN only

10 years agolib/resolve: clear ‘cached’ flag on requery
Marek Vavruša [Tue, 12 May 2015 22:03:41 +0000 (00:03 +0200)] 
lib/resolve: clear ‘cached’ flag on requery

if the flag is left on, it prevents further caching

10 years agodaemon/worker: set ioreq-data early, cancel on timeout
Marek Vavruša [Tue, 12 May 2015 22:02:35 +0000 (00:02 +0200)] 
daemon/worker: set ioreq-data early, cancel on timeout

10 years agobuild: added -ldl for some platforms
Marek Vavruša [Tue, 12 May 2015 11:43:42 +0000 (13:43 +0200)] 
build: added -ldl for some platforms

10 years agotests: fixed typo
Marek Vavruša [Mon, 11 May 2015 07:37:34 +0000 (09:37 +0200)] 
tests: fixed typo

10 years agotests: soamin test is already fixed
Marek Vavruša [Mon, 11 May 2015 07:36:13 +0000 (09:36 +0200)] 
tests: soamin test is already fixed

10 years agotests: moved integration deps
Marek Vavruša [Mon, 11 May 2015 07:31:58 +0000 (09:31 +0200)] 
tests: moved integration deps

10 years agoscripts: fixed dockerfile
Marek Vavruša [Sun, 10 May 2015 19:44:55 +0000 (21:44 +0200)] 
scripts: fixed dockerfile

10 years agotests: preload mock calls on Linux
Marek Vavruša [Sun, 10 May 2015 19:40:33 +0000 (21:40 +0200)] 
tests: preload mock calls on Linux

10 years agolib/resolve: fixed good cached ns expired, only bad remain
Marek Vavruša [Sun, 10 May 2015 19:38:00 +0000 (21:38 +0200)] 
lib/resolve: fixed good cached ns expired, only bad remain

the resolution has to start from the root for zonecut resolution, otherwise it might stall resolution if the only good NS drops out of cache and only the bad remain

10 years agotests: added ncache tests, fixed ‘time elapsed’
Marek Vavruša [Sun, 10 May 2015 19:35:38 +0000 (21:35 +0200)] 
tests: added ncache tests, fixed ‘time elapsed’

10 years agolib/pktcache: fixed too long cache times
Marek Vavruša [Sun, 10 May 2015 17:55:35 +0000 (19:55 +0200)] 
lib/pktcache: fixed too long cache times

10 years agopktcache: adjust ttl in records
Marek Vavruša [Sun, 10 May 2015 09:45:57 +0000 (11:45 +0200)] 
pktcache: adjust ttl in records

10 years agotests: use edns=1 for queries
Marek Vavruša [Sat, 9 May 2015 20:05:07 +0000 (22:05 +0200)] 
tests: use edns=1 for queries

10 years agotests: added pktcache
Marek Vavruša [Sat, 9 May 2015 19:48:49 +0000 (21:48 +0200)] 
tests: added pktcache

10 years agodaemon/io: check for bad udp reads
Marek Vavruša [Sat, 9 May 2015 19:44:16 +0000 (21:44 +0200)] 
daemon/io: check for bad udp reads

10 years agobuild: update brew
Marek Vavruša [Sat, 9 May 2015 17:18:54 +0000 (19:18 +0200)] 
build: update brew

10 years agopktcache: maximum time limit, cache only nodata/nxdomain
Marek Vavruša [Sat, 9 May 2015 17:18:19 +0000 (19:18 +0200)] 
pktcache: maximum time limit, cache only nodata/nxdomain

10 years agobuild: added libtasn1 brew dependency
Marek Vavruša [Sat, 9 May 2015 16:47:08 +0000 (18:47 +0200)] 
build: added libtasn1 brew dependency

10 years agodoc: updated ketcd
Marek Vavruša [Sat, 9 May 2015 16:20:40 +0000 (18:20 +0200)] 
doc: updated ketcd

10 years agodoc: added ketcd
Marek Vavruša [Sat, 9 May 2015 16:18:23 +0000 (18:18 +0200)] 
doc: added ketcd

10 years agodoc: documented Lua modules
Marek Vavruša [Thu, 7 May 2015 19:42:49 +0000 (21:42 +0200)] 
doc: documented Lua modules

10 years agomodules/ketcd: cleanup, added some documentation
Marek Vavruša [Thu, 7 May 2015 19:42:38 +0000 (21:42 +0200)] 
modules/ketcd: cleanup, added some documentation

10 years agomodules: fixed install target of Lua modules
Marek Vavruša [Thu, 7 May 2015 19:42:05 +0000 (21:42 +0200)] 
modules: fixed install target of Lua modules

10 years agodoc: daemon doc cleanup
Marek Vavruša [Thu, 7 May 2015 19:41:46 +0000 (21:41 +0200)] 
doc: daemon doc cleanup

10 years agodaemon/lua: syntactic sugar for ‘net’
Marek Vavruša [Thu, 7 May 2015 19:41:16 +0000 (21:41 +0200)] 
daemon/lua: syntactic sugar for ‘net’

this allows list-like declaration of bound interfaces

e.g. net = { ‘127.0.0.1’, net.eth0 }

10 years agodaemon/bindings: syntactic sugar for cache
Marek Vavruša [Thu, 7 May 2015 19:39:50 +0000 (21:39 +0200)] 
daemon/bindings: syntactic sugar for cache

the cache can be setup declaratively with:

cache.size = 10 * MB

the cache storage backend can be changed with:

cache.storage = ‘lmdb://.'

10 years agobuild: fixed build rule for modules
Marek Vavruša [Thu, 7 May 2015 13:49:02 +0000 (15:49 +0200)] 
build: fixed build rule for modules

10 years agomodules/ketcd: added polling
Marek Vavruša [Thu, 7 May 2015 13:42:57 +0000 (15:42 +0200)] 
modules/ketcd: added polling

10 years agobuild: Lua modules with multiple source files
Marek Vavruša [Thu, 7 May 2015 13:42:43 +0000 (15:42 +0200)] 
build: Lua modules with multiple source files

10 years agodaemon/ffimodule: support for main thread/coroutine
Marek Vavruša [Thu, 7 May 2015 13:42:16 +0000 (15:42 +0200)] 
daemon/ffimodule: support for main thread/coroutine

10 years agomodules/ketcd: Etcd module
Marek Vavruša [Thu, 7 May 2015 08:36:30 +0000 (10:36 +0200)] 
modules/ketcd: Etcd module

10 years agodaemon/bindings: report errors in events
Marek Vavruša [Thu, 7 May 2015 08:36:16 +0000 (10:36 +0200)] 
daemon/bindings: report errors in events

10 years agodaemon/ffimodule: support for Lua modules (including layers)
Marek Vavruša [Thu, 7 May 2015 08:35:53 +0000 (10:35 +0200)] 
daemon/ffimodule: support for Lua modules (including layers)

10 years agobuild: modules/lua, added clean rule
Marek Vavruša [Thu, 7 May 2015 08:35:09 +0000 (10:35 +0200)] 
build: modules/lua, added clean rule

10 years agodaemon/engine: support for Lua modules, stub etcd module
Marek Vavruša [Wed, 6 May 2015 08:28:21 +0000 (10:28 +0200)] 
daemon/engine: support for Lua modules, stub etcd module

10 years agolib/modules: layer() api now accept module name
Marek Vavruša [Wed, 6 May 2015 08:27:47 +0000 (10:27 +0200)] 
lib/modules: layer() api now accept module name

module api can now store userdata, e.g. owner

10 years agodaemon/bindings: cleanup in formatting
Marek Vavruša [Wed, 6 May 2015 08:26:50 +0000 (10:26 +0200)] 
daemon/bindings: cleanup in formatting

10 years agobuild: slack integration
Marek Vavruša [Tue, 5 May 2015 21:35:34 +0000 (23:35 +0200)] 
build: slack integration

10 years agolib: write debug to stdout (buffered)
Marek Vavruša [Tue, 5 May 2015 21:30:19 +0000 (23:30 +0200)] 
lib: write debug to stdout (buffered)

10 years agodaemon/io: fixed corrupted handles with exhausted TCP clients
Marek Vavruša [Tue, 5 May 2015 21:21:49 +0000 (23:21 +0200)] 
daemon/io: fixed corrupted handles with exhausted TCP clients

the TCP allowed parallel processing of multiple requests over
one client socket, however if the client socket disconnected,
it left the running tasks reading from bad handle
now each task takes ownership of the handle until it is finished,
only then it is returned to the loop and closed

10 years agolib/resolve: fixed nested NS dependency chains
Marek Vavruša [Tue, 5 May 2015 18:34:49 +0000 (20:34 +0200)] 
lib/resolve: fixed nested NS dependency chains

10 years agolib/resolve: response marked as resolved too early
Marek Vavruša [Mon, 4 May 2015 08:31:46 +0000 (10:31 +0200)] 
lib/resolve: response marked as resolved too early

10 years agobuild: experimental slack integration
Marek Vavruša [Mon, 4 May 2015 12:28:13 +0000 (14:28 +0200)] 
build: experimental slack integration

10 years agoMerge branch 'cache-backends'
Marek Vavruša [Sun, 3 May 2015 19:16:49 +0000 (21:16 +0200)] 
Merge branch 'cache-backends'

10 years agodoc: updated documentation for cache backends
Marek Vavruša [Sun, 3 May 2015 19:16:29 +0000 (21:16 +0200)] 
doc: updated documentation for cache backends

10 years agodaemon: added cache.backends() binding
Marek Vavruša [Sun, 3 May 2015 19:16:15 +0000 (21:16 +0200)] 
daemon: added cache.backends() binding

10 years agolib/rrcache: renamed itercache to rrcache
Marek Vavruša [Sun, 3 May 2015 18:28:51 +0000 (20:28 +0200)] 
lib/rrcache: renamed itercache to rrcache

10 years agolib/pktcache: packet cache (used for caching negative responses)
Marek Vavruša [Sun, 3 May 2015 18:23:51 +0000 (20:23 +0200)] 
lib/pktcache: packet cache (used for caching negative responses)

the pktcache introduces two cache tags PKT/SEC for
basic/DNSSEC responses and stores negative answers in
the cache

10 years agolib/resolve: produce() layers can generate answer, not just query
Marek Vavruša [Sun, 3 May 2015 18:21:17 +0000 (20:21 +0200)] 
lib/resolve: produce() layers can generate answer, not just query

previously producers in overlay could only generate query or
update the final answer - this required exported callbacks
from iterate.c and specific processing. this wouldn’t work
for negative cache, as it would be required to reimplement
whole iterate layer for cached data

the new workflow allows produce layers to generate answer
instead, this answer is then consumed in the next step
by the iterate module in unified fashion for all caches/generators

10 years agolib/iterate: accept other in-bailiwick data to answer
Marek Vavruša [Sun, 3 May 2015 18:14:04 +0000 (20:14 +0200)] 
lib/iterate: accept other in-bailiwick data to answer

this fixes stripped DNSSEC records in final answer

10 years agolib/resolve: correct edns0 handling for clients
Marek Vavruša [Sun, 3 May 2015 18:12:26 +0000 (20:12 +0200)] 
lib/resolve: correct edns0 handling for clients

the server responds with edns0 if the client requests it,
it also uses DNSSEC for queries if DO=1

the obtained records are not however validated

10 years agolib/resolve: increased buflen to accomodate edns0/dnssec
Marek Vavruša [Sun, 3 May 2015 18:08:37 +0000 (20:08 +0200)] 
lib/resolve: increased buflen to accomodate edns0/dnssec

10 years agodaemon/engine: extensible registry of cache backends
Marek Vavruša [Fri, 1 May 2015 15:51:09 +0000 (17:51 +0200)] 
daemon/engine: extensible registry of cache backends

the engine keeps an array of storage backends available
for caching, it is possible to switch the backend on
runtime with standard ‘proto://config' string

the default backend is ‘lmdb://<path>’

10 years agolib/cache: open with generic storage options
Marek Vavruša [Fri, 1 May 2015 15:49:05 +0000 (17:49 +0200)] 
lib/cache: open with generic storage options

the api is still a global variable, but it would be the
best if the namedb_t carried the pointer to the api,
so it needs to change in libknot later

10 years agolib/cache: relaxed API to allow other assets than RR
Marek Vavruša [Fri, 1 May 2015 00:20:46 +0000 (02:20 +0200)] 
lib/cache: relaxed API to allow other assets than RR

each asset is tagged by a byte defining its type and importance
this is a groundwork for negative cache and packet cache
abstracted the code in preparation for different backends

10 years agoMerge branch 'fix-edns0-badimpl'
Marek Vavruša [Sat, 2 May 2015 14:36:45 +0000 (16:36 +0200)] 
Merge branch 'fix-edns0-badimpl'

10 years agodaemon/worker: close all handles in worker, pass through errors
Marek Vavruša [Sat, 2 May 2015 14:36:33 +0000 (16:36 +0200)] 
daemon/worker: close all handles in worker, pass through errors

do all socket closing in worker to avoid double closes with
timeout timer, also propagate bad messages to discover errors
earlier than timeout

10 years agolib: revert to rfc1035 basic dns query on bad reply
Marek Vavruša [Sat, 2 May 2015 14:32:30 +0000 (16:32 +0200)] 
lib: revert to rfc1035 basic dns query on bad reply

if the server doesn’t understand edns0, replies with
notimpl, formerr or sends bad badly formed response,
we try basic dns query (ns0.rbsov.bbc.co.uk)

10 years agolib: removed unused headers
Marek Vavruša [Thu, 30 Apr 2015 09:57:19 +0000 (11:57 +0200)] 
lib: removed unused headers

10 years agodaemon/engine: missing prefix
Marek Vavruša [Wed, 29 Apr 2015 20:58:38 +0000 (22:58 +0200)] 
daemon/engine: missing prefix

10 years agodaemon/engine: use MODULEDIR for Lua includes
Marek Vavruša [Wed, 29 Apr 2015 20:55:22 +0000 (22:55 +0200)] 
daemon/engine: use MODULEDIR for Lua includes

10 years agoMerge branch 'events'
Marek Vavruša [Wed, 29 Apr 2015 14:25:41 +0000 (16:25 +0200)] 
Merge branch 'events'

10 years agodaemon/binding: cleanup
Marek Vavruša [Wed, 29 Apr 2015 14:13:50 +0000 (16:13 +0200)] 
daemon/binding: cleanup

10 years agodaemon/lua: time constants in env
Marek Vavruša [Wed, 29 Apr 2015 14:13:41 +0000 (16:13 +0200)] 
daemon/lua: time constants in env

10 years agodaemon/bindings: introduced 'event' package for timers
Marek Vavruša [Wed, 29 Apr 2015 14:13:23 +0000 (16:13 +0200)] 
daemon/bindings: introduced 'event' package for timers

10 years agodaemon/engine: check for bad upvalues in module trampoline
Marek Vavruša [Wed, 29 Apr 2015 14:12:36 +0000 (16:12 +0200)] 
daemon/engine: check for bad upvalues in module trampoline

10 years agoMerge branch 'contrib-csprng'
Marek Vavruša [Tue, 28 Apr 2015 17:04:24 +0000 (19:04 +0200)] 
Merge branch 'contrib-csprng'

10 years agocontrib: created 'contrib' directory with ccan/isaac as csprng
Marek Vavruša [Tue, 28 Apr 2015 16:59:43 +0000 (18:59 +0200)] 
contrib: created 'contrib' directory with ccan/isaac as csprng

previously cryptolib random function was used to generate message id,
this works well but it is slow especially when the entropy is low,
replaced with cryptographically safe prng ISAAC

the ccan directory is going to be used in the future, as it's include
structure makes it easy to embed C snippets instead of reimplementing
them

10 years agoMerge branch 'resolve-split-api'
Marek Vavruša [Tue, 28 Apr 2015 07:31:21 +0000 (09:31 +0200)] 
Merge branch 'resolve-split-api'

10 years agolib/iterate: disable qname m12 on positive answers
Marek Vavruša [Tue, 28 Apr 2015 07:30:00 +0000 (09:30 +0200)] 
lib/iterate: disable qname m12 on positive answers

the encloser might exist and contain valid data, the resolver would return wrong records in this case

10 years agolib/resolve: fixed debug build
Marek Vavruša [Tue, 28 Apr 2015 07:21:38 +0000 (09:21 +0200)] 
lib/resolve: fixed debug build

10 years agodaemon/worker: implemented iteration limit
Marek Vavruša [Tue, 28 Apr 2015 06:59:04 +0000 (08:59 +0200)] 
daemon/worker: implemented iteration limit

refs #15

10 years agoMerge branch 'resolve-split-api'
Marek Vavruša [Mon, 27 Apr 2015 17:02:37 +0000 (19:02 +0200)] 
Merge branch 'resolve-split-api'

10 years agobuild: cleanup in make rules
Marek Vavruša [Mon, 27 Apr 2015 14:19:32 +0000 (16:19 +0200)] 
build: cleanup in make rules

10 years agomodules/hints: fixed memleak on exit
Marek Vavruša [Mon, 27 Apr 2015 14:19:22 +0000 (16:19 +0200)] 
modules/hints: fixed memleak on exit

10 years agodaemon: fixed memleak in network address pack
Marek Vavruša [Mon, 27 Apr 2015 14:19:13 +0000 (16:19 +0200)] 
daemon: fixed memleak in network address pack

10 years agodaemon: fixed memleak in CLI
Marek Vavruša [Mon, 27 Apr 2015 14:18:42 +0000 (16:18 +0200)] 
daemon: fixed memleak in CLI

10 years agodaemon/net: use REUSEADDR and IPV6ONLY for bound sockets
Marek Vavruša [Mon, 27 Apr 2015 14:18:31 +0000 (16:18 +0200)] 
daemon/net: use REUSEADDR and IPV6ONLY for bound sockets

this disables dual-stack and allows binding to both v4 and v4-in-v6
addresses separately

10 years agodaemon/worker: timeouts for queries/connections
Marek Vavruša [Mon, 27 Apr 2015 14:17:29 +0000 (16:17 +0200)] 
daemon/worker: timeouts for queries/connections

fixes #22

10 years agotests: added reserve test for array
Marek Vavruša [Sun, 26 Apr 2015 21:38:35 +0000 (23:38 +0200)] 
tests: added reserve test for array

10 years agotests: added parameter checks for zonecut
Marek Vavruša [Sun, 26 Apr 2015 21:37:57 +0000 (23:37 +0200)] 
tests: added parameter checks for zonecut

10 years agodaemon/worker: reworked multiplexed worker
Marek Vavruša [Fri, 24 Apr 2015 16:31:10 +0000 (18:31 +0200)] 
daemon/worker: reworked multiplexed worker

* each query is assigned a task
* each task contains request, some primitives and mempool
* worker can process multiple tasks at once and
  offload I/O to event loop

Not finished:

* it depends on icmp/system timeouts, #22
* tcp reads are going to be bad if the messages
  arrive fragmented #21

10 years agolib/resolve: check for non-rd query input
Marek Vavruša [Sun, 26 Apr 2015 21:10:55 +0000 (23:10 +0200)] 
lib/resolve: check for non-rd query input

10 years agolib/rplan: removed long-lived wr transactions
Marek Vavruša [Sun, 26 Apr 2015 21:09:34 +0000 (23:09 +0200)] 
lib/rplan: removed long-lived wr transactions

the reason is that LMDB allows only 1 write transaction
per thread, and this doesn’t work well with multiplexed
requests. there is probably going to be some performance hit,
but now transactions are scoped for each cache operation

10 years agodaemon/worker: partially implemented multiplexed resolution
Marek Vavruša [Fri, 24 Apr 2015 07:13:20 +0000 (09:13 +0200)] 
daemon/worker: partially implemented multiplexed resolution

the worker now creates a resolution context copy,
and keeps it if the query requires iterative queries.
the worker_exec() is now a reentrant function that gets
called with incoming data until the resolution is done,
and it sends the answer

10 years agodaemon/io: don’t use handle data for buffers
Marek Vavruša [Fri, 24 Apr 2015 07:11:01 +0000 (09:11 +0200)] 
daemon/io: don’t use handle data for buffers

TODO: per-loop freelists are implemented

10 years agolib/resolve: initialize answer from query (if provided)
Marek Vavruša [Fri, 24 Apr 2015 07:09:00 +0000 (09:09 +0200)] 
lib/resolve: initialize answer from query (if provided)

10 years agodaemon/lua: use rawget/rawset to avoid metatable evaluation
Marek Vavruša [Thu, 23 Apr 2015 12:33:17 +0000 (14:33 +0200)] 
daemon/lua: use rawget/rawset to avoid metatable evaluation

10 years agodaemon/engine: unload module if loaded
Marek Vavruša [Thu, 23 Apr 2015 12:33:00 +0000 (14:33 +0200)] 
daemon/engine: unload module if loaded

10 years agoMerge branch 'resolve-split-api'
Marek Vavruša [Wed, 22 Apr 2015 20:57:59 +0000 (22:57 +0200)] 
Merge branch 'resolve-split-api'

10 years agodoc: updated API doc and examples
Marek Vavruša [Wed, 22 Apr 2015 20:57:22 +0000 (22:57 +0200)] 
doc: updated API doc and examples