X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:date:from:mime-version:to:subject :references:in-reply-to:content-type; q=dns; s=default; b=kRNFit e4A6KjfR1NklU6LWdwQujyoCQn25B4EmzoJKLaGukwfV5g9KpLzNHDWDQZvoithW ijQZmKfCOsLcHIGvTOTZ0WkLO3wyrOXImU3zh1/zbuWenhpOfix6g1SJ1SlWBfH9 nV/NSrg/f250QGdGh8bJNh/fxNhRn/l7M/H28= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:date:from:mime-version:to:subject :references:in-reply-to:content-type; s=default; bh=Cxz4dkEDkH67 kxzRZDVRA25lBFI=; b=vZHqlGDDxMnzhPG+HqQwFN5y2ChsX16uR1ofpAkcDt+s bdMNZYXT8E672aTEitSrWbW7iK5ryUM0YOC/OBsd3/c8BIKPk7Ot4tbC3P0KZNkQ ObRXmOc2mJpdLmuV+U2IojTbdJIC06aYXWjPd2JbYPM2bVWJ04KbzBzRnSY2K3w= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=1.0 required=5.0 tests=AWL,BAYES_50,SPF_PASS,T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-HELO: mgw-sa02.nokia.com Message-ID: <54A672F7.2010104@nokia.com> Date: Fri, 02 Jan 2015 12:29:11 +0200 From: Ilya Dogolazky User-Agent: Mozilla/5.0 (X11; Linux i686 on x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.3.0 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: Never ending SSHD story: offering public key terminates connection References: <54A485DE DOT 1090802 AT nokia DOT com> In-Reply-To: <54A485DE.1090802@nokia.com> Content-Type: multipart/mixed; boundary="------------070800080406030205020305" X-Nokia-AV: Clean X-IsSubscribed: yes --------------070800080406030205020305 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit A small follow up about this: I found a registry string Computer\HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\sshd\Parameters\AppArgs and changed the sshd command line parameters from "-D" to "-d -d -d" This was enough to receive the server log in /var/log/sshd.log (attached here). The interesting line in the file is in my opinion this one: "seteuid 1001: Operation not permitted" The number "1001" is the UID of the user ilya. Thus something seems to be wrong with permissions in the system. --------------070800080406030205020305 Content-Type: text/x-log; name="sshd.log" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="sshd.log" debug2: load_server_config: filename /etc/sshd_config debug2: load_server_config: done config len = 235 debug2: parse_server_config: config /etc/sshd_config len 235 debug3: /etc/sshd_config:54 setting AuthorizedKeysFile .ssh/authorized_keys debug3: /etc/sshd_config:110 setting UsePrivilegeSeparation yes debug3: /etc/sshd_config:126 setting Subsystem sftp /usr/sbin/sftp-server debug1: sshd version OpenSSH_6.7, OpenSSL 1.0.1j 15 Oct 2014 debug1: private host key: #0 type 1 RSA debug1: private host key: #1 type 2 DSA debug1: private host key: #2 type 3 ECDSA debug1: private host key: #3 type 4 ED25519 debug1: rexec_argv[0]='/usr/sbin/sshd' debug1: rexec_argv[1]='-d' debug1: rexec_argv[2]='-d' debug1: rexec_argv[3]='-d' debug2: fd 3 setting O_NONBLOCK debug3: sock_set_v6only: set socket 3 IPV6_V6ONLY debug1: Bind to port 22 on ::. Server listening on :: port 22. debug2: fd 4 setting O_NONBLOCK debug1: Bind to port 22 on 0.0.0.0. Server listening on 0.0.0.0 port 22. debug1: fd 5 clearing O_NONBLOCK debug1: Server will not fork when running in debugging mode. debug3: send_rexec_state: entering fd = 8 config len 235 debug3: ssh_msg_send: type 0 debug3: send_rexec_state: done debug1: rexec start in 5 out 5 newsock 5 pipe -1 sock 8 debug1: inetd sockets after dupping: 3, 3 Connection from ::1 port 49235 on ::1 port 22 debug1: Client protocol version 2.0; client software version OpenSSH_6.7 debug1: match: OpenSSH_6.7 pat OpenSSH* compat 0x04000000 debug1: Enabling compatibility mode for protocol 2.0 debug1: Local version string SSH-2.0-OpenSSH_6.7 debug2: fd 3 setting O_NONBLOCK debug2: Network child is on pid 2504 debug3: preauth child monitor started debug1: list_hostkey_types: ssh-rsa,ssh-dss,ecdsa-sha2-nistp256,ssh-ed25519 [preauth] debug1: SSH2_MSG_KEXINIT sent [preauth] debug1: SSH2_MSG_KEXINIT received [preauth] debug2: kex_parse_kexinit: curve25519-sha256 AT libssh DOT org,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group14-sha1 [preauth] debug2: kex_parse_kexinit: ssh-rsa,ssh-dss,ecdsa-sha2-nistp256,ssh-ed25519 [preauth] debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,aes128-gcm AT openssh DOT com,aes256-gcm AT openssh DOT com,chacha20-poly1305 AT openssh DOT com [preauth] debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,aes128-gcm AT openssh DOT com,aes256-gcm AT openssh DOT com,chacha20-poly1305 AT openssh DOT com [preauth] debug2: kex_parse_kexinit: umac-64-etm AT openssh DOT com,umac-128-etm AT openssh DOT com,hmac-sha2-256-etm AT openssh DOT com,hmac-sha2-512-etm AT openssh DOT com,hmac-sha1-etm AT openssh DOT com,umac-64 AT openssh DOT com,umac-128 AT openssh DOT com,hmac-sha2-256,hmac-sha2-512,hmac-sha1 [preauth] debug2: kex_parse_kexinit: umac-64-etm AT openssh DOT com,umac-128-etm AT openssh DOT com,hmac-sha2-256-etm AT openssh DOT com,hmac-sha2-512-etm AT openssh DOT com,hmac-sha1-etm AT openssh DOT com,umac-64 AT openssh DOT com,umac-128 AT openssh DOT com,hmac-sha2-256,hmac-sha2-512,hmac-sha1 [preauth] debug2: kex_parse_kexinit: none,zlib AT openssh DOT com [preauth] debug2: kex_parse_kexinit: none,zlib AT openssh DOT com [preauth] debug2: kex_parse_kexinit: [preauth] debug2: kex_parse_kexinit: [preauth] debug2: kex_parse_kexinit: first_kex_follows 0 [preauth] debug2: kex_parse_kexinit: reserved 0 [preauth] debug2: kex_parse_kexinit: curve25519-sha256 AT libssh DOT org,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 [preauth] debug2: kex_parse_kexinit: ecdsa-sha2-nistp256-cert-v01 AT openssh DOT com,ecdsa-sha2-nistp384-cert-v01 AT openssh DOT com,ecdsa-sha2-nistp521-cert-v01 AT openssh DOT com,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,ssh-ed25519-cert-v01 AT openssh DOT com,ssh-rsa-cert-v01 AT openssh DOT com,ssh-dss-cert-v01 AT openssh DOT com,ssh-rsa-cert-v00 AT openssh DOT com,ssh-dss-cert-v00 AT openssh DOT com,ssh-ed25519,ssh-rsa,ssh-dss [preauth] debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,aes128-gcm AT openssh DOT com,aes256-gcm AT openssh DOT com,chacha20-poly1305 AT openssh DOT com,arcfour256,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,rijndael-cbc AT lysator DOT liu DOT se [preauth] debug2: kex_parse_kexinit: aes128-ctr,aes192-ctr,aes256-ctr,aes128-gcm AT openssh DOT com,aes256-gcm AT openssh DOT com,chacha20-poly1305 AT openssh DOT com,arcfour256,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,aes256-cbc,arcfour,rijndael-cbc AT lysator DOT liu DOT se [preauth] debug2: kex_parse_kexinit: umac-64-etm AT openssh DOT com,umac-128-etm AT openssh DOT com,hmac-sha2-256-etm AT openssh DOT com,hmac-sha2-512-etm AT openssh DOT com,hmac-sha1-etm AT openssh DOT com,umac-64 AT openssh DOT com,umac-128 AT openssh DOT com,hmac-sha2-256,hmac-sha2-512,hmac-sha1,hmac-md5-etm AT openssh DOT com,hmac-ripemd160-etm AT openssh DOT com,hmac-sha1-96-etm AT openssh DOT com,hmac-md5-96-etm AT openssh DOT com,hmac-md5,hmac-ripemd160,hmac-ripemd160 AT openssh DOT com,hmac-sha1-96,hmac-md5-96 [preauth] debug2: kex_parse_kexinit: umac-64-etm AT openssh DOT com,umac-128-etm AT openssh DOT com,hmac-sha2-256-etm AT openssh DOT com,hmac-sha2-512-etm AT openssh DOT com,hmac-sha1-etm AT openssh DOT com,umac-64 AT openssh DOT com,umac-128 AT openssh DOT com,hmac-sha2-256,hmac-sha2-512,hmac-sha1,hmac-md5-etm AT openssh DOT com,hmac-ripemd160-etm AT openssh DOT com,hmac-sha1-96-etm AT openssh DOT com,hmac-md5-96-etm AT openssh DOT com,hmac-md5,hmac-ripemd160,hmac-ripemd160 AT openssh DOT com,hmac-sha1-96,hmac-md5-96 [preauth] debug2: kex_parse_kexinit: none,zlib AT openssh DOT com,zlib [preauth] debug2: kex_parse_kexinit: none,zlib AT openssh DOT com,zlib [preauth] debug2: kex_parse_kexinit: [preauth] debug2: kex_parse_kexinit: [preauth] debug2: kex_parse_kexinit: first_kex_follows 0 [preauth] debug2: kex_parse_kexinit: reserved 0 [preauth] debug2: mac_setup: setup umac-64-etm AT openssh DOT com [preauth] debug1: kex: client->server aes128-ctr umac-64-etm AT openssh DOT com none [preauth] debug2: mac_setup: setup umac-64-etm AT openssh DOT com [preauth] debug1: kex: server->client aes128-ctr umac-64-etm AT openssh DOT com none [preauth] debug1: expecting SSH2_MSG_KEX_ECDH_INIT [preauth] debug3: mm_key_sign entering [preauth] debug3: mm_request_send entering: type 6 [preauth] debug3: mm_key_sign: waiting for MONITOR_ANS_SIGN [preauth] debug3: mm_request_receive_expect entering: type 7 [preauth] debug3: mm_request_receive entering [preauth] debug3: mm_request_receive entering debug3: monitor_read: checking request 6 debug3: mm_answer_sign debug3: mm_answer_sign: signature 0x60005bda0(99) debug3: mm_request_send entering: type 7 debug2: monitor_read: 6 used once, disabling now debug2: kex_derive_keys [preauth] debug2: set_newkeys: mode 1 [preauth] debug1: SSH2_MSG_NEWKEYS sent [preauth] debug1: expecting SSH2_MSG_NEWKEYS [preauth] debug2: set_newkeys: mode 0 [preauth] debug1: SSH2_MSG_NEWKEYS received [preauth] debug1: KEX done [preauth] debug1: userauth-request for user ilya service ssh-connection method none [preauth] debug1: attempt 0 failures 0 [preauth] debug3: mm_getpwnamallow entering [preauth] debug3: mm_request_send entering: type 8 [preauth] debug3: mm_getpwnamallow: waiting for MONITOR_ANS_PWNAM [preauth] debug3: mm_request_receive_expect entering: type 9 [preauth] debug3: mm_request_receive entering [preauth] debug3: mm_request_receive entering debug3: monitor_read: checking request 8 debug3: mm_answer_pwnamallow debug3: Trying to reverse map address ::1. Address ::1 maps to w9, but this does not map back to the address - POSSIBLE BREAK-IN ATTEMPT! debug2: parse_server_config: config reprocess config len 235 debug3: mm_answer_pwnamallow: sending MONITOR_ANS_PWNAM: 1 debug3: mm_request_send entering: type 9 debug2: monitor_read: 8 used once, disabling now debug2: input_userauth_request: setting up authctxt for ilya [preauth] debug3: mm_inform_authserv entering [preauth] debug3: mm_request_send entering: type 4 [preauth] debug2: input_userauth_request: try method none [preauth] debug3: userauth_finish: failure partial=0 next methods="publickey,password,keyboard-interactive" [preauth] debug1: userauth-request for user ilya service ssh-connection method publickey [preauth] debug1: attempt 1 failures 0 [preauth] debug2: input_userauth_request: try method publickey [preauth] debug1: test whether pkalg/pkblob are acceptable [preauth] debug3: mm_key_allowed entering [preauth] debug3: mm_request_send entering: type 22 [preauth] debug3: mm_key_allowed: waiting for MONITOR_ANS_KEYALLOWED [preauth] debug3: mm_request_receive_expect entering: type 23 [preauth] debug3: mm_request_receive entering [preauth] debug3: mm_request_receive entering debug3: monitor_read: checking request 4 debug3: mm_answer_authserv: service=ssh-connection, style= debug2: monitor_read: 4 used once, disabling now debug3: mm_request_receive entering debug3: monitor_read: checking request 22 debug3: mm_answer_keyallowed entering debug3: mm_answer_keyallowed: key_from_blob: 0x60005afe0 debug1: temporarily_use_uid: 1001/513 (e=18/544) seteuid 1001: Operation not permitted debug1: do_cleanup debug1: Killing privsep child 2504 --------------070800080406030205020305 Content-Type: text/plain; charset=us-ascii -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple --------------070800080406030205020305--