Re: [gamin] socket credentials patch for NetBSD



Daniel Veillard wrote:
On Thu, Sep 01, 2005 at 12:54:18PM -0400, Johnny C. Lam wrote:


Please correct me if I'm wrong, but it looked like the extent of the authentication that gamin does is that the server and the client mutually check that the process at the other end of the socket shares the same UID as itself. Since we can easily get this information on all of Linux, FreeBSD, NetBSD, OpenBSD, and BSD/OS, it's easy to make gamin work on all of those platforms with the same "strength of authentication".


 The problem is to get it in a trusted way. Your initial patch was basically
believing informations sent from the client, and to me you can't trust those.

No, the initial patch and the next one got the actual credentials that gamin uses (UID) in the same way. Actually, it's gotten in the same way across all the platforms -- from the kernel. The only difference is that the initial patch pulled the PID info from the socket, but that's not really credential information -- it's actually debugging information.

  We disagree on the importance of the debugging information.

We're not disagreeing. In fact, I agree with you! I was just asking whether my understanding of how the PID information was used by gamin was correct, which you confirmed.

  again non-conditionalized platform changes, you change data for all OSes
You may submit later a second patch explaining why this would need to be
changed, but I don't want to see this as part of a "make gamin work on NetBSD"
patch.

Okay, that's fine. This is your project, and I'll comply with your rules. I do have access to all three platforms under discussion (NetBSD, FreeBSD, and Linux), and I did test on all three before submitting my patches. However, to honor your wishes, I'll submit two separate patches: one with "#ifdef NetBSD" that adds only support for NetBSD, and another that consolidates the code for all three platforms so that differences are minimal.

	Cheers,

	-- Johnny Lam <jlam NetBSD org>



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]