Bug 1569 - Hostbased auth fails when using a proxy command
Summary: Hostbased auth fails when using a proxy command
Status: CLOSED FIXED
Alias: None
Product: Portable OpenSSH
Classification: Unclassified
Component: ssh (show other bugs)
Version: 5.2p1
Hardware: All All
: P2 normal
Assignee: Assigned to nobody
URL:
Keywords:
Depends on:
Blocks: V_5_4
  Show dependency treegraph
 
Reported: 2009-03-10 05:16 AEDT by Iain Morgan
Modified: 2010-03-26 10:51 AEDT (History)
2 users (show)

See Also:


Attachments
Allow get_local_name() to handle a socket or pipe. (2.78 KB, patch)
2009-03-10 05:16 AEDT, Iain Morgan
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Iain Morgan 2009-03-10 05:16:47 AEDT
Created attachment 1612 [details]
Allow get_local_name() to handle a socket or pipe.

If hostbased authentication is enabled and a proxy command is used to 
connect to the server, the following warning messages typically
appear:

cannot get sockname for fd
ssh_keysign: no reply
key_sign failed

This is due to the assumption that the file descriptor passed to 
get_local_name() corresponds to a socket, which is not the case when a
proxy command is used.

The attached patch modifies get_local_name() sot that it falls back to
using gethostname() if get_socket_address() fails. As a result, some
redundant code in sshconnect2.c is removed. A typo is sshconnect2.c is
also fixed. ('no installed' vs 'not installed')
Comment 1 Darren Tucker 2010-01-13 12:20:55 AEDT
Your patch has been applied and will be in the 5.4 release.

Thanks.
Comment 2 Darren Tucker 2010-03-26 10:51:45 AEDT
With the release of 5.4p1, this bug is now considered closed.