From owner-freebsd-net@FreeBSD.ORG Tue Jun 8 07:02:55 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 D1E8116A4CE; Tue, 8 Jun 2004 07:02:55 +0000 (GMT) Received: from tigra.ip.net.ua (tigra.ip.net.ua [82.193.96.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1CB7243D49; Tue, 8 Jun 2004 07:02:55 +0000 (GMT) (envelope-from ru@ip.net.ua) Received: from heffalump.ip.net.ua (heffalump.ip.net.ua [82.193.96.213]) by tigra.ip.net.ua (8.12.11/8.12.11) with ESMTP id i5878Clc032285 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 8 Jun 2004 10:08:13 +0300 (EEST) (envelope-from ru@ip.net.ua) Received: (from ru@localhost) by heffalump.ip.net.ua (8.12.11/8.12.11) id i5872afE057074; Tue, 8 Jun 2004 10:02:36 +0300 (EEST) (envelope-from ru) Date: Tue, 8 Jun 2004 10:02:36 +0300 From: Ruslan Ermilov To: Gleb Smirnoff Message-ID: <20040608070236.GA57053@ip.net.ua> References: <20040607071701.GC17986@cell.sick.ru> <20040607074037.GB18232@cell.sick.ru> <20040608065235.GA56799@ip.net.ua> <20040608065831.GC26822@cell.sick.ru> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="zhXaljGHf11kAtnf" Content-Disposition: inline In-Reply-To: <20040608065831.GC26822@cell.sick.ru> User-Agent: Mutt/1.5.6i X-Virus-Scanned: by amavisd-new X-Spam-Checker-Version: SpamAssassin 2.55 (1.174.2.19-2003-05-19-exp) cc: net@FreeBSD.org cc: Julian Elischer cc: FreeBSD current users Subject: Re: HEADSUP! netgraph Metadata changing. 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: Tue, 08 Jun 2004 07:02:56 -0000 --zhXaljGHf11kAtnf Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jun 08, 2004 at 10:58:31AM +0400, Gleb Smirnoff wrote: > On Tue, Jun 08, 2004 at 09:52:35AM +0300, Ruslan Ermilov wrote: > R> > J> > J> In addition the ng_ksocket node adds info into metadata and = I suspect > R> > J> > J> there are people using that. > R> > J> >=20 > R> > J> > Since ng_ksocket tags packets for itself only, we can safely ch= ange it. > R> > J>=20 > R> > J> Since I did not add that code I am not very familiar with it or w= ho uses > R> > J> it. (or why) > R> > J>=20 > R> > J> if this is true than yes we can do this.. > R> >=20 > R> > It is used only on UDP connection, to send replies back to where the= original > R> > packets came from. > R> >=20 > R> I wouldn't hardcode it this way. Rather, it just mimics the > R> sendto()/recvfrom() semantics, to represent the "to"/"from" > R> arguments, respectively. >=20 > Pardon, haven't understand what do you suggest. You mean, that it'll be b= etter > if node originating packets will insert this tag? >=20 It's not just used "to send replies back". In our proprietary module, we expect the connected node to be of a type "inet/dgram/udp ksocket", and insert tags appropriately to send datagrams to a correct router. We also read tags to verify that the datagrams are coming from the correct router. And it just mimics the sendto()/recvfrom() behavior. Cheers, --=20 Ruslan Ermilov ru@FreeBSD.org FreeBSD committer --zhXaljGHf11kAtnf Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFAxWSMqRfpzJluFF4RAkekAJ97yi0KbkzFeTJmD7l5mmvUXq7CNgCglEMW +096yFXJsnZxagmcpOv32qo= =85Md -----END PGP SIGNATURE----- --zhXaljGHf11kAtnf--