为什么 CreateProcessAsUser 在 Vista/Windows 7 上需要交互式窗口站?
我必须深入研究这个问题,因为在 Windows 2003/XP 上运行良好的代码在 Windows 7 上却无法正常运行。使用 CreateProcessAsUser 启动的应用程序失败,错误代码为 0xc0000142。我的旧代码与 MSDN 上提供的代码之间的区别 Starting C++ 中的交互式客户端进程 是我没有设置 Window Station 和桌面的权限。我已经根据示例更新了我的代码,但我非常想了解较新的 Windows 中的哪些更改使得交互式 Window station 中的运行进程成为必需?
I had to delve into this because the code that worked fine on Windows 2003/XP doesn't on Windows 7. Application launched by the use of CreateProcessAsUser fails with 0xc0000142 error code. The difference between my old code and one available from MSDN at Starting an Interactive Client Process in C++ is that I didn't set up privileges and to Window Station and desktop. I've updated my code according to the example, but I would very much like to understand which change in newer Windows made running processes in interactive Window station a requirement?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
至少部分要求源于在与服务不同的会话中运行交互式进程的更改。这样做是为了使应用程序无法对特权服务运行“粉碎”式攻击。更多信息请访问此处。
At least part of the requirements derive from the change to run interactive processes in a different session from services. This was done so that applications could not run 'shatter' style attacks against privileged services. More information is available here.