Commit Graph

32957 Commits

Author SHA1 Message Date
Ondřej Surý
bcae8ec0ef Merge branch '2607-remove-custom-spnego-v9_16' into 'v9_16'
Remove custom ISC SPNEGO implementation (v9.16)

See merge request isc-projects/bind9!4855
2021-04-01 14:14:13 +00:00
Mark Andrews
99132eda0e Add CHANGES and release note for GL #2607 2021-04-01 16:11:25 +02:00
Ondřej Surý
565a6a5679 Move the dummy shims to single ifndef GSSAPI block
Previously, every function had it's own #ifdef GSSAPI #else #endif block
that defined shim function in case GSSAPI was not being used.  Now the
dummy shim functions have be split out into a single #else #endif block
at the end of the file.

This makes the gssapictx.c similar to 9.17.x code, making the backports
and reviews easier.
2021-04-01 10:42:32 +02:00
Mark Andrews
3fd30e1634 Add Heimdal compatibility support
The Heimdal Kerberos library handles the OID sets in a different manner.
Unify the handling of the OID sets between MIT and Heimdal
implementations by dynamically creating the OID sets instead of using
static predefined set.  This is how upstream recommends to handle the
OID sets.
2021-04-01 10:42:32 +02:00
Mark Andrews
6b0b0c6aba Request krb5 CFLAGS and LIBS from $KRB5_CONFIG
The GSSAPI now needs both gssapi and krb5 libraries, so we need to
request both CFLAGS and LIBS from the configure script.
2021-04-01 10:42:32 +02:00
Mark Andrews
a875dcc669 Remove custom ISC SPNEGO implementation
The custom ISC SPNEGO mechanism implementation is no longer needed on
the basis that all major Kerberos 5/GSSAPI (mit-krb5, heimdal and
Windows) implementations support SPNEGO mechanism since 2006.

This commit removes the custom ISC SPNEGO implementation, and removes
the option from both autoconf and win32 Configure script.  Unknown
options are being ignored, so this doesn't require any special handling.
2021-04-01 10:42:32 +02:00
Mark Andrews
216a97188d Handle expected signals in tsiggss authsock.pl script
When the authsock.pl script would be terminated with a signal,
it would leave the pidfile around.  This commit adds a signal
handler that cleanups the pidfile on signals that are expected.
2021-04-01 09:58:19 +02:00
Michal Nowak
f8c6872beb Merge branch 'mnowak/web-run-gcc-tarball-ci-job-v9_16' into 'v9_16'
[v9_16] Run gcc:tarball CI job in web-triggered pipelines

See merge request isc-projects/bind9!4852
2021-03-31 15:03:57 +00:00
Michal Nowak
fd8ce68189 Run gcc:tarball CI job in web-triggered pipelines
The gcc:tarball CI job may identify problems with tarballs created by
"make dist" of the tarball-create CI job. Enabling the gcc:tarball CI
job in web-triggered pipelines provides developers with a test vector.

(cherry picked from commit 4d5d3b75da)
2021-03-31 16:53:51 +02:00
Ondřej Surý
6e4eaa780d Merge branch 'cherry-pick-19b69e9a' into 'v9_16'
Do not require config.h to use isc/util.h (v9.16)

See merge request isc-projects/bind9!4842
2021-03-26 19:00:03 +00:00
Ondřej Surý
ee7283b3ee Merge branch 'bind-dyndb-ldap-v9.16.13' into 'main'
Do not require config.h to use isc/util.h

See merge request isc-projects/bind9!4840

(cherry picked from commit 19b69e9a3b)

81eb3396 Do not require config.h to use isc/util.h
2021-03-26 18:48:06 +00:00
Diego dos Santos Fronza
1c7b15151b Merge branch '2490-dig-tcp-does-not-honor-tries-1-nor-retry-0-v9_16' into 'v9_16'
Resolve "dig +tcp does not honor +tries=1 nor +retry=0"

See merge request isc-projects/bind9!4839
2021-03-25 17:59:37 +00:00
Diego Fronza
ec83e02ed2 Add CHANGES note for [GL #2490] 2021-03-25 14:35:16 -03:00
Diego Fronza
db2c180feb Update dig's man page
Adjusted man page entries for +tries and +retry options to reflect the
fact that now those options apply to TCP as well.
2021-03-25 14:33:50 -03:00
Diego Fronza
9c2d52bcdb Added tests for tries=1 and retry=0 on TCP EOF
Added tests to ensure that dig won't retry sending a query over tcp
(+tcp) when a TCP connection is closed prematurely (EOF is read) if
either +tries=1 or retry=0 is specified on the command line.
2021-03-25 14:33:08 -03:00
Diego Fronza
d299f0e9ab Adjusted dig system tests
Now that premature EOF on tcp connections take +tries and +retry into
account, the dig system tests handling TCP EOF with +tries=1 were
expecting dig to do a second attempt in handling the tcp query, which
doesn't happen anymore.

To make the test work as expected +tries value was adjusted to 2, to
make it behave as before after the new update on dig.
2021-03-25 14:32:46 -03:00
Diego Fronza
1e5f3e6fa3 Don't retry +tcp queries on failure if tries=1 or retries=0
Before this commit, a premature EOF (connection closed) on tcp queries
was causing dig to automatically attempt to send the query again, even
if +tries=1 or +retries=0 was provided on command line.

This commit fix the problem by taking into account the no. of retries
specified by the user when processing a premature EOF on tcp
connections.
2021-03-25 14:32:37 -03:00
Matthijs Mekking
b813eab387 Merge branch '2488-refresh-keys-after-rndc-rollover-v9_16' into 'v9_16'
Resolve "Update key refresh timer after 'rndc dnssec -rollover'"

See merge request isc-projects/bind9!4833
2021-03-22 15:27:29 +00:00
Matthijs Mekking
a36257ea60 Fix some intermittent kasp failures
When calling "rndc dnssec -checkds", it may take some milliseconds
before the appropriate changes have been written to the state file.
Add retry_quiet mechanisms to allow the write operation to finish.

Also retry_quiet the check for the next key event. A "rndc dnssec"
command may trigger a zone_rekey event and this will write out
a new "next key event" log line, but it may take a bit longer than
than expected in the tests.

(cherry picked from commit 82d667e1d5)
2021-03-22 15:35:22 +01:00
Matthijs Mekking
d12b40f6fb Rekey immediately after rndc checkds/rollover
Call 'dns_zone_rekey' after a 'rndc dnssec -checkds' or 'rndc dnssec
-rollover' command is received, because such a command may influence
the next key event. Updating the keys immediately avoids unnecessary
rollover delays.

The kasp system test no longer needs to call 'rndc loadkeys' after
a 'rndc dnssec -checkds' or 'rndc dnssec -rollover' command.

(cherry picked from commit 82f72ae249)
2021-03-22 15:35:22 +01:00
Matthijs Mekking
a5c402b67d Merge branch '2517-cds-dnskey-delete-records-prevent-loading-unsigned-zone-v9_16' into 'v9_16'
Resolve "CDS and CDNSKEY DELETE records prevent (re-)loading unsigned zone"

See merge request isc-projects/bind9!4832
2021-03-22 13:27:36 +00:00
Matthijs Mekking
3156c0d103 Add CHANGES and notes for [#2517]
(cherry picked from commit 841e90c6fc)
2021-03-22 13:57:10 +01:00
Matthijs Mekking
1f8c5786f8 Delete CDS/CDNSKEY records when zone is unsigned
CDS/CDNSKEY DELETE records are only useful if they are signed,
otherwise the parent cannot verify these RRsets anyway. So once the DS
has been removed (and signaled to BIND), we can remove the DNSKEY and
RRSIG records, and at this point we can also remove the CDS/CDNSKEY
records.

(cherry picked from commit 6f31f62d69)
2021-03-22 13:57:10 +01:00
Matthijs Mekking
7882c7fbea Allow CDS/CDNSKEY DELETE records in unsigned zone
While not useful, having a CDS/CDNSKEY DELETE record in an unsigned
zone is not an error and "named-checkzone" should not complain.

(cherry picked from commit f211c7c2a1)
2021-03-22 13:31:02 +01:00
Matthijs Mekking
62592d59cb Merge branch 'matthijs-test-keymgr2kasp-v9_16' into 'v9_16'
Test keymgr2kasp (9.16)

See merge request isc-projects/bind9!4830
2021-03-22 11:40:59 +00:00
Matthijs Mekking
fe09becc7e Retry quiet check keys
Change the 'check_keys' function to try three times. Some intermittent
kasp test failures are because we are inspecting the key files
before the actual change has happen. The 'retry_quiet' approach allows
for a bit more time to let the write operation finish.

(cherry picked from commit d5531df79a)
2021-03-22 11:24:55 +01:00
Matthijs Mekking
b24a0da8f4 Update copyrights for keymgr2kasp
This MR introduces a new system test 'keymgr2kasp' to test
migration to 'dnssec-policy'. It moves some existing tests from
the 'kasp' system test to here.

Also a common script 'kasp.sh', to be used in kasp specific tests,
is introduced.

(manually picked from commit 923c2a07bf)
2021-03-22 11:24:55 +01:00
Matthijs Mekking
b81502f4ae Fix keymgr key init bug
The 'keymgr_key_init()' function initializes key states if they have
not been set previously. It looks at the key timing metadata and
determines using the given times whether a state should be set to
RUMOURED or OMNIPRESENT.

However, the DNSKEY and ZRRSIG states were mixed up: When looking
at the Activate timing metadata we should set the ZRRSIG state, and
when looking at the Published timing metadata we should set the
DNSKEY state.

(cherry picked from commit 27e7d5f698)
2021-03-22 11:24:55 +01:00
Matthijs Mekking
68e9603ed8 Test keymgr2kasp state from timing metadata
Add two test zones that migrate to dnssec-policy. Test if the key
states are set accordingly given the timing metadata.

The rumoured.kasp zone has its Publish/Active/SyncPublish times set
not too long ago so the key states should be set to RUMOURED. The
omnipresent.kasp zone has its Publish/Active/SyncPublish times set
long enough to set the key states to OMNIPRESENT.

Slightly change the init_migration_keys function to set the
key lifetime to "none" (legacy keys don't have lifetime). Then in the
test case set the expected key lifetime explicitly.

(cherry picked from commit c40c1ebcb1)
2021-03-22 11:24:55 +01:00
Matthijs Mekking
177ceb6cda Editorial commit keymgr2kasp test
This commit is somewhat editorial as it does not introduce something
new nor fixes anything.

The layout in keymgr2kasp/tests.sh has been changed, with the
intention to make more clear where a test scenario ends and begins.

The publication time of some ZSKs has been changed. It makes a more
clear distinction between publication time and activation time.

(cherry picked from commit f6fa254256)
2021-03-22 11:24:55 +01:00
Matthijs Mekking
e91f53cc6e Introduce kasp.sh
Add a script similar to conf.sh to include common functions and
variables for testing KASP. Currently used in kasp, keymgr2kasp, and
nsec3.

(cherry picked from commit ecb073bdd6)
2021-03-22 11:24:55 +01:00
Matthijs Mekking
2fa68d985f Move kasp migration tests to different directory
The kasp system test was getting pretty large, and more tests are on
the way. Time to split up. Move tests that are related to migrating
to dnssec-policy to a separate directory 'keymgr2kasp'.

(cherry picked from commit 5389172111)
2021-03-22 11:24:55 +01:00
Evan Hunt
885524ed38 Merge branch '2592-dig-clock-realtime-v9_16' into 'v9_16'
Resolve "dig -u is extremely inaccurate, especially on machines with the kernel timer tick set at 100Hz"

See merge request isc-projects/bind9!4827
2021-03-20 19:28:45 +00:00
Evan Hunt
0c74340e76 CHANGES 2021-03-20 12:02:23 -07:00
Patrick McLean
702edde73a dig: Use high resolution clocks when microsecond accuracy is requested
The TIME_NOW macro calls isc_time_now which uses CLOCK_REALTIME_COARSE
for getting the current time. This is perfectly fine for millisecond,
however when the user request microsecond resolutiuon, they are going
to get very inaccurate results. This is especially true on a server
class machine where the clock ticks may be set to 100HZ.

This changes dig to use the new TIME_NOW_HIRES macro that uses the
CLOCK_MONOTONIC_RAW that is more expensive, but gets the *actual*
current time rather than the at the last kernel time tick.

(cherry picked from commit 56cef1495f)
2021-03-20 12:00:59 -07:00
Patrick McLean
c5c9c9b83f Add isc_time_now_hires function to get current time with high resolution
The current isc_time_now uses CLOCK_REALTIME_COARSE which only updates
on a timer tick. This clock is generally fine for millisecond accuracy,
but on servers with 100hz clocks, this clock is nowhere near accurate
enough for microsecond accuracy.

This commit adds a new isc_time_now_hires function that uses
CLOCK_REALTIME, which gives the current time, though it is somewhat
expensive to call. When microsecond accuracy is required, it may be
required to use extra resources for higher accuracy.

(cherry picked from commit ebced74b19)
2021-03-20 11:59:21 -07:00
Michal Nowak
a0db1ac26c Merge branch 'v9_16_13-release' into 'v9_16'
Merge 9.16.13 release branch

See merge request isc-projects/bind9!4821
2021-03-19 09:36:09 +00:00
Michal Nowak
63cb814f3c Set up release notes for BIND 9.16.14 2021-03-19 10:10:59 +01:00
Tinderbox User
cfb6cca52d Merge branch 'prep-release' into v9_16_13-release 2021-03-19 09:57:51 +01:00
Michal Nowak
4bbc3587e0 Merge branch 'mnowak/prepare-documentation-for-bind-9.16.13' into 'v9_16_13-release'
Prepare documentation for BIND 9.16.13

See merge request isc-private/bind9!267
2021-03-19 09:57:51 +01:00
Tinderbox User
0525112928 prep 9.16.13 2021-03-19 09:57:51 +01:00
Michal Nowak
d0444472d8 Prepare release notes for BIND 9.16.13 2021-03-19 09:57:51 +01:00
Michal Nowak
7ce5609e8b Add release note for GL #2041 2021-03-19 09:57:51 +01:00
Michal Nowak
ed42c89938 Reorder release notes 2021-03-19 09:57:51 +01:00
Michal Nowak
4af8825c27 Tweak and reword release notes 2021-03-19 09:57:36 +01:00
Michal Nowak
3ef42ca6db Tweak and reword recent CHANGES entries 2021-03-19 09:54:30 +01:00
Diego dos Santos Fronza
706c8c6a12 Merge branch '2575-memory-leak-when-named-attempts-to-listen-on-freebsd-virtual-interface' into 'v9_16'
Resolve "memory leak when named attempts to listen on FreeBSD virtual interface"

See merge request isc-projects/bind9!4823
2021-03-18 21:40:49 +00:00
Diego Fronza
392a08bc95 Add CHANGES and release notes 2021-03-18 18:20:18 -03:00
Witold Kręcicki
a6c4702796 Fix a startup/shutdown crash in ns_clientmgr_create 2021-03-18 15:33:28 -03:00
Witold Kręcicki
dd564da286 Shutdown interface if we can't listen on it to avoid shutdown hang 2021-03-18 15:27:28 -03:00