DHD-Chris
07-09-2009, 06:30 PM
I have created a script that I want to output vzlist, I have the script and I have made a PHP command to execute the script however I need to allow the script more permission to run under the apache user, how could I do this?
adminpaul
07-10-2009, 01:36 AM
Normally you need to give 755 permission for the script. But in some case, if the commands used in that script need "root" ownership, you need to set setuid for that command. But be careful while setting setuid. It will cause security issues.
DHD-Chris
07-10-2009, 05:15 AM
how would I go about elevating the commands for example using higher level permissions that would usually be run under root?
alons
07-10-2009, 05:52 AM
I am not getting the purpose.
Is it that you want to allow other APACHE user(s) to use a file.
Then CHMOD it to 0777.
OR
If you want to use others file, well its not possible unless you have root permissions or your user account is the root account.
You will have to ask your root account to grant permissions for the same.
DHD-Chris
07-10-2009, 06:08 AM
I want php to be able to execute a script but the script needs to be able to have higher access to the OS for example be able to execute vzctl or ping.