Subject: Re: kauth and sleeping [Re: CVS commit: src/sys/kern]
To: Andrew Doran <>
From: Elad Efrat <>
List: tech-kern
Date: 07/24/2006 15:25:49
Andrew Doran wrote:

>                 proclist_lock_read();
>                 PROCLIST_FOREACH(p, &allproc) {
>                         if (kauth_authorize_process(l->l_cred,
>                             KAUTH_PROCESS_CANSEE, p, NULL, NULL, NULL) != 0)
>                                 continue;
> 			[...]
> 		}
> 		proclist_unlock_read();
> I don't fully understand the implication of kauth in this setting, other
> than providing permission to touch another process. In what situations might
> it want to sleep?

the locking is not something kauth(9) added; it was there before to
prevent modification of allproc while traversing it. i admit i'm not
sure how to deal with this one. :)


Elad Efrat