Zend certified PHP/Magento developer

how to demote user privileges to run a script

I would like to run a script, started by snmptrapd, as a regular user.
Looks like the traphandle directive in /etc/snmp/snmptrapd.conf runs the indicated program as a privileged user (root:root).
The traphandle program is a bash script. Is there any way to drop privileges from root to a regular user, at beginning of execution/script ?
The traphandle program that I intend to run as regular user create files that would better if they were created as regular user.
Of course I can issued chmod/chown all over in the script for each file created, but I was wondering if there is a more elegant solution.

best regards,