delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2011/08/01/22:34:11

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=4.3 required=5.0 tests=AWL,BAYES_40,BOTNET,RCVD_IN_DNSWL_NONE,TW_MK
X-Spam-Check-By: sourceware.org
Message-id: <4E3761FE.7070908@cygwin.com>
Date: Mon, 01 Aug 2011 22:33:34 -0400
From: "Larry Hall (Cygwin)" <reply-to-list-only-lh AT cygwin DOT com>
Reply-to: cygwin AT cygwin DOT com
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:5.0) Gecko/20110624 Thunderbird/5.0
MIME-version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: sshd conflicts with mintty allocating /dev/tty[0-9]
References: <4E36CB68 DOT 3000606 AT ank-sia DOT com> <4E36D731 DOT 2090104 AT ank-sia DOT com>
In-reply-to: <4E36D731.2090104@ank-sia.com>
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On 8/1/2011 12:41 PM, Alexey Luchko wrote:
> On 01.08.2011 18:51, Alexey Luchko wrote:
>> I've run mkpasswd and mkgroups, installed sshd, run sshd-host-config,
>> turned on privilege separation, installed it as a service.
>>
>> 'CYGWIN sshd' service starts normally but it closes connection right after
>> successful login:
>> """
>> $ ssh localhost
>> user AT localhost's password:
>> Connection to localhost closed by remote host.
>> Connection to localhost closed.
>> """
>>
>> Logged in sshd's account and started '/usr/sbin/sshd -d' and tries to login
>> via ssh localhost. Tail of sshd output follows:
>> """
>> debug1: userauth-request for user user service ssh-connection method password
>> debug1: attempt 2 failures 1
>> Accepted password for user from ::1 port 63719 ssh2
>> debug1: monitor_child_preauth: user has been authenticated by privileged
>> process
>> debug1: Entering interactive session for SSH2.
>> debug1: server_init_dispatch_20
>> debug1: server_input_channel_open: ctype session rchan 0 win 1048576 max
>> 16384
>> debug1: input_session_request
>> debug1: channel 0: new [server-session]
>> debug1: session_new: session 0
>> debug1: session_open: channel 0
>> debug1: session_open: session 0: link with channel 0
>> debug1: server_input_channel_open: confirm session
>> debug1: server_input_global_request: rtype no-more-sessions AT openssh DOT com
>> want_reply 0
>> debug1: server_input_channel_req: channel 0 request pty-req reply 1
>> debug1: session_by_channel: session 0 channel 0
>> debug1: session_input_channel_req: session 0 req pty-req
>> debug1: Allocating pty.
>> debug1: session_pty_req: session 0 alloc /dev/tty2
>> chown(/dev/tty2, 11135, 10513) failed: Bad file descriptor
>> debug1: do_cleanup
>> debug1: session_pty_cleanup: session 0 release /dev/tty2
>> """
>>
>> It conflicts with mintty because every mintty allocates terminal for
>> himself like this running in mintty:
>> """
>> $ ls -l `tty`
>> crw--w---- 1 user Domain Users 136, 0 Aug 1 18:46 /dev/tty0
>> """
>>
>> Version: CYGWIN_NT-6.1-WOW64 1.7.9(0.237/5/3) 2011-03-29 10:10 i686 Cygwin
>
>
> Cygwin Configuration Diagnostics atteched.

Maybe crank up the debugging flags to maximum?  I assume sshd is still
stopped from your last run of sshd -d.  If that doesn't sound right to
you, you may want to investigate why it's not running now.

-- 
Larry

_____________________________________________________________________

A: Yes.
 > Q: Are you sure?
 >> A: Because it reverses the logical flow of conversation.
 >>> Q: Why is top posting annoying in email?

--
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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019