How can I get (or construct) the full path name of a file from its file
object?
I want to open a file during my completion routine on MJ_CREATE. To
accomplish that I save the relative path passed to the MJ_CREATE before
calling the lower level driver, but I don’t know how to get the device name.
I searched the documentation but I didn’t found an easy way to do it. I
suppose that this has to be a single function call. FYI: I need a way to do
this on Windows 2000 also.
Thanks,
Andres
B绗?'癤?y?呪HPj豰稕?0⑹铻X?韷蒦qw^丌娅y双項+.n?壏澏夗~荶暴莪?jh殲ib潽喈岀奌^甮$韬{.n?壏瑉wZnV
闅奫h曟痾{_陛y胛嫋±矉+
You can find the answer in the source code of Filemon:)
“Andrej Mlinar Groznik” 写入邮件 news:xxxxx@ntfsd…
How can I get (or construct) the full path name of a file from its file object?
I want to open a file during my completion routine on MJ_CREATE. To accomplish that I save the relative path passed to the MJ_CREATE before calling the lower level driver, but I don’t know how to get the device name. I searched the documentation but I didn’t found an easy way to do it. I suppose that this has to be a single function call. FYI: I need a way to do this on Windows 2000 also.
Thanks,
Andres
B绗?'癤?y?呪HPj豰稕? 0⑹铻X?韷蒦qw^丌娅y双項+.n?壏澏夗~荶暴莪?jh殲ib潽喈岀奌^甮$韬{.n?壏瑉wZnV闅奫h曟痾{_陛y胛嫋±矉+
Thanks, works nicely.
From: Ladislav Zezula [mailto:xxxxx@volny.cz]
Sent: Thursday, June 24, 2004 1:06 PM
To: Windows File Systems Devs Interest List
Subject: Re: [ntfsd] Full path name from FILE_OBJECT
-
Query the name of the device using ObQueryNameString,
-
Append backslash, if necessary
-
Query the name of the related file object, if not NULL
-
Append backslash, if necessary
-
Query the name of the file that has been open
(If the file open/create succeeded)
L.
Questions? First check the IFS FAQ at
https://www.osronline.com/article.cfm?id=17
You are currently subscribed to ntfsd as:
xxxxx@hermes.si
To unsubscribe send a blank email to xxxxx@lists.osr.com
A better sample then filemon is the filespy sample in the IFSKIT.
The latest sources for filemon are no longer available and the sources that are still being passed around are old and out of date. Some versions have bugs in the file name generation code.
Neal Christiansen
Microsoft File System Filter Group Lead
This posting is provided “AS IS” with no warranties, and confers no rights.
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of Andrej Mlinar Groznik
Sent: Thursday, June 24, 2004 9:36 AM
To: Windows File Systems Devs Interest List
Subject: RE: [ntfsd] Full path name from FILE_OBJECT
Thanks, works nicely.
From: Ladislav Zezula [mailto:xxxxx@volny.cz]
Sent: Thursday, June 24, 2004 1:06 PM
To: Windows File Systems Devs Interest List
Subject: Re: [ntfsd] Full path name from FILE_OBJECT
- Query the name of the device using ObQueryNameString,
- Append backslash, if necessary
- Query the name of the related file object, if not NULL
- Append backslash, if necessary
- Query the name of the file that has been open
???(If the file open/create succeeded)
?
L.
Questions? First check the IFS FAQ at https://www.osronline.com/article.cfm?id=17
You are currently subscribed to ntfsd as: xxxxx@hermes.si
To unsubscribe send a blank email to xxxxx@lists.osr.com
Questions? First check the IFS FAQ at https://www.osronline.com/article.cfm?id=17
You are currently subscribed to ntfsd as: xxxxx@windows.microsoft.com
To unsubscribe send a blank email to xxxxx@lists.osr.com