我可以修改Win7环境以允许.Net程序始终以管理员身份运行吗? [英] Can I modify a Win7 environment to allow a .Net program to always run as Administrator?

查看:45
本文介绍了我可以修改Win7环境以允许.Net程序始终以管理员身份运行吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们将推出数百台运行Windows 7的新计算机,并通过WDS安装操作系统,目前,我们可以进行更改并将它们进行系统准备.

We are about to roll out several hundred new machines running windows 7, with the OS installed via WDS so at the moment we can make changes and sysprep them into the build.

问题是我们几年前编写的.Net应用程序,它本身产生了经过修改的命令外壳.该外壳程序运行一个dataflex应用程序,该应用程序本身需要以提升的权限运行.

The problem is a .Net app we wrote years ago which itself spawns a modified command shell. That shell runs a dataflex application that itself needs to run with elevated permissions.

我们不授予用户任何一般管理员权限.

We don't grant users any general admin rights.

有没有一种机制可以让我们允许.Net应用程序以管理员身份运行,以便命令控件以管理员身份运行?

Is there a mechanism where we can pre-allow our .Net app to run as administrator so that the command control runs as Administrator?

我知道我可以在app.manifest中进行的更改,以要求程序以管理员身份运行.我不知道如何(以管理员身份)配置计算机以允许发生这种情况,而不给用户更多的权限或凭据.

I'm aware of the changes I can make in the app.manifest to require that the program runs as Administrator. I'm not aware of how I can (as an Administrator) configure the machine to allow that to happen without giving the user more rights or credentials than I would want them to have.

推荐答案

应用程序必须以管理员身份运行吗?还是只需要访问特定内容?如果启动时出现虚假的我是管理员"检查,则可以使用应用程序兼容性工具包对其进行欺骗,然后配置对其实际需要的东西的访问权限.

Does the application have to run as Administrator, or does it just need access to specific things? If it has a spurious "am I admin" check at startup, you can probably use a shim from the Application Compatibility Toolkit to lie to it, and then configure access permissions to the things that it actually needs.

如果它看起来会飞起来的话,那么最好将其他问题提交给serverfault.

If that looks like it'll fly, then you'd be better off taking further questions over to serverfault.

这篇关于我可以修改Win7环境以允许.Net程序始终以管理员身份运行吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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