From owner-freebsd-net Wed Apr 3 18:39:12 2002 Delivered-To: freebsd-net@freebsd.org Received: from serio.al.rim.or.jp (serio.al.rim.or.jp [202.247.191.123]) by hub.freebsd.org (Postfix) with ESMTP id 27EA437B41F; Wed, 3 Apr 2002 18:38:50 -0800 (PST) Received: from mail2.rim.or.jp by serio.al.rim.or.jp (3.7W/HMX-13) id LAA16077; Thu, 4 Apr 2002 11:38:48 +0900 (JST) Received: from bougainvillea.FromTo.Cc (shell.al.rim.or.jp [202.247.191.81]) by mail2.rim.or.jp (8.9.3/3.7W) id LAA04048; Thu, 4 Apr 2002 11:38:48 +0900 (JST) Date: Thu, 04 Apr 2002 11:39:59 +0900 Message-ID: <86zo0kchkw.wl@bougainvillea.FromTo.Cc> From: Tatsumi Hosokawa To: freebsd-net@freebsd.org Cc: hosokawa@freebsd.org Subject: Re: Please review: ppp(8) and RADIUS address allocation In-Reply-To: <86zo0lqdjf.wl@bougainvillea.FromTo.Cc> References: <86zo0lqdjf.wl@bougainvillea.FromTo.Cc> User-Agent: Wanderlust/2.8.1 (Something) SEMI/1.14.3 (Ushinoya) FLIM/1.14.3 (=?ISO-8859-1?Q?Unebigory=F2mae?=) APEL/10.3 MULE XEmacs/21.1 (patch 14) (Cuyahoga Valley) (i386--freebsd) MIME-Version: 1.0 (generated by SEMI 1.14.3 - "Ushinoya") Content-Type: text/plain; charset=US-ASCII 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 At Wed, 03 Apr 2002 19:31:16 +0900, Tatsumi Hosokawa wrote: > > I'm testing to use FreeBSD box as PPPoE server and found that ppp(8) > uses 255.255.255.254 (special address to get IP address from NAS pool > defined in RADIUS protocol) as p2p address when "set radius" is used > in ppp.conf. I found the same trouble at > http://docs.freebsd.org/cgi/getmsg.cgi?fetch=299723+0+archive/2001/freebsd-net/20010812.freebsd-net Updated patch against -current. Endian problem was fixed. Index: auth.c =================================================================== RCS file: /home/ncvs/src/usr.sbin/ppp/auth.c,v retrieving revision 1.53 diff -u -r1.53 auth.c --- auth.c 8 Jan 2002 11:24:39 -0000 1.53 +++ auth.c 4 Apr 2002 01:08:13 -0000 @@ -170,7 +170,8 @@ } #ifndef NORADIUS - if (bundle->radius.valid && bundle->radius.ip.s_addr != INADDR_NONE) { + if (bundle->radius.valid && bundle->radius.ip.s_addr != INADDR_NONE && + bundle->radius.ip.s_addr != RADIUS_INADDR_POOL) { /* We've got a radius IP - it overrides everything */ if (!ipcp_UseHisIPaddr(bundle, bundle->radius.ip)) return 0; Index: radius.h =================================================================== RCS file: /home/ncvs/src/usr.sbin/ppp/radius.h,v retrieving revision 1.7 diff -u -r1.7 radius.h --- radius.h 1 Apr 2001 22:39:17 -0000 1.7 +++ radius.h 4 Apr 2002 01:08:13 -0000 @@ -76,3 +76,6 @@ #define RAD_START 1 #define RAD_STOP 2 #endif + +/* Get address from NAS pool */ +#define RADIUS_INADDR_POOL htonl(0xfffffffe) /* 255.255.255.254 */ -- Tatsumi Hosokawa http://FromTo.Cc/hosokawa/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message