Added new functions from vertdll.dll

pull/83/head
David Hall 2019-09-06 08:17:17 -06:00
parent 2a06438cd4
commit 2497e39ef1
3 changed files with 367 additions and 54 deletions

View File

@ -1,5 +1,5 @@
## Correlation report for kernel32.dll, kernelbase.dll, normaliz.dll, vertdll.dll
### Methods (95% complete)
### Methods (100% complete)
Native Method | Native DLL | Header | Managed Method
--- | --- | --- | ---
[AcquireSRWLockExclusive](http://msdn2.microsoft.com/en-us/library/ms681930) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.AcquireSRWLockExclusive](https://github.com/dahall/Vanara/search?l=C%23&q=AcquireSRWLockExclusive)
@ -131,7 +131,6 @@ Native Method | Native DLL | Header | Managed Method
[CreateUmsThreadContext](http://msdn2.microsoft.com/en-us/library/b27ce81a-8463-46af-8acf-2de091f625df) | kernel32.dll | winbase.h | [Vanara.PInvoke.Kernel32.CreateUmsThreadContext](https://github.com/dahall/Vanara/search?l=C%23&q=CreateUmsThreadContext)
[CreateWaitableTimer](http://msdn2.microsoft.com/en-us/library/ms682492) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.CreateWaitableTimer](https://github.com/dahall/Vanara/search?l=C%23&q=CreateWaitableTimer)
[CreateWaitableTimerEx](http://msdn2.microsoft.com/en-us/library/ms682494) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.CreateWaitableTimerEx](https://github.com/dahall/Vanara/search?l=C%23&q=CreateWaitableTimerEx)
[DbgPrint](https://www.google.com/search?num=5&q=DbgPrint+site%3Amicrosoft.com) | vertdll.dll | |
[DeactivateActCtx](http://msdn2.microsoft.com/en-us/library/aa375140) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.DeactivateActCtx](https://github.com/dahall/Vanara/search?l=C%23&q=DeactivateActCtx)
[DebugActiveProcess](http://msdn2.microsoft.com/en-us/library/ms679295) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.DebugActiveProcess](https://github.com/dahall/Vanara/search?l=C%23&q=DebugActiveProcess)
[DebugActiveProcessStop](http://msdn2.microsoft.com/en-us/library/ms679296) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.DebugActiveProcessStop](https://github.com/dahall/Vanara/search?l=C%23&q=DebugActiveProcessStop)
@ -142,7 +141,6 @@ Native Method | Native DLL | Header | Managed Method
[DecodeRemotePointer](http://msdn2.microsoft.com/en-us/library/dn877133) | kernelbase.dll | UtilApiSet.h | [Vanara.PInvoke.Kernel32.DecodeRemotePointer](https://github.com/dahall/Vanara/search?l=C%23&q=DecodeRemotePointer)
[DecodeSystemPointer](http://msdn2.microsoft.com/en-us/library/bb432243) | kernel32.dll | UtilApiSet.h | [Vanara.PInvoke.Kernel32.DecodeSystemPointer](https://github.com/dahall/Vanara/search?l=C%23&q=DecodeSystemPointer)
[DefineDosDevice](http://msdn2.microsoft.com/en-us/library/924b1456-b2c5-4d52-aacf-6172608c73ea) | kernel32.dll | fileapi.h | [Vanara.PInvoke.Kernel32.DefineDosDevice](https://github.com/dahall/Vanara/search?l=C%23&q=DefineDosDevice)
[DelayLoadFailureHook](https://www.google.com/search?num=5&q=DelayLoadFailureHook+site%3Amicrosoft.com) | vertdll.dll | |
[DeleteAtom](http://msdn2.microsoft.com/en-us/library/ms649057) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.DeleteAtom](https://github.com/dahall/Vanara/search?l=C%23&q=DeleteAtom)
[DeleteBoundaryDescriptor](http://msdn2.microsoft.com/en-us/library/759d9cd9-9ef2-4bbe-9e99-8aec87f5ba4a) | kernel32.dll | namespaceapi.h | [Vanara.PInvoke.Kernel32.DeleteBoundaryDescriptor](https://github.com/dahall/Vanara/search?l=C%23&q=DeleteBoundaryDescriptor)
[DeleteCriticalSection](http://msdn2.microsoft.com/en-us/library/ms682552) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.DeleteCriticalSection](https://github.com/dahall/Vanara/search?l=C%23&q=DeleteCriticalSection)
@ -170,11 +168,11 @@ Native Method | Native DLL | Header | Managed Method
[DuplicateHandle](http://msdn2.microsoft.com/en-us/library/ms724251) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.DuplicateHandle](https://github.com/dahall/Vanara/search?l=C%23&q=DuplicateHandle)
[EmptyWorkingSet](http://msdn2.microsoft.com/en-us/library/76f2252e-7305-46b0-b1af-40ac084e6696) | kernelbase.dll | psapi.h | [Vanara.PInvoke.Kernel32.EmptyWorkingSet](https://github.com/dahall/Vanara/search?l=C%23&q=EmptyWorkingSet)
[EnableThreadProfiling](http://msdn2.microsoft.com/en-us/library/dd796393) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.EnableThreadProfiling](https://github.com/dahall/Vanara/search?l=C%23&q=EnableThreadProfiling)
[EnclaveGetAttestationReport](https://www.google.com/search?num=5&q=EnclaveGetAttestationReport+site%3Amicrosoft.com) | vertdll.dll | |
[EnclaveGetEnclaveInformation](https://www.google.com/search?num=5&q=EnclaveGetEnclaveInformation+site%3Amicrosoft.com) | vertdll.dll | |
[EnclaveSealData](https://www.google.com/search?num=5&q=EnclaveSealData+site%3Amicrosoft.com) | vertdll.dll | |
[EnclaveUnsealData](https://www.google.com/search?num=5&q=EnclaveUnsealData+site%3Amicrosoft.com) | vertdll.dll | |
[EnclaveVerifyAttestationReport](https://www.google.com/search?num=5&q=EnclaveVerifyAttestationReport+site%3Amicrosoft.com) | vertdll.dll | |
[EnclaveGetAttestationReport](http://msdn2.microsoft.com/en-us/library/FEE8F05B-540F-4C10-A90C-55607A4E9293) | vertdll.dll | winenclaveapi.h | [Vanara.PInvoke.Kernel32.EnclaveGetAttestationReport](https://github.com/dahall/Vanara/search?l=C%23&q=EnclaveGetAttestationReport)
[EnclaveGetEnclaveInformation](http://msdn2.microsoft.com/en-us/library/26349C3C-4B73-430C-B002-ED262DB0304F) | vertdll.dll | winenclaveapi.h | [Vanara.PInvoke.Kernel32.EnclaveGetEnclaveInformation](https://github.com/dahall/Vanara/search?l=C%23&q=EnclaveGetEnclaveInformation)
[EnclaveSealData](http://msdn2.microsoft.com/en-us/library/C5711D43-F0B4-43C6-B0DB-D65622851384) | vertdll.dll | winenclaveapi.h | [Vanara.PInvoke.Kernel32.EnclaveSealData](https://github.com/dahall/Vanara/search?l=C%23&q=EnclaveSealData)
[EnclaveUnsealData](http://msdn2.microsoft.com/en-us/library/DDBDBEDE-E7EA-43B0-B2C7-B85D75EF3EB0) | vertdll.dll | winenclaveapi.h | [Vanara.PInvoke.Kernel32.EnclaveUnsealData](https://github.com/dahall/Vanara/search?l=C%23&q=EnclaveUnsealData)
[EnclaveVerifyAttestationReport](http://msdn2.microsoft.com/en-us/library/D74F89FB-9F06-4AA1-9E2E-C9265B3C5B44) | vertdll.dll | winenclaveapi.h | [Vanara.PInvoke.Kernel32.EnclaveVerifyAttestationReport](https://github.com/dahall/Vanara/search?l=C%23&q=EnclaveVerifyAttestationReport)
[EncodePointer](http://msdn2.microsoft.com/en-us/library/bb432254) | kernel32.dll | UtilApiSet.h | [Vanara.PInvoke.Kernel32.EncodePointer](https://github.com/dahall/Vanara/search?l=C%23&q=EncodePointer)
[EncodeRemotePointer](http://msdn2.microsoft.com/en-us/library/dn877135) | kernelbase.dll | UtilApiSet.h | [Vanara.PInvoke.Kernel32.EncodeRemotePointer](https://github.com/dahall/Vanara/search?l=C%23&q=EncodeRemotePointer)
[EncodeSystemPointer](http://msdn2.microsoft.com/en-us/library/bb432255) | kernel32.dll | UtilApiSet.h | [Vanara.PInvoke.Kernel32.EncodeSystemPointer](https://github.com/dahall/Vanara/search?l=C%23&q=EncodeSystemPointer)
@ -216,10 +214,6 @@ Native Method | Native DLL | Header | Managed Method
[EnumUILanguages](http://msdn2.microsoft.com/en-us/library/dd317834) | kernel32.dll | Winnls.h | [Vanara.PInvoke.Kernel32.EnumUILanguages](https://github.com/dahall/Vanara/search?l=C%23&q=EnumUILanguages)
[EraseTape](http://msdn2.microsoft.com/en-us/library/aa362523) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.EraseTape](https://github.com/dahall/Vanara/search?l=C%23&q=EraseTape)
[EscapeCommFunction](http://msdn2.microsoft.com/en-us/library/aa363254) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.EscapeCommFunction](https://github.com/dahall/Vanara/search?l=C%23&q=EscapeCommFunction)
[EventRegister](https://www.google.com/search?num=5&q=EventRegister+site%3Amicrosoft.com) | vertdll.dll | |
[EventSetInformation](https://www.google.com/search?num=5&q=EventSetInformation+site%3Amicrosoft.com) | vertdll.dll | |
[EventUnregister](https://www.google.com/search?num=5&q=EventUnregister+site%3Amicrosoft.com) | vertdll.dll | |
[EventWriteTransfer](https://www.google.com/search?num=5&q=EventWriteTransfer+site%3Amicrosoft.com) | vertdll.dll | |
[ExecuteUmsThread](http://msdn2.microsoft.com/en-us/library/e4265351-e8e9-4878-bd42-93258b4cd1a0) | kernel32.dll | winbase.h | [Vanara.PInvoke.Kernel32.ExecuteUmsThread](https://github.com/dahall/Vanara/search?l=C%23&q=ExecuteUmsThread)
[ExitProcess](http://msdn2.microsoft.com/en-us/library/ms682658) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.ExitProcess](https://github.com/dahall/Vanara/search?l=C%23&q=ExitProcess)
[ExitThread](http://msdn2.microsoft.com/en-us/library/ms682659) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.ExitThread](https://github.com/dahall/Vanara/search?l=C%23&q=ExitThread)
@ -381,7 +375,6 @@ Native Method | Native DLL | Header | Managed Method
[GetFileTime](http://msdn2.microsoft.com/en-us/library/ms724320) | kernel32.dll | FileAPI.h | [Vanara.PInvoke.Kernel32.GetFileTime](https://github.com/dahall/Vanara/search?l=C%23&q=GetFileTime)
[GetFileType](http://msdn2.microsoft.com/en-us/library/aa364960) | kernel32.dll | FileAPI.h | [Vanara.PInvoke.Kernel32.GetFileType](https://github.com/dahall/Vanara/search?l=C%23&q=GetFileType)
[GetFinalPathNameByHandle](http://msdn2.microsoft.com/en-us/library/aa364962) | kernel32.dll | FileAPI.h | [Vanara.PInvoke.Kernel32.GetFinalPathNameByHandle](https://github.com/dahall/Vanara/search?l=C%23&q=GetFinalPathNameByHandle)
[GetFipsModeFromIumKernelState](https://www.google.com/search?num=5&q=GetFipsModeFromIumKernelState+site%3Amicrosoft.com) | vertdll.dll | |
[GetFirmwareEnvironmentVariable](http://msdn2.microsoft.com/en-us/library/ms724325) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.GetFirmwareEnvironmentVariable](https://github.com/dahall/Vanara/search?l=C%23&q=GetFirmwareEnvironmentVariable)
[GetFirmwareEnvironmentVariableEx](http://msdn2.microsoft.com/en-us/library/B093BA68-C68B-4ED6-9902-058650A191FD) | kernel32.dll | winbase.h | [Vanara.PInvoke.Kernel32.GetFirmwareEnvironmentVariableEx](https://github.com/dahall/Vanara/search?l=C%23&q=GetFirmwareEnvironmentVariableEx)
[GetFullPathName](https://www.google.com/search?num=5&q=GetFullPathNameA+site%3Amicrosoft.com) | kernel32.dll | FileAPI.h | [Vanara.PInvoke.Kernel32.GetFullPathName](https://github.com/dahall/Vanara/search?l=C%23&q=GetFullPathName)
@ -489,7 +482,6 @@ Native Method | Native DLL | Header | Managed Method
[GetProfileString](http://msdn2.microsoft.com/en-us/library/ms724366) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.GetProfileString](https://github.com/dahall/Vanara/search?l=C%23&q=GetProfileString)
[GetQueuedCompletionStatus](http://msdn2.microsoft.com/en-us/library/aa364986) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.GetQueuedCompletionStatus](https://github.com/dahall/Vanara/search?l=C%23&q=GetQueuedCompletionStatus)
[GetQueuedCompletionStatusEx](http://msdn2.microsoft.com/en-us/library/aa364988) | kernel32.dll | IoAPI.h | [Vanara.PInvoke.Kernel32.GetQueuedCompletionStatusEx](https://github.com/dahall/Vanara/search?l=C%23&q=GetQueuedCompletionStatusEx)
[GetSeedFromIumKernelState](https://www.google.com/search?num=5&q=GetSeedFromIumKernelState+site%3Amicrosoft.com) | vertdll.dll | |
[GetShortPathName](https://www.google.com/search?num=5&q=GetShortPathNameA+site%3Amicrosoft.com) | kernel32.dll | FileAPI.h | [Vanara.PInvoke.Kernel32.GetShortPathName](https://github.com/dahall/Vanara/search?l=C%23&q=GetShortPathName)
[GetStagedPackageOrigin](http://msdn2.microsoft.com/en-us/library/7A1EE2CA-83CE-4E03-85A5-0061E29EB49B) | kernelbase.dll | appmodel.h | [Vanara.PInvoke.Kernel32.GetStagedPackageOrigin](https://github.com/dahall/Vanara/search?l=C%23&q=GetStagedPackageOrigin)
[GetStagedPackagePathByFullName](http://msdn2.microsoft.com/en-us/library/F0A37D77-6262-44B1-BEC5-083E41BDE139) | kernel32.dll | appmodel.h | [Vanara.PInvoke.Kernel32.GetStagedPackagePathByFullName](https://github.com/dahall/Vanara/search?l=C%23&q=GetStagedPackagePathByFullName)
@ -654,12 +646,9 @@ Native Method | Native DLL | Header | Managed Method
[IsWow64GuestMachineSupported](http://msdn2.microsoft.com/en-us/library/mt804321) | kernel32.dll | Wow64apiset.h | [Vanara.PInvoke.Kernel32.IsWow64GuestMachineSupported](https://github.com/dahall/Vanara/search?l=C%23&q=IsWow64GuestMachineSupported)
[IsWow64Process](http://msdn2.microsoft.com/en-us/library/ms684139) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.IsWow64Process](https://github.com/dahall/Vanara/search?l=C%23&q=IsWow64Process)
[IsWow64Process2](http://msdn2.microsoft.com/en-us/library/mt804318) | kernel32.dll | Wow64apiset.h | [Vanara.PInvoke.Kernel32.IsWow64Process2](https://github.com/dahall/Vanara/search?l=C%23&q=IsWow64Process2)
[KiUserExceptionDispatcher](https://www.google.com/search?num=5&q=KiUserExceptionDispatcher+site%3Amicrosoft.com) | vertdll.dll | |
[LCIDToLocaleName](http://msdn2.microsoft.com/en-us/library/dd318698) | kernel32.dll | Winnls.h | [Vanara.PInvoke.Kernel32.LCIDToLocaleName](https://github.com/dahall/Vanara/search?l=C%23&q=LCIDToLocaleName)
[LCMapString](http://msdn2.microsoft.com/en-us/library/dd318700) | kernel32.dll | Winnls.h | [Vanara.PInvoke.Kernel32.LCMapString](https://github.com/dahall/Vanara/search?l=C%23&q=LCMapString)
[LCMapStringEx](http://msdn2.microsoft.com/en-us/library/dd318702) | kernel32.dll | Winnls.h | [Vanara.PInvoke.Kernel32.LCMapStringEx](https://github.com/dahall/Vanara/search?l=C%23&q=LCMapStringEx)
[LdrDisableThreadCalloutsForDll](https://www.google.com/search?num=5&q=LdrDisableThreadCalloutsForDll+site%3Amicrosoft.com) | vertdll.dll | |
[LdrResolveDelayLoadedAPI](https://www.google.com/search?num=5&q=LdrResolveDelayLoadedAPI+site%3Amicrosoft.com) | vertdll.dll | |
[LeaveCriticalSection](http://msdn2.microsoft.com/en-us/library/ms684169) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.LeaveCriticalSection](https://github.com/dahall/Vanara/search?l=C%23&q=LeaveCriticalSection)
[LeaveCriticalSectionWhenCallbackReturns](http://msdn2.microsoft.com/en-us/library/ms684171) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.LeaveCriticalSectionWhenCallbackReturns](https://github.com/dahall/Vanara/search?l=C%23&q=LeaveCriticalSectionWhenCallbackReturns)
[LoadEnclaveData](http://msdn2.microsoft.com/en-us/library/mt592871) | kernel32.dll | Enclaveapi.h | [Vanara.PInvoke.Kernel32.LoadEnclaveData](https://github.com/dahall/Vanara/search?l=C%23&q=LoadEnclaveData)
@ -697,10 +686,6 @@ Native Method | Native DLL | Header | Managed Method
[MapViewOfFileExNuma](http://msdn2.microsoft.com/en-us/library/1e28c8db-112d-481d-b470-8ca618e125ce) | kernel32.dll | winbase.h | [Vanara.PInvoke.Kernel32.MapViewOfFileExNuma](https://github.com/dahall/Vanara/search?l=C%23&q=MapViewOfFileExNuma)
[MapViewOfFileFromApp](http://msdn2.microsoft.com/en-us/library/hh994454) | kernel32.dll | MemoryApi.h | [Vanara.PInvoke.Kernel32.MapViewOfFileFromApp](https://github.com/dahall/Vanara/search?l=C%23&q=MapViewOfFileFromApp)
[MapViewOfFileNuma2](http://msdn2.microsoft.com/en-us/library/mt492558) | kernelbase.dll | WinBase.h | [Vanara.PInvoke.Kernel32.MapViewOfFileNuma2](https://github.com/dahall/Vanara/search?l=C%23&q=MapViewOfFileNuma2)
[memcmp](https://www.google.com/search?num=5&q=memcmp+site%3Amicrosoft.com) | vertdll.dll | |
[memcpy](https://www.google.com/search?num=5&q=memcpy+site%3Amicrosoft.com) | vertdll.dll | |
[memmove](https://www.google.com/search?num=5&q=memmove+site%3Amicrosoft.com) | vertdll.dll | |
[memset](https://www.google.com/search?num=5&q=memset+site%3Amicrosoft.com) | vertdll.dll | |
[Module32First](http://msdn2.microsoft.com/en-us/library/bb41cab9-13a1-469d-bf76-68c172e982f6) | kernel32.dll | tlhelp32.h | [Vanara.PInvoke.Kernel32.Module32First](https://github.com/dahall/Vanara/search?l=C%23&q=Module32First)
[Module32Next](https://www.google.com/search?num=5&q=Module32Next+site%3Amicrosoft.com) | kernel32.dll | tlhelp32.h | [Vanara.PInvoke.Kernel32.Module32Next](https://github.com/dahall/Vanara/search?l=C%23&q=Module32Next)
[Module32NextA](http://msdn2.microsoft.com/en-us/library/88ec1af4-bae7-4cd7-b830-97a98fb337f4) | kernel32.dll | tlhelp32.h | [Vanara.PInvoke.Kernel32.Module32Next](https://github.com/dahall/Vanara/search?l=C%23&q=Module32Next)
@ -724,7 +709,6 @@ Native Method | Native DLL | Header | Managed Method
[OpenPackageInfoByFullName](http://msdn2.microsoft.com/en-us/library/9ECFC757-1CB3-43A1-BA45-9AF72CAB240E) | kernelbase.dll | appmodel.h | [Vanara.PInvoke.Kernel32.OpenPackageInfoByFullName](https://github.com/dahall/Vanara/search?l=C%23&q=OpenPackageInfoByFullName)
[OpenPrivateNamespace](http://msdn2.microsoft.com/en-us/library/ms684318) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.OpenPrivateNamespaceInternal](https://github.com/dahall/Vanara/search?l=C%23&q=OpenPrivateNamespaceInternal)
[OpenProcess](http://msdn2.microsoft.com/en-us/library/ms684320) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.OpenProcess](https://github.com/dahall/Vanara/search?l=C%23&q=OpenProcess)
[OpenProcessToken](https://www.google.com/search?num=5&q=OpenProcessToken+site%3Amicrosoft.com) | vertdll.dll | |
[OpenSemaphore](http://msdn2.microsoft.com/en-us/library/ms684326) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.OpenSemaphore](https://github.com/dahall/Vanara/search?l=C%23&q=OpenSemaphore)
[OpenThread](http://msdn2.microsoft.com/en-us/library/ms684335) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.OpenThread](https://github.com/dahall/Vanara/search?l=C%23&q=OpenThread)
[OpenWaitableTimer](http://msdn2.microsoft.com/en-us/library/ms684337) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.OpenWaitableTimer](https://github.com/dahall/Vanara/search?l=C%23&q=OpenWaitableTimer)
@ -765,7 +749,6 @@ Native Method | Native DLL | Header | Managed Method
[PowerSetRequest](http://msdn2.microsoft.com/en-us/library/85249de8-5832-4f25-bbd9-3576cfd1caa0) | kernel32.dll | winbase.h | [Vanara.PInvoke.Kernel32.PowerSetRequest](https://github.com/dahall/Vanara/search?l=C%23&q=PowerSetRequest)
[PrefetchVirtualMemory](http://msdn2.microsoft.com/en-us/library/hh780543) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.PrefetchVirtualMemory](https://github.com/dahall/Vanara/search?l=C%23&q=PrefetchVirtualMemory)
[PrepareTape](http://msdn2.microsoft.com/en-us/library/aa362532) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.PrepareTape](https://github.com/dahall/Vanara/search?l=C%23&q=PrepareTape)
[PrivilegeCheck](https://www.google.com/search?num=5&q=PrivilegeCheck+site%3Amicrosoft.com) | vertdll.dll | |
[Process32First](https://www.google.com/search?num=5&q=Process32First+site%3Amicrosoft.com) | kernel32.dll | tlhelp32.h | [Vanara.PInvoke.Kernel32.Process32First](https://github.com/dahall/Vanara/search?l=C%23&q=Process32First)
[Process32FirstA](http://msdn2.microsoft.com/en-us/library/097790e8-30c2-4b00-9256-fa26e2ceb893) | kernel32.dll | tlhelp32.h | [Vanara.PInvoke.Kernel32.Process32First](https://github.com/dahall/Vanara/search?l=C%23&q=Process32First)
[Process32Next](https://www.google.com/search?num=5&q=Process32Next+site%3Amicrosoft.com) | kernel32.dll | tlhelp32.h | [Vanara.PInvoke.Kernel32.Process32Next](https://github.com/dahall/Vanara/search?l=C%23&q=Process32Next)
@ -783,13 +766,11 @@ Native Method | Native DLL | Header | Managed Method
[PssWalkSnapshot](http://msdn2.microsoft.com/en-us/library/C6AC38B5-0A1C-44D7-A1F6-8196AE9B8FB0) | kernel32.dll | processsnapshot.h | [Vanara.PInvoke.Kernel32.PssWalkSnapshot](https://github.com/dahall/Vanara/search?l=C%23&q=PssWalkSnapshot)
[PulseEvent](http://msdn2.microsoft.com/en-us/library/ms684914) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.PulseEvent](https://github.com/dahall/Vanara/search?l=C%23&q=PulseEvent)
[PurgeComm](http://msdn2.microsoft.com/en-us/library/aa363428) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.PurgeComm](https://github.com/dahall/Vanara/search?l=C%23&q=PurgeComm)
[qsort](https://www.google.com/search?num=5&q=qsort+site%3Amicrosoft.com) | vertdll.dll | |
[QueryActCtxSettingsW](http://msdn2.microsoft.com/en-us/library/aa375700) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.QueryActCtxSettingsW](https://github.com/dahall/Vanara/search?l=C%23&q=QueryActCtxSettingsW)
[QueryActCtxW](http://msdn2.microsoft.com/en-us/library/7d45f63f-0baf-4236-b245-d36f9eb32e8c) | kernel32.dll | winbase.h | [Vanara.PInvoke.Kernel32.QueryActCtxW](https://github.com/dahall/Vanara/search?l=C%23&q=QueryActCtxW)
[QueryAuxiliaryCounterFrequency](http://msdn2.microsoft.com/en-us/library/71E00DF2-7F67-43D2-9D6D-BFE9FEA4B30A) | kernelbase.dll | realtimeapiset.h | [Vanara.PInvoke.Kernel32.QueryAuxiliaryCounterFrequency](https://github.com/dahall/Vanara/search?l=C%23&q=QueryAuxiliaryCounterFrequency)
[QueryDepthSList](http://msdn2.microsoft.com/en-us/library/3f9b4481-647f-457f-bdfb-62e6ae4198e5) | kernel32.dll | interlockedapi.h | [Vanara.PInvoke.Kernel32.QueryDepthSList](https://github.com/dahall/Vanara/search?l=C%23&q=QueryDepthSList)
[QueryDosDevice](http://msdn2.microsoft.com/en-us/library/aa365461) | kernel32.dll | FileAPI.h | [Vanara.PInvoke.Kernel32.QueryDosDevice](https://github.com/dahall/Vanara/search?l=C%23&q=QueryDosDevice)
[QueryFullProcess](https://www.google.com/search?num=5&q=QueryFullProcess+site%3Amicrosoft.com) | vertdll.dll | |
[QueryFullProcessImageName](http://msdn2.microsoft.com/en-us/library/49a9d1aa-30f3-45ea-a4ec-9f55df692b8b) | kernel32.dll | winbase.h | [Vanara.PInvoke.Kernel32.QueryFullProcessImageName](https://github.com/dahall/Vanara/search?l=C%23&q=QueryFullProcessImageName)
[QueryIdleProcessorCycleTime](http://msdn2.microsoft.com/en-us/library/75a5c4cf-ccc7-47ab-a2a9-88051e0a7d06) | kernel32.dll | realtimeapiset.h | [Vanara.PInvoke.Kernel32.QueryIdleProcessorCycleTime](https://github.com/dahall/Vanara/search?l=C%23&q=QueryIdleProcessorCycleTime)
[QueryIdleProcessorCycleTimeEx](http://msdn2.microsoft.com/en-us/library/4bf05e40-96d1-4c01-b3a8-8a45934b38c6) | kernel32.dll | realtimeapiset.h | [Vanara.PInvoke.Kernel32.QueryIdleProcessorCycleTimeEx](https://github.com/dahall/Vanara/search?l=C%23&q=QueryIdleProcessorCycleTimeEx)
@ -834,7 +815,6 @@ Native Method | Native DLL | Header | Managed Method
[RegisterApplicationRestart](http://msdn2.microsoft.com/en-us/library/aa373347) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.RegisterApplicationRestart](https://github.com/dahall/Vanara/search?l=C%23&q=RegisterApplicationRestart)
[RegisterBadMemoryNotification](http://msdn2.microsoft.com/en-us/library/hh691013) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.RegisterBadMemoryNotification](https://github.com/dahall/Vanara/search?l=C%23&q=RegisterBadMemoryNotification)
[RegisterWaitForSingleObject](https://www.google.com/search?num=5&q=RegisterWaitForSingleObject+site%3Amicrosoft.com) | kernel32.dll | | [Vanara.PInvoke.Kernel32.RegisterWaitForSingleObject](https://github.com/dahall/Vanara/search?l=C%23&q=RegisterWaitForSingleObject)
[RegisterWaitForSingleObjectEx](https://www.google.com/search?num=5&q=RegisterWaitForSingleObjectEx+site%3Amicrosoft.com) | vertdll.dll | |
[ReleaseActCtx](http://msdn2.microsoft.com/en-us/library/aa375713) | kernel32.dll | Winbase.h | [Vanara.PInvoke.Kernel32.ReleaseActCtx](https://github.com/dahall/Vanara/search?l=C%23&q=ReleaseActCtx)
[ReleaseMutex](http://msdn2.microsoft.com/en-us/library/ms685066) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.ReleaseMutex](https://github.com/dahall/Vanara/search?l=C%23&q=ReleaseMutex)
[ReleaseMutexWhenCallbackReturns](http://msdn2.microsoft.com/en-us/library/ms685070) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.ReleaseMutexWhenCallbackReturns](https://github.com/dahall/Vanara/search?l=C%23&q=ReleaseMutexWhenCallbackReturns)
@ -853,46 +833,20 @@ Native Method | Native DLL | Header | Managed Method
[RequestWakeupLatency](http://msdn2.microsoft.com/en-us/library/aa373199) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.RequestWakeupLatency](https://github.com/dahall/Vanara/search?l=C%23&q=RequestWakeupLatency)
[ResetEvent](http://msdn2.microsoft.com/en-us/library/ms685081) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.ResetEvent](https://github.com/dahall/Vanara/search?l=C%23&q=ResetEvent)
[ResetWriteWatch](http://msdn2.microsoft.com/en-us/library/aa366874) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.ResetWriteWatch](https://github.com/dahall/Vanara/search?l=C%23&q=ResetWriteWatch)
[ResolveDelayLoadedAPI](https://www.google.com/search?num=5&q=ResolveDelayLoadedAPI+site%3Amicrosoft.com) | vertdll.dll | |
[ResolveLocaleName](http://msdn2.microsoft.com/en-us/library/dd319112) | kernel32.dll | Winnls.h | [Vanara.PInvoke.Kernel32.ResolveLocaleName](https://github.com/dahall/Vanara/search?l=C%23&q=ResolveLocaleName)
[RestoreLastError](https://www.google.com/search?num=5&q=RestoreLastError+site%3Amicrosoft.com) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.RestoreLastError](https://github.com/dahall/Vanara/search?l=C%23&q=RestoreLastError)
[ResumeThread](http://msdn2.microsoft.com/en-us/library/ms685086) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.ResumeThread](https://github.com/dahall/Vanara/search?l=C%23&q=ResumeThread)
[RtlAcquireResourceExclusive](https://www.google.com/search?num=5&q=RtlAcquireResourceExclusive+site%3Amicrosoft.com) | vertdll.dll | |
[RtlAcquireResourceShared](https://www.google.com/search?num=5&q=RtlAcquireResourceShared+site%3Amicrosoft.com) | vertdll.dll | |
[RtlAddFunctionTable](http://msdn2.microsoft.com/en-us/library/4717f29e-c5f8-4b02-a7c8-edd065f1c793) | kernel32.dll | rtlsupportapi.h | [Vanara.PInvoke.Kernel32.RtlAddFunctionTable](https://github.com/dahall/Vanara/search?l=C%23&q=RtlAddFunctionTable)
[RtlAllocateHeap](https://www.google.com/search?num=5&q=RtlAllocateHeap+site%3Amicrosoft.com) | vertdll.dll | |
[RtlAssert](https://www.google.com/search?num=5&q=RtlAssert+site%3Amicrosoft.com) | vertdll.dll | |
[RtlCallEnclaveReturn](https://www.google.com/search?num=5&q=RtlCallEnclaveReturn+site%3Amicrosoft.com) | vertdll.dll | |
[RtlCaptureContext](http://msdn2.microsoft.com/en-us/library/e2ce0cde-43ab-4681-be66-bd7509fd6ca2) | kernel32.dll | rtlsupportapi.h | [Vanara.PInvoke.Kernel32.RtlCaptureContext](https://github.com/dahall/Vanara/search?l=C%23&q=RtlCaptureContext)
[RtlCompareUnicodeString](https://www.google.com/search?num=5&q=RtlCompareUnicodeString+site%3Amicrosoft.com) | vertdll.dll | |
[RtlDeleteCriticalSection](https://www.google.com/search?num=5&q=RtlDeleteCriticalSection+site%3Amicrosoft.com) | vertdll.dll | |
[RtlDeleteFunctionTable](http://msdn2.microsoft.com/en-us/library/42bc3d83-8053-40e9-b153-f68733d0cb2b) | kernel32.dll | rtlsupportapi.h | [Vanara.PInvoke.Kernel32.RtlDeleteFunctionTable](https://github.com/dahall/Vanara/search?l=C%23&q=RtlDeleteFunctionTable)
[RtlDeleteResource](https://www.google.com/search?num=5&q=RtlDeleteResource+site%3Amicrosoft.com) | vertdll.dll | |
[RtlEnclaveCallDispatch](https://www.google.com/search?num=5&q=RtlEnclaveCallDispatch+site%3Amicrosoft.com) | vertdll.dll | |
[RtlEnclaveCallDispatchReturn](https://www.google.com/search?num=5&q=RtlEnclaveCallDispatchReturn+site%3Amicrosoft.com) | vertdll.dll | |
[RtlEnterCriticalSection](https://www.google.com/search?num=5&q=RtlEnterCriticalSection+site%3Amicrosoft.com) | vertdll.dll | |
[RtlFillMemory](http://msdn2.microsoft.com/en-us/library/aa366561) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.FillMemory](https://github.com/dahall/Vanara/search?l=C%23&q=FillMemory)
[RtlFreeHeap](https://www.google.com/search?num=5&q=RtlFreeHeap+site%3Amicrosoft.com) | vertdll.dll | |
[RtlGetCurrentProcessorNumberEx](https://www.google.com/search?num=5&q=RtlGetCurrentProcessorNumberEx+site%3Amicrosoft.com) | vertdll.dll | |
[RtlGetLastNtStatus](https://www.google.com/search?num=5&q=RtlGetLastNtStatus+site%3Amicrosoft.com) | vertdll.dll | |
[RtlImageNtHeader](https://www.google.com/search?num=5&q=RtlImageNtHeader+site%3Amicrosoft.com) | vertdll.dll | |
[RtlInitializeCriticalSection](https://www.google.com/search?num=5&q=RtlInitializeCriticalSection+site%3Amicrosoft.com) | vertdll.dll | |
[RtlInitializeResource](https://www.google.com/search?num=5&q=RtlInitializeResource+site%3Amicrosoft.com) | vertdll.dll | |
[RtlInitUnicodeString](https://www.google.com/search?num=5&q=RtlInitUnicodeString+site%3Amicrosoft.com) | vertdll.dll | |
[RtlInstallFunctionTableCallback](http://msdn2.microsoft.com/en-us/library/63b35b17-0b0e-46ed-9dbf-98290ab08bd1) | kernel32.dll | rtlsupportapi.h | [Vanara.PInvoke.Kernel32.RtlInstallFunctionTableCallback](https://github.com/dahall/Vanara/search?l=C%23&q=RtlInstallFunctionTableCallback)
[RtlLeaveCriticalSection](https://www.google.com/search?num=5&q=RtlLeaveCriticalSection+site%3Amicrosoft.com) | vertdll.dll | |
[RtlLookupFunctionEntry](http://msdn2.microsoft.com/en-us/library/624b97fb-0453-4f47-b6bd-92aa14705e78) | kernel32.dll | rtlsupportapi.h | [Vanara.PInvoke.Kernel32.RtlLookupFunctionEntry](https://github.com/dahall/Vanara/search?l=C%23&q=RtlLookupFunctionEntry)
[RtlMoveMemory](http://msdn2.microsoft.com/en-us/library/D374F14D-24C7-4771-AD40-3AC37E7A2D2F) | kernel32.dll | winnt.h | [Vanara.PInvoke.Kernel32.RtlMoveMemory](https://github.com/dahall/Vanara/search?l=C%23&q=RtlMoveMemory)
[RtlNtStatusToDosError](https://www.google.com/search?num=5&q=RtlNtStatusToDosError+site%3Amicrosoft.com) | vertdll.dll | |
[RtlPcToFileHeader](http://msdn2.microsoft.com/en-us/library/690c9f20-d471-49c9-a40c-28926f03acac) | kernel32.dll | rtlsupportapi.h | [Vanara.PInvoke.Kernel32.RtlPcToFileHeader](https://github.com/dahall/Vanara/search?l=C%23&q=RtlPcToFileHeader)
[RtlRaiseStatus](https://www.google.com/search?num=5&q=RtlRaiseStatus+site%3Amicrosoft.com) | vertdll.dll | |
[RtlReleaseResource](https://www.google.com/search?num=5&q=RtlReleaseResource+site%3Amicrosoft.com) | vertdll.dll | |
[RtlReleaseResourceShared](https://www.google.com/search?num=5&q=RtlReleaseResourceShared+site%3Amicrosoft.com) | vertdll.dll | |
[RtlRestoreContext](http://msdn2.microsoft.com/en-us/library/f5304d17-bc67-4e0f-a535-efca4e65c74c) | kernel32.dll | rtlsupportapi.h | [Vanara.PInvoke.Kernel32.RtlRestoreContext](https://github.com/dahall/Vanara/search?l=C%23&q=RtlRestoreContext)
[RtlUnhandledExceptionFilter](https://www.google.com/search?num=5&q=RtlUnhandledExceptionFilter+site%3Amicrosoft.com) | vertdll.dll | |
[RtlUnwind](http://msdn2.microsoft.com/en-us/library/254b2547-9d3d-468f-a360-20a12e9dd82e) | kernel32.dll | rtlsupportapi.h | [Vanara.PInvoke.Kernel32.RtlUnwind](https://github.com/dahall/Vanara/search?l=C%23&q=RtlUnwind)
[RtlUnwindEx](http://msdn2.microsoft.com/en-us/library/3d2d8778-311e-4cc1-b280-4f83ab457755) | kernel32.dll | rtlsupportapi.h | [Vanara.PInvoke.Kernel32.RtlUnwindEx](https://github.com/dahall/Vanara/search?l=C%23&q=RtlUnwindEx)
[RtlVirtualUnwind](https://www.google.com/search?num=5&q=RtlVirtualUnwind+site%3Amicrosoft.com) | vertdll.dll | |
[RtlZeroMemory](https://www.google.com/search?num=5&q=RtlZeroMemory+site%3Amicrosoft.com) | kernel32.dll | winnt.h | [Vanara.PInvoke.Kernel32.RtlZeroMemory](https://github.com/dahall/Vanara/search?l=C%23&q=RtlZeroMemory)
[ScrollConsoleScreenBuffer](https://www.google.com/search?num=5&q=ScrollConsoleScreenBufferA+site%3Amicrosoft.com) | kernel32.dll | Wincon.h | [Vanara.PInvoke.Kernel32.ScrollConsoleScreenBuffer](https://github.com/dahall/Vanara/search?l=C%23&q=ScrollConsoleScreenBuffer)
[SearchPath](http://msdn2.microsoft.com/en-us/library/aa365527) | kernel32.dll | WinBase.h | [Vanara.PInvoke.Kernel32.SearchPath](https://github.com/dahall/Vanara/search?l=C%23&q=SearchPath)
@ -1204,6 +1158,8 @@ Native Structure | Header | Managed Structure
[DYNAMIC_TIME_ZONE_INFORMATION](http://msdn2.microsoft.com/en-us/library/ms724253) | WinBase.h | [Vanara.PInvoke.Kernel32.DYNAMIC_TIME_ZONE_INFORMATION](https://github.com/dahall/Vanara/search?l=C%23&q=DYNAMIC_TIME_ZONE_INFORMATION)
[ENCLAVE_CREATE_INFO_SGX](http://msdn2.microsoft.com/en-us/library/mt592867) | Winnt.h | [Vanara.PInvoke.Kernel32.ENCLAVE_CREATE_INFO_SGX](https://github.com/dahall/Vanara/search?l=C%23&q=ENCLAVE_CREATE_INFO_SGX)
[ENCLAVE_CREATE_INFO_VBS](http://msdn2.microsoft.com/en-us/library/mt844238) | Winnt.h | [Vanara.PInvoke.Kernel32.ENCLAVE_CREATE_INFO_VBS](https://github.com/dahall/Vanara/search?l=C%23&q=ENCLAVE_CREATE_INFO_VBS)
[ENCLAVE_IDENTITY](http://msdn2.microsoft.com/en-us/library/D584D824-3C86-4BBB-9086-6DBE0290E0A4) | ntenclv.h | [Vanara.PInvoke.Kernel32.ENCLAVE_IDENTITY](https://github.com/dahall/Vanara/search?l=C%23&q=ENCLAVE_IDENTITY)
[ENCLAVE_INFORMATION](http://msdn2.microsoft.com/en-us/library/6720EDBE-6A0E-4192-A096-2ACA681E2AAF) | ntenclv.h | [Vanara.PInvoke.Kernel32.ENCLAVE_INFORMATION](https://github.com/dahall/Vanara/search?l=C%23&q=ENCLAVE_INFORMATION)
[ENCLAVE_INIT_INFO_SGX](http://msdn2.microsoft.com/en-us/library/mt592868) | Winnt.h | [Vanara.PInvoke.Kernel32.ENCLAVE_INIT_INFO_SGX](https://github.com/dahall/Vanara/search?l=C%23&q=ENCLAVE_INIT_INFO_SGX)
[ENCLAVE_INIT_INFO_VBS](http://msdn2.microsoft.com/en-us/library/mt844241) | Winnt.h | [Vanara.PInvoke.Kernel32.ENCLAVE_INIT_INFO_VBS](https://github.com/dahall/Vanara/search?l=C%23&q=ENCLAVE_INIT_INFO_VBS)
[ENUM_PAGE_FILE_INFORMATION](http://msdn2.microsoft.com/en-us/library/020f3be8-f624-4788-8079-0f7679c9bef0) | psapi.h | [Vanara.PInvoke.Kernel32.ENUM_PAGE_FILE_INFORMATION](https://github.com/dahall/Vanara/search?l=C%23&q=ENUM_PAGE_FILE_INFORMATION)

View File

@ -5,6 +5,18 @@ namespace Vanara.PInvoke
{
public static partial class Kernel32
{
/// <summary>Enclave constant.</summary>
public const int ENCLAVE_LONG_ID_LENGTH = 32;
/// <summary>Enclave constant.</summary>
public const int ENCLAVE_SHORT_ID_LENGTH = 16;
/// <summary>Enclave constant.</summary>
public const int IMAGE_ENCLAVE_LONG_ID_LENGTH = ENCLAVE_LONG_ID_LENGTH;
/// <summary>Enclave constant.</summary>
public const int IMAGE_ENCLAVE_SHORT_ID_LENGTH = ENCLAVE_SHORT_ID_LENGTH;
/// <summary>Used by the <see cref="CallEnclave"/> function.</summary>
/// <param name="lpThreadParameter">The thread parameter.</param>
/// <returns>The return thread parameter.</returns>
@ -12,6 +24,31 @@ namespace Vanara.PInvoke
[UnmanagedFunctionPointer(CallingConvention.StdCall)]
public delegate IntPtr PENCLAVE_ROUTINE(IntPtr lpThreadParameter);
/// <summary>
/// Specifies how another enclave must be related to the enclave that calls <c>EnclaveSealData</c> for the enclave to unseal the data.
/// </summary>
[PInvokeData("ntenclv.h")]
public enum ENCLAVE_SEALING_IDENTITY_POLICY
{
/// <summary/>
ENCLAVE_IDENTITY_POLICY_SEAL_INVALID = 0,
/// <summary/>
ENCLAVE_IDENTITY_POLICY_SEAL_EXACT_CODE,
/// <summary/>
ENCLAVE_IDENTITY_POLICY_SEAL_SAME_PRIMARY_CODE,
/// <summary/>
ENCLAVE_IDENTITY_POLICY_SEAL_SAME_IMAGE,
/// <summary/>
ENCLAVE_IDENTITY_POLICY_SEAL_SAME_FAMILY,
/// <summary/>
ENCLAVE_IDENTITY_POLICY_SEAL_SAME_AUTHOR,
}
/// <summary>A flag that indicates whether the enclave permits debugging.</summary>
public enum ENCLAVE_VBS_FLAG : uint
{
@ -247,6 +284,219 @@ namespace Vanara.PInvoke
[return: MarshalAs(UnmanagedType.Bool)]
public static extern bool DeleteEnclave(IntPtr lpAddress);
/// <summary>
/// Gets an enclave attestation report that describes the current enclave and is signed by the authority that is responsible for the
/// type of the enclave.
/// </summary>
/// <param name="EnclaveData">
/// A pointer to a 64-byte buffer of data that the enclave wants to insert into its signed report. For example, this buffer could
/// include a 256-bit nonce that the relying party supplied, followed by a SHA-256 hash of additional data that the enclave wants to
/// convey, such as a public key that corresponds to a private key that the enclave owns. If this parameter is NULL, the
/// corresponding field of the report is filled with zeroes.
/// </param>
/// <param name="Report">
/// A pointer to a buffer where the report should be placed. This report may be stored either within the address range of the enclave
/// or within the address space of the host process. Specify NULL to indicate that only the size of the buffer required for the
/// output should be calculated, and not the report itself.
/// </param>
/// <param name="BufferSize">
/// The size of the buffer to which the Report parameter points. If Report is NULL, BufferSize must be zero. If Report is not NULL,
/// and if the size of the report is larger than this value, an error is returned.
/// </param>
/// <param name="OutputSize">A pointer to a variable that receives the size of the report.</param>
/// <returns>If this function succeeds, it returns <c>S_OK</c>. Otherwise, it returns an <c>HRESULT</c> error code.</returns>
/// <remarks>
/// <para><c>EnclaveGetAttestationReport</c> must be called from within an enclave.</para>
/// <para>
/// <c>EnclaveGetAttestationReport</c> is not currently supported for enclaves with a type of <c>ENCLAVE_TYPE_SGX</c>. For VBS
/// enclaves, the report that <c>EnclaveGetAttestationReport</c> gets is signed by using a VBS-specific key.
/// </para>
/// <para>
/// The enclave attestation report contains the identity of all code loaded into the enclave, as well as policies that control how
/// the enclave is running, such as whether the enclave is running with debugger access active. The report also includes a small
/// amount of information that the enclave generated to use in a key-exchange protocol.
/// </para>
/// <para>The report that <c>EnclaveGetAttestationReport</c> generates consists of the following items:</para>
/// <list type="bullet">
/// <item>
/// <term>A VBS_ENCLAVE_REPORT_PKG_HEADER structure</term>
/// </item>
/// <item>
/// <term>A signed statement that consist of the following items:</term>
/// </item>
/// <item>
/// <term>A signature</term>
/// </item>
/// </list>
/// <para>
/// The enclave attestation report provide proof that specific code is running with an enclave. If a validating entity also obtains
/// proof that the host system is running with VBS turned on, that entity can use that proof in conjunction with the enclave
/// attestation report to verify that a specific enclave, populated with specific code, has been loaded.
/// </para>
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/winenclaveapi/nf-winenclaveapi-enclavegetattestationreport HRESULT
// EnclaveGetAttestationReport( const UINT8 [ENCLAVE_REPORT_DATA_LENGTH] EnclaveData, PVOID Report, UINT32 BufferSize, UINT32
// *OutputSize );
[DllImport(Lib.VertDll, SetLastError = false, ExactSpelling = true)]
[PInvokeData("winenclaveapi.h", MSDNShortId = "FEE8F05B-540F-4C10-A90C-55607A4E9293")]
public static extern HRESULT EnclaveGetAttestationReport(byte[] EnclaveData, IntPtr Report, uint BufferSize, out uint OutputSize);
/// <summary>Gets information about the currently executing enclave.</summary>
/// <param name="InformationSize">
/// The size of the ENCLAVE_INFORMATION structure that the EnclaveInformation parameter points to, in bytes.
/// </param>
/// <param name="EnclaveInformation">Information about the currently executing enclave.</param>
/// <returns>If this function succeeds, it returns <c>S_OK</c>. Otherwise, it returns an <c>HRESULT</c> error code.</returns>
/// <remarks>
/// <c>EnclaveGetEnclaveInformation</c> must be called from within an enclave, and is only supported within enclaves that have the
/// <c>ENCLAVE_TYPE_VBS</c> enclave type.
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/winenclaveapi/nf-winenclaveapi-enclavegetenclaveinformation HRESULT
// EnclaveGetEnclaveInformation( UINT32 InformationSize, ENCLAVE_INFORMATION *EnclaveInformation );
[DllImport(Lib.VertDll, SetLastError = false, ExactSpelling = true)]
[PInvokeData("winenclaveapi.h", MSDNShortId = "26349C3C-4B73-430C-B002-ED262DB0304F")]
public static extern HRESULT EnclaveGetEnclaveInformation(uint InformationSize, ref ENCLAVE_INFORMATION EnclaveInformation);
/// <summary>Generates an encrypted binary large object (blob) from unencypted data.</summary>
/// <param name="DataToEncrypt">
/// A pointer to the data that you want to seal. This data can be stored either within the address range of the enclave or within the
/// address range of the host process.
/// </param>
/// <param name="DataToEncryptSize">The size of the data that you want to seal, in bytes.</param>
/// <param name="IdentityPolicy">
/// A value that specifies how another enclave must be related to the enclave that calls <c>EnclaveSealData</c> for the enclave to
/// unseal the data.
/// </param>
/// <param name="RuntimePolicy">
/// <para>
/// A value that indicates whether an enclave that runs with debugging turned on is permitted to unseal the data the this call to
/// <c>EnclaveSealData</c> seals.
/// </para>
/// <list type="table">
/// <listheader>
/// <term>Value</term>
/// <term>Meaning</term>
/// </listheader>
/// <item>
/// <term>ENCLAVE_RUNTIME_POLICY_ALLOW_FULL_DEBUG 1</term>
/// <term>
/// If specified, indicates that an enclave that runs with debugging turned on is permitted to unseal the data. If not specified,
/// indicates that an enclave that runs with debugging turned on is not permitted to unseal the data. This flag is automatically
/// included if the calling enclave is running with debugging turned on.
/// </term>
/// </item>
/// <item>
/// <term>ENCLAVE_RUNTIME_POLICY_ALLOW_DYNAMIC_DEBUG 2</term>
/// <term>
/// If specified, indicates that an enclave that runs with dynamic debugging turned on is permitted to unseal the data. If not
/// specified, indicates that an enclave that runs with dynamic debugging turned on is not permitted to unseal the data. This flag is
/// automatically included if the calling enclave is running with dynamic debugging turned on
/// </term>
/// </item>
/// </list>
/// </param>
/// <param name="ProtectedBlob">
/// A pointer to a buffer where the sealed data should be placed. This data may be stored either within the address range of the
/// enclave or within the address space of the host process. If this parameter is NULL, only the size of the protected blob is calculated.
/// </param>
/// <param name="BufferSize">
/// A pointer to a variable that holds the size of the buffer to which the ProtectedBlob parameter points. If ProtectedBlob is NULL,
/// this value must be zero. If ProtectedBlob is not NULL, and if the size of the encrypted data is larger than this value, an error occurs.
/// </param>
/// <param name="ProtectedBlobSize">A pointer to a variable that receives the actual size of the encrypted blob.</param>
/// <returns>If this function succeeds, it returns <c>S_OK</c>. Otherwise, it returns an <c>HRESULT</c> error code.</returns>
/// <remarks>
/// <c>EnclaveSealData</c> must be called from within an enclave, and is only supported within enclaves that have the
/// <c>ENCLAVE_TYPE_VBS</c> enclave type.
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/winenclaveapi/nf-winenclaveapi-enclavesealdata HRESULT EnclaveSealData( const
// VOID *DataToEncrypt, UINT32 DataToEncryptSize, ENCLAVE_SEALING_IDENTITY_POLICY IdentityPolicy, UINT32 RuntimePolicy, PVOID
// ProtectedBlob, UINT32 BufferSize, UINT32 *ProtectedBlobSize );
[DllImport(Lib.VertDll, SetLastError = false, ExactSpelling = true)]
[PInvokeData("winenclaveapi.h", MSDNShortId = "C5711D43-F0B4-43C6-B0DB-D65622851384")]
public static extern HRESULT EnclaveSealData(IntPtr DataToEncrypt, uint DataToEncryptSize, ENCLAVE_SEALING_IDENTITY_POLICY IdentityPolicy, uint RuntimePolicy, IntPtr ProtectedBlob, uint BufferSize, out uint ProtectedBlobSize);
/// <summary>Decrypts an encrypted binary large object (blob).</summary>
/// <param name="ProtectedBlob">
/// A pointer to the sealed data to unseal. This data may be stored either within the address range of the enclave or within the
/// address space of the host process
/// </param>
/// <param name="ProtectedBlobSize">The size of the sealed data to unseal, in bytes.</param>
/// <param name="DecryptedData">
/// A pointer to a buffer where the unencrypted data should be placed. This data may be stored either within the address range of the
/// enclave or within the address space of the host process. If this parameter is NULL, only the size of the decrypted data is calculated.
/// </param>
/// <param name="BufferSize">
/// The size of the buffer to which the DecryptedData parameter points, in bytes. If DecryptedData is NULL, BufferSize must be zero.
/// If DecryptedData is not NULL, and if the size of the decrypted data is larger than this value, an error is returned.
/// </param>
/// <param name="DecryptedDataSize">A pointer to a variable that receives the actual size of the decrypted data, in bytes.</param>
/// <param name="SealingIdentity">
/// An optional pointer to a buffer that should be filled with the identity of the enclave that sealed the data. If this pointer is
/// NULL, the identity of the sealing enclave is not returned.
/// </param>
/// <param name="UnsealingFlags">
/// <para>
/// An optional pointer to a variable that receives zero or more of the following flags that describe the encrypted binary large object.
/// </para>
/// <list type="table">
/// <listheader>
/// <term>Value</term>
/// <term>Meaning</term>
/// </listheader>
/// <item>
/// <term>ENCLAVE_UNSEAL_FLAG_STALE_KEY 1</term>
/// <term>
/// The data was encrypted with a stale key. Sealing keys are rotated when required for security, and the system can only maintain a
/// fixed number of recently known keys. An enclave that determines that data was encrypted with a stale key should reencrypt the
/// data with a current key to minimize the chances that the key used to encrypt the data is no longer maintained in the key list.
/// </term>
/// </item>
/// </list>
/// </param>
/// <returns>If this function succeeds, it returns <c>S_OK</c>. Otherwise, it returns an <c>HRESULT</c> error code.</returns>
/// <remarks>
/// <para>
/// The enclave that calls <c>EnclaveUnsealData</c> must meet the criteria that correspond to the value of the
/// ENCLAVE_SEALING_IDENTITY_POLICY that was specified by the enclave that sealed the data by calling EnclaveSealData.
/// </para>
/// <para>
/// <c>EnclaveUnsealData</c> must be called from within an enclave, and is only supported within enclaves that have the
/// <c>ENCLAVE_TYPE_VBS</c> enclave type.
/// </para>
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/winenclaveapi/nf-winenclaveapi-enclaveunsealdata HRESULT EnclaveUnsealData(
// const VOID *ProtectedBlob, UINT32 ProtectedBlobSize, PVOID DecryptedData, UINT32 BufferSize, UINT32 *DecryptedDataSize,
// ENCLAVE_IDENTITY *SealingIdentity, UINT32 *UnsealingFlags );
[DllImport(Lib.VertDll, SetLastError = false, ExactSpelling = true)]
[PInvokeData("winenclaveapi.h", MSDNShortId = "DDBDBEDE-E7EA-43B0-B2C7-B85D75EF3EB0")]
public static extern HRESULT EnclaveUnsealData(IntPtr ProtectedBlob, uint ProtectedBlobSize, IntPtr DecryptedData, uint BufferSize, out uint DecryptedDataSize, out ENCLAVE_IDENTITY SealingIdentity, out uint UnsealingFlags);
/// <summary>Verifies an attestation report that was generated on the current system.</summary>
/// <param name="EnclaveType">The type of the enclave for which the report was generated. Must be <c>ENCLAVE_TYPE_VBS</c>.</param>
/// <param name="Report">
/// A pointer to a buffer that stores the report. This report may be stored either within the address range of the enclave or within
/// the address space of the host process.
/// </param>
/// <param name="ReportSize">The size of the report, in bytes.</param>
/// <returns>If this function succeeds, it returns <c>S_OK</c>. Otherwise, it returns an <c>HRESULT</c> error code.</returns>
/// <remarks>
/// <para>
/// This function is used if two enclaves run on the same system and need to establish a secure channel between one another. When you
/// call <c>EnclaveVerifyAttestationReport</c> from a virtualization-based security (VBS) enclave, you can only use
/// <c>EnclaveVerifyAttestationReport</c> to validate an attestation report that another VBS enclave generated.
/// </para>
/// <para>
/// <c>EnclaveVerifyAttestationReport</c> must be called from within an enclave, and is only supported within enclaves that have the
/// <c>ENCLAVE_TYPE_VBS</c> enclave type.
/// </para>
/// </remarks>
// https://docs.microsoft.com/en-us/windows/win32/api/winenclaveapi/nf-winenclaveapi-enclaveverifyattestationreport HRESULT
// EnclaveVerifyAttestationReport( UINT32 EnclaveType, const VOID *Report, UINT32 ReportSize );
[DllImport(Lib.VertDll, SetLastError = false, ExactSpelling = true)]
[PInvokeData("winenclaveapi.h", MSDNShortId = "D74F89FB-9F06-4AA1-9E2E-C9265B3C5B44")]
public static extern HRESULT EnclaveVerifyAttestationReport(uint EnclaveType, IntPtr Report, uint ReportSize);
/// <summary>Initializes an enclave that you created and loaded with data.</summary>
/// <param name="hProcess">A handle to the process for which the enclave was created.</param>
/// <param name="lpAddress">Any address within the enclave.</param>
@ -561,6 +811,113 @@ namespace Vanara.PInvoke
public byte[] OwnerID;
}
/// <summary>Describes the identity of the primary module of an enclave.</summary>
// https://docs.microsoft.com/en-us/windows/win32/api/ntenclv/ns-ntenclv-enclave_identity typedef struct ENCLAVE_IDENTITY { UINT8
// OwnerId[IMAGE_ENCLAVE_LONG_ID_LENGTH]; UINT8 UniqueId[IMAGE_ENCLAVE_LONG_ID_LENGTH]; UINT8 AuthorId[IMAGE_ENCLAVE_LONG_ID_LENGTH];
// UINT8 FamilyId[IMAGE_ENCLAVE_SHORT_ID_LENGTH]; UINT8 ImageId[IMAGE_ENCLAVE_SHORT_ID_LENGTH]; UINT32 EnclaveSvn; UINT32
// SecureKernelSvn; UINT32 PlatformSvn; UINT32 Flags; UINT32 SigningLevel; UINT32 EnclaveType; } ENCLAVE_IDENTITY;
[PInvokeData("ntenclv.h", MSDNShortId = "D584D824-3C86-4BBB-9086-6DBE0290E0A4")]
[StructLayout(LayoutKind.Sequential)]
public struct ENCLAVE_IDENTITY
{
/// <summary>The identifier of the owner for the enclave.</summary>
[MarshalAs(UnmanagedType.ByValArray, SizeConst = IMAGE_ENCLAVE_LONG_ID_LENGTH)]
public byte[] OwnerId;
/// <summary>The unique identifier of the primary module for the enclave.</summary>
[MarshalAs(UnmanagedType.ByValArray, SizeConst = IMAGE_ENCLAVE_LONG_ID_LENGTH)]
public byte[] UniqueId;
/// <summary>The author identifier of the primary module for the enclave.</summary>
[MarshalAs(UnmanagedType.ByValArray, SizeConst = IMAGE_ENCLAVE_LONG_ID_LENGTH)]
public byte[] AuthorId;
/// <summary>The family identifier of the primary module for the enclave.</summary>
[MarshalAs(UnmanagedType.ByValArray, SizeConst = IMAGE_ENCLAVE_SHORT_ID_LENGTH)]
public byte[] FamilyId;
/// <summary>The image identifier of the primary module for the enclave.</summary>
[MarshalAs(UnmanagedType.ByValArray, SizeConst = IMAGE_ENCLAVE_SHORT_ID_LENGTH)]
public byte[] ImageId;
/// <summary>The security version number of the primary module for the enclave.</summary>
public uint EnclaveSvn;
/// <summary>The security version number of the Virtual Secure Mode (VSM) kernel.</summary>
public uint SecureKernelSvn;
/// <summary>The security version number of the platform that hosts the enclave.</summary>
public uint PlatformSvn;
/// <summary>
/// <para>Flags that describe the runtime policy for the enclave.</para>
/// <list type="table">
/// <listheader>
/// <term>Value</term>
/// <term>Meaning</term>
/// </listheader>
/// <item>
/// <term>ENCLAVE_FLAG_FULL_DEBUG_ENABLED 0x00000001</term>
/// <term>The enclave supports debugging.</term>
/// </item>
/// <item>
/// <term>ENCLAVE_FLAG_DYNAMIC_DEBUG_ENABLED 0x00000002</term>
/// <term>The enclave supports dynamic debugging.</term>
/// </item>
/// <item>
/// <term>ENCLAVE_FLAG_DYNAMIC_DEBUG_ACTIVE 0x00000004</term>
/// <term>Dynamic debugging is turned on for the enclave.</term>
/// </item>
/// </list>
/// </summary>
public uint Flags;
/// <summary>The signing level of the primary module for the enclave.</summary>
public uint SigningLevel;
/// <summary/>
public uint EnclaveType;
}
/// <summary>Contains information about the currently executing enclave.</summary>
// https://docs.microsoft.com/en-us/windows/win32/api/ntenclv/ns-ntenclv-enclave_information typedef struct ENCLAVE_INFORMATION {
// ULONG EnclaveType; ULONG Reserved; PVOID BaseAddress; SIZE_T Size; ENCLAVE_IDENTITY Identity; } ENCLAVE_INFORMATION;
[PInvokeData("ntenclv.h", MSDNShortId = "6720EDBE-6A0E-4192-A096-2ACA681E2AAF")]
[StructLayout(LayoutKind.Sequential)]
public struct ENCLAVE_INFORMATION
{
/// <summary>
/// <para>The architecture type of the enclave.</para>
/// <list type="table">
/// <listheader>
/// <term>Value</term>
/// <term>Meaning</term>
/// </listheader>
/// <item>
/// <term>ENCLAVE_TYPE_SGX 0x00000001</term>
/// <term>An enclave for the Intel Software Guard Extensions (SGX) architecture extension.</term>
/// </item>
/// <item>
/// <term>ENCLAVE_TYPE_VBS 0x00000010</term>
/// <term>A VBS enclave.</term>
/// </item>
/// </list>
/// </summary>
public uint EnclaveType;
/// <summary>Reserved.</summary>
public uint Reserved;
/// <summary>A pointer to the base address of the enclave.</summary>
public IntPtr BaseAddress;
/// <summary>The size of the enclave, in bytes.</summary>
public SizeT Size;
/// <summary>The identity of the primary module of an enclave.</summary>
public ENCLAVE_IDENTITY Identity;
}
/// <summary>
/// Contains architecture-specific information to use to initialize an enclave when the enclave type is <c>ENCLAVE_TYPE_SGX</c>,
/// which specifies an enclave for the Intel Software Guard Extensions (SGX) architecture extension.

File diff suppressed because one or more lines are too long