HACK: 2nd try to match RowsetProperties
[wireshark-wip.git] / epan / dissectors / packet-bssgp.c
blobdf18cf9214832bd6d7628227c35cde89ac31ddc4
1 /* packet-bssgp.c
2 * Routines for Base Station Subsystem GPRS Protocol dissection
3 * Copyright 2000, Susanne Edlund <susanne.edlund@ericsson.com>
5 * $Id$
7 * Wireshark - Network traffic analyzer
8 * By Gerald Combs <gerald@wireshark.org>
9 * Copyright 1998 Gerald Combs
11 * This program is free software; you can redistribute it and/or
12 * modify it under the terms of the GNU General Public License
13 * as published by the Free Software Foundation; either version 2
14 * of the License, or (at your option) any later version.
16 * This program is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU General Public License for more details.
21 * You should have received a copy of the GNU General Public License
22 * along with this program; if not, write to the Free Software
23 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
26 /* 3GPP TS 48.018 V 6.5.0 (2004-07) Release 6 */
28 #include "config.h"
30 #include <glib.h>
31 #include <epan/packet.h>
32 #include <epan/expert.h>
33 #include <prefs.h>
34 #include <epan/asn1.h>
36 #include "packet-bssgp.h"
37 #include "packet-e212.h"
38 #include "packet-gsm_a_common.h"
39 #include "packet-ranap.h"
40 #include "packet-rrc.h"
41 #include "packet-lte-rrc.h"
42 #include "packet-s1ap.h"
44 /* #define BSSGP_DEBUG */
46 * TS 48.018 V6.6.0 (2004-11) says, of information elements:
48 * Refer to General Structure Of The Information Elements/3GPP TS 48.016.
50 * TS 48.016 V9.0.0 (2010-02), in that section, says, of information elements:
52 * When a field extends over more than one octet, the order of bit
53 * values progressively decreases as the octet number increases.
54 * The least significant bit of the field is represented by the
55 * lowest numbered bit of the highest numbered octet of the field.
57 * which sure sounds little-endian.
59 * [
60 * Later comment:
61 * Actually: To me. the above reads as being BIG_ENDIAN.
62 * IOW: if bytes are numbered from 0 to n, then the n'th byte
63 * ("highest numbered octet") has the least significant bit.
64 * ]
66 * However, for some not-entirely-obvious reason, BSSGP_LITTLE_ENDIAN, which
67 * was passed to proto_tree_add_item() as the byte-order argument, was
68 * defined as FALSE - which meant big-endian.
70 * For now, we'll use ENC_BIG_ENDIAN, now that we have ENC_BIG_ENDIAN and
71 * REP_LITTLE_ENDIAN definitions.
74 #define BSSGP_SEP ", "
76 void proto_register_bssgp(void);
77 void proto_reg_handoff_bssgp(void);
79 static int bssgp_decode_nri = 0;
80 static guint bssgp_nri_length = 4;
82 static guint8 g_pdu_type, g_rim_application_identity;
83 static proto_tree *gparent_tree;
84 static dissector_handle_t llc_handle;
85 static dissector_handle_t rrlp_handle;
86 static dissector_handle_t data_handle;
88 static module_t *bssgp_module;
89 static dissector_table_t diameter_3gpp_avp_dissector_table;
91 /* Initialize the protocol and registered fields */
92 static int proto_bssgp = -1;
93 static int hf_bssgp_msg_type = -1;
94 int hf_bssgp_elem_id = -1;
95 static int hf_bssgp_ci = -1;
96 static int hf_bssgp_flush_action = -1;
97 static int hf_bssgp_llc_frames_disc = -1;
98 static int hf_bssgp_ra_discriminator = -1;
99 static int hf_bssgp_rim_app_id = -1;
100 static int hf_bssgp_rim_seq_no = -1;
101 static int hf_bssgp_rat_discriminator = -1;
102 static int hf_bssgp_nacc_cause = -1;
103 static int hf_bssgp_s13_cause = -1;
104 static int hf_bssgp_mbms_data_ch_cause = -1;
105 static int hf_bssgp_utra_si_cause = -1;
106 static int hf_bssgp_num_si_psi = -1;
107 static int hf_bssgp_si_psi_type = -1;
108 static int hf_bssgp_ran_inf_req_pdu_t_ext_c = -1;
109 static int hf_bssgp_ran_inf_pdu_t_ext_c = -1;
110 static int hf_bssgp_rim_pdu_ind_ack = -1;
111 static int hf_bssgp_rim_proto_ver_no = -1;
112 static int hf_bssgp_bss_area_ind = -1;
113 static int hf_bssgp_bvci = -1;
114 static int hf_bssgp_bmax = -1;
115 static int hf_bssgp_r = -1;
116 static int hf_bssgp_r_pfc = -1;
117 static int hf_bssgp_bucket_size = -1;
118 static int hf_bssgp_bmax_pfc = -1;
119 static int hf_bssgp_omc_id = -1;
120 static int hf_bssgp_nsei = -1;
121 static int hf_bssgp_rrlp_flag1 = -1;
123 static int hf_bssgp_delay_val = -1;
124 static int hf_bssgp_cause = -1;
125 static int hf_bssgp_peak_rate_gran = -1;
126 static int hf_bssgp_cr_bit = -1;
127 static int hf_bssgp_t_bit = -1;
128 static int hf_bssgp_a_bit = -1;
129 static int hf_bssgp_ra_cause = -1;
130 static int hf_bssgp_ra_cap_upd_cause = -1;
131 static int hf_bssgp_r_default_ms = -1;
132 static int hf_bssgp_suspend_ref_no = -1;
133 static int hf_bssgp_tag = -1;
134 static int hf_bssgp_trace_ref = -1;
135 static int hf_bssgp_trigger_id = -1;
136 static int hf_bssgp_transaction_id = -1;
137 static int hf_bssgp_no_of_oct = -1;
138 static int hf_bssgp_unit_val = -1;
139 static int hf_bssgp_gprs_timer = -1;
140 static int hf_bssgp_mbms = -1;
141 static int hf_bssgp_EnhancedRadioStatus = -1;
142 static int hf_bssgp_pfcfc = -1;
143 static int hf_bssgp_rim = -1;
144 static int hf_bssgp_lcs = -1;
145 static int hf_bssgp_inr = -1;
146 static int hf_bssgp_cbl = -1;
147 static int hf_bssgp_pfc = -1;
148 static int hf_bssgp_bucket_full_ratio = -1;
149 static int hf_bssgp_b_pfc = -1;
151 static int hf_bssgp_precedence = -1;
152 static int hf_bssgp_serv_utran_cco = -1;
153 static int hf_bssgp_mbms_session_id = -1;
154 static int hf_bssgp_mbms_cause = -1;
155 static int hf_bssgp_mbms_stop_cause = -1;
156 static int hf_bssgp_mbms_num_ra_ids = -1;
157 static int hf_bssgp_session_inf = -1;
158 static int hf_bssgp_gb_if = -1;
159 static int hf_bssgp_ps_ho = -1;
160 static int hf_bssgp_src_to_trg_transp_cont = -1;
161 static int hf_bssgp_trg_to_src_transp_cont = -1;
162 static int hf_bssgp_rnc_id = -1;
163 static int hf_bssgp_page_mode = -1;
164 static int hf_bssgp_container_id = -1;
165 static int hf_bssgp_global_tfi = -1;
166 static int hf_bssgp_ul_tfi = -1;
167 static int hf_bssgp_dl_tfi = -1;
168 static int hf_bssgp_time_to_MBMS_data_tran = -1;
169 static int hf_bssgp_mbms_session_rep_no = -1;
170 static int hf_bssgp_ps_ho_cmd = -1;
171 static int hf_bssgp_sipsi = -1;
172 static int hf_bssgp_type = -1;
173 static int hf_bssgp_cs_indication = -1;
174 static int hf_bssgp_flow_control_gran = -1;
175 static int hf_bssgp_serv_eutran_cco = -1;
176 static int hf_bssgp_sub_prof_id_f_rat_freq_prio = -1;
177 static int hf_bssgp_eutran_irat_ho_inf_req = -1;
178 static int hf_bssgp_irat_ho_inf_req = -1;
180 static int hf_bssgp_rel_int_rat_ho_inf_ind = -1;
181 static int hf_bssgp_csg_id = -1;
182 static int hf_bssgp_cell_acc_mode = -1;
183 static int hf_bssgp_redir_complete_outcome = -1;
184 static int hf_bssgp_redir_indiction_reroute_reject_cause = -1;
185 static int hf_bssgp_unconfim_send_state_var = -1;
186 static int hf_bssgp_Global_ENB_ID_PDU = -1;
187 static int hf_bssgp_SONtransferRequestContainer_PDU = -1;
188 static int hf_bssgp_selected_plmn_id = -1;
190 /* Initialize the subtree pointers */
191 static gint ett_bssgp = -1;
192 static gint ett_bssgp_new = -1;
193 static gint ett_bssgp_pfcs_to_be_set_up_list = -1;
194 static gint ett_bssgp_pfcs_to_be_set_up_list_pft = -1;
195 static gint ett_bssgp_pfcs_to_be_set_up_list_abqp = -1;
196 static gint ett_bssgp_pfcs_to_be_set_up_list_arp = -1;
197 static gint ett_bssgp_pfcs_to_be_set_up_list_t10 = -1;
198 static gint ett_bssgp_list_of_setup_pfcs = -1;
199 static gint ett_bssgp_pfc_flow_control_parameters_pfc = -1;
200 static gint ett_bssgp_ra_id = -1;
202 static expert_field ei_bssgp_extraneous_data = EI_INIT;
204 /* PDU type coding, v6.5.0, table 11.3.26, p 80 */
205 #define BSSGP_PDU_DL_UNITDATA 0x00
206 #define BSSGP_PDU_UL_UNITDATA 0x01
207 #define BSSGP_PDU_RA_CAPABILITY 0x02
208 #define BSSGP_PDU_PTM_UNITDATA 0x03
209 #define BSSGP_PDU_DL_MBMS_UNITDATA 0x04
210 #define BSSGP_PDU_UL_MBMS_UNITDATA 0x05
211 #define BSSGP_PDU_PAGING_PS 0x06
212 #define BSSGP_PDU_PAGING_CS 0x07
213 #define BSSGP_PDU_RA_CAPABILITY_UPDATE 0x08
214 #define BSSGP_PDU_RA_CAPABILITY_UPDATE_ACK 0x09
215 #define BSSGP_PDU_RADIO_STATUS 0x0a
216 #define BSSGP_PDU_SUSPEND 0x0b
217 #define BSSGP_PDU_SUSPEND_ACK 0x0c
218 #define BSSGP_PDU_SUSPEND_NACK 0x0d
219 #define BSSGP_PDU_RESUME 0x0e
220 #define BSSGP_PDU_RESUME_ACK 0x0f
221 #define BSSGP_PDU_RESUME_NACK 0x10
223 #define BSSGP_PDU_RESERVED_0X11 0x11
224 #define BSSGP_PDU_RESERVED_0X12 0x12
225 #define BSSGP_PDU_RESERVED_0X13 0x13
226 #define BSSGP_PDU_RESERVED_0X14 0x14
227 #define BSSGP_PDU_RESERVED_0X15 0x15
228 #define BSSGP_PDU_RESERVED_0X16 0x16
229 #define BSSGP_PDU_RESERVED_0X17 0x17
230 #define BSSGP_PDU_RESERVED_0X18 0x18
231 #define BSSGP_PDU_RESERVED_0X19 0x19
232 #define BSSGP_PDU_RESERVED_0X1A 0x1a
233 #define BSSGP_PDU_RESERVED_0X1B 0x1b
234 #define BSSGP_PDU_RESERVED_0X1C 0x1c
235 #define BSSGP_PDU_RESERVED_0X1D 0x1d
236 #define BSSGP_PDU_RESERVED_0X1E 0x1e
237 #define BSSGP_PDU_RESERVED_0X1F 0x1f
239 #define BSSGP_PDU_BVC_BLOCK 0x20
240 #define BSSGP_PDU_BVC_BLOCK_ACK 0x21
241 #define BSSGP_PDU_BVC_RESET 0x22
242 #define BSSGP_PDU_BVC_RESET_ACK 0x23
243 #define BSSGP_PDU_BVC_UNBLOCK 0x24
244 #define BSSGP_PDU_BVC_UNBLOCK_ACK 0x25
245 #define BSSGP_PDU_FLOW_CONTROL_BVC 0x26
246 #define BSSGP_PDU_FLOW_CONTROL_BVC_ACK 0x27
247 #define BSSGP_PDU_FLOW_CONTROL_MS 0x28
248 #define BSSGP_PDU_FLOW_CONTROL_MS_ACK 0x29
249 #define BSSGP_PDU_FLUSH_LL 0x2a
250 #define BSSGP_PDU_FLUSH_LL_ACK 0x2b
251 #define BSSGP_PDU_LLC_DISCARDED 0x2c
252 #define BSSGP_PDU_FLOW_CONTROL_PFC 0x2d
253 #define BSSGP_PDU_FLOW_CONTROL_PFC_ACK 0x2e
255 #define BSSGP_PDU_RESERVED_0X2F 0x2f
256 #define BSSGP_PDU_RESERVED_0X30 0x30
257 #define BSSGP_PDU_RESERVED_0X31 0x31
258 #define BSSGP_PDU_RESERVED_0X32 0x32
259 #define BSSGP_PDU_RESERVED_0X33 0x33
260 #define BSSGP_PDU_RESERVED_0X34 0x34
261 #define BSSGP_PDU_RESERVED_0X35 0x35
262 #define BSSGP_PDU_RESERVED_0X36 0x36
263 #define BSSGP_PDU_RESERVED_0X37 0x37
264 #define BSSGP_PDU_RESERVED_0X38 0x38
265 #define BSSGP_PDU_RESERVED_0X39 0x39
266 #define BSSGP_PDU_RESERVED_0X3A 0x3a
267 #define BSSGP_PDU_RESERVED_0X3B 0x3b
268 #define BSSGP_PDU_RESERVED_0X3C 0x3c
269 #define BSSGP_PDU_RESERVED_0X3D 0x3d
270 #define BSSGP_PDU_RESERVED_0X3E 0x3e
271 #define BSSGP_PDU_RESERVED_0X3F 0x3f
273 #define BSSGP_PDU_SGSN_INVOKE_TRACE 0x40
274 #define BSSGP_PDU_STATUS 0x41
276 #define BSSGP_PDU_RESERVED_0X42 0x42
277 #define BSSGP_PDU_RESERVED_0X43 0x43
278 #define BSSGP_PDU_RESERVED_0X44 0x44
279 #define BSSGP_PDU_RESERVED_0X45 0x45
280 #define BSSGP_PDU_RESERVED_0X46 0x46
281 #define BSSGP_PDU_RESERVED_0X47 0x47
282 #define BSSGP_PDU_RESERVED_0X48 0x48
283 #define BSSGP_PDU_RESERVED_0X49 0x49
284 #define BSSGP_PDU_RESERVED_0X4A 0x4a
285 #define BSSGP_PDU_RESERVED_0X4B 0x4b
286 #define BSSGP_PDU_RESERVED_0X4C 0x4c
287 #define BSSGP_PDU_RESERVED_0X4D 0x4d
288 #define BSSGP_PDU_RESERVED_0X4E 0x4e
289 #define BSSGP_PDU_RESERVED_0X4F 0x4f
291 #define BSSGP_PDU_DOWNLOAD_BSS_PFC 0x50
292 #define BSSGP_PDU_CREATE_BSS_PFC 0x51
293 #define BSSGP_PDU_CREATE_BSS_PFC_ACK 0x52
294 #define BSSGP_PDU_CREATE_BSS_PFC_NACK 0x53
295 #define BSSGP_PDU_MODIFY_BSS_PFC 0x54
296 #define BSSGP_PDU_MODIFY_BSS_PFC_ACK 0x55
297 #define BSSGP_PDU_DELETE_BSS_PFC 0x56
298 #define BSSGP_PDU_DELETE_BSS_PFC_ACK 0x57
299 #define BSSGP_PDU_DELETE_BSS_PFC_REQ 0x58
300 #define BSSGP_PDU_PS_HANDOVER_REQUIRED 0x59
301 #define BSSGP_PDU_PS_HANDOVER_REQUIRED_ACK 0x5a
302 #define BSSGP_PDU_PS_HANDOVER_REQUIRED_NACK 0x5b
303 #define BSSGP_PDU_PS_HANDOVER_REQUEST 0x5c
304 #define BSSGP_PDU_PS_HANDOVER_REQUEST_ACK 0x5d
305 #define BSSGP_PDU_PS_HANDOVER_REQUEST_NACK 0x5e
307 #define BSSGP_PDU_RESERVED_0X5F 0x5f
309 #define BSSGP_PDU_PERFORM_LOCATION_REQUEST 0x60
310 #define BSSGP_PDU_PERFORM_LOCATION_RESPONSE 0x61
311 #define BSSGP_PDU_PERFORM_LOCATION_ABORT 0x62
312 #define BSSGP_PDU_POSITION_COMMAND 0x63
313 #define BSSGP_PDU_POSITION_RESPONSE 0x64
315 #define BSSGP_PDU_RESERVED_0X65 0x65
316 #define BSSGP_PDU_RESERVED_0X66 0x66
317 #define BSSGP_PDU_RESERVED_0X67 0x67
318 #define BSSGP_PDU_RESERVED_0X68 0x68
319 #define BSSGP_PDU_RESERVED_0X69 0x69
320 #define BSSGP_PDU_RESERVED_0X6A 0x6a
321 #define BSSGP_PDU_RESERVED_0X6B 0x6b
322 #define BSSGP_PDU_RESERVED_0X6C 0x6c
323 #define BSSGP_PDU_RESERVED_0X6D 0x6d
324 #define BSSGP_PDU_RESERVED_0X6E 0x6e
325 #define BSSGP_PDU_RESERVED_0X6F 0x6f
327 #define BSSGP_PDU_RAN_INFORMATION 0x70
328 #define BSSGP_PDU_RAN_INFORMATION_REQUEST 0x71
329 #define BSSGP_PDU_RAN_INFORMATION_ACK 0x72
330 #define BSSGP_PDU_RAN_INFORMATION_ERROR 0x73
331 #define BSSGP_PDU_RAN_INFORMATION_APP_ERROR 0x74
333 #define BSSGP_PDU_RESERVED_0X75 0x75
334 #define BSSGP_PDU_RESERVED_0X76 0x76
335 #define BSSGP_PDU_RESERVED_0X77 0x77
336 #define BSSGP_PDU_RESERVED_0X78 0x78
337 #define BSSGP_PDU_RESERVED_0X79 0x79
338 #define BSSGP_PDU_RESERVED_0X7A 0x7a
339 #define BSSGP_PDU_RESERVED_0X7B 0x7b
340 #define BSSGP_PDU_RESERVED_0X7C 0x7c
341 #define BSSGP_PDU_RESERVED_0X7D 0x7d
342 #define BSSGP_PDU_RESERVED_0X7E 0x7e
343 #define BSSGP_PDU_RESERVED_0X7F 0x7f
345 #define BSSGP_PDU_MBMS_SESSION_START_REQ 0x80
346 #define BSSGP_PDU_MBMS_SESSION_START_RESP 0x81
347 #define BSSGP_PDU_MBMS_SESSION_STOP_REQ 0x82
348 #define BSSGP_PDU_MBMS_SESSION_STOP_RESP 0x83
349 #define BSSGP_PDU_MBMS_SESSION_UPDATE_REQ 0x84
350 #define BSSGP_PDU_MBMS_SESSION_UPDATE_RESP 0x85
352 #define BSSGP_PDU_RESERVED_0X86 0x86
353 #define BSSGP_PDU_RESERVED_0X87 0x87
354 #define BSSGP_PDU_RESERVED_0X88 0x88
355 #define BSSGP_PDU_RESERVED_0X89 0x89
356 #define BSSGP_PDU_RESERVED_0X8A 0x8a
357 #define BSSGP_PDU_RESERVED_0X8B 0x8b
358 #define BSSGP_PDU_RESERVED_0X8C 0x8c
359 #define BSSGP_PDU_RESERVED_0X8D 0x8d
360 #define BSSGP_PDU_RESERVED_0X8E 0x8e
361 #define BSSGP_PDU_RESERVED_0X8F 0x8f
363 #define BSSGP_PDU_RESERVED_0X90 0x90
364 #define BSSGP_PDU_PS_HANDOVER_COMPLETE 0x91
365 #define BSSGP_PDU_PS_HANDOVER_CANCEL 0x92
366 #define BSSGP_PDU_PS_HANDOVER_COMPLETE_ACK 0x93
369 0x91 PS-HANDOVER-COMPLETE
370 0x92 PS-HANDOVER-CANCEL
371 0x93 PS-HANDOVER-COMPLETE-ACK
374 /* Information element coding, v 6.5.0, table 11.3, p 72 */
375 #define BSSGP_IEI_ALIGNMENT_OCTETS 0x00
376 #define BSSGP_IEI_BMAX_DEFAULT_MS 0x01
377 #define BSSGP_IEI_BSS_AREA_INDICATION 0x02
378 #define BSSGP_IEI_BUCKET_LEAK_RATE 0x03
379 #define BSSGP_IEI_BVCI 0x04
380 #define BSSGP_IEI_BVC_BUCKET_SIZE 0x05
381 #define BSSGP_IEI_BVC_MEASUREMENT 0x06
382 #define BSSGP_IEI_CAUSE 0x07
383 #define BSSGP_IEI_CELL_IDENTIFIER 0x08
384 #define BSSGP_IEI_CHANNEL_NEEDED 0x09
385 #define BSSGP_IEI_DRX_PARAMETERS 0x0a
386 #define BSSGP_IEI_EMLPP_PRIORITY 0x0b
387 #define BSSGP_IEI_FLUSH_ACTION 0x0c
388 #define BSSGP_IEI_IMSI 0x0d
389 #define BSSGP_IEI_LLC_PDU 0x0e
390 #define BSSGP_IEI_LLC_FRAMES_DISCARDED 0x0f
391 #define BSSGP_IEI_LOCATION_AREA 0x10
392 #define BSSGP_IEI_MOBILE_ID 0x11
393 #define BSSGP_IEI_MS_BUCKET_SIZE 0x12
394 #define BSSGP_IEI_MS_RADIO_ACCESS_CAPABILITY 0x13
395 #define BSSGP_IEI_OMC_ID 0x14
396 #define BSSGP_IEI_PDU_IN_ERROR 0x15
397 #define BSSGP_IEI_PDU_LIFETIME 0x16
398 #define BSSGP_IEI_PRIORITY 0x17
399 #define BSSGP_IEI_QOS_PROFILE 0x18
400 #define BSSGP_IEI_RADIO_CAUSE 0x19
401 #define BSSGP_IEI_RA_CAP_UPD_CAUSE 0x1a
402 #define BSSGP_IEI_ROUTING_AREA 0x1b
403 #define BSSGP_IEI_R_DEFAULT_MS 0x1c
404 #define BSSGP_IEI_SUSPEND_REFERENCE_NUMBER 0x1d
405 #define BSSGP_IEI_TAG 0x1e
406 #define BSSGP_IEI_TLLI 0x1f
407 #define BSSGP_IEI_TMSI 0x20
408 #define BSSGP_IEI_TRACE_REFERENCE 0x21
409 #define BSSGP_IEI_TRACE_TYPE 0x22
410 #define BSSGP_IEI_TRANSACTION_ID 0x23
411 #define BSSGP_IEI_TRIGGER_ID 0x24
412 #define BSSGP_IEI_NUMBER_OF_OCTETS_AFFECTED 0x25
413 #define BSSGP_IEI_LSA_IDENTIFIER_LIST 0x26
414 #define BSSGP_IEI_LSA_INFORMATION 0x27
415 #define BSSGP_IEI_PFI 0x28
416 #define BSSGP_IEI_GPRS_TIMER 0x29
417 #define BSSGP_IEI_ABQP 0x3a
418 #define BSSGP_IEI_FEATURE_BITMAP 0x3b
419 #define BSSGP_IEI_BUCKET_FULL_RATIO 0x3c
420 #define BSSGP_IEI_SERVICE_UTRAN_CCO 0x3d
421 #define BSSGP_IEI_NSEI 0x3e
422 #define BSSGP_IEI_RRLP_APDU 0x3f
423 #define BSSGP_IEI_LCS_QOS 0x40
424 #define BSSGP_IEI_LCS_CLIENT_TYPE 0x41
425 #define BSSGP_IEI_REQUESTED_GPS_ASSISTANCE_DATA 0x42
426 #define BSSGP_IEI_LOCATION_TYPE 0x43
427 #define BSSGP_IEI_LOCATION_ESTIMATE 0x44
428 #define BSSGP_IEI_POSITIONING_DATA 0x45
429 #define BSSGP_IEI_DECIPHERING_KEYS 0x46
430 #define BSSGP_IEI_LCS_PRIORITY 0x47
431 #define BSSGP_IEI_LCS_CAUSE 0x48
432 #define BSSGP_IEI_LCS_CAPABILITY 0x49
433 #define BSSGP_IEI_RRLP_FLAGS 0x4a
434 #define BSSGP_IEI_RIM_APP_ID 0x4b
435 #define BSSGP_IEI_RIM_SEQUENCE_NUMBER 0x4c
436 #define BSSGP_IEI_RAN_INF_REQUEST_APP_CONTAINER 0x4d
437 #define BSSGP_IEI_RAN_INF_APP_CONTAINER 0x4e
438 #define BSSGP_IEI_RIM_PDU_INDICATIONS 0x4f
439 #define BSSGP_IEI_NUMBER_OF_CONTAINER_UNITS 0x50
440 /* x51 This value should not be used, as it has been used in earlier versions of
441 this protocol. */
442 #define BSSGP_IEI_PFC_FLOW_CONTROL_PARAMETERS 0x52
443 #define BSSGP_IEI_GLOBAL_CN_ID 0x53
444 #define BSSGP_IEI_RIM_ROUTING_INFORMATION 0x54
445 #define BSSGP_IEI_RIM_PROTOCOL_VERSION 0x55
446 #define BSSGP_IEI_APPLICATION_ERROR_CONTAINER 0x56
447 #define BSSGP_IEI_RAN_INF_REQUEST_RIM_CONTAINER 0x57
448 #define BSSGP_IEI_RAN_INF_RIM_CONTAINER 0x58
449 #define BSSGP_IEI_RAN_INF_APP_ERROR_RIM_CONTAINER 0x59
450 #define BSSGP_IEI_RAN_INF_ACK_RIM_CONTAINER 0x5a
451 #define BSSGP_IEI_RAN_INF_ERROR_RIM_CONTAINER 0x5b
453 #define BSSGP_IEI_REDIR_ATTEMP_FLG 0x87
454 #define BSSGP_IEI_REDIR_INDICATION 0x88
455 #define BSSGP_IEI_REDIR_COMPLETE 0x89
456 #define BSSGP_IEI_UNCONFIRM_SEND_STATE_VAR 0x8a
458 #define BSSGP_IEI_SELECTED_PLMN_ID 0x8e
460 ETSI
461 3GPP TS 48.018 version 6.16.0 Release 6 108 ETSI TS 148 018 V6.16.0 (2006-12)
462 IEI coding
463 (hexadecimal)
464 IEI Types
466 x5c TMGI
467 x5d MBMS Session Identity
468 x5e MBMS Session Duration
469 x5f MBMS Service Area Identity List
470 x60 MBMS Response
471 x61 MBMS Routing Area List
472 x62 MBMS Session Information
473 x63 MBMS Stop Cause
474 x64 Source BSS to Target BSS Transparent Container
475 x65 Target BSS to Source BSS Transparent Container
476 x66 NAS container for PS Handover
477 x67 PFCs to be set-up list
478 x68 List of set-up PFCs
479 x69 Extended Feature Bitmap
480 x6a Source RNC to Target RNC Transparent Container
481 x6b Target RNC to Source RNC Transparent Container
482 x6c RNC Identifier
483 x6d Page Mode
484 x6e Container ID
485 x6f Global TFI
486 x70 IMEI
487 x71 Time to MBMS Data Transfer
488 x72 MBMS Session Repetition Number
489 x73 Inter RAT Handover Info
490 x74 PS Handover Command
491 x75 PS Handover Indications
492 x76 SI/PSI Container
493 x77 Active PFCs List
494 x78 Velocity Data
495 x79 DTM Handover Command
496 x7a CS Indication
497 x7b Requested GANSS Assistance Data
498 x7c GANSS Location Type
499 x7d GANSS Positioning Data
500 x7e Flow Control Granularity
501 x7f eNB Identifier
502 x80 E-UTRAN Inter RAT Handover Info
503 x81 Subscriber Profile ID for RAT/Frequency priority
504 x82 Request for Inter RAT Handover Info
505 x83 Reliable Inter RAT Handover Info
506 x84 SON Transfer Application Identity
507 x85 CSG Identifier
508 x86 TAC
509 x87 Redirect Attempt Flag
510 x88 Redirection Indication
511 x89 Redirection Completed
512 x8a Unconfirmed send state variable
513 x8b IRAT Measurement Configuration
514 x8c SCI
515 X8d GGSN/P-GW location
516 x8e Selected PLMN ID
517 x8f Priority Class Indicator
520 /* Macros */
521 /* Defined localy here without the check of curr_len wrapping, that will be taken care of when this IEI dissecton finishes */
522 #define ELEM_IN_ELEM_MAND_TELV(EMT_iei, EMT_pdu_type, EMT_elem_idx, EMT_elem_name_addition) \
524 if ((consumed = elem_telv(tvb, tree, pinfo, (guint8) EMT_iei, EMT_pdu_type, EMT_elem_idx, curr_offset, curr_len, EMT_elem_name_addition)) > 0) \
526 curr_offset += consumed; \
527 curr_len -= consumed; \
529 else \
531 proto_tree_add_text(tree, \
532 tvb, curr_offset, 0, \
533 "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect", \
534 EMT_iei, \
535 get_gsm_a_msg_string(EMT_pdu_type, EMT_elem_idx), \
536 (EMT_elem_name_addition == NULL) ? "" : EMT_elem_name_addition \
537 ); \
541 #define ELEM_IN_ELEM_OPT_TELV(EOT_iei, EOT_pdu_type, EOT_elem_idx, EOT_elem_name_addition) \
543 if (curr_len != 0){\
544 if ((consumed = elem_telv(tvb, tree, pinfo, (guint8) EOT_iei, EOT_pdu_type, EOT_elem_idx, curr_offset, curr_len, EOT_elem_name_addition)) > 0) \
546 curr_offset += consumed; \
547 curr_len -= consumed; \
552 /* Forward declarations */
553 static guint16 de_bssgp_ran_inf_request_rim_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_);
554 static guint16 de_bssgp_ran_inf_rim_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_);
555 static guint16 de_bssgp_ran_inf_ack_rim_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_);
556 static guint16 de_bssgp_ran_inf_error_rim_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_);
557 static guint16 de_bssgp_ran_inf_app_error_rim_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_);
560 #if 0
561 static const value_string tab_nacc_cause[]={
562 { 0x00, "Other unspecified error" },
563 { 0x01, "Syntax error in the Application Container" },
564 { 0x02, "Reporting Cell Identifier does not match with the Destination Cell Identifier or with the Source Cell Identifier" },
565 { 0x03, "SI/PSI type error" },
566 { 0x04, "Inconsistent length of a SI/PSI message" },
567 { 0x05, "Inconsistent set of messages" },
568 { 0, NULL },
571 #endif
575 * 11.3 Information Element Identifier (IEI)
579 * 11.3.1 Alignment octets
581 static guint16
582 de_bssgp_aligment_octets(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
584 guint32 curr_offset;
586 curr_offset = offset;
588 proto_tree_add_text(tree, tvb, curr_offset, len, "%u Spare octet(s)",len);
590 return(len);
594 * 11.3.2 Bmax default MS
596 static guint16
597 de_bssgp_bmax_default_ms(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
599 guint32 curr_offset;
601 curr_offset = offset;
603 proto_tree_add_item(tree, hf_bssgp_bmax, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
604 curr_offset+=2;
606 return(curr_offset-offset);
609 * 11.3.3 BSS Area Indication
611 static guint16
612 de_bssgp_bss_area_ind(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
614 guint32 curr_offset;
616 curr_offset = offset;
618 proto_tree_add_item(tree, hf_bssgp_bss_area_ind, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
619 curr_offset++;
621 return(curr_offset-offset);
624 * 11.3.4 Bucket Leak Rate (R)
626 static guint16
627 de_bssgp_bucket_leak_rate(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
629 guint32 curr_offset;
631 curr_offset = offset;
633 proto_tree_add_item(tree, hf_bssgp_r, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
634 curr_offset+=2;
636 return(curr_offset-offset);
639 * 11.3.5 BVC Bucket Size
641 static guint16
642 de_bssgp_bvc_bucket_size(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
644 guint32 curr_offset;
646 curr_offset = offset;
648 proto_tree_add_item(tree, hf_bssgp_bucket_size, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
649 curr_offset+=2;
651 return(curr_offset-offset);
654 * 11.3.6 BVCI (BSSGP Virtual Connection Identifier)
656 static guint16
657 de_bssgp_bvci(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
659 guint32 curr_offset;
660 guint16 bvci;
662 curr_offset = offset;
664 /* octet 3-4 Unstructured value */
665 bvci = tvb_get_ntohs(tvb,curr_offset);
666 proto_tree_add_item(tree, hf_bssgp_bvci, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
667 curr_offset+=2;
669 if (add_string)
670 g_snprintf(add_string, string_len, " - 0x%x", bvci);
673 return(curr_offset-offset);
676 * 11.3.7 BVC Measurement
678 static guint16
679 de_bssgp_bvc_meas(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
681 guint32 curr_offset;
683 curr_offset = offset;
685 /* The Delay Value field is coded as a 16-bit integer value in units of centi-seconds (one hundredth of a second). This
686 * coding provides a range of over 10 minutes in increments of 10 ms. As a special case, the hexadecimal value 0xFFFF
687 *(decimal 65 535) shall be interpreted as "infinite delay".
689 proto_tree_add_item(tree, hf_bssgp_delay_val, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
690 curr_offset+=2;
692 return(curr_offset-offset);
695 * 11.3.8 Cause
697 static const value_string bssgp_cause_vals[] = {
698 { 0x00, "Processor overload" },
699 { 0x01, "Equipment failure" },
700 { 0x02, "Transit network service failure" },
701 { 0x03, "Network service transmission capacity modified from zero kbps to greater than zero kbps" },
702 { 0x04, "Unknown MS" },
703 { 0x05, "BVCI unknown" },
704 { 0x06, "Cell traffic congestion" },
705 { 0x07, "SGSN congestion" },
706 { 0x08, "O&M intervention" },
707 { 0x09, "BVCI blocked" },
708 { 0x0a, "PFC create failure" },
709 { 0x0b, "PFC preempted" },
710 { 0x0c, "ABQP no more supported" },
712 { 0x0d, "Undefined - protocol error - unspecified" },
713 { 0x0e, "Undefined - protocol error - unspecified" },
714 { 0x0f, "Undefined - protocol error - unspecified" },
715 { 0x10, "Undefined - protocol error - unspecified" },
716 { 0x11, "Undefined - protocol error - unspecified" },
717 { 0x12, "Undefined - protocol error - unspecified" },
718 { 0x13, "Undefined - protocol error - unspecified" },
719 { 0x14, "Undefined - protocol error - unspecified" },
720 { 0x15, "Undefined - protocol error - unspecified" },
721 { 0x16, "Undefined - protocol error - unspecified" },
722 { 0x17, "Undefined - protocol error - unspecified" },
723 { 0x18, "Undefined - protocol error - unspecified" },
724 { 0x19, "Undefined - protocol error - unspecified" },
725 { 0x1a, "Undefined - protocol error - unspecified" },
726 { 0x1b, "Undefined - protocol error - unspecified" },
727 { 0x1c, "Undefined - protocol error - unspecified" },
728 { 0x1d, "Undefined - protocol error - unspecified" },
729 { 0x1e, "Undefined - protocol error - unspecified" },
730 { 0x1f, "Undefined - protocol error - unspecified" },
732 { 0x20, "Semantically incorrect PDU" },
733 { 0x21, "Invalid mandatory information" },
734 { 0x22, "Missing mandatory IE" },
735 { 0x23, "Missing conditional IE" },
736 { 0x24, "Unexpected conditional IE" },
737 { 0x25, "Conditional IE error" },
738 { 0x26, "PDU not compatible with the protocol state" },
739 { 0x27, "Protocol error - unspecified" },
740 { 0x28, "PDU not compatible with the feature set" },
741 { 0x29, "Requested information not available" },
742 { 0x2a, "Unknown destination address" },
743 { 0x2b, "Unknown RIM application identity" },
744 { 0x2c, "Invalid container unit information" },
745 { 0x2d, "PFC queuing" },
746 { 0x2e, "PFC created successfully" },
747 { 0x2f, "T12 expiry" },
748 { 0x30, "MS under PS Handover treatment" },
749 { 0x31, "Uplink quality" },
750 { 0x32, "Uplink strength" },
751 { 0x33, "Downlink quality" },
752 { 0x34, "Downlink strength" },
753 { 0x35, "Distance" },
754 { 0x36, "Better cell" },
755 { 0x37, "Traffic" },
756 { 0x38, "Radio contact lost with MS" },
757 { 0x39, "MS back on old channel" },
758 { 0x3a, "T13 expiry" },
759 { 0x3b, "T14 expiry" },
760 { 0x3c, "Not all requested PFCs created" },
761 { 0x3d, "CS cause" },
762 { 0x3e, "Requested ciphering and/or integrity protection algorithms not supported" },
763 { 0x3f, "Relocation failure in target system" },
764 { 0x40, "Directed Retry" },
765 { 0x41, "Time critical relocation" },
766 { 0x42, "PS Handover Target not allowed" },
767 { 0x43, "PS Handover not Supported in Target BSS or Target System" },
768 { 0x44, "Incoming relocation not supported due to PUESBINE feature" },
769 { 0x45, "DTM Handover - No CS resource" },
770 { 0x46, "DTM Handover - PS Allocation failure" },
771 { 0x47, "DTM Handover - T24 expiry" },
772 { 0x48, "DTM Handover - Invalid CS Indication IE" },
773 { 0x49, "DTM Handover - T23 expiry" },
774 { 0x4a, "DTM Handover - MSC Error" },
775 { 0x4b, "Invalid CSG cell" },
776 { 0, NULL },
779 value_string_ext bssgp_cause_vals_ext = VALUE_STRING_EXT_INIT(bssgp_cause_vals);
781 static guint16
782 de_bssgp_cause(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
784 guint32 curr_offset;
786 curr_offset = offset;
788 /* The Delay Value field is coded as a 16-bit integer value in units of centi-seconds (one hundredth of a second). This
789 * coding provides a range of over 10 minutes in increments of 10 ms. As a special case, the hexadecimal value 0xFFFF
790 *(decimal 65 535) shall be interpreted as "infinite delay".
792 proto_tree_add_item(tree, hf_bssgp_cause, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
793 curr_offset+=1;
795 return(curr_offset-offset);
798 * 11.3.9 Cell Identifier
801 * octets 3-8 Octets 3 to 8 contain the value part (starting with octet 2) of the
802 * Routing Area Identification IE defined in 3GPP TS 24.008, not
803 * including 3GPP TS 24.008 IEI
804 * Octets 9 and 10 contain the value part (starting with octet 2) of the
805 * Cell Identity IE defined in 3GPP TS 24.008, not including
806 * 3GPP TS 24.008 IEI (10.5.1.1)
809 guint16
810 de_bssgp_cell_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string, int string_len)
812 guint32 curr_offset;
813 guint16 ci;
815 curr_offset = offset;
817 curr_offset = curr_offset + de_gmm_rai(tvb, tree, pinfo, curr_offset, 6, add_string, string_len);
818 /*Why doesn't this work? ( add_string will not contain RAI + CI )
819 * curr_offset = curr_offset + de_cell_id(tvb, tree, curr_offset , 2, add_string, string_len);
821 ci = tvb_get_ntohs(tvb, curr_offset);
822 proto_tree_add_item(tree, hf_bssgp_ci, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
823 curr_offset+=2;
824 if (add_string)
825 g_snprintf(add_string, string_len, "%s, CI %u", add_string, ci);
828 return(curr_offset-offset);
831 * 11.3.10 Channel needed
833 /* Rest of element coded as the value part of the Channel Needed
834 * PDU defined in 3GPP TS 29.018, not including 3GPP TS 29.018
835 * IEI and 3GPP TS 29.018 length indicator
836 * TS 29.018
837 * The rest of the information element is coded as the IEI part and the
838 * value part of the Channel Needed IE defined in 3GPP TS 44.018.
840 static guint16
841 de_bssgp_chnl_needed(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
843 guint32 curr_offset;
845 curr_offset = offset;
847 curr_offset = de_rr_chnl_needed(tvb, tree, pinfo, curr_offset, len , NULL, 0);
849 return(curr_offset-offset);
853 * 11.3.11 DRX Parameters
856 * Rest of element coded as the value part defined in
857 * 3GPP TS 24.008, not including 3GPP TS 24.008 IEI and
858 * 3GPP TS 24.008 octet length indicator
861 * 11.3.12 eMLPP-Priority
864 * Rest of element coded as the value part of the eMLPP-Priority IE
865 * defined in 3GPP TS 48.008, not including 3GPP TS 48.008 IEI and
866 * 3GPP TS 48.008 length indicator
869 * 11.3.13 Flush Action
871 static const value_string bssgp_flush_action_vals[] = {
872 { 0x00, "LLC-PDU(s) deleted" },
873 { 0x01, "LLC-PDU(s) transferred" },
874 { 0, NULL },
875 /* Otherwise "Reserved" */
878 static guint16
879 de_bssgp_flush_action(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
881 guint32 curr_offset;
882 guint8 oct;
884 curr_offset = offset;
886 /* Action value */
887 oct = tvb_get_guint8(tvb,curr_offset);
888 proto_tree_add_item(tree, hf_bssgp_flush_action, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
889 curr_offset+=1;
890 if (add_string)
891 g_snprintf(add_string, string_len, " - %s", val_to_str_const(oct, bssgp_flush_action_vals, "Reserved"));
894 return(curr_offset-offset);
897 * 11.3.14 IMSI
899 /* Octets 3-n contain an IMSI coded as the value part of the Mobile
900 * Identity IE defined in 3GPP TS 24.008
901 * (NOTE 1)
902 * NOTE 1: The Type of identity field in the Mobile Identity IE shall be ignored by
903 * the receiver.
906 * 11.3.15 LLC-PDU
909 static guint16
910 de_bssgp_llc_pdu(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
912 tvbuff_t *next_tvb=NULL;
913 guint32 curr_offset;
915 curr_offset = offset;
917 if(len > 0){
918 next_tvb = tvb_new_subset(tvb, curr_offset, len, len);
919 proto_tree_add_text(tree, tvb, curr_offset, len, "LLC Data");
922 if(next_tvb){
923 if (llc_handle) {
924 call_dissector(llc_handle, next_tvb, pinfo, gparent_tree);
926 else if (data_handle) {
927 call_dissector(data_handle, next_tvb, pinfo, gparent_tree);
931 return(len);
934 * 11.3.16 LLC Frames Discarded
936 static guint16
937 de_bssgp_llc_frames_disc(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
939 guint32 curr_offset;
940 guint8 oct;
942 curr_offset = offset;
944 /* Action value */
945 oct = tvb_get_guint8(tvb,curr_offset);
946 proto_tree_add_item(tree, hf_bssgp_llc_frames_disc, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
947 curr_offset+=1;
949 if (add_string)
950 g_snprintf(add_string, string_len, " - %u Frames", oct);
952 return(curr_offset-offset);
955 * 11.3.17 Location Area
957 /* Octets 3 to 7 contain the value part (starting with octet 2) of the
958 * Location Area Identification IE defined in 3GPP TS 24.008, not
959 * including 3GPP TS 24.008 IEI
963 * 11.3.18 LSA Identifier List
965 /* Rest of element coded as in 3GPP TS 48.008, not including
966 * 3GPP TS 48.008 IEI and 3GPP TS 48.008 length indicator
969 * 11.3.19 LSA Information
971 /* Rest of element coded as in 3GPP TS 48.008, not including
972 * 3GPP TS 48.008 IEI and 3GPP TS 48.008 length indicator
975 * 11.3.20 Mobile Id
977 /* Octets 3-n contain either the IMSI, IMEISV or IMEI coded as the
978 * value part (starting with octet 3) of the Mobile Identity IE defined in
979 * 3GPP TS 24.008, not including 3GPP TS 24.008 IEI and
980 * 3GPP TS 24.008 length indcator
983 * 11.3.21 MS Bucket Size
986 static guint16
987 de_bssgp_ms_bucket_size(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
989 guint32 curr_offset;
991 curr_offset = offset;
993 /* The Bmax field is coded as Bmax of BVC Bucket Size, see sub-clause 11.3.5. */
994 proto_tree_add_item(tree, hf_bssgp_bucket_size, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
995 curr_offset+=2;
997 return(curr_offset-offset);
1000 * 11.3.22 MS Radio Access Capability
1002 /* Rest of element coded as the value part defined in
1003 * 3GPP TS 24.008, not including 3GPP TS 24.008 IEI and
1004 * 3GPP TS 24.008 octet length indicator.
1007 * 11.3.23 OMC Id
1009 static guint16
1010 de_bssgp_omc_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1012 guint32 curr_offset;
1014 curr_offset = offset;
1016 /* octet 3-22 For the OMC identity, see 3GPP TS 12.20 */
1017 proto_tree_add_item(tree, hf_bssgp_omc_id, tvb, curr_offset, len, ENC_NA);
1019 return len;
1022 * 11.3.24 PDU In Error
1024 static guint16
1025 de_bssgp_pdu_in_error(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1027 guint32 curr_offset;
1029 curr_offset = offset;
1031 /* octet 3-? Erroneous BSSGP PDU */
1032 proto_tree_add_item(tree, hf_bssgp_msg_type, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1033 curr_offset++;
1035 proto_tree_add_text(tree, tvb, curr_offset, len-1, "PDU Data");
1037 return len;
1040 * 11.3.25 PDU Lifetime
1042 static guint16
1043 de_bssgp_pdu_lifetime(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1045 guint32 curr_offset;
1047 curr_offset = offset;
1049 proto_tree_add_item(tree, hf_bssgp_delay_val, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
1050 curr_offset+=2;
1052 return(curr_offset-offset);
1056 The Delay Value field is coded as a 16-bit integer value in units of centi-seconds (one hundredth of a second). This
1057 coding provides a range of over 10 minutes in increments of 10 ms. As a special case, the hexadecimal value 0xFFFF
1058 (decimal 65 535) shall be interpreted as "infinite delay".
1061 * 11.3.26 PDU Type
1064 * 11.3.27 Priority
1066 /* Rest of element coded as the value part of the Priority IE defined in
1067 * 3GPP TS 48.008, not including 3GPP TS 48.008 IEI and
1068 * 3GPP TS 48.008 length indicator
1071 * 11.3.28 QoS Profile
1073 static const true_false_string bssgp_a_bit_vals = {
1074 "Radio interface uses RLC/MAC-UNITDATA functionality",
1075 "Radio interface uses RLC/MAC ARQ functionality"
1078 static const true_false_string bssgp_t_bit_vals = {
1079 "The SDU contains data",
1080 "The SDU contains signalling"
1083 static const true_false_string bssgp_cr_bit_vals = {
1084 "The SDU does not contain a LLC ACK or SACK command/response frame type",
1085 "The SDU contains a LLC ACK or SACK command/response frame type"
1088 const value_string bssgp_peak_rate_gran_vals[] = {
1089 { 0x0, "100 bits/s increments" },
1090 { 0x1, "1000 bits/s increments" },
1091 { 0x2, "10000 bits/s increments" },
1092 { 0x3, "100000 bits/s increments" },
1093 { 0, NULL }
1095 static const value_string bssgp_precedence_ul[] = {
1096 { 0, "High priority" },
1097 { 1, "Normal priority" },
1098 { 2, "Low priority" },
1099 { 0, NULL },
1102 static const value_string bssgp_precedence_dl[] = {
1103 { 0, "Radio priority 1" },
1104 { 1, "Radio priority 2" },
1105 { 2, "Radio priority 3" },
1106 { 3, "Radio priority 4" },
1107 { 4, "Radio priority unknown" },
1108 { 0, NULL },
1111 static guint16
1112 de_bssgp_qos_profile(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1114 proto_item *pi, *pre_item;
1115 guint32 curr_offset;
1116 guint16 peak_bit_rate;
1117 guint8 rate_gran, precedence;
1118 int link_dir;
1120 curr_offset = offset;
1122 /* octet 3-4 Peak bit rate provided by the network (note)
1123 * NOTE: The bit rate 0 (zero) shall mean "best effort" in this IE.
1125 link_dir = pinfo->link_dir;
1127 peak_bit_rate = tvb_get_ntohs(tvb, curr_offset);
1128 pi = proto_tree_add_text(tree, tvb, curr_offset, 1, "Peak bit rate: ");
1129 if (peak_bit_rate == 0) {
1130 proto_item_append_text(pi, "Best effort");
1131 }else{
1132 rate_gran = tvb_get_guint8(tvb, curr_offset+2)&0xc0;
1133 switch(rate_gran){
1134 case 0:
1135 /* 100 bits/s increments */
1136 proto_item_append_text(pi, "%u bits/s", peak_bit_rate * 100);
1137 break;
1138 case 1:
1139 /* 1000 bits/s increments */
1140 proto_item_append_text(pi, "%u kbits/s", peak_bit_rate);
1141 break;
1142 case 2:
1143 /* 10000 bits/s increments */
1144 proto_item_append_text(pi, "%u kbits/s", peak_bit_rate * 10);
1145 break;
1146 case 3:
1147 /* 100000 bits/s increments */
1148 proto_item_append_text(pi, "%u kbits/s", peak_bit_rate * 100);
1149 break;
1150 default:
1151 break;
1154 curr_offset+=2;
1156 /* octet 5 Peak Bit Rate Granularity C/R T A Precedence */
1157 /* If the Gigabit Interface feature has not been negotiated, the "Peak bit rate"
1158 * field is the binary encoding of the peak bit rate information expressed in 100 bits/s
1159 * increments, starting from 0 x 100 bits/s until 65 535 x 100 bits/s (6 Mbps).
1161 * If the Gigabit Interface feature has been negotiated, the "Peak bit rate" field is the
1162 * binary encoding of the peak bit rate information expressed in increments as defined by
1163 * the Peak Bit Rate Granularity field.
1165 proto_tree_add_item(tree, hf_bssgp_peak_rate_gran, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1166 proto_tree_add_item(tree, hf_bssgp_cr_bit, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1167 proto_tree_add_item(tree, hf_bssgp_t_bit, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1168 proto_tree_add_item(tree, hf_bssgp_a_bit, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1169 precedence = tvb_get_guint8(tvb, curr_offset) & 0x7;
1170 pre_item = proto_tree_add_item(tree, hf_bssgp_precedence, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1171 if(link_dir == P2P_DIR_DL){
1172 proto_item_append_text(pre_item, " %s", val_to_str_const((guint32)precedence, bssgp_precedence_dl, "Radio Priority Unknown(Radio priority 3)"));
1173 }else{
1174 proto_item_append_text(pre_item, " %s", val_to_str_const((guint32)precedence, bssgp_precedence_ul, "Priority Unknown(Low priority)"));
1177 curr_offset++;
1179 return(curr_offset-offset);
1182 * 11.3.29 Radio Cause
1184 static const value_string bssgp_radio_cause_vals[] = {
1185 { 0x00, "Radio contact lost with the MS" },
1186 { 0x01, "Radio link quality insufficient to continue communication" },
1187 { 0x02, "Cell reselection ordered" },
1188 { 0x03, "Cell reselection prepare" },
1189 { 0x04, "Cell reselection failure" },
1190 { 0, NULL },
1191 /* Otherwise "Reserved (Radio contact lost with the MS)" */
1194 static guint16
1195 de_bssgp_ra_cause(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1197 guint32 curr_offset;
1199 curr_offset = offset;
1201 proto_tree_add_item(tree, hf_bssgp_ra_cause, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1202 curr_offset++;
1204 return(curr_offset-offset);
1208 * 11.3.30 RA-Cap-UPD-Cause
1210 static const value_string bssgp_ra_cap_upd_cause_vals[] = {
1211 { 0x00, "OK, RA capability IE present" },
1212 { 0x01, "TLLI unknown in SGSN" },
1213 { 0x02, "No RA capabilities or IMSI available for this MS" },
1214 { 0, NULL },
1215 /* Otherwise "Reserved (TLLI unknown in SGSN)" */
1218 static guint16
1219 de_bssgp_ra_cap_upd_cause(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1221 guint32 curr_offset;
1223 curr_offset = offset;
1225 proto_tree_add_item(tree, hf_bssgp_ra_cap_upd_cause, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1226 curr_offset++;
1228 return(curr_offset-offset);
1232 * 11.3.31 Routeing Area
1234 /* Octets 3 to 8 contain the value part (starting with octet 2) of the
1235 * Routing Area Identification IE defined in 3GPP TS 24.008, not
1236 * including 3GPP TS 24.008 IEI
1239 * 11.3.32 R_default_MS
1241 static guint16
1242 de_bssgp_r_default_ms(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1244 guint32 curr_offset;
1246 curr_offset = offset;
1248 proto_tree_add_item(tree, hf_bssgp_r_default_ms, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
1249 curr_offset+=2;
1251 return(curr_offset-offset);
1255 * 11.3.33 Suspend Reference Number
1257 static guint16
1258 de_bssgp_suspend_ref_no(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1260 guint32 curr_offset;
1262 curr_offset = offset;
1264 /* Unstructured value */
1265 proto_tree_add_item(tree, hf_bssgp_suspend_ref_no, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1267 curr_offset++;
1269 return(curr_offset-offset);
1272 * 11.3.34 Tag
1275 static guint16
1276 de_bssgp_tag(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1278 guint32 curr_offset;
1280 curr_offset = offset;
1282 /* Unstructured value */
1283 proto_tree_add_item(tree, hf_bssgp_tag, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1285 curr_offset++;
1287 return(curr_offset-offset);
1291 * 11.3.35 Temporary logical link Identity (TLLI)
1292 * Rest of element coded as the value part of the TLLI information
1293 * element in 3GPP TS 44.018, not including 3GPP TS 44.018 IEI.
1296 * 11.3.36 Temporary Mobile Subscriber Identity (TMSI)
1298 /* Rest of element coded as the value part of the TMSI/P-TMSI
1299 * information element in 3GPP TS 24.008, not including
1300 * 3GPP TS 24.008 IEI.
1303 * 11.3.37 Trace Reference
1305 static guint16
1306 de_bssgp_trace_ref(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1308 guint32 curr_offset;
1310 curr_offset = offset;
1312 /* octet 3-4 Trace Reference */
1313 proto_tree_add_item(tree, hf_bssgp_trace_ref, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
1315 curr_offset+=2;
1317 return(curr_offset-offset);
1321 * 11.3.38 Trace Type
1323 /* This is coded as specified in Technical Specification
1324 * 3GPP TS 32.008
1325 * XXX: Coding unknown (Specification withdrawn) 3GPP TS 32.008
1327 static guint16
1328 de_bssgp_trace_type(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1330 guint32 curr_offset;
1332 curr_offset = offset;
1335 proto_tree_add_text(tree, tvb, curr_offset, len, "Trace Type data ( Coding unknown (Specification withdrawn) 3GPP TS 32.008)");
1337 return(len);
1340 * 11.3.39 Transaction Id
1342 static guint16
1343 de_bssgp_transaction_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1345 guint32 curr_offset;
1347 curr_offset = offset;
1349 proto_tree_add_item(tree, hf_bssgp_transaction_id, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
1351 return(curr_offset-offset);
1354 * 11.3.40 Trigger Id
1356 static guint16
1357 de_bssgp_trigger_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1359 guint32 curr_offset;
1361 curr_offset = offset;
1363 proto_tree_add_item(tree, hf_bssgp_trigger_id, tvb, curr_offset, len, ENC_NA);
1365 return(len);
1368 * 11.3.41 Number of octets affected
1370 static guint16
1371 de_bssgp_no_of_oct_affected(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1373 guint32 curr_offset;
1374 guint32 no_of_oct;
1376 curr_offset = offset;
1378 /* octet 3-5 number of octets transferred or deleted */
1379 no_of_oct = tvb_get_ntoh24(tvb,curr_offset);
1380 proto_tree_add_item(tree, hf_bssgp_no_of_oct, tvb, curr_offset, 3, ENC_BIG_ENDIAN);
1382 curr_offset+=3;
1384 if (add_string)
1385 g_snprintf(add_string, string_len, " - %u", no_of_oct);
1387 return(curr_offset-offset);
1390 * 11.3.42 Packet Flow Identifier (PFI)
1392 /* Rest of element coded as the value part of the Packet Flow
1393 * Identifier information element in 3GPP TS 24.008, not including
1394 * 3GPP TS 24.008 IEI
1397 * 11.3.42a (void)
1400 * 11.3.43 Aggregate BSS QoS Profile
1402 /* Rest of element coded as the value part of the QoS information
1403 * element in 3GPP TS 24.008, not including 3GPP TS 24.008 IEI and
1404 * length indicator. The shorter 3-byte form of QoS information is not
1405 * allowed in BSSGP PDUs.
1406 * 10.5.6.5
1409 * 11.3.44 GPRS Timer
1411 static const value_string bssgp_unit_vals[] = {
1412 { 0, "incremented in multiples of 2 s" },
1413 { 1, "incremented in multiples of 1 minute" },
1414 { 2, "incremented in multiples of decihours" },
1415 { 3, "incremented in multiples of 500 msec" },
1416 { 4, "incremented in multiples of 1 minute(Undefined)" },
1417 { 5, "incremented in multiples of 1 minute(Undefined)" },
1418 { 6, "incremented in multiples of 1 minute(Undefined)" },
1419 { 7, "the timer does not expire" },
1420 { 0, NULL},
1421 /* Otherwise "incremented in multiples of 1 minute" */
1424 static guint16
1425 de_bssgp_gprs_timer(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1427 guint32 curr_offset;
1429 curr_offset = offset;
1431 /*octet 3 Unit Value Timer value */
1432 proto_tree_add_item(tree, hf_bssgp_unit_val, tvb, curr_offset, 3, ENC_BIG_ENDIAN);
1433 proto_tree_add_item(tree, hf_bssgp_gprs_timer, tvb, curr_offset, 3, ENC_BIG_ENDIAN);
1435 curr_offset++;
1437 return(curr_offset-offset);
1440 * 11.3.45 Feature Bitmap
1442 static guint16
1443 de_bssgp_feature_bitmap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1445 guint32 curr_offset;
1447 curr_offset = offset;
1448 /* MBMS */
1449 proto_tree_add_item(tree, hf_bssgp_mbms, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1450 /* EnhancedRadioStatus */
1451 proto_tree_add_item(tree, hf_bssgp_EnhancedRadioStatus, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1452 /* PFCFC */
1453 proto_tree_add_item(tree, hf_bssgp_pfcfc, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1454 /* RIM */
1455 proto_tree_add_item(tree, hf_bssgp_rim, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1456 /* LCS */
1457 proto_tree_add_item(tree, hf_bssgp_lcs, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1458 /* INR */
1459 proto_tree_add_item(tree, hf_bssgp_inr, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1460 /* CBL */
1461 proto_tree_add_item(tree, hf_bssgp_cbl, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1462 /* PFC */
1463 proto_tree_add_item(tree, hf_bssgp_pfc, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1465 curr_offset++;
1467 return(curr_offset-offset);
1470 * 11.3.46 Bucket Full Ratio
1472 static guint16
1473 de_bssgp_bucket_full_ratio(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1475 guint32 curr_offset;
1477 curr_offset = offset;
1479 /* Ratio of the bucket that is filled up with data */
1480 proto_tree_add_item(tree, hf_bssgp_bucket_full_ratio, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1482 curr_offset++;
1484 return(curr_offset-offset);
1487 * 11.3.47 Service UTRAN CCO
1489 static const value_string bssgp_service_utran_cco_vals[] = {
1490 { 0, "Network initiated cell change order procedure to UTRAN should be performed" },
1491 { 1, "Network initiated cell change order procedure to UTRAN should not be performed" },
1492 { 2, "Network initiated cell change order procedure to UTRAN shall not be performed" },
1493 { 3, "If received, shall be interpreted as no information available (bits 4-5 valid)" },
1494 { 0, NULL },
1495 /* Otherwise "No information available" */
1498 static const value_string bssgp_service_eutran_cco_vals[] = {
1499 { 0, "If received, shall be interpreted as no information available" },
1500 { 1, "Network initiated cell change order to E-UTRAN or PS handover to E-UTRAN procedure should be performed" },
1501 { 2, "Network initiated cell change order to E-UTRAN or PS handover to E-UTRAN procedure should not be performed" },
1502 { 3, "Network initiated cell change order to E-UTRAN or PS handover to E-UTRAN procedure shall not be performed" },
1503 { 0, NULL },
1504 /* Otherwise "No information available" */
1507 static guint16
1508 de_bssgp_serv_utran_cco(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1510 guint32 curr_offset;
1512 curr_offset = offset;
1514 /* Service EUTRAN CCO Value part */
1515 proto_tree_add_item(tree, hf_bssgp_serv_eutran_cco, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1516 /* Service UTRAN CCO Value part */
1517 proto_tree_add_item(tree, hf_bssgp_serv_utran_cco, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1518 curr_offset++;
1520 return(curr_offset-offset);
1524 * 11.3.48 NSEI (Network Service Entity Identifier)
1526 static guint16
1527 de_bssgp_nsei(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1529 guint32 curr_offset;
1530 guint16 nsei;
1532 curr_offset = offset;
1534 nsei = tvb_get_ntohs(tvb, curr_offset);
1535 proto_tree_add_item(tree, hf_bssgp_nsei, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
1536 curr_offset+=2;
1538 col_append_sep_fstr(pinfo->cinfo, COL_INFO, BSSGP_SEP, "NSEI %u", nsei);
1541 return(curr_offset-offset);
1544 * 11.3.49 RRLP APDU
1546 static guint16
1547 de_bssgp_rrlp_apdu(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1549 tvbuff_t *next_tvb=NULL;
1550 guint32 curr_offset;
1552 curr_offset = offset;
1554 /* The rest of the information element contains an embedded RRLP
1555 * message whose content and encoding are defined according to the
1556 * 3GPP TS 44.031. The RRLP protocol is not octet aligned.
1557 * Therefore, the unused bits in the last octet are padded with zeroes
1560 if(len > 0){
1561 next_tvb = tvb_new_subset_remaining(tvb, curr_offset);
1562 proto_tree_add_text(tree, tvb, curr_offset, len, "RRLP APDU");
1565 if(next_tvb){
1566 if (rrlp_handle) {
1567 call_dissector(rrlp_handle, next_tvb, pinfo, gparent_tree);
1568 }else if (data_handle) {
1569 call_dissector(data_handle, next_tvb, pinfo, gparent_tree);
1572 return(len);
1576 * 11.3.50 LCS QoS
1578 /* Rest of element coded as the value part defined in
1579 * 3GPP TS 48.008, not including 3GPP TS 48.008 IEI and
1580 * 3GPP TS 48.008 octet length indicator
1583 * 11.3.51 LCS Client Type
1585 /* Rest of element coded as the value part defined in
1586 * 3GPP TS 49.031, not including 3GPP TS 49.031 IEI and
1587 * 3GPP TS 49.031 octet length indicator
1590 * 11.3.52 Requested GPS Assistance Data
1592 /* Rest of element coded as the value part defined in
1593 * 3GPP TS 49.031, not including 3GPP TS 49.031 IEI and
1594 * 3GPP TS 49.031 octet length indicator
1597 * 11.3.53 Location Type
1599 /* Rest of element coded as the value part defined in
1600 * 3GPP TS 49.031, not including 3GPP TS 49.031 IEI and
1601 * 3GPP TS 49.031 octet length indicator
1604 * 11.3.54 Location Estimate
1606 /* Rest of element coded as the value part defined in
1607 * 3GPP TS 48.008, not including 3GPP TS 48.008 IEI and
1608 * 3GPP TS 48.008 octet length indicator
1611 * 11.3.55 Positioning Data
1613 /* Rest of element coded as the value part defined in
1614 * 3GPP TS 49.031, not including 3GPP TS 49.031 IEI and
1615 * 3GPP TS 49.031 octet length indicator
1618 * 11.3.56 Deciphering Keys
1620 /* Rest of element coded as the value part defined in
1621 * 3GPP TS 49.031, not including 3GPP TS 49.031 IEI and
1622 * 3GPP TS 49.031 octet length indicator
1625 * 11.3.57 LCS Priority
1627 /* Rest of element coded as the value part defined in
1628 * 3GPP TS 49.031, not including 3GPP TS 49.031 IEI and
1629 * 3GPP TS 49.031 octet length indicator
1632 * 11.3.58 LCS Cause
1634 /* Rest of element coded as the value part defined in
1635 * 3GPP TS 49.031, not including 3GPP TS 49.031 IEI and
1636 * 3GPP TS 49.031 octet length indicator
1639 * 11.3.59 LCS Capability
1641 /* Rest of element coded as the value part of the PS LCS Capability
1642 * IE defined in 3GPP TS 24.008, not including 3GPP TS 24.008 IEI
1643 * and length indicator
1646 * 11.3.60 RRLP Flags
1649 static const true_false_string bssgp_rrlp_flg1_vals = {
1650 "Not a Positioning Command or final response",
1651 "Position Command (BSS to SGSN) or final response (SGSN to BSS)"
1654 static guint16
1655 de_bssgp_rrlp_flags(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1657 guint32 curr_offset;
1659 curr_offset = offset;
1661 /* Flag 1 (Octet 3, bit 1): */
1662 proto_tree_add_item(tree, hf_bssgp_rrlp_flag1, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
1664 return(curr_offset-offset);
1668 * 11.3.61 RIM Application Identity
1671 static const value_string bssgp_rim_appid_vals[] = {
1672 { 0, "Reserved" },
1673 { 1, "Network Assisted Cell Change (NACC)" },
1674 { 2, "System Information 3 (SI3)" },
1675 { 3, "MBMS data channel" },
1676 { 4, "SON Transfer" },
1677 { 5, "UTRA System Information (UTRA SI)" },
1678 { 0, NULL },
1681 static guint16
1682 de_bssgp_rim_app_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1684 guint32 curr_offset;
1686 curr_offset = offset;
1688 /* RIM Application Identity */
1689 g_rim_application_identity = tvb_get_guint8(tvb, curr_offset);
1690 proto_tree_add_item(tree, hf_bssgp_rim_app_id, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1691 curr_offset++;
1693 return(curr_offset-offset);
1697 * 11.3.62 RIM Sequence Number
1699 static guint16
1700 de_bssgp_rim_seq_no(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1702 guint32 curr_offset;
1704 curr_offset = offset;
1706 /* RIM Sequence Number */
1707 proto_tree_add_item(tree, hf_bssgp_rim_seq_no, tvb, curr_offset, 4, ENC_BIG_ENDIAN);
1708 curr_offset+=4;
1710 return(curr_offset-offset);
1713 * 11.3.62a RIM Container
1714 * 11.3.62a.0 General
1715 * 11.3.62a.1 RAN-INFORMATION-REQUEST RIM Container
1717 /* Dissection moved */
1719 * 11.3.62a.2 RAN-INFORMATION RIM Container
1720 * 11.3.62a.3 RAN-INFORMATION-ACK RIM Container
1721 * 11.3.62a.4 RAN-INFORMATION-ERROR RIM Container
1722 * 11.3.62a.5 RAN-INFORMATION-APPLICATION-ERROR RIM Container
1725 * 11.3.63 Application Container
1726 * 11.3.63.1 RAN-INFORMATION-REQUEST Application Container
1727 * 11.3.63.1.0 General
1732 static guint16
1733 de_bssgp_ran_information_request_app_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1735 tvbuff_t *new_tvb = NULL;
1736 int curr_offset, bit_offset;
1738 curr_offset = offset;
1740 switch(g_rim_application_identity){
1741 case 1:
1742 /* 11.3.63.1.1 RAN-INFORMATION-REQUEST Application Container for the NACC Application */
1743 /* Reporting Cell Identifier */
1744 curr_offset = curr_offset + de_bssgp_cell_id(tvb, tree, pinfo,curr_offset, len, add_string, string_len);
1745 break;
1746 case 2:
1747 /* 11.3.63.1.2 RAN-INFORMATION-REQUEST Application Container for the SI3 Application */
1748 /* Reporting Cell Identifier */
1749 curr_offset = curr_offset + de_bssgp_cell_id(tvb, tree, pinfo, curr_offset, len, add_string, string_len);
1750 break;
1751 case 3:
1752 /* 11.3.63.1.3 RAN-INFORMATION-REQUEST Application Container for the MBMS data channel Application */
1753 /* Reporting Cell Identifier */
1754 curr_offset = curr_offset + de_bssgp_cell_id(tvb, tree, pinfo, curr_offset, len, add_string, string_len);
1755 break;
1756 case 4:
1758 asn1_ctx_t asn1_ctx;
1760 asn1_ctx_init(&asn1_ctx, ASN1_ENC_PER, TRUE, pinfo);
1761 /* 11.3.63.1.4 RAN-INFORMATION-REQUEST Application Container for the SON Transfer Application */
1762 /* Reporting Cell Identifier */
1763 /* convert to bit offset */
1764 bit_offset = curr_offset<<3;
1765 bit_offset = dissect_s1ap_Global_ENB_ID(tvb, bit_offset, &asn1_ctx, tree, hf_bssgp_Global_ENB_ID_PDU);
1766 /*bit_offset = */dissect_s1ap_SONtransferRequestContainer(tvb, bit_offset, &asn1_ctx, tree, hf_bssgp_SONtransferRequestContainer_PDU);
1767 curr_offset += 7; curr_offset >>= 3;
1769 break;
1770 case 5:
1771 /* 11.3.63.1.5 RAN-INFORMATION Application Container for the UTRA SI Application */
1772 /* Octet 3-m Reporting Cell Identifier
1773 * This field is encoded as the Source Cell Identifier IE (UTRAN Source Cell ID) as defined in
1774 * 3GPP TS 25.413
1776 new_tvb = tvb_new_subset_remaining(tvb, curr_offset);
1777 curr_offset = curr_offset + dissect_ranap_SourceCellID_PDU(new_tvb, pinfo, tree, NULL);
1778 break;
1779 default :
1780 proto_tree_add_text(tree, tvb, curr_offset, len, "Unknown RIM Application Identity");
1781 curr_offset+=len;
1782 break;
1786 return(curr_offset-offset);
1790 * 11.3.63.2 RAN-INFORMATION Application Container Unit
1791 * 11.3.63.2.0 General
1793 static const true_false_string bssgp_si_psi_type_vals = {
1794 "PSI messages as specified for PBCCH (3GPP TS 44.060) follow",
1795 "SI messages as specified for BCCH (3GPP TS 44.018) follow"
1798 static const value_string bssgp_rat_discriminator_vals[] = {
1799 { 0, "The reporting RAT is GERAN" },
1800 { 1, "The reporting RAT is UTRAN" },
1801 { 2, "The reporting RAT is E-UTRAN" },
1802 { 0, NULL },
1804 static guint16
1805 de_bssgp_ran_information_app_cont_unit(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1807 tvbuff_t *new_tvb = NULL;
1808 guint32 curr_offset;
1809 guint8 type, num_items, rat_type, oct;
1810 int i;
1812 curr_offset = offset;
1814 switch(g_rim_application_identity){
1815 case 1:
1816 /* 11.3.63.2.1 RAN-INFORMATION Application Container for the NACC Application */
1817 /* Reporting Cell Identifier */
1818 curr_offset = curr_offset + de_bssgp_cell_id(tvb, tree, pinfo, curr_offset, len, add_string, string_len);
1819 /* Number of SI/PSI */
1820 num_items = tvb_get_guint8(tvb,curr_offset)>>1;
1821 proto_tree_add_item(tree, hf_bssgp_num_si_psi, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1822 /* Type */
1823 type = tvb_get_guint8(tvb,curr_offset)&0x01;
1824 proto_tree_add_item(tree, hf_bssgp_si_psi_type, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1825 curr_offset++;
1826 /* Octet 12-n SI/PSI */
1827 if(type==1){
1828 /* If the Type field indicates that "PSI messages as specified for PBCCH (3GPP TS 44.060) follow" then the SI/PSI
1829 * field contains Packet System Information message instances encoded for PBCCH as specified in
1830 * 3GPP TS 44.060. Each Packet System Information message contains the MESSAGE_TYPE field followed by the
1831 * PSI message content. Each message is 22 octets long.
1833 for (i=0; i < num_items; i++){
1834 proto_tree_add_text(tree, tvb, curr_offset, 22, "PSI item %u - not dissected yet",i+1);
1835 curr_offset+=22;
1837 }else{
1838 /* If the Type field indicates that "SI messages as specified for BCCH (3GPP TS 44.018) follow" then the SI/PSI
1839 * field contains System Information message instances encoded for BCCH as specified in 3GPP TS 44.018. Each
1840 * System Information message contains the Message type octet followed by all the IEs composing the message
1841 * payload. Each message is 21 octets long.
1843 void (*msg_fcn_p)(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len);
1844 gint ett_tree;
1845 int hf_idx;
1846 const gchar *msg_str;
1847 proto_item *si_item;
1848 proto_tree *si_tree;
1850 for (i=0; i < num_items; i++){
1851 oct = tvb_get_guint8(tvb,curr_offset);
1852 get_rr_msg_params(oct, &msg_str, &ett_tree, &hf_idx, &msg_fcn_p);
1853 proto_tree_add_text(tree, tvb, curr_offset, 21, "SI item %u ",i+1);
1854 si_item = proto_tree_add_item(tree, hf_idx, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1855 si_tree = proto_item_add_subtree(si_item, ett_tree);
1856 if (msg_fcn_p == NULL){
1857 proto_tree_add_text(si_tree, tvb, curr_offset, 21, "Unknown SI message");
1858 }else{
1859 (*msg_fcn_p)(tvb, si_tree, pinfo, curr_offset+1, 20);
1861 curr_offset+=21;
1864 break;
1865 case 2:
1866 /* 11.3.63.2.2 RAN-INFORMATION Application Container for the SI3 Application */
1867 /* Octet 3-10 Reporting Cell Identifier */
1868 /* Reporting Cell Identifier: The parameter is encoded as the value part of the Cell Identifier IE
1869 * defined in sub-clause 11.3.9, not including IEI and Length Indicator.
1871 curr_offset = curr_offset + de_bssgp_cell_id(tvb, tree, pinfo, curr_offset, len, add_string, string_len);
1872 /* Octet 11-31 SI3 */
1873 /* SI3: contains the SYSTEM INFORMATION type 3 message encoded for BCCH as specified in 3GPP TS 44.018 ch 9.1.35
1874 * It contains the Message type octet followed by all the IEs composing the message payload.
1875 * The message is 21 octets long.
1876 * dtap_rr_sys_info_3(tvb, tree, curr_offset, len-7)
1878 proto_tree_add_text(tree, tvb, curr_offset, 1, "SYSTEM INFORMATION type 3 message");
1879 curr_offset++;
1880 break;
1881 case 3:
1882 /* 11.3.63.2.3 RAN-INFORMATION Application Container for the MBMS data channel Application */
1883 /* Octet 3-10 Reporting Cell Identifier */
1884 curr_offset = curr_offset + de_bssgp_cell_id(tvb, tree, pinfo, curr_offset, len, add_string, string_len);
1885 /* Octet 11-n MBMS data channel report */
1886 proto_tree_add_text(tree, tvb, curr_offset, len-6, "MBMS data channel report - not dissected yet");
1887 break;
1888 case 4:
1889 /* 11.3.63.2.4 RAN-INFORMATION Application Container for the SON Transfer Application */
1890 /* Octet 3 Spare RAT discriminator */
1891 rat_type = tvb_get_guint8(tvb,curr_offset) & 0x0f;
1892 proto_tree_add_item(tree, hf_bssgp_rat_discriminator, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1893 curr_offset++;
1894 /* Octet 4-m Reporting Cell Identifier */
1895 switch(rat_type){
1896 case 0:
1897 /* If the RAT discriminator field indicates GERAN, this field is encoded as the value part of the Cell Identifier IE
1898 * defined in sub-clause 11.3.9, not including IEI and Length Indicator.
1900 curr_offset = curr_offset + de_bssgp_cell_id(tvb, tree, pinfo, curr_offset, len, add_string, string_len);
1901 break;
1902 case 1:
1903 /* If the RAT discriminator field indicates UTRAN, this field is encoded as the Source Cell Identifier IE (UTRAN
1904 * Source Cell ID) as defined in 3GPP TS 25.413
1906 new_tvb = tvb_new_subset_remaining(tvb, curr_offset);
1907 curr_offset = curr_offset + dissect_ranap_SourceCellID_PDU(new_tvb, pinfo, tree, NULL);
1908 break;
1909 case 2:
1910 /* If the RAT discriminator field indicates E-UTRAN, this field is encoded as the E-UTRAN CGI IE as
1911 * defined in 3GPP TS 36.413
1913 new_tvb = tvb_new_subset_remaining(tvb, curr_offset);
1914 curr_offset = curr_offset + dissect_s1ap_Global_ENB_ID_PDU(new_tvb, pinfo, tree, NULL);
1915 break;
1916 default:
1917 break;
1920 break;
1921 case 5:
1922 /* 11.3.63.2.5 RAN-INFORMATION Application Container for the UTRA SI Application */
1923 /* Octet 3-m Reporting Cell Identifier
1924 * Reporting Cell Identifier: This field is encoded as the Source Cell Identifier IE
1925 * (UTRAN Source Cell ID) as defined in 3GPP TS 25.413
1927 new_tvb = tvb_new_subset_remaining(tvb, curr_offset);
1928 curr_offset = curr_offset + dissect_ranap_SourceCellID_PDU(new_tvb, pinfo, tree, NULL);
1929 /* Octet (m+1)-n UTRA SI Container
1930 * UTRA SI Container: This field contains System Information Container valid for the reporting cell
1931 * encoded as defined in TS 25.331
1933 proto_tree_add_text(tree, tvb, curr_offset, len-(curr_offset-offset), "UTRA SI Container - not dissected yet");
1934 break;
1936 default :
1937 proto_tree_add_text(tree, tvb, curr_offset, len, "Unknown RIM Application Identitys Data");
1938 curr_offset+=len;
1939 break;
1943 return(curr_offset-offset);
1946 * 11.3.64 Application Error Container
1948 static const value_string bssgp_nacc_cause_vals[] = {
1949 { 0, "Other unspecified error" },
1950 { 1, "Syntax error in the Application Container" },
1951 { 2, "Reporting Cell Identifier does not match with the Destination Cell Identifier or with the Source Cell Identifier" },
1952 { 3, "SI/PSI type error" },
1953 { 4, "Inconsistent length of a SI/PSI message" },
1954 { 5, "Inconsistent set of messages" },
1955 { 0, NULL },
1958 static const value_string bssgp_s13_cause_vals[] = {
1959 { 0, "Other unspecified error" },
1960 { 1, "Syntax error in the Application Container" },
1961 { 2, "Reporting Cell Identifier does not match with the Destination Cell Identifier or with the Source Cell Identifier" },
1962 { 3, "Inconsistent length of a SI3 message" },
1963 { 4, "Inconsistent set of messages" },
1964 { 0, NULL },
1967 static const value_string bssgp_mbms_data_ch_cause_vals[] = {
1968 { 0, "Other unspecified error" },
1969 { 1, "Syntax error in the Application Container" },
1970 { 2, "Reporting Cell Identifier does not match with the Destination Cell Identifier or with the Source Cell Identifier" },
1971 { 3, "RAN-INFORMATION/Initial Multiple Report or RANINFORMATION/Single Report PDU exceeds the maximum supported length" },
1972 { 4, "Inconsistent MBMS data channel description" },
1973 { 0, NULL },
1976 static const value_string bssgp_utra_si_cause_vals[] = {
1977 { 0, "Other unspecified error" },
1978 { 1, "Syntax error in the Application Container" },
1979 { 2, "Inconsistent Reporting Cell Identifier" },
1980 { 0, NULL },
1983 static guint16
1984 de_bssgp_ran_app_error_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
1986 tvbuff_t *new_tvb = NULL;
1987 guint32 curr_offset;
1989 curr_offset = offset;
1991 switch(g_rim_application_identity){
1992 case 1:
1994 * 11.3.64.1 Application Error Container layout for the NACC application
1996 /* Octet 3 NACC Cause */
1997 proto_tree_add_item(tree, hf_bssgp_nacc_cause, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
1998 curr_offset++;
1999 /* Erroneous Application Container including IEI and LI */
2000 proto_tree_add_text(tree, tvb, curr_offset, len-(curr_offset-offset), "Erroneous Application Container including IEI and LI");
2001 break;
2002 case 2:
2004 * 11.3.64.2 Application Error Container for the SI3 application
2006 /* Octet 3 SI3 Cause */
2007 proto_tree_add_item(tree, hf_bssgp_s13_cause, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2008 curr_offset++;
2009 /* Erroneous Application Container including IEI and LI */
2010 proto_tree_add_text(tree, tvb, curr_offset, len-(curr_offset-offset), "Erroneous Application Container including IEI and LI");
2011 break;
2012 case 3:
2014 * 11.3.64.3 Application Error Container for the MBMS data channel application
2016 /* Octet 3 MBMS data channel Cause */
2017 proto_tree_add_item(tree, hf_bssgp_mbms_data_ch_cause, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2018 curr_offset++;
2019 /* Erroneous Application Container including IEI and LI */
2020 proto_tree_add_text(tree, tvb, curr_offset, len-(curr_offset-offset), "Erroneous Application Container including IEI and LI");
2021 break;
2022 case 4:
2024 * 11.3.64.4 Application Error Container for the SON Transfer Application
2026 /* SON Transfer Cause: This field indicates the cause why the Application Error Container IE is sent.
2027 * The "SON Transfer Cause" field is encoded as the SON Transfer Cause IE as defined in 3GPP TS 36.413
2029 new_tvb = tvb_new_subset_remaining(tvb, curr_offset);
2030 curr_offset = curr_offset + dissect_s1ap_SONtransferCause_PDU(new_tvb, pinfo, tree, NULL);
2031 /* Erroneous Application Container including IEI and LI */
2032 proto_tree_add_text(tree, tvb, curr_offset, len-(curr_offset-offset), "Erroneous Application Container including IEI and LI");
2033 break;
2034 case 5:
2035 /* 11.3.64.5 Application Error Container for the UTRA SI Application*/
2036 /* Octet 3 UTRA SI Cause */
2037 proto_tree_add_item(tree, hf_bssgp_utra_si_cause, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2038 break;
2039 default :
2040 proto_tree_add_text(tree, tvb, curr_offset, len, "Unknown Application Error Container");
2041 break;
2043 return(len);
2047 * 11.3.65 RIM PDU Indications
2049 static const value_string bssgp_ran_inf_req_pdu_t_ext_c_vals[] = {
2050 { 0, "RAN-INFORMATION-REQUEST/Stop PDU" },
2051 { 1, "RAN-INFORMATION-REQUEST/Single Report PDU" },
2052 { 2, "RAN-INFORMATION-REQUEST/Multiple Report PDU" },
2053 { 3, "Reserved" },
2054 { 4, "Reserved" },
2055 { 5, "Reserved" },
2056 { 6, "Reserved" },
2057 { 7, "Reserved" },
2058 { 0, NULL },
2061 static const value_string bssgp_ran_inf_pdu_t_ext_c_vals[] = {
2062 { 0, "RAN-INFORMATION/Stop PDU" },
2063 { 1, "RAN-INFORMATION/Single Report PDU" },
2064 { 2, "RAN-INFORMATION/Initial Multiple Report PDU" },
2065 { 3, "RAN-INFORMATION/Multiple Report PDU" },
2066 { 4, "RAN-INFORMATION/End PDU" },
2067 { 5, "Reserved" },
2068 { 6, "Reserved" },
2069 { 7, "Reserved" },
2070 { 0, NULL },
2073 static const true_false_string bssgp_rim_pdu_ind_ack_vals = {
2074 "ACK requested",
2075 "No ACK requested"
2078 static guint16
2079 de_bssgp_rim_pdu_indications(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2081 guint32 curr_offset;
2083 curr_offset = offset;
2085 switch(g_pdu_type){
2086 case BSSGP_PDU_RAN_INFORMATION_REQUEST:
2087 /* 11.3.65.1 RAN-INFORMATION-REQUEST RIM PDU Indications */
2088 /* Table 11.3.65.1: RAN-INFORMATION-REQUEST PDU Type Extension coding */
2089 proto_tree_add_item(tree, hf_bssgp_ran_inf_req_pdu_t_ext_c, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2090 /* The ACK field is not used and shall be considered as spare */
2091 curr_offset++;
2092 break;
2093 case BSSGP_PDU_RAN_INFORMATION:
2094 /* 11.3.65.2 RAN-INFORMATION RIM PDU Indications */
2095 /* Table 11.3.65.2: RAN-INFORMATION PDU Type Extension coding */
2096 proto_tree_add_item(tree, hf_bssgp_ran_inf_pdu_t_ext_c, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2097 proto_tree_add_item(tree, hf_bssgp_rim_pdu_ind_ack, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2098 curr_offset++;
2099 break;
2100 case BSSGP_PDU_RAN_INFORMATION_APP_ERROR:
2101 /* 11.3.65.3 RAN-INFORMATION-APPLICATION-ERROR RIM PDU Indications */
2102 proto_tree_add_item(tree, hf_bssgp_rim_pdu_ind_ack, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2103 /* The PDU Type Extension field is not used and shall be considered as spare */
2104 curr_offset++;
2105 break;
2106 default:
2107 break;
2110 return(curr_offset-offset);
2114 * 11.3.65.0 General
2115 * 11.3.65.1 RAN-INFORMATION-REQUEST RIM PDU Indications
2116 * 11.3.65.2 RAN-INFORMATION RIM PDU Indications
2117 * 11.3.65.3 RAN-INFORMATION-APPLICATION-ERROR RIM PDU Indications
2118 * 11.3.66 (void)
2121 * 11.3.67 RIM Protocol Version Number
2123 static const value_string bssgp_rim_proto_ver_no_vals[] = {
2124 { 0, "Reserved" },
2125 { 1, "Version 1" },
2126 { 0, NULL },
2129 static guint16
2130 de_bssgp_rim_proto_ver_no(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2132 guint32 curr_offset;
2134 curr_offset = offset;
2136 /* Octet 3 RIM Protocol Version Number */
2137 proto_tree_add_item(tree, hf_bssgp_rim_proto_ver_no, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2138 curr_offset++;
2140 return(curr_offset-offset);
2144 * 11.3.68 PFC Flow Control parameters
2147 static guint16
2148 de_bssgp_pfc_flow_ctrl(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2150 proto_tree *pfc_tree;
2151 proto_item *pi, *ti2;
2153 guint32 curr_offset;
2154 guint8 num_pfc, i, pfc_len;
2155 gboolean b_pfc_included;
2157 curr_offset = offset;
2159 num_pfc = tvb_get_guint8(tvb, curr_offset);
2160 pi = proto_tree_add_text(tree, tvb, curr_offset, 1,
2161 "Number of PFCs: ");
2163 if (num_pfc < 12) {
2164 proto_item_append_text(pi, "%u", num_pfc);
2165 }else {
2166 proto_item_append_text(pi, "Reserved");
2167 return (curr_offset-offset);
2169 curr_offset++;
2170 if (num_pfc == 0)
2171 return (curr_offset-offset);
2173 pfc_len = (len - 1) / num_pfc;
2174 b_pfc_included = (pfc_len == 6);
2176 for (i = 0; i < num_pfc; i++) {
2177 ti2 = proto_tree_add_text(tree, tvb, curr_offset, pfc_len,
2178 "PFC (%u)", i + 1);
2179 pfc_tree = proto_item_add_subtree(ti2, ett_bssgp_pfc_flow_control_parameters_pfc);
2181 /* PFI: Packet Flow Identifier.
2182 * Coded as the value part of the Packet Flow Identifier information element in
2183 * 3GPP TS 24.008, not including 3GPP TS 24.008 IEI
2185 de_sm_pflow_id(tvb, pfc_tree, pinfo, curr_offset, 1, NULL, 0);
2186 curr_offset++;
2188 /* Bmax_PFC: Bucket size of the PFC. Coded like the value part of BVC Bucket Size, see sub-clause 11.3.5. */
2189 proto_tree_add_item(tree, hf_bssgp_bmax_pfc, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
2190 curr_offset += 2;
2192 /* R_PFC: Bucket Leak Rate of the PFC. Coded as the value part of Bucket Leak Rate (R), see sub-clause 11.3.4. */
2193 proto_tree_add_item(tree, hf_bssgp_r_pfc, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
2194 curr_offset += 2;
2196 if (b_pfc_included) {
2197 /* B_PFC: Bucket Full Ratio of the PFC. This field is only present if the Current Bucket Level (CBL) feature is
2198 * negotiated. Otherwise, the flow control parameters for the next PFC, if any, are provided instead. This field if coded as
2199 * the value part of the Bucket Full Ratio, see sub-clause 11.3.46.
2201 proto_tree_add_item(tree, hf_bssgp_b_pfc, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2202 curr_offset++;
2205 return(curr_offset-offset);
2208 * 11.3.69 Global CN-Id
2210 /* Coded as octets 3 to 7 of the Global CN-Id IE, defined in
2211 * 3GPP TS 29.018
2214 * 11.3.70 RIM Routing Information
2216 static const value_string bssgp_ra_discriminator_vals[] = {
2217 { 0, "A Cell Identifier is used to identify a GERAN cell" },
2218 { 1, "A Global RNC-ID is used to identify a UTRAN RNC" },
2219 { 2, "An eNB identifier is used to identify an E-UTRAN eNodeB or HeNB" },
2220 { 0, NULL },
2223 static guint16
2224 de_bssgp_rim_routing_inf(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2226 guint8 oct;
2227 guint16 rnc_id;
2228 tvbuff_t *new_tvb = NULL;
2229 guint32 curr_offset;
2231 curr_offset = offset;
2233 /* This information element uniquely identifies either a cell within a
2234 * GERAN BSS, a UTRAN RNC or an E-UTRAN eNodeB.
2237 /* RIM Routing Address discriminator */
2238 oct = tvb_get_guint8(tvb,curr_offset);
2239 proto_tree_add_item(tree, hf_bssgp_ra_discriminator, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2240 curr_offset++;
2241 switch(oct){
2242 case 0:
2243 /* RIM Routing Address discriminator = 0000:
2244 * The RIM Routing Address field contains a Cell Identifier
2245 * and is coded as the value part (octet 3 to octet 10) of the
2246 * Cell Identifier information element specified in sub-clause 11.3.9.
2248 de_bssgp_cell_id(tvb, tree, pinfo, curr_offset, len, add_string, string_len);
2249 break;
2250 case 1:
2251 /* RIM Routing Address discriminator = 0001:
2252 * The RIM Routing Address field contains an RNC identifier and is coded as follows:
2253 * Octets 4 to 9 contain the value part (starting with octet 2) of the Routing Area Identification IE
2254 * defined in 3GPP TS 24.008, not including 3GPP TS 24.008 IEI
2256 curr_offset = curr_offset + de_gmm_rai(tvb, tree, pinfo, curr_offset , 6, add_string, string_len);
2257 /* Octet 10 - 11 RNC-ID (or Extended RNC-ID) */
2258 rnc_id = tvb_get_ntohs(tvb, curr_offset);
2259 proto_tree_add_item(tree, hf_bssgp_rnc_id, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
2261 if (add_string)
2262 g_snprintf(add_string, string_len, " %s, RNC-ID %u", add_string, rnc_id);
2263 break;
2264 case 2:
2265 /* RIM Routing Address discriminator = 0010:
2266 * The RIM Routing Address field contains an eNB identifier and is coded as follows:
2267 * Octets 4 to 8 contain the value part (starting with octet 2) of the
2268 * Tracking Area Identity IE defined in 3GPP TS 24.301 [37], not including 3GPP TS 24.301 IEI
2270 curr_offset = curr_offset+ de_emm_trac_area_id(tvb, tree, pinfo, curr_offset, 5, add_string, string_len);
2271 /* Octets 9-n contain the Global eNB ID (see 3GPP TS 36.413 [36]) of the eNodeB. */
2272 new_tvb = tvb_new_subset_remaining(tvb, curr_offset);
2273 dissect_s1ap_Global_ENB_ID_PDU(new_tvb, pinfo, tree, NULL);
2274 break;
2275 default:
2276 proto_tree_add_text(tree, tvb, curr_offset, 3, "Unknown RIM Routing Address discriminator");
2277 return len;
2281 return len;
2285 * 11.3.71 MBMS Session Identity
2287 /* MBMS-Session-Identity AVP encoded as in 3GPP TS 29.061 [31],
2288 * excluding AVP Header fields as defined in IETF RFC 3588 [33].
2289 * TS 29.061
2290 * 17.7.11 MBMS-Session-Identity AVP
2291 * The MBMS-Session-Identity AVP (AVP code 908) is of type OctetString. Its length is one octet. It is allocated by the
2292 * BM-SC. Together with TMGI it identifies a transmission of a specific MBMS session. The initial transmission and
2293 * subsequent retransmissions of the MBMS session will use the same values of these parameters. This AVP is optional
2294 * within the Gmb interface.
2296 static guint16
2297 de_bssgp_mbms_session_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2299 guint32 curr_offset;
2301 curr_offset = offset;
2303 /* MBMS Session Identity */
2304 proto_tree_add_item(tree, hf_bssgp_mbms_session_id, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2305 curr_offset++;
2307 return(curr_offset-offset);
2310 * 11.3.72 MBMS Session Duration
2312 static guint16
2313 de_bssgp_mbms_session_dur(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2315 tvbuff_t *new_tvb;
2316 guint32 curr_offset;
2318 curr_offset = offset;
2320 /* AVP Code: 904 MBMS-Session-Duration Registered by packet-gtp.c */
2321 new_tvb =tvb_new_subset(tvb, offset, len, len);
2322 dissector_try_uint(diameter_3gpp_avp_dissector_table, 904, new_tvb, pinfo, tree);
2324 return(curr_offset-offset);
2327 * 11.3.73 MBMS Service Area Identity List
2328 * octet 3 - 514
2329 * MBMS-Service-Area AVP encoded as in 3GPP TS 29.061,
2330 * excluding AVP Header fields (as defined in IETF RFC 3588 [33]).
2333 static guint16
2334 de_bssgp_mbms_sai_list(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len, gchar *add_string _U_, int string_len _U_)
2336 tvbuff_t *new_tvb;
2337 guint32 curr_offset;
2339 curr_offset = offset;
2341 /* AVP Code: 903 MBMS-Service-Area Registered by packet-gtp.c */
2342 new_tvb =tvb_new_subset(tvb, offset, len, len);
2343 dissector_try_uint(diameter_3gpp_avp_dissector_table, 903, new_tvb, pinfo, tree);
2345 return(curr_offset-offset);
2348 * 11.3.74 MBMS Response
2351 static const value_string bssgp_mbms_cause_vals[] = {
2352 { 0, "Acknowledge" },
2353 { 1, "Acknowledge, initiate data transfer" },
2354 { 2, "Acknowledge, data transfer initiated from other SGSN" },
2355 { 3, "Reject - Congestion" },
2356 { 4, "Reject - None of the listed MBMS Service Areas are supported by BSS" },
2357 { 5, "Reject - MBMS Service Context is released due to interrupted data flow" },
2359 { 6, "Unspecified in this version of the protocol" },
2360 { 7, "Unspecified in this version of the protocol" },
2361 { 8, "Unspecified in this version of the protocol" },
2362 { 9, "Unspecified in this version of the protocol" },
2363 { 10, "Unspecified in this version of the protocol" },
2364 { 11, "Unspecified in this version of the protocol" },
2365 { 12, "Unspecified in this version of the protocol" },
2366 { 13, "Unspecified in this version of the protocol" },
2367 { 14, "Unspecified in this version of the protocol" },
2368 { 15, "Unspecified in this version of the protocol" },
2369 { 0, NULL },
2371 static value_string_ext bssgp_mbms_cause_vals_ext = VALUE_STRING_EXT_INIT(bssgp_mbms_cause_vals);
2373 static guint16
2374 de_bssgp_mbms_response(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2376 guint32 curr_offset;
2378 curr_offset = offset;
2380 /* MBMS Session Identity */
2381 proto_tree_add_item(tree, hf_bssgp_mbms_cause, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2382 curr_offset++;
2384 return(curr_offset-offset);
2387 * 11.3.75 MBMS Routing Area List
2389 /* Number of Routing Areas (octet 3) */
2390 static const value_string bssgp_mbms_num_ra_ids_vals[] = {
2391 { 0, "Notification shall not be sent to any Routing Areas in the BSS" },
2392 { 1, "'1' Routing Area Identities" },
2393 { 2, "'1' Routing Area Identities" },
2394 { 3, "'1' Routing Area Identities" },
2395 { 4, "'1' Routing Area Identities" },
2396 { 5, "'1' Routing Area Identities" },
2397 { 6, "'1' Routing Area Identities" },
2398 { 7, "'1' Routing Area Identities" },
2399 { 8, "'1' Routing Area Identities" },
2400 { 9, "'1' Routing Area Identities" },
2401 { 10, "'1' Routing Area Identities" },
2402 { 11, "'1' Routing Area Identities" },
2403 { 12, "'1' Routing Area Identities" },
2404 { 13, "'1' Routing Area Identities" },
2405 { 14, "'1' Routing Area Identities" },
2406 { 15, "Notification shall be sent in all Routing Areas in the BSS" },
2407 { 0, NULL },
2409 static value_string_ext bssgp_mbms_num_ra_ids_vals_ext = VALUE_STRING_EXT_INIT(bssgp_mbms_num_ra_ids_vals);
2411 static guint16
2412 de_bssgp_mbms_ra_list(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2414 proto_item *ti;
2415 proto_tree *rai_tree;
2416 guint32 curr_offset;
2417 guint8 num_ra_ids;
2418 int i;
2420 curr_offset = offset;
2422 /* octet 3 Number of Routing Area Identifications Spare Spare Spare Spare */
2423 num_ra_ids = tvb_get_guint8(tvb,curr_offset) >> 4;
2424 proto_tree_add_item(tree, hf_bssgp_mbms_num_ra_ids, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2426 /* octet 4 - 11 Routing Area Identification 1 (etc)*/
2427 for (i = 0; i < num_ra_ids; i++) {
2428 ti = proto_tree_add_text(tree, tvb, curr_offset, 8, "Routing Area Identification (%u)", i + 1);
2429 rai_tree = proto_item_add_subtree(ti, ett_bssgp_ra_id);
2431 /* The element is coded as the Routing Area Identification information element in
2432 * 3GPP TS 24.008, not including 3GPP TS 24.008 IEI and 3GPP TS 24.008 length indicator.
2434 de_gmm_rai(tvb, rai_tree, pinfo, curr_offset , 6, NULL, 0);
2436 curr_offset+=8;
2439 return(curr_offset-offset);
2443 * 11.3.76 MBMS Session Information
2446 static const true_false_string tfs_bssgp_bc_mc = {
2447 "Multicast Session",
2448 "Broadcast Session"
2450 static guint16
2451 de_bssgp_mbms_session_inf(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2453 guint32 curr_offset;
2455 curr_offset = offset;
2457 /* MBMS Session Identity */
2458 proto_tree_add_item(tree, hf_bssgp_session_inf, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2459 curr_offset++;
2461 return(curr_offset-offset);
2464 * 11.3.77 TMGI (Temporary Mobile Group Identity)
2466 /* Rest of element coded as in 3GPP TS 24.008, not including 3GPP
2467 * TS 24.008 IEI and 3GPP TS 24.008 length indicator.
2470 * 11.3.78 MBMS Stop Cause
2472 static const value_string bssgp_mbms_stop_cause_vals[] = {
2473 { 0, "MBMS Session terminated by upstream node" },
2474 { 1, "MBMS Session terminated by SGSN" },
2476 { 2, "Unspecified in this version of the protocol" },
2477 { 3, "Unspecified in this version of the protocol" },
2478 { 4, "Unspecified in this version of the protocol" },
2479 { 5, "Unspecified in this version of the protocol" },
2480 { 6, "Unspecified in this version of the protocol" },
2481 { 7, "Unspecified in this version of the protocol" },
2482 { 8, "Unspecified in this version of the protocol" },
2483 { 9, "Unspecified in this version of the protocol" },
2484 { 10, "Unspecified in this version of the protocol" },
2485 { 11, "Unspecified in this version of the protocol" },
2486 { 12, "Unspecified in this version of the protocol" },
2487 { 13, "Unspecified in this version of the protocol" },
2488 { 14, "Unspecified in this version of the protocol" },
2489 { 15, "Unspecified in this version of the protocol" },
2490 { 0, NULL },
2492 static value_string_ext bssgp_mbms_stop_cause_vals_ext = VALUE_STRING_EXT_INIT(bssgp_mbms_stop_cause_vals);
2494 static guint16
2495 de_bssgp_mbms_stop_cause(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2497 guint32 curr_offset;
2499 curr_offset = offset;
2501 /* MBMS Session Identity */
2502 proto_tree_add_item(tree, hf_bssgp_mbms_stop_cause, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2503 curr_offset++;
2505 return(curr_offset-offset);
2508 * 11.3.79 Source BSS to Target BSS Transparent Container
2510 /* The actual function moved to after defining the enums */
2513 * 11.3.80 Target BSS to Source BSS Transparent Container
2516 * 11.3.81 NAS container for PS Handover
2519 * 11.3.82 PFCs to be set-up list
2521 static guint16
2522 de_bssgp_pfcs_to_be_set_up_list(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2524 proto_tree *pfc_tree, *pft_tree, *abqp_tree, *arp_tree, *t10_tree;
2525 proto_item *pi, *ti2;
2527 guint32 curr_offset;
2528 guint8 num_pfc, i, pfc_len;
2530 curr_offset = offset;
2532 num_pfc = tvb_get_guint8(tvb, curr_offset);
2533 pi = proto_tree_add_text(tree, tvb, curr_offset, 1,
2534 "Number of PFCs: ");
2536 if (num_pfc < 12) {
2537 proto_item_append_text(pi, "%u", num_pfc);
2538 }else {
2539 proto_item_append_text(pi, "Reserved");
2540 return (len);
2542 curr_offset++;
2543 if (num_pfc == 0)
2544 return (curr_offset-offset);
2546 pfc_len = (len - 1) / num_pfc;
2548 for (i = 0; i < num_pfc; i++) {
2549 ti2 = proto_tree_add_text(tree, tvb, curr_offset, pfc_len,
2550 "PFC (%u)", i + 1);
2551 pfc_tree = proto_item_add_subtree(ti2, ett_bssgp_pfcs_to_be_set_up_list);
2553 de_sm_pflow_id(tvb, pfc_tree, pinfo, curr_offset, 1, NULL, 0);
2554 curr_offset++;
2556 /* PFT: Packet Flow Timer. Coded as the GPRS Timer information element,
2557 * see sub-clause 11.3.44.
2559 proto_tree_add_text(pfc_tree, tvb, curr_offset, 3, "Packet Flow Timer(PFT)");
2560 pft_tree = proto_item_add_subtree(ti2, ett_bssgp_pfcs_to_be_set_up_list_pft);
2561 proto_tree_add_item(pft_tree, hf_bssgp_unit_val, tvb, curr_offset, 3, ENC_BIG_ENDIAN);
2562 proto_tree_add_item(pft_tree, hf_bssgp_gprs_timer, tvb, curr_offset, 3, ENC_BIG_ENDIAN);
2563 curr_offset += 3;
2565 /* ABQP: Aggregate BSS QoS Profile.
2566 * Coded as the Aggregate BSS QoS Profile information element, see sub-clause 11.3.43.
2568 proto_tree_add_text(pfc_tree, tvb, curr_offset, 3, "Aggregate BSS QoS Profile(ABQP)");
2569 abqp_tree = proto_item_add_subtree(ti2, ett_bssgp_pfcs_to_be_set_up_list_abqp);
2570 /* Unsure about length 16 */
2571 curr_offset = curr_offset + de_sm_qos(tvb, abqp_tree, pinfo, curr_offset, 16, NULL, 0);
2573 /* Allocation/Retention Priority: Allocation Retention Priority.
2574 * Coded as the Priority information element, see subclause 11.3.27.
2575 * This information element is optionally included.
2577 if(pfc_len>17){
2578 proto_tree_add_text(pfc_tree, tvb, curr_offset, 3, "Allocation/Retention Priority");
2579 arp_tree = proto_item_add_subtree(ti2, ett_bssgp_pfcs_to_be_set_up_list_arp);
2580 curr_offset = curr_offset + be_prio(tvb, arp_tree, pinfo, curr_offset, 1, NULL, 0);
2582 /* T10: T10.
2583 * Coded as the GPRS Timer information element, see sub-clause 11.3.44.
2584 * This information element shall be present for a PFC if the Allocation/Retention Priority
2585 * is present and if queuing is allowed for the PFC.
2587 if(pfc_len>18){
2588 proto_tree_add_text(pfc_tree, tvb, curr_offset, 3, "T10");
2589 t10_tree = proto_item_add_subtree(ti2, ett_bssgp_pfcs_to_be_set_up_list_t10);
2590 proto_tree_add_item(t10_tree, hf_bssgp_unit_val, tvb, curr_offset, 3, ENC_BIG_ENDIAN);
2591 proto_tree_add_item(t10_tree, hf_bssgp_gprs_timer, tvb, curr_offset, 3, ENC_BIG_ENDIAN);
2592 curr_offset += 3;
2595 return(curr_offset-offset);
2598 * 11.3.83 List of set-up PFCs
2600 static guint16
2601 de_bssgp_list_of_setup_pfcs(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2603 proto_tree *pfc_tree;
2604 proto_item *pi, *ti2;
2606 guint32 curr_offset;
2607 guint8 num_pfc, i;
2609 curr_offset = offset;
2611 num_pfc = tvb_get_guint8(tvb, curr_offset);
2612 pi = proto_tree_add_text(tree, tvb, curr_offset, 1,
2613 "Number of PFCs: ");
2615 if (num_pfc < 12) {
2616 proto_item_append_text(pi, "%u", num_pfc);
2617 }else {
2618 proto_item_append_text(pi, "Reserved");
2619 return (curr_offset-offset);
2621 curr_offset++;
2622 if (num_pfc == 0)
2623 return (curr_offset-offset);
2625 for (i = 0; i < num_pfc; i++) {
2626 ti2 = proto_tree_add_text(tree, tvb, curr_offset, 1,
2627 "PFC (%u)", i + 1);
2628 pfc_tree = proto_item_add_subtree(ti2, ett_bssgp_list_of_setup_pfcs);
2630 de_sm_pflow_id(tvb, pfc_tree, pinfo, curr_offset, 1, NULL, 0);
2631 curr_offset++;
2635 return(curr_offset-offset);
2638 * 11.3.84 Extended Feature Bitmap
2640 static guint16
2641 de_bssgp_ext_feature_bitmap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2643 guint32 curr_offset;
2645 curr_offset = offset;
2647 /* Gigabit Interface */
2648 proto_tree_add_item(tree, hf_bssgp_gb_if, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2649 /* PS Handover */
2650 proto_tree_add_item(tree, hf_bssgp_ps_ho, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2651 curr_offset++;
2653 return(curr_offset-offset);
2656 * 11.3.85 Source to Target Transparent Container
2658 static guint16
2659 de_bssgp_src_to_trg_transp_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2661 guint32 curr_offset;
2663 curr_offset = offset;
2665 /* Octets 3-? Source to Target Transparent Container content coded as
2666 * specified in 3GPP TS 25.413 or 3GPP TS 36.413.
2667 * In inter-RAT handovers ... RANAP specification 3GPP TS 25.413, excluding RANAP tag.
2668 * In inter-RAT handover to E-UTRAN ... encoding is defined in 3GPP TS 36.413
2670 proto_tree_add_item(tree, hf_bssgp_src_to_trg_transp_cont, tvb, curr_offset, len, ENC_NA);
2672 return(len);
2676 * 11.3.86 Target to Source Transparent Container
2678 static guint16
2679 de_bssgp_trg_to_src_transp_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2681 guint32 curr_offset;
2683 curr_offset = offset;
2685 /* Rest of element coded as either a complete Handover to UTRAN
2686 * Command radio interface message (as defined in 3GPP TS
2687 * 25.331) or a complete Radio Bearer Reconfiguration radio
2688 * interface message (as defined in 3GPP TS 44.118) or a complete
2689 * DL-DCCH-Message including a complete
2690 * RRCConnectionReconfiguration radio interface message (as
2691 * defined in 3GPP TS 36.331)
2693 proto_tree_add_item(tree, hf_bssgp_trg_to_src_transp_cont, tvb, curr_offset, len, ENC_NA);
2695 return(len);
2699 * 11.3.87 RNC Identifier
2701 static guint16
2702 de_bssgp_rnc_identifier(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2704 guint32 curr_offset;
2705 guint16 rnc_id;
2707 curr_offset = offset;
2708 /* Octets 3-8 Octets 3 to 8 contain the value part (starting with octet 2) of the
2709 * Routing Area Identification IE defined in 3GPP TS 24.008, not including 3GPP TS 24.008 IEI
2711 curr_offset = curr_offset + de_gmm_rai(tvb, tree, pinfo, curr_offset, 6, add_string, string_len);
2712 /* Octet 9 - 10 RNC ID (or Extended RNC-ID or Corresponding RNC-ID) */
2713 rnc_id = tvb_get_ntohs(tvb, curr_offset);
2714 proto_tree_add_item(tree, hf_bssgp_rnc_id, tvb, curr_offset, 2, ENC_BIG_ENDIAN);
2715 curr_offset+=2;
2717 if (add_string)
2718 g_snprintf(add_string, string_len, " %s, RNC-ID %u", add_string, rnc_id);
2720 return(curr_offset-offset);
2724 * 11.3.88 Page Mode
2726 /* PAGE_MODE (2 bit field) */
2728 static const value_string bssgp_page_mode_vals[] = {
2729 { 0, "Normal Paging" },
2730 { 1, "Extended Paging" },
2731 { 2, "Paging Reorganization" },
2732 { 3, "Same as before" },
2733 { 0, NULL },
2735 static guint16
2736 de_bssgp_page_mode(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2738 guint32 curr_offset;
2740 curr_offset = offset;
2742 proto_tree_add_item(tree, hf_bssgp_page_mode, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2743 curr_offset++;
2745 return(curr_offset-offset);
2748 * 11.3.89 Container ID
2750 static guint16
2751 de_bssgp_container_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2753 guint32 curr_offset;
2755 curr_offset = offset;
2757 proto_tree_add_item(tree, hf_bssgp_container_id, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2758 curr_offset++;
2760 return(curr_offset-offset);
2764 * 11.3.90 Global TFI
2766 static const value_string bssgp_global_tfi_vals[] = {
2767 { 0, "UPLINK_TFI" },
2768 { 1, "DOWNLINK_TFI" },
2769 { 0, NULL },
2772 static guint16
2773 de_bssgp_global_tfi(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2775 guint32 curr_offset;
2776 guint32 bit_offset;
2777 guint8 gtfi;
2779 curr_offset = offset;
2781 /* Bits 6 - 1 Global TFI coded as specified in 3GPP TS 44.060 */
2782 bit_offset = (curr_offset << 3) +3;
2783 gtfi = tvb_get_bits8(tvb,bit_offset,1);
2784 proto_tree_add_bits_item(tree, hf_bssgp_global_tfi, tvb, bit_offset, 1, ENC_BIG_ENDIAN);
2785 bit_offset++;
2786 /* < Global TFI IE > ::=
2787 * { 0 < UPLINK_TFI : bit (5) >
2788 * | 1 < DOWNLINK_TFI : bit (5) > } ;
2790 if(gtfi == 0){
2791 /* UPLINK_TFI (5 bit field)
2792 * This field identifies an uplink TBF. This field is coded the same as the
2793 * TFI field defined in sub-clause 12.15.
2794 * This field is encoded as a binary number. Range 0 to 31
2796 proto_tree_add_bits_item(tree, hf_bssgp_ul_tfi, tvb, bit_offset, 1, ENC_BIG_ENDIAN);
2797 }else{
2798 /* DOWNLINK_TFI (5 bit field)
2799 * This field identifies an uplink TBF. This field is coded the same as the
2800 * TFI field defined in sub-clause 12.15.
2801 * This field is encoded as a binary number. Range 0 to 31
2803 proto_tree_add_bits_item(tree, hf_bssgp_dl_tfi, tvb, bit_offset, 1, ENC_BIG_ENDIAN);
2805 curr_offset++;
2807 return(curr_offset-offset);
2810 * 11.3.91 IMEI
2812 /* Octets 3-10 contain the IMEI coded as the value part of the Mobile
2813 * Identity IE defined in 3GPP TS 24.008
2814 * (NOTE 1)
2817 * 11.3.92 Time to MBMS Data Transfer
2819 static guint16
2820 de_bssgp_time_to_MBMS_data_tran(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2822 guint32 curr_offset;
2823 guint8 value;
2825 curr_offset = offset;
2827 /* 0 = 1s etc */
2828 value = tvb_get_guint8(tvb,curr_offset) + 1;
2829 proto_tree_add_uint(tree, hf_bssgp_time_to_MBMS_data_tran, tvb, curr_offset, 1, value);
2831 return(len);
2834 * 11.3.93 MBMS Session Repetition Number
2836 static guint16
2837 de_bssgp_mbms_session_rep_no(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2839 guint32 curr_offset;
2841 curr_offset = offset;
2843 proto_tree_add_item(tree, hf_bssgp_mbms_session_rep_no, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2844 curr_offset++;
2846 return(len);
2849 * 11.3.94 Inter RAT Handover Info
2851 static guint16
2852 de_bssgp_inter_rat_ho_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2854 tvbuff_t *new_tvb;
2855 guint32 curr_offset;
2857 curr_offset = offset;
2859 new_tvb = tvb_new_subset_remaining(tvb, curr_offset);
2861 * Inter RAT Handover Information coded as specified in 3GPP
2862 * Technical Specification 25.331
2864 dissect_rrc_InterRATHandoverInfo_PDU(new_tvb, pinfo, tree, NULL);
2866 return(len);
2869 * 11.3.95 PS Handover Command
2871 static guint16
2872 de_bssgp_ps_ho_cmd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2874 guint32 curr_offset;
2876 curr_offset = offset;
2878 /* Octet 3-? Rest of element coded as a complete PS Handover Command
2879 * radio interface message as defined in 3GPP TS 44.060 (carrying
2880 * the PS Handover to A/Gb Mode Payload)
2882 proto_tree_add_item(tree, hf_bssgp_ps_ho_cmd, tvb, curr_offset, len, ENC_NA);
2885 return(len);
2889 * 11.3.95a PS Handover Indications
2891 static guint16
2892 de_bssgp_ps_ho_indications(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2894 guint32 curr_offset;
2896 curr_offset = offset;
2898 /* SI/PSI */
2899 proto_tree_add_item(tree, hf_bssgp_sipsi, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2900 curr_offset++;
2902 return(curr_offset-offset);
2906 * 11.3.95b SI/PSI Container
2909 static const value_string type_vals[] = {
2910 { 0, "SI messages as specified for BCCH (3GPP TS 44.018) follow" },
2911 { 1, "PSI messages as specified for PBCCH (3GPP TS 44.060) follow" },
2912 { 0, NULL },
2914 static guint16
2915 de_bssgp_sipsi_container(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2917 guint32 curr_offset;
2918 guint8 oct,num, type, i;
2920 curr_offset = offset;
2922 oct = tvb_get_guint8(tvb, curr_offset);
2923 num = oct >>1;
2924 type = oct & 1;
2925 proto_tree_add_text(tree, tvb, curr_offset, 1,
2926 "Number of SI/PSI: %u",num);
2928 /* Type */
2929 proto_tree_add_item(tree, hf_bssgp_type, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
2930 curr_offset++;
2931 if (type==0){
2932 /* BCCH (3GPP TS 44.018) */
2933 for (i = 0; i < num; i++) {
2934 proto_tree_add_text(tree, tvb, curr_offset, 21, "SI (%u)", i + 1);
2935 curr_offset+=21;
2937 }else{
2938 /* PBCCH (3GPP TS 44.060) */
2939 for (i = 0; i < num; i++) {
2940 proto_tree_add_text(tree, tvb, curr_offset, 22, "PSI (%u)", i + 1);
2941 curr_offset+=22;
2945 return(curr_offset-offset);
2948 * 11.3.95c Active PFCs List
2950 static guint16
2951 de_bssgp_active_pfcs_list(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
2953 proto_tree *pfc_tree;
2954 proto_item *pi, *ti2;
2956 guint32 curr_offset;
2957 guint8 num_pfc, i;
2959 curr_offset = offset;
2961 num_pfc = tvb_get_guint8(tvb, curr_offset);
2962 pi = proto_tree_add_text(tree, tvb, curr_offset, 1,
2963 "Number of PFCs: ");
2965 if (num_pfc < 12) {
2966 proto_item_append_text(pi, "%u", num_pfc);
2967 }else {
2968 proto_item_append_text(pi, "Reserved");
2969 return (curr_offset-offset);
2971 curr_offset++;
2972 if (num_pfc == 0)
2973 return (curr_offset-offset);
2975 for (i = 0; i < num_pfc; i++) {
2976 ti2 = proto_tree_add_text(tree, tvb, curr_offset, 1, "PFC (%u)", i + 1);
2977 pfc_tree = proto_item_add_subtree(ti2, ett_bssgp_pfc_flow_control_parameters_pfc);
2979 de_sm_pflow_id(tvb, pfc_tree, pinfo, curr_offset, 1, NULL, 0);
2980 curr_offset++;
2984 return(curr_offset-offset);
2987 * 11.3.96 Velocity Data
2989 static guint16
2990 de_bssgp_velocity_data(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len, gchar *add_string, int string_len)
2992 guint32 curr_offset;
2994 curr_offset = offset;
2996 /* The rest of the information element contains an octet sequence
2997 * identical to that for Description of Velocity defined in 3GPP TS
2998 * 23.032.
3000 curr_offset = dissect_description_of_velocity(tvb, tree, pinfo, curr_offset, len, add_string, string_len);
3002 return(curr_offset-offset);
3005 * 11.3.97 DTM Handover Command
3007 static guint16
3008 de_bssgp_dtm_ho_cmd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3010 guint32 curr_offset;
3012 curr_offset = offset;
3014 /* Rest of element coded as a complete DTM Handover Command
3015 * radio interface message as defined in 3GPP TS 44.060 (carrying
3016 * the DTM Handover to A/Gb Mode Payload)
3018 proto_tree_add_text(tree, tvb, curr_offset, len, "DTM Handover Command data");
3020 return(len);
3023 * 11.3.98 CS Indication
3025 static guint16
3026 de_bssgp_cs_indication(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3028 guint32 curr_offset;
3030 curr_offset = offset;
3032 /* CS Indication Contents
3033 * CS Indication Contents: This identifies a particular handover attempt for this MS. This shall be identical to the PS
3034 * Indication Contents value in the corresponding PS Indication IE included in the Old BSS to New BSS Information IE
3035 * (see 3GPP TS 48.008). The choice of the value of this field is implementation specific, with the requirement that
3036 * consecutive handover attempts for the same mobile station shall not have the same CS Indication Contents value.
3038 proto_tree_add_item(tree, hf_bssgp_cs_indication, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
3039 curr_offset++;
3041 return(curr_offset-offset);
3044 * 11.3.99 Requested GANSS Assistance Data
3046 /* Rest of element coded as the value part defined in
3047 * 3GPP TS 49.031, not including 3GPP TS 49.031 IEI and
3048 * 3GPP TS 49.031 octet length indicator
3051 * 11.3.100 GANSS Location Type
3053 /* Rest of element coded as the value part defined in
3054 * 3GPP TS 49.031, not including 3GPP TS 49.031 IEI and
3055 * 3GPP TS 49.031 octet length indicator
3058 * 11.3.101 GANSS Positioning Data
3060 /* Rest of element coded as the value part defined in
3061 * 3GPP TS 49.031, not including 3GPP TS 49.031 IEI and
3062 * 3GPP TS 49.031 octet length indicator
3065 * 11.3.102 Flow Control Granularity
3067 static const value_string bssgp_flow_control_gran_vals[] = {
3068 { 0, "100 octets or bits/s increments" },
3069 { 1, "1000 octets or bits/s increments" },
3070 { 2, "10000 octets or bits/s increments" },
3071 { 3, "100000 octets or bits/s increments" },
3072 { 0, NULL },
3076 static guint16
3077 de_bssgp_flow_control_gran(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3079 guint32 curr_offset;
3081 curr_offset = offset;
3083 /* Granularity */
3084 proto_tree_add_item(tree, hf_bssgp_flow_control_gran, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
3085 curr_offset++;
3087 return(curr_offset-offset);
3090 * 11.3.103 eNB Identifier
3092 static guint16
3093 de_bssgp_enb_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string, int string_len)
3095 tvbuff_t *new_tvb;
3096 guint32 curr_offset;
3098 curr_offset = offset;
3100 /* Octets 3 to 7 contain the value part (starting with octet 2) of the
3101 * Tracking Area Identity IE defined in 3GPP TS 24.301 [37], not
3102 * including 3GPP TS 24.301 IEI [37]
3104 curr_offset = curr_offset+ de_emm_trac_area_id(tvb, tree, pinfo, curr_offset, 5, add_string, string_len);
3106 /* Octets 8-n contain the Global eNB ID (see 3GPP TS 36.413) of the eNodeB. */
3107 new_tvb = tvb_new_subset_remaining(tvb, curr_offset);
3108 dissect_s1ap_Global_ENB_ID_PDU(new_tvb, pinfo, tree, NULL);
3110 return(len);
3113 * 11.3.104 E-UTRAN Inter RAT Handover Info
3115 static guint16
3116 de_bssgp_e_utran_inter_rat_ho_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3118 tvbuff_t *new_tvb;
3119 guint32 curr_offset;
3121 curr_offset = offset;
3123 new_tvb = tvb_new_subset_remaining(tvb, curr_offset);
3125 * Formatted and coded according to the UE-EUTRA-Capability IE
3126 * defined in 3GPP Technical Specification 36.331. The most
3127 * significant bit of the first octet of the octet string contains bit 8 of
3128 * the first octet of the IE.
3130 dissect_lte_rrc_UE_EUTRA_Capability_PDU(new_tvb, pinfo, tree, NULL);
3132 return(len);
3135 * 11.3.105 Subscriber Profile ID for RAT/Frequency priority
3138 static guint16
3139 de_bssgp_sub_prof_id_f_rat_freq_prio(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3141 guint32 curr_offset;
3142 guint8 value;
3144 curr_offset = offset;
3146 /* Octet 3 contains a number in binary representation ranging from 0 to 255.
3147 * The Subscriber Profile ID for RAT/Frequency priority is given by
3148 * the indicated value +1.
3150 value = tvb_get_guint8(tvb,curr_offset) + 1;
3151 proto_tree_add_uint(tree, hf_bssgp_sub_prof_id_f_rat_freq_prio, tvb, curr_offset, 1, value);
3152 curr_offset++;
3154 return(curr_offset-offset);
3157 * 11.3.106 Request for Inter-RAT Handover Info
3159 static guint16
3160 de_bssgp_req_for_inter_rat_ho_inf(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3162 guint32 curr_offset;
3164 curr_offset = offset;
3166 /*octet 3 Spare E-UTRAN Inter RAT Handover Info Req Inter RAT Handover Info Req */
3167 proto_tree_add_item(tree, hf_bssgp_eutran_irat_ho_inf_req, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
3168 proto_tree_add_item(tree, hf_bssgp_irat_ho_inf_req, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
3169 curr_offset++;
3171 return(curr_offset-offset);
3174 * 11.3.107 Reliable Inter-RAT Handover Info
3176 static guint16
3177 de_bssgp_reliable_inter_rat_ho_inf(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3179 guint32 curr_offset;
3181 curr_offset = offset;
3183 /* Reliable Inter RAT Handover Info Indicator */
3184 proto_tree_add_item(tree, hf_bssgp_rel_int_rat_ho_inf_ind, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
3185 curr_offset++;
3187 return(curr_offset-offset);
3190 * 11.3.108 SON Transfer Application Identity
3192 static guint16
3193 de_bssgp_son_transfer_app_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset _U_, guint len _U_, gchar *add_string _U_, int string_len _U_)
3195 tvbuff_t *next_tvb;
3197 /* SON Transfer Application Identity: This field is encoded as the SON Transfer Application Identity IE
3198 * as defined in 3GPP TS 36.413
3200 if(len > 0){
3201 next_tvb = tvb_new_subset(tvb, offset, len, len);
3202 dissect_s1ap_SONtransferApplicationIdentity_PDU(next_tvb, pinfo, tree, NULL);
3205 return(len);
3208 * 11.3.109 CSG Identifier
3211 /* Cell Access Mode (bit 1 of octet 7) */
3212 static const value_string bssgp_cell_access_mode_vals[] = {
3213 { 0, "CSG cell" },
3214 { 1, "Hybrid cell" },
3215 { 0, NULL },
3218 static guint16
3219 de_bssgp_csg_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3221 guint32 curr_offset;
3223 curr_offset = offset;
3225 /* Octets 3 to 6 contain the CSG Identity (CSG-ID) of the cell (defined in
3226 * 3GPP TS 23.003) as reported by the mobile station (see 3GPP TS
3227 * 44.060). Bits 4 to 8 of octet 6 are spare and set to zero.
3229 proto_tree_add_item(tree, hf_bssgp_csg_id, tvb, curr_offset, 4, ENC_BIG_ENDIAN);
3230 curr_offset+=4;
3231 /* Cell Access Mode */
3232 proto_tree_add_item(tree, hf_bssgp_cell_acc_mode, tvb, curr_offset, 4, ENC_BIG_ENDIAN);
3233 curr_offset++;
3235 return(curr_offset-offset);
3238 * 11.3.110 Tracking Area Code
3241 * Octets 3 to 5 contain the value part (starting with octet 2) of the TAC
3242 * IE defined in 3GPP TS 24.301.
3246 * 11.3.111 Redirect Attempt Flag
3248 static guint16
3249 de_bssgp_redir_attempt_flg(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3251 guint32 curr_offset;
3253 curr_offset = offset;
3255 proto_tree_add_text(tree, tvb, curr_offset, 1,"Spare");
3256 curr_offset += 1;
3258 return(curr_offset-offset);
3262 * 11.3.112 Redirection Indication
3264 static const value_string bssgp_redir_indiction_reroute_reject_cause_vals[] = {
3265 {0x00, "Reserved"},
3266 {0x01, "Reserved"},
3267 {0x02, "Reserved"},
3268 {0x03, "Reserved"},
3269 {0x04, "Reserved"},
3270 {0x05, "Reserved"},
3271 {0x06, "Reserved"},
3272 {0x07, "Reserved"},
3273 {0x08, "Reserved"},
3274 {0x09, "Reserved"},
3275 {0x0A, "Reserved"},
3276 {0x0B, "PLMN not allowed"},
3277 {0x0C, "Location area not allowed"},
3278 {0x0D, "Roaming not allowed in this location area"},
3279 {0x0E, "GPRS services not allowed in this PLMN"},
3280 {0x0F, "No suitable cell in location area"},
3281 {0x10, "CS/PS domain registration coordination required"},
3282 /* {0x11~0xFF, "Reserved"} */
3283 { 0, NULL },
3286 static guint16
3287 de_bssgp_redir_indication(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3289 guint32 curr_offset;
3291 curr_offset = offset;
3293 proto_tree_add_item(tree, hf_bssgp_redir_indiction_reroute_reject_cause, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
3294 curr_offset += 1;
3296 return(curr_offset-offset);
3300 * 11.3.113 Redirection Completed
3302 static const value_string bssgp_redir_complete_outcome_vals[] = {
3303 {0x00, "Reserved"},
3304 {0x01, "MS is accepted"},
3305 {0x02, "MS is not accepted"},
3306 {0x03, "MS is already registered"},
3307 /* {0x04~0xFF, "Reserved"} */
3308 { 0, NULL },
3311 static guint16
3312 de_bssgp_redir_complete(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3314 guint32 curr_offset;
3316 curr_offset = offset;
3318 proto_tree_add_item(tree, hf_bssgp_redir_complete_outcome, tvb, curr_offset, 1, ENC_BIG_ENDIAN);
3319 curr_offset += 1;
3321 return(curr_offset-offset);
3325 * 11.3.114 Unconfirmed send state variable
3327 static guint16
3328 de_bssgp_unconfim_send_state_var(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3330 proto_tree_add_item(tree, hf_bssgp_unconfim_send_state_var, tvb, offset, 2, ENC_BIG_ENDIAN);
3331 return 2;
3335 * 11.3.118 Selected PLMN ID
3337 static guint16
3338 de_bssgp_selected_plmn_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3340 proto_tree_add_string(tree, hf_bssgp_selected_plmn_id, tvb, offset, 3, dissect_e212_mcc_mnc_wmem_packet_str(tvb, pinfo, tree, offset, TRUE));
3341 return 3;
3344 typedef enum
3346 DE_BSSGP_ALIGNMENT_OCTETS, /* 11.3.1 0x00 Alignment octets */
3347 DE_BSSGP_BMAX_DEFAULT_MS, /* 11.3.2 0x01 Bmax default MS */
3348 DE_BSSGP_BSS_AREA_IND, /* 11.3.3 0x02 BSS Area Indication */
3349 DE_BSSGP_BUCKET_LEAK_RATE, /* 11.3.4 0x03 Bucket Leak Rate (R) */
3350 DE_BSSGP_BVCI, /* 11.3.6 0x04 BVCI (BSSGP Virtual Connection Identifier) */
3351 DE_BSSGP_BVC_BUCKET_SIZE, /* 11.3.5 0x05 BVC Bucket Size */
3352 DE_BSSGP_BVC_MEAS, /* 11.3.7 0x06 BVC Measurement */
3353 DE_BSSGP_CAUSE, /* 11.3.8 0x07 Cause */
3354 DE_BSSGP_CELL_ID, /* 11.3.9 0x08 Cell Identifier */
3355 DE_BSSGP_CHLN_NEEDED, /* 11.3.10 0x09 Channel needed */
3356 DE_BBSGP_DRX_PARAM, /* 11.3.11 0x0a DRX Parameters GSM_A_PDU_TYPE_GM, DE_DRX_PARAM */
3357 DE_BBSGP_EMLPP_PRIO, /* 11.3.12 0x0b eMLPP-Priority GSM_A_PDU_TYPE_BSSMAP, BE_EMLPP_PRIO*/
3358 DE_BSSGP_FLUSH_ACTION, /* 11.3.13 0x0c Flush Action */
3359 DE_BSSGP_IMSI, /* 11.3.14 0x0d IMSI */
3360 DE_BSSGP_LLC_PDU, /* 11.3.15 0x0e LLC-PDU */
3361 DE_BSSGP_LLC_FRAMES_DISC, /* 11.3.16 0x0f LLC Frames Discarded */
3362 DE_BSSGP_LAI , /* 11.3.17 0x10 Location Area GSM_A_PDU_TYPE_COMMON, DE_LAI*/
3363 DE_BSSGP_MID, /* 11.3.20 0x11 Mobile Id GSM_A_PDU_TYPE_COMMON, DE_MID*/
3364 DE_BSSGP_MS_BUCKET_SIZE, /* 11.3.21 0x12 MS Bucket Size */
3365 DE_BSSGP_MS_RAD_ACC_CAP, /* 11.3.22 0x13 MS Radio Access Capability GSM_A_PDU_TYPE_GM, DE_MS_RAD_ACC_CAP*/
3366 DE_BSSGP_OMC_ID, /* 11.3.23 0x14 OMC Id */
3367 DE_BSSGP_PDU_IN_ERROR, /* 11.3.24 0x15 PDU In Error */
3368 DE_BSSGP_PDU_LIFETIME, /* 11.3.25 0x16 PDU Lifetime */
3369 DE_BSSP_PRIORITY, /* 11.3.27 0x17 Priority */
3370 DE_BSSGP_QOS_PROFILE, /* 11.3.28 0x18 QoS Profile */
3371 DE_BSSGP_RA_CAUSE, /* 11.3.29 0x19 Radio Cause */
3372 DE_BSSGP_RA_CAP_UPD_CAUSE, /* 11.3.30 0x1a RA-Cap-UPD-Cause */
3373 DE_BSSGP_RAI, /* 11.3.31 0x1b Routeing Area GSM_A_PDU_TYPE_GM, DE_RAI*/
3374 DE_BSSGP_R_DEFAULT_MS, /* 11.3.32 0x1c R_default_MS */
3375 DE_BBSGP_SUSPEND_REF_NO, /* 11.3.33 0x1d Suspend Reference Number */
3376 DE_BSSGP_TAG, /* 11.3.34 0x1e Tag */
3377 DE_BSSGP_TLLI, /* 11.3.35 0x1f Temporary logical link Identity (TLLI) GSM_A_PDU_TYPE_RR, DE_RR_TLLI*/
3378 DE_BSSGP_TMSI_PTMSI, /* 11.3.36 0x20 Temporary Mobile Subscriber Identity (TMSI) GSM_A_PDU_TYPE_RR, DE_RR_TMSI_PTMSI*/
3379 DE_BSSGP_TRACE_REF, /* 11.3.37 0x21 Trace Reference */
3380 DE_BSSGP_TRACE_TYPE, /* 11.3.38 0x22 Trace Type */
3381 DE_BSSGP_TRANSACTION_ID, /* 11.3.39 0x23 Transaction Id */
3382 DE_BSSGP_TRIGGER_ID, /* 11.3.40 0x24 Trigger Id */
3383 DE_BSSGP_NO_OF_OCT_AFFECTED, /* 11.3.41 0x25 Number of octets affected */
3384 DE_BSSGP_LSA_ID_LIST, /* 11.3.18 0x26 LSA Identifier List GSM_A_PDU_TYPE_BSSMAP, BE_LSA_ID_LIST*/
3385 DE_BSSGP_LSA_INFO, /* 11.3.19 0x27 LSA Information GSM_A_PDU_TYPE_BSSMAP, BE_LSA_INFO */
3386 DE_BSSGP_ACKET_FLOW_ID, /* 11.3.42 0x28 Packet Flow Identifier (PFI) GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID*/
3387 DE_BSSGP_GPRS_TIMER, /* 11.3.44 0x29 GPRS Timer */
3388 DE_BSSGP_QOS, /* 11.3.43 0x3a Aggregate BSS QoS Profile GSM_A_PDU_TYPE_GM, DE_QOS*/
3389 DE_BSSGP_FEATURE_BITMAP, /* 11.3.45 0x3b Feature Bitmap */
3390 DE_BSSGP_BUCKET_FULL_RATIO, /* 11.3.46 0x3c Bucket Full Ratio */
3391 DE_BSSGP_SERV_UTRAN_CCO, /* 11.3.47 0x3d Service UTRAN CCO */
3392 DE_BSSGP_NSEI, /* 11.3.48 0x3e NSEI (Network Service Entity Identifier) */
3393 DE_BSSGP_RRLP_APDU, /* 11.3.49 RRLP APDU */
3394 DE_BSSGP_RRLP_FLAGS, /* 11.3.60 RRLP Flags */
3395 DE_BSSGP_RIM_APP_ID, /* 11.3.61 RIM Application Identity */
3396 DE_BSSGP_RIM_SEQ_NO, /* 11.3.62 RIM Sequence Number */
3397 DE_BSSGP_RAN_INF_REQUEST_RIM_CONT, /* 11.3.62a.1 RAN-INFORMATION-REQUEST RIM Container */
3398 DE_BSSGP_RAN_INF_RIM_CONT, /* 11.3.62a.2 RAN-INFORMATION RIM Container */
3399 DE_BSSGP_RAN_INFORMATION_ACK_RIM_CONT, /* 11.3.62a.3 RAN-INFORMATION-ACK RIM Container */
3400 DE_BSSGP_RAN_INFORMATION_ERROR_RIM_CONT, /* 11.3.62a.4 RAN-INFORMATION-ERROR RIM Container */
3401 DE_BSSGP_RAN_INF_APP_ERROR_RIM_CONT, /* 11.3.62a.5 RAN-INFORMATION-APPLICATION-ERROR RIM Container */
3402 DE_BSSGP_RAN_INFORMATION_REQUEST_APP_CONT, /* 11.3.63.1 RAN-INFORMATION-REQUEST Application Container */
3403 DE_BSSGP_RAN_INFORMATION_APP_CONT_UNIT, /* 11.3.63.2 RAN-INFORMATION Application Container Unit */
3404 DE_BSSGP_RAN_APP_ERROR_CONT, /* 11.3.64 Application Error Container */
3405 DE_BSSGP_RIM_PDU_INDICATIONS, /* 11.3.65 RIM PDU Indications */
3406 DE_BSSGP_RIM_PROTO_VER_NO, /* 11.3.67 RIM Protocol Version Number */
3408 DE_BSSGP_PFC_FLOW_CTRL, /* 11.3.68 PFC Flow Control parameters */
3409 DE_BSSGP_RIM_ROUTING_INF, /* 11.3.70 RIM Routing Information */
3411 DE_BSSGP_MBMS_SESSION_ID, /* 11.3.71 MBMS Session Identity */
3412 DE_BSSGP_MBMS_SESSION_DUR, /* 11.3.72 MBMS Session Duration */
3413 DE_BSSGP_MBMS_SAI_LIST, /* 11.3.73 MBMS Service Area Identity List */
3414 DE_BSSGP_MBMS_RESPONSE, /* 11.3.74 MBMS Response */
3415 DE_BSSGP_MBMS_RA_LIST, /* 11.3.75 MBMS Routing Area List */
3416 DE_BSSGP_MBMS_SESSION_INF, /* 11.3.76 MBMS Session Information */
3417 DE_BSSGP_TMGI, /* 11.3.77 TMGI (Temporary Mobile Group Identity) GSM_A_PDU_TYPE_GM, DE_TMGI*/
3419 DE_BSSGP_MBMS_STOP_CAUSE, /* 11.3.78 MBMS Stop Cause */
3420 DE_BSSGP_SOURCE_BSS_TO_TARGET_BSS_TRANSP_CONT, /* 11.3.79 Source BSS to Target BSS Transparent Container */
3421 DE_BSSGP_TARGET_BSS_TO_SOURCE_BSS_TRANSP_CONT, /* 11.3.80 Target BSS to Source BSS Transparent Container */
3422 DE_BSSGP_PFCS_TO_BE_SET_UP_LIST, /* 11.3.82 PFCs to be set-up list */
3423 DE_BSSGP_LIST_OF_SETUP_PFCS, /* 11.3.83 List of set-up PFCs */
3424 DE_BSSGP_EXT_FEATURE_BITMAP, /* 11.3.84 Extended Feature Bitmap */
3425 DE_BSSGP_SRC_TO_TRG_TRANSP_CONT, /* 11.3.85 Source to Target Transparent Container */
3426 DE_BSSGP_TRG_TO_SRC_TRANSP_CONT, /* 11.3.86 Target to Source Transparent Container */
3427 BE_BSSGP_RNC_ID, /* 11.3.87 RNC Identifier */
3428 DE_BSSGP_PAGE_MODE, /* 11.3.88 Page Mode */
3429 DE_BSSGP_CONTAINER_ID, /* 11.3.89 Container ID */
3430 DE_BSSGP_GLOBAL_TFI, /* 11.3.90 Global TFI */
3431 DE_BSSGP_TIME_TO_MBMS_DATA_TRAN, /* 11.3.92 Time to MBMS Data Transfer */
3432 DE_BSSGP_MBMS_SESSION_REP_NO, /* 11.3.93 MBMS Session Repetition Number */
3434 DE_BSSGP_INTER_RAT_HO_INFO, /* 11.3.94 Inter RAT Handover Info */
3435 DE_BSSGP_PS_HO_CMD, /* 11.3.95 PS Handover Command */
3436 DE_BSSGP_PS_HO_INDICATIONS, /* 11.3.95a PS Handover Indications */
3437 DE_BSSGP_SIPSI_CONTAINER, /* 11.3.95b SI/PSI Container */
3438 DE_BSSGP_ACTIVE_PFCS_LIST, /* 11.3.95c Active PFCs List */
3439 DE_BSSGP_VELOCITY_DATA, /* 11.3.96 Velocity Data */
3440 DE_BBSGP_DTM_HO_CMD, /* 11.3.97 DTM Handover Command */
3441 DE_BSSGP_CS_INDICATION, /* 11.3.98 CS Indication */
3442 DE_BSSGP_FLOW_CONTROL_GRAN, /* 11.3.102 Flow Control Granularity */
3443 DE_BSSGP_ENB_ID, /* 11.3.103 eNB Identifier */
3444 DE_BSSGP_E_UTRAN_INTER_RAT_HO_INFO, /* 11.3.104 E-UTRAN Inter RAT Handover Info */
3445 DE_BSSGP_SUB_PROF_ID_F_RAT_FRQ_PRIO, /* 11.3.105 Subscriber Profile ID for RAT/Frequency priority */
3446 DE_BSSGP_REQ_FOR_INTER_RAT_HO_INFO, /* 11.3.106 Request for Inter-RAT Handover Info */
3447 DE_BSSGP_RELIABLE_INTER_RAT_HO_INF, /* 11.3.107 Reliable Inter-RAT Handover Info */
3448 DE_BSSGP_SON_TRANSFER_APP_ID, /* 11.3.108 SON Transfer Application Identity */
3449 DE_BSSGP_CSG_ID, /* 11.3.109 CSG Identifier */
3450 DE_BSSGP_REDIR_ATTEMPT_FLG, /* 11.3.111 Redirect Attempt Flag */
3451 DE_BSSGP_REDIR_INDICATION, /* 11.3.112 Redirection Indication */
3452 DE_BSSGP_REDIR_COMPLETE, /* 11.3.113 Redirection Completed */
3453 DE_BSSGP_UNCONFIRM_SEND_STATE_VAR, /* 11.3.114 Unconfirmed send state variable */
3454 DE_BSSGP_SELECTED_PLMN_ID, /* 11.3.114 Unconfirmed send state variable */
3455 DE_BSSGP_NONE /* NONE */
3457 bssgp_elem_idx_t;
3459 static const value_string bssgp_elem_strings[] = {
3460 { DE_BSSGP_ALIGNMENT_OCTETS, "Alignment Octets" }, /* 11.3.1 Alignment octets */
3461 { DE_BSSGP_BMAX_DEFAULT_MS, "Bmax default MS" }, /* 11.3.2 Bmax default MS */
3462 { DE_BSSGP_BSS_AREA_IND, "BSS Area Indication" }, /* 11.3.3 BSS Area Indication */
3463 { DE_BSSGP_BUCKET_LEAK_RATE, "Bucket Leak Rate (R)" }, /* 11.3.4 Bucket Leak Rate (R) */
3464 { DE_BSSGP_BVCI, "BVCI (BSSGP Virtual Connection Identifier)" }, /* 11.3.6 BVCI (BSSGP Virtual Connection Identifier) */
3465 { DE_BSSGP_BVC_BUCKET_SIZE, "BVC Bucket size" }, /* 11.3.5 BVC Bucket Size */
3466 { DE_BSSGP_BVC_MEAS, "BVC Measurement" }, /* 11.3.7 BVC Measurement */
3467 { DE_BSSGP_CAUSE, "Cause" }, /* 11.3.8 Cause */
3468 { DE_BSSGP_CELL_ID, "Cell Identifier" }, /* 11.3.9 Cell Identifier */
3469 { DE_BSSGP_CHLN_NEEDED, "Channel needed" }, /* 11.3.10 Channel needed */
3470 { DE_BBSGP_DRX_PARAM, "DRX Parameters" }, /* 11.3.11 DRX Parameters */
3471 { DE_BBSGP_EMLPP_PRIO, "eMLPP-Priority" }, /* 11.3.12 eMLPP-Priority */
3472 { DE_BSSGP_FLUSH_ACTION, "Flush Action" }, /* 11.3.13 Flush Action */
3473 { DE_BSSGP_IMSI, "IMSI" }, /* 11.3.14 IMSI */
3474 { DE_BSSGP_LLC_PDU, "LLC-PDU" }, /* 11.3.15 LLC-PDU */
3475 { DE_BSSGP_LLC_FRAMES_DISC, "LLC Frames Discarded" }, /* 11.3.16 LLC Frames Discarded */
3476 { DE_BSSGP_LAI, "Location Area" }, /* 11.3.17 Location Area */
3477 { DE_BSSGP_MID, "Mobile Id" }, /* 11.3.20 Mobile Id */
3478 { DE_BSSGP_MS_BUCKET_SIZE, "MS Bucket Size" }, /* 11.3.21 MS Bucket Size */
3479 { DE_BSSGP_MS_RAD_ACC_CAP, "MS Radio Access Capability" }, /* 11.3.22 MS Radio Access Capability GSM_A_PDU_TYPE_GM, DE_MS_RAD_ACC_CAP */
3480 { DE_BSSGP_OMC_ID, "OMC Id" }, /* 11.3.23 OMC Id */
3481 { DE_BSSGP_PDU_IN_ERROR, "PDU In Error" }, /* 11.3.24 PDU In Error */
3482 { DE_BSSGP_PDU_LIFETIME, "PDU Lifetime" }, /* 11.3.25 PDU Lifetime */
3483 { DE_BSSP_PRIORITY, "Priority" }, /* 11.3.27 Priority */
3484 { DE_BSSGP_QOS_PROFILE, "QoS Profile" }, /* 11.3.28 QoS Profile */
3485 { DE_BSSGP_RA_CAUSE, "Radio Cause" }, /* 11.3.29 Radio Cause */
3486 { DE_BSSGP_RA_CAP_UPD_CAUSE, "RA-Cap-UPD-Cause" }, /* 11.3.30 RA-Cap-UPD-Cause */
3487 { DE_BSSGP_RAI, "Routeing Area" }, /* 11.3.31 Routeing Area */
3488 { DE_BSSGP_R_DEFAULT_MS, "R_default_MS" }, /* 11.3.32 R_default_MS */
3489 { DE_BBSGP_SUSPEND_REF_NO, "Suspend Reference Number" }, /* 11.3.33 Suspend Reference Number */
3490 { DE_BSSGP_TAG, "Tag" }, /* 11.3.34 Tag */
3491 { DE_BSSGP_TLLI, "Temporary logical link Identity (TLLI)" }, /* 11.3.35 Temporary logical link Identity (TLLI) GSM_A_PDU_TYPE_RR, DE_RR_TLLI*/
3492 { DE_BSSGP_TMSI_PTMSI, "Temporary Mobile Subscriber Identity (TMSI)" }, /* 11.3.36 Temporary Mobile Subscriber Identity (TMSI)GSM_A_PDU_TYPE_RR, DE_RR_TMSI_PTMSI */
3493 { DE_BSSGP_TRACE_REF, "Trace Reference" }, /* 11.3.37 Trace Reference */
3494 { DE_BSSGP_TRACE_TYPE, "Trace Type" }, /* 11.3.38 Trace Type */
3495 { DE_BSSGP_TRANSACTION_ID, "Transaction Id" }, /* 11.3.39 Transaction Id */
3496 { DE_BSSGP_TRIGGER_ID, "Trigger Id" }, /* 11.3.40 Trigger Id */
3497 { DE_BSSGP_NO_OF_OCT_AFFECTED, "Number of octets affected" }, /* 11.3.41 Number of octets affected */
3498 { DE_BSSGP_LSA_ID_LIST, "LSA Identifier List" }, /* 11.3.18 LSA Identifier List */
3499 { DE_BSSGP_LSA_INFO, "LSA Information" }, /* 11.3.19 LSA Information */
3500 { DE_BSSGP_ACKET_FLOW_ID, "Packet Flow Identifier (PFI)" }, /* 11.3.42 Packet Flow Identifier (PFI) GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID*/
3501 /* 11.3.42a (void) */
3502 { DE_BSSGP_GPRS_TIMER, "GPRS Timer" }, /* 11.3.44 GPRS Timer */
3503 { DE_BSSGP_QOS, "Aggregate BSS QoS Profile" }, /* 11.3.43 Aggregate BSS QoS Profile GSM_A_PDU_TYPE_GM, DE_QOS*/
3504 { DE_BSSGP_FEATURE_BITMAP, "Feature Bitmap" }, /* 11.3.45 Feature Bitmap */
3505 { DE_BSSGP_BUCKET_FULL_RATIO, "Bucket Full Ratio" }, /* 11.3.46 Bucket Full Ratio */
3506 { DE_BSSGP_SERV_UTRAN_CCO, "Service UTRAN CCO" }, /* 11.3.47 Service UTRAN CCO */
3507 { DE_BSSGP_NSEI, "NSEI (Network Service Entity Identifier)" }, /* 11.3.48 NSEI (Network Service Entity Identifier) */
3508 { DE_BSSGP_RRLP_APDU, "RRLP APDU" }, /* 11.3.49 RRLP APDU */
3509 /* 11.3.50 LCS QoS BSSGP_IEI_LCS_QOS, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_LCSQOS*/
3510 /* 11.3.51 LCS Client Type BSSGP_IEI_LCS_CLIENT_TYPE, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_LCS_CLIENT_TYPE*/
3511 /* 11.3.52 Requested GPS Assistance Data BSSGP_IEI_REQUESTED_GPS_ASSISTANCE_DATA, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_REQ_GPS_ASSIST_D*/
3512 /* 11.3.53 Location Type 0x7c, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_GANSS_LOC_TYPE*/
3513 /* 11.3.54 Location Estimate BSSGP_IEI_LOCATION_ESTIMATE, GSM_A_PDU_TYPE_BSSMAP, BE_LOC_EST*/
3514 /* 11.3.55 Positioning Data 0x7d, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_POS_DATA*/
3515 /* 11.3.56 Deciphering Keys BSSGP_IEI_DECIPHERING_KEYS, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_DECIPH_KEYS */
3516 /* 11.3.57 LCS Priority BSSGP_IEI_LCS_PRIORITY, GSM_A_PDU_TYPE_BSSMAP, BE_LCS_PRIO;*/
3517 /* 11.3.58 LCS Cause BSSGP_IEI_LCS_CAUSE, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_LCS_CAUSE */
3518 /* 11.3.59 LCS Capability 0x49 , GSM_A_PDU_TYPE_GM, DE_PS_LCS_CAP*/
3519 { DE_BSSGP_RRLP_FLAGS, "RRLP Flags" }, /* 11.3.60 RRLP Flags */
3520 { DE_BSSGP_RIM_APP_ID, "RIM Application Identity" }, /* 11.3.61 RIM Application Identity */
3521 { DE_BSSGP_RIM_SEQ_NO, "RIM Sequence Number" }, /* 11.3.62 RIM Sequence Number */
3522 /* 11.3.62a RIM Container */
3523 /* 11.3.62a.0 General */
3524 { DE_BSSGP_RAN_INF_REQUEST_RIM_CONT, "RAN-INFORMATION-REQUEST RIM Container" }, /* 11.3.62a.1 RAN-INFORMATION-REQUEST RIM Container */
3525 { DE_BSSGP_RAN_INF_RIM_CONT, "RAN-INFORMATION RIM Container" }, /* 11.3.62a.2 RAN-INFORMATION RIM Container */
3526 { DE_BSSGP_RAN_INFORMATION_ACK_RIM_CONT, "RAN-INFORMATION-ACK RIM Container" }, /* 11.3.62a.3 RAN-INFORMATION-ACK RIM Container */
3527 { DE_BSSGP_RAN_INFORMATION_ERROR_RIM_CONT, "RAN-INFORMATION-ERROR RIM Container" }, /* 11.3.62a.4 RAN-INFORMATION-ERROR RIM Container */
3528 { DE_BSSGP_RAN_INF_APP_ERROR_RIM_CONT, "RAN-INFORMATION-APPLICATION-ERROR RIM Container" }, /* 11.3.62a.5 RAN-INFORMATION-APPLICATION-ERROR RIM Container */
3529 /* 11.3.63 Application Container */
3530 { DE_BSSGP_RAN_INFORMATION_REQUEST_APP_CONT, "RAN-INFORMATION-REQUEST Application Container" }, /* 11.3.63.1 RAN-INFORMATION-REQUEST Application Container */
3531 /* 11.3.63.1.0 General */
3532 /* 11.3.63.1.1 RAN-INFORMATION-REQUEST Application Container for the NACC Application */
3533 /* 11.3.63.1.2 RAN-INFORMATION-REQUEST Application Container for the SI3 Application */
3534 /* 11.3.63.1.3 RAN-INFORMATION-REQUEST Application Container for the MBMS data channel Application */
3535 /* 11.3.63.1.4 RAN-INFORMATION-REQUEST Application Container for the SON Transfer Application */
3536 { DE_BSSGP_RAN_INFORMATION_APP_CONT_UNIT, "RAN-INFORMATION Application Container Unit" }, /* 11.3.63.2 RAN-INFORMATION Application Container Unit */
3537 /* 11.3.63.2.0 General */
3538 /* 11.3.63.2.1 RAN-INFORMATION Application Container for the NACC Application */
3539 /* 11.3.63.2.2 RAN-INFORMATION Application Container for the SI3 Application */
3540 /* 11.3.63.2.3 RAN-INFORMATION Application Container for the MBMS data channel Application */
3541 /* 11.3.63.2.4 RAN-INFORMATION Application Container for the SON Transfer Application */
3542 { DE_BSSGP_RAN_APP_ERROR_CONT, "Application Error Container" }, /* 11.3.64 Application Error Container */
3543 /* 11.3.64.1 Application Error Container layout for the NACC application */
3544 /* 11.3.64.2 Application Error Container for the SI3 application */
3545 /* 11.3.64.3 Application Error Container for the MBMS data channel application */
3546 /* 11.3.64.4 Application Error Container for the SON Transfer Application */
3547 { DE_BSSGP_RIM_PDU_INDICATIONS, "RIM PDU Indications" }, /* 11.3.65 RIM PDU Indications */
3548 /* 11.3.65.0 General */
3549 /* 11.3.65.1 RAN-INFORMATION-REQUEST RIM PDU Indications */
3550 /* 11.3.65.2 RAN-INFORMATION RIM PDU Indications */
3551 /* 11.3.65.3 RAN-INFORMATION-APPLICATION-ERROR RIM PDU Indications */
3552 /* 11.3.66 (void) */
3553 { DE_BSSGP_RIM_PROTO_VER_NO, "RIM Protocol Version Number" }, /* 11.3.67 RIM Protocol Version Number */
3554 { DE_BSSGP_PFC_FLOW_CTRL, "PFC Flow Control parameters" }, /* 11.3.68 PFC Flow Control parameters */
3555 /* 0x53, SGSAP_PDU_TYPE, DE_SGSAP_GLOBAL_CN_ID */ /* 11.3.69 Global CN-Id */
3556 { DE_BSSGP_RIM_ROUTING_INF, "RIM Routing Information" }, /* 11.3.70 RIM Routing Information */
3557 { DE_BSSGP_MBMS_SESSION_ID, "MBMS Session Identity" }, /* 11.3.71 MBMS Session Identity */
3558 { DE_BSSGP_MBMS_SESSION_DUR, "MBMS Session Duration" }, /* 11.3.72 MBMS Session Duration */
3559 { DE_BSSGP_MBMS_SAI_LIST, "MBMS Service Area Identity List" }, /* 11.3.73 MBMS Service Area Identity List */
3560 { DE_BSSGP_MBMS_RESPONSE, "MBMS Response" }, /* 11.3.74 MBMS Response */
3561 { DE_BSSGP_MBMS_RA_LIST, "MBMS Routing Area List" }, /* 11.3.75 MBMS Routing Area List */
3562 { DE_BSSGP_MBMS_SESSION_INF, "MBMS Session Information" }, /* 11.3.76 MBMS Session Information */
3563 { DE_BSSGP_TMGI, "TMGI" }, /* 11.3.77 TMGI (Temporary Mobile Group Identity) */
3564 { DE_BSSGP_MBMS_STOP_CAUSE, "MBMS Stop Cause" }, /* 11.3.78 MBMS Stop Cause */
3565 { DE_BSSGP_SOURCE_BSS_TO_TARGET_BSS_TRANSP_CONT, "Source BSS to Target BSS Transparent Container" }, /* 11.3.79 Source BSS to Target BSS Transparent Container */
3566 { DE_BSSGP_TARGET_BSS_TO_SOURCE_BSS_TRANSP_CONT, "Target BSS to Source BSS Transparent Container" }, /* 11.3.80 Target BSS to Source BSS Transparent Container */
3567 /* 11.3.81 NAS container for PS Handover */
3568 { DE_BSSGP_PFCS_TO_BE_SET_UP_LIST, "PFCs to be set-up list" }, /* 11.3.82 PFCs to be set-up list */
3569 { DE_BSSGP_LIST_OF_SETUP_PFCS, "List of set-up PFCs" }, /* 11.3.83 List of set-up PFCs */
3570 { DE_BSSGP_EXT_FEATURE_BITMAP, "Extended Feature Bitmap" }, /* 11.3.84 Extended Feature Bitmap */
3571 { DE_BSSGP_SRC_TO_TRG_TRANSP_CONT, "Source to Target Transparent Container" }, /* 11.3.85 Source to Target Transparent Container */
3572 { DE_BSSGP_TRG_TO_SRC_TRANSP_CONT, "Target to Source Transparent Container" }, /* 11.3.86 Target to Source Transparent Container */
3573 { BE_BSSGP_RNC_ID, "RNC Identifier" }, /* 11.3.87 RNC Identifier */
3574 { DE_BSSGP_PAGE_MODE, "Page Mode" }, /* 11.3.88 Page Mode */
3575 { DE_BSSGP_CONTAINER_ID, "Container ID" }, /* 11.3.89 Container ID */
3576 { DE_BSSGP_GLOBAL_TFI, "Global TFI" }, /* 11.3.90 Global TFI */
3577 /* 11.3.91 IMEI */
3578 { DE_BSSGP_TIME_TO_MBMS_DATA_TRAN, "Time to MBMS Data Transfer" }, /* 11.3.92 Time to MBMS Data Transfer */
3579 { DE_BSSGP_MBMS_SESSION_REP_NO, "MBMS Session Repetition Number" }, /* 11.3.93 MBMS Session Repetition Number */
3580 { DE_BSSGP_INTER_RAT_HO_INFO, "Inter RAT Handover Info" }, /* 11.3.94 Inter RAT Handover Info */
3581 { DE_BSSGP_PS_HO_CMD, "PS Handover Command" }, /* 11.3.95 PS Handover Command */
3582 { DE_BSSGP_PS_HO_INDICATIONS, "PS Handover Indications" }, /* 11.3.95a PS Handover Indications */
3583 { DE_BSSGP_SIPSI_CONTAINER, "SI/PSI Container" }, /* 11.3.95b SI/PSI Container */
3584 { DE_BSSGP_ACTIVE_PFCS_LIST, "Active PFCs List" }, /* 11.3.95c Active PFCs List */
3585 { DE_BSSGP_VELOCITY_DATA, "Velocity Data" }, /* 11.3.96 Velocity Data */
3586 { DE_BBSGP_DTM_HO_CMD, "DTM Handover Command" }, /* 11.3.97 DTM Handover Command */
3587 { DE_BSSGP_CS_INDICATION, "CS Indication" }, /* 11.3.98 CS Indication */
3588 /* 11.3.99 Requested GANSS Assistance Data 0x7b, GSM_A_PDU_TYPE_BSSMAP, BE_GANSS_ASS_DTA*/
3589 /* 11.3.100 GANSS Location Type 0x7c, GSM_A_PDU_TYPE_BSSMAP, BE_GANSS_LOC_TYP*/
3590 /* 11.3.101 GANSS Positioning Data ENC_BIG_ENDIAN);*/
3591 { DE_BSSGP_FLOW_CONTROL_GRAN, "Flow Control Granularity" }, /* 11.3.102 Flow Control Granularity */
3592 { DE_BSSGP_ENB_ID, "eNB Identifier" }, /* 11.3.103 eNB Identifier */
3593 { DE_BSSGP_E_UTRAN_INTER_RAT_HO_INFO, "E-UTRAN Inter RAT Handover Info" }, /* 11.3.104 E-UTRAN Inter RAT Handover Info */
3594 { DE_BSSGP_SUB_PROF_ID_F_RAT_FRQ_PRIO, "Subscriber Profile ID for RAT/Frequency priority" }, /* 11.3.105 Subscriber Profile ID for RAT/Frequency priority */
3595 { DE_BSSGP_REQ_FOR_INTER_RAT_HO_INFO, "Request for Inter-RAT Handover Info" }, /* 11.3.106 Request for Inter-RAT Handover Info */
3596 { DE_BSSGP_RELIABLE_INTER_RAT_HO_INF, "Reliable Inter-RAT Handover Info" }, /* 11.3.107 Reliable Inter-RAT Handover Info */
3597 { DE_BSSGP_SON_TRANSFER_APP_ID, "Son transfer application identity" }, /* 11.3.108 SON Transfer Application Identity */
3598 { DE_BSSGP_CSG_ID, "CSG Identifier" }, /* 11.3.109 CSG Identifier */
3599 /* 11.3.110 Tracking Area Code */
3600 { DE_BSSGP_REDIR_ATTEMPT_FLG, "Redirect Attempt Flag"}, /* 11.3.111 Redirect Attempt Flag */
3601 { DE_BSSGP_REDIR_INDICATION, "Redirection Indication"}, /* 11.3.112 Redirection Indication */
3602 { DE_BSSGP_REDIR_COMPLETE, "Redirection Completed"}, /* 11.3.113 Redirection Completed */
3603 { DE_BSSGP_UNCONFIRM_SEND_STATE_VAR, "Unconfirmed Send State Variable"}, /* 11.3.114 Unconfirmed send state variable */
3605 { DE_BSSGP_SELECTED_PLMN_ID, "Selected PLMN ID"}, /* 11.3.118 Selected PLMN ID */
3607 { 0, NULL }
3609 value_string_ext bssgp_elem_strings_ext = VALUE_STRING_EXT_INIT(bssgp_elem_strings);
3611 #define NUM_BSSGP_ELEM (sizeof(bssgp_elem_strings)/sizeof(value_string))
3612 gint ett_bssgp_elem[NUM_BSSGP_ELEM];
3615 guint16 (*bssgp_elem_fcn[])(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len, gchar *add_string, int string_len) = {
3616 de_bssgp_aligment_octets, /* 11.3.1 0x00 Alignment octets */
3617 de_bssgp_bmax_default_ms, /* 11.3.2 0x01 Bmax default MS */
3618 de_bssgp_bss_area_ind, /* 11.3.3 0x02 BSS Area Indication */
3619 de_bssgp_bucket_leak_rate, /* 11.3.4 0x03 Bucket Leak Rate (R) */
3620 de_bssgp_bvci, /* 11.3.6 0x04 BVCI (BSSGP Virtual Connection Identifier) */
3621 de_bssgp_bvc_bucket_size, /* 11.3.5 0x05 BVC Bucket Size */
3622 de_bssgp_bvc_meas, /* 11.3.7 0x06 BVC Measurement */
3623 de_bssgp_cause, /* 11.3.8 0x07 Cause */
3624 de_bssgp_cell_id, /* 11.3.9 0x08 Cell Identifier */
3625 de_bssgp_chnl_needed, /* 11.3.10 0x09 Channel needed */
3626 NULL, /* 11.3.11 0x0a DRX Parameters */
3627 NULL, /* 11.3.12 0x0b eMLPP-Priority */
3628 de_bssgp_flush_action, /* 11.3.13 0x0c Flush Action */
3629 de_mid, /* 11.3.14 0x0d IMSI */
3630 de_bssgp_llc_pdu, /* 11.3.15 0x0e LLC-PDU */
3631 de_bssgp_llc_frames_disc, /* 11.3.16 0x0f LLC Frames Discarded */
3632 NULL, /* 11.3.17 0x10 Location Area */
3633 NULL, /* 11.3.20 0x11 Mobile Id */
3634 de_bssgp_ms_bucket_size, /* 11.3.21 0x12 MS Bucket Size */
3635 NULL, /* 11.3.22 0x13 MS Radio Access Capability */
3636 de_bssgp_omc_id, /* 11.3.23 0x14 OMC Id */
3637 de_bssgp_pdu_in_error, /* 11.3.24 0x15 PDU In Error */
3638 de_bssgp_pdu_lifetime, /* 11.3.25 0x16 PDU Lifetime */
3639 NULL, /* 11.3.27 0x17 Priority */
3640 de_bssgp_qos_profile, /* 11.3.28 0x18 QoS Profile */
3641 de_bssgp_ra_cause, /* 11.3.29 0x19 Radio Cause */
3642 de_bssgp_ra_cap_upd_cause, /* 11.3.30 0x1a RA-Cap-UPD-Cause */
3643 NULL, /* 11.3.31 0x1b Routeing Area */
3644 de_bssgp_r_default_ms, /* 11.3.32 0x1c R_default_MS */
3645 de_bssgp_suspend_ref_no, /* 11.3.33 0x1d Suspend Reference Number */
3646 de_bssgp_tag, /* 11.3.34 0x1e Tag */
3647 NULL, /* 11.3.35 0x1f Temporary logical link Identity (TLLI) */
3648 NULL, /* 11.3.36 0x20 Temporary Mobile Subscriber Identity (TMSI) */
3649 de_bssgp_trace_ref, /* 11.3.37 0x21 Trace Reference */
3650 de_bssgp_trace_type, /* 11.3.38 0x22 Trace Type */
3651 de_bssgp_transaction_id, /* 11.3.39 0x23 Transaction Id */
3652 de_bssgp_trigger_id, /* 11.3.40 0x24 Trigger Id */
3653 de_bssgp_no_of_oct_affected, /* 11.3.41 0x25 Number of octets affected */
3654 NULL, /* 11.3.18 0x26 LSA Identifier List GSM_A_PDU_TYPE_BSSMAP, BE_LSA_ID_LIST*/
3655 NULL, /* 11.3.19 0x27 LSA Information */
3656 NULL, /* 11.3.42 0x28 Packet Flow Identifier (PFI) */
3657 de_bssgp_gprs_timer, /* 11.3.44 0x29 GPRS Timer */
3658 NULL, /* 11.3.43 0x3a Aggregate BSS QoS Profile */
3659 de_bssgp_feature_bitmap, /* 11.3.45 0x3b Feature Bitmap */
3660 de_bssgp_bucket_full_ratio, /* 11.3.46 0x3c Bucket Full Ratio */
3661 de_bssgp_serv_utran_cco, /* 11.3.47 0x3d Service UTRAN CCO */
3662 de_bssgp_nsei, /* 11.3.48 0x3e NSEI (Network Service Entity Identifier) */
3663 de_bssgp_rrlp_apdu, /* 11.3.49 RRLP APDU */
3664 de_bssgp_rrlp_flags, /* 11.3.60 RRLP Flags */
3665 de_bssgp_rim_app_id, /* 11.3.61 RIM Application Identity */
3666 de_bssgp_rim_seq_no, /* 11.3.62 RIM Sequence Number */
3667 de_bssgp_ran_inf_request_rim_cont, /* 11.3.62a.1 RAN-INFORMATION-REQUEST RIM Container */
3668 de_bssgp_ran_inf_rim_cont, /* 11.3.62a.2 RAN-INFORMATION RIM Container */
3669 de_bssgp_ran_inf_ack_rim_cont, /* 11.3.62a.3 RAN-INFORMATION-ACK RIM Container */
3670 de_bssgp_ran_inf_error_rim_cont, /* 11.3.62a.4 RAN-INFORMATION-ERROR RIM Container */
3671 de_bssgp_ran_inf_app_error_rim_cont, /* 11.3.62a.5 RAN-INFORMATION-APPLICATION-ERROR RIM Container */
3673 de_bssgp_ran_information_request_app_cont, /* 11.3.63.1 RAN-INFORMATION-REQUEST Application Container */
3674 de_bssgp_ran_information_app_cont_unit, /* 11.3.63.2 RAN-INFORMATION Application Container Unit */
3675 de_bssgp_ran_app_error_cont, /* 11.3.64 Application Error Container */
3676 de_bssgp_rim_pdu_indications, /* 11.3.65 RIM PDU Indications */
3677 de_bssgp_rim_proto_ver_no, /* 11.3.67 RIM Protocol Version Number */
3679 de_bssgp_pfc_flow_ctrl, /* 11.3.68 PFC Flow Control parameters */
3680 de_bssgp_rim_routing_inf, /* 11.3.70 RIM Routing Information */
3681 de_bssgp_mbms_session_id, /* 11.3.71 MBMS Session Identity */
3682 de_bssgp_mbms_session_dur, /* 11.3.72 MBMS Session Duration */
3683 de_bssgp_mbms_sai_list, /* 11.3.73 MBMS Service Area Identity List */
3684 de_bssgp_mbms_response, /* 11.3.74 MBMS Response */
3685 de_bssgp_mbms_ra_list, /* 11.3.75 MBMS Routing Area List */
3686 de_bssgp_mbms_session_inf, /* 11.3.76 MBMS Session Information */
3687 NULL, /* 11.3.77 TMGI (Temporary Mobile Group Identity) */
3688 de_bssgp_mbms_stop_cause, /* 11.3.78 MBMS Stop Cause */
3689 de_bssgp_source_BSS_to_target_BSS_transp_cont, /* 11.3.79 Source BSS to Target BSS Transparent Container */
3690 de_bssgp_target_BSS_to_source_BSS_transp_cont, /* 11.3.80 Target BSS to Source BSS Transparent Container */
3691 de_bssgp_pfcs_to_be_set_up_list, /* 11.3.82 PFCs to be set-up list */
3692 de_bssgp_list_of_setup_pfcs, /* 11.3.83 List of set-up PFCs */
3693 de_bssgp_ext_feature_bitmap, /* 11.3.84 Extended Feature Bitmap */
3694 de_bssgp_src_to_trg_transp_cont, /* 11.3.85 Source to Target Transparent Container */
3695 de_bssgp_trg_to_src_transp_cont, /* 11.3.86 Target to Source Transparent Container */
3696 de_bssgp_rnc_identifier, /* 11.3.87 RNC Identifier */
3697 de_bssgp_page_mode, /* 11.3.88 Page Mode */
3698 de_bssgp_container_id, /* 11.3.89 Container ID */
3699 de_bssgp_global_tfi, /* 11.3.90 Global TFI */
3700 de_bssgp_time_to_MBMS_data_tran, /* 11.3.92 Time to MBMS Data Transfer */
3701 de_bssgp_mbms_session_rep_no, /* 11.3.93 MBMS Session Repetition Number */
3702 de_bssgp_inter_rat_ho_info, /* 11.3.94 Inter RAT Handover Info */
3703 de_bssgp_ps_ho_cmd, /* 11.3.95 PS Handover Command */
3704 de_bssgp_ps_ho_indications, /* 11.3.95a PS Handover Indications */
3705 de_bssgp_sipsi_container, /* 11.3.95b SI/PSI Container */
3706 de_bssgp_active_pfcs_list, /* 11.3.95c Active PFCs List */
3707 de_bssgp_velocity_data, /* 11.3.96 Velocity Data */
3708 de_bssgp_dtm_ho_cmd, /* 11.3.97 DTM Handover Command */
3709 de_bssgp_cs_indication, /* 11.3.98 CS Indication */
3710 de_bssgp_flow_control_gran, /* 11.3.102 Flow Control Granularity */
3711 de_bssgp_enb_id, /* 11.3.103 eNB Identifier */
3712 de_bssgp_e_utran_inter_rat_ho_info, /* 11.3.104 E-UTRAN Inter RAT Handover Info */
3713 de_bssgp_sub_prof_id_f_rat_freq_prio, /* 11.3.105 Subscriber Profile ID for RAT/Frequency priority */
3714 de_bssgp_req_for_inter_rat_ho_inf, /* 11.3.106 Request for Inter-RAT Handover Info */
3715 de_bssgp_reliable_inter_rat_ho_inf, /* 11.3.107 Reliable Inter-RAT Handover Info */
3716 de_bssgp_son_transfer_app_id, /* 11.3.108 SON Transfer Application Identity */
3717 de_bssgp_csg_id, /* 11.3.109 CSG Identifier */
3718 de_bssgp_redir_attempt_flg, /* 11.3.111 Redirect Attempt Flag */
3719 de_bssgp_redir_indication, /* 11.3.112 Redirection Indication */
3720 de_bssgp_redir_complete, /* 11.3.113 Redirection Completed */
3721 de_bssgp_unconfim_send_state_var, /* 11.3.114 Unconfirmed send state variable */
3722 de_bssgp_selected_plmn_id, /* 11.3.118 Selected PLMN ID */
3724 NULL, /* NONE */
3728 * 11.3.62a RIM Container
3729 * 11.3.62a.0 General
3730 * 11.3.62a.1 RAN-INFORMATION-REQUEST RIM Container
3732 static guint16
3733 de_bssgp_ran_inf_request_rim_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3735 guint32 curr_offset;
3736 guint32 consumed;
3737 guint curr_len;
3739 curr_offset = offset;
3740 curr_len = len;
3742 /* RAN-INFORMATION-REQUEST RIM Container Contents coded as
3743 * defined in table 11.3.62a.1b
3745 /* RIM Application Identity RIM Application Identity/11.3.61 M TLV 3 */
3746 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_RIM_APP_ID, BSSGP_PDU_TYPE, DE_BSSGP_RIM_APP_ID, NULL);
3747 /* RIM Sequence Number RIM Sequence Number/11.3.62 M TLV 6 */
3748 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_RIM_SEQUENCE_NUMBER, BSSGP_PDU_TYPE, DE_BSSGP_RIM_SEQ_NO, NULL);
3749 /* RIM PDU Indications RIM PDU Indications/11.3.65 M TLV 3 */
3750 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_RIM_PDU_INDICATIONS, BSSGP_PDU_TYPE, DE_BSSGP_RIM_PDU_INDICATIONS, NULL);
3751 /* RIM Protocol Version Number RIM Protocol Version Number/11.3.67 O TLV 3 */
3752 ELEM_IN_ELEM_OPT_TELV(BSSGP_IEI_RIM_PROTOCOL_VERSION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_PROTO_VER_NO, NULL);
3753 /* Application Container (note 1) RAN-INFORMATION-REQUEST Application Container/11.3.63.1 C TLV 4-? */
3754 ELEM_IN_ELEM_OPT_TELV(BSSGP_IEI_RAN_INF_REQUEST_APP_CONTAINER, BSSGP_PDU_TYPE, DE_BSSGP_RAN_INFORMATION_REQUEST_APP_CONT, NULL);
3755 /* SON Transfer Application Identity (note 2) SON Transfer Application Identity/11.3.108 C TLV 3-m */
3756 ELEM_IN_ELEM_OPT_TELV(0x84, BSSGP_PDU_TYPE, DE_BSSGP_SON_TRANSFER_APP_ID, NULL);
3758 return(curr_offset-offset);
3761 * 11.3.62a.2 RAN-INFORMATION RIM Container
3763 static guint16
3764 de_bssgp_ran_inf_rim_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3766 guint32 curr_offset;
3767 guint32 consumed;
3768 guint curr_len;
3770 curr_offset = offset;
3771 curr_len = len;
3773 /* RAN-INFORMATION RIM Container Contents coded as
3774 * defined in table 11.3.62a.2b
3776 /* RIM Application Identity RIM Application Identity /11.3.61 M TLV 3 */
3777 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_RIM_APP_ID, BSSGP_PDU_TYPE, DE_BSSGP_RIM_APP_ID, NULL);
3778 /* RIM Sequence Number RIM Sequence Number /11.3.62 M TLV 6 */
3779 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_RIM_SEQUENCE_NUMBER, BSSGP_PDU_TYPE, DE_BSSGP_RIM_SEQ_NO, NULL);
3780 /* RIM PDU Indications RIM PDU Indications /11.3.65. M TLV 3 */
3781 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_RIM_PDU_INDICATIONS, BSSGP_PDU_TYPE, DE_BSSGP_RIM_PDU_INDICATIONS, NULL);
3782 /* RIM Protocol Version Number RIM Protocol Version Number/11.3.67 O TLV 3 */
3783 ELEM_IN_ELEM_OPT_TELV(BSSGP_IEI_RIM_PROTOCOL_VERSION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_PROTO_VER_NO, NULL);
3784 /* Application Container (NOTE 1) RAN-INFORMATION Application Container /11.3.63.2 C (Note 1) TLV 4-? */
3785 ELEM_IN_ELEM_OPT_TELV(BSSGP_IEI_RAN_INF_APP_CONTAINER, BSSGP_PDU_TYPE, DE_BSSGP_RAN_INFORMATION_APP_CONT_UNIT, NULL);
3786 /* Application Error Container (NOTE 1) Application Error Container/11.3.64 C (Note 1) TLV n */
3787 ELEM_IN_ELEM_OPT_TELV(BSSGP_IEI_APPLICATION_ERROR_CONTAINER, BSSGP_PDU_TYPE, DE_BSSGP_RAN_APP_ERROR_CONT, NULL);
3788 /* SON Transfer Application Identity (note 2) SON Transfer Application Identity/11.3.108 C TLV 3-m */
3789 ELEM_IN_ELEM_OPT_TELV(0x84, BSSGP_PDU_TYPE, DE_BSSGP_SON_TRANSFER_APP_ID, NULL);
3791 return(curr_offset-offset);
3795 * 11.3.62a.3 RAN-INFORMATION-ACK RIM Container
3797 static guint16
3798 de_bssgp_ran_inf_ack_rim_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3800 guint32 curr_offset;
3801 guint32 consumed;
3802 guint curr_len;
3804 curr_offset = offset;
3805 curr_len = len;
3807 /* RAN-INFORMATION-ACK RIM Container Contents coded as
3808 * defined in table 11.3.62a.3b
3810 /* RIM Application Identity RIM Application Identity /11.3.61 M TLV 3 */
3811 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_RIM_APP_ID, BSSGP_PDU_TYPE, DE_BSSGP_RIM_APP_ID, NULL);
3812 /* RIM Sequence Number RIM Sequence Number /11.3.62 M TLV 6 */
3813 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_RIM_SEQUENCE_NUMBER, BSSGP_PDU_TYPE, DE_BSSGP_RIM_SEQ_NO, NULL);
3814 /* RIM Protocol Version Number RIM Protocol Version Number/11.3.67 O TLV 4 */
3815 ELEM_IN_ELEM_OPT_TELV(BSSGP_IEI_RIM_PROTOCOL_VERSION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_PROTO_VER_NO, NULL);
3816 /* SON Transfer Application Identity (note 1) SON Transfer Application Identity/11.3.108 C TLV 3-m */
3817 ELEM_IN_ELEM_OPT_TELV(0x84, BSSGP_PDU_TYPE, DE_BSSGP_SON_TRANSFER_APP_ID, NULL);
3819 return(curr_offset-offset);
3822 * 11.3.62a.4 RAN-INFORMATION-ERROR RIM Container
3824 static guint16
3825 de_bssgp_ran_inf_error_rim_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3827 guint32 curr_offset;
3828 guint32 consumed;
3829 guint curr_len;
3831 curr_offset = offset;
3832 curr_len = len;
3834 /* RAN-INFORMATION-ERROR RIM Container Contents coded as
3835 * defined in table 11.3.62a.4b
3837 /* RIM Application Identity RIM Application Identity /11.3.61 M TLV 3 */
3838 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_RIM_APP_ID, BSSGP_PDU_TYPE, DE_BSSGP_RIM_APP_ID, NULL);
3839 /* RIM Cause Cause/11.3.8 M TLV 3 */
3840 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, " - RIM");
3841 /* RIM Protocol Version Number RIM Protocol Version Number/11.3.67 O TLV 3 */
3842 ELEM_IN_ELEM_OPT_TELV(BSSGP_IEI_RIM_PROTOCOL_VERSION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_PROTO_VER_NO, NULL);
3843 /* PDU in Error PDU in Error/11.3.24 M TLV 3-? */
3844 ELEM_IN_ELEM_MAND_TELV(0x15, BSSGP_PDU_TYPE, DE_BSSGP_PDU_IN_ERROR , NULL);
3845 /* SON Transfer Application Identity (note 1) SON Transfer Application Identity/11.3.108 C TLV 3-m */
3846 ELEM_IN_ELEM_OPT_TELV(0x84, BSSGP_PDU_TYPE, DE_BSSGP_SON_TRANSFER_APP_ID, NULL);
3848 return(curr_offset-offset);
3851 * 11.3.62a.5 RAN-INFORMATION-APPLICATION-ERROR RIM Container
3853 static guint16
3854 de_bssgp_ran_inf_app_error_rim_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3856 guint32 curr_offset;
3857 guint32 consumed;
3858 guint curr_len;
3860 curr_offset = offset;
3861 curr_len = len;
3863 /* RRAN-INFORMATION-APPLICATION-ERROR RIM Container
3864 * Contents coded as defined in table 11.3.62a.5b
3866 /* RIM Application Identity RIM Application Identity /11.3.61 M TLV 3 */
3867 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_RIM_APP_ID, BSSGP_PDU_TYPE, DE_BSSGP_RIM_APP_ID, NULL);
3868 /* RIM Sequence Number RIM Sequence Number /11.3.62 M TLV 6 */
3869 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_RIM_SEQUENCE_NUMBER, BSSGP_PDU_TYPE, DE_BSSGP_RIM_SEQ_NO, NULL);
3870 /* RIM PDU Indications RIM PDU Indications /11.3.65. M TLV 3 */
3871 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_RIM_PDU_INDICATIONS, BSSGP_PDU_TYPE, DE_BSSGP_RIM_PDU_INDICATIONS, NULL);
3872 /* RIM Protocol Version Number RIM Protocol Version Number/11.3.67 O TLV 3 */
3873 ELEM_IN_ELEM_OPT_TELV(BSSGP_IEI_RIM_PROTOCOL_VERSION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_PROTO_VER_NO, NULL);
3874 /* Application Error Container Application Error Container/11.3.64 M TLV n */
3875 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_APPLICATION_ERROR_CONTAINER, BSSGP_PDU_TYPE, DE_BSSGP_RAN_APP_ERROR_CONT, NULL);
3876 /* SON Transfer Application Identity (note 1) SON Transfer Application Identity/11.3.108 C TLV 3-m */
3877 ELEM_IN_ELEM_OPT_TELV(0x84, BSSGP_PDU_TYPE, DE_BSSGP_SON_TRANSFER_APP_ID, NULL);
3879 return(curr_offset-offset);
3883 * 11.3.79 Source BSS to Target BSS Transparent Container
3885 guint16
3886 de_bssgp_source_BSS_to_target_BSS_transp_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3888 guint32 curr_offset;
3889 guint32 consumed;
3890 guint curr_len;
3892 curr_offset = offset;
3893 curr_len = len;
3896 /* Octet 3-? Source BSS to Target BSS Transparent Container Contents coded
3897 * as defined in table 11.3.79.b
3899 /* MS Radio Access Capability MS Radio Access Capability/11.3.22 M TLV 7-? */
3900 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_MS_RADIO_ACCESS_CAPABILITY, GSM_A_PDU_TYPE_GM, DE_MS_RAD_ACC_CAP , NULL);
3901 /* Inter RAT Handover Info Inter RAT Handover Info/11.3.94 O (note 1) TLV 3-? */
3902 ELEM_IN_ELEM_OPT_TELV(0x73, BSSGP_PDU_TYPE, DE_BSSGP_INTER_RAT_HO_INFO, NULL);
3903 /* Page Mode Page Mode/11.3.88 O (note 2, note 3) TLV 3 */
3904 ELEM_IN_ELEM_OPT_TELV(0x6d, BSSGP_PDU_TYPE, DE_BSSGP_PAGE_MODE, NULL);
3905 /* Container ID Container ID/11.3.89 O (note 2) TLV 3 */
3906 ELEM_IN_ELEM_OPT_TELV(0x6e, BSSGP_PDU_TYPE, DE_BSSGP_CONTAINER_ID, NULL);
3907 /* Global TFI Global TFI/11.3.90 O (note 2, note 3) TLV 3 */
3908 ELEM_IN_ELEM_OPT_TELV(0x6f, BSSGP_PDU_TYPE, DE_BSSGP_GLOBAL_TFI, NULL);
3909 /* PS Handover Indications PS Handover Indications/11.3.95a O TLV 3 */
3910 ELEM_IN_ELEM_OPT_TELV(0x75, BSSGP_PDU_TYPE, DE_BSSGP_PS_HO_INDICATIONS, NULL);
3911 /* CS Indication CS Indication/11.3.98 O (note 3) TLV 3 */
3912 ELEM_IN_ELEM_OPT_TELV(0x7a, BSSGP_PDU_TYPE, DE_BSSGP_CS_INDICATION, NULL);
3913 /* E-UTRAN Inter RAT Handover Info E-UTRAN Inter RAT HandoverInfo/11.3.104 O (note 1) TLV 3-? */
3914 ELEM_IN_ELEM_OPT_TELV(0x80, BSSGP_PDU_TYPE, DE_BSSGP_E_UTRAN_INTER_RAT_HO_INFO, NULL);
3916 return(curr_offset-offset);
3920 * 11.3.80 Target BSS to Source BSS Transparent Container
3922 guint16
3923 de_bssgp_target_BSS_to_source_BSS_transp_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U_, guint32 offset, guint len _U_, gchar *add_string _U_, int string_len _U_)
3925 guint32 curr_offset;
3926 guint32 consumed;
3927 guint curr_len;
3929 curr_offset = offset;
3930 curr_len = len;
3933 /* Octet 3-? Target BSS to Source BSS Transparent Container Contents coded
3934 * as defined in table 11.3.80.b
3937 /* PS Handover Command PS Handover Command/11.3.95 O (Note 2) TLV 4-? */
3938 ELEM_IN_ELEM_OPT_TELV(0x74, BSSGP_PDU_TYPE, DE_BSSGP_PS_HO_CMD, NULL);
3939 /* SI/PSI Container SI/PSI Container/11.3.95b O (Note 1) TLV 3-? */
3940 ELEM_IN_ELEM_OPT_TELV(0x76, BSSGP_PDU_TYPE, DE_BSSGP_SIPSI_CONTAINER, NULL);
3941 /* DTM Handover Command DTM Handover Command/11.3.97 O (Note 2) TLV 22-? */
3942 ELEM_IN_ELEM_OPT_TELV(0x79, BSSGP_PDU_TYPE, DE_BBSGP_DTM_HO_CMD, NULL);
3944 return(curr_offset-offset);
3947 /* MESSAGE FUNCTIONS */
3950 * 10.2 PDU functional definitions and contents at RL and BSSGP SAPs
3951 * 10.2.1 DL-UNITDATA
3953 static void
3954 bssgp_dl_unitdata(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
3956 guint32 curr_offset;
3957 guint32 consumed;
3958 guint curr_len;
3960 curr_offset = offset;
3961 curr_len = len;
3963 /* This PDU is sent to the BSS to transfer an LLC-PDU across the radio interface to an MS. */
3964 pinfo->link_dir = P2P_DIR_DL;
3966 /* TLLI (current) TLLI/11.3.35 M V 4 */
3967 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TLLI, " - current");
3968 /* QoS Profile (note 1) QoS Profile/11.3.28 M V 3 */
3969 ELEM_MAND_V(BSSGP_PDU_TYPE, DE_BSSGP_QOS_PROFILE, NULL);
3971 /* PDU Lifetime PDU Lifetime/11.3.25 M TLV 4 */
3972 ELEM_MAND_TELV(0x16, BSSGP_PDU_TYPE, DE_BSSGP_PDU_LIFETIME, NULL);
3973 /* MS Radio Access Capability (note 2) MS Radio Access Capability/11.3.22 O TLV 7-? */
3974 ELEM_OPT_TELV(BSSGP_IEI_MS_RADIO_ACCESS_CAPABILITY, GSM_A_PDU_TYPE_GM, DE_MS_RAD_ACC_CAP , NULL);
3975 /* Priority (note 3) Priority/11.3.27 O TLV 3 */
3976 ELEM_OPT_TELV(0x17, GSM_A_PDU_TYPE_BSSMAP, BE_PRIO, NULL);
3977 /* DRX Parameters DRX Parameters/11.3.11 O TLV 4 */
3978 ELEM_OPT_TELV(0x0a , GSM_A_PDU_TYPE_GM, DE_DRX_PARAM , NULL);
3979 /* IMSI IMSI/11.3.14 O TLV 5-10 */
3980 ELEM_OPT_TELV(BSSGP_IEI_IMSI, BSSGP_PDU_TYPE, DE_BSSGP_IMSI , NULL);
3981 /* TLLI (old) TLLI/11.3.35 O TLV 6 */
3982 ELEM_OPT_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , " - old");
3983 /* PFI PFI/11.3.42 O TLV 3 */
3984 ELEM_OPT_TELV( BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
3985 /* LSA Information LSA Information/11.3.19 O TLV 7-? */
3986 ELEM_OPT_TELV(0x27, GSM_A_PDU_TYPE_BSSMAP, BE_LSA_INFO, NULL);
3987 /* Service UTRAN CCO Service UTRAN CCO/11.3.47 O TLV 3 */
3988 ELEM_OPT_TELV(BSSGP_IEI_SERVICE_UTRAN_CCO, BSSGP_PDU_TYPE, DE_BSSGP_SERV_UTRAN_CCO, NULL);
3990 /* Subscriber Profile ID for RAT/Frequency priority (note 5)
3991 * Subscriber Profile ID for RAT/Frequency priority/11.3.105 O TLV 3
3993 ELEM_OPT_TELV(0x81, BSSGP_PDU_TYPE, DE_BSSGP_SUB_PROF_ID_F_RAT_FRQ_PRIO, NULL);
3994 /* Redirection Indication (note 6) Redirection Indication/11.3.112 O TLV 3 */
3995 ELEM_OPT_TELV(BSSGP_IEI_REDIR_INDICATION, BSSGP_PDU_TYPE, DE_BSSGP_REDIR_INDICATION, NULL);
3996 /* Redirection Completed (note 7) Redirection Completed/ 11.3.113 O TLV 3 */
3997 ELEM_OPT_TELV(BSSGP_IEI_REDIR_COMPLETE, BSSGP_PDU_TYPE, DE_BSSGP_REDIR_COMPLETE, NULL);
3998 /* Unconfirmed send state variable (note 9) Unconfirmed send state variable/11.3.114 C TLV 4 */
3999 ELEM_OPT_TELV(BSSGP_IEI_UNCONFIRM_SEND_STATE_VAR, BSSGP_PDU_TYPE, DE_BSSGP_UNCONFIRM_SEND_STATE_VAR, NULL);
4000 /* Alignment octets Alignment octets/11.3.1 O TLV 2-5 */
4001 ELEM_OPT_TELV(0x00, BSSGP_PDU_TYPE, DE_BSSGP_ALIGNMENT_OCTETS, NULL);
4002 /* LLC-PDU (note 4) LLC-PDU/11.3.15 M TLV 2-? */
4003 ELEM_MAND_TELV(0x0e, BSSGP_PDU_TYPE, DE_BSSGP_LLC_PDU, NULL);
4004 /* Initial LLC-PDU (note 8) LLC-PDU/11.3.15 O TLV 2-? */
4005 ELEM_OPT_TELV(0x0e, BSSGP_PDU_TYPE, DE_BSSGP_LLC_PDU, " - initial");
4007 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4010 * 10.2.2 UL-UNITDATA
4011 * Updated to 3GPP TS 48.018 version 11.3.0 Release 11
4013 static void
4014 bssgp_ul_unitdata(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4016 guint32 curr_offset;
4017 guint32 consumed;
4018 guint curr_len;
4020 curr_offset = offset;
4021 curr_len = len;
4023 /* This PDU transfers an MS's LLC-PDU and its associated radio interface information across the Gb-interface.
4024 * Direction: BSS to SGSN
4026 pinfo->link_dir = P2P_DIR_UL;
4027 /* TLLI TLLI/11.3.35 M V 4 */
4028 ELEM_MAND_V(GSM_A_PDU_TYPE_RR, DE_RR_TLLI, NULL);
4029 /* QoS Profile QoS Profile/11.3.28 M V 3 */
4030 ELEM_MAND_V(BSSGP_PDU_TYPE, DE_BSSGP_QOS_PROFILE, NULL);
4031 /* Cell Identifier Cell Identifier/11.3.9 M TLV 10 */
4032 ELEM_OPT_TELV(BSSGP_IEI_CELL_IDENTIFIER, BSSGP_PDU_TYPE, DE_BSSGP_CELL_ID , NULL);
4033 /* PFI PFI/11.3.42 O TLV 3 */
4034 ELEM_OPT_TELV(BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
4035 /* LSA Identifier List LSA Identifier List/11.3.18 O TLV 3-? */
4036 ELEM_OPT_TELV(0x26, GSM_A_PDU_TYPE_BSSMAP, BE_LSA_ID_LIST, NULL);
4037 /* Redirect Attempt Flag (Note 3) Redirect Attempt Flag/11.3.111 O TLV 3 */
4038 ELEM_OPT_TELV(BSSGP_IEI_REDIR_ATTEMP_FLG, BSSGP_PDU_TYPE, DE_BSSGP_REDIR_ATTEMPT_FLG, NULL);
4039 /* IMSI (note 2) IMSI/11.3.14 O TLV 5-10 */
4040 ELEM_OPT_TELV(BSSGP_IEI_IMSI, BSSGP_PDU_TYPE, DE_BSSGP_IMSI , NULL);
4041 /* Unconfirmed send state variable (note 4) Unconfirmed send state variable/11.3.114 O TLV 4 */
4042 ELEM_OPT_TELV(BSSGP_IEI_UNCONFIRM_SEND_STATE_VAR, BSSGP_PDU_TYPE, DE_BSSGP_UNCONFIRM_SEND_STATE_VAR, NULL);
4043 /* Selected PLMN ID (note 5) Selected PLMN ID/11.3.118 O TLV 5 */
4044 ELEM_OPT_TELV(BSSGP_IEI_SELECTED_PLMN_ID, BSSGP_PDU_TYPE, DE_BSSGP_SELECTED_PLMN_ID, NULL);
4045 /* Alignment octets Alignment octets/11.3.1 O TLV 2-5 */
4046 ELEM_OPT_TELV(0x00, BSSGP_PDU_TYPE, DE_BSSGP_ALIGNMENT_OCTETS, NULL);
4047 /* LLC-PDU (note) LLC-PDU/11.3.15 M TLV 2-? */
4048 ELEM_MAND_TELV(0x0e, BSSGP_PDU_TYPE, DE_BSSGP_LLC_PDU, NULL);
4050 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4053 * 10.2.3 RA-CAPABILITY
4055 static void
4056 bssgp_ra_cap(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4058 guint32 curr_offset;
4059 guint32 consumed;
4060 guint curr_len;
4062 curr_offset = offset;
4063 curr_len = len;
4065 /* This PDU informs the BSS of the new Radio Access Capability of an MS. */
4066 pinfo->link_dir = P2P_DIR_UL;
4068 /* TLLI TLLI/11.3.35 M TLV 6 */
4069 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4070 /* MS Radio Access Capability MS Radio Access Capability/11.3.22 M TLV 7-? */
4071 ELEM_MAND_TELV(BSSGP_IEI_MS_RADIO_ACCESS_CAPABILITY, GSM_A_PDU_TYPE_GM, DE_MS_RAD_ACC_CAP , NULL);
4073 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4077 * 10.2.4 (void)
4080 * 10.2.5 DL-MBMS-UNITDATA
4082 static void
4083 bssgp_dl_mbms_unitdata(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4085 guint32 curr_offset;
4086 guint32 consumed;
4087 guint curr_len;
4089 curr_offset = offset;
4090 curr_len = len;
4092 /* This PDU is sent to the BSS to transfer an LLC-PDU across the radio interface.
4093 * Direction: SGSN to BSS
4095 pinfo->link_dir = P2P_DIR_DL;
4097 /* PDU Lifetime PDU Lifetime/11.3.25 M TLV 4 */
4098 ELEM_MAND_TELV(0x16, BSSGP_PDU_TYPE, DE_BSSGP_PDU_LIFETIME, NULL);
4099 /* TMGI TMGI/ 11.3.77 M TLV 3-8 */
4100 ELEM_MAND_TELV(0x5c, GSM_A_PDU_TYPE_GM, DE_TMGI, NULL);
4101 /* MBMS Session Identity MBMS Session Identity/ 11.3.71 O TLV 3 */
4102 ELEM_OPT_TELV(0x5d, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_ID, NULL);
4103 /* Alignment octets Alignment octets/11.3.1 O TLV 2-5 */
4104 ELEM_OPT_TELV(0x00, BSSGP_PDU_TYPE, DE_BSSGP_ALIGNMENT_OCTETS, NULL);
4105 /* LLC-PDU LLC-PDU/11.3.15 M TLV 3-? */
4106 ELEM_MAND_TELV(0x0e, BSSGP_PDU_TYPE, DE_BSSGP_LLC_PDU, NULL);
4109 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4113 * 10.2.6 UL-MBMS-UNITDATA
4115 static void
4116 bssgp_ul_mbms_unitdata(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4118 guint32 curr_offset;
4119 guint32 consumed;
4120 guint curr_len;
4122 curr_offset = offset;
4123 curr_len = len;
4125 /* This PDU transfers an LLC-PDU for an MBMS session across the Gb-interface.
4126 * Direction: BSS to SGSN */
4127 pinfo->link_dir = P2P_DIR_UL;
4129 /* TMGI TMGI/ 11.3.77 M TLV 3-8 */
4130 ELEM_MAND_TELV(0x5c, GSM_A_PDU_TYPE_GM, DE_TMGI, NULL);
4131 /* MBMS Session Identity MBMS Session Identity/ 11.3.71 O TLV 3 */
4132 ELEM_OPT_TELV(0x5d, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_ID, NULL);
4133 /* Alignment octets Alignment octets/11.3.1 O TLV 2-5 */
4134 ELEM_OPT_TELV(0x00, BSSGP_PDU_TYPE, DE_BSSGP_ALIGNMENT_OCTETS, NULL);
4135 /* LLC-PDU (note 1) LLC-PDU/11.3.15 M TLV 2-? */
4136 ELEM_MAND_TELV(0x0e, BSSGP_PDU_TYPE, DE_BSSGP_LLC_PDU, NULL);
4138 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4142 * 10.3 PDU functional definitions and contents at GMM SAP
4143 * 10.3.1 PAGING PS
4146 static void
4147 bssgp_paging_ps(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4149 guint32 curr_offset;
4150 guint32 consumed;
4151 guint curr_len;
4153 curr_offset = offset;
4154 curr_len = len;
4155 /* This PDU indicates that a BSS shall initiate the packet paging procedure for an MS within a group of cells.
4156 * Direction: SGSN to BSS */
4157 pinfo->link_dir = P2P_DIR_DL;
4159 /* IMSI IMSI/11.3.14 M TLV 5 -10 */
4160 ELEM_MAND_TELV(BSSGP_IEI_IMSI, BSSGP_PDU_TYPE, DE_BSSGP_IMSI , NULL);
4161 /* DRX Parameters DRX Parameters/11.3.11 O TLV 4 */
4162 ELEM_OPT_TELV(0x0a , GSM_A_PDU_TYPE_GM, DE_DRX_PARAM , NULL);
4163 /* BVCI a) BVCI/11.3.6 C TLV 4 */
4164 ELEM_OPT_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , NULL);
4165 /* Location Area (note) Location Area/11.3.17 C TLV 7 */
4166 ELEM_OPT_TELV(0x10,GSM_A_PDU_TYPE_COMMON, DE_LAI, NULL);
4167 /* Routeing Area (note) Routeing Area/11.3.31 C TLV 8 */
4168 ELEM_OPT_TELV(0x1b,GSM_A_PDU_TYPE_GM, DE_RAI, NULL);
4169 /* BSS Area Indication (note) BSS Area Indication/11.3.3 C TLV 3 */
4170 ELEM_OPT_TELV(0x02,BSSGP_PDU_TYPE, DE_BSSGP_BSS_AREA_IND, NULL);
4171 /* PFI PFI/11.3.42 O TLV 3 */
4172 ELEM_OPT_TELV(BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
4173 /* ABQP ABQP/11.3.43 O TLV 13-? */
4174 ELEM_OPT_TELV(0x3a , GSM_A_PDU_TYPE_GM, DE_QOS , NULL);
4175 /* QoS Profile QoS Profile/11.3.28 M TLV 5 */
4176 ELEM_MAND_TELV(0x18,BSSGP_PDU_TYPE, DE_BSSGP_QOS_PROFILE, NULL);
4177 /* P-TMSI TMSI/11.3.36 O TLV 6 */
4178 ELEM_OPT_TELV(BSSGP_IEI_TMSI,GSM_A_PDU_TYPE_RR, DE_RR_TMSI_PTMSI, NULL);
4180 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4184 * 10.3.2 PAGING CS
4186 static void
4187 bssgp_paging_cs(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4189 guint32 curr_offset;
4190 guint32 consumed;
4191 guint curr_len;
4193 curr_offset = offset;
4194 curr_len = len;
4195 /* This PDU indicates that a BSS shall initiate a circuit-switched paging procedure for an MS within a group of cells.
4196 * Direction: SGSN to BSS
4198 pinfo->link_dir = P2P_DIR_DL;
4199 /* IMSI IMSI/11.3.14 M TLV 5 -10 */
4200 ELEM_MAND_TELV(BSSGP_IEI_IMSI, BSSGP_PDU_TYPE, DE_BSSGP_IMSI , NULL);
4201 /* DRX Parameters DRX Parameters/11.3.11 M TLV 4 */
4202 ELEM_MAND_TELV(0x0a , GSM_A_PDU_TYPE_GM, DE_DRX_PARAM , NULL);
4203 /* BVCI a) BVCI/11.3.6 C TLV 4 */
4204 ELEM_OPT_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , NULL);
4205 /* Location Area (note 1) Location Area/11.3.17 C TLV 7 */
4206 ELEM_OPT_TELV(0x10,GSM_A_PDU_TYPE_COMMON, DE_LAI, NULL);
4207 /* Routeing Area (note 1) Routeing Area/11.3.31 C TLV 8 */
4208 ELEM_OPT_TELV(0x1b,GSM_A_PDU_TYPE_GM, DE_RAI, NULL);
4209 /* BSS Area Indication (note 1) BSS Area Indication/11.3.3 C TLV 3 */
4210 ELEM_OPT_TELV(0x02,BSSGP_PDU_TYPE, DE_BSSGP_BSS_AREA_IND, NULL);
4211 /* TLLI TLLI/11.3.35 O TLV 6 */
4212 ELEM_OPT_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4213 /* Channel needed (note 2) Channel needed/11.3.10 O TLV 3 */
4214 ELEM_OPT_TELV(0x09, BSSGP_PDU_TYPE, DE_BSSGP_CHLN_NEEDED , NULL);
4215 /* eMLPP-Priority (note 2) eMLPP-Priority/11.3.12 O TLV 3 */
4216 ELEM_OPT_TELV(0x0b, GSM_A_PDU_TYPE_BSSMAP, BE_EMLPP_PRIO, NULL);
4217 /* TMSI (note 2) TMSI/11.3.36 O TLV 6 */
4218 ELEM_OPT_TELV(BSSGP_IEI_TMSI,GSM_A_PDU_TYPE_RR, DE_RR_TMSI_PTMSI, NULL);
4219 /* Global CN-Id (note 2) Global CN-Id/11.3.69 O TLV 7 */
4220 ELEM_OPT_TELV(0x53, SGSAP_PDU_TYPE, DE_SGSAP_GLOBAL_CN_ID, NULL);
4222 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4226 * 10.3.3 RA-CAPABILITY-UPDATE
4228 static void
4229 bssgp_ra_cap_upd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4231 guint32 curr_offset;
4232 guint32 consumed;
4233 guint curr_len;
4235 curr_offset = offset;
4236 curr_len = len;
4237 /* This PDU requests that the SGSN send an MS's current Radio Access capability or IMSI to the BSS. */
4238 /* Direction: BSS to SGSN */
4239 pinfo->link_dir = P2P_DIR_UL;
4241 /* TLLI TLLI/11.3.35 M TLV 6 */
4242 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4243 /* Tag Tag/11.3.34 M TLV 3 */
4244 ELEM_MAND_TELV(BSSGP_IEI_TAG, BSSGP_PDU_TYPE, DE_BSSGP_TAG , NULL);
4245 /* IMSI (note) IMSI/11.3.14 C TLV 5 -10 */
4246 ELEM_OPT_TELV(BSSGP_IEI_IMSI, BSSGP_PDU_TYPE, DE_BSSGP_IMSI , NULL);
4247 /* RA-Cap-UPD-CAUSE RA-Cap-UPDCAUSE/11.3.30 M TLV 3 */
4248 ELEM_OPT_TELV(BSSGP_IEI_RA_CAP_UPD_CAUSE, BSSGP_PDU_TYPE, DE_BSSGP_RA_CAP_UPD_CAUSE , NULL);
4249 /* MS Radio Access Capability MS Radio Access Capability/11.3.22 C TLV 7-? */
4250 ELEM_OPT_TELV(BSSGP_IEI_MS_RADIO_ACCESS_CAPABILITY, GSM_A_PDU_TYPE_GM, DE_MS_RAD_ACC_CAP , NULL);
4252 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4256 * 10.3.4 RA-CAPABILITY-UPDATE-ACK
4259 static void
4260 bssgp_ra_cap_upd_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4262 guint32 curr_offset;
4263 guint32 consumed;
4264 guint curr_len;
4266 curr_offset = offset;
4267 curr_len = len;
4268 /* This PDU provides the BSS with an MS's current Radio Access capability and IMSI */
4269 /* Direction: SGSN to BSS */
4270 pinfo->link_dir = P2P_DIR_DL;
4272 /* TLLI TLLI/11.3.35 M TLV 6 */
4273 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4274 /* Tag Tag/11.3.34 M TLV 3 */
4275 ELEM_MAND_TELV(BSSGP_IEI_TAG, BSSGP_PDU_TYPE, DE_BSSGP_TAG , NULL);
4276 /* IMSI (note) IMSI/11.3.14 C TLV 5 -10 */
4277 ELEM_OPT_TELV(BSSGP_IEI_IMSI, BSSGP_PDU_TYPE, DE_BSSGP_IMSI , NULL);
4278 /* RA-Cap-UPD-CAUSE RA-Cap-UPDCAUSE/11.3.30 M TLV 3 */
4279 ELEM_OPT_TELV(BSSGP_IEI_RA_CAP_UPD_CAUSE, BSSGP_PDU_TYPE, DE_BSSGP_RA_CAP_UPD_CAUSE , NULL);
4280 /* MS Radio Access Capability MS Radio Access Capability/11.3.22 C TLV 7-? */
4281 ELEM_OPT_TELV(BSSGP_IEI_MS_RADIO_ACCESS_CAPABILITY, GSM_A_PDU_TYPE_GM, DE_MS_RAD_ACC_CAP , NULL);
4283 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4287 * 10.3.5 RADIO-STATUS
4289 static void
4290 bssgp_ra_status(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4292 guint32 curr_offset;
4293 guint32 consumed;
4294 guint curr_len;
4296 curr_offset = offset;
4297 curr_len = len;
4299 /* This PDU indicates that an exception condition related to the radio interface has occurred. */
4300 /* BSS to SGSN */
4301 pinfo->link_dir = P2P_DIR_UL;
4303 /* TLLI (note) TLLI/11.3.35 C TLV 6 */
4304 ELEM_OPT_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4305 /* TMSI (note) TMSI/11.3.36 C TLV 6 */
4306 ELEM_OPT_TELV(BSSGP_IEI_TMSI,GSM_A_PDU_TYPE_RR, DE_RR_TMSI_PTMSI, NULL);
4307 /* IMSI (note) IMSI/11.3.14 C TLV 5-10 */
4308 ELEM_OPT_TELV(BSSGP_IEI_IMSI, BSSGP_PDU_TYPE, DE_BSSGP_IMSI , NULL);
4309 /* Radio Cause Radio Cause/11.3.29 M TLV 3 */
4310 ELEM_MAND_TELV(BSSGP_IEI_RADIO_CAUSE, BSSGP_PDU_TYPE, DE_BSSGP_RA_CAUSE , NULL);
4312 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4315 * 10.3.6 SUSPEND
4317 static void
4318 bssgp_suspend(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4320 guint32 curr_offset;
4321 guint32 consumed;
4322 guint curr_len;
4324 curr_offset = offset;
4325 curr_len = len;
4327 /* This PDU indicates that an MS wishes to suspend its GPRS service. */
4328 /* Direction: BSS to SGSN */
4329 pinfo->link_dir = P2P_DIR_UL;
4331 /* TLLI TLLI/11.3.35 M TLV 6 */
4332 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4333 /* Routeing Area Routeing Area/11.3.31 M TLV 8 */
4334 ELEM_MAND_TELV(0x1b,GSM_A_PDU_TYPE_GM, DE_RAI, NULL);
4336 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4339 * 10.3.7 SUSPEND-ACK
4341 void
4342 bssgp_suspend_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4344 guint32 curr_offset;
4345 guint32 consumed;
4346 guint curr_len;
4348 curr_offset = offset;
4349 curr_len = len;
4351 /* This PDU positively acknowledges the reception of a SUSPEND PDU for an MS. */
4352 /* Direction: SGSN to BSS */
4353 pinfo->link_dir = P2P_DIR_DL;
4355 /* TLLI TLLI/11.3.35 M TLV 6 */
4356 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4357 /* Routeing Area Routeing Area/11.3.31 M TLV 8 */
4358 ELEM_MAND_TELV(0x1b,GSM_A_PDU_TYPE_GM, DE_RAI, NULL);
4359 /* Suspend Reference Number Suspend Reference Number/11.3.33 M TLV 3 */
4360 ELEM_MAND_TELV(0x1d,BSSGP_PDU_TYPE, DE_BBSGP_SUSPEND_REF_NO, NULL);
4363 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4366 * 10.3.8 SUSPEND-NACK
4368 static void
4369 bssgp_suspend_nack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4371 guint32 curr_offset;
4372 guint32 consumed;
4373 guint curr_len;
4375 curr_offset = offset;
4376 curr_len = len;
4379 /* This PDU negatively acknowledges the reception of a SUSPEND PDU for an MS. */
4380 /* Direction: SGSN to BSS */
4381 pinfo->link_dir = P2P_DIR_DL;
4383 /* TLLI TLLI/11.3.35 M TLV 6 */
4384 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4385 /* Routeing Area Routeing Area/11.3.31 M TLV 8 */
4386 ELEM_MAND_TELV(0x1b,GSM_A_PDU_TYPE_GM, DE_RAI, NULL);
4387 /* Cause Cause/11.3.8 O TLV 3 */
4388 ELEM_MAND_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
4390 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4393 * 10.3.9 RESUME
4395 static void
4396 bssgp_resume(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4398 guint32 curr_offset;
4399 guint32 consumed;
4400 guint curr_len;
4402 curr_offset = offset;
4403 curr_len = len;
4405 /* This PDU indicates that an MS wishes to RESUME its GPRS service. */
4406 /* Direction: BSS to SGSN */
4407 pinfo->link_dir = P2P_DIR_UL;
4409 /* TLLI TLLI/11.3.35 M TLV 6 */
4410 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4411 /* Routeing Area Routeing Area/11.3.31 M TLV 8 */
4412 ELEM_MAND_TELV(0x1b,GSM_A_PDU_TYPE_GM, DE_RAI, NULL);
4413 /* Suspend Reference Number Suspend Reference Number/11.3.33 M TLV 3 */
4414 ELEM_MAND_TELV(0x1d,BSSGP_PDU_TYPE, DE_BBSGP_SUSPEND_REF_NO, NULL);
4416 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4419 * 10.3.10 RESUME-ACK
4422 static void
4423 bssgp_resume_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4425 guint32 curr_offset;
4426 guint32 consumed;
4427 guint curr_len;
4429 curr_offset = offset;
4430 curr_len = len;
4432 /* This PDU positively acknowledges the reception of a RESUME PDU for an MS. */
4433 /* Direction: SGSN to BSS */
4434 pinfo->link_dir = P2P_DIR_DL;
4436 /* TLLI TLLI/11.3.35 M TLV 6 */
4437 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4438 /* Routeing Area Routeing Area/11.3.31 M TLV 8 */
4439 ELEM_MAND_TELV(0x1b,GSM_A_PDU_TYPE_GM, DE_RAI, NULL);
4441 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4444 * 10.3.11 RESUME-NACK
4447 static void
4448 bssgp_resume_nack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4450 guint32 curr_offset;
4451 guint32 consumed;
4452 guint curr_len;
4454 curr_offset = offset;
4455 curr_len = len;
4457 /* This PDU negatively acknowledges the reception of a RESUME PDU for an MS. */
4458 /* Direction: SGSN to BSS */
4459 pinfo->link_dir = P2P_DIR_DL;
4461 /* TLLI TLLI/11.3.35 M TLV 6 */
4462 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4463 /* Routeing Area Routeing Area/11.3.31 M TLV 8 */
4464 ELEM_MAND_TELV(0x1b,GSM_A_PDU_TYPE_GM, DE_RAI, NULL);
4465 /* Cause Cause/11.3.8 O TLV 3 */
4466 ELEM_OPT_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
4468 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4471 * 10.4 PDU functional definitions and contents at NM SAP
4472 * 10.4.1 FLUSH-LL
4474 static void
4475 bssgp_flush_ll(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4477 guint32 curr_offset;
4478 guint32 consumed;
4479 guint curr_len;
4481 curr_offset = offset;
4482 curr_len = len;
4484 /* This PDU informs a BSS that an MS has moved from one cell to another. */
4485 /* Direction: SGSN to BSS */
4486 pinfo->link_dir = P2P_DIR_DL;
4488 /* TLLI TLLI/11.3.35 M TLV 6 */
4489 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4490 /* BVCI (old) BVCI/11.3.6 M TLV 4 */
4491 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , " - Old");
4492 /* BVCI (new) BVCI/11.3.6 O TLV 4 */
4493 ELEM_OPT_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , " - New");
4494 /* NSEI (new) NSEI/11.3.48 O (note) TLV 4 */
4495 ELEM_OPT_TELV(0x3e, GSM_A_PDU_TYPE_RR, DE_BSSGP_NSEI , " - New");
4497 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4500 * 10.4.2 FLUSH-LL-ACK
4502 static void
4503 bssgp_flush_ll_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4505 guint32 curr_offset;
4506 guint32 consumed;
4507 guint curr_len;
4509 curr_offset = offset;
4510 curr_len = len;
4512 /* This PDU indicates that LLC-PDU(s) buffered for an MS in the old cell
4513 * have been either deleted or transferred to the new cell within the routing area. */
4514 /* Direction: BSS to SGSN */
4515 pinfo->link_dir = P2P_DIR_UL;
4517 /* TLLI TLLI/11.3.35 M TLV 6 */
4518 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4519 /* Flush Action Flush Action/11.3.13 M TLV 3 */
4520 ELEM_MAND_TELV(0x0c, BSSGP_PDU_TYPE, DE_BSSGP_FLUSH_ACTION , NULL);
4521 /* BVCI (new) BVCI/11.3.13 C (note 1) TLV 4 */
4522 ELEM_OPT_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , " - New");
4523 /* Number of octets affected Number of octets affected/11.3.41 M TLV 5 */
4524 ELEM_MAND_TELV(BSSGP_IEI_NUMBER_OF_OCTETS_AFFECTED, BSSGP_PDU_TYPE, DE_BSSGP_NO_OF_OCT_AFFECTED , NULL);
4525 /* NSEI (new) NSEI/11.3.48 C (note 2) TLV 4 */
4526 ELEM_OPT_TELV(0x3e, GSM_A_PDU_TYPE_RR, DE_BSSGP_NSEI , " - New");
4529 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4532 * 10.4.3 LLC-DISCARDED
4534 static void
4535 bssgp_llc_discarded(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4537 guint32 curr_offset;
4538 guint32 consumed;
4539 guint curr_len;
4541 curr_offset = offset;
4542 curr_len = len;
4544 /* Direction: BSS to SGSN */
4545 pinfo->link_dir = P2P_DIR_UL;
4547 /* TLLI TLLI/11.3.35 M TLV 6 */
4548 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4549 /* LLC Frames Discarded LLC Frames Discarded/11.3.16 M TLV 3 */
4550 ELEM_MAND_TELV(BSSGP_IEI_LLC_FRAMES_DISCARDED, BSSGP_PDU_TYPE, DE_BSSGP_LLC_FRAMES_DISC , NULL);
4551 /* BVCI BVCI/11.3.6 M TLV 4 */
4552 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , NULL);
4553 /* Number of octets deleted Number of octets affected/11.3.41 M TLV 5 */
4554 ELEM_MAND_TELV(BSSGP_IEI_NUMBER_OF_OCTETS_AFFECTED, BSSGP_PDU_TYPE, DE_BSSGP_NO_OF_OCT_AFFECTED , NULL);
4555 /* PFI (note) PFI/11.3.42 O TLV 3 */
4556 ELEM_OPT_TELV(BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
4558 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4562 * 10.4.4 FLOW-CONTROL-BVC
4564 static void
4565 bssgp_flow_control_bvc(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4567 guint32 curr_offset;
4568 guint32 consumed;
4569 guint curr_len;
4571 curr_offset = offset;
4572 curr_len = len;
4574 /* This PDU informs the flow control mechanism at an SGSN of the status of a
4575 * BVC's maximum acceptable SGSN to BSS throughput on the Gb interface.
4577 /* Direction: BSS to SGSN */
4578 pinfo->link_dir = P2P_DIR_UL;
4580 /* Tag Tag/11.3.34 M TLV 3 */
4581 ELEM_MAND_TELV(BSSGP_IEI_TAG, BSSGP_PDU_TYPE, DE_BSSGP_TAG , NULL);
4582 /* BVC Bucket Size BVC Bucket Size/11.3.5 M TLV 4 */
4583 ELEM_MAND_TELV(0x05, BSSGP_PDU_TYPE, DE_BSSGP_BVC_BUCKET_SIZE , NULL);
4584 /* Bucket Leak Rate Bucket Leak Rate/11.3.4 M TLV 4 */
4585 ELEM_MAND_TELV(BSSGP_IEI_BUCKET_LEAK_RATE, BSSGP_PDU_TYPE, DE_BSSGP_BUCKET_LEAK_RATE , NULL);
4586 /* Bmax default MS Bmax default MS/11.3.2 M TLV 4 */
4587 ELEM_MAND_TELV(0x01, BSSGP_PDU_TYPE, DE_BSSGP_BMAX_DEFAULT_MS , NULL);
4588 /* R_default_MS R_default_MS/11.3.32 M TLV 4 */
4589 ELEM_MAND_TELV(0x1c, BSSGP_PDU_TYPE, DE_BSSGP_R_DEFAULT_MS , NULL);
4590 /* Bucket_Full Ratio Bucket_Full Ratio/11.3.46 C TLV 3 */
4591 ELEM_OPT_TELV(BSSGP_IEI_BUCKET_FULL_RATIO, BSSGP_PDU_TYPE, DE_BSSGP_BUCKET_FULL_RATIO , NULL);
4592 /* BVC Measurement BVC Measurement/11.3.7 O TLV 4 */
4593 ELEM_OPT_TELV(0x06, BSSGP_PDU_TYPE, DE_BSSGP_BVC_MEAS , NULL);
4594 /* Flow Control Granularity (note) Flow Control Granularity/11.3.102 O TLV 3 */
4595 ELEM_OPT_TELV(0x7e, BSSGP_PDU_TYPE, DE_BSSGP_FLOW_CONTROL_GRAN , NULL);
4597 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4601 * 10.4.5 FLOW-CONTROL-BVC-ACK
4603 static void
4604 bssgp_flow_control_bvc_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4606 guint32 curr_offset;
4607 guint32 consumed;
4608 guint curr_len;
4610 curr_offset = offset;
4611 curr_len = len;
4613 /* This PDU informs the flow control mechanism at the BSS that the SGSN has received
4614 * the FLOW-CONTROL-BVC PDU indicated by the Tag.
4617 /* Direction: SGSN to BSS */
4618 pinfo->link_dir = P2P_DIR_DL;
4620 /* Tag Tag/11.3.34 M TLV 3 */
4621 ELEM_MAND_TELV(BSSGP_IEI_TAG, BSSGP_PDU_TYPE, DE_BSSGP_TAG , NULL);
4623 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4627 * 10.4.6 FLOW-CONTROL-MS
4629 static void
4630 bssgp_flow_control_ms(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4632 guint32 curr_offset;
4633 guint32 consumed;
4634 guint curr_len;
4636 curr_offset = offset;
4637 curr_len = len;
4639 /* This PDU informs the flow control mechanism at an SGSN of the status of an MS's
4640 * maximum acceptable SGSN to BSS throughput on the Gb interface.
4643 /* Direction: BSS to SGSN */
4644 pinfo->link_dir = P2P_DIR_UL;
4646 /* TLLI TLLI/11.3.35 M TLV 6 */
4647 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4648 /* Tag Tag/11.3.34 M TLV 3 */
4649 ELEM_MAND_TELV(BSSGP_IEI_TAG, BSSGP_PDU_TYPE, DE_BSSGP_TAG , NULL);
4650 /* MS Bucket Size MS Bucket Size/11.3.21 M TLV 4 */
4651 ELEM_MAND_TELV(BSSGP_IEI_MS_BUCKET_SIZE, BSSGP_PDU_TYPE, DE_BSSGP_MS_BUCKET_SIZE , NULL);
4652 /* Bucket Leak rate Bucket Leak rate/11.3.4 M TLV 4 */
4653 ELEM_MAND_TELV(BSSGP_IEI_BUCKET_LEAK_RATE, BSSGP_PDU_TYPE, DE_BSSGP_BUCKET_LEAK_RATE , NULL);
4654 /* Bucket_Full Ratio Bucket_Full Ratio/11.3.46 C TLV 3 */
4655 ELEM_OPT_TELV(BSSGP_IEI_BUCKET_FULL_RATIO, BSSGP_PDU_TYPE, DE_BSSGP_BUCKET_FULL_RATIO , NULL);
4656 /* Flow Control Granularity (note) Flow Control Granularity/11.3.102 O TLV 3 */
4657 ELEM_OPT_TELV(0x7e, BSSGP_PDU_TYPE, DE_BSSGP_FLOW_CONTROL_GRAN , NULL);
4659 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4662 * 10.4.7 FLOW-CONTROL-MS-ACK
4664 static void
4665 bssgp_flow_control_ms_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4667 guint32 curr_offset;
4668 guint32 consumed;
4669 guint curr_len;
4671 curr_offset = offset;
4672 curr_len = len;
4674 /* This PDU informs the flow control mechanism at the BSS that the SGSN has received
4675 * the FLOW-CONTROL-MS PDU indicated by the TLLI and the Tag. */
4676 /* Direction: SGSN to BSS */
4677 pinfo->link_dir = P2P_DIR_DL;
4679 /* TLLI TLLI/11.3.35 M TLV 6 */
4680 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4681 /* Tag Tag/11.3.34 M TLV 3 */
4682 ELEM_MAND_TELV(BSSGP_IEI_TAG, BSSGP_PDU_TYPE, DE_BSSGP_TAG , NULL);
4684 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4687 * 10.4.8 BVC-BLOCK
4690 static void
4691 bssgp_bvc_block(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4693 guint32 curr_offset;
4694 guint32 consumed;
4695 guint curr_len;
4697 curr_offset = offset;
4698 curr_len = len;
4700 /* This PDU indicates that the contained BVC shall be blocked at the recipient entity. */
4701 /* BSS to SGSN */
4702 pinfo->link_dir = P2P_DIR_UL;
4704 /* BVCI BVCI/11.3.6 M TLV 4 */
4705 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , NULL);
4706 /* Cause Cause/11.3.8 M TLV 3 */
4707 ELEM_MAND_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
4709 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4713 * 10.4.9 BVC-BLOCK-ACK
4715 static void
4716 bssgp_bvc_block_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4718 guint32 curr_offset;
4719 guint32 consumed;
4720 guint curr_len;
4722 curr_offset = offset;
4723 curr_len = len;
4725 /* This PDU acknowledges that a BVC has been blocked. */
4726 /* SGSN to BSS */
4727 pinfo->link_dir = P2P_DIR_DL;
4729 /* BVCI BVCI/11.3.6 M TLV 4 */
4730 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , NULL);
4732 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4736 * 10.4.10 BVC-UNBLOCK
4738 static void
4739 bssgp_bvc_un_block(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4741 guint32 curr_offset;
4742 guint32 consumed;
4743 guint curr_len;
4745 curr_offset = offset;
4746 curr_len = len;
4748 /* This PDU indicates that the identified BVC shall be unblocked at the recipient entity. */
4749 /* Direction: BSS to SGSN */
4750 pinfo->link_dir = P2P_DIR_UL;
4752 /* BVCI BVCI/11.3.6 M TLV 4 */
4753 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , NULL);
4756 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4759 * 10.4.11 BVC-UNBLOCK-ACK
4762 static void
4763 bssgp_bvc_un_block_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4765 guint32 curr_offset;
4766 guint32 consumed;
4767 guint curr_len;
4769 curr_offset = offset;
4770 curr_len = len;
4772 /* This PDU acknowledges that a BVC has been unblocked. */
4773 /* Direction: SGSN to BSS */
4774 pinfo->link_dir = P2P_DIR_DL;
4776 /* BVCI BVCI/11.3.6 M TLV 4 */
4777 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , NULL);
4779 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4783 * 10.4.12 BVC-RESET
4786 static void
4787 bssgp_bvc_reset(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4789 guint32 curr_offset;
4790 guint32 consumed;
4791 guint curr_len;
4793 curr_offset = offset;
4794 curr_len = len;
4796 /* This PDU indicates that BVC initialisation is required, e.g. because of a BVC failure. */
4797 /* Direction: SGSN to BSS, BSS to SGSN */
4799 /* BVCI BVCI/11.3.6 M TLV 4 */
4800 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , NULL);
4801 /* Cause Cause/11.3.8 M TLV 3 */
4802 ELEM_MAND_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
4803 /* Cell Identifier (note 1) C TLV 10 */
4804 ELEM_OPT_TELV(BSSGP_IEI_CELL_IDENTIFIER, BSSGP_PDU_TYPE, DE_BSSGP_CELL_ID , NULL);
4805 /* Feature bitmap (note 2) Feature bitmap/11.3.45 O TLV 3 */
4806 ELEM_OPT_TELV(0x3b, BSSGP_PDU_TYPE, DE_BSSGP_FEATURE_BITMAP , NULL);
4807 /* Extended Feature Bitmap (note 3) Extended Feature Bitmap/11.3.84 O TLV 3 */
4808 ELEM_OPT_TELV(0x69, BSSGP_PDU_TYPE, DE_BSSGP_EXT_FEATURE_BITMAP , NULL);
4810 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4814 * 10.4.13 BVC-RESET-ACK
4817 static void
4818 bssgp_bvc_reset_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4820 guint32 curr_offset;
4821 guint32 consumed;
4822 guint curr_len;
4824 curr_offset = offset;
4825 curr_len = len;
4827 /* This PDU indicates that BVC initialisation has been executed */
4828 /* BSS to SGSN, SGSN to BSS */
4830 /* BVCI BVCI/11.3.6 M TLV 4 */
4831 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , NULL);
4832 /* Cell Identifier (note 1) C TLV 10 */
4833 ELEM_OPT_TELV(BSSGP_IEI_CELL_IDENTIFIER, BSSGP_PDU_TYPE, DE_BSSGP_CELL_ID , NULL);
4834 /* Feature bitmap (note 2) Feature bitmap/11.3.45 O TLV 3 */
4835 ELEM_OPT_TELV(0x3b, BSSGP_PDU_TYPE, DE_BSSGP_FEATURE_BITMAP , NULL);
4836 /* Extended Feature Bitmap (note 3) Extended Feature Bitmap/11.3.84 O TLV 3 */
4837 ELEM_OPT_TELV(0x69, BSSGP_PDU_TYPE, DE_BSSGP_EXT_FEATURE_BITMAP , NULL);
4839 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4843 * 10.4.14 STATUS
4845 static void
4846 bssgp_status(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4848 guint32 curr_offset;
4849 guint32 consumed;
4850 guint curr_len;
4852 curr_offset = offset;
4853 curr_len = len;
4855 /* This PDU indicates that an exception condition occurred. */
4856 /* Direction: SGSN to BSS, BSS to SGSN */
4858 /* Cause Cause/11.3.8 M TLV 3 */
4859 ELEM_MAND_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
4860 /* BVCI BVCI/11.3.6 C TLV 4 */
4861 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , NULL);
4862 /* PDU In Error (note) PDU In Error/11.3.24 O TLV 3-? */
4863 ELEM_MAND_TELV(0x15, BSSGP_PDU_TYPE, DE_BSSGP_PDU_IN_ERROR , NULL);
4865 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4868 * 10.4.15 SGSN-INVOKE-TRACE
4870 static void
4871 bssgp_sgsn_invoke_trace(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4873 guint32 curr_offset;
4874 guint32 consumed;
4875 guint curr_len;
4877 curr_offset = offset;
4878 curr_len = len;
4880 /* This PDU indicates that the BSS shall begin the production of a trace record for an MS. */
4881 /* Direction: SGSN to BSS */
4883 pinfo->link_dir = P2P_DIR_UL;
4885 /* Trace Type Trace Type/11.3.38 M TLV 3 */
4886 ELEM_MAND_TELV(0x22, BSSGP_PDU_TYPE, DE_BSSGP_TRACE_TYPE , NULL);
4887 /* Trace Reference Trace Reference/11.3.37 M TLV 4 */
4888 ELEM_MAND_TELV(0x21, BSSGP_PDU_TYPE, DE_BSSGP_TRACE_REF , NULL);
4889 /* Trigger Id Trigger Id/11.3.40 O TLV 4-24 */
4890 ELEM_OPT_TELV(0x24, BSSGP_PDU_TYPE, DE_BSSGP_TRIGGER_ID , NULL);
4891 /* Mobile Id Mobile Id/11.3.20 O TLV 3-10 */
4892 ELEM_OPT_TELV(0x11,GSM_A_PDU_TYPE_COMMON, DE_MID, NULL);
4893 /* OMC Id OMC Id/11.3.23 O TLV 4-24 */
4894 ELEM_OPT_TELV(0x14,GSM_A_PDU_TYPE_COMMON, DE_BSSGP_OMC_ID, NULL);
4895 /* TransactionId TransactionId/11.3.39 O TLV 4 */
4896 ELEM_OPT_TELV(0x23, BSSGP_PDU_TYPE, DE_BSSGP_TRANSACTION_ID , NULL);
4898 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4902 * 10.4.16 DOWNLOAD-BSS-PFC
4904 static void
4905 bssgp_download_bss_pfc(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4907 guint32 curr_offset;
4908 guint32 consumed;
4909 guint curr_len;
4911 curr_offset = offset;
4912 curr_len = len;
4914 /* This PDU requests a SGSN to initiate a CREATE-BSS-PFC procedure. */
4915 /* Direction: BSS to SGSN */
4916 pinfo->link_dir = P2P_DIR_UL;
4918 /* TLLI TLLI/11.3.35 M TLV 6 */
4919 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4920 /* PFI PFI/11.3.42 M TLV 3 */
4921 ELEM_MAND_TELV(BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
4923 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4927 * 10.4.17 CREATE-BSS-PFC
4929 static void
4930 bssgp_create_bss_pfc(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4932 guint32 curr_offset;
4933 guint32 consumed;
4934 guint curr_len;
4936 curr_offset = offset;
4937 curr_len = len;
4939 /* This PDU allows the SGSN to request that a BSS create or modify a BSS Packet Flow Context. */
4940 /* Direction: SGSN to BSS */
4941 pinfo->link_dir = P2P_DIR_DL;
4943 /* TLLI TLLI/11.3.35 M TLV 6 */
4944 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4945 /* IMSI IMSI/11.3.14 O (note 4) TLV 5 -10 */
4946 ELEM_OPT_TELV(BSSGP_IEI_IMSI, BSSGP_PDU_TYPE, DE_BSSGP_IMSI , NULL);
4947 /* PFI PFI/11.3.42 M TLV 3 */
4948 ELEM_MAND_TELV(BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
4949 /* PFT GPRS Timer/11.3.44 M TLV 3 */
4950 ELEM_MAND_TELV(0x29, BSSGP_PDU_TYPE, DE_BSSGP_GPRS_TIMER , " - PFT");
4951 /* ABQP ABQP/11.3.43 M TLV 13-? */
4952 ELEM_MAND_TELV(0x3a , GSM_A_PDU_TYPE_GM, DE_QOS , NULL);
4953 /* Service UTRAN CCO Service UTRAN CCO/11.3.47 O TLV 3 */
4954 ELEM_OPT_TELV(BSSGP_IEI_SERVICE_UTRAN_CCO, BSSGP_PDU_TYPE, DE_BSSGP_SERV_UTRAN_CCO, NULL);
4955 /* MS Radio Access Capability MS Radio Access Capability/11.3.22 O (note 1) TLV 7-? */
4956 ELEM_OPT_TELV(BSSGP_IEI_MS_RADIO_ACCESS_CAPABILITY, GSM_A_PDU_TYPE_GM, DE_MS_RAD_ACC_CAP , NULL);
4957 /* Allocation/Retention Priority Priority/11.3.27 O TLV 3 */
4958 ELEM_OPT_TELV(0x17, GSM_A_PDU_TYPE_BSSMAP, BE_PRIO, NULL);
4959 /* T10 GPRS Timer/11.3.44 C (note 2) TLV 3 */
4960 ELEM_MAND_TELV(BSSGP_IEI_GPRS_TIMER, BSSGP_PDU_TYPE, DE_BSSGP_GPRS_TIMER , " - T10");
4961 /* Inter RAT Handover Info Inter RAT Handover Info/11.3.94 O (note 3) TLV 3-? */
4962 ELEM_OPT_TELV(0x73, BSSGP_PDU_TYPE, DE_BSSGP_INTER_RAT_HO_INFO, NULL);
4963 /* E-UTRAN Inter RAT Handover Info E-UTRAN Inter RAT Handover Info/11.3.104 O (note 3) TLV 3-? */
4964 ELEM_OPT_TELV(0x80, BSSGP_PDU_TYPE, DE_BSSGP_E_UTRAN_INTER_RAT_HO_INFO, NULL);
4965 /* Subscriber Profile ID for RAT/Frequency priority (note 5)
4966 * Subscriber Profile ID for RAT/Frequency priority/11.3.105 O TLV 3
4968 ELEM_OPT_TELV(0x81, BSSGP_PDU_TYPE, DE_BSSGP_SUB_PROF_ID_F_RAT_FRQ_PRIO, NULL);
4970 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
4974 * 10.4.18 CREATE-BSS-PFC-ACK
4976 static void
4977 bssgp_create_bss_pfc_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
4979 guint32 curr_offset;
4980 guint32 consumed;
4981 guint curr_len;
4983 curr_offset = offset;
4984 curr_len = len;
4986 /* This PDU allows the BSS to acknowledge a request from the SGSN for the creation
4987 * or modification of a BSS Packet Flow Context.
4989 /* Direction: BSS to SGSN */
4990 pinfo->link_dir = P2P_DIR_UL;
4992 /* TLLI TLLI/11.3.35 M TLV 6 */
4993 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
4994 /* PFI PFI/11.3.42 M TLV 3 */
4995 ELEM_MAND_TELV(BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
4996 /* ABQP ABQP/11.3.43 M TLV 13-? */
4997 ELEM_MAND_TELV(0x3a , GSM_A_PDU_TYPE_GM, DE_QOS , NULL);
4998 /* Cause Cause/11.3.8 O TLV 3 */
4999 ELEM_OPT_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
5001 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5004 * 10.4.19 CREATE-BSS-PFC-NACK
5006 static void
5007 bssgp_create_bss_pfc_nack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5009 guint32 curr_offset;
5010 guint32 consumed;
5011 guint curr_len;
5013 curr_offset = offset;
5014 curr_len = len;
5016 /* This PDU allows the BSS to Nack a request from the SGSN for the
5017 * creation of a BSS Packet Flow Context
5019 /* Direction: BSS to SGSN */
5020 pinfo->link_dir = P2P_DIR_UL;
5022 /* TLLI TLLI/11.3.35 M TLV 6 */
5023 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5024 /* PFI PFI/11.3.42 M TLV 3 */
5025 ELEM_MAND_TELV(BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
5026 /* Cause Cause/11.3.8 M TLV 3 */
5027 ELEM_MAND_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
5029 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5032 * 10.4.20 MODIFY-BSS-PFC
5034 static void
5035 bssgp_modify_bss_pfc(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5037 guint32 curr_offset;
5038 guint32 consumed;
5039 guint curr_len;
5041 curr_offset = offset;
5042 curr_len = len;
5044 /* This PDU allows the BSS to request a modification of a BSS Packet Flow Context. */
5045 /* Direction: BSS to SGSN */
5046 pinfo->link_dir = P2P_DIR_UL;
5048 /* TLLI TLLI/11.3.35 M TLV 6 */
5049 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5050 /* PFI PFI/11.3.42 M TLV 3 */
5051 ELEM_MAND_TELV(BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
5052 /* ABQP ABQP/11.3.43 M TLV 13-? */
5053 ELEM_MAND_TELV(0x3a , GSM_A_PDU_TYPE_GM, DE_QOS , NULL);
5055 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5059 * 10.4.21 MODIFY-BSS-PFC-ACK
5061 static void
5062 bssgp_modify_bss_pfc_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5064 guint32 curr_offset;
5065 guint32 consumed;
5066 guint curr_len;
5068 curr_offset = offset;
5069 curr_len = len;
5071 /* This PDU allows the SGSN to acknowledge a modification to a BSS Packet Flow Context. */
5072 /* Direction: SGSN to BSS */
5073 pinfo->link_dir = P2P_DIR_DL;
5075 /* TLLI TLLI/11.3.35 M TLV 6 */
5076 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5077 /* PFI PFI/11.3.42 M TLV 3 */
5078 ELEM_MAND_TELV(BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
5079 /* PFT GPRS Timer/11.3.44 M TLV 3 */
5080 ELEM_MAND_TELV(BSSGP_IEI_GPRS_TIMER, BSSGP_PDU_TYPE, DE_BSSGP_GPRS_TIMER , " - PFT");
5081 /* ABQP ABQP/11.3.43 M TLV 13-? */
5082 ELEM_MAND_TELV(0x3a , GSM_A_PDU_TYPE_GM, DE_QOS , NULL);
5085 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5088 * 10.4.22 DELETE-BSS-PFC
5090 static void
5091 bssgp_delete_bss_pfc(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5093 guint32 curr_offset;
5094 guint32 consumed;
5095 guint curr_len;
5097 curr_offset = offset;
5098 curr_len = len;
5100 /* This PDU allows the SGSN to request that a BSS delete a BSS Packet Flow Context. */
5101 /* Direction: SGSN to BSS */
5102 pinfo->link_dir = P2P_DIR_DL;
5104 /* TLLI TLLI/11.3.35 M TLV 6 */
5105 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5106 /* PFI PFI/11.3.42 M TLV 3 */
5107 ELEM_MAND_TELV(BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
5109 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5112 * 10.4.23 DELETE-BSS-PFC-ACK
5114 static void
5115 bssgp_delete_bss_pfc_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5117 guint32 curr_offset;
5118 guint32 consumed;
5119 guint curr_len;
5121 curr_offset = offset;
5122 curr_len = len;
5124 /* This PDU allows the BSS to acknowledge a request for the deletion of a BSS Packet Flow Context. */
5125 /* Direction: BSS to SGSN */
5126 pinfo->link_dir = P2P_DIR_UL;
5128 /* TLLI TLLI/11.3.35 M TLV 6 */
5129 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5130 /* PFI PFI/11.3.42 M TLV 3 */
5131 ELEM_MAND_TELV(BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
5133 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5136 * 10.4.24 FLOW-CONTROL-PFC
5138 static void
5139 bssgp_flow_cntrl_pfc(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5141 guint32 curr_offset;
5142 guint32 consumed;
5143 guint curr_len;
5145 curr_offset = offset;
5146 curr_len = len;
5148 /* This PDU provides the SGSN with flow control information regarding one or more PFC(s) of a given Mobile Station. */
5149 /* Direction: BSS to SGSN */
5150 pinfo->link_dir = P2P_DIR_UL;
5152 /* TLLI TLLI/11.3.35 M TLV 6 */
5153 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5154 /* Tag Tag/11.3.34 M TLV 3 */
5155 ELEM_MAND_TELV(BSSGP_IEI_TAG, BSSGP_PDU_TYPE, DE_BSSGP_TAG , NULL);
5156 /* MS Bucket Size MS Bucket Size/11.3.21 O TLV 4 */
5157 ELEM_OPT_TELV(BSSGP_IEI_MS_BUCKET_SIZE, BSSGP_PDU_TYPE, DE_BSSGP_MS_BUCKET_SIZE , NULL);
5158 /* Bucket Leak rate Bucket Leak rate/11.3.4 O TLV 4 */
5159 ELEM_OPT_TELV(0x3b, BSSGP_PDU_TYPE, DE_BSSGP_FEATURE_BITMAP , NULL);
5160 /* Bucket_Full Ratio Bucket_Full Ratio/11.3.46 O TLV 3 */
5161 ELEM_OPT_TELV(BSSGP_IEI_BUCKET_FULL_RATIO, BSSGP_PDU_TYPE, DE_BSSGP_BUCKET_FULL_RATIO , NULL);
5162 /* PFC flow control parameters PFC flow control parameters/11.3.68 M TLV */
5163 ELEM_MAND_TELV(0x52, BSSGP_PDU_TYPE, DE_BSSGP_PFC_FLOW_CTRL , NULL);
5164 /* Flow Control Granularity (note) Flow Control Granularity/11.3.102 O TLV 3 */
5165 ELEM_OPT_TELV(0x7e, BSSGP_PDU_TYPE, DE_BSSGP_FLOW_CONTROL_GRAN , NULL);
5167 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5170 * 10.4.25 FLOW-CONTROL-PFC-ACK
5172 static void
5173 bssgp_flow_cntrl_pfc_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5175 guint32 curr_offset;
5176 guint32 consumed;
5177 guint curr_len;
5179 curr_offset = offset;
5180 curr_len = len;
5182 /* This PDU informs the flow control mechanism at the BSS that the SGSN has received the FLOW-CONTROL-PFC
5183 * PDU indicated by the TLLI and the Tag.
5185 /* Direction: SGSN to BSS */
5186 pinfo->link_dir = P2P_DIR_DL;
5188 /* TLLI TLLI/11.3.35 M TLV 6 */
5189 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5190 /* Tag Tag/11.3.34 M TLV 3 */
5191 ELEM_MAND_TELV(BSSGP_IEI_TAG, BSSGP_PDU_TYPE, DE_BSSGP_TAG , NULL);
5193 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5196 * 10.4.26 DELETE-BSS-PFC-REQ
5198 static void
5199 bssgp_delete_bss_pfc_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5201 guint32 curr_offset;
5202 guint32 consumed;
5203 guint curr_len;
5205 curr_offset = offset;
5206 curr_len = len;
5208 /* This PDU allows the BSS to inform the SGSN that the BSS Packet Flow Context cannot be supported anymore */
5209 /* Direction: BSS to SGSN */
5210 pinfo->link_dir = P2P_DIR_UL;
5212 /* TLLI TLLI/11.3.35 M TLV 6 */
5213 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5214 /* PFI PFI/11.3.42 M TLV 3 */
5215 ELEM_MAND_TELV(BSSGP_IEI_PFI , GSM_A_PDU_TYPE_GM, DE_PACKET_FLOW_ID , NULL);
5216 /* Cause Cause/11.3.8 M TLV 3 */
5217 ELEM_MAND_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
5219 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5222 * 10.4.27 PS-HANDOVER-REQUIRED
5224 static void
5225 bssgp_ps_ho_required(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5227 guint32 curr_offset;
5228 guint32 consumed;
5229 guint curr_len;
5231 curr_offset = offset;
5232 curr_len = len;
5234 /* This PDU initiates the allocation of resources in the target system for an MS. */
5235 /* Direction: BSS to SGSN */
5236 pinfo->link_dir = P2P_DIR_UL;
5238 /* TLLI TLLI/11.3.35 M TLV 6 */
5239 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5240 /* Cause Cause/11.3.8 M TLV 3 */
5241 ELEM_MAND_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
5242 /* Source Cell Identifier Cell Identifier/11.3.9 M TLV 10 */
5243 ELEM_MAND_TELV(BSSGP_IEI_CELL_IDENTIFIER, BSSGP_PDU_TYPE, DE_BSSGP_CELL_ID , " - Source");
5244 /* Target Cell Identifier (note 2) Cell Identifier/11.3.9 C TLV 10 */
5245 ELEM_OPT_TELV(BSSGP_IEI_CELL_IDENTIFIER, BSSGP_PDU_TYPE, DE_BSSGP_CELL_ID , " - Target");
5246 /* Source BSS to Target BSS Transparent Container (note 1)
5247 * Source BSS to Target BSS Transparent Container/11.3.79 C TLV 10-?
5249 ELEM_OPT_TELV(0x64,BSSGP_PDU_TYPE, DE_BSSGP_SOURCE_BSS_TO_TARGET_BSS_TRANSP_CONT, NULL);
5250 /* Target RNC Identifier (note 2) (note 3) RNC Identifier/11.3.87 C TLV 10 */
5251 ELEM_OPT_TELV(0x6c,BSSGP_PDU_TYPE, BE_BSSGP_RNC_ID, " - Target");
5252 /* Source to Target Transparent Container (note 1)
5253 * Source to Target Transparent Container/11.3.85 C TLV 3-?
5255 ELEM_OPT_TELV(0x6a,BSSGP_PDU_TYPE, DE_BSSGP_SRC_TO_TRG_TRANSP_CONT, NULL);
5256 /* Active PFCs List Active PFCs List/11.3.95c M TLV 3-? */
5257 ELEM_OPT_TELV(0x77,BSSGP_PDU_TYPE, DE_BSSGP_ACTIVE_PFCS_LIST, NULL);
5258 /* Target eNB identifier (note 2) (note 3) eNB Identifier/11.3.103 C TLV 3-n */
5259 ELEM_OPT_TELV(0x7f,BSSGP_PDU_TYPE, DE_BSSGP_ENB_ID, " - Target");
5260 /* Reliable Inter RAT Handover Info (note 4)
5261 * Reliable Inter RAT Handover Info/11.3.107 C TLV 3
5263 ELEM_OPT_TELV(0x83,BSSGP_PDU_TYPE, DE_BSSGP_RELIABLE_INTER_RAT_HO_INF, NULL);
5264 /* CSG Identifier (note 5) CSG Identifier/11.3.109 C TLV 7 */
5265 ELEM_OPT_TELV(0x85,BSSGP_PDU_TYPE, DE_BSSGP_CSG_ID, NULL);
5266 /* TAC (note 6) Tracking Area Code/11.3.110 C TLV 5 */
5267 ELEM_OPT_TELV(0x86, NAS_PDU_TYPE_EMM, DE_EMM_TRAC_AREA_ID, NULL);
5269 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5272 * 10.4.28 PS-HANDOVER-REQUIRED-ACK
5274 static void
5275 bssgp_ps_ho_required_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5277 guint32 curr_offset;
5278 guint32 consumed;
5279 guint curr_len;
5281 curr_offset = offset;
5282 curr_len = len;
5284 /* This PDU indicates that resources have been allocated in the target system and
5285 * that the BSS may initiate the channel change attempt for the corresponding MS.
5287 /* Direction: SGSN to BSS */
5288 pinfo->link_dir = P2P_DIR_DL;
5290 /* TLLI TLLI/11.3.35 M TLV 6 */
5291 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5292 /* List of set-up PFCs List of set-up PFCs/11.3.83 M TLV 3-?S */
5293 ELEM_MAND_TELV(0x68,BSSGP_PDU_TYPE, DE_BSSGP_LIST_OF_SETUP_PFCS, NULL);
5294 /* Target BSS to Source BSS Transparent Container (note)
5295 * Target BSS to Source BSS Transparent Container/11.3.80 C TLV 3-?
5297 ELEM_MAND_TELV(0x65,BSSGP_PDU_TYPE, DE_BSSGP_TARGET_BSS_TO_SOURCE_BSS_TRANSP_CONT, NULL);
5298 /* Target to Source Transparent Container (note)
5299 * Target to Source Transparent Container/11.3.86 C TLV 3-?
5301 ELEM_MAND_TELV(0x6b,BSSGP_PDU_TYPE, DE_BSSGP_TRG_TO_SRC_TRANSP_CONT, NULL);
5303 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5307 * 10.4.29 PS-HANDOVER-REQUIRED-NACK
5309 static void
5310 bssgp_ps_ho_required_nack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5312 guint32 curr_offset;
5313 guint32 consumed;
5314 guint curr_len;
5316 curr_offset = offset;
5317 curr_len = len;
5319 /* This PDU informs the source BSS about failed resource allocation in the target system. */
5320 /* Direction: SGSN to BSS */
5321 pinfo->link_dir = P2P_DIR_DL;
5323 /* TLLI TLLI/11.3.35 M TLV 6 */
5324 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5325 /* Cause Cause/11.3.8 M TLV 3 */
5326 ELEM_MAND_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
5328 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5331 * 10.4.30 PS-HANDOVER-REQUEST
5333 static void
5334 bssgp_ps_ho_request(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5336 guint32 curr_offset;
5337 guint32 consumed;
5338 guint curr_len;
5340 curr_offset = offset;
5341 curr_len = len;
5343 /* This PDU initiates the allocation of resources for one or more PFCs in the target BSS for an MS. */
5344 /* Direction: SGSN to BSS */
5345 pinfo->link_dir = P2P_DIR_DL;
5347 /* TLLI TLLI/11.3.35 M TLV 6 */
5348 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5349 /* IMSI IMSI/11.3.14 M TLV 5-10 */
5350 ELEM_MAND_TELV(BSSGP_IEI_IMSI, BSSGP_PDU_TYPE, DE_BSSGP_IMSI , NULL);
5351 /* Cause Cause/11.3.8 M TLV 3 */
5352 ELEM_MAND_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
5353 /* Source Cell Identifier (note 1) Cell Identifier/11.3.9 C TLV 10 */
5354 ELEM_OPT_TELV(BSSGP_IEI_CELL_IDENTIFIER, BSSGP_PDU_TYPE, DE_BSSGP_CELL_ID , " - Source");
5355 /* Source RNC Identifier (note 1) RNC Identifier/11.3.87 C TLV 10 */
5356 ELEM_OPT_TELV(0x6c,BSSGP_PDU_TYPE, BE_BSSGP_RNC_ID, " - Source");
5357 /* Target Cell Identifier Cell Identifier/11.3.9 M TLV 10 */
5358 ELEM_OPT_TELV(BSSGP_IEI_CELL_IDENTIFIER, BSSGP_PDU_TYPE, DE_BSSGP_CELL_ID , " - Target");
5359 /* Source BSS to Target BSS Transparent Container Source BSS to Target BSS Transparent Container/11.3.79 M TLV 7-? */
5360 ELEM_OPT_TELV(0x64,BSSGP_PDU_TYPE, DE_BSSGP_SOURCE_BSS_TO_TARGET_BSS_TRANSP_CONT, NULL);
5361 /* PFCs to be set-up list PFCs to be set-up list/11.3.82 M TLV 22-? */
5362 ELEM_OPT_TELV(0x67,BSSGP_PDU_TYPE, DE_BSSGP_PFCS_TO_BE_SET_UP_LIST, NULL);
5363 /* NAS container for PS Handover NAS container for PS Handover/11.3.81 O TLV 3-? */
5364 ELEM_OPT_TELV(0x66,GSM_A_PDU_TYPE_COMMON, DE_NAS_CONT_FOR_PS_HO, NULL);
5365 /* Service UTRAN CCO Service UTRAN CCO/11.3.47 O TLV 3 */
5366 ELEM_OPT_TELV(BSSGP_IEI_SERVICE_UTRAN_CCO, BSSGP_PDU_TYPE, DE_BSSGP_SERV_UTRAN_CCO, NULL);
5367 /* Subscriber Profile ID for RAT/Frequency priority (note 2) Subscriber Profile ID for RAT/Frequency priority/11.3.105 O TLV 3 */
5368 ELEM_OPT_TELV(0x81, BSSGP_PDU_TYPE, DE_BSSGP_SUB_PROF_ID_F_RAT_FRQ_PRIO, NULL);
5369 /* Reliable Inter RAT Handover Info (note 3) Reliable Inter RAT Handover Info/11.3.107 C TLV 3 */
5370 ELEM_OPT_TELV(0x83,BSSGP_PDU_TYPE, DE_BSSGP_RELIABLE_INTER_RAT_HO_INF, NULL);
5372 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5376 * 10.4.31 PS-HANDOVER-REQUEST-ACK
5378 static void
5379 bssgp_ps_ho_request_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5381 guint32 curr_offset;
5382 guint32 consumed;
5383 guint curr_len;
5385 curr_offset = offset;
5386 curr_len = len;
5388 /* This PDU acknowledges the successful allocation of resources in the target BSS. */
5389 /* Direction: BSS to SGSN */
5390 pinfo->link_dir = P2P_DIR_UL;
5392 /* TLLI TLLI/11.3.35 M TLV 6 */
5393 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5394 /* List of set-up PFCs List of set-up PFCs/11.3.83 M TLV 3-? */
5395 ELEM_MAND_TELV(0x68,BSSGP_PDU_TYPE, DE_BSSGP_LIST_OF_SETUP_PFCS, NULL);
5396 /* Target BSS to Source BSS Transparent Container Target BSS to Source BSS Transparent Container/11.3.80 M TLV 3-? */
5397 ELEM_MAND_TELV(0x65,BSSGP_PDU_TYPE, DE_BSSGP_TARGET_BSS_TO_SOURCE_BSS_TRANSP_CONT, NULL);
5399 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5402 * 10.4.32 PS-HANDOVER-REQUEST-NACK
5404 static void
5405 bssgp_ps_ho_request_nack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5407 guint32 curr_offset;
5408 guint32 consumed;
5409 guint curr_len;
5411 curr_offset = offset;
5412 curr_len = len;
5414 /* This PDU informs the SGSN about failed resource allocation in the target BSS. */
5415 /* BSS to SGSN */
5416 pinfo->link_dir = P2P_DIR_UL;
5418 /* TLLI TLLI/11.3.35 M TLV 6 */
5419 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5420 /* Cause Cause/11.3.8 M TLV 3 */
5421 ELEM_MAND_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
5423 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5427 * 10.4.33 PS-HANDOVER-COMPLETE
5429 static void
5430 bssgp_ps_ho_complete(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5432 guint32 curr_offset;
5433 guint32 consumed;
5434 guint curr_len;
5436 curr_offset = offset;
5437 curr_len = len;
5439 /* This PDU informs the SGSN about successful channel change for an MS. */
5440 /* BSS to SGSN */
5441 pinfo->link_dir = P2P_DIR_UL;
5443 /* TLLI TLLI/11.3.35 M TLV 6 */
5444 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5445 /* IMSI IMSI/11.3.14 M TLV 5-10 */
5446 ELEM_MAND_TELV(BSSGP_IEI_IMSI, BSSGP_PDU_TYPE, DE_BSSGP_IMSI , NULL);
5447 /* Target Cell Identifier (note 1) Cell Identifier/11.3.9 O TLV 10 */
5448 ELEM_OPT_TELV(BSSGP_IEI_CELL_IDENTIFIER, BSSGP_PDU_TYPE, DE_BSSGP_CELL_ID , " - Target");
5449 /* Request for Inter RAT Handover Info (note 2) Request for Inter RAT Handover Info/11.3.106 C TLV 3 */
5450 ELEM_OPT_TELV(0x82, BSSGP_PDU_TYPE, DE_BSSGP_REQ_FOR_INTER_RAT_HO_INFO , NULL);
5452 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5455 * 10.4.34 PS-HANDOVER-CANCEL
5457 static void
5458 bssgp_ps_ho_cancel(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5460 guint32 curr_offset;
5461 guint32 consumed;
5462 guint curr_len;
5464 curr_offset = offset;
5465 curr_len = len;
5467 /* This PDU cancels the handover for an MS. */
5468 /* BSS to SGSN */
5469 pinfo->link_dir = P2P_DIR_UL;
5471 /* TLLI TLLI/11.3.35 M TLV 6 */
5472 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5473 /* Cause Cause/11.3.8 M TLV 3 */
5474 ELEM_IN_ELEM_MAND_TELV(BSSGP_IEI_CAUSE,BSSGP_PDU_TYPE, DE_BSSGP_CAUSE, NULL);
5475 /* Source Cell Identifier Cell Identifier/11.3.9 M TLV 10 */
5476 ELEM_OPT_TELV(BSSGP_IEI_CELL_IDENTIFIER, BSSGP_PDU_TYPE, DE_BSSGP_CELL_ID , " - Source");
5477 /* Target Cell Identifier (note 1) Cell Identifier/11.3.9 O TLV 10 */
5478 ELEM_OPT_TELV(BSSGP_IEI_CELL_IDENTIFIER, BSSGP_PDU_TYPE, DE_BSSGP_CELL_ID , " - Target");
5479 /* Target RNC Identifier (note 1) (note 2) RNC Identifier/11.3.87 C TLV 10 */
5480 ELEM_OPT_TELV(0x6c,BSSGP_PDU_TYPE, BE_BSSGP_RNC_ID, " - Target");
5481 /* Target eNB Identifier (note 1) (note 2) eNB Identifier/11.3.103 C TLV 3-n */
5482 ELEM_OPT_TELV(0x7f,BSSGP_PDU_TYPE, DE_BSSGP_ENB_ID, " - Target");
5484 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5488 * 10.4.35 PS-HANDOVER-COMPLETE-ACK
5490 static void
5491 bssgp_ps_ho_complete_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5493 guint32 curr_offset;
5494 guint32 consumed;
5495 guint curr_len;
5497 curr_offset = offset;
5498 curr_len = len;
5500 /* This PDU provides to the BSS the Inter RAT Handover Info IE or
5501 * E-UTRAN Inter RAT Handover Info IE or both. It is sent only if
5502 * requested by the BSS and it shall contain at least one of the
5503 * inter-RAT capabilities.
5506 /* SGSN to BSS */
5507 pinfo->link_dir = P2P_DIR_DL;
5509 /* TLLI TLLI/11.3.35 M TLV 6 */
5510 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5511 /* Inter RAT Handover Info Inter RAT Handover Info/11.3.94 C (note 1) TLV 3-? */
5512 ELEM_OPT_TELV(0x73, BSSGP_PDU_TYPE, DE_BSSGP_INTER_RAT_HO_INFO, NULL);
5513 /* E-UTRAN Inter RAT Handover Info E-UTRAN Inter RAT Handover Info/11.3.104 C (note 1) TLV 3-? */
5514 ELEM_OPT_TELV(0x80, BSSGP_PDU_TYPE, DE_BSSGP_E_UTRAN_INTER_RAT_HO_INFO, NULL);
5516 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5519 * 10.5 PDU functional definitions and contents at LCS SAP
5520 * 10.5.1 PERFORM-LOCATION-REQUEST
5522 static void
5523 bssgp_perform_loc_request(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5525 guint32 curr_offset;
5526 guint32 consumed;
5527 guint curr_len;
5529 curr_offset = offset;
5530 curr_len = len;
5532 /* This PDU informs the SGSN about failed resource allocation in the target BSS. */
5533 /* BSS to SGSN */
5534 pinfo->link_dir = P2P_DIR_UL;
5536 /* TLLI TLLI/11.3.35 M TLV 6 */
5537 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5538 /* IMSI IMSI/11.3.14 M TLV 5-10 */
5539 ELEM_MAND_TELV(BSSGP_IEI_IMSI, BSSGP_PDU_TYPE, DE_BSSGP_IMSI , NULL);
5540 /* DRX Parameters (note 1) DRX Parameters/11.3.11 O TLV 4 */
5541 ELEM_OPT_TELV(0x86, NAS_PDU_TYPE_EMM, DE_EMM_TRAC_AREA_ID, NULL);
5542 /* BVCI (PCU-PTP) BVCI/11.3.6 M TLV 4 */
5543 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , " - (PCU-PTP)");
5544 /* NSEI (PCU-PTP) NSEI/11.3.48 M TLV 4-? */
5545 ELEM_OPT_TELV(0x3e, GSM_A_PDU_TYPE_RR, DE_BSSGP_NSEI , " - (PCU-PTP)");
5546 /* Location Type Location Type/11.3.53 M TLV 3-? */
5547 ELEM_OPT_TELV(0x7c, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_GANSS_LOC_TYPE, NULL);
5548 /* Cell Identifier Cell Identifier/11.3.9 M TLV 10 */
5549 ELEM_OPT_TELV(BSSGP_IEI_CELL_IDENTIFIER, BSSGP_PDU_TYPE, DE_BSSGP_CELL_ID , NULL);
5550 /* LCS Capability (note 2) LCS Capability/11.3.59 O TLV 3-? */
5551 ELEM_OPT_TELV( BSSGP_IEI_LCS_CAPABILITY , GSM_A_PDU_TYPE_GM, DE_PS_LCS_CAP , NULL);
5552 /* LCS Priority LCS Priority/11.3.57 O TLV 3-? */
5553 ELEM_OPT_TELV(BSSGP_IEI_LCS_PRIORITY, GSM_A_PDU_TYPE_BSSMAP, BE_LCS_PRIO, NULL);
5554 /* LCS QoS LCS QoS/11.3.50 O TLV 3-? */
5555 ELEM_OPT_TELV(BSSGP_IEI_LCS_QOS, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_LCSQOS, NULL);
5556 /* LCS Client Type (note 3) LCS Client Type/11.3.51 C TLV 3-? */
5557 ELEM_OPT_TELV(BSSGP_IEI_LCS_CLIENT_TYPE, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_LCS_CLIENT_TYPE, NULL);
5558 /* Requested GPS Assistance Data (note 4) Requested GPS Assistance Data/11.3.52 O TLV 3-? */
5559 ELEM_OPT_TELV(BSSGP_IEI_REQUESTED_GPS_ASSISTANCE_DATA, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_REQ_GPS_ASSIST_D, NULL);
5560 /* IMEI (note 5) IMEI/11.3.91 O TLV 10 */
5561 ELEM_OPT_TELV(0x70,GSM_A_PDU_TYPE_COMMON, DE_MID, NULL);
5562 /* GANSS Location Type GANSS Location Type / 11.3.100 C TLV 3 */
5563 ELEM_OPT_TELV(0x7c, GSM_A_PDU_TYPE_BSSMAP, BE_GANSS_LOC_TYP, NULL);
5564 /* Requested GANSS Assistance Data (note 6) Requested GANSS Assistance Data/11.3.99 O TLV 3-? */
5565 ELEM_OPT_TLV(0x7b, GSM_A_PDU_TYPE_BSSMAP, BE_GANSS_ASS_DTA, NULL);
5567 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5571 * 10.5.2 PERFORM-LOCATION-RESPONSE
5573 static void
5574 bssgp_perform_loc_response(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5576 guint32 curr_offset;
5577 guint32 consumed;
5578 guint curr_len;
5580 curr_offset = offset;
5581 curr_len = len;
5583 /*This PDU allows the BSS to respond to the SGSN after the completion of the location procedure. */
5584 /* Direction: BSS to SGSN */
5585 pinfo->link_dir = P2P_DIR_UL;
5587 /* TLLI TLLI/11.3.35 M TLV 6 */
5588 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5589 /* BVCI (PCU-PTP) BVCI/11.3.6 M TLV 4 */
5590 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , " - (PCU-PTP)");
5591 /* Location Estimate (note 1) Location Estimate/11.3.54 C TLV 3-? */
5592 ELEM_OPT_TELV(BSSGP_IEI_LOCATION_ESTIMATE, GSM_A_PDU_TYPE_BSSMAP, BE_LOC_EST, NULL);
5593 /* Positioning Data Positioning Data/11.3.55 O TLV 3-? */
5594 ELEM_OPT_TELV(0x7d, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_POS_DATA, NULL);
5595 /* Deciphering Keys (note 2) Deciphering Keys/11.3.56 C TLV 3-? */
5596 ELEM_OPT_TELV(BSSGP_IEI_DECIPHERING_KEYS, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_DECIPH_KEYS, NULL);
5597 /* LCS Cause (note 3) LCS Cause/11.3.58 O TLV 3-? */
5598 ELEM_OPT_TELV(BSSGP_IEI_LCS_CAUSE, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_LCS_CAUSE, NULL);
5599 /* Velocity Data Velocity Data/11.3.96 O TLV 3-? */
5600 ELEM_MAND_TELV(0x78, BSSGP_PDU_TYPE, DE_BSSGP_VELOCITY_DATA , NULL);
5601 /* GANSS Positioning Data GANSS Positioning Data /11.3.101 O TLV 3-? */
5602 ELEM_OPT_TELV(0x7d, GSM_A_PDU_TYPE_BSSMAP, BE_GANSS_POS_DTA, NULL);
5604 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5608 * 10.5.3 PERFORM-LOCATION-ABORT
5610 static void
5611 bssgp_perform_loc_response_abort(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5613 guint32 curr_offset;
5614 guint32 consumed;
5615 guint curr_len;
5617 curr_offset = offset;
5618 curr_len = len;
5620 /*This PDU allows the SGSN to request the BSS to ABORT the LCS procedure */
5621 /* Direction: SGSN to BSS */
5622 pinfo->link_dir = P2P_DIR_DL;
5624 /* TLLI TLLI/11.3.35 M TLV 6 */
5625 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5626 /* BVCI (PCU-PTP) BVCI/11.3.6 M TLV 4 */
5627 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , " - (PCU-PTP)");
5628 /* LCS Cause LCS Cause/11.3.58 M TLV 3-? */
5629 ELEM_MAND_TELV(BSSGP_IEI_LCS_CAUSE, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_LCS_CAUSE, NULL);
5631 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5635 * 10.5.4 POSITION-COMMAND
5637 static void
5638 bssgp_pos_cmd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5640 guint32 curr_offset;
5641 guint32 consumed;
5642 guint curr_len;
5644 curr_offset = offset;
5645 curr_len = len;
5647 /* This PDU allows the BSS to request the SGSN to perform the position command procedure. */
5648 /* Direction: BSS to SGSN */
5649 pinfo->link_dir = P2P_DIR_UL;
5651 /* TLLI TLLI/11.3.35 M TLV 6 */
5652 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5653 /* BVCI (PCU-PTP) BVCI/11.3.6 M TLV 4 */
5654 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , " - (PCU-PTP)");
5655 /* RRLP Flags RRLP Flags/11.3.60 M TLV 3 */
5656 ELEM_MAND_TELV(BSSGP_IEI_RRLP_FLAGS, BSSGP_PDU_TYPE, DE_BSSGP_RRLP_FLAGS , NULL);
5657 /* RRLP APDU RRLP APDU/11.3.49 M TLV 3-? */
5658 ELEM_MAND_TELV(BSSGP_IEI_RRLP_APDU, BSSGP_PDU_TYPE, DE_BSSGP_RRLP_APDU , NULL);
5660 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5664 * 10.5.5 POSITION-RESPONSE
5666 static void
5667 bssgp_pos_resp(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5669 guint32 curr_offset;
5670 guint32 consumed;
5671 guint curr_len;
5673 curr_offset = offset;
5674 curr_len = len;
5676 /* This PDU allows the SGSN to respond to the position command request procedure. */
5677 /* Direction: SGSN to BSS */
5678 pinfo->link_dir = P2P_DIR_DL;
5680 /* TLLI TLLI/11.3.35 M TLV 6 */
5681 ELEM_MAND_TELV(BSSGP_IEI_TLLI, GSM_A_PDU_TYPE_RR, DE_RR_TLLI , NULL);
5682 /* BVCI (PCU-PTP) BVCI/11.3.6 M TLV 4 */
5683 ELEM_MAND_TELV(BSSGP_IEI_BVCI, BSSGP_PDU_TYPE, DE_BSSGP_BVCI , " - (PCU-PTP)");
5684 /* RRLP Flags a) RRLP Flags/11.3.60 C TLV 3 */
5685 ELEM_OPT_TELV(BSSGP_IEI_RRLP_FLAGS, BSSGP_PDU_TYPE, DE_BSSGP_RRLP_FLAGS , NULL);
5686 /* RRLP APDU a) RRLP APDU/11.3.49 C TLV 3-? */
5687 ELEM_OPT_TELV(BSSGP_IEI_RRLP_APDU, BSSGP_PDU_TYPE, DE_BSSGP_RRLP_APDU , NULL);
5688 /* LCS Cause b) LCS Cause/11.3.58 O TLV 3-? */
5689 ELEM_OPT_TELV(BSSGP_IEI_LCS_CAUSE, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_LCS_CAUSE, NULL);
5691 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5695 * 10.6 PDU functional definitions and contents at RIM SAP
5696 * 10.6.1 RAN-INFORMATION-REQUEST
5698 static void
5699 bssgp_ran_inf_request(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5701 guint32 curr_offset;
5702 guint32 consumed;
5703 guint curr_len;
5705 curr_offset = offset;
5706 curr_len = len;
5708 /* The RAN-INFORMATION-REQUEST PDU allows a controlling BSS to request information from another BSS. */
5709 /* Direction: BSS to SGSN - SGSN to BSS */
5711 /* Destination Cell Identifier RIM Routing Information/11.3.70 M TLV 3-? */
5712 ELEM_MAND_TELV(BSSGP_IEI_RIM_ROUTING_INFORMATION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_ROUTING_INF , " - Destination Cell Identifier");
5713 /* Source Cell Identifier RIM Routing Information/11.3.70 M TLV 3-? */
5714 ELEM_MAND_TELV(BSSGP_IEI_RIM_ROUTING_INFORMATION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_ROUTING_INF , " - Source Cell Identifier");
5715 /* RIM Container RAN-INFORMATION-REQUEST RIM Container/11.3.62a.1 M TLV 3-? */
5716 ELEM_OPT_TELV(BSSGP_IEI_RAN_INF_REQUEST_RIM_CONTAINER, BSSGP_PDU_TYPE, DE_BSSGP_RAN_INF_REQUEST_RIM_CONT, NULL);
5718 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5722 * 10.6.2 RAN-INFORMATION
5724 static void
5725 bssgp_ran_inf(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5727 guint32 curr_offset;
5728 guint32 consumed;
5729 guint curr_len;
5731 curr_offset = offset;
5732 curr_len = len;
5734 /* The RAN-INFORMATION PDU allows a serving BSS to send information to a controlling BSS. */
5735 /* Direction: BSS to SGSN SGSN to BSS */
5737 /* Destination Cell Identifier RIM Routing Information/11.3.70 M TLV 3-? */
5738 ELEM_MAND_TELV(BSSGP_IEI_RIM_ROUTING_INFORMATION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_ROUTING_INF , " - Destination Cell Identifier");
5739 /* Source Cell Identifier RIM Routing Information/11.3.70 M TLV 3-? */
5740 ELEM_MAND_TELV(BSSGP_IEI_RIM_ROUTING_INFORMATION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_ROUTING_INF , " - Source Cell Identifier");
5741 /* RIM Container RAN-INFORMATION RIM Container/11.3.62a.2 M TLV 3-? */
5742 ELEM_MAND_TELV(BSSGP_IEI_RAN_INF_RIM_CONTAINER, BSSGP_PDU_TYPE, DE_BSSGP_RAN_INF_RIM_CONT , " - Source Cell Identifier");
5745 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5749 * 10.6.3 RAN-INFORMATION-ACK
5751 static void
5752 bssgp_ran_inf_request_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5754 guint32 curr_offset;
5755 guint32 consumed;
5756 guint curr_len;
5758 curr_offset = offset;
5759 curr_len = len;
5761 /* The RAN-INFORMATION-ACK PDU allows a controlling BSS to acknowledge the reception of a RANINFORMATION
5762 * PDU and a serving BSS to acknowledge the reception of a RAN-INFORMATION-APPLICATIONERROR PDU.
5765 /* Direction: BSS to SGSN SGSN to BSS */
5767 /* Destination Cell Identifier RIM Routing Information/11.3.70 M TLV 3-? */
5768 ELEM_MAND_TELV(BSSGP_IEI_RIM_ROUTING_INFORMATION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_ROUTING_INF , " - Destination Cell Identifier");
5769 /* Source Cell Identifier RIM Routing Information/11.3.70 M TLV 3-? */
5770 ELEM_MAND_TELV(BSSGP_IEI_RIM_ROUTING_INFORMATION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_ROUTING_INF , " - Source Cell Identifier");
5771 /* RIM Container RAN-INFORMATION-ACK RIM Container/11.3.62a.3 M TLV 3-? */
5772 ELEM_MAND_TELV(BSSGP_IEI_RAN_INF_ACK_RIM_CONTAINER, BSSGP_PDU_TYPE, DE_BSSGP_RAN_INFORMATION_ACK_RIM_CONT , NULL);
5774 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5778 * 10.6.4 RAN-INFORMATION-ERROR
5781 static void
5782 bssgp_ran_inf_err(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5784 guint32 curr_offset;
5785 guint32 consumed;
5786 guint curr_len;
5788 curr_offset = offset;
5789 curr_len = len;
5791 /* The RAN-INFORMATION-ERROR PDU allows a BSS to send an error PDU back to an originating BSS as a response
5792 * to a RAN-INFORMATION, a RAN-INFORMATION-REQUEST, a RAN-INFORMATION-ACK or a RANINFORMATION-APPLICATION-ERROR PDU.
5795 /* Direction: BSS to SGSN SGSN to BSS */
5797 /* Destination Cell Identifier RIM Routing Information/11.3.70 M TLV 3-? */
5798 ELEM_MAND_TELV(BSSGP_IEI_RIM_ROUTING_INFORMATION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_ROUTING_INF , " - Destination Cell Identifier");
5799 /* Source Cell Identifier RIM Routing Information/11.3.70 M TLV 3-? */
5800 ELEM_MAND_TELV(BSSGP_IEI_RIM_ROUTING_INFORMATION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_ROUTING_INF , " - Source Cell Identifier");
5801 /* RIM Container RAN-INFORMATION-ERROR RIM Container/11.3.62a.4 M TLV 3-? */
5802 ELEM_MAND_TELV(BSSGP_IEI_RAN_INF_ERROR_RIM_CONTAINER, BSSGP_PDU_TYPE, DE_BSSGP_RAN_INFORMATION_ERROR_RIM_CONT , NULL);
5804 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5807 * 10.6.5 RAN-INFORMATION-APPLICATION-ERROR
5809 static void
5810 bssgp_ran_inf_app_err(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5812 guint32 curr_offset;
5813 guint32 consumed;
5814 guint curr_len;
5816 curr_offset = offset;
5817 curr_len = len;
5819 /* The RAN-INFORMATION-APPLICATION-ERROR PDU allows a controlling BSS to inform the serving BSS about
5820 * erroneous application information in a previously received RAN-INFORMATION PDU.
5823 /* Direction: BSS to SGSN SGSN to BSS */
5825 /* Destination Cell Identifier RIM Routing Information/11.3.70 M TLV 3-? */
5826 ELEM_MAND_TELV(BSSGP_IEI_RIM_ROUTING_INFORMATION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_ROUTING_INF , " - Destination Cell Identifier");
5827 /* Source Cell Identifier RIM Routing Information/11.3.70 M TLV 3-? */
5828 ELEM_MAND_TELV(BSSGP_IEI_RIM_ROUTING_INFORMATION, BSSGP_PDU_TYPE, DE_BSSGP_RIM_ROUTING_INF , " - Source Cell Identifier");
5829 /* RIM Container RAN-INFORMATION-APPLICATION ERROR RIM Container/11.3.62a.5 M TLV 3-? */
5830 ELEM_MAND_TELV(BSSGP_IEI_RAN_INF_APP_ERROR_RIM_CONTAINER, BSSGP_PDU_TYPE, DE_BSSGP_RAN_INF_APP_ERROR_RIM_CONT , NULL);
5832 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5836 * 10.7 PDU functional definitions and contents at MBMS SAP
5837 * 10.7.1 MBMS-SESSION-START-REQUEST
5839 static void
5840 bssgp_mbms_session_start_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5842 guint32 curr_offset;
5843 guint32 consumed;
5844 guint curr_len;
5846 curr_offset = offset;
5847 curr_len = len;
5849 /* This PDU allows a SGSN to request BSS to start an MBMS session. */
5851 /* Direction: SGSN to BSS */
5852 pinfo->link_dir = P2P_DIR_DL;
5854 /* TMGI TMGI/11.3.77 M TLV 3-8 */
5855 ELEM_MAND_TELV(0x5c, GSM_A_PDU_TYPE_GM, DE_TMGI, NULL);
5856 /* MBMS Session Identity MBMS Session Identity/11.3.71 O TLV 3 */
5857 ELEM_OPT_TELV(0x5d, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_ID, NULL);
5858 /* ABQP ABQP/11.3.43 M TLV 13-? */
5859 ELEM_MAND_TELV(0x3a , GSM_A_PDU_TYPE_GM, DE_QOS , NULL);
5860 /* MBMS Service Area Identity List MBMS Service Area Identity List/11.3.73 M TLV 4-? */
5861 ELEM_MAND_TELV(0x5f, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SAI_LIST, NULL);
5862 /* MBMS Routing Area List MBMS Routing Area List/11.3.75 M TLV 3-? */
5863 ELEM_MAND_TELV(0x61, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_RA_LIST, NULL);
5864 /* MBMS Session Duration MBMS Session Duration/11.3.72 M TLV 3-? */
5865 ELEM_MAND_TELV(0x5e, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_DUR, NULL);
5866 /* MBMS Session Information MBMS Session Information/11.3.76 M TLV 3 */
5867 ELEM_MAND_TELV(0x62, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_INF, NULL);
5868 /* Time to MBMS Data Transfer Time to MBMS Data Transfer/11.3.92 M TLV 3 */
5869 ELEM_MAND_TELV(0x71, BSSGP_PDU_TYPE, DE_BSSGP_TIME_TO_MBMS_DATA_TRAN, NULL);
5870 /* Allocation/Retention Priority Priority/11.3.27 O TLV 3 */
5871 ELEM_OPT_TELV(0x17, GSM_A_PDU_TYPE_BSSMAP, BE_PRIO, NULL);
5872 /* MBMS Session Repetition Number MBMS Session Repetition Number/11.3.93 O TLV 3 */
5873 ELEM_MAND_TELV(0x72, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_REP_NO, NULL);
5876 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5879 * 10.7.2 MBMS-SESSION-START-RESPONSE
5881 static void
5882 bssgp_mbms_session_start_resp(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5884 guint32 curr_offset;
5885 guint32 consumed;
5886 guint curr_len;
5888 curr_offset = offset;
5889 curr_len = len;
5891 /* This PDU allows a BSS to acknowledge to SGSN that it will start an MBMS session or to indicate to SGSN why the
5892 * MBMS Service Context cannot be created or is released by the BSS.
5895 /* Direction: BSS to SGSN */
5896 pinfo->link_dir = P2P_DIR_UL;
5898 /* TMGI TMGI/ 11.3.77 M TLV 3-8 */
5899 ELEM_MAND_TELV(0x5c, GSM_A_PDU_TYPE_GM, DE_TMGI, NULL);
5900 /* MBMS Session Identity MBMS Session Identity/ 11.3.71 O TLV 3 */
5901 ELEM_OPT_TELV(0x5d, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_ID, NULL);
5902 /* MBMS Response MBMS Response/ 11.3.74 M TLV 3 */
5903 ELEM_OPT_TELV(0x60, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_RESPONSE, NULL);
5905 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5909 * 10.7.3 MBMS-SESSION-STOP-REQUEST
5911 static void
5912 bssgp_mbms_session_stop_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5914 guint32 curr_offset;
5915 guint32 consumed;
5916 guint curr_len;
5918 curr_offset = offset;
5919 curr_len = len;
5921 /* This PDU allows a SGSN to request BSS to stop an MBMS session. */
5923 /* Direction: SGSN to BSS */
5924 pinfo->link_dir = P2P_DIR_DL;
5926 /* TMGI TMGI/ 11.3.77 M TLV 3-8 */
5927 ELEM_MAND_TELV(0x5c, GSM_A_PDU_TYPE_GM, DE_TMGI, NULL);
5928 /* MBMS Session Identity MBMS Session Identity/ 11.3.71 O TLV 3 */
5929 ELEM_OPT_TELV(0x5d, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_ID, NULL);
5930 /* MBMS Stop Cause MBMS Stop Cause/11.3.78 M TLV 3 */
5931 ELEM_OPT_TELV(0x63, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_STOP_CAUSE, NULL);
5933 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5936 * 10.7.4 MBMS-SESSION-STOP-RESPONSE
5938 static void
5939 bssgp_mbms_session_stop_resp(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5941 guint32 curr_offset;
5942 guint32 consumed;
5943 guint curr_len;
5945 curr_offset = offset;
5946 curr_len = len;
5948 /* This PDU allows a BSS to acknowledge to SGSN that it will stop an MBMS session. */
5950 /* Direction: BSS to SGSN */
5951 pinfo->link_dir = P2P_DIR_UL;
5953 /* TMGI TMGI/ 11.3.77 M TLV 3-8 */
5954 ELEM_MAND_TELV(0x5c, GSM_A_PDU_TYPE_GM, DE_TMGI, NULL);
5955 /* MBMS Session Identity MBMS Session Identity/ 11.3.71 O TLV 3 */
5956 ELEM_OPT_TELV(0x5d, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_ID, NULL);
5957 /* MBMS Response MBMS Response/ 11.3.74 M TLV 3 */
5958 ELEM_OPT_TELV(0x60, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_RESPONSE, NULL);
5960 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
5963 * 10.7.5 MBMS-SESSION-UPDATE-REQUEST
5965 static void
5966 bssgp_mbms_session_update_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
5968 guint32 curr_offset;
5969 guint32 consumed;
5970 guint curr_len;
5972 curr_offset = offset;
5973 curr_len = len;
5975 /* This PDU allows an SGSN to request BSS to update the MBMS service area list
5976 * of an ongoing MBMS broadcast service session.
5979 /* Direction: BSS to SGSN */
5980 pinfo->link_dir = P2P_DIR_UL;
5982 /* TMGI TMGI/ 11.3.77 M TLV 3-8 */
5983 ELEM_MAND_TELV(0x5c, GSM_A_PDU_TYPE_GM, DE_TMGI, NULL);
5984 /* MBMS Session Identity MBMS Session Identity/ 11.3.71 O TLV 3 */
5985 ELEM_OPT_TELV(0x5d, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_ID, NULL);
5986 /* ABQP ABQP/11.3.43 M TLV 13-? */
5987 ELEM_MAND_TELV(0x3a , GSM_A_PDU_TYPE_GM, DE_QOS , NULL);
5988 /* MBMS Service Area Identity List MBMS Service Area Identity List/11.3.73 M TLV 4-? */
5989 ELEM_MAND_TELV(0x5f, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SAI_LIST, NULL);
5990 /* MBMS Routing Area List MBMS Routing Area List/11.3.75 M TLV 3-? */
5991 ELEM_MAND_TELV(0x61, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_RA_LIST, NULL);
5992 /* MBMS Session Duration MBMS Session Duration/11.3.72 M TLV 3-? */
5993 ELEM_MAND_TELV(0x5e, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_DUR, NULL);
5994 /* MBMS Session Information MBMS Session Information/11.3.76 M TLV 3 */
5995 ELEM_MAND_TELV(0x62, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_INF, NULL);
5996 /* Time to MBMS Data Transfer Time to MBMS Data Transfer/11.3.92 M TLV 3 */
5997 ELEM_MAND_TELV(0x71, BSSGP_PDU_TYPE, DE_BSSGP_TIME_TO_MBMS_DATA_TRAN, NULL);
5998 /* Allocation/Retention Priority Priority/11.3.27 O TLV 3 */
5999 ELEM_OPT_TELV(0x17, GSM_A_PDU_TYPE_BSSMAP, BE_PRIO, NULL);
6000 /* MBMS Session Repetition Number MBMS Session Repetition Number/11.3.93 O TLV 3 */
6001 ELEM_MAND_TELV(0x72, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_REP_NO, NULL);
6003 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
6006 * 10.7.6 MBMS-SESSION-UPDATE-RESPONSE
6008 static void
6009 bssgp_mbms_session_uptate_resp(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len)
6011 guint32 curr_offset;
6012 guint32 consumed;
6013 guint curr_len;
6015 curr_offset = offset;
6016 curr_len = len;
6018 /* This PDU allows a BSS to acknowledge to SGSN that it will update the MBMS service area list of an ongoing MBMS
6019 * broadcast service session or to indicate to SGSN why the MBMS Service Context cannot be created or is released by the BSS.
6022 /* Direction: BSS to SGSN */
6023 pinfo->link_dir = P2P_DIR_UL;
6025 /* TMGI TMGI/ 11.3.77 M TLV 3-8 */
6026 ELEM_MAND_TELV(0x5c, GSM_A_PDU_TYPE_GM, DE_TMGI, NULL);
6027 /* MBMS Session Identity MBMS Session Identity/ 11.3.71 O TLV 3 */
6028 ELEM_OPT_TELV(0x5d, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_SESSION_ID, NULL);
6029 /* MBMS Response MBMS Response/ 11.3.74 M TLV 3 */
6030 ELEM_OPT_TELV(0x60, BSSGP_PDU_TYPE, DE_BSSGP_MBMS_RESPONSE, NULL);
6032 EXTRANEOUS_DATA_CHECK_EXPERT(curr_len, 0, pinfo, &ei_bssgp_extraneous_data);
6035 static const value_string bssgp_msg_strings[] = {
6036 /* 0x00 */ { BSSGP_PDU_DL_UNITDATA, "DL-UNITDATA" }, /* 10.2.1 DL-UNITDATA */
6037 /* 0x01 */ { BSSGP_PDU_UL_UNITDATA, "UL-UNITDATA" }, /* 10.2.2 UL-UNITDATA */
6038 /* 0x02 */ { BSSGP_PDU_RA_CAPABILITY, "RA-CAPABILITY" }, /* 10.2.3 RA-CAPABILITY */
6039 /* NOTE 1: This value was allocated in an earlier version of the protocol and shall not be used */
6040 /* 0x03 */ { BSSGP_PDU_PTM_UNITDATA, "Reserved" }, /* 10.2.4 (void) */
6041 /* 0x04 */ { BSSGP_PDU_DL_MBMS_UNITDATA, "DL-MBMS-UNITDATA" }, /* 10.2.5 DL-MBMS-UNITDATA */
6042 /* 0x05 */ { BSSGP_PDU_UL_MBMS_UNITDATA, "UL-MBMS-UNITDATA" }, /* 10.2.6 UL-MBMS-UNITDATA */
6043 /* 0x06 */ { BSSGP_PDU_PAGING_PS, "PAGING-PS" }, /* 10.3.1 PAGING PS */
6044 /* 0x07 */ { BSSGP_PDU_PAGING_CS, "PAGING-CS" }, /* 10.3.2 PAGING CS */
6045 /* 0x08 */ { BSSGP_PDU_RA_CAPABILITY_UPDATE, "RA-CAPABILITY-UPDATE" }, /* 10.3.3 RA-CAPABILITY-UPDATE */
6046 /* 0x09 */ { BSSGP_PDU_RA_CAPABILITY_UPDATE_ACK, "RA-CAPABILITY-UPDATE-ACK" }, /* 10.3.4 RA-CAPABILITY-UPDATE-ACK */
6047 /* 0x0a */ { BSSGP_PDU_RADIO_STATUS, "RADIO-STATUS" }, /* 10.3.5 RADIO-STATUS */
6048 /* 0x0b */ { BSSGP_PDU_SUSPEND, "SUSPEND" }, /* 10.3.6 SUSPEND */
6049 /* 0x0c */ { BSSGP_PDU_SUSPEND_ACK, "SUSPEND-ACK" }, /* 10.3.7 SUSPEND-ACK */
6050 /* 0x0d */ { BSSGP_PDU_SUSPEND_NACK, "SUSPEND-NACK" }, /* 10.3.8 SUSPEND-NACK */
6051 /* 0x0e */ { BSSGP_PDU_RESUME, "RESUME" }, /* 10.3.9 RESUME */
6052 /* 0x0f */ { BSSGP_PDU_RESUME_ACK, "RESUME-ACK" }, /* 10.3.10 RESUME-ACK */
6053 /* 0x10 */ { BSSGP_PDU_RESUME_NACK, "RESUME-NACK" }, /* 10.3.11 RESUME-NACK */
6054 /* 0x11 to 0x1f Reserved */
6055 /* 0x11 */ { BSSGP_PDU_RESERVED_0X11, "Reserved" }, /* */
6056 /* 0x12 */ { BSSGP_PDU_RESERVED_0X12, "Reserved" }, /* */
6057 /* 0x13 */ { BSSGP_PDU_RESERVED_0X13, "Reserved" }, /* */
6058 /* 0x14 */ { BSSGP_PDU_RESERVED_0X14, "Reserved" }, /* */
6059 /* 0x15 */ { BSSGP_PDU_RESERVED_0X15, "Reserved" }, /* */
6060 /* 0x16 */ { BSSGP_PDU_RESERVED_0X16, "Reserved" }, /* */
6061 /* 0x17 */ { BSSGP_PDU_RESERVED_0X17, "Reserved" }, /* */
6062 /* 0x18 */ { BSSGP_PDU_RESERVED_0X18, "Reserved" }, /* */
6063 /* 0x19 */ { BSSGP_PDU_RESERVED_0X19, "Reserved" }, /* */
6064 /* 0x1a */ { BSSGP_PDU_RESERVED_0X1A, "Reserved" }, /* */
6065 /* 0x1b */ { BSSGP_PDU_RESERVED_0X1B, "Reserved" }, /* */
6066 /* 0x1c */ { BSSGP_PDU_RESERVED_0X1C, "Reserved" }, /* */
6067 /* 0x1d */ { BSSGP_PDU_RESERVED_0X1D, "Reserved" }, /* */
6068 /* 0x1e */ { BSSGP_PDU_RESERVED_0X1E, "Reserved" }, /* */
6069 /* 0x1f */ { BSSGP_PDU_RESERVED_0X1F, "Reserved" }, /* */
6071 /* 0x20 */ { BSSGP_PDU_BVC_BLOCK, "BVC-BLOCK" }, /* 10.4.8 BVC-BLOCK */
6072 /* 0x21 */ { BSSGP_PDU_BVC_BLOCK_ACK, "BVC-BLOCK-ACK" }, /* 10.4.9 BVC-BLOCK-ACK */
6073 /* 0x22 */ { BSSGP_PDU_BVC_RESET, "BVC-RESET" }, /* 10.4.12 BVC-RESET */
6074 /* 0x23 */ { BSSGP_PDU_BVC_RESET_ACK, "BVC-RESET-ACK" }, /* 10.4.13 BVC-RESET-ACK */
6075 /* 0x24 */ { BSSGP_PDU_BVC_UNBLOCK, "UNBLOCK" }, /* 10.4.10 BVC-UNBLOCK */
6076 /* 0x25 */ { BSSGP_PDU_BVC_UNBLOCK_ACK, "UNBLOCK-ACK" }, /* 10.4.11 BVC-UNBLOCK-ACK */
6077 /* 0x26 */ { BSSGP_PDU_FLOW_CONTROL_BVC, "FLOW-CONTROL-BVC" }, /* 10.4.4 FLOW-CONTROL-BVC */
6078 /* 0x27 */ { BSSGP_PDU_FLOW_CONTROL_BVC_ACK, "FLOW-CONTROL-BVC-ACK" }, /* 10.4.5 FLOW-CONTROL-BVC-ACK */
6079 /* 0x28 */ { BSSGP_PDU_FLOW_CONTROL_MS, "FLOW-CONTROL-MS" }, /* 10.4.6 FLOW-CONTROL-MS */
6080 /* 0x29 */ { BSSGP_PDU_FLOW_CONTROL_MS_ACK, "FLOW-CONTROL-MS-ACK" }, /* 10.4.7 FLOW-CONTROL-MS-ACK */
6081 /* 0x2a */ { BSSGP_PDU_FLUSH_LL, "FLUSH-LL" }, /* 10.4.1 FLUSH-LL */
6082 /* 0x2b */ { BSSGP_PDU_FLUSH_LL_ACK, "FLUSH_LL_ACK" }, /* 10.4.2 FLUSH-LL-ACK */
6083 /* 0x2c */ { BSSGP_PDU_LLC_DISCARDED, "LLC-DISCARDED" }, /* 10.4.3 LLC-DISCARDED */
6084 /* 0x2d */ { BSSGP_PDU_FLOW_CONTROL_PFC, "FLOW-CONTROL-PFC" }, /* 10.4.24 FLOW-CONTROL-PFC */
6085 /* 0x2e */ { BSSGP_PDU_FLOW_CONTROL_PFC_ACK, "FLOW-CONTROL-PFC-ACK" }, /* 10.4.25 FLOW-CONTROL-PFC-ACK */
6086 /* 0x2f to 0x3f Reserved */
6087 /* 0x2f */ { BSSGP_PDU_RESERVED_0X2F, "Reserved" }, /* */
6088 /* 0x30 */ { BSSGP_PDU_RESERVED_0X30, "Reserved" }, /* */
6089 /* 0x31 */ { BSSGP_PDU_RESERVED_0X31, "Reserved" }, /* */
6090 /* 0x32 */ { BSSGP_PDU_RESERVED_0X32, "Reserved" }, /* */
6091 /* 0x33 */ { BSSGP_PDU_RESERVED_0X33, "Reserved" }, /* */
6092 /* 0x34 */ { BSSGP_PDU_RESERVED_0X34, "Reserved" }, /* */
6093 /* 0x35 */ { BSSGP_PDU_RESERVED_0X35, "Reserved" }, /* */
6094 /* 0x36 */ { BSSGP_PDU_RESERVED_0X36, "Reserved" }, /* */
6095 /* 0x37 */ { BSSGP_PDU_RESERVED_0X37, "Reserved" }, /* */
6096 /* 0x38 */ { BSSGP_PDU_RESERVED_0X38, "Reserved" }, /* */
6097 /* 0x39 */ { BSSGP_PDU_RESERVED_0X39, "Reserved" }, /* */
6098 /* 0x3a */ { BSSGP_PDU_RESERVED_0X3A, "Reserved" }, /* */
6099 /* 0x3b */ { BSSGP_PDU_RESERVED_0X3B, "Reserved" }, /* */
6100 /* 0x3c */ { BSSGP_PDU_RESERVED_0X3C, "Reserved" }, /* */
6101 /* 0x3d */ { BSSGP_PDU_RESERVED_0X3D, "Reserved" }, /* */
6102 /* 0x3e */ { BSSGP_PDU_RESERVED_0X3E, "Reserved" }, /* */
6103 /* 0x3f */ { BSSGP_PDU_RESERVED_0X3F, "Reserved" }, /* */
6105 /* 0x40 */ { BSSGP_PDU_SGSN_INVOKE_TRACE, "SGSN-INVOKE-TRACE" }, /* 10.4.15 SGSN-INVOKE-TRACE */
6106 /* 0x41 */ { BSSGP_PDU_STATUS, "STATUS" }, /* 10.4.14 STATUS */
6107 /* 0x42 to 0x4f Reserved */
6108 /* 0x42 */ { BSSGP_PDU_RESERVED_0X42, "Reserved" }, /* */
6109 /* 0x43 */ { BSSGP_PDU_RESERVED_0X43, "Reserved" }, /* */
6110 /* 0x44 */ { BSSGP_PDU_RESERVED_0X44, "Reserved" }, /* */
6111 /* 0x45 */ { BSSGP_PDU_RESERVED_0X45, "Reserved" }, /* */
6112 /* 0x46 */ { BSSGP_PDU_RESERVED_0X46, "Reserved" }, /* */
6113 /* 0x47 */ { BSSGP_PDU_RESERVED_0X47, "Reserved" }, /* */
6114 /* 0x48 */ { BSSGP_PDU_RESERVED_0X48, "Reserved" }, /* */
6115 /* 0x49 */ { BSSGP_PDU_RESERVED_0X49, "Reserved" }, /* */
6116 /* 0x4a */ { BSSGP_PDU_RESERVED_0X4A, "Reserved" }, /* */
6117 /* 0x4b */ { BSSGP_PDU_RESERVED_0X4B, "Reserved" }, /* */
6118 /* 0x4c */ { BSSGP_PDU_RESERVED_0X4C, "Reserved" }, /* */
6119 /* 0x4d */ { BSSGP_PDU_RESERVED_0X4D, "Reserved" }, /* */
6120 /* 0x4e */ { BSSGP_PDU_RESERVED_0X4E, "Reserved" }, /* */
6121 /* 0x4f */ { BSSGP_PDU_RESERVED_0X4F, "Reserved" }, /* */
6122 /* 0x50 */ { BSSGP_PDU_DOWNLOAD_BSS_PFC, "DOWNLOAD-BSS-PFC" }, /* 10.4.16 DOWNLOAD-BSS-PFC */
6123 /* 0x51 */ { BSSGP_PDU_CREATE_BSS_PFC, "CREATE-BSS-PFC" }, /* 10.4.17 CREATE-BSS-PFC */
6124 /* 0x52 */ { BSSGP_PDU_CREATE_BSS_PFC_ACK, "CREATE-BSS-PFC-ACK" }, /* 10.4.18 CREATE-BSS-PFC-ACK */
6125 /* 0x53 */ { BSSGP_PDU_CREATE_BSS_PFC_NACK, "CREATE-BSS-PFC-NACK" }, /* 10.4.19 CREATE-BSS-PFC-NACK */
6126 /* 0x54 */ { BSSGP_PDU_MODIFY_BSS_PFC, "MODIFY-BSS-PFC" }, /* 10.4.20 MODIFY-BSS-PFC */
6127 /* 0x55 */ { BSSGP_PDU_MODIFY_BSS_PFC_ACK, "MODIFY-BSS-PFC-ACK" }, /* 10.4.21 MODIFY-BSS-PFC-ACK */
6128 /* 0x56 */ { BSSGP_PDU_DELETE_BSS_PFC, "DELETE-BSS-PFC" }, /* 10.4.22 DELETE-BSS-PFC */
6129 /* 0x57 */ { BSSGP_PDU_DELETE_BSS_PFC_ACK, "DELETE-BSS-PFC-ACK" }, /* 10.4.23 DELETE-BSS-PFC-ACK */
6130 /* 0x58 */ { BSSGP_PDU_DELETE_BSS_PFC_REQ, "DELETE-BSS-PFC-REQ" }, /* 10.4.26 DELETE-BSS-PFC-REQ */
6131 /* 0x59 */ { BSSGP_PDU_PS_HANDOVER_REQUIRED, "PS-HANDOVER-REQUIRED" }, /* 10.4.27 PS-HANDOVER-REQUIRED */
6132 /* 0x5a */ { BSSGP_PDU_PS_HANDOVER_REQUIRED_ACK, "PS-HANDOVER-REQUIRED-ACK" }, /* 10.4.28 PS-HANDOVER-REQUIRED-ACK */
6133 /* 0x5b */ { BSSGP_PDU_PS_HANDOVER_REQUIRED_NACK, "PS-HANDOVER-REQUIRED-NACK" }, /* 10.4.29 PS-HANDOVER-REQUIRED-NACK */
6134 /* 0x5c */ { BSSGP_PDU_PS_HANDOVER_REQUEST, "PS-HANDOVER-REQUEST" }, /* 10.4.30 PS-HANDOVER-REQUEST */
6135 /* 0x5d */ { BSSGP_PDU_PS_HANDOVER_REQUEST_ACK, "PS-HANDOVER-REQUEST-ACK" }, /* 10.4.31 PS-HANDOVER-REQUEST-ACK */
6136 /* 0x5e */ { BSSGP_PDU_PS_HANDOVER_REQUEST_NACK, "PS-HANDOVER-REQUEST-NACK" }, /* 10.4.31 10.4.32 PS-HANDOVER-REQUEST-NACK */
6138 /* 0x5f */ { BSSGP_PDU_RESERVED_0X5F, "Reserved" }, /* */
6140 /* 0x60 */ { BSSGP_PDU_PERFORM_LOCATION_REQUEST, "PERFORM-LOCATION-REQUEST" }, /* 10.5.1 PERFORM-LOCATION-REQUEST */
6141 /* 0x61 */ { BSSGP_PDU_PERFORM_LOCATION_RESPONSE, "PERFORM-LOCATION-RESPONSE" }, /* 10.5.2 PERFORM-LOCATION-RESPONSE */
6142 /* 0x62 */ { BSSGP_PDU_PERFORM_LOCATION_ABORT, "PERFORM-LOCATION-ABORT" }, /* 10.5.3 PERFORM-LOCATION-ABORT */
6143 /* 0x63 */ { BSSGP_PDU_POSITION_COMMAND, "POSITION-COMMAND" }, /* 10.5.4 POSITION-COMMAND */
6144 /* 0x64 */ { BSSGP_PDU_POSITION_RESPONSE, "POSITION-RESPONSE" }, /* 10.5.5 POSITION-RESPONSE */
6146 /* 0x65 */ { BSSGP_PDU_RESERVED_0X65, "Reserved" }, /* */
6147 /* 0x66 */ { BSSGP_PDU_RESERVED_0X66, "Reserved" }, /* */
6148 /* 0x67 */ { BSSGP_PDU_RESERVED_0X67, "Reserved" }, /* */
6149 /* 0x68 */ { BSSGP_PDU_RESERVED_0X68, "Reserved" }, /* */
6150 /* 0x69 */ { BSSGP_PDU_RESERVED_0X69, "Reserved" }, /* */
6151 /* 0x6a */ { BSSGP_PDU_RESERVED_0X6A, "Reserved" }, /* */
6152 /* 0x6b */ { BSSGP_PDU_RESERVED_0X6B, "Reserved" }, /* */
6153 /* 0x6b */ { BSSGP_PDU_RESERVED_0X6C, "Reserved" }, /* */
6154 /* 0x6d */ { BSSGP_PDU_RESERVED_0X6D, "Reserved" }, /* */
6155 /* 0x6e */ { BSSGP_PDU_RESERVED_0X6E, "Reserved" }, /* */
6156 /* 0x6f */ { BSSGP_PDU_RESERVED_0X6F, "Reserved" }, /* */
6158 /* 0x70 */ { BSSGP_PDU_RAN_INFORMATION, "RAN-INFORMATION" }, /* 10.6.2 RAN-INFORMATION */
6159 /* 0x71 */ { BSSGP_PDU_RAN_INFORMATION_REQUEST, "RAN-INFORMATION-REQUEST" }, /* 10.6.1 RAN-INFORMATION-REQUEST */
6160 /* 0x72 */ { BSSGP_PDU_RAN_INFORMATION_ACK, "RAN-INFORMATION-ACK" }, /* 10.6.3 RAN-INFORMATION-ACK */
6161 /* 0x73 */ { BSSGP_PDU_RAN_INFORMATION_ERROR, "RAN-INFORMATION-ERROR" }, /* 10.6.4 RAN-INFORMATION-ERROR */
6162 /* 0x74 */ { BSSGP_PDU_RAN_INFORMATION_APP_ERROR, "RAN-INFORMATION-APPLICATION-ERROR" }, /* 10.6.5 RAN-INFORMATION-APPLICATION-ERROR */
6163 /* 0x75 */ { BSSGP_PDU_RESERVED_0X75, "Reserved" }, /* */
6164 /* 0x76 */ { BSSGP_PDU_RESERVED_0X76, "Reserved" }, /* */
6165 /* 0x77 */ { BSSGP_PDU_RESERVED_0X77, "Reserved" }, /* */
6166 /* 0x78 */ { BSSGP_PDU_RESERVED_0X78, "Reserved" }, /* */
6167 /* 0x79 */ { BSSGP_PDU_RESERVED_0X79, "Reserved" }, /* */
6168 /* 0x7a */ { BSSGP_PDU_RESERVED_0X7A, "Reserved" }, /* */
6169 /* 0x7b */ { BSSGP_PDU_RESERVED_0X7B, "Reserved" }, /* */
6170 /* 0x7c */ { BSSGP_PDU_RESERVED_0X7C, "Reserved" }, /* */
6171 /* 0x7d */ { BSSGP_PDU_RESERVED_0X7D, "Reserved" }, /* */
6172 /* 0x7e */ { BSSGP_PDU_RESERVED_0X7E, "Reserved" }, /* */
6173 /* 0x7f */ { BSSGP_PDU_RESERVED_0X7F, "Reserved" }, /* */
6174 /* 0x80 */ { BSSGP_PDU_MBMS_SESSION_START_REQ, "MBMS-SESSION-START-REQUEST" }, /* 10.7.1 MBMS-SESSION-START-REQUEST */
6175 /* 0x81 */ { BSSGP_PDU_MBMS_SESSION_START_RESP, "MBMS-SESSION-START-RESPONSE" }, /* 10.7.2 MBMS-SESSION-START-RESPONSE */
6176 /* 0x82 */ { BSSGP_PDU_MBMS_SESSION_STOP_REQ, "MBMS-SESSION-STOP-REQUEST" }, /* 10.7.3 MBMS-SESSION-STOP-REQUEST */
6177 /* 0x83 */ { BSSGP_PDU_MBMS_SESSION_STOP_RESP, "MBMS-SESSION-STOP-RESPONSE" }, /* 10.7.4 MBMS-SESSION-STOP-RESPONSE */
6178 /* 0x84 */ { BSSGP_PDU_MBMS_SESSION_UPDATE_REQ, "MBMS-SESSION-UPDATE-REQUEST" }, /* 10.7.5 MBMS-SESSION-UPDATE-REQUEST */
6179 /* 0x85 */ { BSSGP_PDU_MBMS_SESSION_UPDATE_RESP, "MBMS-SESSION-UPDATE-RESPONSE" },/* 10.7.6 MBMS-SESSION-UPDATE-RESPONSE */
6181 /* 0x86 */ { BSSGP_PDU_RESERVED_0X86, "Reserved" }, /* */
6182 /* 0x87 */ { BSSGP_PDU_RESERVED_0X87, "Reserved" }, /* */
6183 /* 0x88 */ { BSSGP_PDU_RESERVED_0X88, "Reserved" }, /* */
6184 /* 0x89 */ { BSSGP_PDU_RESERVED_0X89, "Reserved" }, /* */
6185 /* 0x8a */ { BSSGP_PDU_RESERVED_0X8A, "Reserved" }, /* */
6186 /* 0x8b */ { BSSGP_PDU_RESERVED_0X8B, "Reserved" }, /* */
6187 /* 0x8c */ { BSSGP_PDU_RESERVED_0X8C, "Reserved" }, /* */
6188 /* 0x8d */ { BSSGP_PDU_RESERVED_0X8D, "Reserved" }, /* */
6189 /* 0x8e */ { BSSGP_PDU_RESERVED_0X8E, "Reserved" }, /* */
6190 /* 0x8f */ { BSSGP_PDU_RESERVED_0X8F, "Reserved" }, /* */
6191 /* 0x90 */ { BSSGP_PDU_RESERVED_0X90, "Reserved" }, /* */
6193 /* 0x91 */ {BSSGP_PDU_PS_HANDOVER_COMPLETE, "PS-HANDOVER-COMPLETE" }, /* 10.4.33 PS-HANDOVER-COMPLETE */
6194 /* 0x92 */ {BSSGP_PDU_PS_HANDOVER_CANCEL, "PS-HANDOVER-CANCEL" }, /* 10.4.34 PS-HANDOVER-CANCEL */
6195 /* 0x93 */ {BSSGP_PDU_PS_HANDOVER_COMPLETE_ACK, "PS-HANDOVER-COMPLETE-ACK" }, /* 10.4.35 PS-HANDOVER-COMPLETE-ACK*/
6197 { 0, NULL }
6199 static value_string_ext bssgp_msg_strings_ext = VALUE_STRING_EXT_INIT(bssgp_msg_strings);
6201 #define NUM_BSSGP_MSG (sizeof(bssgp_msg_strings)/sizeof(value_string))
6202 static gint ett_bssgp_msg[NUM_BSSGP_MSG];
6203 static void (*bssgp_msg_fcn[])(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len) = {
6204 /* 0x00 to 0x10 */
6205 bssgp_dl_unitdata, /* 10.2.1 DL-UNITDATA */
6206 bssgp_ul_unitdata, /* 10.2.2 UL-UNITDATA */
6207 bssgp_ra_cap, /* 10.2.3 RA-CAPABILITY */
6208 NULL, /* 10.2.4 (void) */
6209 bssgp_dl_mbms_unitdata, /* 10.2.5 DL-MBMS-UNITDATA */
6210 bssgp_ul_mbms_unitdata, /* 10.2.6 UL-MBMS-UNITDATA */
6211 bssgp_paging_ps, /* 10.3.1 PAGING PS */
6212 bssgp_paging_cs, /* 10.3.2 PAGING CS */
6213 bssgp_ra_cap_upd, /* 10.3.3 RA-CAPABILITY-UPDATE */
6214 bssgp_ra_cap_upd_ack, /* 10.3.3 RA-CAPABILITY-UPDATE */
6215 bssgp_ra_status, /* 10.3.5 RADIO-STATUS */
6216 bssgp_suspend, /* 10.3.6 SUSPEND */
6217 bssgp_suspend_ack, /* 10.3.7 SUSPEND-ACK */
6218 bssgp_suspend_nack, /* 10.3.8 SUSPEND-NACK */
6219 bssgp_resume, /* 10.3.9 RESUME */
6220 bssgp_resume_ack, /* 10.3.10 RESUME-ACK */
6221 bssgp_resume_nack, /* 10.3.11 RESUME-NACK */
6223 /* 0x11 to 0x1f Reserved */
6224 NULL, /* 0x11 */
6225 NULL, /* 0x12 */
6226 NULL, /* 0x13 */
6227 NULL, /* 0x14 */
6228 NULL, /* 0x15 */
6229 NULL, /* 0x16 */
6230 NULL, /* 0x17 */
6231 NULL, /* 0x18 */
6232 NULL, /* 0x19 */
6233 NULL, /* 0x1A */
6234 NULL, /* 0x1B */
6235 NULL, /* 0x1C */
6236 NULL, /* 0x1D */
6237 NULL, /* 0x1E */
6238 NULL, /* 0x1F */
6240 /* 0x20 to 0x2e */
6241 bssgp_bvc_block, /* 10.4.8 BVC-BLOCK */
6242 bssgp_bvc_block_ack, /* 10.4.9 BVC-BLOCK-ACK */
6243 bssgp_bvc_reset, /* 10.4.12 BVC-RESET */
6244 bssgp_bvc_reset_ack, /* 10.4.13 BVC-RESET-ACK */
6245 bssgp_bvc_un_block, /* 10.4.10 BVC-UNBLOCK */
6246 bssgp_bvc_un_block_ack, /* 10.4.11 BVC-UNBLOCK-ACK */
6247 bssgp_flow_control_bvc, /* 10.4.4 FLOW-CONTROL-BVC */
6248 bssgp_flow_control_bvc_ack, /* 10.4.5 FLOW-CONTROL-BVC-ACK */
6249 bssgp_flow_control_ms, /* 10.4.6 FLOW-CONTROL-MS */
6250 bssgp_flow_control_ms_ack, /* 10.4.7 FLOW-CONTROL-MS-ACK */
6251 bssgp_flush_ll, /* 10.4.1 FLUSH-LL */
6252 bssgp_flush_ll_ack, /* 10.4.2 FLUSH-LL-ACK */
6253 bssgp_llc_discarded, /* 10.4.3 LLC-DISCARDED */
6254 bssgp_flow_cntrl_pfc, /* 10.4.24 FLOW-CONTROL-PFC */
6255 bssgp_flow_cntrl_pfc_ack, /* 10.4.25 FLOW-CONTROL-PFC-ACK */
6257 /* 0x2f to 0x3f Reserved */
6258 NULL, /* 0x2f */
6259 NULL, /* 0x30 */
6260 NULL, /* 0x31 */
6261 NULL, /* 0x32 */
6262 NULL, /* 0x33 */
6263 NULL, /* 0x34 */
6264 NULL, /* 0x35 */
6265 NULL, /* 0x36 */
6266 NULL, /* 0x37 */
6267 NULL, /* 0x38 */
6268 NULL, /* 0x39 */
6269 NULL, /* 0x3A */
6270 NULL, /* 0x3B */
6271 NULL, /* 0x3C */
6272 NULL, /* 0x3D */
6273 NULL, /* 0x3E */
6274 NULL, /* 0x3F */
6276 /* 0x40 to 0x41 */
6277 bssgp_sgsn_invoke_trace, /* 10.4.15 SGSN-INVOKE-TRACE */
6278 bssgp_status, /* 10.4.14 STATUS */
6280 /* 0x42 to 0x4f Reserved */
6281 NULL, /* 0x42 */
6282 NULL, /* 0x43 */
6283 NULL, /* 0x44 */
6284 NULL, /* 0x45 */
6285 NULL, /* 0x46 */
6286 NULL, /* 0x47 */
6287 NULL, /* 0x48 */
6288 NULL, /* 0x49 */
6289 NULL, /* 0x4A */
6290 NULL, /* 0x4B */
6291 NULL, /* 0x4C */
6292 NULL, /* 0x4D */
6293 NULL, /* 0x4E */
6294 NULL, /* 0x4F */
6296 /* 0x50 to 0x5e */
6297 bssgp_download_bss_pfc, /* 10.4.16 DOWNLOAD-BSS-PFC */
6298 bssgp_create_bss_pfc, /* 10.4.17 CREATE-BSS-PFC */
6299 bssgp_create_bss_pfc_ack, /* 10.4.18 CREATE-BSS-PFC-ACK */
6300 bssgp_create_bss_pfc_nack, /* 10.4.19 CREATE-BSS-PFC-NACK */
6301 bssgp_modify_bss_pfc, /* 10.4.20 MODIFY-BSS-PFC */
6302 bssgp_modify_bss_pfc_ack, /* 10.4.21 MODIFY-BSS-PFC-ACK */
6303 bssgp_delete_bss_pfc, /* 10.4.22 DELETE-BSS-PFC */
6304 bssgp_delete_bss_pfc_ack, /* 10.4.23 DELETE-BSS-PFC-ACK */
6305 bssgp_delete_bss_pfc_req, /* 10.4.26 DELETE-BSS-PFC-REQ */
6306 bssgp_ps_ho_required, /* 10.4.27 PS-HANDOVER-REQUIRED */
6307 bssgp_ps_ho_required_ack, /* 10.4.28 PS-HANDOVER-REQUIRED-ACK */
6308 bssgp_ps_ho_required_nack, /* 10.4.29 PS-HANDOVER-REQUIRED-NACK */
6309 bssgp_ps_ho_request, /* 10.4.30 PS-HANDOVER-REQUEST */
6310 bssgp_ps_ho_request_ack, /* 10.4.31 PS-HANDOVER-REQUEST-ACK */
6311 bssgp_ps_ho_request_nack, /* 10.4.31 10.4.32 PS-HANDOVER-REQUEST-NACK */
6313 /* 0x5f Reserved */
6314 NULL, /* 0x5F */
6316 /* 0x60 */
6317 bssgp_perform_loc_request, /* 10.5.1 PERFORM-LOCATION-REQUEST */
6318 bssgp_perform_loc_response, /* 10.5.2 PERFORM-LOCATION-RESPONSE */
6319 bssgp_perform_loc_response_abort, /* 10.5.3 PERFORM-LOCATION-ABORT */
6320 bssgp_pos_cmd, /* 10.5.4 POSITION-COMMAND */
6321 bssgp_pos_resp, /* 10.5.5 POSITION-RESPONSE */
6323 /* 0x65 to 0x6f Reserved */
6324 NULL, /* 0x65 */
6325 NULL, /* 0x66 */
6326 NULL, /* 0x67 */
6327 NULL, /* 0x68 */
6328 NULL, /* 0x69 */
6329 NULL, /* 0x6a */
6330 NULL, /* 0x6b */
6331 NULL, /* 0x6c */
6332 NULL, /* 0x6d */
6333 NULL, /* 0x6e */
6334 NULL, /* 0x6f */
6335 bssgp_ran_inf, /* 10.6.2 RAN-INFORMATION */
6336 bssgp_ran_inf_request, /* 10.6.1 RAN-INFORMATION-REQUEST */
6337 bssgp_ran_inf_request_ack, /* 10.6.3 RAN-INFORMATION-ACK */
6338 bssgp_ran_inf_err, /* 10.6.4 RAN-INFORMATION-ERROR */
6339 bssgp_ran_inf_app_err, /* 10.6.5 RAN-INFORMATION-APPLICATION-ERROR */
6340 NULL, /* 0x75 */
6341 NULL, /* 0x76 */
6342 NULL, /* 0x77 */
6343 NULL, /* 0x78 */
6344 NULL, /* 0x79 */
6345 NULL, /* 0x7a */
6346 NULL, /* 0x7b */
6347 NULL, /* 0x7c */
6348 NULL, /* 0x7d */
6349 NULL, /* 0x7e */
6350 NULL, /* 0x7f */
6351 bssgp_mbms_session_start_req, /* 10.7.1 MBMS-SESSION-START-REQUEST */
6352 bssgp_mbms_session_start_resp, /* 10.7.2 MBMS-SESSION-START-RESPONSE */
6353 bssgp_mbms_session_stop_req, /* 10.7.3 MBMS-SESSION-STOP-REQUEST */
6354 bssgp_mbms_session_stop_resp, /* 10.7.4 MBMS-SESSION-STOP-RESPONSE */
6355 bssgp_mbms_session_update_req, /* 10.7.5 MBMS-SESSION-UPDATE-REQUEST */
6356 bssgp_mbms_session_uptate_resp, /* 10.7.6 MBMS-SESSION-UPDATE-RESPONSE */
6357 NULL, /* 0x86 */
6358 NULL, /* 0x87 */
6359 NULL, /* 0x88 */
6360 NULL, /* 0x89 */
6361 NULL, /* 0x8a */
6362 NULL, /* 0x8b */
6363 NULL, /* 0x8c */
6364 NULL, /* 0x8d */
6365 NULL, /* 0x8e */
6366 NULL, /* 0x8f */
6367 NULL, /* 0x90 */
6368 bssgp_ps_ho_complete, /* 0x91 10.4.33 PS-HANDOVER-COMPLETE */
6369 bssgp_ps_ho_cancel, /* 0x92 10.4.34 PS-HANDOVER-CANCEL */
6370 bssgp_ps_ho_complete_ack, /* 0x93 10.4.35 PS-HANDOVER-COMPLETE-ACK*/
6371 NULL, /* NONE */
6374 static void get_bssgp_msg_params(guint8 oct, const gchar **msg_str, int *ett_tree, int *hf_idx, msg_fcn *msg_fcn_p)
6376 gint idx;
6378 *msg_str = try_val_to_str_idx_ext((guint32) (oct & 0xff), &bssgp_msg_strings_ext, &idx);
6379 *hf_idx = hf_bssgp_msg_type;
6380 if (*msg_str != NULL) {
6381 *ett_tree = ett_bssgp_msg[idx];
6382 *msg_fcn_p = bssgp_msg_fcn[idx];
6385 return;
6388 static void
6389 dissect_bssgp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
6392 proto_item *ti;
6393 proto_tree *bssgp_tree = NULL;
6394 int offset = 0;
6395 guint32 len;
6396 const gchar *msg_str = NULL;
6397 gint ett_tree;
6398 int hf_idx;
6399 void (*msg_fcn_p)(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, guint32 offset, guint len);
6401 /* Save pinfo */
6402 g_rim_application_identity = 0;
6403 gparent_tree = tree;
6404 len = tvb_length(tvb);
6406 col_set_str(pinfo->cinfo, COL_PROTOCOL, "BSSGP");
6408 col_clear(pinfo->cinfo, COL_INFO);
6411 g_pdu_type = tvb_get_guint8(tvb,offset);
6412 if (tree) {
6413 ti = proto_tree_add_item(tree, proto_bssgp, tvb, 0, -1, ENC_NA);
6414 bssgp_tree = proto_item_add_subtree(ti, ett_bssgp);
6417 /* Messge type IE*/
6418 msg_fcn_p = NULL;
6419 ett_tree = -1;
6420 hf_idx = -1;
6421 msg_str = NULL;
6423 get_bssgp_msg_params(g_pdu_type, &msg_str, &ett_tree, &hf_idx, &msg_fcn_p);
6425 if(msg_str){
6426 col_add_fstr(pinfo->cinfo, COL_INFO, "%s", msg_str);
6427 }else{
6428 proto_tree_add_text(bssgp_tree, tvb, offset, 1,"Unknown message 0x%x",g_pdu_type);
6429 return;
6433 * Add BSSGP message name
6435 proto_tree_add_item(bssgp_tree, hf_idx, tvb, offset, 1, ENC_BIG_ENDIAN);
6436 offset++;
6440 * decode elements
6442 if (msg_fcn_p == NULL)
6444 proto_tree_add_text(bssgp_tree, tvb, offset, len - offset, "Message Elements");
6446 else
6448 (*msg_fcn_p)(tvb, bssgp_tree, pinfo, offset, len - offset);
6452 void
6453 proto_register_bssgp(void)
6455 guint i;
6456 guint last_offset;
6458 static hf_register_info hf[] = {
6459 { &hf_bssgp_msg_type,
6460 { "PDU Type", "bssgp.pdu_type",
6461 FT_UINT8, BASE_HEX|BASE_EXT_STRING, &bssgp_msg_strings_ext, 0x0,
6462 NULL, HFILL }
6464 { &hf_bssgp_elem_id,
6465 { "Element ID", "bssgp.elem_id",
6466 FT_UINT8, BASE_HEX, NULL, 0,
6467 NULL, HFILL }
6469 { &hf_bssgp_bss_area_ind,
6470 { "BSS indicator", "bssgp.bss_ind",
6471 FT_UINT8, BASE_HEX, NULL, 0x0,
6472 NULL, HFILL }
6474 { &hf_bssgp_bvci,
6475 { "BVCI", "bssgp.bvci",
6476 FT_UINT16, BASE_HEX, NULL, 0x0,
6477 NULL, HFILL }
6479 { &hf_bssgp_bmax,
6480 { "Bmax(x 100 or in increments as defined by the Flow Control Granularity IE)", "bssgp.bmax",
6481 FT_UINT16, BASE_DEC, NULL, 0x0,
6482 NULL, HFILL }
6484 { &hf_bssgp_r,
6485 { "R(x 100 or in increments as defined by the Flow Control Granularity IE)", "bssgp.r",
6486 FT_UINT16, BASE_DEC, NULL, 0x0,
6487 NULL, HFILL }
6489 { &hf_bssgp_r_pfc,
6490 { "R_PFC(x 100 or in increments as defined by the Flow Control Granularity IE)", "bssgp.r_pfc",
6491 FT_UINT16, BASE_DEC, NULL, 0x0,
6492 NULL, HFILL }
6494 { &hf_bssgp_bucket_size,
6495 { "Bmax(x 100 or in increments as defined by the Flow Control Granularity IE)", "bssgp.bucket_size",
6496 FT_UINT16, BASE_DEC, NULL, 0x0,
6497 NULL, HFILL }
6499 { &hf_bssgp_bmax_pfc,
6500 { "Bmax_PFC(x 100 or in increments as defined by the Flow Control Granularity IE)", "bssgp.bmax_pfc",
6501 FT_UINT16, BASE_DEC, NULL, 0x0,
6502 NULL, HFILL }
6504 { &hf_bssgp_omc_id,
6505 { "OMC identity", "bssgp.omc_id",
6506 FT_BYTES, BASE_NONE, NULL, 0x0,
6507 NULL, HFILL }
6509 { &hf_bssgp_nsei,
6510 { "NSEI", "bssgp.nsei",
6511 FT_UINT16, BASE_HEX, NULL, 0x0,
6512 NULL, HFILL }
6514 { &hf_bssgp_rrlp_flag1,
6515 { "Flag 1", "bssgp.rrlp_flag1",
6516 FT_BOOLEAN, 8, TFS(&bssgp_rrlp_flg1_vals), 0x01,
6517 NULL, HFILL }
6519 { &hf_bssgp_ci,
6520 { "CI", "bssgp.ci",
6521 FT_UINT16, BASE_HEX, NULL, 0x0,
6522 "Cell Identity", HFILL }
6524 { &hf_bssgp_flush_action,
6525 { "Action", "bssgp.flush_action",
6526 FT_UINT8, BASE_DEC, VALS(bssgp_flush_action_vals), 0x0,
6527 NULL, HFILL }
6529 { &hf_bssgp_llc_frames_disc,
6530 { "Number of frames discarded", "bssgp.llc_frames_disc",
6531 FT_UINT8, BASE_DEC, NULL, 0x0,
6532 NULL, HFILL }
6534 { &hf_bssgp_ra_discriminator,
6535 { "Routing Address Discriminator", "bssgp.rad",
6536 FT_UINT8, BASE_DEC, VALS(bssgp_ra_discriminator_vals), 0x0f,
6537 NULL, HFILL }
6539 { &hf_bssgp_rim_app_id,
6540 { "RIM Application Identity", "bssgp.rim_app_id",
6541 FT_UINT8, BASE_DEC, VALS(bssgp_rim_appid_vals), 0x0,
6542 NULL, HFILL }
6544 { &hf_bssgp_rim_seq_no,
6545 { "RIM Sequence Number", "bssgp.rim_seq_no",
6546 FT_UINT32, BASE_DEC, NULL, 0x0,
6547 NULL, HFILL }
6549 { &hf_bssgp_rat_discriminator,
6550 { "RAT discriminator", "bssgp.rat_discriminator",
6551 FT_UINT8, BASE_DEC, VALS(bssgp_rat_discriminator_vals), 0x0f,
6552 NULL, HFILL }
6554 { &hf_bssgp_nacc_cause,
6555 { "NACC Cause", "bssgp.nacc_cause",
6556 FT_UINT8, BASE_DEC, VALS(bssgp_nacc_cause_vals), 0x0,
6557 NULL, HFILL }
6559 { &hf_bssgp_s13_cause,
6560 { "SI3 Cause", "bssgp.s13_cause",
6561 FT_UINT8, BASE_DEC, VALS(bssgp_s13_cause_vals), 0x0,
6562 NULL, HFILL }
6564 { &hf_bssgp_mbms_data_ch_cause,
6565 { "MBMS data channel Cause", "bssgp.mbms_data_ch_cause",
6566 FT_UINT8, BASE_DEC, VALS(bssgp_mbms_data_ch_cause_vals), 0x0,
6567 NULL, HFILL }
6569 { &hf_bssgp_utra_si_cause,
6570 { "UTRA SI Cause", "bssgp.utra_si_cause",
6571 FT_UINT8, BASE_DEC, VALS(bssgp_utra_si_cause_vals), 0x0,
6572 NULL, HFILL }
6574 { &hf_bssgp_num_si_psi,
6575 { "Number of SI/PSI", "bssgp.num_si_psi",
6576 FT_UINT8, BASE_DEC, NULL, 0xfe,
6577 NULL, HFILL }
6579 {&hf_bssgp_si_psi_type,
6580 { "Type", "bssgp.si_psi_type",
6581 FT_BOOLEAN, 8, TFS(&bssgp_si_psi_type_vals), 0x01,
6582 NULL, HFILL }
6584 { &hf_bssgp_ran_inf_req_pdu_t_ext_c,
6585 { "PDU Type Extension", "bssgp.ran_inf_req_pdu_t_ext_c",
6586 FT_UINT8, BASE_DEC, VALS(bssgp_ran_inf_req_pdu_t_ext_c_vals), 0x0e,
6587 NULL, HFILL }
6589 { &hf_bssgp_ran_inf_pdu_t_ext_c,
6590 { "PDU Type Extension", "bssgp.ran_inf_pdu_t_ext_c",
6591 FT_UINT8, BASE_DEC, VALS(bssgp_ran_inf_pdu_t_ext_c_vals), 0x0e,
6592 NULL, HFILL }
6594 {&hf_bssgp_rim_pdu_ind_ack,
6595 { "ACK", "bssgp.rim_pdu_ind_ack",
6596 FT_BOOLEAN, 8, TFS(&bssgp_rim_pdu_ind_ack_vals), 0x01,
6597 NULL, HFILL }
6599 { &hf_bssgp_rim_proto_ver_no,
6600 { "RIM Protocol Version Number", "bssgp.rim_proto_ver_no",
6601 FT_UINT8, BASE_DEC, VALS(bssgp_rim_proto_ver_no_vals), 0x0,
6602 NULL, HFILL }
6604 { &hf_bssgp_delay_val,
6605 { "Delay Value (in centi-seconds)", "bssgp.delay_val",
6606 FT_UINT16, BASE_DEC, NULL, 0x0,
6607 NULL, HFILL }
6609 { &hf_bssgp_cause,
6610 { "Cause", "bssgp.cause",
6611 FT_UINT8, BASE_DEC|BASE_EXT_STRING, &bssgp_cause_vals_ext, 0x0,
6612 NULL, HFILL }
6614 { &hf_bssgp_peak_rate_gran,
6615 { "Peak Bit Rate Granularity", "bssgp.peak_rate_gran",
6616 FT_UINT8, BASE_DEC, NULL, 0xc0,
6617 NULL, HFILL }
6619 { &hf_bssgp_cr_bit,
6620 { "C/R", "bssgp.cr_bit",
6621 FT_BOOLEAN, 8, TFS(&bssgp_cr_bit_vals), 0x20,
6622 NULL, HFILL }
6624 { &hf_bssgp_t_bit,
6625 { "T", "bssgp.t_bit",
6626 FT_BOOLEAN, 8, TFS(&bssgp_t_bit_vals), 0x10,
6627 NULL, HFILL }
6629 { &hf_bssgp_a_bit,
6630 { "A", "bssgp.a_bit",
6631 FT_BOOLEAN, 8, TFS(&bssgp_a_bit_vals), 0x08,
6632 NULL, HFILL }
6634 { &hf_bssgp_ra_cause,
6635 { "Radio Cause", "bssgp.ra_cause",
6636 FT_UINT8, BASE_DEC, VALS(bssgp_radio_cause_vals), 0x00,
6637 NULL, HFILL }
6639 { &hf_bssgp_ra_cap_upd_cause,
6640 { "RA-Cap-UPD Cause", "bssgp.ra_cap_upd_cause",
6641 FT_UINT8, BASE_DEC, VALS(bssgp_ra_cap_upd_cause_vals), 0x00,
6642 NULL, HFILL }
6644 { &hf_bssgp_r_default_ms,
6645 { "R_default_MS(x 100 or in increments as defined by the Flow Control Granularity IE)", "bssgp.r_default_ms",
6646 FT_UINT16, BASE_DEC, NULL, 0x0,
6647 NULL, HFILL }
6650 { &hf_bssgp_suspend_ref_no,
6651 { "Suspend Reference Number", "bssgp.suspend_ref_no",
6652 FT_UINT8, BASE_DEC, NULL, 0x00,
6653 NULL, HFILL }
6655 { &hf_bssgp_tag,
6656 { "Tag", "bssgp.tag",
6657 FT_UINT8, BASE_DEC, NULL, 0x00,
6658 NULL, HFILL }
6660 { &hf_bssgp_trace_ref,
6661 { "Trace Reference", "bssgp.trace_ref",
6662 FT_UINT16, BASE_DEC, NULL, 0x00,
6663 NULL, HFILL }
6665 { &hf_bssgp_trigger_id,
6666 { "Entity Identity", "bssgp.entity_id",
6667 FT_BYTES, BASE_NONE, NULL, 0x00,
6668 NULL, HFILL }
6670 { &hf_bssgp_transaction_id,
6671 { "Transaction Id", "bssgp.transaction_id",
6672 FT_UINT16, BASE_DEC, NULL, 0x00,
6673 NULL, HFILL }
6675 { &hf_bssgp_no_of_oct,
6676 { "Number of octets transferred or deleted", "bssgp.no_of_oct",
6677 FT_UINT24, BASE_DEC, NULL, 0x00,
6678 NULL, HFILL }
6680 { &hf_bssgp_unit_val,
6681 { "Unit Value", "bssgp.unit_val",
6682 FT_UINT8, BASE_DEC, VALS(bssgp_unit_vals), 0xe0,
6683 NULL, HFILL }
6685 { &hf_bssgp_gprs_timer,
6686 { "Unit Value", "bssgp.gprs_timer",
6687 FT_UINT8, BASE_DEC, NULL, 0x1f,
6688 NULL, HFILL }
6691 { &hf_bssgp_mbms,
6692 { "MBMS Procedures", "bssgp.mbms",
6693 FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x80,
6694 NULL, HFILL }
6696 { &hf_bssgp_EnhancedRadioStatus,
6697 { "Enhanced Radio Status Procedures", "bssgp.enhancedradiostatus",
6698 FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x40,
6699 NULL, HFILL }
6701 { &hf_bssgp_pfcfc,
6702 { "PFC Flow Control Procedures", "bssgp.pfcfc",
6703 FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x20,
6704 NULL, HFILL }
6706 { &hf_bssgp_rim,
6707 { "RAN Information Management (RIM) procedures", "bssgp.rim",
6708 FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x10,
6709 NULL, HFILL }
6711 { &hf_bssgp_lcs,
6712 { "LCS Procedures", "bssgp.lcs",
6713 FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x08,
6714 NULL, HFILL }
6716 { &hf_bssgp_inr,
6717 { "Inter-NSE re-routing(INR)", "bssgp.inr",
6718 FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x04,
6719 NULL, HFILL }
6721 { &hf_bssgp_cbl,
6722 { "Current Bucket Level(CBL) Procedures", "bssgp.cbl",
6723 FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x02,
6724 NULL, HFILL }
6726 { &hf_bssgp_pfc,
6727 { "Packet Flow Context(PFC) Procedures", "bssgp.pfc",
6728 FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x01,
6729 NULL, HFILL }
6731 { &hf_bssgp_bucket_full_ratio,
6732 { "Ratio of the bucket that is filled up with data", "bssgp.bucket_full_ratio",
6733 FT_UINT8, BASE_DEC, NULL, 0x0,
6734 "B current x (100 / Bmax)", HFILL }
6736 { &hf_bssgp_b_pfc,
6737 { "B_PFC: Bucket Full Ratio of the PFC", "bssgp.b_pfc",
6738 FT_UINT8, BASE_DEC, NULL, 0x0,
6739 "B current x (100 / Bmax)", HFILL }
6742 { &hf_bssgp_precedence,
6743 { "Precedence", "bssgp.precedence",
6744 FT_UINT8, BASE_DEC, NULL, 0x07,
6745 NULL, HFILL }
6747 { &hf_bssgp_serv_utran_cco,
6748 { "Service UTRAN CCO", "bssgp.serv_utran_cco",
6749 FT_UINT8, BASE_DEC, VALS(bssgp_service_utran_cco_vals), 0x07,
6750 NULL, HFILL }
6752 { &hf_bssgp_mbms_session_id,
6753 { "MBMS Session ID", "bssgp.mbms_session_id",
6754 FT_UINT8, BASE_DEC, NULL, 0x0,
6755 NULL, HFILL }
6757 { &hf_bssgp_mbms_cause,
6758 { "Cause", "bssgp.mbms_cause",
6759 FT_UINT8, BASE_DEC|BASE_EXT_STRING, &bssgp_mbms_cause_vals_ext, 0x0f,
6760 NULL, HFILL }
6762 { &hf_bssgp_mbms_stop_cause,
6763 { "Stop Cause", "bssgp.mbms_stop_cause",
6764 FT_UINT8, BASE_DEC|BASE_EXT_STRING, &bssgp_mbms_stop_cause_vals_ext, 0x0f,
6765 NULL, HFILL }
6767 { &hf_bssgp_session_inf,
6768 { "BC/MC", "bssgp.session_inf",
6769 FT_BOOLEAN, 8, TFS(&tfs_bssgp_bc_mc), 0x01,
6770 NULL, HFILL }
6772 { &hf_bssgp_mbms_num_ra_ids,
6773 { "Number of Routing Area Identifications", "bssgp.mbms_num_ra_ids",
6774 FT_UINT8, BASE_DEC|BASE_EXT_STRING, &bssgp_mbms_num_ra_ids_vals_ext, 0xf0,
6775 NULL, HFILL }
6777 { &hf_bssgp_gb_if,
6778 { "Gigabit Interface", "bssgp.gb_if",
6779 FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x02,
6780 NULL, HFILL }
6782 { &hf_bssgp_ps_ho,
6783 { "PS Handover", "bssgp.ps_ho",
6784 FT_BOOLEAN, 8, TFS(&tfs_supported_not_supported), 0x01,
6785 NULL, HFILL }
6787 { &hf_bssgp_src_to_trg_transp_cont,
6788 { "Source to Target Transparent Container", "bssgp.src_to_trg_transp_cont",
6789 FT_BYTES, FT_NONE, NULL, 0x0,
6790 NULL, HFILL }
6792 { &hf_bssgp_trg_to_src_transp_cont,
6793 { "Target to Source Transparent Container", "bssgp.trg_to_src_transp_cont",
6794 FT_BYTES, FT_NONE, NULL, 0x0,
6795 NULL, HFILL }
6797 { &hf_bssgp_rnc_id,
6798 { "RNC ID", "bssgp.rnc_id",
6799 FT_UINT16, BASE_DEC, NULL, 0x0,
6800 NULL, HFILL }
6802 { &hf_bssgp_page_mode,
6803 { "PAGE_MODE", "bssgp.page_mode",
6804 FT_UINT8, BASE_DEC, VALS(bssgp_page_mode_vals), 0x03,
6805 NULL, HFILL }
6807 { &hf_bssgp_container_id,
6808 { "Container ID", "bssgp.container_id",
6809 FT_UINT8, BASE_DEC, NULL, 0x03,
6810 NULL, HFILL }
6812 { &hf_bssgp_global_tfi,
6813 { "Global TFI", "bssgp.global_tfi",
6814 FT_UINT8, BASE_DEC, VALS(bssgp_global_tfi_vals), 0x0,
6815 NULL, HFILL }
6817 { &hf_bssgp_ul_tfi,
6818 { "UPLINK_TFI", "bssgp.ul_tfi",
6819 FT_UINT8, BASE_DEC, NULL, 0x0,
6820 NULL, HFILL }
6822 { &hf_bssgp_dl_tfi,
6823 { "DOWNLINK_TFI", "bssgp.dl_tfi",
6824 FT_UINT8, BASE_DEC, NULL, 0x0,
6825 NULL, HFILL }
6827 { &hf_bssgp_time_to_MBMS_data_tran,
6828 { "Time to MBMS Data Transfer", "bssgp.time_to_mbms_data_tran",
6829 FT_UINT8, BASE_DEC, NULL, 0x0,
6830 NULL, HFILL }
6832 { &hf_bssgp_mbms_session_rep_no,
6833 { "MBMS-Session-Repetition-Number", "bssgp.mbms_session_rep_no",
6834 FT_UINT8, BASE_DEC, NULL, 0x0,
6835 NULL, HFILL }
6837 { &hf_bssgp_ps_ho_cmd,
6838 { "PS Handover Command", "bssgp.ps_ho_cmd",
6839 FT_BYTES, BASE_NONE, NULL, 0x0,
6840 NULL, HFILL }
6842 { &hf_bssgp_sipsi,
6843 { "SI/PSI", "bssgp.sipsi",
6844 FT_BOOLEAN, 8, TFS(&tfs_requested_not_requested), 0x01,
6845 NULL, HFILL }
6847 { &hf_bssgp_type,
6848 { "Type", "bssgp.type",
6849 FT_UINT8, BASE_DEC, VALS(type_vals), 0x01,
6850 NULL, HFILL }
6852 { &hf_bssgp_cs_indication,
6853 { "CS Indication Contents", "bssgp.cs_indication",
6854 FT_UINT8, BASE_HEX, NULL, 0x0,
6855 NULL, HFILL }
6858 { &hf_bssgp_flow_control_gran,
6859 { "Granularity", "bssgp.flow_control_gran",
6860 FT_UINT8, BASE_DEC, VALS(bssgp_flow_control_gran_vals), 0x03,
6861 NULL, HFILL }
6863 { &hf_bssgp_serv_eutran_cco,
6864 { "Service EUTRAN CCO", "bssgp.serv_eutran_cco",
6865 FT_UINT8, BASE_DEC, VALS(bssgp_service_eutran_cco_vals), 0x18,
6866 NULL, HFILL }
6868 { &hf_bssgp_sub_prof_id_f_rat_freq_prio,
6869 { "Subscriber Profile ID for RAT/Frequency priority", "bssgp.sub_prof_id_f_rat_freq_prio",
6870 FT_UINT8, BASE_DEC, NULL, 0x0,
6871 NULL, HFILL }
6873 { &hf_bssgp_eutran_irat_ho_inf_req,
6874 { "E-UTRAN Inter RAT Handover Info", "bssgp.eutran_irat_ho_inf_req",
6875 FT_BOOLEAN, 8, TFS(&tfs_requested_not_requested), 0x02,
6876 NULL, HFILL }
6878 { &hf_bssgp_irat_ho_inf_req,
6879 { "Inter RAT Handover Info", "bssgp.irat_ho_inf_req",
6880 FT_BOOLEAN, 8, TFS(&tfs_requested_not_requested), 0x01,
6881 NULL, HFILL }
6884 { &hf_bssgp_rel_int_rat_ho_inf_ind,
6885 { "Inter RAT Handover Info", "bssgp.rel_int_rat_ho_inf_ind",
6886 FT_BOOLEAN, 8, TFS(&tfs_reliable_not_reliable), 0x01,
6887 NULL, HFILL }
6889 { &hf_bssgp_csg_id,
6890 { "CSG Identity (CSG-ID)", "bssgp.csg_id",
6891 FT_UINT32, BASE_HEX, NULL, 0xffffff0f,
6892 NULL, HFILL }
6894 { &hf_bssgp_cell_acc_mode,
6895 { "Cell Access Mode", "bssgp.cell_acc_mode",
6896 FT_UINT8, BASE_DEC, VALS(bssgp_cell_access_mode_vals), 0x01,
6897 NULL, HFILL }
6899 { &hf_bssgp_redir_complete_outcome,
6900 { "Outcome Value", "bssgp.redir_complete_outcome",
6901 FT_UINT8, BASE_HEX, VALS(bssgp_redir_complete_outcome_vals), 0x0,
6902 NULL, HFILL }
6904 { &hf_bssgp_redir_indiction_reroute_reject_cause,
6905 { "Reroute Reject Cause Value", "bssgp.redir_indiction_reroute_reject_cause",
6906 FT_UINT8, BASE_HEX, VALS(bssgp_redir_indiction_reroute_reject_cause_vals), 0x0,
6907 NULL, HFILL }
6909 { &hf_bssgp_unconfim_send_state_var,
6910 { "Unconfirmed Send State Variable V(U)", "bssgp.unconfim_send_state_var",
6911 FT_UINT16, BASE_DEC, NULL, 0x01ff,
6912 NULL, HFILL }
6914 { &hf_bssgp_Global_ENB_ID_PDU,
6915 { "Global-ENB-ID", "bssgp.Global_ENB_ID",
6916 FT_NONE, BASE_NONE, NULL, 0,
6917 NULL, HFILL }
6919 { &hf_bssgp_SONtransferRequestContainer_PDU,
6920 { "SONtransferRequestContainer", "bssgp.SONtransferRequestContainer",
6921 FT_UINT32, BASE_DEC, VALS(s1ap_SONtransferRequestContainer_vals), 0,
6922 NULL, HFILL }},
6924 { &hf_bssgp_selected_plmn_id,
6925 { "Selected PLMN ID", "bssgp.selected_plmn_id",
6926 FT_STRING, BASE_NONE, NULL, 0,
6927 NULL, HFILL }},
6930 /* Setup protocol subtree array */
6931 #define NUM_INDIVIDUAL_ELEMS 10
6932 gint *ett[NUM_INDIVIDUAL_ELEMS +
6933 NUM_BSSGP_ELEM +
6934 NUM_BSSGP_MSG];
6936 static ei_register_info ei[] = {
6937 { &ei_bssgp_extraneous_data, { "bssgp.extraneous_data", PI_PROTOCOL, PI_NOTE, "Extraneous Data, dissector bug or later version spec(report to wireshark.org)", EXPFILL }},
6940 expert_module_t* expert_bssgp;
6942 ett[0] = &ett_bssgp;
6943 ett[1] = &ett_bssgp_list_of_setup_pfcs;
6944 ett[2] = &ett_bssgp_pfcs_to_be_set_up_list_t10;
6945 ett[3] = &ett_bssgp_pfcs_to_be_set_up_list_arp;
6946 ett[4] = &ett_bssgp_pfcs_to_be_set_up_list_abqp;
6947 ett[5] = &ett_bssgp_pfcs_to_be_set_up_list_pft;
6948 ett[6] = &ett_bssgp_pfcs_to_be_set_up_list;
6949 ett[7] = &ett_bssgp_new;
6950 ett[8] = &ett_bssgp_pfc_flow_control_parameters_pfc;
6951 ett[9] = &ett_bssgp_ra_id,
6953 last_offset = NUM_INDIVIDUAL_ELEMS;
6955 for (i=0; i < NUM_BSSGP_ELEM; i++, last_offset++)
6957 ett_bssgp_elem[i] = -1;
6958 ett[last_offset] = &ett_bssgp_elem[i];
6961 for (i=0; i < NUM_BSSGP_MSG; i++, last_offset++)
6963 ett_bssgp_msg[i] = -1;
6964 ett[last_offset] = &ett_bssgp_msg[i];
6967 /* Register the protocol name and description */
6968 proto_bssgp = proto_register_protocol("Base Station Subsystem GPRS Protocol", "BSSGP", "bssgp");
6970 /* Required function calls to register the header fields and subtrees used */
6971 proto_register_field_array(proto_bssgp, hf, array_length(hf));
6972 proto_register_subtree_array(ett, array_length(ett));
6973 expert_bssgp = expert_register_protocol(proto_bssgp);
6974 expert_register_field_array(expert_bssgp, ei, array_length(ei));
6975 register_dissector("bssgp", dissect_bssgp, proto_bssgp);
6977 /* Register configuration options */
6978 bssgp_module = prefs_register_protocol(proto_bssgp, NULL);
6979 prefs_register_bool_preference(bssgp_module, "decode_nri",
6980 "Decode NRI",
6981 "Decode NRI (for use with SGSN in Pool)",
6982 &bssgp_decode_nri);
6983 prefs_register_uint_preference(bssgp_module, "nri_length", "NRI length",
6984 "NRI length, in bits",
6985 10, &bssgp_nri_length);
6988 /* If this dissector uses sub-dissector registration add a registration routine.
6990 void
6991 proto_reg_handoff_bssgp(void)
6993 llc_handle = find_dissector("llcgprs");
6994 rrlp_handle = find_dissector("rrlp");
6995 data_handle = find_dissector("data");
6997 diameter_3gpp_avp_dissector_table = find_dissector_table("diameter.3gpp");