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

Re: puTTY and debian



> On Thu, Oct 20, 2005 at 07:44:46AM -0400, deb@cercy.net wrote:
> } For some time I've used the ssh client program puTTY to connect from
> } windows machines to debian systems. However, every 3.1 box I've
> installed } refuses to accept ssh logins via putty. What specific
> protocol options } does the pre-compiled sshd requires? I've checekd
> the config files, run } tcpdump to check connectivity, but I've
> uncovered nothing. Is there a way } to turn on logging for sshd? I've
> seen a previous post where someone was } having similar problems with
> the linux puTTY package for debian not being } able to login to other
> debian sshd servers, but there was no resolution } mentioned.
>
> I have never experienced the problems you mention. As I type this, I am
> logged into my Debian box at home (running etch rather than sarge, but
> it ran sarge before its release as stable and I also had no problems)
> with PuTTY on Windows.
>
> That said, here are some ideas on diagnosing your problem. First, edit
> your /etc/ssh/sshd_config and change the LogLevel to DEBUG.
> You should see a line that says that the SyslogFacility being used is
> AUTH; in a normal configuration, this means that sshd messages go to
> /var/log/auth.log and you can grep that file for sshd. Once you've
> restarted sshd after changing the log level, run (as root):
>
> tail -f /var/log/auth.log | grep sshd
>
> This will show you only sshd messages. Now attempt to connect with
> PuTTY. You should see a bunch of output which, one hopes, will shed
> some light on the subject. If it isn't clear to you what the problem
> is, paste that output into your next message.
>
> Also, PuTTY itself has an Event Log accessible from its system menu.
> That, too, may be informative.
>
> --Greg


Thanks for the tips, I totally overlooked the log level in the sshd file.
When I looked at the putty log, it just says the authentication fails,
each time you enter a passwd. The debian sshd logs didn't help a lot, just
one line at the begining saying "no match". But exactly whats not matching
isn't very obvious to me. However by random changing of the puTTY options,
I found settings that work: using ssh protocol version 2 (it defaults to
1) and I check an option saying "Enable legacy use of single-DES in ssh2".
I had tried various options over the last couple of days, but I lucked
into the right ones this morning.
But isn't DES the least of the encryption schemes? I'd like my server to
use the one thats the hardest to crack. Ssh is such a massively important
protocol its amazing how little know about it.
Below is an example of the failed login without the options above:
Oct 20 08:47:12 orl-wikidev-1 sshd[27194]: debug1: Forked child 27196.
Oct 20 08:47:12 orl-wikidev-1 sshd[27196]: Connection from
::ffff:151.214.156.16 port 1654Oct 20 08:47:12 orl-wikidev-1 sshd[27196]: debug1: Client protocol version
1.5; client software version PuTTY_Release_0.58Oct 20 08:47:12 orl-wikidev-1 sshd[27196]: debug1: no match:
PuTTY_Release_0.58Oct 20 08:47:12 orl-wikidev-1 sshd[27196]: debug1: Local version string
SSH-1.99-OpenSSH_3.8.1p1 Debian-8.sarge.4Oct 20 08:47:17 orl-wikidev-1 sshd[27196]: debug1: PAM: initializing for
"gregg"Oct 20 08:47:17 orl-wikidev-1 sshd[27196]: debug1: PAM: setting PAM_RHOST
to "nocorlcl3.ops.x"Oct 20 08:47:17 orl-wikidev-1 sshd[27196]: debug1: PAM: setting PAM_TTY to
"ssh"Oct 20 08:47:27 orl-wikidev-1 sshd[27196]: debug1: do_cleanup
Oct 20 08:47:27 orl-wikidev-1 sshd[27196]: debug1: PAM: cleanup

Here is a successful connection with the options mentioned above:
Oct 20 09:24:34 orl-wikidev-1 sshd[27263]: Connection from
::ffff:151.214.156.16 port 1692Oct 20 09:24:34 orl-wikidev-1 sshd[27194]: debug1: Forked child 27263.
Oct 20 09:24:34 orl-wikidev-1 sshd[27263]: debug1: Client protocol version
2.0; client software version PuTTY_Release_0.58Oct 20 09:24:34 orl-wikidev-1 sshd[27263]: debug1: no match:
PuTTY_Release_0.58Oct 20 09:24:34 orl-wikidev-1 sshd[27263]: debug1: Enabling compatibility
mode for protocol 2.0Oct 20 09:24:34 orl-wikidev-1 sshd[27263]: debug1: Local version string
SSH-1.99-OpenSSH_3.8.1p1 Debian-8.sarge.4Oct 20 09:24:38 orl-wikidev-1 sshd[27263]: debug1: PAM: initializing for
"gregg"Oct 20 09:24:38 orl-wikidev-1 sshd[27263]: debug1: PAM: setting PAM_RHOST
to "nocorlcl3.ops.x"Oct 20 09:24:38 orl-wikidev-1 sshd[27263]: debug1: PAM: setting PAM_TTY to
"ssh"Oct 20 09:24:40 orl-wikidev-1 sshd[27263]: Accepted
keyboard-interactive/pam for gregg from ::ffff:151.214.156.16 port 1692
ssh2Oct 20 09:24:40 orl-wikidev-1 sshd[27263]: debug1: monitor_child_preauth:
gregg has been authenticated by privileged processOct 20 09:24:40 orl-wikidev-1 sshd[27266]: (pam_unix) session opened for
user gregg by (uid=0)Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: PAM: reinitializing
credentialsOct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: permanently_set_uid:
1000/1000Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: Entering interactive
session for SSH2.Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: server_init_dispatch_20
Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1:
server_input_channel_open: ctype session rchan 256 win 16384 max 16384Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: input_session_request
Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: channel 0: new
[server-session]Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: session_new: init
Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: session_new: session 0
Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: session_open: channel 0
Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: session_open: session
0: link with channel 0Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1:
server_input_channel_open: confirm sessionOct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1:
server_input_channel_req: channel 0 request pty-req reply 1Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: session_by_channel:
session 0 channel 0Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1:
session_input_channel_req: session 0 req pty-reqOct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: Allocating pty.
Oct 20 09:24:40 orl-wikidev-1 sshd[27263]: debug1: session_new: init
Oct 20 09:24:40 orl-wikidev-1 sshd[27263]: debug1: session_new: session 0
Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: session_pty_req:
session 0 alloc /dev/pts/1Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1:
server_input_channel_req: channel 0 request shell reply 1Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: session_by_channel:
session 0 channel 0Oct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1:
session_input_channel_req: session 0 req shellOct 20 09:24:40 orl-wikidev-1 sshd[27266]: debug1: PAM: setting PAM_TTY to
"/dev/pts/1"Oct 20 09:24:40 orl-wikidev-1 sshd[27267]: debug1: Setting controlling tty
using TIOCSCTTY.Oct 20 09:24:45 orl-wikidev-1 sshd[27266]: debug1: Received SIGCHLD.
Oct 20 09:24:45 orl-wikidev-1 sshd[27266]: debug1: session_by_pid: pid 27267
Oct 20 09:24:45 orl-wikidev-1 sshd[27266]: debug1: session_exit_message:
session 0 channel 0 pid 27267Oct 20 09:24:45 orl-wikidev-1 sshd[27266]: debug1: session_exit_message:
release channel 0Oct 20 09:24:45 orl-wikidev-1 sshd[27266]: debug1: session_close: session
0 pid 27267Oct 20 09:24:45 orl-wikidev-1 sshd[27263]: debug1: session_by_tty: session
0 tty /dev/pts/1Oct 20 09:24:45 orl-wikidev-1 sshd[27263]: debug1: session_pty_cleanup:
session 0 release /dev/pts/1Oct 20 09:24:45 orl-wikidev-1 sshd[27266]: debug1: channel 0: free:
server-session, nchannels 1Oct 20 09:24:45 orl-wikidev-1 sshd[27266]: Connection closed by
::ffff:151.214.156.16Oct 20 09:24:45 orl-wikidev-1 sshd[27266]: debug1: do_cleanup
Oct 20 09:24:45 orl-wikidev-1 sshd[27266]: debug1: PAM: cleanup
Oct 20 09:24:45 orl-wikidev-1 sshd[27266]: (pam_unix) session closed for
user greggOct 20 09:24:45 orl-wikidev-1 sshd[27266]: Closing connection to
::ffff:151.214.156.16Oct 20 09:24:45 orl-wikidev-1 sshd[27266]: debug1: PAM: cleanup

Thanks again.






Reply to: