From owner-freebsd-questions@FreeBSD.ORG Fri Feb 6 12:25:45 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 589BC106566C for ; Fri, 6 Feb 2009 12:25:45 +0000 (UTC) (envelope-from frederic.perrin@resel.fr) Received: from maisel-gw.enst-bretagne.fr (maisel-gw.enst-bretagne.fr [192.44.76.8]) by mx1.freebsd.org (Postfix) with ESMTP id DCD458FC1A for ; Fri, 6 Feb 2009 12:25:44 +0000 (UTC) (envelope-from frederic.perrin@resel.fr) Received: from localhost (localhost [127.0.0.1]) by maisel-gw.enst-bretagne.fr (Postfix) with ESMTP id 4A9E419C02; Fri, 6 Feb 2009 13:25:43 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at resel.fr Received: from maisel-gw.enst-bretagne.fr ([127.0.0.1]) by localhost (mercure.adm.maisel.enst-bretagne.fr [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id mCx0Dz+38-qx; Fri, 6 Feb 2009 13:25:37 +0100 (CET) Received: from chameau.maisel.enst-bretagne.fr (chameau.maisel.enst-bretagne.fr [172.22.209.241]) (Authenticated sender: fperrin) by maisel-gw.enst-bretagne.fr (Postfix) with ESMTP id 8CC9D19C00; Fri, 6 Feb 2009 13:25:37 +0100 (CET) Received: by chameau.maisel.enst-bretagne.fr (Postfix, from userid 1001) id 3ECF1B829; Fri, 6 Feb 2009 13:25:37 +0100 (CET) From: =?utf-8?Q?Fr=C3=A9d=C3=A9ric_Perrin?= To: Nikos Vassiliadis Organization: =?utf-8?Q?R=C3=A9seau?= des =?utf-8?B?w4lsw6h2ZXM=?= References: <863aeunkj0.fsf@chameau.maisel.enst-bretagne.fr> <498AABCC.4090809@gmx.com> Date: Fri, 06 Feb 2009 13:25:36 +0100 In-Reply-To: <498AABCC.4090809@gmx.com> (Nikos Vassiliadis's message of "Thu, 05 Feb 2009 11:05:16 +0200") Message-ID: <86ocxfeoqn.fsf@chameau.maisel.enst-bretagne.fr> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: FreeBSD Questions Subject: Re: Multiple MAC on a single (physical) interface X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 Feb 2009 12:25:45 -0000 Le Jeudi 5 =C3=A0 10:05, Nikos Vassiliadis a =C3=A9crit : > Fr=C3=A9d=C3=A9ric Perrin wrote: >> I need to be able >> to send and receive using several MAC addresses, as if I had several >> NIC (which I of course don't have). >> >> [...] >> > Yes, you could use a netgraph bridge to bridge several > ethernet interfaces together. Luckily, there is also a > pseudo-ethernet-like interface you can attach to this > bridge and of course you get to treat the pseudo-ethernet > as a regular ethernet interface, that is, change its > MAC address. > > The process is described here: > http://www.bsdatwork.com/2004/06/19/mac_spoofing_on_freebsd/ Oh, yes, I actually remember trying that. However, on the first ngctl(8) invocation I do (even a 'ngctl list' after a clean reboot), the kernel says : > WARNING: attempt to net_add_domain(netgraph) after domainfinalize() I can reproduce this by doing a 'kldload ng_socket'. kldstat(8) says that the module is loaded anyway. A quick googling says that this message is harmless. A 2006 post says that it was silenced in 6-STABLE ; it lokks like this haven't made its way to the 7.1-RELEASE I'm using. However ; On the next step, when I create the bridge, I have : # ngctl -dd mkpeer ngeth0: bridge lower link0 [...] ngctl: sendto(ngeth0:): No such file or directory ngctl: send msg: No such file or directory I guess I have to read more in details about how netgraph works in recent releases of FreeBSD before goiing on. Unfortunately, I will soon be physically away from my FreeBSD box for a week, and fiddling with net interfaces is tipically something I'm afraid of doing through SSH. Thanks anyway from the pointer. --=20 Fred