From owner-freebsd-net@FreeBSD.ORG Mon May 10 12:03:02 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 F084716A4CE for ; Mon, 10 May 2004 12:03:02 -0700 (PDT) Received: from smtp01.uc3m.es (smtp01.uc3m.es [163.117.136.121]) by mx1.FreeBSD.org (Postfix) with ESMTP id 73ECD43D5A for ; Mon, 10 May 2004 12:03:02 -0700 (PDT) (envelope-from jrh@it.uc3m.es) Received: from smtp01.uc3m.es (localhost [127.0.0.1]) by localhost.uc3m.es (Postfix) with ESMTP id 141D4383E6 for ; Mon, 10 May 2004 21:03:01 +0200 (CEST) Received: from [163.117.139.95] (cimborrio.it.uc3m.es [163.117.139.95]) by smtp01.uc3m.es (Postfix) with ESMTP id 0018237FC5 for ; Mon, 10 May 2004 21:03:00 +0200 (CEST) From: Juan Rodriguez Hervella Organization: UC3M To: freebsd-net@freebsd.org Date: Mon, 10 May 2004 21:02:51 +0200 User-Agent: KMail/1.6 MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Message-Id: <200405102102.51399.jrh@it.uc3m.es> Subject: How to use the RTM_IFINFO message of a Routing Socket 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: Mon, 10 May 2004 19:03:03 -0000 Hello, I dont understand, looking at "man 4 route", how to use the RTM_IFINFO message of a Routing Socket. I mean, do I have to make a "write" on the socket with a "struct if_msghdr" of type = RTM_IFINFO and later on a "read" with the same data structure ? Or can I just open the PF_ROUTE socket and then make a "read" with a "struct if_msghdr" data structure, w/out doing a "write" ? I'm really lost, and I haven't found documentation about this topic, so please if somebody can give me an example or pointing me to somewhere to learn to use this, I'd be delighted. Looking at "usr/src/bin/route.c" is simple another big mess for me. I'm looking forward to your answers, net-people ! -- ****** JFRH ******