获取系统进程的访问令牌
如何从在用户帐户下运行的 C# 控制台应用程序获取系统进程的访问令牌 (实际上我需要管理员访问令牌)
how to get the access token of the System process from a console application in c# which is running under user account
(actually i need admin access token)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
“系统”进程不是一个真正的进程。它只是在环 0 中运行的操作系统代码的逻辑占位符。类似于驱动程序。该抽象很有用,特别是在 Taskmgr.exe 中,它可以提示操作系统本身消耗了哪些系统资源。例如,可以识别烧毁 100% 核心的失控驱动程序的问题。
实际上对系统进程做任何事情都是不可能的。用户模式代码在环 3 上运行,根本无法访问环 0 资源。不存在访问令牌,需要硬件陷阱才能穿越边界。您尝试的任何操作都会产生安全异常。
The "System" process is not a real process. It is merely a logical place holder for the operating system code that runs in ring 0. Like drivers. The abstraction is useful, notably in Taskmgr.exe to give a hint what system resources are consumed by the operating system itself. Trouble with a runaway driver that burns 100% core could be identified for example.
Actually doing anything with the System process is out of the question. User mode code runs at ring 3 and has no access at all to ring 0 resources. No access token exists, it takes a hardware trap to traverse the boundary. Anything you'd try will produce a security exception.