1
To test a TCP-stack program, I need to get the TCP packets via the router. When I try to connect to my server program via the router, the OS does not hit the router as the destination IP is the same as the source IP.
Can I make a temporary rule to tell the Linux stack to use a specific adapter (wlan0
) and a specific router address for outgoing TCP packets with a specific target port (5101
)?
Linux will use
wlan0
if that is the route for the IP. Does it need to be port 5101, or can all traffic be temporarily routed through the router? Why don't you tryman ip-route
? – BenjiWiebe – 2014-02-03T13:51:35.430@BenjiWiebe: I checked with wireshark, and there is definitively no packet going over
wlan0
when accessing the computer's own IP. – Lanbo – 2014-02-05T08:21:43.770