3 Copyright (c) Alex Ionescu. All rights reserved.
11 NDK Support for usage without the IFS. Will be deprecated at WDK Release.
15 Alex Ionescu (alexi@tinykrnl.org) - Updated - 27-Feb-2006
19 #ifndef NTOS_MODE_USER
22 #define TOKEN_SOURCE_LENGTH 8
24 typedef enum _TOKEN_TYPE
28 } TOKEN_TYPE
, *PTOKEN_TYPE
;
31 (NTAPI
* PRTL_HEAP_COMMIT_ROUTINE
)(
33 IN OUT PVOID
*CommitAddress
,
34 IN OUT PSIZE_T CommitSize
37 typedef struct _RTL_HEAP_PARAMETERS
40 SIZE_T SegmentReserve
;
42 SIZE_T DeCommitFreeBlockThreshold
;
43 SIZE_T DeCommitTotalFreeThreshold
;
44 SIZE_T MaximumAllocationSize
;
45 SIZE_T VirtualMemoryThreshold
;
47 SIZE_T InitialReserve
;
48 PRTL_HEAP_COMMIT_ROUTINE CommitRoutine
;
50 } RTL_HEAP_PARAMETERS
, *PRTL_HEAP_PARAMETERS
;
52 typedef PVOID PFS_FILTER_CALLBACKS
;
53 typedef USHORT SECURITY_DESCRIPTOR_CONTROL
, *PSECURITY_DESCRIPTOR_CONTROL
;
55 typedef struct _RTL_SPLAY_LINKS
57 struct _RTL_SPLAY_LINKS
*Parent
;
58 struct _RTL_SPLAY_LINKS
*LeftChild
;
59 struct _RTL_SPLAY_LINKS
*RightChild
;
60 } RTL_SPLAY_LINKS
, *PRTL_SPLAY_LINKS
;
62 typedef struct _RTL_GENERIC_TABLE RTL_GENERIC_TABLE
, *PRTL_GENERIC_TABLE
;
63 typedef ULONG TABLE_SEARCH_RESULT
;
65 #if defined(USE_LPC6432)
66 #define LPC_CLIENT_ID CLIENT_ID64
67 #define LPC_SIZE_T ULONGLONG
68 #define LPC_PVOID ULONGLONG
69 #define LPC_HANDLE ULONGLONG
71 #define LPC_CLIENT_ID CLIENT_ID
72 #define LPC_SIZE_T SIZE_T
73 #define LPC_PVOID PVOID
74 #define LPC_HANDLE HANDLE
77 typedef struct _PORT_MESSAGE
93 CSHORT DataInfoOffset
;
99 LPC_CLIENT_ID ClientId
;
100 double DoNotUseThisField
;
105 LPC_SIZE_T ClientViewSize
;
108 } PORT_MESSAGE
, *PPORT_MESSAGE
;
110 typedef struct _PORT_VIEW
113 LPC_HANDLE SectionHandle
;
117 LPC_PVOID ViewRemoteBase
;
118 } PORT_VIEW
, *PPORT_VIEW
;
120 typedef struct _REMOTE_PORT_VIEW
125 } REMOTE_PORT_VIEW
, *PREMOTE_PORT_VIEW
;
127 typedef struct _KAPC_STATE
129 LIST_ENTRY ApcListHead
[2];
130 struct _KPROCESS
*Process
;
131 BOOLEAN KernelApcInProgress
;
132 BOOLEAN KernelApcPending
;
133 BOOLEAN UserApcPending
;
134 } KAPC_STATE
, *PKAPC_STATE
, *RESTRICTED_POINTER PRKAPC_STATE
;
136 typedef struct _KQUEUE
138 DISPATCHER_HEADER Header
;
139 LIST_ENTRY EntryListHead
;
142 LIST_ENTRY ThreadListHead
;
143 } KQUEUE
, *PKQUEUE
, *RESTRICTED_POINTER PRKQUEUE
;
145 typedef struct _ACE_HEADER
150 } ACE_HEADER
, *PACE_HEADER
;
152 typedef enum _RTL_GENERIC_COMPARE_RESULTS
157 } RTL_GENERIC_COMPARE_RESULTS
;
159 typedef struct _SID_IDENTIFIER_AUTHORITY
162 } SID_IDENTIFIER_AUTHORITY
, *PSID_IDENTIFIER_AUTHORITY
;
164 typedef struct _SID_AND_ATTRIBUTES
168 } SID_AND_ATTRIBUTES
, * PSID_AND_ATTRIBUTES
;
170 typedef struct _TOKEN_SOURCE
172 CHAR SourceName
[TOKEN_SOURCE_LENGTH
];
173 LUID SourceIdentifier
;
174 } TOKEN_SOURCE
, *PTOKEN_SOURCE
;
176 typedef struct _TOKEN_CONTROL
179 LUID AuthenticationId
;
181 TOKEN_SOURCE TokenSource
;
182 } TOKEN_CONTROL
, *PTOKEN_CONTROL
;
184 typedef struct _SECURITY_CLIENT_CONTEXT
186 SECURITY_QUALITY_OF_SERVICE SecurityQos
;
187 PACCESS_TOKEN ClientToken
;
188 BOOLEAN DirectlyAccessClientToken
;
189 BOOLEAN DirectAccessEffectiveOnly
;
190 BOOLEAN ServerIsRemote
;
191 TOKEN_CONTROL ClientTokenControl
;
192 } SECURITY_CLIENT_CONTEXT
, *PSECURITY_CLIENT_CONTEXT
;
194 typedef struct _SECURITY_DESCRIPTOR_RELATIVE
198 SECURITY_DESCRIPTOR_CONTROL Control
;
203 } SECURITY_DESCRIPTOR_RELATIVE
, *PISECURITY_DESCRIPTOR_RELATIVE
;
205 typedef struct _TOKEN_GROUPS
208 SID_AND_ATTRIBUTES Groups
[ANYSIZE_ARRAY
];
209 } TOKEN_GROUPS
, *PTOKEN_GROUPS
;
211 typedef struct _TOKEN_PRIVILEGES
213 ULONG PrivilegeCount
;
214 LUID_AND_ATTRIBUTES Privileges
[ANYSIZE_ARRAY
];
215 } TOKEN_PRIVILEGES
, *PTOKEN_PRIVILEGES
;
217 typedef struct _TOKEN_USER
219 SID_AND_ATTRIBUTES User
;
220 } TOKEN_USER
, *PTOKEN_USER
;
222 typedef enum _TOKEN_INFORMATION_CLASS
232 TokenImpersonationLevel
,
236 TokenGroupsAndPrivileges
,
237 TokenSessionReference
,
245 TokenAccessInformation
,
248 TokenIntegrityLevelDesktop
,
249 TokenMandatoryPolicy
,
251 } TOKEN_INFORMATION_CLASS
, *PTOKEN_INFORMATION_CLASS
;
253 typedef struct _TOKEN_OWNER
256 } TOKEN_OWNER
, *PTOKEN_OWNER
;
258 typedef struct _TOKEN_PRIMARY_GROUP
261 } TOKEN_PRIMARY_GROUP
, *PTOKEN_PRIMARY_GROUP
;
263 typedef struct _TOKEN_DEFAULT_DACL
266 } TOKEN_DEFAULT_DACL
, *PTOKEN_DEFAULT_DACL
;
271 #define HEAP_NO_SERIALIZE 0x00000001
272 #define HEAP_GROWABLE 0x00000002
273 #define HEAP_GENERATE_EXCEPTIONS 0x00000004
274 #define HEAP_ZERO_MEMORY 0x00000008
275 #define HEAP_REALLOC_IN_PLACE_ONLY 0x00000010
276 #define HEAP_TAIL_CHECKING_ENABLED 0x00000020
277 #define HEAP_FREE_CHECKING_ENABLED 0x00000040
278 #define HEAP_DISABLE_COALESCE_ON_FREE 0x00000080
280 #define HEAP_CREATE_ALIGN_16 0x00010000
281 #define HEAP_CREATE_ENABLE_TRACING 0x00020000
282 #define HEAP_CREATE_ENABLE_EXECUTE 0x00040000
284 #endif // !NTOS_MODE_USER