summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/netmpls/mpls_input.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/netmpls/mpls_input.c b/sys/netmpls/mpls_input.c
index d92ceac9fc7..bf0ec69fbd5 100644
--- a/sys/netmpls/mpls_input.c
+++ b/sys/netmpls/mpls_input.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mpls_input.c,v 1.8 2008/05/06 08:01:24 norby Exp $ */
+/* $OpenBSD: mpls_input.c,v 1.9 2008/05/06 08:04:04 norby Exp $ */
/*
* Copyright (c) 2008 Claudio Jeker <claudio@openbsd.org>
@@ -80,6 +80,12 @@ mpls_input(struct mbuf *m)
return;
}
+ /* drop all broadcast and multicast packets */
+ if (m->m_flags & (M_BCAST | M_MCAST)) {
+ m_freem(m);
+ return;
+ }
+
if (m->m_len < sizeof(*shim))
if ((m = m_pullup(m, sizeof(*shim))) == NULL)
return;