George George

George George

  • NA
  • 778
  • 0

User privilege issue

Oct 28 2008 9:54 AM

Hello everyone,


My application runs under low privilege account like NetWork Service, but in some specific method I need to have high privilege (e.g. to write to registry or access some local file).

So, I want to change the user privilege of some specific method of a class. Does anyone have any good ideas how to do this in .Net?

I have investigated impersonate technologies and it looks good. But two more issues with impersonate technogies.

http://www.codeproject.com/KB/cs/zetaimpersonator.aspx

- How to manage the password expire issue? (for example, in the current domain, the policy is for every 6 months, password must be changed);

- Is it possible to impersonate from a high privilege to a low privilege user without providing password? My concern is to hardcode password in source code.


thanks in advance,
George


Answers (6)