PHP WhoAmI; whoami www-data using exec()

Content

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

$command = 'whoami'; echo exec($command) . "\n";