From nobody@FreeBSD.org  Thu Dec 18 09:48:53 2008
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 2CE9D1065676
	for <freebsd-gnats-submit@FreeBSD.org>; Thu, 18 Dec 2008 09:48:53 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21])
	by mx1.freebsd.org (Postfix) with ESMTP id 218D18FC14
	for <freebsd-gnats-submit@FreeBSD.org>; Thu, 18 Dec 2008 09:48:53 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.3/8.14.3) with ESMTP id mBI9mqUO054328
	for <freebsd-gnats-submit@FreeBSD.org>; Thu, 18 Dec 2008 09:48:52 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.3/8.14.3/Submit) id mBI9mqTC054327;
	Thu, 18 Dec 2008 09:48:52 GMT
	(envelope-from nobody)
Message-Id: <200812180948.mBI9mqTC054327@www.freebsd.org>
Date: Thu, 18 Dec 2008 09:48:52 GMT
From: KOIE Hidetaka <koie@suri.co.jp>
To: freebsd-gnats-submit@FreeBSD.org
Subject: respond with wrong ARP.
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         129730
>Category:       kern
>Synopsis:       [arp]: respond with wrong ARP.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    qingli
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Dec 18 09:50:01 UTC 2008
>Closed-Date:    Fri Dec 04 18:23:16 UTC 2009
>Last-Modified:  Fri Dec 04 18:23:16 UTC 2009
>Originator:     KOIE Hidetaka
>Release:        current
>Organization:
SURIGIKEN
>Environment:
FreeBSD guriandgura 8.0-CURRENT FreeBSD 8.0-CURRENT #1: Thu Dec 18 17:53:41 JST 2008     koie@guriandgura:/usr/obj/usr/src/sys/GURIANDGURA  amd64
>Description:
I built FreeBSD-current at 2008-12-18, and boot it.

Some machine in my network cannot connect a DNS server...
The finding is my FreeBSD machine responds to ARP request for a 3rd machine with a wrong ARP response like this:

6:50:26.320648 00:1b:78:9a:47:db > Broadcast, ethertype ARP (0x0806), length 42: arp who-has 10.1.100.1 tell 10.1.6.59
16:50:26.320784 00:e0:81:74:ef:e4 > 00:1b:78:9a:47:db, ethertype ARP (0x0806), length 60: arp reply 10.1.100.1 is-at 00:1b:78:9a:47:db
16:50:26.320851 00:30:48:99:64:8c > 00:1b:78:9a:47:db, ethertype ARP (0x0806), length 60: arp reply 10.1.100.1 is-at 00:30:48:99:64:8c
# 00:1b:78:9a:47:db is a requester (10.1.6.59).
# 00:e0:81:74:ef:e4 is my machine (10.1.3.67).
# 00:30:48:99:64:8c is a real responder (10.1.100.1).

line 1 is ARP request.
line 2 is ARP response by my machine with wrong.
line 3 is ARP correct response.

note: bridging and proxyall are not specified on my machine.

>How-To-Repeat:

>Fix:
I don't know. (but, a bug may be in r186119).

Now, to suppress the wrong behavior, 
Index: if_ether.c
===================================================================
RCS file: /.../.../src/sys/netinet/if_ether.c,v
retrieving revision 1.187
diff -u -p -r1.187 if_ether.c
--- if_ether.c  17 Dec 2008 00:14:28 -0000      1.187
+++ if_ether.c  18 Dec 2008 08:52:44 -0000
@@ -660,6 +660,7 @@ reply:
                (void)memcpy(ar_tha(ah), ar_sha(ah), ah->ar_hln);
                (void)memcpy(ar_sha(ah), enaddr, ah->ar_hln);
        } else {
+goto drop; /*KOIE*/
                if (la == NULL) {
                        if (!V_arp_proxyall)
                                goto drop;


>Release-Note:
>Audit-Trail:

From: "Remko Lodder" <remko@elvandar.org>
To: "KOIE Hidetaka" <koie@suri.co.jp>
Cc: freebsd-gnats-submit@freebsd.org,
 qingli@FreeBSD.org
Subject: Re: kern/129730: respond with wrong ARP.
Date: Thu, 18 Dec 2008 13:56:04 +0100 (CET)

 > I built FreeBSD-current at 2008-12-18, and boot it.
 >
 > Some machine in my network cannot connect a DNS server...
 > The finding is my FreeBSD machine responds to ARP request for a 3rd
 > machine with a wrong ARP response like this:
 >
 > 6:50:26.320648 00:1b:78:9a:47:db > Broadcast, ethertype ARP (0x0806),
 > length 42: arp who-has 10.1.100.1 tell 10.1.6.59
 > 16:50:26.320784 00:e0:81:74:ef:e4 > 00:1b:78:9a:47:db, ethertype ARP
 > (0x0806), length 60: arp reply 10.1.100.1 is-at 00:1b:78:9a:47:db
 > 16:50:26.320851 00:30:48:99:64:8c > 00:1b:78:9a:47:db, ethertype ARP
 > (0x0806), length 60: arp reply 10.1.100.1 is-at 00:30:48:99:64:8c
 > # 00:1b:78:9a:47:db is a requester (10.1.6.59).
 > # 00:e0:81:74:ef:e4 is my machine (10.1.3.67).
 > # 00:30:48:99:64:8c is a real responder (10.1.100.1).
 >
 > line 1 is ARP request.
 > line 2 is ARP response by my machine with wrong.
 > line 3 is ARP correct response.
 >
 > note: bridging and proxyall are not specified on my machine.
 >
 >>How-To-Repeat:
 >
 >>Fix:
 > I don't know. (but, a bug may be in r186119).
 >
 > Now, to suppress the wrong behavior,
 > Index: if_ether.c
 > ===================================================================
 > RCS file: /.../.../src/sys/netinet/if_ether.c,v
 > retrieving revision 1.187
 > diff -u -p -r1.187 if_ether.c
 > --- if_ether.c  17 Dec 2008 00:14:28 -0000      1.187
 > +++ if_ether.c  18 Dec 2008 08:52:44 -0000
 > @@ -660,6 +660,7 @@ reply:
 >                 (void)memcpy(ar_tha(ah), ar_sha(ah), ah->ar_hln);
 >                 (void)memcpy(ar_sha(ah), enaddr, ah->ar_hln);
 >         } else {
 > +goto drop; /*KOIE*/
 >                 if (la == NULL) {
 >                         if (!V_arp_proxyall)
 >                                 goto drop;
 >
 
 Hello,
 
 I seem to be hitting the same behaviour, I did a roll back last night, and
 need to finish testing with this. I'll reply-all when I have more
 information about this.
 
 Cheers,
 remko
 
 
 -- 
 /"\   Best regards,                      | remko@FreeBSD.org
 \ /   Remko Lodder                       | remko@EFnet
  X    http://www.evilcoder.org/          |
 / \   ASCII Ribbon Campaign              | Against HTML Mail and News
 
 
Responsible-Changed-From-To: freebsd-bugs->qingli 
Responsible-Changed-By: remko 
Responsible-Changed-When: Thu Dec 18 13:03:18 UTC 2008 
Responsible-Changed-Why:  
reassign to Qing, I see the same behaviour on my local network after 
updating to the latest -current after your changes. If I can test 
anything for you please let me know! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=129730 

From: Remko Lodder <remko@elvandar.org>
To: KOIE Hidetaka <koie@suri.co.jp>
Cc: freebsd-gnats-submit@FreeBSD.org,
 qingli@FreeBSD.org
Subject: Re: kern/129730: respond with wrong ARP.
Date: Thu, 18 Dec 2008 21:02:00 +0100

 On Dec 18, 2008, at 10:48 AM, KOIE Hidetaka wrote:
 
 >
 >> Number:         129730
 >> Category:       kern
 >> Synopsis:       respond with wrong ARP.
 >> Confidential:   no
 >> Severity:       non-critical
 >> Priority:       low
 >> Responsible:    freebsd-bugs
 >> State:          open
 >> Quarter:
 >> Keywords:
 >> Date-Required:
 >> Class:          sw-bug
 >> Submitter-Id:   current-users
 >> Arrival-Date:   Thu Dec 18 09:50:01 UTC 2008
 >> Closed-Date:
 >> Last-Modified:
 >> Originator:     KOIE Hidetaka
 >> Release:        current
 >> Organization:
 > SURIGIKEN
 >> Environment:
 > FreeBSD guriandgura 8.0-CURRENT FreeBSD 8.0-CURRENT #1: Thu Dec 18  
 > 17:53:41 JST 2008     koie@guriandgura:/usr/obj/usr/src/sys/ 
 > GURIANDGURA  amd64
 >> Description:
 > I built FreeBSD-current at 2008-12-18, and boot it.
 >
 > Some machine in my network cannot connect a DNS server...
 > The finding is my FreeBSD machine responds to ARP request for a 3rd  
 > machine with a wrong ARP response like this:
 >
 > 6:50:26.320648 00:1b:78:9a:47:db > Broadcast, ethertype ARP  
 > (0x0806), length 42: arp who-has 10.1.100.1 tell 10.1.6.59
 > 16:50:26.320784 00:e0:81:74:ef:e4 > 00:1b:78:9a:47:db, ethertype ARP  
 > (0x0806), length 60: arp reply 10.1.100.1 is-at 00:1b:78:9a:47:db
 > 16:50:26.320851 00:30:48:99:64:8c > 00:1b:78:9a:47:db, ethertype ARP  
 > (0x0806), length 60: arp reply 10.1.100.1 is-at 00:30:48:99:64:8c
 > # 00:1b:78:9a:47:db is a requester (10.1.6.59).
 > # 00:e0:81:74:ef:e4 is my machine (10.1.3.67).
 > # 00:30:48:99:64:8c is a real responder (10.1.100.1).
 >
 > line 1 is ARP request.
 > line 2 is ARP response by my machine with wrong.
 > line 3 is ARP correct response.
 >
 > note: bridging and proxyall are not specified on my machine.
 >
 >>
 
 I can confirm that rolling back to a version of FreeBSD which predates  
 the ARP-v2 changes, resolved the problem. My clients keep working,  
 where they stopped working within 15 minutes with the new arp code.
 
 Qing: Any ideas that I can try to help resolve this?
 
 Thanks!
 
 >>
 
 /"\   Best regards,                        | remko@FreeBSD.org
 \ /   Remko Lodder                      | remko@EFnet
 X    http://www.evilcoder.org/    |
 / \   ASCII Ribbon Campaign    | Against HTML Mail and News
 

From: "Qing Li" <qingli@speakeasy.net>
To: "'Remko Lodder'" <remko@elvandar.org>,
	"'KOIE Hidetaka'" <koie@suri.co.jp>
Cc: <qingli@FreeBSD.org>,
	<freebsd-gnats-submit@FreeBSD.org>
Subject: RE: kern/129730: respond with wrong ARP.
Date: Fri, 19 Dec 2008 03:11:34 -0800

 I have committed a fix for this bug.
 
 Author: qingli
 Date: Fri Dec 19 11:07:34 2008
 New Revision: 186317
 URL: http://svn.freebsd.org/changeset/base/186317
 
 -- Qing
  
 
 -----Original Message-----
 From: Remko Lodder [mailto:remko@elvandar.org]
 Sent: Thursday, December 18, 2008 12:02 PM
 To: KOIE Hidetaka
 Cc: freebsd-gnats-submit@FreeBSD.org; qingli@FreeBSD.org
 Subject: Re: kern/129730: respond with wrong ARP.
 
 
 On Dec 18, 2008, at 10:48 AM, KOIE Hidetaka wrote:
 
 >
 >> Number:         129730
 >> Category:       kern
 >> Synopsis:       respond with wrong ARP.
 >> Confidential:   no
 >> Severity:       non-critical
 >> Priority:       low
 >> Responsible:    freebsd-bugs
 >> State:          open
 >> Quarter:
 >> Keywords:
 >> Date-Required:
 >> Class:          sw-bug
 >> Submitter-Id:   current-users
 >> Arrival-Date:   Thu Dec 18 09:50:01 UTC 2008
 >> Closed-Date:
 >> Last-Modified:
 >> Originator:     KOIE Hidetaka
 >> Release:        current
 >> Organization:
 > SURIGIKEN
 >> Environment:
 > FreeBSD guriandgura 8.0-CURRENT FreeBSD 8.0-CURRENT #1: Thu Dec 18  
 > 17:53:41 JST 2008     koie@guriandgura:/usr/obj/usr/src/sys/ 
 > GURIANDGURA  amd64
 >> Description:
 > I built FreeBSD-current at 2008-12-18, and boot it.
 >
 > Some machine in my network cannot connect a DNS server...
 > The finding is my FreeBSD machine responds to ARP request for a 3rd 
 > machine with a wrong ARP response like this:
 >
 > 6:50:26.320648 00:1b:78:9a:47:db > Broadcast, ethertype ARP (0x0806), 
 > length 42: arp who-has 10.1.100.1 tell 10.1.6.59
 > 16:50:26.320784 00:e0:81:74:ef:e4 > 00:1b:78:9a:47:db, ethertype ARP 
 > (0x0806), length 60: arp reply 10.1.100.1 is-at 00:1b:78:9a:47:db
 > 16:50:26.320851 00:30:48:99:64:8c > 00:1b:78:9a:47:db, ethertype ARP 
 > (0x0806), length 60: arp reply 10.1.100.1 is-at 00:30:48:99:64:8c # 
 > 00:1b:78:9a:47:db is a requester (10.1.6.59).
 > # 00:e0:81:74:ef:e4 is my machine (10.1.3.67).
 > # 00:30:48:99:64:8c is a real responder (10.1.100.1).
 >
 > line 1 is ARP request.
 > line 2 is ARP response by my machine with wrong.
 > line 3 is ARP correct response.
 >
 > note: bridging and proxyall are not specified on my machine.
 >
 >>
 
 I can confirm that rolling back to a version of FreeBSD which predates the
 ARP-v2 changes, resolved the problem. My clients keep working, where they
 stopped working within 15 minutes with the new arp code.
 
 Qing: Any ideas that I can try to help resolve this?
 
 Thanks!
 
 >>
 
 /"\   Best regards,                        | remko@FreeBSD.org
 \ /   Remko Lodder                      | remko@EFnet
 X    http://www.evilcoder.org/    |
 / \   ASCII Ribbon Campaign    | Against HTML Mail and News
 
 
 
 
 
 
 

From: KOIE Hidetaka (=?iso-2022-jp?B?GyRCOHE5PjFRTjQhdz90TX01OzgmGyhC?=)
 <koie@suri.co.jp>
To: qingli@speakeasy.net
Cc: remko@elvandar.org, qingli@FreeBSD.org, freebsd-gnats-submit@FreeBSD.org
Subject: Re: kern/129730: respond with wrong ARP.
Date: Sat, 20 Dec 2008 15:25:40 +0900 (JST)

 The new code works well.
 Thank you.
 
   Message-Id: <20081219111134.78BA958D2A1@jmx1.suri.co.jp>
   Date:       Fri, 19 Dec 2008 03:11:34 -0800
   From:       "Qing Li" <qingli@speakeasy.net>
   Subject:    RE: kern/129730: respond with wrong ARP.
 
   | 
   | I have committed a fix for this bug.
   | 
   | Author: qingli
   | Date: Fri Dec 19 11:07:34 2008
   | New Revision: 186317
   | URL: http://svn.freebsd.org/changeset/base/186317
   | 
   | -- Qing
   |  
   | 
   | -----Original Message-----
   | From: Remko Lodder [mailto:remko@elvandar.org]
   | Sent: Thursday, December 18, 2008 12:02 PM
   | To: KOIE Hidetaka
   | Cc: freebsd-gnats-submit@FreeBSD.org; qingli@FreeBSD.org
   | Subject: Re: kern/129730: respond with wrong ARP.
   | 
   | 
   | On Dec 18, 2008, at 10:48 AM, KOIE Hidetaka wrote:
   | 
   | >
   | >> Number:         129730
   | >> Category:       kern
   | >> Synopsis:       respond with wrong ARP.
   | >> Confidential:   no
   | >> Severity:       non-critical
   | >> Priority:       low
   | >> Responsible:    freebsd-bugs
   | >> State:          open
   | >> Quarter:
   | >> Keywords:
   | >> Date-Required:
   | >> Class:          sw-bug
   | >> Submitter-Id:   current-users
   | >> Arrival-Date:   Thu Dec 18 09:50:01 UTC 2008
   | >> Closed-Date:
   | >> Last-Modified:
   | >> Originator:     KOIE Hidetaka
   | >> Release:        current
   | >> Organization:
   | > SURIGIKEN
   | >> Environment:
   | > FreeBSD guriandgura 8.0-CURRENT FreeBSD 8.0-CURRENT #1: Thu Dec 18  
   | > 17:53:41 JST 2008     koie@guriandgura:/usr/obj/usr/src/sys/ 
   | > GURIANDGURA  amd64
   | >> Description:
   | > I built FreeBSD-current at 2008-12-18, and boot it.
   | >
   | > Some machine in my network cannot connect a DNS server...
   | > The finding is my FreeBSD machine responds to ARP request for a 3rd 
   | > machine with a wrong ARP response like this:
   | >
   | > 6:50:26.320648 00:1b:78:9a:47:db > Broadcast, ethertype ARP (0x0806), 
   | > length 42: arp who-has 10.1.100.1 tell 10.1.6.59
   | > 16:50:26.320784 00:e0:81:74:ef:e4 > 00:1b:78:9a:47:db, ethertype ARP 
   | > (0x0806), length 60: arp reply 10.1.100.1 is-at 00:1b:78:9a:47:db
   | > 16:50:26.320851 00:30:48:99:64:8c > 00:1b:78:9a:47:db, ethertype ARP 
   | > (0x0806), length 60: arp reply 10.1.100.1 is-at 00:30:48:99:64:8c # 
   | > 00:1b:78:9a:47:db is a requester (10.1.6.59).
   | > # 00:e0:81:74:ef:e4 is my machine (10.1.3.67).
   | > # 00:30:48:99:64:8c is a real responder (10.1.100.1).
   | >
   | > line 1 is ARP request.
   | > line 2 is ARP response by my machine with wrong.
   | > line 3 is ARP correct response.
   | >
   | > note: bridging and proxyall are not specified on my machine.
   | >
   | >>
   | 
   | I can confirm that rolling back to a version of FreeBSD which predates the
   | ARP-v2 changes, resolved the problem. My clients keep working, where they
   | stopped working within 15 minutes with the new arp code.
   | 
   | Qing: Any ideas that I can try to help resolve this?
   | 
   | Thanks!
   | 
   | >>
   | 
   | /"\   Best regards,                        | remko@FreeBSD.org
   | \ /   Remko Lodder                      | remko@EFnet
   | X    http://www.evilcoder.org/    |
   | / \   ASCII Ribbon Campaign    | Against HTML Mail and News
 
 --
 KOIE Hidetaka / koie@suri.co.jp / SURIGIKEN Co.,LTD.
State-Changed-From-To: open->closed 
State-Changed-By: qingli 
State-Changed-When: Fri Dec 4 18:21:19 UTC 2009 
State-Changed-Why:  
The fix for this bug was committed on Dec. 19th and had been verified by the submitter. 


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