hide php.ini and php.cgi from the people

hide php.ini and php.cgi from the people

Posted by: dv1000
Posted on: 2008-01-23 12:32:00

How I can hide php.ini and php.cgi from the people? because any people can see my configuration.
I tried it putting commands on .httaccess but not working.


Any suggestions?

Edited by dv1000 on 01/23/08 01:08 PM (server time).

Re: hide php.ini and php.cgi from the people

Posted by: askapache
Posted on: 2008-01-23 19:51:00

If your php.cgi and php.ini are in /home/user/domain.com/cgi-bin/ add this to your /home/user/domain.com/cgi-bin/.htaccess

Options +ExecCGI -Indexes +FollowSymLinks -Includes

<FilesMatch "^php.(ini|cgi)$">
Order Deny,Allow
Deny from All
Allow from env=REDIRECT_STATUS
</FilesMatch>


_____

 _  _|  _  _  _  _|_  _
(_|_|<(_||_)(_|(_| |(/_
|


Thank you for your response, has helped me a lot!
Gracias por tu respuesta me ha ayudado mucho!

Certainly I have enjoyed very much your web page, it makes things very interesting! I do not known

Edited by dv1000 on 01/25/08 02:58 AM (server time).