From 9ff7ba61e20bae70eeaa0ebf9ff010ca3836a1ac Mon Sep 17 00:00:00 2001 From: Andri Yngvason Date: Mon, 2 Oct 2023 22:01:21 +0000 Subject: [PATCH] main: Add rsa to command sanity checker --- src/main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main.c b/src/main.c index f352a5c..dea7d56 100644 --- a/src/main.c +++ b/src/main.c @@ -1002,12 +1002,12 @@ int check_cfg_sanity(struct cfg* cfg) return -1; } - if (!cfg->certificate_file) { + if (!cfg->certificate_file && !cfg->rsa_private_key_file) { nvnc_log(NVNC_LOG_ERROR, "Authentication enabled, but missing certificate_file"); rc = -1; } - if (!cfg->private_key_file) { + if (!cfg->private_key_file && !cfg->rsa_private_key_file) { nvnc_log(NVNC_LOG_ERROR, "Authentication enabled, but missing private_key_file"); rc = -1; }