summaryrefslogtreecommitdiffhomepage
path: root/cli-kex.c
diff options
context:
space:
mode:
authorVladislav Grishenko <themiron@users.noreply.github.com>2020-05-28 20:01:48 +0500
committerGitHub <noreply@github.com>2020-05-28 23:01:48 +0800
commit413eaf1ba1dc99e1eb7d2375bd6a7c6d8759ff17 (patch)
tree9979669ca65c7efcdac1a0fe06d228533367cb5c /cli-kex.c
parent3b359050b464e9fede85cd299902adea79f027bf (diff)
Allow DH to be completely disabled (#97)
Reduces binary size by ~2kB by default and by 21kB with no other libtommath functions users, ex. with curve25519 kex and ed25519 key only.
Diffstat (limited to 'cli-kex.c')
-rw-r--r--cli-kex.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/cli-kex.c b/cli-kex.c
index 98b0245..af1cfcf 100644
--- a/cli-kex.c
+++ b/cli-kex.c
@@ -155,10 +155,12 @@ void recv_msg_kexdh_reply() {
#endif
}
+#if DROPBEAR_NORMAL_DH
if (cli_ses.dh_param) {
free_kexdh_param(cli_ses.dh_param);
cli_ses.dh_param = NULL;
}
+#endif
#if DROPBEAR_ECDH
if (cli_ses.ecdh_param) {
free_kexecdh_param(cli_ses.ecdh_param);