summaryrefslogtreecommitdiff
path: root/sshconnect2.c
diff options
context:
space:
mode:
authorColin Watson <cjwatson@debian.org>2016-04-28 01:46:08 +0100
committerColin Watson <cjwatson@debian.org>2016-04-28 01:51:47 +0100
commit6d7593fbdec7235d9d21506860513ba43ef3df2f (patch)
treee18507525889b022031e5daa0996e87d108e38d7 /sshconnect2.c
parent8590fd4848ae41b97726d7147daae271a3ab5063 (diff)
parent43a633de1cabe77e652125dac394a99ad9cac3b4 (diff)
Backport upstream patch to unbreak authentication using lone certificate keys in ssh-agent: when attempting pubkey auth with a certificate, if no separate private key is found among the keys then try with the certificate key itself (thanks, Paul Querna; LP: #1575961).
Diffstat (limited to 'sshconnect2.c')
-rw-r--r--sshconnect2.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/sshconnect2.c b/sshconnect2.c
index b452eae24..40facdab5 100644
--- a/sshconnect2.c
+++ b/sshconnect2.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: sshconnect2.c,v 1.239 2016/02/23 01:34:14 djm Exp $ */ 1/* $OpenBSD: sshconnect2.c,v 1.240 2016/03/14 16:20:54 djm Exp $ */
2/* 2/*
3 * Copyright (c) 2000 Markus Friedl. All rights reserved. 3 * Copyright (c) 2000 Markus Friedl. All rights reserved.
4 * Copyright (c) 2008 Damien Miller. All rights reserved. 4 * Copyright (c) 2008 Damien Miller. All rights reserved.
@@ -1224,12 +1224,8 @@ sign_and_send_pubkey(Authctxt *authctxt, Identity *id)
1224 "certificate", __func__, id->filename, 1224 "certificate", __func__, id->filename,
1225 id->agent_fd != -1 ? " from agent" : ""); 1225 id->agent_fd != -1 ? " from agent" : "");
1226 } else { 1226 } else {
1227 /* XXX maybe verbose/error? */ 1227 debug("%s: no separate private key for certificate "
1228 debug("%s: no private key for certificate "
1229 "\"%s\"", __func__, id->filename); 1228 "\"%s\"", __func__, id->filename);
1230 free(blob);
1231 buffer_free(&b);
1232 return 0;
1233 } 1229 }
1234 } 1230 }
1235 1231