mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-30 14:07:59 +00:00
ksr: Take into account key collisions
When generating new key pairs, one test checks if existing keys that
match the time bundle are selected, rather than extra keys being
generated. Part of the test is to check the verbose output, counting
the number of "Selecting" and "Generating" occurences. But if there
is a key collision, the ksr tool will output that the key already
exists and includes the substring "already exists, or might collide
with another key upon revokation. Generating a new key".
So substract by one the generated counter if there is a "collide"
occurrence.
(cherry picked from commit 8b3d2e5633
)
This commit is contained in:
@@ -597,6 +597,10 @@ def test_ksr_common(servers):
|
||||
selected += 1
|
||||
if "Generating" in output:
|
||||
generated += 1
|
||||
# Subtract if there was a key collision.
|
||||
if "collide" in output:
|
||||
generated -= 1
|
||||
|
||||
assert selected == 2
|
||||
assert generated == 2
|
||||
for index, key in enumerate(overlapping_zsks):
|
||||
|
Reference in New Issue
Block a user