aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnderson Toshiyuki Sasaki <ansasaki@redhat.com>2019-10-02 17:36:54 +0200
committerAndreas Schneider <asn@cryptomilk.org>2019-10-25 15:15:20 +0200
commit040aa0edfeb47307f117bf1c5e4d66fc2d579cc2 (patch)
tree80a9e774063835e9d18b27f62a2429f14bb8909a
parentf97a8b4e3f60b2345e9e4b77c42d179435736338 (diff)
downloadlibssh-040aa0edfeb47307f117bf1c5e4d66fc2d579cc2.tar.gz
libssh-040aa0edfeb47307f117bf1c5e4d66fc2d579cc2.tar.xz
libssh-040aa0edfeb47307f117bf1c5e4d66fc2d579cc2.zip
tests: Do not process server config during tests
In pkd tests, avoid processing the global server configuration file. This is to allow testing with algorithms not allowed in the global server configuration. Signed-off-by: Anderson Toshiyuki Sasaki <ansasaki@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
-rw-r--r--tests/pkd/pkd_daemon.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/pkd/pkd_daemon.c b/tests/pkd/pkd_daemon.c
index 141d79a6..910b3749 100644
--- a/tests/pkd/pkd_daemon.c
+++ b/tests/pkd/pkd_daemon.c
@@ -252,6 +252,7 @@ static int pkd_exec_hello(int fd, struct pkd_daemon_args *args)
size_t kex_len = 0;
const char *all_ciphers = NULL;
const uint64_t rekey_data_limit = args->rekey_data_limit;
+ bool process_config = false;
pkd_state.eof_received = 0;
pkd_state.close_received = 0;
@@ -291,6 +292,13 @@ static int pkd_exec_hello(int fd, struct pkd_daemon_args *args)
goto outclose;
}
+ rc = ssh_bind_options_set(b, SSH_BIND_OPTIONS_PROCESS_CONFIG,
+ &process_config);
+ if (rc != 0) {
+ pkderr("ssh_bind_options_set process config: %s\n", ssh_get_error(b));
+ goto outclose;
+ }
+
if (!ssh_fips_mode()) {
/* Add methods not enabled by default */
#define GEX_SHA1 "diffie-hellman-group-exchange-sha1"