### Bug Summary

File: | builds/wireshark/wireshark/epan/dissectors/packet-gsm_a_bssmap.c
Warning: | line 3281, column 9 Value stored to 'curr_offset' is never read

### Annotated Source Code

Press '?' to see keyboard shortcuts

Show analyzer invocation
clang -cc1 -cc1 -triple x86_64-pc-linux-gnu -analyze -disable-free -clear-ast-before-backend -disable-llvm-verifier -discard-value-names -main-file-name packet-gsm_a_bssmap.c -analyzer-checker=core -analyzer-checker=apiModeling -analyzer-checker=unix -analyzer-checker=deadcode -analyzer-checker=security.insecureAPI.UncheckedReturn -analyzer-checker=security.insecureAPI.getpw -analyzer-checker=security.insecureAPI.gets -analyzer-checker=security.insecureAPI.mktemp -analyzer-checker=security.insecureAPI.mkstemp -analyzer-checker=security.insecureAPI.vfork -analyzer-checker=nullability.NullPassedToNonnull -analyzer-checker=nullability.NullReturnedFromNonnull -analyzer-output plist -w -setup-static-analyzer -mrelocation-model pic -pic-level 2 -fhalf-no-semantic-interposition -fno-delete-null-pointer-checks -mframe-pointer=all -relaxed-aliasing -fmath-errno -ffp-contract=on -fno-rounding-math -ffloat16-excess-precision=fast -fbfloat16-excess-precision=fast -mconstructor-aliases -funwind-tables=2 -target-cpu x86-64 -tune-cpu generic -debugger-tuning=gdb -fdebug-compilation-dir=/builds/wireshark/wireshark/build -fcoverage-compilation-dir=/builds/wireshark/wireshark/build -resource-dir /usr/lib/llvm-22/lib/clang/22 -isystem /usr/include/glib-2.0 -isystem /usr/lib/x86_64-linux-gnu/glib-2.0/include -isystem /builds/wireshark/wireshark/epan/dissectors -isystem /builds/wireshark/wireshark/build/epan/dissectors -isystem /usr/include/mit-krb5 -isystem /usr/include/libxml2 -isystem /builds/wireshark/wireshark/epan -D CARES_NO_DEPRECATED -D G_DISABLE_DEPRECATED -D G_DISABLE_SINGLE_INCLUDES -D WS_BUILD_DLL -D WS_DEBUG -D WS_DEBUG_UTF_8 -I /builds/wireshark/wireshark/build -I /builds/wireshark/wireshark -I /builds/wireshark/wireshark/include -D _GLIBCXX_ASSERTIONS -internal-isystem /usr/lib/llvm-22/lib/clang/22/include -internal-isystem /usr/local/include -internal-isystem /usr/lib/gcc/x86_64-linux-gnu/16/../../../../x86_64-linux-gnu/include -internal-externc-isystem /usr/include/x86_64-linux-gnu -internal-externc-isystem /include -internal-externc-isystem /usr/include -fmacro-prefix-map=/builds/wireshark/wireshark/= -fmacro-prefix-map=/builds/wireshark/wireshark/build/= -fmacro-prefix-map=../= -Wno-format-nonliteral -std=gnu17 -ferror-limit 19 -fvisibility=hidden -fwrapv -fwrapv-pointer -fstrict-flex-arrays=3 -stack-protector 2 -fstack-clash-protection -fcf-protection=full -fgnuc-version=4.2.1 -fskip-odr-check-in-gmf -fexceptions -fcolor-diagnostics -analyzer-output=html -faddrsig -fdwarf2-cfi-asm -o /builds/wireshark/wireshark/sbout/2026-08-17-100402-3660-1 -x c /builds/wireshark/wireshark/epan/dissectors/packet-gsm_a_bssmap.c

Keyboard shortcuts:

- Use 'j/k' keys for keyboard navigation
- Use 'Shift+S' to show/hide relevant lines
- Use '?' to toggle this window

Close
Show only relevant lines Show control flow arrows

1 | /* packet-gsm_a_bssmap.c
2 | * Routines for GSM A Interface BSSMAP dissection
3 | *
4 | * Copyright 2003, Michael Lum <mlum [AT] telostech.com>
5 | * In association with Telos Technology Inc.
6 | *
7 | * Updated to 3GPP TS 48.008 version 9.8.0 Release 9
8 | * Copyright 2008, Anders Broman <anders.broman [at] ericsson.com
9 | * Copyright 2012, Pascal Quantin <pascal.quantin [at] gmail.com
10 | * Title 3GPP Other
11 | *
12 | * Reference [2]
13 | * Mobile-services Switching Centre - Base Station System
14 | * (MSC - BSS) interface;
15 | * Layer 3 specification
16 | * (GSM 08.08 version 7.7.0 Release 1998) TS 100 590 v7.7.0
17 | * 3GPP TS 48.008 version 8.4.0 Release 8
18 | * 3GPP TS 48.008 version 9.8.0 Release 9
19 | *
20 | * Wireshark - Network traffic analyzer
21 | * By Gerald Combs <gerald@wireshark.org>
22 | * Copyright 1998 Gerald Combs
23 | *
24 | * SPDX-License-Identifier: GPL-2.0-or-later
25 | */
26 |
27 | #include "config.h"
28 |
29 | #include <epan/packet.h>
30 | #include <epan/tap.h>
31 | #include <epan/expert.h>
32 | #include <epan/asn1.h>
33 | #include <epan/tfs.h>
34 |
35 | #include <wsutil/str_util.h>
36 | #include <wsutil/array.h>
37 |
38 | #include "packet-bssgp.h"
39 | #include "packet-gsm_a_common.h"
40 | #include "packet-e212.h"
41 | #include "packet-ranap.h"
42 | #include "packet-rrc.h"
43 | #include "packet-rtcp.h"
44 | #include "packet-rtp.h"
45 | #include "packet-gsm_map.h"
46 | #include "packet-bicc_mst.h"
47 | #include "packet-s1ap.h"
48 |
49 | void proto_register_gsm_a_bssmap(void);
50 | void proto_reg_handoff_gsm_a_bssmap(void);
51 |
52 | /* PROTOTYPES/FORWARDS */
53 |
54 | /* TS 48.008 3.2.2.1 Message Type */
55 | const value_string gsm_a_bssmap_msg_strings[] = {
56 | { 0x01, "Assignment Request" },
57 | { 0x02, "Assignment Complete" },
58 | { 0x03, "Assignment Failure" },
59 | { 0x04, "VGCS/VBS Setup" },
60 | { 0x05, "VGCS/VBS Setup Ack" },
61 | { 0x06, "VGCS/VBS Setup Refuse" },
62 | { 0x07, "VGCS/VBS Assignment Request" },
63 | { 0x08, "Channel Modify request" },
64 |
65 | { 0x09, "Unallocated" },
66 | { 0x0a, "Unallocated" },
67 | { 0x0b, "Unallocated" },
68 | { 0x0c, "Unallocated" },
69 | { 0x0d, "Unallocated" },
70 | { 0x0e, "Unallocated" },
71 | { 0x0f, "Unallocated" },
72 |
73 | { 0x10, "Handover Request" },
74 | { 0x11, "Handover Required" },
75 | { 0x12, "Handover Request Acknowledge" },
76 | { 0x13, "Handover Command" },
77 | { 0x14, "Handover Complete" },
78 | { 0x15, "Handover Succeeded" },
79 | { 0x16, "Handover Failure" },
80 | { 0x17, "Handover Performed" },
81 | { 0x18, "Handover Candidate Enquire" },
82 | { 0x19, "Handover Candidate Response" },
83 | { 0x1a, "Handover Required Reject" },
84 | { 0x1b, "Handover Detect" },
85 | { 0x1c, "VGCS/VBS Assignment Result" },
86 | { 0x1d, "VGCS/VBS Assignment Failure" },
87 | { 0x1e, "VGCS/VBS Queuing Indication" },
88 | { 0x1f, "Uplink Request" },
89 | { 0x20, "Clear Command" },
90 | { 0x21, "Clear Complete" },
91 | { 0x22, "Clear Request" },
92 | { 0x23, "Reserved" },
93 | { 0x24, "Reserved" },
94 | { 0x25, "SAPI 'n' Reject" },
95 | { 0x26, "Confusion" },
96 | { 0x27, "Uplink Request Acknowledge" },
97 | { 0x28, "Suspend" },
98 | { 0x29, "Resume" },
99 | /* This value (2a) was allocated in an earlier phase of the protocol and shall not be used in the future. */
100 | { 0x2a, "Connection Oriented Information(Obsolete)" },
101 | { 0x2b, "Perform Location Request" },
102 | { 0x2c, "LSA Information" },
103 | { 0x2d, "Perform Location Response" },
104 | { 0x2e, "Perform Location Abort" },
105 | { 0x2f, "Common Id" },
106 | { 0x30, "Reset" },
107 | { 0x31, "Reset Acknowledge" },
108 | { 0x32, "Overload" },
109 | { 0x33, "Reserved" },
110 | { 0x34, "Reset Circuit" },
111 | { 0x35, "Reset Circuit Acknowledge" },
112 | { 0x36, "MSC Invoke Trace" },
113 | { 0x37, "BSS Invoke Trace" },
114 |
115 | { 0x38, "Unallocated" },
116 | { 0x39, "Unallocated" },
117 |
118 | { 0x3a, "Connectionless Information" },
119 | { 0x3b, "VGCS/VBS Assignment Status" },
120 | { 0x3c, "VGCS/VBS Area Cell Info" },
121 | { 0x3d, "Reset IP Resource" },
122 | { 0x3e, "Reset IP Resource Acknowledge" },
123 |
124 | { 0x3f, "Unallocated" },
125 |
126 | { 0x40, "Block" },
127 | { 0x41, "Blocking Acknowledge" },
128 | { 0x42, "Unblock" },
129 | { 0x43, "Unblocking Acknowledge" },
130 | { 0x44, "Circuit Group Block" },
131 | { 0x45, "Circuit Group Blocking Acknowledge" },
132 | { 0x46, "Circuit Group Unblock" },
133 | { 0x47, "Circuit Group Unblocking Acknowledge" },
134 | { 0x48, "Unequipped Circuit" },
135 | { 0x49, "Uplink Request Confirmation" },
136 | { 0x4a, "Uplink Release Indication" },
137 | { 0x4b, "Uplink Reject Command" },
138 | { 0x4c, "Uplink Release Command" },
139 | { 0x4d, "Uplink Seized Command" },
140 | { 0x4e, "Change Circuit" },
141 | { 0x4f, "Change Circuit Acknowledge" },
142 | { 0x50, "Resource Request" },
143 | { 0x51, "Resource Indication" },
144 | { 0x52, "Paging" },
145 | { 0x53, "Cipher Mode Command" },
146 | { 0x54, "Classmark Update" },
147 | { 0x55, "Cipher Mode Complete" },
148 | { 0x56, "Queuing Indication" },
149 | { 0x57, "Complete Layer 3 Information" },
150 | { 0x58, "Classmark Request" },
151 | { 0x59, "Cipher Mode Reject" },
152 | { 0x5a, "Load Indication" },
153 |
154 | { 0x5b, "Unallocated" },
155 | { 0x5c, "Unallocated" },
156 | { 0x5d, "Unallocated" },
157 | { 0x5e, "Unallocated" },
158 | { 0x5f, "Unallocated" },
159 |
160 | { 0x60, "VGCS Additional Information" },
161 | { 0x61, "VGCS SMS" },
162 | { 0x62, "Notification Data" },
163 | { 0x63, "Uplink Application Data" },
164 |
165 | { 0x64, "Unallocated" },
166 | { 0x65, "Unallocated" },
167 | { 0x66, "Unallocated" },
168 | { 0x67, "Unallocated" },
169 | { 0x68, "Unallocated" },
170 | { 0x69, "Unallocated" },
171 | { 0x6a, "Unallocated" },
172 | { 0x6b, "Unallocated" },
173 | { 0x6c, "Unallocated" },
174 | { 0x6d, "Unallocated" },
175 | { 0x6e, "Unallocated" },
176 | { 0x6f, "Unallocated" },
177 |
178 | { 0x70, "Internal Handover Required" },
179 | { 0x71, "Internal Handover Required Reject" },
180 | { 0x72, "Internal Handover Command" },
181 | { 0x73, "Internal Handover Enquiry" },
182 | { 0x74, "LCLS-Connect-Control" },
183 | { 0x75, "LCLS-Connect-Control-Ack" },
184 | { 0x76, "LCLS-Notification" },
185 | { 0x77, "Unallocated" },
186 | { 0x78, "Reroute Command" },
187 | { 0x79, "Reroute Complete" },
188 | { 0, NULL((void*)0) }
189 | };
190 |
191 | static value_string_ext gsm_a_bssmap_msg_strings_ext = VALUE_STRING_EXT_INIT(gsm_a_bssmap_msg_strings){ _try_val_to_str_ext_init, 0, (sizeof (gsm_a_bssmap_msg_strings ) / sizeof ((gsm_a_bssmap_msg_strings)[0]))-1, gsm_a_bssmap_msg_strings , "gsm_a_bssmap_msg_strings", ((void*)0) };
192 |
193 | static const value_string gsm_bssmap_elem_strings[] = {
194 | { BE_UDEF_0, "Undefined" },
195 | { BE_CIC, "Circuit Identity Code" },
196 | { BE_RSVD_1, "Reserved" },
197 | { BE_RES_AVAIL, "Resource Available" },
198 | { BE_CAUSE, "Cause" },
199 | { BE_CELL_ID, "Cell Identifier" },
200 | { BE_PRIO, "Priority" },
201 | { BE_L3_HEADER_INFO, "Layer 3 Header Information" },
202 | { BE_IMSI, "IMSI" },
203 | { BE_TMSI, "TMSI" },
204 | { BE_ENC_INFO, "Encryption Information" },
205 | { BE_CHAN_TYPE, "Channel Type" },
206 | { BE_PERIODICITY, "Periodicity" },
207 | { BE_EXT_RES_IND, "Extended Resource Indicator" },
208 | { BE_NUM_MS, "Number Of MSs" },
209 | { BE_RSVD_2, "Reserved" },
210 | { BE_RSVD_3, "Reserved" },
211 | { BE_RSVD_4, "Reserved" },
212 | { BE_CM_INFO_2, "Classmark Information Type 2" },
213 | { BE_CM_INFO_3, "Classmark Information Type 3" },
214 | { BE_INT_BAND, "Interference Band To Be Used" },
215 | { BE_RR_CAUSE, "RR Cause" },
216 | { BE_RSVD_5, "Reserved" },
217 | { BE_L3_INFO, "Layer 3 Information" },
218 | { BE_DLCI, "DLCI" },
219 | { BE_DOWN_DTX_FLAG, "Downlink DTX Flag" },
220 | { BE_CELL_ID_LIST, "Cell Identifier List" },
221 | { BE_RESP_REQ, "Response Request" },
222 | { BE_RES_IND_METHOD, "Resource Indication Method" },
223 | { BE_CM_INFO_1, "Classmark Information Type 1" },
224 | { BE_CIC_LIST, "Circuit Identity Code List" },
225 | { BE_DIAG, "Diagnostic" },
226 | { BE_L3_MSG, "Layer 3 Message Contents" },
227 | { BE_CHOSEN_CHAN, "Chosen Channel" },
228 | { BE_TOT_RES_ACC, "Total Resource Accessible" },
229 | { BE_CIPH_RESP_MODE, "Cipher Response Mode" },
230 | { BE_CHAN_NEEDED, "Channel Needed" },
231 | { BE_TRACE_TYPE, "Trace Type" },
232 | { BE_TRIGGERID, "TriggerID" },
233 | { BE_TRACE_REF, "Trace Reference" },
234 | { BE_TRANSID, "TransactionID" },
235 | { BE_MID, "Mobile Identity" },
236 | { BE_OMCID, "OMCID" },
237 | { BE_FOR_IND, "Forward Indicator" },
238 | { BE_CHOSEN_ENC_ALG, "Chosen Encryption Algorithm" },
239 | { BE_CCT_POOL, "Circuit Pool" },
240 | { BE_CCT_POOL_LIST, "Circuit Pool List" },
241 | { BE_TIME_IND, "Time Indication" },
242 | { BE_RES_SIT, "Resource Situation" },
243 | { BE_CURR_CHAN_1, "Current Channel Type 1" },
244 | { BE_QUE_IND, "Queuing Indicator" },
245 | { BE_ASS_REQ, "Assignment Requirement" },
246 | { BE_UDEF_52, "Undefined" },
247 | { BE_TALKER_FLAG, "Talker Flag" },
248 | { BE_CONN_REL_REQ, "Connection Release Requested" },
249 | { BE_GROUP_CALL_REF, "Group Call Reference" },
250 | { BE_EMLPP_PRIO, "eMLPP Priority" },
251 | { BE_CONF_EVO_IND, "Configuration Evolution Indication" },
252 | { BE_OLD2NEW_INFO, "Old BSS to New BSS Information" },
253 | { BE_LSA_ID, "LSA Identifier" },
254 | { BE_LSA_ID_LIST, "LSA Identifier List" },
255 | { BE_LSA_INFO, "LSA Information" },
256 | { BE_LCS_QOS, "LCS QoS" },
257 | { BE_LSA_ACC_CTRL, "LSA access control suppression" },
258 | { BE_SPEECH_VER, "Speech Version" },
259 | { BE_UDEF_65, "Undefined" },
260 | { BE_UDEF_66, "Undefined" },
261 | { BE_LCS_PRIO, "LCS Priority" },
262 | { BE_LOC_TYPE, "Location Type" },
263 | { BE_LOC_EST, "Location Estimate" },
264 | { BE_POS_DATA, "Positioning Data" },
265 | { BE_LCS_CAUSE, "LCS Cause" },
266 | { BE_LCS_CLIENT, "LCS Client Type" },
267 | { BE_APDU, "APDU" },
268 | { BE_NE_ID, "Network Element Identity" },
269 | { BE_GPS_ASSIST_DATA, "GPS Assistance Data" },
270 | { BE_DECIPH_KEYS, "Deciphering Keys" },
271 | { BE_RET_ERR_REQ, "Return Error Request" },
272 | { BE_RET_ERR_CAUSE, "Return Error Cause" },
273 | { BE_SEG, "Segmentation" },
274 | { BE_SERV_HO, "Service Handover" },
275 | { BE_SRC_RNC_TO_TAR_RNC_UMTS, "Source RNC to target RNC transparent information (UMTS)" },
276 | { BE_SRC_RNC_TO_TAR_RNC_CDMA, "Source RNC to target RNC transparent information (cdma2000)" },
277 | { BE_GERAN_CLS_M, "GERAN Classmark" },
278 | { BE_GERAN_BSC_CONT, "GERAN BSC Container" },
279 | { BE_VEL_EST, "Velocity Estimate" },
280 | { BE_UDEF_86, "Undefined" },
281 | { BE_UDEF_87, "Undefined" },
282 | { BE_UDEF_88, "Undefined" },
283 | { BE_UDEF_89, "Undefined" },
284 | { BE_UDEF_90, "Undefined" },
285 | { BE_UDEF_91, "Undefined" },
286 | { BE_UDEF_92, "Undefined" },
287 | { BE_UDEF_93, "Undefined" },
288 | { BE_UDEF_94, "Undefined" },
289 | { BE_UDEF_95, "Undefined" },
290 | { BE_UDEF_96, "Undefined" },
291 | { BE_NEW_BSS_TO_OLD_BSS_INF, "New BSS to Old BSS Information" },
292 | { BE_UDEF_98, "Undefined" },
293 | { BE_INTER_SYS_INF, "Inter-System Information" },
294 | { BE_SNA_ACC_INF, "SNA Access Information" },
295 | { BE_VSTK_RAND_INF, "VSTK_RAND Information" },
296 | { BE_VSTK_INF, "VSTK Information" },
297 | { BE_PAGING_INF, "Paging Information" },
298 | { BE_IMEI, "IMEI" },
299 | { BE_VGCS_FEAT_FLG, "VGCS Feature Flags" },
300 | { BE_TALKER_PRI, "Talker Priority" },
301 | { BE_EMRG_SET_IND, "Emergency Set Indication" },
302 | { BE_TALKER_ID, "Talker Identity" },
303 | { BE_CELL_ID_LIST_SEG, "Cell Identifier List Segment" },
304 | { BE_SMS_TO_VGCS, "SMS to VGCS" },
305 | { BE_VGCS_TALKER_MOD, "VGCS Talker Mode" },
306 | { BE_VGS_VBS_CELL_STAT, "VGCS/VBS Cell Status" },
307 | { BE_CELL_ID_LST_SEG_F_EST_CELLS, "Cell Identifier List Segment for established cells" },
308 | { BE_CELL_ID_LST_SEG_F_CELL_TB_EST, "Cell Identifier List Segment for cells to be established" },
309 | { BE_CELL_ID_LST_SEG_F_REL_CELL, "Cell Identifier List Segment for released cells - no user present" },
310 | { BE_CELL_ID_LST_SEG_F_NOT_EST_CELL, "Cell Identifier List Segment for not established cells - no establishment possible" },
311 | { BE_GANSS_ASS_DTA, "GANSS Assistance Data" },
312 | { BE_GANSS_POS_DTA, "GANSS Positioning Data" },
313 | { BE_GANSS_LOC_TYP, "GANSS Location Type" },
314 | { BE_APP_DATA, "Application Data" },
315 | { BE_DATA_ID, "Data Identity" },
316 | { BE_APP_DATA_INF, "Application Data Information" },
317 | { BE_MSISDN, "MSISDN" },
318 | { BE_AOIP_TRANS_LAY_ADD, "AoIP Transport Layer Address" },
319 | { BE_SPEECH_CODEC_LST, "Speech Codec List" },
320 | { BE_SPEECH_CODEC, "Speech Codec" },
321 | { BE_CALL_ID, "Call Identifier" },
322 | { BE_CALL_ID_LST, "Call Identifier List" },
323 | { BE_A_ITF_SEL_FOR_RESET, "A-Interface Selector for RESET" },
324 | { BE_UDEF_130, "Undefined" },
325 | { BE_KC128, "Kc128" },
326 | { BE_CSG_ID, "CSG Identifier" },
327 | { BE_REDIR_ATT_FLG, "Redirect Attempt Flag" }, /* 3.2.2.111 */
328 | { BE_REROUTE_REJ_CAUSE, "Reroute Reject Cause" }, /* 3.2.2.112 */
329 | { BE_SEND_SEQN, "Send Sequence Number" }, /* 3.2.2.113 */
330 | { BE_REROUTE_OUTCOME, "Reroute complete outcome" }, /* 3.2.2.114 */
331 | { BE_GLOBAL_CALL_REF, "Global Call Reference" }, /* 3.2.2.115 */
332 | { BE_LCLS_CONF, "LCLS-Configuration" }, /* 3.2.2.116 */
333 | { BE_LCLS_CON_STATUS_CONTROL, "LCLS-Connection-Status-Control" }, /* 3.2.2.117 */
334 | { BE_LCLS_CORR_NOT_NEEDED, "LCLS-Correlation-Not-Needed" }, /* 3.2.2.118 */
335 | { BE_LCLS_BSS_STATUS, "LCLS-BSS-Status" }, /* 3.2.2.119 */
336 | { BE_LCLS_BREAK_REQ, "LCLS-Break-Request" }, /* 3.2.2.120 */
337 | { BE_CSFB_IND, "CSFB Indication" }, /* 3.2.2.121 */
338 | { BE_CS_TO_PS_SRVCC, "CS to PS SRVCC" }, /* 3.2.2.122 */
339 | { BE_SRC_ENB_2_TGT_ENB_TRANSP_INF, "Source eNB to target eNB transparent information (E-UTRAN)" }, /* 3.2.2.123 */
340 | { BE_CS_TO_PS_SRVCC_IND, "CS to PS SRVCC Indication" }, /* 3.2.2.124 */
341 | { BE_CN_TO_MS_TRANSP, "CN to MS transparent information" }, /* 3.2.2.125 */
342 | { BE_SELECTED_PLMN_ID, "Selected PLMN ID" }, /* 3.2.2.126 */
343 | { BE_LAST_USED_E_UTRAN_PLMN_ID, "Last used E-UTRAN PLMN ID" }, /* 3.2.2.127 */
344 | { BE_UDEF_150, "Undefined" },
345 | { BE_UDEF_151, "Undefined" },
346 | { BE_UDEF_152, "Undefined" },
347 | { BE_UDEF_153, "Undefined" },
348 | { BE_UDEF_154, "Undefined" },
349 | { BE_UDEF_155, "Undefined" },
350 | { BE_UDEF_156, "Undefined" },
351 | { BE_UDEF_157, "Undefined" },
352 | { BE_UDEF_158, "Undefined" },
353 | { BE_UDEF_159, "Undefined" },
354 | { BE_UDEF_160, "Undefined" },
355 | { BE_UDEF_161, "Undefined" },
356 | { BE_UDEF_162, "Undefined" },
357 | { BE_UDEF_163, "Undefined" },
358 | { BE_UDEF_164, "Undefined" },
359 | { BE_UDEF_165, "Undefined" },
360 | { BE_UDEF_166, "Undefined" },
361 | { BE_UDEF_167, "Undefined" },
362 | { BE_UDEF_168, "Undefined" },
363 | { BE_UDEF_169, "Undefined" },
364 | { BE_UDEF_170, "Undefined" },
365 | { BE_UDEF_171, "Undefined" },
366 | { BE_UDEF_172, "Undefined" },
367 | { BE_UDEF_173, "Undefined" },
368 | { BE_UDEF_174, "Undefined" },
369 | { BE_UDEF_175, "Undefined" },
370 | { BE_UDEF_176, "Undefined" },
371 | { BE_UDEF_177, "Undefined" },
372 | { BE_UDEF_178, "Undefined" },
373 | { BE_UDEF_179, "Undefined" },
374 | { BE_UDEF_180, "Undefined" },
375 | { BE_UDEF_181, "Undefined" },
376 | { BE_UDEF_182, "Undefined" },
377 | { BE_UDEF_183, "Undefined" },
378 | { BE_UDEF_184, "Undefined" },
379 | { BE_UDEF_185, "Undefined" },
380 | { BE_UDEF_186, "Undefined" },
381 | { BE_UDEF_187, "Undefined" },
382 | { BE_UDEF_188, "Undefined" },
383 | { BE_UDEF_189, "Undefined" },
384 | { BE_UDEF_190, "Undefined" },
385 | { BE_UDEF_191, "Undefined" },
386 | { BE_UDEF_192, "Undefined" },
387 | { BE_UDEF_193, "Undefined" },
388 | { BE_UDEF_194, "Undefined" },
389 | { BE_UDEF_195, "Undefined" },
390 | { BE_UDEF_196, "Undefined" },
391 | { BE_UDEF_197, "Undefined" },
392 | { BE_UDEF_198, "Undefined" },
393 | { BE_UDEF_199, "Undefined" },
394 | { BE_UDEF_200, "Undefined" },
395 | { BE_UDEF_201, "Undefined" },
396 | { BE_UDEF_202, "Undefined" },
397 | { BE_UDEF_203, "Undefined" },
398 | { BE_UDEF_204, "Undefined" },
399 | { BE_UDEF_205, "Undefined" },
400 | { BE_UDEF_206, "Undefined" },
401 | { BE_UDEF_207, "Undefined" },
402 | { BE_UDEF_208, "Undefined" },
403 | { BE_UDEF_209, "Undefined" },
404 | { BE_UDEF_210, "Undefined" },
405 | { BE_UDEF_211, "Undefined" },
406 | { BE_UDEF_212, "Undefined" },
407 | { BE_UDEF_213, "Undefined" },
408 | { BE_UDEF_214, "Undefined" },
409 | { BE_UDEF_215, "Undefined" },
410 | { BE_UDEF_216, "Undefined" },
411 | { BE_UDEF_217, "Undefined" },
412 | { BE_UDEF_218, "Undefined" },
413 | { BE_UDEF_219, "Undefined" },
414 | { BE_UDEF_220, "Undefined" },
415 | { BE_UDEF_221, "Undefined" },
416 | { BE_UDEF_222, "Undefined" },
417 | { BE_UDEF_223, "Undefined" },
418 | { BE_UDEF_224, "Undefined" },
419 | { BE_UDEF_225, "Undefined" },
420 | { BE_UDEF_226, "Undefined" },
421 | { BE_UDEF_227, "Undefined" },
422 | { BE_UDEF_228, "Undefined" },
423 | { BE_UDEF_229, "Undefined" },
424 | { BE_UDEF_230, "Undefined" },
425 | { BE_UDEF_231, "Undefined" },
426 | { BE_UDEF_232, "Undefined" },
427 | { BE_UDEF_233, "Undefined" },
428 | { BE_UDEF_234, "Undefined" },
429 | { BE_UDEF_235, "Undefined" },
430 | { BE_UDEF_236, "Undefined" },
431 | { BE_UDEF_237, "Undefined" },
432 | { BE_UDEF_238, "Undefined" },
433 | { BE_UDEF_239, "Undefined" },
434 | { BE_OSMOCOM_OSMUX_SUPPORT, "Osmocom extension: Osmux Support" },
435 | { BE_OSMOCOM_OSMUX_CID, "Osmocom extension: Osmux CID" },
436 | { 0, NULL((void*)0) }
437 | };
438 | value_string_ext gsm_bssmap_elem_strings_ext = VALUE_STRING_EXT_INIT(gsm_bssmap_elem_strings){ _try_val_to_str_ext_init, 0, (sizeof (gsm_bssmap_elem_strings ) / sizeof ((gsm_bssmap_elem_strings)[0]))-1, gsm_bssmap_elem_strings , "gsm_bssmap_elem_strings", ((void*)0) };
439 |
440 | /* 3.2.3 Signalling Field Element Coding */
441 | static const value_string bssmap_field_element_ids[] = {
442 |
443 | { 0x1, "BSSMAP Field Element: Extra information" }, /* 3.2.3.1 */
444 | { 0x2, "BSSMAP Field Element: Current Channel Type 2" }, /* 3.2.2.2 */
445 | { 0x3, "BSSMAP Field Element: Target cell radio information" }, /* 3.2.3.3 */
446 | { 0x4, "BSSMAP Field Element: GPRS Suspend information" }, /* 3.2.3.4 */
447 | { 0x5, "BSSMAP Field Element: MultiRate configuration information" }, /* 3.2.3.5 */
448 | { 0x6, "BSSMAP Field Element: Dual Transfer Mode information" }, /* 3.2.3.6 */
449 | { 0x7, "BSSMAP Field Element: Inter RAT Handover Info" }, /* 3.2.3.7 */
450 | /*{ 0x7, "UE Capability information" },*/ /* 3.2.3.7 */
451 | { 0x8, "BSSMAP Field Element: cdma2000 Capability Information" }, /* 3.2.3.8 */
452 | { 0x9, "BSSMAP Field Element: Downlink Cell Load Information" }, /* 3.2.3.9 */
453 | { 0xa, "BSSMAP Field Element: Uplink Cell Load Information" }, /* 3.2.3.10 */
454 | { 0xb, "BSSMAP Field Element: Cell Load Information Group" }, /* 3.2.3.11 */
455 | { 0xc, "BSSMAP Field Element: Cell Load Information" }, /* 3.2.3.12 */
456 | { 0x0d, "BSSMAP Field Element: PS Indication" }, /* 3.2.3.13 */
457 | { 0x0e, "BSSMAP Field Element: DTM Handover Command Indication" }, /* 3.2.3.14 */
458 | { 0x0f, "BSSMAP Field Element: IRAT Measurement Configuration" }, /* 3.2.3.16 */
459 | { 0x10, "BSSMAP Field Element: Source Cell ID" }, /* 3.2.3.17 */
460 | { 0x11, "BSSMAP Field Element: IRAT Measurement Configuration (extended E-ARFCNs)" }, /* 3.2.3.18 */
461 | { 0x6f, "BSSMAP Field Element: VGCS talker mode" }, /* although technically not a Field Element,
462 | this IE can appear in Old BSS to New BSS information */
463 | { 0x95, "BSSMAP Field Element: Last used E-UTRAN PLMN ID" }, /* 3.2.2.127 */
464 | { 0xfe, "BSSMAP Field Element: D-RNTI" }, /* 3.2.3.15 */
465 | { 0, NULL((void*)0) }
466 | };
467 |
468 | static const value_string bssap_cc_values[] = {
469 | { 0x0, "not further specified" },
470 | { 0x2, "FACCH or SDCCH" },
471 | { 0x3, "SACCH" },
472 | { 0, NULL((void*)0) } };
473 |
474 | static const value_string bssap_sapi_values[] = {
475 | { 0x00, "RR/MM/CC" },
476 | { 0x03, "SMS" },
477 | { 0, NULL((void*)0) } };
478 |
479 | static const value_string gsm_a_be_cell_id_disc_vals[] = {
480 | { 0, "The whole Cell Global Identification, CGI, is used to identify the cells."},
481 | { 1, "Location Area Code, LAC, and Cell Identify, CI, is used to identify the cells."},
482 | { 2, "Cell Identity, CI, is used to identify the cells."},
483 | { 3, "No cell is associated with the transaction."},
484 | { 4, "Location Area Identification, LAI, is used to identify all cells within a Location Area."},
485 | { 5, "Location Area Code, LAC, is used to identify all cells within a location area."},
486 | { 6, "All cells on the BSS are identified."},
487 | { 7, "Reserved"},
488 | { 8, "Intersystem Handover to UTRAN or cdma2000. PLMN-ID, LAC, and RNC-ID, are encoded to identify the target RNC."},
489 | { 9, "Intersystem Handover to UTRAN or cdma2000. The RNC-ID is coded to identify the target RNC."},
490 | { 10, "Intersystem Handover to UTRAN or cdma2000. LAC and RNC-ID are encoded to identify the target RNC."},
491 | { 11, "Serving Area Identity, SAI, is used to identify the Serving Area of UE within UTRAN or cdma2000"},
492 | { 12, "LAC, RNC-ID (or Extended RNC-ID) and Cell Identity, CI, is used to identify a UTRAN cell for cell load information"},
493 | { 13, "Reserved"},
494 | { 14, "Reserved"},
495 | { 15, "Reserved"},
496 | { 0, NULL((void*)0) }
497 | };
498 | static value_string_ext gsm_a_be_cell_id_disc_vals_ext = VALUE_STRING_EXT_INIT(gsm_a_be_cell_id_disc_vals){ _try_val_to_str_ext_init, 0, (sizeof (gsm_a_be_cell_id_disc_vals ) / sizeof ((gsm_a_be_cell_id_disc_vals)[0]))-1, gsm_a_be_cell_id_disc_vals , "gsm_a_be_cell_id_disc_vals", ((void*)0) };
499 |
500 | #if 0
501 | static const value_string gsm_a_rr_channel_needed_vals[] = {
502 | { 0x00, "Any channel"},
503 | { 0x01, "SDCCH"},
504 | { 0x02, "TCH/F (Full rate)"},
505 | { 0x03, "TCH/H or TCH/F (Dual rate)"},
506 | { 0, NULL((void*)0) }
507 | };
508 | #endif
509 |
510 | static const value_string bssmap_positioning_methods[] = {
511 | { 0, "Timing Advance" },
512 | { 1, "Reserved (Note)" },
513 | { 2, "Reserved (Note)" },
514 | { 3, "Mobile Assisted E-OTD" },
515 | { 4, "Mobile Based E-OTD" },
516 | { 5, "Mobile Assisted GPS" },
517 | { 6, "Mobile Based GPS" },
518 | { 7, "Conventional GPS" },
519 | { 8, "U-TDOA" },
520 | { 9, "Reserved for UTRAN use only" },
521 | { 10, "Reserved for UTRAN use only" },
522 | { 11, "Reserved for UTRAN use only" },
523 | { 12, "Cell ID" },
524 | { 0, NULL((void*)0)}
525 | };
526 |
527 | /* Positioning Method definitions */
528 | static const value_string bssmap_positioning_method_vals[] = {
529 | { 0, "reserved" },
530 | { 1, "Mobile Assisted E-OTD" },
531 | { 2, "Mobile Based E-OTD" },
532 | { 3, "Assisted GPS" },
533 | { 4, "Assisted GANSS" },
534 | { 5, "Assisted GPS and Assisted GANSS" },
535 | { 0, NULL((void*)0)}
536 | };
537 |
538 | static const value_string bssmap_positioning_methods_usage[] = {
539 | { 0, "Attempted unsuccessfully due to failure or interruption" },
540 | { 1, "Attempted successfully - results not used to generate location" },
541 | { 2, "Attempted successfully - results used to verify but not generate location" },
542 | { 3, "Attempted successfully - results used to generate location" },
543 | { 4, "Attempted successfully - case where MS supports multiple mobile based positioning methods and the actual method or methods used by the MS cannot be determined" },
544 | { 0, NULL((void*)0)}
545 | };
546 |
547 | /* Location Information definitions */
548 | static const value_string bssmap_location_information_vals[] = {
549 | { 0, "current geographic location" },
550 | { 1, "location assistance information for the target MS" },
551 | { 2, "deciphering keys for broadcast assistance data for the target MS" },
552 | { 0, NULL((void*)0)}
553 | };
554 |
555 | static const true_false_string bssmap_chan_type_extension_value = {
556 | "Additional Octet",
557 | "Last Octet"
558 | };
559 |
560 | static const true_false_string bssmap_cause_extension_value = {
561 | "Two Octets",
562 | "One Octet"
563 | };
564 |
565 | /* Current Channel Type */
566 | static const value_string chan_mode_vals[] = {
567 | { 0, "signalling only" },
568 | { 1, "speech (full rate or half rate)" },
569 | { 6, "data, 14.5 kbit/s radio interface rate" },
570 | { 3, "data, 12.0 kbit/s radio interface rate" },
571 | { 4, "data, 6.0 kbit/s radio interface rate" },
572 | { 5, "data, 3.6 kbit/s radio interface rate" },
573 | { 0x0f, "reserved" },
574 | { 0, NULL((void*)0)}
575 | };
576 |
577 | static const value_string fe_cur_chan_type2_chan_field_vals[] = {
578 | { 1, "SDCCH" },
579 | { 8, "1 Full rate TCH" },
580 | { 9, "1 Half rate TCH" },
581 | { 10, "2 Full Rate TCHs" },
582 | { 11, "3 Full Rate TCHs" },
583 | { 12, "4 Full Rate TCHs" },
584 | { 13, "5 Full Rate TCHs" },
585 | { 14, "6 Full Rate TCHs" },
586 | { 15, "7 Full Rate TCHs" },
587 | { 4, "8 Full Rate TCHs" },
588 | { 0, "reserved" },
589 | { 0, NULL((void*)0)}
590 | };
591 |
592 | /* Initialize the protocol and registered fields */
593 | static int proto_a_bssmap;
594 |
595 | static int hf_gsm_a_bssmap_msg_type;
596 | int hf_gsm_a_bssmap_elem_id;
597 | static int hf_gsm_a_bssmap_field_elem_id;
598 | static int hf_gsm_a_bssmap_field_elem_id_len;
599 | static int hf_gsm_a_bssmap_cell_ci;
600 | static int hf_gsm_a_bssmap_cell_lac;
601 | static int hf_gsm_a_bssmap_sac;
602 | static int hf_gsm_a_bssmap_dlci_cc;
603 | static int hf_gsm_a_bssmap_dlci_spare;
604 | static int hf_gsm_a_bssmap_dlci_sapi;
605 | static int hf_gsm_a_bssmap_cause;
606 | static int hf_gsm_a_bssmap_be_cell_id_disc;
607 | static int hf_gsm_a_bssmap_pci;
608 | static int hf_gsm_a_bssmap_qa;
609 | static int hf_gsm_a_bssmap_pvi;
610 | static int hf_gsm_a_bssmap_interference_bands;
611 | static int hf_gsm_a_bssmap_lsa_only;
612 | static int hf_gsm_a_bssmap_act;
613 | static int hf_gsm_a_bssmap_pref;
614 | static int hf_gsm_a_bssmap_lsa_inf_prio;
615 | static int hf_gsm_a_bssmap_seq_len;
616 | static int hf_gsm_a_bssmap_seq_no;
617 | static int hf_gsm_a_bssap_cell_id_list_seg_cell_id_disc;
618 | static int hf_gsm_a_bssap_res_ind_method;
619 | static int hf_gsm_a_bssap_cic_list_range;
620 | static int hf_gsm_a_bssap_cic_list_status;
621 | static int hf_gsm_a_bssap_diag_error_pointer;
622 | static int hf_gsm_a_bssap_diag_msg_rcv;
623 | static int hf_gsm_a_bssmap_ch_mode;
624 | static int hf_gsm_a_bssmap_cur_ch_mode;
625 | static int hf_gsm_a_bssmap_channel;
626 | static int hf_gsm_a_bssmap_trace_trigger_id;
627 | static int hf_gsm_a_bssmap_trace_priority_indication;
628 | static int hf_gsm_a_bssmap_trace_bss_record_type;
629 | static int hf_gsm_a_bssmap_trace_msc_record_type;
630 | static int hf_gsm_a_bssmap_trace_invoking_event;
631 | static int hf_gsm_a_bssmap_trace_reference;
632 | static int hf_gsm_a_bssmap_trace_omc_id;
633 | static int hf_gsm_a_bssmap_be_rnc_id;
634 | static int hf_gsm_a_bssmap_apdu_protocol_id;
635 | static int hf_gsm_a_bssmap_segmentation_spare_bits;
636 | static int hf_gsm_a_bssmap_segment_number;
637 | static int hf_gsm_a_bssmap_msg_id;
638 | static int hf_gsm_a_bssmap_segmentation_info;
639 | static int hf_gsm_a_bssmap_periodicity;
640 | static int hf_gsm_a_bssmap_sm;
641 | static int hf_gsm_a_bssmap_tarr;
642 | static int hf_gsm_a_bssmap_tot_no_of_fullr_ch;
643 | static int hf_gsm_a_bssmap_tot_no_of_hr_ch;
644 | static int hf_gsm_a_bssmap_smi;
645 | static int hf_gsm_a_bssmap_lsa_id;
646 | static int hf_gsm_a_bssmap_ep;
647 | static int hf_gsm_a_bssmap_lcs_pri;
648 | static int hf_gsm_a_bssmap_num_ms;
649 | static int hf_gsm_a_bssmap_talker_pri;
650 | static int hf_gsm_a_bssmap_rr_mode;
651 | static int hf_gsm_a_bssmap_group_cipher_key_nb;
652 | static int hf_gsm_a_bssmap_vgcs_vbs_cell_status;
653 | static int hf_gsm_a_bssmap_paging_cause;
654 | static int hf_gsm_a_bssmap_paging_inf_flg;
655 | static int hf_gsm_a_bssmap_serv_ho_inf;
656 | static int hf_gsm_a_bssmap_max_nb_traffic_chan;
657 | static int hf_gsm_a_bssmap_acceptable_chan_coding_bit5;
658 | static int hf_gsm_a_bssmap_acceptable_chan_coding_bit4;
659 | static int hf_gsm_a_bssmap_acceptable_chan_coding_bit3;
660 | static int hf_gsm_a_bssmap_acceptable_chan_coding_bit2;
661 | static int hf_gsm_a_bssmap_acceptable_chan_coding_bit1;
662 | static int hf_gsm_a_bssmap_allowed_data_rate_bit8;
663 | static int hf_gsm_a_bssmap_allowed_data_rate_bit7;
664 | static int hf_gsm_a_bssmap_allowed_data_rate_bit6;
665 | static int hf_gsm_a_bssmap_allowed_data_rate_bit5;
666 | static int hf_gsm_a_bssmap_allowed_data_rate_bit4;
667 | static int hf_gsm_a_bssmap_vstk_rand;
668 | static int hf_gsm_a_bssmap_vstk;
669 | static int hf_gsm_a_bssmap_spare_bits;
670 | static int hf_gsm_a_bssmap_tpind;
671 | static int hf_gsm_a_bssmap_asind_b2;
672 | static int hf_gsm_a_bssmap_asind_b3;
673 | static int hf_gsm_a_bssmap_bss_res;
674 | static int hf_gsm_a_bssmap_tcp;
675 | static int hf_gsm_a_bssmap_filler_bits;
676 | static int hf_gsm_a_bssmap_method;
677 | static int hf_gsm_a_bssmap_ganss_id;
678 | static int hf_gsm_a_bssmap_usage;
679 | static int hf_gsm_a_bssmap_data_id;
680 | static int hf_gsm_a_bssmap_bt_ind;
681 | static int hf_gsm_a_bssmap_aoip_trans_ipv4;
682 | static int hf_gsm_a_bssmap_aoip_trans_ipv6;
683 | static int hf_gsm_a_bssmap_aoip_trans_port;
684 | static int hf_gsm_a_bssmap_fi;
685 | static int hf_gsm_a_bssmap_tf;
686 | static int hf_gsm_a_bssmap_pi;
687 | static int hf_gsm_a_bssmap_pt;
688 | static int hf_gsm_a_bssap_speech_codec;
689 | static int hf_gsm_a_bssap_extended_codec;
690 | static int hf_gsm_a_bssap_extended_codec_r2;
691 | static int hf_gsm_a_bssap_extended_codec_r3;
692 | static int hf_gsm_a_bssmap_fi2;
693 | static int hf_gsm_a_bssmap_tf2;
694 | static int hf_gsm_a_bssmap_pi2;
695 | static int hf_gsm_a_bssmap_pt2;
696 | static int hf_gsm_a_bssmap_call_id;
697 | static int hf_gsm_a_bssmap_spare;
698 | static int hf_gsm_a_bssmap_positioning_data_discriminator;
699 | static int hf_gsm_a_bssmap_positioning_method;
700 | static int hf_gsm_a_bssmap_positioning_method_usage;
701 | static int hf_gsm_a_bssmap_location_type_location_information;
702 | static int hf_gsm_a_bssmap_location_type_positioning_method;
703 | static int hf_gsm_a_bssmap_chan_type_extension;
704 | static int hf_gsm_a_bssmap_cause_extension;
705 | static int hf_gsm_a_bssmap_ass_req;
706 | static int hf_gsm_a_bssmap_emlpp_prio;
707 | static int hf_gsm_a_bssmap_rip;
708 | static int hf_gsm_a_bssmap_rtd;
709 | static int hf_gsm_a_bssmap_kc128;
710 | static int hf_gsm_a_bssmap_csg_id;
711 | static int hf_gsm_a_bssmap_cell_access_mode;
712 | static int hf_fe_extra_info_prec;
713 | static int hf_fe_extra_info_lcs;
714 | static int hf_fe_extra_info_ue_prob;
715 | static int hf_fe_extra_info_spare;
716 | static int hf_fe_cur_chan_type2_chan_mode;
717 | static int hf_fe_cur_chan_type2_chan_mode_spare;
718 | static int hf_fe_cur_chan_type2_chan_field;
719 | static int hf_fe_cur_chan_type2_chan_field_spare;
720 | static int hf_fe_target_radio_cell_info_rxlev_ncell;
721 | static int hf_fe_target_radio_cell_info_rxlev_ncell_spare;
722 | static int hf_fe_dtm_info_dtm_ind;
723 | static int hf_fe_dtm_info_sto_ind;
724 | static int hf_fe_dtm_info_egprs_ind;
725 | static int hf_fe_dtm_info_spare_bits;
726 | static int hf_fe_cell_load_info_cell_capacity_class;
727 | static int hf_fe_cell_load_info_load_value;
728 | static int hf_fe_cell_load_info_rt_load_value;
729 | static int hf_fe_cell_load_info_nrt_load_information_value;
730 | static int hf_fe_ps_indication;
731 | static int hf_fe_dtm_ho_command_ind_spare;
732 | static int hf_gsm_a_bssmap_speech_data_ind;
733 | static int hf_gsm_a_bssmap_channel_rate_and_type;
734 | static int hf_gsm_a_bssmap_perm_speech_v_ind;
735 | static int hf_gsm_a_bssmap_reroute_rej_cause;
736 | static int hf_gsm_a_bssmap_send_seqn;
737 | static int hf_gsm_a_bssmap_reroute_outcome;
738 | static int hf_gsm_a_bssmap_lcls_conf;
739 | static int hf_gsm_a_bssmap_lcls_con_status_control;
740 | static int hf_gsm_a_bssmap_lcls_bss_status;
741 | static int hf_gsm_a_bssmap_osmocom_osmux_cid;
742 |
743 | /* Generated from convert_proto_tree_add_text.pl */
744 | static int hf_gsm_a_bssmap_message_elements;
745 | static int hf_gsm_a_bssmap_full_rate_channels_available;
746 | static int hf_gsm_a_bssmap_tch_6_4_8kb;
747 | static int hf_gsm_a_bssmap_speech_version_id;
748 | static int hf_gsm_a_bssmap_cell_id_unknown_format;
749 | static int hf_gsm_a_bssmap_tch_12kb;
750 | static int hf_gsm_a_bssmap_all_call_identifiers_resources_released;
751 | static int hf_gsm_a_bssmap_pcm_multiplexer;
752 | static int hf_gsm_a_bssmap_talker_identity_field;
753 | static int hf_gsm_a_bssmap_qri;
754 | static int hf_gsm_a_bssmap_cause_value;
755 | static int hf_gsm_a_bssmap_algorithm_identifier;
756 | static int hf_gsm_a_bssmap_tch_14_5_14_4kb;
757 | static int hf_gsm_a_bssmap_national_cause;
758 | static int hf_gsm_a_bssmap_cause_class;
759 | static int hf_gsm_a_bssmap_rate;
760 | static int hf_gsm_a_bssmap_tch_14_5kb;
761 | static int hf_gsm_a_bssmap_tch_12_9kb;
762 | static int hf_gsm_a_bssmap_s0_s7;
763 | static int hf_gsm_a_bssmap_tio;
764 | static int hf_gsm_a_bssmap_priority_level;
765 | static int hf_gsm_a_bssmap_cause16;
766 | static int hf_gsm_a_bssmap_enc_info_key;
767 | static int hf_gsm_a_bssmap_unknown_format;
768 | static int hf_gsm_a_bssmap_timeslot;
769 | static int hf_gsm_a_bssmap_transparent_service;
770 | static int hf_gsm_a_bssmap_tch_6kb;
771 | static int hf_gsm_a_bssmap_circuit_pool_number;
772 | static int hf_gsm_a_bssmap_ti_flag;
773 | static int hf_gsm_a_bssmap_half_rate_channels_available;
774 | static int hf_gsm_a_bssmap_imeisv_included;
775 | static int hf_gsm_a_bssmap_bss_activate_downlink;
776 | static int hf_gsm_a_bssmap_apdu;
777 | static int hf_gsm_a_bssmap_s0_s15;
778 | static int hf_gsm_a_bssmap_layer_3_information_value;
779 | static int hf_gsm_a_bssmap_gsm_a5_1;
780 | static int hf_gsm_a_bssmap_gsm_a5_2;
781 | static int hf_gsm_a_bssmap_gsm_a5_3;
782 | static int hf_gsm_a_bssmap_gsm_a5_4;
783 | static int hf_gsm_a_bssmap_gsm_a5_5;
784 | static int hf_gsm_a_bssmap_gsm_a5_6;
785 | static int hf_gsm_a_bssmap_gsm_a5_7;
786 | static int hf_gsm_a_bssmap_no_encryption;
787 | static int hf_gsm_a_bssmap_data_channel_rate_and_type;
788 | static int hf_gsm_a_bssmap_cell_discriminator;
789 | static int hf_gsm_a_bssmap_layer3_message_contents;
790 | static int hf_gsm_a_bssmap_forward_indicator;
791 |
792 | static expert_field ei_gsm_a_bssmap_extraneous_data;
793 | static expert_field ei_gsm_a_bssmap_not_decoded_yet;
794 | static expert_field ei_gsm_a_bssap_unknown_codec;
795 | static expert_field ei_gsm_a_bssmap_bogus_length;
796 | static expert_field ei_gsm_a_bssmap_missing_mandatory_element;
797 |
798 | /* Initialize the subtree pointers */
799 | static int ett_bssmap_msg;
800 | static int ett_cell_list;
801 | static int ett_dlci;
802 | static int ett_codec_lst;
803 | static int ett_bss_to_bss_info;
804 |
805 | static dissector_handle_t gsm_bsslap_handle;
806 | static dissector_handle_t dtap_handle;
807 | static dissector_handle_t bssgp_handle;
808 | static dissector_handle_t rrc_handle;
809 | static dissector_handle_t bicc_mst_handle;
810 | static dissector_handle_t bssmap_handle;
811 |
812 | static proto_tree *g_tree;
813 | static uint8_t cell_discriminator = 0x0f; /* tracks whether handover is to UMTS */
814 |
815 | static uint16_t
816 | be_field_element_dissect(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)));
817 |
818 | #if 0
819 | This enum has been moved to packet-gsm_a_common to
820 | make it possible to use element dissecton from this dissector
821 | in other dissectors.
822 | It is left here as a comment for easier reference.
823 |
824 | Note this enum must be of the same size as the element decoding list
825 |
826 | typedef enum
827 | {
828 | BE_UDEF_0, /* Undefined */
829 | BE_CIC, /* Circuit Identity Code */
830 | BE_RSVD_1, /* Reserved */
831 | BE_RES_AVAIL, /* Resource Available */
832 | BE_CAUSE, /* Cause */
833 | BE_CELL_ID, /* Cell Identifier */
834 | BE_PRIO, /* Priority */
835 | BE_L3_HEADER_INFO, /* Layer 3 Header Information */
836 | BE_IMSI, /* IMSI */
837 | BE_TMSI, /* TMSI */
838 | BE_ENC_INFO, /* Encryption Information */
839 | BE_CHAN_TYPE, /* Channel Type */
840 | BE_PERIODICITY, /* Periodicity */
841 | BE_EXT_RES_IND, /* Extended Resource Indicator */
842 | BE_NUM_MS, /* Number Of MSs */
843 | BE_RSVD_2, /* Reserved */
844 | BE_RSVD_3, /* Reserved */
845 | BE_RSVD_4, /* Reserved */
846 | BE_CM_INFO_2, /* Classmark Information Type 2 */
847 | BE_CM_INFO_3, /* Classmark Information Type 3 */
848 | BE_INT_BAND, /* Interference Band To Be Used */
849 | BE_RR_CAUSE, /* RR Cause */
850 | BE_RSVD_5, /* Reserved */
851 | BE_L3_INFO, /* Layer 3 Information */
852 | BE_DLCI, /* DLCI */
853 | BE_DOWN_DTX_FLAG, /* Downlink DTX Flag */
854 | BE_CELL_ID_LIST, /* Cell Identifier List */
855 | BE_RESP_REQ, /* Response Request */
856 | BE_RES_IND_METHOD, /* Resource Indication Method */
857 | BE_CM_INFO_1, /* Classmark Information Type 1 */
858 | BE_CIC_LIST, /* Circuit Identity Code List */
859 | BE_DIAG, /* Diagnostic */
860 | BE_L3_MSG, /* Layer 3 Message Contents */
861 | BE_CHOSEN_CHAN, /* Chosen Channel */
862 | BE_TOT_RES_ACC, /* Total Resource Accessible */
863 | BE_CIPH_RESP_MODE, /* Cipher Response Mode */
864 | BE_CHAN_NEEDED, /* Channel Needed */
865 | BE_TRACE_TYPE, /* Trace Type */
866 | BE_TRIGGERID, /* TriggerID */
867 | BE_TRACE_REF, /* Trace Reference */
868 | BE_TRANSID, /* TransactionID */
869 | BE_MID, /* Mobile Identity */
870 | BE_OMCID, /* OMCID */
871 | BE_FOR_IND, /* Forward Indicator */
872 | BE_CHOSEN_ENC_ALG, /* Chosen Encryption Algorithm */
873 | BE_CCT_POOL, /* Circuit Pool */
874 | BE_CCT_POOL_LIST, /* Circuit Pool List */
875 | BE_TIME_IND, /* Time Indication */
876 | BE_RES_SIT, /* Resource Situation */
877 | BE_CURR_CHAN_1, /* Current Channel Type 1 */
878 | BE_QUE_IND, /* Queueing Indicator */
879 | BE_ASS_REQ, /* Assignment Requirement */
880 | BE_UDEF_52, /* Undefined */
881 | BE_TALKER_FLAG, /* Talker Flag */
882 | BE_CONN_REL_REQ, /* Connection Release Requested */
883 | BE_GROUP_CALL_REF, /* Group Call Reference */
884 | BE_EMLPP_PRIO, /* eMLPP Priority */
885 | BE_CONF_EVO_IND, /* Configuration Evolution Indication */
886 | BE_OLD2NEW_INFO, /* Old BSS to New BSS Information */
887 | BE_LSA_ID, /* LSA Identifier */
888 | BE_LSA_ID_LIST, /* LSA Identifier List */
889 | BE_LSA_INFO, /* LSA Information */
890 | BE_LCS_QOS, /* LCS QoS */
891 | BE_LSA_ACC_CTRL, /* LSA access control suppression */
892 | BE_SPEECH_VER, /* Speech Version */
893 | BE_UDEF_65, /* Undefined */
894 | BE_UDEF_66, /* Undefined */
895 | BE_LCS_PRIO, /* LCS Priority */
896 | BE_LOC_TYPE, /* Location Type */
897 | BE_LOC_EST, /* Location Estimate */
898 | BE_POS_DATA, /* Positioning Data */
899 | BE_LCS_CAUSE, /* 3.2.2.66 LCS Cause */
900 | BE_LCS_CLIENT, /* 10.14 LCS Client Type */
901 | BE_APDU, /* APDU */
902 | BE_NE_ID, /* Network Element Identity */
903 | BE_GPS_ASSIST_DATA, /* GPS Assistance Data */
904 | BE_DECIPH_KEYS, /* Deciphering Keys */
905 | BE_RET_ERR_REQ, /* Return Error Request */
906 | BE_RET_ERR_CAUSE, /* Return Error Cause */
907 | BE_SEG, /* Segmentation */
908 | BE_SERV_HO, /* Service Handover */
909 | BE_SRC_RNC_TO_TAR_RNC_UMTS, /* Source RNC to target RNC transparent information (UMTS) */
910 | BE_SRC_RNC_TO_TAR_RNC_CDMA, /* Source RNC to target RNC transparent information (cdma2000) */
911 | BE_GERAN_CLS_M, /* GERAN Classmark */
912 | BE_GERAN_BSC_CONT, /* GERAN BSC Container */
913 | BE_VEL_EST, /* Velocity Estimate */
914 | BE_UDEF_86, /* Undefined */
915 | BE_UDEF_87, /* Undefined */
916 | BE_UDEF_88, /* Undefined */
917 | BE_UDEF_89, /* Undefined */
918 | BE_UDEF_90, /* Undefined */
919 | BE_UDEF_91, /* Undefined */
920 | BE_UDEF_92, /* Undefined */
921 | BE_UDEF_93, /* Undefined */
922 | BE_UDEF_94, /* Undefined */
923 | BE_UDEF_95, /* Undefined */
924 | BE_UDEF_96, /* Undefined */
925 | BE_NEW_BSS_TO_OLD_BSS_INF, /* New BSS to Old BSS Information */
926 | BE_UDEF_98, /* Undefined */
927 | BE_INTER_SYS_INF, /* Inter-System Information */
928 | BE_SNA_ACC_INF, /* SNA Access Information */
929 | BE_VSTK_RAND_INF, /* VSTK_RAND Information */
930 | BE_VSTK_INF, /* VSTK Information */
931 | BE_PAGING_INF, /* Paging Information */
932 | BE_IMEI, /* IMEI */
933 | BE_VGCS_FEAT_FLG, /* VGCS Feature Flags */
934 | BE_TALKER_PRI, /* Talker Priority */
935 | BE_EMRG_SET_IND, /* Emergency Set Indication */
936 | BE_TALKER_ID, /* Talker Identity */
937 | BE_CELL_ID_LIST_SEG, /* Cell Identifier List Segment */
938 | BE_SMS_TO_VGCS, /* SMS to VGCS */
939 | BE_VGCS_TALKER_MOD, /* VGCS Talker Mode */
940 | BE_VGS_VBS_CELL_STAT, /* VGCS/VBS Cell Status */
941 | BE_CELL_ID_LST_SEG_F_EST_CELLS, /* Cell Identifier List Segment for established cells */
942 | BE_CELL_ID_LST_SEG_F_CELL_TB_EST, /* Cell Identifier List Segment for cells to be established */
943 | BE_CELL_ID_LST_SEG_F_REL_CELL, /* Cell Identifier List Segment for released cells - no user present */
944 | BE_CELL_ID_LST_SEG_F_NOT_EST_CELL, /* Cell Identifier List Segment for not established cells - no establishment possible */
945 | BE_GANSS_ASS_DTA, /* GANSS Assistance Data */
946 | BE_GANSS_POS_DTA, /* GANSS Positioning Data */
947 | BE_GANSS_LOC_TYP, /* GANSS Location Type */
948 | BE_APP_DATA, /* Application Data */
949 | BE_DATA_ID, /* Data Identity */
950 | BE_APP_DATA_INF, /* Application Data Information */
951 | BE_MSISDN, /* MSISDN */
952 | BE_AOIP_TRANS_LAY_ADD, /* AoIP Transport Layer Address */
953 | BE_SPEECH_CODEC_LST, /* Speech Codec List */
954 | BE_SPEECH_CODEC, /* Speech Codec */
955 | BE_CALL_ID, /* Call Identifier */
956 | BE_CALL_ID_LST, /* Call Identifier List */
957 | BE_A_ITF_SEL_FOR_RESET, /* A-Interface Selector for RESET */
958 | BE_UDEF_130, /* Undefined */
959 | BE_KC128, /* Kc128 */
960 | BE_CSG_ID, /* CSG Identifier */
961 | BE_REDIR_ATT_FLG, /* Redirect Attempt Flag 3.2.2.111 */
962 | BE_REROUTE_REJ_CAUSE, /* Reroute Reject Cause 3.2.2.112 */
963 | BE_SEND_SEQN, /* Send Sequence Number 3.2.2.113 */
964 | BE_REROUTE_OUTCOME, /* Reroute complete outcome 3.2.2.114 */
965 | BE_GLOBAL_CALL_REF, /* Global Call Reference 3.2.2.115 */
966 | BE_LCLS_CONF, /* LCLS-Configuration 3.2.2.116 */
967 | BE_LCLS_CON_STATUS_CONTROL, /* LCLS-Connection-Status-Control 3.2.2.117 */
968 | BE_LCLS_CORR_NOT_NEEDED, /* LCLS-Correlation-Not-Needed 3.2.2.118 */
969 | BE_LCLS_BSS_STATUS, /* LCLS-BSS-Status 3.2.2.119 */
970 | BE_LCLS_BREAK_REQ, /* LCLS-Break-Request 3.2.2.120 */
971 | BE_CSFB_IND, /* CSFB Indication 3.2.2.121 */
972 | BE_CS_TO_PS_SRVCC, /* CS to PS SRVCC 3.2.2.122 */
973 | BE_SRC_ENB_2_TGT_ENB_TRANSP_INF, /* Source eNB to target eNB transparent information (E-UTRAN)" 3.2.2.123 */
974 | BE_CS_TO_PS_SRVCC_IND, /* CS to PS SRVCC Indication 3.2.2.124 */
975 | BE_CN_TO_MS_TRANSP, /* CN to MS transparent information 3.2.2.125 */
976 | BE_SELECTED_PLMN_ID, /* Selected PLMN ID 3.2.2.126 */
977 | BE_LAST_USED_EUTRAN_PLMN_ID, /* Last used E - UTRAN PLMN ID 3.2.2.127 */
978 | BE_UDEF_150, /* Undefined Old Location Area Identification 3.2.2.128 */
979 | BE_UDEF_151, /* Undefined Attach Indicator 3.2.2.129 */
980 | BE_UDEF_152, /* Undefined Selected Operator 3.2.2.130 */
981 | BE_UDEF_153, /* Undefined PS Registered Operator 3.2.2.131 */
982 | BE_UDEF_154, /* Undefined CS Registered Operator 3.2.2.132*/
983 | BE_UDEF_155, /* Undefined */
984 | BE_UDEF_156, /* Undefined */
985 | BE_UDEF_157, /* Undefined */
986 | BE_UDEF_158, /* Undefined */
987 | BE_UDEF_159, /* Undefined */
988 | BE_UDEF_160, /* Undefined */
989 | BE_UDEF_161, /* Undefined */
990 | BE_UDEF_162, /* Undefined */
991 | BE_UDEF_163, /* Undefined */
992 | BE_UDEF_164, /* Undefined */
993 | BE_UDEF_165, /* Undefined */
994 | BE_UDEF_166, /* Undefined */
995 | BE_UDEF_167, /* Undefined */
996 | BE_UDEF_168, /* Undefined */
997 | BE_UDEF_169, /* Undefined */
998 | BE_UDEF_170, /* Undefined */
999 | BE_UDEF_171, /* Undefined */
1000 | BE_UDEF_172, /* Undefined */
1001 | BE_UDEF_173, /* Undefined */
1002 | BE_UDEF_174, /* Undefined */
1003 | BE_UDEF_175, /* Undefined */
1004 | BE_UDEF_176, /* Undefined */
1005 | BE_UDEF_177, /* Undefined */
1006 | BE_UDEF_178, /* Undefined */
1007 | BE_UDEF_179, /* Undefined */
1008 | BE_UDEF_180, /* Undefined */
1009 | BE_UDEF_181, /* Undefined */
1010 | BE_UDEF_182, /* Undefined */
1011 | BE_UDEF_183, /* Undefined */
1012 | BE_UDEF_184, /* Undefined */
1013 | BE_UDEF_185, /* Undefined */
1014 | BE_UDEF_186, /* Undefined */
1015 | BE_UDEF_187, /* Undefined */
1016 | BE_UDEF_188, /* Undefined */
1017 | BE_UDEF_189, /* Undefined */
1018 | BE_UDEF_190, /* Undefined */
1019 | BE_UDEF_191, /* Undefined */
1020 | BE_UDEF_192, /* Undefined */
1021 | BE_UDEF_193, /* Undefined */
1022 | BE_UDEF_194, /* Undefined */
1023 | BE_UDEF_195, /* Undefined */
1024 | BE_UDEF_196, /* Undefined */
1025 | BE_UDEF_197, /* Undefined */
1026 | BE_UDEF_198, /* Undefined */
1027 | BE_UDEF_199, /* Undefined */
1028 | BE_UDEF_200, /* Undefined */
1029 | BE_UDEF_201, /* Undefined */
1030 | BE_UDEF_202, /* Undefined */
1031 | BE_UDEF_203, /* Undefined */
1032 | BE_UDEF_204, /* Undefined */
1033 | BE_UDEF_205, /* Undefined */
1034 | BE_UDEF_206, /* Undefined */
1035 | BE_UDEF_207, /* Undefined */
1036 | BE_UDEF_208, /* Undefined */
1037 | BE_UDEF_209, /* Undefined */
1038 | BE_UDEF_210, /* Undefined */
1039 | BE_UDEF_211, /* Undefined */
1040 | BE_UDEF_212, /* Undefined */
1041 | BE_UDEF_213, /* Undefined */
1042 | BE_UDEF_214, /* Undefined */
1043 | BE_UDEF_215, /* Undefined */
1044 | BE_UDEF_216, /* Undefined */
1045 | BE_UDEF_217, /* Undefined */
1046 | BE_UDEF_218, /* Undefined */
1047 | BE_UDEF_219, /* Undefined */
1048 | BE_UDEF_220, /* Undefined */
1049 | BE_UDEF_221, /* Undefined */
1050 | BE_UDEF_222, /* Undefined */
1051 | BE_UDEF_223, /* Undefined */
1052 | BE_UDEF_224, /* Undefined */
1053 | BE_UDEF_225, /* Undefined */
1054 | BE_UDEF_226, /* Undefined */
1055 | BE_UDEF_227, /* Undefined */
1056 | BE_UDEF_228, /* Undefined */
1057 | BE_UDEF_229, /* Undefined */
1058 | BE_UDEF_230, /* Undefined */
1059 | BE_UDEF_231, /* Undefined */
1060 | BE_UDEF_232, /* Undefined */
1061 | BE_UDEF_233, /* Undefined */
1062 | BE_UDEF_234, /* Undefined */
1063 | BE_UDEF_235, /* Undefined */
1064 | BE_UDEF_236, /* Undefined */
1065 | BE_UDEF_237, /* Undefined */
1066 | BE_UDEF_238, /* Undefined */
1067 | BE_UDEF_239, /* Undefined */
1068 | BE_OSMOCOM_OSMUX_SUPPORT = 0xf0, /* Osmocom extension: Osmux Support */
1069 | BE_OSMOCOM_OSMUX_CID = 0xf1, /* Osmocom extension: Osmux CID */
1070 | BE_NONE /* NONE */
1071 | }
1072 | bssmap_elem_idx_t;
1073 | #endif
1074 |
1075 | #define NUM_GSM_BSSMAP_ELEM(sizeof (gsm_bssmap_elem_strings) / sizeof (gsm_bssmap_elem_strings )[0]) array_length(gsm_bssmap_elem_strings)(sizeof (gsm_bssmap_elem_strings) / sizeof (gsm_bssmap_elem_strings )[0])
1076 | int ett_gsm_bssmap_elem[NUM_GSM_BSSMAP_ELEM(sizeof (gsm_bssmap_elem_strings) / sizeof (gsm_bssmap_elem_strings )[0])];
1077 |
1078 | /*
1079 | * [2] 3.2.2.2 Circuit Identity Code
1080 | */
1081 | static uint16_t
1082 | be_cic(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string, int string_len)
1083 | {
1084 | uint32_t curr_offset;
1085 | uint32_t value;
1086 |
1087 | curr_offset = offset;
1088 |
1089 | value = tvb_get_ntohs(tvb, curr_offset);
1090 |
1091 | proto_tree_add_item(tree, hf_gsm_a_bssmap_pcm_multiplexer, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
1092 | proto_tree_add_item(tree, hf_gsm_a_bssmap_timeslot, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
1093 | curr_offset += 2;
1094 |
1095 | if (add_string)
1096 | snprintf(add_string, string_len, " - (%u) (0x%04x)", value, value);
1097 |
1098 | /* no length check possible */
1099 |
1100 | return curr_offset-offset;
1101 | }
1102 | /*
1103 | * 3.2.2.3 Connection Release Requested
1104 | * No Data
1105 | */
1106 |
1107 | /*
1108 | * 3.2.2.4 Resource Available
1109 | */
1110 | static uint16_t
1111 | be_res_avail(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
1112 | {
1113 | uint32_t curr_offset;
1114 | uint16_t value;
1115 | int i;
1116 | proto_item* ti;
1117 |
1118 | curr_offset = offset;
1119 |
1120 | for (i=0; i < 5; i++) {
1121 | value = tvb_get_ntohl(tvb, curr_offset);
1122 | ti = proto_tree_add_uint_format(tree, hf_gsm_a_bssmap_full_rate_channels_available, tvb, curr_offset, 2, value, "Number of full rate channels available in band %u %u",i+1,value);
1123 | proto_item_set_len(ti, len);
1124 | curr_offset+=2;
1125 | ti = proto_tree_add_uint_format(tree, hf_gsm_a_bssmap_half_rate_channels_available, tvb, curr_offset, 2, value, "Number of half rate channels available in band %u %u",i+1, value);
1126 | proto_item_set_len(ti, len);
1127 | curr_offset+=2;
1128 | }
1129 |
1130 |
1131 | return len;
1132 | }
1133 | /*
1134 | * [2] 3.2.2.5 Cause
1135 | */
1136 | static const value_string cause_class_vals[] = {
1137 | { 0, "Normal Event"},
1138 | { 1, "Normal Event"},
1139 | { 2, "Resource Unavailable"},
1140 | { 3, "Service or option not available"},
1141 | { 4, "Service or option not implemented"},
1142 | { 5, "Invalid message (e.g., parameter out of range)"},
1143 | { 6, "Protocol error"},
1144 | { 7, "Interworking"},
1145 | { 0, NULL((void*)0) }
1146 | };
1147 |
1148 | static const range_string gsm_a_bssap_cause_rvals[] = {
1149 | { 0x00, 0x00, "Radio interface message failure" },
1150 | { 0x01, 0x01, "Radio interface failure" },
1151 | { 0x02, 0x02, "Uplink quality" },
1152 | { 0x03, 0x03, "Uplink strength" },
1153 | { 0x04, 0x04, "Downlink quality" },
1154 | { 0x05, 0x05, "Downlink strength" },
1155 | { 0x06, 0x06, "Distance" },
1156 | { 0x07, 0x07, "O and M intervention" },
1157 | { 0x08, 0x08, "Response to MSC invocation" },
1158 | { 0x09, 0x09, "Call control" },
1159 | { 0x0a, 0x0a, "Radio interface failure, reversion to old channel" },
1160 | { 0x0b, 0x0b, "Handover successful" },
1161 | { 0x0c, 0x0c, "Better Cell" },
1162 | { 0x0d, 0x0d, "Directed Retry" },
1163 | { 0x0e, 0x0e, "Joined group call channel" },
1164 | { 0x0f, 0x0f, "Traffic" },
1165 | { 0x10, 0x10, "Reduce load in serving cell" },
1166 | { 0x11, 0x11, "Traffic load in target cell higher than in source cell" },
1167 | { 0x12, 0x12, "Relocation triggered" },
1168 | { 0x14, 0x14, "Requested option not authorised" },
1169 | { 0x15, 0x15, "Alternative channel configuration requested" },
1170 | { 0x16, 0x16, "Response to an INTERNAL HANDOVER ENQUIRY message" },
1171 | { 0x17, 0x17, "INTERNAL HANDOVER ENQUIRY reject" },
1172 | { 0x18, 0x18, "Redundancy Level not adequate" },
1173 | { 0x19, 0x1f, "Reserved for national use" },
1174 | { 0x20, 0x20, "Equipment failure" },
1175 | { 0x21, 0x21, "No radio resource available" },
1176 | { 0x22, 0x22, "Requested terrestrial resource unavailable" },
1177 | { 0x23, 0x23, "CCCH overload" },
1178 | { 0x24, 0x24, "Processor overload" },
1179 | { 0x25, 0x25, "BSS not equipped" },
1180 | { 0x26, 0x26, "MS not equipped" },
1181 | { 0x27, 0x27, "Invalid cell" },
1182 | { 0x28, 0x28, "Traffic Load" },
1183 | { 0x29, 0x29, "Preemption" },
1184 | { 0x2a, 0x2a, "DTM Handover - SGSN Failure" },
1185 | { 0x2b, 0x2b, "DTM Handover - PS Allocation failure" },
1186 | { 0x2c, 0x2f, "Reserved for national use" },
1187 | { 0x30, 0x30, "Requested transcoding/rate adaption unavailable" },
1188 | { 0x31, 0x31, "Circuit pool mismatch" },
1189 | { 0x32, 0x32, "Switch circuit pool" },
1190 | { 0x33, 0x33, "Requested speech version unavailable" },
1191 | { 0x34, 0x34, "LSA not allowed" },
1192 | { 0x35, 0x35, "Requested Codec Type or Codec Configuration unavailable" },
1193 | { 0x36, 0x36, "Requested A-Interface Type unavailable" },
1194 | { 0x37, 0x37, "Invalid CSG cell" },
1195 | { 0x38, 0x3e, "Reserved for international use" },
1196 | { 0x3f, 0x3f, "Requested Redundancy Level not available" },
1197 | { 0x40, 0x40, "Ciphering algorithm not supported" },
1198 | { 0x41, 0x41, "GERAN Iu-mode failure" },
1199 | { 0x42, 0x42, "Incoming Relocation Not Supported Due To PUESBINE Feature" },
1200 | { 0x43, 0x43, "Access Restricted Due to Shared Networks" },
1201 | { 0x44, 0x44, "Requested Codec Type or Codec Configuration not supported" },
1202 | { 0x45, 0x45, "Requested A-Interface Type not supported" },
1203 | { 0x46, 0x46, "Requested Redundancy Level not supported" },
1204 | { 0x47, 0x47, "Reserved for international use" },
1205 | { 0x48, 0x4f, "Reserved for national use" },
1206 | { 0x50, 0x50, "Terrestrial circuit already allocated" },
1207 | { 0x51, 0x51, "Invalid message contents" },
1208 | { 0x52, 0x52, "Information element or field missing" },
1209 | { 0x53, 0x53, "Incorrect value" },
1210 | { 0x54, 0x54, "Unknown Message type" },
1211 | { 0x55, 0x55, "Unknown Information Element" },
1212 | { 0x56, 0x56, "DTM Handover - Invalid PS Indication" },
1213 | { 0x57, 0x57, "Call Identifier already allocated" },
1214 | { 0x58, 0x5f, "Reserved for national use" },
1215 | { 0x60, 0x60, "Protocol Error between BSS and MSC" },
1216 | { 0x61, 0x61, "VGCS/VBS call non existent" },
1217 | { 0x62, 0x62, "DTM Handover - Timer Expiry" },
1218 | { 0x63, 0x67, "Reserved for international use" },
1219 | { 0x68, 0x6f, "Reserved for national use" },
1220 | { 0x70, 0x77, "Reserved for international use" },
1221 | { 0x78, 0x7f, "Reserved for national use" },
1222 |
1223 | { 0, 0, NULL((void*)0) },
1224 | };
1225 |
1226 | /* non-static for packet-gsm_gsup.c */
1227 | uint16_t
1228 | bssmap_dissect_cause(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string, int string_len)
1229 | {
1230 | uint8_t oct;
1231 | uint32_t curr_offset;
1232 |
1233 | curr_offset = offset;
1234 |
1235 | oct = tvb_get_uint8(tvb, curr_offset);
1236 |
1237 | proto_tree_add_item(tree, hf_gsm_a_bssmap_cause_extension, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1238 |
1239 | if (oct & 0x80)
1240 | {
1241 | /* 2 octet cause */
1242 |
1243 | if ((oct & 0x0f) == 0x00)
1244 | {
1245 | /* national cause */
1246 |
1247 | proto_tree_add_item(tree, hf_gsm_a_bssmap_cause_class, tvb, curr_offset, 1, ENC_NA0x00000000);
1248 | proto_tree_add_item(tree, hf_gsm_a_bssmap_national_cause, tvb, curr_offset, 1, ENC_NA0x00000000);
1249 | curr_offset++;
1250 |
1251 | proto_tree_add_item(tree, hf_gsm_a_bssmap_cause_value, tvb, curr_offset, 1, ENC_NA0x00000000);
1252 | curr_offset++;
1253 |
1254 | if (add_string)
1255 | snprintf(add_string, string_len, " - (National Cause)");
1256 | }
1257 | else
1258 | {
1259 | proto_tree_add_item(tree, hf_gsm_a_bssmap_cause16, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
1260 | curr_offset+=2;
1261 | }
1262 | }
1263 | else
1264 | {
1265 | proto_tree_add_item(tree, hf_gsm_a_bssmap_cause,
1266 | tvb, curr_offset, 1, ENC_NA0x00000000);
1267 |
1268 | curr_offset++;
1269 |
1270 | if (add_string)
1271 | snprintf(add_string, string_len, " - (%u) %s", oct & 0x7f,
1272 | rval_to_str_const(oct & 0x7f, gsm_a_bssap_cause_rvals, "Unknown"));
1273 | }
1274 |
1275 | EXTRANEOUS_DATA_CHECK(len, curr_offset - offset, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((len) > (curr_offset - offset)) { proto_tree_add_expert (tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset , (len) - (curr_offset - offset)); curr_offset += ((len) - (curr_offset - offset)); };
1276 |
1277 | return curr_offset-offset;
1278 | }
1279 | /*
1280 | * 3.2.2.6 IMSI
1281 | * IMSI coded as the value part of the Mobile Identity IE defined in 3GPP TS 24.008 (NOTE 1)
1282 | * NOTE 1: The Type of identity field in the Mobile Identity IE shall be ignored by the receiver.
1283 | * Dissected in packet-gsm_a_common.c (de_mid)
1284 | */
1285 |
1286 | /*
1287 | * [2] 3.2.2.7 TMSI
1288 | */
1289 | static uint16_t
1290 | be_tmsi(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string, int string_len)
1291 | {
1292 | uint32_t curr_offset;
1293 | uint32_t value;
1294 |
1295 | curr_offset = offset;
1296 |
1297 | value = tvb_get_ntohl(tvb, curr_offset);
1298 |
1299 | proto_tree_add_uint(tree, hf_gsm_a_tmsi,
1300 | tvb, curr_offset, 4,
1301 | value);
1302 |
1303 | if (add_string)
1304 | snprintf(add_string, string_len, " - (0x%04x)", value);
1305 |
1306 | curr_offset += 4;
1307 |
1308 | EXTRANEOUS_DATA_CHECK(len, curr_offset - offset, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((len) > (curr_offset - offset)) { proto_tree_add_expert (tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset , (len) - (curr_offset - offset)); curr_offset += ((len) - (curr_offset - offset)); };
1309 |
1310 | return curr_offset-offset;
1311 | }
1312 |
1313 | /*
1314 | * [2] 3.2.2.8 Number Of MSs
1315 | */
1316 | static uint16_t
1317 | be_num_ms(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
1318 | {
1319 | uint32_t curr_offset;
1320 |
1321 | curr_offset = offset;
1322 |
1323 | proto_tree_add_item(tree, hf_gsm_a_bssmap_num_ms, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1324 | curr_offset++;
1325 |
1326 | /* no length check possible */
1327 |
1328 | return curr_offset-offset;
1329 | }
1330 | /*
1331 | * [2] 3.2.2.9 Layer 3 Header Information
1332 | */
1333 | static uint16_t
1334 | be_l3_header_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
1335 | {
1336 | uint32_t curr_offset = offset;
1337 |
1338 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
1339 |
1340 | proto_tree_add_item(tree, hf_gsm_a_L3_protocol_discriminator, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1341 |
1342 | curr_offset++;
1343 |
1344 | NO_MORE_DATA_CHECK(len)if ((len) <= (curr_offset - offset)) return(len);;
1345 |
1346 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
1347 | proto_tree_add_item(tree, hf_gsm_a_bssmap_ti_flag, tvb, curr_offset, 1, ENC_NA0x00000000);
1348 | proto_tree_add_item(tree, hf_gsm_a_bssmap_tio, tvb, curr_offset, 1, ENC_NA0x00000000);
1349 | curr_offset++;
1350 |
1351 | EXTRANEOUS_DATA_CHECK(len, curr_offset - offset, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((len) > (curr_offset - offset)) { proto_tree_add_expert (tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset , (len) - (curr_offset - offset)); curr_offset += ((len) - (curr_offset - offset)); };
1352 |
1353 | return curr_offset-offset;
1354 | }
1355 |
1356 | /*
1357 | * [2] 3.2.2.10 Encryption Information
1358 | */
1359 | static const true_false_string tfs_permitted_not_permitted = { "Permitted", "Not permitted" };
1360 |
1361 | static uint16_t
1362 | be_enc_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
1363 | {
1364 | uint32_t curr_offset = offset;
1365 |
1366 | proto_tree_add_item(tree, hf_gsm_a_bssmap_gsm_a5_7, tvb, curr_offset, 1, ENC_NA0x00000000);
1367 | proto_tree_add_item(tree, hf_gsm_a_bssmap_gsm_a5_6, tvb, curr_offset, 1, ENC_NA0x00000000);
1368 | proto_tree_add_item(tree, hf_gsm_a_bssmap_gsm_a5_5, tvb, curr_offset, 1, ENC_NA0x00000000);
1369 | proto_tree_add_item(tree, hf_gsm_a_bssmap_gsm_a5_4, tvb, curr_offset, 1, ENC_NA0x00000000);
1370 | proto_tree_add_item(tree, hf_gsm_a_bssmap_gsm_a5_3, tvb, curr_offset, 1, ENC_NA0x00000000);
1371 | proto_tree_add_item(tree, hf_gsm_a_bssmap_gsm_a5_2, tvb, curr_offset, 1, ENC_NA0x00000000);
1372 | proto_tree_add_item(tree, hf_gsm_a_bssmap_gsm_a5_1, tvb, curr_offset, 1, ENC_NA0x00000000);
1373 | proto_tree_add_item(tree, hf_gsm_a_bssmap_no_encryption, tvb, curr_offset, 1, ENC_NA0x00000000);
1374 | curr_offset++;
1375 |
1376 | NO_MORE_DATA_CHECK(len)if ((len) <= (curr_offset - offset)) return(len);;
1377 |
1378 | proto_tree_add_item(tree, hf_gsm_a_bssmap_enc_info_key, tvb, curr_offset, len - (curr_offset - offset), ENC_NA0x00000000);
1379 |
1380 | curr_offset += len - (curr_offset - offset);
1381 |
1382 | EXTRANEOUS_DATA_CHECK(len, curr_offset - offset, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((len) > (curr_offset - offset)) { proto_tree_add_expert (tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset , (len) - (curr_offset - offset)); curr_offset += ((len) - (curr_offset - offset)); };
1383 |
1384 | return curr_offset-offset;
1385 | }
1386 |
1387 | /*
1388 | * [2] 3.2.2.11 Channel Type
1389 | */
1390 |
1391 | static const value_string gsm_a_bssap_speech_data_ind_vals[] = {
1392 | { 0x0, "Reserved"},
1393 | { 0x1, "Speech"},
1394 | { 0x2, "Data"},
1395 | { 0x3, "Signalling"},
1396 | { 0x4, "Speech + CTM Text Telephony"},
1397 | { 0x5, "Reserved"},
1398 | { 0x6, "Reserved"},
1399 | { 0x7, "Reserved"},
1400 | { 0x8, "Reserved"},
1401 | { 0x9, "Reserved"},
1402 | { 0xa, "Reserved"},
1403 | { 0xb, "Reserved"},
1404 | { 0xc, "Reserved"},
1405 | { 0xd, "Reserved"},
1406 | { 0xe, "Reserved"},
1407 | { 0xf, "Reserved"},
1408 | { 0, NULL((void*)0) }
1409 | };
1410 |
1411 | /* Channel Rate and Type */
1412 | static const value_string gsm_a_bssap_channel_rate_and_type_vals[] = {
1413 | { 0x08, "Full rate TCH channel Bm. Prefer full rate TCH"},
1414 | { 0x09, "Half rate TCH channel Lm. Prefer half rate TCH"},
1415 | { 0x0a, "Full or Half rate channel, Full rate preferred changes allowed after first allocation"},
1416 | { 0x0b, "Full or Half rate channel, Half rate preferred changes allowed after first allocation"},
1417 | { 0x0f, "Full or Half rate channel, changes allowed after first allocation"},
1418 | { 0x1a, "Full or Half rate channel, Full rate preferred changes between full and half rate not allowed after first allocation"},
1419 | { 0x1b, "Full or Half rate channel, Half rate preferred changes between full and half rate not allowed after first allocation"},
1420 | { 0x1f, "Full or Half rate channel, changes between full and half rate not allowed after first allocation"},
1421 | { 0, NULL((void*)0) }
1422 | };
1423 |
1424 | static const range_string gsm_a_bssap_channel_rate_and_type_rvals[] = {
1425 | { 0x00, 0x00, "SDCCH or Full rate TCH channel Bm or Half rate TCH channel Lm" },
1426 | { 0x01, 0x01, "SDCCH" },
1427 | { 0x02, 0x02, "SDCCH or Full rate TCH channel Bm" },
1428 | { 0x03, 0x03, "Half rate TCH channel Lm" },
1429 | { 0x04, 0x07, "Reserved" },
1430 | { 0x08, 0x08, "Full rate TCH channel Bm" },
1431 | { 0x09, 0x09, "Half rate TCH channel Lm" },
1432 | { 0x0a, 0x0a, "Full or Half rate TCH channel, Full rate preferred, changes allowed also after first channel allocation as a result of the request" },
1433 | { 0x0b, 0x0b, "Full or Half rate TCH channel, Half rate preferred, changes allowed also after first channel allocation as a result of the request" },
1434 | { 0x0c, 0x19, "Reserved" },
1435 | { 0x1a, 0x1a, "Full or Half rate TCH channel, Full rate preferred, changes allowed also after first channel allocation as a result of the request" },
1436 | { 0x1b, 0x1b, "Full or Half rate TCH channel, Half rate preferred, changes allowed also after first channel allocation as a result of the request" },
1437 | { 0x1c, 0x1f, "Reserved" },
1438 | { 0x20, 0x27, "Full rate TCH channels in a multislot configuration, changes by the BSS of the number of TCHs and if applicable the used radio interface rate per channel allowed after first channel allocation as a result of the request" },
1439 | { 0x28, 0x2f, "Reserved" },
1440 | { 0x30, 0x37, "Full rate TCH channels in a multislot configuration, changes by the BSS of the number of TCHs or the used radio interface rate per channel not allowed after first channel allocation as a result of the request" },
1441 | { 0x38, 0xff, "Reserved" },
1442 | { 0, 0, NULL((void*)0) },
1443 | };
1444 |
1445 | static const true_false_string tfs_non_transparent_transparent = {"Non-Transparent", "Transparent"};
1446 |
1447 | uint16_t
1448 | be_chan_type(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string, int string_len)
1449 | {
1450 | uint8_t oct;
1451 | uint8_t sdi;
1452 | uint8_t num_chan;
1453 | uint32_t curr_offset = offset;
1454 | const char *str;
1455 |
1456 | oct = tvb_get_uint8(tvb, curr_offset);
1457 | sdi = oct & 0x0f;
1458 |
1459 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
1460 | proto_tree_add_item(tree, hf_gsm_a_bssmap_speech_data_ind, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1461 |
1462 | if (add_string)
1463 | snprintf(add_string, string_len, " - (%s)", val_to_str_const(tvb_get_uint8(tvb, curr_offset) & 0x0f,
1464 | gsm_a_bssap_speech_data_ind_vals,
1465 | "Unknown"));
1466 |
1467 | curr_offset++;
1468 |
1469 | NO_MORE_DATA_CHECK(len)if ((len) <= (curr_offset - offset)) return(len);;
1470 |
1471 | oct = tvb_get_uint8(tvb, curr_offset);
1472 |
1473 | if ((sdi == 0x01)||(sdi == 0x04))
1474 | {
1475 | /* speech */
1476 | proto_tree_add_item(tree, hf_gsm_a_bssmap_channel_rate_and_type, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1477 | curr_offset++;
1478 | NO_MORE_DATA_CHECK(len)if ((len) <= (curr_offset - offset)) return(len);;
1479 |
1480 | do
1481 | {
1482 | proto_tree_add_item(tree, hf_gsm_a_bssmap_chan_type_extension, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1483 | proto_tree_add_item(tree, hf_gsm_a_bssmap_perm_speech_v_ind, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1484 | curr_offset++;
1485 | }
1486 | while ((len - (curr_offset - offset)) > 0);
1487 | }
1488 | else if (sdi == 0x02)
1489 | {
1490 | /* data */
1491 |
1492 | num_chan = 0;
1493 |
1494 | if ((oct >= 0x20) && (oct <= 0x27))
1495 | {
1496 | num_chan = (oct - 0x20) + 1;
1497 | }
1498 | else if ((oct >= 0x30) && (oct <= 0x37))
1499 | {
1500 | num_chan = (oct - 0x30) + 1;
1501 | }
1502 |
1503 | if (num_chan > 0)
1504 | {
1505 | proto_tree_add_uint_format_value(tree, hf_gsm_a_bssmap_data_channel_rate_and_type,
1506 | tvb, curr_offset, 1, oct, "Max channels %u, %s",
1507 | num_chan, rval_to_str_const(oct, gsm_a_bssap_channel_rate_and_type_rvals, "Reserved"));
1508 | }
1509 | else
1510 | {
1511 | proto_tree_add_item(tree, hf_gsm_a_bssmap_data_channel_rate_and_type,
1512 | tvb, curr_offset, 1, ENC_NA0x00000000);
1513 | }
1514 |
1515 | curr_offset++;
1516 |
1517 | NO_MORE_DATA_CHECK(len)if ((len) <= (curr_offset - offset)) return(len);;
1518 |
1519 | oct = tvb_get_uint8(tvb, curr_offset);
1520 |
1521 | proto_tree_add_item(tree, hf_gsm_a_bssmap_chan_type_extension, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1522 | proto_tree_add_item(tree, hf_gsm_a_bssmap_transparent_service, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1523 |
1524 | if (num_chan == 0)
1525 | {
1526 | if (oct & 0x40)
1527 | {
1528 | /* non-transparent */
1529 |
1530 | switch (oct & 0x3f)
1531 | {
1532 | case 0x00: str = "12 kbit/s if the channel is a full rate TCH, or 6 kbit/s if the channel is a half rate TCH"; break;
1533 | case 0x18: str = "14.5 kbit/s"; break;
1534 | case 0x10: str = "12 kbits/s"; break;
1535 | case 0x11: str = "6 kbits/s"; break;
1536 | case 0x31: str = "29 kbit/s"; break;
1537 | case 0x34: str = "43,5 kbit/s"; break;
1538 | default:
1539 | str = "Reserved";
1540 | break;
1541 | }
1542 | }
1543 | else
1544 | {
1545 | switch (oct & 0x3f)
1546 | {
1547 | case 0x18: str = "14.4 kbit/s"; break;
1548 | case 0x10: str = "9.6kbit/s"; break;
1549 | case 0x11: str = "4.8kbit/s"; break;
1550 | case 0x12: str = "2.4kbit/s"; break;
1551 | case 0x13: str = "1.2Kbit/s"; break;
1552 | case 0x14: str = "600 bit/s"; break;
1553 | case 0x15: str = "1200/75 bit/s (1200 network-to-MS / 75 MS-to-network)"; break;
1554 | case 0x39: str = "28,8 kbit/s"; break;
1555 | case 0x3a: str = "32,0 kbit/s"; break;
1556 | default:
1557 | str = "Reserved";
1558 | break;
1559 | }
1560 | }
1561 | }
1562 | else
1563 | {
1564 | if (oct & 0x40)
1565 | {
1566 | /* non-transparent */
1567 |
1568 | switch (oct & 0x3f)
1569 | {
1570 | case 0x16: str = "58 kbit/s (4x14.5 kbit/s)"; break;
1571 | case 0x14: str = "48.0 / 43.5 kbit/s (4x12 kbit/s or 3x14.5 kbit/s)"; break;
1572 | case 0x13: str = "36.0 / 29.0 kbit/s (3x12 kbit/s or 2x14.5 kbit/s)"; break;
1573 | case 0x12: str = "24.0 / 24.0 (4x6 kbit/s or 2x12 kbit/s)"; break;
1574 | case 0x11: str = "18.0 / 14.5 kbit/s (3x6 kbit/s or 1x14.5 kbit/s)"; break;
1575 | case 0x10: str = "12.0 / 12.0 kbit/s (2x6 kbit/s or 1x12 kbit/s)"; break;
1576 | default:
1577 | str = "Reserved";
1578 | break;
1579 | }
1580 | }
1581 | else
1582 | {
1583 | switch (oct & 0x3f)
1584 | {
1585 | case 0x1f: str = "64 kbit/s, bit transparent"; break;
1586 | case 0x1e: str = "56 kbit/s, bit transparent"; break;
1587 | case 0x1d: str = "56 kbit/s"; break;
1588 | case 0x1c: str = "48 kbit/s"; break;
1589 | case 0x1b: str = "38.4 kbit/s"; break;
1590 | case 0x1a: str = "28.8 kbit/s"; break;
1591 | case 0x19: str = "19.2 kbit/s"; break;
1592 | case 0x18: str = "14.4 kbit/s"; break;
1593 | case 0x10: str = "9.6 kbit/s"; break;
1594 | default:
1595 | str = "Reserved";
1596 | break;
1597 | }
1598 | }
1599 | }
1600 |
1601 | proto_tree_add_uint_format_value(tree, hf_gsm_a_bssmap_rate,
1602 | tvb, curr_offset, 1, oct & 0x3f, "%s", str);
1603 |
1604 | curr_offset++;
1605 |
1606 | NO_MORE_DATA_CHECK(len)if ((len) <= (curr_offset - offset)) return(len);;
1607 |
1608 | proto_tree_add_item(tree, hf_gsm_a_bssmap_chan_type_extension, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1609 |
1610 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, (curr_offset<<3)+1, 3, ENC_BIG_ENDIAN0x00000000);
1611 |
1612 | if (num_chan == 0)
1613 | {
1614 | proto_tree_add_item(tree, hf_gsm_a_bssmap_tch_14_5kb, tvb, curr_offset, 1, ENC_NA0x00000000);
1615 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, (curr_offset<<3)+6, 1, ENC_BIG_ENDIAN0x00000000);
1616 | proto_tree_add_item(tree, hf_gsm_a_bssmap_tch_12kb, tvb, curr_offset, 1, ENC_NA0x00000000);
1617 | proto_tree_add_item(tree, hf_gsm_a_bssmap_tch_6kb, tvb, curr_offset, 1, ENC_NA0x00000000);
1618 | }
1619 | else
1620 | {
1621 | proto_tree_add_item(tree, hf_gsm_a_bssmap_tch_14_5_14_4kb, tvb, curr_offset, 1, ENC_NA0x00000000);
1622 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, (curr_offset<<3)+6, 1, ENC_BIG_ENDIAN0x00000000);
1623 | proto_tree_add_item(tree, hf_gsm_a_bssmap_tch_12_9kb, tvb, curr_offset, 1, ENC_NA0x00000000);
1624 | proto_tree_add_item(tree, hf_gsm_a_bssmap_tch_6_4_8kb, tvb, curr_offset, 1, ENC_NA0x00000000);
1625 | }
1626 |
1627 | curr_offset++;
1628 | }
1629 | else if (sdi == 0x03)
1630 | {
1631 | /* signalling */
1632 | proto_tree_add_item(tree, hf_gsm_a_bssmap_data_channel_rate_and_type,
1633 | tvb, curr_offset, 1, ENC_NA0x00000000);
1634 |
1635 | curr_offset++;
1636 |
1637 | NO_MORE_DATA_CHECK(len)if ((len) <= (curr_offset - offset)) return(len);;
1638 |
1639 | proto_tree_add_item(tree, hf_gsm_a_bssmap_spare, tvb, curr_offset, len - (curr_offset - offset), ENC_NA0x00000000);
1640 |
1641 | curr_offset += len - (curr_offset - offset);
1642 | }
1643 | else
1644 | {
1645 | /* unknown format */
1646 |
1647 | proto_tree_add_item(tree, hf_gsm_a_bssmap_unknown_format, tvb, curr_offset, len - (curr_offset - offset), ENC_NA0x00000000);
1648 |
1649 | curr_offset += len - (curr_offset - offset);
1650 | }
1651 |
1652 | EXTRANEOUS_DATA_CHECK(len, curr_offset - offset, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((len) > (curr_offset - offset)) { proto_tree_add_expert (tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset , (len) - (curr_offset - offset)); curr_offset += ((len) - (curr_offset - offset)); };
1653 |
1654 | return curr_offset-offset;
1655 | }
1656 | /*
1657 | * 3.2.2.12 Periodicity
1658 | */
1659 | static uint16_t
1660 | be_periodicity(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
1661 | {
1662 | uint32_t curr_offset;
1663 |
1664 | curr_offset = offset;
1665 | proto_tree_add_item(tree, hf_gsm_a_bssmap_periodicity, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1666 | curr_offset++;
1667 |
1668 | return curr_offset-offset;
1669 | }
1670 | /*
1671 | * 3.2.2.13 Extended Resource Indicator
1672 | */
1673 | #if 0
1674 | static const true_false_string bssmap_tarr_vals = {
1675 | "The total number of accessible channels is requested",
1676 | "No extra Resource Information is requested"
1677 | };
1678 | #endif
1679 | static uint16_t
1680 | be_ext_res_ind(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
1681 | {
1682 | uint32_t curr_offset;
1683 |
1684 | curr_offset = offset;
1685 |
1686 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 6, ENC_BIG_ENDIAN0x00000000);
1687 | /* the Subsequent Mode field */
1688 | proto_tree_add_item(tree, hf_gsm_a_bssmap_sm, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1689 | /* Total Accessible Resource Requested field */
1690 | proto_tree_add_item(tree, hf_gsm_a_bssmap_tarr, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1691 | curr_offset++;
1692 |
1693 |
1694 | return curr_offset-offset;
1695 | }
1696 | /*
1697 | * 3.2.2.14 Total Resource Accessible
1698 | */
1699 | static uint16_t
1700 | be_tot_res_acc(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
1701 | {
1702 | uint32_t curr_offset;
1703 |
1704 | curr_offset = offset;
1705 |
1706 | /* Total number of accessible full rate channels */
1707 | proto_tree_add_item(tree, hf_gsm_a_bssmap_tot_no_of_fullr_ch, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
1708 | curr_offset+=2;
1709 | /* Total number of accessible half rate channels */
1710 | proto_tree_add_item(tree, hf_gsm_a_bssmap_tot_no_of_hr_ch, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
1711 | /*curr_offset+=2;*/
1712 |
1713 |
1714 | return len;
1715 | }
1716 | /*
1717 | * 3.2.2.15 LSA Identifier
1718 | * The octets 3-5 are coded as specified in 3GPP TS 23.003, 'Identification of Localised Service Area'. Bit 8 of octet 3 is the MSB.
1719 | */
1720 | static uint16_t
1721 | be_lsa_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
1722 | {
1723 | uint32_t curr_offset;
1724 |
1725 | curr_offset = offset;
1726 |
1727 | /* TS 23.003:
1728 | * The LSA ID consists of 24 bits, numbered from 0 to 23, with bit 0 being the LSB.
1729 | * Bit 0 indicates whether the LSA is a PLMN significant number or a universal LSA.
1730 | * If the bit is set to 0 the LSA is a PLMN significant number; if it is set to
1731 | * 1 it is a universal LSA.
1732 | */
1733 | proto_tree_add_item(tree, hf_gsm_a_bssmap_lsa_id, tvb, curr_offset, 3, ENC_BIG_ENDIAN0x00000000);
1734 | /*curr_offset+=3;*/
1735 |
1736 |
1737 | return len;
1738 | }
1739 |
1740 |
1741 | /*
1742 | * 3.2.2.16 LSA Identifier List
1743 | */
1744 | static uint16_t
1745 | be_lsa_id_list(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
1746 | {
1747 | uint32_t curr_offset;
1748 |
1749 | curr_offset = offset;
1750 |
1751 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 7, ENC_BIG_ENDIAN0x00000000);
1752 | proto_tree_add_item(tree, hf_gsm_a_bssmap_ep, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1753 | curr_offset++;
1754 |
1755 | /* LSA identification 1 - n */
1756 |
1757 | while (curr_offset-offset < len) {
1758 | proto_tree_add_item(tree, hf_gsm_a_bssmap_lsa_id, tvb, curr_offset, 3, ENC_BIG_ENDIAN0x00000000);
1759 | curr_offset+=3;
1760 | }
1761 |
1762 | return len;
1763 | }
1764 | /*
1765 | * [2] 3.2.2.17 Cell Identifier
1766 | * Formats everything after the discriminator, shared function
1767 | */
1768 | uint16_t
1769 | be_cell_id_type(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string, int string_len, uint8_t disc, e212_number_type_t number_type)
1770 | {
1771 | uint32_t value;
1772 | uint32_t curr_offset;
1773 |
1774 | if (add_string)
1775 | add_string[0] = '\0';
1776 | curr_offset = offset;
1777 |
1778 | switch (disc)
1779 | {
1780 | case 0x00:
1781 | /* FALLTHRU */
1782 |
1783 | case 0x04:
1784 | /* FALLTHRU */
1785 |
1786 | case 0x08: /* For intersystem handover from GSM to UMTS or cdma2000: */
1787 | /* FALLTHRU */
1788 | case 0xb:
1789 | /* Serving Area Identity, SAI, is used to identify the Serving Area of UE
1790 | * within UTRAN or cdma2000.
1791 | * Coding of Cell Identification for Cell identification discriminator = 1011
1792 | * The coding of SAI is defined in 3GPP TS 25.413, without the protocol extension
1793 | * container.
1794 | * TS 25.413:
1795 | * SAI ::= SEQUENCE {
1796 | * pLMNidentity PLMNidentity,
1797 | * lAC LAC,
1798 | * sAC SAC,
1799 | * iE-Extensions ProtocolExtensionContainer { {SAI-ExtIEs} } OPTIONAL
1800 | * }
1801 | */
1802 | /* FALLTHRU */
1803 | case 0x0c: /* For identification of a UTRAN cell for cell load information: */
1804 | if (disc != 0x0b)
1805 | curr_offset = dissect_e212_mcc_mnc(tvb, pinfo, tree, curr_offset, number_type, true1);
1806 | else
1807 | curr_offset = dissect_e212_mcc_mnc(tvb, pinfo, tree, curr_offset, number_type, false0);
1808 | /* FALLTHRU */
1809 |
1810 | case 0x01:
1811 | case 0x05:
1812 | case 0x0a: /*For intersystem handover from GSM to UMTS or cdma2000: */
1813 | /* LAC */
1814 | value = tvb_get_ntohs(tvb, curr_offset);
1815 | proto_tree_add_item(tree, hf_gsm_a_bssmap_cell_lac, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
1816 | curr_offset += 2;
1817 |
1818 | if (add_string)
1819 | snprintf(add_string, string_len, " - LAC (0x%04x)", value);
1820 | if (disc == 0x0b) {
1821 | /* If SAI, SAC follows */
1822 | value = tvb_get_ntohs(tvb, curr_offset);
1823 | proto_tree_add_item(tree, hf_gsm_a_bssmap_sac, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
1824 | if (add_string) {
1825 | char *str = ws_strdup_printf("%s/SAC (%u)", add_string, value)wmem_strdup_printf(((void*)0), "%s/SAC (%u)", add_string, value );
1826 | (void) g_strlcpy(add_string, str, string_len);
1827 | g_free(str)(__builtin_object_size ((str), 0) != ((size_t) - 1)) ? g_free_sized (str, __builtin_object_size ((str), 0)) : (g_free) (str);
1828 | }
1829 | curr_offset += 2;
1830 | break;
1831 | }
1832 | /* FALLTHRU */
1833 |
1834 | case 0x09: /* For intersystem handover from GSM to UMTS or cdma2000: */
1835 |
1836 | if ((disc == 0x08) ||(disc == 0x09) || (disc == 0x0a)|| (disc == 0x0c)) {
1837 | /* RNC-ID
1838 | * The octets 9-10 are coded as the RNC-ID (0..4095) or the
1839 | * Extended RNC-ID (4096..65535) specified in 3GPP TS 25.413 [31]:
1840 | * XXX is this a PER encoded number?
1841 | */
1842 | value = tvb_get_ntohs(tvb, curr_offset);
1843 | proto_tree_add_item(tree, hf_gsm_a_bssmap_be_rnc_id, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
1844 | curr_offset += 2;
1845 |
1846 | if (add_string)
1847 | {
1848 | if (add_string[0] == '\0')
1849 | {
1850 | snprintf(add_string, string_len, " - RNC-ID (%u)", value);
1851 | }
1852 | else
1853 | {
1854 | char *str = ws_strdup_printf("%s/RNC-ID (%u)", add_string, value)wmem_strdup_printf(((void*)0), "%s/RNC-ID (%u)", add_string, value );
1855 | g_strlcpy(add_string, str, string_len);
1856 | g_free(str)(__builtin_object_size ((str), 0) != ((size_t) - 1)) ? g_free_sized (str, __builtin_object_size ((str), 0)) : (g_free) (str);
1857 | }
1858 | }
1859 | if (disc != 0x0c) {
1860 | break;
1861 | }
1862 | /* FALLTHRU */
1863 | }
1864 |
1865 | if ((disc == 0x04) || (disc == 0x05) || (disc == 0x08)) break;
1866 |
1867 | /* FALLTHRU */
1868 |
1869 | case 0x02:
1870 | /* CI */
1871 |
1872 | value = tvb_get_ntohs(tvb, curr_offset);
1873 | proto_tree_add_uint(tree, hf_gsm_a_bssmap_cell_ci, tvb,
1874 | curr_offset, 2, value);
1875 |
1876 | curr_offset += 2;
1877 |
1878 | if (add_string)
1879 | {
1880 | if (add_string[0] == '\0')
1881 | {
1882 | snprintf(add_string, string_len, " - CI (%u)", value);
1883 | }
1884 | else
1885 | {
1886 | char *str = ws_strdup_printf("%s/CI (%u)", add_string, value)wmem_strdup_printf(((void*)0), "%s/CI (%u)", add_string, value );
1887 | g_strlcpy(add_string, str, string_len);
1888 | g_free(str)(__builtin_object_size ((str), 0) != ((size_t) - 1)) ? g_free_sized (str, __builtin_object_size ((str), 0)) : (g_free) (str);
1889 | }
1890 | }
1891 | break;
1892 | default:
1893 | proto_tree_add_item(tree, hf_gsm_a_bssmap_cell_id_unknown_format, tvb, curr_offset, len, ENC_NA0x00000000);
1894 |
1895 | curr_offset += (len);
1896 | break;
1897 | }
1898 |
1899 | return curr_offset-offset;
1900 | }
1901 |
1902 | uint16_t
1903 | be_cell_id_aux(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string, int string_len, uint8_t disc)
1904 | {
1905 | return be_cell_id_type(tvb, tree, pinfo, offset, len, add_string, string_len, disc, E212_NONE);
1906 | }
1907 |
1908 | static uint16_t
1909 | be_cell_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string, int string_len)
1910 | {
1911 | uint8_t oct;
1912 | uint8_t disc;
1913 | uint32_t curr_offset;
1914 |
1915 | curr_offset = offset;
1916 |
1917 | oct = tvb_get_uint8(tvb, curr_offset);
1918 |
1919 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
1920 | proto_tree_add_item(tree, hf_gsm_a_bssmap_be_cell_id_disc, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1921 | disc = oct&0x0f;
1922 | cell_discriminator = disc; /* may be required later */
1923 | curr_offset++;
1924 |
1925 | NO_MORE_DATA_CHECK(len)if ((len) <= (curr_offset - offset)) return(len);;
1926 |
1927 | curr_offset +=
1928 | be_cell_id_aux(tvb, tree, pinfo, curr_offset, len - (curr_offset - offset), add_string, string_len, disc);
1929 |
1930 | /* no length check possible */
1931 |
1932 | return curr_offset-offset;
1933 | }
1934 |
1935 | /*
1936 | * [2] 3.2.2.18 Priority
1937 | */
1938 | static const true_false_string bssmap_pci_value = {
1939 | "This allocation request may preempt an existing connection",
1940 | "This allocation request shall not preempt an existing connection"
1941 | };
1942 |
1943 | static const true_false_string bssmap_pvi_value = {
1944 | "This connection might be preempted by another allocation request",
1945 | "This connection shall not be preempted by another allocation request"
1946 | };
1947 |
1948 | static const range_string bssmap_prio_rvals[] = {
1949 | { 0x00, 0x00, "Spare" },
1950 | { 0x01, 0x0E, "1 is highest" },
1951 | { 0x0F, 0x0f, "priority not used" },
1952 | { 0, 0, NULL((void*)0) },
1953 | };
1954 |
1955 | uint16_t
1956 | be_prio(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string, int string_len)
1957 | {
1958 | uint8_t oct;
1959 | uint32_t curr_offset;
1960 |
1961 | curr_offset = offset;
1962 |
1963 | oct = tvb_get_uint8(tvb, curr_offset);
1964 |
1965 | proto_tree_add_item(tree, hf_gsm_a_b8spare, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1966 | proto_tree_add_item(tree, hf_gsm_a_bssmap_pci, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1967 | proto_tree_add_item(tree, hf_gsm_a_bssmap_priority_level, tvb, curr_offset, 1, ENC_NA0x00000000);
1968 |
1969 | if (add_string)
1970 | snprintf(add_string, string_len, " - (%u)", (oct & 0x3c) >> 2);
1971 |
1972 | proto_tree_add_item(tree, hf_gsm_a_bssmap_qa, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1973 | proto_tree_add_item(tree, hf_gsm_a_bssmap_pvi, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
1974 |
1975 | curr_offset++;
1976 |
1977 | /* no length check possible */
1978 |
1979 | return curr_offset-offset;
1980 | }
1981 | /*
1982 | * 3.2.2.19 Classmark Information Type 2
1983 | * The classmark octets 3, 4 and 5 are coded in the same way as the
1984 | * equivalent octets in the Mobile station classmark 2 element of
1985 | * 3GPP TS 24.008
1986 | * dissected in packet-gsm_a_common.c
1987 | */
1988 | /*
1989 | * 3.2.2.20 Classmark Information Type 3
1990 | * The classmark octets 3 to 34 are coded in the same way as the
1991 | * equivalent octets in the Mobile station classmark 3 element of
1992 | * 3GPP TS 24.008.
1993 | * dissected in packet-gsm_a_common.c
1994 | */
1995 | /*
1996 | * 3.2.2.21 Interference Band To Be Used
1997 | */
1998 | static uint16_t
1999 | be_int_band(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2000 | {
2001 | uint32_t curr_offset;
2002 |
2003 | curr_offset = offset;
2004 |
2005 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 3, ENC_BIG_ENDIAN0x00000000);
2006 | proto_tree_add_item(tree, hf_gsm_a_bssmap_interference_bands, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2007 | curr_offset++;
2008 |
2009 |
2010 | return curr_offset-offset;
2011 | }
2012 | /*
2013 | * 3.2.2.22 RR Cause
2014 | * Octet 2 is coded as the equivalent field from 3GPP TS 24.008
2015 | * Dissected in packet-gsm_a_rr.c
2016 | */
2017 | /*
2018 | * 3.2.2.23 LSA Information
2019 | */
2020 |
2021 | static const true_false_string bssmap_lsa_only_value = {
2022 | "Access to the LSAs that are defined",
2023 | "Allowing emergency call"
2024 | };
2025 |
2026 | static uint16_t
2027 | be_lsa_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2028 | {
2029 | uint32_t curr_offset;
2030 |
2031 | curr_offset = offset;
2032 |
2033 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 7, ENC_BIG_ENDIAN0x00000000);
2034 | proto_tree_add_item(tree, hf_gsm_a_bssmap_lsa_only, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2035 | curr_offset++;
2036 |
2037 | while (curr_offset-offset < len) {
2038 | /* LSA identification and attributes */
2039 | /* 8 7 6 5 4 3 2 1
2040 | * spare act pref priority
2041 | */
2042 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 2, ENC_BIG_ENDIAN0x00000000);
2043 | proto_tree_add_item(tree, hf_gsm_a_bssmap_act, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2044 | proto_tree_add_item(tree, hf_gsm_a_bssmap_pref, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2045 | proto_tree_add_item(tree, hf_gsm_a_bssmap_lsa_inf_prio, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2046 | curr_offset++;
2047 | proto_tree_add_item(tree, hf_gsm_a_bssmap_lsa_id, tvb, curr_offset, 3, ENC_BIG_ENDIAN0x00000000);
2048 | curr_offset+=3;
2049 | }
2050 |
2051 | return len;
2052 | }
2053 | /*
2054 | * [2] 3.2.2.24 Layer 3 Information
2055 | */
2056 | static uint16_t
2057 | be_l3_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2058 | {
2059 | uint32_t curr_offset;
2060 | tvbuff_t *l3_tvb;
2061 | proto_item* ti;
2062 |
2063 | curr_offset = offset;
2064 |
2065 | proto_tree_add_bytes_format(tree, hf_gsm_a_bssmap_layer_3_information_value, tvb, curr_offset, len, NULL((void*)0),
2066 | "Layer 3 Information value");
2067 |
2068 | /*
2069 | * dissect the embedded DTAP message
2070 | */
2071 | l3_tvb = tvb_new_subset_length(tvb, curr_offset, len);
2072 |
2073 | /* This information element carries a radio interface message.
2074 | In the case of an Intersystem handover to UMTS,
2075 | this information element contains a HANDOVER TO UTRAN COMMAND message
2076 | as defined in 3GPP TS 25.331.
2077 | In the case of an Inter BSC handover,
2078 | it contains an RR HANDOVER COMMAND message as defined in 3GPP TS 44.018.
2079 | In the case of an Intersystem handover to cdma2000,
2080 | this information element contains the HANDOVER TO CDMA2000 COMMAND message,
2081 | as defined in 3GPP TS 44.018. */
2082 |
2083 | /* note that we can't (from this PDU alone) determine whether a handover is to UMTS or cdma2000
2084 | Maybe if cdma2000 support is added later, a preference option would select dissection of cdma2000 or UMTS.
2085 | If SCCP trace is enabled (and the cell discriminator has correctly appeared in an earlier PDU)
2086 | then we will have remembered the discriminator */
2087 | if ( cell_discriminator == 0xFF)
2088 | {
2089 | ti = proto_tree_add_uint_format(tree, hf_gsm_a_bssmap_cell_discriminator, l3_tvb, curr_offset, 1, cell_discriminator,
2090 | "Cell Discriminator not initialised, try enabling the SCCP protocol option [Trace Associations], \n or maybe the file does not contain the PDUs needed for SCCP trace");
2091 | proto_item_set_len(ti, len);
2092 | }
2093 | else if ((cell_discriminator & 0x0f) < 8) {
2094 | ti = proto_tree_add_uint(tree, hf_gsm_a_bssmap_cell_discriminator, l3_tvb, curr_offset, 1, cell_discriminator);
2095 | /* cell_discriminator is a preference, so value should be known, but keeping presence of field consistent for filtering */
2096 | proto_item_set_hidden(ti);
2097 |
2098 | /* GSM */
2099 | call_dissector(dtap_handle, l3_tvb, pinfo, g_tree);
2100 | }
2101 | else if ((cell_discriminator & 0x0f) < 13) {
2102 | ti = proto_tree_add_uint(tree, hf_gsm_a_bssmap_cell_discriminator, l3_tvb, curr_offset, 1, cell_discriminator);
2103 | /* cell_discriminator is a preference, so value should be known, but keeping presence of field consistent for filtering */
2104 | proto_item_set_hidden(ti);
2105 |
2106 | /* UMTS or CDMA 2000 */
2107 | dissect_rrc_HandoverToUTRANCommand_PDU(l3_tvb, pinfo, g_tree, NULL((void*)0));
2108 | }
2109 | else{
2110 | ti = proto_tree_add_uint_format(tree, hf_gsm_a_bssmap_cell_discriminator, l3_tvb, curr_offset, 1, cell_discriminator,
2111 | "Unrecognised Cell Discriminator %x",cell_discriminator);
2112 | proto_item_set_len(ti, len);
2113 | }
2114 | curr_offset += len;
2115 |
2116 | EXTRANEOUS_DATA_CHECK(len, curr_offset - offset, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((len) > (curr_offset - offset)) { proto_tree_add_expert (tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset , (len) - (curr_offset - offset)); curr_offset += ((len) - (curr_offset - offset)); };
2117 |
2118 | return curr_offset-offset;
2119 | }
2120 |
2121 | /*
2122 | * [2] 3.2.2.25 DLCI
2123 | */
2124 | static uint16_t
2125 | be_dlci(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2126 | {
2127 | uint8_t oct;
2128 | uint32_t curr_offset;
2129 | proto_tree *subtree;
2130 |
2131 | curr_offset = offset;
2132 |
2133 | subtree =
2134 | proto_tree_add_subtree(tree, tvb, curr_offset, 1,
2135 | ett_dlci, NULL((void*)0), "Data Link Connection Identifier");
2136 |
2137 | oct = tvb_get_uint8(tvb, curr_offset);
2138 |
2139 | proto_tree_add_uint(subtree, hf_gsm_a_bssmap_dlci_cc, tvb, curr_offset, 1, oct);
2140 | proto_tree_add_uint(subtree, hf_gsm_a_bssmap_dlci_spare, tvb, curr_offset, 1, oct);
2141 | proto_tree_add_uint(subtree, hf_gsm_a_bssmap_dlci_sapi, tvb, curr_offset, 1, oct);
2142 |
2143 | curr_offset++;
2144 |
2145 | /* no length check possible */
2146 |
2147 | return curr_offset-offset;
2148 | }
2149 |
2150 | /*
2151 | * [2] 3.2.2.26 Downlink DTX Flag
2152 | */
2153 | static uint16_t
2154 | be_down_dtx_flag(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2155 | {
2156 | uint32_t curr_offset = offset;
2157 |
2158 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 7, ENC_BIG_ENDIAN0x00000000);
2159 | proto_tree_add_item(tree, hf_gsm_a_bssmap_bss_activate_downlink, tvb, curr_offset, 1, ENC_NA0x00000000);
2160 | curr_offset++;
2161 |
2162 | /* no length check possible */
2163 |
2164 | return curr_offset-offset;
2165 | }
2166 |
2167 | /*
2168 | * [2] 3.2.2.27 Cell Identifier List
2169 | */
2170 | uint16_t
2171 | be_cell_id_list(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string, int string_len)
2172 | {
2173 | uint8_t oct;
2174 | uint16_t consumed;
2175 | uint8_t disc;
2176 | uint8_t num_cells;
2177 | uint32_t curr_offset;
2178 | proto_item *item = NULL((void*)0);
2179 | proto_tree *subtree = NULL((void*)0);
2180 |
2181 | curr_offset = offset;
2182 |
2183 | oct = tvb_get_uint8(tvb, curr_offset);
2184 |
2185 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
2186 |
2187 | disc = oct & 0x0f;
2188 | cell_discriminator = disc; /* may be required later */
2189 | proto_tree_add_item(tree, hf_gsm_a_bssmap_be_cell_id_disc, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2190 | curr_offset++;
2191 |
2192 | NO_MORE_DATA_CHECK(len)if ((len) <= (curr_offset - offset)) return(len);;
2193 |
2194 | num_cells = 0;
2195 | do
2196 | {
2197 | subtree =
2198 | proto_tree_add_subtree_format(tree,
2199 | tvb, curr_offset, -1,
2200 | ett_cell_list, &item, "Cell %u",
2201 | num_cells + 1);
2202 |
2203 | if (add_string)
2204 | add_string[0] = '\0';
2205 |
2206 | consumed =
2207 | be_cell_id_aux(tvb, subtree, pinfo, curr_offset, len - (curr_offset - offset), add_string, string_len, disc);
2208 |
2209 | if (add_string && add_string[0] != '\0')
2210 | proto_item_append_text(item, "%s", add_string);
2211 |
2212 | proto_item_set_len(item, consumed);
2213 |
2214 | curr_offset += consumed;
2215 |
2216 | num_cells++;
2217 | }
2218 | while ((len - (curr_offset - offset)) > 0 && consumed > 0);
2219 |
2220 | if (add_string) {
2221 | snprintf(add_string, string_len, " - %u cell%s",
2222 | num_cells, plurality(num_cells, "", "s")((num_cells) == 1 ? ("") : ("s")));
2223 | }
2224 |
2225 | EXTRANEOUS_DATA_CHECK(len, curr_offset - offset, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((len) > (curr_offset - offset)) { proto_tree_add_expert (tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset , (len) - (curr_offset - offset)); curr_offset += ((len) - (curr_offset - offset)); };
2226 |
2227 | return curr_offset-offset;
2228 | }
2229 | /*
2230 | * 3.2.2.27a Cell Identifier List Segment
2231 | */
2232 |
2233 | static const value_string gsm_a_bssap_cell_id_list_seg_cell_id_disc_vals[] = {
2234 | { 0x0, "The whole Cell Global Identification, CGI, is used to identify the cells"},
2235 | { 0x1, "Location Area Code, LAC, and Cell Identify, CI, is used to identify the cells within a given MCC and MNC"},
2236 | { 0x2, "Cell Identity, CI, is used to identify the cells within a given MCC and MNC and LAC"},
2237 | { 0x3, "No cell is associated with the transaction"},
2238 | { 0x4, "Location Area Identification, LAI, is used to identify all cells within a Location Area"},
2239 | { 0x5, "Location Area Code, LAC, is used to identify all cells within a location area"},
2240 | { 0x6, "All cells on the BSS are identified"},
2241 | { 0x7, "MCC and MNC, is used to identify all cells within the given MCC and MNC"},
2242 | { 0, NULL((void*)0) }
2243 | };
2244 |
2245 | static uint16_t
2246 | be_cell_id_list_seg(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2247 | {
2248 | uint32_t curr_offset;
2249 |
2250 | curr_offset = offset;
2251 |
2252 | /* Sequence Length */
2253 | proto_tree_add_item(tree, hf_gsm_a_bssmap_seq_len, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2254 | /* Sequence Number */
2255 | proto_tree_add_item(tree, hf_gsm_a_bssmap_seq_no, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2256 | curr_offset++;
2257 |
2258 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
2259 | /* Cell identification discriminator */
2260 | proto_tree_add_item(tree, hf_gsm_a_bssap_cell_id_list_seg_cell_id_disc, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2261 | curr_offset++;
2262 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len-2);
2263 |
2264 |
2265 | return len;
2266 | }
2267 |
2268 | /*
2269 | * 3.2.2.27b Cell Identifier List Segment for established cells
2270 | */
2271 | static uint16_t
2272 | be_cell_id_lst_seg_f_est_cells(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2273 | {
2274 | uint32_t curr_offset;
2275 |
2276 | curr_offset = offset;
2277 |
2278 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
2279 | /* Cell identification discriminator */
2280 | proto_tree_add_item(tree, hf_gsm_a_bssap_cell_id_list_seg_cell_id_disc, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2281 | curr_offset++;
2282 |
2283 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len-1);
2284 |
2285 |
2286 | return len;
2287 | }
2288 | /*
2289 | * 3.2.2.27c Cell Identifier List Segment for cells to be established
2290 | */
2291 | static uint16_t
2292 | be_cell_id_lst_seg_f_cell_tb_est(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2293 | {
2294 | uint32_t curr_offset;
2295 |
2296 | curr_offset = offset;
2297 |
2298 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
2299 | /* Cell identification discriminator */
2300 | proto_tree_add_item(tree, hf_gsm_a_bssap_cell_id_list_seg_cell_id_disc, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2301 | curr_offset++;
2302 |
2303 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len-1);
2304 |
2305 |
2306 | return len;
2307 | }
2308 | /*
2309 | * 3.2.2.27d (void)
2310 | */
2311 | /*
2312 | * 3.2.2.27e Cell Identifier List Segment for released cells - no user present
2313 | */
2314 | static uint16_t
2315 | be_cell_id_lst_seg_f_rel_cell(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2316 | {
2317 | uint32_t curr_offset;
2318 |
2319 | curr_offset = offset;
2320 |
2321 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
2322 | /* Cell identification discriminator */
2323 | proto_tree_add_item(tree, hf_gsm_a_bssap_cell_id_list_seg_cell_id_disc, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2324 | curr_offset++;
2325 |
2326 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len-1);
2327 |
2328 |
2329 | return len;
2330 | }
2331 | /*
2332 | * 3.2.2.27f Cell Identifier List Segment for not established cells - no establishment possible
2333 | */
2334 | static uint16_t
2335 | be_cell_id_lst_seg_f_not_est_cell(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2336 | {
2337 | uint32_t curr_offset;
2338 |
2339 | curr_offset = offset;
2340 |
2341 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
2342 | /* Cell identification discriminator */
2343 | proto_tree_add_item(tree, hf_gsm_a_bssap_cell_id_list_seg_cell_id_disc, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2344 | curr_offset++;
2345 |
2346 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len-1);
2347 |
2348 |
2349 | return len;
2350 | }
2351 | /*
2352 | * 3.2.2.28 Response Request
2353 | * No data
2354 | */
2355 | /*
2356 | * 3.2.2.29 Resource Indication Method
2357 | */
2358 | static const value_string gsm_a_bssap_resource_indication_vals[] = {
2359 | { 0x0, "Spontaneous resource information expected"},
2360 | { 0x1, "One single resource information expected"},
2361 | { 0x2, "Periodic resource information expected"},
2362 | { 0x3, "No cell is associated with the transaction"},
2363 | { 0x4, "No resource information expected"},
2364 | { 0, NULL((void*)0) }
2365 | };
2366 | static uint16_t
2367 | be_res_ind_method(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2368 | {
2369 | uint32_t curr_offset;
2370 |
2371 | curr_offset = offset;
2372 |
2373 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
2374 | proto_tree_add_item(tree, hf_gsm_a_bssap_res_ind_method, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2375 | curr_offset++;
2376 |
2377 | return len;
2378 | }
2379 |
2380 | /*
2381 | * 3.2.2.30 Classmark Information Type 1
2382 | * coded in the same way as the equivalent octet in the classmark 1 element of 3GPP TS 24.008
2383 | * dissected in packet-gsm_a_common.c
2384 | */
2385 | /*
2386 | * 3.2.2.31 Circuit Identity Code List
2387 | */
2388 | static uint16_t
2389 | be_cic_list(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2390 | {
2391 | uint32_t curr_offset;
2392 |
2393 | curr_offset = offset;
2394 |
2395 | proto_tree_add_item(tree, hf_gsm_a_bssap_cic_list_range, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2396 | proto_tree_add_item(tree, hf_gsm_a_bssap_cic_list_status, tvb, (curr_offset+1), (len-1), ENC_NA0x00000000);
2397 |
2398 | return len;
2399 | }
2400 | /*
2401 | * 3.2.2.32 Diagnostics
2402 | */
2403 | static uint16_t
2404 | be_diag(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len , char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2405 | {
2406 | uint32_t curr_offset;
2407 |
2408 | curr_offset = offset;
2409 |
2410 | proto_tree_add_item(tree, hf_gsm_a_bssap_diag_error_pointer, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
2411 | curr_offset += 2;
2412 | NO_MORE_DATA_CHECK(len)if ((len) <= (curr_offset - offset)) return(len);;
2413 | proto_tree_add_item(tree, hf_gsm_a_bssap_diag_msg_rcv, tvb, curr_offset, (len-2), ENC_NA0x00000000);
2414 |
2415 | return len;
2416 | }
2417 | /*
2418 | * [2] 3.2.2.33 Chosen Channel
2419 | */
2420 | static const value_string gsm_a_bssmap_ch_mode_vals[] = {
2421 | { 0, "no channel mode indication" },
2422 | { 9, "speech (full rate or half rate)" },
2423 | { 14, "data, 14.5 kbit/s radio interface rate" },
2424 | { 11, "data, 12.0 kbit/s radio interface rate" },
2425 | { 12, "data, 6.0 kbit/s radio interface rate" },
2426 | { 13, "data, 3.6 kbit/s radio interface rate" },
2427 | { 8, "signalling only" },
2428 | { 1, "data, 29.0 kbit/s radio interface rate" },
2429 | { 2, "data, 32.0 kbit/s radio interface rate" },
2430 | { 3, "data, 43.5 kbit/s radio interface rate" },
2431 | { 4, "data, 43.5 kbit/s downlink and 14.5 kbit/s uplink" },
2432 | { 5, "data, 29.0 kbit/s downlink and 14.5 kbit/s uplink" },
2433 | { 6, "data, 43.5 kbit/s downlink and 29.0 kbit/s uplink" },
2434 | { 7, "data, 14.5 kbit/s downlink and 43.5 kbit/s uplink" },
2435 | { 10, "data, 14.5 kbit/s downlink and 29.0 kbit/s uplink" },
2436 | { 15, "data, 29.0 kbit/s downlink and 43.5 kbit/s uplink" },
2437 | { 0, NULL((void*)0) }
2438 | };
2439 | static const value_string gsm_a_bssmap_channel_vals[] = {
2440 | { 0, "None(Current Channel Type 1 - Reserved)" },
2441 | { 1, "SDCCH" },
2442 | { 2, "Reserved" },
2443 | { 3, "Reserved" },
2444 | { 5, "Reserved" },
2445 | { 6, "Reserved" },
2446 | { 7, "Reserved" },
2447 | { 8, "1 Full rate TCH" },
2448 | { 9, "1 Half rate TCH" },
2449 | { 10, "2 Full Rate TCHs" },
2450 | { 11, "3 Full Rate TCHs" },
2451 | { 12, "4 Full Rate TCHs" },
2452 | { 13, "5 Full Rate TCHs" },
2453 | { 14, "6 Full Rate TCHs" },
2454 | { 15, "7 Full Rate TCHs" },
2455 | { 4, "8 Full Rate TCHs" },
2456 | { 0, NULL((void*)0) }
2457 | };
2458 | static const value_string gsm_a_bssmap_trace_bss_record_type_vals[] = {
2459 | { 0, "Basic" },
2460 | { 1, "Handover" },
2461 | { 2, "Radio" },
2462 | { 3, "No BSS Trace" },
2463 | { 0, NULL((void*)0) }
2464 | };
2465 | static const value_string gsm_a_bssmap_trace_msc_record_type_vals[] = {
2466 | { 0, "Basic" },
2467 | { 1, "Detailed (optional)" },
2468 | { 2, "Spare" },
2469 | { 3, "No MSC Trace" },
2470 | { 0, NULL((void*)0) }
2471 | };
2472 | static const value_string gsm_a_bssmap_trace_invoking_event_vals[] = {
2473 | { 0, "MOC, MTC, SMS MO, SMS MT, PDS MO, PDS MT, SS, Location Updates, IMSI attach, IMSI detach" },
2474 | { 1, "MOC, MTC, SMS_MO, SMS_MT, PDS MO, PDS MT, SS only" },
2475 | { 2, "Location updates, IMSI attach IMSI detach only" },
2476 | { 3, "Operator definable" },
2477 | { 0, NULL((void*)0) }
2478 | };
2479 | static uint16_t
2480 | be_chosen_chan(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2481 | {
2482 | uint32_t curr_offset;
2483 |
2484 | curr_offset = offset;
2485 |
2486 | /* Channel mode */
2487 | proto_tree_add_item(tree, hf_gsm_a_bssmap_ch_mode, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2488 |
2489 | proto_tree_add_item(tree, hf_gsm_a_bssmap_channel, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2490 |
2491 | curr_offset++;
2492 |
2493 | /* no length check possible */
2494 |
2495 | return curr_offset-offset;
2496 | }
2497 |
2498 | /*
2499 | * [2] 3.2.2.34 Cipher Response Mode
2500 | */
2501 | static uint16_t
2502 | be_ciph_resp_mode(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2503 | {
2504 | uint32_t curr_offset = offset;
2505 |
2506 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 7, ENC_BIG_ENDIAN0x00000000);
2507 | proto_tree_add_item(tree, hf_gsm_a_bssmap_imeisv_included, tvb, curr_offset, 1, ENC_NA0x00000000);
2508 |
2509 | curr_offset++;
2510 |
2511 | /* no length check possible */
2512 |
2513 | return curr_offset-offset;
2514 | }
2515 |
2516 |
2517 | /*
2518 | * [2] 3.2.2.35 Layer 3 Message Contents
2519 | */
2520 | static uint16_t
2521 | be_l3_msg(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2522 | {
2523 | tvbuff_t *l3_tvb;
2524 | uint16_t word;
2525 |
2526 | proto_tree_add_bytes_format(tree, hf_gsm_a_bssmap_layer3_message_contents, tvb, offset, len, NULL((void*)0),
2527 | "Layer 3 Message Contents");
2528 |
2529 | /*
2530 | * dissect the embedded DTAP message
2531 | */
2532 | l3_tvb = tvb_new_subset_length(tvb, offset, len);
2533 |
2534 | /* Some vendors do:
2535 | * Octets 3-12 contain the unchanged radio interface layer 3 message contents, as received from the radio interface.
2536 | * When received in the CIPHER MODE COMPLETE message, this IE contains the mobile identity IE with identity type set to IMEISV.
2537 | * The mobile identity IE is a variable length element and includes a length indicator, which is set to 9 if the type is IMEISV.
2538 | *
2539 | */
2540 | word = tvb_get_ntohs(tvb, offset);
2541 | if(word==0x1709){
2542 | /* start the dissection from byte 3 */
2543 | de_mid(l3_tvb, tree, pinfo, 2, 9, NULL((void*)0), 0);
2544 | return len;
2545 | }
2546 | /* Octet j (j = 3, 4, ..., n) is the unchanged octet j of a radio interface layer 3 message
2547 | * as defined in 3GPP TS 24.008, n is equal to the length of that radio interface layer 3 message. */
2548 | call_dissector(dtap_handle, l3_tvb, pinfo, g_tree);
2549 |
2550 | return len;
2551 | }
2552 |
2553 | /*
2554 | * [2] 3.2.2.36 Channel Needed
2555 | */
2556 | static uint16_t
2557 | be_cha_needed(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2558 | {
2559 | uint32_t curr_offset;
2560 |
2561 | curr_offset = offset;
2562 |
2563 | /* no length check possible */
2564 | proto_tree_add_bits_item(tree, hf_gsm_a_rr_chnl_needed_ch1, tvb, (curr_offset<<3)+6, 2, ENC_BIG_ENDIAN0x00000000);
2565 |
2566 | curr_offset++;
2567 |
2568 | return curr_offset-offset;
2569 | }
2570 | /*
2571 | * 3.2.2.37 Trace Type
2572 | * coded as the MSC/BSS Trace Type specified in 3GPP TS 52.008
2573 | */
2574 | static uint16_t
2575 | be_trace_type(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2576 | {
2577 | uint32_t curr_offset;
2578 | int bit_offset;
2579 |
2580 | bit_offset = (offset<<3);
2581 | curr_offset = offset;
2582 |
2583 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_trace_priority_indication, tvb, bit_offset, 1, ENC_BIG_ENDIAN0x00000000);
2584 | bit_offset ++;
2585 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, bit_offset, 1, ENC_BIG_ENDIAN0x00000000);
2586 | bit_offset ++;
2587 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_trace_bss_record_type, tvb, bit_offset, 2, ENC_BIG_ENDIAN0x00000000);
2588 | bit_offset += 2;
2589 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_trace_msc_record_type, tvb, bit_offset, 2, ENC_BIG_ENDIAN0x00000000);
2590 | bit_offset += 2;
2591 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_trace_invoking_event, tvb, bit_offset, 2, ENC_BIG_ENDIAN0x00000000);
2592 | /*bit_offset += 2;*/
2593 | curr_offset++;
2594 |
2595 | /* no length check possible */
2596 |
2597 | return curr_offset-offset;
2598 | }
2599 |
2600 | /*
2601 | * [2] 3.2.2.38 TriggerID
2602 | */
2603 | static uint16_t
2604 | be_trace_trigger_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2605 | {
2606 | uint32_t curr_offset;
2607 |
2608 | curr_offset = offset;
2609 |
2610 | proto_tree_add_item(tree, hf_gsm_a_bssmap_trace_trigger_id, tvb, curr_offset, len, ENC_ASCII0x00000000);
2611 | curr_offset += len;
2612 |
2613 | /* no length check possible */
2614 |
2615 | return curr_offset-offset;
2616 | }
2617 |
2618 | /* 3.2.2.39 Trace Reference */
2619 | static uint16_t
2620 | be_trace_reference(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2621 | {
2622 | uint32_t curr_offset;
2623 |
2624 | curr_offset = offset;
2625 |
2626 |
2627 | proto_tree_add_item(tree, hf_gsm_a_bssmap_trace_reference, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
2628 | curr_offset +=2;
2629 |
2630 | /* no length check possible */
2631 |
2632 | return curr_offset-offset;
2633 | }
2634 | /* 3.2.2.40 TransactionID */
2635 | static uint16_t
2636 | be_trace_transaction_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2637 | {
2638 | uint32_t curr_offset;
2639 |
2640 | curr_offset = offset;
2641 |
2642 |
2643 | if (len == 1)
2644 | {
2645 | proto_tree_add_item(tree, hf_gsm_a_bssmap_trace_reference, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2646 | curr_offset ++;
2647 | }
2648 | else
2649 | {
2650 | proto_tree_add_item(tree, hf_gsm_a_bssmap_trace_reference, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
2651 | curr_offset +=2;
2652 | }
2653 |
2654 | EXTRANEOUS_DATA_CHECK(len, curr_offset - offset, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((len) > (curr_offset - offset)) { proto_tree_add_expert (tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset , (len) - (curr_offset - offset)); curr_offset += ((len) - (curr_offset - offset)); };
2655 |
2656 | return curr_offset-offset;
2657 | }
2658 | /*
2659 | * 3.2.2.41 Mobile Identity (IMSI, IMEISV or IMEI as coded in 3GPP TS 24.008)
2660 | * Dissected in packet-gsm_a_common.c
2661 | */
2662 | /*
2663 | * 3.2.2.42 OMCID
2664 | * For the OMC identity, see 3GPP TS 52.021
2665 | */
2666 | static uint16_t
2667 | be_trace_omc_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2668 | {
2669 | uint32_t curr_offset;
2670 |
2671 | curr_offset = offset;
2672 |
2673 | proto_tree_add_item(tree, hf_gsm_a_bssmap_trace_omc_id, tvb, curr_offset, len, ENC_ASCII0x00000000);
2674 | curr_offset += len;
2675 |
2676 | /* no length check possible */
2677 |
2678 | return curr_offset-offset;
2679 | }
2680 | /*
2681 | * [2] 3.2.2.43 Forward Indicator
2682 | */
2683 | static const range_string forward_indicator_rvals[] = {
2684 | { 0x00, 0x00, "Reserved" },
2685 | { 0x01, 0x01, "forward to subsequent BSS, no trace at MSC" },
2686 | { 0x02, 0x02, "forward to subsequent BSS, and trace at MSC" },
2687 | { 0x03, 0x0F, "Reserved" },
2688 | { 0, 0, NULL((void*)0) },
2689 | };
2690 |
2691 | static uint16_t
2692 | be_for_ind(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2693 | {
2694 | uint32_t curr_offset = offset;
2695 |
2696 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
2697 | proto_tree_add_item(tree, hf_gsm_a_bssmap_forward_indicator, tvb, curr_offset, 1, ENC_NA0x00000000);
2698 | curr_offset++;
2699 |
2700 | /* no length check possible */
2701 |
2702 | return curr_offset-offset;
2703 | }
2704 |
2705 | /*
2706 | * [2] 3.2.2.44 Chosen Encryption Algorithm
2707 | */
2708 | static const value_string gsm_a_bssmap_algorithm_id_vals[] = {
2709 | { 1, "No encryption used" },
2710 | { 2, "GSM A5/1" },
2711 | { 3, "GSM A5/2" },
2712 | { 4, "GSM A5/3" },
2713 | { 5, "GSM A5/4" },
2714 | { 6, "GSM A5/5" },
2715 | { 7, "GSM A5/6" },
2716 | { 8, "GSM A5/7" },
2717 | { 0, NULL((void*)0) }
2718 | };
2719 |
2720 | static uint16_t
2721 | be_chosen_enc_alg(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string, int string_len)
2722 | {
2723 | uint8_t oct;
2724 | uint32_t curr_offset;
2725 |
2726 | curr_offset = offset;
2727 |
2728 | oct = tvb_get_uint8(tvb, curr_offset);
2729 |
2730 | proto_tree_add_item(tree, hf_gsm_a_bssmap_algorithm_identifier, tvb, curr_offset, 1, ENC_NA0x00000000);
2731 |
2732 | curr_offset++;
2733 |
2734 | if (add_string)
2735 | snprintf(add_string, string_len, " - %s", val_to_str_const(oct, gsm_a_bssmap_algorithm_id_vals, "Unknown"));
2736 |
2737 | /* no length check possible */
2738 |
2739 | return curr_offset-offset;
2740 | }
2741 |
2742 | /*
2743 | * [2] 3.2.2.45 Circuit Pool
2744 | */
2745 | static uint16_t
2746 | be_cct_pool(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string, int string_len)
2747 | {
2748 | uint8_t oct;
2749 | uint32_t curr_offset;
2750 | proto_item* ti;
2751 |
2752 | curr_offset = offset;
2753 |
2754 | oct = tvb_get_uint8(tvb, curr_offset);
2755 |
2756 | ti = proto_tree_add_item(tree, hf_gsm_a_bssmap_circuit_pool_number, tvb, curr_offset, 1, ENC_NA0x00000000);
2757 | if (oct <= 50)
2758 | {
2759 | /* No extra string */
2760 | }
2761 | else if ((oct >= 0x80) && (oct <= 0x8f))
2762 | {
2763 | proto_item_append_text(ti, ", for national/local use");
2764 | }
2765 | else
2766 | {
2767 | proto_item_append_text(ti, ", reserved for future international use");
2768 | }
2769 |
2770 | curr_offset++;
2771 |
2772 | if (add_string)
2773 | snprintf(add_string, string_len, " - (%u)", oct);
2774 |
2775 | /* no length check possible */
2776 |
2777 | return curr_offset-offset;
2778 | }
2779 | /*
2780 | * 3.2.2.46 Circuit Pool List
2781 | * 3.2.2.47 Time Indication
2782 | * 3.2.2.48 Resource Situation
2783 | */
2784 | /*
2785 | * [2] 3.2.2.49 Current Channel Type 1
2786 | */
2787 | static uint16_t
2788 | be_curr_chan_1(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2789 | {
2790 | uint32_t curr_offset;
2791 |
2792 | curr_offset = offset;
2793 |
2794 | /* Channel mode */
2795 | proto_tree_add_item(tree, hf_gsm_a_bssmap_cur_ch_mode, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2796 | /* Channel */
2797 | proto_tree_add_item(tree, hf_gsm_a_bssmap_channel, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2798 |
2799 | curr_offset++;
2800 |
2801 | /* no length check possible */
2802 |
2803 | return curr_offset-offset;
2804 | }
2805 |
2806 | /*
2807 | * [2] 3.2.2.50 Queuing Indicator
2808 | */
2809 | static uint16_t
2810 | be_que_ind(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2811 | {
2812 | uint32_t curr_offset = offset;
2813 |
2814 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 6, ENC_BIG_ENDIAN0x00000000);
2815 | proto_tree_add_item(tree, hf_gsm_a_bssmap_qri, tvb, curr_offset, 1, ENC_NA0x00000000);
2816 |
2817 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, (curr_offset<<3)+7, 1, ENC_BIG_ENDIAN0x00000000);
2818 |
2819 | curr_offset++;
2820 |
2821 | /* no length check possible */
2822 |
2823 | return curr_offset-offset;
2824 | }
2825 |
2826 | /*
2827 | * [2] 3.2.2.51 Speech Version
2828 | */
2829 | static const range_string speech_version_id_rvals[] = {
2830 | { 0x01, 0x01, "GSM speech full rate version 1" },
2831 | { 0x02, 0x04, "Reserved" },
2832 | { 0x05, 0x05, "GSM speech half rate version 1" },
2833 | { 0x06, 0x10, "Reserved" },
2834 | { 0x11, 0x11, "GSM speech full rate version 2 (EFR)" },
2835 | { 0x12, 0x14, "Reserved" },
2836 | { 0x15, 0x15, "GSM speech half rate version 2" },
2837 | { 0x16, 0x20, "Reserved" },
2838 | { 0x21, 0x21, "GSM speech full rate version 3 (AMR)" },
2839 | { 0x22, 0x24, "Reserved" },
2840 | { 0x25, 0x25, "GSM speech half rate version 3 (AMR)" },
2841 | { 0x26, 0x40, "Reserved" },
2842 | { 0x41, 0x41, "GSM speech full rate version 4 (AMR-WB)" },
2843 | { 0x42, 0x42, "GSM speech full rate version 5 (AMR-WB)" },
2844 | { 0x43, 0x44, "Reserved" },
2845 | { 0x45, 0x45, "GSM speech half rate version 6 (AMR)" },
2846 | { 0x46, 0x46, "GSM speech half rate version 4 (AMR-WB)" },
2847 | { 0x47, 0x7f, "Reserved" },
2848 |
2849 | { 0, 0, NULL((void*)0) },
2850 | };
2851 |
2852 | static const range_string speech_version_id_short_rvals[] = {
2853 | { 0x01, 0x01, "FR1" },
2854 | { 0x05, 0x05, "HR1" },
2855 | { 0x11, 0x11, "FR2 (EFR)" },
2856 | { 0x15, 0x15, "HR2" },
2857 | { 0x21, 0x21, "FR3 (AMR)" },
2858 | { 0x25, 0x25, "HR3 (AMR)" },
2859 | { 0x41, 0x41, "OFR AMR-WB" },
2860 | { 0x42, 0x42, "FR AMR-WB" },
2861 | { 0x45, 0x45, "OHR AMR" },
2862 | { 0x46, 0x46, "OHR AMR-WB" },
2863 |
2864 | { 0, 0, NULL((void*)0) },
2865 | };
2866 |
2867 | static uint16_t
2868 | be_speech_ver(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string, int string_len)
2869 | {
2870 | uint8_t oct;
2871 | uint32_t curr_offset;
2872 |
2873 | curr_offset = offset;
2874 |
2875 | oct = tvb_get_uint8(tvb, curr_offset);
2876 |
2877 | proto_tree_add_item(tree, hf_gsm_a_b8spare, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2878 |
2879 | /* The bits 7-1 of octet 2 are coded in the same way as the permitted speech version identifier
2880 | * in the Channel type information element.
2881 | */
2882 | proto_tree_add_item(tree, hf_gsm_a_bssmap_speech_version_id, tvb, curr_offset, 1, ENC_NA0x00000000);
2883 | curr_offset++;
2884 |
2885 | if (add_string)
2886 | snprintf(add_string, string_len, " - (%s)", rval_to_str_const(oct & 0x7f, speech_version_id_short_rvals, "Reserved"));
2887 |
2888 | /* no length check possible */
2889 |
2890 | return curr_offset-offset;
2891 | }
2892 | /*
2893 | * 3.2.2.52 Assignment Requirement
2894 | */
2895 | static const value_string gsm_a_bssmap_assignment_requirement_vals[] = {
2896 | { 0x00, "Delay allowed" },
2897 | { 0x01, "Immediate and the resources shall not be de-allocated until the end of the call (channel establishment on demand forbidden by the MSC)" },
2898 | { 0x02, "Immediate and the resources may further be de-allocated by the BSS (channel establishment on demand permitted by the MSC)." },
2899 | { 0, NULL((void*)0) }
2900 | };
2901 | static uint16_t
2902 | be_ass_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2903 | {
2904 | proto_tree_add_item(tree, hf_gsm_a_bssmap_ass_req, tvb, offset, 1, ENC_BIG_ENDIAN0x00000000);
2905 |
2906 | return 1;
2907 | }
2908 | /*
2909 | * 3.2.2.53 (void)
2910 | */
2911 | /*
2912 | * 3.2.2.54 Talker Flag
2913 | * No data
2914 | */
2915 | /*
2916 | * 3.2.2.55 Group Call Reference
2917 | * The octets 3-7 are coded in the same way as the octets 2-6 in the
2918 | * Descriptive group or broadcast call reference information element as defined in 3GPP TS 24.008.
2919 | * dissected in packet-gsm_a_common.c (de_d_gb_call_ref)
2920 | */
2921 | /*
2922 | * 3.2.2.56 eMLPP Priority
2923 | * The call priority field (bit 3 to 1 of octet 2) is coded in the same way as the call priority field
2924 | * (bit 3 to 1 of octet 5) in the Descriptive group or broadcast call reference information element as
2925 | * defined in 3GPP TS 24.008.
2926 | */
2927 | static const value_string gsm_a_bssmap_call_priority_vals[] = {
2928 | { 0x00, "No priority applied" },
2929 | { 0x01, "Call priority level 4" },
2930 | { 0x02, "Call priority level 3" },
2931 | { 0x03, "Call priority level 2" },
2932 | { 0x04, "Call priority level 1" },
2933 | { 0x05, "Call priority level 0" },
2934 | { 0x06, "Call priority level B" },
2935 | { 0x07, "Call priority level A" },
2936 | { 0, NULL((void*)0) }
2937 | };
2938 |
2939 | uint16_t
2940 | be_emlpp_prio(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2941 | {
2942 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, offset << 3, 5, ENC_BIG_ENDIAN0x00000000);
2943 | proto_tree_add_item(tree, hf_gsm_a_bssmap_emlpp_prio, tvb, offset, 1, ENC_BIG_ENDIAN0x00000000);
2944 |
2945 | return 1;
2946 | }
2947 |
2948 | /*
2949 | * 3.2.2.57 Configuration Evolution Indication
2950 | */
2951 | static const value_string gsm_a_bssmap_smi_vals[] = {
2952 | { 0, "No Modification is allowed" },
2953 | { 1, "Modification is allowed and maximum number of TCH/F is 1" },
2954 | { 2, "Modification is allowed and maximum number of TCH/F is 2" },
2955 | { 3, "Modification is allowed and maximum number of TCH/F is 3" },
2956 | { 4, "Modification is allowed and maximum number of TCH/F is 4" },
2957 | { 5, "Reserved" },
2958 | { 6, "Reserved" },
2959 | { 7, "Reserved" },
2960 | { 0, NULL((void*)0) }
2961 | };
2962 |
2963 | static uint16_t
2964 | be_conf_evo_ind(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
2965 | {
2966 | uint32_t curr_offset;
2967 |
2968 | curr_offset = offset;
2969 |
2970 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 4, ENC_BIG_ENDIAN0x00000000);
2971 | /* Subsequent Modification Indication */
2972 | proto_tree_add_item(tree, hf_gsm_a_bssmap_smi, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
2973 | curr_offset++;
2974 |
2975 | return curr_offset-offset;
2976 | }
2977 | /*
2978 | * 3.2.2.58 Old BSS to New BSS information
2979 | */
2980 | /* This function is only called from other protocols (e.g. RANAP),
2981 | internally, the Field Element dissector is called directly */
2982 | void
2983 | bssmap_old_bss_to_new_bss_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo)
2984 | {
2985 | uint16_t len;
2986 | if (!tree) {
2987 | return;
2988 | }
2989 |
2990 | g_tree = tree;
2991 |
2992 | len = tvb_reported_length(tvb);
2993 | be_field_element_dissect(tvb, tree, pinfo, 0, len, NULL((void*)0), 0);
2994 |
2995 | g_tree = NULL((void*)0);
2996 | }
2997 | /*
2998 | * 3.2.2.59 (void)
2999 | * 3.2.2.60 LCS QoS
3000 | * (The QoS octets 3 to n are coded in the same way as the equivalent octets
3001 | * in the LCS QoS element of 3GPP TS 49.031.)
3002 | */
3003 |
3004 | /*
3005 | * 3.2.2.61 LSA Access Control Suppression
3006 | */
3007 | /*
3008 | * 3.2.2.62 LCS Priority
3009 | * The Priority octets 3 to n are coded in the same way as the equivalent octets
3010 | * in the LCS Priority element of 3GPP TS 49.031.
3011 | */
3012 | /* Location Information definitions */
3013 | static const value_string lcs_priority_vals[] = {
3014 | { 0, "highest" },
3015 | { 1, "normal" },
3016 | { 0, NULL((void*)0)}
3017 | };
3018 |
3019 | static uint16_t
3020 | be_lcs_prio(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3021 | {
3022 | uint32_t curr_offset;
3023 |
3024 | curr_offset = offset;
3025 |
3026 | /* This octet is coded as the LCS-Priority octet in 3GPP TS 29.002 */
3027 | proto_tree_add_item(tree, hf_gsm_a_bssmap_lcs_pri, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3028 | curr_offset++;
3029 |
3030 | return curr_offset-offset;
3031 | }
3032 |
3033 | /*
3034 | * 3.2.2.63 Location Type (Location Type element of 3GPP TS 49.031 BSSAP-LE.)
3035 | */
3036 | static uint16_t
3037 | be_loc_type(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3038 | {
3039 | uint32_t curr_offset;
3040 | uint8_t location_information;
3041 |
3042 | curr_offset = offset;
3043 |
3044 | /* Extract the location information and add to protocol tree */
3045 | proto_tree_add_item_ret_uint8(tree, hf_gsm_a_bssmap_location_type_location_information, tvb, offset, 1, ENC_BIG_ENDIAN0x00000000, &location_information);
3046 | curr_offset++;
3047 |
3048 | if (location_information == 1 || location_information == 2)
3049 | {
3050 | /* protocol method */
3051 | proto_tree_add_item(tree, hf_gsm_a_bssmap_location_type_positioning_method, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3052 | curr_offset++;
3053 | }
3054 |
3055 | return curr_offset-offset;
3056 | }
3057 |
3058 | /*
3059 | * 3.2.2.64 Location Estimate
3060 | * The Location Estimate field is composed of 1 or more octets with an internal structure
3061 | * according to 3GPP TS 23.032.
3062 | */
3063 | static uint16_t
3064 | be_loc_est(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3065 | {
3066 | tvbuff_t *data_tvb;
3067 | uint32_t curr_offset;
3068 |
3069 | curr_offset = offset;
3070 |
3071 | data_tvb = tvb_new_subset_length(tvb, curr_offset, len);
3072 | dissect_geographical_description(data_tvb, pinfo, tree);
3073 |
3074 | return len;
3075 | }
3076 | /*
3077 | * 3.2.2.65 Positioning Data
3078 | * Positioning Data element of 3GPP TS 49.031 BSSAP-LE.
3079 | */
3080 | static uint16_t
3081 | be_pos_data(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3082 | {
3083 | uint32_t curr_offset;
3084 | uint64_t pos_data_disc;
3085 | int bit_offset;
3086 |
3087 | curr_offset = offset;
3088 |
3089 | /* Spare bits */
3090 | bit_offset = (offset<<3);
3091 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare, tvb, bit_offset, 4, ENC_BIG_ENDIAN0x00000000);
3092 | bit_offset += 4;
3093 |
3094 | /* Extract the positioning data discriminator and add to protocol tree */
3095 | proto_tree_add_bits_ret_val(tree, hf_gsm_a_bssmap_positioning_data_discriminator, tvb, bit_offset, 4, &pos_data_disc, ENC_BIG_ENDIAN0x00000000);
3096 | bit_offset += 4;
3097 | curr_offset++;
3098 |
3099 | if (pos_data_disc == 0)
3100 | {
3101 | /* Extract the positioning methods and add to protocol tree */
3102 | for (unsigned i = 0; i < len-1; i++)
3103 | {
3104 | /* Extract the positioning method and add to protocol tree */
3105 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_positioning_method, tvb, bit_offset, 5, ENC_BIG_ENDIAN0x00000000);
3106 | bit_offset += 5;
3107 | /* Extract the usage and add to protocol tree */
3108 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_positioning_method_usage, tvb, bit_offset, 3, ENC_BIG_ENDIAN0x00000000);
3109 | bit_offset += 3;
3110 | curr_offset++;
3111 | }
3112 | }
3113 |
3114 | return curr_offset-offset;
3115 | }
3116 | /*
3117 | * 3.2.2.66 LCS Cause
3118 | * LCS Cause element of 3GPP TS 49.031 BSSAP-LE.
3119 | * Dissected in packet-gsm_bssap_le.c
3120 | */
3121 |
3122 | /*
3123 | * 3.2.2.67 LCS Client Type
3124 | * LCS Client Type element of 3GPP TS 49.031 BSSAP-LE.
3125 | * Dissected in packet-gsm_bssap_le.c
3126 | */
3127 |
3128 | /*
3129 | * 3.2.2.68 3GPP TS 48.008 version 6.9.0 Release 6
3130 | */
3131 |
3132 | /* BSSLAP the embedded message is as defined in 3GPP TS 48.071
3133 | * LLP the embedded message contains a Facility Information Element as defined in 3GPP TS 44.071
3134 | * excluding the Facility IEI and length of Facility IEI octets defined in 3GPP TS 44.071.
3135 | * SMLCPP the embedded message is as defined in 3GPP TS 48.031
3136 | */
3137 | static const value_string gsm_a_apdu_protocol_id_strings[] = {
3138 | { 0, "reserved" },
3139 | { 1, "BSSLAP" },
3140 | { 2, "LLP" },
3141 | { 3, "SMLCPP" },
3142 | { 0, NULL((void*)0) }
3143 | };
3144 |
3145 | static uint16_t
3146 | be_apdu(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3147 | {
3148 | uint32_t curr_offset;
3149 | uint8_t apdu_protocol_id;
3150 | tvbuff_t *APDU_tvb;
3151 |
3152 | curr_offset = offset;
3153 |
3154 | proto_tree_add_bytes_format(tree, hf_gsm_a_bssmap_apdu, tvb, curr_offset, len, NULL((void*)0), "APDU");
3155 |
3156 | /*
3157 | * dissect the embedded APDU message
3158 | * if someone writes a TS 09.31 dissector
3159 | *
3160 | * The APDU octets 4 to n are coded in the same way as the
3161 | * equivalent octet in the APDU element of 3GPP TS 49.031 BSSAP-LE.
3162 | */
3163 |
3164 | proto_tree_add_item_ret_uint8(tree, hf_gsm_a_bssmap_apdu_protocol_id, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000, &apdu_protocol_id);
3165 | curr_offset++;
3166 | len--;
3167 |
3168 | switch (apdu_protocol_id) {
3169 | case 1:
3170 | /* BSSLAP
3171 | * the embedded message is as defined in 3GPP TS 08.71(3GPP TS 48.071 version 7.2.0 Release 7)
3172 | */
3173 | APDU_tvb = tvb_new_subset_length(tvb, curr_offset, len);
3174 | if (gsm_bsslap_handle)
3175 | call_dissector(gsm_bsslap_handle, APDU_tvb, pinfo, g_tree);
3176 | break;
3177 | case 2:
3178 | /* LLP
3179 | * The embedded message contains a Facility Information Element as defined in 3GPP TS 04.71
3180 | * excluding the Facility IEI and length of Facility IEI octets defined in 3GPP TS 04.71.(3GPP TS 44.071).
3181 | */
3182 | break;
3183 | case 3:
3184 | /* SMLCPP
3185 | * The embedded message is as defined in 3GPP TS 08.31(TS 48.031).
3186 | */
3187 | break;
3188 | default:
3189 | break;
3190 | }
3191 |
3192 | curr_offset += len;
3193 |
3194 | EXTRANEOUS_DATA_CHECK(len, curr_offset - offset, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((len) > (curr_offset - offset)) { proto_tree_add_expert (tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset , (len) - (curr_offset - offset)); curr_offset += ((len) - (curr_offset - offset)); };
3195 |
3196 | return curr_offset-offset;
3197 | }
3198 | /*
3199 | * 3.2.2.69 Network Element Identity
3200 | * Network Element Identity element of 3GPP TS 49.031 BSSAP-LE.
3201 | */
3202 | /*
3203 | * 3.2.2.70 GPS Assistance Data
3204 | * Requested GPS Data element of 3GPP TS 49.031 BSSAP-LE.
3205 | */
3206 | static uint16_t
3207 | be_gps_assist_data(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3208 | {
3209 | uint32_t curr_offset;
3210 |
3211 | curr_offset = offset;
3212 |
3213 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len);
3214 |
3215 |
3216 | return len;
3217 | }
3218 | /*
3219 | * 3.2.2.71 Deciphering Keys
3220 | * Deciphering Key element of 3GPP TS 49.031 BSSAP-LE.
3221 | * Dissected in packet-gsm_bssmap_le.c
3222 | */
3223 |
3224 | /* 3.2.2.72 Return Error Request
3225 | * Return Error Request element of 3GPP TS 49.031 BSSAP-LE.
3226 | */
3227 | static uint16_t
3228 | be_ret_err_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3229 | {
3230 | uint32_t curr_offset;
3231 |
3232 | curr_offset = offset;
3233 |
3234 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len);
3235 |
3236 | return len;
3237 | }
3238 | /*
3239 | * 3.2.2.73 Return Error Cause
3240 | * Return Error Cause element of 3GPP TS 49.031 BSSAP-LE.
3241 | */
3242 | static uint16_t
3243 | be_ret_err_cause(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3244 | {
3245 | uint32_t curr_offset;
3246 |
3247 | curr_offset = offset;
3248 |
3249 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len);
3250 |
3251 | return len;
3252 | }
3253 | /*
3254 | * 3.2.2.74 Segmentation
3255 | * Segmentation element of 3GPP TS 49.031 BSSAP-LE.
3256 | */
3257 |
3258 | static const true_false_string tfs_gsm_a_bssmap_segmented = { "non-final segment of a segmented message", "final segment of a segmented message" };
3259 |
3260 | static uint16_t
3261 | be_seg(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3262 | {
3263 | uint32_t curr_offset;
3264 |
3265 | curr_offset = offset;
3266 | /* There are two options for the coding of the Segmentation and Message Information portion;
3267 | * 1 octet containing segmentation information only and 3 octets containing segmentation and message information.
3268 | */
3269 | /* Octet 3 Spare S Segment Number */
3270 | static int* const oct3_flags[] = {
3271 | &hf_gsm_a_bssmap_segmentation_spare_bits,
3272 | &hf_gsm_a_bssmap_segmentation_info,
3273 | &hf_gsm_a_bssmap_segment_number,
3274 | NULL((void*)0)
3275 | };
3276 | proto_tree_add_bitmask_list(tree, tvb, curr_offset, 1, oct3_flags, ENC_NA0x00000000);
3277 | curr_offset++;
3278 | if (len >= 3) {
3279 | /* Octet 4-5 Message ID */
3280 | proto_tree_add_item(tree, hf_gsm_a_bssmap_msg_id, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
3281 | curr_offset += 2;
| Value stored to 'curr_offset' is never read
3282 | }
3283 |
3284 | return len;
3285 | }
3286 | /*
3287 | * 3.2.2.75 Service Handover
3288 | */
3289 | static const value_string gsm_a_bssmap_serv_ho_inf_vals[] = {
3290 | { 0, "Handover to UTRAN or cdma2000 should be performed - Handover to UTRAN or cdma2000 is preferred" },
3291 | { 1, "Handover to UTRAN or cdma2000 should not be performed - Handover to GSM is preferred" },
3292 | { 2, "Handover to UTRAN or cdma2000 shall not be performed - " },
3293 | { 3, "no information available for service based handover" },
3294 | { 4, "no information available for service based handover" },
3295 | { 5, "no information available for service based handover" },
3296 | { 6, "no information available for service based handover" },
3297 | { 7, "no information available for service based handover" },
3298 | { 0, NULL((void*)0) }
3299 | };
3300 | static uint16_t
3301 | be_serv_ho(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3302 | {
3303 | uint32_t curr_offset;
3304 |
3305 | curr_offset = offset;
3306 |
3307 | /* Service Handover information */
3308 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 5, ENC_BIG_ENDIAN0x00000000);
3309 | proto_tree_add_item(tree, hf_gsm_a_bssmap_serv_ho_inf, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3310 | curr_offset++;
3311 | return len;
3312 | }
3313 |
3314 | /*
3315 | * 3.2.2.76 Source RNC to target RNC transparent information (UMTS)
3316 | */
3317 |
3318 | static uint16_t
3319 | be_src_rnc_to_tar_rnc_umts(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3320 | {
3321 | tvbuff_t *container_tvb;
3322 | uint32_t curr_offset;
3323 |
3324 | curr_offset = offset;
3325 |
3326 | /* The Source RNC to Target RNC transparent Information value is encoded as
3327 | * the Source RNC to Target RNC Transparent Container IE as defined in relevant
3328 | * RANAP specification 3GPP TS 25.413, excluding RANAP tag
3329 | */
3330 | container_tvb = tvb_new_subset_length(tvb, curr_offset, len);
3331 | dissect_ranap_SourceRNC_ToTargetRNC_TransparentContainer_PDU(container_tvb, pinfo, tree, NULL((void*)0));
3332 |
3333 | return len;
3334 | }
3335 | /*
3336 | * 3.2.2.77 Source RNC to target RNC transparent information (cdma2000)
3337 | */
3338 | static uint16_t
3339 | be_src_rnc_to_tar_rnc_cdma(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3340 | {
3341 | uint32_t curr_offset;
3342 |
3343 | curr_offset = offset;
3344 |
3345 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len);
3346 | /* The Source RNC to Target RNC transparent Information value (structure and encoding)
3347 | * for cdma2000 is defined in relevant specifications.
3348 | */
3349 |
3350 | return len;
3351 | }
3352 | /*
3353 | * 3.2.2.78 GERAN Classmark
3354 | */
3355 | static const value_string gsm_a_max_nb_traffic_chan_vals[] = {
3356 | { 0x00, "1 TCH" },
3357 | { 0x01, "2 TCHs" },
3358 | { 0x02, "3 TCHs" },
3359 | { 0x03, "4 TCHs" },
3360 | { 0x04, "5 TCHs" },
3361 | { 0x05, "6 TCHs" },
3362 | { 0, NULL((void*)0) }
3363 | };
3364 | static const true_false_string gsm_a_bssmap_accept_not_accept_vals = {
3365 | "Acceptable",
3366 | "Not acceptable"
3367 | };
3368 | static uint16_t
3369 | be_geran_cls_m(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3370 | {
3371 | uint32_t curr_offset;
3372 |
3373 | curr_offset = offset;
3374 |
3375 | if (len > 2) {
3376 | de_sup_codec_list(tvb, tree, pinfo, curr_offset, (len-2), NULL((void*)0), 0);
3377 | }
3378 | curr_offset += len-2;
3379 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 5, ENC_BIG_ENDIAN0x00000000);
3380 | proto_tree_add_item(tree, hf_gsm_a_bssmap_max_nb_traffic_chan, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3381 | curr_offset++;
3382 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 3, ENC_BIG_ENDIAN0x00000000);
3383 | proto_tree_add_item(tree, hf_gsm_a_bssmap_acceptable_chan_coding_bit5, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3384 | proto_tree_add_item(tree, hf_gsm_a_bssmap_acceptable_chan_coding_bit4, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3385 | proto_tree_add_item(tree, hf_gsm_a_bssmap_acceptable_chan_coding_bit3, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3386 | proto_tree_add_item(tree, hf_gsm_a_bssmap_acceptable_chan_coding_bit2, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3387 | proto_tree_add_item(tree, hf_gsm_a_bssmap_acceptable_chan_coding_bit1, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3388 |
3389 | return len;
3390 | }
3391 | /*
3392 | * 3.2.2.79 GERAN BSC Container
3393 | */
3394 | static uint16_t
3395 | be_geran_bsc_cont(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3396 | {
3397 | uint32_t curr_offset;
3398 |
3399 | curr_offset = offset;
3400 |
3401 | proto_tree_add_item(tree, hf_gsm_a_bssap_speech_codec, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3402 | curr_offset++;
3403 | NO_MORE_DATA_CHECK(len)if ((len) <= (curr_offset - offset)) return(len);;
3404 | proto_tree_add_item(tree, hf_gsm_a_bssmap_allowed_data_rate_bit8, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3405 | proto_tree_add_item(tree, hf_gsm_a_bssmap_allowed_data_rate_bit7, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3406 | proto_tree_add_item(tree, hf_gsm_a_bssmap_allowed_data_rate_bit6, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3407 | proto_tree_add_item(tree, hf_gsm_a_bssmap_allowed_data_rate_bit5, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3408 | proto_tree_add_item(tree, hf_gsm_a_bssmap_allowed_data_rate_bit4, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3409 | proto_tree_add_item(tree, hf_gsm_a_bssmap_max_nb_traffic_chan, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3410 |
3411 | return len;
3412 | }
3413 | /*
3414 | * 3.2.2.80 New BSS to Old BSS Information
3415 | */
3416 | /* This function is only called from other protocols (e.g. RANAP),
3417 | internally, the Field Element dissector is called directly */
3418 | void
3419 | bssmap_new_bss_to_old_bss_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo)
3420 | {
3421 | uint16_t len;
3422 | if (!tree) {
3423 | return;
3424 | }
3425 |
3426 | g_tree = tree;
3427 |
3428 | len = tvb_reported_length(tvb);
3429 | be_field_element_dissect(tvb, tree, pinfo, 0, len, NULL((void*)0), 0);
3430 |
3431 | g_tree = NULL((void*)0);
3432 | }
3433 |
3434 |
3435 | /*
3436 | * 3.2.2.81 Inter-System Information
3437 | */
3438 | static uint16_t
3439 | be_inter_sys_inf(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3440 | {
3441 | tvbuff_t *new_tvb;
3442 |
3443 | new_tvb = tvb_new_subset_length(tvb, offset, len);
3444 |
3445 | if (new_tvb) {
3446 | dissect_ranap_InterSystemInformation_TransparentContainer_PDU(new_tvb, pinfo, tree, NULL((void*)0));
3447 | }
3448 |
3449 | return len;
3450 | }
3451 | /*
3452 | * 3.2.2.82 SNA Access Information
3453 | */
3454 | static uint16_t
3455 | be_sna_acc_inf(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3456 | {
3457 | uint32_t curr_offset;
3458 |
3459 | curr_offset = offset;
3460 |
3461 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len);
3462 |
3463 | return len;
3464 | }
3465 |
3466 | /*
3467 | * 3.2.2.83 VSTK_RAND Information
3468 | */
3469 | static uint16_t
3470 | be_vstk_rand_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3471 | {
3472 | uint32_t curr_offset;
3473 | uint64_t vstk_rand;
3474 |
3475 | curr_offset = offset;
3476 |
3477 | vstk_rand = tvb_get_ntoh40(tvb, curr_offset);
3478 | vstk_rand >>= 4;
3479 | proto_tree_add_uint64(tree, hf_gsm_a_bssmap_vstk_rand, tvb, curr_offset, 5, vstk_rand);
3480 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, (((curr_offset+4)<<3)+4), 4, ENC_BIG_ENDIAN0x00000000);
3481 |
3482 | return len;
3483 | }
3484 | /*
3485 | * 3.2.2.84 VSTK information
3486 | */
3487 | static uint16_t
3488 | be_vstk_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3489 | {
3490 | proto_tree_add_item(tree, hf_gsm_a_bssmap_vstk, tvb, offset, 16, ENC_NA0x00000000);
3491 |
3492 | return len;
3493 | }
3494 | /*
3495 | * 3.2.2.85 Paging Information
3496 | */
3497 | /*
3498 | * If the VGCS/VBS flag is set to zero, the mobile station to be paged is not a member of any VGCS/VBS-group.
3499 | * If the VGCS/VBS flag is set to one, the mobile station to be paged is a member of a VGCS/VBS-group.
3500 | */
3501 | static const true_false_string bssmap_paging_inf_flg_value = {
3502 | "A member of a VGCS/VBS-group",
3503 | "Not a member of any VGCS/VBS-group"
3504 | };
3505 |
3506 | static const value_string gsm_a_bssmap_paging_cause_vals[] = {
3507 | { 0, "Paging is for mobile terminating call" },
3508 | { 1, "Paging is for a short message" },
3509 | { 2, "Paging is for a USSD" },
3510 | { 3, "Spare" },
3511 | { 0, NULL((void*)0) }
3512 | };
3513 |
3514 | static uint16_t
3515 | be_paging_inf(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3516 | {
3517 | uint32_t curr_offset;
3518 |
3519 | curr_offset = offset;
3520 |
3521 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 5, ENC_BIG_ENDIAN0x00000000);
3522 | proto_tree_add_item(tree, hf_gsm_a_bssmap_paging_cause, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3523 | proto_tree_add_item(tree, hf_gsm_a_bssmap_paging_inf_flg, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3524 | curr_offset++;
3525 |
3526 | return curr_offset-offset;
3527 | }
3528 | /*
3529 | * 3.2.2.86 IMEI
3530 | * Use same dissector as IMSI 3.2.2.6
3531 | */
3532 |
3533 | /*
3534 | * 3.2.2.87 Velocity Estimate
3535 | */
3536 | static uint16_t
3537 | be_vel_est(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string, int string_len)
3538 | {
3539 | dissect_description_of_velocity(tvb, tree, pinfo, offset, len, add_string, string_len);
3540 |
3541 | return len;
3542 | }
3543 | /*
3544 | * 3.2.2.88 VGCS Feature Flags
3545 | */
3546 |
3547 | /* Bit 1 is the talker priority indicator (TP Ind). */
3548 | static const true_false_string gsm_bssmap_tpind_vals = {
3549 | "Talker Priority not supported" ,
3550 | "Talker Priority supported"
3551 | };
3552 | /* Bits 2 and 3 are the A-interface resource sharing indicator (AS Ind). */
3553 | static const true_false_string gsm_bssmap_asind_b2_vals = {
3554 | "A-interface circuit sharing" ,
3555 | "No A-interface circuit sharing"
3556 | };
3557 |
3558 | static const true_false_string gsm_bssmap_asind_b3_vals = {
3559 | "A-interface link sharing" ,
3560 | "No A-interface link sharing"
3561 | };
3562 |
3563 | /* Bit 4 is the group or broadcast call re-establishment by the BSS indicator (Bss Res). */
3564 | static const true_false_string gsm_bssmap_bss_res_vals = {
3565 | "Re-establishment of the group or broadcast call by the BSS" ,
3566 | "No re-establishment of the group or broadcast call by the BSS"
3567 | };
3568 |
3569 | /* Bit 5 is the Talker Channel Parameter (TCP). */
3570 | static const true_false_string gsm_bssmap_bss_tcp_vals = {
3571 | "Talker channel parameter is applicable to this call, talker shall be established and maintained on a dedicated channel" ,
3572 | "Talker channel parameter is not applicable to this call"
3573 | };
3574 |
3575 | static uint16_t
3576 | be_vgcs_feat_flg(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3577 | {
3578 | uint32_t curr_offset;
3579 |
3580 | curr_offset = offset;
3581 |
3582 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 3, ENC_BIG_ENDIAN0x00000000);
3583 | proto_tree_add_item(tree, hf_gsm_a_bssmap_tcp, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3584 | proto_tree_add_item(tree, hf_gsm_a_bssmap_bss_res, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3585 | proto_tree_add_item(tree, hf_gsm_a_bssmap_asind_b3, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3586 | proto_tree_add_item(tree, hf_gsm_a_bssmap_asind_b2, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3587 | proto_tree_add_item(tree, hf_gsm_a_bssmap_tpind, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3588 |
3589 | curr_offset++;
3590 |
3591 | return curr_offset-offset;
3592 | }
3593 | /*
3594 | * 3.2.2.89 Talker Priority
3595 | */
3596 | static const value_string gsm_a_bssmap_talker_pri_vals[] = {
3597 | { 0, "Normal Priority" },
3598 | { 1, "Privileged Priority" },
3599 | { 2, "Emergency Priority" },
3600 | { 3, "Reserved for future use" },
3601 | { 0, NULL((void*)0) }
3602 | };
3603 |
3604 | static uint16_t
3605 | be_talker_pri(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3606 | {
3607 | uint32_t curr_offset;
3608 |
3609 | curr_offset = offset;
3610 |
3611 | proto_tree_add_item(tree, hf_gsm_a_bssmap_talker_pri, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3612 | curr_offset++;
3613 |
3614 | EXTRANEOUS_DATA_CHECK(len, curr_offset - offset, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((len) > (curr_offset - offset)) { proto_tree_add_expert (tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset , (len) - (curr_offset - offset)); curr_offset += ((len) - (curr_offset - offset)); };
3615 |
3616 | return curr_offset-offset;
3617 | }
3618 |
3619 | /*
3620 | * 3.2.2.90 Emergency Set Indication
3621 | * No data
3622 | */
3623 | /*
3624 | * 3.2.2.91 Talker Identity
3625 | */
3626 | static uint16_t
3627 | be_talker_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3628 | {
3629 | uint32_t curr_offset;
3630 |
3631 | curr_offset = offset;
3632 |
3633 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, curr_offset<<3, 5, ENC_BIG_ENDIAN0x00000000);
3634 | proto_tree_add_item(tree, hf_gsm_a_bssmap_filler_bits, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3635 | curr_offset++;
3636 | proto_tree_add_item(tree, hf_gsm_a_bssmap_talker_identity_field, tvb, curr_offset, len-1, ENC_NA0x00000000);
3637 |
3638 | return len;
3639 | }
3640 | /*
3641 | * 3.2.2.92 SMS to VGCS
3642 | */
3643 | static uint16_t
3644 | be_sms_to_vgcs(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3645 | {
3646 | /* The SMS content field is coded as follows - this field contains
3647 | * the RP-DATA message as defined in 3GPP TS 24.011.
3648 | */
3649 | rp_data_n_ms(tvb, tree, pinfo, offset, len);
3650 |
3651 |
3652 | return len;
3653 | }
3654 | /*
3655 | * 3.2.2.93 VGCS talker mode
3656 | */
3657 | static const value_string gsm_a_bssmap_rr_mode_vals[] = {
3658 | { 0, "dedicated mode (i.e. dedicated channel)"},
3659 | { 1, "group transmit mode (i.e. voice group channel)"},
3660 | { 0, NULL((void*)0) }
3661 | };
3662 | static const value_string gsm_a_bssmap_group_cipher_key_nb_vals[] = {
3663 | { 0x0, "no ciphering"},
3664 | { 0x1, "cipher key number 1"},
3665 | { 0x2, "cipher key number 2"},
3666 | { 0x3, "cipher key number 3"},
3667 | { 0x4, "cipher key number 4"},
3668 | { 0x5, "cipher key number 5"},
3669 | { 0x6, "cipher key number 6"},
3670 | { 0x7, "cipher key number 7"},
3671 | { 0x8, "cipher key number 8"},
3672 | { 0x9, "cipher key number 9"},
3673 | { 0xa, "cipher key number A"},
3674 | { 0xb, "cipher key number B"},
3675 | { 0xc, "cipher key number C"},
3676 | { 0xd, "cipher key number D"},
3677 | { 0xe, "cipher key number E"},
3678 | { 0xf, "cipher key number F"},
3679 | { 0, NULL((void*)0) }
3680 | };
3681 | static uint16_t
3682 | be_vgcs_talker_mode(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3683 | {
3684 | uint32_t curr_offset;
3685 |
3686 | curr_offset = offset;
3687 |
3688 | proto_tree_add_item(tree, hf_gsm_a_bssmap_rr_mode, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3689 | proto_tree_add_item(tree, hf_gsm_a_bssmap_group_cipher_key_nb, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3690 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, ((curr_offset<<3)+6), 2, ENC_BIG_ENDIAN0x00000000);
3691 |
3692 | return len;
3693 | }
3694 | /*
3695 | * 3.2.2.94 VGCS/VBS Cell Status
3696 | */
3697 | static const value_string gsm_a_bssmap_vgcs_vbs_cell_status_vals[] = {
3698 | { 0, "Cell is established for the voice group or broadcast call"},
3699 | { 1, "Cell is not established for the voice group or broadcast call. Establishment by the BSS is to be attempted"},
3700 | { 2, "Cell is released for the voice group or broadcast call because no user is present"},
3701 | { 3, "Cell is not established for the voice group or broadcast call. No establishment by the BSS is to be attempted"},
3702 | { 4, "Reserved"},
3703 | { 5, "Reserved"},
3704 | { 6, "Reserved"},
3705 | { 7, "Reserved"},
3706 | { 0, NULL((void*)0) }
3707 | };
3708 | static uint16_t
3709 | be_vgcs_vbs_cell_status(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3710 | {
3711 | uint32_t curr_offset;
3712 |
3713 | curr_offset = offset;
3714 |
3715 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, (curr_offset<<3), 5, ENC_BIG_ENDIAN0x00000000);
3716 | proto_tree_add_item(tree, hf_gsm_a_bssmap_vgcs_vbs_cell_status, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3717 |
3718 | return len;
3719 | }
3720 | /*
3721 | * 3.2.2.95 GANSS Assistance Data
3722 | * The GANSS Assistance Data octets 3 to n are coded as the Requested GANSS Data element of 3GPP TS 49.031 (BSSAP-LE)
3723 | * XXX move to packet-gsm_bssmap_le.c
3724 | */
3725 | uint16_t
3726 | be_ganss_ass_dta(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3727 | {
3728 | uint32_t curr_offset;
3729 |
3730 | curr_offset = offset;
3731 |
3732 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len);
3733 |
3734 | return len;
3735 | }
3736 | /*
3737 | * 3.2.2.96 GANSS Positioning Data
3738 | * XXX move to packet-gsm_bssmap_le.c
3739 | */
3740 |
3741 | static const value_string gsm_a_bssmap_method_vals[] = {
3742 | { 0x00, "MS-Based" },
3743 | { 0x01, "MS-Assisted" },
3744 | { 0x02, "Conventional" },
3745 | { 0x03, "Reserved" },
3746 | { 0, NULL((void*)0) }
3747 | };
3748 |
3749 | static const value_string gsm_a_bssmap_ganss_id_vals[] = {
3750 | { 0x00, "Galileo" },
3751 | { 0x01, "Satellite Based Augmentation Systems (SBAS)" },
3752 | { 0x02, "Modernized GPS" },
3753 | { 0x03, "Quasi Zenith Satellite System (QZSS)" },
3754 | { 0x04, "GLONASS" },
3755 | { 0, NULL((void*)0) }
3756 | };
3757 |
3758 | static const value_string gsm_a_bssmap_usage_vals[] = {
3759 | { 0x00, "Attempted unsuccessfully due to failure or interruption" },
3760 | { 0x01, "Attempted successfully: results not used to generate location" },
3761 | { 0x02, "Attempted successfully: results used to verify but not generate location" },
3762 | { 0x03, "Attempted successfully: results used to generate location" },
3763 | { 0x04, "Attempted successfully: case where MS supports multiple mobile based positioning methods and the actual method or methods used by the MS cannot be determined" },
3764 | { 0, NULL((void*)0) }
3765 | };
3766 |
3767 | uint16_t
3768 | be_ganss_pos_dta(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3769 | {
3770 | uint32_t curr_offset;
3771 |
3772 | curr_offset = offset;
3773 |
3774 | proto_tree_add_item(tree, hf_gsm_a_bssmap_method, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3775 | proto_tree_add_item(tree, hf_gsm_a_bssmap_ganss_id, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3776 | proto_tree_add_item(tree, hf_gsm_a_bssmap_usage, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3777 | curr_offset++;
3778 |
3779 | return curr_offset-offset;
3780 | }
3781 | /*
3782 | * 3.2.2.97 GANSS Location Type
3783 | */
3784 | uint16_t
3785 | be_ganss_loc_type(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3786 | {
3787 | uint32_t curr_offset;
3788 |
3789 | curr_offset = offset;
3790 |
3791 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len);
3792 |
3793 | return len;
3794 | }
3795 | /*
3796 | * 3.2.2.98 Application Data
3797 | */
3798 | static uint16_t
3799 | be_app_data(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3800 | {
3801 | uint32_t curr_offset;
3802 |
3803 | curr_offset = offset;
3804 |
3805 | proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet, tvb, curr_offset, len);
3806 |
3807 | return len;
3808 | }
3809 | /*
3810 | * 3.2.2.99 Data Identity
3811 | */
3812 | static uint16_t
3813 | be_app_data_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3814 | {
3815 | proto_tree_add_item(tree, hf_gsm_a_bssmap_data_id, tvb, offset, 1, ENC_BIG_ENDIAN0x00000000);
3816 |
3817 | return len;
3818 | }
3819 | /*
3820 | * 3.2.2.100 Application Data Information
3821 | */
3822 | static const true_false_string gsm_a_bssmap_bt_ind_val = {
3823 | "BSS has already transmitted the application data to cells",
3824 | "BSS has not transmitted the application data to cells"
3825 | };
3826 | static uint16_t
3827 | be_app_data_inf(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3828 | {
3829 | uint32_t curr_offset;
3830 |
3831 | curr_offset = offset;
3832 |
3833 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, (curr_offset<<3), 7, ENC_BIG_ENDIAN0x00000000);
3834 | proto_tree_add_item(tree, hf_gsm_a_bssmap_bt_ind, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
3835 |
3836 | return len;
3837 | }
3838 | /*
3839 | * 3.2.2.101 MSISDN
3840 | * Octets 3-12 contain the digits of an MSISDN, coded as in 3GPP TS 24.008, Calling party BCD number, octets 4 - 13.
3841 | */
3842 | static uint16_t
3843 | be_msisdn(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3844 | {
3845 | tvbuff_t *new_tvb;
3846 |
3847 | new_tvb = tvb_new_subset_length(tvb, offset, len);
3848 | if (new_tvb) {
3849 | dissect_gsm_map_msisdn(new_tvb, pinfo , tree);
3850 | }
3851 |
3852 | return len;
3853 | }
3854 | /*
3855 | * 3.2.2.102 AoIP Transport Layer Address
3856 | */
3857 | static uint16_t
3858 | be_aoip_trans_lay_add(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3859 | {
3860 | uint32_t curr_offset;
3861 | uint8_t addr_type;
3862 | uint32_t rtp_ipv4_address;
3863 | uint16_t rtp_port;
3864 | address rtp_dst_addr;
3865 | ws_in6_addr rtp_addr_ipv6;
3866 |
3867 | curr_offset = offset;
3868 |
3869 | /* This Information Element provides either an IPv4 or and IPv6 Address and UDP port value
3870 | * for the Transport Layer information of the connection end point.
3871 | * The Length differentiates between IPv4 and IPv6.
3872 | */
3873 | switch (len) {
3874 | case 6:
3875 | /* IPv4 */
3876 | addr_type = 1;
3877 | proto_tree_add_item(tree, hf_gsm_a_bssmap_aoip_trans_ipv4, tvb, curr_offset, 4, ENC_BIG_ENDIAN0x00000000);
3878 | rtp_ipv4_address = tvb_get_ipv4(tvb, curr_offset);
3879 | curr_offset+=4;
3880 | break;
3881 | case 18:
3882 | /* IPv6 */
3883 | addr_type = 2;
3884 | proto_tree_add_item(tree, hf_gsm_a_bssmap_aoip_trans_ipv6, tvb, curr_offset, 16, ENC_NA0x00000000);
3885 | tvb_get_ipv6(tvb, curr_offset, &rtp_addr_ipv6);
3886 | curr_offset+=16;
3887 | break;
3888 | default:
3889 | /* Bogus */
3890 | proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_bogus_length, tvb, curr_offset, len, "Bogus length %u",len);
3891 | return len;
3892 | }
3893 | proto_tree_add_item(tree, hf_gsm_a_bssmap_aoip_trans_port, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
3894 | rtp_port = tvb_get_ntohs(tvb,curr_offset);
3895 | curr_offset+=2;
3896 |
3897 | switch (addr_type) {
3898 | case 1:
3899 | /* IPv4 */
3900 | rtp_dst_addr.type = AT_IPv4;
3901 | rtp_dst_addr.len = 4;
3902 | rtp_dst_addr.data = (uint8_t *)&rtp_ipv4_address;
3903 | break;
3904 | case 2:
3905 | /* IPv6 */
3906 | rtp_dst_addr.type = AT_IPv6;
3907 | rtp_dst_addr.len = 16;
3908 | rtp_dst_addr.data = (uint8_t *)&rtp_addr_ipv6;
3909 | break;
3910 | }
3911 |
3912 | if ((!pinfo->fd->visited) && rtp_port != 0) {
3913 | rtp_add_address(pinfo, PT_UDP, &rtp_dst_addr, rtp_port, 0, "BSS MAP", pinfo->num, false0, 0);
3914 | rtcp_add_address(pinfo, &rtp_dst_addr, rtp_port+1, 0, "BSS MAP", pinfo->num);
3915 | }
3916 | return curr_offset-offset;
3917 | }
3918 | /*
3919 | * 3.2.2.103 Speech Codec List
3920 | */
3921 | /*
3922 | FR_AMR is coded '011'
3923 | S11, S13 and S15 are reserved and coded with zeroes.
3924 | HR_AMR is coded '100'
3925 | S6 - S7 and S11 - S15 are reserved and coded with zeroes.
3926 | OHR_AMR is coded '011'
3927 | S11, S13 and S15 are reserved and coded with zeroes.
3928 |
3929 | FR_AMR-WB is coded '001'
3930 | S0 is set to '1' S1 - S7 are reserved and coded with zeroes.
3931 | OFR_AMR-WB is coded '100'
3932 | S0, S2, S4 indicates the supported Codec Configurations. S1, S3, S5, S6, S7 are reserved and coded with zeroes.
3933 | OHR_AMR-WB is coded '101'
3934 | S0 is set to '1' S1 - S7 are reserved and coded with zeroes.
3935 |
3936 |
3937 | 8 7 6 5 4 3 2 1
3938 | FI PI PT TF Codec Type (FR_AMR-WB or OFR_AMR-WB or OHR_AMR-WB)
3939 | S7 S6 S5 S4 S3 S2 S1 S0
3940 |
3941 |
3942 | */
3943 | static const true_false_string bssmap_fi_vals = {
3944 | "AoIP with compressed speech via RTP/UDP/IP is supported by the BSS/Preferred by the MSC",
3945 | "AoIP with Compressed speech via RTP/UDP/IP is not supported by the BSS/Not Preferred by the MSC"
3946 | };
3947 | static const true_false_string bssmap_tf_vals = {
3948 | "TFO supported by the BSS or TFO support is preferred by the MSC for this Codec Type",
3949 | "TFO is not supported by the BSS or TFO support is not preferred by the MSC for this Codec Type"
3950 | };
3951 | static const true_false_string bssmap_pi_vals = {
3952 | "Transport of PCM over A-Interface via RTP/UDP/IP is supported by the BSS or preferred by the MSC for this Codec Type",
3953 | "PCM over A interface with IP as transport is not supported by the BSS or not preferred by the MSC for this Codec Type"
3954 | };
3955 | static const true_false_string bssmap_pt_vals = {
3956 | "Transport of PCM over A-Interface via TDM is supported by the BSS or preferred by the MSC",
3957 | "PCM over A-Interface with TDM as transport is not supported by the BSS or not preferred by the MSC for this Codec Type"
3958 | };
3959 | /* 26.103 Table 6.3-1: Coding of the selected Codec_Type (long form) */
3960 | static const value_string bssap_speech_codec_values[] = {
3961 | { 0x00, "GSM FR" },
3962 | { 0x01, "GSM HR" },
3963 | { 0x02, "GSM EFR" },
3964 | { 0x03, "FR_AMR" },
3965 | { 0x04, "HR_AMR" },
3966 | { 0x05, "UMTS AMR" },
3967 | { 0x06, "UMTS AMR 2" },
3968 | { 0x07, "TDMA EFR" },
3969 | { 0x08, "PDC EFR" },
3970 | { 0x09, "FR_AMR-WB" },
3971 | { 0x0a, "UMTS AMR-WB" },
3972 | { 0x0b, "OHR_AMR" },
3973 | { 0x0c, "OFR_AMR-WB" },
3974 | { 0x0d, "OHR_AMR-WB" },
3975 | { 0x0e, "Reserved" },
3976 | { 0x0f, "Codec Extension" },
3977 | { 0xfd, "CSData" },
3978 | { 0xfe, "MuMe2" },
3979 | { 0xff, "MuMe" },
3980 | { 0, NULL((void*)0) }
3981 | };
3982 | static value_string_ext bssap_speech_codec_values_ext = VALUE_STRING_EXT_INIT(bssap_speech_codec_values){ _try_val_to_str_ext_init, 0, (sizeof (bssap_speech_codec_values ) / sizeof ((bssap_speech_codec_values)[0]))-1, bssap_speech_codec_values , "bssap_speech_codec_values", ((void*)0) };
3983 |
3984 | static const value_string bssap_extended_codec_values[] = {
3985 | { 0xfd, "CSData" },
3986 | { 0, NULL((void*)0) }
3987 | };
3988 |
3989 | static uint16_t
3990 | be_speech_codec_lst(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
3991 | {
3992 | uint32_t curr_offset, consumed = 0;
3993 | uint8_t codec;
3994 | uint8_t number = 0;
3995 | proto_item *item = NULL((void*)0);
3996 | proto_tree *subtree = NULL((void*)0);
3997 |
3998 | curr_offset = offset;
3999 |
4000 | while (curr_offset-offset < len) {
4001 | number++;
4002 | consumed = 0;
4003 | subtree = proto_tree_add_subtree_format(tree, tvb, curr_offset, 1,
4004 | ett_codec_lst, &item, "Speech Codec Element %u",number);
4005 | codec = tvb_get_uint8(tvb,curr_offset)&0x0f;
4006 | switch (codec) {
4007 | case 0:
4008 | /* GSM_FR is coded "0000" */
4009 | /* fall through */
4010 | case 1:
4011 | /* GSM_HR is coded "0001" */
4012 | /* fall through */
4013 | case 2:
4014 | /* GSM_EFR is coded "0010" */
4015 | /* fall through */
4016 | /* FI indicates Full IP */
4017 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_fi, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4018 | /* PI indicates PCMoIP */
4019 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pi, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4020 | /* PT indicates PCMoTDM */
4021 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pt, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4022 | /* TF indicates TFO support */
4023 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_tf, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4024 | /* Codec Type */
4025 | proto_tree_add_item(subtree, hf_gsm_a_bssap_speech_codec, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4026 | proto_item_append_text(item, " - %s",
4027 | val_to_str_const(tvb_get_uint8(tvb, curr_offset) & 0x0f,
4028 | bssap_speech_codec_values,
4029 | "Unknown"));
4030 | curr_offset++;
4031 | consumed++;
4032 | break;
4033 | case 3:
4034 | /* fall through */
4035 | case 4:
4036 | /* fall through */
4037 | case 0xb:
4038 | /* FR_AMR is coded '011'
4039 | * HR_AMR is coded '100'
4040 | * OHR_AMR is coded '1011'
4041 | */
4042 | /* FI indicates Full IP */
4043 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_fi, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4044 | /* PI indicates PCMoIP */
4045 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pi, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4046 | /* PT indicates PCMoTDM */
4047 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pt, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4048 | /* TF indicates TFO support */
4049 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_tf, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4050 | /* Codec Type */
4051 | proto_tree_add_item(subtree, hf_gsm_a_bssap_speech_codec, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4052 | proto_item_append_text(item, " - %s",
4053 | val_to_str_const(tvb_get_uint8(tvb, curr_offset) & 0x0f,
4054 | bssap_speech_codec_values,
4055 | "Unknown"));
4056 | curr_offset++;
4057 | consumed++;
4058 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_s0_s15, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
4059 | curr_offset+=2;
4060 | consumed+=2;
4061 | break;
4062 | case 0x9:
4063 | /* fall through */
4064 | case 0xc:
4065 | /* fall through */
4066 | case 0xd:
4067 | /* FR_AMR-WB is coded '1001'
4068 | * OFR_AMR-WB is coded '1100'
4069 | * OHR_AMR-WB is coded '1101'
4070 | */
4071 | /* FI indicates Full IP */
4072 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_fi, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4073 | /* PI indicates PCMoIP */
4074 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pi, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4075 | /* PT indicates PCMoTDM */
4076 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pt, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4077 | /* TF indicates TFO support */
4078 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_tf, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4079 | /* Codec Type */
4080 | proto_tree_add_item(subtree, hf_gsm_a_bssap_speech_codec, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4081 | proto_item_append_text(item, " - %s",
4082 | val_to_str_const(tvb_get_uint8(tvb, curr_offset) & 0x0f,
4083 | bssap_speech_codec_values,
4084 | "Unknown"));
4085 | curr_offset++;
4086 | consumed++;
4087 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_s0_s7, tvb, curr_offset, 1, ENC_NA0x00000000);
4088 | curr_offset++;
4089 | consumed++;
4090 | break;
4091 | case 0xf:
4092 | /* Currently (3GPP TS 48.008 version 9.4.0 Release 9) CSData Codec Type is the only extended one */
4093 | /* PI indicates PCMoIP */
4094 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pi, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4095 | /* PT indicates PCMoTDM */
4096 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pt, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4097 | /* Codec Type */
4098 | proto_tree_add_item(subtree, hf_gsm_a_bssap_speech_codec, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4099 | curr_offset++;
4100 | consumed++;
4101 | /* Codec Extension */
4102 | proto_tree_add_item(subtree, hf_gsm_a_bssap_extended_codec, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4103 | proto_item_append_text(item, " - %s",
4104 | val_to_str_const(tvb_get_uint8(tvb, curr_offset),
4105 | bssap_extended_codec_values,
4106 | "Unknown"));
4107 | curr_offset++;
4108 | consumed++;
4109 | proto_tree_add_item(subtree, hf_gsm_a_bssap_extended_codec_r2, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4110 | proto_tree_add_item(subtree, hf_gsm_a_bssap_extended_codec_r3, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4111 | curr_offset++;
4112 | consumed++;
4113 | break;
4114 | default:
4115 | proto_tree_add_expert(subtree, pinfo, &ei_gsm_a_bssap_unknown_codec, tvb, curr_offset, 2);
4116 | curr_offset+=2;
4117 | consumed+=2;
4118 | break;
4119 | }
4120 | }
4121 | proto_item_set_len(item, consumed);
4122 | return len;
4123 | }
4124 | /*
4125 | * 3.2.2.104 Speech Codec
4126 | */
4127 | static const true_false_string bssmap_fi2_vals = {
4128 | "AoIP with compressed speech via RTP/UDP/IP is selected for this Codec Type",
4129 | "Compressed speech via RTP/UDP/IP is not selected for this Codec Type"
4130 | };
4131 | static const true_false_string bssmap_tf2_vals = {
4132 | "TFO Support is selected for this Codec Type",
4133 | "TFO Support is not selected for this Codec Type"
4134 | };
4135 | static const true_false_string bssmap_pi2_vals = {
4136 | "PCM over A-Interface via RTP/UPD/IP is selected for this Codec Type",
4137 | "PCM over A interface with RTP/UDP/IP is not selected for this Codec Type"
4138 | };
4139 | static const true_false_string bssmap_pt2_vals = {
4140 | "PCM over A-Interface with TDM as transport is selected for this Codec Type",
4141 | "PCM over A-Interface with TDM as transport is not selected for this Codec Type"
4142 | };
4143 | static uint16_t
4144 | be_speech_codec(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4145 | {
4146 | uint32_t curr_offset, consumed = 0;
4147 | uint8_t codec;
4148 | uint8_t number = 0;
4149 | proto_item *item = NULL((void*)0);
4150 | proto_tree *subtree = NULL((void*)0);
4151 |
4152 | curr_offset = offset;
4153 |
4154 | while (curr_offset-offset < len) {
4155 | number++;
4156 | consumed = 0;
4157 | subtree = proto_tree_add_subtree_format(tree, tvb, curr_offset, 1, ett_codec_lst, &item,
4158 | "Speech Codec Element %u",number);
4159 | codec = tvb_get_uint8(tvb,curr_offset)&0x0f;
4160 | switch (codec) {
4161 | case 0:
4162 | /* GSM_FR is coded "0000" */
4163 | /* fall through */
4164 | case 1:
4165 | /* GSM_HR is coded "0001" */
4166 | /* fall through */
4167 | case 2:
4168 | /* GSM_EFR is coded "0010" */
4169 | /* fall through */
4170 | /* FI indicates Full IP */
4171 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_fi, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4172 | /* PI indicates PCMoIP */
4173 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pi, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4174 | /* PT indicates PCMoTDM */
4175 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pt, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4176 | /* TF indicates TFO support */
4177 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_tf, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4178 | /* Codec Type */
4179 | proto_tree_add_item(subtree, hf_gsm_a_bssap_speech_codec, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4180 | proto_item_append_text(item, " - %s",
4181 | val_to_str_const(tvb_get_uint8(tvb, curr_offset) & 0x0f,
4182 | bssap_speech_codec_values,
4183 | "Unknown"));
4184 | curr_offset++;
4185 | consumed++;
4186 | break;
4187 | case 3:
4188 | /* fall through */
4189 | case 4:
4190 | /* fall through */
4191 | case 0xb:
4192 | /* FR_AMR is coded '011'
4193 | * HR_AMR is coded '100'
4194 | * OHR_AMR is coded '1011'
4195 | */
4196 | /* FI indicates Full IP */
4197 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_fi2, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4198 | /* PI indicates PCMoIP */
4199 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pi2, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4200 | /* PT indicates PCMoTDM */
4201 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pt2, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4202 | /* TF indicates TFO support */
4203 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_tf2, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4204 | /* Codec Type */
4205 | proto_tree_add_item(subtree, hf_gsm_a_bssap_speech_codec, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4206 | proto_item_append_text(item, " - %s",
4207 | val_to_str_const(tvb_get_uint8(tvb, curr_offset) & 0x0f,
4208 | bssap_speech_codec_values,
4209 | "Unknown"));
4210 | curr_offset++;
4211 | consumed++;
4212 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_s0_s15, tvb, curr_offset, 2, ENC_BIG_ENDIAN0x00000000);
4213 | curr_offset+=2;
4214 | consumed+=2;
4215 | break;
4216 | case 0x9:
4217 | /* fall through */
4218 | case 0xc:
4219 | /* fall through */
4220 | case 0xd:
4221 | /* FR_AMR-WB is coded '1001'
4222 | * OFR_AMR-WB is coded '1100'
4223 | * OHR_AMR-WB is coded '1101'
4224 | */
4225 | /* FI indicates Full IP */
4226 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_fi2, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4227 | /* PI indicates PCMoIP */
4228 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pi2, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4229 | /* PT indicates PCMoTDM */
4230 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pt2, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4231 | /* TF indicates TFO support */
4232 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_tf2, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4233 | /* Codec Type */
4234 | proto_tree_add_item(subtree, hf_gsm_a_bssap_speech_codec, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4235 | proto_item_append_text(item, " - %s",
4236 | val_to_str_const(tvb_get_uint8(tvb, curr_offset) & 0x0f,
4237 | bssap_speech_codec_values,
4238 | "Unknown"));
4239 | curr_offset++;
4240 | consumed++;
4241 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_s0_s7, tvb, curr_offset, 1, ENC_NA0x00000000);
4242 | curr_offset++;
4243 | consumed++;
4244 | break;
4245 | case 0xf:
4246 | /* Currently (3GPP TS 48.008 version 9.4.0 Release 9) CSData Codec Type is the only extended one */
4247 | /* PI indicates PCMoIP */
4248 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pi, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4249 | /* PT indicates PCMoTDM */
4250 | proto_tree_add_item(subtree, hf_gsm_a_bssmap_pt, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4251 | /* Codec Type */
4252 | proto_tree_add_item(subtree, hf_gsm_a_bssap_speech_codec, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4253 | curr_offset++;
4254 | consumed++;
4255 | /* Codec Extension */
4256 | proto_tree_add_item(subtree, hf_gsm_a_bssap_extended_codec, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4257 | curr_offset++;
4258 | consumed++;
4259 | proto_tree_add_item(subtree, hf_gsm_a_bssap_extended_codec_r2, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4260 | proto_tree_add_item(subtree, hf_gsm_a_bssap_extended_codec_r3, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4261 | curr_offset++;
4262 | consumed++;
4263 | break;
4264 | default:
4265 | proto_tree_add_expert(subtree, pinfo, &ei_gsm_a_bssap_unknown_codec, tvb, curr_offset, 2);
4266 | curr_offset+=2;
4267 | consumed+=2;
4268 | break;
4269 | }
4270 | }
4271 | proto_item_set_len(item, consumed);
4272 | return len;
4273 | }
4274 | /*
4275 | * 3.2.2.105 Call Identifier
4276 | */
4277 | static uint16_t
4278 | be_call_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4279 | {
4280 | uint32_t curr_offset;
4281 |
4282 | curr_offset = offset;
4283 |
4284 | /* Call Identifier (least significant bits) octet 2
4285 | * Call Identifier octet 3
4286 | * Call Identifier octet 4
4287 | * Call Identifier (most significant bits) octet 5
4288 | */
4289 | proto_tree_add_item(tree, hf_gsm_a_bssmap_call_id, tvb, curr_offset, 4, ENC_LITTLE_ENDIAN0x80000000);
4290 | curr_offset+=4;
4291 |
4292 | return curr_offset-offset;
4293 | }
4294 | /*
4295 | * 3.2.2.106 Call Identifier List
4296 | */
4297 | static uint16_t
4298 | be_call_id_lst(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4299 | {
4300 | uint32_t curr_offset;
4301 | curr_offset = offset;
4302 |
4303 | if (len==0) {
4304 | proto_tree_add_item(tree, hf_gsm_a_bssmap_all_call_identifiers_resources_released, tvb, curr_offset, len, ENC_NA0x00000000);
4305 | }
4306 | while (curr_offset-offset < len) {
4307 | proto_tree_add_item(tree, hf_gsm_a_bssmap_call_id, tvb, curr_offset, 4, ENC_LITTLE_ENDIAN0x80000000);
4308 | curr_offset+=4;
4309 | }
4310 |
4311 | return len;
4312 | }
4313 | /*
4314 | * 3.2.2.107 A-Interface Selector for RESET
4315 | */
4316 | static const true_false_string gsm_a_bssmap_rip_value = {
4317 | "all calls associated to IP links shall be cleared",
4318 | "calls associated to IP links shall not be cleared"
4319 | };
4320 | static const true_false_string gsm_a_bssmap_rtd_value = {
4321 | "all calls associated to TDM links shall be cleared",
4322 | "calls associated to TDM links shall not be cleared"
4323 | };
4324 | static uint16_t
4325 | be_a_itf_sel_for_reset(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4326 | {
4327 | uint32_t curr_offset;
4328 | curr_offset = offset;
4329 |
4330 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, (curr_offset<<3), 6, ENC_BIG_ENDIAN0x00000000);
4331 | proto_tree_add_item(tree, hf_gsm_a_bssmap_rip, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4332 | proto_tree_add_item(tree, hf_gsm_a_bssmap_rtd, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4333 | curr_offset++;
4334 |
4335 | return curr_offset-offset;
4336 | }
4337 | /*
4338 | * 3.2.2.109 Kc128
4339 | */
4340 | static uint16_t
4341 | be_kc128(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4342 | {
4343 | uint32_t curr_offset;
4344 | curr_offset = offset;
4345 |
4346 | proto_tree_add_item(tree, hf_gsm_a_bssmap_kc128, tvb, curr_offset, 16, ENC_NA0x00000000);
4347 | curr_offset+=16;
4348 |
4349 | return curr_offset-offset;
4350 | }
4351 | /*
4352 | * 3.2.2.110 CSG Identifier
4353 | */
4354 | static const crumb_spec_t gsm_a_bssmap_csg_id_crumbs[] = {
4355 | { 0, 24},
4356 | { 29, 3},
4357 | { 0, 0}
4358 | };
4359 | static const true_false_string gsm_a_bssmap_cell_access_mode_value = {
4360 | "Hybrid cell",
4361 | "CSG cell"
4362 | };
4363 | static uint16_t
4364 | be_csg_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4365 | {
4366 | uint32_t bit_offset;
4367 | bit_offset = offset<<3;
4368 |
4369 | proto_tree_add_split_bits_item_ret_val(tree, hf_gsm_a_bssmap_csg_id, tvb, bit_offset, gsm_a_bssmap_csg_id_crumbs, NULL((void*)0));
4370 | bit_offset += 32;
4371 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_spare_bits, tvb, bit_offset, 7, ENC_BIG_ENDIAN0x00000000);
4372 | bit_offset += 7;
4373 | proto_tree_add_bits_item(tree, hf_gsm_a_bssmap_cell_access_mode, tvb, bit_offset, 1, ENC_BIG_ENDIAN0x00000000);
4374 |
4375 | return len;
4376 | }
4377 |
4378 | /*
4379 | * 3.2.2.111 Redirect Attempt Flag
4380 | * No data
4381 | */
4382 |
4383 | /*
4384 | * 3.2.2.112 Reroute Reject Cause
4385 | */
4386 | /*
4387 | * Reroute Reject cause value (octet 2)
4388 | */
4389 |
4390 |
4391 | static const value_string gsm_a_bssap_reroute_rej_cause_vals[] = {
4392 | { 0x0, "Reserved" },
4393 | { 0x1, "Reserved" },
4394 | { 0x2, "Reserved" },
4395 | { 0x3, "Reserved" },
4396 | { 0x4, "Reserved" },
4397 | { 0x5, "Reserved" },
4398 | { 0x6, "Reserved" },
4399 | { 0x7, "Reserved" },
4400 | { 0x8, "Reserved" },
4401 | { 0x9, "Reserved" },
4402 | { 0xa, "Reserved" },
4403 | { 0xb, "PLMN not allowed" },
4404 | { 0xc, "Location area not allowed" },
4405 | { 0xd, "Roaming not allowed in this location area" },
4406 | { 0xe, "GPRS services not allowed in this PLMN" },
4407 | { 0xf, "No suitable cell in location area" },
4408 | { 0x10, "CS/PS domain registration coordination required" },
4409 | { 0, NULL((void*)0) }
4410 | };
4411 |
4412 | static uint16_t
4413 | be_reroute_rej_cause(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4414 | {
4415 | uint32_t curr_offset;
4416 | curr_offset = offset;
4417 |
4418 | proto_tree_add_item(tree, hf_gsm_a_bssmap_reroute_rej_cause, tvb, curr_offset, 1, ENC_NA0x00000000);
4419 | curr_offset+=1;
4420 |
4421 | return curr_offset-offset;
4422 |
4423 | }
4424 |
4425 | /*
4426 | * 3.2.2.113 Send Sequence Number
4427 | */
4428 | static uint16_t
4429 | be_send_seqn(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4430 | {
4431 | uint32_t curr_offset;
4432 | curr_offset = offset;
4433 |
4434 | proto_tree_add_item(tree, hf_gsm_a_bssmap_send_seqn, tvb, curr_offset, 1, ENC_NA0x00000000);
4435 | curr_offset+=1;
4436 |
4437 | return curr_offset-offset;
4438 |
4439 | }
4440 |
4441 | /*
4442 | * 3.2.2.114 Reroute complete outcome
4443 | */
4444 | static const value_string gsm_a_bssap_reroute_outcome_vals[] = {
4445 | { 0x0, "Reserved" },
4446 | { 0x1, "MS is accepted" },
4447 | { 0x2, "MS is not accepted" },
4448 | { 0x3, "MS is already registered" },
4449 | { 0, NULL((void*)0) }
4450 | };
4451 |
4452 | static uint16_t
4453 | be_reroute_outcome(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4454 | {
4455 | uint32_t curr_offset;
4456 | curr_offset = offset;
4457 |
4458 | proto_tree_add_item(tree, hf_gsm_a_bssmap_reroute_outcome, tvb, curr_offset, 1, ENC_NA0x00000000);
4459 | curr_offset+=1;
4460 |
4461 | return curr_offset-offset;
4462 |
4463 | }
4464 |
4465 | /*
4466 | * 3.2.2.115 Global Call Reference as per 3GPP TS 29.205 Section B.2.1.9
4467 | */
4468 | static uint16_t
4469 | be_global_call_ref(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4470 | {
4471 | dissect_bicc_mst_lcls_gcr(tvb, tree, offset, len);
4472 |
4473 | return len;
4474 | }
4475 |
4476 | /*
4477 | * 3.2.2.116 LCLS-Configuration
4478 | */
4479 | static const value_string gsm_a_bssap_lcls_conf_vals[] = {
4480 | { 0x0, "Connect both-way" },
4481 | { 0x1, "Connect both-way and bi-cast UL to the core network" },
4482 | { 0x2, "Connect both-way and send access DL from the core network" },
4483 | { 0x3, "Connect both-way and send access DL from the core network, block local DL user data" },
4484 | { 0x4, "Connect both-way and bi-cast UL to the core network with send access DL from the core network" },
4485 | { 0x5, "Connect both-way and bi-cast UL to the core network with send access DL from the core network, block local DL user data" },
4486 | { 0, NULL((void*)0) }
4487 | };
4488 |
4489 | static uint16_t
4490 | be_lcls_conf(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4491 | {
4492 | uint32_t curr_offset;
4493 | curr_offset = offset;
4494 |
4495 | proto_tree_add_item(tree, hf_gsm_a_bssmap_lcls_conf, tvb, curr_offset, 1, ENC_NA0x00000000);
4496 | curr_offset+=1;
4497 |
4498 | return curr_offset-offset;
4499 |
4500 | }
4501 |
4502 | /*
4503 | * 3.2.2.117 LCLS-Connection-Status-Control
4504 | */
4505 | static const value_string gsm_a_bssap_lcls_con_status_control_vals[] = {
4506 | { 0x0, "Connect" },
4507 | { 0x1, "Do not connect" },
4508 | { 0x2, "Release LCLS" },
4509 | { 0x3, "Bi-cast UL at Handover" },
4510 | { 0x4, "Bi-cast UL and receive DL data at Handover" },
4511 | { 0, NULL((void*)0) }
4512 | };
4513 |
4514 | static uint16_t
4515 | be_lcls_con_status_control(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4516 | {
4517 | uint32_t curr_offset;
4518 | curr_offset = offset;
4519 |
4520 | proto_tree_add_item(tree, hf_gsm_a_bssmap_lcls_con_status_control, tvb, curr_offset, 1, ENC_NA0x00000000);
4521 | curr_offset+=1;
4522 |
4523 | return curr_offset-offset;
4524 |
4525 | }
4526 |
4527 | /*
4528 | * 3.2.2.118 LCLS-Correlation-Not-Needed
4529 | * No data
4530 | */
4531 |
4532 | /*
4533 | * 3.2.2.119 LCLS-BSS-Status
4534 | */
4535 | static const value_string gsm_a_bssmap_lcls_bss_status_vals[] = {
4536 | { 0x0, "Call not yet locally switched" },
4537 | { 0x1, "Call not possible to be locally switched" },
4538 | { 0x2, "Call is no longer locally switched" },
4539 | { 0x3, "Requested LCLS configuration is not supported" },
4540 | { 0x4, "Call is locally switched with requested LCLS configuration" },
4541 | { 0, NULL((void*)0) }
4542 | };
4543 |
4544 | static uint16_t
4545 | be_lcls_bss_status(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4546 | {
4547 | uint32_t curr_offset;
4548 | curr_offset = offset;
4549 |
4550 | proto_tree_add_item(tree, hf_gsm_a_bssmap_lcls_bss_status, tvb, curr_offset, 1, ENC_NA0x00000000);
4551 | curr_offset+=1;
4552 |
4553 | return curr_offset-offset;
4554 |
4555 | }
4556 |
4557 | /*
4558 | * 3.2.2.120 LCLS-Break-Request
4559 | * No data
4560 | */
4561 |
4562 | /*
4563 | * 3.2.2.121 CSFB Indication
4564 | * No data
4565 | */
4566 |
4567 | /*
4568 | * 3.2.2.123 Source eNB to target eNB transparent information (E-UTRAN)
4569 | */
4570 |
4571 | /*
4572 | * 3.2.2.124 CS to PS SRVCC Indication
4573 | */
4574 |
4575 | /*
4576 | * 3.2.2.125 CN to MS transparent information
4577 | */
4578 |
4579 | /*
4580 | * 3.2.2.126 Selected PLMN ID
4581 | */
4582 | static uint16_t
4583 | be_selected_plmn_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4584 | {
4585 |
4586 | dissect_e212_mcc_mnc_wmem_packet_str(tvb, pinfo, tree, offset, E212_NONE, true1);
4587 | return 3;
4588 |
4589 | }
4590 |
4591 | /*
4592 | * 3.2.2.127 Last used E-UTRAN PLMN ID
4593 | */
4594 | static uint16_t
4595 | be_last_used_eutran_plmn_id(tvbuff_t* tvb, proto_tree* tree, packet_info* pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char* add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4596 | {
4597 |
4598 | dissect_e212_mcc_mnc(tvb, pinfo, tree, offset, E212_NONE, true1);
4599 |
4600 | return 3;
4601 |
4602 | }
4603 |
4604 | /* Osmocom extension: Osmux CID */
4605 | static uint16_t
4606 | be_osmocom_osmux_cid(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4607 | {
4608 | proto_tree_add_item(tree, hf_gsm_a_bssmap_osmocom_osmux_cid, tvb, offset, 1, ENC_NA0x00000000);
4609 | return 1;
4610 | }
4611 |
4612 |
4613 | uint16_t (* const bssmap_elem_fcn[])(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string, int string_len) = {
4614 | NULL((void*)0), /* Undefined */
4615 | be_cic, /* Circuit Identity Code */
4616 | NULL((void*)0), /* Reserved */
4617 | be_res_avail, /* Resource Available */
4618 | bssmap_dissect_cause,/* Cause */
4619 | be_cell_id, /* Cell Identifier */
4620 | be_prio, /* Priority */
4621 | be_l3_header_info, /* Layer 3 Header Information */
4622 | de_mid, /* IMSI */
4623 | be_tmsi, /* TMSI */
4624 | be_enc_info, /* Encryption Information */
4625 | be_chan_type, /* Channel Type */
4626 | be_periodicity, /* Periodicity */
4627 | be_ext_res_ind, /* Extended Resource Indicator */
4628 | be_num_ms, /* Number Of MSs */
4629 | NULL((void*)0), /* Reserved */
4630 | NULL((void*)0), /* Reserved */
4631 | NULL((void*)0), /* Reserved */
4632 | de_ms_cm_2, /* Classmark Information Type 2 */
4633 | de_ms_cm_3, /* Classmark Information Type 3 */
4634 | be_int_band, /* Interference Band To Be Used */
4635 | de_rr_cause, /* RR Cause */
4636 | NULL((void*)0), /* Reserved */
4637 | be_l3_info, /* Layer 3 Information */
4638 | be_dlci, /* DLCI */
4639 | be_down_dtx_flag, /* Downlink DTX Flag */
4640 | be_cell_id_list, /* Cell Identifier List */
4641 | NULL((void*)0) /* no associated data */, /* Response Request */
4642 | be_res_ind_method, /* Resource Indication Method */
4643 | de_ms_cm_1, /* Classmark Information Type 1 */
4644 | be_cic_list, /* Circuit Identity Code List */
4645 | be_diag, /* Diagnostics */
4646 | be_l3_msg, /* Layer 3 Message Contents */
4647 | be_chosen_chan, /* Chosen Channel */
4648 | be_tot_res_acc, /* Total Resource Accessible */
4649 | be_ciph_resp_mode, /* Cipher Response Mode */
4650 | be_cha_needed, /* Channel Needed */
4651 | be_trace_type, /* Trace Type */
4652 | be_trace_trigger_id,/* TriggerID */
4653 | be_trace_reference, /* Trace Reference */
4654 | be_trace_transaction_id, /* TransactionID */
4655 | de_mid, /* Mobile Identity */
4656 | be_trace_omc_id, /* OMCID */
4657 | be_for_ind, /* Forward Indicator */
4658 | be_chosen_enc_alg, /* Chosen Encryption Algorithm */
4659 | be_cct_pool, /* Circuit Pool */
4660 | NULL((void*)0), /* Circuit Pool List */
4661 | NULL((void*)0), /* Time Indication */
4662 | NULL((void*)0), /* Resource Situation */
4663 | be_curr_chan_1, /* Current Channel Type 1 */
4664 | be_que_ind, /* Queueing Indicator */
4665 | be_ass_req, /* Assignment Requirement */
4666 | NULL((void*)0), /* Undefined */
4667 | NULL((void*)0) /* no associated data */, /* Talker Flag */
4668 | NULL((void*)0) /* no associated data */, /* Connection Release Requested */
4669 | de_d_gb_call_ref, /* Group Call Reference */
4670 | be_emlpp_prio, /* eMLPP Priority */
4671 | be_conf_evo_ind, /* Configuration Evolution Indication */
4672 | be_field_element_dissect, /* Old BSS to New BSS Information */
4673 | be_lsa_id, /* LSA Identifier */
4674 | be_lsa_id_list, /* LSA Identifier List */
4675 | be_lsa_info, /* LSA Information */
4676 | NULL((void*)0), /* LCS QoS Dissected in packet-gsm_bssmap_le.c*/
4677 | NULL((void*)0), /* LSA access control suppression */
4678 | be_speech_ver, /* Speech Version */
4679 | NULL((void*)0), /* Undefined */
4680 | NULL((void*)0), /* Undefined */
4681 | be_lcs_prio, /* LCS Priority */
4682 | be_loc_type, /* Location Type */
4683 | be_loc_est, /* Location Estimate */
4684 | be_pos_data, /* Positioning Data */
4685 | NULL((void*)0), /* 3.2.2.66 LCS Cause Dissected in packet-gsm_bssmap_le.c */
4686 | NULL((void*)0), /* LCS Client Type Dissected in packet-gsm_bssmap_le.c */
4687 | be_apdu, /* APDU */
4688 | NULL((void*)0), /* Network Element Identity */
4689 | be_gps_assist_data, /* GPS Assistance Data */
4690 | NULL((void*)0), /* Deciphering Keys (dissected in packet-gsm_bssmap_le)*/
4691 | be_ret_err_req, /* Return Error Request */
4692 | be_ret_err_cause, /* Return Error Cause */
4693 | be_seg, /* Segmentation */
4694 | be_serv_ho, /* Service Handover */
4695 | be_src_rnc_to_tar_rnc_umts, /* Source RNC to target RNC transparent information (UMTS) */
4696 | be_src_rnc_to_tar_rnc_cdma, /* Source RNC to target RNC transparent information (cdma2000) */
4697 | be_geran_cls_m, /* GERAN Classmark */
4698 | be_geran_bsc_cont, /* GERAN BSC Container */
4699 | be_vel_est, /* Velocity Estimate */
4700 | NULL((void*)0), /* Undefined */
4701 | NULL((void*)0), /* Undefined */
4702 | NULL((void*)0), /* Undefined */
4703 | NULL((void*)0), /* Undefined */
4704 | NULL((void*)0), /* Undefined */
4705 | NULL((void*)0), /* Undefined */
4706 | NULL((void*)0), /* Undefined */
4707 | NULL((void*)0), /* Undefined */
4708 | NULL((void*)0), /* Undefined */
4709 | NULL((void*)0), /* Undefined */
4710 | NULL((void*)0), /* Undefined */
4711 | be_field_element_dissect, /* New BSS to Old BSS Information */
4712 | NULL((void*)0), /* Undefined */
4713 | be_inter_sys_inf, /* Inter-System Information */
4714 | be_sna_acc_inf, /* SNA Access Information */
4715 | be_vstk_rand_info, /* VSTK_RAND Information */
4716 | be_vstk_info, /* VSTK Information */
4717 | be_paging_inf, /* Paging Information */
4718 | de_mid, /* 3.2.2.86 IMEI (use same dissector as IMSI)*/
4719 | be_vgcs_feat_flg, /* VGCS Feature Flags */
4720 | be_talker_pri, /* Talker Priority */
4721 | NULL((void*)0), /* no data Emergency Set Indication */
4722 | be_talker_id, /* Talker Identity */
4723 | be_cell_id_list_seg, /* Cell Identifier List Segment */
4724 | be_sms_to_vgcs, /* SMS to VGCS */
4725 | be_vgcs_talker_mode,/* VGCS Talker Mode */
4726 | be_vgcs_vbs_cell_status, /* VGCS/VBS Cell Status */
4727 | be_cell_id_lst_seg_f_est_cells, /* Cell Identifier List Segment for established cells */
4728 | be_cell_id_lst_seg_f_cell_tb_est, /* Cell Identifier List Segment for cells to be established */
4729 | be_cell_id_lst_seg_f_rel_cell, /* Cell Identifier List Segment for released cells - no user present */
4730 | be_cell_id_lst_seg_f_not_est_cell, /* Cell Identifier List Segment for not established cells - no establishment possible */
4731 | be_ganss_ass_dta, /* GANSS Assistance Data */
4732 | be_ganss_pos_dta, /* GANSS Positioning Data */
4733 | be_ganss_loc_type, /* GANSS Location Type */
4734 | be_app_data, /* Application Data */
4735 | be_app_data_id, /* Data Identity */
4736 | be_app_data_inf, /* Application Data Information */
4737 | be_msisdn, /* MSISDN */
4738 | be_aoip_trans_lay_add, /* AoIP Transport Layer Address */
4739 | be_speech_codec_lst,/* Speech Codec List */
4740 | be_speech_codec, /* Speech Codec */
4741 | be_call_id, /* Call Identifier */
4742 | be_call_id_lst, /* Call Identifier List */
4743 | be_a_itf_sel_for_reset, /* A-Interface Selector for RESET */
4744 | NULL((void*)0), /* Undefined */
4745 | be_kc128, /* Kc128 */
4746 | be_csg_id, /* CSG Identifier */
4747 | NULL((void*)0), /* Redirect Attempt Flag 3.2.2.111 No data */
4748 | be_reroute_rej_cause, /* Reroute Reject Cause 3.2.2.112 */
4749 | be_send_seqn, /* Send Sequence Number 3.2.2.113 */
4750 | be_reroute_outcome, /* Reroute complete outcome 3.2.2.114 */
4751 | be_global_call_ref, /* Global Call Reference 3.2.2.115 */
4752 | be_lcls_conf, /* LCLS-Configuration 3.2.2.116 */
4753 | be_lcls_con_status_control, /* LCLS-Connection-Status-Control 3.2.2.117 */
4754 | NULL((void*)0), /* LCLS-Correlation-Not-Needed 3.2.2.118 No data */
4755 | be_lcls_bss_status, /* LCLS-BSS-Status 3.2.2.119 */
4756 | NULL((void*)0), /* LCLS-Break-Request 3.2.2.120 No data */
4757 | NULL((void*)0), /* CSFB Indication 3.2.2.121 No data */
4758 | NULL((void*)0), /* CS to PS SRVCC 3.2.2.122 */
4759 | NULL((void*)0), /* Source eNB to target eNB transparent information (E-UTRAN)" 3.2.2.123 */
4760 | NULL((void*)0), /* CS to PS SRVCC Indication 3.2.2.124 */
4761 | NULL((void*)0), /* CN to MS transparent information 3.2.2.125 */
4762 | be_selected_plmn_id, /* Selected PLMN ID 3.2.2.126 */
4763 | be_last_used_eutran_plmn_id, /* Last used E-UTRAN PLMN ID 3.2.2.127 */
4764 | NULL((void*)0), /* 0x96 */
4765 | NULL((void*)0), /* 0x97 */
4766 | NULL((void*)0), /* 0x98 */
4767 | NULL((void*)0), /* 0x99 */
4768 | NULL((void*)0), /* 0x9a */
4769 | NULL((void*)0), /* 0x9b */
4770 | NULL((void*)0), /* 0x9c */
4771 | NULL((void*)0), /* 0x9d */
4772 | NULL((void*)0), /* 0x9e */
4773 | NULL((void*)0), /* 0x9f */
4774 | NULL((void*)0), /* 0xa0 */
4775 | NULL((void*)0), /* 0xa1 */
4776 | NULL((void*)0), /* 0xa2 */
4777 | NULL((void*)0), /* 0xa3 */
4778 | NULL((void*)0), /* 0xa4 */
4779 | NULL((void*)0), /* 0xa5 */
4780 | NULL((void*)0), /* 0xa6 */
4781 | NULL((void*)0), /* 0xa7 */
4782 | NULL((void*)0), /* 0xa8 */
4783 | NULL((void*)0), /* 0xa9 */
4784 | NULL((void*)0), /* 0xaa */
4785 | NULL((void*)0), /* 0xab */
4786 | NULL((void*)0), /* 0xac */
4787 | NULL((void*)0), /* 0xad */
4788 | NULL((void*)0), /* 0xae */
4789 | NULL((void*)0), /* 0xaf */
4790 | NULL((void*)0), /* 0xb0 */
4791 | NULL((void*)0), /* 0xb1 */
4792 | NULL((void*)0), /* 0xb2 */
4793 | NULL((void*)0), /* 0xb3 */
4794 | NULL((void*)0), /* 0xb4 */
4795 | NULL((void*)0), /* 0xb5 */
4796 | NULL((void*)0), /* 0xb6 */
4797 | NULL((void*)0), /* 0xb7 */
4798 | NULL((void*)0), /* 0xb8 */
4799 | NULL((void*)0), /* 0xb9 */
4800 | NULL((void*)0), /* 0xba */
4801 | NULL((void*)0), /* 0xbb */
4802 | NULL((void*)0), /* 0xbc */
4803 | NULL((void*)0), /* 0xbd */
4804 | NULL((void*)0), /* 0xbe */
4805 | NULL((void*)0), /* 0xbf */
4806 | NULL((void*)0), /* 0xc0 */
4807 | NULL((void*)0), /* 0xc1 */
4808 | NULL((void*)0), /* 0xc2 */
4809 | NULL((void*)0), /* 0xc3 */
4810 | NULL((void*)0), /* 0xc4 */
4811 | NULL((void*)0), /* 0xc5 */
4812 | NULL((void*)0), /* 0xc6 */
4813 | NULL((void*)0), /* 0xc7 */
4814 | NULL((void*)0), /* 0xc8 */
4815 | NULL((void*)0), /* 0xc9 */
4816 | NULL((void*)0), /* 0xca */
4817 | NULL((void*)0), /* 0xcb */
4818 | NULL((void*)0), /* 0xcc */
4819 | NULL((void*)0), /* 0xcd */
4820 | NULL((void*)0), /* 0xce */
4821 | NULL((void*)0), /* 0xcf */
4822 | NULL((void*)0), /* 0xd0 */
4823 | NULL((void*)0), /* 0xd1 */
4824 | NULL((void*)0), /* 0xd2 */
4825 | NULL((void*)0), /* 0xd3 */
4826 | NULL((void*)0), /* 0xd4 */
4827 | NULL((void*)0), /* 0xd5 */
4828 | NULL((void*)0), /* 0xd6 */
4829 | NULL((void*)0), /* 0xd7 */
4830 | NULL((void*)0), /* 0xd8 */
4831 | NULL((void*)0), /* 0xd9 */
4832 | NULL((void*)0), /* 0xda */
4833 | NULL((void*)0), /* 0xdb */
4834 | NULL((void*)0), /* 0xdc */
4835 | NULL((void*)0), /* 0xdd */
4836 | NULL((void*)0), /* 0xde */
4837 | NULL((void*)0), /* 0xdf */
4838 | NULL((void*)0), /* 0xe0 */
4839 | NULL((void*)0), /* 0xe1 */
4840 | NULL((void*)0), /* 0xe2 */
4841 | NULL((void*)0), /* 0xe3 */
4842 | NULL((void*)0), /* 0xe4 */
4843 | NULL((void*)0), /* 0xe5 */
4844 | NULL((void*)0), /* 0xe6 */
4845 | NULL((void*)0), /* 0xe7 */
4846 | NULL((void*)0), /* 0xe8 */
4847 | NULL((void*)0), /* 0xe9 */
4848 | NULL((void*)0), /* 0xea */
4849 | NULL((void*)0), /* 0xeb */
4850 | NULL((void*)0), /* 0xec */
4851 | NULL((void*)0), /* 0xed */
4852 | NULL((void*)0), /* 0xee */
4853 | NULL((void*)0), /* 0xef */
4854 | NULL((void*)0), /* Osmocom extension: Osmux Support */
4855 | be_osmocom_osmux_cid, /* Osmocom extension: Osmux CID */
4856 | NULL((void*)0) /* NONE */
4857 |
4858 | };
4859 | /* 3.2.3 Signalling Field Element Coding */
4860 | /* 3.2.3.1 Extra information */
4861 | static const value_string fe_extra_info_prec_vals[] = {
4862 | { 0, "The old BSS recommends that this allocation request should not cause a pre-emption an existing connection" },
4863 | { 1, "The old BSS recommends that this allocation request is allowed to preempt an existing connection based on the information supplied in the Priority information element, if available" },
4864 | { 0, NULL((void*)0)}
4865 | };
4866 |
4867 | static const value_string fe_extra_info_lcs_vals[] = {
4868 | { 0, "No ongoing LCS procedure" },
4869 | { 1, "An ongoing LCS procedure was interrupted by handover. The new BSS may notify the SMLC when the handover is completed" },
4870 | { 0, NULL((void*)0)}
4871 | };
4872 |
4873 | static const value_string fe_extra_info_ue_prob_vals[] = {
4874 | { 0, "This MS supports handover to UMTS" },
4875 | { 1, "This MS does not support handover to UMTS" },
4876 | { 0, NULL((void*)0)}
4877 | };
4878 |
4879 | static uint16_t
4880 | be_fe_extra_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4881 | {
4882 | uint32_t curr_offset;
4883 |
4884 | curr_offset = offset;
4885 | proto_tree_add_item(tree, hf_fe_extra_info_prec, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4886 | proto_tree_add_item(tree, hf_fe_extra_info_lcs, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4887 | proto_tree_add_item(tree, hf_fe_extra_info_ue_prob, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4888 | proto_tree_add_item(tree, hf_fe_extra_info_spare, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4889 | curr_offset++;
4890 |
4891 | return curr_offset-offset;
4892 | }
4893 |
4894 | /* 3.2.3.2 Current Channel type 2 */
4895 | static uint16_t
4896 | be_fe_cur_chan_type2(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4897 | {
4898 | uint32_t curr_offset;
4899 |
4900 | curr_offset = offset;
4901 | proto_tree_add_item(tree, hf_fe_cur_chan_type2_chan_mode, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4902 | proto_tree_add_item(tree, hf_fe_cur_chan_type2_chan_mode_spare, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4903 | curr_offset++;
4904 | proto_tree_add_item(tree, hf_fe_cur_chan_type2_chan_field, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4905 | proto_tree_add_item(tree, hf_fe_cur_chan_type2_chan_field_spare, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4906 | curr_offset++;
4907 |
4908 | return curr_offset-offset;
4909 | }
4910 |
4911 | /* 3.2.3.3 Target cell radio information */
4912 | static uint16_t
4913 | be_fe_target_radio_cell_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4914 | {
4915 | uint32_t curr_offset;
4916 |
4917 | curr_offset = offset;
4918 | proto_tree_add_item(tree, hf_fe_target_radio_cell_info_rxlev_ncell, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4919 | proto_tree_add_item(tree, hf_fe_target_radio_cell_info_rxlev_ncell_spare, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4920 | curr_offset++;
4921 |
4922 | return curr_offset-offset;
4923 | }
4924 |
4925 | /* 3.2.3.4 GPRS Suspend Information */
4926 | static uint16_t
4927 | be_fe_gprs_suspend_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4928 | {
4929 | uint32_t curr_offset = offset;
4930 |
4931 | /* This Field Element contains the contents of the Gb interface SUSPEND ACK PDU,
4932 | Call the BSSGP dissector here, assuming that the encoding is per 48.018 */
4933 |
4934 |
4935 | bssgp_suspend_ack(tvb, tree, pinfo, offset, len);
4936 | curr_offset += len;
4937 |
4938 | return curr_offset-offset;
4939 | }
4940 |
4941 | /* 3.2.3.5 MultiRate configuration Information */
4942 |
4943 | /* 3.2.3.6 Dual Transfer Mode information */
4944 | static const value_string gsm_a_bssmap_dtm_info_dtm_ind_vals[] = {
4945 | { 0, "The MS has resources allocated exclusively for the CS domain in the old cell" },
4946 | { 1, "The MS has resources allocated for both the CS and PS domains in the old cell" },
4947 | { 0, NULL((void*)0) }
4948 | };
4949 |
4950 | static const value_string gsm_a_bssmap_dtm_info_sto_ind_vals[] = {
4951 | { 0, "The MS is in multislot operation in the old cell" },
4952 | { 1, "The MS is in single timeslot operation in the old cell" },
4953 | { 0, NULL((void*)0) }
4954 | };
4955 |
4956 | static const value_string gsm_a_bssmap_dtm_info_egprs_ind_vals[] = {
4957 | { 0, "The MS has no TBF using E-GPRS in the old cell" },
4958 | { 1, "The MS has a TBF using E-GPRS in the old cell" },
4959 | { 0, NULL((void*)0) }
4960 | };
4961 |
4962 | static uint16_t
4963 | be_fe_dual_transfer_mode_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4964 | {
4965 | uint32_t curr_offset;
4966 |
4967 | curr_offset = offset;
4968 | proto_tree_add_item(tree, hf_fe_dtm_info_dtm_ind, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4969 | proto_tree_add_item(tree, hf_fe_dtm_info_sto_ind, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4970 | proto_tree_add_item(tree, hf_fe_dtm_info_egprs_ind, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4971 | proto_tree_add_item(tree, hf_fe_dtm_info_spare_bits, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
4972 | curr_offset++;
4973 |
4974 | return curr_offset-offset;
4975 | }
4976 |
4977 | /* 3.2.3.7 Inter RAT Handover Info */
4978 | static uint16_t
4979 | be_fe_inter_rat_handover_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
4980 | {
4981 | tvbuff_t *container_tvb;
4982 |
4983 | /* Octets 3-n are encoded as Inter RAT Handover Info as defined in 3GPP TS 25.331 */
4984 | container_tvb = tvb_new_subset_length(tvb, offset, len);
4985 | dissect_rrc_InterRATHandoverInfo_PDU(container_tvb, pinfo, tree, NULL((void*)0));
4986 |
4987 | return len;
4988 | }
4989 |
4990 | /* 3.2.3.8 cdma2000 Capability Information */
4991 |
4992 | /* 3.2.3.9 Downlink Cell Load Information */
4993 |
4994 | /* 3.2.3.10 Uplink Cell Load Information */
4995 |
4996 |
4997 | static const value_string gsm_a_bssmap_cell_load_nrt_vals[] = {
4998 | { 0, "NRT Load is low" },
4999 | { 1, "NRT load is medium" },
5000 | { 2, "NRT load is high. (Probability to admit a new user is low.)" },
5001 | { 3, "NRT overload. (Probability to admit a new user is low, packets are discarded and the source is recommended to reduce the data flow.)" },
5002 | { 0, NULL((void*)0) }
5003 | };
5004 |
5005 | /* 3.2.3.11 Cell Load Information Group */
5006 | static uint16_t
5007 | be_fe_cell_load_info_group(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
5008 | {
5009 | uint32_t curr_offset;
5010 |
5011 | curr_offset = offset;
5012 | curr_offset += be_cell_id(tvb, tree, pinfo, curr_offset, len, NULL((void*)0), 0);
5013 | curr_offset += be_field_element_dissect(tvb, tree, pinfo, curr_offset, len + offset - curr_offset, NULL((void*)0), 0);
5014 |
5015 | return curr_offset-offset;
5016 | }
5017 |
5018 | /* 3.2.3.12 Cell Load Information */
5019 | static uint16_t
5020 | be_fe_cell_load_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
5021 | {
5022 | uint32_t curr_offset;
5023 |
5024 | curr_offset = offset;
5025 | proto_tree_add_item(tree, hf_fe_cell_load_info_cell_capacity_class, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
5026 | curr_offset++;
5027 | proto_tree_add_item(tree, hf_fe_cell_load_info_load_value, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
5028 | curr_offset++;
5029 | proto_tree_add_item(tree, hf_fe_cell_load_info_rt_load_value, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
5030 | curr_offset++;
5031 | proto_tree_add_item(tree, hf_fe_cell_load_info_nrt_load_information_value, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
5032 | curr_offset++;
5033 |
5034 | return curr_offset-offset;
5035 | }
5036 |
5037 | /* 3.2.3.13 PS Indication */
5038 | static uint16_t
5039 | be_fe_ps_indication(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
5040 | {
5041 | uint32_t curr_offset;
5042 |
5043 | curr_offset = offset;
5044 | proto_tree_add_item(tree, hf_fe_ps_indication, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
5045 | curr_offset++;
5046 |
5047 | return curr_offset-offset;
5048 | }
5049 |
5050 | /* 3.2.3.14 DTM Handover Command Indication */
5051 | static uint16_t
5052 | be_fe_dtm_ho_command_ind(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo _U___attribute__((unused)), uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
5053 | {
5054 | uint32_t curr_offset;
5055 |
5056 | curr_offset = offset;
5057 | proto_tree_add_item(tree, hf_fe_dtm_ho_command_ind_spare, tvb, curr_offset, 1, ENC_BIG_ENDIAN0x00000000);
5058 | curr_offset++;
5059 |
5060 | return curr_offset-offset;
5061 | }
5062 |
5063 | /* 3.2.3.17 Source Cell ID */
5064 | static uint16_t
5065 | be_fe_source_cell_id(tvbuff_t* tvb, proto_tree* tree, packet_info* pinfo _U___attribute__((unused)), uint32_t offset, unsigned len, char* add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
5066 | {
5067 | tvbuff_t* new_tvb;
5068 | uint32_t curr_offset;
5069 |
5070 | curr_offset = offset;
5071 |
5072 | /* Tracking Area Identity: Octets 3 to 7 contain the value part of the Tracking Area Identity IE defined in 3GPP TS 24.301, not including 3GPP TS 24.301 IEI. */
5073 | curr_offset += de_emm_trac_area_id(tvb, tree, pinfo, curr_offset, 5, NULL((void*)0), 0);
5074 | /* E-UTRAN CGI: Octets 8 - m contain the value part of the E-UTRAN CGI IE defined 3GPP TS 36.413 for the source cell. */
5075 | new_tvb = tvb_new_subset_remaining(tvb, curr_offset);
5076 | curr_offset += dissect_s1ap_EUTRAN_CGI_PDU(new_tvb , pinfo, tree, NULL((void*)0));
5077 | /* Global eNB ID: Octets (m+1) - n contain the value part of the Global eNB ID IE defined 3GPP TS 36.413 for the source eNB. */
5078 | new_tvb = tvb_new_subset_remaining(tvb, curr_offset);
5079 | dissect_s1ap_Global_ENB_ID_PDU(new_tvb, pinfo, tree, NULL((void*)0));
5080 |
5081 | return len;
5082 | }
5083 |
5084 |
5085 | static uint16_t (* const bssmap_bss_to_bss_element_fcn[])(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len, char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused))) = {
5086 | be_fe_extra_info, /* { 0x01, "Extra information" }, */
5087 | be_fe_cur_chan_type2, /* { 0x02, "Current Channel Type 2" }, */
5088 | be_fe_target_radio_cell_info, /* { 0x03, "Target cell radio information" }, */
5089 | be_fe_gprs_suspend_info, /* { 0x04, "GPRS Suspend information" }, */
5090 | de_rr_multirate_conf, /* { 0x05, "MultiRate configuration information" }, */
5091 | be_fe_dual_transfer_mode_info, /* { 0x06, "Dual Transfer Mode Information" }, */
5092 | be_fe_inter_rat_handover_info, /* { 0x07, "Inter RAT Handover Info" }, */
5093 | NULL((void*)0), /* { 0x08, "cdma2000 Capability Information" }, */
5094 | be_fe_cell_load_info, /* { 0x09, "Downlink Cell Load Information" }, */
5095 | be_fe_cell_load_info, /* { 0x0a, "Uplink Cell Load Information" }, */
5096 | be_fe_cell_load_info_group, /* { 0x0b, "Cell Load Information Group" }, 3.2.3.11 */
5097 | be_fe_cell_load_info, /* { 0x0c, "Cell Load Information" }, */
5098 | be_fe_ps_indication, /* { 0x0d, "PS Indication" }, 3.2.3.13 */
5099 | be_fe_dtm_ho_command_ind, /* { 0x0e, "DTM Handover Command Indication" }, 3.2.3.14 */
5100 | NULL((void*)0), /* { 0x0f, "IRAT Measurement Configuration" }, 3.2.3.16 */
5101 | be_fe_source_cell_id, /* { 0x10, "Source Cell ID" }, 3.2.3.17 */
5102 | NULL((void*)0), /* { 0x11, "IRAT Measurement Configuration (extended E-ARFCNs)" }, 3.2.3.18 */
5103 | be_vgcs_talker_mode, /* { 0x6f, "VGCS talker mode" }, */ /* not really a field element
5104 | but does appear in old bss to new bss info 3.2.2.93 */
5105 | be_last_used_eutran_plmn_id, /* { 0x95, "Last used E-UTRAN PLMN ID" }, 3.2.2.127 */
5106 | NULL((void*)0), /* { 0xfe, "D-RNTI" }, 3.2.3.15 */
5107 | NULL((void*)0), /* NONE */
5108 | };
5109 |
5110 | #define NUM_BSS_ELEMENT_FCNS(int)(sizeof (bssmap_bss_to_bss_element_fcn) / sizeof (bssmap_bss_to_bss_element_fcn )[0]) (int)array_length(bssmap_bss_to_bss_element_fcn)(sizeof (bssmap_bss_to_bss_element_fcn) / sizeof (bssmap_bss_to_bss_element_fcn )[0])
5111 |
5112 | static uint16_t
5113 | be_field_element_dissect(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len _U___attribute__((unused)), char *add_string _U___attribute__((unused)), int string_len _U___attribute__((unused)))
5114 | {
5115 | uint32_t curr_offset, ie_len, fe_start_offset, ie_id_off, len_len;
5116 | int idx;
5117 | const char *str;
5118 | proto_tree * bss_to_bss_tree = NULL((void*)0);
5119 | bool_Bool has_len = true1;
5120 |
5121 | curr_offset = offset;
5122 |
5123 |
5124 | while (curr_offset - offset + 2 < len) {
5125 | uint8_t oct;
5126 | /*
5127 | * add name
5128 | */
5129 | ie_id_off = curr_offset;
5130 | oct = tvb_get_uint8(tvb, curr_offset++);
5131 |
5132 | str = try_val_to_str_idx((uint32_t) oct, bssmap_field_element_ids, &idx);
5133 | /* It looks like a few IEs come without length Check for those here */
5134 | switch (oct) {
5135 | case 0x95:
5136 | /* 3.2.2.127 Last used E-UTRAN PLMN ID */
5137 | len_len = 0;
5138 | ie_len = 3; /* Data part */
5139 | has_len = false0;
5140 | break;
5141 | default:
5142 | len_len = 1;
5143 | ie_len = tvb_get_uint8(tvb, curr_offset++);
5144 | break;
5145 | }
5146 |
5147 | if (!str)
5148 | str = "Unknown";
5149 |
5150 | /* Add subtree */
5151 | bss_to_bss_tree = proto_tree_add_subtree_format(tree, tvb, ie_id_off, ie_len + 1 + len_len, ett_bss_to_bss_info, NULL((void*)0), "%s", str);
5152 | /*
5153 | * add Field Element name and length
5154 | */
5155 | proto_tree_add_item(bss_to_bss_tree, hf_gsm_a_bssmap_field_elem_id, tvb, ie_id_off, 1, ENC_BIG_ENDIAN0x00000000);
5156 | if (has_len) {
5157 | proto_tree_add_item(bss_to_bss_tree, hf_gsm_a_bssmap_field_elem_id_len, tvb, curr_offset - 1, 1, ENC_BIG_ENDIAN0x00000000);
5158 | }
5159 |
5160 | fe_start_offset = curr_offset;
5161 |
5162 | /*
5163 | * decode field element
5164 | */
5165 | if (idx < 0 || idx >= NUM_BSS_ELEMENT_FCNS(int)(sizeof (bssmap_bss_to_bss_element_fcn) / sizeof (bssmap_bss_to_bss_element_fcn )[0]) ||
5166 | (bssmap_bss_to_bss_element_fcn[idx] == NULL((void*)0)))
5167 | {
5168 | proto_tree_add_expert_format(bss_to_bss_tree, pinfo, &ei_gsm_a_bssmap_not_decoded_yet,
5169 | tvb, curr_offset, ie_len, "Field Element not decoded");
5170 | curr_offset += ie_len;
5171 | }
5172 | else
5173 | {
5174 | /* dissect the field element */
5175 | curr_offset += (*bssmap_bss_to_bss_element_fcn[idx])(tvb, bss_to_bss_tree, pinfo, curr_offset, ie_len, NULL((void*)0), 0);
5176 |
5177 | EXTRANEOUS_DATA_CHECK(ie_len, curr_offset - fe_start_offset, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((ie_len) > (curr_offset - fe_start_offset)) { proto_tree_add_expert (tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset , (ie_len) - (curr_offset - fe_start_offset)); curr_offset += ((ie_len) - (curr_offset - fe_start_offset)); };
5178 |
5179 | }
5180 | }
5181 | return len;
5182 | }
5183 | /* MESSAGE FUNCTIONS */
5184 |
5185 | /*
5186 | * [2] 3.2.1.1 ASSIGNMENT REQUEST
5187 | * 48.008 8.4.0
5188 | */
5189 | static void
5190 | bssmap_ass_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5191 | {
5192 | uint32_t curr_offset;
5193 | uint32_t consumed;
5194 | unsigned curr_len;
5195 |
5196 | curr_offset = offset;
5197 | curr_len = len;
5198 |
5199 | /* Channel Type 3.2.2.11 MSC-BSS M 5-13 */
5200 | ELEM_MAND_TLV(BE_CHAN_TYPE, GSM_A_PDU_TYPE_BSSMAP, BE_CHAN_TYPE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CHAN_TYPE, 0, BE_CHAN_TYPE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CHAN_TYPE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CHAN_TYPE ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5201 | /* Layer 3 Header Information 3.2.2.9 MSC-BSS O (note 3) 4 */
5202 | ELEM_OPT_TLV(BE_L3_HEADER_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_L3_HEADER_INFO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_L3_HEADER_INFO, 0, BE_L3_HEADER_INFO , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5203 | /* Priority 3.2.2.18 MSC-BSS O 3 */
5204 | ELEM_OPT_TLV(BE_PRIO, GSM_A_PDU_TYPE_BSSMAP, BE_PRIO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_PRIO, 0, BE_PRIO, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5205 | /* Circuit Identity Code 3.2.2.2 MSC-BSS O (note 1, 12 3 */
5206 | ELEM_OPT_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed ; } };
5207 | /* Downlink DTX Flag 3.2.2.26 MSC-BSS O (note 2) 2 */
5208 | ELEM_OPT_TV(BE_DOWN_DTX_FLAG, GSM_A_PDU_TYPE_BSSMAP, BE_DOWN_DTX_FLAG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_DOWN_DTX_FLAG, 0, BE_DOWN_DTX_FLAG , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5209 | /* Interference Band To Be Used 3.2.2.21 MSC-BSS O 2 */
5210 | ELEM_OPT_TV(BE_INT_BAND, GSM_A_PDU_TYPE_BSSMAP, BE_INT_BAND, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_INT_BAND, 0, BE_INT_BAND, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5211 | /* Classmark Information 2 3.2.2.19 MSC-BSS O (note 4) 4-5 */
5212 | ELEM_OPT_TLV(BE_CM_INFO_2, GSM_A_PDU_TYPE_BSSMAP, BE_CM_INFO_2, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CM_INFO_2, 0, BE_CM_INFO_2, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5213 | /* Group Call Reference 3.2.2.55 MSC-BSS O (note 5) 7 */
5214 | ELEM_OPT_TLV(BE_GROUP_CALL_REF, GSM_A_PDU_TYPE_BSSMAP, BE_GROUP_CALL_REF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_GROUP_CALL_REF, 0, BE_GROUP_CALL_REF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5215 | /* Talker Flag 3.2.2.54 MSC-BSS O (note 6) 1 */
5216 | ELEM_OPT_T(BE_TALKER_FLAG, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_FLAG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_t (tvb, tree, pinfo, (uint8_t) BE_TALKER_FLAG, 0, BE_TALKER_FLAG , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5217 | /* Configuration Evolution Indication 3.2.2.57 MSC-BSS O (note 7) 2 */
5218 | ELEM_OPT_TV(BE_CONF_EVO_IND, GSM_A_PDU_TYPE_BSSMAP, BE_CONF_EVO_IND, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CONF_EVO_IND, 0, BE_CONF_EVO_IND , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5219 | /* LSA Access Control Suppression 3.2.2.61 MSC-BSS O (note 8) 2 */
5220 | ELEM_OPT_TV(BE_LSA_ACC_CTRL, GSM_A_PDU_TYPE_BSSMAP, BE_LSA_ACC_CTRL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LSA_ACC_CTRL, 0, BE_LSA_ACC_CTRL , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5221 | /* Service Handover 3.2.2.75 MSC-BSS O (note 9) 3 */
5222 | ELEM_OPT_TLV(BE_SERV_HO, GSM_A_PDU_TYPE_BSSMAP, BE_SERV_HO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SERV_HO, 0, BE_SERV_HO, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5223 | /* Encryption Information 3.2.2.10 MSC-BSS O (note 10) 3-n */
5224 | ELEM_OPT_TLV(BE_ENC_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_ENC_INFO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_ENC_INFO, 0, BE_ENC_INFO, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5225 | /* Talker Priority 3.2.2.89 MSC-BSS O (note 11) 2 */
5226 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5227 | /* AoIP Transport Layer Address (MGW) 3.2.2.102 MSC-BSS O (note 12) 10-22 */
5228 | ELEM_OPT_TLV(BE_AOIP_TRANS_LAY_ADD, GSM_A_PDU_TYPE_BSSMAP, BE_AOIP_TRANS_LAY_ADD, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_AOIP_TRANS_LAY_ADD, 0, BE_AOIP_TRANS_LAY_ADD , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5229 | /* Codec List (MSC Preferred) 3.2.2.103 MSC-BSS O (note 13) 3-n */
5230 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(MSC Preferred)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(MSC Preferred)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5231 | /* Call Identifier 3.2.2.105 MSC-BSS O (note 12) 5 */
5232 | ELEM_OPT_TV(BE_CALL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CALL_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CALL_ID, 0, BE_CALL_ID, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5233 | /* Kc128 3.2.2.109 MSC-BSS C (note 15) 17 */
5234 | ELEM_OPT_TV(BE_KC128, GSM_A_PDU_TYPE_BSSMAP, BE_KC128, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_KC128, 0, BE_KC128, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5235 | /* Global Call Reference 3.2.2.115 MSC-BSS O (note 16) 3-n*/
5236 | ELEM_OPT_TLV(BE_GLOBAL_CALL_REF, GSM_A_PDU_TYPE_BSSMAP, BE_GLOBAL_CALL_REF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_GLOBAL_CALL_REF, 0, BE_GLOBAL_CALL_REF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5237 | /* LCLS-Configuration 3.2.2.116 MSC-BSS O (note 16) 2*/
5238 | ELEM_OPT_TV(BE_LCLS_CONF, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_CONF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_CONF, 0, BE_LCLS_CONF, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5239 | /* LCLS-Connection-Status-Control 3.2.2.117 MSC-BSS O (note 17) 2*/
5240 | ELEM_OPT_TV(BE_LCLS_CON_STATUS_CONTROL, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_CON_STATUS_CONTROL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_CON_STATUS_CONTROL, 0, BE_LCLS_CON_STATUS_CONTROL , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5241 | /* LCLS-Correlation-Not-Needed 3.2.2.118 MSC-BSS O (note 18) 1*/
5242 | ELEM_OPT_T(BE_LCLS_CORR_NOT_NEEDED, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_CORR_NOT_NEEDED, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_t (tvb, tree, pinfo, (uint8_t) BE_LCLS_CORR_NOT_NEEDED, 0, BE_LCLS_CORR_NOT_NEEDED , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5243 | /* CS to PS SRVCC 3.2.2.122 MSC-BSS O (note 19) 1*/
5244 | /* Osmocom extension: Osmux CID */
5245 | ELEM_OPT_TV(BE_OSMOCOM_OSMUX_CID, GSM_A_PDU_TYPE_BSSMAP, BE_OSMOCOM_OSMUX_CID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_OSMOCOM_OSMUX_CID, 0, BE_OSMOCOM_OSMUX_CID , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5246 |
5247 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5248 | }
5249 |
5250 | /*
5251 | * [2] 3.2.1.2 ASSIGNMENT COMPLETE
5252 | */
5253 | static void
5254 | bssmap_ass_complete(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5255 | {
5256 | uint32_t curr_offset;
5257 | uint32_t consumed;
5258 | unsigned curr_len;
5259 |
5260 | curr_offset = offset;
5261 | curr_len = len;
5262 |
5263 | /* RR Cause 3.2.2.22 BSS-MSC O 2 */
5264 | ELEM_OPT_TV(BE_RR_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_RR_CAUSE, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_RR_CAUSE, 0, BE_RR_CAUSE, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5265 | /* Circuit Identity Code 3.2.2.2 BSS-MSC O (note 4) 3 */
5266 | ELEM_OPT_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed ; } };
5267 | /* Cell Identifier 3.2.2.17 BSS-MSC O (note 1) 3-10 */
5268 | ELEM_OPT_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5269 | /* Chosen Channel 3.2.2.33 BSS-MSC O (note 3) 2 */
5270 | ELEM_OPT_TV(BE_CHOSEN_CHAN, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_CHAN, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_CHAN, 0, BE_CHOSEN_CHAN , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5271 | /* Chosen Encryption Algorithm 3.2.2.44 BSS-MSC O (note 5) 2 */
5272 | ELEM_OPT_TV(BE_CHOSEN_ENC_ALG, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_ENC_ALG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_ENC_ALG, 0, BE_CHOSEN_ENC_ALG , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5273 | /* Circuit Pool 3.2.2.45 BSS-MSC O (note 2) 2 */
5274 | ELEM_OPT_TV(BE_CCT_POOL, GSM_A_PDU_TYPE_BSSMAP, BE_CCT_POOL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CCT_POOL, 0, BE_CCT_POOL, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5275 | /* Speech Version (Chosen) 3.2.2.51 BSS-MSC O (note 6) 2 */
5276 | ELEM_OPT_TV(BE_SPEECH_VER, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_VER, " (Chosen)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_VER, 0, BE_SPEECH_VER, curr_offset, " (Chosen)")) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5277 | /* LSA Identifier 3.2.2.15 BSS-MSC O (note 7) 5 */
5278 | ELEM_OPT_TLV(BE_LSA_ID, GSM_A_PDU_TYPE_BSSMAP, BE_LSA_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LSA_ID, 0, BE_LSA_ID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5279 | /* Talker Priority 3.2.2.89 BSS-MSC O (note 8) 2 */
5280 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5281 | /* AoIP Transport Layer Address (BSS) 3.2.2.102 BSS-MSC O (note 9) 10-22 */
5282 | ELEM_OPT_TLV(BE_AOIP_TRANS_LAY_ADD, GSM_A_PDU_TYPE_BSSMAP, BE_AOIP_TRANS_LAY_ADD, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_AOIP_TRANS_LAY_ADD, 0, BE_AOIP_TRANS_LAY_ADD , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5283 | /* Speech Codec (Chosen) 3.2.2.104 BSS-MSC O (note 10) 3-5 */
5284 | ELEM_OPT_TLV(BE_SPEECH_CODEC, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC, "(Chosen)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC, 0, BE_SPEECH_CODEC , curr_offset, curr_len, "(Chosen)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5285 | /* Codec List (BSS supported) 3.2.2.103 MSC-BSS O (note 11) 3-n */
5286 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(BSS Supported)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(BSS Supported)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5287 | /* LCLS-BSS-Status 3.2.2.119 BSS-MSC O (note 12) 2 */
5288 | ELEM_OPT_TV(BE_LCLS_BSS_STATUS, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_BSS_STATUS, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_BSS_STATUS, 0, BE_LCLS_BSS_STATUS , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5289 | /* Osmocom extension: Osmux CID */
5290 | ELEM_OPT_TV(BE_OSMOCOM_OSMUX_CID, GSM_A_PDU_TYPE_BSSMAP, BE_OSMOCOM_OSMUX_CID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_OSMOCOM_OSMUX_CID, 0, BE_OSMOCOM_OSMUX_CID , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5291 |
5292 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5293 | }
5294 |
5295 | /*
5296 | * [2] 3.2.1.3 ASSIGNMENT FAILURE
5297 | */
5298 | static void
5299 | bssmap_ass_failure(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5300 | {
5301 | uint32_t curr_offset;
5302 | uint32_t consumed;
5303 | unsigned curr_len;
5304 |
5305 | curr_offset = offset;
5306 | curr_len = len;
5307 |
5308 | /* Cause 3.2.2.5 BSS-MSC M 3-4 */
5309 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5310 | /* RR Cause 3.2.2.22 BSS-MSC O 2 */
5311 | ELEM_OPT_TV(BE_RR_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_RR_CAUSE, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_RR_CAUSE, 0, BE_RR_CAUSE, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5312 | /* Circuit Pool 3.2.2.45 BSS-MSC O (note 1) 2 */
5313 | ELEM_OPT_TV(BE_CCT_POOL, GSM_A_PDU_TYPE_BSSMAP, BE_CCT_POOL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CCT_POOL, 0, BE_CCT_POOL, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5314 | /* Circuit Pool List 3.2.2.46 BSS-MSC O (note 2) V */
5315 | ELEM_OPT_TLV(BE_CCT_POOL_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CCT_POOL_LIST, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CCT_POOL_LIST, 0, BE_CCT_POOL_LIST , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5316 | /* Talker Priority 3.2.2.89 BSS-MSC O (note 3) 2 */
5317 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5318 | /* Codec List (BSS Supported) 3.2.2.103 BSS-MSC O (note 4) 3-n */
5319 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(BSS Supported)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(BSS Supported)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5320 |
5321 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5322 | }
5323 |
5324 | /*
5325 | * [2] 3.2.1.4 BLOCK
5326 | */
5327 | static void
5328 | bssmap_block(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5329 | {
5330 | uint32_t curr_offset;
5331 | uint32_t consumed;
5332 | unsigned curr_len;
5333 |
5334 | curr_offset = offset;
5335 | curr_len = len;
5336 |
5337 | /* Circuit Identity Code 3.2.2.2 both M 3*/
5338 | ELEM_MAND_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed ; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element , tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC), (( (void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5339 | /* Cause 3.2.2.5 both M 3-4 */
5340 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5341 | /* Connection Release Requested 3.2.2.3 MSC-BSS O 1 */
5342 | ELEM_OPT_T(BE_CONN_REL_REQ, GSM_A_PDU_TYPE_BSSMAP, BE_CONN_REL_REQ, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_t (tvb, tree, pinfo, (uint8_t) BE_CONN_REL_REQ, 0, BE_CONN_REL_REQ , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5343 |
5344 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5345 | }
5346 |
5347 | /*
5348 | * [2] 3.2.1.5 BLOCKING ACKNOWLEDGE
5349 | */
5350 |
5351 | static void
5352 | bssmap_block_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5353 | {
5354 | uint32_t curr_offset;
5355 | uint32_t consumed;
5356 | unsigned curr_len;
5357 |
5358 | curr_offset = offset;
5359 | curr_len = len;
5360 |
5361 | /* Circuit Identity Code 3.2.2.2 both M 3 */
5362 | ELEM_MAND_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed ; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element , tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC), (( (void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5363 |
5364 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5365 | }
5366 |
5367 | /*
5368 | * [2] 3.2.1.6 UNBLOCK
5369 | */
5370 | static void
5371 | bssmap_unblock(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5372 | {
5373 | uint32_t curr_offset;
5374 | uint32_t consumed;
5375 | unsigned curr_len;
5376 |
5377 | curr_offset = offset;
5378 | curr_len = len;
5379 |
5380 | /* Circuit Identity Code 3.2.2.2 both M 3 */
5381 | ELEM_MAND_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed ; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element , tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC), (( (void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5382 |
5383 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5384 | }
5385 |
5386 | /*
5387 | * [2] 3.2.1.7 UNBLOCKING ACKNOWLEDGE
5388 | */
5389 | static void
5390 | bssmap_unblock_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5391 | {
5392 | uint32_t curr_offset;
5393 | uint32_t consumed;
5394 | unsigned curr_len;
5395 |
5396 | curr_offset = offset;
5397 | curr_len = len;
5398 |
5399 | /* Circuit Identity Code 3.2.2.2 both M 3 */
5400 | ELEM_MAND_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed ; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element , tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC), (( (void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5401 |
5402 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5403 | }
5404 |
5405 | /*
5406 | * [2] 3.2.1.8 HANDOVER REQUEST
5407 | */
5408 | static void
5409 | bssmap_ho_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5410 | {
5411 | uint32_t curr_offset;
5412 | uint32_t consumed;
5413 | unsigned curr_len;
5414 |
5415 | curr_offset = offset;
5416 | curr_len = len;
5417 |
5418 | /* Channel Type 3.2.2.11 MSC-BSS M 5-13 */
5419 | ELEM_MAND_TLV(BE_CHAN_TYPE, GSM_A_PDU_TYPE_BSSMAP, BE_CHAN_TYPE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CHAN_TYPE, 0, BE_CHAN_TYPE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CHAN_TYPE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CHAN_TYPE ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5420 | /* Encryption Information 3.2.2.10 MSC-BSS M (note 1) 3-n */
5421 | ELEM_MAND_TLV(BE_ENC_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_ENC_INFO, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_ENC_INFO, 0, BE_ENC_INFO, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_ENC_INFO, get_gsm_a_msg_string(pinfo->pool, 0, BE_ENC_INFO ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5422 |
5423 | /* Classmark Information 1 3.2.2.30 MSC-BSS M# 2
5424 | * or
5425 | * Classmark Information 2 3.2.2.19 MSC-BSS M (note 6) 4-5
5426 | */
5427 | ELEM_OPT_TV(BE_CM_INFO_1, GSM_A_PDU_TYPE_BSSMAP, BE_CM_INFO_1, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CM_INFO_1, 0, BE_CM_INFO_1, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5428 |
5429 | ELEM_OPT_TLV(BE_CM_INFO_2, GSM_A_PDU_TYPE_BSSMAP, BE_CM_INFO_2, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CM_INFO_2, 0, BE_CM_INFO_2, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5430 | /* Cell Identifier (Serving) 3.2.2.17 MSC-BSS M (note 20) 5-10 */
5431 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, " (Serving)", ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, " (Serving)")) > 0)) { curr_offset += consumed ; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (" (Serving)" == ((void*)0)) ? "" : " (Serving)" ); } };
5432 | /* Priority 3.2.2.18 MSC-BSS O 3 */
5433 | ELEM_OPT_TLV(BE_PRIO, GSM_A_PDU_TYPE_BSSMAP, BE_PRIO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_PRIO, 0, BE_PRIO, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5434 | /* Circuit Identity Code 3.2.2.2 MSC-BSS O (note 7, 28 3 */
5435 | ELEM_OPT_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed ; } };
5436 | /* Downlink DTX Flag 3.2.2.26 MSC-BSS O (note 3) 2 */
5437 | ELEM_OPT_TV(BE_DOWN_DTX_FLAG, GSM_A_PDU_TYPE_BSSMAP, BE_DOWN_DTX_FLAG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_DOWN_DTX_FLAG, 0, BE_DOWN_DTX_FLAG , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5438 | /* Cell Identifier (Target) 3.2.2.17 MSC-BSS M (note 17) 3-10 */
5439 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, " (Target)", ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, " (Target)")) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format( tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb , curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (" (Target)" == ((void*)0)) ? "" : " (Target)" ); } };
5440 | /* Interference Band To Be Used 3.2.2.21 MSC-BSS O 2 */
5441 | ELEM_OPT_TV(BE_INT_BAND, GSM_A_PDU_TYPE_BSSMAP, BE_INT_BAND, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_INT_BAND, 0, BE_INT_BAND, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5442 | /* Cause 3.2.2.5 MSC-BSS O (note 9) 3-4 */
5443 | ELEM_OPT_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5444 | /* Classmark Information 3 3.2.2.20 MSC-BSS O (note 4) 3-34 */
5445 | ELEM_OPT_TLV(BE_CM_INFO_3, GSM_A_PDU_TYPE_BSSMAP, BE_CM_INFO_3, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CM_INFO_3, 0, BE_CM_INFO_3, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5446 | /* Current Channel type 1 3.2.2.49 MSC-BSS O (note 8) 2 */
5447 | ELEM_OPT_TV(BE_CURR_CHAN_1, GSM_A_PDU_TYPE_BSSMAP, BE_CURR_CHAN_1, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CURR_CHAN_1, 0, BE_CURR_CHAN_1 , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5448 | /* Speech Version (Used) 3.2.2.51 MSC-BSS O (note 10) 2 */
5449 | ELEM_OPT_TV(BE_SPEECH_VER, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_VER, " (Used)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_VER, 0, BE_SPEECH_VER, curr_offset, " (Used)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5450 | /* Group Call Reference 3.2.2.55 MSC-BSS O (note 5) 7 */
5451 | ELEM_OPT_TLV(BE_GROUP_CALL_REF, GSM_A_PDU_TYPE_BSSMAP, BE_GROUP_CALL_REF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_GROUP_CALL_REF, 0, BE_GROUP_CALL_REF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5452 | /* Talker Flag 3.2.2.54 MSC-BSS O (note 11) 1 */
5453 | ELEM_OPT_T(BE_TALKER_FLAG, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_FLAG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_t (tvb, tree, pinfo, (uint8_t) BE_TALKER_FLAG, 0, BE_TALKER_FLAG , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5454 | /* Configuration Evolution Indication 3.2.2.57 MSC-BSS O (note 12) 2 */
5455 | ELEM_OPT_TV(BE_CONF_EVO_IND, GSM_A_PDU_TYPE_BSSMAP, BE_CONF_EVO_IND, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CONF_EVO_IND, 0, BE_CONF_EVO_IND , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5456 | /* Chosen Encryption Algorithm (Serving) 3.2.2.44 MSC-BSS O (note 2) 2 */
5457 | ELEM_OPT_TV(BE_CHOSEN_ENC_ALG, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_ENC_ALG, " (Serving)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_ENC_ALG, 0, BE_CHOSEN_ENC_ALG , curr_offset, " (Serving)")) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5458 | /* Old BSS to New BSS Information 3.2.2.58 MSC-BSS O (note 13) 2-n */
5459 | ELEM_OPT_TLV(BE_OLD2NEW_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_OLD2NEW_INFO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_OLD2NEW_INFO, 0, BE_OLD2NEW_INFO , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5460 | /* LSA Information 3.2.2.23 MSC-BSS O (note 14) 3+4n */
5461 | ELEM_OPT_TLV(BE_LSA_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_LSA_INFO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LSA_INFO, 0, BE_LSA_INFO, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5462 | /* LSA Access Control Suppression 3.2.2.61 MSC-BSS O (note 15) 2 */
5463 | ELEM_OPT_TV(BE_LSA_ACC_CTRL, GSM_A_PDU_TYPE_BSSMAP, BE_LSA_ACC_CTRL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LSA_ACC_CTRL, 0, BE_LSA_ACC_CTRL , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5464 | /* Service Handover 3.2.2.75 MSC-BSS O (note 21) 3 */
5465 | ELEM_OPT_TLV(BE_SERV_HO, GSM_A_PDU_TYPE_BSSMAP, BE_SERV_HO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SERV_HO, 0, BE_SERV_HO, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5466 | /* IMSI 3.2.2.6 MSC-BSC O (note 16) 3-10 */
5467 | ELEM_OPT_TLV(BE_IMSI, GSM_A_PDU_TYPE_BSSMAP, BE_IMSI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_IMSI, 0, BE_IMSI, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5468 | /* Source RNC to target RNC transparent information (UMTS) 3.2.2.76 MSC-BSS O (note 18) n-m */
5469 | ELEM_OPT_TLV(BE_SRC_RNC_TO_TAR_RNC_UMTS, GSM_A_PDU_TYPE_BSSMAP, BE_SRC_RNC_TO_TAR_RNC_UMTS, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SRC_RNC_TO_TAR_RNC_UMTS, 0, BE_SRC_RNC_TO_TAR_RNC_UMTS , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5470 | /* Source RNC to target RNC transparent information (cdma2000) 3.2.2.77 MSC-BSS O (note 19) n-m */
5471 | ELEM_OPT_TLV(BE_SRC_RNC_TO_TAR_RNC_CDMA, GSM_A_PDU_TYPE_BSSMAP, BE_SRC_RNC_TO_TAR_RNC_CDMA, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SRC_RNC_TO_TAR_RNC_CDMA, 0, BE_SRC_RNC_TO_TAR_RNC_CDMA , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5472 | /* SNA Access Information 3.2.2.82 MSC-BSC O (note 22) 2+n */
5473 | ELEM_OPT_TLV(BE_SNA_ACC_INF, GSM_A_PDU_TYPE_BSSMAP, BE_SNA_ACC_INF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SNA_ACC_INF, 0, BE_SNA_ACC_INF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5474 | /* Talker Priority 3.2.2.89 MSC-BSC O (note 23) 2 */
5475 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5476 | /* AoIP Transport Layer Address (MGW) 3.2.2.102 MSC-BSS O (note 24) 10-22 */
5477 | ELEM_OPT_TLV(BE_AOIP_TRANS_LAY_ADD, GSM_A_PDU_TYPE_BSSMAP, BE_AOIP_TRANS_LAY_ADD, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_AOIP_TRANS_LAY_ADD, 0, BE_AOIP_TRANS_LAY_ADD , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5478 | /* Codec List (MSC Preferred) 3.2.2.103 MSC-BSS O (note 25) 3-n */
5479 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(MSC Preferred)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(MSC Preferred)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5480 | /* Call Identifier 3.2.2.105 MSC-BSS O (note 24) 5 */
5481 | ELEM_OPT_TV(BE_CALL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CALL_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CALL_ID, 0, BE_CALL_ID, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5482 | /* Kc128 3.2.2.109 MSC-BSS C (note 27) 17 */
5483 | ELEM_OPT_TV(BE_KC128, GSM_A_PDU_TYPE_BSSMAP, BE_KC128, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_KC128, 0, BE_KC128, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5484 | /* Global Call Reference 3.2.2.115 MSC - BSS O(note 28) 3 - n*/
5485 | ELEM_OPT_TLV(BE_GLOBAL_CALL_REF, GSM_A_PDU_TYPE_BSSMAP, BE_GLOBAL_CALL_REF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_GLOBAL_CALL_REF, 0, BE_GLOBAL_CALL_REF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5486 | /* LCLS-Configuration 3.2.2.116 MSC - BSS O(note 28) 2*/
5487 | ELEM_OPT_TV(BE_LCLS_CONF, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_CONF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_CONF, 0, BE_LCLS_CONF, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5488 | /* LCLS-Connection-Status-Control 3.2.2.117 MSC - BSS O(note 28) 2*/
5489 | ELEM_OPT_TV(BE_LCLS_CON_STATUS_CONTROL, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_CON_STATUS_CONTROL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_CON_STATUS_CONTROL, 0, BE_LCLS_CON_STATUS_CONTROL , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5490 | /* CS to PS SRVCC 3.2.2.122 MSC - BSS O(note 29) 1*/
5491 |
5492 |
5493 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5494 | }
5495 |
5496 | /*
5497 | * [2] 3.2.1.9 HANDOVER REQUIRED
5498 | */
5499 | static void
5500 | bssmap_ho_reqd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5501 | {
5502 | uint32_t curr_offset;
5503 | uint32_t consumed;
5504 | unsigned curr_len;
5505 |
5506 | curr_offset = offset;
5507 | curr_len = len;
5508 |
5509 | /* Cause 3.2.2.5 BSS-MSC M 3-4 */
5510 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5511 | /* Response Request 3.2.2.28 BSS-MSC O (note 8) 1 */
5512 | ELEM_OPT_T(BE_RESP_REQ, GSM_A_PDU_TYPE_BSSMAP, BE_RESP_REQ, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_t (tvb, tree, pinfo, (uint8_t) BE_RESP_REQ, 0, BE_RESP_REQ, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5513 | /* Cell Identifier List (Preferred) 3.2.2.27 BSS-MSC M (note 4) 2n+3 to 7n+3 */
5514 | ELEM_MAND_TLV(BE_CELL_ID_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID_LIST, " (Preferred)", ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID_LIST, 0, BE_CELL_ID_LIST , curr_offset, curr_len, " (Preferred)")) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID_LIST, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID_LIST ), (" (Preferred)" == ((void*)0)) ? "" : " (Preferred)" ); } };
5515 | /* Circuit Pool List 3.2.2.46 BSS-MSC O (note 1) V */
5516 | ELEM_OPT_TLV(BE_CCT_POOL_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CCT_POOL_LIST, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CCT_POOL_LIST, 0, BE_CCT_POOL_LIST , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5517 | /* Current Channel Type 1 3.2.2.49 BSS-MSC O (note 2) 2 */
5518 | ELEM_OPT_TV(BE_CURR_CHAN_1, GSM_A_PDU_TYPE_BSSMAP, BE_CURR_CHAN_1, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CURR_CHAN_1, 0, BE_CURR_CHAN_1 , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5519 | /* Speech Version (Used) 3.2.2.51 BSS-MSC O (note 3) 2 */
5520 | ELEM_OPT_TV(BE_SPEECH_VER, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_VER, " (Used)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_VER, 0, BE_SPEECH_VER, curr_offset, " (Used)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5521 | /* Queueing Indicator 3.2.2.50 BSS-MSC O 2 */
5522 | ELEM_OPT_TV(BE_QUE_IND, GSM_A_PDU_TYPE_BSSMAP, BE_QUE_IND, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_QUE_IND, 0, BE_QUE_IND, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5523 | /* Old BSS to New BSS Information 3.2.2.58 BSS-MSC O 2-n */
5524 | ELEM_OPT_TLV(BE_OLD2NEW_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_OLD2NEW_INFO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_OLD2NEW_INFO, 0, BE_OLD2NEW_INFO , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5525 | /* Source RNC to target RNC transparent information (UMTS) 3.2.2.76 BSS-MSC O (note 5) 3-m */
5526 | ELEM_OPT_TLV(BE_SRC_RNC_TO_TAR_RNC_UMTS, GSM_A_PDU_TYPE_BSSMAP, BE_SRC_RNC_TO_TAR_RNC_UMTS, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SRC_RNC_TO_TAR_RNC_UMTS, 0, BE_SRC_RNC_TO_TAR_RNC_UMTS , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5527 | /* Source RNC to target RNC transparent information (cdma2000) 3.2.2.77 BSS-MSC O (note 6) n-m */
5528 | ELEM_OPT_TLV(BE_SRC_RNC_TO_TAR_RNC_CDMA, GSM_A_PDU_TYPE_BSSMAP, BE_SRC_RNC_TO_TAR_RNC_CDMA, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SRC_RNC_TO_TAR_RNC_CDMA, 0, BE_SRC_RNC_TO_TAR_RNC_CDMA , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5529 | /* GERAN Classmark 3.2.2.78 BSS-MSC O (note 7) V */
5530 | ELEM_OPT_TLV(BE_GERAN_CLS_M, GSM_A_PDU_TYPE_BSSMAP, BE_GERAN_CLS_M, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_GERAN_CLS_M, 0, BE_GERAN_CLS_M , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5531 | /* Talker Priority 3.2.2.89 BSS-MSC O (note 9) 2 */
5532 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5533 | /* Speech Codec (Used) 3.2.2.104 BSS-MSC O (note 10) 3-5 */
5534 | ELEM_OPT_TLV(BE_SPEECH_CODEC, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC, "(Used)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC, 0, BE_SPEECH_CODEC , curr_offset, curr_len, "(Used)")) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5535 | /* CSG Identifier 3.2.2.110 BSS-MSC O (note 11) 7 */
5536 | ELEM_OPT_TLV(BE_CSG_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CSG_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CSG_ID, 0, BE_CSG_ID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5537 | /* Source eNB to target eNB transparent information (E-UTRAN) 3.2.2.123 BSS-MSC O (note 12) 3-m */
5538 | /* CS to PS SRVCC Indication 3.2.2.124 BSS-MSC O (note 13) 1 */
5539 |
5540 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5541 | }
5542 |
5543 | /*
5544 | * [2] 3.2.1.10 HANDOVER REQUEST ACKNOWLEDGE
5545 | */
5546 | static void
5547 | bssmap_ho_req_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5548 | {
5549 | uint32_t curr_offset;
5550 | uint32_t consumed;
5551 | unsigned curr_len;
5552 |
5553 | curr_offset = offset;
5554 | curr_len = len;
5555 |
5556 | /* Layer 3 Information 3.2.2.24 BSS-MSC M (note 1) 11-n */
5557 | ELEM_MAND_TLV(BE_L3_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_L3_INFO, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_L3_INFO, 0, BE_L3_INFO, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_L3_INFO, get_gsm_a_msg_string(pinfo->pool, 0, BE_L3_INFO ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5558 | /* Chosen Channel 3.2.2.33 BSS-MSC O (note 4) 2 */
5559 | ELEM_OPT_TV(BE_CHOSEN_CHAN, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_CHAN, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_CHAN, 0, BE_CHOSEN_CHAN , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5560 | /* Chosen Encryption Algorithm 3.2.2.44 BSS-MSC O (note 5) 2 */
5561 | ELEM_OPT_TV(BE_CHOSEN_ENC_ALG, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_ENC_ALG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_ENC_ALG, 0, BE_CHOSEN_ENC_ALG , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5562 | /* Circuit Pool 3.2.2.45 BSS-MSC O (note 2) 2 */
5563 | ELEM_OPT_TV(BE_CCT_POOL, GSM_A_PDU_TYPE_BSSMAP, BE_CCT_POOL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CCT_POOL, 0, BE_CCT_POOL, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5564 | /* Speech Version (Chosen) 3.2.2.51 BSS-MSC O (note 6) 2 */
5565 | ELEM_OPT_TV(BE_SPEECH_VER, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_VER, " (Chosen)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_VER, 0, BE_SPEECH_VER, curr_offset, " (Chosen)")) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5566 | /* Circuit Identity Code 3.2.2.2 BSS-MSC O (note 3) 3 */
5567 | ELEM_OPT_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed ; } };
5568 | /* LSA Identifier 3.2.2.15 BSS-MSC O (note 7) 5 */
5569 | ELEM_OPT_TLV(BE_LSA_ID, GSM_A_PDU_TYPE_BSSMAP, BE_LSA_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LSA_ID, 0, BE_LSA_ID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5570 | /* New BSS to Old BSS Information 3.2.2.80 BSS-MSC O (note 8) 2-n */
5571 | ELEM_OPT_TLV(BE_NEW_BSS_TO_OLD_BSS_INF, GSM_A_PDU_TYPE_BSSMAP, BE_NEW_BSS_TO_OLD_BSS_INF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_NEW_BSS_TO_OLD_BSS_INF, 0, BE_NEW_BSS_TO_OLD_BSS_INF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5572 | /* Inter-System Information 3.2.2.81 BSS-MSC O (note 9) 2-n */
5573 | ELEM_OPT_TLV(BE_INTER_SYS_INF, GSM_A_PDU_TYPE_BSSMAP, BE_INTER_SYS_INF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_INTER_SYS_INF, 0, BE_INTER_SYS_INF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5574 | /* Talker Priority 3.2.2.89 BSS-MSC O (note 10) 2 */
5575 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5576 | /* AoIP Transport Layer Address (BSS) 3.2.2.102 BSS-MSC O (note 11) 10-22 */
5577 | ELEM_OPT_TLV(BE_AOIP_TRANS_LAY_ADD, GSM_A_PDU_TYPE_BSSMAP, BE_AOIP_TRANS_LAY_ADD, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_AOIP_TRANS_LAY_ADD, 0, BE_AOIP_TRANS_LAY_ADD , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5578 | /* Codec List (BSS Supported) 3.2.2.103 BSS-MSC O (note 12) 3-n */
5579 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(BSS Supported)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(BSS Supported)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5580 | /* Speech Codec (Chosen) 3.2.2.104 BSS-MSC O (note 12) 3-5 */
5581 | ELEM_OPT_TLV(BE_SPEECH_CODEC, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC, "(Chosen)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC, 0, BE_SPEECH_CODEC , curr_offset, curr_len, "(Chosen)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5582 | /* LCLS-BSS-Status 3.2.2.119 BSS-MSC O (note 13) 2 */
5583 | ELEM_OPT_TV(BE_LCLS_BSS_STATUS, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_BSS_STATUS, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_BSS_STATUS, 0, BE_LCLS_BSS_STATUS , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5584 |
5585 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5586 | }
5587 |
5588 | /*
5589 | * [2] 3.2.1.11 HANDOVER COMMAND
5590 | */
5591 | static void
5592 | bssmap_ho_cmd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5593 | {
5594 | uint32_t curr_offset;
5595 | uint32_t consumed;
5596 | unsigned curr_len;
5597 |
5598 | curr_offset = offset;
5599 | curr_len = len;
5600 |
5601 | /* Layer 3 Information 3.2.2.24 MSC-BSS M (note 1) 11-n */
5602 | ELEM_MAND_TLV(BE_L3_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_L3_INFO, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_L3_INFO, 0, BE_L3_INFO, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_L3_INFO, get_gsm_a_msg_string(pinfo->pool, 0, BE_L3_INFO ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5603 | /* Cell Identifier 3.2.2.17 MSC-BSS O 3-10 */
5604 | ELEM_OPT_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5605 | /* New BSS to Old BSS Information 3.2.2.80 MSC-BSS O (note 2) 2-n */
5606 | ELEM_OPT_TLV(BE_NEW_BSS_TO_OLD_BSS_INF, GSM_A_PDU_TYPE_BSSMAP, BE_NEW_BSS_TO_OLD_BSS_INF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_NEW_BSS_TO_OLD_BSS_INF, 0, BE_NEW_BSS_TO_OLD_BSS_INF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5607 | /* Talker Priority 3.2.2.89 MSC-BSS O (note 3) 2 */
5608 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5609 | /* CN to MS transparent information 3.2.2.125 MSC-BSS O (note 4) 19-n */
5610 |
5611 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5612 | }
5613 |
5614 | /*
5615 | * [2] 3.2.1.12 HANDOVER COMPLETE
5616 | */
5617 | static void
5618 | bssmap_ho_complete(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5619 | {
5620 | uint32_t curr_offset;
5621 | uint32_t consumed;
5622 | unsigned curr_len;
5623 |
5624 | curr_offset = offset;
5625 | curr_len = len;
5626 |
5627 | /* RR Cause 3.2.2.22 BSS-MSC O 2 */
5628 | ELEM_OPT_TV(BE_RR_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_RR_CAUSE, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_RR_CAUSE, 0, BE_RR_CAUSE, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5629 | /* Talker Priority 3.2.2.89 BSS-MSC O (note 1) 2 */
5630 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5631 | /* Speech Codec (Chosen) 3.2.2.104 BSS-MSC O (note 2) 3-5 */
5632 | ELEM_OPT_TLV(BE_SPEECH_CODEC, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC, "(Chosen)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC, 0, BE_SPEECH_CODEC , curr_offset, curr_len, "(Chosen)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5633 | /* Codec List (BSS Supported) 3.2.2.103 BSS-MSC O (note 3) 3-n */
5634 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(BSS Supported)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(BSS Supported)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5635 | /* Chosen Encryption Algorithm 3.2.2.44 BSS-MSC O (note 4) 2 */
5636 | ELEM_OPT_TV(BE_CHOSEN_ENC_ALG, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_ENC_ALG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_ENC_ALG, 0, BE_CHOSEN_ENC_ALG , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5637 | /* Chosen Channel 3.2.2.33 BSS-MSC O (note 5) 2 */
5638 | ELEM_OPT_TV(BE_CHOSEN_CHAN, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_CHAN, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_CHAN, 0, BE_CHOSEN_CHAN , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5639 | /* LCLS-BSS-Status 3.2.2.119 BSS-MSC O (note 6) 2 */
5640 | ELEM_OPT_TV(BE_LCLS_BSS_STATUS, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_BSS_STATUS, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_BSS_STATUS, 0, BE_LCLS_BSS_STATUS , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5641 |
5642 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5643 | }
5644 |
5645 | /*
5646 | * 3.2.1.13 HANDOVER SUCCEEDED
5647 | */
5648 | static void
5649 | bssmap_ho_succ(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5650 | {
5651 | uint32_t curr_offset;
5652 | uint32_t consumed;
5653 | unsigned curr_len;
5654 |
5655 | curr_offset = offset;
5656 | curr_len = len;
5657 |
5658 | /* Talker Priority 3.2.2.89 MSC-BSS O (note 1) 2 */
5659 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5660 |
5661 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5662 | }
5663 |
5664 | /*
5665 | * [2] 3.2.1.14 HANDOVER CANDIDATE ENQUIRE
5666 | */
5667 | static void
5668 | bssmap_ho_cand_enq(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5669 | {
5670 | uint32_t curr_offset;
5671 | uint32_t consumed;
5672 | unsigned curr_len;
5673 |
5674 | curr_offset = offset;
5675 | curr_len = len;
5676 |
5677 | /* Number Of Mss 3.2.2.8 MSC-BSS M 2 */
5678 | ELEM_MAND_TV(BE_NUM_MS, GSM_A_PDU_TYPE_BSSMAP, BE_NUM_MS, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_NUM_MS, 0, BE_NUM_MS, curr_offset , ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_NUM_MS, get_gsm_a_msg_string(pinfo->pool, 0, BE_NUM_MS ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5679 |
5680 | /* Cell Identifier List 3.2.2.27 MSC-BSS M 2n+3 to 7n+3 */
5681 | ELEM_MAND_TLV(BE_CELL_ID_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID_LIST, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID_LIST, 0, BE_CELL_ID_LIST , curr_offset, curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID_LIST, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID_LIST ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5682 |
5683 | /* Cell Identifier 3.2.2.17 MSC-BSS M 3-10 */
5684 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5685 |
5686 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5687 | }
5688 |
5689 | /*
5690 | * [2] 3.2.1.15 HANDOVER CANDIDATE RESPONSE
5691 | */
5692 | static void
5693 | bssmap_ho_cand_resp(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5694 | {
5695 | uint32_t curr_offset;
5696 | uint32_t consumed;
5697 | unsigned curr_len;
5698 |
5699 | curr_offset = offset;
5700 | curr_len = len;
5701 |
5702 | /* Number Of Mss 3.2.2.8 BSS-MSC M 2 */
5703 | ELEM_MAND_TV(BE_NUM_MS, GSM_A_PDU_TYPE_BSSMAP, BE_NUM_MS, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_NUM_MS, 0, BE_NUM_MS, curr_offset , ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_NUM_MS, get_gsm_a_msg_string(pinfo->pool, 0, BE_NUM_MS ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5704 |
5705 | /* Cell Identifier 3.2.2.17 BSS-MSC M 3-10 */
5706 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5707 |
5708 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5709 | }
5710 |
5711 | /*
5712 | * [2] 3.2.1.16 HANDOVER FAILURE
5713 | */
5714 | static void
5715 | bssmap_ho_failure(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5716 | {
5717 | uint32_t curr_offset;
5718 | uint32_t consumed;
5719 | unsigned curr_len;
5720 |
5721 | curr_offset = offset;
5722 | curr_len = len;
5723 |
5724 | /* Cause 3.2.2.5 BSS-MSC M 3-4 */
5725 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5726 | /* RR Cause 3.2.2.22 BSS-MSC O 2 */
5727 | ELEM_OPT_TV(BE_RR_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_RR_CAUSE, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_RR_CAUSE, 0, BE_RR_CAUSE, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5728 | /* Circuit Pool 3.2.2.45 BSS-MSC O (note 1) 2 */
5729 | ELEM_OPT_TV(BE_CCT_POOL, GSM_A_PDU_TYPE_BSSMAP, BE_CCT_POOL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CCT_POOL, 0, BE_CCT_POOL, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5730 | /* Circuit Pool List 3.2.2.46 BSS-MSC O (note 2) V */
5731 | ELEM_OPT_TLV(BE_CCT_POOL_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CCT_POOL_LIST, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CCT_POOL_LIST, 0, BE_CCT_POOL_LIST , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5732 | /* GERAN Classmark 3.2.2.78 BSS-MSC O (note 3) V */
5733 | ELEM_OPT_TLV(BE_GERAN_CLS_M, GSM_A_PDU_TYPE_BSSMAP, BE_GERAN_CLS_M, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_GERAN_CLS_M, 0, BE_GERAN_CLS_M , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5734 | /* New BSS to Old BSS Information 3.2.2.80 BSS-MSC O (note 4) 2-n */
5735 | ELEM_OPT_TLV(BE_NEW_BSS_TO_OLD_BSS_INF, GSM_A_PDU_TYPE_BSSMAP, BE_NEW_BSS_TO_OLD_BSS_INF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_NEW_BSS_TO_OLD_BSS_INF, 0, BE_NEW_BSS_TO_OLD_BSS_INF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5736 | /* Inter-System Information 3.2.2.81 BSS-MSC O (note 5) 2-n */
5737 | ELEM_OPT_TLV(BE_INTER_SYS_INF, GSM_A_PDU_TYPE_BSSMAP, BE_INTER_SYS_INF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_INTER_SYS_INF, 0, BE_INTER_SYS_INF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5738 | /* Talker Priority 3.2.2.89 BSS-MSC O (note 6) 2 */
5739 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5740 | /* Codec List (BSS Supported) 3.2.2.103 BSS-MSC O (note 7) 3-n */
5741 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(BSS Supported)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(BSS Supported)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5742 |
5743 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5744 | }
5745 |
5746 | /*
5747 | * 3.2.1.17 RESOURCE REQUEST
5748 | */
5749 | static void
5750 | bssmap_res_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5751 | {
5752 | uint32_t curr_offset;
5753 | uint32_t consumed;
5754 | unsigned curr_len;
5755 |
5756 | curr_offset = offset;
5757 | curr_len = len;
5758 |
5759 | /* Periodicity 3.2.2.12 MSC-BSS M 2 */
5760 | ELEM_MAND_TV(BE_PERIODICITY, GSM_A_PDU_TYPE_BSSMAP, BE_PERIODICITY, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_PERIODICITY, 0, BE_PERIODICITY , curr_offset, ((void*)0))) > 0)) { curr_offset += consumed ; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_PERIODICITY, get_gsm_a_msg_string(pinfo->pool, 0, BE_PERIODICITY ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5761 | /* Resource Indication Method 3.2.2.29 MSC-BSS M 2 */
5762 | ELEM_MAND_TV(BE_RES_IND_METHOD, GSM_A_PDU_TYPE_BSSMAP, BE_RES_IND_METHOD, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_RES_IND_METHOD, 0, BE_RES_IND_METHOD , curr_offset, ((void*)0))) > 0)) { curr_offset += consumed ; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_RES_IND_METHOD, get_gsm_a_msg_string(pinfo->pool, 0, BE_RES_IND_METHOD ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5763 | /* Cell Identifier 3.2.2.17 MSC-BSS M 3-10 */
5764 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5765 | /* Extended Resource Indicator 3.2.2.13 MSC-BSS O 2 */
5766 | ELEM_MAND_TV(BE_EXT_RES_IND, GSM_A_PDU_TYPE_BSSMAP, BE_EXT_RES_IND, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_EXT_RES_IND, 0, BE_EXT_RES_IND , curr_offset, ((void*)0))) > 0)) { curr_offset += consumed ; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_EXT_RES_IND, get_gsm_a_msg_string(pinfo->pool, 0, BE_EXT_RES_IND ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5767 |
5768 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5769 | }
5770 |
5771 | /*
5772 | * 3.2.1.18 RESOURCE INDICATION
5773 | */
5774 | static void
5775 | bssmap_res_ind(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5776 | {
5777 | uint32_t curr_offset;
5778 | uint32_t consumed;
5779 | unsigned curr_len;
5780 |
5781 | curr_offset = offset;
5782 | curr_len = len;
5783 |
5784 | /* Resource Indication Method 3.2.2.29 BSS-MSC M 2 */
5785 | ELEM_MAND_TV(BE_RES_IND_METHOD, GSM_A_PDU_TYPE_BSSMAP, BE_RES_IND_METHOD, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_RES_IND_METHOD, 0, BE_RES_IND_METHOD , curr_offset, ((void*)0))) > 0)) { curr_offset += consumed ; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_RES_IND_METHOD, get_gsm_a_msg_string(pinfo->pool, 0, BE_RES_IND_METHOD ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5786 | /* Resource Available 3.2.2.4 BSS-MSC O (note 1) 21 */
5787 | ELEM_MAND_TV(BE_RES_AVAIL, GSM_A_PDU_TYPE_BSSMAP, BE_RES_AVAIL, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_RES_AVAIL, 0, BE_RES_AVAIL, curr_offset , ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_RES_AVAIL, get_gsm_a_msg_string(pinfo->pool, 0, BE_RES_AVAIL ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5788 | /* Cell Identifier 3.2.2.17 BSS-MSC M 3-10 */
5789 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5790 | /* Total Resource Accessible 3.2.2.14 BSS-MSC O (note 2) 5 */
5791 | ELEM_MAND_TV(BE_TOT_RES_ACC, GSM_A_PDU_TYPE_BSSMAP, BE_TOT_RES_ACC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TOT_RES_ACC, 0, BE_TOT_RES_ACC , curr_offset, ((void*)0))) > 0)) { curr_offset += consumed ; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_TOT_RES_ACC, get_gsm_a_msg_string(pinfo->pool, 0, BE_TOT_RES_ACC ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5792 |
5793 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5794 | }
5795 | /*
5796 | * [2] 3.2.1.19 PAGING
5797 | */
5798 | static void
5799 | bssmap_paging(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5800 | {
5801 | uint32_t curr_offset;
5802 | uint32_t consumed;
5803 | unsigned curr_len;
5804 |
5805 | curr_offset = offset;
5806 | curr_len = len;
5807 |
5808 | /* IMSI 3.2.2.6 MSC-BSS M 3-10 */
5809 | ELEM_MAND_TLV(BE_IMSI, GSM_A_PDU_TYPE_BSSMAP, BE_IMSI, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_IMSI, 0, BE_IMSI, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_IMSI, get_gsm_a_msg_string(pinfo->pool, 0, BE_IMSI), ( ((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5810 | /* TMSI 3.2.2.7 MSC-BSS O (note 1) 6 */
5811 | ELEM_OPT_TLV(BE_TMSI, GSM_A_PDU_TYPE_BSSMAP, BE_TMSI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_TMSI, 0, BE_TMSI, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5812 | /* Cell Identifier List 3.2.2.27 MSC-BSS M 3 to 3+7n */
5813 | ELEM_MAND_TLV(BE_CELL_ID_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID_LIST, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID_LIST, 0, BE_CELL_ID_LIST , curr_offset, curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID_LIST, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID_LIST ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5814 | /* Channel Needed 3.2.2.36 MSC-BSS O (note 2) 2 */
5815 | ELEM_OPT_TV(BE_CHAN_NEEDED, GSM_A_PDU_TYPE_BSSMAP, BE_CHAN_NEEDED, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHAN_NEEDED, 0, BE_CHAN_NEEDED , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5816 | /* eMLPP Priority 3.2.2.56 MSC-BSS O (note 3) 2 */
5817 | ELEM_OPT_TV(BE_EMLPP_PRIO, GSM_A_PDU_TYPE_BSSMAP, BE_EMLPP_PRIO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_EMLPP_PRIO, 0, BE_EMLPP_PRIO, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5818 | /* Paging Information 3.2.2.85 MSC-BSS O 2 */
5819 | ELEM_OPT_TV(BE_PAGING_INF, GSM_A_PDU_TYPE_BSSMAP, BE_PAGING_INF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_PAGING_INF, 0, BE_PAGING_INF, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5820 |
5821 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5822 | }
5823 |
5824 | /*
5825 | * [2] 3.2.1.20 CLEAR REQUEST
5826 | */
5827 | static void
5828 | bssmap_clear_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5829 | {
5830 | uint32_t curr_offset;
5831 | uint32_t consumed;
5832 | unsigned curr_len;
5833 |
5834 | curr_offset = offset;
5835 | curr_len = len;
5836 |
5837 | /* Cause 3.2.2.5 BSS-MSC M 3-4 */
5838 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5839 |
5840 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5841 | }
5842 |
5843 | /*
5844 | * [2] 3.2.1.21 CLEAR COMMAND
5845 | */
5846 | static void
5847 | bssmap_clear_cmd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5848 | {
5849 | uint32_t curr_offset;
5850 | uint32_t consumed;
5851 | unsigned curr_len;
5852 |
5853 | curr_offset = offset;
5854 | curr_len = len;
5855 |
5856 | /* Layer 3 Header Information 3.2.2.9 MSC-BSS O (note) 4 */
5857 | ELEM_OPT_TLV(BE_L3_HEADER_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_L3_HEADER_INFO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_L3_HEADER_INFO, 0, BE_L3_HEADER_INFO , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5858 | /* Cause 3.2.2.5 MSC-BSS M 3-4 */
5859 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5860 | /* CSFB Indication 3.2.2.121 MSC-BSS O 1 */
5861 | ELEM_OPT_T(BE_CSFB_IND, GSM_A_PDU_TYPE_BSSMAP, BE_CSFB_IND, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_t (tvb, tree, pinfo, (uint8_t) BE_CSFB_IND, 0, BE_CSFB_IND, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5862 |
5863 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5864 | }
5865 | /*
5866 | * 3.2.1.22 CLEAR COMPLETE
5867 | * No data
5868 | */
5869 |
5870 | /*
5871 | * [2] 3.2.1.23 RESET
5872 | */
5873 | void
5874 | bssmap_reset(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5875 | {
5876 | uint32_t curr_offset;
5877 | uint32_t consumed;
5878 | unsigned curr_len;
5879 |
5880 | curr_offset = offset;
5881 | curr_len = len;
5882 |
5883 | /* Cause 3.2.2.5 Both M 3-4 */
5884 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5885 | /* A-Interface Selector for RESET 3.2.2.107 Both O 2 */
5886 | ELEM_OPT_TV(BE_A_ITF_SEL_FOR_RESET, GSM_A_PDU_TYPE_BSSMAP, BE_A_ITF_SEL_FOR_RESET, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_A_ITF_SEL_FOR_RESET, 0, BE_A_ITF_SEL_FOR_RESET , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5887 | /*Osmocom extension: Osmux Support */
5888 | ELEM_OPT_T(BE_OSMOCOM_OSMUX_SUPPORT, GSM_A_PDU_TYPE_BSSMAP, BE_OSMOCOM_OSMUX_SUPPORT, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_t (tvb, tree, pinfo, (uint8_t) BE_OSMOCOM_OSMUX_SUPPORT, 0, BE_OSMOCOM_OSMUX_SUPPORT , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5889 |
5890 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5891 | }
5892 |
5893 | /*
5894 | * 3.2.1.24 RESET ACKNOWLEDGE
5895 | */
5896 | static void
5897 | bssmap_reset_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5898 | {
5899 | uint32_t curr_offset;
5900 | uint32_t consumed;
5901 | unsigned curr_len;
5902 |
5903 | curr_offset = offset;
5904 | curr_len = len;
5905 |
5906 | /* A-Interface Selector for RESET 3.2.2.107 Both O 2 */
5907 | ELEM_OPT_TV(BE_A_ITF_SEL_FOR_RESET, GSM_A_PDU_TYPE_BSSMAP, BE_A_ITF_SEL_FOR_RESET, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_A_ITF_SEL_FOR_RESET, 0, BE_A_ITF_SEL_FOR_RESET , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5908 | /*Osmocom extension: Osmux Support */
5909 | ELEM_OPT_T(BE_OSMOCOM_OSMUX_SUPPORT, GSM_A_PDU_TYPE_BSSMAP, BE_OSMOCOM_OSMUX_SUPPORT, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_t (tvb, tree, pinfo, (uint8_t) BE_OSMOCOM_OSMUX_SUPPORT, 0, BE_OSMOCOM_OSMUX_SUPPORT , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5910 |
5911 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5912 | }
5913 |
5914 | /*
5915 | * [2] 3.2.1.25 HANDOVER PERFORMED
5916 | */
5917 | static void
5918 | bssmap_ho_performed(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5919 | {
5920 | uint32_t curr_offset;
5921 | uint32_t consumed;
5922 | unsigned curr_len;
5923 |
5924 | curr_offset = offset;
5925 | curr_len = len;
5926 |
5927 | /* Cause 3.2.2.5 BSS-MSC M 3-4 */
5928 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5929 | /* Cell Identifier 3.2.2.17 BSS-MSC M (note 5) 3-10 */
5930 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5931 | /* Chosen Channel 3.2.2.33 BSS-MSC O (note 1) 2 */
5932 | ELEM_OPT_TV(BE_CHOSEN_CHAN, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_CHAN, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_CHAN, 0, BE_CHOSEN_CHAN , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5933 | /* Chosen Encryption Algorithm 3.2.2.44 BSS-MSC O (note 2) 2 */
5934 | ELEM_OPT_TV(BE_CHOSEN_ENC_ALG, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_ENC_ALG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_ENC_ALG, 0, BE_CHOSEN_ENC_ALG , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5935 | /* Speech Version (Chosen) 3.2.2.51 BSS-MSC O (note 3) 2 */
5936 | ELEM_OPT_TV(BE_SPEECH_VER, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_VER, " (Chosen)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_VER, 0, BE_SPEECH_VER, curr_offset, " (Chosen)")) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5937 | /* LSA Identifier 3.2.2.15 BSS-MSC O (note 4) 5 */
5938 | ELEM_OPT_TLV(BE_LSA_ID, GSM_A_PDU_TYPE_BSSMAP, BE_LSA_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LSA_ID, 0, BE_LSA_ID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5939 | /* Talker Priority 3.2.2.89 BSS-MSC O (note 6) 2 */
5940 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5941 | /* Codec List (BSS Supported) (serving cell) 3.2.2.103 BSS-MSC O (note 7) 3-n */
5942 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(BSS Supported)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(BSS Supported)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5943 | /* Speech Codec (Chosen) 3.2.2.104 BSS-MSC O (note 8) 3-5 */
5944 | ELEM_OPT_TLV(BE_SPEECH_CODEC, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC, "(Chosen)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC, 0, BE_SPEECH_CODEC , curr_offset, curr_len, "(Chosen)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5945 | /* LCLS-BSS-Status 3.2.2.119 BSS-MSC O (note 9) 2 */
5946 | ELEM_OPT_TV(BE_LCLS_BSS_STATUS, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_BSS_STATUS, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_BSS_STATUS, 0, BE_LCLS_BSS_STATUS , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
5947 |
5948 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5949 | }
5950 |
5951 | /*
5952 | * [2] 3.2.1.26 OVERLOAD
5953 | */
5954 | static void
5955 | bssmap_overload(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5956 | {
5957 | uint32_t curr_offset;
5958 | uint32_t consumed;
5959 | unsigned curr_len;
5960 |
5961 | curr_offset = offset;
5962 | curr_len = len;
5963 |
5964 | /* Cause 3.2.2.5 Both M 3-4 */
5965 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5966 | /* Cell Identifier 3.2.2.17 BSS-MSC O 3-10 */
5967 | ELEM_OPT_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5968 |
5969 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5970 | }
5971 | /*
5972 | * 3.2.1.27 MSC INVOKE TRACE
5973 | */
5974 | static void
5975 | bssmap_msc_invoke_trace(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
5976 | {
5977 | uint32_t curr_offset;
5978 | uint32_t consumed;
5979 | unsigned curr_len;
5980 |
5981 | curr_offset = offset;
5982 | curr_len = len;
5983 |
5984 | /* Trace Type 3.2.2.37 MSC-BSS M 2 */
5985 | ELEM_MAND_TV(BE_TRACE_TYPE, GSM_A_PDU_TYPE_BSSMAP, BE_TRACE_TYPE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TRACE_TYPE, 0, BE_TRACE_TYPE, curr_offset, ((void*)0))) > 0)) { curr_offset += consumed ; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_TRACE_TYPE, get_gsm_a_msg_string(pinfo->pool, 0, BE_TRACE_TYPE ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5986 | /* Triggerid 3.2.2.38 MSC-BSS O 3-22 */
5987 | ELEM_OPT_TLV(BE_TRIGGERID, GSM_A_PDU_TYPE_BSSMAP, BE_TRIGGERID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_TRIGGERID, 0, BE_TRIGGERID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5988 | /* Trace Reference 3.2.2.39 MSC-BSS M 3 */
5989 | ELEM_MAND_TV(BE_TRACE_REF, GSM_A_PDU_TYPE_BSSMAP, BE_TRACE_REF, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TRACE_REF, 0, BE_TRACE_REF, curr_offset , ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_TRACE_REF, get_gsm_a_msg_string(pinfo->pool, 0, BE_TRACE_REF ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
5990 | /* Transactionid 3.2.2.40 MSC-BSS O 4 */
5991 | ELEM_OPT_TLV(BE_TRANSID, GSM_A_PDU_TYPE_BSSMAP, BE_TRANSID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_TRANSID, 0, BE_TRANSID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5992 | /* Mobile Identity 3.2.2.41 MSC-BSS O 3-10 */
5993 | ELEM_OPT_TLV(BE_MID, GSM_A_PDU_TYPE_BSSMAP, BE_MID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_MID, 0, BE_MID, curr_offset, curr_len , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5994 | /* OMCId 3.2.2.42 MSC-BSS O 3-22 */
5995 | ELEM_OPT_TLV(BE_OMCID, GSM_A_PDU_TYPE_BSSMAP, BE_OMCID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_OMCID, 0, BE_OMCID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
5996 |
5997 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
5998 | }
5999 |
6000 | /*
6001 | * 3.2.1.28 BSS INVOKE TRACE
6002 | */
6003 | static void
6004 | bssmap_bss_invoke_trace(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6005 | {
6006 | uint32_t curr_offset;
6007 | uint32_t consumed;
6008 | unsigned curr_len;
6009 |
6010 | curr_offset = offset;
6011 | curr_len = len;
6012 |
6013 | /* Trace Type 3.2.2.37 Both M 2 */
6014 | ELEM_MAND_TV(BE_TRACE_TYPE, GSM_A_PDU_TYPE_BSSMAP, BE_TRACE_TYPE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TRACE_TYPE, 0, BE_TRACE_TYPE, curr_offset, ((void*)0))) > 0)) { curr_offset += consumed ; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_TRACE_TYPE, get_gsm_a_msg_string(pinfo->pool, 0, BE_TRACE_TYPE ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6015 | /* Forward Indicator 3.2.2.43 Both O 2 */
6016 | ELEM_OPT_TV(BE_FOR_IND, GSM_A_PDU_TYPE_BSSMAP, BE_FOR_IND, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_FOR_IND, 0, BE_FOR_IND, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6017 | /* Triggerid 3.2.2.38 Both O 3-22 */
6018 | ELEM_OPT_TLV(BE_TRIGGERID, GSM_A_PDU_TYPE_BSSMAP, BE_TRIGGERID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_TRIGGERID, 0, BE_TRIGGERID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6019 | /* Trace Reference 3.2.2.39 Both M 3 */
6020 | ELEM_MAND_TV(BE_TRACE_REF, GSM_A_PDU_TYPE_BSSMAP, BE_TRACE_REF, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TRACE_REF, 0, BE_TRACE_REF, curr_offset , ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_TRACE_REF, get_gsm_a_msg_string(pinfo->pool, 0, BE_TRACE_REF ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6021 | /* TransactionId 3.2.2.40 Both O 4 */
6022 | ELEM_OPT_TLV(BE_TRANSID, GSM_A_PDU_TYPE_BSSMAP, BE_TRANSID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_TRANSID, 0, BE_TRANSID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6023 | /* OMCId 3.2.2.42 Both O 3-22 */
6024 | ELEM_OPT_TLV(BE_OMCID, GSM_A_PDU_TYPE_BSSMAP, BE_OMCID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_OMCID, 0, BE_OMCID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6025 |
6026 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6027 | }
6028 |
6029 | /*
6030 | * [2] 3.2.1.29 CLASSMARK UPDATE
6031 | */
6032 | static void
6033 | bssmap_cm_upd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6034 | {
6035 | uint32_t curr_offset;
6036 | uint32_t consumed;
6037 | unsigned curr_len;
6038 |
6039 | curr_offset = offset;
6040 | curr_len = len;
6041 |
6042 | /* Classmark Information Type 2 3.2.2.19 Both M 4-5 */
6043 | ELEM_MAND_TLV(BE_CM_INFO_2, GSM_A_PDU_TYPE_BSSMAP, BE_CM_INFO_2, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CM_INFO_2, 0, BE_CM_INFO_2, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CM_INFO_2, get_gsm_a_msg_string(pinfo->pool, 0, BE_CM_INFO_2 ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6044 | /* Classmark Information Type 3 3.2.2.20 Both O (note 1) 3-34 */
6045 | ELEM_OPT_TLV(BE_CM_INFO_3, GSM_A_PDU_TYPE_BSSMAP, BE_CM_INFO_3, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CM_INFO_3, 0, BE_CM_INFO_3, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6046 | /* Talker Priority 3.2.2.89 Both O (note 2) 2 */
6047 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6048 |
6049 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6050 | }
6051 |
6052 | /*
6053 | * [2] 3.2.1.30 CIPHER MODE COMMAND
6054 | */
6055 | static void
6056 | bssmap_ciph_mode_cmd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6057 | {
6058 | uint32_t curr_offset;
6059 | uint32_t consumed;
6060 | unsigned curr_len;
6061 |
6062 | curr_offset = offset;
6063 | curr_len = len;
6064 |
6065 | /* Layer 3 Header Information 3.2.2.9 MSC-BSS O (note) 4 */
6066 | ELEM_OPT_TLV(BE_L3_HEADER_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_L3_HEADER_INFO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_L3_HEADER_INFO, 0, BE_L3_HEADER_INFO , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6067 | /* Encryption Information 3.2.2.10 MSC-BSS M 3-n */
6068 | ELEM_MAND_TLV(BE_ENC_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_ENC_INFO, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_ENC_INFO, 0, BE_ENC_INFO, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_ENC_INFO, get_gsm_a_msg_string(pinfo->pool, 0, BE_ENC_INFO ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6069 | /* Cipher Response Mode 3.2.2.34 MSC-BSS O 2 */
6070 | ELEM_OPT_TV(BE_CIPH_RESP_MODE, GSM_A_PDU_TYPE_BSSMAP, BE_CIPH_RESP_MODE, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIPH_RESP_MODE, 0, BE_CIPH_RESP_MODE , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
6071 | /* Kc128 3.2.2.109 MSC-BSS C (note 2) 17 */
6072 | ELEM_OPT_TV(BE_KC128, GSM_A_PDU_TYPE_BSSMAP, BE_KC128, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_KC128, 0, BE_KC128, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6073 |
6074 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6075 | }
6076 |
6077 | /*
6078 | * [2] 3.2.1.31 CIPHER MODE COMPLETE
6079 | */
6080 | static void
6081 | bssmap_ciph_mode_complete(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6082 | {
6083 | uint32_t curr_offset;
6084 | uint32_t consumed;
6085 | unsigned curr_len;
6086 |
6087 | curr_offset = offset;
6088 | curr_len = len;
6089 |
6090 | /* Layer 3 Message Contents 3.2.2.35 BSS-MSC O 2-n */
6091 | ELEM_OPT_TLV(BE_L3_MSG, GSM_A_PDU_TYPE_BSSMAP, BE_L3_MSG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_L3_MSG, 0, BE_L3_MSG, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6092 | /* Chosen Encryption Algorithm 3.2.2.44 BSS-MSC O (note) 2 */
6093 | ELEM_OPT_TV(BE_CHOSEN_ENC_ALG, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_ENC_ALG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_ENC_ALG, 0, BE_CHOSEN_ENC_ALG , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
6094 |
6095 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6096 | }
6097 |
6098 | /*
6099 | * [2] 3.2.1.32 COMPLETE LAYER 3 INFORMATION
6100 | * Updated to 3GPP TS 48.008 version 11.5.0 Release 11
6101 | */
6102 | static void
6103 | bssmap_cl3_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6104 | {
6105 | uint32_t consumed;
6106 | uint32_t curr_offset;
6107 | unsigned curr_len;
6108 |
6109 | curr_offset = offset;
6110 | curr_len = len;
6111 |
6112 | /* Cell Identifier 3.2.2.17 BSS-MSC M 3-10 */
6113 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6114 | /* Layer 3 Information 3.2.2.24 BSS-MSC M 3-n */
6115 | ELEM_MAND_TLV(BE_L3_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_L3_INFO, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_L3_INFO, 0, BE_L3_INFO, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_L3_INFO, get_gsm_a_msg_string(pinfo->pool, 0, BE_L3_INFO ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6116 | /* Chosen Channel 3.2.2.33 BSS-MSC O (note 1) 2 */
6117 | ELEM_OPT_TV(BE_CHOSEN_CHAN, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_CHAN, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_CHAN, 0, BE_CHOSEN_CHAN , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
6118 | /* LSA Identifier List 3.2.2.16 BSS-MSC O (note 2) 3+3n */
6119 | ELEM_OPT_TLV(BE_LSA_ID_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_LSA_ID_LIST, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LSA_ID_LIST, 0, BE_LSA_ID_LIST , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6120 | /* APDU 3.2.2.68 BSS-MSC O (note 3) 3-n */
6121 | ELEM_OPT_TLV_E(BE_APDU, GSM_A_PDU_TYPE_BSSMAP, BE_APDU, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv_e (tvb, tree, pinfo, (uint8_t) BE_APDU, 0, BE_APDU, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6122 | /* Codec List (BSS Supported) 3.2.2.103 BSS-MSC O (note 4) 3-n */
6123 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(BSS Supported)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(BSS Supported)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6124 | /* Redirect Attempt Flag 3.2.2.111 BSS-MSC O (note 5) 1 */
6125 | ELEM_OPT_T(BE_REDIR_ATT_FLG, GSM_A_PDU_TYPE_BSSMAP, BE_REDIR_ATT_FLG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_t (tvb, tree, pinfo, (uint8_t) BE_REDIR_ATT_FLG, 0, BE_REDIR_ATT_FLG , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
6126 | /* Send Sequence Number 3.2.2.113 BSS-MSC O (note 6) 2 */
6127 | ELEM_OPT_TV(BE_SEND_SEQN, GSM_A_PDU_TYPE_BSSMAP, BE_SEND_SEQN, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_SEND_SEQN, 0, BE_SEND_SEQN, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6128 | /* IMSI 3.2.2.6 BSS-MSC O (note 7) 3-10 */
6129 | ELEM_OPT_TLV(BE_IMSI, GSM_A_PDU_TYPE_BSSMAP, BE_IMSI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_IMSI, 0, BE_IMSI, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6130 | /* Selected PLMN ID 3.2.2.126 BSS-MSC O (note 8) 4 */
6131 | ELEM_OPT_TV(BE_SELECTED_PLMN_ID, GSM_A_PDU_TYPE_BSSMAP, BE_SELECTED_PLMN_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_SELECTED_PLMN_ID, 0, BE_SELECTED_PLMN_ID , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
6132 | /* Selected Operator 3.2.2.130 BSS-MSC O (note 9, 10) 4 */
6133 | /* PS Registered Operator 3.2.2.131 BSS-MSC O (note 9, 11) 4 */
6134 |
6135 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6136 | }
6137 | /*
6138 | * 3.2.1.33 QUEUEING INDICATION
6139 | * No data
6140 | */
6141 |
6142 | /*
6143 | * [2] 3.2.1.34 SAPI "n" REJECT
6144 | */
6145 | static void
6146 | bssmap_sapi_rej(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6147 | {
6148 | uint32_t consumed;
6149 | uint32_t curr_offset;
6150 | unsigned curr_len;
6151 |
6152 | curr_offset = offset;
6153 | curr_len = len;
6154 |
6155 | /* DLCI 3.2.2.25 BSS-MSC M 2 */
6156 | ELEM_MAND_TV(BE_DLCI, GSM_A_PDU_TYPE_BSSMAP, BE_DLCI, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_DLCI, 0, BE_DLCI, curr_offset , ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_DLCI, get_gsm_a_msg_string(pinfo->pool, 0, BE_DLCI), ( ((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6157 | /* Cause 3.2.2.5 BSS-MSC M 3-4 */
6158 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6159 |
6160 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6161 | }
6162 | /* 3.2.1.35 (void)
6163 | * 3.2.1.36 (void)
6164 | */
6165 | /*
6166 | * [2] 3.2.1.37 HANDOVER REQUIRED REJECT
6167 | */
6168 | static void
6169 | bssmap_ho_reqd_rej(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6170 | {
6171 | uint32_t curr_offset;
6172 | uint32_t consumed;
6173 | unsigned curr_len;
6174 |
6175 | curr_offset = offset;
6176 | curr_len = len;
6177 |
6178 | /* Cause 3.2.2.5 MSC-BSS M 3-4 */
6179 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6180 | /* New BSS to Old BSS Information 3.2.2.78 MSC-BSS O (note 1) 2-n */
6181 | ELEM_OPT_TLV(BE_NEW_BSS_TO_OLD_BSS_INF, GSM_A_PDU_TYPE_BSSMAP, BE_NEW_BSS_TO_OLD_BSS_INF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_NEW_BSS_TO_OLD_BSS_INF, 0, BE_NEW_BSS_TO_OLD_BSS_INF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6182 | /* Talker Priority 3.2.2.89 MSC-BSS O (note 2) 2 */
6183 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6184 |
6185 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6186 | }
6187 |
6188 | /*
6189 | * [2] 3.2.1.38 RESET CIRCUIT
6190 | */
6191 | static void
6192 | bssmap_reset_cct(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6193 | {
6194 | uint32_t curr_offset;
6195 | uint32_t consumed;
6196 | unsigned curr_len;
6197 |
6198 | curr_offset = offset;
6199 | curr_len = len;
6200 |
6201 | /* Circuit Identity Code 3.2.2.2 Both M 3 */
6202 | ELEM_MAND_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed ; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element , tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC), (( (void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6203 | /* Cause 3.2.2.5 Both M 3-4 */
6204 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6205 |
6206 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6207 | }
6208 |
6209 | /*
6210 | * [2] 3.2.1.39 RESET CIRCUIT ACKNOWLEDGE
6211 | */
6212 | static void
6213 | bssmap_reset_cct_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6214 | {
6215 | uint32_t curr_offset;
6216 | uint32_t consumed;
6217 | unsigned curr_len;
6218 |
6219 | curr_offset = offset;
6220 | curr_len = len;
6221 |
6222 | /* Circuit Identity 3.2.2.2 Both M 3 */
6223 | ELEM_MAND_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed ; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element , tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC), (( (void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6224 |
6225 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6226 | }
6227 |
6228 | /*
6229 | * 3.2.1.40 HANDOVER DETECT
6230 | */
6231 | static void
6232 | bssmap_ho_det(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6233 | {
6234 | uint32_t curr_offset;
6235 | uint32_t consumed;
6236 | unsigned curr_len;
6237 |
6238 | curr_offset = offset;
6239 | curr_len = len;
6240 |
6241 | /* Talker Priority 3.2.2.89 BSS-MSC O (note 1) 2 */
6242 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6243 |
6244 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6245 | }
6246 | /*
6247 | * [2] 3.2.1.41 CIRCUIT GROUP BLOCK
6248 | */
6249 | static void
6250 | bssmap_cct_group_block(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6251 | {
6252 | uint32_t curr_offset;
6253 | uint32_t consumed;
6254 | unsigned curr_len;
6255 |
6256 | curr_offset = offset;
6257 | curr_len = len;
6258 |
6259 | /* Cause 3.2.2.5 Both M 3-4 */
6260 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6261 | /* Circuit Identity Code 3.2.2.2 Both M 3 */
6262 | ELEM_MAND_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed ; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element , tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC), (( (void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6263 | /* Circuit Identity Code List 3.2.2.31 Both M 4-35 */
6264 | ELEM_MAND_TLV(BE_CIC_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CIC_LIST, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CIC_LIST, 0, BE_CIC_LIST, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC_LIST, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC_LIST ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6265 |
6266 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6267 | }
6268 |
6269 | /*
6270 | * [2] 3.2.1.42 CIRCUIT GROUP BLOCKING ACKNOWLEDGE
6271 | */
6272 | static void
6273 | bssmap_cct_group_block_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6274 | {
6275 | uint32_t curr_offset;
6276 | uint32_t consumed;
6277 | unsigned curr_len;
6278 |
6279 | curr_offset = offset;
6280 | curr_len = len;
6281 |
6282 | /* Circuit Identity Code 3.2.2.2 Both M 3 */
6283 | ELEM_MAND_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed ; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element , tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC), (( (void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6284 | /* Circuit Identity Code List 3.2.2.31 Both M 4-35 */
6285 | ELEM_MAND_TLV(BE_CIC_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CIC_LIST, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CIC_LIST, 0, BE_CIC_LIST, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC_LIST, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC_LIST ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6286 |
6287 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6288 | }
6289 |
6290 | /*
6291 | * [2] 3.2.1.43 CIRCUIT GROUP UNBLOCK
6292 | */
6293 | static void
6294 | bssmap_cct_group_unblock(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6295 | {
6296 | uint32_t curr_offset;
6297 | uint32_t consumed;
6298 | unsigned curr_len;
6299 |
6300 | curr_offset = offset;
6301 | curr_len = len;
6302 |
6303 | /* Circuit Identity Code 3.2.2.2 Both M 3 */
6304 | ELEM_MAND_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed ; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element , tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC), (( (void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6305 | /* Circuit Identity Code List 3.2.2.31 Both M 4-35 */
6306 | ELEM_MAND_TLV(BE_CIC_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CIC_LIST, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CIC_LIST, 0, BE_CIC_LIST, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC_LIST, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC_LIST ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6307 |
6308 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6309 | }
6310 |
6311 | /*
6312 | * [2] 3.2.1.44 CIRCUIT GROUP UNBLOCKING ACKNOWLEDGE
6313 | */
6314 | static void
6315 | bssmap_cct_group_unblock_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6316 | {
6317 | uint32_t curr_offset;
6318 | uint32_t consumed;
6319 | unsigned curr_len;
6320 |
6321 | curr_offset = offset;
6322 | curr_len = len;
6323 |
6324 | /* Circuit Identity Code 3.2.2.2 Both M 3 */
6325 | ELEM_MAND_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed ; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element , tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC), (( (void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6326 | /* Circuit Identity Code List 3.2.2.31 Both M 4-35 */
6327 | ELEM_MAND_TLV(BE_CIC_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CIC_LIST, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CIC_LIST, 0, BE_CIC_LIST, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC_LIST, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC_LIST ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6328 |
6329 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6330 | }
6331 |
6332 | /*
6333 | * [2] 3.2.1.45 CONFUSION
6334 | */
6335 | static void
6336 | bssmap_confusion(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6337 | {
6338 | uint32_t curr_offset;
6339 | uint32_t consumed;
6340 | unsigned curr_len;
6341 |
6342 | curr_offset = offset;
6343 | curr_len = len;
6344 |
6345 | /* Cause 3.2.2.5 Both M 3-4 */
6346 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6347 | /* Diagnostics 3.2.2.32 Both M 4-n */
6348 | ELEM_MAND_TLV(BE_DIAG, GSM_A_PDU_TYPE_BSSMAP, BE_DIAG, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_DIAG, 0, BE_DIAG, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_DIAG, get_gsm_a_msg_string(pinfo->pool, 0, BE_DIAG), ( ((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6349 |
6350 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6351 | }
6352 | /*
6353 | * 3.2.1.46 CLASSMARK REQUEST
6354 | */
6355 | static void
6356 | bssmap_cls_m_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6357 | {
6358 | uint32_t curr_offset;
6359 | uint32_t consumed;
6360 | unsigned curr_len;
6361 |
6362 | curr_offset = offset;
6363 | curr_len = len;
6364 |
6365 | /* Talker Priority 3.2.2.89 MSC-BSS O (note 1) 2 */
6366 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6367 |
6368 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6369 | }
6370 | /*
6371 | * [2] 3.2.1.47 UNEQUIPPED CIRCUIT
6372 | */
6373 | static void
6374 | bssmap_unequipped_cct(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6375 | {
6376 | uint32_t curr_offset;
6377 | uint32_t consumed;
6378 | unsigned curr_len;
6379 |
6380 | curr_offset = offset;
6381 | curr_len = len;
6382 |
6383 | /* Circuit Identity Code 3.2.2.2 Both M 3 */
6384 | ELEM_MAND_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed ; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element , tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC), (( (void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6385 | /* Circuit Identity Code List 3.2.2.31 Both O 4-35 */
6386 | ELEM_OPT_TLV(BE_CIC_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CIC_LIST, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CIC_LIST, 0, BE_CIC_LIST, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6387 |
6388 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6389 | }
6390 |
6391 | /*
6392 | * [2] 3.2.1.48 CIPHER MODE REJECT
6393 | */
6394 | static void
6395 | bssmap_ciph_mode_rej(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6396 | {
6397 | uint32_t curr_offset;
6398 | uint32_t consumed;
6399 | unsigned curr_len;
6400 |
6401 | curr_offset = offset;
6402 | curr_len = len;
6403 |
6404 | /* Cause 3.2.2.5 BSS-MSC M 3-4 */
6405 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6406 |
6407 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6408 | }
6409 |
6410 | /*
6411 | * [2] 3.2.1.49 LOAD INDICATION
6412 | */
6413 | static void
6414 | bssmap_load_ind(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6415 | {
6416 | uint32_t curr_offset;
6417 | uint32_t consumed;
6418 | unsigned curr_len;
6419 |
6420 | curr_offset = offset;
6421 | curr_len = len;
6422 |
6423 | /* Time Indication 3.2.2.47 Both M 2 */
6424 | ELEM_MAND_TV(BE_TIME_IND, GSM_A_PDU_TYPE_BSSMAP, BE_TIME_IND, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TIME_IND, 0, BE_TIME_IND, curr_offset , ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_TIME_IND, get_gsm_a_msg_string(pinfo->pool, 0, BE_TIME_IND ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6425 | /* Cell Identifier 3.2.2.17 Both M 3-10 */
6426 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6427 | /* Cell Identifier List (Target) 3.2.2.27 Both M 3 to 3+7n */
6428 | ELEM_MAND_TLV(BE_CELL_ID_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID_LIST, " (Target)", ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID_LIST, 0, BE_CELL_ID_LIST , curr_offset, curr_len, " (Target)")) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID_LIST, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID_LIST ), (" (Target)" == ((void*)0)) ? "" : " (Target)" ); } };
6429 | /* Resource Situation 3.2.2.48 Both O (note 1) 4-N */
6430 | ELEM_OPT_TLV(BE_RES_SIT, GSM_A_PDU_TYPE_BSSMAP, BE_RES_SIT, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_RES_SIT, 0, BE_RES_SIT, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6431 | /* Cause 3.2.2.5 Both O (note 2) 4-5 */
6432 | ELEM_OPT_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6433 |
6434 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6435 | }
6436 | /*
6437 | * 3.2.1.50 VGCS/VBS SETUP
6438 | */
6439 | static void
6440 | bssmap_vgcs_vbs_setup(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6441 | {
6442 | uint32_t curr_offset;
6443 | uint32_t consumed;
6444 | unsigned curr_len;
6445 |
6446 | curr_offset = offset;
6447 | curr_len = len;
6448 |
6449 | /* Group Call Reference 3.2.2.55 MSC-BSS M 7 */
6450 | ELEM_MAND_TLV(BE_GROUP_CALL_REF, GSM_A_PDU_TYPE_BSSMAP, BE_GROUP_CALL_REF, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_GROUP_CALL_REF, 0, BE_GROUP_CALL_REF , curr_offset, curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_GROUP_CALL_REF, get_gsm_a_msg_string(pinfo->pool, 0, BE_GROUP_CALL_REF ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6451 | /* Priority 3.2.2.18 MSC-BSS O 3 */
6452 | ELEM_OPT_TLV(BE_PRIO, GSM_A_PDU_TYPE_BSSMAP, BE_PRIO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_PRIO, 0, BE_PRIO, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6453 | /* VGCS Feature Flags 3.2.2.88 MSC-BSS O 3 */
6454 | ELEM_OPT_TLV(BE_VGCS_FEAT_FLG, GSM_A_PDU_TYPE_BSSMAP, BE_VGCS_FEAT_FLG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_VGCS_FEAT_FLG, 0, BE_VGCS_FEAT_FLG , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6455 |
6456 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6457 | }
6458 |
6459 | /*
6460 | * 3.2.1.51 VGCS/VBS SETUP ACK
6461 | */
6462 | static void
6463 | bssmap_vgcs_vbs_setup_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6464 | {
6465 | uint32_t curr_offset;
6466 | uint32_t consumed;
6467 | unsigned curr_len;
6468 |
6469 | curr_offset = offset;
6470 | curr_len = len;
6471 |
6472 | /* VGCS Feature Flags 3.2.2.88 BSS-MSC O(note 1) 3 */
6473 | ELEM_OPT_TLV(BE_VGCS_FEAT_FLG, GSM_A_PDU_TYPE_BSSMAP, BE_VGCS_FEAT_FLG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_VGCS_FEAT_FLG, 0, BE_VGCS_FEAT_FLG , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6474 |
6475 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6476 | }
6477 |
6478 | /*
6479 | * 3.2.1.52 VGCS/VBS SETUP REFUSE
6480 | */
6481 | static void
6482 | bssmap_vgcs_vbs_setup_refuse(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6483 | {
6484 | uint32_t curr_offset;
6485 | uint32_t consumed;
6486 | unsigned curr_len;
6487 |
6488 | curr_offset = offset;
6489 | curr_len = len;
6490 |
6491 | /* Cause 3.2.2.5 BSS-MSC M 3-4 */
6492 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6493 |
6494 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6495 | }
6496 |
6497 | /*
6498 | * 3.2.1.53 VGCS/VBS ASSIGNMENT REQUEST
6499 | */
6500 | static void
6501 | bssmap_vgcs_vbs_ass_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6502 | {
6503 | uint32_t curr_offset;
6504 | uint32_t consumed;
6505 | unsigned curr_len;
6506 |
6507 | curr_offset = offset;
6508 | curr_len = len;
6509 |
6510 | /* Channel Type 3.2.2.11 MSC-BSS M (note 2) 5-13 */
6511 | ELEM_MAND_TLV(BE_CHAN_TYPE, GSM_A_PDU_TYPE_BSSMAP, BE_CHAN_TYPE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CHAN_TYPE, 0, BE_CHAN_TYPE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CHAN_TYPE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CHAN_TYPE ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6512 | /* Assignment Requirement 3.2.2.52 MSC-BSS M 2 */
6513 | ELEM_MAND_TV(BE_ASS_REQ, GSM_A_PDU_TYPE_BSSMAP, BE_ASS_REQ, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_ASS_REQ, 0, BE_ASS_REQ, curr_offset , ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_ASS_REQ, get_gsm_a_msg_string(pinfo->pool, 0, BE_ASS_REQ ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6514 | /* Cell Identifier 3.2.2.17 MSC-BSS M 3-10 */
6515 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6516 | /* Group Call Reference 3.2.2.55 MSC-BSS M 7 */
6517 | ELEM_MAND_TLV(BE_GROUP_CALL_REF, GSM_A_PDU_TYPE_BSSMAP, BE_GROUP_CALL_REF, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_GROUP_CALL_REF, 0, BE_GROUP_CALL_REF , curr_offset, curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_GROUP_CALL_REF, get_gsm_a_msg_string(pinfo->pool, 0, BE_GROUP_CALL_REF ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6518 | /* Priority 3.2.2.18 MSC-BSS O 3 */
6519 | ELEM_OPT_TLV(BE_PRIO, GSM_A_PDU_TYPE_BSSMAP, BE_PRIO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_PRIO, 0, BE_PRIO, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6520 | /* Circuit Identity Code 3.2.2.2 MSC-BSS O (note 4, 5) 3 */
6521 | ELEM_OPT_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed ; } };
6522 | /* Downlink DTX Flag 3.2.2.26 MSC-BSS O (note 2, 4) 2 */
6523 | ELEM_OPT_TV(BE_DOWN_DTX_FLAG, GSM_A_PDU_TYPE_BSSMAP, BE_DOWN_DTX_FLAG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_DOWN_DTX_FLAG, 0, BE_DOWN_DTX_FLAG , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
6524 | /* Encryption Information 3.2.2.10 MSC-BSS O 3-n */
6525 | ELEM_OPT_TLV(BE_ENC_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_ENC_INFO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_ENC_INFO, 0, BE_ENC_INFO, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6526 | /* VSTK_RAND 3.2.2.83 MSC-BSS O (note 1) 7 */
6527 | ELEM_OPT_TLV(BE_VSTK_RAND_INF, GSM_A_PDU_TYPE_BSSMAP, BE_VSTK_RAND_INF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_VSTK_RAND_INF, 0, BE_VSTK_RAND_INF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6528 | /* VSTK 3.2.2.84 MSC-BSS O (note 1) 18 */
6529 | ELEM_OPT_TLV(BE_VSTK_INF, GSM_A_PDU_TYPE_BSSMAP, BE_VSTK_INF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_VSTK_INF, 0, BE_VSTK_INF, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6530 | /* Cell Identifier List Segment 3.2.2.27a MSC-BSS O (note 3) 4-? */
6531 | ELEM_OPT_TLV(BE_CELL_ID_LIST_SEG, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID_LIST_SEG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID_LIST_SEG, 0, BE_CELL_ID_LIST_SEG , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6532 | /* AoIP Transport Layer Address(MGW) 3.2.2.102 MSC - BSS O(note 6, 7) 8 - 20 */
6533 | ELEM_OPT_TLV(BE_AOIP_TRANS_LAY_ADD, GSM_A_PDU_TYPE_BSSMAP, BE_AOIP_TRANS_LAY_ADD, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_AOIP_TRANS_LAY_ADD, 0, BE_AOIP_TRANS_LAY_ADD , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6534 | /* Call Identifier 3.2.2.105 MSC - BSS O(note 6, 7) 5 */
6535 | ELEM_OPT_TV(BE_CALL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CALL_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CALL_ID, 0, BE_CALL_ID, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6536 | /* Codec List(MSC Preferred) 3.2.2.103 MSC - BSS O(note 6, 7) 3 - n */
6537 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(MSC Preferred)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(MSC Preferred)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6538 |
6539 |
6540 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6541 | }
6542 | /*
6543 | * 3.2.1.54 VGCS/VBS ASSIGNMENT RESULT
6544 | */
6545 | static void
6546 | bssmap_vgcs_vbs_ass_res(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6547 | {
6548 | uint32_t curr_offset;
6549 | uint32_t consumed;
6550 | unsigned curr_len;
6551 |
6552 | curr_offset = offset;
6553 | curr_len = len;
6554 |
6555 | /* Channel Type 3.2.2.11 BSS-MSC M (note 3, 4) 5 */
6556 | ELEM_MAND_TLV(BE_CHAN_TYPE, GSM_A_PDU_TYPE_BSSMAP, BE_CHAN_TYPE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CHAN_TYPE, 0, BE_CHAN_TYPE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CHAN_TYPE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CHAN_TYPE ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6557 | /* Cell Identifier 3.2.2.17 BSS-MSC M 3-10 */
6558 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6559 | /* Chosen Channel 3.2.2.33 BSS-MSC O (note 2) 2 */
6560 | ELEM_OPT_TV(BE_CHOSEN_CHAN, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_CHAN, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_CHAN, 0, BE_CHOSEN_CHAN , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
6561 | /* Circuit Identity Code 3.2.2.2 BSS-MSC O (note 5) 3 */
6562 | ELEM_OPT_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed ; } };
6563 | /* Circuit Pool 3.2.2.45 BSS-MSC O (note 1) 2 */
6564 | ELEM_OPT_TV(BE_CCT_POOL, GSM_A_PDU_TYPE_BSSMAP, BE_CCT_POOL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CCT_POOL, 0, BE_CCT_POOL, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6565 | /* AoIP Transport Layer Address (BSS) 3.2.2.102 BSS-MSC O (note 6, 7) 8-20 */
6566 | ELEM_OPT_TLV(BE_AOIP_TRANS_LAY_ADD, GSM_A_PDU_TYPE_BSSMAP, BE_AOIP_TRANS_LAY_ADD, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_AOIP_TRANS_LAY_ADD, 0, BE_AOIP_TRANS_LAY_ADD , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6567 | /* Speech Codec (Chosen) 3.2.2.104 BSS-MSC O (note 6, 7) 3-5 */
6568 | ELEM_OPT_TLV(BE_SPEECH_CODEC, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC, "(Chosen)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC, 0, BE_SPEECH_CODEC , curr_offset, curr_len, "(Chosen)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6569 | /* Call Identifier 3.2.2.105 BSS-MSC O (note 6, 7) 5 */
6570 | ELEM_OPT_TV(BE_CALL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CALL_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CALL_ID, 0, BE_CALL_ID, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6571 |
6572 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6573 | }
6574 | /*
6575 | * 3.2.1.55 VGCS/VBS ASSIGNMENT FAILURE
6576 | */
6577 | static void
6578 | bssmap_vgcs_vbs_ass_fail(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6579 | {
6580 | uint32_t curr_offset;
6581 | uint32_t consumed;
6582 | unsigned curr_len;
6583 |
6584 | curr_offset = offset;
6585 | curr_len = len;
6586 |
6587 | /* Cause 3.2.2.5 BSS-MSC M 3-4 */
6588 | ELEM_OPT_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6589 | /* Circuit Pool 3.2.2.45 BSS-MSC O (note 1) 2 */
6590 | ELEM_OPT_TV(BE_CCT_POOL, GSM_A_PDU_TYPE_BSSMAP, BE_CCT_POOL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CCT_POOL, 0, BE_CCT_POOL, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6591 | /* Circuit Pool List 3.2.2.46 BSS-MSC O (note 2) V */
6592 | ELEM_OPT_TLV(BE_CCT_POOL_LIST, GSM_A_PDU_TYPE_BSSMAP, BE_CCT_POOL_LIST, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CCT_POOL_LIST, 0, BE_CCT_POOL_LIST , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6593 | /* Codec List (BSS Supported) 3.2.2.103 BSS-MSC O (note 3) 3-n */
6594 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(BSS Supported)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(BSS Supported)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6595 |
6596 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6597 | }
6598 | /*
6599 | * 3.2.1.56 VGCS/VBS QUEUING INDICATION
6600 | * No data
6601 | */
6602 | /*
6603 | * 3.2.1.57 UPLINK REQUEST
6604 | */
6605 | static void
6606 | bssmap_uplink_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6607 | {
6608 | uint32_t curr_offset;
6609 | uint32_t consumed;
6610 | unsigned curr_len;
6611 |
6612 | curr_offset = offset;
6613 | curr_len = len;
6614 |
6615 | /* Talker Priority 3.2.2.89 BSS-MSC O (note 1) 2 */
6616 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6617 | /* Cell Identifier 3.2.2.17 BSS-MSC O (note 1) 3-10 */
6618 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6619 | /* Layer 3 Information 3.2.2.24 BSS-MSC O (note 1,3) 3-n */
6620 | ELEM_OPT_TLV(BE_L3_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_L3_INFO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_L3_INFO, 0, BE_L3_INFO, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6621 | /* Mobile Identity 3.2.2.41 BSS-MSC O (note 1,2) 3-n */
6622 | ELEM_OPT_TLV(BE_MID, GSM_A_PDU_TYPE_COMMON, DE_MID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_MID, 4, DE_MID, curr_offset, curr_len , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6623 |
6624 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6625 | }
6626 | /*
6627 | * 3.2.1.58 UPLINK REQUEST ACKNOWLEDGE
6628 | */
6629 | static void
6630 | bssmap_uplink_req_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6631 | {
6632 | uint32_t curr_offset;
6633 | uint32_t consumed;
6634 | unsigned curr_len;
6635 |
6636 | curr_offset = offset;
6637 | curr_len = len;
6638 |
6639 | /* Talker Priority 3.2.2.89 MSC-BSS O (note 1) 2 */
6640 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6641 | /* Emergency set indication 3.2.2.90 MSC-BSS O (note 1) 1 */
6642 | ELEM_OPT_T(BE_EMRG_SET_IND, GSM_A_PDU_TYPE_BSSMAP, BE_EMRG_SET_IND, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_t (tvb, tree, pinfo, (uint8_t) BE_EMRG_SET_IND, 0, BE_EMRG_SET_IND , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
6643 | /* Talker Identity 3.2.2.91 MSC-BSS O 3-20 */
6644 | ELEM_MAND_TLV(BE_TALKER_ID, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_TALKER_ID, 0, BE_TALKER_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_TALKER_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_TALKER_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6645 |
6646 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6647 | }
6648 | /*
6649 | * 3.2.1.59 UPLINK REQUEST CONFIRMATION
6650 | */
6651 | static void
6652 | bssmap_uplink_req_conf(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6653 | {
6654 | uint32_t curr_offset;
6655 | uint32_t consumed;
6656 | unsigned curr_len;
6657 |
6658 | curr_offset = offset;
6659 | curr_len = len;
6660 |
6661 | /* Cell Identifier 3.2.2.17 BSS-MSC M 3-10 */
6662 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6663 | /* Talker Identity 3.2.2.91 BSS-MSC O 3-20 */
6664 | ELEM_OPT_TLV(BE_TALKER_ID, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_TALKER_ID, 0, BE_TALKER_ID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6665 | /* Layer 3 Information 3.2.2.24 BSS-MSC M 3-n */
6666 | ELEM_MAND_TLV(BE_L3_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_L3_INFO, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_L3_INFO, 0, BE_L3_INFO, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_L3_INFO, get_gsm_a_msg_string(pinfo->pool, 0, BE_L3_INFO ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6667 |
6668 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6669 | }
6670 | /*
6671 | * 3.2.1.59a UPLINK APPLICATION DATA
6672 | */
6673 | static void
6674 | bssmap_uplink_app_data(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6675 | {
6676 | uint32_t curr_offset;
6677 | uint32_t consumed;
6678 | unsigned curr_len;
6679 |
6680 | curr_offset = offset;
6681 | curr_len = len;
6682 |
6683 | /* Cell Identifier 3.2.2.17 BSS-MSC M 3-10 */
6684 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6685 | /* Layer 3 Information 3.2.2.24 BSS-MSC M 3-n */
6686 | ELEM_MAND_TLV(BE_L3_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_L3_INFO, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_L3_INFO, 0, BE_L3_INFO, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_L3_INFO, get_gsm_a_msg_string(pinfo->pool, 0, BE_L3_INFO ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6687 | /* Application Data information 3.2.2.100 BSS-MSC M 3 */
6688 | ELEM_MAND_TLV(BE_APP_DATA_INF, GSM_A_PDU_TYPE_BSSMAP, BE_APP_DATA_INF, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_APP_DATA_INF, 0, BE_APP_DATA_INF , curr_offset, curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_APP_DATA_INF, get_gsm_a_msg_string(pinfo->pool, 0, BE_APP_DATA_INF ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6689 |
6690 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6691 | }
6692 | /*
6693 | * 3.2.1.60 UPLINK RELEASE INDICATION
6694 | */
6695 | static void
6696 | bssmap_uplink_rel_ind(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6697 | {
6698 | uint32_t curr_offset;
6699 | uint32_t consumed;
6700 | unsigned curr_len;
6701 |
6702 | curr_offset = offset;
6703 | curr_len = len;
6704 |
6705 | /* Cause 3.2.2.5 BSS-MSC M 3-4 */
6706 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6707 | /* Talker Priority 3.2.2.89 BSS-MSC O (note 1) 2 */
6708 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6709 |
6710 |
6711 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6712 | }
6713 | /*
6714 | * 3.2.1.61 UPLINK REJECT COMMAND
6715 | */
6716 | static void
6717 | bssmap_uplink_rej_cmd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6718 | {
6719 | uint32_t curr_offset;
6720 | uint32_t consumed;
6721 | unsigned curr_len;
6722 |
6723 | curr_offset = offset;
6724 | curr_len = len;
6725 |
6726 | /* Cause 3.2.2.5 MSC-BSS M 3-4 */
6727 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6728 | /* Current Talker Priority 3.2.2.89 MSC-BSS O (note 1) 2 */
6729 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, "Current"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, "Current")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6730 | /* Rejected Talker Priority 3.2.2.89 MSC-BSS O (note 1) 2 */
6731 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, "Rejected"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, "Rejected")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6732 | /* Talker Identity 3.2.2.91 MSC-BSS O 3-20 */
6733 | ELEM_OPT_TLV(BE_TALKER_ID, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_TALKER_ID, 0, BE_TALKER_ID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6734 |
6735 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6736 | }
6737 | /*
6738 | * 3.2.1.62 UPLINK RELEASE COMMAND
6739 | */
6740 | static void
6741 | bssmap_uplink_rel_cmd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6742 | {
6743 | uint32_t curr_offset;
6744 | uint32_t consumed;
6745 | unsigned curr_len;
6746 |
6747 | curr_offset = offset;
6748 | curr_len = len;
6749 |
6750 | /* Cause 3.2.2.5 MSC-BSS M 3-4 */
6751 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6752 |
6753 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6754 | }
6755 |
6756 | /*
6757 | * 3.2.1.63 UPLINK SEIZED COMMAND
6758 | */
6759 | static void
6760 | bssmap_uplink_seized_cmd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6761 | {
6762 | uint32_t curr_offset;
6763 | uint32_t consumed;
6764 | unsigned curr_len;
6765 |
6766 | curr_offset = offset;
6767 | curr_len = len;
6768 |
6769 | /* Cause 3.2.2.5 MSC-BSS M 3-4 */
6770 | ELEM_OPT_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6771 | /* Talker Priority 3.2.2.89 MSC-BSS O (note 1) 2 */
6772 | ELEM_OPT_TV(BE_TALKER_PRI, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_PRI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_TALKER_PRI, 0, BE_TALKER_PRI, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6773 | /* Emergency set indication 3.2.2.90 MSC-BSS O (note 1) 1 */
6774 | ELEM_OPT_T(BE_EMRG_SET_IND, GSM_A_PDU_TYPE_BSSMAP, BE_EMRG_SET_IND, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_t (tvb, tree, pinfo, (uint8_t) BE_EMRG_SET_IND, 0, BE_EMRG_SET_IND , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
6775 | /* Talker Identity 3.2.2.91 MSC-BSS O 3-20 */
6776 | ELEM_MAND_TLV(BE_TALKER_ID, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_TALKER_ID, 0, BE_TALKER_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_TALKER_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_TALKER_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6777 |
6778 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6779 | }
6780 | /*
6781 | * 3.2.1.64 SUSPEND
6782 | */
6783 | static void
6784 | bssmap_sus(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6785 | {
6786 | uint32_t curr_offset;
6787 | uint32_t consumed;
6788 | unsigned curr_len;
6789 |
6790 | curr_offset = offset;
6791 | curr_len = len;
6792 |
6793 | /* DLCI 3.2.2.25 BSS-MSC M 2 */
6794 | ELEM_MAND_TV(BE_DLCI, GSM_A_PDU_TYPE_BSSMAP, BE_DLCI, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_DLCI, 0, BE_DLCI, curr_offset , ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_DLCI, get_gsm_a_msg_string(pinfo->pool, 0, BE_DLCI), ( ((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6795 |
6796 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6797 | }
6798 | /*
6799 | * 3.2.1.65 RESUME
6800 | */
6801 | static void
6802 | bssmap_res(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6803 | {
6804 | uint32_t curr_offset;
6805 | uint32_t consumed;
6806 | unsigned curr_len;
6807 |
6808 | curr_offset = offset;
6809 | curr_len = len;
6810 |
6811 | /* DLCI 3.2.2.25 BSS-MSC M 2 */
6812 | ELEM_MAND_TV(BE_DLCI, GSM_A_PDU_TYPE_BSSMAP, BE_DLCI, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_DLCI, 0, BE_DLCI, curr_offset , ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_DLCI, get_gsm_a_msg_string(pinfo->pool, 0, BE_DLCI), ( ((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6813 |
6814 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6815 | }
6816 | /*
6817 | * [2] 3.2.1.66 CHANGE CIRCUIT
6818 | */
6819 | static void
6820 | bssmap_change_cct(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6821 | {
6822 | uint32_t curr_offset;
6823 | uint32_t consumed;
6824 | unsigned curr_len;
6825 |
6826 | curr_offset = offset;
6827 | curr_len = len;
6828 |
6829 | /* Cause 3.2.2.5 MSC-BSS M 3-4 */
6830 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6831 |
6832 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6833 | }
6834 |
6835 | /*
6836 | * [2] 3.2.1.67 CHANGE CIRCUIT ACKNOWLEDGE
6837 | */
6838 | static void
6839 | bssmap_change_cct_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6840 | {
6841 | uint32_t curr_offset;
6842 | uint32_t consumed;
6843 | unsigned curr_len;
6844 |
6845 | curr_offset = offset;
6846 | curr_len = len;
6847 |
6848 | /* Circuit identity 3.2.2.2 BSS-MSC M 3 */
6849 | ELEM_MAND_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed ; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element , tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CIC, get_gsm_a_msg_string(pinfo->pool, 0, BE_CIC), (( (void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6850 |
6851 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6852 | }
6853 |
6854 | /*
6855 | * [2] 3.2.1.68 Common ID
6856 | */
6857 | static void
6858 | bssmap_common_id(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6859 | {
6860 | uint32_t curr_offset;
6861 | uint32_t consumed;
6862 | unsigned curr_len;
6863 |
6864 | curr_offset = offset;
6865 | curr_len = len;
6866 |
6867 | /* IMSI 3.2.2.6 MSC-BSS M 3-10 */
6868 | ELEM_MAND_TLV(BE_IMSI, GSM_A_PDU_TYPE_BSSMAP, BE_IMSI, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_IMSI, 0, BE_IMSI, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_IMSI, get_gsm_a_msg_string(pinfo->pool, 0, BE_IMSI), ( ((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6869 | /* SNA Access Information 3.2.2.82 MSC-BSC O (note) 2+n */
6870 | ELEM_OPT_TLV(BE_SNA_ACC_INF, GSM_A_PDU_TYPE_BSSMAP, BE_SNA_ACC_INF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SNA_ACC_INF, 0, BE_SNA_ACC_INF , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6871 | /* Selected PLMN ID 3.2.2.126 MSC-BSC O (note 3) */
6872 | ELEM_OPT_TV(BE_SELECTED_PLMN_ID, GSM_A_PDU_TYPE_BSSMAP, BE_SELECTED_PLMN_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_SELECTED_PLMN_ID, 0, BE_SELECTED_PLMN_ID , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
6873 | /* Last used E-UTRAN PLMN ID 3.2.2.127 MSC-BSC O (note 4) 4 */
6874 | ELEM_OPT_TV(BE_LAST_USED_E_UTRAN_PLMN_ID, GSM_A_PDU_TYPE_BSSMAP, BE_LAST_USED_E_UTRAN_PLMN_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LAST_USED_E_UTRAN_PLMN_ID, 0, BE_LAST_USED_E_UTRAN_PLMN_ID, curr_offset, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6875 |
6876 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6877 | }
6878 |
6879 | /*
6880 | * [2] 3.2.1.69 LSA INFORMATION
6881 | */
6882 | static void
6883 | bssmap_lsa_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6884 | {
6885 | uint32_t curr_offset;
6886 | uint32_t consumed;
6887 | unsigned curr_len;
6888 |
6889 | curr_offset = offset;
6890 | curr_len = len;
6891 |
6892 | /* LSA Information 3.2.2.23 MSC-BSS M 3+4n */
6893 | ELEM_MAND_TLV(BE_LSA_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_LSA_INFO, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LSA_INFO, 0, BE_LSA_INFO, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_LSA_INFO, get_gsm_a_msg_string(pinfo->pool, 0, BE_LSA_INFO ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6894 |
6895 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6896 | }
6897 |
6898 | /*
6899 | * [2] 3.2.1.70 (void)
6900 | */
6901 | void
6902 | bssmap_conn_oriented(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6903 | {
6904 | uint32_t curr_offset;
6905 | uint32_t consumed;
6906 | unsigned curr_len;
6907 |
6908 | curr_offset = offset;
6909 | curr_len = len;
6910 |
6911 | ELEM_MAND_TLV_E(BE_APDU, GSM_A_PDU_TYPE_BSSMAP, BE_APDU, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv_e (tvb, tree, pinfo, (uint8_t) BE_APDU, 0, BE_APDU, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_APDU, get_gsm_a_msg_string(pinfo->pool, 0, BE_APDU), ( ((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6912 |
6913 | ELEM_OPT_TLV(BE_SEG, GSM_A_PDU_TYPE_BSSMAP, BE_SEG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SEG, 0, BE_SEG, curr_offset, curr_len , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6914 | /* Multilateration Positioning Method Multilateration Positioning Method C (Note 2) TLV 2
6915 | * Cell Identifier Cell Identifier C (Note 3) TLV 7
6916 | * Multilateration Timing Advance Multilateration Timing Advance C (Note 3) TV 3
6917 | * MS Sync Accuracy MS Sync Accuracy C (Note 4) TV 2
6918 | * BTS Reception Accuracy Level BTS Reception Accuracy Level C (Note 3) TV 2
6919 | * Short ID Short ID C (Note 5) TV 2
6920 | * Random ID Random ID C (Note 4) TV 3
6921 | */
6922 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6923 | }
6924 |
6925 | /*
6926 | * 3.2.1.71 PERFORM LOCATION REQUEST
6927 | */
6928 | static void
6929 | bssmap_perf_loc_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6930 | {
6931 | uint32_t curr_offset;
6932 | uint32_t consumed;
6933 | unsigned curr_len;
6934 |
6935 | curr_offset = offset;
6936 | curr_len = len;
6937 |
6938 | /* Location Type 3.2.2.63 M 3-n */
6939 | ELEM_MAND_TLV(BE_LOC_TYPE, GSM_A_PDU_TYPE_BSSMAP, BE_LOC_TYPE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LOC_TYPE, 0, BE_LOC_TYPE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_LOC_TYPE, get_gsm_a_msg_string(pinfo->pool, 0, BE_LOC_TYPE ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
6940 | /* Cell Identifier 3.2.2.17 O 5-10 */
6941 | ELEM_OPT_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6942 | /* Classmark Information Type 3 3.2.2.20 O 3-14 */
6943 | ELEM_OPT_TLV(BE_CM_INFO_3, GSM_A_PDU_TYPE_BSSMAP, BE_CM_INFO_3, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CM_INFO_3, 0, BE_CM_INFO_3, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6944 | /* LCS Client Type 3.2.2.67 C (note 3) 3-n */
6945 | ELEM_OPT_TLV(BE_LCS_CLIENT, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_LCS_CLIENT_TYPE, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LCS_CLIENT, 8, DE_BMAPLE_LCS_CLIENT_TYPE , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6946 | /* Chosen Channel 3.2.2.33 O 2 */
6947 | ELEM_OPT_TV(BE_CHOSEN_CHAN, GSM_A_PDU_TYPE_BSSMAP, BE_CHOSEN_CHAN, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CHOSEN_CHAN, 0, BE_CHOSEN_CHAN , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
6948 | /* LCS Priority 3.2.2.62 O 3-n */
6949 | ELEM_OPT_TLV(BE_LCS_PRIO, GSM_A_PDU_TYPE_BSSMAP, BE_LCS_PRIO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LCS_PRIO, 0, BE_LCS_PRIO, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6950 | /* LCS QoS 3.2.2.60 C (note 1) 3-n */
6951 | ELEM_OPT_TLV(BE_LCS_QOS, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_LCSQOS, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LCS_QOS, 8, DE_BMAPLE_LCSQOS, curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6952 | /* GPS Assistance Data 3.2.2.70 C (note 2) 3-n */
6953 | ELEM_OPT_TLV(BE_GPS_ASSIST_DATA, GSM_A_PDU_TYPE_BSSMAP, BE_GPS_ASSIST_DATA, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_GPS_ASSIST_DATA, 0, BE_GPS_ASSIST_DATA , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6954 | /* APDU 3.2.2.68 O 3-n */
6955 | ELEM_OPT_TLV_E(BE_APDU, GSM_A_PDU_TYPE_BSSMAP, BE_APDU, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv_e (tvb, tree, pinfo, (uint8_t) BE_APDU, 0, BE_APDU, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6956 | /* IMSI 3.2.2.6 O (note 4) 5-10 */
6957 | ELEM_OPT_TLV(BE_IMSI, GSM_A_PDU_TYPE_BSSMAP, BE_IMSI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_IMSI, 0, BE_IMSI, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6958 | /* IMEI 3.2.2.86 O (note 4) 10 (use same decode as IMSI) */
6959 | ELEM_OPT_TLV(BE_IMEI, GSM_A_PDU_TYPE_BSSMAP, BE_IMEI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_IMEI, 0, BE_IMEI, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6960 | /* GANSS Location Type 3.2.2.97 C 3 */
6961 | ELEM_OPT_TLV(BE_GANSS_LOC_TYP, GSM_A_PDU_TYPE_BSSMAP, BE_GANSS_LOC_TYP, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_GANSS_LOC_TYP, 0, BE_GANSS_LOC_TYP , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6962 | /* GANSS Assistance Data 3.2.2.95 C (note 5) 3-n */
6963 | ELEM_OPT_TLV(BE_GANSS_ASS_DTA, GSM_A_PDU_TYPE_BSSMAP, BE_GANSS_ASS_DTA, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_GANSS_ASS_DTA, 0, BE_GANSS_ASS_DTA , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6964 |
6965 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6966 | }
6967 | /*
6968 | * 3.2.1.72 PERFORM LOCATION RESPONSE
6969 | */
6970 | static void
6971 | bssmap_perf_loc_res(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
6972 | {
6973 | uint32_t curr_offset;
6974 | uint32_t consumed;
6975 | unsigned curr_len;
6976 |
6977 | curr_offset = offset;
6978 | curr_len = len;
6979 |
6980 | /* Location Estimate 3.2.2.64 C (note 1) 3-n */
6981 | ELEM_OPT_TLV(BE_LOC_EST, GSM_A_PDU_TYPE_BSSMAP, BE_LOC_EST, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LOC_EST, 0, BE_LOC_EST, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6982 | /* Positioning Data 3.2.2.65 O 3-n */
6983 | ELEM_OPT_TLV(BE_POS_DATA, GSM_A_PDU_TYPE_BSSMAP, BE_POS_DATA, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_POS_DATA, 0, BE_POS_DATA, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6984 | /* Deciphering Keys 3.2.2.71 C (note 2) 3-n */
6985 | ELEM_OPT_TLV(BE_DECIPH_KEYS, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_DECIPH_KEYS, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_DECIPH_KEYS, 8, DE_BMAPLE_DECIPH_KEYS , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6986 | /* LCS Cause 3.2.2.66 C (note 3) 3-n */
6987 | ELEM_OPT_TLV(BE_LCS_CAUSE, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_LCS_CAUSE, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LCS_CAUSE, 8, DE_BMAPLE_LCS_CAUSE , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6988 | /* Velocity Estimate 3.2.2.87 O 3-n */
6989 | ELEM_OPT_TLV(BE_VEL_EST, GSM_A_PDU_TYPE_BSSMAP, BE_VEL_EST, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_VEL_EST, 0, BE_VEL_EST, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6990 | /* GANSS Positioning Data 3.2.2.96 O 3-n */
6991 | ELEM_OPT_TLV(BE_GANSS_POS_DTA, GSM_A_PDU_TYPE_BSSMAP, BE_GANSS_POS_DTA, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_GANSS_POS_DTA, 0, BE_GANSS_POS_DTA , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
6992 |
6993 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
6994 | }
6995 | /*
6996 | * 3.2.1.73 PERFORM LOCATION ABORT
6997 | */
6998 | void
6999 | bssmap_perf_loc_abort(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7000 | {
7001 | uint32_t curr_offset;
7002 | uint32_t consumed;
7003 | unsigned curr_len;
7004 |
7005 | curr_offset = offset;
7006 | curr_len = len;
7007 |
7008 | /* LCS Cause 3.2.2.66 M 3-n */
7009 | ELEM_OPT_TLV(BE_LCS_CAUSE, GSM_PDU_TYPE_BSSMAP_LE, DE_BMAPLE_LCS_CAUSE, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_LCS_CAUSE, 8, DE_BMAPLE_LCS_CAUSE , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7010 |
7011 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7012 | }
7013 |
7014 | /*
7015 | * 3.2.1.74 CONNECTIONLESS INFORMATION
7016 | *
7017 | Network Element Identity (source) 3.2.2.69 Both M 3-n
7018 | Network Element Identity (target) 3.2.2.69 Both M 3-n
7019 | APDU 3.2.2.68 Both M 3-n
7020 | Segmentation 3.2,2,74 Both C (note 1) 5
7021 | Return Error Request 3.2.2.72 Both C (note 2) 3-n
7022 | Return Error Cause 3.2.2.73 Both C (note 3) 3-n
7023 | */
7024 |
7025 | /*
7026 | * 3.2.1.75 CHANNEL MODIFY REQUEST
7027 | */
7028 |
7029 | static void
7030 | bssmap_chan_mod_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7031 | {
7032 | uint32_t curr_offset;
7033 | uint32_t consumed;
7034 | unsigned curr_len;
7035 |
7036 | curr_offset = offset;
7037 | curr_len = len;
7038 |
7039 | /* Cause 3.2.2.5 BSS-MSC M 3-4 */
7040 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
7041 |
7042 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7043 | }
7044 | /*
7045 | * 3.2.1.76 EMERGENCY RESET INDICATION
7046 | */
7047 | /*
7048 | Cell Identifier 3.2.2.17 BSS-MSC O 3-10
7049 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL);
7050 | Layer 3 Information 3.2.2.24 BSS-MSC O (note 2) 3-n
7051 | ELEM_OPT_TLV(BE_L3_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_L3_INFO, NULL);
7052 | Mobile Identity 3.2.2.41 BSS-MSC O (note 1) 3-n
7053 | */
7054 | /*
7055 | * 3.2.1.77 EMERGENCY RESET COMMAND
7056 | * No data
7057 | */
7058 | /*
7059 | * 3.2.1.78 VGCS ADDITIONAL INFORMATION
7060 | */
7061 | static void
7062 | bssmap_vgcs_add_inf(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7063 | {
7064 | uint32_t curr_offset;
7065 | uint32_t consumed;
7066 | unsigned curr_len;
7067 |
7068 | curr_offset = offset;
7069 | curr_len = len;
7070 |
7071 | /* Talker Identity 3.2.2.91 MSC-BSS M 3-20 */
7072 | ELEM_MAND_TLV(BE_TALKER_ID, GSM_A_PDU_TYPE_BSSMAP, BE_TALKER_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_TALKER_ID, 0, BE_TALKER_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_TALKER_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_TALKER_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
7073 |
7074 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7075 | }
7076 | /*
7077 | * 3.2.1.79 VGCS/VBS AREA CELL INFO
7078 | */
7079 | static void
7080 | bssmap_vgcs_vbs_area_cell_info(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7081 | {
7082 | uint32_t curr_offset;
7083 | uint32_t consumed;
7084 | unsigned curr_len;
7085 |
7086 | curr_offset = offset;
7087 | curr_len = len;
7088 |
7089 | /* Cell Identifier List Segment 3.2.2.27a MSC-BSS M 4-? */
7090 | ELEM_OPT_TLV(BE_CELL_ID_LIST_SEG, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID_LIST_SEG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID_LIST_SEG, 0, BE_CELL_ID_LIST_SEG , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7091 | /* Assignment Requirement 3.2.2.52 MSC-BSS O 2 */
7092 | ELEM_MAND_TV(BE_ASS_REQ, GSM_A_PDU_TYPE_BSSMAP, BE_ASS_REQ, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_ASS_REQ, 0, BE_ASS_REQ, curr_offset , ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_ASS_REQ, get_gsm_a_msg_string(pinfo->pool, 0, BE_ASS_REQ ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
7093 |
7094 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7095 | }
7096 | /*
7097 | * 3.2.1.80 VGCS/VBS ASSIGNMENT STATUS
7098 | */
7099 | static void
7100 | bssmap_vgcs_vbs_assign_status(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7101 | {
7102 | uint32_t curr_offset;
7103 | uint32_t consumed;
7104 | unsigned curr_len;
7105 |
7106 | curr_offset = offset;
7107 | curr_len = len;
7108 |
7109 | /* Cell Identifier List Segment for established cells 3.2.2.27b BSS-MSC O (note 1) 3-? */
7110 | ELEM_OPT_TLV(BE_CELL_ID_LST_SEG_F_EST_CELLS, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID_LST_SEG_F_EST_CELLS, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID_LST_SEG_F_EST_CELLS, 0 , BE_CELL_ID_LST_SEG_F_EST_CELLS, curr_offset, curr_len, ((void *)0))) > 0) { curr_offset += consumed; curr_len -= consumed ; } };
7111 | /* Cell Identifier List Segment for cells to be established 3.2.2.27c BSS-MSC O (note 1) 3-? */
7112 | ELEM_OPT_TLV(BE_CELL_ID_LST_SEG_F_CELL_TB_EST, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID_LST_SEG_F_CELL_TB_EST, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID_LST_SEG_F_CELL_TB_EST , 0, BE_CELL_ID_LST_SEG_F_CELL_TB_EST, curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed ; } };
7113 | /* Cell Identifier List Segment for released cells - no user present 3.2.2.27e BSS-MSC O (note 1) 3-? */
7114 | ELEM_OPT_TLV(BE_CELL_ID_LST_SEG_F_REL_CELL, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID_LST_SEG_F_REL_CELL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID_LST_SEG_F_REL_CELL, 0 , BE_CELL_ID_LST_SEG_F_REL_CELL, curr_offset, curr_len, ((void *)0))) > 0) { curr_offset += consumed; curr_len -= consumed ; } };
7115 | /* Cell Identifier List Segment for not established cells - no establishment possible 3.2.2.27f BSS-MSC O (note 1) 3-? */
7116 | ELEM_OPT_TLV(BE_CELL_ID_LST_SEG_F_NOT_EST_CELL, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID_LST_SEG_F_NOT_EST_CELL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID_LST_SEG_F_NOT_EST_CELL , 0, BE_CELL_ID_LST_SEG_F_NOT_EST_CELL, curr_offset, curr_len , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7117 | /* VGCS/VBS Cell Status 3.2.2.94 BSS-MSC O (note 2) 3 */
7118 | ELEM_OPT_TLV(BE_VGS_VBS_CELL_STAT, GSM_A_PDU_TYPE_BSSMAP, BE_VGS_VBS_CELL_STAT, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_VGS_VBS_CELL_STAT, 0, BE_VGS_VBS_CELL_STAT , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7119 |
7120 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7121 | }
7122 | /*
7123 | * 3.2.1.81 VGCS SMS
7124 | */
7125 | static void
7126 | bssmap_vgcs_sms(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7127 | {
7128 | uint32_t curr_offset;
7129 | uint32_t consumed;
7130 | unsigned curr_len;
7131 |
7132 | curr_offset = offset;
7133 | curr_len = len;
7134 |
7135 | /* SMS to VGCS 3.2.2.92 MSC-BSS M 2-250 */
7136 | ELEM_MAND_TLV(BE_SMS_TO_VGCS, GSM_A_PDU_TYPE_BSSMAP, BE_SMS_TO_VGCS, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SMS_TO_VGCS, 0, BE_SMS_TO_VGCS , curr_offset, curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_SMS_TO_VGCS, get_gsm_a_msg_string(pinfo->pool, 0, BE_SMS_TO_VGCS ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
7137 |
7138 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7139 | }
7140 | /*
7141 | * 3.2.1.82 NOTIFICATION DATA
7142 | */
7143 | static void
7144 | bssmap_notification_data(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7145 | {
7146 | uint32_t curr_offset;
7147 | uint32_t consumed;
7148 | unsigned curr_len;
7149 |
7150 | curr_offset = offset;
7151 | curr_len = len;
7152 |
7153 | /* Application Data 3.2.2.98 MSC-BSS M 11 */
7154 | ELEM_MAND_TLV(BE_APP_DATA_INF, GSM_A_PDU_TYPE_BSSMAP, BE_APP_DATA_INF, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_APP_DATA_INF, 0, BE_APP_DATA_INF , curr_offset, curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_APP_DATA_INF, get_gsm_a_msg_string(pinfo->pool, 0, BE_APP_DATA_INF ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
7155 | /* Data Identity 3.2.2.99 MSC-BSS M 3 */
7156 | ELEM_MAND_TLV(BE_DATA_ID, GSM_A_PDU_TYPE_BSSMAP, BE_DATA_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_DATA_ID, 0, BE_DATA_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_DATA_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_DATA_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
7157 | /* MSISDN 3.2.2.101 MSC-BSS O 2-12 */
7158 | ELEM_MAND_TLV(BE_MSISDN, GSM_A_PDU_TYPE_BSSMAP, BE_MSISDN, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_MSISDN, 0, BE_MSISDN, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_MSISDN, get_gsm_a_msg_string(pinfo->pool, 0, BE_MSISDN ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
7159 |
7160 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7161 | }
7162 | /*
7163 | * 3.2.1.83 INTERNAL HANDOVER REQUIRED
7164 | */
7165 | static void
7166 | bssmap_int_ho_req(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7167 | {
7168 | uint32_t curr_offset;
7169 | uint32_t consumed;
7170 | unsigned curr_len;
7171 |
7172 | curr_offset = offset;
7173 | curr_len = len;
7174 |
7175 | /* Cause 3.2.2.5 BSS-MSC M 3-4 */
7176 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
7177 | /* Cell Identifier 3.2.2.17 BSS-MSC M 4-10 */
7178 | ELEM_MAND_TLV(BE_CELL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CELL_ID, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CELL_ID, 0, BE_CELL_ID, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CELL_ID, get_gsm_a_msg_string(pinfo->pool, 0, BE_CELL_ID ), (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
7179 | /* AoIP Transport Layer Address (BSS) 3.2.2.nn BSS-MSC C (Note 1) 10-22 */
7180 | ELEM_OPT_TLV(BE_AOIP_TRANS_LAY_ADD, GSM_A_PDU_TYPE_BSSMAP, BE_AOIP_TRANS_LAY_ADD, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_AOIP_TRANS_LAY_ADD, 0, BE_AOIP_TRANS_LAY_ADD , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7181 | /* Codec List (BSS Supported) 3.2.2.103 BSS-MSC M 3-n */
7182 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(BSS Supported)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(BSS Supported)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7183 |
7184 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7185 | }
7186 | /*
7187 | * 3.2.1.84 INTERNAL HANDOVER REQUIRED REJECT
7188 | */
7189 | static void
7190 | bssmap_int_ho_req_rej(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7191 | {
7192 | uint32_t curr_offset;
7193 | uint32_t consumed;
7194 | unsigned curr_len;
7195 |
7196 | curr_offset = offset;
7197 | curr_len = len;
7198 |
7199 | /* Cause 3.2.2.5 MSC-BSS M 3-4 */
7200 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
7201 | /* Codec List (MSC Preferred) 3.2.2.nn MSC-BSS O 3-n */
7202 | ELEM_OPT_TLV(BE_SPEECH_CODEC_LST, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC_LST, "(BSS Supported)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC_LST, 0, BE_SPEECH_CODEC_LST , curr_offset, curr_len, "(BSS Supported)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7203 |
7204 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7205 | }
7206 |
7207 | /*
7208 | * 3.2.1.85 INTERNAL HANDOVER COMMAND
7209 | */
7210 | static void
7211 | bssmap_int_ho_cmd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7212 | {
7213 | uint32_t curr_offset;
7214 | uint32_t consumed;
7215 | unsigned curr_len;
7216 |
7217 | curr_offset = offset;
7218 | curr_len = len;
7219 |
7220 | /* Speech Codec (MSC Chosen) 3.2.2.nn MSC-BSS M (note 1) 3-n */
7221 | ELEM_OPT_TLV(BE_SPEECH_CODEC, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC, "(Chosen)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC, 0, BE_SPEECH_CODEC , curr_offset, curr_len, "(Chosen)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7222 | /* Circuit Identity Code 3.2.2.2 MSC-BSS C (note 2) 3 */
7223 | ELEM_OPT_TV(BE_CIC, GSM_A_PDU_TYPE_BSSMAP, BE_CIC, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CIC, 0, BE_CIC, curr_offset, ( (void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed ; } };
7224 | /* AoIP Transport Layer Address (MGW) 3.2.2.102 MSC-BSS C (note 2) 10-22 */
7225 | ELEM_OPT_TLV(BE_AOIP_TRANS_LAY_ADD, GSM_A_PDU_TYPE_BSSMAP, BE_AOIP_TRANS_LAY_ADD, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_AOIP_TRANS_LAY_ADD, 0, BE_AOIP_TRANS_LAY_ADD , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7226 | /* Call Identifier 3.2.2.105 MSC-BSS C (note 4) 5 */
7227 | ELEM_OPT_TV(BE_CALL_ID, GSM_A_PDU_TYPE_BSSMAP, BE_CALL_ID, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_CALL_ID, 0, BE_CALL_ID, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7228 | /* Downlink DTX Flag 3.2.2.26 MSC-BSS O (note 5) 2 */
7229 | ELEM_OPT_TV(BE_DOWN_DTX_FLAG, GSM_A_PDU_TYPE_BSSMAP, BE_DOWN_DTX_FLAG, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_DOWN_DTX_FLAG, 0, BE_DOWN_DTX_FLAG , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
7230 | /* LCLS-Connection-Status-Control 3.2.2.117 MSC-BSS O (note 6) 2 */
7231 | ELEM_OPT_TV(BE_LCLS_CON_STATUS_CONTROL, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_CON_STATUS_CONTROL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_CON_STATUS_CONTROL, 0, BE_LCLS_CON_STATUS_CONTROL , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
7232 |
7233 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7234 | }
7235 | /*
7236 | * 3.2.1.86 INTERNAL HANDOVER ENQUIRY
7237 | */
7238 |
7239 | static void
7240 | bssmap_int_ho_enq(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7241 | {
7242 | uint32_t curr_offset;
7243 | uint32_t consumed;
7244 | unsigned curr_len;
7245 |
7246 | curr_offset = offset;
7247 | curr_len = len;
7248 |
7249 | /* Speech Codec (MSC Chosen) 3.2.2.104 MSC-BSS M 3-n */
7250 | ELEM_OPT_TLV(BE_SPEECH_CODEC, GSM_A_PDU_TYPE_BSSMAP, BE_SPEECH_CODEC, "(Chosen)"){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_SPEECH_CODEC, 0, BE_SPEECH_CODEC , curr_offset, curr_len, "(Chosen)")) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7251 |
7252 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7253 | }
7254 | /*
7255 | * 3.2.1.87 RESET IP RESOURCE
7256 | */
7257 | static void
7258 | bssmap_reset_ip_res(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7259 | {
7260 | uint32_t curr_offset;
7261 | uint32_t consumed;
7262 | unsigned curr_len;
7263 |
7264 | curr_offset = offset;
7265 | curr_len = len;
7266 |
7267 | /* Cause 3.2.2.5 Both M 3-4 */
7268 | ELEM_MAND_TLV(BE_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CAUSE, 0, BE_CAUSE, curr_offset , curr_len, ((void*)0))) > 0)) { curr_offset += consumed; curr_len -= consumed; } else { proto_tree_add_expert_format(tree, pinfo , &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset , 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0, BE_CAUSE) , (((void*)0) == ((void*)0)) ? "" : ((void*)0) ); } };
7269 | /* Call Identifier List 3.2.2.106 Both M 6-n */
7270 | ELEM_OPT_TLV(BE_CALL_ID_LST, GSM_A_PDU_TYPE_BSSMAP, BE_CALL_ID_LST, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CALL_ID_LST, 0, BE_CALL_ID_LST , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7271 |
7272 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7273 | }
7274 | /*
7275 | * 3.2.1.88 RESET IP RESOURCE ACKNOWLEDGE
7276 | */
7277 | static void
7278 | bssmap_reset_ip_res_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7279 | {
7280 | uint32_t curr_offset;
7281 | uint32_t consumed;
7282 | unsigned curr_len;
7283 |
7284 | curr_offset = offset;
7285 | curr_len = len;
7286 |
7287 | /* Call Identifier List 3.2.2.106 Both M 6-n */
7288 | ELEM_OPT_TLV(BE_CALL_ID_LST, GSM_A_PDU_TYPE_BSSMAP, BE_CALL_ID_LST, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_CALL_ID_LST, 0, BE_CALL_ID_LST , curr_offset, curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7289 |
7290 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7291 | }
7292 |
7293 | /*
7294 | * 3.2.1.89 REROUTE COMMAND
7295 | */
7296 | static void
7297 | bssmap_reroute_cmd(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7298 | {
7299 | uint32_t curr_offset;
7300 | uint32_t consumed;
7301 | unsigned curr_len;
7302 |
7303 | curr_offset = offset;
7304 | curr_len = len;
7305 |
7306 | /* Initial Layer 3 Information 3.2.2.24 MSC-BSS M (note 1) 3-n */
7307 | ELEM_MAND_TLV(BE_L3_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_L3_INFO, " (Initial)", ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_L3_INFO, 0, BE_L3_INFO, curr_offset , curr_len, " (Initial)")) > 0)) { curr_offset += consumed ; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_L3_INFO, get_gsm_a_msg_string(pinfo->pool, 0, BE_L3_INFO ), (" (Initial)" == ((void*)0)) ? "" : " (Initial)" ); } };
7308 | /* Reroute Reject Cause 3.2.2.112 MSC-BSS M (note 2) 2 */
7309 | ELEM_MAND_TV(BE_REROUTE_REJ_CAUSE, GSM_A_PDU_TYPE_BSSMAP, BE_REROUTE_REJ_CAUSE, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_REROUTE_REJ_CAUSE, 0, BE_REROUTE_REJ_CAUSE , curr_offset, ((void*)0))) > 0)) { curr_offset += consumed ; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_REROUTE_REJ_CAUSE, get_gsm_a_msg_string(pinfo->pool, 0 , BE_REROUTE_REJ_CAUSE), (((void*)0) == ((void*)0)) ? "" : (( void*)0) ); } };
7310 | /* Layer 3 Information 3.2.2.24 MSC-BSS O (note3) 3-n */
7311 | ELEM_OPT_TLV(BE_L3_INFO, GSM_A_PDU_TYPE_BSSMAP, BE_L3_INFO, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_L3_INFO, 0, BE_L3_INFO, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7312 | /* Send Sequence Number 3.2.2.113 MSC-BSS O (note 4) 2 */
7313 | ELEM_OPT_TV(BE_SEND_SEQN, GSM_A_PDU_TYPE_BSSMAP, BE_SEND_SEQN, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_SEND_SEQN, 0, BE_SEND_SEQN, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7314 | /* IMSI 3.2.2.6 MSC-BSS O (note 5) 3-10 */
7315 | ELEM_OPT_TLV(BE_IMSI, GSM_A_PDU_TYPE_BSSMAP, BE_IMSI, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tlv (tvb, tree, pinfo, (uint8_t) BE_IMSI, 0, BE_IMSI, curr_offset , curr_len, ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7316 | /* Old Location Area Identification 3.2.2.128 MSC-BSS O (note 6) 6 */
7317 |
7318 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7319 | }
7320 |
7321 | /*
7322 | * 3.2.1.90 REROUTE COMPLETE
7323 | */
7324 |
7325 | static void
7326 | bssmap_reroute_complete(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7327 | {
7328 | uint32_t curr_offset;
7329 | uint32_t consumed;
7330 | unsigned curr_len;
7331 |
7332 | curr_offset = offset;
7333 | curr_len = len;
7334 |
7335 | /* Reroute complete outcome 3.2.2.114 MSC-BSS M 2 */
7336 | ELEM_MAND_TV(BE_REROUTE_OUTCOME, GSM_A_PDU_TYPE_BSSMAP, BE_REROUTE_OUTCOME, NULL, ei_gsm_a_bssmap_missing_mandatory_element){ if (((signed)curr_len > 0) && ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_REROUTE_OUTCOME, 0, BE_REROUTE_OUTCOME , curr_offset, ((void*)0))) > 0)) { curr_offset += consumed ; curr_len -= consumed; } else { proto_tree_add_expert_format (tree, pinfo, &ei_gsm_a_bssmap_missing_mandatory_element, tvb, curr_offset, 0, "Missing Mandatory element (0x%02x) %s%s, rest of dissection is suspect" , BE_REROUTE_OUTCOME, get_gsm_a_msg_string(pinfo->pool, 0, BE_REROUTE_OUTCOME), (((void*)0) == ((void*)0)) ? "" : ((void *)0) ); } };
7337 |
7338 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7339 | }
7340 |
7341 | /*
7342 | * 3.2.1.91 LCLS-CONNECT-CONTROL
7343 | */
7344 | static void
7345 | bssmap_lcls_conn_ctrl(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7346 | {
7347 | uint32_t curr_offset;
7348 | uint32_t consumed;
7349 | unsigned curr_len;
7350 |
7351 | curr_offset = offset;
7352 | curr_len = len;
7353 |
7354 |
7355 | /* LCLS-Configuration 3.2.2.116 MSC-BSS O (note1) 2 */
7356 | ELEM_OPT_TV(BE_LCLS_CONF, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_CONF, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_CONF, 0, BE_LCLS_CONF, curr_offset , ((void*)0))) > 0) { curr_offset += consumed; curr_len -= consumed; } };
7357 | /* LCLS-Connection-Status-Control 3.2.2.117 MSC-BSS O (note1) 2 */
7358 | ELEM_OPT_TV(BE_LCLS_CON_STATUS_CONTROL, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_CON_STATUS_CONTROL, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_CON_STATUS_CONTROL, 0, BE_LCLS_CON_STATUS_CONTROL , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
7359 |
7360 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7361 | }
7362 |
7363 | /*
7364 | * 3.2.1.92 LCLS-CONNECT-CONTROL-ACK
7365 | */
7366 | static void
7367 | bssmap_lcls_conn_ctrl_ack(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7368 | {
7369 | uint32_t curr_offset;
7370 | uint32_t consumed;
7371 | unsigned curr_len;
7372 |
7373 | curr_offset = offset;
7374 | curr_len = len;
7375 |
7376 | /* LCLS-BSS-Status 3.2.2.119 BSS-MSC M 2 */
7377 | ELEM_OPT_TV(BE_LCLS_BSS_STATUS, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_BSS_STATUS, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_BSS_STATUS, 0, BE_LCLS_BSS_STATUS , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
7378 |
7379 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7380 | }
7381 | /*
7382 | *
7383 | * 3.2.1.93 LCLS-NOTIFICATION
7384 | */
7385 | static void
7386 | bssmap_lcls_notif(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len)
7387 | {
7388 | uint32_t curr_offset;
7389 | uint32_t consumed;
7390 | unsigned curr_len;
7391 |
7392 | curr_offset = offset;
7393 | curr_len = len;
7394 |
7395 | /* LCLS-BSS-Status 3.2.2.119 BSS-MSC O (note 1) 2 */
7396 | ELEM_OPT_TV(BE_LCLS_BSS_STATUS, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_BSS_STATUS, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_tv (tvb, tree, pinfo, (uint8_t) BE_LCLS_BSS_STATUS, 0, BE_LCLS_BSS_STATUS , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
7397 | /* LCLS-Break-Request 3.2.2.120 BSS-MSC O (note 1) 1 */
7398 | ELEM_OPT_T(BE_LCLS_BREAK_REQ, GSM_A_PDU_TYPE_BSSMAP, BE_LCLS_BREAK_REQ, NULL){ if ((signed)curr_len <= 0) return; if ((consumed = elem_t (tvb, tree, pinfo, (uint8_t) BE_LCLS_BREAK_REQ, 0, BE_LCLS_BREAK_REQ , curr_offset, ((void*)0))) > 0) { curr_offset += consumed ; curr_len -= consumed; } };
7399 |
7400 | EXTRANEOUS_DATA_CHECK(curr_len, 0, pinfo, &ei_gsm_a_bssmap_extraneous_data)if ((curr_len) > (0)) { proto_tree_add_expert(tree, pinfo, &ei_gsm_a_bssmap_extraneous_data, tvb, curr_offset, (curr_len ) - (0)); curr_offset += ((curr_len) - (0)); };
7401 | }
7402 |
7403 | #if 0
7404 | /*
7405 | * 3.2.1.94 MS REGISTRATION ENQUIRY
7406 | */
7407 | /* IMSI 3.2.2.6 BSS-MSC M 3-10 */
7408 | /*
7409 | * 3.2.1.95 MS REGISTRATION ENQUIRY RESPONSE
7410 | */
7411 | /* IMSI 3.2.2.6 MSC-BSS M 3-10 */
7412 | /* CS Registered Operator 3.2.2.132 MSC-BSS O (note 1) 4 */
7413 |
7414 |
7415 | #endif
7416 | #define NUM_GSM_BSSMAP_MSG(int)(sizeof (gsm_a_bssmap_msg_strings) / sizeof (gsm_a_bssmap_msg_strings )[0]) (int)array_length(gsm_a_bssmap_msg_strings)(sizeof (gsm_a_bssmap_msg_strings) / sizeof (gsm_a_bssmap_msg_strings )[0])
7417 | static int ett_gsm_bssmap_msg[NUM_GSM_BSSMAP_MSG(int)(sizeof (gsm_a_bssmap_msg_strings) / sizeof (gsm_a_bssmap_msg_strings )[0])];
7418 |
7419 | static void (* const bssmap_msg_fcn[])(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo, uint32_t offset, unsigned len) = {
7420 | bssmap_ass_req, /* Assignment Request */
7421 | bssmap_ass_complete, /* Assignment Complete */
7422 | bssmap_ass_failure, /* Assignment Failure */
7423 | bssmap_vgcs_vbs_setup, /* VGCS/VBS Setup */
7424 | bssmap_vgcs_vbs_setup_ack, /* VGCS/VBS Setup Ack */
7425 | bssmap_vgcs_vbs_setup_refuse, /* VGCS/VBS Setup Refuse */
7426 | bssmap_vgcs_vbs_ass_req, /* VGCS/VBS Assignment Request */
7427 | bssmap_chan_mod_req, /* 0x08 Channel Modify request */
7428 | NULL((void*)0), /* Unallocated */
7429 | NULL((void*)0), /* Unallocated */
7430 | NULL((void*)0), /* Unallocated */
7431 | NULL((void*)0), /* Unallocated */
7432 | NULL((void*)0), /* Unallocated */
7433 | NULL((void*)0), /* Unallocated */
7434 | NULL((void*)0), /* Unallocated */
7435 | bssmap_ho_req, /* 0x10 Handover Request */
7436 | bssmap_ho_reqd, /* Handover Required */
7437 | bssmap_ho_req_ack, /* Handover Request Acknowledge */
7438 | bssmap_ho_cmd, /* Handover Command */
7439 | bssmap_ho_complete, /* Handover Complete */
7440 | bssmap_ho_succ, /* Handover Succeeded */
7441 | bssmap_ho_failure, /* Handover Failure */
7442 | bssmap_ho_performed, /* Handover Performed */
7443 | bssmap_ho_cand_enq, /* Handover Candidate Enquire */
7444 | bssmap_ho_cand_resp, /* Handover Candidate Response */
7445 | bssmap_ho_reqd_rej, /* Handover Required Reject */
7446 | bssmap_ho_det, /* 0x1b Handover Detect */
7447 | bssmap_vgcs_vbs_ass_res, /* 0x1c VGCS/VBS Assignment Result */
7448 | bssmap_vgcs_vbs_ass_fail, /* 0x1d VGCS/VBS Assignment Failure */
7449 | NULL((void*)0), /* 0x1e No dsta VGCS/VBS Queuing Indication */
7450 | bssmap_uplink_req, /* 0x1f Uplink Request */
7451 |
7452 | bssmap_clear_cmd, /* 0x20 Clear Command */
7453 | NULL((void*)0) /* no associated data */, /* Clear Complete */
7454 | bssmap_clear_req, /* Clear Request */
7455 | NULL((void*)0), /* Reserved */
7456 | NULL((void*)0), /* Reserved */
7457 | bssmap_sapi_rej, /* SAPI 'n' Reject */
7458 | bssmap_confusion, /* Confusion */
7459 | bssmap_uplink_req_ack, /* Uplink Request Acknowledge */
7460 | bssmap_sus, /* Suspend */
7461 | bssmap_res, /* Resume */
7462 | bssmap_conn_oriented, /* Connection Oriented Information */
7463 | bssmap_perf_loc_req, /* Perform Location Request */
7464 | bssmap_lsa_info, /* LSA Information */
7465 | bssmap_perf_loc_res, /* Perform Location Response */
7466 | bssmap_perf_loc_abort, /* Perform Location Abort */
7467 | bssmap_common_id, /* Common Id */
7468 | bssmap_reset, /* Reset */
7469 | bssmap_reset_ack, /* Reset Acknowledge */
7470 | bssmap_overload, /* Overload */
7471 | NULL((void*)0), /* Reserved */
7472 | bssmap_reset_cct, /* Reset Circuit */
7473 | bssmap_reset_cct_ack, /* Reset Circuit Acknowledge */
7474 | bssmap_msc_invoke_trace, /* MSC Invoke Trace */
7475 | bssmap_bss_invoke_trace, /* 0x37 BSS Invoke Trace */
7476 |
7477 | NULL((void*)0), /* 0x38 unallocated */
7478 | NULL((void*)0), /* 0x39 unallocated */
7479 |
7480 | NULL((void*)0), /* 0x3a Connectionless Information */
7481 | bssmap_vgcs_vbs_assign_status, /* 0x3b VGCS/VBS ASSIGNMENT STATUS */
7482 | bssmap_vgcs_vbs_area_cell_info, /* 0x3c VGCS/VBS AREA CELL INFO */
7483 | bssmap_reset_ip_res, /* 0x3d 3.2.1.87 RESET IP RESOURCE */
7484 | bssmap_reset_ip_res_ack, /* 0x3e 3.2.1.88 RESET IP RESOURCE ACKNOWLEDGE */
7485 | NULL((void*)0), /* 0x3f VGCS/VBS AREA CELL INFO */
7486 | bssmap_block, /* Block */
7487 | bssmap_block_ack, /* Blocking Acknowledge */
7488 | bssmap_unblock, /* Unblock */
7489 | bssmap_unblock_ack, /* Unblocking Acknowledge */
7490 | bssmap_cct_group_block, /* Circuit Group Block */
7491 | bssmap_cct_group_block_ack, /* Circuit Group Blocking Acknowledge */
7492 | bssmap_cct_group_unblock, /* Circuit Group Unblock */
7493 | bssmap_cct_group_unblock_ack, /* Circuit Group Unblocking Acknowledge */
7494 | bssmap_unequipped_cct, /* Unequipped Circuit */
7495 | bssmap_uplink_req_conf, /* Uplink Request Confirmation */
7496 | bssmap_uplink_rel_ind, /* Uplink Release Indication */
7497 | bssmap_uplink_rej_cmd, /* Uplink Reject Command */
7498 | bssmap_uplink_rel_cmd, /* Uplink Release Command */
7499 | bssmap_uplink_seized_cmd, /* Uplink Seized Command */
7500 | bssmap_change_cct, /* Change Circuit */
7501 | bssmap_change_cct_ack, /* Change Circuit Acknowledge */
7502 | bssmap_res_req, /* Resource Request */
7503 | bssmap_res_ind, /* Resource Indication */
7504 | bssmap_paging, /* Paging */
7505 | bssmap_ciph_mode_cmd, /* Cipher Mode Command */
7506 | bssmap_cm_upd, /* Classmark Update */
7507 | bssmap_ciph_mode_complete, /* Cipher Mode Complete */
7508 | NULL((void*)0) /* no associated data */, /* Queuing Indication */
7509 | bssmap_cl3_info, /* Complete Layer 3 Information */
7510 | bssmap_cls_m_req /* no associated data */, /* Classmark Request */
7511 | bssmap_ciph_mode_rej, /* Cipher Mode Reject */
7512 | bssmap_load_ind, /* 0x5a Load Indication */
7513 |
7514 | NULL((void*)0), /* 0x5b unallocated */
7515 | NULL((void*)0), /* 0x5c unallocated */
7516 | NULL((void*)0), /* 0x5d unallocated */
7517 | NULL((void*)0), /* 0x5e unallocated */
7518 | NULL((void*)0), /* 0x5f unallocated */
7519 |
7520 | bssmap_vgcs_add_inf, /* 0x60 VGCS Additional Information */
7521 | bssmap_vgcs_sms, /* 0x61 VGCS SMS */
7522 | bssmap_notification_data, /* 0x62 Notification Data*/
7523 | bssmap_uplink_app_data, /* 0x63 Uplink Application Data */
7524 |
7525 | NULL((void*)0), /* 0x64 unallocated */
7526 | NULL((void*)0), /* 0x65 unallocated */
7527 | NULL((void*)0), /* 0x66 unallocated */
7528 | NULL((void*)0), /* 0x67 unallocated */
7529 | NULL((void*)0), /* 0x68 unallocated */
7530 | NULL((void*)0), /* 0x69 unallocated */
7531 | NULL((void*)0), /* 0x6a unallocated */
7532 | NULL((void*)0), /* 0x6b unallocated */
7533 | NULL((void*)0), /* 0x6c unallocated */
7534 | NULL((void*)0), /* 0x6d unallocated */
7535 | NULL((void*)0), /* 0x6e unallocated */
7536 | NULL((void*)0), /* 0x6f unallocated */
7537 |
7538 | bssmap_int_ho_req, /* 0x70 Internal Handover Required */
7539 | bssmap_int_ho_req_rej, /* 0x71 Internal Handover Required Reject */
7540 | bssmap_int_ho_cmd, /* 0x72 Internal Handover Command */
7541 | bssmap_int_ho_enq, /* 0x73 Internal Handover Enquiry */
7542 |
7543 | bssmap_lcls_conn_ctrl, /* 0x74 LCLS-Connect-Control */
7544 | bssmap_lcls_conn_ctrl_ack, /* 0x75 LCLS-Connect-Control-Ack */
7545 | bssmap_lcls_notif, /* 0x76 LCLS-Notification */
7546 | NULL((void*)0), /* 0x77 Unallocated */
7547 | bssmap_reroute_cmd, /* 0x78 Reroute Command */
7548 | bssmap_reroute_complete, /* 0x79 Reroute Complete */
7549 |
7550 | NULL((void*)0), /* NONE */
7551 | };
7552 | #define NUM_BSSMAP_MSG_FCNS(int)(sizeof (bssmap_msg_fcn) / sizeof (bssmap_msg_fcn)[0]) (int)array_length(bssmap_msg_fcn)(sizeof (bssmap_msg_fcn) / sizeof (bssmap_msg_fcn)[0])
7553 |
7554 | static int
7555 | dissect_bssmap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data)
7556 | {
7557 | static gsm_a_tap_rec_t tap_rec[4];
7558 | static gsm_a_tap_rec_t *tap_p;
7559 | static unsigned tap_current = 0;
7560 | uint8_t oct;
7561 | uint32_t offset, saved_offset;
7562 | uint32_t len;
7563 | int idx;
7564 | proto_item *bssmap_item = NULL((void*)0);
7565 | proto_tree *bssmap_tree = NULL((void*)0);
7566 | const char *str;
7567 | sccp_msg_info_t* sccp_msg_p = (sccp_msg_info_t*)data;
7568 |
7569 | if (!(sccp_msg_p && sccp_msg_p->data.co.assoc)) {
7570 | sccp_msg_p = NULL((void*)0);
7571 | }
7572 |
7573 | col_append_str(pinfo->cinfo, COL_INFO, "(BSSMAP) ");
7574 |
7575 | /*
7576 | * set tap record pointer
7577 | */
7578 | tap_current++;
7579 | if (tap_current >= 4)
7580 | {
7581 | tap_current = 0;
7582 | }
7583 | tap_p = &tap_rec[tap_current];
7584 |
7585 |
7586 | offset = 0;
7587 | saved_offset = offset;
7588 |
7589 | g_tree = tree;
7590 |
7591 | len = tvb_reported_length(tvb);
7592 |
7593 | /*
7594 | * add BSSMAP message name
7595 | */
7596 | oct = tvb_get_uint8(tvb, offset++);
7597 |
7598 | str = try_val_to_str_idx_ext((uint32_t) oct, &gsm_a_bssmap_msg_strings_ext, &idx);
7599 |
7600 | if (sccp_msg_p && !sccp_msg_p->data.co.label) {
7601 | sccp_msg_p->data.co.label = val_to_str_ext(wmem_file_scope(), (uint32_t)oct,
7602 | &gsm_a_bssmap_msg_strings_ext,
7603 | "BSSMAP (0x%02x)");
7604 | }
7605 |
7606 | /*
7607 | * create the protocol tree
7608 | */
7609 | /* The first two conditions are actually the same, i.e. if str != NULL,
7610 | * idx >= 0, but checking idx makes it obvious we won' t use a potentially
7611 | * negative idx in the else case.
7612 | */
7613 | if (str == NULL((void*)0) || idx < 0 || idx >= NUM_GSM_BSSMAP_MSG(int)(sizeof (gsm_a_bssmap_msg_strings) / sizeof (gsm_a_bssmap_msg_strings )[0]))
7614 | {
7615 | bssmap_item =
7616 | proto_tree_add_protocol_format(tree, proto_a_bssmap, tvb, 0, len,
7617 | "GSM A-I/F BSSMAP - Unknown BSSMAP Message Type (0x%02x)",
7618 | oct);
7619 |
7620 | bssmap_tree = proto_item_add_subtree(bssmap_item, ett_bssmap_msg);
7621 | }
7622 | else
7623 | {
7624 | bssmap_item =
7625 | proto_tree_add_protocol_format(tree, proto_a_bssmap, tvb, 0, -1,
7626 | "GSM A-I/F BSSMAP - %s",
7627 | str);
7628 |
7629 | bssmap_tree = proto_item_add_subtree(bssmap_item, ett_gsm_bssmap_msg[idx]);
7630 |
7631 | col_append_fstr(pinfo->cinfo, COL_INFO, "%s ", str);
7632 |
7633 | /*
7634 | * add BSSMAP message name
7635 | */
7636 | proto_tree_add_uint_format(bssmap_tree, hf_gsm_a_bssmap_msg_type,
7637 | tvb, saved_offset, 1, oct, "Message Type %s",str);
7638 | }
7639 |
7640 | tap_p->pdu_type = GSM_A_PDU_TYPE_BSSMAP0;
7641 | tap_p->message_type = oct;
7642 |
7643 | tap_queue_packet(gsm_a_tap, pinfo, tap_p);
7644 |
7645 | if (str == NULL((void*)0)) return len;
7646 |
7647 | if ((len - offset) <= 0) return len;
7648 |
7649 | /*
7650 | * decode elements
7651 | */
7652 | if (idx < 0 || idx >= NUM_BSSMAP_MSG_FCNS(int)(sizeof (bssmap_msg_fcn) / sizeof (bssmap_msg_fcn)[0]) || bssmap_msg_fcn[idx] == NULL((void*)0)) {
7653 | proto_tree_add_bytes_format(bssmap_tree, hf_gsm_a_bssmap_message_elements,
7654 | tvb, offset, len - offset, NULL((void*)0), "Message Elements");
7655 | }else{
7656 | if (sccp_msg_p && ((sccp_msg_p->data.co.assoc->app_info & 0xCD00) == 0xCD00)) {
7657 | cell_discriminator = sccp_msg_p->data.co.assoc->app_info & 0xFF;
7658 | }else{
7659 | cell_discriminator = 0xFF;
7660 | }
7661 | (*bssmap_msg_fcn[idx])(tvb, bssmap_tree, pinfo, offset, len - offset);
7662 | if (sccp_msg_p) {
7663 | sccp_msg_p->data.co.assoc->app_info = cell_discriminator | 0xCDF0;
7664 | }
7665 | }
7666 | g_tree = NULL((void*)0);
7667 | return len;
7668 | }
7669 |
7670 | /* Register the protocol with Wireshark */
7671 | void
7672 | proto_register_gsm_a_bssmap(void)
7673 | {
7674 | unsigned i;
7675 | unsigned last_offset;
7676 |
7677 | /* Setup list of header fields */
7678 |
7679 | static hf_register_info hf[] =
7680 | {
7681 | { &hf_gsm_a_bssmap_msg_type,
7682 | { "BSSMAP Message Type", "gsm_a.bssmap.msgtype",
7683 | FT_UINT8, BASE_HEX|BASE_EXT_STRING0x00000200, &gsm_a_bssmap_msg_strings_ext, 0x0,
7684 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7685 | },
7686 | { &hf_gsm_a_bssmap_elem_id,
7687 | { "Element ID", "gsm_a.bssmap.elem_id",
7688 | FT_UINT8, BASE_HEX, NULL((void*)0), 0,
7689 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7690 | },
7691 | { &hf_gsm_a_bssmap_field_elem_id,
7692 | { "Field Element ID", "gsm_a.bssmap.field_elem_id",
7693 | FT_UINT8, BASE_HEX, VALS(bssmap_field_element_ids)((0 ? (const struct _value_string*)0 : ((bssmap_field_element_ids )))), 0,
7694 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7695 | },
7696 | { &hf_gsm_a_bssmap_field_elem_id_len,
7697 | { "Length", "gsm_a.bssmap.field_elem_id_len",
7698 | FT_UINT8, BASE_DEC, NULL((void*)0), 0,
7699 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7700 | },
7701 | { &hf_gsm_a_bssmap_cell_ci,
7702 | { "Cell CI", "gsm_a.bssmap.cell_ci",
7703 | FT_UINT16, BASE_HEX_DEC, 0, 0x0,
7704 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7705 | },
7706 | { &hf_gsm_a_bssmap_cell_lac,
7707 | { "Cell LAC", "gsm_a.bssmap.cell_lac",
7708 | FT_UINT16, BASE_HEX_DEC, 0, 0x0,
7709 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7710 | },
7711 | { &hf_gsm_a_bssmap_sac,
7712 | { "SAC", "gsm_a.bssmap.sac",
7713 | FT_UINT16, BASE_HEX, 0, 0x0,
7714 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7715 | },
7716 | { &hf_gsm_a_bssmap_dlci_cc,
7717 | { "Control Channel", "gsm_a.bssmap.dlci.cc",
7718 | FT_UINT8, BASE_HEX, VALS(bssap_cc_values)((0 ? (const struct _value_string*)0 : ((bssap_cc_values)))), 0xc0,
7719 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0)}
7720 | },
7721 | { &hf_gsm_a_bssmap_dlci_spare,
7722 | { "Spare", "gsm_a.bssmap.dlci.spare",
7723 | FT_UINT8, BASE_HEX, NULL((void*)0), 0x38,
7724 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0)}
7725 | },
7726 | { &hf_gsm_a_bssmap_dlci_sapi,
7727 | { "SAPI", "gsm_a.bssmap.dlci.sapi",
7728 | FT_UINT8, BASE_HEX, VALS(bssap_sapi_values)((0 ? (const struct _value_string*)0 : ((bssap_sapi_values))) ), 0x07,
7729 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0)}
7730 | },
7731 | { &hf_gsm_a_bssmap_cause,
7732 | { "BSSMAP Cause", "gsm_a.bssmap.cause",
7733 | FT_UINT8, BASE_HEX|BASE_RANGE_STRING0x00000100, RVALS(gsm_a_bssap_cause_rvals)((0 ? (const struct _range_string*)0 : ((gsm_a_bssap_cause_rvals )))), 0x7F,
7734 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7735 | },
7736 | { &hf_gsm_a_bssmap_be_cell_id_disc,
7737 | { "Cell identification discriminator","gsm_a.bssmap.be.cell_id_disc",
7738 | FT_UINT8,BASE_DEC|BASE_EXT_STRING0x00000200, &gsm_a_be_cell_id_disc_vals_ext, 0x0f,
7739 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7740 | },
7741 | { &hf_gsm_a_bssmap_pci,
7742 | { "Preemption Capability indicator(PCI)","gsm_a.bssmap.pci",
7743 | FT_BOOLEAN,8, TFS(&bssmap_pci_value)((0 ? (const struct true_false_string*)0 : ((&bssmap_pci_value )))), 0x40,
7744 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7745 | },
7746 | { &hf_gsm_a_bssmap_qa,
7747 | { "Queuing Allowed Indicator(QA)","gsm_a.bssmap.qa",
7748 | FT_BOOLEAN,8, TFS(&tfs_allowed_not_allowed)((0 ? (const struct true_false_string*)0 : ((&tfs_allowed_not_allowed )))), 0x02,
7749 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7750 | },
7751 | { &hf_gsm_a_bssmap_pvi,
7752 | { "Preemption Vulnerability Indicator(PVI)","gsm_a.bssmap.pvi",
7753 | FT_BOOLEAN,8, TFS(&bssmap_pvi_value)((0 ? (const struct true_false_string*)0 : ((&bssmap_pvi_value )))), 0x01,
7754 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7755 | },
7756 | { &hf_gsm_a_bssmap_interference_bands,
7757 | { "Acceptable interference bands","gsm_a.bssmap.interference_bands",
7758 | FT_UINT8, BASE_HEX, NULL((void*)0), 0x1f,
7759 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7760 | },
7761 | { &hf_gsm_a_bssmap_lsa_only,
7762 | { "LSA only","gsm_a.bssmap.lsa_only",
7763 | FT_BOOLEAN,8, TFS(&bssmap_lsa_only_value)((0 ? (const struct true_false_string*)0 : ((&bssmap_lsa_only_value )))), 0x01,
7764 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7765 | },
7766 | { &hf_gsm_a_bssmap_act,
7767 | { "Active mode support","gsm_a.bssmap.act",
7768 | FT_BOOLEAN,8, NULL((void*)0), 0x20,
7769 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7770 | },
7771 | { &hf_gsm_a_bssmap_pref,
7772 | { "Preferential access","gsm_a.bssmap.pref",
7773 | FT_BOOLEAN,8, NULL((void*)0), 0x10,
7774 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7775 | },
7776 | { &hf_gsm_a_bssmap_lsa_inf_prio,
7777 | { "Priority","gsm_a.bssmap.lsa_inf_prio",
7778 | FT_UINT8,BASE_DEC, NULL((void*)0), 0x0f,
7779 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7780 | },
7781 | { &hf_gsm_a_bssmap_seq_len,
7782 | { "Sequence Length","gsm_a.bssmap.seq_len",
7783 | FT_UINT8,BASE_DEC, NULL((void*)0), 0xf0,
7784 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7785 | },
7786 | { &hf_gsm_a_bssmap_seq_no,
7787 | { "Sequence Number","gsm_a.bssmap.seq_no",
7788 | FT_UINT8,BASE_DEC, NULL((void*)0), 0xf,
7789 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7790 | },
7791 | { &hf_gsm_a_bssap_cell_id_list_seg_cell_id_disc,
7792 | { "Cell identification discriminator","gsm_a.bssmap.cell_id_list_seg_cell_id_disc",
7793 | FT_UINT8,BASE_DEC, VALS(gsm_a_bssap_cell_id_list_seg_cell_id_disc_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssap_cell_id_list_seg_cell_id_disc_vals )))), 0xf,
7794 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7795 | },
7796 | { &hf_gsm_a_bssap_res_ind_method,
7797 | { "Resource indication method","gsm_a.bssmap.res_ind_method",
7798 | FT_UINT8,BASE_DEC, VALS(gsm_a_bssap_resource_indication_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssap_resource_indication_vals )))), 0xf,
7799 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7800 | },
7801 | { &hf_gsm_a_bssap_cic_list_range,
7802 | { "Range","gsm_a.bssmap.cic_list_range",
7803 | FT_UINT8, BASE_DEC, NULL((void*)0), 0,
7804 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7805 | },
7806 | { &hf_gsm_a_bssap_cic_list_status,
7807 | { "Status","gsm_a.bssmap.cic_list_status",
7808 | FT_BYTES, BASE_NONE, NULL((void*)0), 0,
7809 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7810 | },
7811 | { &hf_gsm_a_bssap_diag_error_pointer,
7812 | { "Error pointer","gsm_a.bssmap.diag_error_pointer",
7813 | FT_UINT16, BASE_HEX, NULL((void*)0), 0,
7814 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7815 | },
7816 | { &hf_gsm_a_bssap_diag_msg_rcv,
7817 | { "Message received","gsm_a.bssmap.diag_msg_rcv",
7818 | FT_BYTES, BASE_NONE, NULL((void*)0), 0,
7819 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7820 | },
7821 | { &hf_gsm_a_bssmap_ch_mode,
7822 | { "Channel mode","gsm_a.bssmap.cch_mode",
7823 | FT_UINT8,BASE_DEC, VALS(gsm_a_bssmap_ch_mode_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_ch_mode_vals )))), 0xf0,
7824 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7825 | },
7826 | { &hf_gsm_a_bssmap_cur_ch_mode,
7827 | { "Channel Mode", "gsm_a.bssmap.fe_cur_chan_type2.chan_mode",
7828 | FT_UINT8, BASE_HEX, VALS(chan_mode_vals)((0 ? (const struct _value_string*)0 : ((chan_mode_vals)))), 0xf0,
7829 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7830 | },
7831 | { &hf_gsm_a_bssmap_channel,
7832 | { "Channel","gsm_a.bssmap.channel",
7833 | FT_UINT8,BASE_DEC, VALS(gsm_a_bssmap_channel_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_channel_vals )))), 0x0f,
7834 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7835 | },
7836 | { &hf_gsm_a_bssmap_trace_trigger_id,
7837 | { "Priority Indication","gsm_a.bssmap.trace_trigger_id",
7838 | FT_STRING, BASE_NONE, NULL((void*)0), 0x0,
7839 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7840 | },
7841 | { &hf_gsm_a_bssmap_trace_priority_indication,
7842 | { "Priority Indication","gsm_a.bssmap.trace_priority_indication",
7843 | FT_UINT8,BASE_DEC, NULL((void*)0), 0x00,
7844 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7845 | },
7846 | { &hf_gsm_a_bssmap_trace_bss_record_type,
7847 | { "BSS Record Type","gsm_a.bssmap.bss_record__type",
7848 | FT_UINT8,BASE_DEC, VALS(gsm_a_bssmap_trace_bss_record_type_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_trace_bss_record_type_vals )))), 0x00,
7849 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7850 | },
7851 | { &hf_gsm_a_bssmap_trace_msc_record_type,
7852 | { "MSC Record Type","gsm_a.bssmap.msc_record_type",
7853 | FT_UINT8,BASE_DEC, VALS(gsm_a_bssmap_trace_msc_record_type_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_trace_msc_record_type_vals )))), 0x00,
7854 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7855 | },
7856 | { &hf_gsm_a_bssmap_trace_invoking_event,
7857 | { "Invoking Event","gsm_a.bssmap.trace_invoking_event",
7858 | FT_UINT8,BASE_DEC, VALS(gsm_a_bssmap_trace_invoking_event_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_trace_invoking_event_vals )))), 0x0,
7859 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7860 | },
7861 | { &hf_gsm_a_bssmap_trace_reference,
7862 | { "Trace Reference","gsm_a.bssmap.trace_id",
7863 | FT_UINT16,BASE_DEC, NULL((void*)0), 0x0,
7864 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7865 | },
7866 | { &hf_gsm_a_bssmap_trace_omc_id,
7867 | { "OMC ID","gsm_a.bssmap.trace_omc_id",
7868 | FT_STRING, BASE_NONE, NULL((void*)0), 0x0,
7869 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7870 | },
7871 | { &hf_gsm_a_bssmap_be_rnc_id,
7872 | { "RNC-ID","gsm_a.bssmap.be.rnc_id",
7873 | FT_UINT16,BASE_DEC, NULL((void*)0), 0x0,
7874 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7875 | },
7876 | { &hf_gsm_a_bssmap_apdu_protocol_id,
7877 | { "Protocol ID", "gsm_a.bssmap.apdu_protocol_id",
7878 | FT_UINT8, BASE_DEC, VALS(gsm_a_apdu_protocol_id_strings)((0 ? (const struct _value_string*)0 : ((gsm_a_apdu_protocol_id_strings )))), 0x0,
7879 | "APDU embedded protocol id", HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7880 | },
7881 | { &hf_gsm_a_bssmap_segmentation_spare_bits ,
7882 | { "Spare bits", "gsm_a.bssmap.segmentation_spare_bits",
7883 | FT_UINT8, BASE_HEX, NULL((void*)0), 0xe0,
7884 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7885 | },
7886 | { &hf_gsm_a_bssmap_segmentation_info,
7887 | { "Segmentation indicator", "gsm_a.bssmap.segmentation_indicator",
7888 | FT_BOOLEAN, 8, TFS(&tfs_gsm_a_bssmap_segmented)((0 ? (const struct true_false_string*)0 : ((&tfs_gsm_a_bssmap_segmented )))), 0x10,
7889 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7890 | },
7891 | { &hf_gsm_a_bssmap_segment_number,
7892 | { "Segment Number", "gsm_a.bssmap.segment_number",
7893 | FT_UINT8, BASE_DEC, NULL((void*)0), 0x0f,
7894 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7895 | },
7896 | { &hf_gsm_a_bssmap_msg_id,
7897 | { "Message ID", "gsm_a.bssmap.msg_id",
7898 | FT_UINT16, BASE_DEC, NULL((void*)0), 0x0,
7899 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7900 | },
7901 | { &hf_gsm_a_bssmap_periodicity,
7902 | { "Periodicity", "gsm_a.bssmap.periodicity",
7903 | FT_UINT8, BASE_DEC, NULL((void*)0), 0x0,
7904 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7905 | },
7906 | { &hf_gsm_a_bssmap_sm,
7907 | { "Subsequent Mode","gsm_a.bssmap.sm",
7908 | FT_BOOLEAN,8, NULL((void*)0), 0x02,
7909 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7910 | },
7911 | { &hf_gsm_a_bssmap_tarr,
7912 | { "Total Accessible Resource Requested","gsm_a.bssmap.tarr",
7913 | FT_BOOLEAN,8, NULL((void*)0), 0x01,
7914 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7915 | },
7916 | { &hf_gsm_a_bssmap_tot_no_of_fullr_ch,
7917 | { "Total number of accessible full rate channels", "gsm_a.bssmap.tot_no_of_fullr_ch",
7918 | FT_UINT16, BASE_DEC, NULL((void*)0), 0x0,
7919 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7920 | },
7921 | { &hf_gsm_a_bssmap_tot_no_of_hr_ch,
7922 | { "Total number of accessible half rate channels", "gsm_a.bssmap.tot_no_of_hr_ch",
7923 | FT_UINT16, BASE_DEC, NULL((void*)0), 0x0,
7924 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7925 | },
7926 | { &hf_gsm_a_bssmap_lsa_id,
7927 | { "Identification of Localised Service Area", "gsm_a.bssmap.lsa_id",
7928 | FT_UINT24, BASE_HEX, NULL((void*)0), 0x0,
7929 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7930 | },
7931 | { &hf_gsm_a_bssmap_ep,
7932 | { "EP", "gsm_a.bssmap.ep",
7933 | FT_UINT8, BASE_DEC, NULL((void*)0), 0x01,
7934 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7935 | },
7936 | { &hf_gsm_a_bssmap_smi,
7937 | { "Subsequent Modification Indication(SMI)", "gsm_a.bssmap.smi",
7938 | FT_UINT8, BASE_DEC, VALS(gsm_a_bssmap_smi_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_smi_vals )))), 0x0f,
7939 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7940 | },
7941 | { &hf_gsm_a_bssmap_lcs_pri,
7942 | { "Periodicity", "gsm_a.bssmap.lcs_pri",
7943 | FT_UINT8, BASE_DEC, VALS(lcs_priority_vals)((0 ? (const struct _value_string*)0 : ((lcs_priority_vals))) ), 0x0,
7944 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7945 | },
7946 | { &hf_gsm_a_bssmap_num_ms,
7947 | { "Number of handover candidates", "gsm_a.bssmap.num_ms",
7948 | FT_UINT8, BASE_DEC,NULL((void*)0), 0x0,
7949 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7950 | },
7951 | { &hf_gsm_a_bssmap_talker_pri,
7952 | { "Priority", "gsm_a.bssmap.talker_pri",
7953 | FT_UINT8, BASE_DEC,VALS(gsm_a_bssmap_talker_pri_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_talker_pri_vals )))), 0x03,
7954 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7955 | },
7956 | { &hf_gsm_a_bssmap_rr_mode,
7957 | { "RR mode", "gsm_a.bssmap.rr_mode",
7958 | FT_UINT8, BASE_DEC, VALS(gsm_a_bssmap_rr_mode_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_rr_mode_vals )))), 0xc0,
7959 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7960 | },
7961 | { &hf_gsm_a_bssmap_group_cipher_key_nb,
7962 | { "Group cipher key number", "gsm_a.bssmap.group_cipher_key_nb",
7963 | FT_UINT8, BASE_DEC, VALS(gsm_a_bssmap_group_cipher_key_nb_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_group_cipher_key_nb_vals )))), 0x3c,
7964 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7965 | },
7966 | { &hf_gsm_a_bssmap_vgcs_vbs_cell_status,
7967 | { "Status", "gsm_a.bssmap.vgcs_vbs_cell_status",
7968 | FT_UINT8, BASE_DEC, VALS(gsm_a_bssmap_vgcs_vbs_cell_status_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_vgcs_vbs_cell_status_vals )))), 0x07,
7969 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7970 | },
7971 | { &hf_gsm_a_bssmap_paging_cause,
7972 | { "Paging Cause", "gsm_a.bssmap.paging_cause",
7973 | FT_UINT8, BASE_DEC,VALS(gsm_a_bssmap_paging_cause_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_paging_cause_vals )))), 0x06,
7974 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7975 | },
7976 | { &hf_gsm_a_bssmap_paging_inf_flg,
7977 | { "VGCS/VBS flag","gsm_a.bssmap.paging_inf_flg",
7978 | FT_BOOLEAN,8, TFS(&bssmap_paging_inf_flg_value)((0 ? (const struct true_false_string*)0 : ((&bssmap_paging_inf_flg_value )))), 0x01,
7979 | "If 1, a member of a VGCS/VBS-group", HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7980 | },
7981 | { &hf_gsm_a_bssmap_serv_ho_inf,
7982 | { "Service Handover information", "gsm_a.bssmap.serv_ho_inf",
7983 | FT_UINT8, BASE_DEC, VALS(gsm_a_bssmap_serv_ho_inf_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_serv_ho_inf_vals )))), 0x07,
7984 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7985 | },
7986 | { &hf_gsm_a_bssmap_max_nb_traffic_chan,
7987 | { "Maximum Number of Traffic Channels", "gsm_a.bssmap.max_nb_traffic_chan",
7988 | FT_UINT8, BASE_DEC, VALS(gsm_a_max_nb_traffic_chan_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_max_nb_traffic_chan_vals )))), 0x07,
7989 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7990 | },
7991 | { &hf_gsm_a_bssmap_acceptable_chan_coding_bit5,
7992 | { "TCH/F43.2", "gsm_a.bssmap.acceptable_chan_coding_bit5",
7993 | FT_BOOLEAN, 8, TFS(&gsm_a_bssmap_accept_not_accept_vals)((0 ? (const struct true_false_string*)0 : ((&gsm_a_bssmap_accept_not_accept_vals )))), 0x10,
7994 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
7995 | },
7996 | { &hf_gsm_a_bssmap_acceptable_chan_coding_bit4,
7997 | { "TCH/F43.2", "gsm_a.bssmap.acceptable_chan_coding_bit4",
7998 | FT_BOOLEAN, 8, TFS(&gsm_a_bssmap_accept_not_accept_vals)((0 ? (const struct true_false_string*)0 : ((&gsm_a_bssmap_accept_not_accept_vals )))), 0x08,
7999 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8000 | },
8001 | { &hf_gsm_a_bssmap_acceptable_chan_coding_bit3,
8002 | { "TCH/F43.2", "gsm_a.bssmap.acceptable_chan_coding_bit3",
8003 | FT_BOOLEAN, 8, TFS(&gsm_a_bssmap_accept_not_accept_vals)((0 ? (const struct true_false_string*)0 : ((&gsm_a_bssmap_accept_not_accept_vals )))), 0x04,
8004 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8005 | },
8006 | { &hf_gsm_a_bssmap_acceptable_chan_coding_bit2,
8007 | { "TCH/F43.2", "gsm_a.bssmap.acceptable_chan_coding_bit2",
8008 | FT_BOOLEAN, 8, TFS(&gsm_a_bssmap_accept_not_accept_vals)((0 ? (const struct true_false_string*)0 : ((&gsm_a_bssmap_accept_not_accept_vals )))), 0x02,
8009 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8010 | },
8011 | { &hf_gsm_a_bssmap_acceptable_chan_coding_bit1,
8012 | { "TCH/F43.2", "gsm_a.bssmap.acceptable_chan_coding_bit1",
8013 | FT_BOOLEAN, 8, TFS(&gsm_a_bssmap_accept_not_accept_vals)((0 ? (const struct true_false_string*)0 : ((&gsm_a_bssmap_accept_not_accept_vals )))), 0x01,
8014 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8015 | },
8016 | { &hf_gsm_a_bssmap_allowed_data_rate_bit8,
8017 | { "43.5 kbit/s (TCH/F43.2)", "gsm_a.bssmap.allowed_data_rate_bit8",
8018 | FT_BOOLEAN, 8, TFS(&tfs_allowed_not_allowed)((0 ? (const struct true_false_string*)0 : ((&tfs_allowed_not_allowed )))), 0x80,
8019 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8020 | },
8021 | { &hf_gsm_a_bssmap_allowed_data_rate_bit7,
8022 | { "32.0 kbit/s (TCH/F32.0)", "gsm_a.bssmap.allowed_data_rate_bit7",
8023 | FT_BOOLEAN, 8, TFS(&tfs_allowed_not_allowed)((0 ? (const struct true_false_string*)0 : ((&tfs_allowed_not_allowed )))), 0x40,
8024 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8025 | },
8026 | { &hf_gsm_a_bssmap_allowed_data_rate_bit6,
8027 | { "29.0 kbit/s (TCH/F28.8)", "gsm_a.bssmap.allowed_data_rate_bit6",
8028 | FT_BOOLEAN, 8, TFS(&tfs_allowed_not_allowed)((0 ? (const struct true_false_string*)0 : ((&tfs_allowed_not_allowed )))), 0x20,
8029 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8030 | },
8031 | { &hf_gsm_a_bssmap_allowed_data_rate_bit5,
8032 | { "14.5/14.4 kbit/s (TCH/F14.4)", "gsm_a.bssmap.allowed_data_rate_bit5",
8033 | FT_BOOLEAN, 8, TFS(&tfs_allowed_not_allowed)((0 ? (const struct true_false_string*)0 : ((&tfs_allowed_not_allowed )))), 0x10,
8034 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8035 | },
8036 | { &hf_gsm_a_bssmap_allowed_data_rate_bit4,
8037 | { "12.0/9.6 kbit/s (TCH F/9.6)", "gsm_a.bssmap.allowed_data_rate_bit4",
8038 | FT_BOOLEAN, 8, TFS(&tfs_allowed_not_allowed)((0 ? (const struct true_false_string*)0 : ((&tfs_allowed_not_allowed )))), 0x08,
8039 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8040 | },
8041 | { &hf_gsm_a_bssmap_vstk_rand,
8042 | { "VSTK_RAND", "gsm_a.bssmap.vstk_rand",
8043 | FT_UINT64, BASE_HEX, NULL((void*)0), 0,
8044 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8045 | },
8046 | { &hf_gsm_a_bssmap_vstk,
8047 | { "VSTK", "gsm_a.bssmap.vstk",
8048 | FT_BYTES, BASE_NONE, NULL((void*)0), 0,
8049 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8050 | },
8051 |
8052 | { &hf_gsm_a_bssmap_spare_bits,
8053 | { "Spare bit(s)", "gsm_a.bssmap.spare_bits",
8054 | FT_UINT8, BASE_HEX, NULL((void*)0), 0x0,
8055 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8056 | },
8057 | { &hf_gsm_a_bssmap_tpind,
8058 | { "Talker priority indicator (TP Ind)","gsm_a.bssmap.tpind",
8059 | FT_BOOLEAN,8, TFS(&gsm_bssmap_tpind_vals)((0 ? (const struct true_false_string*)0 : ((&gsm_bssmap_tpind_vals )))), 0x01,
8060 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8061 | },
8062 | { &hf_gsm_a_bssmap_asind_b2,
8063 | { "A-interface resource sharing indicator (AS Ind) bit 2","gsm_a.bssmap.asind_b2",
8064 | FT_BOOLEAN,8, TFS(&gsm_bssmap_asind_b2_vals)((0 ? (const struct true_false_string*)0 : ((&gsm_bssmap_asind_b2_vals )))), 0x02,
8065 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8066 | },
8067 | { &hf_gsm_a_bssmap_asind_b3,
8068 | { "A-interface resource sharing indicator (AS Ind) bit 3","gsm_a.bssmap.asind_b3",
8069 | FT_BOOLEAN,8, TFS(&gsm_bssmap_asind_b3_vals)((0 ? (const struct true_false_string*)0 : ((&gsm_bssmap_asind_b3_vals )))), 0x04,
8070 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8071 | },
8072 | { &hf_gsm_a_bssmap_bss_res,
8073 | { "Group or broadcast call re-establishment by the BSS indicator","gsm_a.bssmap.bss_res",
8074 | FT_BOOLEAN,8, TFS(&gsm_bssmap_bss_res_vals)((0 ? (const struct true_false_string*)0 : ((&gsm_bssmap_bss_res_vals )))), 0x08,
8075 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8076 | },
8077 | { &hf_gsm_a_bssmap_tcp,
8078 | { "Talker Channel Parameter (TCP)","gsm_a.bssmap.tcp",
8079 | FT_BOOLEAN,8, TFS(&gsm_bssmap_bss_tcp_vals)((0 ? (const struct true_false_string*)0 : ((&gsm_bssmap_bss_tcp_vals )))), 0x10,
8080 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8081 | },
8082 | { &hf_gsm_a_bssmap_filler_bits,
8083 | { "Filler Bits","gsm_a.bssmap.filler_bits",
8084 | FT_UINT8, BASE_DEC,NULL((void*)0), 0x07,
8085 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8086 | },
8087 | { &hf_gsm_a_bssmap_method,
8088 | { "Method","gsm_a.bssmap.method",
8089 | FT_UINT8, BASE_DEC,VALS(gsm_a_bssmap_method_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_method_vals )))), 0xc0,
8090 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8091 | },
8092 | { &hf_gsm_a_bssmap_ganss_id,
8093 | { "GANSS Id","gsm_a.bssmap.ganss_id",
8094 | FT_UINT8, BASE_DEC,VALS(gsm_a_bssmap_ganss_id_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_ganss_id_vals )))), 0x38,
8095 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8096 | },
8097 | { &hf_gsm_a_bssmap_usage,
8098 | { "Usage","gsm_a.bssmap.usage",
8099 | FT_UINT8, BASE_DEC,VALS(gsm_a_bssmap_usage_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_usage_vals )))), 0x07,
8100 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8101 | },
8102 | { &hf_gsm_a_bssmap_data_id,
8103 | { "Data Identity","gsm_a.bssmap.data_id",
8104 | FT_UINT8, BASE_DEC_HEX, NULL((void*)0), 0,
8105 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8106 | },
8107 | { &hf_gsm_a_bssmap_bt_ind,
8108 | { "BT Ind","gsm_a.bssmap.bt_ind",
8109 | FT_BOOLEAN, 8, TFS(&gsm_a_bssmap_bt_ind_val)((0 ? (const struct true_false_string*)0 : ((&gsm_a_bssmap_bt_ind_val )))), 0x01,
8110 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8111 | },
8112 | { &hf_gsm_a_bssmap_aoip_trans_ipv4,
8113 | { "Transport Layer Address (IPv4)","gsm_a.bssmap.aoip_trans_ipv4",
8114 | FT_IPv4, BASE_NONE, NULL((void*)0), 0x0,
8115 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8116 | },
8117 | { &hf_gsm_a_bssmap_aoip_trans_ipv6,
8118 | { "Transport Layer Address (IPv6)","gsm_a.bssmap.aoip_trans_ipv6",
8119 | FT_IPv6, BASE_NONE,NULL((void*)0), 0x0,
8120 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8121 | },
8122 | { &hf_gsm_a_bssmap_aoip_trans_port,
8123 | { "UDP Port","gsm_a.bssmap.aoip_trans_port",
8124 | FT_UINT16, BASE_PT_UDP, NULL((void*)0), 0x0,
8125 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8126 | },
8127 | { &hf_gsm_a_bssmap_fi,
8128 | { "FI(Full IP)","gsm_a.bssmap.fi",
8129 | FT_BOOLEAN,8, TFS(&bssmap_fi_vals)((0 ? (const struct true_false_string*)0 : ((&bssmap_fi_vals )))), 0x80,
8130 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8131 | },
8132 | { &hf_gsm_a_bssmap_pi,
8133 | { "PI","gsm_a.bssmap.pi",
8134 | FT_BOOLEAN,8, TFS(&bssmap_pi_vals)((0 ? (const struct true_false_string*)0 : ((&bssmap_pi_vals )))), 0x40,
8135 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8136 | },
8137 | { &hf_gsm_a_bssmap_pt,
8138 | { "PT","gsm_a.bssmap.pt",
8139 | FT_BOOLEAN,8, TFS(&bssmap_pt_vals)((0 ? (const struct true_false_string*)0 : ((&bssmap_pt_vals )))), 0x20,
8140 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8141 | },
8142 | { &hf_gsm_a_bssmap_tf,
8143 | { "TF","gsm_a.bssmap.tf",
8144 | FT_BOOLEAN,8, TFS(&bssmap_tf_vals)((0 ? (const struct true_false_string*)0 : ((&bssmap_tf_vals )))), 0x10,
8145 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8146 | },
8147 | { &hf_gsm_a_bssap_speech_codec,
8148 | { "Codec Type","gsm_a.bssmap.speech_codec",
8149 | FT_UINT8, BASE_DEC|BASE_EXT_STRING0x00000200, &bssap_speech_codec_values_ext, 0x0f,
8150 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8151 | },
8152 | { &hf_gsm_a_bssap_extended_codec,
8153 | { "Extended Codec Type","gsm_a.bssmap.extended_codec",
8154 | FT_UINT8, BASE_DEC, VALS(bssap_extended_codec_values)((0 ? (const struct _value_string*)0 : ((bssap_extended_codec_values )))), 0x0,
8155 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8156 | },
8157 | { &hf_gsm_a_bssap_extended_codec_r2,
8158 | { "Redundancy Level 2","gsm_a.bssmap.r2",
8159 | FT_BOOLEAN,8, TFS(&tfs_supported_not_supported)((0 ? (const struct true_false_string*)0 : ((&tfs_supported_not_supported )))), 0x80,
8160 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8161 | },
8162 | { &hf_gsm_a_bssap_extended_codec_r3,
8163 | { "Redundancy Level 3","gsm_a.bssmap.r3",
8164 | FT_BOOLEAN,8, TFS(&tfs_supported_not_supported)((0 ? (const struct true_false_string*)0 : ((&tfs_supported_not_supported )))), 0x40,
8165 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8166 | },
8167 | { &hf_gsm_a_bssmap_fi2,
8168 | { "FI(Full IP)","gsm_a.bssmap.fi2",
8169 | FT_BOOLEAN,8, TFS(&bssmap_fi2_vals)((0 ? (const struct true_false_string*)0 : ((&bssmap_fi2_vals )))), 0x80,
8170 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8171 | },
8172 | { &hf_gsm_a_bssmap_pi2,
8173 | { "PI","gsm_a.bssmap.pi2",
8174 | FT_BOOLEAN,8, TFS(&bssmap_pi2_vals)((0 ? (const struct true_false_string*)0 : ((&bssmap_pi2_vals )))), 0x40,
8175 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8176 | },
8177 | { &hf_gsm_a_bssmap_pt2,
8178 | { "PT","gsm_a.bssmap.pt2",
8179 | FT_BOOLEAN,8, TFS(&bssmap_pt2_vals)((0 ? (const struct true_false_string*)0 : ((&bssmap_pt2_vals )))), 0x20,
8180 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8181 | },
8182 | { &hf_gsm_a_bssmap_tf2,
8183 | { "TF","gsm_a.bssmap.tf2",
8184 | FT_BOOLEAN,8, TFS(&bssmap_tf2_vals)((0 ? (const struct true_false_string*)0 : ((&bssmap_tf2_vals )))), 0x10,
8185 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8186 | },
8187 | { &hf_gsm_a_bssmap_call_id,
8188 | { "Call Identifier","gsm_a.bssmap.callid",
8189 | FT_UINT32, BASE_DEC,NULL((void*)0), 0x0,
8190 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8191 | },
8192 | { &hf_gsm_a_bssmap_spare,
8193 | { "Spare", "gsm_a.bssmap.spare",
8194 | FT_UINT8, BASE_HEX, NULL((void*)0), 0x0,
8195 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0)}
8196 | },
8197 | { &hf_gsm_a_bssmap_positioning_data_discriminator,
8198 | { "Positioning Data Discriminator", "gsm_a.bssmap.posData.discriminator",
8199 | FT_UINT8, BASE_HEX, NULL((void*)0), 0x0,
8200 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8201 | },
8202 | { &hf_gsm_a_bssmap_positioning_method,
8203 | { "Positioning method", "gsm_a.bssmap.posData.method",
8204 | FT_UINT8, BASE_HEX, VALS(bssmap_positioning_methods)((0 ? (const struct _value_string*)0 : ((bssmap_positioning_methods )))), 0x0,
8205 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8206 | },
8207 | { &hf_gsm_a_bssmap_positioning_method_usage,
8208 | { "Usage", "gsm_a.bssmap.posData.usage",
8209 | FT_UINT8, BASE_HEX, VALS(bssmap_positioning_methods_usage)((0 ? (const struct _value_string*)0 : ((bssmap_positioning_methods_usage )))), 0x0,
8210 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8211 | },
8212 | { &hf_gsm_a_bssmap_location_type_location_information,
8213 | { "Location Information", "gsm_a.bssmap.locationType.locationInformation",
8214 | FT_UINT8, BASE_HEX, VALS(bssmap_location_information_vals)((0 ? (const struct _value_string*)0 : ((bssmap_location_information_vals )))), 0x0,
8215 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8216 | },
8217 | { &hf_gsm_a_bssmap_location_type_positioning_method,
8218 | { "Positioning Method", "gsm_a.bssmap.locationType.positioningMethod",
8219 | FT_UINT8, BASE_HEX, VALS(bssmap_positioning_method_vals)((0 ? (const struct _value_string*)0 : ((bssmap_positioning_method_vals )))), 0x0,
8220 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8221 | },
8222 | { &hf_gsm_a_bssmap_chan_type_extension,
8223 | { "Extension", "gsm_a.bssmap.chanType.permittedIndicator.extension",
8224 | FT_BOOLEAN, 8, TFS(&bssmap_chan_type_extension_value)((0 ? (const struct true_false_string*)0 : ((&bssmap_chan_type_extension_value )))), 0x80,
8225 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8226 | },
8227 | { &hf_gsm_a_bssmap_cause_extension,
8228 | { "Extension", "gsm_a.bssmap.causeType.extension",
8229 | FT_BOOLEAN, 8, TFS(&bssmap_cause_extension_value)((0 ? (const struct true_false_string*)0 : ((&bssmap_cause_extension_value )))), 0x80,
8230 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8231 | },
8232 | { &hf_gsm_a_bssmap_ass_req,
8233 | { "Assignment Requirement", "gsm_a.bssmap.assignment_requirement",
8234 | FT_UINT8, BASE_HEX, VALS(gsm_a_bssmap_assignment_requirement_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_assignment_requirement_vals )))), 0x0,
8235 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8236 | },
8237 | { &hf_gsm_a_bssmap_emlpp_prio,
8238 | { "eMLPP Priority", "gsm_a.bssmap.emlpp_priority",
8239 | FT_UINT8, BASE_HEX, VALS(gsm_a_bssmap_call_priority_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_call_priority_vals )))), 0x07,
8240 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8241 | },
8242 | { &hf_gsm_a_bssmap_rip,
8243 | { "RIP", "gsm_a.bssmap.rip",
8244 | FT_BOOLEAN, 8, TFS(&gsm_a_bssmap_rip_value)((0 ? (const struct true_false_string*)0 : ((&gsm_a_bssmap_rip_value )))), 0x02,
8245 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8246 | },
8247 | { &hf_gsm_a_bssmap_rtd,
8248 | { "RTD", "gsm_a.bssmap.rtd",
8249 | FT_BOOLEAN, 8, TFS(&gsm_a_bssmap_rtd_value)((0 ? (const struct true_false_string*)0 : ((&gsm_a_bssmap_rtd_value )))), 0x01,
8250 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8251 | },
8252 | { &hf_gsm_a_bssmap_kc128,
8253 | { "Kc128", "gsm_a.bssmap.kc128",
8254 | FT_BYTES, BASE_NONE, NULL((void*)0), 0,
8255 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8256 | },
8257 | { &hf_gsm_a_bssmap_csg_id,
8258 | { "CSG Identity", "gsm_a.bssmap.csg_id",
8259 | FT_UINT32, BASE_DEC, NULL((void*)0), 0,
8260 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8261 | },
8262 | { &hf_gsm_a_bssmap_cell_access_mode,
8263 | { "Cell Access Mode", "gsm_a.bssmap.cell_access_mode",
8264 | FT_BOOLEAN, BASE_NONE, TFS(&gsm_a_bssmap_cell_access_mode_value)((0 ? (const struct true_false_string*)0 : ((&gsm_a_bssmap_cell_access_mode_value )))), 0,
8265 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8266 | },
8267 |
8268 | { &hf_fe_extra_info_prec,
8269 | { "Pre-emption Recommendation", "gsm_a.bssmap.fe_extra_info.prec",
8270 | FT_UINT8, BASE_DEC, VALS(fe_extra_info_prec_vals)((0 ? (const struct _value_string*)0 : ((fe_extra_info_prec_vals )))), 0x01,
8271 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8272 | },
8273 | { &hf_fe_extra_info_lcs,
8274 | { "LCS Information", "gsm_a.bssmap.fe_extra_info.lcs",
8275 | FT_UINT8, BASE_DEC, VALS(fe_extra_info_lcs_vals)((0 ? (const struct _value_string*)0 : ((fe_extra_info_lcs_vals )))), 0x02,
8276 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8277 | },
8278 | { &hf_fe_extra_info_ue_prob,
8279 | { "UE support of UMTS", "gsm_a.bssmap.fe_extra_info.ue_prob",
8280 | FT_UINT8, BASE_DEC, VALS(fe_extra_info_ue_prob_vals)((0 ? (const struct _value_string*)0 : ((fe_extra_info_ue_prob_vals )))), 0x04,
8281 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8282 | },
8283 | { &hf_fe_extra_info_spare,
8284 | { "Extra Information Spare bits", "gsm_a.bssmap.fe_extra_info.spare",
8285 | FT_UINT8, BASE_HEX, NULL((void*)0), 0xf8,
8286 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8287 | },
8288 | { &hf_fe_cur_chan_type2_chan_mode,
8289 | { "Channel Mode", "gsm_a.bssmap.fe_cur_chan_type2.chan_mode",
8290 | FT_UINT8, BASE_HEX, VALS(chan_mode_vals)((0 ? (const struct _value_string*)0 : ((chan_mode_vals)))), 0x0f,
8291 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8292 | },
8293 | { &hf_fe_cur_chan_type2_chan_mode_spare,
8294 | { "Channel Mode Spare bits", "gsm_a.bssmap.fe_cur_chan_type2_chan_mode.spare",
8295 | FT_UINT8, BASE_HEX, NULL((void*)0), 0xf0,
8296 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8297 | },
8298 | { &hf_fe_cur_chan_type2_chan_field,
8299 | { "Channel Field", "gsm_a.bssmap.fe_cur_chan_type2.chan_field",
8300 | FT_UINT8, BASE_HEX, VALS(fe_cur_chan_type2_chan_field_vals)((0 ? (const struct _value_string*)0 : ((fe_cur_chan_type2_chan_field_vals )))),0x0f,
8301 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8302 | },
8303 | { &hf_fe_cur_chan_type2_chan_field_spare,
8304 | { "Channel field Spare bits", "gsm_a.bssmap.fe_cur_chan_type2_chan_field.spare",
8305 | FT_UINT8, BASE_HEX, NULL((void*)0), 0xf0,
8306 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8307 | },
8308 | { &hf_fe_target_radio_cell_info_rxlev_ncell,
8309 | { "RXLEV-NCELL", "gsm_a.bssmap.fe_target_radio_cell_info.rxlev_ncell",
8310 | FT_UINT8, BASE_HEX|BASE_EXT_STRING0x00000200, &gsm_a_rr_rxlev_vals_ext, 0x3f,
8311 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8312 | },
8313 | { &hf_fe_target_radio_cell_info_rxlev_ncell_spare,
8314 | { "RXLEV-NCELL Spare bits", "gsm_a.bssmap.fe_target_radio_cell_info.rxlev_ncell_spare",
8315 | FT_UINT8, BASE_HEX, NULL((void*)0), 0xc0,
8316 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8317 | },
8318 | { &hf_fe_dtm_info_dtm_ind,
8319 | { "DTM indicator", "gsm_a.bssmap.fe_dtm_info.dtm_ind",
8320 | FT_UINT8, BASE_HEX, VALS(gsm_a_bssmap_dtm_info_dtm_ind_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_dtm_info_dtm_ind_vals )))), 0x01,
8321 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8322 | },
8323 | { &hf_fe_dtm_info_sto_ind,
8324 | { "Time Slot Operation indicator", "gsm_a.bssmap.fe_dtm_info.sto_ind",
8325 | FT_UINT8, BASE_HEX, VALS(gsm_a_bssmap_dtm_info_sto_ind_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_dtm_info_sto_ind_vals )))), 0x02,
8326 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8327 | },
8328 | { &hf_fe_dtm_info_egprs_ind,
8329 | { "EGPRS indicator", "gsm_a.bssmap.fe_dtm_info.egprs_ind",
8330 | FT_UINT8, BASE_HEX, VALS(gsm_a_bssmap_dtm_info_egprs_ind_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_dtm_info_egprs_ind_vals )))), 0x04,
8331 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8332 | },
8333 | { &hf_fe_dtm_info_spare_bits,
8334 | { "DTM Info Spare bits", "gsm_a.bssmap.fe_dtm_info.spare_bits",
8335 | FT_UINT8, BASE_HEX, NULL((void*)0), 0xf8,
8336 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8337 | },
8338 | { &hf_fe_cell_load_info_cell_capacity_class,
8339 | { "Cell capacity class", "gsm_a.bssmap.fe_cell_load_info.cell_capacity_class",
8340 | FT_UINT8, BASE_DEC, NULL((void*)0), 0,
8341 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8342 | },
8343 | { &hf_fe_cell_load_info_load_value,
8344 | { "Load value", "gsm_a.bssmap.fe_cell_load_info.load_info",
8345 | FT_UINT8, BASE_DEC, NULL((void*)0), 0,
8346 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8347 | },
8348 | { &hf_fe_cell_load_info_rt_load_value,
8349 | { "Realtime load value", "gsm_a.bssmap.fe_cell_load_info.rt_load_value",
8350 | FT_UINT8, BASE_DEC, NULL((void*)0), 0,
8351 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8352 | },
8353 | { &hf_fe_cell_load_info_nrt_load_information_value,
8354 | { "Non-Realtime load information value", "gsm_a.bssmap.fe_cell_load_info.nrt_load_info_value",
8355 | FT_UINT8, BASE_HEX, VALS(gsm_a_bssmap_cell_load_nrt_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_cell_load_nrt_vals )))), 0,
8356 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8357 | },
8358 | { &hf_fe_ps_indication,
8359 | { "PS Indication", "gsm_a.bssmap.fe_ps_indication.value",
8360 | FT_UINT8, BASE_HEX, NULL((void*)0), 0,
8361 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8362 | },
8363 | { &hf_fe_dtm_ho_command_ind_spare,
8364 | { "Spare octet", "gsm_a.bssmap.fe_dtm_ho_command_ind.spare",
8365 | FT_UINT8, BASE_HEX, NULL((void*)0), 0,
8366 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8367 | },
8368 | { &hf_gsm_a_bssmap_speech_data_ind,
8369 | { "Speech/Data Indicator", "gsm_a.bssmap.speech_data_ind",
8370 | FT_UINT8, BASE_DEC, VALS(gsm_a_bssap_speech_data_ind_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssap_speech_data_ind_vals )))), 0x0f,
8371 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8372 | },
8373 | { &hf_gsm_a_bssmap_channel_rate_and_type,
8374 | { "Channel Rate and Type", "gsm_a.bssmap.rate_and_type",
8375 | FT_UINT8, BASE_DEC, VALS(gsm_a_bssap_channel_rate_and_type_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssap_channel_rate_and_type_vals )))), 0x0,
8376 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8377 | },
8378 | { &hf_gsm_a_bssmap_perm_speech_v_ind,
8379 | { "Permitted speech version indication", "gsm_a.bssmap.perm_speech_v_ind",
8380 | FT_UINT8, BASE_HEX|BASE_RANGE_STRING0x00000100, RVALS(speech_version_id_rvals)((0 ? (const struct _range_string*)0 : ((speech_version_id_rvals )))), 0x7f,
8381 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8382 | },
8383 | { &hf_gsm_a_bssmap_reroute_rej_cause,
8384 | { "Reroute Reject cause", "gsm_a.bssmap.reroute_rej_cause",
8385 | FT_UINT8, BASE_HEX, VALS(gsm_a_bssap_reroute_rej_cause_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssap_reroute_rej_cause_vals )))), 0x0,
8386 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8387 | },
8388 | { &hf_gsm_a_bssmap_send_seqn,
8389 | { "Send Sequence Number", "gsm_a.bssmap.send_seqn",
8390 | FT_UINT8, BASE_HEX, NULL((void*)0), 0xc0,
8391 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8392 | },
8393 | { &hf_gsm_a_bssmap_reroute_outcome,
8394 | { "Outcome", "gsm_a.bssmap.reroute_outcome",
8395 | FT_UINT8, BASE_HEX, VALS(gsm_a_bssap_reroute_outcome_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssap_reroute_outcome_vals )))), 0x0,
8396 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8397 | },
8398 | { &hf_gsm_a_bssmap_lcls_conf,
8399 | { "LCLS-Configuration", "gsm_a.bssmap.lcls_conf",
8400 | FT_UINT8, BASE_HEX, VALS(gsm_a_bssap_lcls_conf_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssap_lcls_conf_vals )))), 0x0f,
8401 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8402 | },
8403 | { &hf_gsm_a_bssmap_lcls_con_status_control,
8404 | { "LCLS-Connection-Status-Control", "gsm_a.bssmap.lcls_con_status_control",
8405 | FT_UINT8, BASE_HEX, VALS(gsm_a_bssap_lcls_con_status_control_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssap_lcls_con_status_control_vals )))), 0x0f,
8406 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8407 | },
8408 | { &hf_gsm_a_bssmap_lcls_bss_status,
8409 | { "LCLS-BSS-Status", "gsm_a.bssmap.lcls_bss_status",
8410 | FT_UINT8, BASE_HEX, VALS(gsm_a_bssmap_lcls_bss_status_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_lcls_bss_status_vals )))), 0x0f,
8411 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8412 | },
8413 | { &hf_gsm_a_bssmap_osmocom_osmux_cid,
8414 | { "Osmux CID", "gsm_a.bssmap.osmocom_osmux_cid",
8415 | FT_UINT8, BASE_DEC, NULL((void*)0), 0,
8416 | NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }
8417 | },
8418 |
8419 | /* Generated from convert_proto_tree_add_text.pl */
8420 | { &hf_gsm_a_bssmap_pcm_multiplexer, { "PCM Multiplexer", "gsm_a_bssmap.pcm_multiplexer", FT_UINT16, BASE_DEC, NULL((void*)0), 0xffe0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8421 | { &hf_gsm_a_bssmap_timeslot, { "Timeslot", "gsm_a_bssmap.timeslot", FT_UINT16, BASE_DEC, NULL((void*)0), 0x001f, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8422 | { &hf_gsm_a_bssmap_full_rate_channels_available, { "Number of full rate channels available in band", "gsm_a_bssmap.full_rate_channels_available", FT_UINT32, BASE_DEC, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8423 | { &hf_gsm_a_bssmap_half_rate_channels_available, { "Number of half rate channels available in band", "gsm_a_bssmap.half_rate_channels_available", FT_UINT32, BASE_DEC, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8424 | { &hf_gsm_a_bssmap_cause_class, { "Cause Class", "gsm_a_bssmap.cause_class", FT_UINT8, BASE_DEC, VALS(cause_class_vals)((0 ? (const struct _value_string*)0 : ((cause_class_vals)))), 0x70, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8425 | { &hf_gsm_a_bssmap_national_cause, { "National Cause", "gsm_a_bssmap.national_cause", FT_UINT8, BASE_DEC, NULL((void*)0), 0x0f, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8426 | { &hf_gsm_a_bssmap_cause_value, { "Cause Value", "gsm_a_bssmap.cause_value", FT_UINT8, BASE_DEC, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8427 | { &hf_gsm_a_bssmap_cause16, { "Cause", "gsm_a_bssmap.cause", FT_UINT16, BASE_DEC, NULL((void*)0), 0x07ff, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8428 | { &hf_gsm_a_bssmap_ti_flag, { "TI flag", "gsm_a_bssmap.ti_flag", FT_BOOLEAN, 8, TFS(&tfs_allocated_by_receiver_sender)((0 ? (const struct true_false_string*)0 : ((&tfs_allocated_by_receiver_sender )))), 0x08, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8429 | { &hf_gsm_a_bssmap_tio, { "TIO", "gsm_a_bssmap.tio", FT_UINT8, BASE_DEC, NULL((void*)0), 0x07, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8430 | { &hf_gsm_a_bssmap_enc_info_key, { "Key", "gsm_a_bssmap.enc_info_key", FT_BYTES, BASE_NONE, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8431 | { &hf_gsm_a_bssmap_transparent_service, { "Service", "gsm_a_bssmap.transparent_service", FT_BOOLEAN, 8, TFS(&tfs_non_transparent_transparent)((0 ? (const struct true_false_string*)0 : ((&tfs_non_transparent_transparent )))), 0x40, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8432 | { &hf_gsm_a_bssmap_rate, { "Rate", "gsm_a_bssmap.rate", FT_UINT8, BASE_DEC, NULL((void*)0), 0x3f, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8433 | { &hf_gsm_a_bssmap_tch_14_5kb, { "14.5 kbit/s (TCH/F14.4)", "gsm_a_bssmap.tch_14_5kb", FT_BOOLEAN, 8, TFS(&tfs_allowed_not_allowed)((0 ? (const struct true_false_string*)0 : ((&tfs_allowed_not_allowed )))), 0x08, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8434 | { &hf_gsm_a_bssmap_tch_12kb, { "12.0 kbit/s (TCH F/9.6)", "gsm_a_bssmap.tch_12kb", FT_BOOLEAN, 8, TFS(&tfs_allowed_not_allowed)((0 ? (const struct true_false_string*)0 : ((&tfs_allowed_not_allowed )))), 0x02, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8435 | { &hf_gsm_a_bssmap_tch_6kb, { "6.0 kbit/s (TCH F/4.8)", "gsm_a_bssmap.tch_6kb", FT_BOOLEAN, 8, TFS(&tfs_allowed_not_allowed)((0 ? (const struct true_false_string*)0 : ((&tfs_allowed_not_allowed )))), 0x01, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8436 | { &hf_gsm_a_bssmap_tch_14_5_14_4kb, { "14.5/14.4 kbit/s (TCH/F14.4)", "gsm_a_bssmap.tch_14_5_14_4kb", FT_BOOLEAN, 8, NULL((void*)0), 0x08, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8437 | { &hf_gsm_a_bssmap_tch_12_9kb, { "12.0/9.6 kbit/s (TCH F/9.6)", "gsm_a_bssmap.tch_12_9kb", FT_BOOLEAN, 8, NULL((void*)0), 0x02, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8438 | { &hf_gsm_a_bssmap_tch_6_4_8kb, { "6.0/4.8 kbit/s (TCH F/4.8)", "gsm_a_bssmap.tch_6_4_8kb", FT_BOOLEAN, 8, NULL((void*)0), 0x01, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8439 | { &hf_gsm_a_bssmap_unknown_format, { "Unknown format", "gsm_a_bssmap.unknown_format", FT_BYTES, BASE_NONE, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8440 | { &hf_gsm_a_bssmap_cell_id_unknown_format, { "Cell ID - Unknown format", "gsm_a_bssmap.cell_id.unknown_format", FT_BYTES, BASE_NONE, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8441 | { &hf_gsm_a_bssmap_priority_level, { "Priority Level", "gsm_a_bssmap.priority_level", FT_UINT8, BASE_DEC|BASE_RANGE_STRING0x00000100, RVALS(bssmap_prio_rvals)((0 ? (const struct _range_string*)0 : ((bssmap_prio_rvals))) ), 0x3c, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8442 | { &hf_gsm_a_bssmap_layer_3_information_value, { "Layer 3 Information value", "gsm_a_bssmap.layer_3_information_value", FT_BYTES, BASE_NONE, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8443 | { &hf_gsm_a_bssmap_bss_activate_downlink, { "BSS can to activate DTX in the downlink direction", "gsm_a_bssmap.bss_activate_downlink", FT_BOOLEAN, 8, TFS(&tfs_yes_no)((0 ? (const struct true_false_string*)0 : ((&tfs_yes_no) ))), 0x01, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8444 | { &hf_gsm_a_bssmap_imeisv_included, { "IMEISV must be included by the mobile station", "gsm_a_bssmap.imeisv_included", FT_BOOLEAN, 8, TFS(&tfs_yes_no)((0 ? (const struct true_false_string*)0 : ((&tfs_yes_no) ))), 0x01, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8445 | { &hf_gsm_a_bssmap_algorithm_identifier, { "Algorithm Identifier", "gsm_a_bssmap.algorithm_identifier", FT_UINT8, BASE_DEC, VALS(gsm_a_bssmap_algorithm_id_vals)((0 ? (const struct _value_string*)0 : ((gsm_a_bssmap_algorithm_id_vals )))), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8446 | { &hf_gsm_a_bssmap_circuit_pool_number, { "Circuit pool number", "gsm_a_bssmap.circuit_pool_number", FT_UINT8, BASE_DEC, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8447 | { &hf_gsm_a_bssmap_qri, { "qri recommended queuing", "gsm_a_bssmap.qri", FT_BOOLEAN, 8, TFS(&tfs_allowed_not_allowed)((0 ? (const struct true_false_string*)0 : ((&tfs_allowed_not_allowed )))), 0x02, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8448 | { &hf_gsm_a_bssmap_speech_version_id, { "Speech version identifier", "gsm_a_bssmap.speech_version_id", FT_UINT8, BASE_DEC|BASE_RANGE_STRING0x00000100, RVALS(speech_version_id_rvals)((0 ? (const struct _range_string*)0 : ((speech_version_id_rvals )))), 0x7f, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8449 | { &hf_gsm_a_bssmap_apdu, { "APDU", "gsm_a_bssmap.apdu", FT_BYTES, BASE_NONE, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8450 | { &hf_gsm_a_bssmap_talker_identity_field, { "Talker Identity field", "gsm_a_bssmap.talker_identity_field", FT_BYTES, BASE_NONE, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8451 | { &hf_gsm_a_bssmap_s0_s15, { "S0 - S15", "gsm_a_bssmap.s0_s15", FT_UINT16, BASE_HEX, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8452 | { &hf_gsm_a_bssmap_s0_s7, { "S0 - S7", "gsm_a_bssmap.s0_s7", FT_UINT8, BASE_HEX, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8453 | { &hf_gsm_a_bssmap_all_call_identifiers_resources_released, { "all resources and references associated to all Call Identifiers in use between the BSC and the MSC need to be released", "gsm_a_bssmap.all_call_identifiers_resources_released", FT_NONE, BASE_NONE, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8454 | { &hf_gsm_a_bssmap_message_elements, { "Message Elements", "gsm_a_bssmap.message_elements", FT_BYTES, BASE_NONE, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8455 | { &hf_gsm_a_bssmap_layer3_message_contents, { "Layer 3 Message Contents", "gsm_a_bssmap.layer3_message_contents", FT_BYTES, BASE_NONE, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8456 | { &hf_gsm_a_bssmap_gsm_a5_1, { "GSM A5/1", "gsm_a_bssmap.gsm_a5_1", FT_BOOLEAN, 8, TFS(&tfs_permitted_not_permitted)((0 ? (const struct true_false_string*)0 : ((&tfs_permitted_not_permitted )))), 0x02, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8457 | { &hf_gsm_a_bssmap_gsm_a5_2, { "GSM A5/2", "gsm_a_bssmap.gsm_a5_2", FT_BOOLEAN, 8, TFS(&tfs_permitted_not_permitted)((0 ? (const struct true_false_string*)0 : ((&tfs_permitted_not_permitted )))), 0x04, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8458 | { &hf_gsm_a_bssmap_gsm_a5_3, { "GSM A5/3", "gsm_a_bssmap.gsm_a5_3", FT_BOOLEAN, 8, TFS(&tfs_permitted_not_permitted)((0 ? (const struct true_false_string*)0 : ((&tfs_permitted_not_permitted )))), 0x08, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8459 | { &hf_gsm_a_bssmap_gsm_a5_4, { "GSM A5/4", "gsm_a_bssmap.gsm_a5_4", FT_BOOLEAN, 8, TFS(&tfs_permitted_not_permitted)((0 ? (const struct true_false_string*)0 : ((&tfs_permitted_not_permitted )))), 0x10, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8460 | { &hf_gsm_a_bssmap_gsm_a5_5, { "GSM A5/5", "gsm_a_bssmap.gsm_a5_5", FT_BOOLEAN, 8, TFS(&tfs_permitted_not_permitted)((0 ? (const struct true_false_string*)0 : ((&tfs_permitted_not_permitted )))), 0x20, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8461 | { &hf_gsm_a_bssmap_gsm_a5_6, { "GSM A5/6", "gsm_a_bssmap.gsm_a5_6", FT_BOOLEAN, 8, TFS(&tfs_permitted_not_permitted)((0 ? (const struct true_false_string*)0 : ((&tfs_permitted_not_permitted )))), 0x40, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8462 | { &hf_gsm_a_bssmap_gsm_a5_7, { "GSM A5/7", "gsm_a_bssmap.gsm_a5_7", FT_BOOLEAN, 8, TFS(&tfs_permitted_not_permitted)((0 ? (const struct true_false_string*)0 : ((&tfs_permitted_not_permitted )))), 0x80, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8463 | { &hf_gsm_a_bssmap_no_encryption, { "No encryption", "gsm_a_bssmap.no_encryption", FT_BOOLEAN, 8, TFS(&tfs_permitted_not_permitted)((0 ? (const struct true_false_string*)0 : ((&tfs_permitted_not_permitted )))), 0x01, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8464 | { &hf_gsm_a_bssmap_data_channel_rate_and_type, { "Channel rate and type", "gsm_a_bssmap.channel_rate_and_type", FT_UINT8, BASE_DEC|BASE_RANGE_STRING0x00000100, RVALS(gsm_a_bssap_channel_rate_and_type_rvals)((0 ? (const struct _range_string*)0 : ((gsm_a_bssap_channel_rate_and_type_rvals )))), 0x7f, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8465 | { &hf_gsm_a_bssmap_cell_discriminator, { "Cell Discriminator", "gsm_a_bssmap.cell_discriminator", FT_UINT8, BASE_HEX, NULL((void*)0), 0x0, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8466 | { &hf_gsm_a_bssmap_forward_indicator, { "Forward indicator", "gsm_a_bssmap.forward_indicator", FT_UINT8, BASE_DEC|BASE_RANGE_STRING0x00000100, RVALS(forward_indicator_rvals)((0 ? (const struct _range_string*)0 : ((forward_indicator_rvals )))), 0x0f, NULL((void*)0), HFILL-1, 0, HF_REF_TYPE_NONE, -1, ((void*)0) }},
8467 | };
8468 |
8469 | expert_module_t* expert_gsm_a_bssmap;
8470 |
8471 | static ei_register_info ei[] = {
8472 | { &ei_gsm_a_bssmap_extraneous_data, { "gsm_a_bssmap.extraneous_data", PI_PROTOCOL0x09000000, PI_NOTE0x00400000, "Extraneous Data, dissector bug or later version spec (report to wireshark.org)", EXPFILL0, ((void*)0), 0, ((void*)0), {0, {((void*)0), ((void*)0), FT_NONE , BASE_NONE, ((void*)0), 0, ((void*)0), -1, 0, HF_REF_TYPE_NONE , -1, ((void*)0)}} }},
8473 | { &ei_gsm_a_bssmap_not_decoded_yet, { "gsm_a_bssmap.not_decoded_yet", PI_UNDECODED0x05000000, PI_WARN0x00600000, "Not decoded yet", EXPFILL0, ((void*)0), 0, ((void*)0), {0, {((void*)0), ((void*)0), FT_NONE , BASE_NONE, ((void*)0), 0, ((void*)0), -1, 0, HF_REF_TYPE_NONE , -1, ((void*)0)}} }},
8474 | { &ei_gsm_a_bssap_unknown_codec, { "gsm_a_bssmap.unknown_codec", PI_PROTOCOL0x09000000, PI_WARN0x00600000, "Unknown codec - the rest of the dissection my be suspect", EXPFILL0, ((void*)0), 0, ((void*)0), {0, {((void*)0), ((void*)0), FT_NONE , BASE_NONE, ((void*)0), 0, ((void*)0), -1, 0, HF_REF_TYPE_NONE , -1, ((void*)0)}} }},
8475 | { &ei_gsm_a_bssmap_bogus_length, { "gsm_a_bssmap.bogus_length", PI_PROTOCOL0x09000000, PI_WARN0x00600000, "Bogus length", EXPFILL0, ((void*)0), 0, ((void*)0), {0, {((void*)0), ((void*)0), FT_NONE , BASE_NONE, ((void*)0), 0, ((void*)0), -1, 0, HF_REF_TYPE_NONE , -1, ((void*)0)}} }},
8476 | { &ei_gsm_a_bssmap_missing_mandatory_element, { "gsm_a_bssmap.missing_mandatory_element", PI_PROTOCOL0x09000000, PI_WARN0x00600000, "Missing Mandatory element, rest of dissection is suspect", EXPFILL0, ((void*)0), 0, ((void*)0), {0, {((void*)0), ((void*)0), FT_NONE , BASE_NONE, ((void*)0), 0, ((void*)0), -1, 0, HF_REF_TYPE_NONE , -1, ((void*)0)}} }},
8477 | };
8478 |
8479 | /* Setup protocol subtree array */
8480 | #define NUM_INDIVIDUAL_ELEMS5 5
8481 | int *ett[NUM_INDIVIDUAL_ELEMS5 + NUM_GSM_BSSMAP_MSG(int)(sizeof (gsm_a_bssmap_msg_strings) / sizeof (gsm_a_bssmap_msg_strings )[0]) +
8482 | NUM_GSM_BSSMAP_ELEM(sizeof (gsm_bssmap_elem_strings) / sizeof (gsm_bssmap_elem_strings )[0])];
8483 |
8484 | ett[0] = &ett_bssmap_msg;
8485 | ett[1] = &ett_cell_list;
8486 | ett[2] = &ett_dlci;
8487 | ett[3] = &ett_codec_lst;
8488 | ett[4] = &ett_bss_to_bss_info;
8489 |
8490 | last_offset = NUM_INDIVIDUAL_ELEMS5;
8491 |
8492 | for (i=0; i < NUM_GSM_BSSMAP_MSG(int)(sizeof (gsm_a_bssmap_msg_strings) / sizeof (gsm_a_bssmap_msg_strings )[0]); i++, last_offset++)
8493 | {
8494 | ett[last_offset] = &ett_gsm_bssmap_msg[i];
8495 | }
8496 |
8497 | for (i=0; i < NUM_GSM_BSSMAP_ELEM(sizeof (gsm_bssmap_elem_strings) / sizeof (gsm_bssmap_elem_strings )[0]); i++, last_offset++)
8498 | {
8499 | ett[last_offset] = &ett_gsm_bssmap_elem[i];
8500 | }
8501 |
8502 | /* Register the protocol name and description */
8503 |
8504 | proto_a_bssmap =
8505 | proto_register_protocol("GSM A-I/F BSSMAP", "GSM BSSMAP", "gsm_a.bssmap");
8506 |
8507 | proto_register_field_array(proto_a_bssmap, hf, array_length(hf)(sizeof (hf) / sizeof (hf)[0]));
8508 |
8509 | proto_register_subtree_array(ett, array_length(ett)(sizeof (ett) / sizeof (ett)[0]));
8510 |
8511 | expert_gsm_a_bssmap = expert_register_protocol(proto_a_bssmap);
8512 | expert_register_field_array(expert_gsm_a_bssmap, ei, array_length(ei)(sizeof (ei) / sizeof (ei)[0]));
8513 |
8514 | bssmap_handle = register_dissector("gsm_a_bssmap", dissect_bssmap, proto_a_bssmap);
8515 | }
8516 |
8517 |
8518 | void
8519 | proto_reg_handoff_gsm_a_bssmap(void)
8520 | {
8521 | dissector_add_uint("bssap.pdu_type", GSM_A_PDU_TYPE_BSSMAP0, bssmap_handle);
8522 |
8523 | dtap_handle = find_dissector_add_dependency("gsm_a_dtap", proto_a_bssmap);
8524 | gsm_bsslap_handle = find_dissector_add_dependency("gsm_bsslap", proto_a_bssmap);
8525 | bssgp_handle = find_dissector_add_dependency("bssgp", proto_a_bssmap);
8526 | rrc_handle = find_dissector_add_dependency("rrc", proto_a_bssmap);
8527 | bicc_mst_handle = find_dissector_add_dependency("bicc_mst", proto_a_bssmap);
8528 | }
8529 |
8530 | /*
8531 | * Editor modelines - https://www.wireshark.org/tools/modelines.html
8532 | *
8533 | * Local variables:
8534 | * c-basic-offset: 4
8535 | * tab-width: 8
8536 | * indent-tabs-mode: nil
8537 | * End:
8538 | *
8539 | * vi: set shiftwidth=4 tabstop=8 expandtab:
8540 | * :indentSize=4:tabSize=8:noTabs=true:
8541 | */