Spawn a process that runs under an Impersonated user




We are trying to kick off an executable from an page. We have
followed article 889251 "How to spawn a process that runs under the context
of the impersonated user in Microsoft ASP.NET pages" (including adding the
impersonated user to the "Replace a process level token").

When we run the code still get a 1314 error "ERROR_PRIVILEGE_NOT_HELD".
What permission is this referring to? Our impersonated user is a domain user
with sign on rights to the box.

We appreciate that spawning a thread from an ASP.NET page undesirable, but
this is what we are stuck with due to other circumstances.

Grant Holdom.

Bruce Barker

either the create primary token is failing, or you did not give Replace
Process rights to the users login.

-- bruce (

Wei-Dong XU [MS]

Hi Grant,

Thanks for posting at the newsgroup!

Based on my test, the sample code from the kb article could work as
expected. So currently for assisting you on this issue, could you be so
kind to tell me more information about your environment, for example which
operating system are you using(service pack has applied or not),
runtime version( 2.0/1.1) ? We will perform the further research then.
Thanks in advance!

Best Regards,
Wei-Dong XU
Microsoft Support

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question