C#open regedit作为管理员 [英] C# open regedit as administrator

查看:80
本文介绍了C#open regedit作为管理员的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这与我之前的问题有点相似,但我认为我需要另一种方法。



我有一个可以连接公司其他电脑的应用程序网络。现在我可以作为管理员连接到他们的资源管理器,而没有任何对话框要求我的凭据。

但是现在我希望能够将管理员权限导入我的注册表(读/写)。



所以我需要以管理员身份打开regedit.exe。



我想在没有UAC弹出的情况下打开它。



有人知道怎么做吗?



我尝试了什么:



我已经尝试使用Manifest,但是当应用程序启动时我会得到UAC。

并且使用Impersonate类也不起作用。

This is a bit simular as my previous question, but I think I need another approach.

I have a app that can connect to other pc's on the company network. For now I can connect to their explorer as an admin without any dialog asking for my credentials.
But now I want to be able to import their registry into my registry with admin rights so (read/write).

So i need to open the regedit.exe as an Administrator.

I want to open it without the UAC popping up.

Does someone know how to do this?

What I have tried:

I've already tried to use a Manifest, but then i get the UAC when the app starts.
And with the Impersonate class doesn't work either.

推荐答案

如果没有UAC,您无法将流程提升为管理员权限:这就是整个想法。

如果可以的话 - 你不能 - 我们不会告诉你如何做到这一点,因为它会使访问控制变得毫无意义,这只会使黑客,勒索软件编写者和低生活垃圾一样受益。



我们不会宽恕,支持或协助以任何方式,形式或方式生成恶意代码。这是专业开发人员的专业网站。
You cannot elevate a process to Admin privilege without UAC: that's the whole idea.
And if you could - which you can't - we wouldn't tell you how to do it, as it would render access control meaningless which would only benefit hackers, ransomware writers, and such like low life scum.

We do not condone, support, or assist in the production of malicious code in any way, form, or manner. This is a professional site for professional developers.


这篇关于C#open regedit作为管理员的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆