2 * Copyright 2004-2005 Ivan Leo Puoti
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
26 #define POINTER_ALIGNMENT DECLSPEC_ALIGN(8)
28 #define POINTER_ALIGNMENT
31 typedef LONG KPRIORITY
;
33 typedef ULONG_PTR KSPIN_LOCK
, *PKSPIN_LOCK
;
38 struct _DEVICE_OBJECT
;
39 struct _DRIVER_OBJECT
;
41 typedef VOID (WINAPI
*PKDEFERRED_ROUTINE
)(struct _KDPC
*, PVOID
, PVOID
, PVOID
);
42 typedef VOID (WINAPI
*PKSTART_ROUTINE
)(PVOID
);
44 typedef NTSTATUS (WINAPI
*PDRIVER_INITIALIZE
)(struct _DRIVER_OBJECT
*, PUNICODE_STRING
);
45 typedef NTSTATUS (WINAPI
*PDRIVER_DISPATCH
)(struct _DEVICE_OBJECT
*, struct _IRP
*);
46 typedef void (WINAPI
*PDRIVER_STARTIO
)(struct _DEVICE_OBJECT
*, struct _IRP
*);
47 typedef void (WINAPI
*PDRIVER_UNLOAD
)(struct _DRIVER_OBJECT
*);
49 typedef struct _DISPATCHER_HEADER
{
55 LIST_ENTRY WaitListHead
;
56 } DISPATCHER_HEADER
, *PDISPATCHER_HEADER
;
58 typedef struct _KEVENT
{
59 DISPATCHER_HEADER Header
;
60 } KEVENT
, *PKEVENT
, *RESTRICTED_POINTER PRKEVENT
;
62 typedef struct _KDPC
{
66 LIST_ENTRY DpcListEntry
;
67 PKDEFERRED_ROUTINE DeferredRoutine
;
68 PVOID DeferredContext
;
69 PVOID SystemArgument1
;
70 PVOID SystemArgument2
;
72 } KDPC
, *PKDPC
, *RESTRICTED_POINTER PRKDPC
;
74 typedef struct _KDEVICE_QUEUE_ENTRY
{
75 LIST_ENTRY DeviceListEntry
;
78 } KDEVICE_QUEUE_ENTRY
, *PKDEVICE_QUEUE_ENTRY
,
79 *RESTRICTED_POINTER PRKDEVICE_QUEUE_ENTRY
;
81 typedef struct _KDEVICE_QUEUE
{
84 LIST_ENTRY DeviceListHead
;
87 } KDEVICE_QUEUE
, *PKDEVICE_QUEUE
, *RESTRICTED_POINTER PRKDEVICE_QUEUE
;
89 typedef struct _KMUTANT
{
90 DISPATCHER_HEADER Header
;
91 LIST_ENTRY MutantListEntry
;
92 struct _KTHREAD
*RESTRICTED_POINTER OwnerThread
;
95 } KMUTANT
, *PKMUTANT
, *RESTRICTED_POINTER PRKMUTANT
, KMUTEX
, *PKMUTEX
, *RESTRICTED_POINTER PRKMUTEX
;
97 typedef enum _KWAIT_REASON
127 typedef struct _IO_TIMER
*PIO_TIMER
;
128 typedef struct _ETHREAD
*PETHREAD
;
129 typedef struct _KTHREAD
*PKTHREAD
;
130 typedef struct _EPROCESS
*PEPROCESS
;
131 typedef struct _IO_WORKITEM
*PIO_WORKITEM
;
132 typedef struct _OBJECT_TYPE
*POBJECT_TYPE
;
133 typedef struct _OBJECT_HANDLE_INFORMATION
*POBJECT_HANDLE_INFORMATION
;
135 #define MAXIMUM_VOLUME_LABEL_LENGTH (32 * sizeof(WCHAR))
137 typedef struct _VPB
{
141 USHORT VolumeLabelLength
;
142 struct _DEVICE_OBJECT
*DeviceObject
;
143 struct _DEVICE_OBJECT
*RealDevice
;
145 ULONG ReferenceCount
;
146 WCHAR VolumeLabel
[MAXIMUM_VOLUME_LABEL_LENGTH
/ sizeof(WCHAR
)];
149 typedef enum _POOL_TYPE
{
152 NonPagedPoolMustSucceed
,
154 NonPagedPoolCacheAligned
,
155 PagedPoolCacheAligned
,
156 NonPagedPoolCacheAlignedMustS
,
160 typedef struct _WAIT_CONTEXT_BLOCK
{
161 KDEVICE_QUEUE_ENTRY WaitQueueEntry
;
162 struct _DRIVER_CONTROL
*DeviceRoutine
;
164 ULONG NumberOfMapRegisters
;
167 PKDPC BufferChainingDpc
;
168 } WAIT_CONTEXT_BLOCK
, *PWAIT_CONTEXT_BLOCK
;
170 #define DO_BUFFERED_IO 0x00000004
171 #define DO_EXCLUSIVE 0x00000008
172 #define DO_DIRECT_IO 0x00000010
173 #define DO_MAP_IO_BUFFER 0x00000020
174 #define DO_DEVICE_INITIALIZING 0x00000080
175 #define DO_SHUTDOWN_REGISTERED 0x00000800
176 #define DO_BUS_ENUMERATED_DEVICE 0x00001000
177 #define DO_POWER_PAGABLE 0x00002000
178 #define DO_POWER_INRUSH 0x00004000
180 #define IO_NO_INCREMENT 0
181 #define IO_CD_ROM_INCREMENT 1
182 #define IO_DISK_INCREMENT 1
183 #define IO_KEYBOARD_INCREMENT 6
184 #define IO_MAILSLOT_INCREMENT 2
185 #define IO_MOUSE_INCREMENT 6
186 #define IO_NAMED_PIPE_INCREMENT 2
187 #define IO_NETWORK_INCREMENT 2
188 #define IO_PARALLEL_INCREMENT 1
189 #define IO_SERIAL_INCREMENT 2
190 #define IO_SOUND_INCREMENT 8
191 #define IO_VIDEO_INCREMENT 1
194 #define DEVICE_TYPE ULONG
196 #define IRP_MJ_MAXIMUM_FUNCTION 0x1b
197 #define IRP_MJ_CREATE 0x00
198 #define IRP_MJ_CREATE_NAMED_PIPE 0x01
199 #define IRP_MJ_CLOSE 0x02
200 #define IRP_MJ_READ 0x03
201 #define IRP_MJ_WRITE 0x04
202 #define IRP_MJ_QUERY_INFORMATION 0x05
203 #define IRP_MJ_SET_INFORMATION 0x06
204 #define IRP_MJ_QUERY_EA 0x07
205 #define IRP_MJ_SET_EA 0x08
206 #define IRP_MJ_FLUSH_BUFFERS 0x09
207 #define IRP_MJ_QUERY_VOLUME_INFORMATION 0x0a
208 #define IRP_MJ_SET_VOLUME_INFORMATION 0x0b
209 #define IRP_MJ_DIRECTORY_CONTROL 0x0c
210 #define IRP_MJ_FILE_SYSTEM_CONTROL 0x0d
211 #define IRP_MJ_DEVICE_CONTROL 0x0e
212 #define IRP_MJ_INTERNAL_DEVICE_CONTROL 0x0f
213 #define IRP_MJ_SHUTDOWN 0x10
214 #define IRP_MJ_LOCK_CONTROL 0x11
215 #define IRP_MJ_CLEANUP 0x12
216 #define IRP_MJ_CREATE_MAILSLOT 0x13
217 #define IRP_MJ_QUERY_SECURITY 0x14
218 #define IRP_MJ_SET_SECURITY 0x15
219 #define IRP_MJ_POWER 0x16
220 #define IRP_MJ_SYSTEM_CONTROL 0x17
221 #define IRP_MJ_DEVICE_CHANGE 0x18
222 #define IRP_MJ_QUERY_QUOTA 0x19
223 #define IRP_MJ_SET_QUOTA 0x1a
224 #define IRP_MJ_PNP 0x1b
226 #define IRP_MN_START_DEVICE 0x00
227 #define IRP_MN_QUERY_REMOVE_DEVICE 0x01
228 #define IRP_MN_REMOVE_DEVICE 0x02
229 #define IRP_MN_CANCEL_REMOVE_DEVICE 0x03
230 #define IRP_MN_STOP_DEVICE 0x04
231 #define IRP_MN_QUERY_STOP_DEVICE 0x05
232 #define IRP_MN_CANCEL_STOP_DEVICE 0x06
233 #define IRP_MN_QUERY_DEVICE_RELATIONS 0x07
234 #define IRP_MN_QUERY_INTERFACE 0x08
235 #define IRP_MN_QUERY_CAPABILITIES 0x09
236 #define IRP_MN_QUERY_RESOURCES 0x0A
237 #define IRP_MN_QUERY_RESOURCE_REQUIREMENTS 0x0B
238 #define IRP_MN_QUERY_DEVICE_TEXT 0x0C
239 #define IRP_MN_FILTER_RESOURCE_REQUIREMENTS 0x0D
240 #define IRP_MN_READ_CONFIG 0x0F
241 #define IRP_MN_WRITE_CONFIG 0x10
242 #define IRP_MN_EJECT 0x11
243 #define IRP_MN_SET_LOCK 0x12
244 #define IRP_MN_QUERY_ID 0x13
245 #define IRP_MN_QUERY_PNP_DEVICE_STATE 0x14
246 #define IRP_MN_QUERY_BUS_INFORMATION 0x15
247 #define IRP_MN_DEVICE_USAGE_NOTIFICATION 0x16
248 #define IRP_MN_SURPRISE_REMOVAL 0x17
250 #define IRP_QUOTA_CHARGED 0x01
251 #define IRP_ALLOCATED_MUST_SUCCEED 0x02
252 #define IRP_ALLOCATED_FIXED_SIZE 0x04
253 #define IRP_LOOKASIDE_ALLOCATION 0x08
255 #define IO_TYPE_ADAPTER 0x01
256 #define IO_TYPE_CONTROLLER 0x02
257 #define IO_TYPE_DEVICE 0x03
258 #define IO_TYPE_DRIVER 0x04
259 #define IO_TYPE_FILE 0x05
260 #define IO_TYPE_IRP 0x06
261 #define IO_TYPE_MASTER_ADAPTER 0x07
262 #define IO_TYPE_OPEN_PACKET 0x08
263 #define IO_TYPE_TIMER 0x09
264 #define IO_TYPE_VPB 0x0a
265 #define IO_TYPE_ERROR_LOG 0x0b
266 #define IO_TYPE_ERROR_MESSAGE 0x0c
267 #define IO_TYPE_DEVICE_OBJECT_EXTENSION 0x0d
269 typedef struct _DEVICE_OBJECT
{
273 struct _DRIVER_OBJECT
*DriverObject
;
274 struct _DEVICE_OBJECT
*NextDevice
;
275 struct _DEVICE_OBJECT
*AttachedDevice
;
276 struct _IRP
*CurrentIrp
;
279 ULONG Characteristics
;
281 PVOID DeviceExtension
;
282 DEVICE_TYPE DeviceType
;
285 LIST_ENTRY ListEntry
;
286 WAIT_CONTEXT_BLOCK Wcb
;
288 ULONG AlignmentRequirement
;
289 KDEVICE_QUEUE DeviceQueue
;
291 ULONG ActiveThreadCount
;
292 PSECURITY_DESCRIPTOR SecurityDescriptor
;
296 struct _DEVOBJ_EXTENSION
*DeviceObjectExtension
;
299 typedef struct _DEVICE_OBJECT
*PDEVICE_OBJECT
;
301 typedef struct _DRIVER_EXTENSION
{
302 struct _DRIVER_OBJECT
*DriverObject
;
305 UNICODE_STRING ServiceKeyName
;
306 } DRIVER_EXTENSION
, *PDRIVER_EXTENSION
;
308 typedef struct _DRIVER_OBJECT
{
311 PDEVICE_OBJECT DeviceObject
;
316 PDRIVER_EXTENSION DriverExtension
;
317 UNICODE_STRING DriverName
;
318 PUNICODE_STRING HardwareDatabase
;
319 PVOID FastIoDispatch
;
320 PDRIVER_INITIALIZE DriverInit
;
321 PDRIVER_STARTIO DriverStartIo
;
322 PDRIVER_UNLOAD DriverUnload
;
323 PDRIVER_DISPATCH MajorFunction
[IRP_MJ_MAXIMUM_FUNCTION
+ 1];
325 typedef struct _DRIVER_OBJECT
*PDRIVER_OBJECT
;
327 /* Irp definitions */
328 typedef UCHAR KIRQL
, *PKIRQL
;
329 typedef CCHAR KPROCESSOR_MODE
;
331 typedef VOID (WINAPI
*PDRIVER_CANCEL
)(
332 IN
struct _DEVICE_OBJECT
*DeviceObject
,
333 IN
struct _IRP
*Irp
);
335 typedef VOID (WINAPI
*PKNORMAL_ROUTINE
)(
336 IN PVOID NormalContext
,
337 IN PVOID SystemArgument1
,
338 IN PVOID SystemArgument2
);
340 typedef VOID (WINAPI
*PKKERNEL_ROUTINE
)(
341 IN
struct _KAPC
*Apc
,
342 IN OUT PKNORMAL_ROUTINE
*NormalRoutine
,
343 IN OUT PVOID
*NormalContext
,
344 IN OUT PVOID
*SystemArgument1
,
345 IN OUT PVOID
*SystemArgument2
);
347 typedef VOID (WINAPI
*PKRUNDOWN_ROUTINE
)(
348 IN
struct _KAPC
*Apc
);
350 typedef struct _KAPC
{
354 struct _KTHREAD
*Thread
;
355 LIST_ENTRY ApcListEntry
;
356 PKKERNEL_ROUTINE KernelRoutine
;
357 PKRUNDOWN_ROUTINE RundownRoutine
;
358 PKNORMAL_ROUTINE NormalRoutine
;
360 PVOID SystemArgument1
;
361 PVOID SystemArgument2
;
363 KPROCESSOR_MODE ApcMode
;
365 } KAPC
, *PKAPC
, *RESTRICTED_POINTER PRKAPC
;
367 #include <pshpack1.h>
368 typedef struct _IRP
{
371 struct _MDL
*MdlAddress
;
374 struct _IRP
*MasterIrp
;
378 LIST_ENTRY ThreadListEntry
;
379 IO_STATUS_BLOCK IoStatus
;
380 KPROCESSOR_MODE RequestorMode
;
381 BOOLEAN PendingReturned
;
383 CHAR CurrentLocation
;
386 CCHAR ApcEnvironment
;
387 UCHAR AllocationFlags
;
388 PIO_STATUS_BLOCK UserIosb
;
392 PIO_APC_ROUTINE UserApcRoutine
;
393 PVOID UserApcContext
;
394 } AsynchronousParameters
;
395 LARGE_INTEGER AllocationSize
;
397 PDRIVER_CANCEL CancelRoutine
;
402 KDEVICE_QUEUE_ENTRY DeviceQueueEntry
;
404 PVOID DriverContext
[4];
408 PCHAR AuxiliaryBuffer
;
410 LIST_ENTRY ListEntry
;
412 struct _IO_STACK_LOCATION
*CurrentStackLocation
;
416 struct _FILE_OBJECT
*OriginalFileObject
;
422 typedef struct _IRP
*PIRP
;
425 /* MDL definitions */
427 typedef VOID (WINAPI
*PINTERFACE_REFERENCE
)(
430 typedef VOID (WINAPI
*PINTERFACE_DEREFERENCE
)(
433 typedef struct _INTERFACE
{
437 PINTERFACE_REFERENCE InterfaceReference
;
438 PINTERFACE_DEREFERENCE InterfaceDereference
;
439 } INTERFACE
, *PINTERFACE
;
441 typedef struct _SECTION_OBJECT_POINTERS
{
442 PVOID DataSectionObject
;
443 PVOID SharedCacheMap
;
444 PVOID ImageSectionObject
;
445 } SECTION_OBJECT_POINTERS
, *PSECTION_OBJECT_POINTERS
;
447 typedef struct _IO_COMPLETION_CONTEXT
{
450 } IO_COMPLETION_CONTEXT
, *PIO_COMPLETION_CONTEXT
;
452 typedef enum _DEVICE_RELATION_TYPE
{
457 TargetDeviceRelation
,
459 } DEVICE_RELATION_TYPE
, *PDEVICE_RELATION_TYPE
;
461 typedef struct _FILE_OBJECT
{
464 PDEVICE_OBJECT DeviceObject
;
468 PSECTION_OBJECT_POINTERS SectionObjectPointer
;
469 PVOID PrivateCacheMap
;
470 NTSTATUS FinalStatus
;
471 struct _FILE_OBJECT
*RelatedFileObject
;
472 BOOLEAN LockOperation
;
473 BOOLEAN DeletePending
;
476 BOOLEAN DeleteAccess
;
479 BOOLEAN SharedDelete
;
481 UNICODE_STRING FileName
;
482 LARGE_INTEGER CurrentByteOffset
;
488 PIO_COMPLETION_CONTEXT CompletionContext
;
490 typedef struct _FILE_OBJECT
*PFILE_OBJECT
;
492 #define INITIAL_PRIVILEGE_COUNT 3
494 typedef struct _INITIAL_PRIVILEGE_SET
{
495 ULONG PrivilegeCount
;
497 LUID_AND_ATTRIBUTES Privilege
[INITIAL_PRIVILEGE_COUNT
];
498 } INITIAL_PRIVILEGE_SET
, * PINITIAL_PRIVILEGE_SET
;
500 typedef struct _SECURITY_SUBJECT_CONTEXT
{
501 PACCESS_TOKEN ClientToken
;
502 SECURITY_IMPERSONATION_LEVEL ImpersonationLevel
;
503 PACCESS_TOKEN PrimaryToken
;
504 PVOID ProcessAuditId
;
505 } SECURITY_SUBJECT_CONTEXT
, *PSECURITY_SUBJECT_CONTEXT
;
507 typedef struct _ACCESS_STATE
{
509 BOOLEAN SecurityEvaluated
;
510 BOOLEAN GenerateAudit
;
511 BOOLEAN GenerateOnClose
;
512 BOOLEAN PrivilegesAllocated
;
514 ACCESS_MASK RemainingDesiredAccess
;
515 ACCESS_MASK PreviouslyGrantedAccess
;
516 ACCESS_MASK OriginalDesiredAccess
;
517 SECURITY_SUBJECT_CONTEXT SubjectSecurityContext
;
518 PSECURITY_DESCRIPTOR SecurityDescriptor
;
521 INITIAL_PRIVILEGE_SET InitialPrivilegeSet
;
522 PRIVILEGE_SET PrivilegeSet
;
525 BOOLEAN AuditPrivileges
;
526 UNICODE_STRING ObjectName
;
527 UNICODE_STRING ObjectTypeName
;
528 } ACCESS_STATE
, *PACCESS_STATE
;
530 typedef struct _IO_SECURITY_CONTEXT
{
531 PSECURITY_QUALITY_OF_SERVICE SecurityQos
;
532 PACCESS_STATE AccessState
;
533 ACCESS_MASK DesiredAccess
;
534 ULONG FullCreateOptions
;
535 } IO_SECURITY_CONTEXT
, *PIO_SECURITY_CONTEXT
;
537 typedef struct _DEVICE_CAPABILITIES
{
542 ULONG LockSupported
: 1;
543 ULONG EjectSupported
: 1;
545 ULONG DockDevice
: 1;
547 ULONG SilentInstall
: 1;
548 ULONG RawDeviceOK
: 1;
549 ULONG SurpriseRemovalOK
: 1;
550 ULONG WakeFromD0
: 1;
551 ULONG WakeFromD1
: 1;
552 ULONG WakeFromD2
: 1;
553 ULONG WakeFromD3
: 1;
554 ULONG HardwareDisabled
: 1;
555 ULONG NonDynamic
: 1;
556 ULONG WarmEjectSupported
: 1;
557 ULONG NoDisplayInUI
: 1;
561 DEVICE_POWER_STATE DeviceState
[PowerSystemMaximum
];
562 SYSTEM_POWER_STATE SystemWake
;
563 DEVICE_POWER_STATE DeviceWake
;
567 } DEVICE_CAPABILITIES
, *PDEVICE_CAPABILITIES
;
569 typedef enum _INTERFACE_TYPE
{
570 InterfaceTypeUndefined
= -1,
588 } INTERFACE_TYPE
, *PINTERFACE_TYPE
;
590 typedef LARGE_INTEGER PHYSICAL_ADDRESS
, *PPHYSICAL_ADDRESS
;
592 #define IO_RESOURCE_PREFERRED 0x01
593 #define IO_RESOURCE_DEFAULT 0x02
594 #define IO_RESOURCE_ALTERNATIVE 0x08
596 typedef struct _IO_RESOURCE_DESCRIPTOR
{
599 UCHAR ShareDisposition
;
607 PHYSICAL_ADDRESS MinimumAddress
;
608 PHYSICAL_ADDRESS MaximumAddress
;
613 PHYSICAL_ADDRESS MinimumAddress
;
614 PHYSICAL_ADDRESS MaximumAddress
;
621 ULONG MinimumChannel
;
622 ULONG MaximumChannel
;
627 PHYSICAL_ADDRESS MinimumAddress
;
628 PHYSICAL_ADDRESS MaximumAddress
;
645 } IO_RESOURCE_DESCRIPTOR
, *PIO_RESOURCE_DESCRIPTOR
;
647 typedef struct _IO_RESOURCE_LIST
{
651 IO_RESOURCE_DESCRIPTOR Descriptors
[1];
652 } IO_RESOURCE_LIST
, *PIO_RESOURCE_LIST
;
654 typedef struct _IO_RESOURCE_REQUIREMENTS_LIST
{
656 INTERFACE_TYPE InterfaceType
;
660 ULONG AlternativeLists
;
661 IO_RESOURCE_LIST List
[1];
662 } IO_RESOURCE_REQUIREMENTS_LIST
, *PIO_RESOURCE_REQUIREMENTS_LIST
;
664 typedef enum _BUS_QUERY_ID_TYPE
{
667 BusQueryCompatibleIDs
,
669 BusQueryDeviceSerialNumber
670 } BUS_QUERY_ID_TYPE
, *PBUS_QUERY_ID_TYPE
;
672 typedef enum _DEVICE_TEXT_TYPE
{
673 DeviceTextDescription
,
674 DeviceTextLocationInformation
675 } DEVICE_TEXT_TYPE
, *PDEVICE_TEXT_TYPE
;
677 typedef enum _DEVICE_USAGE_NOTIFICATION_TYPE
{
678 DeviceUsageTypeUndefined
,
679 DeviceUsageTypePaging
,
680 DeviceUsageTypeHibernation
,
681 DeviceUsageTypeDumpFile
682 } DEVICE_USAGE_NOTIFICATION_TYPE
;
684 typedef struct _POWER_SEQUENCE
{
688 } POWER_SEQUENCE
, *PPOWER_SEQUENCE
;
690 typedef enum _POWER_STATE_TYPE
{
693 } POWER_STATE_TYPE
, *PPOWER_STATE_TYPE
;
695 typedef union _POWER_STATE
{
696 SYSTEM_POWER_STATE SystemState
;
697 DEVICE_POWER_STATE DeviceState
;
698 } POWER_STATE
, *PPOWER_STATE
;
700 typedef struct _CM_PARTIAL_RESOURCE_DESCRIPTOR
{
702 UCHAR ShareDisposition
;
706 PHYSICAL_ADDRESS Start
;
710 PHYSICAL_ADDRESS Start
;
719 PHYSICAL_ADDRESS Start
;
739 } DeviceSpecificData
;
741 } CM_PARTIAL_RESOURCE_DESCRIPTOR
, *PCM_PARTIAL_RESOURCE_DESCRIPTOR
;
743 typedef struct _CM_PARTIAL_RESOURCE_LIST
{
747 CM_PARTIAL_RESOURCE_DESCRIPTOR PartialDescriptors
[1];
748 } CM_PARTIAL_RESOURCE_LIST
, *PCM_PARTIAL_RESOURCE_LIST
;
750 typedef struct _CM_FULL_RESOURCE_DESCRIPTOR
{
751 INTERFACE_TYPE InterfaceType
;
753 CM_PARTIAL_RESOURCE_LIST PartialResourceList
;
754 } CM_FULL_RESOURCE_DESCRIPTOR
, *PCM_FULL_RESOURCE_DESCRIPTOR
;
756 typedef struct _CM_RESOURCE_LIST
{
758 CM_FULL_RESOURCE_DESCRIPTOR List
[1];
759 } CM_RESOURCE_LIST
, *PCM_RESOURCE_LIST
;
761 typedef NTSTATUS (WINAPI
*PIO_COMPLETION_ROUTINE
)(
762 IN
struct _DEVICE_OBJECT
*DeviceObject
,
766 #define SL_PENDING_RETURNED 0x01
767 #define SL_INVOKE_ON_CANCEL 0x20
768 #define SL_INVOKE_ON_SUCCESS 0x40
769 #define SL_INVOKE_ON_ERROR 0x80
771 #include <pshpack1.h>
772 typedef struct _IO_STACK_LOCATION
{
779 PIO_SECURITY_CONTEXT SecurityContext
;
781 USHORT POINTER_ALIGNMENT FileAttributes
;
783 ULONG POINTER_ALIGNMENT EaLength
;
787 ULONG POINTER_ALIGNMENT Key
;
788 LARGE_INTEGER ByteOffset
;
792 ULONG POINTER_ALIGNMENT Key
;
793 LARGE_INTEGER ByteOffset
;
797 FILE_INFORMATION_CLASS POINTER_ALIGNMENT FileInformationClass
;
801 FILE_INFORMATION_CLASS POINTER_ALIGNMENT FileInformationClass
;
802 PFILE_OBJECT FileObject
;
805 BOOLEAN ReplaceIfExists
;
814 FS_INFORMATION_CLASS POINTER_ALIGNMENT FsInformationClass
;
817 ULONG OutputBufferLength
;
818 ULONG POINTER_ALIGNMENT InputBufferLength
;
819 ULONG POINTER_ALIGNMENT IoControlCode
;
820 PVOID Type3InputBuffer
;
823 SECURITY_INFORMATION SecurityInformation
;
824 ULONG POINTER_ALIGNMENT Length
;
827 SECURITY_INFORMATION SecurityInformation
;
828 PSECURITY_DESCRIPTOR SecurityDescriptor
;
832 PDEVICE_OBJECT DeviceObject
;
836 PDEVICE_OBJECT DeviceObject
;
839 struct _SCSI_REQUEST_BLOCK
*Srb
;
842 DEVICE_RELATION_TYPE Type
;
843 } QueryDeviceRelations
;
845 CONST GUID
*InterfaceType
;
848 PINTERFACE Interface
;
849 PVOID InterfaceSpecificData
;
852 PDEVICE_CAPABILITIES Capabilities
;
853 } DeviceCapabilities
;
855 PIO_RESOURCE_REQUIREMENTS_LIST IoResourceRequirementList
;
856 } FilterResourceRequirements
;
861 ULONG POINTER_ALIGNMENT Length
;
867 BUS_QUERY_ID_TYPE IdType
;
870 DEVICE_TEXT_TYPE DeviceTextType
;
871 LCID POINTER_ALIGNMENT LocaleId
;
876 DEVICE_USAGE_NOTIFICATION_TYPE POINTER_ALIGNMENT Type
;
879 SYSTEM_POWER_STATE PowerState
;
882 PPOWER_SEQUENCE PowerSequence
;
886 POWER_STATE_TYPE POINTER_ALIGNMENT Type
;
887 POWER_STATE POINTER_ALIGNMENT State
;
888 POWER_ACTION POINTER_ALIGNMENT ShutdownType
;
891 PCM_RESOURCE_LIST AllocatedResources
;
892 PCM_RESOURCE_LIST AllocatedResourcesTranslated
;
895 ULONG_PTR ProviderId
;
907 PDEVICE_OBJECT DeviceObject
;
908 PFILE_OBJECT FileObject
;
909 PIO_COMPLETION_ROUTINE CompletionRoutine
;
911 } IO_STACK_LOCATION
, *PIO_STACK_LOCATION
;
914 typedef struct _MDL
{
918 struct _EPROCESS
*Process
;
919 PVOID MappedSystemVa
;
925 typedef struct _KTIMER
{
926 DISPATCHER_HEADER Header
;
927 ULARGE_INTEGER DueTime
;
928 LIST_ENTRY TimerListEntry
;
933 typedef struct _KSYSTEM_TIME
{
937 } KSYSTEM_TIME
, *PKSYSTEM_TIME
;
939 typedef enum _NT_PRODUCT_TYPE
{
943 } NT_PRODUCT_TYPE
, *PNT_PRODUCT_TYPE
;
945 #define PROCESSOR_FEATURE_MAX 64
947 typedef enum _ALTERNATIVE_ARCHITECTURE_TYPE
952 } ALTERNATIVE_ARCHITECTURE_TYPE
;
954 typedef struct _KUSER_SHARED_DATA
{
955 ULONG TickCountLowDeprecated
;
956 ULONG TickCountMultiplier
;
957 volatile KSYSTEM_TIME InterruptTime
;
958 volatile KSYSTEM_TIME SystemTime
;
959 volatile KSYSTEM_TIME TimeZoneBias
;
960 USHORT ImageNumberLow
;
961 USHORT ImageNumberHigh
;
962 WCHAR NtSystemRoot
[260];
963 ULONG MaxStckTraceDepth
;
964 ULONG CryptoExponent
;
966 ULONG LargePageMinimum
;
968 NT_PRODUCT_TYPE NtProductType
;
969 BOOLEAN ProductTypeIsValid
;
970 ULONG MajorNtVersion
;
971 ULONG MinorNtVersion
;
972 BOOLEAN ProcessorFeatures
[PROCESSOR_FEATURE_MAX
];
975 volatile ULONG TimeSlip
;
976 ALTERNATIVE_ARCHITECTURE_TYPE AlternativeArchitecture
;
977 LARGE_INTEGER SystemExpirationDate
;
979 BOOLEAN KdDebuggerEnabled
;
980 volatile ULONG ActiveConsoleId
;
981 volatile ULONG DismountCount
;
982 ULONG ComPlusPackage
;
983 ULONG LastSystemRITEventTickCount
;
984 ULONG NumberOfPhysicalPages
;
985 BOOLEAN SafeBootMode
;
988 ULONGLONG SystemCall
[4];
990 volatile KSYSTEM_TIME TickCount
;
991 volatile ULONG64 TickCountQuad
;
993 } KSHARED_USER_DATA
, *PKSHARED_USER_DATA
;
995 NTSTATUS WINAPI
ObCloseHandle(IN HANDLE handle
);
997 #define IoGetCurrentIrpStackLocation(_Irp) ((_Irp)->Tail.Overlay.CurrentStackLocation)
1002 /* directory object access rights */
1003 #define DIRECTORY_QUERY 0x0001
1004 #define DIRECTORY_TRAVERSE 0x0002
1005 #define DIRECTORY_CREATE_OBJECT 0x0004
1006 #define DIRECTORY_CREATE_SUBDIRECTORY 0x0008
1007 #define DIRECTORY_ALL_ACCESS (STANDARD_RIGHTS_REQUIRED | 0xF)
1009 /* symbolic link access rights */
1010 #define SYMBOLIC_LINK_QUERY 0x0001
1011 #define SYMBOLIC_LINK_ALL_ACCESS (STANDARD_RIGHTS_REQUIRED | 0x1)
1013 PVOID WINAPI
ExAllocatePool(POOL_TYPE
,SIZE_T
);
1014 PVOID WINAPI
ExAllocatePoolWithQuota(POOL_TYPE
,SIZE_T
);
1015 PVOID WINAPI
ExAllocatePoolWithTag(POOL_TYPE
,SIZE_T
,ULONG
);
1016 PVOID WINAPI
ExAllocatePoolWithQuotaTag(POOL_TYPE
,SIZE_T
,ULONG
);
1017 void WINAPI
ExFreePool(PVOID
);
1018 void WINAPI
ExFreePoolWithTag(PVOID
,ULONG
);
1020 PIRP WINAPI
IoAllocateIrp(CCHAR
,BOOLEAN
);
1021 NTSTATUS WINAPI
IoCreateDevice(DRIVER_OBJECT
*,ULONG
,UNICODE_STRING
*,DEVICE_TYPE
,ULONG
,BOOLEAN
,DEVICE_OBJECT
**);
1022 NTSTATUS WINAPI
IoCreateDriver(UNICODE_STRING
*,PDRIVER_INITIALIZE
);
1023 NTSTATUS WINAPI
IoCreateSymbolicLink(UNICODE_STRING
*,UNICODE_STRING
*);
1024 void WINAPI
IoDeleteDevice(DEVICE_OBJECT
*);
1025 void WINAPI
IoDeleteDriver(DRIVER_OBJECT
*);
1026 NTSTATUS WINAPI
IoDeleteSymbolicLink(UNICODE_STRING
*);
1027 void WINAPI
IoFreeIrp(IRP
*);
1028 PEPROCESS WINAPI
IoGetCurrentProcess(void);
1029 NTSTATUS WINAPI
IoGetDeviceObjectPointer(UNICODE_STRING
*,ACCESS_MASK
,PFILE_OBJECT
*,PDEVICE_OBJECT
*);
1030 PDEVICE_OBJECT WINAPI
IoGetRelatedDeviceObject(PFILE_OBJECT
);
1031 void WINAPI
IoInitializeIrp(IRP
*,USHORT
,CCHAR
);
1033 PKTHREAD WINAPI
KeGetCurrentThread(void);
1034 void WINAPI
KeQuerySystemTime(LARGE_INTEGER
*);
1035 void WINAPI
KeQueryTickCount(LARGE_INTEGER
*);
1036 ULONG WINAPI
KeQueryTimeIncrement(void);
1038 PVOID WINAPI
MmAllocateNonCachedMemory(SIZE_T
);
1039 void WINAPI
MmFreeNonCachedMemory(PVOID
,SIZE_T
);
1041 NTSTATUS WINAPI
ObReferenceObjectByHandle(HANDLE
,ACCESS_MASK
,POBJECT_TYPE
,KPROCESSOR_MODE
,PVOID
*,POBJECT_HANDLE_INFORMATION
);
1043 NTSTATUS WINAPI
PsCreateSystemThread(PHANDLE
,ULONG
,POBJECT_ATTRIBUTES
,HANDLE
,PCLIENT_ID
,PKSTART_ROUTINE
,PVOID
);
1044 #define PsGetCurrentProcess() IoGetCurrentProcess()
1045 #define PsGetCurrentThread() ((PETHREAD)KeGetCurrentThread())
1046 HANDLE WINAPI
PsGetCurrentProcessId(void);
1047 HANDLE WINAPI
PsGetCurrentThreadId(void);
1048 BOOLEAN WINAPI
PsGetVersion(ULONG
*,ULONG
*,ULONG
*,UNICODE_STRING
*);
1049 NTSTATUS WINAPI
PsTerminateSystemThread(NTSTATUS
);
1051 NTSTATUS WINAPI
ZwAddBootEntry(PUNICODE_STRING
,PUNICODE_STRING
);
1052 NTSTATUS WINAPI
ZwAccessCheckAndAuditAlarm(PUNICODE_STRING
,HANDLE
,PUNICODE_STRING
,PUNICODE_STRING
,PSECURITY_DESCRIPTOR
,ACCESS_MASK
,PGENERIC_MAPPING
,BOOLEAN
,PACCESS_MASK
,PBOOLEAN
,PBOOLEAN
);
1053 NTSTATUS WINAPI
ZwAdjustPrivilegesToken(HANDLE
,BOOLEAN
,PTOKEN_PRIVILEGES
,DWORD
,PTOKEN_PRIVILEGES
,PDWORD
);
1054 NTSTATUS WINAPI
ZwAlertThread(HANDLE ThreadHandle
);
1055 NTSTATUS WINAPI
ZwAllocateVirtualMemory(HANDLE
,PVOID
*,ULONG
,SIZE_T
*,ULONG
,ULONG
);
1056 NTSTATUS WINAPI
ZwCancelIoFile(HANDLE
,PIO_STATUS_BLOCK
);
1057 NTSTATUS WINAPI
ZwCancelTimer(HANDLE
, BOOLEAN
*);
1058 NTSTATUS WINAPI
ZwClearEvent(HANDLE
);
1059 NTSTATUS WINAPI
ZwClose(HANDLE
);
1060 NTSTATUS WINAPI
ZwCloseObjectAuditAlarm(PUNICODE_STRING
,HANDLE
,BOOLEAN
);
1061 NTSTATUS WINAPI
ZwConnectPort(PHANDLE
,PUNICODE_STRING
,PSECURITY_QUALITY_OF_SERVICE
,PLPC_SECTION_WRITE
,PLPC_SECTION_READ
,PULONG
,PVOID
,PULONG
);
1062 NTSTATUS WINAPI
ZwCreateDirectoryObject(PHANDLE
,ACCESS_MASK
,POBJECT_ATTRIBUTES
);
1063 NTSTATUS WINAPI
ZwCreateEvent(PHANDLE
,ACCESS_MASK
,const OBJECT_ATTRIBUTES
*,BOOLEAN
,BOOLEAN
);
1064 NTSTATUS WINAPI
ZwCreateFile(PHANDLE
,ACCESS_MASK
,POBJECT_ATTRIBUTES
,PIO_STATUS_BLOCK
,PLARGE_INTEGER
,ULONG
,ULONG
,ULONG
,ULONG
,PVOID
,ULONG
);
1065 NTSTATUS WINAPI
ZwCreateKey(PHANDLE
,ACCESS_MASK
,const OBJECT_ATTRIBUTES
*,ULONG
,const UNICODE_STRING
*,ULONG
,PULONG
);
1066 NTSTATUS WINAPI
ZwCreateSection(HANDLE
*,ACCESS_MASK
,const OBJECT_ATTRIBUTES
*,const LARGE_INTEGER
*,ULONG
,ULONG
,HANDLE
);
1067 NTSTATUS WINAPI
ZwCreateSymbolicLinkObject(PHANDLE
,ACCESS_MASK
,POBJECT_ATTRIBUTES
,PUNICODE_STRING
);
1068 NTSTATUS WINAPI
ZwCreateTimer(HANDLE
*, ACCESS_MASK
, const OBJECT_ATTRIBUTES
*, TIMER_TYPE
);
1069 NTSTATUS WINAPI
ZwDeleteAtom(RTL_ATOM
);
1070 NTSTATUS WINAPI
ZwDeleteFile(POBJECT_ATTRIBUTES
);
1071 NTSTATUS WINAPI
ZwDeleteKey(HANDLE
);
1072 NTSTATUS WINAPI
ZwDeleteValueKey(HANDLE
,const UNICODE_STRING
*);
1073 NTSTATUS WINAPI
ZwDeviceIoControlFile(HANDLE
,HANDLE
,PIO_APC_ROUTINE
,PVOID
,PIO_STATUS_BLOCK
,ULONG
,PVOID
,ULONG
,PVOID
,ULONG
);
1074 NTSTATUS WINAPI
ZwDisplayString(PUNICODE_STRING
);
1075 NTSTATUS WINAPI
ZwDuplicateObject(HANDLE
,HANDLE
,HANDLE
,PHANDLE
,ACCESS_MASK
,ULONG
,ULONG
);
1076 NTSTATUS WINAPI
ZwDuplicateToken(HANDLE
,ACCESS_MASK
,POBJECT_ATTRIBUTES
,SECURITY_IMPERSONATION_LEVEL
,TOKEN_TYPE
,PHANDLE
);
1077 NTSTATUS WINAPI
ZwEnumerateKey(HANDLE
,ULONG
,KEY_INFORMATION_CLASS
,void *,DWORD
,DWORD
*);
1078 NTSTATUS WINAPI
ZwEnumerateValueKey(HANDLE
,ULONG
,KEY_VALUE_INFORMATION_CLASS
,PVOID
,ULONG
,PULONG
);
1079 NTSTATUS WINAPI
ZwFlushInstructionCache(HANDLE
,LPCVOID
,SIZE_T
);
1080 NTSTATUS WINAPI
ZwFlushKey(HANDLE
);
1081 NTSTATUS WINAPI
ZwFlushVirtualMemory(HANDLE
,LPCVOID
*,SIZE_T
*,ULONG
);
1082 NTSTATUS WINAPI
ZwFreeVirtualMemory(HANDLE
,PVOID
*,SIZE_T
*,ULONG
);
1083 NTSTATUS WINAPI
ZwFsControlFile(HANDLE
,HANDLE
,PIO_APC_ROUTINE
,PVOID
,PIO_STATUS_BLOCK
,ULONG
,PVOID
,ULONG
,PVOID
,ULONG
);
1084 NTSTATUS WINAPI
ZwInitiatePowerAction(POWER_ACTION
,SYSTEM_POWER_STATE
,ULONG
,BOOLEAN
);
1085 NTSTATUS WINAPI
ZwLoadDriver(const UNICODE_STRING
*);
1086 NTSTATUS WINAPI
ZwLoadKey(const OBJECT_ATTRIBUTES
*,OBJECT_ATTRIBUTES
*);
1087 NTSTATUS WINAPI
ZwLockVirtualMemory(HANDLE
,PVOID
*,SIZE_T
*,ULONG
);
1088 NTSTATUS WINAPI
ZwMakeTemporaryObject(HANDLE
);
1089 NTSTATUS WINAPI
ZwMapViewOfSection(HANDLE
,HANDLE
,PVOID
*,ULONG
,SIZE_T
,const LARGE_INTEGER
*,SIZE_T
*,SECTION_INHERIT
,ULONG
,ULONG
);
1090 NTSTATUS WINAPI
ZwNotifyChangeKey(HANDLE
,HANDLE
,PIO_APC_ROUTINE
,PVOID
,PIO_STATUS_BLOCK
,ULONG
,BOOLEAN
,PVOID
,ULONG
,BOOLEAN
);
1091 NTSTATUS WINAPI
ZwOpenDirectoryObject(PHANDLE
,ACCESS_MASK
,POBJECT_ATTRIBUTES
);
1092 NTSTATUS WINAPI
ZwOpenEvent(PHANDLE
,ACCESS_MASK
,const OBJECT_ATTRIBUTES
*);
1093 NTSTATUS WINAPI
ZwOpenFile(PHANDLE
,ACCESS_MASK
,POBJECT_ATTRIBUTES
,PIO_STATUS_BLOCK
,ULONG
,ULONG
);
1094 NTSTATUS WINAPI
ZwOpenKey(PHANDLE
,ACCESS_MASK
,const OBJECT_ATTRIBUTES
*);
1095 NTSTATUS WINAPI
ZwOpenProcess(PHANDLE
,ACCESS_MASK
,const OBJECT_ATTRIBUTES
*,const CLIENT_ID
*);
1096 NTSTATUS WINAPI
ZwOpenProcessToken(HANDLE
,DWORD
,HANDLE
*);
1097 NTSTATUS WINAPI
ZwOpenSection(HANDLE
*,ACCESS_MASK
,const OBJECT_ATTRIBUTES
*);
1098 NTSTATUS WINAPI
ZwOpenSymbolicLinkObject(PHANDLE
,ACCESS_MASK
,POBJECT_ATTRIBUTES
);
1099 NTSTATUS WINAPI
ZwOpenThread(HANDLE
*,ACCESS_MASK
,const OBJECT_ATTRIBUTES
*,const CLIENT_ID
*);
1100 NTSTATUS WINAPI
ZwOpenThreadToken(HANDLE
,DWORD
,BOOLEAN
,HANDLE
*);
1101 NTSTATUS WINAPI
ZwOpenTimer(HANDLE
*, ACCESS_MASK
, const OBJECT_ATTRIBUTES
*);
1102 NTSTATUS WINAPI
ZwPowerInformation(POWER_INFORMATION_LEVEL
,PVOID
,ULONG
,PVOID
,ULONG
);
1103 NTSTATUS WINAPI
ZwPulseEvent(HANDLE
,PULONG
);
1104 NTSTATUS WINAPI
ZwQueryDefaultLocale(BOOLEAN
,LCID
*);
1105 NTSTATUS WINAPI
ZwQueryDefaultUILanguage(LANGID
*);
1106 NTSTATUS WINAPI
ZwQueryDirectoryFile(HANDLE
,HANDLE
,PIO_APC_ROUTINE
,PVOID
,PIO_STATUS_BLOCK
,PVOID
,ULONG
,FILE_INFORMATION_CLASS
,BOOLEAN
,PUNICODE_STRING
,BOOLEAN
);
1107 NTSTATUS WINAPI
ZwQueryDirectoryObject(HANDLE
,PDIRECTORY_BASIC_INFORMATION
,ULONG
,BOOLEAN
,BOOLEAN
,PULONG
,PULONG
);
1108 NTSTATUS WINAPI
ZwQueryEaFile(HANDLE
,PIO_STATUS_BLOCK
,PVOID
,ULONG
,BOOLEAN
,PVOID
,ULONG
,PVOID
,BOOLEAN
);
1109 NTSTATUS WINAPI
ZwQueryFullAttributesFile(const OBJECT_ATTRIBUTES
*,FILE_NETWORK_OPEN_INFORMATION
*);
1110 NTSTATUS WINAPI
ZwQueryInformationFile(HANDLE
,PIO_STATUS_BLOCK
,PVOID
,LONG
,FILE_INFORMATION_CLASS
);
1111 NTSTATUS WINAPI
ZwQueryInformationThread(HANDLE
,THREADINFOCLASS
,PVOID
,ULONG
,PULONG
);
1112 NTSTATUS WINAPI
ZwQueryInformationToken(HANDLE
,DWORD
,PVOID
,DWORD
,LPDWORD
);
1113 NTSTATUS WINAPI
ZwQueryInstallUILanguage(LANGID
*);
1114 NTSTATUS WINAPI
ZwQueryKey(HANDLE
,KEY_INFORMATION_CLASS
,void *,DWORD
,DWORD
*);
1115 NTSTATUS WINAPI
ZwQueryObject(HANDLE
, OBJECT_INFORMATION_CLASS
, PVOID
, ULONG
, PULONG
);
1116 NTSTATUS WINAPI
ZwQuerySecurityObject(HANDLE
,SECURITY_INFORMATION
,PSECURITY_DESCRIPTOR
,ULONG
,PULONG
);
1117 NTSTATUS WINAPI
ZwQuerySection(HANDLE
,SECTION_INFORMATION_CLASS
,PVOID
,ULONG
,PULONG
);
1118 NTSTATUS WINAPI
ZwQuerySymbolicLinkObject(HANDLE
,PUNICODE_STRING
,PULONG
);
1119 NTSTATUS WINAPI
ZwQuerySystemInformation(SYSTEM_INFORMATION_CLASS
,PVOID
,ULONG
,PULONG
);
1120 NTSTATUS WINAPI
ZwQueryTimerResolution(PULONG
,PULONG
,PULONG
);
1121 NTSTATUS WINAPI
ZwQueryValueKey(HANDLE
,const UNICODE_STRING
*,KEY_VALUE_INFORMATION_CLASS
,void *,DWORD
,DWORD
*);
1122 NTSTATUS WINAPI
ZwQueryVolumeInformationFile(HANDLE
,PIO_STATUS_BLOCK
,PVOID
,ULONG
,FS_INFORMATION_CLASS
);
1123 NTSTATUS WINAPI
ZwReadFile(HANDLE
,HANDLE
,PIO_APC_ROUTINE
,PVOID
,PIO_STATUS_BLOCK
,PVOID
,ULONG
,PLARGE_INTEGER
,PULONG
);
1124 NTSTATUS WINAPI
ZwReplaceKey(POBJECT_ATTRIBUTES
,HANDLE
,POBJECT_ATTRIBUTES
);
1125 NTSTATUS WINAPI
ZwRequestWaitReplyPort(HANDLE
,PLPC_MESSAGE
,PLPC_MESSAGE
);
1126 NTSTATUS WINAPI
ZwResetEvent(HANDLE
,PULONG
);
1127 NTSTATUS WINAPI
ZwRestoreKey(HANDLE
,HANDLE
,ULONG
);
1128 NTSTATUS WINAPI
ZwSaveKey(HANDLE
,HANDLE
);
1129 NTSTATUS WINAPI
ZwSecureConnectPort(PHANDLE
,PUNICODE_STRING
,PSECURITY_QUALITY_OF_SERVICE
,PLPC_SECTION_WRITE
,PSID
,PLPC_SECTION_READ
,PULONG
,PVOID
,PULONG
);
1130 NTSTATUS WINAPI
ZwSetDefaultLocale(BOOLEAN
,LCID
);
1131 NTSTATUS WINAPI
ZwSetDefaultUILanguage(LANGID
);
1132 NTSTATUS WINAPI
ZwSetEaFile(HANDLE
,PIO_STATUS_BLOCK
,PVOID
,ULONG
);
1133 NTSTATUS WINAPI
ZwSetEvent(HANDLE
,PULONG
);
1134 NTSTATUS WINAPI
ZwSetInformationFile(HANDLE
,PIO_STATUS_BLOCK
,PVOID
,ULONG
,FILE_INFORMATION_CLASS
);
1135 NTSTATUS WINAPI
ZwSetInformationKey(HANDLE
,const int,PVOID
,ULONG
);
1136 NTSTATUS WINAPI
ZwSetInformationObject(HANDLE
, OBJECT_INFORMATION_CLASS
, PVOID
, ULONG
);
1137 NTSTATUS WINAPI
ZwSetInformationProcess(HANDLE
,PROCESS_INFORMATION_CLASS
,PVOID
,ULONG
);
1138 NTSTATUS WINAPI
ZwSetInformationThread(HANDLE
,THREADINFOCLASS
,LPCVOID
,ULONG
);
1139 NTSTATUS WINAPI
ZwSetIoCompletion(HANDLE
,ULONG
,ULONG
,NTSTATUS
,ULONG
);
1140 NTSTATUS WINAPI
ZwSetSecurityObject(HANDLE
,SECURITY_INFORMATION
,PSECURITY_DESCRIPTOR
);
1141 NTSTATUS WINAPI
ZwSetSystemInformation(SYSTEM_INFORMATION_CLASS
,PVOID
,ULONG
);
1142 NTSTATUS WINAPI
ZwSetSystemTime(const LARGE_INTEGER
*,LARGE_INTEGER
*);
1143 NTSTATUS WINAPI
ZwSetTimer(HANDLE
, const LARGE_INTEGER
*, PTIMER_APC_ROUTINE
, PVOID
, BOOLEAN
, ULONG
, BOOLEAN
*);
1144 NTSTATUS WINAPI
ZwSetValueKey(HANDLE
,const UNICODE_STRING
*,ULONG
,ULONG
,const void *,ULONG
);
1145 NTSTATUS WINAPI
ZwSetVolumeInformationFile(HANDLE
,PIO_STATUS_BLOCK
,PVOID
,ULONG
,FS_INFORMATION_CLASS
);
1146 NTSTATUS WINAPI
ZwSuspendThread(HANDLE
,PULONG
);
1147 NTSTATUS WINAPI
ZwTerminateProcess(HANDLE
,LONG
);
1148 NTSTATUS WINAPI
ZwUnloadDriver(const UNICODE_STRING
*);
1149 NTSTATUS WINAPI
ZwUnloadKey(HANDLE
);
1150 NTSTATUS WINAPI
ZwUnmapViewOfSection(HANDLE
,PVOID
);
1151 NTSTATUS WINAPI
ZwWaitForSingleObject(HANDLE
,BOOLEAN
,const LARGE_INTEGER
*);
1152 NTSTATUS WINAPI
ZwWaitForMultipleObjects(ULONG
,const HANDLE
*,BOOLEAN
,BOOLEAN
,const LARGE_INTEGER
*);
1153 NTSTATUS WINAPI
ZwWriteFile(HANDLE
,HANDLE
,PIO_APC_ROUTINE
,PVOID
,PIO_STATUS_BLOCK
,const void*,ULONG
,PLARGE_INTEGER
,PULONG
);
1154 NTSTATUS WINAPI
ZwYieldExecution(void);