I am by no means an email expert.
If you specify the FROM: field,
most email clients will show that from address
rather than the actual sender's address since
most email clients do not print the full email header
by defalut.
If you want to acutaly send email out as that user,
you will have to change to that user's id.
You may experiment running the script with the suid bit set
so that the script runs as and with the permissions of the
owner no matter who invokes it.
Check out the man page on chmod. An example is the
passwd program. It always runs as root no matter what
user invokes it. If I remember correctly, you should
be able to set it like this.
chmod 4755 script
Again, this is just a guess.
Robert
Robert G. Jordan
Unix Sys Admin
Sleepy Hollow, Illinois U.S.A.
FREE Unix Scripts