From 8fe8dbb378d1d9d7cde54dfd3aa7ff9acca77733 Mon Sep 17 00:00:00 2001 From: Axel Eppe Date: Tue, 1 Mar 2016 00:46:13 +0000 Subject: [PATCH] agent: Add cert auth support to ssh_agent_get_next_ident() Signed-off-by: Axel Eppe Reviewed-by: Andreas Schneider --- src/agent.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/agent.c b/src/agent.c index 76265645..0b145ff3 100644 --- a/src/agent.c +++ b/src/agent.c @@ -472,6 +472,10 @@ ssh_key ssh_agent_get_next_ident(struct ssh_session_struct *session, /* get key from blob */ rc = ssh_pki_import_pubkey_blob(blob, &key); + if (rc == SSH_ERROR) { + /* Try again as a cert. */ + rc = ssh_pki_import_cert_blob(blob, &key); + } ssh_string_free(blob); if (rc == SSH_ERROR) { return NULL;