Viktors Rotanovs home

Lighttpd initgroups()

While converting my website to lighttpd, I noticed that php processes launched by adaptive spawning can’t access certain files anymore. Small investigation has shown that the problem was caused by user httpd not joining groups specified in /etc/groups. Adding initgroups() call before calling setuid() helped.

lighttpd initgroups patch

Please let me know if you’ve experienced the same problem with spawn-fcgi program.

blog comments powered by Disqus
Fork me on GitHub