Subject: Re: CVS commit: [elad-kernelauth] src/sys
To: Elad Efrat <elad@NetBSD.org>
From: Jason Thorpe <thorpej@shagadelic.org>
List: source-changes
Date: 03/08/2006 09:10:35
On Mar 8, 2006, at 8:12 AM, Elad Efrat wrote:

> No. It is not used often. In fact, in the *elad-kernelauth* branch
> it is not used *at all*.

...which is the way it ought to be.  Now that I think about it, all  
of the suser() call sites would have to change anyway, because p- 
 >p_ucred is now p->p_cred.  Note, Darwin provides a kauth_cred_get 
(), which returns the credentials of the current thread -- we should  
also provide this... our implementation can simply be:

kauth_cred_t
kauth_cred_get(void)
{

	return (curproc->p_cred);
}

(Darwin's is more complicated, because the Darwin kernel supports  
binding different credentials to each thread in a process...)

-- thorpej