aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/asn1/gsm_map/gsm_map.cnf
diff options
context:
space:
mode:
authorPascal Quantin <pascal.quantin@gmail.com>2017-04-23 23:17:15 +0200
committerPascal Quantin <pascal.quantin@gmail.com>2017-04-24 18:59:36 +0000
commit4b2ee367434572f288f1272cc4c1722a0c484798 (patch)
treeb258121883d2abd8595385fb802f10025df0825c /epan/dissectors/asn1/gsm_map/gsm_map.cnf
parent9785aed5b6fe3b2e67b20d8b044fda6c4626e908 (diff)
GSM SMS: optionally use GSM-MAP info to perform reassembly (off by default)
Change-Id: I62c7a04e62167bd2d68d861f1d8d854f3159b159 Ping-Bug: 13592 Reviewed-on: https://code.wireshark.org/review/21306 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Diffstat (limited to 'epan/dissectors/asn1/gsm_map/gsm_map.cnf')
-rw-r--r--epan/dissectors/asn1/gsm_map/gsm_map.cnf126
1 files changed, 102 insertions, 24 deletions
diff --git a/epan/dissectors/asn1/gsm_map/gsm_map.cnf b/epan/dissectors/asn1/gsm_map/gsm_map.cnf
index 6c2683436b..5e751aeba5 100644
--- a/epan/dissectors/asn1/gsm_map/gsm_map.cnf
+++ b/epan/dissectors/asn1/gsm_map/gsm_map.cnf
@@ -243,31 +243,40 @@ MAP-DialoguePDU B "0.4.0.0.1.1.1.1" "map-DialogueAS"
#.FN_BODY AddressString VAL_PTR = &parameter_tvb
- tvbuff_t *parameter_tvb;
- proto_tree *subtree;
+ tvbuff_t *parameter_tvb;
+ proto_tree *subtree;
%(DEFAULT_BODY)s
- if (!parameter_tvb)
- return offset;
+ if (!parameter_tvb)
+ return offset;
- subtree = proto_item_add_subtree(actx->created_item, ett_gsm_map_isdn_address_string);
- dissect_gsm_map_msisdn(parameter_tvb, actx->pinfo , subtree);
+ subtree = proto_item_add_subtree(actx->created_item, ett_gsm_map_isdn_address_string);
+ dissect_gsm_map_msisdn(parameter_tvb, actx->pinfo , subtree);
+ actx->private_data = tvb_bytes_to_str(actx->pinfo->pool, parameter_tvb, 0, tvb_captured_length(parameter_tvb));
#.FN_BODY IMSI VAL_PTR = &parameter_tvb
- tvbuff_t *parameter_tvb;
+ tvbuff_t *parameter_tvb;
- offset = dissect_ber_octet_string(implicit_tag, actx, tree, tvb, offset, hf_index, &parameter_tvb);
+ offset = dissect_ber_octet_string(implicit_tag, actx, tree, tvb, offset, hf_index, &parameter_tvb);
if (!parameter_tvb)
- return offset;
- if(tvb_reported_length(parameter_tvb)==0)
- return offset;
+ return offset;
+ if(tvb_reported_length(parameter_tvb)==0)
+ return offset;
/* Hide the octet string default printout */
PROTO_ITEM_SET_HIDDEN(actx->created_item);
- dissect_e212_imsi(parameter_tvb, actx->pinfo, tree, 0, tvb_reported_length(parameter_tvb), FALSE);
+ actx->private_data = wmem_strdup(actx->pinfo->pool,
+ dissect_e212_imsi(parameter_tvb, actx->pinfo, tree,
+ 0, tvb_reported_length(parameter_tvb), FALSE));
+#.FN_BODY LMSI VAL_PTR = &parameter_tvb
+ tvbuff_t *parameter_tvb;
+%(DEFAULT_BODY)s
+ if (parameter_tvb) {
+ actx->private_data = tvb_bytes_to_str(actx->pinfo->pool, parameter_tvb, 0, tvb_captured_length(parameter_tvb));
+ }
#.FN_BODY TBCD-STRING VAL_PTR = &parameter_tvb
tvbuff_t *parameter_tvb;
@@ -344,44 +353,113 @@ MAP-DialoguePDU B "0.4.0.0.1.1.1.1" "map-DialogueAS"
# Set SENT/RECEIVED depending if ISDN-AddressString or AddressString is used.
# as it's a CHOICE only one is present.
#.FN_BODY SM-RP-OAold/serviceCentreAddressOA
- actx->pinfo->p2p_dir = P2P_DIR_SENT;
+ actx->private_data = NULL;
+ actx->pinfo->p2p_dir = P2P_DIR_SENT;
%(DEFAULT_BODY)s
+ if (actx->private_data) {
+ gsm_map_packet_info_t *gsm_map_pi = gsm_map_get_packet_info(actx->pinfo);
+ gsm_map_pi->rp_oa_id = GSM_MAP_RP_OA_SERVICE_CENTER_ADDRESS;
+ gsm_map_pi->rp_oa_str = (const gchar*)actx->private_data;
+ actx->private_data = NULL;
+ }
#.FN_BODY SM-RP-OA/serviceCentreAddressOA
- actx->pinfo->p2p_dir = P2P_DIR_SENT;
+ actx->private_data = NULL;
+ actx->pinfo->p2p_dir = P2P_DIR_SENT;
%(DEFAULT_BODY)s
+ if (actx->private_data) {
+ gsm_map_packet_info_t *gsm_map_pi = gsm_map_get_packet_info(actx->pinfo);
+ gsm_map_pi->rp_oa_id = GSM_MAP_RP_OA_SERVICE_CENTER_ADDRESS;
+ gsm_map_pi->rp_oa_str = (const gchar*)actx->private_data;
+ actx->private_data = NULL;
+ }
#.FN_BODY SM-RP-DAold/imsi
- actx->pinfo->p2p_dir = P2P_DIR_SENT;
+ actx->private_data = NULL;
+ actx->pinfo->p2p_dir = P2P_DIR_SENT;
%(DEFAULT_BODY)s
+ if (actx->private_data) {
+ gsm_map_packet_info_t *gsm_map_pi = gsm_map_get_packet_info(actx->pinfo);
+ gsm_map_pi->rp_da_id = GSM_MAP_RP_DA_IMSI;
+ gsm_map_pi->rp_da_str = (const gchar*)actx->private_data;
+ actx->private_data = NULL;
+ }
#.FN_BODY SM-RP-DAold/lmsi
- actx->pinfo->p2p_dir = P2P_DIR_SENT;
+ actx->private_data = NULL;
+ actx->pinfo->p2p_dir = P2P_DIR_SENT;
%(DEFAULT_BODY)s
+ if (actx->private_data) {
+ gsm_map_packet_info_t *gsm_map_pi = gsm_map_get_packet_info(actx->pinfo);
+ gsm_map_pi->rp_da_id = GSM_MAP_RP_DA_LMSI;
+ gsm_map_pi->rp_da_str = (const gchar*)actx->private_data;
+ actx->private_data = NULL;
+ }
#.FN_BODY SM-RP-DA/imsi
- actx->pinfo->p2p_dir = P2P_DIR_SENT;
+ actx->private_data = NULL;
+ actx->pinfo->p2p_dir = P2P_DIR_SENT;
%(DEFAULT_BODY)s
+ if (actx->private_data) {
+ gsm_map_packet_info_t *gsm_map_pi = gsm_map_get_packet_info(actx->pinfo);
+ gsm_map_pi->rp_da_id = GSM_MAP_RP_DA_IMSI;
+ gsm_map_pi->rp_da_str = (const gchar*)actx->private_data;
+ actx->private_data = NULL;
+ }
#.FN_BODY SM-RP-DA/lmsi
- actx->pinfo->p2p_dir = P2P_DIR_SENT;
+ actx->private_data = NULL;
+ actx->pinfo->p2p_dir = P2P_DIR_SENT;
%(DEFAULT_BODY)s
+ if (actx->private_data) {
+ gsm_map_packet_info_t *gsm_map_pi = gsm_map_get_packet_info(actx->pinfo);
+ gsm_map_pi->rp_da_id = GSM_MAP_RP_DA_LMSI;
+ gsm_map_pi->rp_da_str = (const gchar*)actx->private_data;
+ actx->private_data = NULL;
+ }
#.FN_BODY SM-RP-OAold/msisdn
-actx->pinfo->p2p_dir = P2P_DIR_RECV;
- %(DEFAULT_BODY)s
+ actx->private_data = NULL;
+ actx->pinfo->p2p_dir = P2P_DIR_RECV;
+%(DEFAULT_BODY)s
+ if (actx->private_data) {
+ gsm_map_packet_info_t *gsm_map_pi = gsm_map_get_packet_info(actx->pinfo);
+ gsm_map_pi->rp_oa_id = GSM_MAP_RP_OA_MSISDN;
+ gsm_map_pi->rp_oa_str = (const gchar*)actx->private_data;
+ actx->private_data = NULL;
+ }
#.FN_BODY SM-RP-OA/msisdn
-actx->pinfo->p2p_dir = P2P_DIR_RECV;
- %(DEFAULT_BODY)s
+ actx->pinfo->p2p_dir = P2P_DIR_RECV;
+%(DEFAULT_BODY)s
+ if (actx->private_data) {
+ gsm_map_packet_info_t *gsm_map_pi = gsm_map_get_packet_info(actx->pinfo);
+ gsm_map_pi->rp_oa_id = GSM_MAP_RP_OA_MSISDN;
+ gsm_map_pi->rp_oa_str = (const gchar*)actx->private_data;
+ actx->private_data = NULL;
+ }
#.FN_BODY SM-RP-DAold/serviceCentreAddressDA
- actx->pinfo->p2p_dir = P2P_DIR_RECV;
+ actx->private_data = NULL;
+ actx->pinfo->p2p_dir = P2P_DIR_RECV;
%(DEFAULT_BODY)s
+ if (actx->private_data) {
+ gsm_map_packet_info_t *gsm_map_pi = gsm_map_get_packet_info(actx->pinfo);
+ gsm_map_pi->rp_da_id = GSM_MAP_RP_DA_SERVICE_CENTER_ADDRESS;
+ gsm_map_pi->rp_da_str = (const gchar*)actx->private_data;
+ actx->private_data = NULL;
+ }
#.FN_BODY SM-RP-DA/serviceCentreAddressDA
- actx->pinfo->p2p_dir = P2P_DIR_RECV;
+ actx->private_data = NULL;
+ actx->pinfo->p2p_dir = P2P_DIR_RECV;
%(DEFAULT_BODY)s
+ if (actx->private_data) {
+ gsm_map_packet_info_t *gsm_map_pi = gsm_map_get_packet_info(actx->pinfo);
+ gsm_map_pi->rp_da_id = GSM_MAP_RP_DA_SERVICE_CENTER_ADDRESS;
+ gsm_map_pi->rp_da_str = (const gchar*)actx->private_data;
+ actx->private_data = NULL;
+ }
#.FN_BODY SignalInfo VAL_PTR = &parameter_tvb
tvbuff_t *parameter_tvb;