Re: A weird routing question.
- From: Robert Harris <robert.f.harris@xxxxxxxxxxxxxxxx>
- Date: Thu, 27 Sep 2007 20:05:17 GMT
none wrote:
Hi all,You need to read "raw" packets at eth0 and write them to eth1.
Generally speaking, in an IP network, any IP packet which reach a node
(workstation, gateway, router...), and whichever the incoming interface,
will either be caught and absorbed by this node if it is the intended
recipient, or redirected for output (IP forwarding) through [another]
interface in respect to the current routing policy.
But I have a weird goal to achieve:
On a linux box 'A' which has interfaces eth0, eth1, eth2, eth3, I would
like to do a special treatment on packets incoming via eth0 and whose
source is <some-network>.
I would like these packets be unconditionaly redirected unmodified for
output via interface eth1.
That is:
- even if they were targeted (destination IP) at my box 'A', they will
be re-emitted through eth1.
- even if they would have been forwarded through eth2 or eth3, they
will be re-emitted through eth1 too.
Any idea to help me reach this goal?
Sincerely,
Le Testeur
"man packet" will get you started. There is also a library "libpcap"
that is used by tcpdump which you may find useful.
Robert
.
- Follow-Ups:
- Re: A weird routing question.
- From: none
- Re: A weird routing question.
- From: Unruh
- Re: A weird routing question.
- References:
- A weird routing question.
- From: none
- A weird routing question.
- Prev by Date: A weird routing question.
- Next by Date: Re: A weird routing question.
- Previous by thread: A weird routing question.
- Next by thread: Re: A weird routing question.
- Index(es):
Relevant Pages
|