[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 0/3] Allow use of ssh_bind_accept_fd without ssh_bind_listen


Hi folks,

I noticed that ssh_bind_accept_fd doesn't appear to work on its own
for accepting fds that have come through an accept on a listening
socket.  It seems that server private keys are read in from their file
locations in ssh_bind_listen, so that if ssh_bind_accept_fd is used
instead without the intent to ever use ssh_bind_listen, then a
subsequent ssh_handle_key_exchange will always return an error
(server_set_kex in server.c wil return -1).

This patch allows keys to be set up in ssh_bind_accept_fd or
ssh_bind_listen, whichever is called first.  Then ssh_bind_accept_fd
can be called by itself.

Alan Dunn (3):
  Separate out key import functionality from ssh_bind_listen
  Import keys during ssh_bind_accept_fd
  Test change to ssh_bind_accept_fd

 src/bind.c                      |   42 ++++++++----
 tests/test_ssh_bind_accept_fd.c |  139 +++++++++++++++++++++++++++++++++++++++
 2 files changed, 169 insertions(+), 12 deletions(-)
 create mode 100644 tests/test_ssh_bind_accept_fd.c

-- 
1.7.9.5


Archive administrator: postmaster@lists.cynapses.org