1 /* Do not modify this file. */
2 /* It is created automatically by the ASN.1 to Ethereal dissector compiler */
4 /* ../../tools/asn2eth.py -X -b -e -p tcap -c tcap.cnf -s packet-tcap-template tcap.asn */
6 /* Input file: packet-tcap-template.c */
8 #line 1 "packet-tcap-template.c"
9 /* packet-tcap-template.c
11 * Copyright 2004 - 2005, Tim Endean <endeant@hotmail.com>
12 * Built from the gsm-map dissector Copyright 2004 - 2005, Anders Broman <anders.broman@ericsson.com>
15 * Ethereal - Network traffic analyzer
16 * By Gerald Combs <gerald@ethereal.com>
17 * Copyright 1998 Gerald Combs
19 * This program is free software; you can redistribute it and/or
20 * modify it under the terms of the GNU General Public License
21 * as published by the Free Software Foundation; either version 2
22 * of the License, or (at your option) any later version.
24 * This program is distributed in the hope that it will be useful,
25 * but WITHOUT ANY WARRANTY; without even the implied warranty of
26 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
27 * GNU General Public License for more details.
29 * You should have received a copy of the GNU General Public License
30 * along with this program; if not, write to the Free Software
31 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
32 * References: ETSI 300 374
40 #include <epan/packet.h>
41 #include <epan/prefs.h>
42 #include <epan/conversation.h>
46 #include "packet-ber.h"
47 #include "packet-tcap.h"
49 #define PNAME "Transaction Capabilities Application Part"
53 /* Initialize the protocol and registered fields */
55 static int hf_tcap_tag = -1;
56 static int hf_tcap_length = -1;
57 static int hf_tcap_data = -1;
58 static int hf_tcap_tid = -1;
61 /*--- Included file: packet-tcap-hf.c ---*/
62 #line 1 "packet-tcap-hf.c"
63 static int hf_tcap_dialogueRequest = -1; /* AARQ_apdu */
64 static int hf_tcap_dialogueResponse = -1; /* AARE_apdu */
65 static int hf_tcap_dialogueAbort = -1; /* ABRT_apdu */
66 static int hf_tcap_oid = -1; /* OBJECT_IDENTIFIER */
67 static int hf_tcap_dialog = -1; /* Dialog1 */
68 static int hf_tcap_useroid = -1; /* UserInfoOID */
69 static int hf_tcap_externuserinfo = -1; /* ExternUserInfo */
70 static int hf_tcap_protocol_versionrq = -1; /* T_protocol_versionrq */
71 static int hf_tcap_application_context_name = -1; /* Applicationcontext */
72 static int hf_tcap_user_information = -1; /* User_information */
73 static int hf_tcap_protocol_versionre = -1; /* T_protocol_versionre */
74 static int hf_tcap_result = -1; /* Associate_result */
75 static int hf_tcap_result_source_diagnostic = -1; /* Associate_source_diagnostic */
76 static int hf_tcap_reasonrq = -1; /* Release_request_reason */
77 static int hf_tcap_reasonre = -1; /* Release_response_reason */
78 static int hf_tcap_abort_source = -1; /* ABRT_source */
79 static int hf_tcap_dialogue_service_user = -1; /* T_dialogue_service_user */
80 static int hf_tcap_dialogue_service_provider = -1; /* T_dialogue_service_provider */
81 static int hf_tcap_unidialoguePDU = -1; /* AUDT_apdu */
82 static int hf_tcap_protocol_version3 = -1; /* T_protocol_version3 */
83 static int hf_tcap_unidirectional = -1; /* Unidirectional */
84 static int hf_tcap_begin = -1; /* Begin */
85 static int hf_tcap_end = -1; /* End */
86 static int hf_tcap_continue = -1; /* Continue */
87 static int hf_tcap_abort = -1; /* Abort */
88 static int hf_tcap_ansiunidirectional = -1; /* UniTransactionPDU */
89 static int hf_tcap_ansiqueryWithPerm = -1; /* TransactionPDU */
90 static int hf_tcap_ansiqueryWithoutPerm = -1; /* TransactionPDU */
91 static int hf_tcap_ansiresponse = -1; /* TransactionPDU */
92 static int hf_tcap_ansiconversationWithPerm = -1; /* TransactionPDU */
93 static int hf_tcap_ansiconversationWithoutPerm = -1; /* TransactionPDU */
94 static int hf_tcap_ansiabort = -1; /* AbortPDU */
95 static int hf_tcap_dialoguePortion = -1; /* DialoguePortion */
96 static int hf_tcap_components = -1; /* ComponentPortion */
97 static int hf_tcap_otid = -1; /* OrigTransactionID */
98 static int hf_tcap_dtid = -1; /* DestTransactionID */
99 static int hf_tcap_reason = -1; /* Reason */
100 static int hf_tcap_p_abortCause = -1; /* P_AbortCause */
101 static int hf_tcap_u_abortCause = -1; /* DialoguePortion */
102 static int hf_tcap_ComponentPortion_item = -1; /* Component */
103 static int hf_tcap_invoke = -1; /* Invoke */
104 static int hf_tcap_returnResultLast = -1; /* ReturnResult */
105 static int hf_tcap_returnError = -1; /* ReturnError */
106 static int hf_tcap_reject = -1; /* Reject */
107 static int hf_tcap_returnResultNotLast = -1; /* ReturnResult */
108 static int hf_tcap_invokeID = -1; /* InvokeIdType */
109 static int hf_tcap_linkedID = -1; /* InvokeIdType */
110 static int hf_tcap_opCode = -1; /* OPERATION */
111 static int hf_tcap_parameter = -1; /* Parameter */
112 static int hf_tcap_resultretres = -1; /* T_resultretres */
113 static int hf_tcap_errorCode = -1; /* ErrorCode */
114 static int hf_tcap_invokeIDRej = -1; /* T_invokeIDRej */
115 static int hf_tcap_derivable = -1; /* InvokeIdType */
116 static int hf_tcap_not_derivable = -1; /* NULL */
117 static int hf_tcap_problem = -1; /* T_problem */
118 static int hf_tcap_generalProblem = -1; /* GeneralProblem */
119 static int hf_tcap_invokeProblem = -1; /* InvokeProblem */
120 static int hf_tcap_returnResultProblem = -1; /* ReturnResultProblem */
121 static int hf_tcap_returnErrorProblem = -1; /* ReturnErrorProblem */
122 static int hf_tcap_localValue = -1; /* INTEGER */
123 static int hf_tcap_globalValue = -1; /* OBJECT_IDENTIFIER */
124 static int hf_tcap_identifier = -1; /* TransactionID */
125 static int hf_tcap_dialoguePortionansi = -1; /* DialoguePortionANSI */
126 static int hf_tcap_componentPortion = -1; /* ComponentSequence */
127 static int hf_tcap_causeInformation = -1; /* T_causeInformation */
128 static int hf_tcap_abortCause = -1; /* P_Abort_cause */
129 static int hf_tcap_userInformation = -1; /* UserInformation */
130 static int hf_tcap_version = -1; /* ProtocolVersion */
131 static int hf_tcap_applicationContext = -1; /* T_applicationContext */
132 static int hf_tcap_integerApplicationId = -1; /* IntegerApplicationContext */
133 static int hf_tcap_objectApplicationId = -1; /* ObjectIDApplicationContext */
134 static int hf_tcap_securityContext = -1; /* T_securityContext */
135 static int hf_tcap_integerSecurityId = -1; /* INTEGER */
136 static int hf_tcap_objectSecurityId = -1; /* OBJECT_IDENTIFIER */
137 static int hf_tcap_confidentiality = -1; /* Confidentiality */
138 static int hf_tcap_confidentialityId = -1; /* T_confidentialityId */
139 static int hf_tcap_integerConfidentialityId = -1; /* INTEGER */
140 static int hf_tcap_objectConfidentialityId = -1; /* OBJECT_IDENTIFIER */
141 static int hf_tcap_ComponentSequence_item = -1; /* ComponentPDU */
142 static int hf_tcap_invokeLastansi = -1; /* InvokePDU */
143 static int hf_tcap_returnResultLastansi = -1; /* ReturnResultPDU */
144 static int hf_tcap_returnErroransi = -1; /* ReturnErrorPDU */
145 static int hf_tcap_rejectansi = -1; /* RejectPDU */
146 static int hf_tcap_invokeNotLastansi = -1; /* InvokePDU */
147 static int hf_tcap_returnResultNotLastansi = -1; /* ReturnResultPDU */
148 static int hf_tcap_componentIDs = -1; /* OCTET_STRING_SIZE_0_2 */
149 static int hf_tcap_operationCode = -1; /* OperationCode */
150 static int hf_tcap_parameterinv = -1; /* ANSIparamch */
151 static int hf_tcap_ansiparams = -1; /* ANSIParameters */
152 static int hf_tcap_ansiparams1 = -1; /* ANSIParameters */
153 static int hf_tcap_ansiparams2 = -1; /* ANSIParameters */
154 static int hf_tcap_ansiparams3 = -1; /* ANSIParameters */
155 static int hf_tcap_ansiparams4 = -1; /* ANSIParameters */
156 static int hf_tcap_ansiparams5 = -1; /* ANSIParameters */
157 static int hf_tcap_ansiparams6 = -1; /* ANSIParameters */
158 static int hf_tcap_ansiparams7 = -1; /* ANSIParameters */
159 static int hf_tcap_ansiparams8 = -1; /* ANSIParameters */
160 static int hf_tcap_ansiparams9 = -1; /* ANSIParameters */
161 static int hf_tcap_ansiparams10 = -1; /* ANSIParameters */
162 static int hf_tcap_ansiparams11 = -1; /* ANSIParameters */
163 static int hf_tcap_ansiparams12 = -1; /* ANSIParameters */
164 static int hf_tcap_ansiparams13 = -1; /* ANSIParameters */
165 static int hf_tcap_ansiparams14 = -1; /* ANSIParameters */
166 static int hf_tcap_ansiparams15 = -1; /* ANSIParameters */
167 static int hf_tcap_ansiparams16 = -1; /* ANSIParameters */
168 static int hf_tcap_ansiparams17 = -1; /* ANSIParameters */
169 static int hf_tcap_ansiparams18 = -1; /* ANSIParameters */
170 static int hf_tcap_ansiparams19 = -1; /* ANSIParameters */
171 static int hf_tcap_ansiparams20 = -1; /* ANSIParameters */
172 static int hf_tcap_ansiparams21 = -1; /* ANSIParameters */
173 static int hf_tcap_componentID = -1; /* ComponentID */
174 static int hf_tcap_parameterrr = -1; /* ANSIparamch */
175 static int hf_tcap_parameterre = -1; /* ANSIparamch */
176 static int hf_tcap_rejectProblem = -1; /* ProblemPDU */
177 static int hf_tcap_parameterrj = -1; /* ANSIparamch */
178 static int hf_tcap_national = -1; /* INTEGER_M32768_32767 */
179 static int hf_tcap_private = -1; /* INTEGER */
180 static int hf_tcap_nationaler = -1; /* INTEGER_M32768_32767 */
181 static int hf_tcap_privateer = -1; /* INTEGER */
183 static int hf_tcap_T_protocol_versionrq_version1 = -1;
184 static int hf_tcap_T_protocol_versionre_version1 = -1;
185 static int hf_tcap_T_protocol_version3_version1 = -1;
187 /*--- End of included file: packet-tcap-hf.c ---*/
188 #line 53 "packet-tcap-template.c"
190 /* Initialize the subtree pointers */
191 static gint ett_tcap = -1;
192 static gint ett_param = -1;
194 static gint ett_otid = -1;
195 static gint ett_dtid = -1;
199 /*--- Included file: packet-tcap-ett.c ---*/
200 #line 1 "packet-tcap-ett.c"
201 static gint ett_tcap_DialoguePDU = -1;
202 static gint ett_tcap_ExternalPDU = -1;
203 static gint ett_tcap_UserInformation = -1;
204 static gint ett_tcap_AARQ_apdu = -1;
205 static gint ett_tcap_T_protocol_versionrq = -1;
206 static gint ett_tcap_AARE_apdu = -1;
207 static gint ett_tcap_T_protocol_versionre = -1;
208 static gint ett_tcap_RLRQ_apdu = -1;
209 static gint ett_tcap_RLRE_apdu = -1;
210 static gint ett_tcap_ABRT_apdu = -1;
211 static gint ett_tcap_Associate_source_diagnostic = -1;
212 static gint ett_tcap_UniDialoguePDU = -1;
213 static gint ett_tcap_AUDT_apdu = -1;
214 static gint ett_tcap_T_protocol_version3 = -1;
215 static gint ett_tcap_MessageType = -1;
216 static gint ett_tcap_Unidirectional = -1;
217 static gint ett_tcap_Begin = -1;
218 static gint ett_tcap_End = -1;
219 static gint ett_tcap_Continue = -1;
220 static gint ett_tcap_Abort = -1;
221 static gint ett_tcap_Reason = -1;
222 static gint ett_tcap_ComponentPortion = -1;
223 static gint ett_tcap_Component = -1;
224 static gint ett_tcap_Invoke = -1;
225 static gint ett_tcap_ReturnResult = -1;
226 static gint ett_tcap_T_resultretres = -1;
227 static gint ett_tcap_ReturnError = -1;
228 static gint ett_tcap_Reject = -1;
229 static gint ett_tcap_T_invokeIDRej = -1;
230 static gint ett_tcap_T_problem = -1;
231 static gint ett_tcap_OPERATION = -1;
232 static gint ett_tcap_ERROR = -1;
233 static gint ett_tcap_UniTransactionPDU = -1;
234 static gint ett_tcap_TransactionPDU = -1;
235 static gint ett_tcap_AbortPDU = -1;
236 static gint ett_tcap_T_causeInformation = -1;
237 static gint ett_tcap_DialoguePortionANSI = -1;
238 static gint ett_tcap_T_applicationContext = -1;
239 static gint ett_tcap_T_securityContext = -1;
240 static gint ett_tcap_Confidentiality = -1;
241 static gint ett_tcap_T_confidentialityId = -1;
242 static gint ett_tcap_ComponentSequence = -1;
243 static gint ett_tcap_ComponentPDU = -1;
244 static gint ett_tcap_InvokePDU = -1;
245 static gint ett_tcap_ANSIparamch = -1;
246 static gint ett_tcap_ReturnResultPDU = -1;
247 static gint ett_tcap_ReturnErrorPDU = -1;
248 static gint ett_tcap_RejectPDU = -1;
249 static gint ett_tcap_OperationCode = -1;
250 static gint ett_tcap_ErrorCode = -1;
252 /*--- End of included file: packet-tcap-ett.c ---*/
253 #line 63 "packet-tcap-template.c"
256 static range_t *global_ssn_range;
257 static range_t *ssn_range;
259 dissector_handle_t tcap_handle = NULL;
260 static dissector_table_t ber_oid_dissector_table=NULL;
261 static const char * cur_oid;
262 static const char * tcapext_oid;
263 static proto_tree *tcap_top_tree=NULL;
264 static dissector_handle_t data_handle;
266 static dissector_table_t sccp_ssn_table;
267 static int dissect_tcap_param(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset);
268 static int dissect_tcap_UserInformation(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_);
271 static GHashTable* ansi_sub_dissectors = NULL;
272 static GHashTable* itu_sub_dissectors = NULL;
274 static void dissect_tcap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree);
276 extern void add_ansi_tcap_subdissector(guint32 ssn, dissector_handle_t dissector) {
277 g_hash_table_insert(ansi_sub_dissectors,GUINT_TO_POINTER(ssn),dissector);
278 dissector_add("sccp.ssn",ssn,tcap_handle);
281 extern void add_itu_tcap_subdissector(guint32 ssn, dissector_handle_t dissector) {
282 g_hash_table_insert(itu_sub_dissectors,GUINT_TO_POINTER(ssn),dissector);
283 dissector_add("sccp.ssn",ssn,tcap_handle);
286 extern void delete_ansi_tcap_subdissector(guint32 ssn, dissector_handle_t dissector _U_) {
287 g_hash_table_remove(ansi_sub_dissectors,GUINT_TO_POINTER(ssn));
288 dissector_delete("sccp.ssn",ssn,tcap_handle);
290 extern void delete_itu_tcap_subdissector(guint32 ssn, dissector_handle_t dissector _U_) {
291 g_hash_table_remove(itu_sub_dissectors,GUINT_TO_POINTER(ssn));
292 dissector_delete("sccp.ssn", ssn,tcap_handle);
295 static dissector_handle_t get_ansi_tcap_subdissector(guint32 ssn) {
296 return g_hash_table_lookup(ansi_sub_dissectors,GUINT_TO_POINTER(ssn));
299 static dissector_handle_t get_itu_tcap_subdissector(guint32 ssn) {
300 return g_hash_table_lookup(itu_sub_dissectors,GUINT_TO_POINTER(ssn));
306 /*--- Included file: packet-tcap-fn.c ---*/
307 #line 1 "packet-tcap-fn.c"
308 /*--- Fields for imported types ---*/
312 static const asn_namedbit T_protocol_versionrq_bits[] = {
313 { 0, &hf_tcap_T_protocol_versionrq_version1, -1, -1, "version1", NULL },
314 { 0, NULL, 0, 0, NULL, NULL }
318 dissect_tcap_T_protocol_versionrq(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
319 offset = dissect_ber_bitstring(implicit_tag, pinfo, tree, tvb, offset,
320 T_protocol_versionrq_bits, hf_index, ett_tcap_T_protocol_versionrq,
325 static int dissect_protocol_versionrq_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
326 return dissect_tcap_T_protocol_versionrq(TRUE, tvb, offset, pinfo, tree, hf_tcap_protocol_versionrq);
332 dissect_tcap_Applicationcontext(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
334 offset = dissect_ber_object_identifier_str(implicit_tag, pinfo, tree, tvb, offset, hf_index, &cur_oid);
336 pinfo->private_data = (void*)cur_oid;
342 static int dissect_application_context_name(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
343 return dissect_tcap_Applicationcontext(FALSE, tvb, offset, pinfo, tree, hf_tcap_application_context_name);
349 dissect_tcap_User_information(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
359 offset = get_ber_identifier(tvb, offset, &class, &pc, &tag);
360 offset = get_ber_length(tree, tvb, offset, &len, &ind_field);
361 next_tvb = tvb_new_subset(tvb, offset, len-(2*ind_field), len-(2*ind_field));
364 dissect_tcap_UserInformation(TRUE, next_tvb, 0, pinfo, tree, -1);
372 static int dissect_user_information_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
373 return dissect_tcap_User_information(TRUE, tvb, offset, pinfo, tree, hf_tcap_user_information);
377 static const ber_sequence_t AARQ_apdu_sequence[] = {
378 { BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_protocol_versionrq_impl },
379 { BER_CLASS_CON, 1, 0, dissect_application_context_name },
380 { BER_CLASS_CON, 30, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_user_information_impl },
385 dissect_tcap_AARQ_apdu(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
386 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
387 AARQ_apdu_sequence, hf_index, ett_tcap_AARQ_apdu);
391 static int dissect_dialogueRequest(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
392 return dissect_tcap_AARQ_apdu(FALSE, tvb, offset, pinfo, tree, hf_tcap_dialogueRequest);
396 static const asn_namedbit T_protocol_versionre_bits[] = {
397 { 0, &hf_tcap_T_protocol_versionre_version1, -1, -1, "version1", NULL },
398 { 0, NULL, 0, 0, NULL, NULL }
402 dissect_tcap_T_protocol_versionre(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
403 offset = dissect_ber_bitstring(implicit_tag, pinfo, tree, tvb, offset,
404 T_protocol_versionre_bits, hf_index, ett_tcap_T_protocol_versionre,
409 static int dissect_protocol_versionre_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
410 return dissect_tcap_T_protocol_versionre(TRUE, tvb, offset, pinfo, tree, hf_tcap_protocol_versionre);
414 static const value_string tcap_Associate_result_vals[] = {
416 { 1, "reject-permanent" },
422 dissect_tcap_Associate_result(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
423 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
428 static int dissect_result(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
429 return dissect_tcap_Associate_result(FALSE, tvb, offset, pinfo, tree, hf_tcap_result);
433 static const value_string tcap_T_dialogue_service_user_vals[] = {
435 { 1, "no-reason-given" },
436 { 2, "application-context-name-not-supported" },
442 dissect_tcap_T_dialogue_service_user(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
443 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
448 static int dissect_dialogue_service_user(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
449 return dissect_tcap_T_dialogue_service_user(FALSE, tvb, offset, pinfo, tree, hf_tcap_dialogue_service_user);
453 static const value_string tcap_T_dialogue_service_provider_vals[] = {
455 { 1, "no-reason-given" },
456 { 2, "no-common-dialogue-portion" },
462 dissect_tcap_T_dialogue_service_provider(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
463 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
468 static int dissect_dialogue_service_provider(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
469 return dissect_tcap_T_dialogue_service_provider(FALSE, tvb, offset, pinfo, tree, hf_tcap_dialogue_service_provider);
473 static const value_string tcap_Associate_source_diagnostic_vals[] = {
474 { 1, "dialogue-service-user" },
475 { 2, "dialogue-service-provider" },
479 static const ber_choice_t Associate_source_diagnostic_choice[] = {
480 { 1, BER_CLASS_CON, 1, 0, dissect_dialogue_service_user },
481 { 2, BER_CLASS_CON, 2, 0, dissect_dialogue_service_provider },
486 dissect_tcap_Associate_source_diagnostic(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
487 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
488 Associate_source_diagnostic_choice, hf_index, ett_tcap_Associate_source_diagnostic,
493 static int dissect_result_source_diagnostic(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
494 return dissect_tcap_Associate_source_diagnostic(FALSE, tvb, offset, pinfo, tree, hf_tcap_result_source_diagnostic);
498 static const ber_sequence_t AARE_apdu_sequence[] = {
499 { BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_protocol_versionre_impl },
500 { BER_CLASS_CON, 1, 0, dissect_application_context_name },
501 { BER_CLASS_CON, 2, 0, dissect_result },
502 { BER_CLASS_CON, 3, BER_FLAGS_NOTCHKTAG, dissect_result_source_diagnostic },
503 { BER_CLASS_CON, 30, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_user_information_impl },
508 dissect_tcap_AARE_apdu(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
509 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
510 AARE_apdu_sequence, hf_index, ett_tcap_AARE_apdu);
514 static int dissect_dialogueResponse(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
515 return dissect_tcap_AARE_apdu(FALSE, tvb, offset, pinfo, tree, hf_tcap_dialogueResponse);
519 static const value_string tcap_ABRT_source_vals[] = {
520 { 0, "dialogue-service-user" },
521 { 1, "dialogue-service-provider" },
527 dissect_tcap_ABRT_source(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
528 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
533 static int dissect_abort_source_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
534 return dissect_tcap_ABRT_source(TRUE, tvb, offset, pinfo, tree, hf_tcap_abort_source);
538 static const ber_sequence_t ABRT_apdu_sequence[] = {
539 { BER_CLASS_CON, 0, BER_FLAGS_IMPLTAG, dissect_abort_source_impl },
540 { BER_CLASS_CON, 30, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_user_information_impl },
545 dissect_tcap_ABRT_apdu(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
546 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
547 ABRT_apdu_sequence, hf_index, ett_tcap_ABRT_apdu);
551 static int dissect_dialogueAbort(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
552 return dissect_tcap_ABRT_apdu(FALSE, tvb, offset, pinfo, tree, hf_tcap_dialogueAbort);
556 static const value_string tcap_DialoguePDU_vals[] = {
557 { 0, "dialogueRequest" },
558 { 1, "dialogueResponse" },
559 { 4, "dialogueAbort" },
563 static const ber_choice_t DialoguePDU_choice[] = {
564 { 0, BER_CLASS_APP, 0, BER_FLAGS_NOOWNTAG, dissect_dialogueRequest },
565 { 1, BER_CLASS_APP, 1, BER_FLAGS_NOOWNTAG, dissect_dialogueResponse },
566 { 4, BER_CLASS_APP, 4, BER_FLAGS_NOOWNTAG, dissect_dialogueAbort },
571 dissect_tcap_DialoguePDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
572 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
573 DialoguePDU_choice, hf_index, ett_tcap_DialoguePDU,
582 dissect_tcap_OBJECT_IDENTIFIER(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
583 offset = dissect_ber_object_identifier(implicit_tag, pinfo, tree, tvb, offset, hf_index, NULL);
587 static int dissect_oid(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
588 return dissect_tcap_OBJECT_IDENTIFIER(FALSE, tvb, offset, pinfo, tree, hf_tcap_oid);
590 static int dissect_globalValue(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
591 return dissect_tcap_OBJECT_IDENTIFIER(FALSE, tvb, offset, pinfo, tree, hf_tcap_globalValue);
593 static int dissect_objectSecurityId_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
594 return dissect_tcap_OBJECT_IDENTIFIER(TRUE, tvb, offset, pinfo, tree, hf_tcap_objectSecurityId);
596 static int dissect_objectConfidentialityId_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
597 return dissect_tcap_OBJECT_IDENTIFIER(TRUE, tvb, offset, pinfo, tree, hf_tcap_objectConfidentialityId);
603 dissect_tcap_Dialog1(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
612 offset = get_ber_identifier(tvb, offset, &class, &pc, &tag);
613 offset = get_ber_length(tree, tvb, offset, &len, &ind_field);
614 dissect_tcap_DialoguePDU(TRUE, tvb, 0, pinfo, tree, -1);
622 static int dissect_dialog_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
623 return dissect_tcap_Dialog1(TRUE, tvb, offset, pinfo, tree, hf_tcap_dialog);
627 static const ber_sequence_t ExternalPDU_sequence[] = {
628 { BER_CLASS_UNI, BER_UNI_TAG_OID, BER_FLAGS_NOOWNTAG, dissect_oid },
629 { BER_CLASS_CON, 0, BER_FLAGS_IMPLTAG, dissect_dialog_impl },
634 dissect_tcap_ExternalPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
635 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
636 ExternalPDU_sequence, hf_index, ett_tcap_ExternalPDU);
644 dissect_tcap_UserInfoOID(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
646 offset = dissect_ber_object_identifier_str(implicit_tag, pinfo, tree, tvb, offset, hf_index, &tcapext_oid);
648 pinfo->private_data = (void*)tcapext_oid;
654 static int dissect_useroid(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
655 return dissect_tcap_UserInfoOID(FALSE, tvb, offset, pinfo, tree, hf_tcap_useroid);
661 dissect_tcap_ExternUserInfo(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
667 guint32 len, start_offset;
670 * ok lets look at the oid and ssn and try and find a dissector, otherwise lets decode it.
672 ber_oid_dissector_table = find_dissector_table("ber.oid");
673 start_offset = offset;
674 offset = get_ber_identifier(tvb, offset, &class, &pc, &tag);
675 offset = get_ber_length(tree, tvb, offset, &len, &ind_field);
676 /* Use the recived length, XXX What if it was indefenet? length is good now */
677 next_tvb = tvb_new_subset(tvb, start_offset, len +(offset - start_offset), len+(offset - start_offset));
680 if (ber_oid_dissector_table && tcapext_oid){
681 if(!dissector_try_string(ber_oid_dissector_table, tcapext_oid, next_tvb, pinfo, tcap_top_tree))
685 dissect_tcap_param(pinfo,tree,next_tvb,0);
693 static int dissect_externuserinfo_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
694 return dissect_tcap_ExternUserInfo(TRUE, tvb, offset, pinfo, tree, hf_tcap_externuserinfo);
698 static const ber_sequence_t UserInformation_sequence[] = {
699 { BER_CLASS_UNI, BER_UNI_TAG_OID, BER_FLAGS_NOOWNTAG, dissect_useroid },
700 { BER_CLASS_CON, 0, BER_FLAGS_IMPLTAG, dissect_externuserinfo_impl },
705 dissect_tcap_UserInformation(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
706 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
707 UserInformation_sequence, hf_index, ett_tcap_UserInformation);
711 static int dissect_userInformation(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
712 return dissect_tcap_UserInformation(FALSE, tvb, offset, pinfo, tree, hf_tcap_userInformation);
716 static const value_string tcap_Release_request_reason_vals[] = {
719 { 30, "user-defined" },
725 dissect_tcap_Release_request_reason(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
726 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
731 static int dissect_reasonrq_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
732 return dissect_tcap_Release_request_reason(TRUE, tvb, offset, pinfo, tree, hf_tcap_reasonrq);
736 static const ber_sequence_t RLRQ_apdu_sequence[] = {
737 { BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_reasonrq_impl },
738 { BER_CLASS_CON, 30, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_user_information_impl },
743 dissect_tcap_RLRQ_apdu(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
744 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
745 RLRQ_apdu_sequence, hf_index, ett_tcap_RLRQ_apdu);
751 static const value_string tcap_Release_response_reason_vals[] = {
753 { 1, "not-finished" },
754 { 30, "user-defined" },
760 dissect_tcap_Release_response_reason(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
761 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
766 static int dissect_reasonre_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
767 return dissect_tcap_Release_response_reason(TRUE, tvb, offset, pinfo, tree, hf_tcap_reasonre);
771 static const ber_sequence_t RLRE_apdu_sequence[] = {
772 { BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_reasonre_impl },
773 { BER_CLASS_CON, 30, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_user_information_impl },
778 dissect_tcap_RLRE_apdu(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
779 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
780 RLRE_apdu_sequence, hf_index, ett_tcap_RLRE_apdu);
786 static const asn_namedbit T_protocol_version3_bits[] = {
787 { 0, &hf_tcap_T_protocol_version3_version1, -1, -1, "version1", NULL },
788 { 0, NULL, 0, 0, NULL, NULL }
792 dissect_tcap_T_protocol_version3(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
793 offset = dissect_ber_bitstring(implicit_tag, pinfo, tree, tvb, offset,
794 T_protocol_version3_bits, hf_index, ett_tcap_T_protocol_version3,
799 static int dissect_protocol_version3_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
800 return dissect_tcap_T_protocol_version3(TRUE, tvb, offset, pinfo, tree, hf_tcap_protocol_version3);
804 static const ber_sequence_t AUDT_apdu_sequence[] = {
805 { BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_protocol_version3_impl },
806 { BER_CLASS_CON, 1, 0, dissect_application_context_name },
807 { BER_CLASS_CON, 30, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_user_information_impl },
812 dissect_tcap_AUDT_apdu(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
813 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
814 AUDT_apdu_sequence, hf_index, ett_tcap_AUDT_apdu);
818 static int dissect_unidialoguePDU(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
819 return dissect_tcap_AUDT_apdu(FALSE, tvb, offset, pinfo, tree, hf_tcap_unidialoguePDU);
823 static const value_string tcap_UniDialoguePDU_vals[] = {
824 { 0, "unidialoguePDU" },
828 static const ber_choice_t UniDialoguePDU_choice[] = {
829 { 0, BER_CLASS_APP, 0, BER_FLAGS_NOOWNTAG, dissect_unidialoguePDU },
834 dissect_tcap_UniDialoguePDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
835 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
836 UniDialoguePDU_choice, hf_index, ett_tcap_UniDialoguePDU,
845 dissect_tcap_DialogueOC(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
855 offset = get_ber_identifier(tvb, offset, &class, &pc, &tag);
856 offset = get_ber_length(tree, tvb, offset, &len, &ind_field);
857 next_tvb = tvb_new_subset(tvb, offset, len-(2*ind_field), len-(2*ind_field));
863 dissect_tcap_ExternalPDU(TRUE, next_tvb, 2, pinfo, tree, -1);
876 dissect_tcap_DialoguePortion(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
877 offset = dissect_tcap_DialogueOC(implicit_tag, tvb, offset, pinfo, tree, hf_index);
881 static int dissect_dialoguePortion(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
882 return dissect_tcap_DialoguePortion(FALSE, tvb, offset, pinfo, tree, hf_tcap_dialoguePortion);
884 static int dissect_u_abortCause(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
885 return dissect_tcap_DialoguePortion(FALSE, tvb, offset, pinfo, tree, hf_tcap_u_abortCause);
891 dissect_tcap_InvokeIdType(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
892 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
897 static int dissect_invokeID(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
898 return dissect_tcap_InvokeIdType(FALSE, tvb, offset, pinfo, tree, hf_tcap_invokeID);
900 static int dissect_linkedID_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
901 return dissect_tcap_InvokeIdType(TRUE, tvb, offset, pinfo, tree, hf_tcap_linkedID);
903 static int dissect_derivable(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
904 return dissect_tcap_InvokeIdType(FALSE, tvb, offset, pinfo, tree, hf_tcap_derivable);
910 dissect_tcap_INTEGER(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
911 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
916 static int dissect_localValue(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
917 return dissect_tcap_INTEGER(FALSE, tvb, offset, pinfo, tree, hf_tcap_localValue);
919 static int dissect_integerSecurityId_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
920 return dissect_tcap_INTEGER(TRUE, tvb, offset, pinfo, tree, hf_tcap_integerSecurityId);
922 static int dissect_integerConfidentialityId_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
923 return dissect_tcap_INTEGER(TRUE, tvb, offset, pinfo, tree, hf_tcap_integerConfidentialityId);
925 static int dissect_private_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
926 return dissect_tcap_INTEGER(TRUE, tvb, offset, pinfo, tree, hf_tcap_private);
928 static int dissect_privateer_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
929 return dissect_tcap_INTEGER(TRUE, tvb, offset, pinfo, tree, hf_tcap_privateer);
933 static const value_string tcap_OPERATION_vals[] = {
935 { 1, "globalValue" },
939 static const ber_choice_t OPERATION_choice[] = {
940 { 0, BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_localValue },
941 { 1, BER_CLASS_UNI, BER_UNI_TAG_OID, BER_FLAGS_NOOWNTAG, dissect_globalValue },
946 dissect_tcap_OPERATION(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
947 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
948 OPERATION_choice, hf_index, ett_tcap_OPERATION,
953 static int dissect_opCode(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
954 return dissect_tcap_OPERATION(FALSE, tvb, offset, pinfo, tree, hf_tcap_opCode);
960 dissect_tcap_Parameter(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
970 offset = get_ber_identifier(tvb, offset, &class, &pc, &tag);
971 offset = get_ber_length(tree, tvb, offset, &len, &ind_field);
972 /* need to strip the EOC off the next_tvb */
973 next_tvb = tvb_new_subset(tvb, offset, len-(2*ind_field), len-(2*ind_field));
977 dissect_tcap_param(pinfo,tree,tvb,0);
985 static int dissect_parameter(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
986 return dissect_tcap_Parameter(FALSE, tvb, offset, pinfo, tree, hf_tcap_parameter);
990 static const ber_sequence_t Invoke_sequence[] = {
991 { BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_invokeID },
992 { BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_linkedID_impl },
993 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_opCode },
994 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_parameter },
999 dissect_tcap_Invoke(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1000 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1001 Invoke_sequence, hf_index, ett_tcap_Invoke);
1005 static int dissect_invoke_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1006 return dissect_tcap_Invoke(TRUE, tvb, offset, pinfo, tree, hf_tcap_invoke);
1010 static const ber_sequence_t T_resultretres_sequence[] = {
1011 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_opCode },
1012 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_parameter },
1017 dissect_tcap_T_resultretres(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1018 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1019 T_resultretres_sequence, hf_index, ett_tcap_T_resultretres);
1023 static int dissect_resultretres(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1024 return dissect_tcap_T_resultretres(FALSE, tvb, offset, pinfo, tree, hf_tcap_resultretres);
1028 static const ber_sequence_t ReturnResult_sequence[] = {
1029 { BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_invokeID },
1030 { BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_resultretres },
1035 dissect_tcap_ReturnResult(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1036 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1037 ReturnResult_sequence, hf_index, ett_tcap_ReturnResult);
1041 static int dissect_returnResultLast_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1042 return dissect_tcap_ReturnResult(TRUE, tvb, offset, pinfo, tree, hf_tcap_returnResultLast);
1044 static int dissect_returnResultNotLast_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1045 return dissect_tcap_ReturnResult(TRUE, tvb, offset, pinfo, tree, hf_tcap_returnResultNotLast);
1051 dissect_tcap_INTEGER_M32768_32767(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1052 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
1057 static int dissect_national_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1058 return dissect_tcap_INTEGER_M32768_32767(TRUE, tvb, offset, pinfo, tree, hf_tcap_national);
1060 static int dissect_nationaler_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1061 return dissect_tcap_INTEGER_M32768_32767(TRUE, tvb, offset, pinfo, tree, hf_tcap_nationaler);
1065 static const value_string tcap_ErrorCode_vals[] = {
1066 { 19, "nationaler" },
1067 { 20, "privateer" },
1071 static const ber_choice_t ErrorCode_choice[] = {
1072 { 19, BER_CLASS_PRI, 19, BER_FLAGS_IMPLTAG, dissect_nationaler_impl },
1073 { 20, BER_CLASS_PRI, 20, BER_FLAGS_IMPLTAG, dissect_privateer_impl },
1074 { 0, 0, 0, 0, NULL }
1078 dissect_tcap_ErrorCode(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1079 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
1080 ErrorCode_choice, hf_index, ett_tcap_ErrorCode,
1085 static int dissect_errorCode(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1086 return dissect_tcap_ErrorCode(FALSE, tvb, offset, pinfo, tree, hf_tcap_errorCode);
1090 static const ber_sequence_t ReturnError_sequence[] = {
1091 { BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_invokeID },
1092 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_errorCode },
1093 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_parameter },
1098 dissect_tcap_ReturnError(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1099 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1100 ReturnError_sequence, hf_index, ett_tcap_ReturnError);
1104 static int dissect_returnError_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1105 return dissect_tcap_ReturnError(TRUE, tvb, offset, pinfo, tree, hf_tcap_returnError);
1111 dissect_tcap_NULL(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1112 offset = dissect_ber_null(implicit_tag, pinfo, tree, tvb, offset, hf_index);
1116 static int dissect_not_derivable(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1117 return dissect_tcap_NULL(FALSE, tvb, offset, pinfo, tree, hf_tcap_not_derivable);
1121 static const value_string tcap_T_invokeIDRej_vals[] = {
1123 { 1, "not-derivable" },
1127 static const ber_choice_t T_invokeIDRej_choice[] = {
1128 { 0, BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_derivable },
1129 { 1, BER_CLASS_UNI, BER_UNI_TAG_NULL, BER_FLAGS_NOOWNTAG, dissect_not_derivable },
1130 { 0, 0, 0, 0, NULL }
1134 dissect_tcap_T_invokeIDRej(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1135 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
1136 T_invokeIDRej_choice, hf_index, ett_tcap_T_invokeIDRej,
1141 static int dissect_invokeIDRej(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1142 return dissect_tcap_T_invokeIDRej(FALSE, tvb, offset, pinfo, tree, hf_tcap_invokeIDRej);
1146 static const value_string tcap_GeneralProblem_vals[] = {
1147 { 0, "unrecognizedComponent" },
1148 { 1, "mistypedComponent" },
1149 { 2, "badlyStructuredComponent" },
1155 dissect_tcap_GeneralProblem(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1156 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
1161 static int dissect_generalProblem_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1162 return dissect_tcap_GeneralProblem(TRUE, tvb, offset, pinfo, tree, hf_tcap_generalProblem);
1166 static const value_string tcap_InvokeProblem_vals[] = {
1167 { 0, "duplicateInvokeID" },
1168 { 1, "unrecognizedOperation" },
1169 { 2, "mistypedParameter" },
1170 { 3, "resourceLimitation" },
1171 { 4, "initiatingRelease" },
1172 { 5, "unrecognizedLinkedID" },
1173 { 6, "linkedResponseUnexpected" },
1174 { 7, "unexpectedLinkedOperation" },
1180 dissect_tcap_InvokeProblem(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1181 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
1186 static int dissect_invokeProblem_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1187 return dissect_tcap_InvokeProblem(TRUE, tvb, offset, pinfo, tree, hf_tcap_invokeProblem);
1191 static const value_string tcap_ReturnResultProblem_vals[] = {
1192 { 0, "unrecognizedInvokeID" },
1193 { 1, "returnResultUnexpected" },
1194 { 2, "mistypedParameter" },
1200 dissect_tcap_ReturnResultProblem(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1201 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
1206 static int dissect_returnResultProblem_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1207 return dissect_tcap_ReturnResultProblem(TRUE, tvb, offset, pinfo, tree, hf_tcap_returnResultProblem);
1211 static const value_string tcap_ReturnErrorProblem_vals[] = {
1212 { 0, "unrecognizedInvokeID" },
1213 { 1, "returnErrorUnexpected" },
1214 { 2, "unrecognizedError" },
1215 { 3, "unexpectedError" },
1216 { 4, "mistypedParameter" },
1222 dissect_tcap_ReturnErrorProblem(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1223 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
1228 static int dissect_returnErrorProblem_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1229 return dissect_tcap_ReturnErrorProblem(TRUE, tvb, offset, pinfo, tree, hf_tcap_returnErrorProblem);
1233 static const value_string tcap_T_problem_vals[] = {
1234 { 0, "generalProblem" },
1235 { 1, "invokeProblem" },
1236 { 2, "returnResultProblem" },
1237 { 3, "returnErrorProblem" },
1241 static const ber_choice_t T_problem_choice[] = {
1242 { 0, BER_CLASS_CON, 0, BER_FLAGS_IMPLTAG, dissect_generalProblem_impl },
1243 { 1, BER_CLASS_CON, 1, BER_FLAGS_IMPLTAG, dissect_invokeProblem_impl },
1244 { 2, BER_CLASS_CON, 2, BER_FLAGS_IMPLTAG, dissect_returnResultProblem_impl },
1245 { 3, BER_CLASS_CON, 3, BER_FLAGS_IMPLTAG, dissect_returnErrorProblem_impl },
1246 { 0, 0, 0, 0, NULL }
1250 dissect_tcap_T_problem(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1251 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
1252 T_problem_choice, hf_index, ett_tcap_T_problem,
1257 static int dissect_problem(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1258 return dissect_tcap_T_problem(FALSE, tvb, offset, pinfo, tree, hf_tcap_problem);
1262 static const ber_sequence_t Reject_sequence[] = {
1263 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_invokeIDRej },
1264 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_problem },
1269 dissect_tcap_Reject(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1270 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1271 Reject_sequence, hf_index, ett_tcap_Reject);
1275 static int dissect_reject_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1276 return dissect_tcap_Reject(TRUE, tvb, offset, pinfo, tree, hf_tcap_reject);
1280 static const value_string tcap_Component_vals[] = {
1282 { 2, "returnResultLast" },
1283 { 3, "returnError" },
1285 { 7, "returnResultNotLast" },
1289 static const ber_choice_t Component_choice[] = {
1290 { 1, BER_CLASS_CON, 1, BER_FLAGS_IMPLTAG, dissect_invoke_impl },
1291 { 2, BER_CLASS_CON, 2, BER_FLAGS_IMPLTAG, dissect_returnResultLast_impl },
1292 { 3, BER_CLASS_CON, 3, BER_FLAGS_IMPLTAG, dissect_returnError_impl },
1293 { 4, BER_CLASS_CON, 4, BER_FLAGS_IMPLTAG, dissect_reject_impl },
1294 { 7, BER_CLASS_CON, 7, BER_FLAGS_IMPLTAG, dissect_returnResultNotLast_impl },
1295 { 0, 0, 0, 0, NULL }
1299 dissect_tcap_Component(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1305 guint32 len, s_offset;
1308 * ok lets look at the oid and ssn and try and find a dissector, otherwise lets decode it.
1310 ber_oid_dissector_table = find_dissector_table("ber.oid");
1312 offset = get_ber_identifier(tvb, offset, &class, &pc, &tag);
1313 offset = get_ber_length(tree, tvb, offset, &len, &ind_field);
1314 /* we can believe the length now */
1315 next_tvb = tvb_new_subset(tvb, s_offset, len+(offset-s_offset), len+(offset-s_offset));
1319 dissect_ber_choice(pinfo, tree, next_tvb, 0,
1320 Component_choice, hf_index, ett_tcap_Component,NULL);
1322 if (ber_oid_dissector_table && cur_oid){
1323 if(!dissector_try_string(ber_oid_dissector_table, cur_oid, next_tvb, pinfo, tcap_top_tree))
1325 dissector_handle_t subdissector_handle;
1327 if (! (subdissector_handle = get_itu_tcap_subdissector(pinfo->match_port))) {
1328 subdissector_handle = data_handle;
1331 call_dissector(subdissector_handle, next_tvb, pinfo, tcap_top_tree);
1336 dissector_handle_t subdissector_handle;
1338 if (! (subdissector_handle = get_itu_tcap_subdissector(pinfo->match_port))) {
1339 subdissector_handle = data_handle;
1342 call_dissector(subdissector_handle, next_tvb, pinfo, tcap_top_tree);
1351 static int dissect_ComponentPortion_item(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1352 return dissect_tcap_Component(FALSE, tvb, offset, pinfo, tree, hf_tcap_ComponentPortion_item);
1356 static const ber_sequence_t ComponentPortion_sequence_of[1] = {
1357 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_ComponentPortion_item },
1361 dissect_tcap_ComponentPortion(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1362 offset = dissect_ber_sequence_of(implicit_tag, pinfo, tree, tvb, offset,
1363 ComponentPortion_sequence_of, hf_index, ett_tcap_ComponentPortion);
1367 static int dissect_components(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1368 return dissect_tcap_ComponentPortion(FALSE, tvb, offset, pinfo, tree, hf_tcap_components);
1372 static const ber_sequence_t Unidirectional_sequence[] = {
1373 { BER_CLASS_APP, 11, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_dialoguePortion },
1374 { BER_CLASS_APP, 12, BER_FLAGS_NOOWNTAG, dissect_components },
1379 dissect_tcap_Unidirectional(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1380 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1381 Unidirectional_sequence, hf_index, ett_tcap_Unidirectional);
1385 static int dissect_unidirectional_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1386 return dissect_tcap_Unidirectional(TRUE, tvb, offset, pinfo, tree, hf_tcap_unidirectional);
1392 dissect_tcap_OrigTransactionID(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1393 #line 203 "tcap.cnf"
1394 tvbuff_t *parameter_tvb;
1396 proto_item *tid_item;
1397 proto_tree *subtree;
1398 tid_item = proto_tree_add_text(tree, tvb, offset, -1, "Source Transaction ID");
1399 subtree = proto_item_add_subtree(tid_item, ett_otid);
1400 offset = dissect_ber_octet_string(implicit_tag, pinfo, subtree, tvb, offset, hf_tcap_tid,
1404 len = tvb_length_remaining(parameter_tvb, 0);
1405 if ((len)&&(check_col(pinfo->cinfo, COL_INFO))){
1406 col_append_fstr(pinfo->cinfo, COL_INFO, "otid(");
1408 col_append_fstr(pinfo->cinfo, COL_INFO, "%02x",tvb_get_guint8(parameter_tvb,i));
1409 col_append_fstr(pinfo->cinfo, COL_INFO, ") ");
1419 static int dissect_otid(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1420 return dissect_tcap_OrigTransactionID(FALSE, tvb, offset, pinfo, tree, hf_tcap_otid);
1424 static const ber_sequence_t Begin_sequence[] = {
1425 { BER_CLASS_APP, 8, BER_FLAGS_NOOWNTAG, dissect_otid },
1426 { BER_CLASS_APP, 11, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_dialoguePortion },
1427 { BER_CLASS_APP, 12, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_components },
1432 dissect_tcap_Begin(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1433 #line 244 "tcap.cnf"
1434 if (check_col(pinfo->cinfo, COL_INFO))
1435 col_append_fstr(pinfo->cinfo, COL_INFO, " Begin ");
1436 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1437 Begin_sequence, hf_index, ett_tcap_Begin);
1442 static int dissect_begin_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1443 return dissect_tcap_Begin(TRUE, tvb, offset, pinfo, tree, hf_tcap_begin);
1449 dissect_tcap_DestTransactionID(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1450 #line 225 "tcap.cnf"
1451 tvbuff_t *parameter_tvb;
1453 proto_item *tid_item;
1454 proto_tree *subtree;
1455 tid_item = proto_tree_add_text(tree, tvb, offset, -1, "Destination Transaction ID");
1456 subtree = proto_item_add_subtree(tid_item, ett_otid);
1457 offset = dissect_ber_octet_string(implicit_tag, pinfo, subtree, tvb, offset, hf_tcap_tid,
1461 len = tvb_length_remaining(parameter_tvb, 0);
1462 if ((len)&&(check_col(pinfo->cinfo, COL_INFO))){
1463 col_append_fstr(pinfo->cinfo, COL_INFO, "dtid(");
1465 col_append_fstr(pinfo->cinfo, COL_INFO, "%02x",tvb_get_guint8(parameter_tvb,i));
1466 col_append_fstr(pinfo->cinfo, COL_INFO, ") ");
1473 static int dissect_dtid(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1474 return dissect_tcap_DestTransactionID(FALSE, tvb, offset, pinfo, tree, hf_tcap_dtid);
1478 static const ber_sequence_t End_sequence[] = {
1479 { BER_CLASS_APP, 9, BER_FLAGS_NOOWNTAG, dissect_dtid },
1480 { BER_CLASS_APP, 11, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_dialoguePortion },
1481 { BER_CLASS_APP, 12, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_components },
1486 dissect_tcap_End(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1487 #line 249 "tcap.cnf"
1488 if (check_col(pinfo->cinfo, COL_INFO))
1489 col_append_fstr(pinfo->cinfo, COL_INFO, " End ");
1490 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1491 End_sequence, hf_index, ett_tcap_End);
1496 static int dissect_end_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1497 return dissect_tcap_End(TRUE, tvb, offset, pinfo, tree, hf_tcap_end);
1501 static const ber_sequence_t Continue_sequence[] = {
1502 { BER_CLASS_APP, 8, BER_FLAGS_NOOWNTAG, dissect_otid },
1503 { BER_CLASS_APP, 9, BER_FLAGS_NOOWNTAG, dissect_dtid },
1504 { BER_CLASS_APP, 11, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_dialoguePortion },
1505 { BER_CLASS_APP, 12, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_components },
1510 dissect_tcap_Continue(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1511 #line 254 "tcap.cnf"
1512 if (check_col(pinfo->cinfo, COL_INFO))
1513 col_append_fstr(pinfo->cinfo, COL_INFO, " Continue ");
1514 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1515 Continue_sequence, hf_index, ett_tcap_Continue);
1520 static int dissect_continue_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1521 return dissect_tcap_Continue(TRUE, tvb, offset, pinfo, tree, hf_tcap_continue);
1525 static const value_string tcap_P_AbortCause_vals[] = {
1526 { 0, "unrecognizedMessageType" },
1527 { 1, "unrecognizedTransactionID" },
1528 { 2, "badlyFormattedTransactionPortion" },
1529 { 3, "incorrectTransactionPortion" },
1530 { 4, "resourceLimitation" },
1536 dissect_tcap_P_AbortCause(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1537 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
1542 static int dissect_p_abortCause(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1543 return dissect_tcap_P_AbortCause(FALSE, tvb, offset, pinfo, tree, hf_tcap_p_abortCause);
1547 static const value_string tcap_Reason_vals[] = {
1548 { 10, "p-abortCause" },
1549 { 11, "u-abortCause" },
1553 static const ber_choice_t Reason_choice[] = {
1554 { 10, BER_CLASS_APP, 10, BER_FLAGS_NOOWNTAG, dissect_p_abortCause },
1555 { 11, BER_CLASS_APP, 11, BER_FLAGS_NOOWNTAG, dissect_u_abortCause },
1556 { 0, 0, 0, 0, NULL }
1560 dissect_tcap_Reason(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1561 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
1562 Reason_choice, hf_index, ett_tcap_Reason,
1567 static int dissect_reason(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1568 return dissect_tcap_Reason(FALSE, tvb, offset, pinfo, tree, hf_tcap_reason);
1572 static const ber_sequence_t Abort_sequence[] = {
1573 { BER_CLASS_APP, 9, BER_FLAGS_NOOWNTAG, dissect_dtid },
1574 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_reason },
1579 dissect_tcap_Abort(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1580 #line 259 "tcap.cnf"
1581 if (check_col(pinfo->cinfo, COL_INFO))
1582 col_append_fstr(pinfo->cinfo, COL_INFO, " Abort ");
1583 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1584 Abort_sequence, hf_index, ett_tcap_Abort);
1589 static int dissect_abort_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1590 return dissect_tcap_Abort(TRUE, tvb, offset, pinfo, tree, hf_tcap_abort);
1596 dissect_tcap_TransactionID(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1597 offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index,
1602 static int dissect_identifier(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1603 return dissect_tcap_TransactionID(FALSE, tvb, offset, pinfo, tree, hf_tcap_identifier);
1609 dissect_tcap_ProtocolVersion(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1610 offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index,
1615 static int dissect_version(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1616 return dissect_tcap_ProtocolVersion(FALSE, tvb, offset, pinfo, tree, hf_tcap_version);
1622 dissect_tcap_IntegerApplicationContext(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1623 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
1628 static int dissect_integerApplicationId(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1629 return dissect_tcap_IntegerApplicationContext(FALSE, tvb, offset, pinfo, tree, hf_tcap_integerApplicationId);
1635 dissect_tcap_ObjectIDApplicationContext(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1636 offset = dissect_ber_object_identifier(implicit_tag, pinfo, tree, tvb, offset, hf_index, NULL);
1640 static int dissect_objectApplicationId(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1641 return dissect_tcap_ObjectIDApplicationContext(FALSE, tvb, offset, pinfo, tree, hf_tcap_objectApplicationId);
1645 static const value_string tcap_T_applicationContext_vals[] = {
1646 { 27, "integerApplicationId" },
1647 { 28, "objectApplicationId" },
1651 static const ber_choice_t T_applicationContext_choice[] = {
1652 { 27, BER_CLASS_PRI, 27, BER_FLAGS_NOOWNTAG, dissect_integerApplicationId },
1653 { 28, BER_CLASS_PRI, 28, BER_FLAGS_NOOWNTAG, dissect_objectApplicationId },
1654 { 0, 0, 0, 0, NULL }
1658 dissect_tcap_T_applicationContext(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1659 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
1660 T_applicationContext_choice, hf_index, ett_tcap_T_applicationContext,
1665 static int dissect_applicationContext(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1666 return dissect_tcap_T_applicationContext(FALSE, tvb, offset, pinfo, tree, hf_tcap_applicationContext);
1670 static const value_string tcap_T_securityContext_vals[] = {
1671 { 0, "integerSecurityId" },
1672 { 1, "objectSecurityId" },
1676 static const ber_choice_t T_securityContext_choice[] = {
1677 { 0, BER_CLASS_CON, 0, BER_FLAGS_IMPLTAG, dissect_integerSecurityId_impl },
1678 { 1, BER_CLASS_CON, 1, BER_FLAGS_IMPLTAG, dissect_objectSecurityId_impl },
1679 { 0, 0, 0, 0, NULL }
1683 dissect_tcap_T_securityContext(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1684 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
1685 T_securityContext_choice, hf_index, ett_tcap_T_securityContext,
1690 static int dissect_securityContext(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1691 return dissect_tcap_T_securityContext(FALSE, tvb, offset, pinfo, tree, hf_tcap_securityContext);
1695 static const value_string tcap_T_confidentialityId_vals[] = {
1696 { 0, "integerConfidentialityId" },
1697 { 1, "objectConfidentialityId" },
1701 static const ber_choice_t T_confidentialityId_choice[] = {
1702 { 0, BER_CLASS_CON, 0, BER_FLAGS_IMPLTAG, dissect_integerConfidentialityId_impl },
1703 { 1, BER_CLASS_CON, 1, BER_FLAGS_IMPLTAG, dissect_objectConfidentialityId_impl },
1704 { 0, 0, 0, 0, NULL }
1708 dissect_tcap_T_confidentialityId(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1709 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
1710 T_confidentialityId_choice, hf_index, ett_tcap_T_confidentialityId,
1715 static int dissect_confidentialityId(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1716 return dissect_tcap_T_confidentialityId(FALSE, tvb, offset, pinfo, tree, hf_tcap_confidentialityId);
1720 static const ber_sequence_t Confidentiality_sequence[] = {
1721 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_confidentialityId },
1726 dissect_tcap_Confidentiality(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1727 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1728 Confidentiality_sequence, hf_index, ett_tcap_Confidentiality);
1732 static int dissect_confidentiality_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1733 return dissect_tcap_Confidentiality(TRUE, tvb, offset, pinfo, tree, hf_tcap_confidentiality);
1737 static const ber_sequence_t DialoguePortionANSI_sequence[] = {
1738 { BER_CLASS_PRI, 26, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_version },
1739 { BER_CLASS_CON, 0, BER_FLAGS_OPTIONAL, dissect_applicationContext },
1740 { BER_CLASS_UNI, 8, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_userInformation },
1741 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_securityContext },
1742 { BER_CLASS_CON, 2, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_confidentiality_impl },
1747 dissect_tcap_DialoguePortionANSI(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1748 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1749 DialoguePortionANSI_sequence, hf_index, ett_tcap_DialoguePortionANSI);
1753 static int dissect_dialoguePortionansi(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1754 return dissect_tcap_DialoguePortionANSI(FALSE, tvb, offset, pinfo, tree, hf_tcap_dialoguePortionansi);
1760 dissect_tcap_OCTET_STRING_SIZE_0_2(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1761 offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index,
1766 static int dissect_componentIDs_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1767 return dissect_tcap_OCTET_STRING_SIZE_0_2(TRUE, tvb, offset, pinfo, tree, hf_tcap_componentIDs);
1771 static const value_string tcap_OperationCode_vals[] = {
1777 static const ber_choice_t OperationCode_choice[] = {
1778 { 16, BER_CLASS_PRI, 16, BER_FLAGS_IMPLTAG, dissect_national_impl },
1779 { 17, BER_CLASS_PRI, 17, BER_FLAGS_IMPLTAG, dissect_private_impl },
1780 { 0, 0, 0, 0, NULL }
1784 dissect_tcap_OperationCode(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1785 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
1786 OperationCode_choice, hf_index, ett_tcap_OperationCode,
1791 static int dissect_operationCode(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1792 return dissect_tcap_OperationCode(FALSE, tvb, offset, pinfo, tree, hf_tcap_operationCode);
1798 dissect_tcap_ANSIParameters(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1799 #line 177 "tcap.cnf"
1800 /* we are doing the ParamSet here so need to look at the tags*/
1802 len = tvb_length_remaining(tvb, offset);
1803 if (len > 2) /* arghhh I dont know whether this is constructed or not! */
1804 offset = dissect_tcap_param(pinfo,tree,tvb,offset);
1806 offset = dissect_ber_octet_string(TRUE, pinfo, tree, tvb, 0, hf_index,
1814 static int dissect_ansiparams(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1815 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams);
1817 static int dissect_ansiparams1(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1818 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams1);
1820 static int dissect_ansiparams2(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1821 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams2);
1823 static int dissect_ansiparams3(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1824 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams3);
1826 static int dissect_ansiparams4(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1827 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams4);
1829 static int dissect_ansiparams5(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1830 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams5);
1832 static int dissect_ansiparams6(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1833 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams6);
1835 static int dissect_ansiparams7(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1836 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams7);
1838 static int dissect_ansiparams8(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1839 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams8);
1841 static int dissect_ansiparams9(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1842 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams9);
1844 static int dissect_ansiparams10(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1845 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams10);
1847 static int dissect_ansiparams11(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1848 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams11);
1850 static int dissect_ansiparams12(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1851 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams12);
1853 static int dissect_ansiparams13(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1854 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams13);
1856 static int dissect_ansiparams14(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1857 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams14);
1859 static int dissect_ansiparams15(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1860 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams15);
1862 static int dissect_ansiparams16(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1863 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams16);
1865 static int dissect_ansiparams17(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1866 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams17);
1868 static int dissect_ansiparams18(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1869 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams18);
1871 static int dissect_ansiparams19(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1872 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams19);
1874 static int dissect_ansiparams20(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1875 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams20);
1877 static int dissect_ansiparams21(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1878 return dissect_tcap_ANSIParameters(FALSE, tvb, offset, pinfo, tree, hf_tcap_ansiparams21);
1882 static const ber_sequence_t ANSIparamch_sequence[] = {
1883 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams },
1884 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams1 },
1885 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams2 },
1886 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams3 },
1887 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams4 },
1888 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams5 },
1889 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams6 },
1890 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams7 },
1891 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams8 },
1892 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams9 },
1893 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams10 },
1894 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams11 },
1895 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams12 },
1896 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams13 },
1897 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams14 },
1898 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams15 },
1899 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams16 },
1900 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams17 },
1901 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams18 },
1902 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams19 },
1903 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams20 },
1904 { BER_CLASS_ANY, 0, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_ansiparams21 },
1909 dissect_tcap_ANSIparamch(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1910 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1911 ANSIparamch_sequence, hf_index, ett_tcap_ANSIparamch);
1915 static int dissect_parameterinv(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1916 return dissect_tcap_ANSIparamch(FALSE, tvb, offset, pinfo, tree, hf_tcap_parameterinv);
1918 static int dissect_parameterrr(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1919 return dissect_tcap_ANSIparamch(FALSE, tvb, offset, pinfo, tree, hf_tcap_parameterrr);
1921 static int dissect_parameterre(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1922 return dissect_tcap_ANSIparamch(FALSE, tvb, offset, pinfo, tree, hf_tcap_parameterre);
1924 static int dissect_parameterrj(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1925 return dissect_tcap_ANSIparamch(FALSE, tvb, offset, pinfo, tree, hf_tcap_parameterrj);
1929 static const ber_sequence_t InvokePDU_sequence[] = {
1930 { BER_CLASS_PRI, 15, BER_FLAGS_OPTIONAL|BER_FLAGS_IMPLTAG, dissect_componentIDs_impl },
1931 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_operationCode },
1932 { BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_parameterinv },
1937 dissect_tcap_InvokePDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1938 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1939 InvokePDU_sequence, hf_index, ett_tcap_InvokePDU);
1943 static int dissect_invokeLastansi_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1944 return dissect_tcap_InvokePDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_invokeLastansi);
1946 static int dissect_invokeNotLastansi_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1947 return dissect_tcap_InvokePDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_invokeNotLastansi);
1953 dissect_tcap_ComponentID(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1954 offset = dissect_ber_octet_string(implicit_tag, pinfo, tree, tvb, offset, hf_index,
1959 static int dissect_componentID(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1960 return dissect_tcap_ComponentID(FALSE, tvb, offset, pinfo, tree, hf_tcap_componentID);
1964 static const ber_sequence_t ReturnResultPDU_sequence[] = {
1965 { BER_CLASS_PRI, 15, BER_FLAGS_NOOWNTAG, dissect_componentID },
1966 { BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_parameterrr },
1971 dissect_tcap_ReturnResultPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1972 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1973 ReturnResultPDU_sequence, hf_index, ett_tcap_ReturnResultPDU);
1977 static int dissect_returnResultLastansi_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1978 return dissect_tcap_ReturnResultPDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_returnResultLastansi);
1980 static int dissect_returnResultNotLastansi_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
1981 return dissect_tcap_ReturnResultPDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_returnResultNotLastansi);
1985 static const ber_sequence_t ReturnErrorPDU_sequence[] = {
1986 { BER_CLASS_PRI, 15, BER_FLAGS_NOOWNTAG, dissect_componentID },
1987 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_errorCode },
1988 { BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_parameterre },
1993 dissect_tcap_ReturnErrorPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
1994 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
1995 ReturnErrorPDU_sequence, hf_index, ett_tcap_ReturnErrorPDU);
1999 static int dissect_returnErroransi_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2000 return dissect_tcap_ReturnErrorPDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_returnErroransi);
2004 static const value_string tcap_ProblemPDU_vals[] = {
2005 { 257, "general-unrecognisedComponentType" },
2006 { 258, "general-incorrectComponentPortion" },
2007 { 259, "general-badlyStructuredCompPortion" },
2013 dissect_tcap_ProblemPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
2014 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
2019 static int dissect_rejectProblem_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2020 return dissect_tcap_ProblemPDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_rejectProblem);
2024 static const ber_sequence_t RejectPDU_sequence[] = {
2025 { BER_CLASS_PRI, 15, BER_FLAGS_NOOWNTAG, dissect_componentID },
2026 { BER_CLASS_PRI, 21, BER_FLAGS_IMPLTAG, dissect_rejectProblem_impl },
2027 { BER_CLASS_UNI, BER_UNI_TAG_SEQUENCE, BER_FLAGS_NOOWNTAG, dissect_parameterrj },
2032 dissect_tcap_RejectPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
2033 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
2034 RejectPDU_sequence, hf_index, ett_tcap_RejectPDU);
2038 static int dissect_rejectansi_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2039 return dissect_tcap_RejectPDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_rejectansi);
2043 static const value_string tcap_ComponentPDU_vals[] = {
2044 { 9, "invokeLastansi" },
2045 { 10, "returnResultLastansi" },
2046 { 11, "returnErroransi" },
2047 { 12, "rejectansi" },
2048 { 13, "invokeNotLastansi" },
2049 { 14, "returnResultNotLastansi" },
2053 static const ber_choice_t ComponentPDU_choice[] = {
2054 { 9, BER_CLASS_PRI, 9, BER_FLAGS_IMPLTAG, dissect_invokeLastansi_impl },
2055 { 10, BER_CLASS_PRI, 10, BER_FLAGS_IMPLTAG, dissect_returnResultLastansi_impl },
2056 { 11, BER_CLASS_PRI, 11, BER_FLAGS_IMPLTAG, dissect_returnErroransi_impl },
2057 { 12, BER_CLASS_PRI, 12, BER_FLAGS_IMPLTAG, dissect_rejectansi_impl },
2058 { 13, BER_CLASS_PRI, 13, BER_FLAGS_IMPLTAG, dissect_invokeNotLastansi_impl },
2059 { 14, BER_CLASS_PRI, 14, BER_FLAGS_IMPLTAG, dissect_returnResultNotLastansi_impl },
2060 { 0, 0, 0, 0, NULL }
2064 dissect_tcap_ComponentPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
2065 #line 188 "tcap.cnf"
2067 dissector_handle_t subdissector_handle;
2069 next_tvb = tvb_new_subset(tvb, offset, tvb_length_remaining(tvb, offset), tvb_length_remaining(tvb, offset));
2071 if (! (subdissector_handle = get_ansi_tcap_subdissector(pinfo->match_port))) {
2072 subdissector_handle = data_handle;
2075 call_dissector(subdissector_handle, next_tvb, pinfo, tcap_top_tree);
2077 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
2078 ComponentPDU_choice, hf_index, ett_tcap_ComponentPDU,NULL);
2084 static int dissect_ComponentSequence_item(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2085 return dissect_tcap_ComponentPDU(FALSE, tvb, offset, pinfo, tree, hf_tcap_ComponentSequence_item);
2089 static const ber_sequence_t ComponentSequence_sequence_of[1] = {
2090 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_ComponentSequence_item },
2094 dissect_tcap_ComponentSequence(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
2095 offset = dissect_ber_sequence_of(implicit_tag, pinfo, tree, tvb, offset,
2096 ComponentSequence_sequence_of, hf_index, ett_tcap_ComponentSequence);
2100 static int dissect_componentPortion(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2101 return dissect_tcap_ComponentSequence(FALSE, tvb, offset, pinfo, tree, hf_tcap_componentPortion);
2105 static const ber_sequence_t UniTransactionPDU_sequence[] = {
2106 { BER_CLASS_PRI, 7, BER_FLAGS_NOOWNTAG, dissect_identifier },
2107 { BER_CLASS_PRI, 25, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_dialoguePortionansi },
2108 { BER_CLASS_PRI, 8, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_componentPortion },
2113 dissect_tcap_UniTransactionPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
2114 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
2115 UniTransactionPDU_sequence, hf_index, ett_tcap_UniTransactionPDU);
2119 static int dissect_ansiunidirectional_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2120 return dissect_tcap_UniTransactionPDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_ansiunidirectional);
2124 static const ber_sequence_t TransactionPDU_sequence[] = {
2125 { BER_CLASS_PRI, 7, BER_FLAGS_NOOWNTAG, dissect_identifier },
2126 { BER_CLASS_PRI, 25, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_dialoguePortionansi },
2127 { BER_CLASS_PRI, 8, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_componentPortion },
2132 dissect_tcap_TransactionPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
2133 #line 269 "tcap.cnf"
2134 if ((hf_index == hf_tcap_ansiqueryWithPerm)&&(check_col(pinfo->cinfo, COL_INFO)))
2135 col_append_fstr(pinfo->cinfo, COL_INFO, " QueryWithPerm");
2137 if ((hf_index == hf_tcap_ansiqueryWithoutPerm)&&(check_col(pinfo->cinfo, COL_INFO)))
2138 col_append_fstr(pinfo->cinfo, COL_INFO, " QueryWithOutPerm");
2140 if ((hf_index == hf_tcap_ansiresponse)&&(check_col(pinfo->cinfo, COL_INFO)))
2141 col_append_fstr(pinfo->cinfo, COL_INFO, " Response");
2143 if ((hf_index == hf_tcap_ansiconversationWithPerm)&&(check_col(pinfo->cinfo, COL_INFO)))
2144 col_append_fstr(pinfo->cinfo, COL_INFO, " ConversationWithPerm");
2146 if ((hf_index == hf_tcap_ansiconversationWithoutPerm)&&(check_col(pinfo->cinfo, COL_INFO)))
2147 col_append_fstr(pinfo->cinfo, COL_INFO, " ConversationWithoutPerm");
2149 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
2150 TransactionPDU_sequence, hf_index, ett_tcap_TransactionPDU);
2156 static int dissect_ansiqueryWithPerm_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2157 return dissect_tcap_TransactionPDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_ansiqueryWithPerm);
2159 static int dissect_ansiqueryWithoutPerm_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2160 return dissect_tcap_TransactionPDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_ansiqueryWithoutPerm);
2162 static int dissect_ansiresponse_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2163 return dissect_tcap_TransactionPDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_ansiresponse);
2165 static int dissect_ansiconversationWithPerm_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2166 return dissect_tcap_TransactionPDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_ansiconversationWithPerm);
2168 static int dissect_ansiconversationWithoutPerm_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2169 return dissect_tcap_TransactionPDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_ansiconversationWithoutPerm);
2173 static const value_string tcap_P_Abort_cause_vals[] = {
2174 { 1, "unrecognizedPackageType" },
2175 { 2, "incorrestTransactionPortion" },
2176 { 3, "badlyStructuredTransactionPortion" },
2177 { 4, "unassignedRespondingTransactionID" },
2178 { 5, "permissionToReleaseProblem" },
2179 { 6, "resourceUnavilable" },
2180 { 7, "unrecognizedDialoguePortionID" },
2181 { 8, "badlyStructuredDialoguePortion" },
2182 { 9, "missingDialoguePortion" },
2183 { 10, "inconsistentDialoguePortion" },
2189 dissect_tcap_P_Abort_cause(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
2190 offset = dissect_ber_integer(implicit_tag, pinfo, tree, tvb, offset, hf_index,
2195 static int dissect_abortCause(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2196 return dissect_tcap_P_Abort_cause(FALSE, tvb, offset, pinfo, tree, hf_tcap_abortCause);
2200 static const value_string tcap_T_causeInformation_vals[] = {
2201 { 0, "abortCause" },
2202 { 1, "userInformation" },
2206 static const ber_choice_t T_causeInformation_choice[] = {
2207 { 0, BER_CLASS_PRI, 23, BER_FLAGS_NOOWNTAG, dissect_abortCause },
2208 { 1, BER_CLASS_UNI, 8, BER_FLAGS_NOOWNTAG, dissect_userInformation },
2209 { 0, 0, 0, 0, NULL }
2213 dissect_tcap_T_causeInformation(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
2214 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
2215 T_causeInformation_choice, hf_index, ett_tcap_T_causeInformation,
2220 static int dissect_causeInformation(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2221 return dissect_tcap_T_causeInformation(FALSE, tvb, offset, pinfo, tree, hf_tcap_causeInformation);
2225 static const ber_sequence_t AbortPDU_sequence[] = {
2226 { BER_CLASS_PRI, 7, BER_FLAGS_NOOWNTAG, dissect_identifier },
2227 { BER_CLASS_PRI, 25, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG, dissect_dialoguePortionansi },
2228 { BER_CLASS_ANY/*choice*/, -1/*choice*/, BER_FLAGS_OPTIONAL|BER_FLAGS_NOOWNTAG|BER_FLAGS_NOTCHKTAG, dissect_causeInformation },
2233 dissect_tcap_AbortPDU(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
2234 #line 264 "tcap.cnf"
2235 if (check_col(pinfo->cinfo, COL_INFO))
2236 col_append_fstr(pinfo->cinfo, COL_INFO, " Abort ");
2237 offset = dissect_ber_sequence(implicit_tag, pinfo, tree, tvb, offset,
2238 AbortPDU_sequence, hf_index, ett_tcap_AbortPDU);
2243 static int dissect_ansiabort_impl(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset) {
2244 return dissect_tcap_AbortPDU(TRUE, tvb, offset, pinfo, tree, hf_tcap_ansiabort);
2248 static const value_string tcap_MessageType_vals[] = {
2249 { 0, "unidirectional" },
2254 { 5, "ansiunidirectional" },
2255 { 6, "ansiqueryWithPerm" },
2256 { 7, "ansiqueryWithoutPerm" },
2257 { 8, "ansiresponse" },
2258 { 9, "ansiconversationWithPerm" },
2259 { 10, "ansiconversationWithoutPerm" },
2260 { 11, "ansiabort" },
2264 static const ber_choice_t MessageType_choice[] = {
2265 { 0, BER_CLASS_APP, 1, BER_FLAGS_IMPLTAG, dissect_unidirectional_impl },
2266 { 1, BER_CLASS_APP, 2, BER_FLAGS_IMPLTAG, dissect_begin_impl },
2267 { 2, BER_CLASS_APP, 4, BER_FLAGS_IMPLTAG, dissect_end_impl },
2268 { 3, BER_CLASS_APP, 5, BER_FLAGS_IMPLTAG, dissect_continue_impl },
2269 { 4, BER_CLASS_APP, 7, BER_FLAGS_IMPLTAG, dissect_abort_impl },
2270 { 5, BER_CLASS_PRI, 1, BER_FLAGS_IMPLTAG, dissect_ansiunidirectional_impl },
2271 { 6, BER_CLASS_PRI, 2, BER_FLAGS_IMPLTAG, dissect_ansiqueryWithPerm_impl },
2272 { 7, BER_CLASS_PRI, 3, BER_FLAGS_IMPLTAG, dissect_ansiqueryWithoutPerm_impl },
2273 { 8, BER_CLASS_PRI, 4, BER_FLAGS_IMPLTAG, dissect_ansiresponse_impl },
2274 { 9, BER_CLASS_PRI, 5, BER_FLAGS_IMPLTAG, dissect_ansiconversationWithPerm_impl },
2275 { 10, BER_CLASS_PRI, 6, BER_FLAGS_IMPLTAG, dissect_ansiconversationWithoutPerm_impl },
2276 { 11, BER_CLASS_PRI, 22, BER_FLAGS_IMPLTAG, dissect_ansiabort_impl },
2277 { 0, 0, 0, 0, NULL }
2281 dissect_tcap_MessageType(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
2282 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
2283 MessageType_choice, hf_index, ett_tcap_MessageType,
2290 static const value_string tcap_ERROR_vals[] = {
2291 { 0, "localValue" },
2292 { 1, "globalValue" },
2296 static const ber_choice_t ERROR_choice[] = {
2297 { 0, BER_CLASS_UNI, BER_UNI_TAG_INTEGER, BER_FLAGS_NOOWNTAG, dissect_localValue },
2298 { 1, BER_CLASS_UNI, BER_UNI_TAG_OID, BER_FLAGS_NOOWNTAG, dissect_globalValue },
2299 { 0, 0, 0, 0, NULL }
2303 dissect_tcap_ERROR(gboolean implicit_tag _U_, tvbuff_t *tvb, int offset, packet_info *pinfo _U_, proto_tree *tree, int hf_index _U_) {
2304 offset = dissect_ber_choice(pinfo, tree, tvb, offset,
2305 ERROR_choice, hf_index, ett_tcap_ERROR,
2312 /*--- End of included file: packet-tcap-fn.c ---*/
2313 #line 115 "packet-tcap-template.c"
2317 const value_string tcap_component_type_str[] = {
2318 { TCAP_COMP_INVOKE, "Invoke" },
2319 { TCAP_COMP_RRL, "Return Result(L)" },
2320 { TCAP_COMP_RE, "Return Error" },
2321 { TCAP_COMP_REJECT, "Reject" },
2322 { TCAP_COMP_RRN, "Return Result(NL)" },
2327 dissect_tcap(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
2329 proto_item *item=NULL;
2330 proto_tree *tree=NULL;
2332 tcap_top_tree = parent_tree;
2333 if (check_col(pinfo->cinfo, COL_PROTOCOL))
2335 col_set_str(pinfo->cinfo, COL_PROTOCOL, "TCAP");
2338 /* create display subtree for the protocol */
2340 item = proto_tree_add_item(parent_tree, proto_tcap, tvb, 0, -1, FALSE);
2341 tree = proto_item_add_subtree(item, ett_tcap);
2345 pinfo->private_data = NULL;
2346 dissect_tcap_MessageType(FALSE, tvb, 0, pinfo, tree, -1);
2353 proto_reg_handoff_tcap(void)
2356 static gboolean prefs_initialized = FALSE;
2358 if (! prefs_initialized) {
2359 sccp_ssn_table = find_dissector_table("sccp.ssn");
2360 prefs_initialized = TRUE;
2363 register_ber_oid_name("0.0.17.773.1.1.1",
2364 "itu-t(0) recommendation(0) q(17) 773 as(1) dialogue-as(1) version1(1)");
2368 static void init_tcap(void);
2371 proto_register_tcap(void)
2374 /* Setup list of header fields See Section 1.6.1 for details*/
2375 static hf_register_info hf[] = {
2377 { "Tag", "tcap.msgtype",
2378 FT_UINT8, BASE_HEX, NULL, 0,
2382 { "Length", "tcap.len",
2383 FT_UINT8, BASE_HEX, NULL, 0,
2387 { "Data", "tcap.data",
2388 FT_BYTES, BASE_HEX, NULL, 0,
2392 { "Transaction Id", "tcap.tid",
2393 FT_BYTES, BASE_HEX, NULL, 0,
2397 /*--- Included file: packet-tcap-hfarr.c ---*/
2398 #line 1 "packet-tcap-hfarr.c"
2399 { &hf_tcap_dialogueRequest,
2400 { "dialogueRequest", "tcap.dialogueRequest",
2401 FT_NONE, BASE_NONE, NULL, 0,
2402 "DialoguePDU/dialogueRequest", HFILL }},
2403 { &hf_tcap_dialogueResponse,
2404 { "dialogueResponse", "tcap.dialogueResponse",
2405 FT_NONE, BASE_NONE, NULL, 0,
2406 "DialoguePDU/dialogueResponse", HFILL }},
2407 { &hf_tcap_dialogueAbort,
2408 { "dialogueAbort", "tcap.dialogueAbort",
2409 FT_NONE, BASE_NONE, NULL, 0,
2410 "DialoguePDU/dialogueAbort", HFILL }},
2412 { "oid", "tcap.oid",
2413 FT_OID, BASE_NONE, NULL, 0,
2414 "ExternalPDU/oid", HFILL }},
2416 { "dialog", "tcap.dialog",
2417 FT_BYTES, BASE_HEX, NULL, 0,
2418 "ExternalPDU/dialog", HFILL }},
2420 { "useroid", "tcap.useroid",
2421 FT_OID, BASE_NONE, NULL, 0,
2422 "UserInformation/useroid", HFILL }},
2423 { &hf_tcap_externuserinfo,
2424 { "externuserinfo", "tcap.externuserinfo",
2425 FT_BYTES, BASE_HEX, NULL, 0,
2426 "UserInformation/externuserinfo", HFILL }},
2427 { &hf_tcap_protocol_versionrq,
2428 { "protocol-versionrq", "tcap.protocol_versionrq",
2429 FT_BYTES, BASE_HEX, NULL, 0,
2430 "AARQ-apdu/protocol-versionrq", HFILL }},
2431 { &hf_tcap_application_context_name,
2432 { "application-context-name", "tcap.application_context_name",
2433 FT_OID, BASE_NONE, NULL, 0,
2435 { &hf_tcap_user_information,
2436 { "user-information", "tcap.user_information",
2437 FT_BYTES, BASE_HEX, NULL, 0,
2439 { &hf_tcap_protocol_versionre,
2440 { "protocol-versionre", "tcap.protocol_versionre",
2441 FT_BYTES, BASE_HEX, NULL, 0,
2442 "AARE-apdu/protocol-versionre", HFILL }},
2444 { "result", "tcap.result",
2445 FT_INT32, BASE_DEC, VALS(tcap_Associate_result_vals), 0,
2446 "AARE-apdu/result", HFILL }},
2447 { &hf_tcap_result_source_diagnostic,
2448 { "result-source-diagnostic", "tcap.result_source_diagnostic",
2449 FT_UINT32, BASE_DEC, VALS(tcap_Associate_source_diagnostic_vals), 0,
2450 "AARE-apdu/result-source-diagnostic", HFILL }},
2451 { &hf_tcap_reasonrq,
2452 { "reasonrq", "tcap.reasonrq",
2453 FT_INT32, BASE_DEC, VALS(tcap_Release_request_reason_vals), 0,
2454 "RLRQ-apdu/reasonrq", HFILL }},
2455 { &hf_tcap_reasonre,
2456 { "reasonre", "tcap.reasonre",
2457 FT_INT32, BASE_DEC, VALS(tcap_Release_response_reason_vals), 0,
2458 "RLRE-apdu/reasonre", HFILL }},
2459 { &hf_tcap_abort_source,
2460 { "abort-source", "tcap.abort_source",
2461 FT_INT32, BASE_DEC, VALS(tcap_ABRT_source_vals), 0,
2462 "ABRT-apdu/abort-source", HFILL }},
2463 { &hf_tcap_dialogue_service_user,
2464 { "dialogue-service-user", "tcap.dialogue_service_user",
2465 FT_INT32, BASE_DEC, VALS(tcap_T_dialogue_service_user_vals), 0,
2466 "Associate-source-diagnostic/dialogue-service-user", HFILL }},
2467 { &hf_tcap_dialogue_service_provider,
2468 { "dialogue-service-provider", "tcap.dialogue_service_provider",
2469 FT_INT32, BASE_DEC, VALS(tcap_T_dialogue_service_provider_vals), 0,
2470 "Associate-source-diagnostic/dialogue-service-provider", HFILL }},
2471 { &hf_tcap_unidialoguePDU,
2472 { "unidialoguePDU", "tcap.unidialoguePDU",
2473 FT_NONE, BASE_NONE, NULL, 0,
2474 "UniDialoguePDU/unidialoguePDU", HFILL }},
2475 { &hf_tcap_protocol_version3,
2476 { "protocol-version3", "tcap.protocol_version3",
2477 FT_BYTES, BASE_HEX, NULL, 0,
2478 "AUDT-apdu/protocol-version3", HFILL }},
2479 { &hf_tcap_unidirectional,
2480 { "unidirectional", "tcap.unidirectional",
2481 FT_NONE, BASE_NONE, NULL, 0,
2482 "MessageType/unidirectional", HFILL }},
2484 { "begin", "tcap.begin",
2485 FT_NONE, BASE_NONE, NULL, 0,
2486 "MessageType/begin", HFILL }},
2488 { "end", "tcap.end",
2489 FT_NONE, BASE_NONE, NULL, 0,
2490 "MessageType/end", HFILL }},
2491 { &hf_tcap_continue,
2492 { "continue", "tcap.continue",
2493 FT_NONE, BASE_NONE, NULL, 0,
2494 "MessageType/continue", HFILL }},
2496 { "abort", "tcap.abort",
2497 FT_NONE, BASE_NONE, NULL, 0,
2498 "MessageType/abort", HFILL }},
2499 { &hf_tcap_ansiunidirectional,
2500 { "ansiunidirectional", "tcap.ansiunidirectional",
2501 FT_NONE, BASE_NONE, NULL, 0,
2502 "MessageType/ansiunidirectional", HFILL }},
2503 { &hf_tcap_ansiqueryWithPerm,
2504 { "ansiqueryWithPerm", "tcap.ansiqueryWithPerm",
2505 FT_NONE, BASE_NONE, NULL, 0,
2506 "MessageType/ansiqueryWithPerm", HFILL }},
2507 { &hf_tcap_ansiqueryWithoutPerm,
2508 { "ansiqueryWithoutPerm", "tcap.ansiqueryWithoutPerm",
2509 FT_NONE, BASE_NONE, NULL, 0,
2510 "MessageType/ansiqueryWithoutPerm", HFILL }},
2511 { &hf_tcap_ansiresponse,
2512 { "ansiresponse", "tcap.ansiresponse",
2513 FT_NONE, BASE_NONE, NULL, 0,
2514 "MessageType/ansiresponse", HFILL }},
2515 { &hf_tcap_ansiconversationWithPerm,
2516 { "ansiconversationWithPerm", "tcap.ansiconversationWithPerm",
2517 FT_NONE, BASE_NONE, NULL, 0,
2518 "MessageType/ansiconversationWithPerm", HFILL }},
2519 { &hf_tcap_ansiconversationWithoutPerm,
2520 { "ansiconversationWithoutPerm", "tcap.ansiconversationWithoutPerm",
2521 FT_NONE, BASE_NONE, NULL, 0,
2522 "MessageType/ansiconversationWithoutPerm", HFILL }},
2523 { &hf_tcap_ansiabort,
2524 { "ansiabort", "tcap.ansiabort",
2525 FT_NONE, BASE_NONE, NULL, 0,
2526 "MessageType/ansiabort", HFILL }},
2527 { &hf_tcap_dialoguePortion,
2528 { "dialoguePortion", "tcap.dialoguePortion",
2529 FT_BYTES, BASE_HEX, NULL, 0,
2531 { &hf_tcap_components,
2532 { "components", "tcap.components",
2533 FT_UINT32, BASE_DEC, NULL, 0,
2536 { "otid", "tcap.otid",
2537 FT_BYTES, BASE_HEX, NULL, 0,
2540 { "dtid", "tcap.dtid",
2541 FT_BYTES, BASE_HEX, NULL, 0,
2544 { "reason", "tcap.reason",
2545 FT_UINT32, BASE_DEC, VALS(tcap_Reason_vals), 0,
2546 "Abort/reason", HFILL }},
2547 { &hf_tcap_p_abortCause,
2548 { "p-abortCause", "tcap.p_abortCause",
2549 FT_INT32, BASE_DEC, VALS(tcap_P_AbortCause_vals), 0,
2550 "Reason/p-abortCause", HFILL }},
2551 { &hf_tcap_u_abortCause,
2552 { "u-abortCause", "tcap.u_abortCause",
2553 FT_BYTES, BASE_HEX, NULL, 0,
2554 "Reason/u-abortCause", HFILL }},
2555 { &hf_tcap_ComponentPortion_item,
2556 { "Item", "tcap.ComponentPortion_item",
2557 FT_UINT32, BASE_DEC, VALS(tcap_Component_vals), 0,
2558 "ComponentPortion/_item", HFILL }},
2560 { "invoke", "tcap.invoke",
2561 FT_NONE, BASE_NONE, NULL, 0,
2562 "Component/invoke", HFILL }},
2563 { &hf_tcap_returnResultLast,
2564 { "returnResultLast", "tcap.returnResultLast",
2565 FT_NONE, BASE_NONE, NULL, 0,
2566 "Component/returnResultLast", HFILL }},
2567 { &hf_tcap_returnError,
2568 { "returnError", "tcap.returnError",
2569 FT_NONE, BASE_NONE, NULL, 0,
2570 "Component/returnError", HFILL }},
2572 { "reject", "tcap.reject",
2573 FT_NONE, BASE_NONE, NULL, 0,
2574 "Component/reject", HFILL }},
2575 { &hf_tcap_returnResultNotLast,
2576 { "returnResultNotLast", "tcap.returnResultNotLast",
2577 FT_NONE, BASE_NONE, NULL, 0,
2578 "Component/returnResultNotLast", HFILL }},
2579 { &hf_tcap_invokeID,
2580 { "invokeID", "tcap.invokeID",
2581 FT_INT32, BASE_DEC, NULL, 0,
2583 { &hf_tcap_linkedID,
2584 { "linkedID", "tcap.linkedID",
2585 FT_INT32, BASE_DEC, NULL, 0,
2586 "Invoke/linkedID", HFILL }},
2588 { "opCode", "tcap.opCode",
2589 FT_UINT32, BASE_DEC, VALS(tcap_OPERATION_vals), 0,
2591 { &hf_tcap_parameter,
2592 { "parameter", "tcap.parameter",
2593 FT_NONE, BASE_NONE, NULL, 0,
2595 { &hf_tcap_resultretres,
2596 { "resultretres", "tcap.resultretres",
2597 FT_NONE, BASE_NONE, NULL, 0,
2598 "ReturnResult/resultretres", HFILL }},
2599 { &hf_tcap_errorCode,
2600 { "errorCode", "tcap.errorCode",
2601 FT_UINT32, BASE_DEC, VALS(tcap_ErrorCode_vals), 0,
2603 { &hf_tcap_invokeIDRej,
2604 { "invokeIDRej", "tcap.invokeIDRej",
2605 FT_UINT32, BASE_DEC, VALS(tcap_T_invokeIDRej_vals), 0,
2606 "Reject/invokeIDRej", HFILL }},
2607 { &hf_tcap_derivable,
2608 { "derivable", "tcap.derivable",
2609 FT_INT32, BASE_DEC, NULL, 0,
2610 "Reject/invokeIDRej/derivable", HFILL }},
2611 { &hf_tcap_not_derivable,
2612 { "not-derivable", "tcap.not_derivable",
2613 FT_NONE, BASE_NONE, NULL, 0,
2614 "Reject/invokeIDRej/not-derivable", HFILL }},
2616 { "problem", "tcap.problem",
2617 FT_UINT32, BASE_DEC, VALS(tcap_T_problem_vals), 0,
2618 "Reject/problem", HFILL }},
2619 { &hf_tcap_generalProblem,
2620 { "generalProblem", "tcap.generalProblem",
2621 FT_INT32, BASE_DEC, VALS(tcap_GeneralProblem_vals), 0,
2622 "Reject/problem/generalProblem", HFILL }},
2623 { &hf_tcap_invokeProblem,
2624 { "invokeProblem", "tcap.invokeProblem",
2625 FT_INT32, BASE_DEC, VALS(tcap_InvokeProblem_vals), 0,
2626 "Reject/problem/invokeProblem", HFILL }},
2627 { &hf_tcap_returnResultProblem,
2628 { "returnResultProblem", "tcap.returnResultProblem",
2629 FT_INT32, BASE_DEC, VALS(tcap_ReturnResultProblem_vals), 0,
2630 "Reject/problem/returnResultProblem", HFILL }},
2631 { &hf_tcap_returnErrorProblem,
2632 { "returnErrorProblem", "tcap.returnErrorProblem",
2633 FT_INT32, BASE_DEC, VALS(tcap_ReturnErrorProblem_vals), 0,
2634 "Reject/problem/returnErrorProblem", HFILL }},
2635 { &hf_tcap_localValue,
2636 { "localValue", "tcap.localValue",
2637 FT_INT32, BASE_DEC, NULL, 0,
2639 { &hf_tcap_globalValue,
2640 { "globalValue", "tcap.globalValue",
2641 FT_OID, BASE_NONE, NULL, 0,
2643 { &hf_tcap_identifier,
2644 { "identifier", "tcap.identifier",
2645 FT_BYTES, BASE_HEX, NULL, 0,
2647 { &hf_tcap_dialoguePortionansi,
2648 { "dialoguePortionansi", "tcap.dialoguePortionansi",
2649 FT_NONE, BASE_NONE, NULL, 0,
2651 { &hf_tcap_componentPortion,
2652 { "componentPortion", "tcap.componentPortion",
2653 FT_UINT32, BASE_DEC, NULL, 0,
2655 { &hf_tcap_causeInformation,
2656 { "causeInformation", "tcap.causeInformation",
2657 FT_UINT32, BASE_DEC, VALS(tcap_T_causeInformation_vals), 0,
2658 "AbortPDU/causeInformation", HFILL }},
2659 { &hf_tcap_abortCause,
2660 { "abortCause", "tcap.abortCause",
2661 FT_INT32, BASE_DEC, VALS(tcap_P_Abort_cause_vals), 0,
2662 "AbortPDU/causeInformation/abortCause", HFILL }},
2663 { &hf_tcap_userInformation,
2664 { "userInformation", "tcap.userInformation",
2665 FT_NONE, BASE_NONE, NULL, 0,
2668 { "version", "tcap.version",
2669 FT_BYTES, BASE_HEX, NULL, 0,
2670 "DialoguePortionANSI/version", HFILL }},
2671 { &hf_tcap_applicationContext,
2672 { "applicationContext", "tcap.applicationContext",
2673 FT_UINT32, BASE_DEC, VALS(tcap_T_applicationContext_vals), 0,
2674 "DialoguePortionANSI/applicationContext", HFILL }},
2675 { &hf_tcap_integerApplicationId,
2676 { "integerApplicationId", "tcap.integerApplicationId",
2677 FT_INT32, BASE_DEC, NULL, 0,
2678 "DialoguePortionANSI/applicationContext/integerApplicationId", HFILL }},
2679 { &hf_tcap_objectApplicationId,
2680 { "objectApplicationId", "tcap.objectApplicationId",
2681 FT_OID, BASE_NONE, NULL, 0,
2682 "DialoguePortionANSI/applicationContext/objectApplicationId", HFILL }},
2683 { &hf_tcap_securityContext,
2684 { "securityContext", "tcap.securityContext",
2685 FT_UINT32, BASE_DEC, VALS(tcap_T_securityContext_vals), 0,
2686 "DialoguePortionANSI/securityContext", HFILL }},
2687 { &hf_tcap_integerSecurityId,
2688 { "integerSecurityId", "tcap.integerSecurityId",
2689 FT_INT32, BASE_DEC, NULL, 0,
2690 "DialoguePortionANSI/securityContext/integerSecurityId", HFILL }},
2691 { &hf_tcap_objectSecurityId,
2692 { "objectSecurityId", "tcap.objectSecurityId",
2693 FT_OID, BASE_NONE, NULL, 0,
2694 "DialoguePortionANSI/securityContext/objectSecurityId", HFILL }},
2695 { &hf_tcap_confidentiality,
2696 { "confidentiality", "tcap.confidentiality",
2697 FT_NONE, BASE_NONE, NULL, 0,
2698 "DialoguePortionANSI/confidentiality", HFILL }},
2699 { &hf_tcap_confidentialityId,
2700 { "confidentialityId", "tcap.confidentialityId",
2701 FT_UINT32, BASE_DEC, VALS(tcap_T_confidentialityId_vals), 0,
2702 "Confidentiality/confidentialityId", HFILL }},
2703 { &hf_tcap_integerConfidentialityId,
2704 { "integerConfidentialityId", "tcap.integerConfidentialityId",
2705 FT_INT32, BASE_DEC, NULL, 0,
2706 "Confidentiality/confidentialityId/integerConfidentialityId", HFILL }},
2707 { &hf_tcap_objectConfidentialityId,
2708 { "objectConfidentialityId", "tcap.objectConfidentialityId",
2709 FT_OID, BASE_NONE, NULL, 0,
2710 "Confidentiality/confidentialityId/objectConfidentialityId", HFILL }},
2711 { &hf_tcap_ComponentSequence_item,
2712 { "Item", "tcap.ComponentSequence_item",
2713 FT_UINT32, BASE_DEC, VALS(tcap_ComponentPDU_vals), 0,
2714 "ComponentSequence/_item", HFILL }},
2715 { &hf_tcap_invokeLastansi,
2716 { "invokeLastansi", "tcap.invokeLastansi",
2717 FT_NONE, BASE_NONE, NULL, 0,
2718 "ComponentPDU/invokeLastansi", HFILL }},
2719 { &hf_tcap_returnResultLastansi,
2720 { "returnResultLastansi", "tcap.returnResultLastansi",
2721 FT_NONE, BASE_NONE, NULL, 0,
2722 "ComponentPDU/returnResultLastansi", HFILL }},
2723 { &hf_tcap_returnErroransi,
2724 { "returnErroransi", "tcap.returnErroransi",
2725 FT_NONE, BASE_NONE, NULL, 0,
2726 "ComponentPDU/returnErroransi", HFILL }},
2727 { &hf_tcap_rejectansi,
2728 { "rejectansi", "tcap.rejectansi",
2729 FT_NONE, BASE_NONE, NULL, 0,
2730 "ComponentPDU/rejectansi", HFILL }},
2731 { &hf_tcap_invokeNotLastansi,
2732 { "invokeNotLastansi", "tcap.invokeNotLastansi",
2733 FT_NONE, BASE_NONE, NULL, 0,
2734 "ComponentPDU/invokeNotLastansi", HFILL }},
2735 { &hf_tcap_returnResultNotLastansi,
2736 { "returnResultNotLastansi", "tcap.returnResultNotLastansi",
2737 FT_NONE, BASE_NONE, NULL, 0,
2738 "ComponentPDU/returnResultNotLastansi", HFILL }},
2739 { &hf_tcap_componentIDs,
2740 { "componentIDs", "tcap.componentIDs",
2741 FT_BYTES, BASE_HEX, NULL, 0,
2742 "InvokePDU/componentIDs", HFILL }},
2743 { &hf_tcap_operationCode,
2744 { "operationCode", "tcap.operationCode",
2745 FT_UINT32, BASE_DEC, VALS(tcap_OperationCode_vals), 0,
2746 "InvokePDU/operationCode", HFILL }},
2747 { &hf_tcap_parameterinv,
2748 { "parameterinv", "tcap.parameterinv",
2749 FT_NONE, BASE_NONE, NULL, 0,
2750 "InvokePDU/parameterinv", HFILL }},
2751 { &hf_tcap_ansiparams,
2752 { "ansiparams", "tcap.ansiparams",
2753 FT_NONE, BASE_NONE, NULL, 0,
2754 "ANSIparamch/ansiparams", HFILL }},
2755 { &hf_tcap_ansiparams1,
2756 { "ansiparams1", "tcap.ansiparams1",
2757 FT_NONE, BASE_NONE, NULL, 0,
2758 "ANSIparamch/ansiparams1", HFILL }},
2759 { &hf_tcap_ansiparams2,
2760 { "ansiparams2", "tcap.ansiparams2",
2761 FT_NONE, BASE_NONE, NULL, 0,
2762 "ANSIparamch/ansiparams2", HFILL }},
2763 { &hf_tcap_ansiparams3,
2764 { "ansiparams3", "tcap.ansiparams3",
2765 FT_NONE, BASE_NONE, NULL, 0,
2766 "ANSIparamch/ansiparams3", HFILL }},
2767 { &hf_tcap_ansiparams4,
2768 { "ansiparams4", "tcap.ansiparams4",
2769 FT_NONE, BASE_NONE, NULL, 0,
2770 "ANSIparamch/ansiparams4", HFILL }},
2771 { &hf_tcap_ansiparams5,
2772 { "ansiparams5", "tcap.ansiparams5",
2773 FT_NONE, BASE_NONE, NULL, 0,
2774 "ANSIparamch/ansiparams5", HFILL }},
2775 { &hf_tcap_ansiparams6,
2776 { "ansiparams6", "tcap.ansiparams6",
2777 FT_NONE, BASE_NONE, NULL, 0,
2778 "ANSIparamch/ansiparams6", HFILL }},
2779 { &hf_tcap_ansiparams7,
2780 { "ansiparams7", "tcap.ansiparams7",
2781 FT_NONE, BASE_NONE, NULL, 0,
2782 "ANSIparamch/ansiparams7", HFILL }},
2783 { &hf_tcap_ansiparams8,
2784 { "ansiparams8", "tcap.ansiparams8",
2785 FT_NONE, BASE_NONE, NULL, 0,
2786 "ANSIparamch/ansiparams8", HFILL }},
2787 { &hf_tcap_ansiparams9,
2788 { "ansiparams9", "tcap.ansiparams9",
2789 FT_NONE, BASE_NONE, NULL, 0,
2790 "ANSIparamch/ansiparams9", HFILL }},
2791 { &hf_tcap_ansiparams10,
2792 { "ansiparams10", "tcap.ansiparams10",
2793 FT_NONE, BASE_NONE, NULL, 0,
2794 "ANSIparamch/ansiparams10", HFILL }},
2795 { &hf_tcap_ansiparams11,
2796 { "ansiparams11", "tcap.ansiparams11",
2797 FT_NONE, BASE_NONE, NULL, 0,
2798 "ANSIparamch/ansiparams11", HFILL }},
2799 { &hf_tcap_ansiparams12,
2800 { "ansiparams12", "tcap.ansiparams12",
2801 FT_NONE, BASE_NONE, NULL, 0,
2802 "ANSIparamch/ansiparams12", HFILL }},
2803 { &hf_tcap_ansiparams13,
2804 { "ansiparams13", "tcap.ansiparams13",
2805 FT_NONE, BASE_NONE, NULL, 0,
2806 "ANSIparamch/ansiparams13", HFILL }},
2807 { &hf_tcap_ansiparams14,
2808 { "ansiparams14", "tcap.ansiparams14",
2809 FT_NONE, BASE_NONE, NULL, 0,
2810 "ANSIparamch/ansiparams14", HFILL }},
2811 { &hf_tcap_ansiparams15,
2812 { "ansiparams15", "tcap.ansiparams15",
2813 FT_NONE, BASE_NONE, NULL, 0,
2814 "ANSIparamch/ansiparams15", HFILL }},
2815 { &hf_tcap_ansiparams16,
2816 { "ansiparams16", "tcap.ansiparams16",
2817 FT_NONE, BASE_NONE, NULL, 0,
2818 "ANSIparamch/ansiparams16", HFILL }},
2819 { &hf_tcap_ansiparams17,
2820 { "ansiparams17", "tcap.ansiparams17",
2821 FT_NONE, BASE_NONE, NULL, 0,
2822 "ANSIparamch/ansiparams17", HFILL }},
2823 { &hf_tcap_ansiparams18,
2824 { "ansiparams18", "tcap.ansiparams18",
2825 FT_NONE, BASE_NONE, NULL, 0,
2826 "ANSIparamch/ansiparams18", HFILL }},
2827 { &hf_tcap_ansiparams19,
2828 { "ansiparams19", "tcap.ansiparams19",
2829 FT_NONE, BASE_NONE, NULL, 0,
2830 "ANSIparamch/ansiparams19", HFILL }},
2831 { &hf_tcap_ansiparams20,
2832 { "ansiparams20", "tcap.ansiparams20",
2833 FT_NONE, BASE_NONE, NULL, 0,
2834 "ANSIparamch/ansiparams20", HFILL }},
2835 { &hf_tcap_ansiparams21,
2836 { "ansiparams21", "tcap.ansiparams21",
2837 FT_NONE, BASE_NONE, NULL, 0,
2838 "ANSIparamch/ansiparams21", HFILL }},
2839 { &hf_tcap_componentID,
2840 { "componentID", "tcap.componentID",
2841 FT_BYTES, BASE_HEX, NULL, 0,
2843 { &hf_tcap_parameterrr,
2844 { "parameterrr", "tcap.parameterrr",
2845 FT_NONE, BASE_NONE, NULL, 0,
2846 "ReturnResultPDU/parameterrr", HFILL }},
2847 { &hf_tcap_parameterre,
2848 { "parameterre", "tcap.parameterre",
2849 FT_NONE, BASE_NONE, NULL, 0,
2850 "ReturnErrorPDU/parameterre", HFILL }},
2851 { &hf_tcap_rejectProblem,
2852 { "rejectProblem", "tcap.rejectProblem",
2853 FT_INT32, BASE_DEC, VALS(tcap_ProblemPDU_vals), 0,
2854 "RejectPDU/rejectProblem", HFILL }},
2855 { &hf_tcap_parameterrj,
2856 { "parameterrj", "tcap.parameterrj",
2857 FT_NONE, BASE_NONE, NULL, 0,
2858 "RejectPDU/parameterrj", HFILL }},
2859 { &hf_tcap_national,
2860 { "national", "tcap.national",
2861 FT_INT32, BASE_DEC, NULL, 0,
2862 "OperationCode/national", HFILL }},
2864 { "private", "tcap.private",
2865 FT_INT32, BASE_DEC, NULL, 0,
2866 "OperationCode/private", HFILL }},
2867 { &hf_tcap_nationaler,
2868 { "nationaler", "tcap.nationaler",
2869 FT_INT32, BASE_DEC, NULL, 0,
2870 "ErrorCode/nationaler", HFILL }},
2871 { &hf_tcap_privateer,
2872 { "privateer", "tcap.privateer",
2873 FT_INT32, BASE_DEC, NULL, 0,
2874 "ErrorCode/privateer", HFILL }},
2875 { &hf_tcap_T_protocol_versionrq_version1,
2876 { "version1", "tcap.version1",
2877 FT_BOOLEAN, 8, NULL, 0x80,
2879 { &hf_tcap_T_protocol_versionre_version1,
2880 { "version1", "tcap.version1",
2881 FT_BOOLEAN, 8, NULL, 0x80,
2883 { &hf_tcap_T_protocol_version3_version1,
2884 { "version1", "tcap.version1",
2885 FT_BOOLEAN, 8, NULL, 0x80,
2888 /*--- End of included file: packet-tcap-hfarr.c ---*/
2889 #line 198 "packet-tcap-template.c"
2892 /* Setup protocol subtree array */
2893 static gint *ett[] = {
2899 /*--- Included file: packet-tcap-ettarr.c ---*/
2900 #line 1 "packet-tcap-ettarr.c"
2901 &ett_tcap_DialoguePDU,
2902 &ett_tcap_ExternalPDU,
2903 &ett_tcap_UserInformation,
2904 &ett_tcap_AARQ_apdu,
2905 &ett_tcap_T_protocol_versionrq,
2906 &ett_tcap_AARE_apdu,
2907 &ett_tcap_T_protocol_versionre,
2908 &ett_tcap_RLRQ_apdu,
2909 &ett_tcap_RLRE_apdu,
2910 &ett_tcap_ABRT_apdu,
2911 &ett_tcap_Associate_source_diagnostic,
2912 &ett_tcap_UniDialoguePDU,
2913 &ett_tcap_AUDT_apdu,
2914 &ett_tcap_T_protocol_version3,
2915 &ett_tcap_MessageType,
2916 &ett_tcap_Unidirectional,
2922 &ett_tcap_ComponentPortion,
2923 &ett_tcap_Component,
2925 &ett_tcap_ReturnResult,
2926 &ett_tcap_T_resultretres,
2927 &ett_tcap_ReturnError,
2929 &ett_tcap_T_invokeIDRej,
2930 &ett_tcap_T_problem,
2931 &ett_tcap_OPERATION,
2933 &ett_tcap_UniTransactionPDU,
2934 &ett_tcap_TransactionPDU,
2936 &ett_tcap_T_causeInformation,
2937 &ett_tcap_DialoguePortionANSI,
2938 &ett_tcap_T_applicationContext,
2939 &ett_tcap_T_securityContext,
2940 &ett_tcap_Confidentiality,
2941 &ett_tcap_T_confidentialityId,
2942 &ett_tcap_ComponentSequence,
2943 &ett_tcap_ComponentPDU,
2944 &ett_tcap_InvokePDU,
2945 &ett_tcap_ANSIparamch,
2946 &ett_tcap_ReturnResultPDU,
2947 &ett_tcap_ReturnErrorPDU,
2948 &ett_tcap_RejectPDU,
2949 &ett_tcap_OperationCode,
2950 &ett_tcap_ErrorCode,
2952 /*--- End of included file: packet-tcap-ettarr.c ---*/
2953 #line 207 "packet-tcap-template.c"
2956 /*static enum_val_t tcap_options[] = {
2957 { "itu", "ITU", ITU_TCAP_STANDARD },
2958 { "ansi", "ANSI", ANSI_TCAP_STANDARD },
2962 module_t *tcap_module;
2964 /* Register the protocol name and description */
2965 proto_tcap = proto_register_protocol(PNAME, PSNAME, PFNAME);
2967 /* Required function calls to register the header fields and subtrees used */
2968 proto_register_field_array(proto_tcap, hf, array_length(hf));
2969 proto_register_subtree_array(ett, array_length(ett));
2971 tcap_module = prefs_register_protocol(proto_tcap, proto_reg_handoff_tcap);
2974 prefs_register_enum_preference(tcap_module, "standard", "ITU TCAP standard",
2975 "The SS7 standard used in ITU TCAP packets",
2976 &tcap_standard, tcap_options, FALSE);
2978 prefs_register_obsolete_preference(tcap_module, "standard");
2982 prefs_register_bool_preference(tcap_module, "lock_info_col", "Lock Info column",
2983 "Always show TCAP in Info column",
2986 prefs_register_obsolete_preference(tcap_module, "lock_info_col");
2989 /* Set default SSNs */
2990 range_convert_str(&global_ssn_range, "", MAX_SSN);
2991 ssn_range = range_empty();
2993 prefs_register_range_preference(tcap_module, "ssn", "SCCP SSNs",
2994 "SCCP (and SUA) SSNs to decode as TCAP",
2995 &global_ssn_range, MAX_SSN);
2997 ansi_sub_dissectors = g_hash_table_new(g_direct_hash,g_direct_equal);
2998 itu_sub_dissectors = g_hash_table_new(g_direct_hash,g_direct_equal);
3000 /* 'globally' register dissector */
3001 register_dissector("tcap", dissect_tcap, proto_tcap);
3003 tcap_handle = create_dissector_handle(dissect_tcap, proto_tcap);
3005 register_init_routine(&init_tcap);
3009 static void range_delete_callback(guint32 ssn)
3011 if ( ssn && !get_ansi_tcap_subdissector(ssn) && !get_itu_tcap_subdissector(ssn) ) {
3012 dissector_delete("sccp.ssn", ssn, tcap_handle);
3016 static void range_add_callback(guint32 ssn)
3018 if (ssn && !get_ansi_tcap_subdissector(ssn) && !get_itu_tcap_subdissector(ssn) ) {
3019 dissector_add("sccp.ssn", ssn, tcap_handle);
3024 static void init_tcap(void) {
3026 range_foreach(ssn_range, range_delete_callback);
3030 ssn_range = range_copy(global_ssn_range);
3031 range_foreach(ssn_range, range_add_callback);
3036 dissect_tcap_param(packet_info *pinfo, proto_tree *tree, tvbuff_t *tvb, int offset)
3038 gint tag_offset, saved_offset, len_offset;
3040 proto_tree *subtree;
3048 while (tvb_reported_length_remaining(tvb, offset) > 0)
3050 saved_offset = offset;
3052 offset = get_ber_identifier(tvb, offset, &class, &pc, &tag);
3053 tag_offset = offset;
3054 offset = get_ber_length(tree, tvb, offset, &len, &ind_field);
3055 len_offset = offset;
3060 proto_tree_add_text(tree, tvb, saved_offset, len + (len_offset - saved_offset), "CONSTRUCTOR");
3061 subtree = proto_item_add_subtree(pi, ett_param);
3062 proto_tree_add_uint_format(subtree, hf_tcap_tag, tvb,
3063 saved_offset, tag_offset-saved_offset, tag, "CONSTRUCTOR Tag");
3064 proto_tree_add_uint(subtree, hf_tcap_tag, tvb,
3065 saved_offset, tag_offset-saved_offset, class);
3067 proto_tree_add_uint(subtree, hf_tcap_length, tvb,
3068 tag_offset, len_offset-tag_offset, len);
3069 if (len-(2*ind_field)) /*should always be positive unless we get an empty contructor pointless? */
3071 next_tvb = tvb_new_subset(tvb, offset, len-(2*ind_field), len-(2*ind_field));
3072 dissect_tcap_param(pinfo, subtree,next_tvb,0);
3075 proto_tree_add_text(subtree, tvb, offset+len-2, 2, "CONSTRUCTOR EOC");
3080 pi = proto_tree_add_text(tree, tvb,
3081 saved_offset, len + (len_offset - saved_offset), "Parameter (0x%.2x)", tag);
3083 subtree = proto_item_add_subtree(pi, ett_param);
3085 proto_tree_add_uint(subtree, hf_tcap_tag, tvb,
3086 saved_offset, 1, tag);
3088 proto_tree_add_uint(subtree, hf_tcap_length, tvb,
3089 saved_offset+1, 1, len);
3090 if (len) /* check for NULLS */
3092 next_tvb = tvb_new_subset(tvb, offset, len, len);
3093 dissect_ber_octet_string(TRUE, pinfo, tree, next_tvb, 0, hf_tcap_data,