From owner-freebsd-net@FreeBSD.ORG Sat Nov 13 15:36:39 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A5D3116A4CE for ; Sat, 13 Nov 2004 15:36:39 +0000 (GMT) Received: from pan.gwi.net (pan.gwi.net [207.5.128.165]) by mx1.FreeBSD.org (Postfix) with ESMTP id 121A843D1F for ; Sat, 13 Nov 2004 15:36:39 +0000 (GMT) (envelope-from kurlon@gwi.net) Received: from [192.168.1.5] (66-55-199-20.gwi.net [66.55.199.20]) by pan.gwi.net (8.12.9p2/8.12.9) with ESMTP id iADFab7C041944 for ; Sat, 13 Nov 2004 10:36:38 -0500 (EST) (envelope-from kurlon@gwi.net) Mime-Version: 1.0 (Apple Message framework v619) Content-Transfer-Encoding: 7bit Message-Id: Content-Type: text/plain; charset=US-ASCII; format=flowed To: freebsd-net@freebsd.org From: Josh Coombs Date: Sat, 13 Nov 2004 10:36:37 -0500 X-Mailer: Apple Mail (2.619) Subject: Netgraph node with inet and ethernet hooks? X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 13 Nov 2004 15:36:39 -0000 I'm trying to find a way to get PPPoE half-bridging functionality working with FreeBSD, similar to what Cisco routers and many older ISDN routers can/could do. Basically, I'm trying to get the ip/subnet assigned to the ppp link usable on an ethernet interface. So, on the radius side, you have (format is off, I know...) user dsluser, prefix=P fixed-address = 10.0.0.1 fixed-netmask = 255.255.255.0 Normally, when mpd connects up, 10.0.0.1 will be assigned with a /32 netmask to ng0 or whatever netgraph iface node is created for the job. Warning, bad ascii table: +-----+ |xl1 | |ether| | | +-----+ |orphans | ethernet| +--------+ |0000000b| |pppoe | | | +--------+ |mpd983_pppoe | link0 | +--------+ +------------+ +--------+ |00000005|bypass |mpd983_pppoe|VJC Support |00000009| |socket |-------|00000007 |------------|vjc | | | bypass|ppp | VJC Support| | +--------+ +------------+ +--------+ |demand |inet | | | ppp| | +--------+ | |00000008| |--------------|bpf | mpd| | +--------+ |iface | inet| +--------+ |ng0 | |00000006| |iface | +--------+ Having spent a couple nights trying to get myself up to speed with netgraph, it seems if I can get a node that takes inet (ip) in, and spits out ethernet, I can then attach from the bpf node direct to an existing ethernet interface. Looking around, I can't find a node type that accomplishes this. Does such a connector exist? If not, is the closest logical option to stick a ng_socket between the bpf and ethernet nodes, and do the ethernet [en,de]capsulation in userland? Joshua Coombs