bind9/bin/tests
Matthijs Mekking 9b57ad68d4 Fix kasp timing issue on Windows
This fixes another intermittent failure in the kasp system test.
It does not happen often, except for in the Windows platform tests
where it takes a long time to run the tests.

In the "kasp" system test, there is an "rndc reconfig" call which
triggers a new rekey event.  check_next_key_event() verifies the time
remaining from the moment "rndc reconfig" is called until the next key
event.  However, the next key event time is calculated from the key
times provided during key creation (i.e. during test setup).  Given
this, if "rndc reconfig" is called a significant amount of time after
the test is started, some check_next_key_event() checks will fail.

Fix by calculating the time passed since the start of the test and
when 'rndc reconfig' happens.  Substract this time from the
calculated next key event.

This only needs to be done after an "rndc reconfig" on zones where
the keymgr needs to wait for a period of time (for example for keys
to become OMNIPRESENT, or HIDDEN). This is on step 2 and step 5 of
the algorithm rollover.  In step 2 there is a waiting period before
the DNSKEY is OMNIPRESENT, in step 5 there is a waiting period
before the DNSKEY is HIDDEN.

In step 1 new keys are created, in step 3 and 4 key states just
entered OMNIPRESENT, and in step 6 we no longer care because the
key lifetime is unlimited and we default to checking once per hour.

Regardless of our indifference about the next key event after step 6,
change some of the key timings in the setup script to better
reflect reality: DNSKEY is in HIDDEN after step 5, DS times have
changed when the new DS became active.

(cherry picked from commit 62a97570b8)
2020-04-08 09:47:32 +02:00
..
bigtest update file headers 2018-03-15 18:33:13 -07:00
optional Fix 'Dereference of null pointer' from scan-build-10 2020-03-25 18:06:29 +01:00
pkcs11 Add ZLIB_LIBS to ISCLIBS 2020-02-28 15:22:59 +01:00
startperf Remove $Id markers, Principal Author and Reviewed tags from the full source tree 2018-05-11 13:17:46 +02:00
system Fix kasp timing issue on Windows 2020-04-08 09:47:32 +02:00
testdata/wire move all optional tests from bin/tests to bin/tests/optional 2018-03-09 14:12:47 -08:00
win32 Make VS solution upgrading unnecessary 2019-09-26 15:11:15 +02:00
.gitignore Remove genrandom command and all usage of specific random files throughout the system test suite 2018-05-16 09:54:35 +02:00
cfg_test.c Refactor the isc_log API so it cannot fail on memory failures 2020-03-18 11:44:18 +01:00
fromhex.pl Update license headers to not include years in copyright in all applicable files 2018-02-23 10:12:02 +01:00
headerdep_test.sh.in Remove $Id markers, Principal Author and Reviewed tags from the full source tree 2018-05-11 13:17:46 +02:00
Makefile.in Add ZLIB_LIBS to ISCLIBS 2020-02-28 15:22:59 +01:00
makejournal.c Refactor the isc_log API so it cannot fail on memory failures 2020-03-18 11:44:18 +01:00
named.conf update documentation 2019-06-05 07:49:57 -07:00
prepare-softhsm2.sh Fix "pkcs11" system test 2020-03-05 07:00:50 +00:00
wire_test.c Merge branch '46-enforce-clang-format-rules' into 'master' 2020-02-14 08:45:59 +00:00