To send data from a user-mode application to a driver, the API DeviceIoControl can be used. If I want to send data from one driver to another, both of which are in kernel-mode, what options do I have? This is assuming, of course, that the drivers are not in the same stack and passing IRPs to one another already. Thank you.
IRP_MN_QUERY_INTERFACE is the most common way to exchange function pointers.
Bent from my phone
From: xxxxx@lists.osr.com on behalf of xxxxx@toddcullumresearch.com
Sent: Friday, December 15, 2017 10:40:33 PM
To: Windows System Software Devs Interest List
Subject: [ntdev] What options can I use to send data between drivers besides an IRP?
To send data from a user-mode application to a driver, the API DeviceIoControl can be used. If I want to send data from one driver to another, both of which are in kernel-mode, what options do I have? This is assuming, of course, that the drivers are not in the same stack and passing IRPs to one another already. Thank you.
—
NTDEV is sponsored by OSR
Visit the list online at: https:
MONTHLY seminars on crash dump analysis, WDF, Windows internals and software drivers!
Details at https:
To unsubscribe, visit the List Server section of OSR Online at https:</https:></https:></https:>
To add to Doron?s suggestion, I wrote an article about using bus interfaces for this a few years ago:
https://www.osr.com/nt-insider/2014-issue2/using-bus-interfaces-driver-driver-communication/
-scott
OSR
@OSRDrivers
You can also export a function from one driver, dll style, and call it from another. Watch out for driver load order though.