Skip to content

Commit 4366fa3

Browse files
committed
tests: Skip escrow tests in FIPS mode
There are some new stricter rules for FIPS in RHEL/CentOS 10 and we are not able to generate a self-signed certificate for testing that wouldn't be rejected by NSS. There might be a workaround for this, but I wasn't able to find one.
1 parent 2f5af57 commit 4366fa3

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tests/crypto_test.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -702,6 +702,12 @@ def test_luks2_open_rw(self):
702702

703703
class CryptoTestEscrow(CryptoTestCase):
704704
def setUp(self):
705+
# I am not able to generate a self-signed certificate that would work in FIPS
706+
# so let's just skip this for now
707+
fips = read_file("/proc/sys/crypto/fips_enabled")
708+
if int(fips) == 1:
709+
self.skipTest("Skipping escrow tests in FIPS mode")
710+
705711
super(CryptoTestEscrow, self).setUp()
706712

707713
# Create the certificate used to encrypt the escrow packet and backup passphrase.

0 commit comments

Comments
 (0)