summaryrefslogtreecommitdiff
path: root/clientloop.c
diff options
context:
space:
mode:
authordjm@openbsd.org <djm@openbsd.org>2021-12-19 22:08:48 +0000
committerDamien Miller <djm@mindrot.org>2021-12-20 09:24:42 +1100
commite9497ecf73f3c16667288bce48d4e3d7e746fea1 (patch)
treea066c9cb60add52ff97fe31bdc8d631716e0c248 /clientloop.c
parentb42c61d6840d16ef392ed0f365e8c000734669aa (diff)
downloadopenssh-git-e9497ecf73f3c16667288bce48d4e3d7e746fea1.tar.gz
upstream: ssh client side of binding
send session ID, hostkey, signature and a flag indicating whether the agent connection is being forwarded to ssh agent each time a connection is opened via a new "session-bind@openssh.com" agent extension. ok markus@ OpenBSD-Commit-ID: 2f154844fe13167d3ab063f830d7455fcaa99135
Diffstat (limited to 'clientloop.c')
-rw-r--r--clientloop.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/clientloop.c b/clientloop.c
index 147dfd21..7652b35a 100644
--- a/clientloop.c
+++ b/clientloop.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: clientloop.c,v 1.371 2021/11/18 21:32:11 djm Exp $ */
+/* $OpenBSD: clientloop.c,v 1.372 2021/12/19 22:08:48 djm Exp $ */
/*
* Author: Tatu Ylonen <ylo@cs.hut.fi>
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -1597,6 +1597,12 @@ client_request_agent(struct ssh *ssh, const char *request_type, int rchan)
debug_fr(r, "ssh_get_authentication_socket");
return NULL;
}
+ if ((r = ssh_agent_bind_hostkey(sock, ssh->kex->initial_hostkey,
+ ssh->kex->session_id, ssh->kex->initial_sig, 1)) == 0)
+ debug_f("bound agent to hostkey");
+ else
+ debug2_fr(r, "ssh_agent_bind_hostkey");
+
c = channel_new(ssh, "authentication agent connection",
SSH_CHANNEL_OPEN, sock, sock, -1,
CHAN_X11_WINDOW_DEFAULT, CHAN_TCP_PACKET_DEFAULT, 0,