Try enabling NTLM Security (and Basic Authentication if you have Netscape users) for the directory and disabling anonymous access. Then the user will be prompted for their NT username and password and your script will run with those rights.
Note that this is not a cross platform solution, but it is the easiest.
Dave