Hello,
I have PHP running as the user who owns the docroot, but is it possible to set the GID too? A static GID (nogroup) would be okay. I ask, because I thought of the following security concept:
LiteSpeed runs as user www-data, group www-data
all docroots (and files / dirs in there) are owned by user XYZ, group www-data and have mode 0750.
So, the webserver is able to read the files he should serve, while the user and his scripts are able to read and write in the docroot. Now I have a problem - when PHP runs as user XYZ, group www-data, a malicious PHP-script could still read (but not write) other users docroots (because I can't use chroot). Running PHP-scripts as group nogroup would fix this problem.
Regards,
Philipp
I have PHP running as the user who owns the docroot, but is it possible to set the GID too? A static GID (nogroup) would be okay. I ask, because I thought of the following security concept:
LiteSpeed runs as user www-data, group www-data
all docroots (and files / dirs in there) are owned by user XYZ, group www-data and have mode 0750.
So, the webserver is able to read the files he should serve, while the user and his scripts are able to read and write in the docroot. Now I have a problem - when PHP runs as user XYZ, group www-data, a malicious PHP-script could still read (but not write) other users docroots (because I can't use chroot). Running PHP-scripts as group nogroup would fix this problem.
Regards,
Philipp