且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

将命令行参数隐藏到EXE

更新时间:2023-08-25 23:04:16

坏主意,带有额外可执行文件的那个。通常,如果您将某个* .EXE用于其他目的,然后让用户启动应用程序,这已经是错误架构的标志。至少它可以从* .EXE重命名为其他东西(它不会改变它的功能),但这不是一个真正的解决方案...



你可以自动请求通过添加和嵌入适当的应用程序清单来提升权限。这在这里解释:

http://msdn.microsoft.com/en -us / library / bb756929.aspx [ ^ ]。



当然,你不能绕过UAC(它会破坏它的目的),但你可以关掉它,我强烈反对。



-SA
Bad idea, the one with extra executable. Generally, if you are using some *.EXE for the purpose other then letting the user to start an application, this is already a sign of wrong architecture. At least it could be renamed from *.EXE to something else (it would not change its functionality), but this is not a real solution…

You can automatically request elevated privileges by adding and embedding appropriate application manifest. This is explained here:
http://msdn.microsoft.com/en-us/library/bb756929.aspx[^].

Of course, you cannot bypass UAC (it would defeat its purpose), but you can switch it off, which I would strongly discourage.

—SA