5 * Routines for IDL dissection
7 * Autogenerated from idl2wrs
8 * Copyright 2001 Frank Singleton <frank.singleton@ericsson.com>
13 * Wireshark - Network traffic analyzer
15 * Copyright 1999 - 2012 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., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
41 #include <epan/packet.h>
42 #include <epan/proto.h>
43 #include <epan/dissectors/packet-giop.h>
44 #include <epan/expert.h>
47 /* disable warning: "unreference local variable" */
48 #pragma warning(disable:4101)
52 /* Initialise the protocol and subtree pointers */
53 static int proto_cosnaming
= -1;
54 static gint ett_cosnaming
= -1;
57 /* Initialise the initial Alignment */
58 static guint32 boundary
= GIOP_HEADER_SIZE
; /* initial value */
60 static int hf_operationrequest
= -1;/* Request_Operation field */
62 /* Operation filters */
63 static int hf_CosNaming_NamingContext_bind_n
= -1;
64 static int hf_CosNaming_NamingContext_bind_obj
= -1;
65 static int hf_CosNaming_NamingContext_rebind_n
= -1;
66 static int hf_CosNaming_NamingContext_rebind_obj
= -1;
67 static int hf_CosNaming_NamingContext_bind_context_n
= -1;
68 static int hf_CosNaming_NamingContext_bind_context_nc
= -1;
69 static int hf_CosNaming_NamingContext_rebind_context_n
= -1;
70 static int hf_CosNaming_NamingContext_rebind_context_nc
= -1;
71 static int hf_CosNaming_NamingContext_resolve_return
= -1;
72 static int hf_CosNaming_NamingContext_resolve_n
= -1;
73 static int hf_CosNaming_NamingContext_unbind_n
= -1;
74 static int hf_CosNaming_NamingContext_new_context_return
= -1;
75 static int hf_CosNaming_NamingContext_bind_new_context_return
= -1;
76 static int hf_CosNaming_NamingContext_bind_new_context_n
= -1;
77 static int hf_CosNaming_NamingContext_list_how_many
= -1;
78 static int hf_CosNaming_NamingContext_list_bl
= -1;
79 static int hf_CosNaming_NamingContext_list_bi
= -1;
80 static int hf_CosNaming_BindingIterator_next_one_return
= -1;
81 static int hf_CosNaming_BindingIterator_next_one_b
= -1;
82 static int hf_CosNaming_BindingIterator_next_n_return
= -1;
83 static int hf_CosNaming_BindingIterator_next_n_how_many
= -1;
84 static int hf_CosNaming_BindingIterator_next_n_bl
= -1;
86 static int hf_CosNaming_NameComponent_id
= -1;
87 static int hf_CosNaming_NameComponent_kind
= -1;
88 static int hf_CosNaming_Binding_binding_name
= -1;
89 static int hf_CosNaming_Binding_binding_type
= -1;
90 /* User exception filters */
91 static int hf_CosNaming_NamingContext_NotFound_why
= -1;
92 static int hf_CosNaming_NamingContext_NotFound_rest_of_name
= -1;
93 static int hf_CosNaming_NamingContext_CannotProceed_cxt
= -1;
94 static int hf_CosNaming_NamingContext_CannotProceed_rest_of_name
= -1;
95 /* Expert info filters */
96 static expert_field ei_cosnaming_unknown_giop_msg
= EI_INIT
;
97 static expert_field ei_cosnaming_unknown_exception
= EI_INIT
;
98 static expert_field ei_cosnaming_unknown_reply_status
= EI_INIT
;
101 static proto_tree
*start_dissecting(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*ptree
, int *offset
);
104 /* Struct prototype declaration Start */
106 /* Struct = IDL:omg.org/CosNaming/NameComponent:1.0 */
107 static void decode_CosNaming_NameComponent_st(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header _U_
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
);
109 /* Struct = IDL:omg.org/CosNaming/Binding:1.0 */
110 static void decode_CosNaming_Binding_st(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header _U_
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
);
112 /* Struct prototype declaration End */
119 * Enum = IDL:omg.org/CosNaming/BindingType:1.0
121 static const value_string CosNaming_BindingType
[] = {
129 * Enum = IDL:omg.org/CosNaming/NamingContext/NotFoundReason:1.0
131 static const value_string CosNaming_NamingContext_NotFoundReason
[] = {
133 { 0, "missing_node" },
134 { 1, "not_context" },
143 /* Begin Exception Helper Functions */
146 /* Exception = IDL:omg.org/CosNaming/NamingContext/NotFound:1.0 */
148 decode_ex_CosNaming_NamingContext_NotFound(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, int *offset _U_
, MessageHeader
*header _U_
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
150 proto_item
*item _U_
;
152 /* Operation specific Variable declarations Begin */
154 guint32 u_octet4_loop_CosNaming_NamingContext_NotFound_rest_of_name
;
155 guint32 i_CosNaming_NamingContext_NotFound_rest_of_name
;
156 /* Operation specific Variable declarations End */
158 (void)item
; /* Avoid coverity param_set_but_unused parse warning */
160 u_octet4
= get_CDR_enum(tvb
,offset
,stream_is_big_endian
, boundary
);
161 /* coverity[returned_pointer] */
162 item
= proto_tree_add_uint(tree
, hf_CosNaming_NamingContext_NotFound_why
, tvb
, *offset
-4, 4, u_octet4
);
164 u_octet4_loop_CosNaming_NamingContext_NotFound_rest_of_name
= get_CDR_ulong(tvb
, offset
, stream_is_big_endian
, boundary
);
165 /* coverity[returned_pointer] */
166 item
= proto_tree_add_uint(tree
, hf_CosNaming_NamingContext_NotFound_rest_of_name
, tvb
,*offset
-4, 4, u_octet4_loop_CosNaming_NamingContext_NotFound_rest_of_name
);
168 for (i_CosNaming_NamingContext_NotFound_rest_of_name
=0; i_CosNaming_NamingContext_NotFound_rest_of_name
< u_octet4_loop_CosNaming_NamingContext_NotFound_rest_of_name
; i_CosNaming_NamingContext_NotFound_rest_of_name
++) {
170 /* Begin struct "CosNaming_NameComponent" */
171 decode_CosNaming_NameComponent_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
172 /* End struct "CosNaming_NameComponent" */
177 /* Exception = IDL:omg.org/CosNaming/NamingContext/CannotProceed:1.0 */
179 decode_ex_CosNaming_NamingContext_CannotProceed(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, int *offset _U_
, MessageHeader
*header _U_
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
181 proto_item
*item _U_
;
183 /* Operation specific Variable declarations Begin */
184 guint32 u_octet4_loop_CosNaming_NamingContext_CannotProceed_rest_of_name
;
185 guint32 i_CosNaming_NamingContext_CannotProceed_rest_of_name
;
186 /* Operation specific Variable declarations End */
188 (void)item
; /* Avoid coverity param_set_but_unused parse warning */
190 get_CDR_object(tvb
, pinfo
, tree
, offset
, stream_is_big_endian
, boundary
);
192 u_octet4_loop_CosNaming_NamingContext_CannotProceed_rest_of_name
= get_CDR_ulong(tvb
, offset
, stream_is_big_endian
, boundary
);
193 /* coverity[returned_pointer] */
194 item
= proto_tree_add_uint(tree
, hf_CosNaming_NamingContext_CannotProceed_rest_of_name
, tvb
,*offset
-4, 4, u_octet4_loop_CosNaming_NamingContext_CannotProceed_rest_of_name
);
196 for (i_CosNaming_NamingContext_CannotProceed_rest_of_name
=0; i_CosNaming_NamingContext_CannotProceed_rest_of_name
< u_octet4_loop_CosNaming_NamingContext_CannotProceed_rest_of_name
; i_CosNaming_NamingContext_CannotProceed_rest_of_name
++) {
198 /* Begin struct "CosNaming_NameComponent" */
199 decode_CosNaming_NameComponent_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
200 /* End struct "CosNaming_NameComponent" */
206 /* End Exception Helper Functions */
209 * Main delegator for exception handling
213 decode_user_exception(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*ptree _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
215 proto_tree
*tree _U_
;
217 if (!header
->exception_id
)
220 if (strcmp(header
->exception_id
, "IDL:omg.org/CosNaming/NamingContext/NotFound:1.0") == 0) {
221 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
222 decode_ex_CosNaming_NamingContext_NotFound(tvb
, pinfo
, tree
, offset
, header
, operation
, stream_is_big_endian
); /* IDL:omg.org/CosNaming/NamingContext/NotFound:1.0 */
226 if (strcmp(header
->exception_id
, "IDL:omg.org/CosNaming/NamingContext/CannotProceed:1.0") == 0) {
227 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
228 decode_ex_CosNaming_NamingContext_CannotProceed(tvb
, pinfo
, tree
, offset
, header
, operation
, stream_is_big_endian
); /* IDL:omg.org/CosNaming/NamingContext/CannotProceed:1.0 */
233 return FALSE
; /* user exception not found */
237 * IDL:omg.org/CosNaming/NamingContext/bind:1.0
240 decode_CosNaming_NamingContext_bind(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
242 /* Operation specific Variable declarations Begin */
243 guint32 u_octet4_loop_CosNaming_NamingContext_bind_n
;
244 guint32 i_CosNaming_NamingContext_bind_n
;
245 /* Operation specific Variable declarations End */
247 (void)item
; /* Avoid coverity param_set_but_unused parse warning */
249 switch(header
->message_type
) {
251 u_octet4_loop_CosNaming_NamingContext_bind_n
= get_CDR_ulong(tvb
, offset
, stream_is_big_endian
, boundary
);
252 /* coverity[returned_pointer] */
253 item
= proto_tree_add_uint(tree
, hf_CosNaming_NamingContext_bind_n
, tvb
,*offset
-4, 4, u_octet4_loop_CosNaming_NamingContext_bind_n
);
255 for (i_CosNaming_NamingContext_bind_n
=0; i_CosNaming_NamingContext_bind_n
< u_octet4_loop_CosNaming_NamingContext_bind_n
; i_CosNaming_NamingContext_bind_n
++) {
257 /* Begin struct "CosNaming_NameComponent" */
258 decode_CosNaming_NameComponent_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
259 /* End struct "CosNaming_NameComponent" */
262 get_CDR_object(tvb
, pinfo
, tree
, offset
, stream_is_big_endian
, boundary
);
266 switch(header
->rep_status
) {
268 /* Function returns void */
274 /* Unknown Exception */
275 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
277 } /* switch(header->rep_status) */
281 /* Unknown GIOP Message */
282 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
284 } /* switch(header->message_type) */
288 * IDL:omg.org/CosNaming/NamingContext/rebind:1.0
291 decode_CosNaming_NamingContext_rebind(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
293 /* Operation specific Variable declarations Begin */
294 guint32 u_octet4_loop_CosNaming_NamingContext_rebind_n
;
295 guint32 i_CosNaming_NamingContext_rebind_n
;
296 /* Operation specific Variable declarations End */
298 (void)item
; /* Avoid coverity param_set_but_unused parse warning */
300 switch(header
->message_type
) {
302 u_octet4_loop_CosNaming_NamingContext_rebind_n
= get_CDR_ulong(tvb
, offset
, stream_is_big_endian
, boundary
);
303 /* coverity[returned_pointer] */
304 item
= proto_tree_add_uint(tree
, hf_CosNaming_NamingContext_rebind_n
, tvb
,*offset
-4, 4, u_octet4_loop_CosNaming_NamingContext_rebind_n
);
306 for (i_CosNaming_NamingContext_rebind_n
=0; i_CosNaming_NamingContext_rebind_n
< u_octet4_loop_CosNaming_NamingContext_rebind_n
; i_CosNaming_NamingContext_rebind_n
++) {
308 /* Begin struct "CosNaming_NameComponent" */
309 decode_CosNaming_NameComponent_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
310 /* End struct "CosNaming_NameComponent" */
313 get_CDR_object(tvb
, pinfo
, tree
, offset
, stream_is_big_endian
, boundary
);
317 switch(header
->rep_status
) {
319 /* Function returns void */
325 /* Unknown Exception */
326 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
328 } /* switch(header->rep_status) */
332 /* Unknown GIOP Message */
333 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
335 } /* switch(header->message_type) */
339 * IDL:omg.org/CosNaming/NamingContext/bind_context:1.0
342 decode_CosNaming_NamingContext_bind_context(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
344 /* Operation specific Variable declarations Begin */
345 guint32 u_octet4_loop_CosNaming_NamingContext_bind_context_n
;
346 guint32 i_CosNaming_NamingContext_bind_context_n
;
347 /* Operation specific Variable declarations End */
349 (void)item
; /* Avoid coverity param_set_but_unused parse warning */
351 switch(header
->message_type
) {
353 u_octet4_loop_CosNaming_NamingContext_bind_context_n
= get_CDR_ulong(tvb
, offset
, stream_is_big_endian
, boundary
);
354 /* coverity[returned_pointer] */
355 item
= proto_tree_add_uint(tree
, hf_CosNaming_NamingContext_bind_context_n
, tvb
,*offset
-4, 4, u_octet4_loop_CosNaming_NamingContext_bind_context_n
);
357 for (i_CosNaming_NamingContext_bind_context_n
=0; i_CosNaming_NamingContext_bind_context_n
< u_octet4_loop_CosNaming_NamingContext_bind_context_n
; i_CosNaming_NamingContext_bind_context_n
++) {
359 /* Begin struct "CosNaming_NameComponent" */
360 decode_CosNaming_NameComponent_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
361 /* End struct "CosNaming_NameComponent" */
364 get_CDR_object(tvb
, pinfo
, tree
, offset
, stream_is_big_endian
, boundary
);
368 switch(header
->rep_status
) {
370 /* Function returns void */
376 /* Unknown Exception */
377 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
379 } /* switch(header->rep_status) */
383 /* Unknown GIOP Message */
384 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
386 } /* switch(header->message_type) */
390 * IDL:omg.org/CosNaming/NamingContext/rebind_context:1.0
393 decode_CosNaming_NamingContext_rebind_context(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
395 /* Operation specific Variable declarations Begin */
396 guint32 u_octet4_loop_CosNaming_NamingContext_rebind_context_n
;
397 guint32 i_CosNaming_NamingContext_rebind_context_n
;
398 /* Operation specific Variable declarations End */
400 (void)item
; /* Avoid coverity param_set_but_unused parse warning */
402 switch(header
->message_type
) {
404 u_octet4_loop_CosNaming_NamingContext_rebind_context_n
= get_CDR_ulong(tvb
, offset
, stream_is_big_endian
, boundary
);
405 /* coverity[returned_pointer] */
406 item
= proto_tree_add_uint(tree
, hf_CosNaming_NamingContext_rebind_context_n
, tvb
,*offset
-4, 4, u_octet4_loop_CosNaming_NamingContext_rebind_context_n
);
408 for (i_CosNaming_NamingContext_rebind_context_n
=0; i_CosNaming_NamingContext_rebind_context_n
< u_octet4_loop_CosNaming_NamingContext_rebind_context_n
; i_CosNaming_NamingContext_rebind_context_n
++) {
410 /* Begin struct "CosNaming_NameComponent" */
411 decode_CosNaming_NameComponent_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
412 /* End struct "CosNaming_NameComponent" */
415 get_CDR_object(tvb
, pinfo
, tree
, offset
, stream_is_big_endian
, boundary
);
419 switch(header
->rep_status
) {
421 /* Function returns void */
427 /* Unknown Exception */
428 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
430 } /* switch(header->rep_status) */
434 /* Unknown GIOP Message */
435 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
437 } /* switch(header->message_type) */
441 * IDL:omg.org/CosNaming/NamingContext/resolve:1.0
444 decode_CosNaming_NamingContext_resolve(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
446 /* Operation specific Variable declarations Begin */
447 guint32 u_octet4_loop_CosNaming_NamingContext_resolve_n
;
448 guint32 i_CosNaming_NamingContext_resolve_n
;
449 /* Operation specific Variable declarations End */
451 (void)item
; /* Avoid coverity param_set_but_unused parse warning */
453 switch(header
->message_type
) {
455 u_octet4_loop_CosNaming_NamingContext_resolve_n
= get_CDR_ulong(tvb
, offset
, stream_is_big_endian
, boundary
);
456 /* coverity[returned_pointer] */
457 item
= proto_tree_add_uint(tree
, hf_CosNaming_NamingContext_resolve_n
, tvb
,*offset
-4, 4, u_octet4_loop_CosNaming_NamingContext_resolve_n
);
459 for (i_CosNaming_NamingContext_resolve_n
=0; i_CosNaming_NamingContext_resolve_n
< u_octet4_loop_CosNaming_NamingContext_resolve_n
; i_CosNaming_NamingContext_resolve_n
++) {
461 /* Begin struct "CosNaming_NameComponent" */
462 decode_CosNaming_NameComponent_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
463 /* End struct "CosNaming_NameComponent" */
468 switch(header
->rep_status
) {
470 get_CDR_object(tvb
, pinfo
, tree
, offset
, stream_is_big_endian
, boundary
);
476 /* Unknown Exception */
477 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
479 } /* switch(header->rep_status) */
483 /* Unknown GIOP Message */
484 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
486 } /* switch(header->message_type) */
490 * IDL:omg.org/CosNaming/NamingContext/unbind:1.0
493 decode_CosNaming_NamingContext_unbind(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
495 /* Operation specific Variable declarations Begin */
496 guint32 u_octet4_loop_CosNaming_NamingContext_unbind_n
;
497 guint32 i_CosNaming_NamingContext_unbind_n
;
498 /* Operation specific Variable declarations End */
500 (void)item
; /* Avoid coverity param_set_but_unused parse warning */
502 switch(header
->message_type
) {
504 u_octet4_loop_CosNaming_NamingContext_unbind_n
= get_CDR_ulong(tvb
, offset
, stream_is_big_endian
, boundary
);
505 /* coverity[returned_pointer] */
506 item
= proto_tree_add_uint(tree
, hf_CosNaming_NamingContext_unbind_n
, tvb
,*offset
-4, 4, u_octet4_loop_CosNaming_NamingContext_unbind_n
);
508 for (i_CosNaming_NamingContext_unbind_n
=0; i_CosNaming_NamingContext_unbind_n
< u_octet4_loop_CosNaming_NamingContext_unbind_n
; i_CosNaming_NamingContext_unbind_n
++) {
510 /* Begin struct "CosNaming_NameComponent" */
511 decode_CosNaming_NameComponent_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
512 /* End struct "CosNaming_NameComponent" */
517 switch(header
->rep_status
) {
519 /* Function returns void */
525 /* Unknown Exception */
526 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
528 } /* switch(header->rep_status) */
532 /* Unknown GIOP Message */
533 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
535 } /* switch(header->message_type) */
539 * IDL:omg.org/CosNaming/NamingContext/new_context:1.0
542 decode_CosNaming_NamingContext_new_context(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
544 switch(header
->message_type
) {
548 switch(header
->rep_status
) {
550 get_CDR_object(tvb
, pinfo
, tree
, offset
, stream_is_big_endian
, boundary
);
556 /* Unknown Exception */
557 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
559 } /* switch(header->rep_status) */
563 /* Unknown GIOP Message */
564 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
566 } /* switch(header->message_type) */
570 * IDL:omg.org/CosNaming/NamingContext/bind_new_context:1.0
573 decode_CosNaming_NamingContext_bind_new_context(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
575 /* Operation specific Variable declarations Begin */
576 guint32 u_octet4_loop_CosNaming_NamingContext_bind_new_context_n
;
577 guint32 i_CosNaming_NamingContext_bind_new_context_n
;
578 /* Operation specific Variable declarations End */
580 (void)item
; /* Avoid coverity param_set_but_unused parse warning */
582 switch(header
->message_type
) {
584 u_octet4_loop_CosNaming_NamingContext_bind_new_context_n
= get_CDR_ulong(tvb
, offset
, stream_is_big_endian
, boundary
);
585 /* coverity[returned_pointer] */
586 item
= proto_tree_add_uint(tree
, hf_CosNaming_NamingContext_bind_new_context_n
, tvb
,*offset
-4, 4, u_octet4_loop_CosNaming_NamingContext_bind_new_context_n
);
588 for (i_CosNaming_NamingContext_bind_new_context_n
=0; i_CosNaming_NamingContext_bind_new_context_n
< u_octet4_loop_CosNaming_NamingContext_bind_new_context_n
; i_CosNaming_NamingContext_bind_new_context_n
++) {
590 /* Begin struct "CosNaming_NameComponent" */
591 decode_CosNaming_NameComponent_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
592 /* End struct "CosNaming_NameComponent" */
597 switch(header
->rep_status
) {
599 get_CDR_object(tvb
, pinfo
, tree
, offset
, stream_is_big_endian
, boundary
);
605 /* Unknown Exception */
606 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
608 } /* switch(header->rep_status) */
612 /* Unknown GIOP Message */
613 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
615 } /* switch(header->message_type) */
619 * IDL:omg.org/CosNaming/NamingContext/destroy:1.0
622 decode_CosNaming_NamingContext_destroy(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
624 switch(header
->message_type
) {
628 switch(header
->rep_status
) {
630 /* Function returns void */
636 /* Unknown Exception */
637 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
639 } /* switch(header->rep_status) */
643 /* Unknown GIOP Message */
644 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
646 } /* switch(header->message_type) */
650 * IDL:omg.org/CosNaming/NamingContext/list:1.0
653 decode_CosNaming_NamingContext_list(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
655 /* Operation specific Variable declarations Begin */
656 guint32 u_octet4_loop_CosNaming_NamingContext_list_bl
;
657 guint32 i_CosNaming_NamingContext_list_bl
;
658 /* Operation specific Variable declarations End */
660 (void)item
; /* Avoid coverity param_set_but_unused parse warning */
662 switch(header
->message_type
) {
664 proto_tree_add_uint(tree
, hf_CosNaming_NamingContext_list_how_many
, tvb
, *offset
-4, 4, get_CDR_ulong(tvb
,offset
,stream_is_big_endian
, boundary
));
668 switch(header
->rep_status
) {
670 /* Function returns void */
672 u_octet4_loop_CosNaming_NamingContext_list_bl
= get_CDR_ulong(tvb
, offset
, stream_is_big_endian
, boundary
);
673 /* coverity[returned_pointer] */
674 item
= proto_tree_add_uint(tree
, hf_CosNaming_NamingContext_list_bl
, tvb
,*offset
-4, 4, u_octet4_loop_CosNaming_NamingContext_list_bl
);
676 for (i_CosNaming_NamingContext_list_bl
=0; i_CosNaming_NamingContext_list_bl
< u_octet4_loop_CosNaming_NamingContext_list_bl
; i_CosNaming_NamingContext_list_bl
++) {
678 /* Begin struct "CosNaming_Binding" */
679 decode_CosNaming_Binding_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
680 /* End struct "CosNaming_Binding" */
683 get_CDR_object(tvb
, pinfo
, tree
, offset
, stream_is_big_endian
, boundary
);
689 /* Unknown Exception */
690 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
692 } /* switch(header->rep_status) */
696 /* Unknown GIOP Message */
697 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
699 } /* switch(header->message_type) */
703 * IDL:omg.org/CosNaming/BindingIterator/next_one:1.0
706 decode_CosNaming_BindingIterator_next_one(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
708 switch(header
->message_type
) {
712 switch(header
->rep_status
) {
714 proto_tree_add_boolean(tree
, hf_CosNaming_BindingIterator_next_one_return
, tvb
, *offset
-1, 1, get_CDR_boolean(tvb
,offset
));
716 /* Begin struct "CosNaming_Binding" */
717 decode_CosNaming_Binding_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
718 /* End struct "CosNaming_Binding" */
723 /* Unknown Exception */
724 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
726 } /* switch(header->rep_status) */
730 /* Unknown GIOP Message */
731 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
733 } /* switch(header->message_type) */
737 * IDL:omg.org/CosNaming/BindingIterator/next_n:1.0
740 decode_CosNaming_BindingIterator_next_n(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
742 /* Operation specific Variable declarations Begin */
743 guint32 u_octet4_loop_CosNaming_BindingIterator_next_n_bl
;
744 guint32 i_CosNaming_BindingIterator_next_n_bl
;
745 /* Operation specific Variable declarations End */
747 (void)item
; /* Avoid coverity param_set_but_unused parse warning */
749 switch(header
->message_type
) {
751 proto_tree_add_uint(tree
, hf_CosNaming_BindingIterator_next_n_how_many
, tvb
, *offset
-4, 4, get_CDR_ulong(tvb
,offset
,stream_is_big_endian
, boundary
));
755 switch(header
->rep_status
) {
757 proto_tree_add_boolean(tree
, hf_CosNaming_BindingIterator_next_n_return
, tvb
, *offset
-1, 1, get_CDR_boolean(tvb
,offset
));
759 u_octet4_loop_CosNaming_BindingIterator_next_n_bl
= get_CDR_ulong(tvb
, offset
, stream_is_big_endian
, boundary
);
760 /* coverity[returned_pointer] */
761 item
= proto_tree_add_uint(tree
, hf_CosNaming_BindingIterator_next_n_bl
, tvb
,*offset
-4, 4, u_octet4_loop_CosNaming_BindingIterator_next_n_bl
);
763 for (i_CosNaming_BindingIterator_next_n_bl
=0; i_CosNaming_BindingIterator_next_n_bl
< u_octet4_loop_CosNaming_BindingIterator_next_n_bl
; i_CosNaming_BindingIterator_next_n_bl
++) {
765 /* Begin struct "CosNaming_Binding" */
766 decode_CosNaming_Binding_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
767 /* End struct "CosNaming_Binding" */
774 /* Unknown Exception */
775 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
777 } /* switch(header->rep_status) */
781 /* Unknown GIOP Message */
782 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
784 } /* switch(header->message_type) */
788 * IDL:omg.org/CosNaming/BindingIterator/destroy:1.0
791 decode_CosNaming_BindingIterator_destroy(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
793 switch(header
->message_type
) {
797 switch(header
->rep_status
) {
799 /* Function returns void */
805 /* Unknown Exception */
806 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_exception
, "Unknown exception %d", header
->rep_status
);
808 } /* switch(header->rep_status) */
812 /* Unknown GIOP Message */
813 expert_add_info_format(pinfo
, item
, &ei_cosnaming_unknown_giop_msg
, "Unknown GIOP message %d", header
->message_type
);
815 } /* switch(header->message_type) */
818 /* Struct = IDL:omg.org/CosNaming/NameComponent:1.0 */
820 decode_CosNaming_NameComponent_st(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header _U_
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
823 giop_add_CDR_string(tree
, tvb
, offset
, stream_is_big_endian
, boundary
, hf_CosNaming_NameComponent_id
);
825 giop_add_CDR_string(tree
, tvb
, offset
, stream_is_big_endian
, boundary
, hf_CosNaming_NameComponent_kind
);
829 /* Struct = IDL:omg.org/CosNaming/Binding:1.0 */
831 decode_CosNaming_Binding_st(tvbuff_t
*tvb _U_
, packet_info
*pinfo _U_
, proto_tree
*tree _U_
, proto_item
*item _U_
, int *offset _U_
, MessageHeader
*header _U_
, const gchar
*operation _U_
, gboolean stream_is_big_endian _U_
)
834 /* Operation specific Variable declarations Begin */
835 guint32 u_octet4_loop_CosNaming_Binding_binding_name
;
836 guint32 i_CosNaming_Binding_binding_name
;
838 /* Operation specific Variable declarations End */
840 (void)item
; /* Avoid coverity param_set_but_unused parse warning */
842 u_octet4_loop_CosNaming_Binding_binding_name
= get_CDR_ulong(tvb
, offset
, stream_is_big_endian
, boundary
);
843 /* coverity[returned_pointer] */
844 item
= proto_tree_add_uint(tree
, hf_CosNaming_Binding_binding_name
, tvb
,*offset
-4, 4, u_octet4_loop_CosNaming_Binding_binding_name
);
846 for (i_CosNaming_Binding_binding_name
=0; i_CosNaming_Binding_binding_name
< u_octet4_loop_CosNaming_Binding_binding_name
; i_CosNaming_Binding_binding_name
++) {
848 /* Begin struct "CosNaming_NameComponent" */
849 decode_CosNaming_NameComponent_st(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
850 /* End struct "CosNaming_NameComponent" */
853 u_octet4
= get_CDR_enum(tvb
,offset
,stream_is_big_endian
, boundary
);
854 /* coverity[returned_pointer] */
855 item
= proto_tree_add_uint(tree
, hf_CosNaming_Binding_binding_type
, tvb
, *offset
-4, 4, u_octet4
);
860 * Called once we accept the packet as being for us; it sets the
861 * Protocol and Info columns and creates the top-level protocol
865 start_dissecting(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*ptree
, int *offset
)
868 proto_item
*ti
= NULL
;
869 proto_tree
*tree
= NULL
; /* init later, inside if(tree) */
871 col_set_str(pinfo
->cinfo
, COL_PROTOCOL
, "COSNAMING");
874 * Do not clear COL_INFO, as nothing is being written there by
875 * this dissector yet. So leave it as is from the GIOP dissector.
876 * TODO: add something useful to COL_INFO
877 * col_clear(pinfo->cinfo, COL_INFO);
881 ti
= proto_tree_add_item(ptree
, proto_cosnaming
, tvb
, *offset
, -1, ENC_NA
);
882 tree
= proto_item_add_subtree(ti
, ett_cosnaming
);
888 process_RequestOperation(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*ptree
, MessageHeader
*header
, const gchar
*operation
)
891 if(header
->message_type
== Reply
) {
892 /* fill-up info column */
893 col_append_fstr(pinfo
->cinfo
, COL_INFO
, " op = %s",operation
);
895 /* fill-up the field */
896 pi
=proto_tree_add_string(ptree
, hf_operationrequest
, tvb
, 0, 0, operation
);
897 PROTO_ITEM_SET_GENERATED(pi
);
902 dissect_cosnaming(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*ptree
, int *offset
, MessageHeader
*header
, const gchar
*operation
, gchar
*idlname
)
904 proto_item
*item _U_
;
905 proto_tree
*tree _U_
;
906 gboolean stream_is_big_endian
= is_big_endian(header
); /* get endianess */
908 /* If we have a USER Exception, then decode it and return */
909 if ((header
->message_type
== Reply
) && (header
->rep_status
== USER_EXCEPTION
)) {
910 return decode_user_exception(tvb
, pinfo
, ptree
, offset
, header
, operation
, stream_is_big_endian
);
913 switch(header
->message_type
) {
918 if (strcmp(operation
, "bind") == 0
919 && (!idlname
|| strcmp(idlname
, "CosNaming/NamingContext") == 0)) {
920 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
921 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
922 decode_CosNaming_NamingContext_bind(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
926 if (strcmp(operation
, "rebind") == 0
927 && (!idlname
|| strcmp(idlname
, "CosNaming/NamingContext") == 0)) {
928 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
929 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
930 decode_CosNaming_NamingContext_rebind(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
934 if (strcmp(operation
, "bind_context") == 0
935 && (!idlname
|| strcmp(idlname
, "CosNaming/NamingContext") == 0)) {
936 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
937 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
938 decode_CosNaming_NamingContext_bind_context(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
942 if (strcmp(operation
, "rebind_context") == 0
943 && (!idlname
|| strcmp(idlname
, "CosNaming/NamingContext") == 0)) {
944 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
945 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
946 decode_CosNaming_NamingContext_rebind_context(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
950 if (strcmp(operation
, "resolve") == 0
951 && (!idlname
|| strcmp(idlname
, "CosNaming/NamingContext") == 0)) {
952 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
953 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
954 decode_CosNaming_NamingContext_resolve(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
958 if (strcmp(operation
, "unbind") == 0
959 && (!idlname
|| strcmp(idlname
, "CosNaming/NamingContext") == 0)) {
960 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
961 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
962 decode_CosNaming_NamingContext_unbind(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
966 if (strcmp(operation
, "new_context") == 0
967 && (!idlname
|| strcmp(idlname
, "CosNaming/NamingContext") == 0)) {
968 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
969 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
970 decode_CosNaming_NamingContext_new_context(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
974 if (strcmp(operation
, "bind_new_context") == 0
975 && (!idlname
|| strcmp(idlname
, "CosNaming/NamingContext") == 0)) {
976 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
977 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
978 decode_CosNaming_NamingContext_bind_new_context(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
982 if (strcmp(operation
, "destroy") == 0
983 && (!idlname
|| strcmp(idlname
, "CosNaming/NamingContext") == 0)) {
984 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
985 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
986 decode_CosNaming_NamingContext_destroy(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
990 if (strcmp(operation
, "list") == 0
991 && (!idlname
|| strcmp(idlname
, "CosNaming/NamingContext") == 0)) {
992 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
993 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
994 decode_CosNaming_NamingContext_list(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
998 if (strcmp(operation
, "next_one") == 0
999 && (!idlname
|| strcmp(idlname
, "CosNaming/BindingIterator") == 0)) {
1000 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
1001 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
1002 decode_CosNaming_BindingIterator_next_one(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
1006 if (strcmp(operation
, "next_n") == 0
1007 && (!idlname
|| strcmp(idlname
, "CosNaming/BindingIterator") == 0)) {
1008 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
1009 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
1010 decode_CosNaming_BindingIterator_next_n(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
1014 if (strcmp(operation
, "destroy") == 0
1015 && (!idlname
|| strcmp(idlname
, "CosNaming/BindingIterator") == 0)) {
1016 item
= process_RequestOperation(tvb
, pinfo
, ptree
, header
, operation
); /* fill-up Request_Operation field & info column */
1017 tree
= start_dissecting(tvb
, pinfo
, ptree
, offset
);
1018 decode_CosNaming_BindingIterator_destroy(tvb
, pinfo
, tree
, item
, offset
, header
, operation
, stream_is_big_endian
);
1027 case CloseConnection
:
1030 return FALSE
; /* not handled yet */
1033 return FALSE
; /* not handled yet */
1040 } /* End of main dissector */
1043 /* Register the protocol with Wireshark */
1044 void proto_register_giop_cosnaming(void)
1046 /* setup list of header fields */
1047 static hf_register_info hf
[] = {
1048 /* field that indicates the currently ongoing request/reply exchange */
1049 {&hf_operationrequest
, {"Request_Operation","giop-cosnaming.Request_Operation",FT_STRING
,BASE_NONE
,NULL
,0x0,NULL
,HFILL
}},
1050 /* Operation filters */
1051 {&hf_CosNaming_NamingContext_bind_n
, {"Seq length of n","giop-cosnaming.NamingContext.bind.n",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1052 {&hf_CosNaming_NamingContext_rebind_n
, {"Seq length of n","giop-cosnaming.NamingContext.rebind.n",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1053 {&hf_CosNaming_NamingContext_bind_context_n
, {"Seq length of n","giop-cosnaming.NamingContext.bind_context.n",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1054 {&hf_CosNaming_NamingContext_rebind_context_n
, {"Seq length of n","giop-cosnaming.NamingContext.rebind_context.n",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1055 {&hf_CosNaming_NamingContext_resolve_n
, {"Seq length of n","giop-cosnaming.NamingContext.resolve.n",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1056 {&hf_CosNaming_NamingContext_unbind_n
, {"Seq length of n","giop-cosnaming.NamingContext.unbind.n",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1057 {&hf_CosNaming_NamingContext_bind_new_context_n
, {"Seq length of n","giop-cosnaming.NamingContext.bind_new_context.n",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1058 {&hf_CosNaming_NamingContext_list_how_many
, {"how_many","giop-cosnaming.NamingContext.list.how_many",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1059 {&hf_CosNaming_NamingContext_list_bl
, {"Seq length of bl","giop-cosnaming.NamingContext.list.bl",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1060 {&hf_CosNaming_BindingIterator_next_one_return
, {"Return value","giop-cosnaming.BindingIterator.next_one.return",FT_BOOLEAN
,8,NULL
,0x01,NULL
,HFILL
}},
1061 {&hf_CosNaming_BindingIterator_next_n_return
, {"Return value","giop-cosnaming.BindingIterator.next_n.return",FT_BOOLEAN
,8,NULL
,0x01,NULL
,HFILL
}},
1062 {&hf_CosNaming_BindingIterator_next_n_how_many
, {"how_many","giop-cosnaming.BindingIterator.next_n.how_many",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1063 {&hf_CosNaming_BindingIterator_next_n_bl
, {"Seq length of bl","giop-cosnaming.BindingIterator.next_n.bl",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1064 /* Attribute filters */
1065 /* Struct filters */
1066 {&hf_CosNaming_NameComponent_id
, {"NameComponent_id","giop-cosnaming.NameComponent.id",FT_STRING
,BASE_NONE
,NULL
,0x0,NULL
,HFILL
}},
1067 {&hf_CosNaming_NameComponent_kind
, {"NameComponent_kind","giop-cosnaming.NameComponent.kind",FT_STRING
,BASE_NONE
,NULL
,0x0,NULL
,HFILL
}},
1068 {&hf_CosNaming_Binding_binding_name
, {"Seq length of Binding_binding_name","giop-cosnaming.Binding.binding_name",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1069 {&hf_CosNaming_Binding_binding_type
, {"Binding_binding_type","giop-cosnaming.Binding.binding_type",FT_UINT32
,BASE_DEC
,VALS(CosNaming_BindingType
),0x0,NULL
,HFILL
}},
1070 /* User exception filters */
1071 {&hf_CosNaming_NamingContext_NotFound_why
, {"NotFound_why","giop-cosnaming.NamingContext.NotFound_why",FT_UINT32
,BASE_DEC
,VALS(CosNaming_NamingContext_NotFoundReason
),0x0,NULL
,HFILL
}},
1072 {&hf_CosNaming_NamingContext_NotFound_rest_of_name
, {"Seq length of NotFound_rest_of_name","giop-cosnaming.NamingContext.NotFound_rest_of_name",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1073 {&hf_CosNaming_NamingContext_CannotProceed_rest_of_name
, {"Seq length of CannotProceed_rest_of_name","giop-cosnaming.NamingContext.CannotProceed_rest_of_name",FT_UINT32
,BASE_DEC
,NULL
,0x0,NULL
,HFILL
}},
1078 static ei_register_info ei
[] = {
1079 { &ei_cosnaming_unknown_giop_msg
, { "giop-cosnaming.unknown_giop_msg", PI_PROTOCOL
, PI_WARN
, "Unknown GIOP message", EXPFILL
}},
1080 { &ei_cosnaming_unknown_exception
, { "giop-cosnaming.unknown_exception", PI_PROTOCOL
, PI_WARN
, "Unknown exception", EXPFILL
}},
1081 { &ei_cosnaming_unknown_reply_status
, { "giop-cosnaming.unknown_reply_status", PI_PROTOCOL
, PI_WARN
, "Unknown reply status", EXPFILL
}},
1084 /* setup protocol subtree array */
1086 static gint
*ett
[] = {
1090 expert_module_t
* expert_cosnaming
;
1093 /* Register the protocol name and description */
1094 proto_cosnaming
= proto_register_protocol("Cosnaming Dissector Using GIOP API" , "COSNAMING", "giop-cosnaming" );
1095 proto_register_field_array(proto_cosnaming
, hf
, array_length(hf
));
1096 proto_register_subtree_array(ett
, array_length(ett
));
1098 expert_cosnaming
= expert_register_protocol(proto_cosnaming
);
1099 expert_register_field_array(expert_cosnaming
, ei
, array_length(ei
));
1102 /* register me as handler for these interfaces */
1103 void proto_reg_handoff_giop_cosnaming(void)
1106 /* Register for Explicit Dissection */
1107 register_giop_user_module(dissect_cosnaming
, "COSNAMING", "CosNaming/BindingIterator", proto_cosnaming
); /* explicit dissector */
1109 /* Register for Explicit Dissection */
1110 register_giop_user_module(dissect_cosnaming
, "COSNAMING", "CosNaming/NamingContext", proto_cosnaming
); /* explicit dissector */
1112 /* Register for Heuristic Dissection */
1113 register_giop_user(dissect_cosnaming
, "COSNAMING" ,proto_cosnaming
); /* heuristic dissector */