filter driver for AVStream

is it possible to create a filter driver for avstream? I know the mini port
is possible but if I want to control other flows for instance control the
setState methods and others. can I create a filter driver for the avstream?
I think I saw someplace it is not possible but not sure about that is it
true?

Miriam Engel wrote:

is it possible to create a filter driver for avstream? I know the mini
port is possible but if I want to control other flows for instance
control the setState methods and others. can I create a filter driver
for the avstream?
I think I saw someplace it is not possible but not sure about that is
it true?

Yes, an AVStream driver is just a normal WDM driver. You can install
filter drivers above or below.

However, it’s not easy. If you are an upper filter, then you are
intercepting the raw kernel streaming ioctls (IOCTL_KS_PROPERTY,
IOCTL_KS_METHOD, IOCTL_KS_READ_STREAM, etc). You don’t have the benefit
of the AVStream port driver interpreting the ioctls and calling your
convenient methods. For example, instead of a neat call to SetState,
you will get an IRP_MJ_DEVICECONTROL IRP with IOCTL_KS_PROPERTY for
property set KSPROPERTYSETID_Connection and property
KSPROPERTY_CONNECTION_STATE. And because these are all METHOD_NEITHER
ioctls, you have to do reverse engineering to figure out where the
buffers are located.


Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.