R rzRDJ New member Joined Jul 11, 2012 Messages 3 Jul 11, 2012 #1 Hello. I have some packages which PHP has been switched off. However the user still can execute PHP scripts even with PHP Off. I test this by making a test account with CGI & PHP switched off and i could use PHP scripts too. How can i fix this?
Hello. I have some packages which PHP has been switched off. However the user still can execute PHP scripts even with PHP Off. I test this by making a test account with CGI & PHP switched off and i could use PHP scripts too. How can i fix this?
zEitEr Super Moderator Joined Apr 11, 2005 Messages 15,831 Location www.poralix.com Jul 12, 2012 #2 Hello, If you use suPHP (PHP-CGI via mod_suphp), then it caused mostly by the fact that PHP is globally enabled in /etc/httpd/conf/extra/httpd-suphp.conf Code: suPHP_Engine on And in some cases (I don't remember details) if your suPHP module is compiled as Code: --with-setid-mode=paranoid then you can not redefine it, it means that if even try to disable PHp for an user, or a domain, you won't be able to do that. So you need 1. Open /etc/httpd/conf/extra/httpd-suphp.conf in editor via SSh. Here change line Code: suPHP_Engine on into Code: #suPHP_Engine on (this is very important) 2. Protect /etc/httpd/conf/extra/httpd-suphp.conf from being overwritten, Code: chattr +i /etc/httpd/conf/extra/httpd-suphp.conf 3. restart apache Code: service httpd restart 4. check it in your browser.
Hello, If you use suPHP (PHP-CGI via mod_suphp), then it caused mostly by the fact that PHP is globally enabled in /etc/httpd/conf/extra/httpd-suphp.conf Code: suPHP_Engine on And in some cases (I don't remember details) if your suPHP module is compiled as Code: --with-setid-mode=paranoid then you can not redefine it, it means that if even try to disable PHp for an user, or a domain, you won't be able to do that. So you need 1. Open /etc/httpd/conf/extra/httpd-suphp.conf in editor via SSh. Here change line Code: suPHP_Engine on into Code: #suPHP_Engine on (this is very important) 2. Protect /etc/httpd/conf/extra/httpd-suphp.conf from being overwritten, Code: chattr +i /etc/httpd/conf/extra/httpd-suphp.conf 3. restart apache Code: service httpd restart 4. check it in your browser.