From 4363b8b32deb69b30b756a34a720e67d1c3708fe Mon Sep 17 00:00:00 2001 From: Matt Johnston Date: Thu, 7 Nov 2013 00:18:52 +0800 Subject: refactor key generation, make it generate as required. Needs UI in server command line options --HG-- branch : keyondemand --- ecdsa.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'ecdsa.c') diff --git a/ecdsa.c b/ecdsa.c index 66612e4..fc8ea1f 100644 --- a/ecdsa.c +++ b/ecdsa.c @@ -8,6 +8,13 @@ #ifdef DROPBEAR_ECDSA +int signkey_is_ecdsa(enum signkey_type type) +{ + return type == DROPBEAR_SIGNKEY_ECDSA_NISTP256 + || type == DROPBEAR_SIGNKEY_ECDSA_NISTP384 + || type == DROPBEAR_SIGNKEY_ECDSA_NISTP521; +} + enum signkey_type ecdsa_signkey_type(ecc_key * key) { #ifdef DROPBEAR_ECC_256 if (key->dp == ecc_curve_nistp256.dp) { -- cgit v1.2.3