From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 12 04:26:27 2008 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4C3DA16A420 for ; Sat, 12 Jan 2008 04:26:27 +0000 (UTC) (envelope-from subhashg.unix@gmail.com) Received: from hu-out-0506.google.com (hu-out-0506.google.com [72.14.214.239]) by mx1.freebsd.org (Postfix) with ESMTP id D763313C467 for ; Sat, 12 Jan 2008 04:26:26 +0000 (UTC) (envelope-from subhashg.unix@gmail.com) Received: by hu-out-0506.google.com with SMTP id 28so539353hub.8 for ; Fri, 11 Jan 2008 20:26:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to:subject:mime-version:content-type; bh=fL3MgB+0J8blBu1b3qBtXoJElvsbrDWGMu5iB05gz9I=; b=RfCqqeB5d1zPoqs7KbgDTRfBW0gNhbMENiIh4d494wLGBWwPed65VD6LjI+SeIusuUMGEPxzgeh8IuEbDsBLYDAPfNRJ88sEh7BDfwCqMai99XTX6j6tKuH1gi+9R+A6dheQLACA41g8fJ+bqwxgfr73Fw3+eVWcQhce2LNT+wI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type; b=d95iaIV+9F/ftw2bVMYQ9jbUuAKOI1/BhnnpjmTmFYoKHMjYr3Gim1faNyFOeudVDc5oteAzWtOU1JlBGJAN31nYXEZ4pQ+y5yIAJV9b4V+uQmER4m/S0eCS8yOiaWlJ4oR6NH5u3RYituPT4jY9PyxM5kiWYNqcXSWRDWCpCG4= Received: by 10.78.132.2 with SMTP id f2mr4816481hud.19.1200111034750; Fri, 11 Jan 2008 20:10:34 -0800 (PST) Received: by 10.78.187.8 with HTTP; Fri, 11 Jan 2008 20:10:34 -0800 (PST) Message-ID: <5db9d2e0801112010s55812b20p6a43f0fbb5cddd17@mail.gmail.com> Date: Fri, 11 Jan 2008 20:10:34 -0800 From: "Subhash Gopinath" To: freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: netgraph question X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Jan 2008 04:26:27 -0000 Hello folks, I am looking at writing an application program to tap certain ipv6 packets (say icmpv6) using netgraph. The application has to do some processing, before kernel can proceed with those packets. I have vaguely understood netgraph, and I see that I need a ng_socket node in the application, an ng_bpf node, and an ng_ether or ng_iface node in the kernel. My question is. would I need to create such nodes for each interface. Then it becomes unscalable.. Can I have just one socket, bpf, iface node that can tap icmpv6 packets on all interfaces? I'll reiterate if this question was not clear. Any help would be greatly appreciated... Otherwise I'll have to end up using raw sockets.. Thanks, Subhash