cvs commit: src/kerberos5/lib/libroken Makefile

Jacques A. Vidrine nectar at
Tue Feb 3 10:24:24 PST 2004

On Tue, Feb 03, 2004 at 11:06:52AM -0600, Jacques A. Vidrine wrote:
> On Tue, Feb 03, 2004 at 06:02:54PM +0100, Andre Oppermann wrote:
> > Hmm...  getlogin might be the problem (from perl man page):
> > 
> >  getlogin
> > 
> >     Implements the C library function of the same name, which on most systems
> >     returns the current login from /etc/utmp, if any. If null, use getpwuid.
> Only that's not correct for most systems :-)
> getlogin(2) returns what was previously passed to setlogin(2) (usually
> by login(1)).  But this could indeed be a part of the problem,
> especially since there is a known bug in ssh involving a missing
> setsid() ...
> Sorry to tease and run, but I have an appointment right *now*.
> Will follow-up when I return.

No, after reviewing my notes, I don't think it is ssh after all.  In
4.x, an ifdef'd out setsid (sshd.c:1402) leaves sshd subprocesses
[1] sharing the same `struct session' as the master sshd process.
However, the login shell or other commands that are executed will get
their own `struct session', so this is just cosmetic.

Still, I'd recommend removing that `getlogin' invocation.

Jacques Vidrine   NTT/Verio SME      FreeBSD UNIX       Heimdal
nectar at jvidrine at nectar at nectar at

[1] The ones that look like `sshd: nectar [priv] (sshd)' and
    `sshd: nectar at notty (sshd)'.

More information about the cvs-all mailing list