简体   繁体   中英

How to allow SYNCHRONIZE access right to all processes

I have a windows service which I want other processes (of different users, some with low priviliges) to wait on its handle. Meaning, other processes WaitForSingleObject() on the windows service process HANDLE.

In order that other processes will be able to wait on the service process they need to OpenProcess() with SYNCHRONIZE access right, but how can I be sure that other processes with lower priviliges can aquire the SYNCHRONIZE access right???

Can I force my process (windows service) to allow SYNCHRONIZE to everyone?

Here's how I solved it.

Using SetSecurityInfo didn't work because the user itself doesn't have the privileges to access SYSTEM processes.

The following kb: http://support.microsoft.com/kb/131065 explains how to add to the user SE_DEBUG_NAME privilege which gives the user the ability to open any process.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM