C
CBran
Hi, I've written an ASP.NET web service which impersonates a user
designated by the end user, then calls into another .NET assembly
to copy a file from a network share to a local drive. The assembly
throws the exception "Could not find file [unc path]." I added
code to determine the current identity as follows:
WindowsIdentity.GetCurrent().Name
This code returns [Domain name]\ASPNET, which tells me the code is
not running under the impersonated account, but the ASPNET account.
I even tried adding code to impersonate the same account within the
assembly in question, but the results are the same - the code insists
on running under the ASPNET account.
I can't seem to find anyone else having similar issues, but then I
cant't find documentation that indicates I should be able to do this
either.
This is on a Windows Server 2003 machine.
Can anyone confirm that an assembly called from an ASP.NET application
using impersonation will also run using the impersonated account?
I'm convinced it's a configuration issue, but can't seem to find a fix.
Thanks,
Chris
designated by the end user, then calls into another .NET assembly
to copy a file from a network share to a local drive. The assembly
throws the exception "Could not find file [unc path]." I added
code to determine the current identity as follows:
WindowsIdentity.GetCurrent().Name
This code returns [Domain name]\ASPNET, which tells me the code is
not running under the impersonated account, but the ASPNET account.
I even tried adding code to impersonate the same account within the
assembly in question, but the results are the same - the code insists
on running under the ASPNET account.
I can't seem to find anyone else having similar issues, but then I
cant't find documentation that indicates I should be able to do this
either.
This is on a Windows Server 2003 machine.
Can anyone confirm that an assembly called from an ASP.NET application
using impersonation will also run using the impersonated account?
I'm convinced it's a configuration issue, but can't seem to find a fix.
Thanks,
Chris