#include <ntoskrnl.h>
#include <debug.h>
Go to the source code of this file.
|
VOID NTAPI | FsRtlPTeardownPerFileObjectContexts (IN PFILE_OBJECT FileObject) |
|
LOGICAL NTAPI | FsRtlIsPagingFile (IN PFILE_OBJECT FileObject) |
|
PFSRTL_PER_FILEOBJECT_CONTEXT NTAPI | FsRtlLookupPerFileObjectContext (IN PFILE_OBJECT FileObject, IN PVOID OwnerId OPTIONAL, IN PVOID InstanceId OPTIONAL) |
|
PFSRTL_PER_STREAM_CONTEXT NTAPI | FsRtlLookupPerStreamContextInternal (IN PFSRTL_ADVANCED_FCB_HEADER AdvFcbHeader, IN PVOID OwnerId OPTIONAL, IN PVOID InstanceId OPTIONAL) |
|
NTSTATUS NTAPI | FsRtlInsertPerFileObjectContext (IN PFILE_OBJECT FileObject, IN PFSRTL_PER_FILEOBJECT_CONTEXT Ptr) |
|
NTSTATUS NTAPI | FsRtlInsertPerStreamContext (IN PFSRTL_ADVANCED_FCB_HEADER AdvFcbHeader, IN PFSRTL_PER_STREAM_CONTEXT PerStreamContext) |
|
PFSRTL_PER_FILEOBJECT_CONTEXT NTAPI | FsRtlRemovePerFileObjectContext (IN PFILE_OBJECT FileObject, IN PVOID OwnerId OPTIONAL, IN PVOID InstanceId OPTIONAL) |
|
PFSRTL_PER_STREAM_CONTEXT NTAPI | FsRtlRemovePerStreamContext (IN PFSRTL_ADVANCED_FCB_HEADER AdvFcbHeader, IN PVOID OwnerId OPTIONAL, IN PVOID InstanceId OPTIONAL) |
|
VOID NTAPI | FsRtlTeardownPerStreamContexts (IN PFSRTL_ADVANCED_FCB_HEADER AdvFcbHeader) |
|
◆ NDEBUG
◆ FILE_OBJECT_FILTER_CONTEXTS
◆ PFILE_OBJECT_FILTER_CONTEXTS
◆ FsRtlInsertPerFileObjectContext()
Definition at line 175 of file filtrctx.c.
177{
180
182 {
184 }
185
187 {
189 }
190
191
193 if (!FOContext)
194 {
195
197 if (!FOContext)
198 {
200 }
201
202
205
206
209 {
210
212
213
215 if (!FOContext)
216 {
217
220 }
221 }
222 }
223
224
228
230}
#define NT_SUCCESS(StatCode)
#define InsertHeadList(ListHead, Entry)
#define ExAllocatePoolWithTag(hernya, size, tag)
#define InitializeListHead(ListHead)
_Must_inspect_result_ _In_ PFSRTL_PER_STREAM_CONTEXT Ptr
VOID FASTCALL ExAcquireFastMutex(IN PFAST_MUTEX FastMutex)
VOID FASTCALL ExReleaseFastMutex(IN PFAST_MUTEX FastMutex)
#define ExFreePoolWithTag(_P, _T)
#define FO_FILE_OBJECT_HAS_EXTENSION
NTSTATUS NTAPI IoChangeFileObjectFilterContext(IN PFILE_OBJECT FileObject, IN PVOID FilterContext, IN BOOLEAN Define)
PVOID NTAPI IoGetFileObjectFilterContext(IN PFILE_OBJECT FileObject)
FAST_MUTEX FilterContextsMutex
LIST_ENTRY FilterContexts
#define STATUS_INVALID_DEVICE_REQUEST
#define STATUS_INVALID_PARAMETER
#define STATUS_UNSUCCESSFUL
#define STATUS_INSUFFICIENT_RESOURCES
_In_ WDFREQUEST _In_ WDFFILEOBJECT FileObject
FORCEINLINE VOID ExInitializeFastMutex(_Out_ PFAST_MUTEX FastMutex)
◆ FsRtlInsertPerStreamContext()
Definition at line 237 of file filtrctx.c.
239{
241 {
243 }
244
246 InsertHeadList(&(AdvFcbHeader->FilterContexts), &(PerStreamContext->Links));
249}
#define FSRTL_FLAG2_SUPPORTS_FILTER_CONTEXTS
◆ FsRtlIsPagingFile()
Definition at line 64 of file filtrctx.c.
65{
67}
BOOLEAN NTAPI MmIsFileObjectAPagingFile(PFILE_OBJECT FileObject)
◆ FsRtlLookupPerFileObjectContext()
Definition at line 74 of file filtrctx.c.
77{
81
83 {
85 }
86
88
89
91 {
94 NextEntry = NextEntry->
Flink)
95 {
96
98 {
100 break;
101 }
102
103 else
104 {
108 {
109 PerFOContext = TmpPerFOContext;
110 break;
111 }
112 }
113 }
114 }
115
117
118 return PerFOContext;
119}
#define IsListEmpty(ListHead)
_Must_inspect_result_ _In_opt_ PVOID _In_opt_ PVOID InstanceId
_Must_inspect_result_ _In_opt_ PVOID OwnerId
struct _FSRTL_PER_FILEOBJECT_CONTEXT * PFSRTL_PER_FILEOBJECT_CONTEXT
struct _LIST_ENTRY * Flink
#define CONTAINING_RECORD(address, type, field)
◆ FsRtlLookupPerStreamContextInternal()
Definition at line 126 of file filtrctx.c.
129{
132
135
137
138
140 {
141 for (NextEntry = AdvFcbHeader->FilterContexts.Flink;
142 NextEntry != &(AdvFcbHeader->FilterContexts);
143 NextEntry = NextEntry->
Flink)
144 {
145
147 {
149 break;
150 }
151
152 else
153 {
157 {
158 PerStreamContext = TmpPerStreamContext;
159 break;
160 }
161 }
162 }
163 }
164
166
167 return PerStreamContext;
168}
struct _FSRTL_PER_STREAM_CONTEXT * PFSRTL_PER_STREAM_CONTEXT
◆ FsRtlPTeardownPerFileObjectContexts()
◆ FsRtlRemovePerFileObjectContext()
Definition at line 256 of file filtrctx.c.
259{
263
265 {
267 }
268
270
271
273 {
276 NextEntry = NextEntry->
Flink)
277 {
278
280 {
282 break;
283 }
284
285 else
286 {
290 {
291 PerFOContext = TmpPerFOContext;
292 break;
293 }
294 }
295 }
296
297
298 if (PerFOContext)
299 {
301 }
302 }
303
305
306 return PerFOContext;
307}
#define RemoveEntryList(Entry)
◆ FsRtlRemovePerStreamContext()
Definition at line 314 of file filtrctx.c.
317{
320
322 {
324 }
325
327
329 {
330 for (NextEntry = AdvFcbHeader->FilterContexts.Flink;
331 NextEntry != &(AdvFcbHeader->FilterContexts);
332 NextEntry = NextEntry->
Flink)
333 {
334
336 {
338 break;
339 }
340
341 else
342 {
346 {
347 PerStreamContext = TmpPerStreamContext;
348 break;
349 }
350 }
351 }
352
353
354 if (PerStreamContext)
355 {
357 }
358 }
360
361 return PerStreamContext;
362
363}
◆ FsRtlTeardownPerStreamContexts()