RE: Transfer a sending packet to upper TCP/IP protocol layer in IM
- From: Anton Bassov <AntonBassov@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Sat, 17 Mar 2007 13:38:03 -0700
Can I call NdisMIndicateReceivePacket() in my MiniportSendPacket()
Sure you can - this is out of question. The only question is what are you
going to achieve this way......
Can the TCP/IP driver foward the packet correctly ?
Forward to whom???? MiniportSendPackets() deals only with outgoing packets,
which means that packet' s source IP and MAC addresses are local and
destination ones are remote, i.e. the packet is outgoing one and TCPIP
already made its routing decision to send a packet via either underlying
adapter (if you speak about filter), or via your virtual miniport (if you
speak about MUX). If you want to change the adapter the packet gets sent
through, you have to call NdisSend() and, specify NDIS_HANDLE that
corresponds to that adapter ( apparently, it is a good idea to replace MAC
addresses in a packet's ARP header as well), rather than indicating it
to TCPIP as incoming one. Apparently, TCPIP is going to silently discard
your packet if you indicate it, and that's it......
If you want TCPIP to treat you packet as incoming one, you have to modify
both physical and logical transport addresses in the packet's headers.
However, if TCPIP
takes it for incoming one, why should it send it to any remote
address(unless logical IP address in the packet's header is remote and the
system is configured as a router)????
In other words, no matter what you do, you have to modify packet's headers
in such way that it conforms to the logic of the bound protocol...
Another option (at least in MUX) could be taking the whole packet simply as
data, and resubmitting it to TCPIP via its TDI interface, i.e. to act simply
as TCPIP's client
If you tell us a bit more about your objectives, probably, we will be able
to give you the most appropriate advice....
Anton Bassov
"Seong Moon" wrote:
Hi ! There !.
I'm now designing Intermediate Driver for my project.
I'd like to transfer sending packet to the upper TCP/IP protocol layer on my
MiniportSendPackets function as if the packet is received from the NIC.
And I'd like to have IP protocol layer forward the transferred packet to the
adaquate adaptor.
Is it possible ?
That is, Can I call NdisMIndicateReceivePacket() in my MiniportSendPacket() ?
If that possible, Can the TCP/IP driver foward the packet correctly ?
Thanks in advance.
regards seong
- Follow-Ups:
- RE: Transfer a sending packet to upper TCP/IP protocol layer in IM
- From: Seong Moon
- RE: Transfer a sending packet to upper TCP/IP protocol layer in IM
- Prev by Date: bda ip sink and vista
- Next by Date: Re: Transfer a sending packet to upper TCP/IP protocol layer in IM
- Previous by thread: Re: Transfer a sending packet to upper TCP/IP protocol layer in IM
- Next by thread: RE: Transfer a sending packet to upper TCP/IP protocol layer in IM
- Index(es):
Relevant Pages
|
Loading