Possible wrong MAC address with bridge(4)

Michal Mertl mime at traveller.cz
Sat Aug 13 11:09:54 GMT 2005

I played a little with bridge(4) and found out that when I want to
communicate with the IP address on one of the member interfaces of a
bridge the system behaves a little strange.

This is the configuration of the bridge machine:
> ifconfig
        inet netmask 0xffffff00 broadcast
        ether 00:0e:0c:68:71:6a
        media: Ethernet autoselect (100baseTX)
        status: active
        inet netmask 0xffffff00 broadcast
        ether 00:0b:6b:35:dc:d4
        media: IEEE 802.11 Wireless Ethernet autoselect mode 11b
        status: associated
        ssid mig_ap_xx channel 1 bssid 00:0b:6b:35:dc:d4
        authmode OPEN privacy OFF txpowmax 16 protmode CTS dtimperiod 1
        bintval 100

net.link.ether.bridge.enable: 1
net.link.ether.bridge.config: fxp0,ath0

When I ping from behind the fxp0 interface the ip address of the ath0
interface, the ARP returns the MAC address of the ath0 interface but the
packets have source MAC address of the fxp0 interface (see tcpdump
snippet at the end of this message). Is it correct?

The system doesn't check if the source MAC address of incoming packets
matches expected (as learned by ARP) so the communication works.

genius1# tcpdump -vvlnepi em0
tcpdump: listening on em0, link-type EN10MB (Ethernet), capture size 68
12:55:02.173340 00:0d:60:cd:ae:e2 > ff:ff:ff:ff:ff:ff, ethertype ARP
(0x0806), length 42: arp who-has tell
12:55:02.173588 00:0e:0c:68:71:6a > 00:0d:60:cd:ae:e2, ethertype ARP
(0x0806), length 60: arp reply is-at 00:0e:0c:68:71:6a
12:55:02.173765 00:0d:60:cd:ae:e2 > 00:0e:0c:68:71:6a, ethertype IPv4
(0x0800), length 98: (tos 0x0, ttl  64, id 58301, offset 0, flags
[none], proto: ICMP (1), length: 84) > ICMP
echo request, id 563, seq 0, length 64
12:55:02.173920 00:0b:6b:35:dc:d4 > 00:0d:60:cd:ae:e2, ethertype IPv4
(0x0800), length 98: (tos 0x0, ttl  64, id 310, offset 0, flags [none],
proto: ICMP (1), length: 84) > ICMP echo reply,
id 563, seq 0, length 64


More information about the freebsd-current mailing list