Commit graph

39592 commits

Author SHA1 Message Date
Mark Andrews
00a09e0d35 Only set key->engine if engine != NULL 2023-08-09 23:48:17 +00:00
Mark Andrews
d527ae11c9 Fix clang formatting 2023-08-09 23:48:17 +00:00
Mark Andrews
3907de98ca Fix line wrap 2023-08-09 23:48:17 +00:00
Mark Andrews
0aeffb55c9 Merge branch '4245-incorrect-return-values-in-rpz-s-addr-and-drop-function' into 'main'
Resolve "Incorrect return values in rpz's addr and drop functions"

Closes #4245

See merge request isc-projects/bind9!8172
2023-08-09 23:33:25 +00:00
Mark Andrews
1394f12a1c Fix 'addr', 'ckresult' and 'drop' functions
'addr', 'ckresult' and 'drop' should return 0 rather than 1 after
calling 'setret' as the error has been logged and these functions
are not expect to fail.
2023-08-09 10:45:38 +10:00
Michal Nowak
a5cf49c378 Merge branch 'mnowak/cross-version-test' into 'main'
Cross-version testing with named configurations

See merge request isc-projects/bind9!7863
2023-08-08 17:37:19 +00:00
Michal Nowak
4eac32fe23
Exclude dupsigs and keymgr2kasp from cross-version-config-tests
pytest should not schedule dupsigs and keymgr2kasp system tests removed
in BIND 9 mainline but still present in BIND 9 baseline version
(v9.19.15). (Can be dropped once the v9.19.16 tag is present.)
2023-08-08 19:18:36 +02:00
Michal Nowak
cc54211baa
Cross-version testing with named configurations
In #3381 (and #3385), we committed a backward-incompatible change to
BIND 9.19.5, 9.18.7, and 9.16.33, explicitly requiring "inline-signing"
for every "dnssec-policy".

We did this backward-incompatible change deliberately, knowing the
consequences for users and their configurations. But if we didn't, say,
we were unaware this is a backward-incompatible change and fixed failing
systems test by "tweaking a knob to make the CI pass", we would not have
a second look before the change hits user configurations.

"cross-version-config-tests" CI job is such a second look. It will run
system tests from the latest release tag specific to the particular
branch (e.g., v9.19.12 for the "main" branch) with BIND 9 binaries from
the current "HEAD" (the future v9.19.13). This Frankenstein build gets
conceived by altering the "TOP_BUILDDIR" variable in
"bin/tests/system/conf.sh".

Caveats:
- Only system test configurations are tested; no actual test code is
  run.
- Problems with namedN.conf configurations are not identified.

When backward-incompatible change is introduced, the CI job is expected
to fail. If the change is deliberate, the job will keep failing until
the version with the backward-incompatible change is tagged, and the
minor version in configure.ac is bumped.
2023-08-08 19:18:36 +02:00
Matthijs Mekking
9f3b5d6841 Merge branch 'tt-provider-engine' into 'main'
Fix keyfromlabel to not use engine parameter for provider keys

See merge request isc-projects/bind9!8153
2023-08-08 14:26:15 +00:00
Timo Teräs
de486d0ec5 Fix keyfromlabel to not use engine parameter for provider keys
- Rework key checks to not require 'engine' tag, private key
  is valid with 'label' tag alone

- Fix _fromlabel() functions to work with engine == NULL

- Update dst__openssl_fromlabel_engine() to do provider lookup
  only when engine is not set
2023-08-08 17:16:14 +03:00
Matthijs Mekking
222f2bd11c Merge branch 'tt-ecdsa-fixes' into 'main'
Fixes to provider/engine based ECDSA key handling

See merge request isc-projects/bind9!8152
2023-08-08 14:13:21 +00:00
Timo Teräs
1b47385f58 Add CHANGES for GL !8152 2023-08-08 14:08:00 +00:00
Timo Teräs
a337dbef22 Always use OpenSSL 3.0 API when available
The new APIs work always as OpenSSL provides glue to access also
old style engines using the new APIs.
2023-08-08 14:08:00 +00:00
Timo Teräs
8de089e514 Fix support for engine/provider ECDSA keys
Exporting private key of on-token keys is not possible. Fix code
to not fail in this case.
2023-08-08 14:08:00 +00:00
Timo Teräs
de45aab184 Fix OpenSSL 3.0 API EC curve names
The OpenSSL man page examples used the NIST curve names which
are supported. But when querying the name, the native OpenSSL
name is returned. Use these names to pass curve type checks for
engine/provider objects.
2023-08-08 14:08:00 +00:00
Michal Nowak
349fa71a0d Merge branch 'mnowak/pytest_rewrite_stress' into 'main'
Rewrite stress test to pytest

See merge request isc-projects/bind9!7905
2023-08-08 12:29:24 +00:00
Michał Kępień
08a8906cfc
Convert setup.pl into static configurations
The setup.pl script has been replaced with static BIND configurations,
and in the course of this change, the unused ns1 server was removed.
This enhancement has greatly improved the overall test's readability.
2023-08-08 10:31:45 +02:00
Michal Nowak
ecd7b30d0a
Rewrite stress test to pytest
The shell version of the test was completed only after all DNS zone
updates were sent, even if the BIND server crashed while processing
them, leading to prolonged execution and potential hang in the CI
environment. The Python rewrite of the test ensures that DNS update
tasks finish within five minutes of starting, irrespective of a BIND
crash possibility or DNS zone updates not finishing in time.
2023-08-08 10:31:45 +02:00
Michał Kępień
448831dde2 Merge branch '4240-dnstap-system-test-fixes' into 'main'
"dnstap" system test fixes

Closes #4240

See merge request isc-projects/bind9!8177
2023-08-07 11:58:54 +00:00
Michał Kępień
67df78e518
Lower the minimum expected dnstap output file size
Lower the size requirement for the dnstap output file produced during
the "dnstap" system test from 454 to 450 bytes; while files of that size
are not generated in any GitLab CI job, they are in other environments
where the test passes.
2023-08-07 11:26:58 +02:00
Michał Kępień
26d3d97f12
Wait until fstrm_capture is ready
The fstrm_capture utility is started in the background during the
"dnstap" system test.  Consequently, "rndc dnstap-reopen" and similar
commands may be executed before fstrm_capture starts listening on the
Unix domain socket it is configured to receive dnstap data on.  This
results in the dnstap data sent to that socket in the meantime to be
lost; while the fstrm writer thread is able to recover from such a
scenario within a couple of seconds (by reopening the configured dnstap
destination itself), only one write attempt is made for data
successfully queued to the writer thread, so dnstap frames can still be
lost in the process.  This may happen during the "dnstap" system test,
leading to the dnstap output file being empty, which in turn causes the
test to fail.

Fix by waiting until fstrm_capture starts listening on the Unix domain
socket it is configured to use before asking named to reopen the
configured dnstap destination.  Since various fstrm_capture versions log
different messages when the listening socket is set up, wait for a
common string that works for all fstrm_capture versions released to
date.  Add a few extra debug messages indicating test progress and make
the test fail if the expected fstrm_capture log message is not generated
within 10 seconds.
2023-08-07 11:26:58 +02:00
Michał Kępień
bd2941fc72
Capture all fstrm_capture output
The fstrm_capture.out file is overwritten when the fstrm_capture utility
is restarted during the "dnstap" system test.  Use a separate output
file for each fstrm_capture instance to ensure all output produced by
that tool during the "dnstap" system test is preserved for forensic
purposes.
2023-08-07 11:26:58 +02:00
Mark Andrews
ac41053d38 Merge branch '4243-_wait_for_stats-errors-not-detected-in-ixfr-system-test' into 'main'
Resolve "_wait_for_stats errors not detected in ixfr system test"

Closes #4243

See merge request isc-projects/bind9!8171
2023-08-07 09:16:55 +00:00
Mark Andrews
287a1ac09b Set ret=1 if _wait_for_stats does not succeed
Errors getting transfer statistics from named.run where not detected
as ret was not set to one if there hadn't been a success after looping
for a while.
2023-08-07 08:49:47 +00:00
Michał Kępień
638db88737 Merge branch 'michal/set-up-version-and-release-notes-for-bind-9.19.17' into 'main'
Set up version and release notes for BIND 9.19.17

See merge request isc-projects/bind9!8173
2023-08-07 08:26:04 +00:00
Michał Kępień
c0a6068215
Set up release notes for BIND 9.19.17 2023-08-07 10:23:55 +02:00
Michał Kępień
7fffb66891
Update BIND version to 9.19.17-dev 2023-08-07 10:23:55 +02:00
Evan Hunt
9aa6cd74fa Merge branch '4232-rbtdb-performance-fix' into 'main'
use read lock in rdataset_getownercase()

Closes #4232

See merge request isc-projects/bind9!8169
2023-08-04 09:12:45 +00:00
Evan Hunt
b3c2b64662 use read lock in rdataset_getownercase()
we were incorrectly write-locking the node when retrieving
the owner case of an rdataset.
2023-08-03 13:26:27 -07:00
Matthijs Mekking
c3fbcda5a1 Merge branch 'matthijs-followup-4032' into 'main'
Change default TTLsig to one week

See merge request isc-projects/bind9!8164
2023-08-02 10:21:32 +00:00
Matthijs Mekking
32686beabc Change default TTLsig to one week
Commit dc6dafdad1 allows larger TTL values
in zones that go insecure, and ignores the maximum zone TTL.

This means that if you use TTL values larger than 1 day in your zone,
your zone runs the risk of going bogus before it moves safely to
insecure.

Most resolvers by default cap the maximum TTL that they cache RRsets,
at one day (Unbound, Knot, PowerDNS) so that is fine. However, BIND 9's
default is one week.

Change the default TTLsig to one week, so that also for BIND 9
resolvers in the default cases responses for zones that are going
insecure will not be evaluated as bogus.

This change does mean that when unsigning your zone, it will take six
days longer to safely go insecure, regardless of what TTL values you
use in the zone.
2023-08-02 11:16:50 +02:00
Michał Kępień
ffd05d82ed Merge branch 'michal/add-changes-entry-for-rbtdb-split-up' into 'main'
Add CHANGES entry for GL !7873

See merge request isc-projects/bind9!8162
2023-08-02 08:44:11 +00:00
Michał Kępień
e5a0784e60
Add CHANGES entry for GL !7873 2023-08-02 10:40:09 +02:00
Evan Hunt
39f46fc128 Merge branch '3700-deprecate-dialup' into 'main'
deprecate "dialup" and "heartbeat-interval"

Closes #3700

See merge request isc-projects/bind9!8080
2023-08-02 01:38:27 +00:00
Evan Hunt
d10b6a4b39 CHANGES and release note for [GL #3700] 2023-08-01 18:10:44 -07:00
Evan Hunt
eeeccec67c deprecate "dialup" and "heartbeat-interval"
these options concentrate zone maintenance actions into
bursts for the benefit of servers with intermittent connections.
that's no longer something we really need to optimize.
2023-08-01 18:10:44 -07:00
Mark Andrews
cd0f115082 Merge branch '4229-nextpart-failed-set-e-fallout' into 'main'
Resolve "nextpart failed, set -e fallout?"

Closes #4229

See merge request isc-projects/bind9!8149
2023-08-02 00:21:26 +00:00
Mark Andrews
dd74840291 Add sleep 1 so that the signing happens in a different second 2023-08-01 23:47:55 +00:00
Mark Andrews
162db75e2b Use $() instead of backticks 2023-08-01 23:47:55 +00:00
Mark Andrews
6d0f19da7d Correctly grep nextpart output 2023-08-01 23:47:55 +00:00
Mark Andrews
edd4226df2 Merge branch '4059-oracle-linux-8-shell-doesn-t-always-restore-environment-variable-correctly' into 'main'
Resolve "Oracle Linux 8 shell doesn't always restore environment variable correctly"

Closes #4059

See merge request isc-projects/bind9!7908
2023-08-01 23:47:38 +00:00
Mark Andrews
96f75bba18 Use sub shell to isolate enviroment changes
'HOME=value command' should only change HOME for command but on
some platforms this occasionally sets HOME for the rest of the
test. Explicitly isolate the enviroment change using a sub shell.
2023-08-01 23:17:15 +00:00
Arаm Sаrgsyаn
d6cbb3d6aa Merge branch '4226-dig-help-message-https-plain-get-vs-http-plain-get' into 'main'
Fix dig help message typo in the http-plain-get option

Closes #4226

See merge request isc-projects/bind9!8148
2023-08-01 10:39:26 +00:00
Aram Sargsyan
77d1476c46 Fix dig help message typo in the http-plain-get option
The option name is misspelled as 'https-plain-get'. Fix the error.
2023-08-01 10:38:44 +00:00
Matthijs Mekking
9a4a4c6678 Merge branch '4032-ignore-max-zone-ttl-dnssec-policy-insecure' into 'main'
Ignore max-zone-ttl on dnssec-policy insecure

Closes #4032

See merge request isc-projects/bind9!8142
2023-08-01 07:46:22 +00:00
Matthijs Mekking
0bdf1980c4 Add CHANGES and release note for #4032 2023-08-01 08:57:11 +02:00
Matthijs Mekking
dc6dafdad1 Ignore max-zone-ttl on dnssec-policy insecure
Allow larger TTL values in zones that go insecure. This is necessary
because otherwise the zone will not be loaded due to the max-zone-ttl
of P1D that is part of the current insecure policy.

In the keymgr.c code, default back to P1D if the max-zone-ttl is set
to zero.
2023-08-01 08:56:52 +02:00
Matthijs Mekking
ce869a521c Merge branch '3677-dnssec-policy-inline-signing' into 'main'
Add inline-signing to dnssec-policy

Closes #3677

See merge request isc-projects/bind9!7204
2023-08-01 06:55:56 +00:00
Matthijs Mekking
bd00c2ce4e Add release note and CHANGES for GL #3677
News worthy.
2023-08-01 06:55:48 +00:00
Matthijs Mekking
1e0f77b349 Remove redundant inline-signing lines from docs
Now that inline-signing is explicitly set in dnssec-policy, remove
the redundant "inline-signing yes;" lines from the documentation.
2023-08-01 06:55:48 +00:00