static int ett_nas_eps_esm_msg_cont = -1;
/* Global variables */
-packet_info *gpinfo;
+static packet_info *gpinfo;
/* Table 9.8.1: Message types for EPS mobility management
* 0 1 - - - - - - EPS mobility management messages
*/
-static const value_string nas_msg_emm_strings[] = {
+static const value_string nas_msg_emm_strings[] = {
{ 0x41, "Attach request"},
{ 0x42, "Attach accept"},
{ 0x43, "Attach complete"},
{ 0x44, "Attach reject"},
{ 0x45, "Detach request"},
{ 0x46, "Detach accept"},
-
+
{ 0x48, "Tracking area update request"},
{ 0x49, "Tracking area update accept"},
{ 0x4a, "Tracking area update complete"},
{ 0x4b, "Tracking area update reject"},
-
+
{ 0x4c, "Extended service request"},
{ 0x4e, "Service reject"},
-
+
{ 0x50, "GUTI reallocation command"},
{ 0x51, "GUTI reallocation complete"},
{ 0x52, "Authentication request"},
{ 0x5d, "Security mode command"},
{ 0x5e, "Security mode complete"},
{ 0x5f, "Security mode reject"},
-
+
{ 0x60, "EMM status"},
{ 0x61, "EMM information"},
{ 0x62, "Downlink NAS transport"},
/* Table 9.8.2: Message types for EPS session management */
-static const value_string nas_msg_esm_strings[] = {
+static const value_string nas_msg_esm_strings[] = {
{ 0xc1, "Activate default EPS bearer context request"},
{ 0xc2, "Activate default EPS bearer context accept"},
{ 0xc3, "Activate default EPS bearer context reject"},
else if (value > 0xba && value <= 0xfa) {
return_value = 128 + (value-0xba)*2;
}
-
+
return return_value;
}
DE_EPS_COMMON_NONE /* NONE */
}
nas_eps_common_elem_idx_t;
-/*
+/*
* 9.9.2 Common information elements
*/
*/
/*
* 9.9.2.7 Spare half octet
- * This element is used in the description of EMM and ESM messages when an odd number of
- * half octet type 1 information elements are used. This element is filled with spare bits
+ * This element is used in the description of EMM and ESM messages when an odd number of
+ * half octet type 1 information elements are used. This element is filled with spare bits
* set to zero and is placed in bits 5 to 8 of the octet unless otherwise specified.
* Coded Inline
*/
proto_tree_add_bits_item(tree, hf_nas_eps_emm_nas_key_set_id, tvb, (curr_offset<<3)+5, 3, FALSE);
curr_offset++;
return len;
-}
+}
/*
* 9.9.2.10 Supported codec list
DE_EMM_TRAC_AREA_ID_LST, /* 9.9.3.33 Tracking area identity list */
DE_EMM_UE_NET_CAP, /* 9.9.3.34 UE network capability */
DE_EMM_UE_RA_CAP_INF_UPD_NEED, /* 9.9.3.35 UE radio capability information update needed */
- DE_EMM_UE_SEC_CAP, /* 9.9.3.36 UE security capability */
+ DE_EMM_UE_SEC_CAP, /* 9.9.3.36 UE security capability */
DE_EMM_EMERG_NUM_LST, /* 9.9.3.37 Emergency Number List */
DE_EMM_CLI, /* 9.9.3.38 CLI */
DE_EMM_SS_CODE, /* 9.9.3.39 SS Code */
{ 0, NULL }
};
-/*
+/*
* In the network to UE direction:
*/
proto_tree_add_text(tree, tvb, curr_offset, len - 1, "Type of identity not known");
break;
}
-
+
return(len);
}
bit_offset = curr_offset<<3;
bit_offset+=4;
proto_tree_add_bits_item(tree, hf_nas_eps_spare_bits, tvb, bit_offset, 1, FALSE);
- proto_tree_add_item(tree, hf_nas_eps_esm_imeisv_req, tvb, curr_offset, 1, FALSE);
+ proto_tree_add_item(tree, hf_nas_eps_esm_imeisv_req, tvb, curr_offset, 1, FALSE);
curr_offset++;
return(curr_offset - offset);
/* Get the bit offset of the lover half of the octet bits 4 - 1 */
bit_offset = curr_offset<<3;
bit_offset+=4;
-
+
/* Type of security context flag (TSC) (octet 1) V 1/2 */
proto_tree_add_bits_item(tree, hf_nas_eps_tsc, tvb, bit_offset, 1, FALSE);
bit_offset++;
new_tvb = tvb_new_subset(tvb, curr_offset, len, len );
if(gsm_a_dtap_handle)
call_dissector(gsm_a_dtap_handle,new_tvb, gpinfo, tree);
-
+
return(len);
}
/*
/*
* 9.9.3.33 Tracking area identity list
*/
-/* Type of list (octet 1)
+/* Type of list (octet 1)
* Bits 7 6
*/
static const value_string nas_eps_emm_tai_tol_vals[] = {
return(curr_offset-offset);
}
/*
- * 9.9.3.34 UE network capability
+ * 9.9.3.34 UE network capability
*/
static const true_false_string nas_eps_emm_supported_flg_value = {
/*
* The coding of the CLI value part is the same as for octets 3 to 14
- * of the Calling party BCD number information element defined in
+ * of the Calling party BCD number information element defined in
* subclause 10.5.4.9 of 3GPP TS 24.008
*/
return(len);
}
-/*
- * 9.9.3.42 Generic message container type
+/*
+ * 9.9.3.42 Generic message container type
*/
static guint16
return(len);
}
-/*
+/*
* 9.9.3.43 Generic message container
*/
static guint16
return(len);
}
-/*
+/*
* 9.9.3.44 Voice domain preference and UE's usage setting
*/
static guint16
"Use the value indicated by the maximum bit rate for uplink in octet 4.");
}else{
proto_tree_add_uint_format(tree, hf_nas_eps_embr_ul, tvb, curr_offset, 1, octet,
- "Maximum bit rate for uplink(extended) : %u %s",
+ "Maximum bit rate for uplink(extended) : %u %s",
calc_bitrate_ext(octet),
(octet > 0x4a) ? "Mbps" : "kbps");
}
"Use the value indicated by the maximum bit rate for downlink in octet 5.");
}else{
proto_tree_add_uint_format(tree, hf_nas_eps_embr_ul, tvb, curr_offset, 1, octet,
- "Maximum bit rate for downlink(extended) : %u %s",
+ "Maximum bit rate for downlink(extended) : %u %s",
calc_bitrate_ext(octet),
(octet > 0x4a) ? "Mbps" : "kbps");
}
"Use the value indicated by the Guaranteed bit rate for uplink in octet 6.");
}else{
proto_tree_add_uint_format(tree, hf_nas_eps_embr_ul, tvb, curr_offset, 1, octet,
- "Guaranteed bit rate for uplink(extended) : %u %s",
+ "Guaranteed bit rate for uplink(extended) : %u %s",
calc_bitrate_ext(octet),
(octet > 0x4a) ? "Mbps" : "kbps");
}
"Use the value indicated by the Guaranteed bit rate for downlink in octet 7.");
}else{
proto_tree_add_uint_format(tree, hf_nas_eps_embr_ul, tvb, curr_offset, 1, octet,
- "Guaranteed bit rate for downlink(extended) : %u %s",
+ "Guaranteed bit rate for downlink(extended) : %u %s",
calc_bitrate_ext(octet),
(octet > 0x4a) ? "Mbps" : "kbps");
}
{ 0x2b, "Invalid EPS bearer identity"},
{ 0x2c, "Semantic errors in packet filter(s)"},
{ 0x2d, "Syntactical errors in packet filter(s)"},
- { 0x2e, "EPS bearer context without TFT already activated"},
+ { 0x2e, "EPS bearer context without TFT already activated"},
{ 0x2f, "PTI mismatch"},
{ 0x31, "Last PDN disconnection not allowed"},
{ 0x32, "PDN type IPv4 only allowed"},
return(curr_offset - offset);
}
/*
- * 9.9.4.5 ESM information transfer flag
+ * 9.9.4.5 ESM information transfer flag
*/
/* EIT (ESM information transfer) */
static const true_false_string nas_eps_emm_eit_vals = {
return(curr_offset-offset);
}
/*
- * 9.9.4.6 Linked EPS bearer identity
+ * 9.9.4.6 Linked EPS bearer identity
*/
-/*
+/*
* Linked EPS bearer identity (bits 1-4)
*/
return(len);
}
/*
- * 9.9.4.7 LLC service access point identifier
+ * 9.9.4.7 LLC service access point identifier
* See subclause 10.5.6.9 in 3GPP TS 24.008
*/
/*
- * 9.9.4.8 Packet flow identifier
- * See subclause 10.5.6.11 in 3GPP TS 24.008
+ * 9.9.4.8 Packet flow identifier
+ * See subclause 10.5.6.11 in 3GPP TS 24.008
*/
/*
* 9.9.4.9 PDN address
};
/*
- * 9.9.4.11 Protocol configuration options
+ * 9.9.4.11 Protocol configuration options
* See subclause 10.5.6.3 in 3GPP TS 24.008
*/
/*
* See subclause 10.5.6.5 in 3GPP TS 24.008
*/
/*
- * 9.9.4.13 Radio priority
+ * 9.9.4.13 Radio priority
* See subclause 10.5.7.2 in 3GPP TS 24.008
*/
/*
* See subclause 10.5.6.17 in 3GPP TS 24.008
*/
/*
- * 9.9.4.15 Traffic flow aggregate description
+ * 9.9.4.15 Traffic flow aggregate description
* The Traffic flow aggregate description information element is encoded using the same format as the Traffic flow
* template information element (see subclause 10.5.6.12 in 3GPP TS 24.008 [13]). When sending this IE, the UE shall
* assign the packet filter identifier values so that they are unique across all packet filters for the PDN connection.
* packet-gsm_a_gm.c
*/
/*
- * 9.9.4.17 Transaction identifier
+ * 9.9.4.17 Transaction identifier
* The Transaction identifier information element is coded as the Linked TI information element in 3GPP TS 24.008 [13],
* subclause 10.5.6.7.
* The coding of the TI flag, the TI value and the EXT bit is defined in 3GPP TS 24.007[20].
/* 9.9.4 EPS Session Management (ESM) information elements */
const value_string nas_esm_elem_strings[] = {
{ 0x00, "Access point name" }, /* 9.9.4.1 Access point name */
- { 0x00, "APN aggregate maximum bit rate" }, /* 9.9.4.2 APN aggregate maximum bit rate */
+ { 0x00, "APN aggregate maximum bit rate" }, /* 9.9.4.2 APN aggregate maximum bit rate */
{ 0x00, "EPS quality of service" }, /* 9.9.4.3 EPS quality of service */
{ 0x00, "ESM cause" }, /* 9.9.4.4 ESM cause */
- { 0x00, "ESM information transfer flag" }, /* 9.9.4.5 ESM information transfer flag */
+ { 0x00, "ESM information transfer flag" }, /* 9.9.4.5 ESM information transfer flag */
{ 0x00, "Linked EPS bearer identity" }, /* 9.9.4.6 Linked EPS bearer identity */
- { 0x00, "LLC service access point identifier" }, /* 9.9.4.7 LLC service access point identifier */
+ { 0x00, "LLC service access point identifier" }, /* 9.9.4.7 LLC service access point identifier */
{ 0x00, "Packet flow identifier" }, /* 9.9.4.8 Packet flow identifier */
{ 0x00, "PDN address" }, /* 9.9.4.9 PDN address */
{ 0x00, "PDN type" }, /* 9.9.4.10 PDN type */
- { 0x00, "Protocol configuration options" }, /* 9.9.4.11 Protocol configuration options */
+ { 0x00, "Protocol configuration options" }, /* 9.9.4.11 Protocol configuration options */
{ 0x00, "Quality of service" }, /* 9.9.4.12 Quality of service */
{ 0x00, "Radio priority" }, /* 9.9.4.13 Radio priority */
{ 0x00, "Request type" }, /* 9.9.4.14 Request type */
- { 0x00, "Traffic flow aggregate description" }, /* 9.9.4.15 Traffic flow aggregate description */
+ { 0x00, "Traffic flow aggregate description" }, /* 9.9.4.15 Traffic flow aggregate description */
{ 0x00, "Traffic flow templat" }, /* 9.9.4.16 Traffic flow template */
{ 0x00, "Transaction identifier" }, /* 9.9.4.17 Transaction identifier */
{ 0, NULL }
DE_ESM_APN_AGR_MAX_BR, /* 9.9.4.2 APN aggregate maximum bit rate */
DE_ESM_EPS_QOS, /* 9.9.4.3 EPS quality of service */
DE_ESM_CAUSE, /* 9.9.4.4 ESM cause */
- DE_ESM_INF_TRF_FLG, /* 9.9.4.5 ESM information transfer flag */
+ DE_ESM_INF_TRF_FLG, /* 9.9.4.5 ESM information transfer flag */
DE_ESM_LNKED_EPS_B_ID, /* 9.9.4.6 Linked EPS bearer identity */
- DE_ESM_LLC_SAPI, /* 9.9.4.7 LLC service access point identifier */
+ DE_ESM_LLC_SAPI, /* 9.9.4.7 LLC service access point identifier */
DE_ESM_P_FLW_ID, /* 9.9.4.8 Packet flow identifier */
DE_ESM_PDN_ADDR, /* 9.9.4.9 PDN address */
DE_ESM_PDN_TYPE, /* 9.9.4.10 PDN type */
- DE_ESM_PROT_CONF_OPT, /* 9.9.4.11 Protocol configuration options */
+ DE_ESM_PROT_CONF_OPT, /* 9.9.4.11 Protocol configuration options */
DE_ESM_QOS, /* 9.9.4.12 Quality of service */
DE_ESM_RA_PRI, /* 9.9.4.13 Radio priority */
DE_ESM_REQ_TYPE, /* 9.9.4.14 Request type */
- DE_ESM_TRAF_FLOW_AGR_DESC, /* 9.9.4.15 Traffic flow aggregate description */
+ DE_ESM_TRAF_FLOW_AGR_DESC, /* 9.9.4.15 Traffic flow aggregate description */
DE_ESM_TRAF_FLOW_TEMPL, /* 9.9.4.16 Traffic flow template */
DE_ESM_TID, /* 9.9.4.17 Transaction identifier */
DE_ESM_NONE /* NONE */
de_esm_apn_aggr_max_br, /* 9.9.4.2 APN aggregate maximum bit rate */
de_esm_qos, /* 9.9.4.3 EPS quality of service */
de_esm_cause, /* 9.9.4.4 ESM cause */
- de_esm_inf_trf_flg, /* 9.9.4.5 ESM information transfer flag */
+ de_esm_inf_trf_flg, /* 9.9.4.5 ESM information transfer flag */
de_esm_lnkd_eps_bearer_id, /* 9.9.4.6 Linked EPS bearer identity */
- NULL, /* 9.9.4.7 LLC service access point identifier */
+ NULL, /* 9.9.4.7 LLC service access point identifier */
NULL, /* 9.9.4.8 Packet flow identifier */
de_esm_pdn_addr, /* 9.9.4.9 PDN address */
NULL, /* 9.9.4.10 PDN type */
- NULL, /* 9.9.4.11 Protocol configuration options */
+ NULL, /* 9.9.4.11 Protocol configuration options */
NULL, /* 9.9.4.12 Quality of service */
NULL, /* 9.9.4.13 Radio priority */
NULL, /* 9.9.4.14 Request type */
- NULL, /* 9.9.4.15 Traffic flow aggregate description */
+ NULL, /* 9.9.4.15 Traffic flow aggregate description */
NULL, /* 9.9.4.16 Traffic flow template */
NULL, /* 9.9.4.17 Transaction identifier */
NULL, /* NONE */
ELEM_OPT_TLV(0x4a, NAS_PDU_TYPE_COMMON, DE_EPS_CMN_PLM_LST, " - Equivalent PLMNs");
/* 34 Emergency Number List 9.9.3.37 O TLV 5-50 */
ELEM_OPT_TLV(0x34, GSM_A_PDU_TYPE_DTAP, DE_EMERGENCY_NUM_LIST, "");
- /* 64 EPS network feature support EPS network feature support 9.9.3.12A O TLV 3 */
+ /* 64 EPS network feature support EPS network feature support 9.9.3.12A O TLV 3 */
ELEM_OPT_TLV(0x64, NAS_PDU_TYPE_EMM, DE_EMM_EPS_NET_FEATURE_SUP, "");
/* F- Additional update result Additional update result 9.9.3.0A O TV 1 */
ELEM_OPT_TV_SHORT( 0xF0 , NAS_PDU_TYPE_EMM, DE_EMM_ADD_UPD_RES, "" );
de_emm_nas_key_set_id_bits(tvb, tree, bit_offset, NULL);
bit_offset+=4;
- /* EPS attach type EPS attach type 9.9.3.11 M V 1/2
+ /* EPS attach type EPS attach type 9.9.3.11 M V 1/2
* Inline:
*/
proto_tree_add_bits_item(tree, hf_nas_eps_spare_bits, tvb, bit_offset, 1, FALSE);
bit_offset++;
proto_tree_add_bits_item(tree, hf_nas_eps_emm_eps_att_type, tvb, bit_offset, 3, FALSE);
bit_offset+=3;
-
+
/* Fix the lengths */
curr_len--;
curr_offset++;
/* 5D Voice domain preference and UE's usage setting Voice domain preference and UE's usage setting 9.9.3.44 O TLV 3 */
/* ELEM_OPT_TLV(0x5D, xxxxxx, xxxxxx, ""); */
-
+
EXTRANEOUS_DATA_CHECK(curr_len, 0);
}
/*
- * 8.2.5 Authentication failure
+ * 8.2.5 Authentication failure
*/
static void
nas_emm_attach_fail(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
proto_tree_add_bits_item(tree, hf_nas_eps_emm_spare_half_octet, tvb, bit_offset, 4, FALSE);
bit_offset+=4;
/* H0 */
- /*
- * NAS key set identifierASME NAS key set identifier 9.9.3.21 M V 1/2
+ /*
+ * NAS key set identifierASME NAS key set identifier 9.9.3.21 M V 1/2
*/
de_emm_nas_key_set_id_bits(tvb, tree, bit_offset, " ASME");
bit_offset+=4;
-
+
/* Fix the lengths */
curr_len--;
curr_offset++;
/* 60 CLI CLI 9.9.3.38 O TLV 3-12 */
ELEM_OPT_TLV(0x60, GSM_A_PDU_TYPE_DTAP, DE_CLD_PARTY_BCD_NUM, " - CLI");
/* 61 SS Code SS Code 9.9.3.39 O TV 2 */
- ELEM_OPT_TV(0x61, NAS_PDU_TYPE_EMM, DE_EMM_SS_CODE, "");
+ ELEM_OPT_TV(0x61, NAS_PDU_TYPE_EMM, DE_EMM_SS_CODE, "");
/* 62 LCS indicator LCS indicator 9.9.3.40 O TV 2 */
- ELEM_OPT_TV(0x62, NAS_PDU_TYPE_EMM, DE_EMM_LCS_IND, "");
+ ELEM_OPT_TV(0x62, NAS_PDU_TYPE_EMM, DE_EMM_LCS_IND, "");
/* 63 LCS client identity LCS client identity 9.9.3.41 O TLV 3-257 */
- ELEM_OPT_TLV(0x63, NAS_PDU_TYPE_EMM, DE_EMM_LCS_CLIENT_ID, "");
-
+ ELEM_OPT_TLV(0x63, NAS_PDU_TYPE_EMM, DE_EMM_LCS_CLIENT_ID, "");
+
EXTRANEOUS_DATA_CHECK(curr_len, 0);
}
/*
/* GUTI EPS mobile identity 9.9.3.12 M LV 12 */
ELEM_MAND_LV(NAS_PDU_TYPE_EMM, DE_EMM_EPS_MID, " - GUTI");
-
+
/* 54 TAI list Tracking area identity list 9.9.3.33 O TLV 8-98 */
ELEM_OPT_TLV(0x54, NAS_PDU_TYPE_EMM, DE_EMM_TRAC_AREA_ID_LST, "");
/* Mobile identity Mobile identity 9.9.2.3 M LV 4-10 */
ELEM_MAND_LV(NAS_PDU_TYPE_COMMON, DE_EPS_CMN_MOB_ID, "");
-
+
EXTRANEOUS_DATA_CHECK(curr_len, 0);
}
/* 23 IMEISV Mobile identity 9.9.2.3 O TLV 11 */
ELEM_OPT_TLV(0x23, NAS_PDU_TYPE_COMMON, DE_EPS_CMN_MOB_ID, " - IMEISV");
-
+
EXTRANEOUS_DATA_CHECK(curr_len, 0);
}
/*
/*
* 8.2.25 Service request
* This message is sent by the UE to the network to request the establishment
- * of a NAS signalling connection and of the radio and S1 bearers.
+ * of a NAS signalling connection and of the radio and S1 bearers.
* Its structure does not follow the structure of a standard layer 3 message. See table 8.2.25.1.
*/
/* Table 8.2.25.1
/* 5A T3412 value GPRS timer 9.9.3.16 O TV 2 */
ELEM_OPT_TV(0x5a, GSM_A_PDU_TYPE_GM, DE_GPRS_TIMER, " - T3412 value");
/* 50 GUTI EPS mobile identity 9.9.3.12 O TLV 13 */
- ELEM_OPT_TLV(0x50, NAS_PDU_TYPE_EMM, DE_EMM_EPS_MID, " - GUTI");
+ ELEM_OPT_TLV(0x50, NAS_PDU_TYPE_EMM, DE_EMM_EPS_MID, " - GUTI");
/* 54 TAI list Tracking area identity list 9.9.3.33 O TLV 8-98 */
- ELEM_OPT_TLV(0x54, NAS_PDU_TYPE_EMM, DE_EMM_TRAC_AREA_ID_LST, "");
+ ELEM_OPT_TLV(0x54, NAS_PDU_TYPE_EMM, DE_EMM_TRAC_AREA_ID_LST, "");
/* 57 EPS bearer context status EPS bearer context status 9.9.2.1 O TLV 4 */
ELEM_OPT_TLV(0x57, NAS_PDU_TYPE_COMMON, DE_EPS_CMN_EPS_BE_CTX_STATUS, "");
/* 13 Location area identification Location area identification 9.9.2.2 O TV 6 */
/* NAS message container NAS message container 9.9.3.22 M LV 3-252*/
ELEM_MAND_LV(NAS_PDU_TYPE_EMM, DE_EMM_NAS_MSG_CONT, "");
-
+
EXTRANEOUS_DATA_CHECK(curr_len, 0);
}
/* 27 Protocol configuration options Protocol configuration options 9.9.4.11 O TLV 3-253 */
ELEM_OPT_TLV( 0x27 , GSM_A_PDU_TYPE_GM, DE_PRO_CONF_OPT , "" );
-
+
EXTRANEOUS_DATA_CHECK(curr_len, 0);
}
ELEM_MAND_V(NAS_PDU_TYPE_ESM, DE_ESM_CAUSE);
/* 27 Protocol configuration options Protocol configuration options 9.9.4.11 O TLV 3-253 */
ELEM_OPT_TLV( 0x27 , GSM_A_PDU_TYPE_GM, DE_PRO_CONF_OPT , "" );
-
+
EXTRANEOUS_DATA_CHECK(curr_len, 0);
}
/*
EXTRANEOUS_DATA_CHECK(curr_len, 0);
}
/*
- * 8.3.9 Bearer resource modification reject
+ * 8.3.9 Bearer resource modification reject
*/
static void
nas_esm_bearer_res_mod_rej(tvbuff_t *tvb, proto_tree *tree, guint32 offset, guint len)
/* Request type 9.9.4.14 M V 1/2 */
ELEM_MAND_V(GSM_A_PDU_TYPE_GM, DE_REQ_TYPE);
-
+
/* Lengths already fixed by the call to ELEM_MAND_V macro */
if (curr_len==0)
NULL, /* NONE */
};
-void get_nas_esm_msg_params(guint8 oct, const gchar **msg_str, int *ett_tree, int *hf_idx, msg_fcn *msg_fcn_p)
+static void
+get_nas_esm_msg_params(guint8 oct, const gchar **msg_str, int *ett_tree, int *hf_idx, msg_fcn *msg_fcn_p)
{
gint idx;
nas_emm_attach_rej, /* Attach reject */
nas_emm_detach_req, /* Detach request */
NULL, /* 8.2.10 Detach accept */
-
+
nas_emm_trac_area_upd_req, /* Tracking area update request */
nas_emm_trac_area_upd_acc, /* Tracking area update accept */
NULL, /* Tracking area update complete (No IE's)*/
nas_emm_trac_area_upd_rej, /* Tracking area update reject */
-
+
nas_emm_ext_serv_req, /* Extended service request */
nas_emm_serv_rej, /* Service reject */
-
+
nas_emm_guti_realloc_cmd, /* GUTI reallocation command */
NULL, /* GUTI reallocation complete (No IE's) */
nas_emm_auth_req, /* Authentication request */
nas_emm_sec_mode_cmd, /* Security mode command */
nas_emm_sec_mode_comp, /* Security mode complete */
nas_emm_sec_mode_rej, /* Security mode reject */
-
+
nas_emm_emm_status, /* EMM status */
nas_emm_emm_inf, /* EMM information */
nas_emm_dl_nas_trans, /* Downlink NAS transport */
};
-void get_nas_emm_msg_params(guint8 oct, const gchar **msg_str, int *ett_tree, int *hf_idx, msg_fcn *msg_fcn_p)
+static void
+get_nas_emm_msg_params(guint8 oct, const gchar **msg_str, int *ett_tree, int *hf_idx, msg_fcn *msg_fcn_p)
{
gint idx;
return;
}
-/*
- * EPS session management messages.
+/*
+ * EPS session management messages.
* A plain NAS message is pased to this function
*/
static void
proto_tree_add_item(tree, hf_gsm_a_L3_protocol_discriminator, tvb, offset, 1, FALSE);
offset++;
- /* Procedure transaction identity 9.4
+ /* Procedure transaction identity 9.4
* The procedure transaction identity and its use are defined in 3GPP TS 24.007
*/
proto_tree_add_item(tree, hf_nas_eps_esm_proc_trans_id, tvb, offset, 1, FALSE);
* d) sequence number;
* e) plain NAS message, as defined in item 1.
*
- * The EPS bearer identity and the procedure transaction identity are only used in messages
+ * The EPS bearer identity and the procedure transaction identity are only used in messages
* with protocol discriminator EPS session management. Octet 1a with the procedure transaction
* identity shall only be included in these messages.
*/
pd = tvb_get_guint8(tvb,offset)&0x0f;
switch (pd){
case 2:
- /* EPS session management messages.
- * Ref 3GPP TS 24.007 version 8.0.0 Release 8, Table 11.2: Protocol discriminator values
+ /* EPS session management messages.
+ * Ref 3GPP TS 24.007 version 8.0.0 Release 8, Table 11.2: Protocol discriminator values
*/
disect_nas_eps_esm_msg(tvb, pinfo, nas_eps_tree, offset);
break;
case 7:
- /* EPS mobility management messages.
- * Ref 3GPP TS 24.007 version 8.0.0 Release 8, Table 11.2: Protocol discriminator values
+ /* EPS mobility management messages.
+ * Ref 3GPP TS 24.007 version 8.0.0 Release 8, Table 11.2: Protocol discriminator values
*/
dissect_nas_eps_emm_msg(tvb, pinfo, nas_eps_tree, offset, TRUE);
break;
case 15:
- /* Special conformance testing functions for User Equipment messages.
- * Ref 3GPP TS 24.007 version 8.0.0 Release 8, Table 11.2: Protocol discriminator values
+ /* Special conformance testing functions for User Equipment messages.
+ * Ref 3GPP TS 24.007 version 8.0.0 Release 8, Table 11.2: Protocol discriminator values
*/
if (gsm_a_dtap_handle){
tvbuff_t *new_tvb = tvb_new_subset(tvb, offset, -1, -1);
gsm_a_dtap_pinfo = pinfo;
call_dissector(gsm_a_dtap_handle, new_tvb, gsm_a_dtap_pinfo, nas_eps_tree);
- break;
+ break;
} /* else fall through default */
default:
proto_tree_add_text(nas_eps_tree, tvb, offset, -1, "Not a NAS EPS PD %u(%s)",pd,val_to_str(pd, protocol_discriminator_vals,"unknown"));
NULL, HFILL }
},
/* ESM hf cvariables */
- { &hf_nas_eps_msg_esm_type,
+ { &hf_nas_eps_msg_esm_type,
{ "NAS EPS session management messages", "nas_eps.nas_msg_esm_type",
FT_UINT8, BASE_HEX, VALS(nas_msg_esm_strings), 0x0,
NULL, HFILL }
/* Register fields and subtrees */
proto_register_field_array(proto_nas_eps, hf, array_length(hf));
proto_register_subtree_array(ett, array_length(ett));
-
+
/* Register dissector */
register_dissector(PFNAME, dissect_nas_eps, proto_nas_eps);
}
ndmp_task_data_t *task;
conversation_t *conversation;
} ndmp_conv_data_t;
-ndmp_conv_data_t *ndmp_conv_data=NULL;
+static ndmp_conv_data_t *ndmp_conv_data=NULL;
static proto_tree *top_tree;
static itl_nexus_t *
long ntp_frac_sec; /* n/(2**32) */
} ntptime_t;
-void nstime_to_ntptime(nstime_t *nst, ntptime_t *ntpt) {
+static void
+nstime_to_ntptime(nstime_t *nst, ntptime_t *ntpt) {
ntpt->ntp_sec = nst->secs + NTP_BASETIME;
ntpt->ntp_frac_sec = (long) ((nst->nsecs*FLOAT_DENOM)/1000000000.0);
}
-void ntptime_to_nstime(ntptime_t *ntpt, nstime_t *nst) {
+static void
+ntptime_to_nstime(ntptime_t *ntpt, nstime_t *nst) {
nst->secs = ntpt->ntp_sec - NTP_BASETIME;
nst->nsecs = (int)((ntpt->ntp_frac_sec*1000000000.0)/FLOAT_DENOM);
}
#endif
-void ntptime_buf_to_nstime(const guint8 *ntptime_buf, nstime_t *nstime) {
+static void
+ntptime_buf_to_nstime(const guint8 *ntptime_buf, nstime_t *nstime) {
nstime->secs = pntohl(&ntptime_buf[0]) - NTP_BASETIME;
nstime->nsecs = (int)((pntohl(&ntptime_buf[4])*1000000000.0)/FLOAT_DENOM);
}
{ NULL, NULL, 0 }
};
/* decode all nfs filehandles as this type */
-gint default_nfs_fhandle_type=FHT_UNKNOWN;
+static gint default_nfs_fhandle_type=FHT_UNKNOWN;
/* For dissector helpers which take a "levels" argument to indicate how
* many expansions up they should populate the expansion items with
/* file name snooping */
gboolean nfs_file_name_snooping = FALSE;
-gboolean nfs_file_name_full_snooping = FALSE;
+static gboolean nfs_file_name_full_snooping = FALSE;
typedef struct nfs_name_snoop {
int fh_length;
unsigned char *fh;
static emem_tree_t *nfs_name_snoop_known = NULL;
static emem_tree_t *nfs_file_handles = NULL;
-gboolean nfs_display_v4_tag = TRUE;
-gboolean display_major_nfsv4_ops = TRUE;
+static gboolean nfs_display_v4_tag = TRUE;
+static gboolean display_major_nfsv4_ops = TRUE;
static int dissect_nfs_stateid4(tvbuff_t *tvb, int offset, proto_tree *tree, guint16 *hash);
};
-const true_false_string tfs_endianness = { "Little Endian", "Big Endian" };
+static const true_false_string tfs_endianness = { "Little Endian", "Big Endian" };
/* SVR4: checked with ReliantUNIX (5.43, 5.44, 5.45), OpenSolaris (build 101a) */
}
}
-const value_string netapp_file_flag_vals[] = {
+static const value_string netapp_file_flag_vals[] = {
{ 0x0000, "Not set"},
{ 0x0001, "Set"},
{ 0, NULL}
/* RFC 1094, Page 15 */
-const value_string nfs2_ftype[] =
+static const value_string nfs2_ftype[] =
{
{ 0, "Non-File" },
{ 1, "Regular File" },
{ 0, NULL }
};
-gint *nfsv4_operation_ett[] =
+static gint *nfsv4_operation_ett[] =
{
&ett_nfs_access4 ,
&ett_nfs_access_supp4,
{ 0, NULL }
};
-const value_string nfs_fh_obj_id[] = {
+static const value_string nfs_fh_obj_id[] = {
{ 1, "NF4REG"},
{ 2, "NF4DIR"},
{ 3, "NF4BLK"},
{ 0, NULL }
};
-gint *nfs_cb_operation_ett[] =
+static gint *nfs_cb_operation_ett[] =
{
&ett_nfs_cb_getattr,
&ett_nfs_cb_recall,
extern int dissect_access_reply(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree* tree,
int version, GString *optext);
-extern gint default_nfs_fhandle_type;
extern gint hf_nfs_nfsstat;
#endif /* packet-nfs.h */
NULL
};
-const int *cyclic_non_fatal_1_fields[] = {
+static const int *cyclic_non_fatal_1_fields[] = {
&hf_omron_cyclic_1,
&hf_omron_cyclic_2,
&hf_omron_cyclic_3,
NULL
};
-const int *cyclic_non_fatal_2_fields[] = {
+static const int *cyclic_non_fatal_2_fields[] = {
&hf_omron_cyclic_8,
&hf_omron_cyclic_9,
&hf_omron_cyclic_10,
NULL
};
-const int *cyclic_non_fatal_3_fields[] = {
+static const int *cyclic_non_fatal_3_fields[] = {
&hf_omron_cyclic_16,
&hf_omron_cyclic_17,
&hf_omron_cyclic_18,
NULL
};
-const int *cyclic_non_fatal_4_fields[] = {
+static const int *cyclic_non_fatal_4_fields[] = {
&hf_omron_cyclic_24,
&hf_omron_cyclic_25,
&hf_omron_cyclic_26,
NULL
};
-const int *cyclic_non_fatal_5_fields[] = {
+static const int *cyclic_non_fatal_5_fields[] = {
&hf_omron_cyclic_32,
&hf_omron_cyclic_33,
&hf_omron_cyclic_34,
NULL
};
-const int *cyclic_non_fatal_6_fields[] = {
+static const int *cyclic_non_fatal_6_fields[] = {
&hf_omron_cyclic_40,
&hf_omron_cyclic_41,
&hf_omron_cyclic_42,
NULL
};
-const int *cyclic_non_fatal_7_fields[] = {
+static const int *cyclic_non_fatal_7_fields[] = {
&hf_omron_cyclic_48,
&hf_omron_cyclic_49,
&hf_omron_cyclic_50,
NULL
};
-const int *cyclic_non_fatal_8_fields[] = {
+static const int *cyclic_non_fatal_8_fields[] = {
&hf_omron_cyclic_56,
&hf_omron_cyclic_57,
&hf_omron_cyclic_58,
*/
static int radius_tap = -1;
-radius_vendor_info_t no_vendor = {"Unknown Vendor",0,NULL,-1,1,1,FALSE};
+static radius_vendor_info_t no_vendor = {"Unknown Vendor",0,NULL,-1,1,1,FALSE};
-radius_attr_info_t no_dictionary_entry = {"Unknown-Attribute",0,FALSE,FALSE,radius_octets, NULL, NULL, -1, -1, -1, -1, -1, NULL };
+static radius_attr_info_t no_dictionary_entry = {"Unknown-Attribute",0,FALSE,FALSE,radius_octets, NULL, NULL, -1, -1, -1, -1, -1, NULL };
static dissector_handle_t eap_handle;
{RADIUS_DISCONNECT_REQUEST_ACK, "Disconnect-ACK"}, /* 41 RFC3575 */
{RADIUS_DISCONNECT_REQUEST_NAK, "Disconnect-NAK"}, /* 42 RFC3575 */
{RADIUS_CHANGE_FILTER_REQUEST, "CoA-Request"}, /* 43 */
- {RADIUS_CHANGE_FILTER_REQUEST_ACK, "CoA-ACK"}, /* 44 */
- {RADIUS_CHANGE_FILTER_REQUEST_NAK, "CoA-NAK"}, /* 45 */
+ {RADIUS_CHANGE_FILTER_REQUEST_ACK, "CoA-ACK"}, /* 44 */
+ {RADIUS_CHANGE_FILTER_REQUEST_NAK, "CoA-NAK"}, /* 45 */
/*
50 IP-Address-Allocate [RFC3575]
51 IP-Address-Release [RFC3575]
const radius_vsa_buffer_key* key1 = (const radius_vsa_buffer_key*) k1;
const radius_vsa_buffer_key* key2 = (const radius_vsa_buffer_key*) k2;
- return (((key1->vendor_id == key2->vendor_id) &&
+ return (((key1->vendor_id == key2->vendor_id) &&
(key1->vsa_type == key2->vsa_type)
) ? TRUE : FALSE);
}
const radius_vsa_buffer_key* key = (const radius_vsa_buffer_key*) k;
return key->vendor_id + key->vsa_type;
-}
+}
/* Compare 2 keys */
static gint radius_call_equal(gconstpointer k1, gconstpointer k2)
proto_item_append_text(avp_item, "[wrong length for IPv6 prefix]");
return;
}
-
+
/* first byte is reserved == 0x00 */
if (tvb_get_guint8(tvb, offset)) {
proto_item_append_text(avp_item, "[invalid reserved byte for IPv6 prefix]");
add_avp_to_tree(avp_tree, avp_item, pinfo, vsa_tvb, dictionary_entry, vsa_buffer->len, 0);
g_hash_table_remove(vsa_buffer_table, &(vsa_buffer->key));
g_free(vsa_buffer);
-
+
} else {
add_avp_to_tree(avp_tree, avp_item, pinfo, tvb, dictionary_entry, avp_vsa_len, offset);
}
guint avplength;
e_radiushdr rh;
radius_info_t *rad_info;
-
+
conversation_t* conversation;
radius_call_info_key radius_call_key;
radius_call_t *radius_call = NULL;
nstime_t delta;
static address null_address = { AT_NONE, 0, NULL };
-
+
/* does this look like radius ? */
if(!is_radius(tvb)){
return 0;
}
-
+
col_set_str(pinfo->cinfo, COL_PROTOCOL, "RADIUS");
col_clear(pinfo->cinfo, COL_INFO);
/* XXX: Default "standard" values: Should be parameters ? */
vendor->type_octets = 1;
vendor->length_octets = 1;
- vendor->has_flags = FALSE;
+ vendor->has_flags = FALSE;
g_hash_table_insert(dict->vendors_by_id,GUINT_TO_POINTER(vendor->code),vendor);
g_hash_table_insert(dict->vendors_by_name,(gpointer)(vendor->name),vendor);
{ "Ascend Data Filter", "radius.ascenddatafilter", FT_BYTES, BASE_NONE, NULL, 0x0,
NULL, HFILL }}
};
-
+
gint *base_ett[] = {
&ett_radius,
&ett_radius_avp,
&(no_dictionary_entry.ett),
&(no_vendor.ett),
};
-
+
hfett_t ri;
char* dir = NULL;
gchar* dict_err_str = NULL;
-
+
ri.hf = g_array_new(FALSE,TRUE,sizeof(hf_register_info));
ri.ett = g_array_new(FALSE,TRUE,sizeof(gint *));
ri.vend_vs = g_array_new(TRUE,TRUE,sizeof(value_string));
-
+
g_array_append_vals(ri.hf, base_hf, array_length(base_hf));
g_array_append_vals(ri.ett, base_ett, array_length(base_ett));
-
+
dir = get_persconffile_path("radius", FALSE, FALSE);
-
+
if (test_for_directory(dir) != EISDIR) {
/* Although dir isn't a directory it may still use memory */
g_free(dir);
-
+
dir = get_datafile_path("radius");
-
+
if (test_for_directory(dir) != EISDIR) {
g_free(dir);
dir = NULL;
}
}
-
+
if (dir) {
radius_load_dictionary(dict,dir,"dictionary",&dict_err_str);
g_warning("radius: %s",dict_err_str);
g_free(dict_err_str);
}
-
+
g_hash_table_foreach(dict->attrs_by_id,register_attrs,&ri);
g_hash_table_foreach(dict->vendors_by_id,register_vendors,&ri);
}
"Time to live for a radius request used for matching it with a response", 10, &request_ttl);
radius_tap = register_tap("radius");
proto_register_prefix("radius",register_radius_fields);
-
+
dict = g_malloc(sizeof(radius_dictionary_t));
dict->attrs_by_id = g_hash_table_new(g_direct_hash,g_direct_equal);
dict->attrs_by_name = g_hash_table_new(g_str_hash,g_str_equal);
static int ett_ie_message_id = -1;
static int ett_ie_sys_info_type = -1;
-proto_tree *top_tree;
-dissector_handle_t gsm_a_ccch_handle;
-dissector_handle_t gsm_a_dtap_handle;
+static proto_tree *top_tree;
+static dissector_handle_t gsm_a_ccch_handle;
+static dissector_handle_t gsm_a_dtap_handle;
static gboolean is_si2q = FALSE;
#define RSL_MSG_CHAN_ACTIV_N_ACK 35
#define RSL_MSG_CONN_FAIL 36
#define RSL_MSG_DEACTIVATE_SACCH 37
-
+
#define RSL_MSG_ENCR_CMD 38 /* 8.4.6 */
#define RSL_MSG_HANDODET 39 /* 8.4.7 */
#define RSL_MSG_MEAS_RES 40 /* 8.4.8 */
#define RSL_IE_TFO_STATUS 59
#define RSL_IE_LLP_APDU 60
#define RSL_IE_TFO_TRANSP_CONT 61
-
+
static const value_string rsl_ie_type_vals[] = {
{ 0x01, "Channel Number" }, /* 9.3.1 */
{ 0x02, "Link Identifier" }, /* 9.3.2 */
/* The R bit indicates if the procedure is an initial activation or a reactivation. */
proto_tree_add_item(ie_tree, hf_rsl_rbit, tvb, offset, 1, FALSE);
- /* The A-bits indicate the type of activation, which defines the access procedure
+ /* The A-bits indicate the type of activation, which defines the access procedure
* and the operation of the data link layer
*/
octet = (tvb_get_guint8(tvb,offset) & 0x06)>>1;
/* FPC_EPC mode */
proto_tree_add_item(ie_tree, hf_rsl_bs_fpc_epc_mode, tvb, offset, 1, FALSE);
- /* The Power Level field (octet 2) indicates the number of 2 dB steps by
- * which the power shall be reduced from its nominal value, Pn,
- * set by the network operator to adjust the coverage.
+ /* The Power Level field (octet 2) indicates the number of 2 dB steps by
+ * which the power shall be reduced from its nominal value, Pn,
+ * set by the network operator to adjust the coverage.
* Thus the Power Level values correspond to the following powers (relative to Pn):
*/
proto_tree_add_item(ie_tree, hf_rsl_bs_power, tvb, offset, 1, FALSE);
ie_offset = offset;
/* The DTX bits of octet 3 indicate whether DTX is applied
- * DTXd indicates use of DTX in the downlink direction (BTS to MS) and
+ * DTXd indicates use of DTX in the downlink direction (BTS to MS) and
* DTXu indicates use of DTX in the uplink direction (MS to BTS).
*/
proto_tree_add_item(ie_tree, hf_rsl_cm_dtxd, tvb, offset, 1, FALSE);
/* The "Speech or data indicator" field (octet 4) */
proto_tree_add_item(ie_tree, hf_rsl_speech_or_data, tvb, offset, 1, FALSE);
octet = tvb_get_guint8(tvb,offset);
- offset++;
+ offset++;
/* Channel rate and type */
proto_tree_add_item(ie_tree, hf_rsl_ch_rate_and_type, tvb, offset, 1, FALSE);
offset++;
/* Element identifier */
proto_tree_add_item(ie_tree, hf_rsl_ie_id, tvb, offset, 1, FALSE);
offset++;
-
+
/* Hand-over reference */
proto_tree_add_item(ie_tree, hf_rsl_ho_ref, tvb, offset, 1, FALSE);
offset++;
proto_tree_add_item(ie_tree, hf_rsl_ie_id, tvb, offset, 1, FALSE);
offset++;
- /* The Paging Group field (octet 2) contains the binary representation of the paging
+ /* The Paging Group field (octet 2) contains the binary representation of the paging
* group as defined in 3GPP TS 45.002.
*/
proto_tree_add_item(ie_tree, hf_rsl_paging_grp, tvb, offset, 1, FALSE);
proto_tree_add_item(ie_tree, hf_rsl_ie_id, tvb, offset, 1, FALSE);
offset++;
- /*
+ /*
* Paging Buffer Space.
*/
proto_tree_add_item(ie_tree, hf_rsl_paging_load, tvb, offset, 2, FALSE);
return offset;
}
-/*
+/*
* 9.3.24 Timing Advance
*/
static int
*/
proto_tree_add_item(ie_tree, hf_rsl_rxlev_sub_up, tvb, offset, 1, FALSE);
offset++;
- /* Octet 5
+ /* Octet 5
* 8 7 6 5 4 3 2 1
* Reserved | RXQUAL.FULL.up | RXQUAL.SUB.up
*/
{ 0x07, "Interworking" },
{ 0, NULL }
};
-
+
/*
* 9.3.26 Cause
*/
proto_tree_add_item(ie_tree, hf_rsl_ie_length, tvb, offset, 1, FALSE);
offset++;
ie_offset = offset;
-
+
/* Cause Value */
octet = tvb_get_guint8(tvb,offset);
proto_tree_add_item(tree, hf_rsl_extension_bit, tvb, offset, 1, FALSE);
if ((octet & 0x80) == 80)
/* Cause Extension*/
offset++;
-
+
/* Diagnostic(s) if any */
return ie_offset+length;
}
proto_tree_add_item(ie_tree, hf_rsl_ie_length, tvb, offset, 1, FALSE);
offset++;
- /*
+ /*
* SMSCB frame
*/
proto_tree_add_text(ie_tree, tvb,offset,length,"SMSCB frame");
proto_tree_add_item(ie_tree, hf_rsl_ie_id, tvb, offset, 1, FALSE);
offset++;
- /* Timing Offset
- * The meaning of the MS Timing Offset is as defined in 3GPP TS 45.010.
+ /* Timing Offset
+ * The meaning of the MS Timing Offset is as defined in 3GPP TS 45.010.
* The value of MS Timing Offset is the binary value of the 8-bit Timing Offset field (octet 2) - 63.
* The range of MS Timing Offset is therefore -63 to 192.
*/
proto_tree_add_item(ie_tree, hf_rsl_timing_offset, tvb, offset, 1, FALSE);
offset++;
-
+
return offset;
}
proto_tree_add_item(ie_tree, hf_rsl_ie_length, tvb, offset, 1, FALSE);
offset++;
- /*
+ /*
* Octets 3-25 contain the complete L3 message as defined in 3GPP TS 44.018.
*/
/* Channel */
proto_tree_add_item(ie_tree, hf_rsl_ch_needed, tvb, offset, 1, FALSE);
offset++;
-
+
return offset;
}
-/*
+/*
* 9.3.41 CB Command type
*/
static int
/* Channel */
proto_tree_add_item(ie_tree, hf_rsl_ch_needed, tvb, offset, 1, FALSE);
offset++;
-
+
return offset;
}
offset++;
ie_offset = offset;
- /*
+ /*
* SMSCB Message
*/
/* Channel Ind */
proto_tree_add_item(ie_tree, hf_rsl_ch_ind, tvb, offset, 1, FALSE);
offset++;
-
+
return offset;
}
proto_tree_add_text(ie_tree, tvb,offset,length,"Descriptive group or broadcast call reference");
- /* The octets 3 to 7 are coded in the same way as the octets 2 to 6
+ /* The octets 3 to 7 are coded in the same way as the octets 2 to 6
* in the Descriptive group or broadcast call reference
* information element as defined in 3GPP TS 24.008.
*/
* information element as defined in 3GPP TS 44.018, n-2 is equal to the length of the radio interface
* Group channel description information element
*/
-
+
offset = offset + length;
return offset;
/* Octet 3 bits 3, 4 and 5 are bits 1, 2 and 3 of the radio interface
* eMLPP priority as defined in 3GPP TS 44.018.
*/
- /* Octet 3 bits 1 and 2 are bits 1 and 2 of the radio interface NLN
+ /* Octet 3 bits 1 and 2 are bits 1 and 2 of the radio interface NLN
* as defined in 3GPP TS 44.018.
*/
proto_tree_add_item(ie_tree, hf_rsl_command, tvb, offset, 1, FALSE);
offset++;
}
-
+
return offset;
}
/*
offset++;
/* The call priority field (bit 3 to 1 of octet 2) is coded in the same way
- * as the call priority field (bit 3 to 1 of octet 5) in the
+ * as the call priority field (bit 3 to 1 of octet 5) in the
* Descriptive group or broadcast call reference information element
- * as defined in 3GPP TS 24.008.
+ * as defined in 3GPP TS 24.008.
*/
proto_tree_add_item(ie_tree, hf_rsl_emlpp_prio, tvb, offset, 1, FALSE);
offset++;
offset++;
/* Octet 3 bits 1 to 6 contain the radio interface octet 2 bits 3 to 8 of the
- * UIC information element as defined in 3GPP TS 44.018.
+ * UIC information element as defined in 3GPP TS 44.018.
*/
proto_tree_add_text(ie_tree, tvb,offset,1,"UIC");
offset++;
* and bit 8 is set to 0, or if bit 6 of the Codec List field (octet 4) indicates
* that UMTS AMR is supported, or if bit 7 of the Codec List field (octet 4)
* indicates that UMTS AMR 2 is supported, or if bit 1, 3, 4 or 5 of the Codec List
- * extension 1 field (octet 5) indicates that AMR WB is supported, the following
+ * extension 1 field (octet 5) indicates that AMR WB is supported, the following
* two octets (after the Codec List field and its extensions) is present
*/
proto_tree_add_item(ie_tree, hf_rsl_ie_id, tvb, offset, 1, FALSE);
offset++;
- /* The RTD field is the binary representation of the value of the
+ /* The RTD field is the binary representation of the value of the
* round trip delay in 20 ms increments.
*/
rtd = (tvb_get_guint8(tvb,offset)>>1)*20;
rtd_item = proto_tree_add_uint(tree, hf_rsl_rtd, tvb,offset,1,rtd);
proto_item_append_text(rtd_item," ms");
- /* The Delay IND field indicates if the delay corresponds to a BTS
+ /* The Delay IND field indicates if the delay corresponds to a BTS
* to transcoder delay or to a BTS to remote BTS delay.
*/
proto_tree_add_item(ie_tree, hf_rsl_delay_ind, tvb, offset, 1, FALSE);
/*
* 9.3.59 TFO transparent container
* This is a variable length element that conveys a message associated with TFO protocol,
- * as defined in 3GPP TS 28.062. This element can be sent from the BSC to the BTS or
+ * as defined in 3GPP TS 28.062. This element can be sent from the BSC to the BTS or
* from the BTS to the BSC. The BTS shall retrieve the information it is able to understand,
* and forward transparently the complete information to the BSC or to the TRAU.
*/
if(tvb_length_remaining(tvb,offset) > 0)
offset = dissect_rsl_ie_staring_time(tvb, pinfo, tree, offset, FALSE);
break;
- /* 8.5.2 CCCH LOAD INDICATION 18*/
+ /* 8.5.2 CCCH LOAD INDICATION 18*/
case RSL_MSG_CCCH_LOAD_IND:
/* Channel number (note) 9.3.1 M TV 2 */
offset = dissect_rsl_ie_ch_no(tvb, pinfo, tree, offset, TRUE);
offset = dissect_rsl_ie_ho_ref(tvb, pinfo, tree, offset, FALSE);
/* BS Power 9.3.4 O 3) TV 2 */
if(tvb_length_remaining(tvb,offset) > 0)
- offset = dissect_rsl_ie_bs_power(tvb, pinfo, tree, offset, FALSE);
+ offset = dissect_rsl_ie_bs_power(tvb, pinfo, tree, offset, FALSE);
/* MS Power 9.3.13 O 3) TV 2 */
if(tvb_length_remaining(tvb,offset) > 0)
offset = dissect_rsl_ie_ms_pow(tvb, pinfo, tree, offset, FALSE);
/* Link Identifier 9.3.2 M TV 2 */
offset = dissect_rsl_ie_link_id(tvb, pinfo, tree, offset, TRUE);
/* L3 Info (CIPH MOD CMD) 9.3.11 M TLV 6 */
- offset = dissect_rsl_ie_L3_inf(tvb, pinfo, tree, offset, TRUE);
+ offset = dissect_rsl_ie_L3_inf(tvb, pinfo, tree, offset, TRUE);
break;
/* 8.4.7 HANDOVER DETECTION */
case RSL_MSG_HANDODET: /* 39 8.4.7 */
offset = dissect_rsl_ie_l1_inf(tvb, pinfo, tree, offset, FALSE);
/* L3 Info (MEAS REP, EXT MEAS REP or ENH MEAS REP) 9.3.11 O 1) TLV 21 */
if(tvb_length_remaining(tvb,offset) > 0)
- offset = dissect_rsl_ie_L3_inf(tvb, pinfo, tree, offset, FALSE);
+ offset = dissect_rsl_ie_L3_inf(tvb, pinfo, tree, offset, FALSE);
/* MS Timing Offset 9.3.37 O 2) TV 2 */
if(tvb_length_remaining(tvb,offset) > 0)
- offset = dissect_rsl_ie_ms_timing_offset(tvb, pinfo, tree, offset, FALSE);
+ offset = dissect_rsl_ie_ms_timing_offset(tvb, pinfo, tree, offset, FALSE);
break;
/* 8.4.9 MODE MODIFY */
case RSL_MSG_MODE_MODIFY_REQ: /* 41 8.4.9 */
offset = dissect_rsl_ie_ch_mode(tvb, pinfo, tree, offset, TRUE);
/* Encryption information 9.3.7 O 1) TLV >=3 */
if(tvb_length_remaining(tvb,offset) > 0)
- offset = dissect_rsl_ie_enc_inf(tvb, pinfo, tree, offset, FALSE);
+ offset = dissect_rsl_ie_enc_inf(tvb, pinfo, tree, offset, FALSE);
/* Main channel reference 9.3.45 O 2) TV 2 */
if(tvb_length_remaining(tvb,offset) > 0)
offset = dissect_rsl_ie_main_ch_ref(tvb, pinfo, tree, offset, FALSE);
offset = dissect_rsl_ie_multirate_cntrl(tvb, pinfo, tree, offset, TRUE);
/* Supported Codec Type 9.3.54 O 1) TLV >=5 */
if(tvb_length_remaining(tvb,offset) > 0)
- offset = dissect_rsl_ie_sup_codec_types(tvb, pinfo, tree, offset, FALSE);
+ offset = dissect_rsl_ie_sup_codec_types(tvb, pinfo, tree, offset, FALSE);
/* TFO transparent container 9.3.59 O 4) TLV >=3 */
if(tvb_length_remaining(tvb,offset) > 0)
offset = dissect_rsl_ie_tfo_transp_cont(tvb, pinfo, tree, offset, FALSE);
};
-proto_item *memdatacomp = NULL;
-proto_tree *memdatacomp_tree = NULL;
+static proto_item *memdatacomp = NULL;
+static proto_tree *memdatacomp_tree = NULL;
return private_key;
}
-const char *BAGTYPE(gnutls_pkcs12_bag_type_t x) {
+static const char *
+BAGTYPE(gnutls_pkcs12_bag_type_t x) {
switch (x) {
case GNUTLS_BAG_EMPTY: return "Empty";
case GNUTLS_BAG_PKCS8_ENCRYPTED_KEY: return "PKCS#8 Encrypted key";
static gint tds_protocol_type = TDS_PROTOCOL_NOT_SPECIFIED;
-const enum_val_t tds_protocol_type_options[] = {
+static const enum_val_t tds_protocol_type_options[] = {
{"not_specified", "Not Specified", TDS_PROTOCOL_NOT_SPECIFIED},
{"tds4", "TDS 4", TDS_PROTOCOL_4}, /* TDS 4.2 and TDS 4.6 */
{"tds5", "TDS 5", TDS_PROTOCOL_5},
static gboolean tds_little_endian = TRUE;
-const enum_val_t tds_endian_type_options[] = {
+static const enum_val_t tds_endian_type_options[] = {
{"little_endian", "Little Endian", TRUE},
{"big_endian" , "Big Endian" , FALSE},
{NULL, NULL, -1}
}
-static int tds_token_is_fixed_size(guint8 token)
+static int
+tds_token_is_fixed_size(guint8 token)
{
switch (token) {
case TDS_DONE_TOKEN:
}
-static int tds_get_fixed_token_size(guint8 token)
+static int
+tds_get_fixed_token_size(guint8 token)
{
switch(token) {
case TDS_DONE_TOKEN:
}
}
-static int get_size_by_coltype(int servertype)
+static int
+get_size_by_coltype(int servertype)
{
switch(servertype)
{
*/
return pkt_len;
}
-guint16 is_asciitpkt(tvbuff_t *tvb)
+guint16
+is_asciitpkt(tvbuff_t *tvb)
{
guint16 count;
/*
}
-int parseLengthText ( guint8* pTpktData )
+static int
+parseLengthText ( guint8* pTpktData )
{
int value = 0;
const guint8 * pData = pTpktData;
}
return value;
}
-int parseVersionText ( guint8* pTpktData )
+static int
+parseVersionText ( guint8* pTpktData )
{
int value = 0;
guint8 * pData = pTpktData;
return value;
}
-int parseReservedText ( guint8* pTpktData )
+static int
+parseReservedText ( guint8* pTpktData )
{
int value = 0;
guint8 * pData = pTpktData;
volatile int offset = 0;
int length_remaining;
int data_len;
- int mgcp_packet_len = 0;
+ volatile int mgcp_packet_len = 0;
int mgcp_version = 0;
int mgcp_reserved = 0;
volatile int length;
{
dissect_tpkt_encap(tvb, pinfo, tree, tpkt_desegment, x224_handle);
}
+
/*
* Dissect ASCII TPKT, which wraps a ASCII TPKT header around an OSI TP
* PDU.
-
+ */
+#if 0
static void
dissect_ascii_tpkt(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
{
dissect_asciitpkt(tvb, pinfo, tree, osi_tp_handle);
}
- */
+#endif
void
proto_register_tpkt(void)
#include <dirent.h>
#endif
-#include <ctype.h>
-#include <stdlib.h>
#include <string.h>
-#include <stdarg.h>
#include <errno.h>
#include <glib.h>
#define XML_SCOPED_NAME -1001
-GArray* hf_arr;
-GArray* ett_arr;
+static GArray* hf_arr;
+static GArray* ett_arr;
static const gchar* default_media_types[] = {
"text/xml",
"application/x-wms-logconnectstats",
"application/x-wms-logplaystats",
"application/x-wms-sendevent",
- "application/rss+xml",
+ "application/rss+xml",
"image/svg+xml",
};
static GPtrArray* stack = NULL;
xml_frame_t* current_frame;
char* colinfo_str;
-
+
if (stack != NULL)
g_ptr_array_free(stack,TRUE);
xml_frame_t *xml_item = frame->first_child;
while (xml_item) {
- if ((xml_item->type == XML_FRAME_ATTRIB) &&
+ if ((xml_item->type == XML_FRAME_ATTRIB) &&
xml_item->name_orig_case && !strcmp(xml_item->name_orig_case, name)) {
attr = xml_item;
break;
proto_item_set_text(pi, "%s", tvb_format_text(tok->tvb,tok->offset,tok->len));
current_frame->last_item = pi;
-
+
new_frame = ep_alloc(sizeof(xml_frame_t));
new_frame->type = XML_FRAME_ATTRIB;
new_frame->name = name;
GString* s = g_string_new(proto_name);
gchar* str;
g_string_append(s,".");
-
+
for (i = 1; i < hier->len; i++) {
g_string_append_printf(s, "%s.",(gchar*)g_ptr_array_index(hier,i));
}
pref_heuristic_media_save = FALSE;
}
}
-
+
if (pref_heuristic_tcp_save != pref_heuristic_tcp ) {
if (pref_heuristic_tcp) {
heur_dissector_add("tcp", dissect_xml_heur, xml_ns.hf_tag);
pref_heuristic_tcp_save = FALSE;
}
}
-
+
if (pref_heuristic_udp_save != pref_heuristic_udp ) {
if (pref_heuristic_udp) {
heur_dissector_add("udp", dissect_xml_heur, xml_ns.hf_tag);
range_foreach(xml_tcp_range, range_delete_xml_tcp_callback);
g_free(xml_tcp_range);
xml_tcp_range = range_copy(global_xml_tcp_range);
- range_foreach(xml_tcp_range, range_add_xml_tcp_callback);
+ range_foreach(xml_tcp_range, range_add_xml_tcp_callback);
}
void
gint ett_zbee_zdp_cache = -1;
/* Data dissector handle. */
-dissector_handle_t data_handle;
+static dissector_handle_t data_handle;
/**************************************
* Value Strings