PHP WhoAmI; whoami www-data using exec()

PHP scripts typically runs under the www-data user. Verify this using the following code:

$command = 'whoami';
echo exec($command) . "\n";
Did this help you? Please let me know with a comment. Thank you
Posted .

Comments (RSS)

Leave a comment