mirror of
https://github.com/hakril/PythonForWindows
synced 2026-06-08 14:31:45 +00:00
Added some ctypes definitions
This commit is contained in:
@@ -365,3 +365,13 @@ BOOL WINAPI CryptMsgVerifyCountersignatureEncodedEx(
|
||||
_Reserved_ DWORD dwFlags,
|
||||
_Reserved_ PVOID pvExtra
|
||||
);
|
||||
|
||||
BOOL WINAPI CryptHashCertificate(
|
||||
_In_ HCRYPTPROV_LEGACY hCryptProv,
|
||||
_In_ ALG_ID Algid,
|
||||
_In_ DWORD dwFlags,
|
||||
_In_ BYTE *pbEncoded,
|
||||
_In_ DWORD cbEncoded,
|
||||
_Out_ BYTE *pbComputedHash,
|
||||
_Inout_ DWORD *pcbComputedHash
|
||||
);
|
||||
@@ -1143,6 +1143,11 @@ typedef struct _IMAGE_EXPORT_DIRECTORY {
|
||||
DWORD AddressOfNameOrdinals;
|
||||
} IMAGE_EXPORT_DIRECTORY, *PIMAGE_EXPORT_DIRECTORY;
|
||||
|
||||
typedef struct _IMAGE_BASE_RELOCATION {
|
||||
DWORD VirtualAddress;
|
||||
DWORD SizeOfBlock;
|
||||
} IMAGE_BASE_RELOCATION, *PIMAGE_BASE_RELOCATION;
|
||||
|
||||
typedef struct _MEMORY_BASIC_INFORMATION {
|
||||
PVOID BaseAddress;
|
||||
PVOID AllocationBase;
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1551,6 +1551,43 @@ CERT_SYSTEM_STORE_USERS = make_flag("CERT_SYSTEM_STORE_USERS", ( CERT_SYSTEM_STO
|
||||
CERT_SYSTEM_STORE_CURRENT_USER_GROUP_POLICY = make_flag("CERT_SYSTEM_STORE_CURRENT_USER_GROUP_POLICY", ( CERT_SYSTEM_STORE_CURRENT_USER_GROUP_POLICY_ID << CERT_SYSTEM_STORE_LOCATION_SHIFT ))
|
||||
CERT_SYSTEM_STORE_LOCAL_MACHINE_GROUP_POLICY = make_flag("CERT_SYSTEM_STORE_LOCAL_MACHINE_GROUP_POLICY", ( CERT_SYSTEM_STORE_LOCAL_MACHINE_GROUP_POLICY_ID << CERT_SYSTEM_STORE_LOCATION_SHIFT ))
|
||||
CERT_SYSTEM_STORE_LOCAL_MACHINE_ENTERPRISE = make_flag("CERT_SYSTEM_STORE_LOCAL_MACHINE_ENTERPRISE", ( CERT_SYSTEM_STORE_LOCAL_MACHINE_ENTERPRISE_ID << CERT_SYSTEM_STORE_LOCATION_SHIFT ))
|
||||
IMAGE_DLLCHARACTERISTICS_HIGH_ENTROPY_VA = make_flag("IMAGE_DLLCHARACTERISTICS_HIGH_ENTROPY_VA", 0x0020)
|
||||
IMAGE_DLLCHARACTERISTICS_DYNAMIC_BASE = make_flag("IMAGE_DLLCHARACTERISTICS_DYNAMIC_BASE", 0x0040)
|
||||
IMAGE_DLLCHARACTERISTICS_FORCE_INTEGRITY = make_flag("IMAGE_DLLCHARACTERISTICS_FORCE_INTEGRITY", 0x0080)
|
||||
IMAGE_DLLCHARACTERISTICS_NX_COMPAT = make_flag("IMAGE_DLLCHARACTERISTICS_NX_COMPAT", 0x0100)
|
||||
IMAGE_DLLCHARACTERISTICS_NO_ISOLATION = make_flag("IMAGE_DLLCHARACTERISTICS_NO_ISOLATION", 0x0200)
|
||||
IMAGE_DLLCHARACTERISTICS_NO_SEH = make_flag("IMAGE_DLLCHARACTERISTICS_NO_SEH", 0x0400)
|
||||
IMAGE_DLLCHARACTERISTICS_NO_BIND = make_flag("IMAGE_DLLCHARACTERISTICS_NO_BIND", 0x0800)
|
||||
IMAGE_DLLCHARACTERISTICS_APPCONTAINER = make_flag("IMAGE_DLLCHARACTERISTICS_APPCONTAINER", 0x1000)
|
||||
IMAGE_DLLCHARACTERISTICS_WDM_DRIVER = make_flag("IMAGE_DLLCHARACTERISTICS_WDM_DRIVER", 0x2000)
|
||||
IMAGE_DLLCHARACTERISTICS_GUARD_CF = make_flag("IMAGE_DLLCHARACTERISTICS_GUARD_CF", 0x4000)
|
||||
IMAGE_DLLCHARACTERISTICS_TERMINAL_SERVER_AWARE = make_flag("IMAGE_DLLCHARACTERISTICS_TERMINAL_SERVER_AWARE", 0x8000)
|
||||
IMAGE_DIRECTORY_ENTRY_EXPORT = make_flag("IMAGE_DIRECTORY_ENTRY_EXPORT", 0)
|
||||
IMAGE_DIRECTORY_ENTRY_IMPORT = make_flag("IMAGE_DIRECTORY_ENTRY_IMPORT", 1)
|
||||
IMAGE_DIRECTORY_ENTRY_RESOURCE = make_flag("IMAGE_DIRECTORY_ENTRY_RESOURCE", 2)
|
||||
IMAGE_DIRECTORY_ENTRY_EXCEPTION = make_flag("IMAGE_DIRECTORY_ENTRY_EXCEPTION", 3)
|
||||
IMAGE_DIRECTORY_ENTRY_SECURITY = make_flag("IMAGE_DIRECTORY_ENTRY_SECURITY", 4)
|
||||
IMAGE_DIRECTORY_ENTRY_BASERELOC = make_flag("IMAGE_DIRECTORY_ENTRY_BASERELOC", 5)
|
||||
IMAGE_DIRECTORY_ENTRY_DEBUG = make_flag("IMAGE_DIRECTORY_ENTRY_DEBUG", 6)
|
||||
IMAGE_DIRECTORY_ENTRY_ARCHITECTURE = make_flag("IMAGE_DIRECTORY_ENTRY_ARCHITECTURE", 7)
|
||||
IMAGE_DIRECTORY_ENTRY_GLOBALPTR = make_flag("IMAGE_DIRECTORY_ENTRY_GLOBALPTR", 8)
|
||||
IMAGE_DIRECTORY_ENTRY_TLS = make_flag("IMAGE_DIRECTORY_ENTRY_TLS", 9)
|
||||
IMAGE_DIRECTORY_ENTRY_LOAD_CONFIG = make_flag("IMAGE_DIRECTORY_ENTRY_LOAD_CONFIG", 10)
|
||||
IMAGE_DIRECTORY_ENTRY_BOUND_IMPORT = make_flag("IMAGE_DIRECTORY_ENTRY_BOUND_IMPORT", 11)
|
||||
IMAGE_DIRECTORY_ENTRY_IAT = make_flag("IMAGE_DIRECTORY_ENTRY_IAT", 12)
|
||||
IMAGE_DIRECTORY_ENTRY_DELAY_IMPORT = make_flag("IMAGE_DIRECTORY_ENTRY_DELAY_IMPORT", 13)
|
||||
IMAGE_DIRECTORY_ENTRY_COM_DESCRIPTOR = make_flag("IMAGE_DIRECTORY_ENTRY_COM_DESCRIPTOR", 14)
|
||||
IMAGE_REL_BASED_ABSOLUTE = make_flag("IMAGE_REL_BASED_ABSOLUTE", 0)
|
||||
IMAGE_REL_BASED_HIGH = make_flag("IMAGE_REL_BASED_HIGH", 1)
|
||||
IMAGE_REL_BASED_LOW = make_flag("IMAGE_REL_BASED_LOW", 2)
|
||||
IMAGE_REL_BASED_HIGHLOW = make_flag("IMAGE_REL_BASED_HIGHLOW", 3)
|
||||
IMAGE_REL_BASED_HIGHADJ = make_flag("IMAGE_REL_BASED_HIGHADJ", 4)
|
||||
IMAGE_REL_BASED_MACHINE_SPECIFIC_5 = make_flag("IMAGE_REL_BASED_MACHINE_SPECIFIC_5", 5)
|
||||
IMAGE_REL_BASED_RESERVED = make_flag("IMAGE_REL_BASED_RESERVED", 6)
|
||||
IMAGE_REL_BASED_MACHINE_SPECIFIC_7 = make_flag("IMAGE_REL_BASED_MACHINE_SPECIFIC_7", 7)
|
||||
IMAGE_REL_BASED_MACHINE_SPECIFIC_8 = make_flag("IMAGE_REL_BASED_MACHINE_SPECIFIC_8", 8)
|
||||
IMAGE_REL_BASED_MACHINE_SPECIFIC_9 = make_flag("IMAGE_REL_BASED_MACHINE_SPECIFIC_9", 9)
|
||||
IMAGE_REL_BASED_DIR64 = make_flag("IMAGE_REL_BASED_DIR64", 10)
|
||||
ERROR_SUCCESS = make_flag("ERROR_SUCCESS", 0)
|
||||
ERROR_INVALID_FUNCTION = make_flag("ERROR_INVALID_FUNCTION", 1)
|
||||
ERROR_FILE_NOT_FOUND = make_flag("ERROR_FILE_NOT_FOUND", 2)
|
||||
|
||||
+185
-180
@@ -29,166 +29,6 @@ RollbackTransactionParams = ((1, 'TransactionHandle'),)
|
||||
OpenTransactionPrototype = WINFUNCTYPE(HANDLE, DWORD, LPGUID)
|
||||
OpenTransactionParams = ((1, 'dwDesiredAccess'), (1, 'TransactionId'))
|
||||
|
||||
#def OpenEventLogA(lpUNCServerName, lpSourceName):
|
||||
# return OpenEventLogA.ctypes_function(lpUNCServerName, lpSourceName)
|
||||
OpenEventLogAPrototype = WINFUNCTYPE(HANDLE, LPCSTR, LPCSTR)
|
||||
OpenEventLogAParams = ((1, 'lpUNCServerName'), (1, 'lpSourceName'))
|
||||
|
||||
#def OpenEventLogW(lpUNCServerName, lpSourceName):
|
||||
# return OpenEventLogW.ctypes_function(lpUNCServerName, lpSourceName)
|
||||
OpenEventLogWPrototype = WINFUNCTYPE(HANDLE, LPWSTR, LPWSTR)
|
||||
OpenEventLogWParams = ((1, 'lpUNCServerName'), (1, 'lpSourceName'))
|
||||
|
||||
#def ReadEventLogA(hEventLog, dwReadFlags, dwRecordOffset, lpBuffer, nNumberOfBytesToRead, pnBytesRead, pnMinNumberOfBytesNeeded):
|
||||
# return ReadEventLogA.ctypes_function(hEventLog, dwReadFlags, dwRecordOffset, lpBuffer, nNumberOfBytesToRead, pnBytesRead, pnMinNumberOfBytesNeeded)
|
||||
ReadEventLogAPrototype = WINFUNCTYPE(BOOL, HANDLE, DWORD, DWORD, LPVOID, DWORD, POINTER(DWORD), POINTER(DWORD))
|
||||
ReadEventLogAParams = ((1, 'hEventLog'), (1, 'dwReadFlags'), (1, 'dwRecordOffset'), (1, 'lpBuffer'), (1, 'nNumberOfBytesToRead'), (1, 'pnBytesRead'), (1, 'pnMinNumberOfBytesNeeded'))
|
||||
|
||||
#def ReadEventLogW(hEventLog, dwReadFlags, dwRecordOffset, lpBuffer, nNumberOfBytesToRead, pnBytesRead, pnMinNumberOfBytesNeeded):
|
||||
# return ReadEventLogW.ctypes_function(hEventLog, dwReadFlags, dwRecordOffset, lpBuffer, nNumberOfBytesToRead, pnBytesRead, pnMinNumberOfBytesNeeded)
|
||||
ReadEventLogWPrototype = WINFUNCTYPE(BOOL, HANDLE, DWORD, DWORD, LPVOID, DWORD, POINTER(DWORD), POINTER(DWORD))
|
||||
ReadEventLogWParams = ((1, 'hEventLog'), (1, 'dwReadFlags'), (1, 'dwRecordOffset'), (1, 'lpBuffer'), (1, 'nNumberOfBytesToRead'), (1, 'pnBytesRead'), (1, 'pnMinNumberOfBytesNeeded'))
|
||||
|
||||
#def GetEventLogInformation(hEventLog, dwInfoLevel, lpBuffer, cbBufSize, pcbBytesNeeded):
|
||||
# return GetEventLogInformation.ctypes_function(hEventLog, dwInfoLevel, lpBuffer, cbBufSize, pcbBytesNeeded)
|
||||
GetEventLogInformationPrototype = WINFUNCTYPE(BOOL, HANDLE, DWORD, LPVOID, DWORD, LPDWORD)
|
||||
GetEventLogInformationParams = ((1, 'hEventLog'), (1, 'dwInfoLevel'), (1, 'lpBuffer'), (1, 'cbBufSize'), (1, 'pcbBytesNeeded'))
|
||||
|
||||
#def GetNumberOfEventLogRecords(hEventLog, NumberOfRecords):
|
||||
# return GetNumberOfEventLogRecords.ctypes_function(hEventLog, NumberOfRecords)
|
||||
GetNumberOfEventLogRecordsPrototype = WINFUNCTYPE(BOOL, HANDLE, PDWORD)
|
||||
GetNumberOfEventLogRecordsParams = ((1, 'hEventLog'), (1, 'NumberOfRecords'))
|
||||
|
||||
#def CloseEventLog(hEventLog):
|
||||
# return CloseEventLog.ctypes_function(hEventLog)
|
||||
CloseEventLogPrototype = WINFUNCTYPE(BOOL, HANDLE)
|
||||
CloseEventLogParams = ((1, 'hEventLog'),)
|
||||
|
||||
#def GetCursorPos(lpPoint):
|
||||
# return GetCursorPos.ctypes_function(lpPoint)
|
||||
GetCursorPosPrototype = WINFUNCTYPE(BOOL, LPPOINT)
|
||||
GetCursorPosParams = ((1, 'lpPoint'),)
|
||||
|
||||
#def WindowFromPoint(Point):
|
||||
# return WindowFromPoint.ctypes_function(Point)
|
||||
WindowFromPointPrototype = WINFUNCTYPE(HWND, POINT)
|
||||
WindowFromPointParams = ((1, 'Point'),)
|
||||
|
||||
#def GetWindowRect(hWnd, lpRect):
|
||||
# return GetWindowRect.ctypes_function(hWnd, lpRect)
|
||||
GetWindowRectPrototype = WINFUNCTYPE(BOOL, HWND, LPRECT)
|
||||
GetWindowRectParams = ((1, 'hWnd'), (1, 'lpRect'))
|
||||
|
||||
#def EnumWindows(lpEnumFunc, lParam):
|
||||
# return EnumWindows.ctypes_function(lpEnumFunc, lParam)
|
||||
EnumWindowsPrototype = WINFUNCTYPE(BOOL, WNDENUMPROC, LPARAM)
|
||||
EnumWindowsParams = ((1, 'lpEnumFunc'), (1, 'lParam'))
|
||||
|
||||
#def GetWindowTextA(hWnd, lpString, nMaxCount):
|
||||
# return GetWindowTextA.ctypes_function(hWnd, lpString, nMaxCount)
|
||||
GetWindowTextAPrototype = WINFUNCTYPE(INT, HWND, LPSTR, INT)
|
||||
GetWindowTextAParams = ((1, 'hWnd'), (1, 'lpString'), (1, 'nMaxCount'))
|
||||
|
||||
#def GetParent(hWnd):
|
||||
# return GetParent.ctypes_function(hWnd)
|
||||
GetParentPrototype = WINFUNCTYPE(HWND, HWND)
|
||||
GetParentParams = ((1, 'hWnd'),)
|
||||
|
||||
#def GetWindowTextW(hWnd, lpString, nMaxCount):
|
||||
# return GetWindowTextW.ctypes_function(hWnd, lpString, nMaxCount)
|
||||
GetWindowTextWPrototype = WINFUNCTYPE(INT, HWND, LPWSTR, INT)
|
||||
GetWindowTextWParams = ((1, 'hWnd'), (1, 'lpString'), (1, 'nMaxCount'))
|
||||
|
||||
#def GetWindowModuleFileNameA(hwnd, pszFileName, cchFileNameMax):
|
||||
# return GetWindowModuleFileNameA.ctypes_function(hwnd, pszFileName, cchFileNameMax)
|
||||
GetWindowModuleFileNameAPrototype = WINFUNCTYPE(UINT, HWND, LPSTR, UINT)
|
||||
GetWindowModuleFileNameAParams = ((1, 'hwnd'), (1, 'pszFileName'), (1, 'cchFileNameMax'))
|
||||
|
||||
#def GetWindowModuleFileNameW(hwnd, pszFileName, cchFileNameMax):
|
||||
# return GetWindowModuleFileNameW.ctypes_function(hwnd, pszFileName, cchFileNameMax)
|
||||
GetWindowModuleFileNameWPrototype = WINFUNCTYPE(UINT, HWND, LPWSTR, UINT)
|
||||
GetWindowModuleFileNameWParams = ((1, 'hwnd'), (1, 'pszFileName'), (1, 'cchFileNameMax'))
|
||||
|
||||
#def EnumChildWindows(hWndParent, lpEnumFunc, lParam):
|
||||
# return EnumChildWindows.ctypes_function(hWndParent, lpEnumFunc, lParam)
|
||||
EnumChildWindowsPrototype = WINFUNCTYPE(BOOL, HWND, WNDENUMPROC, LPARAM)
|
||||
EnumChildWindowsParams = ((1, 'hWndParent'), (1, 'lpEnumFunc'), (1, 'lParam'))
|
||||
|
||||
#def CloseWindow(hWnd):
|
||||
# return CloseWindow.ctypes_function(hWnd)
|
||||
CloseWindowPrototype = WINFUNCTYPE(BOOL, HWND)
|
||||
CloseWindowParams = ((1, 'hWnd'),)
|
||||
|
||||
#def GetDesktopWindow():
|
||||
# return GetDesktopWindow.ctypes_function()
|
||||
GetDesktopWindowPrototype = WINFUNCTYPE(HWND)
|
||||
GetDesktopWindowParams = ()
|
||||
|
||||
#def GetForegroundWindow():
|
||||
# return GetForegroundWindow.ctypes_function()
|
||||
GetForegroundWindowPrototype = WINFUNCTYPE(HWND)
|
||||
GetForegroundWindowParams = ()
|
||||
|
||||
#def BringWindowToTop(hWnd):
|
||||
# return BringWindowToTop.ctypes_function(hWnd)
|
||||
BringWindowToTopPrototype = WINFUNCTYPE(BOOL, HWND)
|
||||
BringWindowToTopParams = ((1, 'hWnd'),)
|
||||
|
||||
#def MoveWindow(hWnd, X, Y, nWidth, nHeight, bRepaint):
|
||||
# return MoveWindow.ctypes_function(hWnd, X, Y, nWidth, nHeight, bRepaint)
|
||||
MoveWindowPrototype = WINFUNCTYPE(BOOL, HWND, INT, INT, INT, INT, BOOL)
|
||||
MoveWindowParams = ((1, 'hWnd'), (1, 'X'), (1, 'Y'), (1, 'nWidth'), (1, 'nHeight'), (1, 'bRepaint'))
|
||||
|
||||
#def SetWindowPos(hWnd, hWndInsertAfter, X, Y, cx, cy, uFlags):
|
||||
# return SetWindowPos.ctypes_function(hWnd, hWndInsertAfter, X, Y, cx, cy, uFlags)
|
||||
SetWindowPosPrototype = WINFUNCTYPE(BOOL, HWND, HWND, INT, INT, INT, INT, UINT)
|
||||
SetWindowPosParams = ((1, 'hWnd'), (1, 'hWndInsertAfter'), (1, 'X'), (1, 'Y'), (1, 'cx'), (1, 'cy'), (1, 'uFlags'))
|
||||
|
||||
#def SetWindowTextA(hWnd, lpString):
|
||||
# return SetWindowTextA.ctypes_function(hWnd, lpString)
|
||||
SetWindowTextAPrototype = WINFUNCTYPE(BOOL, HWND, LPCSTR)
|
||||
SetWindowTextAParams = ((1, 'hWnd'), (1, 'lpString'))
|
||||
|
||||
#def SetWindowTextW(hWnd, lpString):
|
||||
# return SetWindowTextW.ctypes_function(hWnd, lpString)
|
||||
SetWindowTextWPrototype = WINFUNCTYPE(BOOL, HWND, LPWSTR)
|
||||
SetWindowTextWParams = ((1, 'hWnd'), (1, 'lpString'))
|
||||
|
||||
#def RealGetWindowClassA(hwnd, pszType, cchType):
|
||||
# return RealGetWindowClassA.ctypes_function(hwnd, pszType, cchType)
|
||||
RealGetWindowClassAPrototype = WINFUNCTYPE(UINT, HWND, LPCSTR, UINT)
|
||||
RealGetWindowClassAParams = ((1, 'hwnd'), (1, 'pszType'), (1, 'cchType'))
|
||||
|
||||
#def RealGetWindowClassW(hwnd, pszType, cchType):
|
||||
# return RealGetWindowClassW.ctypes_function(hwnd, pszType, cchType)
|
||||
RealGetWindowClassWPrototype = WINFUNCTYPE(UINT, HWND, LPWSTR, UINT)
|
||||
RealGetWindowClassWParams = ((1, 'hwnd'), (1, 'pszType'), (1, 'cchType'))
|
||||
|
||||
#def GetClassInfoExA(hinst, lpszClass, lpwcx):
|
||||
# return GetClassInfoExA.ctypes_function(hinst, lpszClass, lpwcx)
|
||||
GetClassInfoExAPrototype = WINFUNCTYPE(BOOL, HINSTANCE, LPCSTR, LPWNDCLASSEXA)
|
||||
GetClassInfoExAParams = ((1, 'hinst'), (1, 'lpszClass'), (1, 'lpwcx'))
|
||||
|
||||
#def GetClassInfoExW(hinst, lpszClass, lpwcx):
|
||||
# return GetClassInfoExW.ctypes_function(hinst, lpszClass, lpwcx)
|
||||
GetClassInfoExWPrototype = WINFUNCTYPE(BOOL, HINSTANCE, LPCWSTR, LPWNDCLASSEXW)
|
||||
GetClassInfoExWParams = ((1, 'hinst'), (1, 'lpszClass'), (1, 'lpwcx'))
|
||||
|
||||
#def GetClassNameA(hWnd, lpClassName, nMaxCount):
|
||||
# return GetClassNameA.ctypes_function(hWnd, lpClassName, nMaxCount)
|
||||
GetClassNameAPrototype = WINFUNCTYPE(INT, HWND, LPCSTR, INT)
|
||||
GetClassNameAParams = ((1, 'hWnd'), (1, 'lpClassName'), (1, 'nMaxCount'))
|
||||
|
||||
#def GetClassNameW(hWnd, lpClassName, nMaxCount):
|
||||
# return GetClassNameW.ctypes_function(hWnd, lpClassName, nMaxCount)
|
||||
GetClassNameWPrototype = WINFUNCTYPE(INT, HWND, LPWSTR, INT)
|
||||
GetClassNameWParams = ((1, 'hWnd'), (1, 'lpClassName'), (1, 'nMaxCount'))
|
||||
|
||||
#def GetWindowThreadProcessId(hWnd, lpdwProcessId):
|
||||
# return GetWindowThreadProcessId.ctypes_function(hWnd, lpdwProcessId)
|
||||
GetWindowThreadProcessIdPrototype = WINFUNCTYPE(DWORD, HWND, LPDWORD)
|
||||
GetWindowThreadProcessIdParams = ((1, 'hWnd'), (1, 'lpdwProcessId'))
|
||||
|
||||
#def ExitProcess(uExitCode):
|
||||
# return ExitProcess.ctypes_function(uExitCode)
|
||||
ExitProcessPrototype = WINFUNCTYPE(VOID, UINT)
|
||||
@@ -1534,30 +1374,130 @@ RtlDosPathNameToNtPathName_UParams = ((1, 'DosName'), (1, 'NtName'), (1, 'PartNa
|
||||
ApiSetResolveToHostPrototype = WINFUNCTYPE(NTSTATUS, PVOID, PUNICODE_STRING, PUNICODE_STRING, PBOOLEAN, PUNICODE_STRING)
|
||||
ApiSetResolveToHostParams = ((1, 'Schema'), (1, 'FileNameIn'), (1, 'ParentName'), (1, 'Resolved'), (1, 'HostBinary'))
|
||||
|
||||
#def CreateNamedPipeA(lpName, dwOpenMode, dwPipeMode, nMaxInstances, nOutBufferSize, nInBufferSize, nDefaultTimeOut, lpSecurityAttributes):
|
||||
# return CreateNamedPipeA.ctypes_function(lpName, dwOpenMode, dwPipeMode, nMaxInstances, nOutBufferSize, nInBufferSize, nDefaultTimeOut, lpSecurityAttributes)
|
||||
CreateNamedPipeAPrototype = WINFUNCTYPE(HANDLE, LPCSTR, DWORD, DWORD, DWORD, DWORD, DWORD, DWORD, LPSECURITY_ATTRIBUTES)
|
||||
CreateNamedPipeAParams = ((1, 'lpName'), (1, 'dwOpenMode'), (1, 'dwPipeMode'), (1, 'nMaxInstances'), (1, 'nOutBufferSize'), (1, 'nInBufferSize'), (1, 'nDefaultTimeOut'), (1, 'lpSecurityAttributes'))
|
||||
#def GetCursorPos(lpPoint):
|
||||
# return GetCursorPos.ctypes_function(lpPoint)
|
||||
GetCursorPosPrototype = WINFUNCTYPE(BOOL, LPPOINT)
|
||||
GetCursorPosParams = ((1, 'lpPoint'),)
|
||||
|
||||
#def CreateNamedPipeW(lpName, dwOpenMode, dwPipeMode, nMaxInstances, nOutBufferSize, nInBufferSize, nDefaultTimeOut, lpSecurityAttributes):
|
||||
# return CreateNamedPipeW.ctypes_function(lpName, dwOpenMode, dwPipeMode, nMaxInstances, nOutBufferSize, nInBufferSize, nDefaultTimeOut, lpSecurityAttributes)
|
||||
CreateNamedPipeWPrototype = WINFUNCTYPE(HANDLE, LPWSTR, DWORD, DWORD, DWORD, DWORD, DWORD, DWORD, LPSECURITY_ATTRIBUTES)
|
||||
CreateNamedPipeWParams = ((1, 'lpName'), (1, 'dwOpenMode'), (1, 'dwPipeMode'), (1, 'nMaxInstances'), (1, 'nOutBufferSize'), (1, 'nInBufferSize'), (1, 'nDefaultTimeOut'), (1, 'lpSecurityAttributes'))
|
||||
#def WindowFromPoint(Point):
|
||||
# return WindowFromPoint.ctypes_function(Point)
|
||||
WindowFromPointPrototype = WINFUNCTYPE(HWND, POINT)
|
||||
WindowFromPointParams = ((1, 'Point'),)
|
||||
|
||||
#def ConnectNamedPipe(hNamedPipe, lpOverlapped):
|
||||
# return ConnectNamedPipe.ctypes_function(hNamedPipe, lpOverlapped)
|
||||
ConnectNamedPipePrototype = WINFUNCTYPE(BOOL, HANDLE, LPOVERLAPPED)
|
||||
ConnectNamedPipeParams = ((1, 'hNamedPipe'), (1, 'lpOverlapped'))
|
||||
#def GetWindowRect(hWnd, lpRect):
|
||||
# return GetWindowRect.ctypes_function(hWnd, lpRect)
|
||||
GetWindowRectPrototype = WINFUNCTYPE(BOOL, HWND, LPRECT)
|
||||
GetWindowRectParams = ((1, 'hWnd'), (1, 'lpRect'))
|
||||
|
||||
#def SetNamedPipeHandleState(hNamedPipe, lpMode, lpMaxCollectionCount, lpCollectDataTimeout):
|
||||
# return SetNamedPipeHandleState.ctypes_function(hNamedPipe, lpMode, lpMaxCollectionCount, lpCollectDataTimeout)
|
||||
SetNamedPipeHandleStatePrototype = WINFUNCTYPE(BOOL, HANDLE, LPDWORD, LPDWORD, LPDWORD)
|
||||
SetNamedPipeHandleStateParams = ((1, 'hNamedPipe'), (1, 'lpMode'), (1, 'lpMaxCollectionCount'), (1, 'lpCollectDataTimeout'))
|
||||
#def EnumWindows(lpEnumFunc, lParam):
|
||||
# return EnumWindows.ctypes_function(lpEnumFunc, lParam)
|
||||
EnumWindowsPrototype = WINFUNCTYPE(BOOL, WNDENUMPROC, LPARAM)
|
||||
EnumWindowsParams = ((1, 'lpEnumFunc'), (1, 'lParam'))
|
||||
|
||||
#def TpCallbackSendAlpcMessageOnCompletion(TpHandle, PortHandle, Flags, SendMessage):
|
||||
# return TpCallbackSendAlpcMessageOnCompletion.ctypes_function(TpHandle, PortHandle, Flags, SendMessage)
|
||||
TpCallbackSendAlpcMessageOnCompletionPrototype = WINFUNCTYPE(NTSTATUS, HANDLE, HANDLE, ULONG, PPORT_MESSAGE)
|
||||
TpCallbackSendAlpcMessageOnCompletionParams = ((1, 'TpHandle'), (1, 'PortHandle'), (1, 'Flags'), (1, 'SendMessage'))
|
||||
#def GetWindowTextA(hWnd, lpString, nMaxCount):
|
||||
# return GetWindowTextA.ctypes_function(hWnd, lpString, nMaxCount)
|
||||
GetWindowTextAPrototype = WINFUNCTYPE(INT, HWND, LPSTR, INT)
|
||||
GetWindowTextAParams = ((1, 'hWnd'), (1, 'lpString'), (1, 'nMaxCount'))
|
||||
|
||||
#def GetParent(hWnd):
|
||||
# return GetParent.ctypes_function(hWnd)
|
||||
GetParentPrototype = WINFUNCTYPE(HWND, HWND)
|
||||
GetParentParams = ((1, 'hWnd'),)
|
||||
|
||||
#def GetWindowTextW(hWnd, lpString, nMaxCount):
|
||||
# return GetWindowTextW.ctypes_function(hWnd, lpString, nMaxCount)
|
||||
GetWindowTextWPrototype = WINFUNCTYPE(INT, HWND, LPWSTR, INT)
|
||||
GetWindowTextWParams = ((1, 'hWnd'), (1, 'lpString'), (1, 'nMaxCount'))
|
||||
|
||||
#def GetWindowModuleFileNameA(hwnd, pszFileName, cchFileNameMax):
|
||||
# return GetWindowModuleFileNameA.ctypes_function(hwnd, pszFileName, cchFileNameMax)
|
||||
GetWindowModuleFileNameAPrototype = WINFUNCTYPE(UINT, HWND, LPSTR, UINT)
|
||||
GetWindowModuleFileNameAParams = ((1, 'hwnd'), (1, 'pszFileName'), (1, 'cchFileNameMax'))
|
||||
|
||||
#def GetWindowModuleFileNameW(hwnd, pszFileName, cchFileNameMax):
|
||||
# return GetWindowModuleFileNameW.ctypes_function(hwnd, pszFileName, cchFileNameMax)
|
||||
GetWindowModuleFileNameWPrototype = WINFUNCTYPE(UINT, HWND, LPWSTR, UINT)
|
||||
GetWindowModuleFileNameWParams = ((1, 'hwnd'), (1, 'pszFileName'), (1, 'cchFileNameMax'))
|
||||
|
||||
#def EnumChildWindows(hWndParent, lpEnumFunc, lParam):
|
||||
# return EnumChildWindows.ctypes_function(hWndParent, lpEnumFunc, lParam)
|
||||
EnumChildWindowsPrototype = WINFUNCTYPE(BOOL, HWND, WNDENUMPROC, LPARAM)
|
||||
EnumChildWindowsParams = ((1, 'hWndParent'), (1, 'lpEnumFunc'), (1, 'lParam'))
|
||||
|
||||
#def CloseWindow(hWnd):
|
||||
# return CloseWindow.ctypes_function(hWnd)
|
||||
CloseWindowPrototype = WINFUNCTYPE(BOOL, HWND)
|
||||
CloseWindowParams = ((1, 'hWnd'),)
|
||||
|
||||
#def GetDesktopWindow():
|
||||
# return GetDesktopWindow.ctypes_function()
|
||||
GetDesktopWindowPrototype = WINFUNCTYPE(HWND)
|
||||
GetDesktopWindowParams = ()
|
||||
|
||||
#def GetForegroundWindow():
|
||||
# return GetForegroundWindow.ctypes_function()
|
||||
GetForegroundWindowPrototype = WINFUNCTYPE(HWND)
|
||||
GetForegroundWindowParams = ()
|
||||
|
||||
#def BringWindowToTop(hWnd):
|
||||
# return BringWindowToTop.ctypes_function(hWnd)
|
||||
BringWindowToTopPrototype = WINFUNCTYPE(BOOL, HWND)
|
||||
BringWindowToTopParams = ((1, 'hWnd'),)
|
||||
|
||||
#def MoveWindow(hWnd, X, Y, nWidth, nHeight, bRepaint):
|
||||
# return MoveWindow.ctypes_function(hWnd, X, Y, nWidth, nHeight, bRepaint)
|
||||
MoveWindowPrototype = WINFUNCTYPE(BOOL, HWND, INT, INT, INT, INT, BOOL)
|
||||
MoveWindowParams = ((1, 'hWnd'), (1, 'X'), (1, 'Y'), (1, 'nWidth'), (1, 'nHeight'), (1, 'bRepaint'))
|
||||
|
||||
#def SetWindowPos(hWnd, hWndInsertAfter, X, Y, cx, cy, uFlags):
|
||||
# return SetWindowPos.ctypes_function(hWnd, hWndInsertAfter, X, Y, cx, cy, uFlags)
|
||||
SetWindowPosPrototype = WINFUNCTYPE(BOOL, HWND, HWND, INT, INT, INT, INT, UINT)
|
||||
SetWindowPosParams = ((1, 'hWnd'), (1, 'hWndInsertAfter'), (1, 'X'), (1, 'Y'), (1, 'cx'), (1, 'cy'), (1, 'uFlags'))
|
||||
|
||||
#def SetWindowTextA(hWnd, lpString):
|
||||
# return SetWindowTextA.ctypes_function(hWnd, lpString)
|
||||
SetWindowTextAPrototype = WINFUNCTYPE(BOOL, HWND, LPCSTR)
|
||||
SetWindowTextAParams = ((1, 'hWnd'), (1, 'lpString'))
|
||||
|
||||
#def SetWindowTextW(hWnd, lpString):
|
||||
# return SetWindowTextW.ctypes_function(hWnd, lpString)
|
||||
SetWindowTextWPrototype = WINFUNCTYPE(BOOL, HWND, LPWSTR)
|
||||
SetWindowTextWParams = ((1, 'hWnd'), (1, 'lpString'))
|
||||
|
||||
#def RealGetWindowClassA(hwnd, pszType, cchType):
|
||||
# return RealGetWindowClassA.ctypes_function(hwnd, pszType, cchType)
|
||||
RealGetWindowClassAPrototype = WINFUNCTYPE(UINT, HWND, LPCSTR, UINT)
|
||||
RealGetWindowClassAParams = ((1, 'hwnd'), (1, 'pszType'), (1, 'cchType'))
|
||||
|
||||
#def RealGetWindowClassW(hwnd, pszType, cchType):
|
||||
# return RealGetWindowClassW.ctypes_function(hwnd, pszType, cchType)
|
||||
RealGetWindowClassWPrototype = WINFUNCTYPE(UINT, HWND, LPWSTR, UINT)
|
||||
RealGetWindowClassWParams = ((1, 'hwnd'), (1, 'pszType'), (1, 'cchType'))
|
||||
|
||||
#def GetClassInfoExA(hinst, lpszClass, lpwcx):
|
||||
# return GetClassInfoExA.ctypes_function(hinst, lpszClass, lpwcx)
|
||||
GetClassInfoExAPrototype = WINFUNCTYPE(BOOL, HINSTANCE, LPCSTR, LPWNDCLASSEXA)
|
||||
GetClassInfoExAParams = ((1, 'hinst'), (1, 'lpszClass'), (1, 'lpwcx'))
|
||||
|
||||
#def GetClassInfoExW(hinst, lpszClass, lpwcx):
|
||||
# return GetClassInfoExW.ctypes_function(hinst, lpszClass, lpwcx)
|
||||
GetClassInfoExWPrototype = WINFUNCTYPE(BOOL, HINSTANCE, LPCWSTR, LPWNDCLASSEXW)
|
||||
GetClassInfoExWParams = ((1, 'hinst'), (1, 'lpszClass'), (1, 'lpwcx'))
|
||||
|
||||
#def GetClassNameA(hWnd, lpClassName, nMaxCount):
|
||||
# return GetClassNameA.ctypes_function(hWnd, lpClassName, nMaxCount)
|
||||
GetClassNameAPrototype = WINFUNCTYPE(INT, HWND, LPCSTR, INT)
|
||||
GetClassNameAParams = ((1, 'hWnd'), (1, 'lpClassName'), (1, 'nMaxCount'))
|
||||
|
||||
#def GetClassNameW(hWnd, lpClassName, nMaxCount):
|
||||
# return GetClassNameW.ctypes_function(hWnd, lpClassName, nMaxCount)
|
||||
GetClassNameWPrototype = WINFUNCTYPE(INT, HWND, LPWSTR, INT)
|
||||
GetClassNameWParams = ((1, 'hWnd'), (1, 'lpClassName'), (1, 'nMaxCount'))
|
||||
|
||||
#def GetWindowThreadProcessId(hWnd, lpdwProcessId):
|
||||
# return GetWindowThreadProcessId.ctypes_function(hWnd, lpdwProcessId)
|
||||
GetWindowThreadProcessIdPrototype = WINFUNCTYPE(DWORD, HWND, LPDWORD)
|
||||
GetWindowThreadProcessIdParams = ((1, 'hWnd'), (1, 'lpdwProcessId'))
|
||||
|
||||
#def CryptCATAdminCalcHashFromFileHandle(hFile, pcbHash, pbHash, dwFlags):
|
||||
# return CryptCATAdminCalcHashFromFileHandle.ctypes_function(hFile, pcbHash, pbHash, dwFlags)
|
||||
@@ -1799,3 +1739,68 @@ CryptMsgVerifyCountersignatureEncodedParams = ((1, 'hCryptProv'), (1, 'dwEncodin
|
||||
CryptMsgVerifyCountersignatureEncodedExPrototype = WINFUNCTYPE(BOOL, HCRYPTPROV_LEGACY, DWORD, PBYTE, DWORD, PBYTE, DWORD, DWORD, PVOID, DWORD, PVOID)
|
||||
CryptMsgVerifyCountersignatureEncodedExParams = ((1, 'hCryptProv'), (1, 'dwEncodingType'), (1, 'pbSignerInfo'), (1, 'cbSignerInfo'), (1, 'pbSignerInfoCountersignature'), (1, 'cbSignerInfoCountersignature'), (1, 'dwSignerType'), (1, 'pvSigner'), (1, 'dwFlags'), (1, 'pvExtra'))
|
||||
|
||||
#def CryptHashCertificate(hCryptProv, Algid, dwFlags, pbEncoded, cbEncoded, pbComputedHash, pcbComputedHash):
|
||||
# return CryptHashCertificate.ctypes_function(hCryptProv, Algid, dwFlags, pbEncoded, cbEncoded, pbComputedHash, pcbComputedHash)
|
||||
CryptHashCertificatePrototype = WINFUNCTYPE(BOOL, HCRYPTPROV_LEGACY, ALG_ID, DWORD, POINTER(BYTE), DWORD, POINTER(BYTE), POINTER(DWORD))
|
||||
CryptHashCertificateParams = ((1, 'hCryptProv'), (1, 'Algid'), (1, 'dwFlags'), (1, 'pbEncoded'), (1, 'cbEncoded'), (1, 'pbComputedHash'), (1, 'pcbComputedHash'))
|
||||
|
||||
#def TpCallbackSendAlpcMessageOnCompletion(TpHandle, PortHandle, Flags, SendMessage):
|
||||
# return TpCallbackSendAlpcMessageOnCompletion.ctypes_function(TpHandle, PortHandle, Flags, SendMessage)
|
||||
TpCallbackSendAlpcMessageOnCompletionPrototype = WINFUNCTYPE(NTSTATUS, HANDLE, HANDLE, ULONG, PPORT_MESSAGE)
|
||||
TpCallbackSendAlpcMessageOnCompletionParams = ((1, 'TpHandle'), (1, 'PortHandle'), (1, 'Flags'), (1, 'SendMessage'))
|
||||
|
||||
#def CreateNamedPipeA(lpName, dwOpenMode, dwPipeMode, nMaxInstances, nOutBufferSize, nInBufferSize, nDefaultTimeOut, lpSecurityAttributes):
|
||||
# return CreateNamedPipeA.ctypes_function(lpName, dwOpenMode, dwPipeMode, nMaxInstances, nOutBufferSize, nInBufferSize, nDefaultTimeOut, lpSecurityAttributes)
|
||||
CreateNamedPipeAPrototype = WINFUNCTYPE(HANDLE, LPCSTR, DWORD, DWORD, DWORD, DWORD, DWORD, DWORD, LPSECURITY_ATTRIBUTES)
|
||||
CreateNamedPipeAParams = ((1, 'lpName'), (1, 'dwOpenMode'), (1, 'dwPipeMode'), (1, 'nMaxInstances'), (1, 'nOutBufferSize'), (1, 'nInBufferSize'), (1, 'nDefaultTimeOut'), (1, 'lpSecurityAttributes'))
|
||||
|
||||
#def CreateNamedPipeW(lpName, dwOpenMode, dwPipeMode, nMaxInstances, nOutBufferSize, nInBufferSize, nDefaultTimeOut, lpSecurityAttributes):
|
||||
# return CreateNamedPipeW.ctypes_function(lpName, dwOpenMode, dwPipeMode, nMaxInstances, nOutBufferSize, nInBufferSize, nDefaultTimeOut, lpSecurityAttributes)
|
||||
CreateNamedPipeWPrototype = WINFUNCTYPE(HANDLE, LPWSTR, DWORD, DWORD, DWORD, DWORD, DWORD, DWORD, LPSECURITY_ATTRIBUTES)
|
||||
CreateNamedPipeWParams = ((1, 'lpName'), (1, 'dwOpenMode'), (1, 'dwPipeMode'), (1, 'nMaxInstances'), (1, 'nOutBufferSize'), (1, 'nInBufferSize'), (1, 'nDefaultTimeOut'), (1, 'lpSecurityAttributes'))
|
||||
|
||||
#def ConnectNamedPipe(hNamedPipe, lpOverlapped):
|
||||
# return ConnectNamedPipe.ctypes_function(hNamedPipe, lpOverlapped)
|
||||
ConnectNamedPipePrototype = WINFUNCTYPE(BOOL, HANDLE, LPOVERLAPPED)
|
||||
ConnectNamedPipeParams = ((1, 'hNamedPipe'), (1, 'lpOverlapped'))
|
||||
|
||||
#def SetNamedPipeHandleState(hNamedPipe, lpMode, lpMaxCollectionCount, lpCollectDataTimeout):
|
||||
# return SetNamedPipeHandleState.ctypes_function(hNamedPipe, lpMode, lpMaxCollectionCount, lpCollectDataTimeout)
|
||||
SetNamedPipeHandleStatePrototype = WINFUNCTYPE(BOOL, HANDLE, LPDWORD, LPDWORD, LPDWORD)
|
||||
SetNamedPipeHandleStateParams = ((1, 'hNamedPipe'), (1, 'lpMode'), (1, 'lpMaxCollectionCount'), (1, 'lpCollectDataTimeout'))
|
||||
|
||||
#def OpenEventLogA(lpUNCServerName, lpSourceName):
|
||||
# return OpenEventLogA.ctypes_function(lpUNCServerName, lpSourceName)
|
||||
OpenEventLogAPrototype = WINFUNCTYPE(HANDLE, LPCSTR, LPCSTR)
|
||||
OpenEventLogAParams = ((1, 'lpUNCServerName'), (1, 'lpSourceName'))
|
||||
|
||||
#def OpenEventLogW(lpUNCServerName, lpSourceName):
|
||||
# return OpenEventLogW.ctypes_function(lpUNCServerName, lpSourceName)
|
||||
OpenEventLogWPrototype = WINFUNCTYPE(HANDLE, LPWSTR, LPWSTR)
|
||||
OpenEventLogWParams = ((1, 'lpUNCServerName'), (1, 'lpSourceName'))
|
||||
|
||||
#def ReadEventLogA(hEventLog, dwReadFlags, dwRecordOffset, lpBuffer, nNumberOfBytesToRead, pnBytesRead, pnMinNumberOfBytesNeeded):
|
||||
# return ReadEventLogA.ctypes_function(hEventLog, dwReadFlags, dwRecordOffset, lpBuffer, nNumberOfBytesToRead, pnBytesRead, pnMinNumberOfBytesNeeded)
|
||||
ReadEventLogAPrototype = WINFUNCTYPE(BOOL, HANDLE, DWORD, DWORD, LPVOID, DWORD, POINTER(DWORD), POINTER(DWORD))
|
||||
ReadEventLogAParams = ((1, 'hEventLog'), (1, 'dwReadFlags'), (1, 'dwRecordOffset'), (1, 'lpBuffer'), (1, 'nNumberOfBytesToRead'), (1, 'pnBytesRead'), (1, 'pnMinNumberOfBytesNeeded'))
|
||||
|
||||
#def ReadEventLogW(hEventLog, dwReadFlags, dwRecordOffset, lpBuffer, nNumberOfBytesToRead, pnBytesRead, pnMinNumberOfBytesNeeded):
|
||||
# return ReadEventLogW.ctypes_function(hEventLog, dwReadFlags, dwRecordOffset, lpBuffer, nNumberOfBytesToRead, pnBytesRead, pnMinNumberOfBytesNeeded)
|
||||
ReadEventLogWPrototype = WINFUNCTYPE(BOOL, HANDLE, DWORD, DWORD, LPVOID, DWORD, POINTER(DWORD), POINTER(DWORD))
|
||||
ReadEventLogWParams = ((1, 'hEventLog'), (1, 'dwReadFlags'), (1, 'dwRecordOffset'), (1, 'lpBuffer'), (1, 'nNumberOfBytesToRead'), (1, 'pnBytesRead'), (1, 'pnMinNumberOfBytesNeeded'))
|
||||
|
||||
#def GetEventLogInformation(hEventLog, dwInfoLevel, lpBuffer, cbBufSize, pcbBytesNeeded):
|
||||
# return GetEventLogInformation.ctypes_function(hEventLog, dwInfoLevel, lpBuffer, cbBufSize, pcbBytesNeeded)
|
||||
GetEventLogInformationPrototype = WINFUNCTYPE(BOOL, HANDLE, DWORD, LPVOID, DWORD, LPDWORD)
|
||||
GetEventLogInformationParams = ((1, 'hEventLog'), (1, 'dwInfoLevel'), (1, 'lpBuffer'), (1, 'cbBufSize'), (1, 'pcbBytesNeeded'))
|
||||
|
||||
#def GetNumberOfEventLogRecords(hEventLog, NumberOfRecords):
|
||||
# return GetNumberOfEventLogRecords.ctypes_function(hEventLog, NumberOfRecords)
|
||||
GetNumberOfEventLogRecordsPrototype = WINFUNCTYPE(BOOL, HANDLE, PDWORD)
|
||||
GetNumberOfEventLogRecordsParams = ((1, 'hEventLog'), (1, 'NumberOfRecords'))
|
||||
|
||||
#def CloseEventLog(hEventLog):
|
||||
# return CloseEventLog.ctypes_function(hEventLog)
|
||||
CloseEventLogPrototype = WINFUNCTYPE(BOOL, HANDLE)
|
||||
CloseEventLogParams = ((1, 'hEventLog'),)
|
||||
|
||||
|
||||
+180
-172
@@ -160,35 +160,6 @@ class _API_SET_NAMESPACE_V6(Structure):
|
||||
]
|
||||
API_SET_NAMESPACE_V6 = _API_SET_NAMESPACE_V6
|
||||
|
||||
class _EVENTLOGRECORD(Structure):
|
||||
_fields_ = [
|
||||
("Length", DWORD),
|
||||
("Reserved", DWORD),
|
||||
("RecordNumber", DWORD),
|
||||
("TimeGenerated", DWORD),
|
||||
("TimeWritten", DWORD),
|
||||
("EventID", DWORD),
|
||||
("EventType", WORD),
|
||||
("NumStrings", WORD),
|
||||
("EventCategory", WORD),
|
||||
("ReservedFlags", WORD),
|
||||
("ClosingRecordNumber", DWORD),
|
||||
("StringOffset", DWORD),
|
||||
("UserSidLength", DWORD),
|
||||
("UserSidOffset", DWORD),
|
||||
("DataLength", DWORD),
|
||||
("DataOffset", DWORD),
|
||||
]
|
||||
PEVENTLOGRECORD = POINTER(_EVENTLOGRECORD)
|
||||
EVENTLOGRECORD = _EVENTLOGRECORD
|
||||
|
||||
class _EVENTLOG_FULL_INFORMATION(Structure):
|
||||
_fields_ = [
|
||||
("dwFull", DWORD),
|
||||
]
|
||||
EVENTLOG_FULL_INFORMATION = _EVENTLOG_FULL_INFORMATION
|
||||
LPEVENTLOG_FULL_INFORMATION = POINTER(_EVENTLOG_FULL_INFORMATION)
|
||||
|
||||
VOID = DWORD
|
||||
BYTE = c_ubyte
|
||||
PWSTR = LPWSTR
|
||||
@@ -282,6 +253,21 @@ HCERTSTORE = PVOID
|
||||
HCRYPTMSG = PVOID
|
||||
PALPC_PORT_ATTRIBUTES = PVOID
|
||||
PPORT_MESSAGE = PVOID
|
||||
class _SHITEMID(Structure):
|
||||
_fields_ = [
|
||||
("cb", USHORT),
|
||||
("abID", BYTE * 1),
|
||||
]
|
||||
SHITEMID = _SHITEMID
|
||||
|
||||
class _ITEMIDLIST(Structure):
|
||||
_fields_ = [
|
||||
("mkid", SHITEMID),
|
||||
]
|
||||
ITEMIDLIST = _ITEMIDLIST
|
||||
PCIDLIST_ABSOLUTE = POINTER(_ITEMIDLIST)
|
||||
PIDLIST_ABSOLUTE = POINTER(_ITEMIDLIST)
|
||||
|
||||
FakeFileInformationZero = EnumValue("_FILE_INFORMATION_CLASS", "FakeFileInformationZero", 0x0)
|
||||
FileDirectoryInformation = EnumValue("_FILE_INFORMATION_CLASS", "FileDirectoryInformation", 0x1)
|
||||
FileFullDirectoryInformation = EnumValue("_FILE_INFORMATION_CLASS", "FileFullDirectoryInformation", 0x2)
|
||||
@@ -491,139 +477,34 @@ class _FILE_ALL_INFORMATION(Structure):
|
||||
PFILE_ALL_INFORMATION = POINTER(_FILE_ALL_INFORMATION)
|
||||
FILE_ALL_INFORMATION = _FILE_ALL_INFORMATION
|
||||
|
||||
class tagRGBTRIPLE(Structure):
|
||||
class _EVENTLOGRECORD(Structure):
|
||||
_fields_ = [
|
||||
("rgbtBlue", BYTE),
|
||||
("rgbtGreen", BYTE),
|
||||
("rgbtRed", BYTE),
|
||||
("Length", DWORD),
|
||||
("Reserved", DWORD),
|
||||
("RecordNumber", DWORD),
|
||||
("TimeGenerated", DWORD),
|
||||
("TimeWritten", DWORD),
|
||||
("EventID", DWORD),
|
||||
("EventType", WORD),
|
||||
("NumStrings", WORD),
|
||||
("EventCategory", WORD),
|
||||
("ReservedFlags", WORD),
|
||||
("ClosingRecordNumber", DWORD),
|
||||
("StringOffset", DWORD),
|
||||
("UserSidLength", DWORD),
|
||||
("UserSidOffset", DWORD),
|
||||
("DataLength", DWORD),
|
||||
("DataOffset", DWORD),
|
||||
]
|
||||
NPRGBTRIPLE = POINTER(tagRGBTRIPLE)
|
||||
LPRGBTRIPLE = POINTER(tagRGBTRIPLE)
|
||||
RGBTRIPLE = tagRGBTRIPLE
|
||||
PRGBTRIPLE = POINTER(tagRGBTRIPLE)
|
||||
PEVENTLOGRECORD = POINTER(_EVENTLOGRECORD)
|
||||
EVENTLOGRECORD = _EVENTLOGRECORD
|
||||
|
||||
class tagBITMAPFILEHEADER(Structure):
|
||||
_pack_ = 2
|
||||
class _EVENTLOG_FULL_INFORMATION(Structure):
|
||||
_fields_ = [
|
||||
("bfType", WORD),
|
||||
("bfSize", DWORD),
|
||||
("bfReserved1", WORD),
|
||||
("bfReserved2", WORD),
|
||||
("bfOffBits", DWORD),
|
||||
("dwFull", DWORD),
|
||||
]
|
||||
BITMAPFILEHEADER = tagBITMAPFILEHEADER
|
||||
PBITMAPFILEHEADER = POINTER(tagBITMAPFILEHEADER)
|
||||
LPBITMAPFILEHEADER = POINTER(tagBITMAPFILEHEADER)
|
||||
|
||||
class tagBITMAPCOREHEADER(Structure):
|
||||
_fields_ = [
|
||||
("bcSize", DWORD),
|
||||
("bcWidth", WORD),
|
||||
("bcHeight", WORD),
|
||||
("bcPlanes", WORD),
|
||||
("bcBitCount", WORD),
|
||||
]
|
||||
LPBITMAPCOREHEADER = POINTER(tagBITMAPCOREHEADER)
|
||||
PBITMAPCOREHEADER = POINTER(tagBITMAPCOREHEADER)
|
||||
BITMAPCOREHEADER = tagBITMAPCOREHEADER
|
||||
|
||||
class tagBITMAP(Structure):
|
||||
_fields_ = [
|
||||
("bmType", LONG),
|
||||
("bmWidth", LONG),
|
||||
("bmHeight", LONG),
|
||||
("bmWidthBytes", LONG),
|
||||
("bmPlanes", WORD),
|
||||
("bmBitsPixel", WORD),
|
||||
("bmBits", LPVOID),
|
||||
]
|
||||
NPBITMAP = POINTER(tagBITMAP)
|
||||
LPBITMAP = POINTER(tagBITMAP)
|
||||
PBITMAP = POINTER(tagBITMAP)
|
||||
BITMAP = tagBITMAP
|
||||
|
||||
class tagBITMAPINFOHEADER(Structure):
|
||||
_fields_ = [
|
||||
("biSize", DWORD),
|
||||
("biWidth", LONG),
|
||||
("biHeight", LONG),
|
||||
("biPlanes", WORD),
|
||||
("biBitCount", WORD),
|
||||
("biCompression", DWORD),
|
||||
("biSizeImage", DWORD),
|
||||
("biXPelsPerMeter", LONG),
|
||||
("biYPelsPerMeter", LONG),
|
||||
("biClrUsed", DWORD),
|
||||
("biClrImportant", DWORD),
|
||||
]
|
||||
BITMAPINFOHEADER = tagBITMAPINFOHEADER
|
||||
PBITMAPINFOHEADER = POINTER(tagBITMAPINFOHEADER)
|
||||
LPBITMAPINFOHEADER = POINTER(tagBITMAPINFOHEADER)
|
||||
|
||||
class tagRGBQUAD(Structure):
|
||||
_fields_ = [
|
||||
("rgbBlue", BYTE),
|
||||
("rgbGreen", BYTE),
|
||||
("rgbRed", BYTE),
|
||||
("rgbReserved", BYTE),
|
||||
]
|
||||
RGBQUAD = tagRGBQUAD
|
||||
|
||||
class tagBITMAPINFO(Structure):
|
||||
_fields_ = [
|
||||
("bmiHeader", BITMAPINFOHEADER),
|
||||
("bmiColors", RGBQUAD * 1),
|
||||
]
|
||||
LPBITMAPINFO = POINTER(tagBITMAPINFO)
|
||||
PBITMAPINFO = POINTER(tagBITMAPINFO)
|
||||
BITMAPINFO = tagBITMAPINFO
|
||||
|
||||
class tagBITMAPCOREINFO(Structure):
|
||||
_fields_ = [
|
||||
("bmciHeader", BITMAPCOREHEADER),
|
||||
("bmciColors", RGBTRIPLE * 1),
|
||||
]
|
||||
LPBITMAPCOREINFO = POINTER(tagBITMAPCOREINFO)
|
||||
BITMAPCOREINFO = tagBITMAPCOREINFO
|
||||
PBITMAPCOREINFO = POINTER(tagBITMAPCOREINFO)
|
||||
|
||||
class tagWNDCLASSEXA(Structure):
|
||||
_fields_ = [
|
||||
("cbSize", UINT),
|
||||
("style", UINT),
|
||||
("lpfnWndProc", WNDPROC),
|
||||
("cbClsExtra", INT),
|
||||
("cbWndExtra", INT),
|
||||
("hInstance", HINSTANCE),
|
||||
("hIcon", HICON),
|
||||
("hCursor", HCURSOR),
|
||||
("hbrBackground", HBRUSH),
|
||||
("lpszMenuName", LPCSTR),
|
||||
("lpszClassName", LPCSTR),
|
||||
("hIconSm", HICON),
|
||||
]
|
||||
PWNDCLASSEXA = POINTER(tagWNDCLASSEXA)
|
||||
LPWNDCLASSEXA = POINTER(tagWNDCLASSEXA)
|
||||
WNDCLASSEXA = tagWNDCLASSEXA
|
||||
|
||||
class tagWNDCLASSEXW(Structure):
|
||||
_fields_ = [
|
||||
("cbSize", UINT),
|
||||
("style", UINT),
|
||||
("lpfnWndProc", WNDPROC),
|
||||
("cbClsExtra", INT),
|
||||
("cbWndExtra", INT),
|
||||
("hInstance", HINSTANCE),
|
||||
("hIcon", HICON),
|
||||
("hCursor", HCURSOR),
|
||||
("hbrBackground", HBRUSH),
|
||||
("lpszMenuName", LPWSTR),
|
||||
("lpszClassName", LPWSTR),
|
||||
("hIconSm", HICON),
|
||||
]
|
||||
WNDCLASSEXW = tagWNDCLASSEXW
|
||||
LPWNDCLASSEXW = POINTER(tagWNDCLASSEXW)
|
||||
PWNDCLASSEXW = POINTER(tagWNDCLASSEXW)
|
||||
EVENTLOG_FULL_INFORMATION = _EVENTLOG_FULL_INFORMATION
|
||||
LPEVENTLOG_FULL_INFORMATION = POINTER(_EVENTLOG_FULL_INFORMATION)
|
||||
|
||||
BG_JOB_STATE_QUEUED = EnumValue("_BG_JOB_STATE", "BG_JOB_STATE_QUEUED", 0x0)
|
||||
BG_JOB_STATE_CONNECTING = EnumValue("_BG_JOB_STATE", "BG_JOB_STATE_CONNECTING", 0x1)
|
||||
@@ -2199,6 +2080,14 @@ class _IMAGE_EXPORT_DIRECTORY(Structure):
|
||||
IMAGE_EXPORT_DIRECTORY = _IMAGE_EXPORT_DIRECTORY
|
||||
PIMAGE_EXPORT_DIRECTORY = POINTER(_IMAGE_EXPORT_DIRECTORY)
|
||||
|
||||
class _IMAGE_BASE_RELOCATION(Structure):
|
||||
_fields_ = [
|
||||
("VirtualAddress", DWORD),
|
||||
("SizeOfBlock", DWORD),
|
||||
]
|
||||
PIMAGE_BASE_RELOCATION = POINTER(_IMAGE_BASE_RELOCATION)
|
||||
IMAGE_BASE_RELOCATION = _IMAGE_BASE_RELOCATION
|
||||
|
||||
class _MEMORY_BASIC_INFORMATION(Structure):
|
||||
_fields_ = [
|
||||
("BaseAddress", PVOID),
|
||||
@@ -4874,6 +4763,140 @@ class _PROCESS_INSTRUMENTATION_CALLBACK_INFORMATION(Structure):
|
||||
PPROCESS_INSTRUMENTATION_CALLBACK_INFORMATION = POINTER(_PROCESS_INSTRUMENTATION_CALLBACK_INFORMATION)
|
||||
PROCESS_INSTRUMENTATION_CALLBACK_INFORMATION = _PROCESS_INSTRUMENTATION_CALLBACK_INFORMATION
|
||||
|
||||
class tagRGBTRIPLE(Structure):
|
||||
_fields_ = [
|
||||
("rgbtBlue", BYTE),
|
||||
("rgbtGreen", BYTE),
|
||||
("rgbtRed", BYTE),
|
||||
]
|
||||
NPRGBTRIPLE = POINTER(tagRGBTRIPLE)
|
||||
LPRGBTRIPLE = POINTER(tagRGBTRIPLE)
|
||||
RGBTRIPLE = tagRGBTRIPLE
|
||||
PRGBTRIPLE = POINTER(tagRGBTRIPLE)
|
||||
|
||||
class tagBITMAPFILEHEADER(Structure):
|
||||
_pack_ = 2
|
||||
_fields_ = [
|
||||
("bfType", WORD),
|
||||
("bfSize", DWORD),
|
||||
("bfReserved1", WORD),
|
||||
("bfReserved2", WORD),
|
||||
("bfOffBits", DWORD),
|
||||
]
|
||||
BITMAPFILEHEADER = tagBITMAPFILEHEADER
|
||||
PBITMAPFILEHEADER = POINTER(tagBITMAPFILEHEADER)
|
||||
LPBITMAPFILEHEADER = POINTER(tagBITMAPFILEHEADER)
|
||||
|
||||
class tagBITMAPCOREHEADER(Structure):
|
||||
_fields_ = [
|
||||
("bcSize", DWORD),
|
||||
("bcWidth", WORD),
|
||||
("bcHeight", WORD),
|
||||
("bcPlanes", WORD),
|
||||
("bcBitCount", WORD),
|
||||
]
|
||||
LPBITMAPCOREHEADER = POINTER(tagBITMAPCOREHEADER)
|
||||
PBITMAPCOREHEADER = POINTER(tagBITMAPCOREHEADER)
|
||||
BITMAPCOREHEADER = tagBITMAPCOREHEADER
|
||||
|
||||
class tagBITMAP(Structure):
|
||||
_fields_ = [
|
||||
("bmType", LONG),
|
||||
("bmWidth", LONG),
|
||||
("bmHeight", LONG),
|
||||
("bmWidthBytes", LONG),
|
||||
("bmPlanes", WORD),
|
||||
("bmBitsPixel", WORD),
|
||||
("bmBits", LPVOID),
|
||||
]
|
||||
NPBITMAP = POINTER(tagBITMAP)
|
||||
LPBITMAP = POINTER(tagBITMAP)
|
||||
PBITMAP = POINTER(tagBITMAP)
|
||||
BITMAP = tagBITMAP
|
||||
|
||||
class tagBITMAPINFOHEADER(Structure):
|
||||
_fields_ = [
|
||||
("biSize", DWORD),
|
||||
("biWidth", LONG),
|
||||
("biHeight", LONG),
|
||||
("biPlanes", WORD),
|
||||
("biBitCount", WORD),
|
||||
("biCompression", DWORD),
|
||||
("biSizeImage", DWORD),
|
||||
("biXPelsPerMeter", LONG),
|
||||
("biYPelsPerMeter", LONG),
|
||||
("biClrUsed", DWORD),
|
||||
("biClrImportant", DWORD),
|
||||
]
|
||||
BITMAPINFOHEADER = tagBITMAPINFOHEADER
|
||||
PBITMAPINFOHEADER = POINTER(tagBITMAPINFOHEADER)
|
||||
LPBITMAPINFOHEADER = POINTER(tagBITMAPINFOHEADER)
|
||||
|
||||
class tagRGBQUAD(Structure):
|
||||
_fields_ = [
|
||||
("rgbBlue", BYTE),
|
||||
("rgbGreen", BYTE),
|
||||
("rgbRed", BYTE),
|
||||
("rgbReserved", BYTE),
|
||||
]
|
||||
RGBQUAD = tagRGBQUAD
|
||||
|
||||
class tagBITMAPINFO(Structure):
|
||||
_fields_ = [
|
||||
("bmiHeader", BITMAPINFOHEADER),
|
||||
("bmiColors", RGBQUAD * 1),
|
||||
]
|
||||
LPBITMAPINFO = POINTER(tagBITMAPINFO)
|
||||
PBITMAPINFO = POINTER(tagBITMAPINFO)
|
||||
BITMAPINFO = tagBITMAPINFO
|
||||
|
||||
class tagBITMAPCOREINFO(Structure):
|
||||
_fields_ = [
|
||||
("bmciHeader", BITMAPCOREHEADER),
|
||||
("bmciColors", RGBTRIPLE * 1),
|
||||
]
|
||||
LPBITMAPCOREINFO = POINTER(tagBITMAPCOREINFO)
|
||||
BITMAPCOREINFO = tagBITMAPCOREINFO
|
||||
PBITMAPCOREINFO = POINTER(tagBITMAPCOREINFO)
|
||||
|
||||
class tagWNDCLASSEXA(Structure):
|
||||
_fields_ = [
|
||||
("cbSize", UINT),
|
||||
("style", UINT),
|
||||
("lpfnWndProc", WNDPROC),
|
||||
("cbClsExtra", INT),
|
||||
("cbWndExtra", INT),
|
||||
("hInstance", HINSTANCE),
|
||||
("hIcon", HICON),
|
||||
("hCursor", HCURSOR),
|
||||
("hbrBackground", HBRUSH),
|
||||
("lpszMenuName", LPCSTR),
|
||||
("lpszClassName", LPCSTR),
|
||||
("hIconSm", HICON),
|
||||
]
|
||||
PWNDCLASSEXA = POINTER(tagWNDCLASSEXA)
|
||||
LPWNDCLASSEXA = POINTER(tagWNDCLASSEXA)
|
||||
WNDCLASSEXA = tagWNDCLASSEXA
|
||||
|
||||
class tagWNDCLASSEXW(Structure):
|
||||
_fields_ = [
|
||||
("cbSize", UINT),
|
||||
("style", UINT),
|
||||
("lpfnWndProc", WNDPROC),
|
||||
("cbClsExtra", INT),
|
||||
("cbWndExtra", INT),
|
||||
("hInstance", HINSTANCE),
|
||||
("hIcon", HICON),
|
||||
("hCursor", HCURSOR),
|
||||
("hbrBackground", HBRUSH),
|
||||
("lpszMenuName", LPWSTR),
|
||||
("lpszClassName", LPWSTR),
|
||||
("hIconSm", HICON),
|
||||
]
|
||||
WNDCLASSEXW = tagWNDCLASSEXW
|
||||
LPWNDCLASSEXW = POINTER(tagWNDCLASSEXW)
|
||||
PWNDCLASSEXW = POINTER(tagWNDCLASSEXW)
|
||||
|
||||
AlpcBasicInformation = EnumValue("_ALPC_PORT_INFORMATION_CLASS", "AlpcBasicInformation", 0x0)
|
||||
AlpcPortInformation = EnumValue("_ALPC_PORT_INFORMATION_CLASS", "AlpcPortInformation", 0x1)
|
||||
AlpcAssociateCompletionPortInformation = EnumValue("_ALPC_PORT_INFORMATION_CLASS", "AlpcAssociateCompletionPortInformation", 0x2)
|
||||
@@ -5199,18 +5222,3 @@ class _RPC_IF_ID(INITIAL_RPC_IF_ID):
|
||||
def __repr__(self):
|
||||
return '<RPC_IF_ID "{0}" ({1}, {2})>'.format(self.Uuid.to_string(), self.VersMajor, self.VersMinor)
|
||||
RPC_IF_ID = _RPC_IF_ID
|
||||
class _SHITEMID(Structure):
|
||||
_fields_ = [
|
||||
("cb", USHORT),
|
||||
("abID", BYTE * 1),
|
||||
]
|
||||
SHITEMID = _SHITEMID
|
||||
|
||||
class _ITEMIDLIST(Structure):
|
||||
_fields_ = [
|
||||
("mkid", SHITEMID),
|
||||
]
|
||||
ITEMIDLIST = _ITEMIDLIST
|
||||
PCIDLIST_ABSOLUTE = POINTER(_ITEMIDLIST)
|
||||
PIDLIST_ABSOLUTE = POINTER(_ITEMIDLIST)
|
||||
|
||||
|
||||
@@ -605,12 +605,24 @@ def GetLongPathNameA(lpszShortPath, lpszLongPath, cchBuffer=None):
|
||||
cchBuffer = len(lpszLongPath)
|
||||
return GetLongPathNameA.ctypes_function(lpszShortPath, lpszLongPath, cchBuffer)
|
||||
|
||||
@Kernel32Proxy("GetLongPathNameW")
|
||||
def GetLongPathNameW(lpszShortPath, lpszLongPath, cchBuffer=None):
|
||||
if cchBuffer is None:
|
||||
cchBuffer = len(lpszLongPath)
|
||||
return GetLongPathNameW.ctypes_function(lpszShortPath, lpszLongPath, cchBuffer)
|
||||
|
||||
@Kernel32Proxy("GetShortPathNameA")
|
||||
def GetShortPathNameA(lpszLongPath, lpszShortPath, cchBuffer=None):
|
||||
if cchBuffer is None:
|
||||
cchBuffer = len(lpszShortPath)
|
||||
return GetShortPathNameA.ctypes_function(lpszLongPath, lpszShortPath, cchBuffer)
|
||||
|
||||
@Kernel32Proxy("GetShortPathNameW")
|
||||
def GetShortPathNameW(lpszLongPath, lpszShortPath, cchBuffer=None):
|
||||
if cchBuffer is None:
|
||||
cchBuffer = len(lpszShortPath)
|
||||
return GetShortPathNameW.ctypes_function(lpszLongPath, lpszShortPath, cchBuffer)
|
||||
|
||||
# TODO: might be in another DLL depending of version
|
||||
# Should handle this..
|
||||
|
||||
@@ -1557,6 +1569,10 @@ def CryptMsgVerifyCountersignatureEncodedEx(hCryptProv, dwEncodingType, pbSigner
|
||||
return CryptMsgVerifyCountersignatureEncodedEx.ctypes_function(hCryptProv, dwEncodingType, pbSignerInfo, cbSignerInfo, pbSignerInfoCountersignature, cbSignerInfoCountersignature, dwSignerType, pvSigner, dwFlags, pvExtra)
|
||||
|
||||
|
||||
@Crypt32Proxy('CryptHashCertificate')
|
||||
def CryptHashCertificate(hCryptProv, Algid, dwFlags, pbEncoded, cbEncoded, pbComputedHash, pcbComputedHash):
|
||||
return CryptHashCertificate.ctypes_function(hCryptProv, Algid, dwFlags, pbEncoded, cbEncoded, pbComputedHash, pcbComputedHash)
|
||||
|
||||
# ## CryptUI ## #
|
||||
|
||||
@CryptUIProxy('CryptUIDlgViewContext')
|
||||
|
||||
Reference in New Issue
Block a user