Commit Graph

1372 Commits

Author SHA1 Message Date
W.C.A. Wijngaards
0f78bea4a3 - Fix #954: Inconsistent RPZ handling for A record returned along with
CNAME.
2023-10-17 16:47:04 +02:00
W.C.A. Wijngaards
39df4f0923 - disable-edns-do, queriers receive no EDNS in response if the
disable-edns-do option is enabled and they set the DO flag. And unit test
  for that.
2023-10-04 13:54:05 +02:00
George Thessalonikefs
9342bf685e - Fix misplaced comment. 2023-10-02 16:13:23 +02:00
W.C.A. Wijngaards
bd5dc855af - Fix rpz tcp-only action with rpz triggers nsdname and nsip. 2023-09-18 09:55:39 +02:00
W.C.A. Wijngaards
6e65343895 - Fix authority zone answers for obscured DNAMEs and delegations. 2023-09-14 11:37:49 +02:00
Philip Homburg
1c8f0e0fc5 Avoid calling comm_point_udp_ancil_callback from comm_point_create_udp 2023-09-07 16:35:22 +02:00
Philip Homburg
17a557dfd5 Fix #928 (1.18 doesn't start on macOS/SunOS) 2023-09-07 16:35:22 +02:00
George Thessalonikefs
49e4258102 - For #762: Interaction between DNS Cookies and source IP ratelimiting
by allowing Cookies to bypass the ratelimit, but still allowing
  ratelimit to valid DNS Cookie clients via the new
  ip-ratelimit-cookie option.
2023-08-08 10:14:03 +02:00
George Thessalonikefs
4ccb613396 Merge branch 'master' into features/downstream-cookies 2023-08-05 20:37:48 +02:00
George Thessalonikefs
f97927a47e Merge branch 'master' into features/ede-caching-cachedb 2023-07-30 14:17:52 +02:00
George Thessalonikefs
6819c1e444 - Merge #759 from Tom Carpay: Add EDE (RFC8914) caching. 2023-07-30 11:48:04 +02:00
George Thessalonikefs
0912015fb9 - Review for #790: Fix memory leak. 2023-07-28 17:21:15 +02:00
George Thessalonikefs
50ea4a1072 Address review comments for #759:
- Decrease allocations for "" EDE strings when loading the cachedump.
- Check for existence of EDE code before attaching.
2023-07-28 12:56:13 +02:00
George Thessalonikefs
6289238cd6 - For #889: Account for num_detached_states before possible
mesh_state_delete when erroring out.
2023-07-21 21:05:38 +02:00
George Thessalonikefs
201da1f50a Merge branch 'free_memory_in_error_case' of https://github.com/borisVanhoof/unbound into borisVanhoof-free_memory_in_error_case 2023-07-21 17:04:33 +02:00
George Thessalonikefs
862fa0d514 Merge branch 'module-error' of https://github.com/trofi/unbound into trofi-module-error 2023-07-20 12:08:27 +02:00
George Thessalonikefs
846b158304 - Remove redundant checks when attaching EDE to a SERVFAIL answer. 2023-07-19 15:26:08 +02:00
George Thessalonikefs
95604a90e8 Review for #759:
- Keep EDE information for keys close to key creation.
- Fix inconsistencies between reply and cached EDEs.
- Incorporate EDE caching checks in EDE tests.
- Fix some EDE cases where missing DNSKEY was wrongly reported.
2023-07-19 15:20:44 +02:00
George Thessalonikefs
f5a2a58ce3 Review for #759:
- Fix SEGFAULT in load_cache control command.
- Change reason_bogus_str to an explicit NULL-terminated string.
- Fix potential memory leak when discarding a message for referrals and
  0 TTL answers.
- Fix reason_bogus initialization in localzone answers.
- reply_info creation in validator is always regional.
2023-07-17 17:26:31 +02:00
George Thessalonikefs
606e5a0a5f Merge branch 'cleanup_cppcheck' of https://github.com/chipitsine/unbound into chipitsine-cleanup_cppcheck 2023-07-13 11:49:41 +02:00
George Thessalonikefs
15b8d8b96a Merge branch 'master' into features/ede-caching 2023-07-13 11:25:59 +02:00
George Thessalonikefs
a952ac17be Merge branch 'tilan7663-subnet_cache_prefetch' into subnet_cache_prefetch 2023-07-07 16:50:58 +02:00
George Thessalonikefs
40e47bf767 - For #664: easier code flow for subnetcache prefetching.
- For #664: add testcase.
2023-07-06 22:22:21 +02:00
George Thessalonikefs
2069271384 - Merge #802: add validation EDEs to queries where the CD bit is set.
- For #802: Cleanup comments and add RCODE check for CD bit test case.
2023-07-03 14:48:39 +02:00
George Thessalonikefs
014db3fb03 - For #802: Cleanup comments and add RCODE check for CD bit test case. 2023-07-03 14:40:01 +02:00
W.C.A. Wijngaards
5aa47fb1fa - Fix dereference of NULL variable warning in mesh_do_callback. 2023-07-03 13:50:39 +02:00
George Thessalonikefs
41dac805f5 - Merge #892: Add cachedb hit stat. Introduces 'num.query.cachedb' as
a new statistical counter.
2023-06-27 12:46:26 +02:00
Sergei Trofimovich
d10a889a68 config: improve handling of unknown modules
The change fixes module print when specified module is unknown. On
example config:

    server:
      module-config: "respip valdator iterator"

Before the change printed error looked like:

    error: Unknown value in module-config, module: ''. This module is
    not present (not compiled in), See the list of linked modules with
    unbound -V

After the change module is printed as expected:

    error: Unknown value in module-config, module: 'valdator'. This
    module is not present (not compiled in), See the list of linked
    modules with unbound -V

Module truncation happens because parse error does not guarantee that
leading whitespace is removed by `module_factory()` call.

The change always removes leading whitespace (if present).
2023-06-19 18:20:22 +01:00
Philip Homburg
52581f8644 Fix for issue #887 (Timeouts to forward servers on BSD based system with ASLR)
and proabbly #516 (Stream reuse does not work on Windows)
2023-06-09 13:59:31 +02:00
George Thessalonikefs
db5cf5851d - More efficient mesh accounting per client. 2023-05-30 23:34:31 +02:00
George Thessalonikefs
4f52be4db9 - Introduce num.query.cachedb to track cache hits for the external cache. 2023-05-30 17:49:50 +02:00
Boris VANHOOF
a21bc23139 free memory in error case 2023-05-23 09:23:03 +02:00
Boris VANHOOF
62d54d8091 remove unused function 2023-05-23 09:22:35 +02:00
W.C.A. Wijngaards
59fd48c226 - Fix to remove unused variables from RPZ clientip data structure. 2023-05-19 16:36:31 +02:00
W.C.A. Wijngaards
da78c42f88 - Fix RPZ removal of client-ip, nsip, nsdname triggers from IXFR. 2023-05-19 14:38:41 +02:00
W.C.A. Wijngaards
1fb78afc29 - Fix warning in windows compile, in set_recvtimestamp. 2023-05-11 09:32:59 +02:00
Philip Homburg
4a04ba813a Merge branch '0ttl' 2023-04-26 17:14:15 +02:00
Philip Homburg
1aa2c318e7 Remove msg_del_for_0ttl, call msg_cache_remove directly 2023-04-26 17:11:29 +02:00
W.C.A. Wijngaards
8058dc9127 - Fix for #882: document variable to stop doxygen warning. 2023-04-26 14:07:33 +02:00
Vadim Fedorenko
04540f82e5 config: add sock_queue_timeout configuration
Add sock_queue_timeout config option to have queue timeout configurable.

Signed-off-by: Vadim Fedorenko <vadfed@meta.com>
2023-04-26 03:27:19 -07:00
Vadim Fedorenko
a197aac2f6 timeval_func: move all timeval manipulation to separate file
There are several definitions of the same functions manipulating timeval
structures. Let's move them to separate file and arrange the code
preperly.

Signed-off-by: Vadim Fedorenko <vadfed@meta.com>
2023-04-26 03:23:41 -07:00
Vadim Fedorenko
648ad4db6f Linting change.
Remove config parser/lexer code as it's rebuilded every time but can
break adding new config options.
Also clean up the code base to avoid mixing actual code changes and lint
issues.

Signed-off-by: Vadim Fedorenko <vadfed@meta.com>
2023-04-25 17:05:00 -07:00
Ilya Shipitsin
cba1350886
services/authzone.c: remove redundant check
found by cppcheck

services\authzone.c:7513:12: style: Condition 'rrlist[i]' is always true [knownConditionTrueFalse]
2023-04-24 11:45:41 +02:00
W.C.A. Wijngaards
fe46bc47d7 - Fix for #878: Invalid IP address in unbound.conf causes Segmentation
Fault on OpenBSD.
2023-04-19 09:56:31 +02:00
Philip Homburg
1ac9b7548b Small fixes from Wouter's review 2023-03-23 15:15:54 +01:00
Philip Homburg
eb7eff4fc7 Extra consistency check to make sure that when TLS is requested, either we
set up a TLS connection or we return an error.
2023-03-23 15:00:10 +01:00
Philip Homburg
9d7b1d3127 Fix issue #860: Bad interaction with 0 TTL records and serve-expired 2023-03-22 15:23:47 +01:00
Philip Homburg
fb06364014 Fix issue #825: interaction between ECS and serve-expired. 2023-02-21 09:20:28 +01:00
W.C.A. Wijngaards
111e66ae64 Changelog note for #819, generate configparser.c and comment syntax change.
- Merge #819: Added new static zone type block_a to suppress all A
  queries for specific zones.
2023-01-20 16:19:20 +01:00
Wouter Wijngaards
6a4a9435d1
Merge pull request #819 from pavel-odintsov/pavel/suppress_a
Added new static zone type block_a to suppress all A queries for specific zones
2023-01-20 16:18:05 +01:00