diff options
author | Pascal Quantin <pascal@wireshark.org> | 2020-06-24 12:47:07 +0200 |
---|---|---|
committer | Anders Broman <a.broman58@gmail.com> | 2020-06-24 11:51:04 +0000 |
commit | a2afe9b255df28466f17624ad8e1df656d3e7ecd (patch) | |
tree | be7a9ef7fa917f766438f713b865324ed13ab63a | |
parent | 006a7f51154f50172c9bcf3e1e8a0735ecbe8ec9 (diff) |
NGAP: fix dissection of PWS messages exchanged in Namf interface
Change-Id: I1d810a0f7de6333938a88bd7616367a687d77e30
Reviewed-on: https://code.wireshark.org/review/37554
Petri-Dish: Pascal Quantin <pascal@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
-rw-r--r-- | epan/dissectors/asn1/ngap/packet-ngap-template.c | 8 | ||||
-rw-r--r-- | epan/dissectors/packet-ngap.c | 14 |
2 files changed, 5 insertions, 17 deletions
diff --git a/epan/dissectors/asn1/ngap/packet-ngap-template.c b/epan/dissectors/asn1/ngap/packet-ngap-template.c index e213d6ffbd..6b20594409 100644 --- a/epan/dissectors/asn1/ngap/packet-ngap-template.c +++ b/epan/dissectors/asn1/ngap/packet-ngap-template.c @@ -516,19 +516,13 @@ dissect_ngap_media_type(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, voi } else if (!strcmp(n2_info_class, "PWS") || !strcmp(n2_info_class, "PWS-BCAL") || !strcmp(n2_info_class, "PWS-RF")) { - gdouble msg_type; cur_tok = json_get_object(json_data, cur_tok, "pwsInfo"); if (!cur_tok) return 0; n2_info_content_tok = json_get_object(json_data, cur_tok, "pwsContainer"); if (!n2_info_content_tok) return 0; - if (!json_get_double(json_data, n2_info_content_tok, "ngapMessageType", &msg_type)) - return 0; - if (!strcmp(n2_info_class, "PWS-BCAL")) - subdissector = dissector_get_uint_handle(ngap_proc_sout_dissector_table, (guint32)msg_type); - else - subdissector = dissector_get_uint_handle(ngap_proc_imsg_dissector_table, (guint32)msg_type); + subdissector = ngap_handle; } else { return 0; } diff --git a/epan/dissectors/packet-ngap.c b/epan/dissectors/packet-ngap.c index 94d9bbf79c..a0edc1a685 100644 --- a/epan/dissectors/packet-ngap.c +++ b/epan/dissectors/packet-ngap.c @@ -14678,19 +14678,13 @@ dissect_ngap_media_type(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, voi } else if (!strcmp(n2_info_class, "PWS") || !strcmp(n2_info_class, "PWS-BCAL") || !strcmp(n2_info_class, "PWS-RF")) { - gdouble msg_type; cur_tok = json_get_object(json_data, cur_tok, "pwsInfo"); if (!cur_tok) return 0; n2_info_content_tok = json_get_object(json_data, cur_tok, "pwsContainer"); if (!n2_info_content_tok) return 0; - if (!json_get_double(json_data, n2_info_content_tok, "ngapMessageType", &msg_type)) - return 0; - if (!strcmp(n2_info_class, "PWS-BCAL")) - subdissector = dissector_get_uint_handle(ngap_proc_sout_dissector_table, (guint32)msg_type); - else - subdissector = dissector_get_uint_handle(ngap_proc_imsg_dissector_table, (guint32)msg_type); + subdissector = ngap_handle; } else { return 0; } @@ -15026,7 +15020,7 @@ proto_reg_handoff_ngap(void) /*--- End of included file: packet-ngap-dis-tab.c ---*/ -#line 584 "./asn1/ngap/packet-ngap-template.c" +#line 578 "./asn1/ngap/packet-ngap-template.c" dissector_add_string("media_type", "application/vnd.3gpp.ngap", ngap_media_type_handle); } else { @@ -18159,7 +18153,7 @@ void proto_register_ngap(void) { "UnsuccessfulOutcome_value", HFILL }}, /*--- End of included file: packet-ngap-hfarr.c ---*/ -#line 732 "./asn1/ngap/packet-ngap-template.c" +#line 726 "./asn1/ngap/packet-ngap-template.c" }; /* List of subtrees */ @@ -18630,7 +18624,7 @@ void proto_register_ngap(void) { &ett_ngap_UnsuccessfulOutcome, /*--- End of included file: packet-ngap-ettarr.c ---*/ -#line 763 "./asn1/ngap/packet-ngap-template.c" +#line 757 "./asn1/ngap/packet-ngap-template.c" }; static ei_register_info ei[] = { |