Re: 1.5.5: sshd problem

2003-12-04 Thread John Pye
Hi Igor

I completely removed my cygwin installation and reinstalled. That fixed 
the problem. I don't know how things managed to get so broken; I think 
it was to do with running ssh-host-config as a second user perhaps, but 
I'm not sure of that.

So, problem solved, although not elegantly. Thanks for all the suggestions.

JP

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


Re: 1.5.5: sshd problem

2003-11-17 Thread Igor Pechtchanski
On Mon, 17 Nov 2003, John Pye wrote:

> Thanks for the extra tips, Igor. Do any of these results look strange to
> you?
>
> Igor Pechtchanski wrote:
>
> >That's the default mode Windows gives it.  This should work, but somehow
> >doesn't...  Can sshd get to all the necessary files and directories?  Look
> >at the permissions on /etc and the files in it, as well as /bin.
>
> I tried an ls -l /etc and found
>
> -rwxr-xr-x1 SYSTEM   None 1159 Nov 13 19:02 ssh_config
> -rw---1 SYSTEM   None  668 Nov 13 19:02 ssh_host_dsa_key
> -rw-r--r--1 SYSTEM   None  599 Nov 13 19:02 ssh_host_dsa_key.pub
> -rw---1 SYSTEM   None  524 Nov 13 19:02 ssh_host_key
> -rw-r--r--1 SYSTEM   None  328 Nov 13 19:02 ssh_host_key.pub
> -rw---1 SYSTEM   None  887 Nov 13 19:02 ssh_host_rsa_key
> -rw-r--r--1 SYSTEM   None  219 Nov 13 19:02 ssh_host_rsa_key.pub
> -rw-r--r--1 SYSTEM   None 2427 Nov 13 19:03 sshd_config
>
> That looks OK I thought... or is it? Does 'SYSTEM' need to be able to
> read those files, or does 'sshd'?

Whatever account the ssh daemon is running as (if you use cygrunsrv or the
ssh-host-config script, it's most likely "SYSTEM").  How about 'ls -ld
/etc'?

> I also had a look at /etc/bin and it's all  owned by john.Users, for example

Huh?  /etc/bin?  I assume you mean /usr/bin or /bin.

> -rwxrwxrwx1 john Users   19456 Feb 20  2002 split.exe
> -rwxrwxrwx1 john Users   68608 Nov  6 02:47 ssh-add.exe
> -rwxrwxrwx1 john Users   57856 Nov  6 02:47 ssh-agent.exe
> -rwxrwxrwx1 john Users   17333 Nov  6 02:47 ssh-host-config
> -rwxrwxrwx1 john Users   75776 Nov  6 02:47 ssh-keygen.exe
> -rwxrwxrwx1 john Users  130048 Nov  6 02:47 ssh-keyscan.exe
> -rwxrwxrwx1 john Users6266 Nov  6 02:47 ssh-user-config
> -rwxrwxrwx1 john Users  223232 Nov  6 02:47 ssh.exe
> -rwxrwxrwx1 john Users   18944 Sep 21 06:32 ssp.exe
> -rwxrwxrwx1 john Users   87552 Aug 26  2002 states.exe
> -rwxrwxrwx1 john Users   23552 Sep 21 06:32 strace.exe
>
> That could be a problem perhaps? Should the 'Users' group contain 'sshd'
> or is access for sshd to the /bin executables handled somehow else?

No, the access on the files themselves is ok.  How about 'ls -ld /bin'?

> >Ok, looks like all your mounts are system mounts, unless you simply don't
> >have the permission to read the registry keys for the SYSTEM user...
>
> That seems strange. My home computer has a couple of mounts when I run
> that command, but this system has none. However, it works fine locally
> (compiling, listing files, /cygdrive/c, etc). I haven't ever tinkered
> with the mounts, so I wonder how that comes to be... Couldn't be related
> to mingw/msys could it?
>
> John

It's related to the mode you installed Cygwin in ("Just me" vs. "All
users").  If you installed for "Just me", you may be missing the necessary
mounts for services like sshd to work.

Looking at your earlier message, however, I start wondering if we aren't
barking up the wrong tree here...

On Thu, 13 Nov 2003, John Pye wrote:

> I still get the error as shown
>
>  [EMAIL PROTECTED] ~
>  $ ssh localhost
>  ssh_exchange_identification: Connection closed by remote host
>
> The verbose output is
>
> $ ssh -vvv localhost
> OpenSSH_3.7.1p2, SSH protocols 1.5/2.0, OpenSSL 0.9.7c 30 Sep 2003
> debug1: Reading configuration data /etc/ssh_config
> debug2: ssh_connect: needpriv 0
> debug1: Connecting to localhost [127.0.0.1] port 22.
> debug1: Connection established.
> debug1: identity file /home/john/.ssh/identity type 0
> debug3: Not a RSA1 key file /home/john/.ssh/id_rsa.
  ^^^
> debug2: key_type_from_name: unknown key type '-BEGIN'
> debug3: key_read: missing keytype
> debug2: key_type_from_name: unknown key type 'Proc-Type:'
> debug3: key_read: missing keytype
> debug2: key_type_from_name: unknown key type 'DEK-Info:'
> debug3: key_read: missing keytype
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug2: key_type_from_name: unknown key type '-END'
> debug3: key_read: missing keytype
> debug1: identity file /home/john/.ssh/id_rsa type 1
> debug1: identity file /home/john/.ssh/id_dsa type -1
> ssh_exchange_identification: Connection closed by remote host
> debug1: Calling cleanup 0x41bf10(0x0)

Could you try removing /home/john/.ssh and re-running
/bin/ssh-user-config?
Ig

Re: 1.5.5: sshd problem

2003-11-16 Thread John Pye
Thanks for the extra tips, Igor. Do any of these results look strange to 
you?

Igor Pechtchanski wrote:

That's the default mode Windows gives it.  This should work, but somehow
doesn't...  Can sshd get to all the necessary files and directories?  Look
at the permissions on /etc and the files in it, as well as /bin.
 

I tried an ls -l /etc and found

-rwxr-xr-x1 SYSTEM   None 1159 Nov 13 19:02 ssh_config
-rw---1 SYSTEM   None  668 Nov 13 19:02 ssh_host_dsa_key
-rw-r--r--1 SYSTEM   None  599 Nov 13 19:02 ssh_host_dsa_key.pub
-rw---1 SYSTEM   None  524 Nov 13 19:02 ssh_host_key
-rw-r--r--1 SYSTEM   None  328 Nov 13 19:02 ssh_host_key.pub
-rw---1 SYSTEM   None  887 Nov 13 19:02 ssh_host_rsa_key
-rw-r--r--1 SYSTEM   None  219 Nov 13 19:02 ssh_host_rsa_key.pub
-rw-r--r--1 SYSTEM   None 2427 Nov 13 19:03 sshd_config
That looks OK I thought... or is it? Does 'SYSTEM' need to be able to 
read those files, or does 'sshd'?

I also had a look at /etc/bin and it's all  owned by john.Users, for example

-rwxrwxrwx1 john Users   19456 Feb 20  2002 split.exe
-rwxrwxrwx1 john Users   68608 Nov  6 02:47 ssh-add.exe
-rwxrwxrwx1 john Users   57856 Nov  6 02:47 ssh-agent.exe
-rwxrwxrwx1 john Users   17333 Nov  6 02:47 ssh-host-config
-rwxrwxrwx1 john Users   75776 Nov  6 02:47 ssh-keygen.exe
-rwxrwxrwx1 john Users  130048 Nov  6 02:47 ssh-keyscan.exe
-rwxrwxrwx1 john Users6266 Nov  6 02:47 ssh-user-config
-rwxrwxrwx1 john Users  223232 Nov  6 02:47 ssh.exe
-rwxrwxrwx1 john Users   18944 Sep 21 06:32 ssp.exe
-rwxrwxrwx1 john Users   87552 Aug 26  2002 states.exe
-rwxrwxrwx1 john Users   23552 Sep 21 06:32 strace.exe
That could be a problem perhaps? Should the 'Users' group contain 'sshd' 
or is access for sshd to the /bin executables handled somehow else?

Ok, looks like all your mounts are system mounts, unless you simply don't
have the permission to read the registry keys for the SYSTEM user...
 

That seems strange. My home computer has a couple of mounts when I run 
that command, but this system has none. However, it works fine locally 
(compiling, listing files, /cygdrive/c, etc). I haven't ever tinkered 
with the mounts, so I wonder how that comes to be... Couldn't be related 
to mingw/msys could it?

John

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


Re: 1.5.5: sshd problem

2003-11-13 Thread Igor Pechtchanski
On Fri, 14 Nov 2003, John Pye wrote:

> Well... This is looking weird now :-)
> In response to your suggestions, Igor...
>
> >Access is denied.
> >
> >At a guess, your sshd doesn't have permissions to execute bash.
> >
> >
> > $ net helpmsg 5
>
> [EMAIL PROTECTED] ~
> $ net helpmsg 5
>
> Access is denied.
>
> [EMAIL PROTECTED] ~
>
> >Please post the output of "ls -ln /bin/bash".
> >
> >
> [EMAIL PROTECTED] ~
> $ ls -ln /bin/bash
> -rwxrwxrwx1 1000 545527360 Oct 20 22:12 /bin/bash
>
> [EMAIL PROTECTED] ~
> $
>
> Why are those numbers like that? 1000 and 545? Shouldn't they read my
> username?

No, the "-n" option to ls forces it to output numeric values instead.

> Some of /etc/passwd:
>
> SYSTEM:*:18:544:,S-1-5-18::
> Administrators:*:544:544:,S-1-5-32-544::
> Administrator:unused_by_nt/2000/xp:500:513:U-JOHN\Administrator
> john:unused_by_nt/2000/xp:1000:513:John Pye,U-JOHN\john,S-1-5-2
> sshd:unused_by_nt/2000/xp:1004:513:sshd privsep,U-JOHN\sshd,S-1
>
> Also...
>
> [EMAIL PROTECTED] ~
> $ cat /etc/group
> SYSTEM:S-1-5-18:18:
> None:S-1-5-21-1960408961-1647877149-725345543-513:513:
> Administrators:S-1-5-32-544:544:
> Backup Operators:S-1-5-32-551:551:
> Guests:S-1-5-32-546:546:
> Power Users:S-1-5-32-547:547:
> Replicator:S-1-5-32-552:552:
> Users:S-1-5-32-545:545:
>
> How would /bin/bash have become chmod 777 ?

That's the default mode Windows gives it.  This should work, but somehow
doesn't...  Can sshd get to all the necessary files and directories?  Look
at the permissions on /etc and the files in it, as well as /bin.

> >Also, please post the output of "mount -m" and
> >"/bin/ls -1 /proc/registry/HKEY_USERS/*/Software/Cygnus\ Solutions/Cygwin/mounts\ 
> >v2/".
> >
> [EMAIL PROTECTED] ~
> $ /bin/ls -1 /proc/registry/HKEY_USERS/*/Software/Cygnus\ Solutions/Cygwin/mounts\ 
> v2/
>
> [EMAIL PROTECTED] ~
> $

Ok, looks like all your mounts are system mounts, unless you simply don't
have the permission to read the registry keys for the SYSTEM user...

> Thanks for the suggestions, Igor
> JP

Hmm, try looking for wrong directory permissions, that's my only guess at
this point...  Sorry.
Igor
-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_[EMAIL PROTECTED]
 |,4-  ) )-,_. ,\ (  `'-'   Igor Pechtchanski, Ph.D.
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"I have since come to realize that being between your mentor and his route
to the bathroom is a major career booster."  -- Patrick Naughton

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: 1.5.5: sshd problem

2003-11-13 Thread John Pye
Well... This is looking weird now :-)
In response to your suggestions, Igor...
Access is denied.

At a guess, your sshd doesn't have permissions to execute bash.
 

$ net helpmsg 5
[EMAIL PROTECTED] ~
$ net helpmsg 5
Access is denied.

[EMAIL PROTECTED] ~

Please post the output of "ls -ln /bin/bash".
 

[EMAIL PROTECTED] ~
$ ls -ln /bin/bash
-rwxrwxrwx1 1000 545527360 Oct 20 22:12 /bin/bash
[EMAIL PROTECTED] ~
$
Why are those numbers like that? 1000 and 545? Shouldn't they read my 
username? Some of /etc/passwd:

SYSTEM:*:18:544:,S-1-5-18::
Administrators:*:544:544:,S-1-5-32-544::
Administrator:unused_by_nt/2000/xp:500:513:U-JOHN\Administrator
john:unused_by_nt/2000/xp:1000:513:John Pye,U-JOHN\john,S-1-5-2
sshd:unused_by_nt/2000/xp:1004:513:sshd privsep,U-JOHN\sshd,S-1
Also...

[EMAIL PROTECTED] ~
$ cat /etc/group
SYSTEM:S-1-5-18:18:
None:S-1-5-21-1960408961-1647877149-725345543-513:513:
Administrators:S-1-5-32-544:544:
Backup Operators:S-1-5-32-551:551:
Guests:S-1-5-32-546:546:
Power Users:S-1-5-32-547:547:
Replicator:S-1-5-32-552:552:
Users:S-1-5-32-545:545:
How would /bin/bash have become chmod 777 ?

Also, please post the output of "mount -m" and
"/bin/ls -1 /proc/registry/HKEY_USERS/*/Software/Cygnus\ Solutions/Cygwin/mounts\ v2/".
 

[EMAIL PROTECTED] ~
$ /bin/ls -1 /proc/registry/HKEY_USERS/*/Software/Cygnus\ 
Solutions/Cygwin/mounts\ v2/

[EMAIL PROTECTED] ~
$
Thanks for the suggestions, Igor

JP

--
John Pye
School of Mechanical and Manufacturing Engineering
The University of New South Wales
Sydney  NSW 2052  Australia  
t +61 2 9385 5127  
f +61 2 9663 1222



--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


Re: 1.5.5: sshd problem

2003-11-13 Thread Igor Pechtchanski
On Thu, 13 Nov 2003, John Pye wrote:

> Hi everyone
>
> I'm still having problems with my SSH configuration. I have followed all
> the steps give by Corinna earlier, plus some more, but it hasn't changed
> anything.  Does anyone have any more tips or suggestions?
>
> Perhaps other files which could secretly be snarling up my SSH config,
> other than ~/.ssh/*, /etc/ssh* ? The only thing I can think of is that
> there are two dns entries for my machine, via dyndns.org - could that
> have anything to do with it?
>
> Here are the steps I tried for fixing the problem:
>
> >> - Deinstall the sshd service: cygrunsrv -R sshd
> >> - Edit /etc/passwd and remove the sshd account entry.
> >> - Remove the sshd account: net user sshd /delete
> >> - If you didn't change much in your /etc/ssh_config and /etc/ssdh_config
> >>  files, remove them.
> >
> >
> I deleted all those files, as well as /etc/ssh_host* and ~/.ssh
>
> I ran a complete 'reinstall' of cygwin using the setup.exe program
> (selecting 'reinstall' from the root node)
>
> I restarted my machine
>
> >> - Run ssh-host-config again.
> >> - Run ssh-user-config for your own (and each other used) account.
> >
> >
> I just did this for my own account, as well as for the one other account
> I want to be using for SSH.
>
> >> - Restart the sshd service.
> >
> >
> I still get the error as shown
>
>  [EMAIL PROTECTED] ~
>  $ ssh localhost
>  ssh_exchange_identification: Connection closed by remote host
>
> The verbose output is
>
> $ ssh -vvv localhost
> OpenSSH_3.7.1p2, SSH protocols 1.5/2.0, OpenSSL 0.9.7c 30 Sep 2003
> debug1: Reading configuration data /etc/ssh_config
> debug2: ssh_connect: needpriv 0
> debug1: Connecting to localhost [127.0.0.1] port 22.
> debug1: Connection established.
> debug1: identity file /home/john/.ssh/identity type 0
> debug3: Not a RSA1 key file /home/john/.ssh/id_rsa.
> debug2: key_type_from_name: unknown key type '-BEGIN'
> debug3: key_read: missing keytype
> debug2: key_type_from_name: unknown key type 'Proc-Type:'
> debug3: key_read: missing keytype
> debug2: key_type_from_name: unknown key type 'DEK-Info:'
> debug3: key_read: missing keytype
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug3: key_read: missing whitespace
> debug2: key_type_from_name: unknown key type '-END'
> debug3: key_read: missing keytype
> debug1: identity file /home/john/.ssh/id_rsa type 1
> debug1: identity file /home/john/.ssh/id_dsa type -1
> ssh_exchange_identification: Connection closed by remote host
> debug1: Calling cleanup 0x41bf10(0x0)
>
> I look at /var/log/sshd
>
>13 [main] sshd 2468 proc_subproc: Couldn't duplicate my handle<0x3D4> for pid 
> 2528, Win32 error 5
> 49583 [main] sshd 2468 sync_with_child: child 2528(0x2B4) died before initialization 
> with status code 0x80
> 66055 [main] sshd 2468 sync_with_child: *** child state waiting for longjmp
>
> I try again to log in via SSH... Now the log file is
>
> 13 [main] sshd 2468 proc_subproc: Couldn't duplicate my handle<0x3D4> for pid 
> 2528, Win32 error 5
>  49583 [main] sshd 2468 sync_with_child: child 2528(0x2B4) died before 
> initialization with status code 0x80
>  66055 [main] sshd 2468 sync_with_child: *** child state waiting for longjmp
> 34018725 [main] sshd 2468 sync_with_child: child 2116(0x284) died before 
> initialization with status code 0x80
> 34029578 [main] sshd 2468 sync_with_child: *** child state waiting for longjmp
>
> I try again and it's now
>
> 13 [main] sshd 2468 proc_subproc: Couldn't duplicate my handle<0x3D4> for pid 
> 2528, Win32 error 5
>  49583 [main] sshd 2468 sync_with_child: child 2528(0x2B4) died before 
> initialization with status code 0x80
>  66055 [main] sshd 2468 sync_with_child: *** child state waiting for longjmp
> 34018725 [main] sshd 2468 sync_with_child: child 2116(0x284) died before 
> initialization with status code 0x80
> 34029578 [main] sshd 2468 sync_with_child: *** child state waiting for longjmp
> 94072696 [main] sshd 2468 sync_with_child: child 2544(0x280) died before 
> initialization with status code 0x80
> 94090700 [main] sshd 2468 sync_with_child: *** child state waiting for longjmp
>
> Each time there are two more lines. What's that first line then?

$ net helpmsg 5

Access is denied.

At a guess, your sshd doesn't have permissions to execute bash.

> I delete the sshd.log file, I end the SSHD service, I look at the file
> which has again been created (sshd.log). It's empty. I start the service
> again, and I see it's still empty. The first line appears after I make
> my first login attempt, but it d

Re: 1.5.5: sshd problem

2003-11-13 Thread John Pye
Hi everyone

I'm still having problems with my SSH configuration. I have followed all 
the steps give by Corinna earlier, plus some more, but it hasn't changed 
anything.  Does anyone have any more tips or suggestions?

Perhaps other files which could secretly be snarling up my SSH config, 
other than ~/.ssh/*, /etc/ssh* ? The only thing I can think of is that 
there are two dns entries for my machine, via dyndns.org - could that 
have anything to do with it?

Here are the steps I tried for fixing the problem:

- Deinstall the sshd service: cygrunsrv -R sshd
- Edit /etc/passwd and remove the sshd account entry.
- Remove the sshd account: net user sshd /delete
- If you didn't change much in your /etc/ssh_config and /etc/ssdh_config
 files, remove them.


I deleted all those files, as well as /etc/ssh_host* and ~/.ssh

I ran a complete 'reinstall' of cygwin using the setup.exe program 
(selecting 'reinstall' from the root node)

I restarted my machine

- Run ssh-host-config again.
- Run ssh-user-config for your own (and each other used) account.


I just did this for my own account, as well as for the one other account 
I want to be using for SSH.

- Restart the sshd service.


I still get the error as shown

[EMAIL PROTECTED] ~
$ ssh localhost
ssh_exchange_identification: Connection closed by remote host
The verbose output is

$ ssh -vvv localhost
OpenSSH_3.7.1p2, SSH protocols 1.5/2.0, OpenSSL 0.9.7c 30 Sep 2003
debug1: Reading configuration data /etc/ssh_config
debug2: ssh_connect: needpriv 0
debug1: Connecting to localhost [127.0.0.1] port 22.
debug1: Connection established.
debug1: identity file /home/john/.ssh/identity type 0
debug3: Not a RSA1 key file /home/john/.ssh/id_rsa.
debug2: key_type_from_name: unknown key type '-BEGIN'
debug3: key_read: missing keytype
debug2: key_type_from_name: unknown key type 'Proc-Type:'
debug3: key_read: missing keytype
debug2: key_type_from_name: unknown key type 'DEK-Info:'
debug3: key_read: missing keytype
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug3: key_read: missing whitespace
debug2: key_type_from_name: unknown key type '-END'
debug3: key_read: missing keytype
debug1: identity file /home/john/.ssh/id_rsa type 1
debug1: identity file /home/john/.ssh/id_dsa type -1
ssh_exchange_identification: Connection closed by remote host
debug1: Calling cleanup 0x41bf10(0x0)
I look at /var/log/sshd

  13 [main] sshd 2468 proc_subproc: Couldn't duplicate my handle<0x3D4> 
for pid 2528, Win
2 error 5
49583 [main] sshd 2468 sync_with_child: child 2528(0x2B4) died before 
initialization with
tatus code 0x80
66055 [main] sshd 2468 sync_with_child: *** child state waiting for longjmp

I try again to log in via SSH... Now the log file is

   13 [main] sshd 2468 proc_subproc: Couldn't duplicate my 
handle<0x3D4> for pid 2528, Win32 error 5
49583 [main] sshd 2468 sync_with_child: child 2528(0x2B4) died before 
initialization with status code 0x80
66055 [main] sshd 2468 sync_with_child: *** child state waiting for 
longjmp
34018725 [main] sshd 2468 sync_with_child: child 2116(0x284) died before 
initialization with status code 0x80
34029578 [main] sshd 2468 sync_with_child: *** child state waiting for 
longjmp

I try again and it's now

   13 [main] sshd 2468 proc_subproc: Couldn't duplicate my 
handle<0x3D4> for pid 2528, Win32 error 5
49583 [main] sshd 2468 sync_with_child: child 2528(0x2B4) died before 
initialization with status code 0x80
66055 [main] sshd 2468 sync_with_child: *** child state waiting for 
longjmp
34018725 [main] sshd 2468 sync_with_child: child 2116(0x284) died before 
initialization with status code 0x80
34029578 [main] sshd 2468 sync_with_child: *** child state waiting for 
longjmp
94072696 [main] sshd 2468 sync_with_child: child 2544(0x280) died before 
initialization with status code 0x80
94090700 [main] sshd 2468 sync_with_child: *** child state waiting for 
longjmp

Each time there are two more lines. What's that first line then? I 
delete the sshd.log file, I end the SSHD service, I look at the file 
which has again been created (sshd.log). It's empty. I start the service 
again, and I see it's still empty. The first line appears after I make 
my first login attempt, but it doesn't appear on subsequent login attempts.

I am going to have to do a total remove-and-reinstall of cygwin?

May the merciful hacker who comes to my aid be blessed with infinite 
vanilla milkshakes, or something.

John Pye





--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://c

Re: 1.5.5: sshd problem

2003-11-10 Thread Corinna Vinschen
On Mon, Nov 10, 2003 at 07:38:46PM +1100, John Pye wrote:
> Hi everyone
> 
> I have a strange problem with sshd and can't seem to find any tips in 
> the mailing list archives, ssh docs, or on the web.
> 
> I have been getting the following error, "ssh_exchange_identification: 
> Connection closed by remote host" - see (1) below

Any interesting syslog entry from sshd?  Any error message in
/var/log/sshd.log?

If not, try this:

- Deinstall the sshd service: cygrunsrv -R sshd
- Edit /etc/passwd and remove the sshd account entry.
- Remove the sshd account: net user sshd /delete
- If you didn't change much in your /etc/ssh_config and /etc/ssdh_config
  files, remove them.
- Run ssh-host-config again.
- Run ssh-user-config for your own (and each other used) account.
- Restart the sshd service.

Corinna

-- 
Corinna Vinschen  Please, send mails regarding Cygwin to
Cygwin Developermailto:[EMAIL PROTECTED]
Red Hat, Inc.

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



1.5.5: sshd problem

2003-11-10 Thread John Pye
Hi everyone

I have a strange problem with sshd and can't seem to find any tips in 
the mailing list archives, ssh docs, or on the web.

I have been getting the following error, "ssh_exchange_identification: 
Connection closed by remote host" - see (1) below

When I run a verbose ssh, I get the output shown in (2) below. I have 
attached the cygcheck output below as (3).

This computer was set up just a few weeks ago following a rebuild. I 
downloaded fresh cygwin from the internet as shown in (3). Recently I 
wanted to add an account for a friend, so I did the following:
(a) added a new user account.
(b) from my usual account, ran *mkpasswd -l > /etc/passwd*
(c) from my usual account, ran *mkgroup -l > /etc/group
*(d) added two DNS entries for my (static) IP address using www.dyndns.org

It was at this point that I noticed that ssh wasn't working at all, not 
even from localhost. I tried to reinstall ssh using the cygwin setup. I 
deleted my /etc/ssh* files and my .ssh directory to try to eliminate any 
hangover.

I have read that reverse DNS lookups can cause problems, also that there 
have been recent changes to the ssh config stuff in cygwin (but am not 
an expert on either). Could either of these issues be bugs which are 
causing me problems here?

I had a look for /etc/hosts.allow and /etc/hosts.deny files under 
cygwin, and these files don't exist.

Any suggestions mightily appreciated!

John Pye

 1 ---

[EMAIL PROTECTED] ~
$ ssh-host-config
There are still ssh processes running. Please shut them down first.

[EMAIL PROTECTED] ~
$ cygrunsrv -E sshd
[EMAIL PROTECTED] ~
$ ssh-host-config
Overwrite existing /etc/ssh_config file? (yes/no) yes
Generating /etc/ssh_config file
Overwrite existing /etc/sshd_config file? (yes/no) yes
Privilege separation is set to yes by default since OpenSSH 3.3.
However, this requires a non-privileged account called 'sshd'.
For more info on privilege separation read 
/usr/share/doc/openssh/README.privsep.

Should privilege separation be used? (yes/no) yes
Generating /etc/sshd_config file
Host configuration finished. Have fun!

[EMAIL PROTECTED] ~
$ cygrunsrv -S sshd
[EMAIL PROTECTED] ~
$ ssh localhost
ssh_exchange_identification: Connection closed by remote host
[EMAIL PROTECTED] ~
$ cygcheck -s -r -v > cygcheck.out
-- 2 --

[EMAIL PROTECTED] ~
$ ssh -v -v -v localhost
OpenSSH_3.7.1p2, SSH protocols 1.5/2.0, OpenSSL 0.9.7c 30 Sep 2003
debug1: Reading configuration data /etc/ssh_config
debug2: ssh_connect: needpriv 0
debug1: Connecting to localhost [127.0.0.1] port 22.
debug1: Connection established.
debug1: identity file /home/john/.ssh/identity type -1
debug1: identity file /home/john/.ssh/id_rsa type -1
debug1: identity file /home/john/.ssh/id_dsa type -1
ssh_exchange_identification: Connection closed by remote host
debug1: Calling cleanup 0x41bf10(0x0)
[EMAIL PROTECTED] ~
$ ssh -v -v -v -1 localhost
OpenSSH_3.7.1p2, SSH protocols 1.5/2.0, OpenSSL 0.9.7c 30 Sep 2003
debug1: Reading configuration data /etc/ssh_config
debug2: ssh_connect: needpriv 0
debug1: Connecting to localhost [127.0.0.1] port 22.
debug1: Connection established.
debug1: identity file /home/john/.ssh/identity type -1
ssh_exchange_identification: Connection closed by remote host
debug1: Calling cleanup 0x41bf10(0x0)
[EMAIL PROTECTED] ~
$ ssh -v -v -v -2 localhost
OpenSSH_3.7.1p2, SSH protocols 1.5/2.0, OpenSSL 0.9.7c 30 Sep 2003
debug1: Reading configuration data /etc/ssh_config
debug2: ssh_connect: needpriv 0
debug1: Connecting to localhost [127.0.0.1] port 22.
debug1: Connection established.
debug1: identity file /home/john/.ssh/id_rsa type -1
debug1: identity file /home/john/.ssh/id_dsa type -1
ssh_exchange_identification: Connection closed by remote host
debug1: Calling cleanup 0x41bf10(0x0)
 3 

Cygwin Win95/NT Configuration Diagnostics
Current System Time: Mon Nov 10 18:52:40 2003
Windows 2000 Professional Ver 5.0 Build 2195 Service Pack 4

Path:C:\cygwin\usr\local\bin
   C:\cygwin\bin
   C:\cygwin\bin
   C:\cygwin\usr\X11R6\bin
   c:\WINNT\system32
   c:\WINNT
   c:\WINNT\System32\Wbem
   c:\mysql\bin\
   c:\php
   c:\bin
   c:\Program Files\GnuWin32\bin
   C:\cygwin\bin
   c:\Program Files\Python232
   c:\Program Files\Common Files\Adaptec Shared\System
Output from C:\cygwin\bin\id.exe (nontsec)
UID: 1000(john) GID: 513(None)
513(None)
Output from C:\cygwin\bin\id.exe (ntsec)
UID: 1000(john) GID: 513(None)
513(None)544(Administrators) 
545(Users)

SysDir: C:\WINNT\system32
WinDir: C:\WINNT
HOME = `C:\cygwin\home\john'
MAKE_MODE = `unix'
PWD = `/home/john'
USER = `john'
ALLUSERSPROFILE = `C:\Documents and Settings\All Users'
APPDATA = `C:\Documents and Settings\john\Application Data'
COMMONPROGRAMFILES = `C:\Program Files\Common Files'
COMPUTERNAME = `JOHN'
COMSPEC = `C:\WINNT\system32\cmd.exe'
CVS_RSH = `/bin/ssh'
HOMEDRIVE = `C:'
HOMEPATH = `\Documents and Settings\john'
HOSTNAME = `john'
INFOPATH = 
`/usr/local/info:/usr/info:/usr/share/info:/