RE: How to distinguish between creating a reparse point a nd opening a reparse point file by a filte

Check for FILE_OPEN_REPARSE_POINT (in Parameters.Create.Options) in the
CREATE IRP. An applicaton must use this option to manipulate an object’s
reparse point. It is when this flag is absent, the FSD can return
STATUS_REPARSE.

/ted

-----Original Message-----
From: Shangwu [mailto:xxxxx@fcni.com]
Sent: Tuesday, February 17, 2004 5:35 PM
To: Windows File Systems Devs Interest List
Subject: [ntfsd] How to distinguish between creating a reparse point and
opening a reparse point file by a filter driver

Probably only Microsoft folks can answer this question.
My file system filter driver is designed to take actions for opening an
existing reparse point file. But now I found that when an user mode program
calls DeviceIoControl with FSCTL_SET_REPARSE_POINT to convert a normal file
to a reparse point file, my filter driver receives the same request as an
existing reparse point file is opened. I guess the DeviceIoControl with
FSCTL_SET_REPARSE_POINT internally calls ZwCreateFile to make the
conversion. Is there any flag in the IRP by which my filter driver can
distinguish the different requests?

Thanks and regards,

Shangwu


Questions? First check the IFS FAQ at
https://www.osronline.com/article.cfm?id=17

You are currently subscribed to ntfsd as: xxxxx@livevault.com To unsubscribe
send a blank email to xxxxx@lists.osr.com

Ted,

Thank you for inputting. My filter driver does check the flag and it is fine
when the file is opened by CreateFile with FILE_OPEN_REPARSE_POINT in the
beginning. The problem is that later when DeviceIoControl() and
CloseHandle() are called, the filter receives other three IRP_MJ_CREATE
requests without FILE_OPEN_REPARSE_POINT flag. This confuses the filter.

Regards,

Shangwu

“Ted Hess” wrote in message news:xxxxx@ntfsd…
> Check for FILE_OPEN_REPARSE_POINT (in Parameters.Create.Options) in the
> CREATE IRP. An applicaton must use this option to manipulate an object’s
> reparse point. It is when this flag is absent, the FSD can return
> STATUS_REPARSE.
>
> /ted
>
> -----Original Message-----
> From: Shangwu [mailto:xxxxx@fcni.com]
> Sent: Tuesday, February 17, 2004 5:35 PM
> To: Windows File Systems Devs Interest List
> Subject: [ntfsd] How to distinguish between creating a reparse point and
> opening a reparse point file by a filter driver
>
>
> Probably only Microsoft folks can answer this question.
> My file system filter driver is designed to take actions for opening an
> existing reparse point file. But now I found that when an user mode
program
> calls DeviceIoControl with FSCTL_SET_REPARSE_POINT to convert a normal
file
> to a reparse point file, my filter driver receives the same request as an
> existing reparse point file is opened. I guess the DeviceIoControl with
> FSCTL_SET_REPARSE_POINT internally calls ZwCreateFile to make the
> conversion. Is there any flag in the IRP by which my filter driver can
> distinguish the different requests?
>
> Thanks and regards,
>
> Shangwu
>
>
>
> —
> Questions? First check the IFS FAQ at
> https://www.osronline.com/article.cfm?id=17
>
> You are currently subscribed to ntfsd as: xxxxx@livevault.com To
unsubscribe
> send a blank email to xxxxx@lists.osr.com
>