in reply to changing user mid-script

The ability to do this easily is one of the cool things about perl!

I described the way that I like to do this trick in Re: File Protections. As others have mentioned, you may need to worry about the security implications. In particular, your system administrator may take a dim view of suid programs. Check your local security policy to make sure that you don't get in trouble. You wouldn't want to get fired because you chose a computer language that was too powerful!

It should work perfectly the first time! - toma