mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-09 18:04:25 +09:00
pkd: Support ed25519 host keys in server
This adds support for the ed25519 keys in the pkd framework and adds openssh-only tests utilizing these host keys (dropbear does not support them yet). Signed-off-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
committed by
Andreas Schneider
parent
c8429113fa
commit
0e886ba803
@@ -27,6 +27,15 @@ void setup_rsa_key() {
|
||||
assert_int_equal(rc, 0);
|
||||
}
|
||||
|
||||
void setup_ed25519_key() {
|
||||
int rc = 0;
|
||||
if (access(LIBSSH_ED25519_TESTKEY, F_OK) != 0) {
|
||||
rc = system_checked(OPENSSH_KEYGEN " -t ed25519 -q -N \"\" -f "
|
||||
LIBSSH_ED25519_TESTKEY);
|
||||
}
|
||||
assert_int_equal(rc, 0);
|
||||
}
|
||||
|
||||
#ifdef HAVE_DSA
|
||||
void setup_dsa_key() {
|
||||
int rc = 0;
|
||||
@@ -67,6 +76,10 @@ void cleanup_rsa_key() {
|
||||
cleanup_key(LIBSSH_RSA_TESTKEY, LIBSSH_RSA_TESTKEY ".pub");
|
||||
}
|
||||
|
||||
void cleanup_ed25519_key() {
|
||||
cleanup_key(LIBSSH_ED25519_TESTKEY, LIBSSH_ED25519_TESTKEY ".pub");
|
||||
}
|
||||
|
||||
#ifdef HAVE_DSA
|
||||
void cleanup_dsa_key() {
|
||||
cleanup_key(LIBSSH_DSA_TESTKEY, LIBSSH_DSA_TESTKEY ".pub");
|
||||
|
||||
Reference in New Issue
Block a user