Re: PHP Execute as User ???
| From: | Richard Lynch | Date: | Wed, 01 Aug 2001 07:42:56 +0000 |
| Subject: | Re: PHP Execute as User ??? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-60598@lists.php.net to get a copy of this message | ||
> I have php files which run on various VirtualHost's and there is suexec on
> those VirtualHosts, however, when I look at the user/group which PHP runs
> under it always seems to be the main web user (nobody, www, or whatever we
> set it to). Is there any way for PHP to be able to execute as the
> User/Group of the VirtualHost?
>
> Please forgive me if this subject has been explained elsewhere, I did a
> search and it revealed nothing.
Only if you execute PHP as a "CGI" with suExec.
PHP as a Module is a part of Apache, and has its same User/Group.
Apache 2.0 will (allegedly) allow mod_php to run as different user in
different hosts.
Not sure how to set up suExec, but suExec + PHP-CGI *can* be made to work
and run PHP as any user you choose. My ISP did it to me.
--
WARNING richard@zend.com address is an endangered species -- Use
ceo@l-i-e.com
Wanna help me out? Like Music? Buy a CD: http://l-i-e.com/artists.htm
Volunteer a little time: http://chatmusic.com/volunteer.htm