First of all sorry for my English, I am German. I am using Debian with apache2 and php5. The server is just for testing and in my local network, so I’ve got no secure-problems. My Question is:
How to give PHP/the PHP-User root-rights?
For example: I want my .php files in /var/www/ to do file_put_contents() for every file on my server, exec() any command (with root-rights),... when I call them in my browser.
I’ve tried a lot of things, for example I put www-data in the root-group or to change the Apache-User in /etc/apache2/envvars, but nothing worked or I got Errors.
I’ve heard about a httpd.conf but I can’t find this file.
Please help me!
/etc/sudoers
file, some examples here stackoverflow.com/questions/3173201/sudo-in-php-exec – rjdown