Results 1 to 1 of 1
Hi everyone,
I have created a webapp and now want to send emails at midnight using a cronjob.
When i go directly to the (PHP) script in my browser everthing ...
- 05-06-2011 #1Just Joined!
- Join Date
- May 2011
- Posts
- 1
Cron + Suhosin
Hi everyone,
I have created a webapp and now want to send emails at midnight using a cronjob.
When i go directly to the (PHP) script in my browser everthing works correctly, but when using cron to run the script i get these errors:
I tried setting suhosin.executor.disable_eval to Off in my php.ini, but it did not solve it.Code:ALERT - use of eval is forbidden by configuration (attacker 'REMOTE_ADDR not set', file '***', line 118) PHP Fatal error: SUHOSIN - Use of eval is forbidden by configuration in ***(118) : eval()'d code on line 118
This is the directory config the app is running in:
But this apperently does not have any effect on cron.Code:<Directory /***/httpdocs > php_admin_value suhosin.executor.disable_eval 0 php_admin_value suhosin.mail.protect 0 </Directory>
Any ideas on how to solev this? Can i disable suhosin for cron?
I searched the web but have not found a solution yet.
EDIT:
Found out it also loaded /etc/php.d/suhosin.ini.
changed the two lines mail.protect and disable_eval, and now it works correct. But this is system-wide and i prefer only to have it for cron. Is this possible?Code:; Enable suhosin extension module extension=suhosin.so [suhosin] suhosin.mail.protect = 2 suhosin.memory_limit = 32M suhosin.executor.disable_eval = 1 suhosin.cookie.checkraddr = 1 suhosin.cookie.cryptraddr = 1 suhosin.multiheader = 1 suhosin.session.checkraddr = 1 suhosin.session.cryptraddr = 1 suhosin.upload.disallow_elf = 1
Last edited by klompie; 05-06-2011 at 02:25 PM.


Reply With Quote