From owner-freebsd-net Sat Feb 8 19:20:52 2003 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 463B137B401 for ; Sat, 8 Feb 2003 19:20:51 -0800 (PST) Received: from creme-brulee.marcuscom.com (rdu57-17-158.nc.rr.com [66.57.17.158]) by mx1.FreeBSD.org (Postfix) with ESMTP id 54F3F43F85 for ; Sat, 8 Feb 2003 19:20:50 -0800 (PST) (envelope-from marcus@marcuscom.com) Received: from [192.168.1.4] (shumai.marcuscom.com [192.168.1.4]) by creme-brulee.marcuscom.com (8.12.6/8.12.6) with ESMTP id h193KeRA010286 for ; Sat, 8 Feb 2003 22:20:40 -0500 (EST) (envelope-from marcus@marcuscom.com) Subject: Programmatically obtaining interface hardware addrs From: Joe Marcus Clarke To: freebsd-net@freebsd.org Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-MqNI1HJHKJlIofxkSvl8" Organization: MarcusCom, Inc. Message-Id: <1044760845.66333.35.camel@shumai.marcuscom.com> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.2.2 Date: 08 Feb 2003 22:20:46 -0500 X-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,NOSPAM_INC,PGP_SIGNATURE_2,SPAM_PHRASE_00_01 version=2.44 Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org --=-MqNI1HJHKJlIofxkSvl8 Content-Type: text/plain Content-Transfer-Encoding: quoted-printable What's the best (or easiest) way to programmatically obtain interfaces' hardware addresses (that is, without forking ifconfig ;-))? I'm looking at how ifconfig does it, and wondering if there's an easier way. It seems Linux has a nice SIOCGIFHWADDR ioctl to do this. Thanks. Joe --=20 PGP Key : http://www.marcuscom.com/pgp.asc --=-MqNI1HJHKJlIofxkSvl8 Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.1 (FreeBSD) iD8DBQA+RckNb2iPiv4Uz4cRAt76AJ4laNmrRU7QGqyEA/EjCfupCbeKugCePZHN ai5uo5wurJpaXuzOZ4tlxWM= =Hmsj -----END PGP SIGNATURE----- --=-MqNI1HJHKJlIofxkSvl8-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message