Re: Reinjecting IP Packets

Parmer
2003-08-22T18:32:33Z

On Fri, 22 Aug 2003, Ben Greear wrote:

> Patrick Sodre Carlos wrote:
> > Hi Guys,
> > I'm trying to figure out what is the best way to reinject IP packets
> > into the stack. Does anyone have good/right/left ideas on this?
>
> Maybe netif_rx() in net/core/dev.c ?

If you want an example of how this is done, look in /net/ipv4/ipip.c and
(I'm pretty sure) /net/ipv4/ip_gre.c. I only know 2.4.*, but the files
still exist in 2.6, and they probably do it the same way.

Fairly elegant way to strip some headers and send it though again.

Hope that helps,
Gabe