From owner-freebsd-questions@FreeBSD.ORG Sun Jan 25 17:51:52 2015 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id F1124FE0 for ; Sun, 25 Jan 2015 17:51:52 +0000 (UTC) Received: from homiemail-a104.g.dreamhost.com (sub4.mail.dreamhost.com [69.163.253.135]) by mx1.freebsd.org (Postfix) with ESMTP id D241AF86 for ; Sun, 25 Jan 2015 17:51:51 +0000 (UTC) Received: from homiemail-a104.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a104.g.dreamhost.com (Postfix) with ESMTP id 70F512004692F; Sun, 25 Jan 2015 09:51:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=doomgeek.com; h=subject :mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; s= doomgeek.com; bh=OGtq5aD5l1+lGAuAf+i83K7hLcU=; b=bu1TjF+6Z1+ZCAM CUK2AQTgwOk0y3lxDTvNKSDsw3AWyJhJEKIY57GWLhXO+ZrlokIj+vCHL9MF4IWs QWcNbU+kkFg7bT+ZXTxJ2sfM2YGYE1P+onIvhO7vcv7mc6nkjYXDUCpwOwWzPA0B B105mRakW4WPLNLipsAVTi6/OoFY= Received: from [10.0.66.52] (c-73-20-92-222.hsd1.ut.comcast.net [73.20.92.222]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: geek@doomgeek.com) by homiemail-a104.g.dreamhost.com (Postfix) with ESMTPSA id 3E7CD20046912; Sun, 25 Jan 2015 09:51:51 -0800 (PST) Subject: Re: real IP and rfc1918 IP on the same machine - how? Mime-Version: 1.0 (Mac OS X Mail 8.1 \(1993\)) Content-Type: text/plain; charset=utf-8 From: Matthew Hardcastle In-Reply-To: <20150125165019.GA38580@potato.growveg.org> Date: Sun, 25 Jan 2015 10:51:51 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: <44F0B11B-918A-4A44-8F90-99778991ED14@doomgeek.com> References: <20150125141518.GA23664@potato.growveg.org> <20150125165019.GA38580@potato.growveg.org> To: freebsd-lists@potato.growveg.org X-Mailer: Apple Mail (2.1993) Cc: freebsd-questions@freebsd.org X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 25 Jan 2015 17:51:53 -0000 > On Jan 25, 2015, at 9:50 AM, freebsd-lists@potato.growveg.org wrote: >=20 > Ah sorry I've probably worded it wrongly.=20 >=20 > em0 =3D wired interface =3D real ip on a /28 =3D 255.255.255.240 = netmask > ath0 =3D wireless interface =3D 192.168.100.100 netmask 255.255.255.0 >=20 > Something just occurred to me. If the default route i.e. 0.0.0.0/0 -> = my=20 > real router ip then how am I going to exclude 192.168.100.0/24 ? > --=20 > John=20 You don=E2=80=99t need to do anything other than assign the IP and = subnet to your wireless interface to exclude it from the default route. = Your computer decides which interface it will send a packet out of based = on the most specific route for that packet it can find in the routing = table. For example, If you have a packet destined for 192.168.100.1 your = computer will choose your wireless interface because the packet matches = 192.168.100.0/24 more specifically that it matches 0.0.0.0/0. Double checking your routing table (by running `netstat -rn`) and your = interface configuration (by running `ifconfig` and `grep ^ifconfig = /etc/rc.conf`) will allow us to make sure you=E2=80=99re interfaces are = actually configured as your expect they are. Matt=