microsoft / microsoft/win32metadata
Missing unsafe context/modifier when parsing SslGetCipherSuitePRFHashAlgorithm
- Dominant language
- C++
- Stars
- 1.5k
- Forks
- 149
- Avg merge
- 5d 16h
- Merged PRs (30d)
- 4
Description
Placeholder issue. Hit an issue with this particular API, might be a ClangSharp bug but haven't fully investigated yet.
```cpp
SECURITY_STATUS
WINAPI
SslGetCipherSuitePRFHashAlgorithm(
_In_ NCRYPT_PROV_HANDLE hSslProvider,
_In_ DWORD dwProtocol,
_In_ DWORD dwCipherSuite,
_In_ DWORD dwKeyType,
_Out_writes_(NCRYPT_SSL_MAX_NAME_SIZE)
WCHAR szPRFHash[NCRYPT_SSL_MAX_NAME_SIZE],
_In_ DWORD dwFlags);
```
results in
```csharp
public delegate HRESULT SslGetCipherSuitePRFHashAlgorithmFn([NativeTypeName("NCRYPT_PROV_HANDLE")][In]UIntPtr hSslProvider, [NativeTypeName("DWORD")][In]uint dwProtocol, [NativeTypeName("DWORD")][In]uint dwCipherSuite, [NativeTypeName("DWORD")][In]uint dwKeyType, [NativeTypeName("WCHAR[64]")][NativeArrayInfo(CountConst = 64),Out]ushort* szPRFHash, [NativeTypeName("DWORD")][In]uint dwFlags);
```
Contributor guide
Research direction
Start with the SslGetCipherSuitePRFHashAlgorithm declaration and the generated C# delegate shown in the issue. Reproduce metadata generation and trace how ClangSharp handles the pointer parameter and unsafe context or modifier. Done means determining whether this is a ClangSharp parsing bug and producing the expected generated declaration, if a fix is confirmed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, csharp
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100