- Jan 31, 2018
-
-
Vladimír Čunát authored
Some parts were hand-written, apparently.
-
- Jan 30, 2018
-
-
Tomas Krizek authored
-
- Jan 24, 2018
- Jan 23, 2018
-
-
Petr Špaček authored
-
Petr Špaček authored
-
Config tests now have ability to run daemon with different arguments and to check exit code.
-
Arguments --keyfile, -k for managed mode and --keyfile-ro, -K for unmanaged (readonly) mode. Automatic setting based on the file permission is removed because it was confusing and could easily lead to state where automatic update does not happen because of unexpected file permissions. Check if folder is writeable was moved into Lua code. Default unmanaged keyfile path can be specified at compile time with option KEYFILE_DEFAULT. This default configuration can be disabled in configuration file with trust_anchors.keyfile_default = nil.
-
Petr Špaček authored
It is enabled by default.
-
Petr Špaček authored
-
Petr Špaček authored
RFC 6761 mandates functionality implemented by policy module, so it is now loaded by default. Users with special needs can still unload the module.
-
- Jan 08, 2018
-
-
Marek Vavruša authored
This is a followup on addition of trace callbacks in the resolver library, to get rid of the Lua/C interfacing in daemon and unify it with the log tracing. All modules can now install completion callback on the kr_request object that will be called after the resolution is done.
-
This implements worker coroutines in Lua to perform non-blocking I/O and do many things concurrently. For example a file watcher can be now implemented as: ``` local watcher = notify.opendir('/etc') watcher:add('hosts') -- Watch changes to /etc/hosts worker.coroutine(function () for flags, name in watcher:changes() do for flag in notify.flags(flags) do print(name, notify[flag]) end end end) ``` In order to make this work, the runtime uses the cqueues library which can run coroutines concurrently, and return a file descriptor to poll on if it's blocked. The worker takes that file descriptor and calls `event.socket(pollfd, resume_callback)` so that libuv can wake up the worker when its ready again. The cqueues library is still optional, but if it's not present following stuff won't work: * worker.coroutine() * worker.sleep()
-
- Jan 04, 2018
- Dec 21, 2017
-
-
Marek Vavruša authored
This reverts commit 0a891eb6.
-
Marek Vavruša authored
-
Marek Vavruša authored
This allows debugging of what records were used for final answer.
-
Marek Vavruša authored
-
Marek Vavruša authored
This is useful in many troubleshooting scenarios when you want debug logs just for a single request. It's going to expand on TRACE flag functionality in the next PRs, so that special requests can be invoked with various tracers attached. Currently this is only available in the C modules that can set the callback, it's not called anywhere in the library yet.
-
Marek Vavruša authored
this allows for changing request settings or performing other actions just after the request is created.
-
- Dec 08, 2017
-
-
Check differences between real and monotonic time. It clears cache when this diffrence changes since last cache clear.
-
Monotonic time from libuv function uv_now (wrapped in kr_now) is used for query timeout, stats and RTT in reputation cache. Cache, DNSSEC Validation and Cookies use real time.
-
Petr Špaček authored
Some RR type definitions present in IANA DNS parameters registry were missing in kresd. This commit synchronizes the tables with IANA registry as of 2017-12-08 13:20 UTC. At the same time, this commit is fixup! converted constant tables, support kres.type.TYPE1234 The mentioned commit accidentally removed NULL definition which broke TA signaling module.
-
- Dec 07, 2017
-
-
This module is enabled by default, but disabled in Deckard tests.
-
- Dec 04, 2017
-
-
Vitezslav Kriz authored
-
- Nov 28, 2017
- Nov 24, 2017
-
-
Marek Vavruša authored
Also fixed improper promotion of `ffi` to global variable. ``` $ luacheck --codes daemon/lua/ Checking daemon/lua/config.lua OK Checking daemon/lua/kres-gen.lua OK Checking daemon/lua/kres.lua OK Checking daemon/lua/sandbox.lua OK Checking daemon/lua/trust_anchors.lua OK Checking daemon/lua/zonefile.lua OK Total: 0 warnings / 0 errors in 6 files ```
-
Marek Vavruša authored
The library now depends on libknot >= 2.4.0 (in Debian stable), this allows us to remove a dead code and sed-ing of the kres.lua Added a basic config tests to check that constants still work, and basic interface to rrsets still works after the change.
-
Marek Vavruša authored
-
Marek Vavruša authored
The difficulty with using structs as constant tables is that access to non-existent fields throws an error. This is difficult to handle without wrapping every access in a pcall, for example in predict module: ``` error: /usr/local/lib/kdns_modules/predict.lua:34: 'struct rr_type' has no member named 'TYPE65535' ``` So I converted the constant tables into regular Lua tables, and added a metatable for RR types to allow looking up unnamed types, in the TYPE%d format. Looking up non-existent fields will now return nil instead of throwing an error.
-
Marek Vavruša authored
The config tests locked up on error as if error was raised from the event callback, it would never reach the `quit()` statement, so server would never close on error. Added a script to make running these types of tests a little bit nicer and to allow concurrent execution of config tests. Added a test for the predict module, that fails on prediction of unknown types: ``` error: /usr/local/lib/kdns_modules/predict.lua:34: 'struct rr_type' has no member named 'TYPE65535' ```
-
- Nov 21, 2017
-
-
Vladimír Čunát authored
-
- Nov 20, 2017
-
-
Vladimír Čunát authored
For now I didn't touch the generator to be correct on this line, as we will probably want to change it after bumping minimal libknot version.
-
Vladimír Čunát authored
-
- Nov 02, 2017