From nobody@FreeBSD.org  Wed Jan 11 13:52:05 2006
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 5294116A41F
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 11 Jan 2006 13:52:05 +0000 (GMT)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [216.136.204.117])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 8906A43DA1
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 11 Jan 2006 13:51:46 +0000 (GMT)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.13.1/8.13.1) with ESMTP id k0BDpj0S094123
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 11 Jan 2006 13:51:45 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.13.1/8.13.1/Submit) id k0BDpjlv094117;
	Wed, 11 Jan 2006 13:51:45 GMT
	(envelope-from nobody)
Message-Id: <200601111351.k0BDpjlv094117@www.freebsd.org>
Date: Wed, 11 Jan 2006 13:51:45 GMT
From: Konstantin V Falkov <unlim@voce.ru>
To: freebsd-gnats-submit@FreeBSD.org
Subject: Dublicate tun IP address
X-Send-Pr-Version: www-2.3

>Number:         91665
>Category:       kern
>Synopsis:       [if_tun] Duplicate tun IP address
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Jan 11 14:00:10 GMT 2006
>Closed-Date:    Thu Jan 12 14:02:37 GMT 2006
>Last-Modified:  Thu Jan 12 14:02:37 GMT 2006
>Originator:     Konstantin V Falkov
>Release:        5.4
>Organization:
Infinity.Net
>Environment:
FreeBSD gw.tehnosoft.ru 5.4-RELEASE FreeBSD 5.4-RELEASE #2: Tue Nov  8 15:11:44
MSK 2005     root@:/usr/src/sys/i386/compile/IGATE  i386
>Description:
Ioctl allows to set up same ip addresses on tun interfaces.
ppp configured with range on ip addressess can set ip same addresses on
different tun interfaces and both will not work properly.              
>How-To-Repeat:
configure host ppp with only 1 client ip address and then make more the 1
connection...  or set up same ip on tun with ifconfig (FreeBSD 5.3 and
above will return File exists on try to set dublicate ip on different tuns)
>Fix:
              
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: glebius 
State-Changed-When: Thu Jan 12 14:02:16 UTC 2006 
State-Changed-Why:  
Actually the PPP software or RADIUS should take care about colliding 
client IP addresses. Historically PPP software didn't do this relying 
on the fact that kernel will refuse such configuration. Meanwhile 
this configuration is valid and in some cases it is useful, and thus 
since FreeBSD 5.4-RELEASE kernel doesn't refuse same IP addresses 
on different interfaces. 

To assist software that relies on the old behavior a helper sysctl 
is available - net.inet.ip.same_prefix_carp_only. To get the old 
behavior you need to add the following line to your /etc/sysctl.conf: 

net.inet.ip.same_prefix_carp_only=1 

http://www.freebsd.org/cgi/query-pr.cgi?pr=91665 
>Unformatted:
