From: Alexander Aring <alex.aring@gmail.com>
To: linux-bluetooth@vger.kernel.org
Cc: marcel@holtmann.org, linux-wpan@vger.kernel.org,
kernel@pengutronix.de,
Martin Townsend <martin.townsend@xsilon.com>,
Alexander Aring <alex.aring@gmail.com>
Subject: [PATCH bluetooth 3/5] ieee802154: mac802154: handle the reserved dest mode by dropping the packet
Date: Tue, 19 Aug 2014 11:03:01 +0200 [thread overview]
Message-ID: <1408438983-13892-4-git-send-email-alex.aring@gmail.com> (raw)
In-Reply-To: <1408438983-13892-1-git-send-email-alex.aring@gmail.com>
From: Martin Townsend <martin.townsend@xsilon.com>
If received frame contains the reserved destination address mode. The
frame should be dropped and free the skb.
Signed-off-by: Martin Townsend <martin.townsend@xsilon.com>
Signed-off-by: Alexander Aring <alex.aring@gmail.com>
---
net/mac802154/wpan.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/net/mac802154/wpan.c b/net/mac802154/wpan.c
index 4c13323..5478388 100644
--- a/net/mac802154/wpan.c
+++ b/net/mac802154/wpan.c
@@ -462,7 +462,10 @@ mac802154_subif_frame(struct mac802154_sub_if_data *sdata, struct sk_buff *skb,
skb->pkt_type = PACKET_OTHERHOST;
break;
default:
- break;
+ spin_unlock_bh(&sdata->mib_lock);
+ pr_debug("invalid dest mode\n");
+ kfree_skb(skb);
+ return NET_RX_DROP;
}
spin_unlock_bh(&sdata->mib_lock);
--
2.0.3
next prev parent reply other threads:[~2014-08-19 9:03 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-19 9:02 [PATCH bluetooth 0/5] mac802154: ieee802154: stable patches Alexander Aring
2014-08-19 9:02 ` [PATCH bluetooth 1/5] mac802154: fixed potential skb leak with mac802154_parse_frame_start Alexander Aring
2014-08-19 9:03 ` [PATCH bluetooth 2/5] ieee802154: 6lowpan_rtnl: fix correct errno value Alexander Aring
2014-08-19 9:03 ` Alexander Aring [this message]
2014-08-19 9:03 ` [PATCH bluetooth 4/5] ieee802154: 6lowpan: ensure of sending 1280 packets Alexander Aring
2014-08-19 9:03 ` [PATCH bluetooth 5/5] ieee802154: 6lowpan: ensure MTU of 1280 for 6lowpan Alexander Aring
2014-08-19 16:44 ` [PATCH bluetooth 0/5] mac802154: ieee802154: stable patches Marcel Holtmann
2014-08-19 16:51 ` Alexander Aring
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1408438983-13892-4-git-send-email-alex.aring@gmail.com \
--to=alex.aring@gmail.com \
--cc=kernel@pengutronix.de \
--cc=linux-bluetooth@vger.kernel.org \
--cc=linux-wpan@vger.kernel.org \
--cc=marcel@holtmann.org \
--cc=martin.townsend@xsilon.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).