View Full Version : Packet Forwarding Fun!
paulq
07-17-2006, 07:06 PM
I'm looking to write a program that will make a computer act as a firewall\router\gateway. I am using the WinPcap library to capture the packets promiscuously then I want to forward them to their proper destination. Will I need to forward them manually using WinPcap send packet function or is there a setting in Windows or WinPcap that allows the automatic forwarding of packets to the proper destination?
paulq
07-18-2006, 03:51 PM
I may have answered my own question with this documentation (http://windowssdk.msdn.microsoft.com/en-us/library/ms690854.aspx).
The EnableRouter function turns on IP forwarding on the local computer. EnableRouter also increments a reference count that tracks the number of enable-IP-forwarding requests.
I will eventually try this out and keep everyone updated on how this works.
paulq
08-11-2006, 06:02 PM
UPDATE: I have tried this on an WinXP Home machine and it works well. EnableRouter is the function to use to turn automatic IP Forwarding on in MS Windows.
vBulletin® v3.8.2, Copyright ©2000-2010, Jelsoft Enterprises Ltd.