- Merge aicom-network-fixes up to r36740
[reactos.git] / reactos / include / ndk / ifssupp.h
1 /*++ NDK Version: 0098
2
3 Copyright (c) Alex Ionescu. All rights reserved.
4
5 Header Name:
6
7 ifssupp.h
8
9 Abstract:
10
11 NDK Support for usage without the IFS. Will be deprecated at WDK Release.
12
13 Author:
14
15 Alex Ionescu (alexi@tinykrnl.org) - Updated - 27-Feb-2006
16
17 --*/
18 #ifndef _NTIFS_
19 #ifndef NTOS_MODE_USER
20 #define _NTIFS_
21
22 #define TOKEN_SOURCE_LENGTH 8
23
24 typedef enum _TOKEN_TYPE
25 {
26 TokenPrimary = 1,
27 TokenImpersonation
28 } TOKEN_TYPE, *PTOKEN_TYPE;
29
30 typedef PVOID PRTL_HEAP_PARAMETERS;
31 typedef PVOID PFS_FILTER_CALLBACKS;
32 typedef USHORT SECURITY_DESCRIPTOR_CONTROL, *PSECURITY_DESCRIPTOR_CONTROL;
33
34 typedef struct _RTL_SPLAY_LINKS
35 {
36 struct _RTL_SPLAY_LINKS *Parent;
37 struct _RTL_SPLAY_LINKS *LeftChild;
38 struct _RTL_SPLAY_LINKS *RightChild;
39 } RTL_SPLAY_LINKS, *PRTL_SPLAY_LINKS;
40
41 typedef struct _RTL_GENERIC_TABLE RTL_GENERIC_TABLE, *PRTL_GENERIC_TABLE;
42 typedef ULONG TABLE_SEARCH_RESULT;
43
44 #if defined(USE_LPC6432)
45 #define LPC_CLIENT_ID CLIENT_ID64
46 #define LPC_SIZE_T ULONGLONG
47 #define LPC_PVOID ULONGLONG
48 #define LPC_HANDLE ULONGLONG
49 #else
50 #define LPC_CLIENT_ID CLIENT_ID
51 #define LPC_SIZE_T SIZE_T
52 #define LPC_PVOID PVOID
53 #define LPC_HANDLE HANDLE
54 #endif
55
56 typedef struct _PORT_MESSAGE
57 {
58 union
59 {
60 struct
61 {
62 CSHORT DataLength;
63 CSHORT TotalLength;
64 } s1;
65 ULONG Length;
66 } u1;
67 union
68 {
69 struct
70 {
71 CSHORT Type;
72 CSHORT DataInfoOffset;
73 } s2;
74 ULONG ZeroInit;
75 } u2;
76 union
77 {
78 LPC_CLIENT_ID ClientId;
79 double DoNotUseThisField;
80 };
81 ULONG MessageId;
82 union
83 {
84 LPC_SIZE_T ClientViewSize;
85 ULONG CallbackId;
86 };
87 } PORT_MESSAGE, *PPORT_MESSAGE;
88
89 typedef struct _PORT_VIEW
90 {
91 ULONG Length;
92 LPC_HANDLE SectionHandle;
93 ULONG SectionOffset;
94 LPC_SIZE_T ViewSize;
95 LPC_PVOID ViewBase;
96 LPC_PVOID ViewRemoteBase;
97 } PORT_VIEW, *PPORT_VIEW;
98
99 typedef struct _REMOTE_PORT_VIEW
100 {
101 ULONG Length;
102 LPC_SIZE_T ViewSize;
103 LPC_PVOID ViewBase;
104 } REMOTE_PORT_VIEW, *PREMOTE_PORT_VIEW;
105
106 typedef struct _KAPC_STATE
107 {
108 LIST_ENTRY ApcListHead[2];
109 struct _KPROCESS *Process;
110 BOOLEAN KernelApcInProgress;
111 BOOLEAN KernelApcPending;
112 BOOLEAN UserApcPending;
113 } KAPC_STATE, *PKAPC_STATE, *RESTRICTED_POINTER PRKAPC_STATE;
114
115 typedef struct _KQUEUE
116 {
117 DISPATCHER_HEADER Header;
118 LIST_ENTRY EntryListHead;
119 ULONG CurrentCount;
120 ULONG MaximumCount;
121 LIST_ENTRY ThreadListHead;
122 } KQUEUE, *PKQUEUE, *RESTRICTED_POINTER PRKQUEUE;
123
124 typedef struct _ACE_HEADER
125 {
126 UCHAR AceType;
127 UCHAR AceFlags;
128 USHORT AceSize;
129 } ACE_HEADER, *PACE_HEADER;
130
131 typedef enum _RTL_GENERIC_COMPARE_RESULTS
132 {
133 GenericLessThan,
134 GenericGreaterThan,
135 GenericEqual
136 } RTL_GENERIC_COMPARE_RESULTS;
137
138 typedef struct _SID_IDENTIFIER_AUTHORITY
139 {
140 UCHAR Value[6];
141 } SID_IDENTIFIER_AUTHORITY, *PSID_IDENTIFIER_AUTHORITY;
142
143 typedef struct _SID_AND_ATTRIBUTES
144 {
145 PSID Sid;
146 ULONG Attributes;
147 } SID_AND_ATTRIBUTES, * PSID_AND_ATTRIBUTES;
148
149 typedef struct _TOKEN_SOURCE
150 {
151 CHAR SourceName[TOKEN_SOURCE_LENGTH];
152 LUID SourceIdentifier;
153 } TOKEN_SOURCE, *PTOKEN_SOURCE;
154
155 typedef struct _TOKEN_CONTROL
156 {
157 LUID TokenId;
158 LUID AuthenticationId;
159 LUID ModifiedId;
160 TOKEN_SOURCE TokenSource;
161 } TOKEN_CONTROL, *PTOKEN_CONTROL;
162
163 typedef struct _SECURITY_CLIENT_CONTEXT
164 {
165 SECURITY_QUALITY_OF_SERVICE SecurityQos;
166 PACCESS_TOKEN ClientToken;
167 BOOLEAN DirectlyAccessClientToken;
168 BOOLEAN DirectAccessEffectiveOnly;
169 BOOLEAN ServerIsRemote;
170 TOKEN_CONTROL ClientTokenControl;
171 } SECURITY_CLIENT_CONTEXT, *PSECURITY_CLIENT_CONTEXT;
172
173 typedef struct _SECURITY_DESCRIPTOR_RELATIVE
174 {
175 UCHAR Revision;
176 UCHAR Sbz1;
177 SECURITY_DESCRIPTOR_CONTROL Control;
178 ULONG Owner;
179 ULONG Group;
180 ULONG Sacl;
181 ULONG Dacl;
182 } SECURITY_DESCRIPTOR_RELATIVE, *PISECURITY_DESCRIPTOR_RELATIVE;
183
184 typedef struct _TOKEN_GROUPS
185 {
186 ULONG GroupCount;
187 SID_AND_ATTRIBUTES Groups[ANYSIZE_ARRAY];
188 } TOKEN_GROUPS, *PTOKEN_GROUPS;
189
190 typedef struct _TOKEN_PRIVILEGES
191 {
192 ULONG PrivilegeCount;
193 LUID_AND_ATTRIBUTES Privileges[ANYSIZE_ARRAY];
194 } TOKEN_PRIVILEGES, *PTOKEN_PRIVILEGES;
195
196 typedef struct _TOKEN_USER
197 {
198 SID_AND_ATTRIBUTES User;
199 } TOKEN_USER, *PTOKEN_USER;
200
201 typedef enum _TOKEN_INFORMATION_CLASS
202 {
203 TokenUser = 1,
204 TokenGroups,
205 TokenPrivileges,
206 TokenOwner,
207 TokenPrimaryGroup,
208 TokenDefaultDacl,
209 TokenSource,
210 TokenType,
211 TokenImpersonationLevel,
212 TokenStatistics,
213 TokenRestrictedSids,
214 TokenSessionId,
215 TokenGroupsAndPrivileges,
216 TokenSessionReference,
217 TokenSandBoxInert,
218 TokenAuditPolicy,
219 TokenOrigin,
220 TokenElevationType,
221 TokenLinkedToken,
222 TokenElevation,
223 TokenIsRestricted,
224 TokenAccessInformation,
225 TokenVirtualization,
226 TokenIntegrityLevel,
227 TokenIntegrityLevelDesktop,
228 TokenMandatoryPolicy,
229 MaxTokenInfoClass
230 } TOKEN_INFORMATION_CLASS, *PTOKEN_INFORMATION_CLASS;
231
232 typedef struct _TOKEN_OWNER
233 {
234 PSID Owner;
235 } TOKEN_OWNER, *PTOKEN_OWNER;
236
237 typedef struct _TOKEN_PRIMARY_GROUP
238 {
239 PSID PrimaryGroup;
240 } TOKEN_PRIMARY_GROUP, *PTOKEN_PRIMARY_GROUP;
241
242 typedef struct _TOKEN_DEFAULT_DACL
243 {
244 PACL DefaultDacl;
245 } TOKEN_DEFAULT_DACL, *PTOKEN_DEFAULT_DACL;
246
247 #endif // !NTOS_MODE_USER
248 #endif // _NTIFS_