Can I give the default user that runs Perl scripts from cgi-bin different permisions?
The default user that Perl scripts run from browsers is www-data. My scripts need permission to read/write/delete files in other directories. All these directories are created within the /home directory (all recursive, i.e. /home/Daniel/ftp/files) and these directories and files are created at run time by different users.
Is there a way to give www-data broader authority? Should I change the default user that runs Perl scripts (again from browsers) even though that sounds dangerous?
Thanks
1 Answer
Should anyone come across this I found my answer.
The default user (for Perl/CGI commands) is located in /etc/apache2/envvars
I commented the line out
#export APACHE_RUN_USER=www-dataReplaced it with the user I wanted
export APACHE_RUN_USER=franklinthen after saving the file I restarted the service
sudo service apache2 restartI should note that even though I am sure it would have been the wrong thing to do, trying to make the default user 'root' produced an error.