I have an NDIS intermediate driver running on Win 2K and XP. The driver is fully functional and operational, but I now need to add additional functionality to the driver which seems to require that I indicate received packets to NDIS outside of the receive handler or transfer data complete handlers of the driver. Specifically, packets may arrive compressed which have been fragmented by the remote sender. These fragments are queued (since the entire packet must be present for the driver to perform decompression) and the receive handler returns without indicating the received packet. At some later point in time, after the packet has been re-assembled and decompressed, I call NdisMIndicateReceivePacket(…) (in the context of my receive complete handler) with the decompressed packet in order to indicate the packet up to all bound protocols above the driver.
Using Network Monitor, I can see the reassembled/decompressed packets arriving and they appear valid. However, it appears that the packets are not being accepted by something above my driver - namely, TCP returns ACKs for the packet received prior to the reassembled packet being received and the connection will eventually fail. Occasionally (due to the nature of the compression algorithm), the retransmitted packet will not need fragmentation and the packet is accepted. By comparing the successfully accepted and the not successfully accepted packets, the data in the not accepted packet is correct, and all headers (Ethernet, IP, TCP) are correct (including checksums).
My questions:
1.) Can I use this approach of delaying indicating the receive?
2.) If the answer is Yes, what tools are available other than Network Monitor to debug why TCPIP.SYS (???) apparently does not accept the indicated packet?
3.) If the answer is No, what other methods are available to achieve this functionality?
Thanks in advance,
Ed Lau
ArteraGroup, Inc.
900 Straits Tpke
Middlebury, CT 06762