This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: rsh with command hangs, rlogin works

Lars Björnfot wrote:
$ rsh localhost ls HANGS for any command
Still unsolved but: I noted a SIGSEGV message in the syslog which explains why it hangs.

Jun 2 23:39:12 baloo kernel: in.rshd[3308]: segfault at 00000003 rip 0022E4E5 rsp 0022E454 error 4

I downloaded the inetutil sources, added some syslog lines and pinpointed the problem to the rresvport() call:

s = rresvport(&lport);

rshd crashes on the first attempt, when lport=1023.
You and I are working on similar problems lately. I spent some time installing syslogd hoping to get more info about this much like you. I got syslogd installed and running - but nothing ever logged anything to /var/log/messages 'cept start and stop messages. IOW, with syslogd running, rsh <machine> put nothing into /var/log/messages. Once syslogd is up and running, how do you switch such services to log to there?

Regarding in.rshd dying, I have seen in.rshd.stackdump's around.

BTW Lars, how did you get rsh passwordless login configured via .rhosts? I had done this successfully in the past but I remember having to change the permissions on my home directory by opening them up a bit (I believe I needed to add Everybody Read access but I forget - it was a while ago). Note that we use networked home directories from another server that is mounted to essentially /home (actually /us). So while I have what I think is a validly formated ~/.rhosts it's really //<server>/<share>/adefaria/.rhosts.

Another thing I noticed in my digging around last night - In order to avoid the complications of having everybody set up their .rhosts properly and play with permissions, in the past on our old 2000 server I simply removed the password field in /etc/passwd. This also allows passwordless logins without having to setup and maintain ~/.rhosts files. Insecure - I know - but it worked.

Now we are on a 2003 server and it appears security has been tightened somewhat. Now if I have a user who's password field has been removed and I try an rsh I get "Switch user <username> failed"! If I put something the password field I get prompted for a password and rsh works. However rsh <machine> <command> still fails. It seems clear to me that this is in or close to the code that is supposed to echo a message "Permission denied" or whatever error is supposed to be issued when one tries an rsh with a command but their .rhosts is not set up properly...

-- Unsubscribe info: Problem reports: Documentation: FAQ:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]