C:/Web/handle/src/handle.h File Reference

#include <stdio.h>
#include <windows.h>
#include <psapi.h>
#include <shlwapi.h>

Go to the source code of this file.

Data Structures

struct  _credenciales
struct  _IO_STATUS_BLOCK
struct  _TDI_REQUEST
struct  _TDI_CONNECTION_INFORMATION
struct  _TDI_REQUEST_QUERY_INFORMATION
struct  _SYSTEM_HANDLE
struct  _SYSTEM_HANDLE_INFORMATION
struct  _UNICODE_STRING
struct  _PROCESS_BASIC_INFORMATION
struct  _FILE_NAME_INFORMATION

Defines

#define MAX_USERS   1000
#define TDI_QUERY_ADDRESS_INFO   0x00000003
#define IOCTL_TDI_QUERY_INFORMATION   CTL_CODE(FILE_DEVICE_TRANSPORT, 4, METHOD_OUT_DIRECT, FILE_ANY_ACCESS)
#define STATUS_SUCCESS   ((NTSTATUS)0x00000000L)
#define STATUS_INFO_LENGTH_MISMATCH   ((NTSTATUS)0xC0000004L)
#define STATUS_BUFFER_OVERFLOW   ((NTSTATUS)0x80000005L)
#define SystemHandleInformation   16
#define OBJTOKEN   1
#define OBJTHREAD   2
#define OBJPROCESS   3
#define OBJFILE   4
#define OBJUNKNOWN   5

Typedefs

typedef struct _credenciales CREDENCIALES
typedef LONG NTSTATUS
typedef VOID * POBJECT
typedef struct _IO_STATUS_BLOCK IO_STATUS_BLOCK
typedef struct _IO_STATUS_BLOCKPIO_STATUS_BLOCK
typedef void(WINAPI * PIO_APC_ROUTINE )(PVOID, PIO_STATUS_BLOCK, DWORD)
typedef LONG TDI_STATUS
typedef PVOID CONNECTION_CONTEXT
typedef struct _TDI_REQUEST TDI_REQUEST
typedef struct _TDI_REQUESTPTDI_REQUEST
typedef struct
_TDI_CONNECTION_INFORMATION 
TDI_CONNECTION_INFORMATION
typedef struct
_TDI_CONNECTION_INFORMATION
PTDI_CONNECTION_INFORMATION
typedef struct
_TDI_REQUEST_QUERY_INFORMATION 
TDI_REQUEST_QUERY_INFORMATION
typedef struct
_TDI_REQUEST_QUERY_INFORMATION
PTDI_REQUEST_QUERY_INFORMATION
typedef struct _SYSTEM_HANDLE SYSTEM_HANDLE
typedef struct _SYSTEM_HANDLEPSYSTEM_HANDLE
typedef struct
_SYSTEM_HANDLE_INFORMATION 
SYSTEM_HANDLE_INFORMATION
typedef struct
_SYSTEM_HANDLE_INFORMATION
PSYSTEM_HANDLE_INFORMATION
typedef struct _UNICODE_STRING UNICODE_STRING
typedef UNICODE_STRINGPUNICODE_STRING
typedef const UNICODE_STRINGPCUNICODE_STRING
typedef UNICODE_STRING OBJECT_NAME_INFORMATION
typedef UNICODE_STRINGPOBJECT_NAME_INFORMATION
typedef enum
_OBJECT_INFORMATION_CLASS 
OBJECT_INFORMATION_CLASS
typedef enum _PROCESSINFOCLASS PROCESSINFOCLASS
typedef enum _THREADINFOCLASS THREADINFOCLASS
typedef struct
_PROCESS_BASIC_INFORMATION 
PROCESS_BASIC_INFORMATION
typedef enum
_FILE_INFORMATION_CLASS 
FILE_INFORMATION_CLASS
typedef enum
_FILE_INFORMATION_CLASS
PFILE_INFORMATION_CLASS
typedef struct
_FILE_NAME_INFORMATION 
FILE_NAME_INFORMATION
typedef struct
_FILE_NAME_INFORMATION
PFILE_NAME_INFORMATION
typedef PROCESSINFOCLASS ProcessInformationClass
typedef PROCESSINFOCLASS PVOID ProcessInformation
typedef PROCESSINFOCLASS PVOID
DWORD 
ProcessInformationLength
typedef PROCESSINFOCLASS PVOID
DWORD DWORD * 
ReturnLength
typedef NTSTATUS(WINAPI * NTQUERYSYSTEMINFORMATION )(DWORD SystemInformationClass, PVOID SystemInformation, DWORD SystemInformationLength, PDWORD ReturnLength)
typedef NTSTATUS(WINAPI * NTQUERYOBJECT )(HANDLE ObjectHandle, OBJECT_INFORMATION_CLASS ObjectInformationClass, PVOID ObjectInformation, DWORD Length, PDWORD ResultLength)
typedef NTSTATUS(WINAPI * NTDEVICEIOCONTROLFILE )(HANDLE FileHandle, HANDLE Event, PIO_APC_ROUTINE ApcRoutine, PVOID ApcContext, PIO_STATUS_BLOCK IoStatusBlock, DWORD IoControlCode, PVOID InputBuffer, DWORD InputBufferLength, PVOID OutputBuffer, DWORD OutputBufferLength)
typedef THREADINFOCLASS ThreadInfoClass
typedef THREADINFOCLASS PVOID ThreadInformation
typedef THREADINFOCLASS PVOID DWORD Length
typedef PVOID IoStatusBlock
typedef PVOID PVOID FileInformation
typedef PVOID PVOID DWORD DWORD FileInformationClass
typedef HANDLE SecondTokenHandle
typedef HANDLE PBOOLEAN Equal

Enumerations

enum  _OBJECT_INFORMATION_CLASS {
  ObjectBasicInformation, ObjectNameInformation, ObjectTypeInformation, ObjectAllTypesInformation,
  ObjectHandleInformation
}
enum  _PROCESSINFOCLASS {
  ProcessBasicInformation, ProcessQuotaLimits, ProcessIoCounters, ProcessVmCounters,
  ProcessTimes, ProcessBasePriority, ProcessRaisePriority, ProcessDebugPort,
  ProcessExceptionPort, ProcessAccessToken, ProcessLdtInformation, ProcessLdtSize,
  ProcessDefaultHardErrorMode, ProcessIoPortHandlers, ProcessPooledUsageAndLimits, ProcessWorkingSetWatch,
  ProcessUserModeIOPL, ProcessEnableAlignmentFaultFixup, ProcessPriorityClass, MaxProcessInfoClass
}
enum  _THREADINFOCLASS {
  ThreadBasicInformation, ThreadTimes, ThreadPriority, ThreadBasePriority,
  ThreadAffinityMask, ThreadImpersonationToken, ThreadDescriptorTableEntry, ThreadEnableAlignmentFaultFixup,
  ThreadEventPair, ThreadQuerySetWin32StartAddress, ThreadZeroTlsCell, ThreadPerformanceCount,
  ThreadAmILastThread, MaxThreadInfoClass
}
enum  _FILE_INFORMATION_CLASS {
  FileDirectoryInformation, FileFullDirectoryInformation, FileBothDirectoryInformation, FileBasicInformation,
  FileStandardInformation, FileInternalInformation, FileEaInformation, FileAccessInformation,
  FileNameInformation, FileRenameInformation, FileLinkInformation, FileNamesInformation,
  FileDispositionInformation, FilePositionInformation, FileFullEaInformation, FileModeInformation,
  FileAlignmentInformation, FileAllInformation, FileAllocationInformation, FileEndOfFileInformation,
  FileAlternateNameInformation, FileStreamInformation, FilePipeInformation, FilePipeLocalInformation,
  FilePipeRemoteInformation, FileMailslotQueryInformation, FileMailslotSetInformation, FileCompressionInformation,
  FileCopyOnWriteInformation, FileCompletionInformation, FileMoveClusterInformation, FileQuotaInformation,
  FileReparsePointInformation, FileNetworkOpenInformation, FileObjectIdInformation, FileTrackingInformation,
  FileOleDirectoryInformation, FileContentIndexInformation, FileInheritContentIndexInformation, FileOleInformation,
  FileMaximumInformation
}

Functions

typedef NTSTATUS (WINAPI *NTQUERYINFORMATIONPROCESS)(HANDLE ProcessHandle


Define Documentation

#define IOCTL_TDI_QUERY_INFORMATION   CTL_CODE(FILE_DEVICE_TRANSPORT, 4, METHOD_OUT_DIRECT, FILE_ANY_ACCESS)

Definition at line 71 of file handle.h.

Referenced by main().

#define MAX_USERS   1000

Definition at line 23 of file handle.h.

#define OBJFILE   4

Definition at line 276 of file handle.h.

Referenced by GetOption(), and main().

#define OBJPROCESS   3

Definition at line 275 of file handle.h.

Referenced by GetOption(), and main().

#define OBJTHREAD   2

Definition at line 274 of file handle.h.

Referenced by GetOption(), and main().

#define OBJTOKEN   1

Definition at line 273 of file handle.h.

Referenced by GetOption(), and main().

#define OBJUNKNOWN   5

Definition at line 277 of file handle.h.

Referenced by GetOption().

#define STATUS_BUFFER_OVERFLOW   ((NTSTATUS)0x80000005L)

Definition at line 111 of file handle.h.

Referenced by GetObjectInfo().

#define STATUS_INFO_LENGTH_MISMATCH   ((NTSTATUS)0xC0000004L)

Definition at line 110 of file handle.h.

Referenced by GetObjectInfo(), and main().

#define STATUS_SUCCESS   ((NTSTATUS)0x00000000L)

Definition at line 109 of file handle.h.

Referenced by GetObjectInfo(), and main().

#define SystemHandleInformation   16

Definition at line 112 of file handle.h.

Referenced by main().

#define TDI_QUERY_ADDRESS_INFO   0x00000003

Definition at line 70 of file handle.h.

Referenced by main().


Typedef Documentation

typedef PVOID CONNECTION_CONTEXT

Definition at line 41 of file handle.h.

typedef struct _credenciales CREDENCIALES

typedef HANDLE PBOOLEAN Equal

Definition at line 268 of file handle.h.

typedef enum _FILE_INFORMATION_CLASS FILE_INFORMATION_CLASS

typedef struct _FILE_NAME_INFORMATION FILE_NAME_INFORMATION

typedef PVOID PVOID FileInformation

Definition at line 260 of file handle.h.

typedef PVOID PVOID DWORD DWORD FileInformationClass

Definition at line 260 of file handle.h.

typedef struct _IO_STATUS_BLOCK IO_STATUS_BLOCK

typedef PVOID IoStatusBlock

Definition at line 260 of file handle.h.

typedef PVOID PVOID DWORD Length

Definition at line 252 of file handle.h.

typedef NTSTATUS(WINAPI * NTDEVICEIOCONTROLFILE)(HANDLE FileHandle, HANDLE Event, PIO_APC_ROUTINE ApcRoutine, PVOID ApcContext, PIO_STATUS_BLOCK IoStatusBlock, DWORD IoControlCode, PVOID InputBuffer, DWORD InputBufferLength, PVOID OutputBuffer, DWORD OutputBufferLength)

Definition at line 239 of file handle.h.

typedef NTSTATUS(WINAPI * NTQUERYOBJECT)(HANDLE ObjectHandle, OBJECT_INFORMATION_CLASS ObjectInformationClass, PVOID ObjectInformation, DWORD Length, PDWORD ResultLength)

Definition at line 232 of file handle.h.

typedef NTSTATUS(WINAPI * NTQUERYSYSTEMINFORMATION)(DWORD SystemInformationClass, PVOID SystemInformation, DWORD SystemInformationLength, PDWORD ReturnLength)

Definition at line 227 of file handle.h.

typedef NTSTATUS

Definition at line 25 of file handle.h.

typedef enum _OBJECT_INFORMATION_CLASS OBJECT_INFORMATION_CLASS

typedef UNICODE_STRING OBJECT_NAME_INFORMATION

Definition at line 97 of file handle.h.

typedef const UNICODE_STRING* PCUNICODE_STRING

Definition at line 95 of file handle.h.

typedef enum _FILE_INFORMATION_CLASS * PFILE_INFORMATION_CLASS

typedef struct _FILE_NAME_INFORMATION * PFILE_NAME_INFORMATION

typedef void(WINAPI * PIO_APC_ROUTINE)(PVOID, PIO_STATUS_BLOCK, DWORD)

Definition at line 38 of file handle.h.

typedef struct _IO_STATUS_BLOCK * PIO_STATUS_BLOCK

typedef VOID* POBJECT

Definition at line 26 of file handle.h.

typedef UNICODE_STRING* POBJECT_NAME_INFORMATION

Definition at line 98 of file handle.h.

typedef struct _PROCESS_BASIC_INFORMATION PROCESS_BASIC_INFORMATION

typedef enum _PROCESSINFOCLASS PROCESSINFOCLASS

typedef PROCESSINFOCLASS PVOID ProcessInformation

Definition at line 222 of file handle.h.

typedef PROCESSINFOCLASS ProcessInformationClass

Definition at line 222 of file handle.h.

typedef PROCESSINFOCLASS PVOID DWORD ProcessInformationLength

Definition at line 222 of file handle.h.

typedef struct _SYSTEM_HANDLE * PSYSTEM_HANDLE

typedef struct _SYSTEM_HANDLE_INFORMATION * PSYSTEM_HANDLE_INFORMATION

typedef struct _TDI_CONNECTION_INFORMATION * PTDI_CONNECTION_INFORMATION

typedef struct _TDI_REQUEST * PTDI_REQUEST

typedef struct _TDI_REQUEST_QUERY_INFORMATION * PTDI_REQUEST_QUERY_INFORMATION

typedef UNICODE_STRING* PUNICODE_STRING

Definition at line 94 of file handle.h.

typedef THREADINFOCLASS PVOID DWORD DWORD * ReturnLength

Definition at line 222 of file handle.h.

typedef HANDLE SecondTokenHandle

Definition at line 268 of file handle.h.

typedef struct _SYSTEM_HANDLE SYSTEM_HANDLE

typedef struct _SYSTEM_HANDLE_INFORMATION SYSTEM_HANDLE_INFORMATION

typedef struct _TDI_CONNECTION_INFORMATION TDI_CONNECTION_INFORMATION

typedef struct _TDI_REQUEST TDI_REQUEST

typedef struct _TDI_REQUEST_QUERY_INFORMATION TDI_REQUEST_QUERY_INFORMATION

typedef LONG TDI_STATUS

Definition at line 40 of file handle.h.

typedef THREADINFOCLASS ThreadInfoClass

Definition at line 252 of file handle.h.

typedef enum _THREADINFOCLASS THREADINFOCLASS

typedef THREADINFOCLASS PVOID ThreadInformation

Definition at line 252 of file handle.h.

typedef struct _UNICODE_STRING UNICODE_STRING


Enumeration Type Documentation

enum _FILE_INFORMATION_CLASS

Enumerator:
FileDirectoryInformation 
FileFullDirectoryInformation 
FileBothDirectoryInformation 
FileBasicInformation 
FileStandardInformation 
FileInternalInformation 
FileEaInformation 
FileAccessInformation 
FileNameInformation 
FileRenameInformation 
FileLinkInformation 
FileNamesInformation 
FileDispositionInformation 
FilePositionInformation 
FileFullEaInformation 
FileModeInformation 
FileAlignmentInformation 
FileAllInformation 
FileAllocationInformation 
FileEndOfFileInformation 
FileAlternateNameInformation 
FileStreamInformation 
FilePipeInformation 
FilePipeLocalInformation 
FilePipeRemoteInformation 
FileMailslotQueryInformation 
FileMailslotSetInformation 
FileCompressionInformation 
FileCopyOnWriteInformation 
FileCompletionInformation 
FileMoveClusterInformation 
FileQuotaInformation 
FileReparsePointInformation 
FileNetworkOpenInformation 
FileObjectIdInformation 
FileTrackingInformation 
FileOleDirectoryInformation 
FileContentIndexInformation 
FileInheritContentIndexInformation 
FileOleInformation 
FileMaximumInformation 

Definition at line 167 of file handle.h.

enum _OBJECT_INFORMATION_CLASS

Enumerator:
ObjectBasicInformation 
ObjectNameInformation 
ObjectTypeInformation 
ObjectAllTypesInformation 
ObjectHandleInformation 

Definition at line 101 of file handle.h.

enum _PROCESSINFOCLASS

Enumerator:
ProcessBasicInformation 
ProcessQuotaLimits 
ProcessIoCounters 
ProcessVmCounters 
ProcessTimes 
ProcessBasePriority 
ProcessRaisePriority 
ProcessDebugPort 
ProcessExceptionPort 
ProcessAccessToken 
ProcessLdtInformation 
ProcessLdtSize 
ProcessDefaultHardErrorMode 
ProcessIoPortHandlers 
ProcessPooledUsageAndLimits 
ProcessWorkingSetWatch 
ProcessUserModeIOPL 
ProcessEnableAlignmentFaultFixup 
ProcessPriorityClass 
MaxProcessInfoClass 

Definition at line 115 of file handle.h.

enum _THREADINFOCLASS

Enumerator:
ThreadBasicInformation 
ThreadTimes 
ThreadPriority 
ThreadBasePriority 
ThreadAffinityMask 
ThreadImpersonationToken 
ThreadDescriptorTableEntry 
ThreadEnableAlignmentFaultFixup 
ThreadEventPair 
ThreadQuerySetWin32StartAddress 
ThreadZeroTlsCell 
ThreadPerformanceCount 
ThreadAmILastThread 
MaxThreadInfoClass 

Definition at line 139 of file handle.h.


Function Documentation

typedef NTSTATUS ( WINAPI *  NTQUERYINFORMATIONPROCESS  ) 


Generated on Fri Feb 22 14:14:32 2008 for Handle by  doxygen 1.5.4