| Commit message (Collapse) | Author | Age | Files | Lines |
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
It was a confusing way of repurposing the field.
My comment from over five years ago (129002fc0d) said that
some external C modules might be relying on this.
But that certainly sounds moot nowadays. To get more confidence,
I rechecked all kr_module::data references (as found by libclang).
|
| |
| |
| |
| |
| |
| | |
If the module's init() failed or wasn't even called,
I see it as an API error to call deinit().
When init() fails, it should take care of cleanup itself.
|
|/ |
|
| |
|
|
|
|
|
|
|
|
| |
We'll utilize this for cache, so this will be an easy way for GC
to access the mmapped_* symbols.
In lib/ we usually prefix symbols by kr_ but I don't think it's worth
the hassle in this case, as mmapped_ seems like a good enough prefix.
|
| |
|
| |
|
| |
|
|
|
|
| |
In particular this turns off those debug logs by default.
|
| |
|
|\ |
|
| |
| |
| |
| |
| | |
As with some other aspects, these DNAMEs do not work exactly as
in a real zone, e.g. they don't cause occlusion.
|
| |
| |
| |
| |
| |
| |
| |
| | |
In case of no error, the index is returned,
but `int` isn't a great choice for returning array indices.
(though I doubt that we can get anywhere near 2^31 elements in practice)
Detected by Coverity.
|
| |
| |
| |
| |
| | |
See:
https://gitlab.nic.cz/knot/knot-resolver/-/merge_requests/1590#note_304380
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
If the tag and algorithm of DS and DNSKEY do not correspond, or in case
the DNSKEY is revoked, set EDE code "DNSKEY Missing".
If both match, but the algorithm is not supported, set EDE code
"Unsupported DNSKEY Algorithm".
In case RRSIGs for DNSKEY exist, but can't be validated due to a key
error, set EDE code "RRSIGs Missing".
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
dnssec:
* Provide a way to retrieve whether a DNSKEY has the Zone Key bit set,
and add bindings for Lua modules (kr_dnssec_key_zonekey_flag), like
kr_dnssec_key_sep_flag.
* In kr_ds_algo_support() provide a way to retrieve what is wrong with
the keys.
* Check if a RRSIG RR has the signature expired already before
inception time.
validator:
* Set EDE "Unsupported NSEC3 Iterations Value" when downgrading.
* Set EDE "Signature Expired before Valid" when checking RRSIGs.
* Set EDE "No Zone Key Bit Set" when a DNSKEY with the Zone Key Bit
set to 0 is discarded.
* Instead of the generic "Other Error" with extra text
"unsupported digest/key", set appropriate EDEs
"Unsupported DNSKEY Algorithm" and "Unsupported DS Digest Type".
resolver:
* Set EDE "No Reachable Authority" when it is decided that all
authoritative servers are unreachable or misbehaving.
Some parts adjusted by vcunat, in particular construction of EDE messages.
|
| |
| |
| |
| | |
It's trivial really, and I'd like to use it now.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
It is not guaranteed yet that the request will finish in state DONE.
This prevents other EDE codes from being applied to the request and in
case the request ends in FAIL state it produces a SERVFAIL answer with
EDE "Stale Answer", which is a bit weird.
Move setting EDEs in answer_finalize in the serve_stale module, where
the proper EDE in case of NXDOMAIN is set too.
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Adds the following extended error codes:
* 25 (Signature Expired before Valid): KNOT_EDNS_EDE_EXPIRED_INV
* 26 (Too Early): KNOT_EDNS_EDE_TOO_EARLY
* 27 (Unsupported NSEC3 Iterations Value): KNOT_EDNS_EDE_NSEC3_ITERS
* 28 (Unable to conform to policy): KNOT_EDNS_EDE_NONCONF_POLICY
* 29 (Synthesized): KNOT_EDNS_EDE_SYNTHESIZED
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
It was supposed to answer NOTIMP, but was returning FAIL instead of
DONE and so the answer was SERVFAIL.
Also added EDE code "Not Supported" for clarity.
|
| |
| |
| |
| |
| | |
Setting log_groups({ 'zonecut' }) just leads to a warning and no
"zone cut" logging shown.
|
| | |
|
| |
| |
| |
| |
| | |
Missing include caused issues with unknown `KR_EXPORT`, e.g.:
https://gitlab.nic.cz/knot/knot-resolver/-/jobs/1142787#L2801
|
|\| |
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The problem mainly affected subnets not aligned on whole bytes,
but maybe also others. Reported:
https://lists.nic.cz/hyperkitty/list/knot-resolver-users@lists.nic.cz/message/6P2JPK72WMVLP45TDV42DTACEA2N5NW2/
I'm really sorry about this; no idea why I thought that the simple
multiplication would suffice.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
(u)intptr_t casts seem the best in terms of compliance:
https://stackoverflow.com/q/45220134/587396
Otherwise with clang 18 we can get warnings like
../$path:$line:$col: runtime error: applying non-zero offset $num to null pointer
SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior ../$path:$line:$col
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| | |
- Upstream last maintained 3.0.x in summer 2022.
- Our packaging shouldn't be affected, neither the new one, nor OBS.
- If someone updates resolver, it shouldn't be too hard
to update libknot as well.
- Maintenance on resolver side still needed effort for kres-gen-30.lua
|
| |\ |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When positive wildcard expansion happens, NSEC(3) records are needed
to prove that the expansion was allowed. If the NSEC3 had too many
iterations, we downgrade the answer to insecure status, but
unintentionally we also dropped the NSEC3 record from the answer.
That was breaking DNSSEC validation of that answer, e.g. when
forwarding to Knot Resolver. The validator needs the NSEC3 -
either to validate the expansion or to determine that it's too expensive.
|
| | |
| | |
| | |
| | |
| | |
| | | |
Let's avoid reloading the RO transaction unless necessary.
For example, when normal config reload happens (one kresd at a time),
we most likely do *not* want to reload the rule DB prematurely.
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
| | | |
|
|\| | |
|
| | | |
|
| | | |
|