CreateFile is failing for filter drivers

Hi,
I have a WDM Driver for which CreateFile is failing after I
install it as a lower filter driver. If I install the driver as a
independent System Driver CreateFile succeeds. CreateFile() fails when we
install the Driver as the filter driver of the device. It gives me “Access
Denied” error. Please can anybody help me here?

Regards
Madhu

What particular device stack are you adding yourself as a lower filter to? Many stacks (like keyboard, mouse, etc) do not allow additional creates to the stack

d

From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of Madhusudan Narayan
Sent: Thursday, February 08, 2007 3:23 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] CreateFile is failing for filter drivers

Hi,
??? I have a WDM Driver for which CreateFile is failing after I install it as a lower filter driver. If I install the driver as a independent System Driver CreateFile succeeds.?CreateFile() fails when we install the Driver as the filter driver of the device. It gives me “Access Denied” error. Please can anybody help me here?
?
Regards
Madhu
?
— 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

> I have a WDM Driver for which CreateFile is failing after I

install it as a lower filter driver. If I install the driver as a
independent System Driver CreateFile succeeds. CreateFile() fails when we
install the Driver as the filter driver of the device. It gives me “Access
Denied” error. Please can anybody help me here?

The answer seems to be obvious - apparently, FDO driver just does not allow opening its device with CreateFile(), so that it fails IRP_MJ_CREATE, instead of passing it down to your driver.Kbdclass is a typical example of such FDO driver. However, when you install your driver as stand-alone one,
it receives IRP_MJ_CREATE directly from IO Manager and successfully processes it, so that CreateFile() call succeeds…

Anton Bassov

I installed it as a lower filter for the graphics device.

Doron Holan wrote: What particular device stack are you adding yourself as a lower filter to? Many stacks (like keyboard, mouse, etc) do not allow additional creates to the stack

d

From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of Madhusudan Narayan
Sent: Thursday, February 08, 2007 3:23 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] CreateFile is failing for filter drivers

Hi,
I have a WDM Driver for which CreateFile is failing after I install it as a lower filter driver. If I install the driver as a independent System Driver CreateFile succeeds. CreateFile() fails when we install the Driver as the filter driver of the device. It gives me “Access Denied” error. Please can anybody help me here?

Regards
Madhu

— 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


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

---------------------------------
Check out the all-new Yahoo! Mail beta - Fire up a more powerful email and get things done faster.

videoprt (and is Vista equivalent) do not allow files to be created against themselves. you have a few options

  1. filter above the FDO
  2. create a control device object with a fixed legacy name. this works well if you are only filtering one device on a machine
  3. enumerate a raw PDO. this works well if you are filtering more then one device on the machine. writing a bus driver to do this very easy w/KMDF.

d