开发者

Restricting Non-Admin Users From Stopping a Process in Task Manager C++

开发者_运维问答

In C++ and using the WinAPI; I am trying to start a process with admin rights using CreateProcessWithLogonW(), from within another application that does not have admin rights, but the new process can be stopped from within task manager by the non-admin user.

Any help would be greatly appreciated.

Chaman


As I can remember, Create admin process from non-admin process is very hard in windows. The simplest option to start admin process is to build that process exe with admin privilege, and use ::ShellExecute.

In vista and win7, posting message to admin process from non-admin process is not allowed. you may need to create your own message queue to send msg to admin process in order to kill it. (boost message queue can be one option). Or you can use some other sync techniques to kill it.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜