Actual behavior
It's generated like this:
[DllImport("WINTRUST.dll", ExactSpelling = true)]
[DefaultDllImportSearchPaths(DllImportSearchPath.System32)]
[SupportedOSPlatform("windows5.1.2600")]
internal static extern winmdroot.Security.WinTrust.CRYPT_PROVIDER_DATA WTHelperProvDataFromStateData(winmdroot.Foundation.HANDLE hStateData);
But it should return a pointer to CRYPT_PROVIDER_DATA.
In the metadata this is OK:
[SupportedOSPlatform("windows5.1.2600")]
[Documentation("https://docs.microsoft.com/windows/win32/api/wintrust/nf-wintrust-wthelperprovdatafromstatedata")]
[DllImport("WINTRUST.dll", ExactSpelling = true, PreserveSig = false)]
public unsafe static extern CRYPT_PROVIDER_DATA* WTHelperProvDataFromStateData([In] HANDLE hStateData);
Expected behavior
A clear and concise description of what you expected to happen.
Repro steps
NativeMethods.txt content:
WTHelperProvDataFromStateData
Context
- CsWin32 version: 0.3.18-beta+dc807e7787
- Target Framework: net 6.0
LangVersion (if explicitly set by project): latest