diff options
author | Reyk Floeter <reyk@cvs.openbsd.org> | 2016-08-06 14:29:49 +0000 |
---|---|---|
committer | Reyk Floeter <reyk@cvs.openbsd.org> | 2016-08-06 14:29:49 +0000 |
commit | 30a1274d5c2707fdf478fa5ecc23f6f9986dfddf (patch) | |
tree | 23ac4ad5677c0d7f87995a0e7a6168af7e2530d5 /sys | |
parent | 45dd434047193ad4ffdba23112428172d9bf12b9 (diff) |
Fix multicast mode (destination is a multicast IP): the BCAST and
MCAST flags have to be cleared from the mbuf after decapsulating
packets. This fixes tunneled broadcast packets, eg. ARP. It used to
work before the input path was changed the flags got cleared later in
the stack.
OK yasuoka@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/net/if_vxlan.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/sys/net/if_vxlan.c b/sys/net/if_vxlan.c index 7d7bb4aafe5..f8abf90509c 100644 --- a/sys/net/if_vxlan.c +++ b/sys/net/if_vxlan.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_vxlan.c,v 1.38 2016/04/13 11:41:15 mpi Exp $ */ +/* $OpenBSD: if_vxlan.c,v 1.39 2016/08/06 14:29:48 reyk Exp $ */ /* * Copyright (c) 2013 Reyk Floeter <reyk@openbsd.org> @@ -562,11 +562,7 @@ vxlan_lookup(struct mbuf *m, struct udphdr *uh, int iphlen, memcpy(sa, srcsa, sa->sa_len); #endif - /* Clear multicast flag from the outer packet */ - if (sc->sc_imo.imo_num_memberships > 0 && - m->m_flags & (M_MCAST) && - !ETHER_IS_MULTICAST(eh->ether_dhost)) - m->m_flags &= ~M_MCAST; + m->m_flags &= ~(M_MCAST|M_BCAST); #if NPF > 0 pf_pkt_addr_changed(m); |