Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 24 Dec 2004 18:52:24 GMT
From:      Jon Simola <jsimola@gmail.com>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   misc/75471: Inconsistent MAC formatting by /usr/sbin/arp on vlan pseudo interfaces
Message-ID:  <200412241852.iBOIqO2I002606@www.freebsd.org>
Resent-Message-ID: <200412241900.iBOJ0iEb066164@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         75471
>Category:       misc
>Synopsis:       Inconsistent MAC formatting by /usr/sbin/arp on vlan pseudo interfaces
>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:   Fri Dec 24 19:00:44 GMT 2004
>Closed-Date:
>Last-Modified:
>Originator:     Jon Simola
>Release:        5.3-STABLE
>Organization:
>Environment:
FreeBSD tycho.abccomm.com 5.3-STABLE FreeBSD 5.3-STABLE #1: Wed Dec 22 17:11:02 PST 2004     jon@tycho.abccomm.com:/usr/obj/usr/src/sys/CARP  i386
>Description:
Sample output from my Vlan router
#/usr/sbin/arp -an
? (204.239.167.99) at 00:90:27:76:a9:9c on em0 [ethernet]
? (204.239.167.248) at 00:30:48:72:36:24 on em0 [ethernet]
<...>
? (208.181.67.228) at 0.30.ab.4.43.4 on vlan100 [vlan]
? (208.181.68.97) at 0.1.2.3.4.5 on vlan100 [vlan]

I expected zero-filled and colon seperated MACs, the non filled and dot seperated MACs on the vlan interfaces are suprising.
>How-To-Repeat:
/usr/sbin/arp on any vlan pseudointerface.
>Fix:
--- usr.sbin/arp/arp.c.orig     Fri Dec 24 11:45:11 2004
+++ usr.sbin/arp/arp.c  Fri Dec 24 11:53:04 2004
@@ -523,7 +523,7 @@
        }
        printf("%s (%s) at ", host, inet_ntoa(addr-&gt;sin_addr));
        if (sdl-&gt;sdl_alen) {
-               if (sdl-&gt;sdl_type == IFT_ETHER &&
+               if ((sdl-&gt;sdl_type == IFT_ETHER || sdl->sdl_type == IFT_L2VLAN) &&
                    sdl-&gt;sdl_alen == ETHER_ADDR_LEN)
                        printf("%s", ether_ntoa((struct ether_addr *)LLADDR(sdl)));
                else {

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200412241852.iBOIqO2I002606>