PFCP: Fix lengths of fields in Remote GTP-U Peer

Fix the field length of "Length of Destination Interface
field" and "Length of Network Instance field" which should
be two-octet long but only one in the current codes.

Change-Id: Id303b92812bb2551ec570ec807d602d0fb44f27a
Signed-off-by: Yoshiyuki Kurauchi <ahochauwaaaaa@gmail.com>
Reviewed-on: https://code.wireshark.org/review/36908
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
This commit is contained in:
Yoshiyuki Kurauchi 2020-04-22 21:05:31 +09:00 committed by Anders Broman
parent 2a64d97d8c
commit 569deb7215
1 changed files with 6 additions and 6 deletions

View File

@ -4557,8 +4557,8 @@ dissect_pfcp_remote_gtp_u_peer(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tr
/* DI (if present)*/
if (flags & 0x4) {
/* Length of Destination Interface field */
proto_tree_add_item_ret_uint(tree, hf_pfcp_remote_gtp_u_peer_length_di, tvb, offset, 1, ENC_BIG_ENDIAN, &length_di);
offset += 1;
proto_tree_add_item_ret_uint(tree, hf_pfcp_remote_gtp_u_peer_length_di, tvb, offset, 2, ENC_BIG_ENDIAN, &length_di);
offset += 2;
/* Destination Interface */
offset += decode_pfcp_destination_interface(tvb, pinfo, tree, item, offset, length_di);
@ -4566,8 +4566,8 @@ dissect_pfcp_remote_gtp_u_peer(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tr
/* NI (if present)*/
if (flags & 0x8) {
/* Length of Network Instance field */
proto_tree_add_item_ret_uint(tree, hf_pfcp_remote_gtp_u_peer_length_ni, tvb, offset, 1, ENC_BIG_ENDIAN, &length_ni);
offset += 1;
proto_tree_add_item_ret_uint(tree, hf_pfcp_remote_gtp_u_peer_length_ni, tvb, offset, 2, ENC_BIG_ENDIAN, &length_ni);
offset += 2;
/* Network Instance */
offset += decode_pfcp_network_instance(tvb, pinfo, tree, item, offset, length_ni);
@ -10466,12 +10466,12 @@ proto_register_pfcp(void)
},
{ &hf_pfcp_remote_gtp_u_peer_length_di,
{ "Length of Destination Interface field", "pfcp.node_id_length_di",
FT_UINT8, BASE_DEC, NULL, 0,
FT_UINT16, BASE_DEC, NULL, 0,
NULL, HFILL }
},
{ &hf_pfcp_remote_gtp_u_peer_length_ni,
{ "Length of Network Instance field", "pfcp.node_id_length_ni",
FT_UINT8, BASE_DEC, NULL, 0,
FT_UINT16, BASE_DEC, NULL, 0,
NULL, HFILL }
},
{ &hf_pfcp_ur_seqn,