tests: add config tests for SSH_OPTIONS_GSSAPI_KEY_EXCHANGE

Signed-off-by: Gauravsingh Sisodia <xaerru@gmail.com>
Reviewed-by: Jakub Jelen <jjelen@redhat.com>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
Gauravsingh Sisodia
2025-08-08 11:49:36 +00:00
committed by Jakub Jelen
parent 83114b636f
commit e94fd6ccd1

View File

@@ -94,6 +94,7 @@ extern LIBSSH_THREAD int ssh_log_level;
"\tGSSAPIClientIdentity home.sweet\n" \ "\tGSSAPIClientIdentity home.sweet\n" \
"\tUserKnownHostsFile "USER_KNOWN_HOSTS"\n" \ "\tUserKnownHostsFile "USER_KNOWN_HOSTS"\n" \
"\tRequiredRSASize 2233\n" \ "\tRequiredRSASize 2233\n" \
"\tGSSAPIKeyExchange yes\n" \
"\tGSSAPIKexAlgorithms gss-group14-sha256-\n" "\tGSSAPIKexAlgorithms gss-group14-sha256-\n"
/* authentication methods */ /* authentication methods */
@@ -650,6 +651,7 @@ static void torture_config_new(void ** state,
assert_string_equal(session->opts.gss_server_identity, "example.com"); assert_string_equal(session->opts.gss_server_identity, "example.com");
assert_string_equal(session->opts.gss_client_identity, "home.sweet"); assert_string_equal(session->opts.gss_client_identity, "home.sweet");
#ifdef WITH_GSSAPI #ifdef WITH_GSSAPI
assert_true(session->opts.gssapi_key_exchange);
assert_string_equal(session->opts.gssapi_key_exchange_algs, assert_string_equal(session->opts.gssapi_key_exchange_algs,
"gss-group14-sha256-"); "gss-group14-sha256-");
#endif /* WITH_GSSAPI */ #endif /* WITH_GSSAPI */