tests/torture_hostkey: Skip some tests in FIPS mode

Skip tests using non allowed algorithms.

Signed-off-by: Anderson Toshiyuki Sasaki <ansasaki@redhat.com>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
Anderson Toshiyuki Sasaki
2019-06-05 15:14:49 +02:00
committed by Andreas Schneider
parent 1a6ac291a7
commit 92a0d23eac

View File

@@ -88,6 +88,10 @@ static void torture_hostkey_rsa(void **state) {
int rc;
if (ssh_fips_mode()) {
skip();
}
rc = ssh_options_set(session, SSH_OPTIONS_HOSTKEYS, &rsa);
assert_ssh_return_code(session, rc);
@@ -107,6 +111,10 @@ static void torture_hostkey_ed25519(void **state) {
int rc;
if (ssh_fips_mode()) {
skip();
}
rc = ssh_options_set(session, SSH_OPTIONS_HOSTKEYS, &ed);
assert_ssh_return_code(session, rc);
@@ -127,6 +135,10 @@ static void torture_hostkey_dss(void **state) {
int rc;
if (ssh_fips_mode()) {
skip();
}
rc = ssh_options_set(session, SSH_OPTIONS_HOSTKEYS, &rsa);
assert_ssh_return_code(session, rc);