What solutions do I have to enforce memory limit on PHP server?
- by Zulgrib
I would like to enforce memory limit on a folder basis (and have it applied on subfolders) but I don't want the user able to change the memory limit.
I know I can disable ini_set and I know I can enforce a hard limit or deny ini_set with Suhosin.
With the first one, I doubt it will block changing it from the user.ini file, for the second, the user may still be able to change it to the hard limit I enforce with Suhosin.
In both cases, I would prefer to not entierly block ini_set because it may have a legit use for other settings.
In case it is important, I'm using PHP version 5.4.4 with nginx (PHP in FPM mode)