id int64 0 190k | prompt stringlengths 21 13.4M | docstring stringlengths 1 12k ⌀ |
|---|---|---|
177,072 | from _pydev_bundle import pydev_log
from _pydevd_bundle.pydevd_constants import DebugInfoHolder, IS_WINDOWS, IS_JYTHON, \
DISABLE_FILE_VALIDATION, is_true_in_env, IS_MAC
from _pydev_bundle._pydev_filesystem_encoding import getfilesystemencoding
from _pydevd_bundle.pydevd_comm_constants import file_system_encoding, ... | null |
177,073 | from _pydev_bundle import pydev_log
from _pydevd_bundle.pydevd_constants import DebugInfoHolder, IS_WINDOWS, IS_JYTHON, \
DISABLE_FILE_VALIDATION, is_true_in_env, IS_MAC
from _pydev_bundle._pydev_filesystem_encoding import getfilesystemencoding
from _pydevd_bundle.pydevd_comm_constants import file_system_encoding, ... | null |
177,074 | from _pydev_bundle import pydev_log
from _pydevd_bundle.pydevd_constants import DebugInfoHolder, IS_WINDOWS, IS_JYTHON, \
DISABLE_FILE_VALIDATION, is_true_in_env, IS_MAC
from _pydev_bundle._pydev_filesystem_encoding import getfilesystemencoding
from _pydevd_bundle.pydevd_comm_constants import file_system_encoding, ... | null |
177,075 | from _pydev_bundle import pydev_log
from _pydevd_bundle.pydevd_constants import DebugInfoHolder, IS_WINDOWS, IS_JYTHON, \
DISABLE_FILE_VALIDATION, is_true_in_env, IS_MAC
from _pydev_bundle._pydev_filesystem_encoding import getfilesystemencoding
from _pydevd_bundle.pydevd_comm_constants import file_system_encoding, ... | null |
177,076 | from _pydev_bundle import pydev_log
from _pydevd_bundle.pydevd_constants import DebugInfoHolder, IS_WINDOWS, IS_JYTHON, \
DISABLE_FILE_VALIDATION, is_true_in_env, IS_MAC
from _pydev_bundle._pydev_filesystem_encoding import getfilesystemencoding
from _pydevd_bundle.pydevd_comm_constants import file_system_encoding, ... | null |
177,077 | from _pydev_bundle import pydev_log
from _pydevd_bundle.pydevd_constants import DebugInfoHolder, IS_WINDOWS, IS_JYTHON, \
DISABLE_FILE_VALIDATION, is_true_in_env, IS_MAC
from _pydev_bundle._pydev_filesystem_encoding import getfilesystemencoding
from _pydevd_bundle.pydevd_comm_constants import file_system_encoding, ... | null |
177,078 | from _pydev_bundle import pydev_log
from _pydevd_bundle.pydevd_constants import DebugInfoHolder, IS_WINDOWS, IS_JYTHON, \
DISABLE_FILE_VALIDATION, is_true_in_env, IS_MAC
from _pydev_bundle._pydev_filesystem_encoding import getfilesystemencoding
from _pydevd_bundle.pydevd_comm_constants import file_system_encoding, ... | null |
177,079 | from _pydev_bundle import pydev_log
from _pydevd_bundle.pydevd_constants import DebugInfoHolder, IS_WINDOWS, IS_JYTHON, \
DISABLE_FILE_VALIDATION, is_true_in_env, IS_MAC
from _pydev_bundle._pydev_filesystem_encoding import getfilesystemencoding
from _pydevd_bundle.pydevd_comm_constants import file_system_encoding, ... | null |
177,080 | import sys
import os
def process_command_line(argv):
setup = {}
setup['port'] = 5678 # Default port for PyDev remote debugger
setup['pid'] = 0
setup['host'] = '127.0.0.1'
setup['protocol'] = ''
setup['debug-mode'] = ''
i = 0
while i < len(argv):
if argv[i] == '--port':
... | null |
177,081 | import sys
import struct
import os
import threading
def loop_in_thread():
while True:
import time
time.sleep(.5)
sys.stdout.write('#')
sys.stdout.flush() | null |
177,082 | import sys
import struct
import os
import threading
def is_python_64bit():
return (struct.calcsize('P') == 8) | null |
177,083 | import ctypes
import os
import struct
import subprocess
import sys
import time
from contextlib import contextmanager
import platform
import traceback
def _create_win_event(name):
from winappdbg.win32.kernel32 import CreateEventA, WaitForSingleObject, CloseHandle
manual_reset = False # i.e.: after someone waits... | null |
177,084 | import ctypes
import os
import struct
import subprocess
import sys
import time
from contextlib import contextmanager
import platform
import traceback
def get_target_filename(is_target_process_64=None, prefix=None, extension=None):
def run_python_code_linux(pid, python_code, connect_debugger_tracing=False, show_debug_i... | null |
177,085 | import ctypes
import os
import struct
import subprocess
import sys
import time
from contextlib import contextmanager
import platform
import traceback
def get_target_filename(is_target_process_64=None, prefix=None, extension=None):
# Note: we have an independent (and similar -- but not equal) version of this method ... | null |
177,086 | import ctypes
import os
import struct
import subprocess
import sys
import time
from contextlib import contextmanager
import platform
import traceback
def run_python_code(*args, **kwargs):
print('Unable to attach to process in platform: %s', sys.platform) | null |
177,087 | import sys
import os
import ctypes
import optparse
from winappdbg import win32
from winappdbg import compat
def CustomAddressIterator(memory_map, condition):
"""
Generator function that iterates through a memory map, filtering memory
region blocks by any given condition.
Returned by L{Process.get_me... | Generator function that iterates through a memory map, returning only those memory blocks that contain data. @type memory_map: list( L{win32.MemoryBasicInformation} ) @param memory_map: List of memory region information objects. Returned by L{Process.get_memory_map}. @rtype: generator of L{win32.MemoryBasicInformation}... |
177,088 | import sys
import os
import ctypes
import optparse
from winappdbg import win32
from winappdbg import compat
def CustomAddressIterator(memory_map, condition):
"""
Generator function that iterates through a memory map, filtering memory
region blocks by any given condition.
Returned by L{Process.get_me... | Generator function that iterates through a memory map, returning only those memory blocks that belong to executable images. @type memory_map: list( L{win32.MemoryBasicInformation} ) @param memory_map: List of memory region information objects. Returned by L{Process.get_memory_map}. @rtype: generator of L{win32.MemoryBa... |
177,089 | import sys
import os
import ctypes
import optparse
from winappdbg import win32
from winappdbg import compat
def CustomAddressIterator(memory_map, condition):
"""
Generator function that iterates through a memory map, filtering memory
region blocks by any given condition.
Returned by L{Process.get_me... | Generator function that iterates through a memory map, returning only those memory blocks that belong to memory mapped files. @type memory_map: list( L{win32.MemoryBasicInformation} ) @param memory_map: List of memory region information objects. Returned by L{Process.get_memory_map}. @rtype: generator of L{win32.Memory... |
177,090 | import sys
import os
import ctypes
import optparse
from winappdbg import win32
from winappdbg import compat
def CustomAddressIterator(memory_map, condition):
"""
Generator function that iterates through a memory map, filtering memory
region blocks by any given condition.
Returned by L{Process.get_me... | Generator function that iterates through a memory map, returning only those memory blocks that are readable. @type memory_map: list( L{win32.MemoryBasicInformation} ) @param memory_map: List of memory region information objects. Returned by L{Process.get_memory_map}. @rtype: generator of L{win32.MemoryBasicInformation}... |
177,091 | import sys
import os
import ctypes
import optparse
from winappdbg import win32
from winappdbg import compat
def CustomAddressIterator(memory_map, condition):
"""
Generator function that iterates through a memory map, filtering memory
region blocks by any given condition.
Returned by L{Process.get_me... | Generator function that iterates through a memory map, returning only those memory blocks that are writeable. @note: Writeable memory is always readable too. @type memory_map: list( L{win32.MemoryBasicInformation} ) @param memory_map: List of memory region information objects. Returned by L{Process.get_memory_map}. @rt... |
177,092 | import sys
import os
import ctypes
import optparse
from winappdbg import win32
from winappdbg import compat
def CustomAddressIterator(memory_map, condition):
"""
Generator function that iterates through a memory map, filtering memory
region blocks by any given condition.
Returned by L{Process.get_me... | Generator function that iterates through a memory map, returning only those memory blocks that are executable. @note: Executable memory is always readable too. @type memory_map: list( L{win32.MemoryBasicInformation} ) @param memory_map: List of memory region information objects. Returned by L{Process.get_memory_map}. @... |
177,093 | import sys
import os
import ctypes
import optparse
from winappdbg import win32
from winappdbg import compat
def CustomAddressIterator(memory_map, condition):
"""
Generator function that iterates through a memory map, filtering memory
region blocks by any given condition.
Returned by L{Process.get_me... | Generator function that iterates through a memory map, returning only those memory blocks that are executable and writeable. @note: The presence of such pages make memory corruption vulnerabilities much easier to exploit. @type memory_map: list( L{win32.MemoryBasicInformation} ) @param memory_map: List of memory region... |
177,094 | from winappdbg.win32.defines import *
def GetLargePageMinimum():
_GetLargePageMinimum = windll.user32.GetLargePageMinimum
_GetLargePageMinimum.argtypes = []
_GetLargePageMinimum.restype = SIZE_T
return _GetLargePageMinimum() | null |
177,095 | from winappdbg.win32.defines import *
def GetCurrentThread():
## return 0xFFFFFFFFFFFFFFFEL
_GetCurrentThread = windll.kernel32.GetCurrentThread
_GetCurrentThread.argtypes = []
_GetCurrentThread.restype = HANDLE
return _GetCurrentThread() | null |
177,096 | from winappdbg.win32.defines import *
def GetVersion():
_GetVersion = windll.kernel32.GetVersion
_GetVersion.argtypes = []
_GetVersion.restype = DWORD
_GetVersion.errcheck = RaiseIfZero
# See the example code here:
# http://msdn.microsoft.com/en-us/library/ms724439(VS.85).aspx
dwVersion ... | null |
177,097 | from winappdbg.win32.defines import *
class OSVERSIONINFOA(Structure):
_fields_ = [
("dwOSVersionInfoSize", DWORD),
("dwMajorVersion", DWORD),
("dwMinorVersion", DWORD),
("dwBuildNumber", DWORD),
("dwPlatformId", DWORD),
("szCSDVersion", ... | null |
177,098 | from winappdbg.win32.defines import *
class OSVERSIONINFOW(Structure):
class OSVERSIONINFOEXW(Structure):
def GetVersionExW():
_GetVersionExW = windll.kernel32.GetVersionExW
_GetVersionExW.argtypes = [POINTER(OSVERSIONINFOEXW)]
_GetVersionExW.restype = bool
_GetVersionExW.errcheck = RaiseIfZero
o... | null |
177,099 | from winappdbg.win32.defines import *
def GetProductInfo(dwOSMajorVersion, dwOSMinorVersion, dwSpMajorVersion, dwSpMinorVersion):
_GetProductInfo = windll.kernel32.GetProductInfo
_GetProductInfo.argtypes = [DWORD, DWORD, DWORD, DWORD, PDWORD]
_GetProductInfo.restype = BOOL
_GetProductInfo.errcheck = R... | null |
177,100 | from winappdbg.win32.defines import *
class OSVERSIONINFOEXA(Structure):
class OSVERSIONINFOEXW(Structure):
def VerifyVersionInfoA(lpVersionInfo, dwTypeMask, dwlConditionMask):
def VerifyVersionInfoW(lpVersionInfo, dwTypeMask, dwlConditionMask):
def VerifyVersionInfo(lpVersionInfo, dwTypeMask, dwlConditionMask):
i... | null |
177,101 | from winappdbg.win32.defines import *
def VerSetConditionMask(dwlConditionMask, dwTypeBitMask, dwConditionMask):
_VerSetConditionMask = windll.kernel32.VerSetConditionMask
_VerSetConditionMask.argtypes = [ULONGLONG, DWORD, BYTE]
_VerSetConditionMask.restype = ULONGLONG
return _VerSetConditionMask(dwlC... | null |
177,102 | from winappdbg.win32.defines import *
The provided code snippet includes necessary dependencies for implementing the `_get_bits` function. Write a Python function `def _get_bits()` to solve the following problem:
Determines the current integer size in bits. This is useful to know if we're running in a 32 bits or a 64 ... | Determines the current integer size in bits. This is useful to know if we're running in a 32 bits or a 64 bits machine. @rtype: int @return: Returns the size of L{SIZE_T} in bits. |
177,103 | from winappdbg.win32.defines import *
def GetSystemInfo():
_GetSystemInfo = windll.kernel32.GetSystemInfo
_GetSystemInfo.argtypes = [LPSYSTEM_INFO]
_GetSystemInfo.restype = None
sysinfo = SYSTEM_INFO()
_GetSystemInfo(byref(sysinfo))
return sysinfo
def GetNativeSystemInfo():
_GetNativeSystem... | Determines the current processor architecture. @rtype: str @return: On error, returns: - L{ARCH_UNKNOWN} (C{"unknown"}) meaning the architecture could not be detected or is not known to WinAppDbg. On success, returns one of the following values: - L{ARCH_I386} (C{"i386"}) for Intel 32-bit x86 processor or compatible. -... |
177,104 | from winappdbg.win32.defines import *
def GetCurrentProcess():
## return 0xFFFFFFFFFFFFFFFFL
_GetCurrentProcess = windll.kernel32.GetCurrentProcess
_GetCurrentProcess.argtypes = []
_GetCurrentProcess.restype = HANDLE
return _GetCurrentProcess()
def IsWow64Process(hProcess):
_IsWow64Process = win... | Determines if the current process is running in Windows-On-Windows 64 bits. @rtype: bool @return: C{True} of the current process is a 32 bit program running in a 64 bit version of Windows, C{False} if it's either a 32 bit program in a 32 bit Windows or a 64 bit program in a 64 bit Windows. |
177,105 | from winappdbg.win32.defines import *
VER_PLATFORM_WIN32_NT = 2
VER_SUITE_STORAGE_SERVER = 0x00002000
VER_SUITE_WH_SERVER = 0x00008000
VER_NT_WORKSTATION = 0x0000001
SM_SERVERR2 = 89
def GetSystemMetrics(nIndex):
_GetSystemMetrics = windll.user32... | Determines the current operating system. This function allows you to quickly tell apart major OS differences. For more detailed information call L{GetVersionEx} instead. @note: Wine reports itself as Windows XP 32 bits (even if the Linux host is 64 bits). ReactOS may report itself as Windows 2000 or Windows XP, dependi... |
177,106 | from winappdbg.win32.defines import *
GetVersionEx = GuessStringType(GetVersionExA, GetVersionExW)
The provided code snippet includes necessary dependencies for implementing the `_get_ntddi` function. Write a Python function `def _get_ntddi(osvi)` to solve the following problem:
Determines the current operating system... | Determines the current operating system. This function allows you to quickly tell apart major OS differences. For more detailed information call L{kernel32.GetVersionEx} instead. @note: Wine reports itself as Windows XP 32 bits (even if the Linux host is 64 bits). ReactOS may report itself as Windows 2000 or Windows XP... |
177,107 | from winappdbg.win32.defines import *
def GetFileVersionInfoA(lptstrFilename):
_GetFileVersionInfoA = windll.version.GetFileVersionInfoA
_GetFileVersionInfoA.argtypes = [LPSTR, DWORD, DWORD, LPVOID]
_GetFileVersionInfoA.restype = bool
_GetFileVersionInfoA.errcheck = RaiseIfZero
_GetFileVersionInf... | null |
177,108 | from winappdbg.win32.defines import *
def GetFileVersionInfoW(lptstrFilename):
_GetFileVersionInfoW = windll.version.GetFileVersionInfoW
_GetFileVersionInfoW.argtypes = [LPWSTR, DWORD, DWORD, LPVOID]
_GetFileVersionInfoW.restype = bool
_GetFileVersionInfoW.errcheck = RaiseIfZero
_GetFileVersionIn... | null |
177,109 | from winappdbg.win32.defines import *
def VerQueryValueA(pBlock, lpSubBlock):
_VerQueryValueA = windll.version.VerQueryValueA
_VerQueryValueA.argtypes = [LPVOID, LPSTR, LPVOID, POINTER(UINT)]
_VerQueryValueA.restype = bool
_VerQueryValueA.errcheck = RaiseIfZero
lpBuffer = LPVOID(0)
uLen = UIN... | null |
177,110 | from winappdbg.win32.defines import *
def VerQueryValueW(pBlock, lpSubBlock):
_VerQueryValueW = windll.version.VerQueryValueW
_VerQueryValueW.argtypes = [LPVOID, LPWSTR, LPVOID, POINTER(UINT)]
_VerQueryValueW.restype = bool
_VerQueryValueW.errcheck = RaiseIfZero
lpBuffer = LPVOID(0)
uLen = UI... | null |
177,111 | from winappdbg.win32.defines import *
from winappdbg.win32.advapi32 import *
def WTSFreeMemory(pMemory):
_WTSFreeMemory = windll.wtsapi32.WTSFreeMemory
_WTSFreeMemory.argtypes = [PVOID]
_WTSFreeMemory.restype = None
_WTSFreeMemory(pMemory) | null |
177,112 | from winappdbg.win32.defines import *
from winappdbg.win32.advapi32 import *
WTS_CURRENT_SERVER_HANDLE = 0
PWTS_PROCESS_INFOA = POINTER(WTS_PROCESS_INFOA)
def WTSEnumerateProcessesA(hServer = WTS_CURRENT_SERVER_HANDLE):
_WTSEnumerateProcessesA = windll.wtsapi32.WTSEnumerateProcessesA
_WTSEnumerateProcessesA.ar... | null |
177,113 | from winappdbg.win32.defines import *
from winappdbg.win32.advapi32 import *
WTS_CURRENT_SERVER_HANDLE = 0
PWTS_PROCESS_INFOW = POINTER(WTS_PROCESS_INFOW)
def WTSEnumerateProcessesW(hServer = WTS_CURRENT_SERVER_HANDLE):
_WTSEnumerateProcessesW = windll.wtsapi32.WTSEnumerateProcessesW
_WTSEnumerateProcessesW.ar... | null |
177,114 | from winappdbg.win32.defines import *
from winappdbg.win32.advapi32 import *
def WTSTerminateProcess(hServer, ProcessId, ExitCode):
_WTSTerminateProcess = windll.wtsapi32.WTSTerminateProcess
_WTSTerminateProcess.argtypes = [HANDLE, DWORD, DWORD]
_WTSTerminateProcess.restype = bool
_WTSTerminateProcess... | null |
177,115 | from winappdbg.win32.defines import *
from winappdbg.win32.advapi32 import *
def ProcessIdToSessionId(dwProcessId):
_ProcessIdToSessionId = windll.kernel32.ProcessIdToSessionId
_ProcessIdToSessionId.argtypes = [DWORD, PDWORD]
_ProcessIdToSessionId.restype = bool
_ProcessIdToSessionId.errcheck = RaiseI... | null |
177,116 | from winappdbg.win32.defines import *
from winappdbg.win32.advapi32 import *
def WTSGetActiveConsoleSessionId():
_WTSGetActiveConsoleSessionId = windll.kernel32.WTSGetActiveConsoleSessionId
_WTSGetActiveConsoleSessionId.argtypes = []
_WTSGetActiveConsoleSessionId.restype = DWORD
_WTSGetActiveConsoleSe... | null |
177,117 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def _load_latest_dbghelp_dll():
from os import getenv
from os.path import join, exists
program_files_location = getenv("ProgramFiles")
if not program_files_location:
program_file... | null |
177,118 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
MakeSureDirectoryPathExists = GuessStringType(MakeSureDirectoryPathExistsA, MakeSureDirectoryPathExistsW)
def MakeSureDirectoryPathExistsA(DirPath):
_MakeSureDirectoryPathExists = windll.dbghelp.MakeS... | null |
177,119 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
SymInitialize = GuessStringType(SymInitializeA, SymInitializeW)
def SymInitializeA(hProcess, UserSearchPath = None, fInvadeProcess = False):
_SymInitialize = windll.dbghelp.SymInitialize
_SymIniti... | null |
177,120 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymCleanup(hProcess):
_SymCleanup = windll.dbghelp.SymCleanup
_SymCleanup.argtypes = [HANDLE]
_SymCleanup.restype = bool
_SymCleanup.errcheck = RaiseIfZero
_SymCleanup(hProcess) | null |
177,121 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymRefreshModuleList(hProcess):
_SymRefreshModuleList = windll.dbghelp.SymRefreshModuleList
_SymRefreshModuleList.argtypes = [HANDLE]
_SymRefreshModuleList.restype = bool
_SymRefreshM... | null |
177,122 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymSetParentWindow(hwnd):
_SymSetParentWindow = windll.dbghelp.SymSetParentWindow
_SymSetParentWindow.argtypes = [HWND]
_SymSetParentWindow.restype = bool
_SymSetParentWindow.errcheck... | null |
177,123 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymSetOptions(SymOptions):
_SymSetOptions = windll.dbghelp.SymSetOptions
_SymSetOptions.argtypes = [DWORD]
_SymSetOptions.restype = DWORD
_SymSetOptions.errcheck = RaiseIfZero
_Sy... | null |
177,124 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymGetOptions():
_SymGetOptions = windll.dbghelp.SymGetOptions
_SymGetOptions.argtypes = []
_SymGetOptions.restype = DWORD
return _SymGetOptions() | null |
177,125 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
SymLoadModule = GuessStringType(SymLoadModuleA, SymLoadModuleW)
def SymLoadModuleA(hProcess, hFile = None, ImageName = None, ModuleName = None, BaseOfDll = None, SizeOfDll = None):
_SymLoadModule = wi... | null |
177,126 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
SymLoadModule64 = GuessStringType(SymLoadModule64A, SymLoadModule64W)
def SymLoadModule64A(hProcess, hFile = None, ImageName = None, ModuleName = None, BaseOfDll = None, SizeOfDll = None):
_SymLoadMod... | null |
177,127 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymUnloadModule(hProcess, BaseOfDll):
_SymUnloadModule = windll.dbghelp.SymUnloadModule
_SymUnloadModule.argtypes = [HANDLE, DWORD]
_SymUnloadModule.restype = bool
_SymUnloadModule.er... | null |
177,128 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymUnloadModule64(hProcess, BaseOfDll):
_SymUnloadModule64 = windll.dbghelp.SymUnloadModule64
_SymUnloadModule64.argtypes = [HANDLE, DWORD64]
_SymUnloadModule64.restype = bool
_SymUnl... | null |
177,129 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
class IMAGEHLP_MODULE (Structure):
_fields_ = [
("SizeOfStruct", DWORD),
("BaseOfImage", DWORD),
("ImageSize", DWORD),
("TimeDateStamp", DWORD),
(... | null |
177,130 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
class IMAGEHLP_MODULEW (Structure):
_fields_ = [
("SizeOfStruct", DWORD),
("BaseOfImage", DWORD),
("ImageSize", DWORD),
("TimeDateStamp", DWORD),
... | null |
177,131 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
class IMAGEHLP_MODULE64 (Structure):
_fields_ = [
("SizeOfStruct", DWORD),
("BaseOfImage", DWORD64),
("ImageSize", DWORD),
("TimeDateStamp", DWORD),
... | null |
177,132 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymGetModuleInfo64W(hProcess, dwAddr):
_SymGetModuleInfo64W = windll.dbghelp.SymGetModuleInfo64W
_SymGetModuleInfo64W.argtypes = [HANDLE, DWORD64, PIMAGEHLP_MODULE64W]
_SymGetModuleInfo64W... | null |
177,133 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
PSYM_ENUMMODULES_CALLBACK = WINFUNCTYPE(BOOL, LPSTR, DWORD, PVOID)
SymEnumerateModules = GuessStringType(SymEnumerateModulesA, SymEnumerateModulesW)
def SymEnumerateModulesA(hProcess, EnumModulesCal... | null |
177,134 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
PSYM_ENUMMODULES_CALLBACKW = WINFUNCTYPE(BOOL, LPWSTR, DWORD, PVOID)
def SymEnumerateModulesW(hProcess, EnumModulesCallback, UserContext = None):
_SymEnumerateModulesW = windll.dbghelp.SymEnumerat... | null |
177,135 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
PSYM_ENUMMODULES_CALLBACK64 = WINFUNCTYPE(BOOL, LPSTR, DWORD64, PVOID)
SymEnumerateModules64 = GuessStringType(SymEnumerateModules64A, SymEnumerateModules64W)
def SymEnumerateModules64A(hProcess, EnumMo... | null |
177,136 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymEnumerateModules64W(hProcess, EnumModulesCallback, UserContext = None):
_SymEnumerateModules64W = windll.dbghelp.SymEnumerateModules64W
_SymEnumerateModules64W.argtypes = [HANDLE, PSYM_ENUM... | null |
177,137 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
PSYM_ENUMSYMBOLS_CALLBACK = WINFUNCTYPE(BOOL, LPSTR, DWORD, ULONG, PVOID)
SymEnumerateSymbols = GuessStringType(SymEnumerateSymbolsA, SymEnumerateSymbolsW)
def SymEnumerateSymbolsA(hProcess, BaseOfD... | null |
177,138 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
PSYM_ENUMSYMBOLS_CALLBACKW = WINFUNCTYPE(BOOL, LPWSTR, DWORD, ULONG, PVOID)
def SymEnumerateSymbolsW(hProcess, BaseOfDll, EnumSymbolsCallback, UserContext = None):
_SymEnumerateSymbolsW = windll.d... | null |
177,139 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
PSYM_ENUMSYMBOLS_CALLBACK64 = WINFUNCTYPE(BOOL, LPSTR, DWORD64, ULONG, PVOID)
SymEnumerateSymbols64 = GuessStringType(SymEnumerateSymbols64A, SymEnumerateSymbols64W)
def SymEnumerateSymbols64A(hProcess,... | null |
177,140 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymEnumerateSymbols64W(hProcess, BaseOfDll, EnumSymbolsCallback, UserContext = None):
_SymEnumerateSymbols64W = windll.dbghelp.SymEnumerateSymbols64W
_SymEnumerateSymbols64W.argtypes = [HANDLE... | null |
177,141 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
UNDNAME_COMPLETE = 0x0000
UnDecorateSymbolName = GuessStringType(UnDecorateSymbolNameA, UnDecorateSymbolNameW)
def UnDecorateSymbolNameA(DecoratedName, Flags = UNDNAME_COMPLETE):
_UnDec... | null |
177,142 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
UNDNAME_COMPLETE = 0x0000
def UnDecorateSymbolNameW(DecoratedName, Flags = UNDNAME_COMPLETE):
_UnDecorateSymbolNameW = windll.dbghelp.UnDecorateSymbolNameW
_UnDecorateSymbolNameW.ar... | null |
177,143 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
SymGetSearchPath = GuessStringType(SymGetSearchPathA, SymGetSearchPathW)
def SymGetSearchPathA(hProcess):
_SymGetSearchPath = windll.dbghelp.SymGetSearchPath
_SymGetSearchPath.argtypes = [HANDLE, ... | null |
177,144 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymGetSearchPathW(hProcess):
_SymGetSearchPathW = windll.dbghelp.SymGetSearchPathW
_SymGetSearchPathW.argtypes = [HANDLE, LPWSTR, DWORD]
_SymGetSearchPathW.restype = bool
_SymGetSearc... | null |
177,145 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
SymSetSearchPath = GuessStringType(SymSetSearchPathA, SymSetSearchPathW)
def SymSetSearchPathA(hProcess, SearchPath = None):
_SymSetSearchPath = windll.dbghelp.SymSetSearchPath
_SymSetSearchPath.a... | null |
177,146 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymSetSearchPathW(hProcess, SearchPath = None):
_SymSetSearchPathW = windll.dbghelp.SymSetSearchPathW
_SymSetSearchPathW.argtypes = [HANDLE, LPWSTR]
_SymSetSearchPathW.restype = bool
... | null |
177,147 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymGetHomeDirectoryA(type):
_SymGetHomeDirectoryA = windll.dbghelp.SymGetHomeDirectoryA
_SymGetHomeDirectoryA.argtypes = [DWORD, LPSTR, SIZE_T]
_SymGetHomeDirectoryA.restype = LPSTR
_... | null |
177,148 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymGetHomeDirectoryW(type):
_SymGetHomeDirectoryW = windll.dbghelp.SymGetHomeDirectoryW
_SymGetHomeDirectoryW.argtypes = [DWORD, LPWSTR, SIZE_T]
_SymGetHomeDirectoryW.restype = LPWSTR
... | null |
177,149 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymSetHomeDirectoryA(hProcess, dir = None):
_SymSetHomeDirectoryA = windll.dbghelp.SymSetHomeDirectoryA
_SymSetHomeDirectoryA.argtypes = [HANDLE, LPSTR]
_SymSetHomeDirectoryA.restype = LP... | null |
177,150 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
def SymSetHomeDirectoryW(hProcess, dir = None):
_SymSetHomeDirectoryW = windll.dbghelp.SymSetHomeDirectoryW
_SymSetHomeDirectoryW.argtypes = [HANDLE, LPWSTR]
_SymSetHomeDirectoryW.restype = L... | null |
177,151 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
MAX_SYM_NAME = 2000
class SYM_INFO(Structure):
_fields_ = [
("SizeOfStruct", ULONG),
("TypeIndex", ULONG),
("Reserved", ULONG64 * 2),
("Index", ... | null |
177,152 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
MAX_SYM_NAME = 2000
class SYM_INFOW(Structure):
_fields_ = [
("SizeOfStruct", ULONG),
("TypeIndex", ULONG),
("Reserved", ULONG64 * 2),
("Index", ... | null |
177,153 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
MAX_SYM_NAME = 2000
class SYM_INFO(Structure):
_fields_ = [
("SizeOfStruct", ULONG),
("TypeIndex", ULONG),
("Reserved", ULONG64 * 2),
("Index", ... | null |
177,154 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
MAX_SYM_NAME = 2000
class SYM_INFOW(Structure):
_fields_ = [
("SizeOfStruct", ULONG),
("TypeIndex", ULONG),
("Reserved", ULONG64 * 2),
("Index", ... | null |
177,155 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
MAX_SYM_NAME = 2000
class IMAGEHLP_SYMBOL64 (Structure):
_fields_ = [
("SizeOfStruct", DWORD),
("Address", DWORD64),
("Size", DWORD),
("Flags", ... | null |
177,156 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
LPAPI_VERSION = PAPI_VERSION
def ImagehlpApiVersion():
_ImagehlpApiVersion = windll.dbghelp.ImagehlpApiVersion
_ImagehlpApiVersion.restype = LPAPI_VERSION
api_version = _ImagehlpApiVersion()
... | null |
177,157 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
class API_VERSION (Structure):
_fields_ = [
("MajorVersion", USHORT),
("MinorVersion", USHORT),
("Revision", USHORT),
("Reserved", USHORT),
]
LPA... | null |
177,158 | from winappdbg.win32.defines import *
from winappdbg.win32.version import *
from winappdbg.win32.kernel32 import *
LPSTACKFRAME64 = POINTER(STACKFRAME64)
PREAD_PROCESS_MEMORY_ROUTINE64 = WINFUNCTYPE(BOOL, HANDLE, DWORD64, PVOID, DWORD, LPDWORD)
PFUNCTION_TABLE_ACCESS_ROUTINE64 = WINFUNCTYPE(PVOID, HANDLE, DWORD64)
PGET... | null |
177,159 | from winappdbg.win32.defines import *
from winappdbg.win32.version import ARCH_I386
class LDT_ENTRY(Structure):
LPLDT_ENTRY = PLDT_ENTRY
def GetThreadSelectorEntry(hThread, dwSelector):
_GetThreadSelectorEntry = windll.kernel32.GetThreadSelectorEntry
_GetThreadSelectorEntry.argtypes = [HANDLE, DWORD, LPLDT_ENT... | null |
177,160 | from winappdbg.win32.defines import *
from winappdbg.win32.version import ARCH_I386
CONTEXT_i386 = 0x00010000
CONTEXT_ALL = (CONTEXT_CONTROL | CONTEXT_INTEGER | CONTEXT_SEGMENTS | \
CONTEXT_FLOATING_POINT | CONTEXT_DEBUG_REGISTERS | \
CONTEXT_EXTENDED_REGISTERS)
clas... | null |
177,161 | from winappdbg.win32.defines import *
from winappdbg.win32.version import ARCH_I386
class CONTEXT(Structure):
arch = ARCH_I386
_pack_ = 1
# Context Frame
#
# This frame has a several purposes: 1) it is used as an argument to
# NtContinue, 2) is is used to constuct a call frame for APC delivery... | null |
177,162 | from winappdbg.win32.defines import *
from winappdbg.win32.peb_teb import *
SYSDBG_COMMAND = DWORD
def RtlNtStatusToDosError(Status):
_RtlNtStatusToDosError = windll.ntdll.RtlNtStatusToDosError
_RtlNtStatusToDosError.argtypes = [NTSTATUS]
_RtlNtStatusToDosError.restype = ULONG
return _RtlNtStat... | null |
177,163 | from winappdbg.win32.defines import *
from winappdbg.win32.peb_teb import *
PROCESSINFOCLASS = DWORD
ProcessBasicInformation = 0
ProcessDebugPort = 7
ProcessWx86Information = 19
ProcessHandleCount = 20
ProcessPriorityBoost = 22
ProcessWo... | null |
177,164 | from winappdbg.win32.defines import *
from winappdbg.win32.peb_teb import *
THREADINFOCLASS = DWORD
ThreadBasicInformation = 0
ThreadQuerySetWin32StartAddress = 9
ThreadPerformanceCount = 11
ThreadAmILastThread = 12
ThreadPriorityBoost = 14
ThreadHid... | null |
177,165 | from winappdbg.win32.defines import *
from winappdbg.win32.peb_teb import *
class IO_STATUS_BLOCK(Structure):
_fields_ = [
("Status", NTSTATUS),
("Information", ULONG_PTR),
]
def __get_Pointer(self):
return PVOID(self.Status)
def __set_Pointer(self, ptr):
self.Status... | null |
177,166 | from winappdbg.win32.defines import *
from winappdbg.win32.peb_teb import *
def CsrGetProcessId():
_CsrGetProcessId = windll.ntdll.CsrGetProcessId
_CsrGetProcessId.argtypes = []
_CsrGetProcessId.restype = DWORD
return _CsrGetProcessId() | null |
177,167 | from winappdbg.win32.defines import *
from winappdbg.win32.kernel32 import LocalFree
def CommandLineToArgvW(lpCmdLine):
_CommandLineToArgvW = windll.shell32.CommandLineToArgvW
_CommandLineToArgvW.argtypes = [LPVOID, POINTER(ctypes.c_int)]
_CommandLineToArgvW.restype = LPVOID
if not lpCmdLine:
l... | null |
177,168 | from winappdbg.win32.defines import *
from winappdbg.win32.kernel32 import LocalFree
def ShellExecuteA(hwnd = None, lpOperation = None, lpFile = None, lpParameters = None, lpDirectory = None, nShowCmd = None):
_ShellExecuteA = windll.shell32.ShellExecuteA
_ShellExecuteA.argtypes = [HWND, LPSTR, LPSTR, LPSTR, L... | null |
177,169 | from winappdbg.win32.defines import *
from winappdbg.win32.kernel32 import LocalFree
def ShellExecuteW(hwnd = None, lpOperation = None, lpFile = None, lpParameters = None, lpDirectory = None, nShowCmd = None):
_ShellExecuteW = windll.shell32.ShellExecuteW
_ShellExecuteW.argtypes = [HWND, LPWSTR, LPWSTR, LPWSTR... | null |
177,170 | from winappdbg.win32.defines import *
from winappdbg.win32.kernel32 import LocalFree
def ShellExecuteExA(lpExecInfo):
_ShellExecuteExA = windll.shell32.ShellExecuteExA
_ShellExecuteExA.argtypes = [LPSHELLEXECUTEINFOA]
_ShellExecuteExA.restype = BOOL
_ShellExecuteExA.errcheck = RaiseIfZero
_ShellExe... | null |
177,171 | from winappdbg.win32.defines import *
from winappdbg.win32.kernel32 import LocalFree
def FindExecutableA(lpFile, lpDirectory = None):
_FindExecutableA = windll.shell32.FindExecutableA
_FindExecutableA.argtypes = [LPSTR, LPSTR, LPSTR]
_FindExecutableA.restype = HINSTANCE
lpResult = ctypes.create_strin... | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.