Commit Graph

36264 Commits

Author SHA1 Message Date
Artem Boldariev
69e1d3804e doth test: extend with HTTP endpoints reconfiguration check
This commit add a check which verifies that HTTP endpoints are being
picked up properly by the BIND instance on a reconfiguration.

(cherry picked from commit 7822670d0f)
2022-06-28 16:38:21 +03:00
Artem Boldariev
12a6fafae2 Update CHANGES [GL #3415]
Mention that the settings are now applied properly on reconfiguration.

(cherry picked from commit 502c78c339)
2022-06-28 16:38:18 +03:00
Artem Boldariev
b6b07c5646 Update the set of HTTP endpoints on reconfiguration
This commit ensures that on reconfiguration the set of HTTP
endpoints (=paths) is being updated within HTTP listeners.

(cherry picked from commit d2e13ddf22)
2022-06-28 16:37:31 +03:00
Artem Boldariev
bb8ba2c027 Update max concurrent streams limit in HTTP listeners on reconfig
This commit ensures that HTTP listeners concurrent streams limit gets
updated properly on reconfiguration.

(cherry picked from commit e72962d5f1)
2022-06-28 16:37:31 +03:00
Artem Boldariev
1ccbb24078 Update HTTP listeners quotas on reconfiguration
This commit ensures that on reconfiguration a proper value for HTTP
connections limit is picked up.

The commit also refactors how listeners settings are updated so that
there is less code duplication.

(cherry picked from commit a2379135fa)
2022-06-28 16:37:31 +03:00
Artem Boldariev
63a4c12227 Store HTTP quota size inside a listenlist instead of the quota
This way only quota size is passed to the interface/listener
management code instead of a quota object. Thus, we can implement
updating the quota object size instead of recreating the object.

(cherry picked from commit 3f0b310772)
2022-06-28 16:37:31 +03:00
Matthijs Mekking
1330732872 Merge branch 'matthijs-dnssec-policy-defaults-in-config-dot-c-v9_18' into 'v9_18'
[v9_18] Move built-in dnssec-policies into defaultconf

See merge request isc-projects/bind9!6493
2022-06-28 13:30:26 +00:00
Matthijs Mekking
35f6cabab4 Add isccfg duration utility functions
Add function isccfg_duration_toseconds and isccfg_parse_duration to get
rid of code duplication.

(cherry picked from commit d8dae61832)
2022-06-28 14:37:26 +02:00
Matthijs Mekking
feaf3950fd Fix a bug in the duration_fromtext function
The function actually did not enforce that the duration string starts
with a P (or p), just that there is a P (or p) in the string.

(cherry picked from commit 8e18fa5874)
2022-06-28 14:37:19 +02:00
Matthijs Mekking
8af88d4111 Also inherit from "default" for "insecure" policy
Remove the duplication from the defaultconf and inherit the values
not set in the "insecure" policy from the "default" policy. Therefore,
we must insist that the first read built-in policy is the default one.

(cherry picked from commit c2a7950417)
2022-06-28 14:37:10 +02:00
Matthijs Mekking
bd15b7c3c6 Add change entry for dnssec-policy in defaultconf
(cherry picked from commit 80b55f9cfa)
2022-06-28 14:37:02 +02:00
Matthijs Mekking
fd34ea8523 Nit changes in keymgr and kasp
Use the ISC_MAX define instead of "x = a > b ? a : b" paradigm.

Remove an unneeded include.

(cherry picked from commit 5d6f0de84b)
2022-06-28 14:36:53 +02:00
Matthijs Mekking
e16cfce91d When loading dnssec-policies, inherit from default
Most of the settings (durations) are already inheriting from the default
because they use the constants from lib/dns/kasp.h. We need them as
constants so we can use them in named-checkconf to verify the policy
parameters.

The NSEC(3) parameters and keys should come from the actual default
policy. Change the call to cfg_kasp_fromconfig() to include the default
kasp. We also no longer need to corner case where config is NULL we load
the built-in policy: the built-in policies are now loaded when config is
set to named_g_config.

Finally, add a debug log (it is useful to see which policies are being
loaded).

(cherry picked from commit 20acb8d3a3)
2022-06-28 14:36:45 +02:00
Matthijs Mekking
03c0c72aeb Store built-in dnssec-policies in defaultconf
Update the defaultconf with the built-in policies. These will now be
printed with "named -C".

Change the defines in kasp.h to be strings, so they can be concatenated
in the defaultconf. This means when creating a kasp structure, we no
longer initialize the defaults (this is fine because only kaspconf.c
uses dns_kasp_create() and it inherits from the default policy).

In kaspconf.c, the default values now need to be parsed from string.

Introduce some variables so we don't need to do get_duration multiple
times on the same configuration option.

Finally, clang-format-14 decided to do some random formatting changes.

(cherry picked from commit 5ff414e986)
2022-06-28 14:36:38 +02:00
Matthijs Mekking
4fb2ecd444 Move duration structure to libisccfg/duration
Having the duration structure and parsing code here, it becomes
more accessible to be used in other places.

(cherry picked from commit a28d919503)
2022-06-28 14:36:31 +02:00
Michał Kępień
d75ce232a6 Merge branch '3216-run-sslyze-in-gitlab-ci-v9_18' into 'v9_18'
[CVE-2022-1183] [v9_18] Run sslyze in GitLab CI

See merge request isc-projects/bind9!6492
2022-06-27 21:19:49 +00:00
Michał Kępień
a649bd2148 Also test DNS-over-TLS code using sslyze
Since sslyze can test any TLS-enabled server, also use it for exercising
DNS-over-TLS code rather than just DNS-over-HTTPS code.

(cherry picked from commit 4f12892740)
2022-06-27 23:10:00 +02:00
Michał Kępień
4cda066de2 Add regression test for CVE-2022-1183
If sslyze is available in PATH, run it in a loop as part of the "doth"
system test.

(cherry picked from commit e97b4697cf)
2022-06-27 23:10:00 +02:00
Matthijs Mekking
11abb69fb4 Merge branch '3422-dnssec-policy-clarifications-v9_18' into 'v9_18'
[v9_18] Add some clarifications wrt dynamic zones

See merge request isc-projects/bind9!6489
2022-06-27 09:54:52 +00:00
Matthijs Mekking
f2fc0e9c9e Add some clarifications wrt dynamic zones
These were suggested by GitLab user @elmaimbo.

(cherry picked from commit fb517eb52a)
2022-06-27 11:04:11 +02:00
Tom Krizek
def7601987 Merge branch '3169-named-conf-intro-and-links-v9_18' into 'v9_18'
Reworked named.conf introduction and link anchors [v9_18]

See merge request isc-projects/bind9!6488
2022-06-24 14:55:08 +00:00
Ron Aitchison
22ac5003b5 Added explanations or Argument, Value, and Directive to the ARM
(cherry picked from commit d44cb9f194)
2022-06-24 16:47:28 +02:00
Petr Špaček
5fbeebc6f3 Add link to glob definition for include directive
(cherry picked from commit bb2a19d655)
2022-06-24 16:47:28 +02:00
Suzanne Goldlust
1fc681cce6 Minor text nitpicking around dnssec-policy grammar reference
(cherry picked from commit f4503061ba)
2022-06-24 16:47:28 +02:00
Petr Špaček
19fde8b8f1 Remove ambiguous link anchors for logging { file } statement
Unfortunatelly logging and zone blocks use file statements with
different semantics but the same name.

There is no sane way to disambiguate them in text, so let's remove the
link anchor from logging so we can link to the file statement in zone.

My assumption is that linking to logging { file } is very unlikely
because logging is self-contained in one block but zone config is all
over the place.

(cherry picked from commit fbcaa44851)
2022-06-24 16:47:28 +02:00
Petr Špaček
1b9c74152e Remove ambiguous link anchors for keys statement
Unfortunatelly dnssec-policy and servers blocks use keys statements with
a totally different grammar and semantics but the same name.
There is no sane way to disambiguate them in text, so let's remove the
link anchors to prevent errorneous linking.

(cherry picked from commit d6b2423c99)
2022-06-24 16:47:28 +02:00
Petr Špaček
a7da2d4993 Change statement->argument terminology for control channel
control { inet ... allow keys read-only }; are not actual statements
but in fact arguments of a statement. Remove .. namedconf:statement::
syntax to avoid collisions with other statements of the same name.

(cherry picked from commit caf2675ef8)
2022-06-24 16:47:28 +02:00
Petr Špaček
70924290ca Deduplicate dnssec-policy definition in the ARM
(cherry picked from commit 3233414a53)
2022-06-24 16:47:28 +02:00
Petr Špaček
b023b62b8d Deduplicate null definition in the ARM logging section
(cherry picked from commit fa2ba5423b)
2022-06-24 16:47:28 +02:00
Petr Špaček
c496ffe4f4 Deduplicate {use,avoid}-v{4,6}-udp-ports definitions in the ARM
Statements affected:
use-v4-udp-ports
use-v6-udp-ports
avoid-v4-udp-ports
avoid-v6-udp-ports

(cherry picked from commit cd1b9aa052)
2022-06-24 16:47:28 +02:00
Petr Špaček
df2c19c19b Deduplicate request-expire definition in the ARM
(cherry picked from commit 6e634c43cd)
2022-06-24 16:47:27 +02:00
Petr Špaček
8af0d9eca7 Deduplicate provide-ixfr definition in the ARM
(cherry picked from commit 22e6c8a29e)
2022-06-24 16:47:27 +02:00
Petr Špaček
98445cc32b Deduplicate request-ixfr definition in the ARM
Let's be consistent and put all definitions in the options block.

(cherry picked from commit 14389bc446)
2022-06-24 16:47:27 +02:00
Petr Špaček
0dd45cb17f Deduplicate notify-source, notify-source-v6 definitions in the ARM
(cherry picked from commit 08a3cd7ae4)
2022-06-24 16:47:27 +02:00
Petr Špaček
3688d706da Deduplicate request-nsid definition in the ARM
(cherry picked from commit e91529a48b)
2022-06-24 16:47:27 +02:00
Petr Špaček
c611110c9b Deduplicate query-source, query-source-v6 definitions in the ARM
(cherry picked from commit 92a125b9c4)
2022-06-24 16:47:27 +02:00
Petr Špaček
8e5925c25a Deduplicate transfer-source, transfer-source-v6 definitions in the ARM
(cherry picked from commit 538f5a7520)
2022-06-24 16:47:27 +02:00
Petr Špaček
8a2470d559 Deduplicate transfer-format definition in the ARM
(cherry picked from commit b6eb0b298d)
2022-06-24 16:47:27 +02:00
Petr Špaček
97530e74e0 Deduplicate send-cookie definition in the ARM
(cherry picked from commit 7937c4bc9c)
2022-06-24 16:47:27 +02:00
Petr Špaček
7390e1e113 Deduplicate max-udp-size definition in the ARM
(cherry picked from commit 8ac82b4f30)
2022-06-24 16:47:27 +02:00
Petr Špaček
9ccadcc310 Deduplicate edns-udp-size definition in the ARM
(cherry picked from commit 624bbf403c)
2022-06-24 16:47:27 +02:00
Petr Špaček
40b9aa2e0b Deduplicate max-zone-ttl definition in the ARM
This is confusing as hell, but we cannot fix that in the manual itself.
At least now the user is made aware of two distinct defaults.

(cherry picked from commit 405a0931ea)
2022-06-24 16:47:27 +02:00
Petr Špaček
e28050e7a4 Deduplicate allow-update definition in the ARM
(cherry picked from commit 420a7331a8)
2022-06-24 16:47:27 +02:00
Ron Aitchison
0c52d244ba Reference new named.conf description instead of man page
(cherry picked from commit cf85e776c6)
2022-06-24 16:47:26 +02:00
Ron Aitchison
b8fa35789e Remove line numbering from config file examples
(cherry picked from commit 31e3d1aaf7)
2022-06-24 16:47:26 +02:00
Ron Aitchison
309a75e56b Changed all references from clause to block
(cherry picked from commit c40a983334)
2022-06-24 16:47:26 +02:00
Ron Aitchison
f16cfcebe4 Restructure introduction to named.conf in the ARM
(cherry picked from commit b01262b7f2)
2022-06-24 16:47:26 +02:00
Petr Špaček
667335bd1c Add link anchors to statements and blocks in the ARM
All statements now use .. namedconf:statement:: or
.. rndcconf:statement:: syntax provided by our Sphinx extension.

This has several consequences:
- It changes how statement headings are rendered
- Statements are indexed and show up as separate items in doc
  search results (in the HTML version)
- Statements can be linked to using either :any:`statement` or
  :namedconf:ref:`statement` syntax (not used in this commit)
- Statements can be categorized and printed using ..
  namedconf:statatementlist:: syntax (not used in this commit)

(cherry picked from commit e5b7022dcb)
2022-06-24 16:47:25 +02:00
Michał Kępień
22ac7b0a4a Merge branch '3416-document-key-lifetime-min-length-v9_18' into 'v9_18'
[v9_18] Document what is a too short key lifetime

See merge request isc-projects/bind9!6483
2022-06-23 10:53:54 +00:00
Matthijs Mekking
b18e6455d1 Document what is a too short key lifetime
To give a hint to users that get an error that the key lifetime is
shorter than the time it takes to do a rollover.

(cherry picked from commit c47735b86b)
2022-06-23 12:40:47 +02:00