WindowsImpersonationContext

S

Sorin Sandu

This code is valid only for current page ?
WindowsIdentity newId = new WindowsIdentity(dupeTokenHandle);
WindowsImpersonationContext impersonatedUser = newId.Impersonate();
After I impersonate current user and Response.Redirect to another page there
WindowsIdentity is changed to user before Impersonate.
Is it normal ?
How can I do to maintain Impersonation to all my pages ?
 
S

Sorin Sandu

I am trying to impersonate the windows account in code like in
http://support.microsoft.com/default.aspx?scid=kb;en-us;306158 and then all
aspx pages to run on this new account (ACL is only for this account).
But after the first page when I impersonate it and I redirect to another
page the account reverse to original.
How can I do to maintain impersonation but in code not in web.config.
 

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

Top