in reply to CGI: A Tale of Two Usernames

If you want apache to run as a different user , there is an option in httpd.conf
User <username>
Group <groupname>
. Also read the documentation carefully about the security implications when using sudo.