سؤال

I have 1 windows service running on local machine under local system account. This service is written in C#. I am using impersonation in code to run service code under admin user context. If I set logon of service to Administrator account and remove impersonation code from service, then still code will be run under admin user context ? I mean whether these two approach are same or there is something different?

هل كانت مفيدة؟

المحلول

The 2 approaches are absolutely the same. You could safely remove any impersonation code from your service and configure it to run under Administrator account in the management console.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top