aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-rrc.c
diff options
context:
space:
mode:
authorDarien Spencer <cusneud@mail.com>2017-08-27 22:10:48 +0300
committerPascal Quantin <pascal.quantin@gmail.com>2017-09-15 20:39:34 +0000
commit875a46d1b54da3b2dcf0deb586de7745cabfa51f (patch)
tree8584b432d19117d825cbf3b3c0b74ad8d3f6267a /epan/dissectors/packet-rrc.c
parente84c2e03e47cac0682ba03323ee0d7f6ff7d7b10 (diff)
UMTS RRC: Call E.212 Dissector
Calling E.212 dissector for MCC-MNC pairs/IMSIs found in RRC messages Change-Id: I1cbb4fe552323b65c761cdf7a721e8b93f297106 Reviewed-on: https://code.wireshark.org/review/23520 Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Diffstat (limited to 'epan/dissectors/packet-rrc.c')
-rw-r--r--epan/dissectors/packet-rrc.c182
1 files changed, 145 insertions, 37 deletions
diff --git a/epan/dissectors/packet-rrc.c b/epan/dissectors/packet-rrc.c
index 0868635949..a8f5430784 100644
--- a/epan/dissectors/packet-rrc.c
+++ b/epan/dissectors/packet-rrc.c
@@ -98,6 +98,8 @@ typedef struct umts_rrc_private_data_t
guint32 current_u_rnti;
guint32 scrambling_code;
enum nas_sys_info_gsm_map cn_domain;
+ wmem_strbuf_t* digits_strbuf; /* A collection of digits in a string. Used for reconstructing IMSIs or MCC-MNC pairs */
+ gboolean digits_strbuf_parsing_failed_flag; /* Whether an error occured when creating the IMSI/MCC-MNC pair string */
guint32 rbid;
guint32 rlc_ciphering_sqn; /* Sequence number where ciphering starts in a given bearer */
rrc_ciphering_info* ciphering_info;
@@ -189,6 +191,30 @@ static void private_data_set_cn_domain(asn1_ctx_t *actx, enum nas_sys_info_gsm_m
private_data->cn_domain = cn_domain;
}
+static wmem_strbuf_t* private_data_get_digits_strbuf(asn1_ctx_t *actx)
+{
+ umts_rrc_private_data_t *private_data = (umts_rrc_private_data_t*)umts_rrc_get_private_data(actx);
+ return private_data->digits_strbuf;
+}
+
+static void private_data_set_digits_strbuf(asn1_ctx_t *actx, wmem_strbuf_t* digits_strbuf)
+{
+ umts_rrc_private_data_t *private_data = (umts_rrc_private_data_t*)umts_rrc_get_private_data(actx);
+ private_data->digits_strbuf = digits_strbuf;
+}
+
+static gboolean private_data_get_digits_strbuf_parsing_failed_flag(asn1_ctx_t *actx)
+{
+ umts_rrc_private_data_t *private_data = (umts_rrc_private_data_t*)umts_rrc_get_private_data(actx);
+ return private_data->digits_strbuf_parsing_failed_flag;
+}
+
+static void private_data_set_digits_strbuf_parsing_failed_flag(asn1_ctx_t *actx, gboolean digits_strbuf_parsing_failed_flag)
+{
+ umts_rrc_private_data_t *private_data = (umts_rrc_private_data_t*)umts_rrc_get_private_data(actx);
+ private_data->digits_strbuf_parsing_failed_flag = digits_strbuf_parsing_failed_flag;
+}
+
static guint32 private_data_get_rbid(asn1_ctx_t *actx)
{
umts_rrc_private_data_t *private_data = (umts_rrc_private_data_t*)umts_rrc_get_private_data(actx);
@@ -451,7 +477,7 @@ static int dissect_SysInfoType22_PDU(tvbuff_t *tvb, packet_info *pinfo, proto_tr
#define maxWLANs 64
/*--- End of included file: packet-rrc-val.h ---*/
-#line 248 "./asn1/rrc/packet-rrc-template.c"
+#line 274 "./asn1/rrc/packet-rrc-template.c"
/* Initialize the protocol and registered fields */
int proto_rrc = -1;
@@ -11290,7 +11316,7 @@ static int hf_rrc_GsmSecurityCapability_a5_2 = -1;
static int hf_rrc_GsmSecurityCapability_a5_1 = -1;
/*--- End of included file: packet-rrc-hf.c ---*/
-#line 253 "./asn1/rrc/packet-rrc-template.c"
+#line 279 "./asn1/rrc/packet-rrc-template.c"
/* Initialize the subtree pointers */
static int ett_rrc = -1;
@@ -18194,7 +18220,7 @@ static gint ett_rrc_UE_RadioAccessCapability_r6 = -1;
static gint ett_rrc_UL_RFC3095_Context = -1;
/*--- End of included file: packet-rrc-ett.c ---*/
-#line 258 "./asn1/rrc/packet-rrc-template.c"
+#line 284 "./asn1/rrc/packet-rrc-template.c"
static gint ett_rrc_eutraFeatureGroupIndicators = -1;
static gint ett_rrc_cn_CommonGSM_MAP_NAS_SysInfo = -1;
@@ -18550,7 +18576,7 @@ dissect_rrc_ActivationTime(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _
static int
dissect_rrc_RB_Identity(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 1078 "./asn1/rrc/rrc.cnf"
+#line 1157 "./asn1/rrc/rrc.cnf"
guint32 rbid;
offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index,
1U, 32U, &rbid, FALSE);
@@ -18567,7 +18593,7 @@ private_data_set_rbid(actx, rbid);
static int
dissect_rrc_RLC_SequenceNumber(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 1084 "./asn1/rrc/rrc.cnf"
+#line 1163 "./asn1/rrc/rrc.cnf"
guint32 rlc_ciphering_sqn;
offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index,
0U, 4095U, &rlc_ciphering_sqn, FALSE);
@@ -18588,7 +18614,7 @@ static const per_sequence_t RB_ActivationTimeInfo_sequence[] = {
static int
dissect_rrc_RB_ActivationTimeInfo(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 1050 "./asn1/rrc/rrc.cnf"
+#line 1129 "./asn1/rrc/rrc.cnf"
fp_info *fpinf;
rlc_info *rlcinf;
rrc_ciphering_info *ciphering_info;
@@ -18657,7 +18683,7 @@ dissect_rrc_CipheringModeInfo(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *act
static int
dissect_rrc_SRNC_Identity(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 791 "./asn1/rrc/rrc.cnf"
+#line 870 "./asn1/rrc/rrc.cnf"
tvbuff_t * s_rnc_id_tvb = NULL;
offset = dissect_per_bit_string(tvb, offset, actx, tree, hf_index,
12, 12, FALSE, &s_rnc_id_tvb, NULL);
@@ -18675,7 +18701,7 @@ dissect_rrc_SRNC_Identity(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U
static int
dissect_rrc_S_RNTI(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 798 "./asn1/rrc/rrc.cnf"
+#line 877 "./asn1/rrc/rrc.cnf"
tvbuff_t * s_rnti_tvb = NULL;
offset = dissect_per_bit_string(tvb, offset, actx, tree, hf_index,
20, 20, FALSE, &s_rnti_tvb, NULL);
@@ -18698,7 +18724,7 @@ static const per_sequence_t U_RNTI_sequence[] = {
static int
dissect_rrc_U_RNTI(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 805 "./asn1/rrc/rrc.cnf"
+#line 884 "./asn1/rrc/rrc.cnf"
private_data_set_s_rnc_id(actx, 0);
private_data_set_s_rnti(actx, 0);
guint32 s_rnc_id;
@@ -18734,8 +18760,31 @@ dissect_rrc_U_RNTI(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, prot
static int
dissect_rrc_Digit(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
+#line 755 "./asn1/rrc/rrc.cnf"
+ guint32 digit;
+ gchar digit_char;
+ wmem_strbuf_t* digits_strbuf; /* The string of either an IMSI or a MCC-MNC pair */
offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index,
- 0U, 9U, NULL, FALSE);
+ 0U, 9U, &digit, FALSE);
+
+
+ if(private_data_get_digits_strbuf_parsing_failed_flag(actx)) {
+ return offset;
+ }
+
+ digits_strbuf = private_data_get_digits_strbuf(actx);
+ if(digit > 9) {
+ private_data_set_digits_strbuf_parsing_failed_flag(actx, TRUE);
+ return offset;
+ }
+
+ /* Converting to the matching gchar */
+ digit_char = (gchar)(digit + '0');
+
+ /* Appending to the digits string */
+ wmem_strbuf_append_c(digits_strbuf, digit_char);
+
+
return offset;
}
@@ -18777,9 +18826,39 @@ static const per_sequence_t PLMN_Identity_sequence[] = {
static int
dissect_rrc_PLMN_Identity(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
+#line 698 "./asn1/rrc/rrc.cnf"
+ wmem_strbuf_t* mcc_mnc_strbuf;
+ guint32 string_len;
+ gchar* mcc_mnc_string;
+ tvbuff_t* mcc_mnc_tvb;
+
+ /* Reset the digits string in the private data struct */
+ /* Maximal length: 6 = 3 digits MCC + 3 digits MNC + trailing '\0'*/
+ mcc_mnc_strbuf = wmem_strbuf_sized_new(actx->pinfo->pool,7,7);
+ private_data_set_digits_strbuf(actx, mcc_mnc_strbuf);
+ /* Reset parsing failure flag*/
+ private_data_set_digits_strbuf_parsing_failed_flag(actx, FALSE);
offset = dissect_per_sequence(tvb, offset, actx, tree, hf_index,
ett_rrc_PLMN_Identity, PLMN_Identity_sequence);
+ /* Check for parsing errors */
+ if(private_data_get_digits_strbuf_parsing_failed_flag(actx)) {
+ return offset;
+ }
+
+ /* Extracing the string collected in the strbuf */
+ string_len = (guint32)wmem_strbuf_get_len(mcc_mnc_strbuf);
+ mcc_mnc_string = wmem_strbuf_finalize(mcc_mnc_strbuf);
+
+ /* Creating TVB from extracted string*/
+ mcc_mnc_tvb = tvb_new_child_real_data(tvb, (guint8*)mcc_mnc_string, string_len, string_len);
+ add_new_data_source(actx->pinfo, mcc_mnc_tvb, "MCC-MNC");
+
+ /* Calling E.212 */
+ dissect_e212_mcc_mnc_in_utf8_address(mcc_mnc_tvb, actx->pinfo, tree, 0);
+
+
+
return offset;
}
@@ -18787,7 +18866,7 @@ dissect_rrc_PLMN_Identity(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U
static int
dissect_rrc_NAS_SystemInformationGSM_MAP(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 759 "./asn1/rrc/rrc.cnf"
+#line 838 "./asn1/rrc/rrc.cnf"
tvbuff_t *nas_sys_info_gsm_map_tvb = NULL;
guint32 length;
enum nas_sys_info_gsm_map cn_domain;
@@ -18830,7 +18909,7 @@ dissect_rrc_NAS_SystemInformationGSM_MAP(tvbuff_t *tvb _U_, int offset _U_, asn1
static int
dissect_rrc_T_cn_CommonGSM_MAP_NAS_SysInfo(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 743 "./asn1/rrc/rrc.cnf"
+#line 822 "./asn1/rrc/rrc.cnf"
private_data_set_cn_domain(actx, RRC_NAS_SYS_INFO_CN_COMMON);
offset = dissect_rrc_NAS_SystemInformationGSM_MAP(tvb, offset, actx, tree, hf_index);
@@ -18850,7 +18929,7 @@ static const value_string rrc_CN_DomainIdentity_vals[] = {
static int
dissect_rrc_CN_DomainIdentity(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 736 "./asn1/rrc/rrc.cnf"
+#line 815 "./asn1/rrc/rrc.cnf"
guint32 nas_sys_info;
offset = dissect_per_enumerated(tvb, offset, actx, tree, hf_index,
2, &nas_sys_info, FALSE, 0, NULL);
@@ -22509,7 +22588,7 @@ dissect_rrc_SSDT_UL(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, pro
static int
dissect_rrc_CellIdentity(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 904 "./asn1/rrc/rrc.cnf"
+#line 983 "./asn1/rrc/rrc.cnf"
tvbuff_t * cell_id_tvb = NULL;
proto_item *temp_ti;
proto_tree *cell_identity_tree;
@@ -22734,7 +22813,7 @@ dissect_rrc_T_r3(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_
static int
dissect_rrc_H_RNTI(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 992 "./asn1/rrc/rrc.cnf"
+#line 1071 "./asn1/rrc/rrc.cnf"
tvbuff_t *hrnti_tvb;
struct rrc_info *rrcinf;
offset = dissect_per_bit_string(tvb, offset, actx, tree, hf_index,
@@ -22743,7 +22822,7 @@ dissect_rrc_H_RNTI(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, prot
-#line 997 "./asn1/rrc/rrc.cnf"
+#line 1076 "./asn1/rrc/rrc.cnf"
rrcinf = (struct rrc_info *)p_get_proto_data(wmem_file_scope(), actx->pinfo, proto_rrc, 0);
if (!rrcinf) {
rrcinf = wmem_new0(wmem_file_scope(), struct rrc_info);
@@ -22769,7 +22848,7 @@ dissect_rrc_E_RNTI(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, prot
static int
dissect_rrc_T_cn_CommonGSM_MAP_NAS_SysInfo_01(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 747 "./asn1/rrc/rrc.cnf"
+#line 826 "./asn1/rrc/rrc.cnf"
private_data_set_cn_domain(actx, RRC_NAS_SYS_INFO_CN_COMMON);
offset = dissect_rrc_NAS_SystemInformationGSM_MAP(tvb, offset, actx, tree, hf_index);
@@ -28243,7 +28322,7 @@ dissect_rrc_ScramblingCodeType(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *ac
static int
dissect_rrc_UL_ScramblingCode(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 899 "./asn1/rrc/rrc.cnf"
+#line 978 "./asn1/rrc/rrc.cnf"
guint32 scrambling_code;
offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index,
0U, 16777215U, &scrambling_code, FALSE);
@@ -38988,7 +39067,7 @@ dissect_rrc_CellChangeOrderFromUTRAN(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx
static int
dissect_rrc_C_RNTI(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 830 "./asn1/rrc/rrc.cnf"
+#line 909 "./asn1/rrc/rrc.cnf"
fp_info *fpinf = NULL;
umts_mac_info *macinf = NULL;
rlc_info *rlcinf = NULL;
@@ -46096,7 +46175,7 @@ dissect_rrc_RLC_Info_r5(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_,
static int
dissect_rrc_MAC_d_FlowIdentity(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 989 "./asn1/rrc/rrc.cnf"
+#line 1068 "./asn1/rrc/rrc.cnf"
offset = dissect_per_constrained_integer(tvb, offset, actx, tree, hf_index,
0U, 7U, &flowd, FALSE);
@@ -46144,7 +46223,7 @@ static const per_choice_t DL_TransportChannelType_r5_choice[] = {
static int
dissect_rrc_DL_TransportChannelType_r5(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 918 "./asn1/rrc/rrc.cnf"
+#line 997 "./asn1/rrc/rrc.cnf"
/*Here we try to figure out which HS-DSCH channels are multiplexed*/
guint *flowd_p;
guint *cur_val=NULL;
@@ -49618,7 +49697,7 @@ static const per_choice_t DL_TransportChannelType_r7_choice[] = {
static int
dissect_rrc_DL_TransportChannelType_r7(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 953 "./asn1/rrc/rrc.cnf"
+#line 1032 "./asn1/rrc/rrc.cnf"
/*Here we try to figure out which HS-DSCH channels are multiplexed*/
guint *flowd_p;
guint *cur_val=NULL;
@@ -90196,7 +90275,7 @@ static const value_string rrc_ReleaseCause_vals[] = {
static int
dissect_rrc_ReleaseCause(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 1106 "./asn1/rrc/rrc.cnf"
+#line 1185 "./asn1/rrc/rrc.cnf"
guint32 value;
offset = dissect_per_enumerated(tvb, offset, actx, tree, hf_index,
8, &value, FALSE, 0, NULL);
@@ -95777,7 +95856,7 @@ dissect_rrc_UE_ConnTimersAndConstants(tvbuff_t *tvb _U_, int offset _U_, asn1_ct
static int
dissect_rrc_T_cn_CommonGSM_MAP_NAS_SysInfo_02(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 751 "./asn1/rrc/rrc.cnf"
+#line 830 "./asn1/rrc/rrc.cnf"
private_data_set_cn_domain(actx, RRC_NAS_SYS_INFO_CN_COMMON);
offset = dissect_rrc_NAS_SystemInformationGSM_MAP(tvb, offset, actx, tree, hf_index);
@@ -98444,7 +98523,7 @@ dissect_rrc_T_r8_04(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, pro
static int
dissect_rrc_T_ims_Information(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 698 "./asn1/rrc/rrc.cnf"
+#line 777 "./asn1/rrc/rrc.cnf"
tvbuff_t *imsInformation_tvb=NULL;
offset = dissect_per_octet_string(tvb, offset, actx, tree, hf_index,
1, 32, FALSE, &imsInformation_tvb);
@@ -99634,7 +99713,7 @@ static const per_choice_t DL_DCCH_MessageType_choice[] = {
static int
dissect_rrc_DL_DCCH_MessageType(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 1089 "./asn1/rrc/rrc.cnf"
+#line 1168 "./asn1/rrc/rrc.cnf"
offset = dissect_per_choice(tvb, offset, actx, tree, hf_index,
ett_rrc_DL_DCCH_MessageType, DL_DCCH_MessageType_choice,
&msg_type);
@@ -99654,7 +99733,7 @@ static const per_sequence_t DL_DCCH_Message_sequence[] = {
static int
dissect_rrc_DL_DCCH_Message(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 1092 "./asn1/rrc/rrc.cnf"
+#line 1171 "./asn1/rrc/rrc.cnf"
offset = dissect_per_sequence(tvb, offset, actx, tree, hf_index,
ett_rrc_DL_DCCH_Message, DL_DCCH_Message_sequence);
@@ -99668,7 +99747,7 @@ dissect_rrc_DL_DCCH_Message(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx
static int
dissect_rrc_START_Value(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 1005 "./asn1/rrc/rrc.cnf"
+#line 1084 "./asn1/rrc/rrc.cnf"
tvbuff_t * start_val;
fp_info *fpinf;
rlc_info *rlcinf;
@@ -114860,10 +114939,39 @@ static const per_sequence_t IMSI_GSM_MAP_sequence_of[1] = {
static int
dissect_rrc_IMSI_GSM_MAP(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
+#line 727 "./asn1/rrc/rrc.cnf"
+ wmem_strbuf_t* imsi_strbuf;
+ guint32 string_len;
+ gchar* imsi_string;
+ tvbuff_t* imsi_tvb;
+
+ /* Reset the digits string in the private data struct */
+ imsi_strbuf = wmem_strbuf_sized_new(actx->pinfo->pool,16,16);
+ private_data_set_digits_strbuf(actx, imsi_strbuf);
+ /* Reset parsing failure flag*/
+ private_data_set_digits_strbuf_parsing_failed_flag(actx, FALSE);
offset = dissect_per_constrained_sequence_of(tvb, offset, actx, tree, hf_index,
ett_rrc_IMSI_GSM_MAP, IMSI_GSM_MAP_sequence_of,
6, 21, FALSE);
+ /* Check for parsing errors */
+ if(private_data_get_digits_strbuf_parsing_failed_flag(actx)) {
+ return offset;
+ }
+
+ /* Extracing the string collected in the strbuf */
+ string_len = (guint32)wmem_strbuf_get_len(imsi_strbuf);
+ imsi_string = wmem_strbuf_finalize(imsi_strbuf);
+
+ /* Creating TVB from extracted string*/
+ imsi_tvb = tvb_new_child_real_data(tvb, (guint8*)imsi_string, string_len, string_len);
+ add_new_data_source(actx->pinfo, imsi_tvb, "IMSI");
+
+ /* Calling E.212 */
+ dissect_e212_utf8_imsi(imsi_tvb,actx->pinfo,tree,0,string_len);
+
+
+
return offset;
}
@@ -129423,7 +129531,7 @@ static const per_choice_t HandoverToUTRANCommand_choice[] = {
static int
dissect_rrc_HandoverToUTRANCommand(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 1095 "./asn1/rrc/rrc.cnf"
+#line 1174 "./asn1/rrc/rrc.cnf"
offset = dissect_per_choice(tvb, offset, actx, tree, hf_index,
ett_rrc_HandoverToUTRANCommand, HandoverToUTRANCommand_choice,
NULL);
@@ -129564,7 +129672,7 @@ static const per_sequence_t UE_SecurityInformation_sequence[] = {
static int
dissect_rrc_UE_SecurityInformation(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 1098 "./asn1/rrc/rrc.cnf"
+#line 1177 "./asn1/rrc/rrc.cnf"
private_data_set_cn_domain(actx, RRC_NAS_SYS_INFO_CS);
offset = dissect_per_sequence(tvb, offset, actx, tree, hf_index,
ett_rrc_UE_SecurityInformation, UE_SecurityInformation_sequence);
@@ -129967,7 +130075,7 @@ static const per_sequence_t UE_SecurityInformation2_sequence[] = {
static int
dissect_rrc_UE_SecurityInformation2(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 1102 "./asn1/rrc/rrc.cnf"
+#line 1181 "./asn1/rrc/rrc.cnf"
private_data_set_cn_domain(actx, RRC_NAS_SYS_INFO_PS);
offset = dissect_per_sequence(tvb, offset, actx, tree, hf_index,
ett_rrc_UE_SecurityInformation2, UE_SecurityInformation2_sequence);
@@ -150661,7 +150769,7 @@ dissect_rrc_ExtSIBTypeInfoSchedulingInfo_List3(tvbuff_t *tvb _U_, int offset _U_
static int
dissect_rrc_HNBName(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 730 "./asn1/rrc/rrc.cnf"
+#line 809 "./asn1/rrc/rrc.cnf"
tvbuff_t *hnbname_tvb = NULL;
offset = dissect_per_octet_string(tvb, offset, actx, tree, -1,
@@ -151252,7 +151360,7 @@ dissect_rrc_SIB_ReferenceList2(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *ac
static int
dissect_rrc_T_cn_CommonGSM_MAP_NAS_SysInfo_03(tvbuff_t *tvb _U_, int offset _U_, asn1_ctx_t *actx _U_, proto_tree *tree _U_, int hf_index _U_) {
-#line 755 "./asn1/rrc/rrc.cnf"
+#line 834 "./asn1/rrc/rrc.cnf"
private_data_set_cn_domain(actx, RRC_NAS_SYS_INFO_CN_COMMON);
offset = dissect_rrc_NAS_SystemInformationGSM_MAP(tvb, offset, actx, tree, hf_index);
@@ -162967,7 +163075,7 @@ static int dissect_MeasurementReport_PDU(tvbuff_t *tvb _U_, packet_info *pinfo _
/*--- End of included file: packet-rrc-fn.c ---*/
-#line 372 "./asn1/rrc/packet-rrc-template.c"
+#line 398 "./asn1/rrc/packet-rrc-template.c"
static int
@@ -206374,7 +206482,7 @@ void proto_register_rrc(void) {
NULL, HFILL }},
/*--- End of included file: packet-rrc-hfarr.c ---*/
-#line 462 "./asn1/rrc/packet-rrc-template.c"
+#line 488 "./asn1/rrc/packet-rrc-template.c"
{ &hf_test,
{ "RAB Test", "rrc.RAB.test",
FT_UINT8, BASE_DEC, NULL, 0,
@@ -213323,7 +213431,7 @@ void proto_register_rrc(void) {
&ett_rrc_UL_RFC3095_Context,
/*--- End of included file: packet-rrc-ettarr.c ---*/
-#line 512 "./asn1/rrc/packet-rrc-template.c"
+#line 538 "./asn1/rrc/packet-rrc-template.c"
&ett_rrc_eutraFeatureGroupIndicators,
&ett_rrc_cn_CommonGSM_MAP_NAS_SysInfo,
&ett_rrc_ims_info,
@@ -213422,7 +213530,7 @@ void proto_register_rrc(void) {
/*--- End of included file: packet-rrc-dis-reg.c ---*/
-#line 535 "./asn1/rrc/packet-rrc-template.c"
+#line 561 "./asn1/rrc/packet-rrc-template.c"