The free OSR Learning Library has more than 50 articles on a wide variety of topics about writing and debugging device drivers and Minifilters. From introductory level to advanced. All the articles have been recently reviewed and updated, and are written using the clear and definitive style you've come to expect from OSR over the years.
Check out The OSR Learning Library at: https://www.osr.com/osr-learning-library/
I am building a file system Minifilter driver to track all I/Os to a volumes which becomes the foundation for our incremental backups for our disk image Backups .
I have taken the minispy sample driver . We have registered IRP_MJ_Write alone .
On analyzing the argument received during Pre op and Post op callbacks
Data->Iopb->Parameters.Write.ByteOffset; The File Offset of the I/O
Data->Iopb->Parameters.Legnth; Total I/O Legnth
The File Offset of the I/O is received . Is there any argument which directly gives me the volume offset like legacy filters .
To map the file Offset to volume offset I have used this API call
FltFsControlFile(Data->Iopb->TargetInstance, FltObjects->FileObject, .....)
With FSCTL_GET_RETRIEVAL_POINTERS IOCTL
Which fetches the Cluster Extents or runs of the Entire File .
But the API returns STATUS_END_OF_FILE for small Files (less than Cluster Size , Data Written in MFT record itself )
and INVALID_PARAMETER for System Files such as $MFT ,$ Logfile .etc .
Any inputs would be highly valuable . Is my approach correct or should I go for another approach .
|Upcoming OSR Seminars|
|OSR has suspended in-person seminars due to the Covid-19 outbreak. But, don't miss your training! Attend via the internet instead!||Kernel Debugging||30 Mar 2020||OSR Seminar Space|
|Developing Minifilters||15 Jun 2020||LIVE ONLINE|
|Writing WDF Drivers||22 June 2020||LIVE ONLINE|
|Internals & Software Drivers||28 Sept 2020||Dulles, VA|