Impersonation to get user HKEY_CURRENT_USER does not work?

后端 未结 4 1431
甜味超标
甜味超标 2021-01-23 18:20

I am attempting to Impersonate an administrator account from a LocalSystem Service in order to get data from administrators HKEY CURRENT USER registry - in order to impersonate

4条回答
  •  温柔的废话
    2021-01-23 18:59

    Everything I've read on the subject seems to indicate that impersonation should get you access to the HKEY_CurrentUser for the impersonated account. However, it could be a quirk in the .NET Registry implementation.

    This is just a hunch, and an untested one at that, but have you considered using Registry.Users instead of Registry.CurrentUser?

    You'll need to find the SID for the Administrator account, but you should be able to deduce that using Regedit

提交回复
热议问题