Also fix off by one error in system test

The system test was also subject to the same off by one bug that also
existed in the code. That is: if the inception time of the signature
is exactly equal to the inactive time of the key, we still have to
expect the signature.
This commit is contained in:
Matthijs Mekking 2026-04-02 10:54:53 +02:00
parent 784a441e2d
commit d9b6036e0f

View file

@ -338,7 +338,7 @@ def check_keysigningrequest(path, zsks, start, end):
line_no = 0
inception = start
while inception < end:
while inception <= end:
next_bundle = end + 1
# expect bundle header
assert f";; KeySigningRequest 1.0 {inception}" in lines[line_no]
@ -402,7 +402,7 @@ def check_signedkeyresponse(
dnskey_ttl = int(config["dnskey-ttl"].total_seconds())
inception = start
while inception < end:
while inception <= end:
# A single signed key response may consist of:
# ;; SignedKeyResponse (header)
# ;; DNSKEY 257 (one per published key in ksks)
@ -487,7 +487,7 @@ def check_signedkeyresponse(
inactive = key.get_timing("Inactive", must_exist=False)
if active > inception:
continue
if inactive is not None and inception >= inactive:
if inactive is not None and inception > inactive:
continue
# collect keys that should be in this bundle
@ -537,7 +537,7 @@ def check_signedkeyresponse(
inactive = key.get_timing("Inactive", must_exist=False)
if active > inception:
continue
if inactive is not None and inception >= inactive:
if inactive is not None and inception > inactive:
continue
# collect keys that should be in this bundle
@ -595,7 +595,7 @@ def check_signedkeyresponse(
inactive = key.get_timing("Inactive", must_exist=False)
if active > inception:
continue
if inactive is not None and inception >= inactive:
if inactive is not None and inception > inactive:
continue
# collect keys that should be in this bundle