Tech Support > Microsoft Windows > Drivers > Is there a way to dynamically call NdisIMAssociateMiniport?
Is there a way to dynamically call NdisIMAssociateMiniport?
Posted by Quinton Wang on November 3rd, 2003


Is there a way to load NDIS.SYS and find NdisIMAssociateMiniport
address? I know it's working under USER MODE, e.g. using LoadLibrary
and GetProcAddress to call a func from DLLs.

I'm working on NDIS Intermediate Driver. I need to call
NdisIMAssociateMiniport on Windows 2k/xp, which causes a loading error
on Windows 98. I want to make it BINARY COMPATIBLE so I can't call
directly NdisIMAssociateMiniport in my code. So I need to find a way
to find the address of NdisIMAssociateMiniport during the run time.
Is it gonna work?

Regards,

Quinton

Posted by Duh Pohmelja on November 3rd, 2003


Quinton Wang wrote:
NDIS versions are incompatible...


Posted by Maxim S. Shatskih on November 3rd, 2003


Try just forgetting to call NdisIMAssociateMiniport. Will it work?

Another way is to write your own GetProcAddress by parsing the PE export
table and your own GetModuleHandle from ZwQuerySystemInformation. This is not
NDIS-compatible though.

--
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
maxim@storagecraft.com
http://www.storagecraft.com

"Quinton Wang" <wruoca@hotmail.com> wrote in message
news:952aed2a.0311030753.47cb5692@posting.google.c om...


Posted by Pavel A. on November 3rd, 2003


"Quinton Wang" <wruoca@hotmail.com> wrote in message
news:952aed2a.0311030753.47cb5692@posting.google.c om...
NdisGetRoutineAddress() ?

- PA




Posted by Alireza Dabagh [MS] on November 5th, 2003


Why do you want to be binary compatible?

-ali

--
This posting is provided "AS IS" with no warranties, and confers no rights.

"Quinton Wang" <wruoca@hotmail.com> wrote in message
news:952aed2a.0311030753.47cb5692@posting.google.c om...


Posted by Quinton Wang on November 27th, 2003


Thanks, guys.

Our competitor can provide binary-compatible, so we'd better be same.
However, I can only make it source compatible.

NdisGetRoutineAddress is only available in Windows XP and later
versions. I guess that's why Microsoft only declares NDIS driver is
source compatible in Windows 9x and 2K. NDIS driver can be binary
compatible with NdisGetRoutineAddress from Windows XP.


Regards,
Quinton


"Alireza Dabagh [MS]" <alid@online.microsoft.com> wrote in message news:<uVnHhQ2oDHA.392@TK2MSFTNGP11.phx.gbl>...

Posted by Pavel A. on November 27th, 2003


"Quinton Wang" <wruoca@hotmail.com> wrote in message news:952aed2a.0311271129.5f6a61c1@posting.google.c om...
NdisGetRoutineAddress also exists in win2000 SP3, but unfortunately not in earlier SPs

For win9x - I wonder if Walter Oney has plans to add NDIS routines into his wdmstub, or even
implement MmGetProcedureAddress and NdisGetRoutineAddress ?

-- PA



Posted by Alexander Grigoriev on November 28th, 2003


What's wrong with having two different binaries copied by a single INF file,
depending on the OS? It's still one INF file, no need for the user to
choose, etc.

"Quinton Wang" <wruoca@hotmail.com> wrote in message
news:952aed2a.0311271129.5f6a61c1@posting.google.c om...



Similar Posts