Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 11 Apr 2005 09:07:49 +0900
From:      Jacques Vidrine <nectar@FreeBSD.org>
To:        des@des.no (=?ISO-8859-1?Q?Dag-Erling_Sm=F8rgrav?=)
Cc:        cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/libexec/rexecd rexecd.c
Message-ID:  <d48970b320355d1b5337567f0aa4e1e7@FreeBSD.org>
In-Reply-To: <8664yx2wwd.fsf@xps.des.no>
References:  <200504081119.j38BJoZf036618@repoman.freebsd.org> <6715759dfc36ac3b48dc3efe8cfcd07d@FreeBSD.org> <8664yx2wwd.fsf@xps.des.no>

next in thread | previous in thread | raw e-mail | index | archive | help

On Apr 8, 2005, at 10:58 PM, Dag-Erling Sm=F8rgrav wrote:

> Jacques Vidrine <nectar@FreeBSD.org> writes:
>> Thanks for fixing, DES.   Only, you have re-introduced some of the
>> bugs.  You need to use getpwnam_r or copy the contents of the =
returned
>> struct passwd before continuing.
>
> Hmm, actually it should be sufficient to re-getpwnam() after the call
> to pam_setcred() in the child.  There's nothing else that has the
> potential to screw up pwd.

Yes, it would be sufficient, but wasteful (^_^).  But, I'm not too=20
concerned.  (BTW, getpwnam is just a wrapper for getpwnam_r).

Cheers,
--=20
Jacques A Vidrine / NTT/Verio
nectar@celabo.org / jvidrine@verio.net / nectar@freebsd.org



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?d48970b320355d1b5337567f0aa4e1e7>