Jump to content
WebFlake
  • 0

How to disable these php functions


Kabouterplob

Question

I need to disable these: exec, system, pcntl_exec, popen, proc_open, shell_exec

I have my own dedicated server, so I have root access, access to the php.ini file etc, but Im not sure which files I have to go to for each thing.

and what I have to look for for each function.

 

If anybody would be willing to help, i'd really appreciate it.

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0

In php.ini find disable_functions and set new list as follows:

disable_functions =exec,system,pcntl_exec,popen,proc_open,shell_exec

And disable this two also : 

allow_url_fopen=Off
allow_url_include=Off

Just for security reasons.

After you do that restart httpd.

service httpd restart

Or if you are using Debian/Ubuntu use:

service apache2 restart

 

Edited by Faraonii
  • Upvote 1
Link to comment
Share on other sites

  • 0
7 hours ago, Faraonii said:

In php.ini find disable_functions and set new list as follows:


disable_functions =exec,system,pcntl_exec,popen,proc_open,shell_exec

And disable this two also : 


allow_url_fopen=Off
allow_url_include=Off

Just for security reasons.

After you do that restart httpd.


service httpd restart

Or if you are using Debian/Ubuntu use:


service apache2 restart

 

Thanks :)

  • Upvote 1
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...