Date: Tue, 26 Aug 1997 17:08:37 +0100 (BST) From: Aled Morris <aledm@routers.co.uk> To: "Louis A. Mamakos" <louie@TransSys.COM> Cc: hackers@FreeBSD.ORG Subject: Re: UDP "to" address? Message-ID: <Pine.BSF.3.91.970826170445.21490H-100000@ns.uk.peer.net> In-Reply-To: <199708261352.JAA04942@whizzo.TransSys.COM>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 26 Aug 1997, Louis A. Mamakos wrote: > Typically, a portable approach to doing this is to create a socket > per interface address and bind it. Then you look at which fd the > packet was received on to determine the destination address. That sounds like the best way - unfortunately, I'm currently using inetd, so I'll have to do a bit more work... > There also seems to be a socket option you can set which returns the > destination address in the "control information" field specified > with recvmsg(2). I noticed the code for this in ip_input.c. I've just had a look, INP_RECVDSTADDR looks like the one. I don't know how to set it, or how to recover the data, but I'm sure someone will have a nifty code fragment (please?) Aled -- tel +44 973 207987 O- aledm@routers.co.uk
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.91.970826170445.21490H-100000>