diff options
author | Michael Mann <mmann78@netscape.net> | 2017-05-05 16:37:35 -0400 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2017-05-06 02:17:24 +0000 |
commit | 0e53c857e5ecc0032941b2e8a048989099fb0043 (patch) | |
tree | 869164e95688371b042529697ca0877890c52f9f | |
parent | 5d67b334e7d1ab7bf06500daed22e92ac52b379f (diff) | |
download | wireshark-0e53c857e5ecc0032941b2e8a048989099fb0043.tar.gz |
packet-ipv6.c: dissect_routing6_rpl must have IPv6 addresses.
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=1303
Bug: 13675
Change-Id: Icadf8a57a25bbf9abaa9685f9e9c7a803204b7e5
Reviewed-on: https://code.wireshark.org/review/21527
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
-rw-r--r-- | epan/dissectors/packet-ipv6.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/epan/dissectors/packet-ipv6.c b/epan/dissectors/packet-ipv6.c index 0ae0f711df..7522ce6a4c 100644 --- a/epan/dissectors/packet-ipv6.c +++ b/epan/dissectors/packet-ipv6.c @@ -943,6 +943,10 @@ dissect_routing6_rpl(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree * wmem_array_t *rpl_addr_vector = NULL; guint i; + /* Must be IPv6 addresses */ + if ((pinfo->dst.type != AT_IPv6) || (pinfo->src.type != AT_IPv6)) + return; + /* IPv6 destination address used for elided bytes */ ip6_dst_addr = (const struct e_in6_addr *)pinfo->dst.data; /* IPv6 source address used for strict checking */ |