Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 23 Sep 2013 12:10:12 +0800
From:      Julian Elischer <julian@freebsd.org>
To:        Ihsan Junaidi Ibrahim <ihsan@grep.my>
Cc:        "freebsd-net@freebsd.org" <freebsd-net@freebsd.org>
Subject:   Re: Programmatically forwarding packets to outgoing interface
Message-ID:  <523FBF24.50004@freebsd.org>
In-Reply-To: <4DC4F001-D430-4110-81DA-279F3D01AD33@grep.my>
References:  <4DC4F001-D430-4110-81DA-279F3D01AD33@grep.my>

next in thread | previous in thread | raw e-mail | index | archive | help
On 9/23/13 11:55 AM, Ihsan Junaidi Ibrahim wrote:
> Hi folks,
>
> I'm trying to learn building a VPN-type application on FreeBSD and I'm currently stuck at trying to route packets to outgoing interface.
>
> I've managed to push/pop IP packets in a tun(4) interface but now that I can read the inner packet header, I need to route the payload out of the box. I'm not quite sure which API I need to use to achieve this.
>
> The inner packets can be of either IPv4 or IPv6.
>
> Thanks.
> _______________________________________________
> freebsd-net@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-net
> To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org"
>
>
you can try use ipfw and its 'fwd' option to reroute packets
not sure if fwd works with ipv6.. I've never tried..



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?523FBF24.50004>