Reputation: 584
I am developing a mini-filter to intercept files and get the name of files which are dragged & dropped to a specific disk and get the file names.
If I drag & drop a file, I can get this file name and intercept it successfully (That's mean this file is not created on disk).
If I drag & drop multiple files, I can only get the first file name and other is not. But when I open the disk, I don't see any file here (That's mean Mini-Filter intercept them successfully). So I can not get the file names (except the first file)
I intercept drag & drop by redirect them:
Above code can only intercept all files and get the first file name.
How can I do to intercept each file when I drag & drop multiple file?
Upvotes: 0
Views: 820
Reputation: 1271
Make sure you check the simrep sample from Microsoft they show you how to properly do this. I would not base my assumption that Drag&Drop has a correspondence in the kernel and in the file-system. It can be implemented in user-mode in many ways especially if you are doing it on the same volume. It can be as simple as a rename. Also keep in mind hard-links and symboliclinks and alternate data streams.
Good luck.
Upvotes: 0
Reputation: 584
I found myself that:
Get file name from Data->Iopb->TargetFileObject->FileName
Delete redirect file name. This step can be run before step #1
Upvotes: 1