forked from mtusi2026/mtusi2026lab7
fix: address rotation-revocation final verify findings
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -465,11 +465,16 @@ def test_require_ready(stand: RunStand) -> None:
|
||||
}
|
||||
|
||||
|
||||
@pytest.mark.parametrize("missing", [set(), {"relay"}])
|
||||
@pytest.mark.parametrize("name", ["ca.crt", "crl.pem"])
|
||||
def test_require_files(name: str, stand: RunStand) -> None:
|
||||
def test_require_files(
|
||||
name: str,
|
||||
missing: set[str],
|
||||
stand: RunStand,
|
||||
) -> None:
|
||||
_ready(stand)
|
||||
(stand.pki_dir / name).unlink()
|
||||
stand.missing = {"relay"}
|
||||
stand.missing = missing
|
||||
with pytest.raises(rotation.NotReady, match=f"no {name}"):
|
||||
stand.require(set())
|
||||
|
||||
@@ -650,6 +655,8 @@ def test_recreated_stand_directory(stand: RunStand) -> None:
|
||||
"leaf openbao",
|
||||
"leaf api",
|
||||
"revoke relay",
|
||||
# при пропавшей worker — отзыв её самой
|
||||
"revoke worker",
|
||||
"renew",
|
||||
"secret postgres/worker",
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user