Re: Need help with usbstor.sys filter driver

Is there a way to install a filter driver to “usbstor.sys” and not “disk.sys”?

Thanks,
Yigal.

— Peter Wieland
wrote:

> I’m not sure how a service solves the problem of making the device
> visible in some sessions but not in others.
>
> on your second question: there is no “disk-on-key”
> device class, but there is a “disk” device class.
> That’s where you’d want to install your filter. You then need to
> determine whether the device is a USB disk or a fixed disk … you can

> use IOCTL_STORAGE_QUERY_PROPERTY to determine the bus type for a given

> disk device.
>
> I don’t beleive there’s a way to install your driver on a remote
> machine. SetupDI has some remote machine access, but i don’t believe
> that device installation is part of that. However i could be wrong -
> you should look at the SetupDi functions to find out for yourself.
>
> -p

Do you mean that you want the filter between disk.sys and usbstor.sys?
You can do this by making your filter a lower-class or lower-device
filter (depending on whether you want it on all disks).

If you meant is there a way to install my filter only on USB disks …
not really. The best you could do is install everywhere, check the bus
type during IRP_MJ_START_DEVICE handling, and do nothing if it’s not a
USB device.

-p

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Yigal Maman
Sent: Wednesday, October 25, 2006 9:43 PM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] Need help with usbstor.sys filter driver

Is there a way to install a filter driver to “usbstor.sys” and not
“disk.sys”?

Thanks,
Yigal.

— Peter Wieland
wrote:

> I’m not sure how a service solves the problem of making the device
> visible in some sessions but not in others.
>
> on your second question: there is no “disk-on-key”
> device class, but there is a “disk” device class.
> That’s where you’d want to install your filter. You then need to
> determine whether the device is a USB disk or a fixed disk … you can

> use IOCTL_STORAGE_QUERY_PROPERTY to determine the bus type for a given

> disk device.
>
> I don’t beleive there’s a way to install your driver on a remote
> machine. SetupDI has some remote machine access, but i don’t believe
> that device installation is part of that. However i could be wrong -
> you should look at the SetupDi functions to find out for yourself.
>
> -p


Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer