直接从另一个可执行文件调用内部本机方法

发布于 2025-02-01 22:54:37 字数 426 浏览 4 评论 0原文

出于安全目的,我的应用程序IM试图调用较低级别的功能以加载我的DLL。

首先,我使用assembly.load,但是如我所见,挂钩和获取DLL字节非常容易。

因此,我要做的是从runtimeassembly调用nloadImage,这是加载汇编的较低级功能。

这是问题来自于runtimeassembly是默认库类,并标记为internal,我需要调用的方法,nloadimage is另外内部

我怎么称呼该方法?

PS。我将C#与.NET框架一起使用。

第2页。只是知道,加载exe/dll的过程中是一种更低级的方法吗?甚至通过使用本地功能?

For security purposes of my application im trying to call a lower-level function to load my dll.

At first i was using Assembly.Load but as i see, it is pretty easy to hook and get the dll bytes.

So what i want to do is to call nLoadImage from RuntimeAssembly which is the lower-level function to load an assembly.

Here is were the problem comes from, RuntimeAssembly is a default library class and is marked as internal, the method i need to call, nLoadImage is also internal.

How could i call that method?

PS. Im using C# with .Net framework.

PS.2. Just to know, is a more low-level way to load an Exe/Dll inside the process? Maybe even by using native functions?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文