Skip to content

Commit

Permalink
Merge pull request #533 from SUSE/fips_140_3
Browse files Browse the repository at this point in the history
Add basic FIPS-140-3 test
  • Loading branch information
dcermak authored Jul 15, 2024
2 parents 5bb6197 + d203afa commit 5b5a9ea
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions tests/test_fips.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,17 @@ def openssl_fips_hashes_test_fnct(container_per_test: ContainerData) -> None:
), f"unexpected digest of hash {digest}: {dev_null_digest}"


@pytest.mark.skipif(
OS_VERSION in ("15.3",), reason="FIPS 140-3 not supported on 15.3"
)
def fips_mode_setup_check(container_per_test: ContainerData) -> None:
"""If the host is running in FIPS mode, then `fips-mode-setup --check` should
exit with `0`.
"""
container_per_test.connection.check_output("fips-mode-setup --check")


@pytest.mark.parametrize(
"container_per_test", CONTAINER_IMAGES_WITH_ZYPPER, indirect=True
)
Expand Down

0 comments on commit 5b5a9ea

Please sign in to comment.