如何搜索包含Windows api函数的Windows动态链接库



我正在使用JNA与Windows API进行交互。

我想使用WinBase.h标头中的LogonUserW函数。为了使用JNA的Native.load加载它,我需要知道动态链接库的名称。

例如,CredReadWWinCred.h标头中,我通过示例发现该函数是由advapi32.dll提供的,因此我能够加载带有的函数

// WinCrypt is my own interface. I'm not sure why it's WinCrypt instead of WinCred,
// but that's what I saw in other examples.
Native.load("Advapi32", WinCrypt.class);

这是一个基于的例子

我真的需要使用DUMPBIN来检查Windows中的每个dll才能找到它吗?我本希望微软能提供一种更好的方法来找到这些。

Agh-nvm页面本身有一个表,显示库。只需搜索字符串";Advapi32〃;

https://learn.microsoft.com/en-us/windows/win32/api/winbase/nf-winbase-logonuserw

最新更新