disable_functions in php.ini doesn't seem to work

Discussion in 'General' started by msp, Oct 13, 2015.

  1. msp

    msp Member

    Maybe I have the wrong syntax but when I update /etc/php5/cli/php.ini to add
    disable_functions = mail
    this does not have the effect of disabling the ability of a script to send email from the server.
    I also tried entering this directive into ISPConfig site options under "Custom php.ini settings", but this doesn't work for the site in question.
    Any ideas?
    Ideally I want to completely remove the ability for rogue scripts to send email from the server.
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    The php.ini file that you updated is for shell scripts only, so disabling the mail function there makes not much sense. I guess you mix up cli with cgi, the php.ini for the cgi anf fcgi modes is /etc/php5/cgi/php.ini. Modification in the cli (commandline) php.ini will just cause the ispconfig server cronjob to fail and has no influence on website scripts.

    Maybe you used a wrong php mode, the php mode has to be fastcgi or fpm as described in the manual.
     

Share This Page