forked from osmocom/wireshark
802.15.4 fixed processing of PAN ID compression bit
This the result of updated 'PAN ID Compression field value for frame version 0b10' table in IEEE spec which clarifies the interpretaion of the PAN ID Compression bits for different combinations of Src and Dst Addresses. Change-Id: Ia70836b8571beae80a3f507be4f39736e13eb110 Reviewed-on: https://code.wireshark.org/review/13984 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
This commit is contained in:
parent
50a9165831
commit
6d6f49d294
|
@ -876,10 +876,21 @@ dissect_ieee802154_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, g
|
|||
}
|
||||
}
|
||||
else { /* Frame Version 0b10 */
|
||||
if (packet->pan_id_compression == 0) {
|
||||
srcPanPresent = TRUE;
|
||||
if ((packet->src_addr_mode == IEEE802154_FCF_ADDR_EXT) &&
|
||||
(packet->dst_addr_mode == IEEE802154_FCF_ADDR_EXT)) {
|
||||
if (packet->pan_id_compression == 0) {
|
||||
dstPanPresent = TRUE;
|
||||
}
|
||||
}
|
||||
else {
|
||||
if (packet->pan_id_compression == 1) {
|
||||
dstPanPresent = TRUE;
|
||||
}
|
||||
else {
|
||||
dstPanPresent = TRUE;
|
||||
srcPanPresent = TRUE;
|
||||
}
|
||||
}
|
||||
/* else neither present */
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -916,10 +927,21 @@ dissect_ieee802154_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, g
|
|||
}
|
||||
}
|
||||
else { /* Frame Version 0b10 */
|
||||
if (packet->pan_id_compression == 0) {
|
||||
dstPanPresent = TRUE;
|
||||
if ((packet->src_addr_mode == IEEE802154_FCF_ADDR_EXT) &&
|
||||
(packet->dst_addr_mode == IEEE802154_FCF_ADDR_EXT)) {
|
||||
if (packet->pan_id_compression == 0) {
|
||||
dstPanPresent = TRUE;
|
||||
}
|
||||
}
|
||||
else {
|
||||
if (packet->pan_id_compression == 1) {
|
||||
dstPanPresent = TRUE;
|
||||
}
|
||||
else {
|
||||
dstPanPresent = TRUE;
|
||||
srcPanPresent = TRUE;
|
||||
}
|
||||
}
|
||||
/* else neither PAN Ids */
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue