apache2 - Which one of security technique use for Apache and PHP? -


I always run Apache default mpm-prefork and PHP as dso (mod_php). I am going to create a new LAMP server for myself and some friends and I would like to use the most effective security method.

I decided for Apache 2 (although I know that NGX should be a good choice for securities) and use instead of traditional prefork mpm-itk my vision is that every website has a unique user's So far everything is fine. For PHP I do not want to use DSO, I want to set up FastCGI (PHP-FPM).

But I do not know whether it will be compatible with each other or not. For example, user danil (/ home / daniel / www / ...) will have a web presentation that runs under it and the PHP scrip will also run under:

  & lt; VirtualHost *: 80 & gt; SuexecUserGroup daniel daniel servername example.com documentRoot / home / daniel / www PHP_Fix_Pathinfo_Enable 1 & lt; Directory / home / daniel / www & gt; Option + Coordinate + ExecCGI AllowOverride All AddHandler FCGID-Script .php FCGIWrapper / var / www / daniel / php5-wrap .php Decline, Allow All Allow From & lt; / Directory & gt; & Lt; / VirtualHost & gt; & Lt; IfModule mpm_itk_module & gt; AssignUserId Daniel Daniel & lt; / IfModule & gt;  

If this is a good solution, then I'm a bit disappointed if it works together.

Thanks in advance.

Daniel

I found an interesting article on that topic.


Comments