diff options
-rw-r--r-- | asn1/m3ap/m3ap.cnf | 98 | ||||
-rw-r--r-- | asn1/m3ap/packet-m3ap-template.c | 15 | ||||
-rw-r--r-- | epan/dissectors/packet-gtpv2.c | 93 | ||||
-rw-r--r-- | epan/dissectors/packet-gtpv2.h | 26 | ||||
-rw-r--r-- | epan/dissectors/packet-m3ap.c | 126 |
5 files changed, 312 insertions, 46 deletions
diff --git a/asn1/m3ap/m3ap.cnf b/asn1/m3ap/m3ap.cnf index a1acc4a209..7ec47d5b38 100644 --- a/asn1/m3ap/m3ap.cnf +++ b/asn1/m3ap/m3ap.cnf @@ -7,6 +7,10 @@ PER ALIGNED #.END +#.USE_VALS_EXT +ProcedureCode +ProtocolIE-ID + #.EXPORTS #.PDU_NEW @@ -16,9 +20,8 @@ M3AP-PDU ProcedureCode ProtocolIE-ID -#.USE_VALS_EXT -ProcedureCode -ProtocolIE-ID +#.NO_EMIT +# TBCD-STRING #.OMIT_ASSIGNMENT # Get rid of unused code warnings @@ -55,7 +58,7 @@ ProtocolIE-Field/value ie_field_value # FN_PARS ProtocolIE-FieldPair/firstValue FN_VARIANT=_pdu_new TYPE_REF_FN=dissect_ProtocolIEFieldPairFirstValue # FN_PARS ProtocolIE-FieldPair/secondValue FN_VARIANT=_pdu_new TYPE_REF_FN=dissect_ProtocolIEFieldPairSecondValue -#.FN_PARS ProtocolExtensionID VAL_PTR=&ProtocolExtensionID +# FN_PARS ProtocolExtensionID VAL_PTR=&ProtocolExtensionID #.FN_PARS ProtocolExtensionField/extensionValue FN_VARIANT=_pdu_new TYPE_REF_FN=dissect_ProtocolExtensionFieldExtensionValue #.FN_PARS ProcedureCode VAL_PTR = &ProcedureCode @@ -112,6 +115,92 @@ MAX_VAL = asn1_param_get_integer(%(ACTX)s,"upperBound") # Handle 64 bit constraint #.FN_PARS BitRate FN_VARIANT = _64b +# following construction is not supported by asn2wrs +# PLMNidentity ::= TBCD-STRING (SIZE (3)) + +#.FN_BODY PLMN-Identity VAL_PTR = ¶meter_tvb + tvbuff_t *parameter_tvb=NULL; + + offset = dissect_per_octet_string(tvb, offset, actx, tree, hf_index, + 3, 3, FALSE, ¶meter_tvb); + + if (!parameter_tvb) + return offset; + dissect_e212_mcc_mnc(parameter_tvb, actx->pinfo, tree, 0, FALSE); +#.END + +#.FN_BODY IPAddress VAL_PTR = ¶meter_tvb + tvbuff_t *parameter_tvb=NULL; + gint tvb_len; + +%(DEFAULT_BODY)s + + if (!parameter_tvb) + return offset; + + tvb_len = tvb_length(parameter_tvb); + proto_tree_add_item(tree, hf_m3ap_IPAddress, parameter_tvb, 0, tvb_len, ENC_BIG_ENDIAN); +#.END + +#.FN_BODY Absolute-Time-ofMBMS-Data VAL_PTR = ¶meter_tvb + tvbuff_t *parameter_tvb=NULL; + const gchar *time_str; + gint tvb_len; + +%(DEFAULT_BODY)s + + if (!parameter_tvb) + return offset; + + tvb_len = tvb_length(parameter_tvb); + + time_str = tvb_ntp_fmt_ts(parameter_tvb, 0); + proto_tree_add_string(tree, hf_m3ap_Absolute_Time_ofMBMS_Data_value, parameter_tvb, 0, tvb_len, time_str); +#.END + +#.FN_BODY MBMS-Service-Area VAL_PTR = ¶meter_tvb + tvbuff_t *parameter_tvb=NULL; + guint16 tvb_len; + +%(DEFAULT_BODY)s + + if (!parameter_tvb) + return offset; + + tvb_len = tvb_length(parameter_tvb); + + dissect_gtpv2_mbms_service_area(parameter_tvb, actx->pinfo, tree, actx->created_item, tvb_len, 0, 0); +#.END + +#.FN_BODY MBMS-Session-Duration VAL_PTR = ¶meter_tvb + tvbuff_t *parameter_tvb=NULL; + guint16 tvb_len; + + offset = dissect_per_octet_string(tvb, offset, actx, tree, hf_index, + 3, 3, FALSE, ¶meter_tvb); + + if (!parameter_tvb) + return offset; + + tvb_len = tvb_length(parameter_tvb); + + proto_item_append_text(actx->created_item, " "); + dissect_gtpv2_mbms_session_duration(parameter_tvb, actx->pinfo, tree, actx->created_item, tvb_len, 0, 0); +#.END + +#.FN_BODY MinimumTimeToMBMSDataTransfer VAL_PTR = ¶meter_tvb + tvbuff_t *parameter_tvb=NULL; + guint16 tvb_len; + +%(DEFAULT_BODY)s + + if (!parameter_tvb) + return offset; + + tvb_len = tvb_length(parameter_tvb); + dissect_gtpv2_mbms_time_to_data_xfer(parameter_tvb, actx->pinfo, tree, actx->created_item, tvb_len, 0, 0); +#.END + #.ASSIGN_VALUE_TO_TYPE # M3AP does not have constants assigned to types, they are pure INTEGER # ProcedureCode id-mBMSsessionStart ProcedureCode @@ -147,7 +236,6 @@ id-MCEname ProtocolIE-ID id-MBMSServiceAreaList ProtocolIE-ID id-Time-ofMBMS-DataTransfer ProtocolIE-ID id-Time-ofMBMS-DataStop ProtocolIE-ID -#.END #.REGISTER_NEW diff --git a/asn1/m3ap/packet-m3ap-template.c b/asn1/m3ap/packet-m3ap-template.c index 66f40345b2..db89c66f09 100644 --- a/asn1/m3ap/packet-m3ap-template.c +++ b/asn1/m3ap/packet-m3ap-template.c @@ -39,6 +39,8 @@ #include "packet-ber.h" #include "packet-per.h" #include "packet-e212.h" +#include "packet-gtpv2.h" +#include "packet-ntp.h" #define PNAME "M3 Application Protocol" #define PSNAME "M3AP" @@ -53,6 +55,9 @@ static dissector_handle_t m3ap_handle=NULL; /* Initialize the protocol and registered fields */ static int proto_m3ap = -1; +static int hf_m3ap_Absolute_Time_ofMBMS_Data_value = -1; +static int hf_m3ap_IPAddress = -1; + #include "packet-m3ap-hf.c" /* Initialize the subtree pointers */ @@ -137,6 +142,16 @@ void proto_register_m3ap(void) { /* List of fields */ static hf_register_info hf[] = { + { &hf_m3ap_Absolute_Time_ofMBMS_Data_value, + { "Absolute-Time-ofMBMS-Data-value", "m3ap.Absolute_Time_ofMBMS_Data_value", + FT_STRING, BASE_NONE, NULL, 0, + NULL, HFILL } + }, + { &hf_m3ap_IPAddress, + { "IPAddress", "m3ap.IPAddress", + FT_IPv6, BASE_NONE, NULL, 0, + NULL, HFILL } + }, #include "packet-m3ap-hfarr.c" }; diff --git a/epan/dissectors/packet-gtpv2.c b/epan/dissectors/packet-gtpv2.c index ff3cada45a..59e85d5e5c 100644 --- a/epan/dissectors/packet-gtpv2.c +++ b/epan/dissectors/packet-gtpv2.c @@ -43,6 +43,7 @@ #include "packet-s1ap.h" #include "packet-ranap.h" #include "packet-bssgp.h" +#include "packet-ntp.h" static dissector_handle_t nas_eps_handle; static dissector_table_t gtpv2_priv_ext_dissector_table; @@ -366,6 +367,10 @@ static int hf_gtpv2_mbms_dist_indication = -1; static int hf_gtpv2_mbms_service_id = -1; static int hf_gtpv2_add_flags_for_srvcc_ics = -1; static int hf_gtpv2_vsrvcc_flag = -1; +static int hf_gtpv2_abs_time_mbms_data = -1; +static int hf_gtpv2_mbms_session_duration_days = -1; +static int hf_gtpv2_mbms_session_duration_secs = -1; +static int hf_gtpv2_time_to_data_xfer = -1; static gint ett_gtpv2 = -1; static gint ett_gtpv2_flags = -1; @@ -660,6 +665,7 @@ static const value_string gtpv2_message_type_vals[] = { #define GTPV2_IE_MMBR 161 #define GTPV2_IE_MDT_CONFIG 162 #define GTPV2_IE_APCO 163 +#define GTPV2_IE_ABS_MBMS_DATA_TF_TIME 164 /* 164 to 254 reserved for future use */ #define GTPV2_IE_PRIVATE_EXT 255 @@ -762,7 +768,7 @@ static const value_string gtpv2_element_type_vals[] = { {135, "Node Type"}, /* Extendable / 8.65 */ {136, "Fully Qualified Domain Name (FQDN)"}, /* Variable Length / 8.66 */ {137, "Transaction Identifier (TI)"}, /* Variable Length / 8.68 */ - {138, "MBMS Session"}, /* Duration Extendable / 8.69 */ + {138, "MBMS Session Duration"}, /* Duration Extendable / 8.69 */ {139, "MBMS Service Area"}, /* Extendable / 8.70 */ {140, "MBMS Session Identifier"}, /* Extendable / 8.71 */ {141, "MBMS Flow Identifier"}, /* Extendable / 8.72 */ @@ -788,7 +794,8 @@ static const value_string gtpv2_element_type_vals[] = { {161, "Max MBR/APN-AMBR (MMBR)"}, /* Extendable / 8.92 */ {162, "MDT Configuration"}, /* Extendable / 8.93 */ {163, "Additional Protocol Configuration Options (APCO)"}, /* Extendable / 8.94 */ - /* 164 to 254 Spare. For future use. */ /* For future use. FFS */ + {164, "Absolute Time of MBMS Data Transfer"}, /* Extendable / 8.95 */ + /* 165 to 254 Spare. For future use. */ /* For future use. FFS */ {255, "Private Extension"}, /* Variable Length / 8.67 */ {0, NULL} }; @@ -4302,7 +4309,7 @@ dissect_gtpv2_ti(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, proto_ /* * 8.69 MBMS Session Duration */ -static void +void dissect_gtpv2_mbms_session_duration(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, proto_item *item _U_, guint16 length _U_, guint8 message_type _U_, guint8 instance _U_) { int offset = 0; @@ -4312,13 +4319,7 @@ dissect_gtpv2_mbms_session_duration(tvbuff_t *tvb, packet_info *pinfo _U_, proto guint32 seconds; /* From 3GPP TS 29.061 17.7.7 MBMS-Session-Duration AVP */ - /* Total length is three octets; is it suitable to use tvb_get_bits32() in order to extract 24 bits? */ - /* Bits: ssss ssss ssss ssss sddd dddd where s bits = seconds, d bits = days - * Will tvb_get_bits32() put the bits in the correct positions? For seconds - * It should be: 0000 0000 0000 000s ssss ssss ssss ssss (maximum = 131,071, maximum allowed = 86,400) - * But I fear it is: ssss ssss ssss ssss s000 0000 0000 0000 (maximum = a very big number!) - * For days - * It should be: 0000 0000 0000 0000 0000 0000 0ddd dddd */ + /* Bits: ssss ssss ssss ssss sddd dddd where s bits = seconds, d bits = days */ seconds = tvb_get_bits32(tvb, bit_offset, 17, ENC_BIG_ENDIAN); bit_offset += 17; @@ -4331,13 +4332,17 @@ dissect_gtpv2_mbms_session_duration(tvbuff_t *tvb, packet_info *pinfo _U_, proto } /* The lowest value of this AVP (i.e. all 0:s) is reserved to indicate an indefinite value to denote sessions that are expected to be always-on. */ - if((seconds&days) == 0xffffffff) { + if((seconds == 0) && (days == 0)) { + proto_tree_add_item(tree, hf_gtpv2_mbms_session_duration_days, tvb, offset, 3, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_gtpv2_mbms_session_duration_secs, tvb, offset, 3, ENC_BIG_ENDIAN); proto_item_append_text(item, "Indefinite (always-on)"); } else { hours = seconds / 60; seconds = seconds % 60; - proto_item_append_text(item, "%d Day(s) %d Hour(s) %d Second(s)", days, hours, seconds); + proto_tree_add_item(tree, hf_gtpv2_mbms_session_duration_days, tvb, offset, 3, ENC_BIG_ENDIAN); + proto_tree_add_item(tree, hf_gtpv2_mbms_session_duration_secs, tvb, offset, 3, ENC_BIG_ENDIAN); + proto_item_append_text(item, "%d day(s), %d hour(s), %d second(s)", days, hours, seconds); } offset += 3; @@ -4348,24 +4353,30 @@ dissect_gtpv2_mbms_session_duration(tvbuff_t *tvb, packet_info *pinfo _U_, proto /* * 8.70 MBMS Service Area */ -static void +void dissect_gtpv2_mbms_service_area(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, proto_item *item _U_, guint16 length _U_, guint8 message_type _U_, guint8 instance _U_) { int offset = 0; proto_item *sai_item; + guint8 binary_nr; + guint16 real_nr; + guint16 sai; + + binary_nr = tvb_get_guint8(tvb, offset); + real_nr = (guint16)binary_nr + 1; /* 3GPP TS 29.061 17.7.6 MBMS-Service-Area AVP */ - proto_tree_add_item(tree, hf_gtpv2_mbms_service_area_nr, tvb, offset, 1, ENC_BIG_ENDIAN); + proto_tree_add_string_format(tree, hf_gtpv2_mbms_service_area_nr, tvb, offset, 1, "", "Number of MBMS Service Area codes: %d", real_nr); offset += 1; /* A consecutive list of MBMS Service Area Identities follow, each with a length of two octets. */ while(offset<length) { /* 3GPP TS 23.003 15.3 Structure of MBMS SAI */ - guint16 sai = tvb_get_bits16(tvb, 0, 16, ENC_BIG_ENDIAN); + sai = tvb_get_ntohs(tvb, offset); sai_item = proto_tree_add_item(tree, hf_gtpv2_mbms_service_area_id, tvb, offset, 2, ENC_BIG_ENDIAN); /* The value 0 denotes the whole of PLMN as the MBMS Service Area */ if(sai == 0) { - proto_item_append_text(sai_item, "Entire PLMN"); + proto_item_append_text(sai_item, " Entire PLMN"); } offset += 2; } @@ -4579,7 +4590,7 @@ dissect_gtpv2_node_features(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *t /* 8.84 * MBMS Time to Data Transfer */ -static void +void dissect_gtpv2_mbms_time_to_data_xfer(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, proto_item *item _U_, guint16 length _U_, guint8 message_type _U_, guint8 instance _U_) { int offset = 0; @@ -4588,7 +4599,8 @@ dissect_gtpv2_mbms_time_to_data_xfer(tvbuff_t *tvb, packet_info *pinfo _U_, prot binary_secs = tvb_get_guint8(tvb, offset); real_secs = (guint16)binary_secs + 1; - proto_item_append_text(item, "%d second(s)", real_secs); + + proto_tree_add_string_format(tree, hf_gtpv2_time_to_data_xfer, tvb, offset, 1, "", "MBMS Time to Data Transfer: %d second(s)", real_secs); offset += 1; if(length > 1) @@ -4645,7 +4657,7 @@ dissect_gtpv2_tmgi(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, prot { int offset = 0; - proto_tree_add_item(tree, hf_gtpv2_mbms_service_id, tvb, offset, 3, ENC_NA); + proto_tree_add_item(tree, hf_gtpv2_mbms_service_id, tvb, offset, 3, ENC_BIG_ENDIAN); offset += 3; dissect_e212_mcc_mnc(tvb, pinfo, tree, offset, TRUE); @@ -4748,6 +4760,22 @@ dissect_gtpv2_apco(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, prot PROTO_ITEM_SET_GENERATED(expert_item); } +/* 8.95 Absolute Time of MBMS Data Transfer */ +static void +dissect_gtpv2_abs_mbms_data_tf_time(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, proto_item *item _U_, guint16 length _U_, guint8 message_type _U_, guint8 instance _U_) +{ + int offset = 0; + const gchar *time_str; + + time_str = tvb_ntp_fmt_ts(tvb, offset); + proto_tree_add_string(tree, hf_gtpv2_abs_time_mbms_data, tvb, offset, 8, time_str); + proto_item_append_text(item, "%s", time_str); + + offset += 8; + if(length > offset) + proto_tree_add_text(tree, tvb, offset, length-offset, "Spare: %s", tvb_bytes_to_str(tvb, offset, length-offset)); +} + typedef struct _gtpv2_ie { int ie_type; @@ -4866,7 +4894,8 @@ static const gtpv2_ie_t gtpv2_ies[] = { {GTPV2_IE_MMBR, dissect_gtpv2_mmbr}, /* 161, 8.92 Max MBR/APN-AMBR (MMBR) */ {GTPV2_IE_MDT_CONFIG, dissect_gtpv2_mdt_config}, /* 162, 8.93 MDT Configuration */ {GTPV2_IE_APCO, dissect_gtpv2_apco}, /* 163, 8.94 Additional Protocol Configuration Options (APCO) */ - /* 164-254 Spare. For future use. FFS */ + {GTPV2_IE_ABS_MBMS_DATA_TF_TIME, dissect_gtpv2_abs_mbms_data_tf_time}, /* 164, 9.95 Absolute Time of MBMS Data Transfer */ + /* 165-254 Spare. For future use. FFS */ {GTPV2_IE_PRIVATE_EXT,dissect_gtpv2_private_ext}, {0, dissect_gtpv2_unknown} @@ -6404,7 +6433,7 @@ void proto_register_gtpv2(void) }, { &hf_gtpv2_mbms_service_area_nr, {"Number of MBMS Service Area codes", "gtpv2.mbms_service_area_nr", - FT_UINT8, BASE_DEC, NULL, 0x0, + FT_STRING, BASE_NONE, NULL, 0x0, NULL, HFILL} }, { &hf_gtpv2_mbms_service_area_id, @@ -6423,7 +6452,7 @@ void proto_register_gtpv2(void) NULL, HFILL} }, { &hf_gtpv2_cteid, - {"Common Tunnel Endpoint Identifiere", "gtpv2.cetid", + {"Common Tunnel Endpoint Identifier", "gtpv2.cetid", FT_UINT32, BASE_DEC, NULL, 0x0, NULL, HFILL} }, @@ -6482,6 +6511,26 @@ void proto_register_gtpv2(void) FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL} }, + { &hf_gtpv2_abs_time_mbms_data, + {"Absolute Time of MBMS Data Transfer", "gtpv2.abs_time_mbms_data", + FT_STRING, BASE_NONE, NULL, 0, + NULL, HFILL} + }, + { &hf_gtpv2_mbms_session_duration_days, + {"MBMS Session Duration (days)", "gtpv2.mbms_session_duration_days", + FT_UINT24, BASE_DEC, NULL, 0x00007F, + NULL, HFILL} + }, + { &hf_gtpv2_mbms_session_duration_secs, + {"MBMS Session Duration (seconds)", "gtpv2.mbms_session_duration_secs", + FT_UINT24, BASE_DEC, NULL, 0xFFFF80, + NULL, HFILL} + }, + { &hf_gtpv2_time_to_data_xfer, + {"MBMS Time to Data Transfer", "gtpv2.time_to_data_xfer", + FT_STRING, BASE_NONE, NULL, 0, + NULL, HFILL} + }, }; static gint *ett_gtpv2_array[] = { diff --git a/epan/dissectors/packet-gtpv2.h b/epan/dissectors/packet-gtpv2.h new file mode 100644 index 0000000000..293f2a5c38 --- /dev/null +++ b/epan/dissectors/packet-gtpv2.h @@ -0,0 +1,26 @@ +/* packet-gtpv2.h + * + * $Id$ + * + * Wireshark - Network traffic analyzer + * By Gerald Combs <gerald@wireshark.org> + * Copyright 1998 Gerald Combs + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + +extern void dissect_gtpv2_mbms_service_area(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, proto_item *item _U_, guint16 length _U_, guint8 message_type _U_, guint8 instance _U_); +extern void dissect_gtpv2_mbms_session_duration(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, proto_item *item _U_, guint16 length _U_, guint8 message_type _U_, guint8 instance _U_); +extern void dissect_gtpv2_mbms_time_to_data_xfer(tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *tree, proto_item *item _U_, guint16 length _U_, guint8 message_type _U_, guint8 instance _U_); diff --git a/epan/dissectors/packet-m3ap.c b/epan/dissectors/packet-m3ap.c index e6f76b7382..862b796952 100644 --- a/epan/dissectors/packet-m3ap.c +++ b/epan/dissectors/packet-m3ap.c @@ -47,6 +47,8 @@ #include "packet-ber.h" #include "packet-per.h" #include "packet-e212.h" +#include "packet-gtpv2.h" +#include "packet-ntp.h" #define PNAME "M3 Application Protocol" #define PSNAME "M3AP" @@ -104,11 +106,14 @@ typedef enum _ProtocolIE_ID_enum { } ProtocolIE_ID_enum; /*--- End of included file: packet-m3ap-val.h ---*/ -#line 52 "../../asn1/m3ap/packet-m3ap-template.c" +#line 54 "../../asn1/m3ap/packet-m3ap-template.c" /* Initialize the protocol and registered fields */ static int proto_m3ap = -1; +static int hf_m3ap_Absolute_Time_ofMBMS_Data_value = -1; +static int hf_m3ap_IPAddress = -1; + /*--- Included file: packet-m3ap-hf.c ---*/ #line 1 "../../asn1/m3ap/packet-m3ap-hf.c" @@ -210,7 +215,7 @@ static int hf_m3ap_successfulOutcome_value = -1; /* SuccessfulOutcome_value */ static int hf_m3ap_unsuccessfulOutcome_value = -1; /* UnsuccessfulOutcome_value */ /*--- End of included file: packet-m3ap-hf.c ---*/ -#line 57 "../../asn1/m3ap/packet-m3ap-template.c" +#line 62 "../../asn1/m3ap/packet-m3ap-template.c" /* Initialize the subtree pointers */ static int ett_m3ap = -1; @@ -265,7 +270,7 @@ static gint ett_m3ap_SuccessfulOutcome = -1; static gint ett_m3ap_UnsuccessfulOutcome = -1; /*--- End of included file: packet-m3ap-ett.c ---*/ -#line 62 "../../asn1/m3ap/packet-m3ap-template.c" +#line 67 "../../asn1/m3ap/packet-m3ap-template.c" enum{ INITIATING_MESSAGE, @@ -375,7 +380,7 @@ dissect_m3ap_ProcedureCode(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _ offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index, 0U, 255U, &ProcedureCode, FALSE); -#line 63 "../../asn1/m3ap/m3ap.cnf" +#line 66 "../../asn1/m3ap/m3ap.cnf" col_add_fstr(actx->pinfo->cinfo, COL_INFO, "%s", val_to_str_ext(ProcedureCode, &m3ap_ProcedureCode_vals_ext, "unknown message")); @@ -419,7 +424,7 @@ dissect_m3ap_ProtocolIE_ID(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _ offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index, 0U, maxProtocolIEs, &ProtocolIE_ID, FALSE); -#line 48 "../../asn1/m3ap/m3ap.cnf" +#line 51 "../../asn1/m3ap/m3ap.cnf" if (tree) { proto_item_append_text(proto_item_get_parent_nth(actx->created_item, 2), ": %s", val_to_str_ext(ProtocolIE_ID, &m3ap_ProtocolIE_ID_vals_ext, "unknown (%d)")); } @@ -499,7 +504,7 @@ static const per_sequence_t ProtocolIE_ContainerList_sequence_of[1] = { static int dissect_m3ap_ProtocolIE_ContainerList(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { -#line 88 "../../asn1/m3ap/m3ap.cnf" +#line 91 "../../asn1/m3ap/m3ap.cnf" static const asn1_par_def_t ProtocolIE_ContainerList_pars[] = { { "lowerBound", ASN1_PAR_INTEGER }, { "upperBound", ASN1_PAR_INTEGER }, @@ -596,8 +601,23 @@ dissect_m3ap_PrivateIE_Container(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t * static int dissect_m3ap_Absolute_Time_ofMBMS_Data(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { +#line 146 "../../asn1/m3ap/m3ap.cnf" + tvbuff_t *parameter_tvb=NULL; + const gchar *time_str; + gint tvb_len; + offset = dissect_per_bit_string(tvb, offset, actx, tree, hf_index, - 64, 64, FALSE, NULL); + 64, 64, FALSE, ¶meter_tvb); + + + if (!parameter_tvb) + return offset; + + tvb_len = tvb_length(parameter_tvb); + + time_str = tvb_ntp_fmt_ts(parameter_tvb, 0); + proto_tree_add_string(tree, hf_m3ap_Absolute_Time_ofMBMS_Data_value, parameter_tvb, 0, tvb_len, time_str); + return offset; } @@ -879,8 +899,16 @@ dissect_m3ap_ExtendedMCE_ID(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx static int dissect_m3ap_PLMN_Identity(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { +#line 122 "../../asn1/m3ap/m3ap.cnf" + tvbuff_t *parameter_tvb=NULL; + offset = dissect_per_octet_string(tvb, offset, actx, tree, hf_index, - 3, 3, FALSE, NULL); + 3, 3, FALSE, ¶meter_tvb); + + if (!parameter_tvb) + return offset; + dissect_e212_mcc_mnc(parameter_tvb, actx->pinfo, tree, 0, FALSE); + return offset; } @@ -942,8 +970,20 @@ dissect_m3ap_GTP_TEID(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, p static int dissect_m3ap_IPAddress(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { +#line 133 "../../asn1/m3ap/m3ap.cnf" + tvbuff_t *parameter_tvb=NULL; + gint tvb_len; + offset = dissect_per_octet_string(tvb, offset, actx, tree, hf_index, - 4, 16, TRUE, NULL); + 4, 16, TRUE, ¶meter_tvb); + + + if (!parameter_tvb) + return offset; + + tvb_len = tvb_length(parameter_tvb); + proto_tree_add_item(tree, hf_m3ap_IPAddress, parameter_tvb, 0, tvb_len, ENC_BIG_ENDIAN); + return offset; } @@ -1024,8 +1064,21 @@ dissect_m3ap_MBMSServiceArea1(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *act static int dissect_m3ap_MBMS_Service_Area(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { +#line 162 "../../asn1/m3ap/m3ap.cnf" + tvbuff_t *parameter_tvb=NULL; + guint16 tvb_len; + offset = dissect_per_octet_string(tvb, offset, actx, tree, hf_index, - NO_BOUND, NO_BOUND, FALSE, NULL); + NO_BOUND, NO_BOUND, FALSE, ¶meter_tvb); + + + if (!parameter_tvb) + return offset; + + tvb_len = tvb_length(parameter_tvb); + + dissect_gtpv2_mbms_service_area(parameter_tvb, actx->pinfo, tree, actx->created_item, tvb_len, 0, 0); + return offset; } @@ -1034,8 +1087,21 @@ dissect_m3ap_MBMS_Service_Area(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *ac static int dissect_m3ap_MBMS_Session_Duration(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { +#line 176 "../../asn1/m3ap/m3ap.cnf" + tvbuff_t *parameter_tvb=NULL; + guint16 tvb_len; + offset = dissect_per_octet_string(tvb, offset, actx, tree, hf_index, - 3, 3, FALSE, NULL); + 3, 3, FALSE, ¶meter_tvb); + + if (!parameter_tvb) + return offset; + + tvb_len = tvb_length(parameter_tvb); + + proto_item_append_text(actx->created_item, " "); + dissect_gtpv2_mbms_session_duration(parameter_tvb, actx->pinfo, tree, actx->created_item, tvb_len, 0, 0); + return offset; } @@ -1064,8 +1130,20 @@ dissect_m3ap_MCEname(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, pr static int dissect_m3ap_MinimumTimeToMBMSDataTransfer(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { +#line 192 "../../asn1/m3ap/m3ap.cnf" + tvbuff_t *parameter_tvb=NULL; + guint16 tvb_len; + offset = dissect_per_octet_string(tvb, offset, actx, tree, hf_index, - 1, 1, FALSE, NULL); + 1, 1, FALSE, ¶meter_tvb); + + + if (!parameter_tvb) + return offset; + + tvb_len = tvb_length(parameter_tvb); + dissect_gtpv2_mbms_time_to_data_xfer(parameter_tvb, actx->pinfo, tree, actx->created_item, tvb_len, 0, 0); + return offset; } @@ -1468,7 +1546,7 @@ dissect_m3ap_MCEConfigurationUpdateFailure(tvbuff_t *tvb _U_, int offset _U_, as static int dissect_m3ap_InitiatingMessage_value(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { -#line 70 "../../asn1/m3ap/m3ap.cnf" +#line 73 "../../asn1/m3ap/m3ap.cnf" message_type = INITIATING_MESSAGE; offset = dissect_per_open_type_pdu_new(tvb, offset, actx, tree, hf_index, dissect_InitiatingMessageValue); @@ -1496,7 +1574,7 @@ dissect_m3ap_InitiatingMessage(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *ac static int dissect_m3ap_SuccessfulOutcome_value(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { -#line 73 "../../asn1/m3ap/m3ap.cnf" +#line 76 "../../asn1/m3ap/m3ap.cnf" message_type = SUCCESSFUL_OUTCOME; offset = dissect_per_open_type_pdu_new(tvb, offset, actx, tree, hf_index, dissect_SuccessfulOutcomeValue); @@ -1524,7 +1602,7 @@ dissect_m3ap_SuccessfulOutcome(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *ac static int dissect_m3ap_UnsuccessfulOutcome_value(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) { -#line 76 "../../asn1/m3ap/m3ap.cnf" +#line 79 "../../asn1/m3ap/m3ap.cnf" message_type = UNSUCCESSFUL_OUTCOME; @@ -1892,7 +1970,7 @@ static int dissect_M3AP_PDU_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _U_, proto /*--- End of included file: packet-m3ap-fn.c ---*/ -#line 90 "../../asn1/m3ap/packet-m3ap-template.c" +#line 95 "../../asn1/m3ap/packet-m3ap-template.c" static int dissect_ProtocolIEFieldValue(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) { @@ -1943,6 +2021,16 @@ void proto_register_m3ap(void) { /* List of fields */ static hf_register_info hf[] = { + { &hf_m3ap_Absolute_Time_ofMBMS_Data_value, + { "Absolute-Time-ofMBMS-Data-value", "m3ap.Absolute_Time_ofMBMS_Data_value", + FT_STRING, BASE_NONE, NULL, 0, + NULL, HFILL } + }, + { &hf_m3ap_IPAddress, + { "IPAddress", "m3ap.IPAddress", + FT_IPv6, BASE_NONE, NULL, 0, + NULL, HFILL } + }, /*--- Included file: packet-m3ap-hfarr.c ---*/ @@ -2333,7 +2421,7 @@ void proto_register_m3ap(void) { "UnsuccessfulOutcome_value", HFILL }}, /*--- End of included file: packet-m3ap-hfarr.c ---*/ -#line 142 "../../asn1/m3ap/packet-m3ap-template.c" +#line 157 "../../asn1/m3ap/packet-m3ap-template.c" }; /* List of subtrees */ @@ -2389,7 +2477,7 @@ void proto_register_m3ap(void) { &ett_m3ap_UnsuccessfulOutcome, /*--- End of included file: packet-m3ap-ettarr.c ---*/ -#line 148 "../../asn1/m3ap/packet-m3ap-template.c" +#line 163 "../../asn1/m3ap/packet-m3ap-template.c" }; @@ -2466,7 +2554,7 @@ proto_reg_handoff_m3ap(void) /*--- End of included file: packet-m3ap-dis-tab.c ---*/ -#line 180 "../../asn1/m3ap/packet-m3ap-template.c" +#line 195 "../../asn1/m3ap/packet-m3ap-template.c" } else { if (SctpPort != 0) { |