开发者

Modifying another user registry

Here is the problem.

I need to run a Windows开发者_高级运维 Service which is being configured through registry. Is there any way to modify another user HKCU without enumeration all the users on the machine?


I have found good way to do it through WMI interface. I've opened connectioin to WMI (see there: http://msdn.microsoft.com/en-us/library/aa390423%28v=vs.85%29.aspx).

Next, I've enumerated all the items in Win32_Account database. Each item in win32_Account have Domain, Name and SID fields.

That's the way to get correct SID.

Unfortunately, I still don't know how to make this operation without enumerating all the users.

Also, this method enumerates all the users in domain (even if they never log on to local machine).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜