Bug 208067

Summary: Wrong MAC addresses reported by ndp
Product: Base System Reporter: Serhii (Sergey) Kozlov <skozlov>
Component: binAssignee: Mark Johnston <markj>
Status: Closed FIXED    
Severity: Affects Some People CC: allanjude, bz, emaste, gnn, markj, melifaro, sbruno
Priority: ---    
Version: CURRENT   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
Log from 11-CURRENT
none
Log from 10.2-RELEASE
none
proposed fix none

Description Serhii (Sergey) Kozlov freebsd_committer freebsd_triage 2016-03-16 17:18:40 UTC
Created attachment 168302 [details]
Log from 11-CURRENT

The ndp utility report wrong MAC addresses on 11-CURRENT snapshot from 2016-03-08.

On the same machine:
10.2:
root@u0824:~ # ndp -na
Neighbor                             Linklayer Address  Netif Expire    S Flags
fe80::e2db:55ff:fefd:3045%igb0       e0:db:55:fd:30:45   igb0 permanent R

11.0:
root@u0824:~ # ndp -an
Neighbor                             Linklayer Address  Netif Expire    S Flags
fe80::e2db:55ff:fefd:3045%igb0       20:f0:66:26:00:f8   igb0 permanent R

Full logs are attached.

Isolation notes:
- Wrong MACs reported for local and remote hosts
- Tested on igb and ixl drivers
- IPv4 stack (arp utility) is not affected
- Despite the wrong MAC addresses are reported, IPv6 traffic is working OK


Sponsored by: Intel Corporation
Comment 1 Serhii (Sergey) Kozlov freebsd_committer freebsd_triage 2016-03-16 17:19:02 UTC
Created attachment 168303 [details]
Log from 10.2-RELEASE
Comment 2 Mark Johnston freebsd_committer freebsd_triage 2016-03-29 21:47:52 UTC
Created attachment 168769 [details]
proposed fix

This looks like a bug in r292978. Could anyone give the attached patch a try?
Comment 3 commit-hook freebsd_committer freebsd_triage 2016-03-30 00:04:43 UTC
A commit references this bug:

Author: markj
Date: Wed Mar 30 00:03:59 UTC 2016
New revision: 297403
URL: https://svnweb.freebsd.org/changeset/base/297403

Log:
  Fix the lladdr copy in in6_lltable_dump_entry() after r292978.

  This bug caused "ndp -a" to show the wrong link layer address for neighbour
  cache entries.

  PR:	208067

Changes:
  head/sys/netinet6/in6.c
Comment 4 Mark Johnston freebsd_committer freebsd_triage 2016-03-30 00:06:26 UTC
Thanks for the report!
Comment 5 Serhii (Sergey) Kozlov freebsd_committer freebsd_triage 2016-03-30 13:37:38 UTC
(In reply to Mark Johnston from comment #2)

Checked the patch - it does fix the problem. Thanks!
Comment 6 Allan Jude freebsd_committer freebsd_triage 2016-06-18 21:46:58 UTC
I am getting a crash that may be related to this fix

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=210379