Re: Permissions on server

From: Date: Tue, 08 Jul 2003 13:53:13 +0000
Subject: Re: Permissions on server
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-154361@lists.php.net to get a copy of this message
On Tue, 2003-07-08 at 07:21, Steve Jackson wrote: > If I set permissions of my server root to chmod 777 that's a security > risk right? > How do I set my server to allow me to write a file to my web root from > another directory using PHP? Or is it a Unix problem? > > I have a generator file writes a string to a text file and then renames > the text file as a PHP file however it occurred to me while I was doing > this that chmod 777 the root might not be a good idea. > > Anyone have a simple fix or idea for this? Change the ownership on the directory to whichever user apache is running as (this is the User directive in your httpd.conf file). Then you can restrict the permissions on that directory. You could probably make it 600 if you want. Brad

« previous php.general (#154361) next »