Skip to content

Commit 6e361d6

Browse files
Martin Townsendholtmann
authored andcommitted
ieee802154: mac802154: handle the reserved dest mode by dropping the packet
If received frame contains the reserved destination address mode. The frame should be dropped and free the skb. Signed-off-by: Martin Townsend <[email protected]> Signed-off-by: Alexander Aring <[email protected]> Signed-off-by: Marcel Holtmann <[email protected]>
1 parent c4cb901 commit 6e361d6

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

net/mac802154/wpan.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -462,7 +462,10 @@ mac802154_subif_frame(struct mac802154_sub_if_data *sdata, struct sk_buff *skb,
462462
skb->pkt_type = PACKET_OTHERHOST;
463463
break;
464464
default:
465-
break;
465+
spin_unlock_bh(&sdata->mib_lock);
466+
pr_debug("invalid dest mode\n");
467+
kfree_skb(skb);
468+
return NET_RX_DROP;
466469
}
467470

468471
spin_unlock_bh(&sdata->mib_lock);

0 commit comments

Comments
 (0)