From owner-freebsd-net Wed Mar 1 13: 8:32 2000 Delivered-To: freebsd-net@freebsd.org Received: from khavrinen.lcs.mit.edu (khavrinen.lcs.mit.edu [18.24.4.193]) by hub.freebsd.org (Postfix) with ESMTP id C2D9537B9E9 for ; Wed, 1 Mar 2000 13:04:56 -0800 (PST) (envelope-from wollman@khavrinen.lcs.mit.edu) Received: (from wollman@localhost) by khavrinen.lcs.mit.edu (8.9.3/8.9.3) id QAA64880; Wed, 1 Mar 2000 16:04:38 -0500 (EST) (envelope-from wollman) Date: Wed, 1 Mar 2000 16:04:38 -0500 (EST) From: Garrett Wollman Message-Id: <200003012104.QAA64880@khavrinen.lcs.mit.edu> To: Archie Cobbs Cc: wollman@khavrinen.lcs.mit.edu (Garrett Wollman), julian@elischer.org (Julian Elischer), ales@megared.net.mx (Alejandro Ramirez), net@FreeBSD.ORG Subject: Re: GRE Support in 4.X ??? In-Reply-To: <200003012039.MAA71524@bubba.whistle.com> References: <200003012036.PAA64720@khavrinen.lcs.mit.edu> <200003012039.MAA71524@bubba.whistle.com> Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org < said: > Sorry, I don't understand your point here. What does TCP > have to do with anything? Look at the code for a moment: if (ntohl(gre->type) != GRE_PROTOCOL_TYPE) { rip_input(m, iphlen); return; } So, if it's not the protocol we're expecting, we just punt it to the SOCK_RAW interface. len = m->m_len - len; if (ip->ip_len != len) { if (len > ip->ip_len || len < sizeof(struct ip)) { m_freem(m); return; } m_adj(m, iphlen + sizeof(struct gre)); } ip_input(m); Otherwise, decapsulate the packet and hand it directly to the IP layer to be acted upon as if it had been received directly. The user then configures IPFIREWALL_FORWARD to send the packet to lo0 where it gets interpreted by the local protocol stack. -GAWollman -- Garrett A. Wollman | O Siem / We are all family / O Siem / We're all the same wollman@lcs.mit.edu | O Siem / The fires of freedom Opinions not those of| Dance in the burning flame MIT, LCS, CRS, or NSA| - Susan Aglukark and Chad Irschick To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message