Re: posix_getgroups() and effective grooup id's

From: Date: Wed, 09 Mar 2005 22:10:10 +0000
Subject: Re: posix_getgroups() and effective grooup id's
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-210378@lists.php.net to get a copy of this message
> Hello, > > while I can use posix_getgroups() to get groups additional to the > posix_getgid() value, I don't know which function to use to find out the > groups additional to posix_getegid(). There's no posix_getegroups() > function. You may be stuck with: <?php $uid = posix_getuid(); exec("groups $uid", $output, $error); if ($error) echo "OS Error: $error<br />\n"; echo implode("<br />", $output); ?> You'd want to do more than just echo the output, of course. -- Like Music? http://l-i-e.com/artists.htm

« previous php.general (#210378) next »