2 * Routines for NetWare's NDPS
3 * Greg Morris <gmorris@novell.com>
4 * Copyright (c) Novell, Inc. 2002-2003
6 * $Id: packet-ndps.c,v 1.21 2003/04/21 23:06:38 guy Exp $
8 * Ethereal - Network traffic analyzer
9 * By Gerald Combs <gerald@ethereal.com>
10 * Copyright 1998 Gerald Combs
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation; either version 2
15 * of the License, or (at your option) any later version.
17 * This program is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
22 * You should have received a copy of the GNU General Public License
23 * along with this program; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
33 #include <epan/packet.h>
35 #include "packet-ipx.h"
36 #include "packet-tcp.h"
37 #include <epan/conversation.h>
38 #include "packet-ndps.h"
39 #include "reassemble.h"
41 #define NDPS_PACKET_INIT_COUNT 200
43 /* Tables for reassembly of fragments. */
44 static GHashTable *ndps_fragment_table = NULL;
45 static GHashTable *ndps_reassembled_table = NULL;
47 /* desegmentation of ndps */
48 static gboolean ndps_defragment = TRUE;
49 static guint32 frag_number = 0;
50 static guint32 save_frag_length=0;
51 static guint32 save_frag_seq=0;
52 static gboolean ndps_fragmented = FALSE;
53 static gboolean more_fragment = FALSE;
54 static guint32 tid = 1;
57 static gboolean ndps_show_oids=FALSE;
59 /* Global Attribute for evaluation of Values */
60 static char *global_attribute_name=NULL;
62 static void dissect_ndps_request(tvbuff_t*, packet_info*, proto_tree*, guint32, guint32, int);
64 static void dissect_ndps_reply(tvbuff_t *, packet_info*, proto_tree*, int);
66 static int hf_ndps_segments = -1;
67 static int hf_ndps_segment = -1;
68 static int hf_ndps_segment_overlap = -1;
69 static int hf_ndps_segment_overlap_conflict = -1;
70 static int hf_ndps_segment_multiple_tails = -1;
71 static int hf_ndps_segment_too_long_segment = -1;
72 static int hf_ndps_segment_error = -1;
74 static gint ett_ndps_segments = -1;
75 static gint ett_ndps_segment = -1;
77 static int proto_ndps = -1;
78 static int hf_ndps_record_mark = -1;
79 static int hf_ndps_length = -1;
80 static int hf_ndps_xid = -1;
81 static int hf_ndps_packet_type = -1;
82 static int hf_ndps_rpc_version = -1;
83 static int hf_ndps_error = -1;
84 static int hf_ndps_items = -1;
85 static int hf_ndps_objects = -1;
86 static int hf_ndps_attributes = -1;
87 static int hf_ndps_sbuffer = -1;
88 static int hf_ndps_rbuffer = -1;
89 static int hf_ndps_user_name = -1;
90 static int hf_ndps_broker_name = -1;
91 static int hf_ndps_pa_name = -1;
92 static int hf_ndps_tree = -1;
93 static int hf_ndps_reqframe = -1;
94 static int hf_ndps_error_val = -1;
95 static int hf_ndps_ext_error = -1;
96 static int hf_ndps_object = -1;
97 static int hf_ndps_cred_type = -1;
98 static int hf_ndps_server_name = -1;
99 static int hf_ndps_connection = -1;
100 static int hf_ndps_auth_null = -1;
101 static int hf_ndps_rpc_accept = -1;
102 static int hf_ndps_rpc_acc_stat = -1;
103 static int hf_ndps_rpc_rej_stat = -1;
104 static int hf_ndps_rpc_acc_results = -1;
105 static int hf_ndps_problem_type = -1;
106 static int hf_security_problem_type = -1;
107 static int hf_service_problem_type = -1;
108 static int hf_access_problem_type = -1;
109 static int hf_printer_problem_type = -1;
110 static int hf_selection_problem_type = -1;
111 static int hf_doc_access_problem_type = -1;
112 static int hf_attribute_problem_type = -1;
113 static int hf_update_problem_type = -1;
114 static int hf_obj_id_type = -1;
115 static int hf_oid_struct_size = -1;
116 static int hf_object_name = -1;
117 static int hf_ndps_document_number = -1;
118 static int hf_ndps_nameorid = -1;
119 static int hf_local_object_name = -1;
120 static int hf_printer_name = -1;
121 static int hf_ndps_qualified_name = -1;
122 static int hf_ndps_item_count = -1;
123 static int hf_ndps_qualifier = -1;
124 static int hf_ndps_lib_error = -1;
125 static int hf_ndps_other_error = -1;
126 static int hf_ndps_other_error_2 = -1;
127 static int hf_ndps_session = -1;
128 static int hf_ndps_abort_flag = -1;
129 static int hf_obj_attribute_type = -1;
130 static int hf_ndps_attribute_value = -1;
131 static int hf_ndps_lower_range = -1;
132 static int hf_ndps_upper_range = -1;
133 static int hf_ndps_n64 = -1;
134 static int hf_ndps_lower_range_n64 = -1;
135 static int hf_ndps_upper_range_n64 = -1;
136 static int hf_ndps_attrib_boolean = -1;
137 static int hf_ndps_realization = -1;
138 static int hf_ndps_xdimension_n64 = -1;
139 static int hf_ndps_ydimension_n64 = -1;
140 static int hf_ndps_dim_value = -1;
141 static int hf_ndps_dim_flag = -1;
142 static int hf_ndps_xydim_value = -1;
143 static int hf_ndps_location_value = -1;
144 static int hf_ndps_xmin_n64 = -1;
145 static int hf_ndps_xmax_n64 = -1;
146 static int hf_ndps_ymin_n64 = -1;
147 static int hf_ndps_ymax_n64 = -1;
148 static int hf_ndps_edge_value = -1;
149 static int hf_ndps_cardinal_or_oid = -1;
150 static int hf_ndps_cardinal_name_or_oid = -1;
151 static int hf_ndps_integer_or_oid = -1;
152 static int hf_ndps_profile_id = -1;
153 static int hf_ndps_persistence = -1;
154 static int hf_ndps_language_id = -1;
155 static int hf_address_type = -1;
156 static int hf_ndps_address = -1;
157 static int hf_ndps_add_bytes = -1;
158 static int hf_ndps_event_type = -1;
159 static int hf_ndps_event_object_identifier = -1;
160 static int hf_ndps_octet_string = -1;
161 static int hf_ndps_scope = -1;
162 static int hf_address_len = -1;
163 static int hf_ndps_net = -1;
164 static int hf_ndps_node = -1;
165 static int hf_ndps_socket = -1;
166 static int hf_ndps_port = -1;
167 static int hf_ndps_ip = -1;
168 static int hf_ndps_server_type = -1;
169 static int hf_ndps_service_type = -1;
170 static int hf_ndps_service_enabled = -1;
171 static int hf_ndps_method_name = -1;
172 static int hf_ndps_method_ver = -1;
173 static int hf_ndps_file_name = -1;
174 static int hf_ndps_admin_submit = -1;
175 static int hf_ndps_oid = -1;
176 static int hf_ndps_object_op = -1;
177 static int hf_answer_time = -1;
178 static int hf_oid_asn1_type = -1;
179 static int hf_ndps_item_ptr = -1;
180 static int hf_ndps_len = -1;
181 static int hf_limit_enc = -1;
182 static int hf_ndps_qualified_name2 = -1;
183 static int hf_ndps_delivery_add_type = -1;
184 static int hf_ndps_criterion_type = -1;
185 static int hf_ndps_ignored_type = -1;
186 static int hf_ndps_resource_type = -1;
187 static int hf_ndps_identifier_type = -1;
188 static int hf_ndps_page_flag = -1;
189 static int hf_ndps_media_type = -1;
190 static int hf_ndps_doc_content = -1;
191 static int hf_ndps_page_size = -1;
192 static int hf_ndps_direction = -1;
193 static int hf_ndps_page_order = -1;
194 static int hf_ndps_medium_size = -1;
195 static int hf_ndps_long_edge_feeds = -1;
196 static int hf_ndps_inc_across_feed = -1;
197 static int hf_ndps_size_inc_in_feed = -1;
198 static int hf_ndps_page_orientation = -1;
199 static int hf_ndps_numbers_up = -1;
200 static int hf_ndps_xdimension = -1;
201 static int hf_ndps_ydimension = -1;
202 static int hf_ndps_state_severity = -1;
203 static int hf_ndps_training = -1;
204 static int hf_ndps_colorant_set = -1;
205 static int hf_ndps_card_enum_time = -1;
206 static int hf_ndps_attrs_arg = -1;
207 static int hf_ndps_context = -1;
208 static int hf_ndps_filter = -1;
209 static int hf_ndps_item_filter = -1;
210 static int hf_ndps_substring_match = -1;
211 static int hf_ndps_time_limit = -1;
212 static int hf_ndps_count_limit = -1;
213 static int hf_ndps_operator = -1;
214 static int hf_ndps_password = -1;
215 static int hf_ndps_retrieve_restrictions = -1;
216 static int hf_bind_security = -1;
217 static int hf_ndps_max_items = -1;
218 static int hf_ndps_status_flags = -1;
219 static int hf_ndps_resource_list_type = -1;
220 static int hf_os_type = -1;
221 static int hf_ndps_printer_type = -1;
222 static int hf_ndps_printer_manuf = -1;
223 static int hf_ndps_inf_file_name = -1;
224 static int hf_ndps_vendor_dir = -1;
225 static int hf_banner_type = -1;
226 static int hf_font_type = -1;
227 static int hf_printer_id = -1;
228 static int hf_ndps_font_name = -1;
229 static int hf_ndps_return_code = -1;
230 static int hf_ndps_banner_name = -1;
231 static int hf_font_type_name = -1;
232 static int hf_font_file_name = -1;
233 static int hf_ndps_prn_file_name = -1;
234 static int hf_ndps_prn_dir_name = -1;
235 static int hf_ndps_def_file_name = -1;
236 static int hf_ndps_win31_items = -1;
237 static int hf_ndps_win95_items = -1;
238 static int hf_ndps_windows_key = -1;
239 static int hf_archive_type = -1;
240 static int hf_archive_file_size = -1;
241 static int hf_ndps_data = -1;
242 static int hf_get_status_flag = -1;
243 static int hf_res_type = -1;
244 static int hf_file_timestamp = -1;
245 static int hf_sub_complete = -1;
246 static int hf_doc_content = -1;
247 static int hf_ndps_doc_name = -1;
248 static int hf_print_arg = -1;
249 static int hf_local_id = -1;
250 static int hf_ndps_included_doc = -1;
251 static int hf_ndps_ref_name = -1;
252 static int hf_interrupt_job_type = -1;
253 static int hf_pause_job_type = -1;
254 static int hf_ndps_force = -1;
255 static int hf_resubmit_op_type = -1;
256 static int hf_shutdown_type = -1;
257 static int hf_ndps_supplier_flag = -1;
258 static int hf_ndps_language_flag = -1;
259 static int hf_ndps_method_flag = -1;
260 static int hf_ndps_delivery_address_flag = -1;
261 static int hf_ndps_list_profiles_type = -1;
262 static int hf_ndps_list_profiles_choice_type = -1;
263 static int hf_ndps_list_profiles_result_type = -1;
264 static int hf_ndps_integer_type_flag = -1;
265 static int hf_ndps_integer_type_value = -1;
266 static int hf_ndps_continuation_option = -1;
267 static int hf_ndps_ds_info_type = -1;
268 static int hf_ndps_guid = -1;
269 static int hf_ndps_list_services_type = -1;
270 static int hf_ndps_item_bytes = -1;
271 static int hf_ndps_certified = -1;
272 static int hf_ndps_attribute_set = -1;
273 static int hf_ndps_data_item_type = -1;
274 static int hf_info_int = -1;
275 static int hf_info_int16 = -1;
276 static int hf_info_int32 = -1;
277 static int hf_info_boolean = -1;
278 static int hf_info_string = -1;
279 static int hf_info_bytes = -1;
280 static int hf_ndps_list_local_servers_type = -1;
281 static int hf_ndps_registry_name = -1;
282 static int hf_ndps_client_server_type = -1;
283 static int hf_ndps_session_type = -1;
284 static int hf_time = -1;
285 static int hf_ndps_supplier_name = -1;
286 static int hf_ndps_message = -1;
287 static int hf_delivery_method_type = -1;
288 static int hf_ndps_get_session_type = -1;
289 static int hf_packet_count = -1;
290 static int hf_last_packet_flag = -1;
291 static int hf_ndps_get_resman_session_type = -1;
292 static int hf_problem_type = -1;
293 static int hf_ndps_values = -1;
294 static int hf_ndps_object_ids_7 = -1;
295 static int hf_ndps_object_ids_8 = -1;
296 static int hf_ndps_object_ids_9 = -1;
297 static int hf_ndps_object_ids_10 = -1;
298 static int hf_ndps_object_ids_11 = -1;
299 static int hf_ndps_object_ids_12 = -1;
300 static int hf_ndps_object_ids_13 = -1;
301 static int hf_ndps_object_ids_14 = -1;
302 static int hf_ndps_object_ids_15 = -1;
303 static int hf_ndps_object_ids_16 = -1;
304 static int hf_ndps_attribute_time = -1;
305 static int hf_print_security = -1;
306 static int hf_notify_time_interval = -1;
307 static int hf_notify_sequence_number = -1;
308 static int hf_notify_lease_exp_time = -1;
309 static int hf_notify_printer_uri = -1;
310 static int hf_level = -1;
311 static int hf_interval = -1;
313 static int hf_spx_ndps_program = -1;
314 static int hf_spx_ndps_version = -1;
315 static int hf_spx_ndps_func_print = -1;
316 static int hf_spx_ndps_func_registry = -1;
317 static int hf_spx_ndps_func_notify = -1;
318 static int hf_spx_ndps_func_resman = -1;
319 static int hf_spx_ndps_func_delivery = -1;
320 static int hf_spx_ndps_func_broker = -1;
322 static gint ett_ndps = -1;
323 static dissector_handle_t ndps_data_handle;
325 /* desegmentation of NDPS over TCP */
326 static gboolean ndps_desegment = TRUE;
328 static const value_string true_false[] = {
329 { 0x00000000, "Accept" },
330 { 0x00000001, "Deny" },
334 static const value_string ndps_limit_enc_enum[] = {
335 { 0x00000000, "Time" },
336 { 0x00000001, "Count" },
337 { 0x00000002, "Error" },
341 static const value_string problem_type_enum[] = {
342 { 0x00000000, "Standard" },
343 { 0x00000001, "Extended" },
347 static const value_string accept_stat[] = {
348 { 0x00000000, "Success" },
349 { 0x00000001, "Program Unavailable" },
350 { 0x00000002, "Program Mismatch" },
351 { 0x00000003, "Procedure Unavailable" },
352 { 0x00000004, "Garbage Arguments" },
353 { 0x00000005, "System Error" },
357 static const value_string reject_stat[] = {
358 { 0x00000000, "RPC Mismatch" },
359 { 0x00000001, "Authentication Error" },
363 static const value_string error_type_enum[] = {
364 { 0x00000000, "Security Error" },
365 { 0x00000001, "Service Error" },
366 { 0x00000002, "Access Error" },
367 { 0x00000003, "Printer Error" },
368 { 0x00000004, "Selection Error" },
369 { 0x00000005, "Document Access Error" },
370 { 0x00000006, "Attribute Error" },
371 { 0x00000007, "Update Error" },
375 static const value_string security_problem_enum[] = {
376 { 0x00000000, "Authentication" },
377 { 0x00000001, "Credentials" },
378 { 0x00000002, "Rights" },
379 { 0x00000003, "Invalid PAC" },
383 static const value_string service_problem_enum[] = {
384 { 0x00000000, "Sever Busy" },
385 { 0x00000001, "Server Unavailable" },
386 { 0x00000002, "Complex Operation" },
387 { 0x00000003, "Resource Limit" },
388 { 0x00000004, "Unclassified Server Error" },
389 { 0x00000005, "Too Many Items in List" },
390 { 0x00000006, "Resource not Available" },
391 { 0x00000007, "Cancel Document Support" },
392 { 0x00000008, "Modify Document Support" },
393 { 0x00000009, "Multiple Document Support" },
394 { 0x0000000a, "Parameter Valid Support" },
395 { 0x0000000b, "Invalid Checkpoint" },
396 { 0x0000000c, "Continuation Context" },
397 { 0x0000000d, "Pause Limit Exceeded" },
398 { 0x0000000e, "Unsupported Operation" },
399 { 0x0000000f, "Notify Service Error" },
400 { 0x00000010, "Accounting Service Error" },
404 static const value_string access_problem_enum[] = {
405 { 0x00000000, "Wrong Object Class" },
406 { 0x00000001, "Lack of Access Rights" },
407 { 0x00000002, "Can't Interrupt Job" },
408 { 0x00000003, "Wrong Object State" },
409 { 0x00000004, "Client Not Bound" },
410 { 0x00000005, "Not Available" },
411 { 0x00000006, "Notify Service Not Connected" },
412 { 0x00000007, "PDS Not Connected" },
416 static const value_string printer_problem_enum[] = {
417 { 0x00000000, "Printer Error" },
418 { 0x00000001, "Printer Needs Attention" },
419 { 0x00000002, "Printer Needs Key Operator" },
423 static const value_string selection_problem_enum[] = {
424 { 0x00000000, "Invalid ID" },
425 { 0x00000001, "Unknown ID" },
426 { 0x00000002, "Object Exists" },
427 { 0x00000003, "ID Changed" },
431 static const value_string doc_access_problem_enum[] = {
432 { 0x00000000, "Access Not Available" },
433 { 0x00000001, "Time Expired" },
434 { 0x00000002, "Access Denied" },
435 { 0x00000003, "Unknown Document" },
436 { 0x00000004, "No Documents in Job" },
440 static const value_string attribute_problem_enum[] = {
441 { 0x00000000, "Invalid Syntax" },
442 { 0x00000001, "Undefined Type" },
443 { 0x00000002, "Wrong Matching" },
444 { 0x00000003, "Constraint Violated" },
445 { 0x00000004, "Unsupported Type" },
446 { 0x00000005, "Illegal Modification" },
447 { 0x00000006, "Consists With Other Attribute" },
448 { 0x00000007, "Undefined Attribute Value" },
449 { 0x00000008, "Unsupported Value" },
450 { 0x00000009, "Invalid Noncompulsed Modification" },
451 { 0x0000000a, "Per Job Inadmissible" },
452 { 0x0000000b, "Not Multivalued" },
453 { 0x0000000c, "Mandatory Omitted" },
454 { 0x0000000d, "Illegal For Class" },
458 static const value_string update_problem_enum[] = {
459 { 0x00000000, "No Modifications Allowed" },
460 { 0x00000001, "Insufficient Rights" },
461 { 0x00000002, "Previous Operation Incomplete" },
462 { 0x00000003, "Cancel Not Possible" },
466 static const value_string obj_identification_enum[] = {
467 { 0x00000000, "Printer Contained Object ID" },
468 { 0x00000001, "Document Identifier" },
469 { 0x00000002, "Object Identifier" },
470 { 0x00000003, "Object Name" },
471 { 0x00000004, "Name or Object ID" },
472 { 0x00000005, "Simple Name" },
473 { 0x00000006, "Printer Configuration Object ID" },
474 { 0x00000007, "Qualified Name" },
475 { 0x00000008, "Event Object ID" },
479 static const value_string nameorid_enum[] = {
480 { 0x00000000, "None" },
481 { 0x00000001, "Global" },
482 { 0x00000002, "Local" },
486 static const value_string qualified_name_enum[] = {
487 { 0x00000000, "None" },
488 { 0x00000001, "Simple" },
489 { 0x00000002, "NDS" },
493 static const value_string qualified_name_enum2[] = {
494 { 0x00000000, "NDS" },
498 static const value_string spx_ndps_program_vals[] = {
499 { 0x00060976, "Print Program" },
500 { 0x00060977, "Broker Program" },
501 { 0x00060978, "Registry Program" },
502 { 0x00060979, "Notify Program" },
503 { 0x0006097a, "Resource Manager Program" },
504 { 0x0006097b, "Programmatic Delivery Program" },
508 static const value_string spx_ndps_print_func_vals[] = {
509 { 0x00000000, "None" },
510 { 0x00000001, "Bind PSM" },
511 { 0x00000002, "Bind PA" },
512 { 0x00000003, "Unbind" },
513 { 0x00000004, "Print" },
514 { 0x00000005, "Modify Job" },
515 { 0x00000006, "Cancel Job" },
516 { 0x00000007, "List Object Attributes" },
517 { 0x00000008, "Promote Job" },
518 { 0x00000009, "Interrupt" },
519 { 0x0000000a, "Pause" },
520 { 0x0000000b, "Resume" },
521 { 0x0000000c, "Clean" },
522 { 0x0000000d, "Create" },
523 { 0x0000000e, "Delete" },
524 { 0x0000000f, "Disable PA" },
525 { 0x00000010, "Enable PA" },
526 { 0x00000011, "Resubmit Jobs" },
527 { 0x00000012, "Set" },
528 { 0x00000013, "Shutdown PA" },
529 { 0x00000014, "Startup PA" },
530 { 0x00000015, "Reorder Job" },
531 { 0x00000016, "Pause PA" },
532 { 0x00000017, "Resume PA" },
533 { 0x00000018, "Transfer Data" },
534 { 0x00000019, "Device Control" },
535 { 0x0000001a, "Add Event Profile" },
536 { 0x0000001b, "Remove Event Profile" },
537 { 0x0000001c, "Modify Event Profile" },
538 { 0x0000001d, "List Event Profiles" },
539 { 0x0000001e, "Shutdown PSM" },
540 { 0x0000001f, "Cancel PSM Shutdown" },
541 { 0x00000020, "Set Printer DS Information" },
542 { 0x00000021, "Clean User Jobs" },
543 { 0x00000022, "Map GUID to NDS Name" },
544 { 0x00000023, "Add Event Profile 2" },
545 { 0x00000024, "List Event Profile 2" },
549 static const value_string spx_ndps_notify_func_vals[] = {
550 { 0x00000000, "None" },
551 { 0x00000001, "Notify Bind" },
552 { 0x00000002, "Notify Unbind" },
553 { 0x00000003, "Register Supplier" },
554 { 0x00000004, "Deregister Supplier" },
555 { 0x00000005, "Add Profile" },
556 { 0x00000006, "Remove Profile" },
557 { 0x00000007, "Modify Profile" },
558 { 0x00000008, "List Profiles" },
559 { 0x00000009, "Report Event" },
560 { 0x0000000a, "List Supported Languages" },
561 { 0x0000000b, "Report Notification" },
562 { 0x0000000c, "Add Delivery Method" },
563 { 0x0000000d, "Remove Delivery Method" },
564 { 0x0000000e, "List Delivery Methods" },
565 { 0x0000000f, "Get Delivery Method Information" },
566 { 0x00000010, "Get Notify NDS Object Name" },
567 { 0x00000011, "Get Notify Session Information" },
571 static const value_string spx_ndps_deliver_func_vals[] = {
572 { 0x00000000, "None" },
573 { 0x00000001, "Delivery Bind" },
574 { 0x00000002, "Delivery Unbind" },
575 { 0x00000003, "Delivery Send" },
576 { 0x00000004, "Delivery Send2" },
580 static const value_string spx_ndps_registry_func_vals[] = {
581 { 0x00000000, "None" },
582 { 0x00000001, "Bind" },
583 { 0x00000002, "Unbind" },
584 { 0x00000003, "Register Server" },
585 { 0x00000004, "Deregister Server" },
586 { 0x00000005, "Register Registry" },
587 { 0x00000006, "Deregister Registry" },
588 { 0x00000007, "Registry Update" },
589 { 0x00000008, "List Local Servers" },
590 { 0x00000009, "List Servers" },
591 { 0x0000000a, "List Known Registries" },
592 { 0x0000000b, "Get Registry NDS Object Name" },
593 { 0x0000000c, "Get Registry Session Information" },
597 static const value_string spx_ndps_resman_func_vals[] = {
598 { 0x00000000, "None" },
599 { 0x00000001, "Bind" },
600 { 0x00000002, "Unbind" },
601 { 0x00000003, "Add Resource File" },
602 { 0x00000004, "Delete Resource File" },
603 { 0x00000005, "List Resources" },
604 { 0x00000006, "Get Resource File" },
605 { 0x00000007, "Get Resource File Date" },
606 { 0x00000008, "Get Resource Manager NDS Object Name" },
607 { 0x00000009, "Get Resource Manager Session Information" },
608 { 0x0000000a, "Set Resource Language Context" },
612 static const value_string spx_ndps_broker_func_vals[] = {
613 { 0x00000000, "None" },
614 { 0x00000001, "Bind" },
615 { 0x00000002, "Unbind" },
616 { 0x00000003, "List Services" },
617 { 0x00000004, "Enable Service" },
618 { 0x00000005, "Disable Service" },
619 { 0x00000006, "Down Broker" },
620 { 0x00000007, "Get Broker NDS Object Name" },
621 { 0x00000008, "Get Broker Session Information" },
625 static const value_string ndps_packet_types[] = {
626 { 0x00000000, "Request" },
627 { 0x00000001, "Reply" },
631 static const value_string ndps_realization_enum[] = {
632 { 0x00000000, "Logical" },
633 { 0x00000001, "Physical" },
634 { 0x00000002, "Logical & Physical" },
638 static const value_string ndps_dim_value_enum[] = {
639 { 0x00000000, "Numeric" },
640 { 0x00000001, "Named" },
644 static const value_string ndps_xydim_value_enum[] = {
645 { 0x00000000, "Real" },
646 { 0x00000001, "Named" },
647 { 0x00000002, "Cardinal" },
651 static const value_string ndps_location_value_enum[] = {
652 { 0x00000000, "Numeric" },
653 { 0x00000001, "Named" },
657 static const value_string ndps_edge_value_enum[] = {
658 { 0x00000000, "Bottom" },
659 { 0x00000001, "Right" },
660 { 0x00000002, "Top" },
661 { 0x00000003, "Left" },
665 static const value_string ndps_card_or_oid_enum[] = {
666 { 0x00000000, "Number" },
667 { 0x00000001, "ID" },
671 static const value_string ndps_card_name_or_oid_enum[] = {
672 { 0x00000000, "Number" },
673 { 0x00000001, "ID" },
677 static const value_string ndps_integer_or_oid_enum[] = {
678 { 0x00000000, "ID" },
679 { 0x00000001, "Number" },
683 static const value_string ndps_persistence_enum[] = {
684 { 0x00000000, "Permanent" },
685 { 0x00000001, "Volatile" },
689 static const value_string ndps_address_type_enum[] = {
690 { 0x00000000, "User" },
691 { 0x00000001, "Server" },
692 { 0x00000002, "Volume" },
693 { 0x00000003, "Organization Unit" },
694 { 0x00000004, "Organization" },
695 { 0x00000005, "Group" },
696 { 0x00000006, "Distinguished Name" },
697 { 0x00000007, "User or Container" },
698 { 0x00000008, "Case Exact String" },
699 { 0x00000009, "Case Ignore String" },
700 { 0x0000000a, "Numeric String" },
701 { 0x0000000b, "DOS File Name" },
702 { 0x0000000c, "Phone Number" },
703 { 0x0000000d, "Boolean" },
704 { 0x0000000e, "Integer" },
705 { 0x0000000f, "Network Address" },
706 { 0x00000010, "Choice" },
707 { 0x00000011, "GroupWise User" },
711 static const value_string ndps_address_enum[] = {
712 { 0x00000000, "IPX" },
713 { 0x00000001, "IP" },
714 { 0x00000002, "SDLC" },
715 { 0x00000003, "Token Ring to Ethernet" },
716 { 0x00000004, "OSI" },
717 { 0x00000005, "AppleTalk" },
718 { 0x00000006, "Count" },
723 static const value_string ndps_server_type_enum[] = {
724 { 0x00000000, "All" },
725 { 0x00000001, "Public Access Printer Agent" },
726 { 0x00000002, "Notification Server" },
727 { 0x00000003, "Resource Manager" },
728 { 0x00000004, "Network Port Handler" },
732 static const value_string ndps_event_object_enum[] = {
733 { 0x00000000, "Object" },
734 { 0x00000001, "Filter" },
735 { 0x00000002, "Detail" },
739 static const value_string ndps_service_type_enum[] = {
740 { 0x00000000, "SRS" },
741 { 0x00000001, "ENS" },
742 { 0x00000002, "RMS" },
746 static const value_string ndps_delivery_add_enum[] = {
747 { 0x00000000, "MHS Address" },
748 { 0x00000001, "Distinguished Name" },
749 { 0x00000002, "Text" },
750 { 0x00000003, "Octet String" },
751 { 0x00000004, "Distinguished Name String" },
752 { 0x00000005, "RPC Address" },
753 { 0x00000006, "Qualified Name" },
757 static const value_string ndps_resource_enum[] = {
758 { 0x00000000, "Name or ID" },
759 { 0x00000001, "Text" },
764 static const value_string ndps_identifier_enum[] = {
765 { 0x00000000, "ID Nominal Number" },
766 { 0x00000001, "ID Alpha-numeric" },
767 { 0x00000002, "ID Tag" },
771 static const value_string ndps_media_enum[] = {
772 { 0x00000000, "Select All Pages" },
773 { 0x00000001, "Selected Pages" },
777 static const value_string ndps_page_size_enum[] = {
778 { 0x00000000, "ID" },
779 { 0x00000001, "Dimensions" },
783 static const value_string ndps_pres_direction_enum[] = {
784 { 0x00000000, "Right to Bottom" },
785 { 0x00000001, "Left to Bottom" },
786 { 0x00000002, "Bidirectional to Bottom" },
787 { 0x00000003, "Right to Top" },
788 { 0x00000004, "Left to Top" },
789 { 0x00000005, "Bidirectional to Top" },
790 { 0x00000006, "Bottom to Right" },
791 { 0x00000007, "Bottom to Left" },
792 { 0x00000008, "Top to Left" },
793 { 0x00000009, "Top to Right" },
797 static const value_string ndps_page_order_enum[] = {
798 { 0x00000000, "Unknown" },
799 { 0x00000001, "First to Last" },
800 { 0x00000002, "Last to First" },
804 static const value_string ndps_medium_size_enum[] = {
805 { 0x00000000, "Discrete" },
806 { 0x00000001, "Continuous" },
810 static const value_string ndps_page_orientation_enum[] = {
811 { 0x00000000, "Unknown" },
812 { 0x00000001, "Face Up" },
813 { 0x00000002, "Face Down" },
817 static const value_string ndps_print_security[] = {
818 { 0x00000001, "Low" },
819 { 0x00000002, "Medium" },
820 { 0x00000003, "High" },
824 static const value_string ndps_numbers_up_enum[] = {
825 { 0x00000000, "Cardinal" },
826 { 0x00000001, "Name or Object ID" },
827 { 0x00000002, "Cardinal Range" },
832 static const value_string ndps_state_severity_enum[] = {
833 { 0x00000001, "Other" },
834 { 0x00000002, "Warning" },
835 { 0x00000003, "Critical" },
840 static const value_string ndps_training_enum[] = {
841 { 0x00000001, "Other" },
842 { 0x00000002, "Unknown" },
843 { 0x00000003, "Untrained" },
844 { 0x00000004, "Trained" },
845 { 0x00000005, "Field Service" },
846 { 0x00000006, "Management" },
850 static const value_string ndps_colorant_set_enum[] = {
851 { 0x00000000, "Name" },
852 { 0x00000001, "Description" },
856 static const value_string ndps_card_enum_time_enum[] = {
857 { 0x00000000, "Cardinal" },
858 { 0x00000001, "Enumeration" },
859 { 0x00000002, "Time" },
863 static const value_string ndps_attrs_arg_enum[] = {
864 { 0x00000000, "Continuation" },
865 { 0x00000001, "Specification" },
870 static const value_string ndps_filter_enum[] = {
871 { 0x00000000, "Item" },
872 { 0x00000001, "And" },
873 { 0x00000002, "Or" },
874 { 0x00000003, "Not" },
879 static const value_string ndps_filter_item_enum[] = {
880 { 0x00000000, "Equality" },
881 { 0x00000001, "Substrings" },
882 { 0x00000002, "Greater then or Equal to" },
883 { 0x00000003, "Less then or Equal to" },
884 { 0x00000004, "Present" },
885 { 0x00000005, "Subset of" },
886 { 0x00000006, "Superset of" },
887 { 0x00000007, "Non NULL Set Intersect" },
891 static const value_string ndps_match_criteria_enum[] = {
892 { 0x00000000, "Exact" },
893 { 0x00000001, "Case Insensitive" },
894 { 0x00000002, "Same Letter" },
895 { 0x00000003, "Approximate" },
899 static const value_string ndps_operator_enum[] = {
900 { 0x00000000, "Attributes" },
901 { 0x00000002, "Ordered Jobs" },
905 static const value_string ndps_resource_type_enum[] = {
906 { 0x00000000, "Printer Drivers" },
907 { 0x00000001, "Printer Definitions" },
908 { 0x00000002, "Printer Definitions Short" },
909 { 0x00000003, "Banner Page Files" },
910 { 0x00000004, "Font Types" },
911 { 0x00000005, "Printer Driver Files" },
912 { 0x00000006, "Printer Definition File" },
913 { 0x00000007, "Font Files" },
914 { 0x00000008, "Generic Type" },
915 { 0x00000009, "Generic Files" },
916 { 0x0000000a, "Printer Definition File 2" },
917 { 0x0000000b, "Printer Driver Types 2" },
918 { 0x0000000c, "Printer Driver Files 2" },
919 { 0x0000000d, "Printer Driver Types Archive" },
920 { 0x0000000e, "Languages Available" },
924 static const value_string ndps_os_type_enum[] = {
925 { 0x00000000, "DOS" },
926 { 0x00000001, "Windows 3.1" },
927 { 0x00000002, "Windows 95" },
928 { 0x00000003, "Windows NT" },
929 { 0x00000004, "OS2" },
930 { 0x00000005, "MAC" },
931 { 0x00000006, "UNIX" },
932 { 0x00000007, "Windows NT 4.0" },
933 { 0x00000008, "Windows 2000/XP" },
934 { 0x00000009, "Windows 98" },
935 { 0xffffffff, "None" },
939 static const value_string ndps_banner_type_enum[] = {
940 { 0x00000000, "All" },
941 { 0x00000001, "PCL" },
942 { 0x00000002, "PostScript" },
943 { 0x00000003, "ASCII Text" },
947 static const value_string ndps_font_type_enum[] = {
948 { 0x00000000, "TrueType" },
949 { 0x00000001, "PostScript" },
950 { 0x00000002, "System" },
951 { 0x00000003, "SPD" },
952 { 0x00000004, "True Doc" },
956 static const value_string ndps_archive_enum[] = {
957 { 0x00000000, "ZIP" },
958 { 0x00000001, "JAR" },
963 static const value_string ndps_res_type_enum[] = {
964 { 0x00000000, "Printer Driver" },
965 { 0x00000001, "Printer Definition" },
966 { 0x00000002, "Banner Page" },
967 { 0x00000003, "Font" },
968 { 0x00000004, "Generic Resource" },
969 { 0x00000005, "Print Driver Archive" },
973 static const value_string ndps_print_arg_enum[] = {
974 { 0x00000000, "Create Job" },
975 { 0x00000001, "Add Document" },
976 { 0x00000002, "Close Job" },
980 static const value_string ndps_doc_content_enum[] = {
981 { 0x00000000, "Content Included" },
982 { 0x00000001, "Content Referenced" },
986 static const value_string ndps_interrupt_job_enum[] = {
987 { 0x00000000, "Job ID" },
988 { 0x00000001, "Name" },
992 static const value_string ndps_pause_job_enum[] = {
993 { 0x00000000, "Job ID" },
994 { 0x00000001, "Name" },
998 static const value_string ndps_resubmit_op_enum[] = {
999 { 0x00000000, "Copy" },
1000 { 0x00000001, "Move" },
1004 static const value_string ndps_shutdown_enum[] = {
1005 { 0x00000000, "Do Current Jobs" },
1006 { 0x00000001, "Immediate" },
1007 { 0x00000002, "Do Pending Jobs" },
1011 static const value_string ndps_list_profiles_choice_enum[] = {
1012 { 0x00000000, "ID" },
1013 { 0x00000001, "Filter" },
1017 static const value_string ndps_list_profiles_result_enum[] = {
1018 { 0x00000000, "Complete" },
1019 { 0x00000001, "No Event Objects" },
1020 { 0x00000002, "Profile ID's" },
1024 static const value_string ndps_ds_info_enum[] = {
1025 { 0x00000000, "Add" },
1026 { 0x00000001, "Remove" },
1027 { 0x00000002, "Update" },
1031 static const value_string ndps_list_services_enum[] = {
1032 { 0x00000000, "Supported" },
1033 { 0x00000001, "Enabled" },
1037 static const value_string ndps_data_item_enum[] = {
1038 { 0x00000000, "Int8" },
1039 { 0x00000001, "Int16" },
1040 { 0x00000002, "Int32" },
1041 { 0x00000003, "Boolean" },
1042 { 0x00000004, "Character String" },
1043 { 0x00000005, "Byte String" },
1047 static const value_string ndps_list_local_servers_enum[] = {
1048 { 0x00000000, "Specification" },
1049 { 0x00000001, "Continuation" },
1053 static const value_string ndps_delivery_method_enum[] = {
1054 { 0x00000000, "Specification" },
1055 { 0x00000001, "Continuation" },
1059 static const value_string ndps_attribute_enum[] = {
1060 { 0x00000000, "Null" },
1061 { 0x00000001, "Text" },
1062 { 0x00000002, "Descriptive Name" },
1063 { 0x00000003, "Descriptor" },
1064 { 0x00000004, "Message" },
1065 { 0x00000005, "Error Message" },
1066 { 0x00000006, "Simple Name" },
1067 { 0x00000007, "Distinguished Name String" },
1068 { 0x00000008, "Distinguished Name Seq" },
1069 { 0x00000009, "Delta Time" },
1070 { 0x0000000a, "Time" },
1071 { 0x0000000b, "Integer" },
1072 { 0x0000000c, "Integer Seq" },
1073 { 0x0000000d, "Cardinal" },
1074 { 0x0000000e, "Cardinal Seq" },
1075 { 0x0000000f, "Positive Integer" },
1076 { 0x00000010, "Integer Range" },
1077 { 0x00000011, "Cardinal Range" },
1078 { 0x00000012, "Maximum Integer" },
1079 { 0x00000013, "Minimum Integer" },
1080 { 0x00000014, "Integer 64" },
1081 { 0x00000015, "Integer 64 Seq" },
1082 { 0x00000016, "Cardinal 64" },
1083 { 0x00000017, "Cardinal 64 Seq" },
1084 { 0x00000018, "Positive Integer 64" },
1085 { 0x00000019, "Integer 64 Range" },
1086 { 0x0000001a, "Cardinal 64 Range" },
1087 { 0x0000001b, "Maximum Integer 64" },
1088 { 0x0000001c, "Minimum Integer 64" },
1089 { 0x0000001d, "Real" },
1090 { 0x0000001e, "Real Seq" },
1091 { 0x0000001f, "Non-Negative Real" },
1092 { 0x00000020, "Real Range" },
1093 { 0x00000021, "Non-Negative Real Range" },
1094 { 0x00000022, "Boolean" },
1095 { 0x00000023, "Percent" },
1096 { 0x00000024, "Object Identifier" },
1097 { 0x00000025, "Object Identifier Seq" },
1098 { 0x00000026, "Name or OID" },
1099 { 0x00000027, "Name or OID Seq" },
1100 { 0x00000028, "Distinguished Name" },
1101 { 0x00000029, "Relative Distinguished Name Seq" },
1102 { 0x0000002a, "Realization" },
1103 { 0x0000002b, "Medium Dimensions" },
1104 { 0x0000002c, "Dimension" },
1105 { 0x0000002d, "XY Dimensions" },
1106 { 0x0000002e, "Locations" },
1107 { 0x0000002f, "Area" },
1108 { 0x00000030, "Area Seq" },
1109 { 0x00000031, "Edge" },
1110 { 0x00000032, "Font Reference" },
1111 { 0x00000033, "Cardinal or OID" },
1112 { 0x00000034, "OID Cardinal Map" },
1113 { 0x00000035, "Cardinal or Name or OID" },
1114 { 0x00000036, "Positive Integer or OID" },
1115 { 0x00000037, "Event Handling Profile" },
1116 { 0x00000038, "Octet String" },
1117 { 0x00000039, "Priority" },
1118 { 0x0000003a, "Locale" },
1119 { 0x0000003b, "Method Delivery Address" },
1120 { 0x0000003c, "Object Identification" },
1121 { 0x0000003d, "Results Profile" },
1122 { 0x0000003e, "Criteria" },
1123 { 0x0000003f, "Job Password" },
1124 { 0x00000040, "Job Level" },
1125 { 0x00000041, "Job Categories" },
1126 { 0x00000042, "Print Checkpoint" },
1127 { 0x00000043, "Ignored Attribute" },
1128 { 0x00000044, "Resource" },
1129 { 0x00000045, "Medium Substitution" },
1130 { 0x00000046, "Font Substitution" },
1131 { 0x00000047, "Resource Context Seq" },
1132 { 0x00000048, "Sides" },
1133 { 0x00000049, "Page Select Seq" },
1134 { 0x0000004a, "Page Media Select" },
1135 { 0x0000004b, "Document Content" },
1136 { 0x0000004c, "Page Size" },
1137 { 0x0000004d, "Presentation Direction" },
1138 { 0x0000004e, "Page Order" },
1139 { 0x0000004f, "File Reference" },
1140 { 0x00000050, "Medium Source Size" },
1141 { 0x00000051, "Input Tray Medium" },
1142 { 0x00000052, "Output Bins Chars" },
1143 { 0x00000053, "Page ID Type" },
1144 { 0x00000054, "Level Range" },
1145 { 0x00000055, "Category Set" },
1146 { 0x00000056, "Numbers Up Supported" },
1147 { 0x00000057, "Finishing" },
1148 { 0x00000058, "Print Contained Object ID" },
1149 { 0x00000059, "Print Config Object ID" },
1150 { 0x0000005a, "Typed Name" },
1151 { 0x0000005b, "Network Address" },
1152 { 0x0000005c, "XY Dimensions Value" },
1153 { 0x0000005d, "Name or OID Dimensions Map" },
1154 { 0x0000005e, "Printer State Reason" },
1155 { 0x0000005f, "Enumeration" },
1156 { 0x00000060, "Qualified Name" },
1157 { 0x00000061, "Qualified Name Set" },
1158 { 0x00000062, "Colorant Set" },
1159 { 0x00000063, "Resource Printer ID" },
1160 { 0x00000064, "Event Object ID" },
1161 { 0x00000065, "Qualified Name Map" },
1162 { 0x00000066, "File Path" },
1163 { 0x00000067, "Uniform Resource Identifier" },
1164 { 0x00000068, "Cardinal or Enum or Time" },
1165 { 0x00000069, "Print Contained Object ID Set" },
1166 { 0x0000006a, "Octet String Pair" },
1167 { 0x0000006b, "Octet String Integer Pair" },
1168 { 0x0000006c, "Extended Resource Identifier" },
1169 { 0x0000006d, "Event Handling Profile 2" },
1173 static const value_string ndps_error_types[] = {
1174 { 0x00000000, "Ok" },
1175 { 0x00000001, "Error" },
1176 { 0xFFFFFC18, "Broker Out of Memory" }, /* Broker Errors */
1177 { 0xFFFFFC17, "Broker Bad NetWare Version" },
1178 { 0xFFFFFC16, "Broker Wrong Command Line Arguments" },
1179 { 0xFFFFFC15, "Broker Name Not Given" },
1180 { 0xFFFFFC14, "Not Broker Class" },
1181 { 0xFFFFFC13, "Invalid Broker Password" },
1182 { 0xFFFFFC12, "Invalid Broker Name" },
1183 { 0xFFFFFC11, "Broker Failed to Create Thread" },
1184 { 0xFFFFFC10, "Broker Failed to Initialize NUT" },
1185 { 0xFFFFFC0F, "Broker Failed to Get Messages" },
1186 { 0xFFFFFC0E, "Broker Failed to Allocate Resources" },
1187 { 0xFFFFFC0D, "Broker Service Name Must be Fully Distinguished" },
1188 { 0xFFFFFC0C, "Broker Uninitialized Module" },
1189 { 0xFFFFFC0B, "Broker DS Value Size Too Large" },
1190 { 0xFFFFFC0A, "Broker No Attribute Values" },
1191 { 0xFFFFFC09, "Broker Unknown Session" },
1192 { 0xFFFFFC08, "Broker Service Disabled" },
1193 { 0xFFFFFC07, "Broker Unknown Modify Operation" },
1194 { 0xFFFFFC06, "Broker Invalid Arguments" },
1195 { 0xFFFFFC05, "Broker Duplicate Session ID" },
1196 { 0xFFFFFC04, "Broker Unknown Service" },
1197 { 0xFFFFFC03, "Broker Service Already Enabled" },
1198 { 0xFFFFFC02, "Broker Service Already Disabled" },
1199 { 0xFFFFFC01, "Broker Invalid Credential" },
1200 { 0xFFFFFC00, "Broker Unknown Designator" },
1201 { 0xFFFFFBFF, "Broker Failed to Make Change Permanent" },
1202 { 0xFFFFFBFE, "Broker Not Admin Type Session" },
1203 { 0xFFFFFBFD, "Broker Option Not Supported" },
1204 { 0xFFFFFBFC, "Broker No Effective Rights" },
1205 { 0xFFFFFBFB, "Broker Could Not Find File" },
1206 { 0xFFFFFBFA, "Broker Error Reading File" },
1207 { 0xFFFFFBF9, "Broker Not NLM File Format" },
1208 { 0xFFFFFBF8, "Broker Wrong NLM File Version" },
1209 { 0xFFFFFBF7, "Broker Reentrant Initialization Failure" },
1210 { 0xFFFFFBF6, "Broker Already in Progress" },
1211 { 0xFFFFFBF5, "Broker Initialize Failure" },
1212 { 0xFFFFFBF4, "Broker Inconsistent File Format" },
1213 { 0xFFFFFBF3, "Broker Can't Load at Startup" },
1214 { 0xFFFFFBF2, "Broker Autoload Modules Not Loaded" },
1215 { 0xFFFFFBF1, "Broker Unresolved External" },
1216 { 0xFFFFFBF0, "Broker Public Already Defined" },
1217 { 0xFFFFFBEF, "Broker Other Broker Using Object" },
1218 { 0xFFFFFBEE, "Broker Service Failed to Initialize" },
1219 { 0xFFFFFBB4, "Registry Out of Memory" }, /* SRS Errors */
1220 { 0xFFFFFBB3, "Registry Bad NetWare Version" },
1221 { 0xFFFFFBB2, "Registry Failed to Create Context" },
1222 { 0xFFFFFBB1, "Registry Failed Login" },
1223 { 0xFFFFFBB0, "Registry Failed to Create Thread" },
1224 { 0xFFFFFBAF, "Registry Failed to Get Messages" },
1225 { 0xFFFFFBAE, "Registry Service Name Must Be Fully Distinguished" },
1226 { 0xFFFFFBAD, "Registry DS Value Size Too Large" },
1227 { 0xFFFFFBAC, "Registry No Attribute Values" },
1228 { 0xFFFFFBAB, "Registry Unknown Session" },
1229 { 0xFFFFFBAA, "Registry Service Disabled" },
1230 { 0xFFFFFBA9, "Registry Unknown Modify Operation" },
1231 { 0xFFFFFBA8, "Registry Can't Start Advertise" },
1232 { 0xFFFFFBA7, "Registry Duplicate Server Entry" },
1233 { 0xFFFFFBA6, "Registry Can't Bind to Registry" },
1234 { 0xFFFFFBA5, "Registry Can't Create Client" },
1235 { 0xFFFFFBA4, "Registry Invalid Arguments" },
1236 { 0xFFFFFBA3, "Registry Duplicate Session ID" },
1237 { 0xFFFFFBA2, "Registry Unknown Server Entry" },
1238 { 0xFFFFFBA1, "Registry Invalid Credential" },
1239 { 0xFFFFFBA0, "Registry Type Session" },
1240 { 0xFFFFFB9F, "Registry Server Type Session" },
1241 { 0xFFFFFB9E, "Registry Not Server Type Session" },
1242 { 0xFFFFFB9D, "Not Registry Type Session" },
1243 { 0xFFFFFB9C, "Registry Unknown Designator" },
1244 { 0xFFFFFB9B, "Registry Option Not Supported" },
1245 { 0xFFFFFB9A, "Registry Not in List Iteration" },
1246 { 0xFFFFFB99, "Registry Invalid Continuation Handle" },
1247 { 0xFFFFFB50, "Notify Out of Memory" }, /* Notification Service Errors */
1248 { 0xFFFFFB4F, "Notify Bad NetWare Version" },
1249 { 0xFFFFFB4E, "Notify Failed to Create Thread" },
1250 { 0xFFFFFB4D, "Notify Failed to Get Messages" },
1251 { 0xFFFFFB4C, "Notify Failed to Create Context" },
1252 { 0xFFFFFB4B, "Notify Failed Login" },
1253 { 0xFFFFFB4A, "Notify Service Name Must be Fully Distiguished" },
1254 { 0xFFFFFB49, "Notify DS Value Size Too Large" },
1255 { 0xFFFFFB48, "Notify No Attribute Values" },
1256 { 0xFFFFFB47, "Notify Unknown Session" },
1257 { 0xFFFFFB46, "Notify Unknown Notify Profile" },
1258 { 0xFFFFFB45, "Notify Error Reading File" },
1259 { 0xFFFFFB44, "Notify Error Writing File" },
1260 { 0xFFFFFB43, "Wrong Notify Database Version" },
1261 { 0xFFFFFB42, "Corrupted Notify Database" },
1262 { 0xFFFFFB41, "Notify Unknown Event Object ID" },
1263 { 0xFFFFFB40, "Notify Method Already Installed" },
1264 { 0xFFFFFB3F, "Notify Unknown Method" },
1265 { 0xFFFFFB3E, "Notify Service Disabled" },
1266 { 0xFFFFFB3D, "Notify Unknown Modify Operation" },
1267 { 0xFFFFFB3C, "Out of Notify Entries" },
1268 { 0xFFFFFB3B, "Notify Unknown Language ID" },
1269 { 0xFFFFFB3A, "Notify Queue Empty" },
1270 { 0xFFFFFB39, "Notify Can't Load Delivery Method" },
1271 { 0xFFFFFB38, "Notify Invalid Arguments" },
1272 { 0xFFFFFB37, "Notify Duplicate Session ID" },
1273 { 0xFFFFFB36, "Notify Invalid Credentials" },
1274 { 0xFFFFFB35, "Notify Unknown Choice" },
1275 { 0xFFFFFB34, "Notify Unknown Attribute Value" },
1276 { 0xFFFFFB33, "Notify Error Writing Database" },
1277 { 0xFFFFFB32, "Notify Unknown Object ID" },
1278 { 0xFFFFFB31, "Notify Unknown Designator" },
1279 { 0xFFFFFB30, "Notify Failed to Make Change Permanent" },
1280 { 0xFFFFFB2F, "Notify User Interface Not Supported" },
1281 { 0xFFFFFB2E, "Notify Not Supplied Type of Session" },
1282 { 0xFFFFFB2D, "Notify Not Admin Type Session" },
1283 { 0xFFFFFB2C, "Notify No Service Registry Available" },
1284 { 0xFFFFFB2B, "Notify Failed to Register With Any Server" },
1285 { 0xFFFFFB2A, "Notify Empty Event Object Set" },
1286 { 0xFFFFFB29, "Notify Unknown Notify Handle" },
1287 { 0xFFFFFB28, "Notify Option Not Supported" },
1288 { 0xFFFFFB27, "Notify Unknown RPC Session" },
1289 { 0xFFFFFB26, "Notify Initialization Error" },
1290 { 0xFFFFFB25, "Notify No Effective Rights" },
1291 { 0xFFFFFB24, "Notify No Persistent Storage" },
1292 { 0xFFFFFB23, "Notify Bad Method Filename" },
1293 { 0xFFFFFB22, "Notify Unknown Continuation Handle" },
1294 { 0xFFFFFB21, "Notify Invalid Continuation Handle" },
1295 { 0xFFFFFB20, "Notify Could Not Find File" },
1296 { 0xFFFFFB1F, "Notify Error Reading File" },
1297 { 0xFFFFFB1E, "Notify Not NLM File Format" },
1298 { 0xFFFFFB1D, "Notify Wrong NLM File Version" },
1299 { 0xFFFFFB1C, "Notify Reentrant Initialization Failure" },
1300 { 0xFFFFFB1B, "Notify Already in Progress" },
1301 { 0xFFFFFB1A, "Notify Initialization Failure" },
1302 { 0xFFFFFB19, "Notify Inconsistent File Format" },
1303 { 0xFFFFFB18, "Notify Can't Load at Startup" },
1304 { 0xFFFFFB17, "Notify Autoload Modules Not Loaded" },
1305 { 0xFFFFFB16, "Notify Unresolved External" },
1306 { 0xFFFFFB15, "Notify Public Already Defined" },
1307 { 0xFFFFFB14, "Notify Using Unknown Methods" },
1308 { 0xFFFFFB13, "Notify Service Not Fully Enabled" },
1309 { 0xFFFFFB12, "Notify Foreign NDS Tree Name" },
1310 { 0xFFFFFB11, "Notify Delivery Method Rejected Address" },
1311 { 0xFFFFFB10, "Notify Unsupported Delivery Address Type" },
1312 { 0xFFFFFB0F, "Notify User Object No Default Server" },
1313 { 0xFFFFFB0E, "Notify Failed to Send Notification" },
1314 { 0xFFFFFB0D, "Notify Bad Volume in Address" },
1315 { 0xFFFFFB0C, "Notify Broker Has No File Rights" },
1316 { 0xFFFFFB0B, "Notify Maximum Methods Supported" },
1317 { 0xFFFFFB0A, "Notify No Filter Provided" },
1318 { 0xFFFFFB09, "Notify IPX Not Supported By Method" },
1319 { 0xFFFFFB08, "Notify IP Not Supported By Method" },
1320 { 0xFFFFFB07, "Notify Failed to Startup Winsock" },
1321 { 0xFFFFFB06, "Notify No Protocols Available" },
1322 { 0xFFFFFB05, "Notify Failed to Launch RPC Server" },
1323 { 0xFFFFFB04, "Notify Invalid SLP Attribute Format" },
1324 { 0xFFFFFB03, "Notify Invalid SLP URL Format" },
1325 { 0xFFFFFB02, "Notify Unknown Attribute Object ID" },
1326 { 0xFFFFFB01, "Notify Duplicate Session ID" },
1327 { 0xFFFFFB00, "Notify Failed to Authenticate" },
1328 { 0xFFFFFAFF, "Notify Failed to Authenticate Protocol Mismatch" },
1329 { 0xFFFFFAFE, "Notify Failed to Authenticate Internal Error" },
1330 { 0xFFFFFAFD, "Notify Failed to Authenticate Connection Error" },
1331 { 0xFFFFFC7C, "Resource Manager Out of Memory" }, /* ResMan Errors */
1332 { 0xFFFFFC7B, "Resource Manager Bad NetWare Version" },
1333 { 0xFFFFFC7A, "Resource Manager Wrong Command Line Arguments" },
1334 { 0xFFFFFC79, "Resource Manager Broker Name Not Given" },
1335 { 0xFFFFFC78, "Resource Manager Invalid Broker Password" },
1336 { 0xFFFFFC77, "Resource Manager Invalid Broker Name" },
1337 { 0xFFFFFC76, "Resource Manager Failed to Create Thread" },
1338 { 0xFFFFFC75, "Resource Manager Service Name Must be Fully Distinguished" },
1339 { 0xFFFFFC74, "Resource Manager DS Value Size Too Large" },
1340 { 0xFFFFFC73, "Resource Manager No Attribute Values" },
1341 { 0xFFFFFC72, "Resource Manager Unknown Session" },
1342 { 0xFFFFFC71, "Resource Manager Error Reading File" },
1343 { 0xFFFFFC70, "Resource Manager Error Writing File" },
1344 { 0xFFFFFC6F, "Resource Manager Service Disabled" },
1345 { 0xFFFFFC6E, "Resource Manager Unknown Modify Operation" },
1346 { 0xFFFFFC6D, "Resource Manager Duplicate Session ID" },
1347 { 0xFFFFFC6C, "Resource Manager Invalid Credentials" },
1348 { 0xFFFFFC6B, "Resource Manager No Service Registry Available" },
1349 { 0xFFFFFC6A, "Resource Manager Failed to Register With any Server" },
1350 { 0xFFFFFC69, "Resource Manager Failed to Get Messages" },
1351 { 0xFFFFFC68, "Resource Manager Failed to Create Context" },
1352 { 0xFFFFFC67, "Resource Manager Failed to Login" },
1353 { 0xFFFFFC66, "Resource Manager NPD Files Generation Error" },
1354 { 0xFFFFFC65, "Resource Manager INF File Format Error" },
1355 { 0xFFFFFC64, "Resource Manager No Printer Type in INF File" },
1356 { 0xFFFFFC63, "Resource Manager No INF Files Present" },
1357 { 0xFFFFFC62, "Resource Manager File Open Error" },
1358 { 0xFFFFFC61, "Resource Manager Read File Error" },
1359 { 0xFFFFFC60, "Resource Manager Write File Error" },
1360 { 0xFFFFFC5F, "Resource Manager Resource Type Invalid" },
1361 { 0xFFFFFC5E, "Resource Manager No Such Filename" },
1362 { 0xFFFFFC5D, "Resource Manager Banner Type Invalid" },
1363 { 0xFFFFFC5C, "Resource Manager List Type Unknown" },
1364 { 0xFFFFFC5B, "Resource Manager OS Not Supported" },
1365 { 0xFFFFFC5A, "Resource Manager No Banner Files Present" },
1366 { 0xFFFFFC59, "Resource Manager Printer Definition Type Unknown" },
1367 { 0xFFFFFC58, "Resource Manager No Printer Types in List" },
1368 { 0xFFFFFC57, "Resource Manager Option Not Supported" },
1369 { 0xFFFFFC56, "Resource Manager Unicode Convention Error" },
1370 { 0xFFFFFC55, "Resource Manager Invalid Arguments" },
1371 { 0xFFFFFC54, "Resource Manager Initialization Error" },
1372 { 0xFFFFFC53, "Resource Manager No Service Registry Available" },
1373 { 0xFFFFFC52, "Resource Manager Failed to Register to Any Server" },
1374 { 0xFFFFFC51, "Resource Manager Unknown Designator" },
1375 { 0xFFFFFC50, "Resource Manager Not Admin Session" },
1376 { 0xFFFFFC4F, "Resource Manager No Effective Rights" },
1377 { 0xFFFFFC4E, "Resource Manager Bad File Attribute" },
1378 { 0xFFFFFC4D, "Resource Manager Document ID Format Error" },
1379 { 0xFFFFFC4C, "Resource Manager Unknown RPC Session" },
1380 { 0xFFFFFC4B, "Resource Manager Session Being Removed" },
1381 { 0xFFFFFC49, "Resource Manager Font Manager IO Error" },
1382 { 0xFFFFFC48, "Resource Manager Font Manager Reentrancy" },
1383 { 0xFFFFFC47, "Resource Manager Font Manager Sequence Error" },
1384 { 0xFFFFFC46, "Resource Manager Font Manager Corrupt Index File" },
1385 { 0xFFFFFC45, "Resource Manager Font Manager No Such Font" },
1386 { 0xFFFFFC44, "Resource Manager Font Manager Not Initialized" },
1387 { 0xFFFFFC43, "Resource Manager Font Manager System Error" },
1388 { 0xFFFFFC42, "Resource Manager Font Manager Bad Parameter" },
1389 { 0xFFFFFC41, "Resource Manager Font Manager Path Too Long" },
1390 { 0xFFFFFC40, "Resource Manager Font Manager Failure" },
1391 { 0xFFFFFC3F, "Resource Manager Duplicate TIRPC Session" },
1392 { 0xFFFFFC3E, "Resource Manager Connection Lost RMS Data" },
1393 { 0xFFFFFC3D, "Resource Manager Failed to Start Winsock" },
1394 { 0xFFFFFC3C, "Resource Manager No Protocols Available" },
1395 { 0xFFFFFC3B, "Resource Manager Failed to Launch RPC Server" },
1396 { 0xFFFFFC3A, "Resource Manager Invalid SLP Attribute Format" },
1397 { 0xFFFFFC39, "Resource Manager Invalid SLP URL Format" },
1398 { 0xFFFFFC38, "Resource Manager Unresolved External" },
1399 { 0xFFFFFC37, "Resource Manager Failed to Authenticate" },
1400 { 0xFFFFFC36, "Resource Manager Failed to Authenticate Protocol Mismatch" },
1401 { 0xFFFFFC35, "Resource Manager Failed to Authenticate Internal Error" },
1402 { 0xFFFFFC34, "Resource Manager Failed to Authenticate Connection Error" },
1403 { 0xFFFFFC33, "Resource Manager No Rights to Remote Resdir" },
1404 { 0xFFFFFC32, "Resource Manager Can't Initialize NDPS Library" },
1405 { 0xFFFFFC31, "Resource Manager Can't Create Resource Reference" },
1406 { 0xFFFFFC30, "Resource Manager File is Zero Length" },
1407 { 0xFFFFFC2F, "Resource Manager Failed to Write INF in Address" },
1408 { 0xFFFFFCDF, "NDPSM No Memory" }, /* NDPSM Errors */
1409 { 0xFFFFFCDE, "NDPSM Memory Not Found" },
1410 { 0xFFFFFCDD, "NDPSM Job Storage Limit" },
1411 { 0xFFFFFCDC, "NDPSM Job Retention Limit" },
1412 { 0xFFFFFCDB, "NDPSM Unsupported Type" },
1413 { 0xFFFFFCDA, "NDPSM Undefined Type" },
1414 { 0xFFFFFCD9, "NDPSM Unsupported Operation" },
1415 { 0xFFFFFCD8, "NDPSM Error Accessing Database" },
1416 { 0xFFFFFCD7, "NDPSM No PDS" },
1417 { 0xFFFFFCD6, "NDPSM Invalid Class" },
1418 { 0xFFFFFCD5, "NDPSM Bad Parameter" },
1419 { 0xFFFFFCD4, "NDPSM Object Not Found" },
1420 { 0xFFFFFCD3, "NDPSM Attribute Not Found" },
1421 { 0xFFFFFCD2, "NDPSM Value Not Found" },
1422 { 0xFFFFFCD1, "NDPSM Values Not Comparable" },
1423 { 0xFFFFFCD0, "NDPSM Invalid Value Syntax" },
1424 { 0xFFFFFCCF, "NDPSM Job Not Found" },
1425 { 0xFFFFFCCE, "NDPSM Communications Error" },
1426 { 0xFFFFFCCD, "NDPSM Printer Agent Initializing" },
1427 { 0xFFFFFCCC, "NDPSM Printer Agent Going Down" },
1428 { 0xFFFFFCCB, "NDPSM Printer Agent Disabled" },
1429 { 0xFFFFFCCA, "NDPSM Printer Agent Paused" },
1430 { 0xFFFFFCC9, "NDPSM Bad Printer Agent Handle" },
1431 { 0xFFFFFCC8, "NDPSM Object Not Locked" },
1432 { 0xFFFFFCC7, "NDPSM Version Incompatible" },
1433 { 0xFFFFFCC6, "NDPSM PSM Initializing" },
1434 { 0xFFFFFCC5, "NDPSM PSM Going Down" },
1435 { 0xFFFFFCC4, "NDPSM Notification Service Error" },
1436 { 0xFFFFFCC3, "NDPSM Medium Needs Mounted" },
1437 { 0xFFFFFCC2, "NDPSM PDS Not Responding" },
1438 { 0xFFFFFCC1, "NDPSM Session Not Found" },
1439 { 0xFFFFFCC0, "NDPSM RPC Failure" },
1440 { 0xFFFFFCBF, "NDPSM Duplicate Value" },
1441 { 0xFFFFFCBE, "NDPSM PDS Refuses Rename" },
1442 { 0xFFFFFCBD, "NDPSM No Mandatory Attribute" },
1443 { 0xFFFFFCBC, "NDPSM Already Attached" },
1444 { 0xFFFFFCBB, "NDPSM Can't Attach" },
1445 { 0xFFFFFCBA, "NDPSM Too Many NetWare Servers" },
1446 { 0xFFFFFCB9, "NDPSM Can't Create Document File" },
1447 { 0xFFFFFCB8, "NDPSM Can't Delete Document File" },
1448 { 0xFFFFFCB7, "NDPSM Can't Open Document File" },
1449 { 0xFFFFFCB6, "NDPSM Can't Write Document File" },
1450 { 0xFFFFFCB5, "NDPSM Job is Active" },
1451 { 0xFFFFFCB4, "NDPSM No Scheduler" },
1452 { 0xFFFFFCB3, "NDPSM Changing Connection" },
1453 { 0xFFFFFCB2, "NDPSM Could not Create Account Reference" },
1454 { 0xFFFFFCB1, "NDPSM Accounting Service Error" },
1455 { 0xFFFFFCB0, "NDPSM RMS Service Error" },
1456 { 0xFFFFFCAF, "NDPSM Failed Validation" },
1457 { 0xFFFFFCAE, "NDPSM Broker Server Connecting" },
1458 { 0xFFFFFCAD, "NDPSM SRS Service Error" },
1459 { 0xFFFFFD44, "JPM Execute Request Later" },
1460 { 0xFFFFFD43, "JPM Failed to Open Document" },
1461 { 0xFFFFFD42, "JPM Failed to Read Document File" },
1462 { 0xFFFFFD41, "JPM Bad Printer Agent Handle" },
1463 { 0xFFFFFD40, "JPM Bad Job Handle" },
1464 { 0xFFFFFD3F, "JPM Bad Document Handle" },
1465 { 0xFFFFFD3E, "JPM Unsupported Operation" },
1466 { 0xFFFFFD3D, "JPM Request Queue Full" },
1467 { 0xFFFFFD3C, "JPM Printer Agent Not Found" },
1468 { 0xFFFFFD3B, "JPM Invalid Request" },
1469 { 0xFFFFFD3A, "JPM Not Accepting Requests" },
1470 { 0xFFFFFD39, "JPM Printer Agent Already Serviced By PDS" },
1471 { 0xFFFFFD38, "JPM No Job" },
1472 { 0xFFFFFD37, "JPM Job Not Found" },
1473 { 0xFFFFFD36, "JPM Could not Access Database" },
1474 { 0xFFFFFD35, "JPM Bad Object Type" },
1475 { 0xFFFFFD34, "JPM Job Already Closed" },
1476 { 0xFFFFFD33, "JPM Document Already Closed" },
1477 { 0xFFFFFD32, "JPM Print Handler Not Registered" },
1478 { 0xFFFFFD31, "JPM Version Incompatible" },
1479 { 0xFFFFFD30, "JPM Printer Agent Paused" },
1480 { 0xFFFFFD2F, "JPM Printer Agent Shutdown" },
1481 { 0xFFFFFD2E, "JPM No CLIB Context" },
1482 { 0xFFFFFD2D, "JPM Accounting Already Serviced" },
1483 { 0xFFFFFC7B, "Database Can't Create File" },
1484 { 0xFFFFFC7A, "Database Can't Find Data File" },
1485 { 0xFFFFFC79, "Database Can't Open Data File" },
1486 { 0xFFFFFC78, "Database Can't Open Index File" },
1487 { 0xFFFFFC77, "Database Index File Not Open" },
1488 { 0xFFFFFC76, "Database Can't Rename File" },
1489 { 0xFFFFFC75, "Database Can't Read Data File" },
1490 { 0xFFFFFC74, "Database Can't Read Index File" },
1491 { 0xFFFFFC73, "Database Can't Write Data File" },
1492 { 0xFFFFFC72, "Database Can't Write Index File" },
1493 { 0xFFFFFC71, "Database Can't Delete Printer Agent Directory" },
1494 { 0xFFFFFC70, "Database Already Deleted" },
1495 { 0xFFFFFC6F, "Database Object Exists" },
1496 { 0xFFFFFC6E, "Database Descriptor In Use" },
1497 { 0xFFFFFC6D, "Database Descriptor Being Deleted" },
1501 static const value_string ndps_credential_enum[] = {
1510 static const value_string ndps_object_op_enum[] = {
1514 { 3, "Delete Object" },
1518 static const value_string ndps_client_server_enum[] = {
1521 { 2, "Client and Server" },
1525 static const value_string ndps_session_type_enum[] = {
1534 static const value_string ndps_get_session_type_enum[] = {
1542 static const value_string ndps_get_resman_session_type_enum[] = {
1550 align_4(tvbuff_t *tvb, int aoffset)
1552 if(tvb_length_remaining(tvb, aoffset) > 4 )
1560 ndps_string(tvbuff_t* tvb, int hfinfo, proto_tree *ndps_tree, int offset)
1562 int foffset = offset;
1567 guint32 length_remaining = 0;
1569 str_length = tvb_get_ntohl(tvb, foffset);
1571 length_remaining = tvb_length_remaining(tvb, foffset);
1572 if(str_length > (guint)length_remaining || str_length > 1024)
1574 proto_tree_add_string(ndps_tree, hfinfo, tvb, foffset,
1575 length_remaining + 4, "<String too long to process>");
1576 foffset += length_remaining;
1581 proto_tree_add_string(ndps_tree, hfinfo, tvb, offset,
1582 4, "<Not Specified>");
1585 for ( i = 0; i < str_length; i++ )
1587 c_char = tvb_get_guint8(tvb, foffset );
1588 if (c_char<0x20 || c_char>0x7e)
1593 buffer[i] = c_char & 0xff;
1603 buffer[i] = c_char & 0xff;
1608 if(length_remaining==1)
1616 str_length = tvb_get_ntohl(tvb, offset);
1617 proto_tree_add_string(ndps_tree, hfinfo, tvb, offset+4,
1618 str_length, buffer);
1619 foffset += align_4(tvb, foffset);
1624 objectidentifier(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
1628 guint32 label_value=0;
1631 gboolean found=TRUE;
1633 if (tvb_get_ntohl(tvb, foffset)==0)
1637 length = tvb_get_ntohl(tvb, foffset);
1642 label_value = tvb_get_ntohl(tvb, foffset+5);
1643 label = match_strval(label_value, object_ids_7);
1646 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, length, "Unknown ID");
1650 aitem = proto_tree_add_none_format(ndps_tree, hf_ndps_object_ids_7, tvb, foffset, length, label);
1653 label_value = tvb_get_ntohl(tvb, foffset+6);
1654 label = match_strval(label_value, object_ids_8);
1657 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, length, "Unknown ID");
1661 aitem = proto_tree_add_none_format(ndps_tree, hf_ndps_object_ids_8, tvb, foffset, length, label);
1664 label_value = tvb_get_ntohl(tvb, foffset+7);
1665 label = match_strval(label_value, object_ids_9);
1668 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, length, "Unknown ID");
1672 aitem = proto_tree_add_none_format(ndps_tree, hf_ndps_object_ids_9, tvb, foffset, length, label);
1675 label_value = tvb_get_ntohl(tvb, foffset+8);
1676 label = match_strval(label_value, object_ids_10);
1679 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, length, "Unknown ID");
1683 aitem = proto_tree_add_none_format(ndps_tree, hf_ndps_object_ids_10, tvb, foffset, length, label);
1686 label_value = tvb_get_ntohl(tvb, foffset+9);
1687 label = match_strval(label_value, object_ids_11);
1690 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, length, "Unknown ID");
1694 aitem = proto_tree_add_none_format(ndps_tree, hf_ndps_object_ids_11, tvb, foffset, length, label);
1697 label_value = tvb_get_ntohl(tvb, foffset+10);
1698 label = match_strval(label_value, object_ids_12);
1701 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, length, "Unknown ID");
1705 aitem = proto_tree_add_none_format(ndps_tree, hf_ndps_object_ids_12, tvb, foffset, length, label);
1708 label_value = tvb_get_ntohl(tvb, foffset+11);
1709 label = match_strval(label_value, object_ids_13);
1712 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, length, "Unknown ID");
1716 aitem = proto_tree_add_none_format(ndps_tree, hf_ndps_object_ids_13, tvb, foffset, length, label);
1719 label_value = tvb_get_ntohl(tvb, foffset+12);
1720 label = match_strval(label_value, object_ids_14);
1723 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, length, "Unknown ID");
1727 aitem = proto_tree_add_none_format(ndps_tree, hf_ndps_object_ids_14, tvb, foffset, length, label);
1730 label_value = tvb_get_ntohl(tvb, foffset+13);
1731 label = match_strval(label_value, object_ids_15);
1734 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, length, "Unknown ID");
1738 aitem = proto_tree_add_none_format(ndps_tree, hf_ndps_object_ids_15, tvb, foffset, length, label);
1741 label_value = tvb_get_ntohl(tvb, foffset+14);
1742 label = match_strval(label_value, object_ids_16);
1745 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, length, "Unknown ID");
1749 aitem = proto_tree_add_none_format(ndps_tree, hf_ndps_object_ids_16, tvb, foffset, length, label);
1752 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, length, "Unknown ID");
1759 label = match_strval(label_value, object_ids_7);
1763 atree = proto_item_add_subtree(aitem, ett_ndps);
1764 proto_tree_add_item(atree, hf_oid_asn1_type, tvb, foffset, 1, FALSE);
1766 length = tvb_get_guint8(tvb, foffset);
1768 proto_tree_add_item(atree, hf_ndps_oid, tvb, foffset, length, FALSE);
1780 length = tvb_get_guint8(tvb, foffset);
1785 global_attribute_name = label;
1786 return foffset+(length%2);
1790 name_or_id(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
1793 proto_tree_add_item(ndps_tree, hf_ndps_nameorid, tvb, foffset, 4, FALSE);
1795 if(tvb_get_ntohl(tvb, foffset-4)==1) /* Global */
1797 foffset = objectidentifier(tvb, ndps_tree, foffset);
1801 if(tvb_get_ntohl(tvb, foffset-4)==2) /* Local */
1803 foffset = ndps_string(tvb, hf_local_object_name, ndps_tree, foffset);
1810 qualifiedname(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
1812 guint32 qualified_name_type=0;
1814 qualified_name_type = tvb_get_ntohl(tvb, foffset);
1815 proto_tree_add_uint(ndps_tree, hf_ndps_qualified_name, tvb, foffset, 4, qualified_name_type);
1817 if (qualified_name_type != 0) {
1818 if (qualified_name_type == 1) {
1819 foffset = ndps_string(tvb, hf_printer_name, ndps_tree, foffset);
1823 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
1824 foffset = ndps_string(tvb, hf_ndps_tree, ndps_tree, foffset);
1831 objectidentification(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
1833 guint32 object_type=0;
1837 object_type = tvb_get_ntohl(tvb, foffset);
1838 aitem = proto_tree_add_item(ndps_tree, hf_obj_id_type, tvb, foffset, 4, FALSE);
1839 atree = proto_item_add_subtree(aitem, ett_ndps);
1843 case 0: /* Printer Contained Object ID */
1844 foffset = ndps_string(tvb, hf_printer_name, atree, foffset);
1845 proto_tree_add_item(atree, hf_ndps_object, tvb, foffset,
1849 case 1: /* Document Identifier */
1850 foffset = ndps_string(tvb, hf_printer_name, atree, foffset);
1851 proto_tree_add_item(atree, hf_ndps_document_number, tvb, foffset,
1855 case 2: /* Object Identifier */
1856 foffset = objectidentifier(tvb, atree, foffset);
1858 case 3: /* Object Name */
1859 foffset = ndps_string(tvb, hf_object_name, atree, foffset);
1860 if (foffset > tvb_length_remaining(tvb, foffset)) {
1863 foffset = name_or_id(tvb, atree, foffset);
1865 case 4: /* Name or Object ID */
1866 foffset = name_or_id(tvb, atree, foffset);
1868 case 5: /* Simple Name */
1869 foffset = ndps_string(tvb, hf_object_name, atree, foffset);
1871 case 6: /* Printer Configuration Object ID */
1872 foffset = ndps_string(tvb, hf_printer_name, atree, foffset);
1874 case 7: /* Qualified Name */
1875 foffset = qualifiedname(tvb, ndps_tree, foffset);
1877 case 8: /* Event Object ID */
1878 foffset = ndps_string(tvb, hf_object_name, atree, foffset);
1879 foffset = objectidentifier(tvb, atree, foffset);
1880 proto_tree_add_item(atree, hf_ndps_event_type, tvb, foffset,
1890 print_address(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
1892 guint32 address_type=0;
1894 guint32 address_len=0;
1896 address_type = tvb_get_ntohl(tvb, foffset);
1897 proto_tree_add_uint(ndps_tree, hf_ndps_address, tvb, foffset, 4, address_type);
1899 address_len = tvb_get_ntohl(tvb, foffset);
1900 proto_tree_add_item(ndps_tree, hf_address_len, tvb, foffset, 4, FALSE);
1902 switch(address_type)
1905 proto_tree_add_item(ndps_tree, hf_ndps_net, tvb, foffset, 4, FALSE);
1906 proto_tree_add_item(ndps_tree, hf_ndps_node, tvb, foffset+4, 6, FALSE);
1907 proto_tree_add_item(ndps_tree, hf_ndps_socket, tvb, foffset+10, 2, FALSE);
1908 foffset += address_len;
1911 proto_tree_add_item(ndps_tree, hf_ndps_port, tvb, foffset, 2, FALSE);
1912 address = tvb_get_letohl(tvb, foffset+2);
1913 proto_tree_add_ipv4(ndps_tree, hf_ndps_ip, tvb, foffset+2, 4, address);
1914 foffset += address_len;
1917 foffset += tvb_get_ntohl(tvb, foffset -4);
1920 return foffset+(address_len%4);
1924 address_item(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
1926 guint32 address_type=0;
1928 address_type = tvb_get_ntohl(tvb, foffset);
1929 proto_tree_add_uint(ndps_tree, hf_address_type, tvb, foffset, 4, address_type);
1931 switch(address_type)
1941 foffset = qualifiedname(tvb, ndps_tree, foffset);
1948 foffset = ndps_string(tvb, hf_object_name, ndps_tree, foffset);
1951 proto_tree_add_item(ndps_tree, hf_ndps_attrib_boolean, tvb, foffset, 4, FALSE);
1955 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
1959 foffset = print_address(tvb, ndps_tree, foffset);
1964 foffset = ndps_string(tvb, hf_object_name, ndps_tree, foffset);
1971 credentials(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
1973 guint32 cred_type=0;
1975 guint32 number_of_items=0;
1980 cred_type = tvb_get_ntohl(tvb, foffset);
1981 proto_tree_add_item(ndps_tree, hf_ndps_cred_type, tvb, foffset, 4, FALSE);
1986 foffset = ndps_string(tvb, hf_ndps_user_name, ndps_tree, foffset);
1987 number_of_items=tvb_get_ntohl(tvb, foffset);
1989 for (i = 1 ; i <= number_of_items; i++ )
1991 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Password %d", i);
1992 atree = proto_item_add_subtree(aitem, ett_ndps);
1993 length = tvb_get_ntohl(tvb, foffset);
1995 proto_tree_add_item(atree, hf_ndps_password, tvb, foffset, length, FALSE);
2000 length = tvb_get_ntohl(tvb, foffset);
2002 proto_tree_add_item(ndps_tree, hf_ndps_certified, tvb, foffset, length, FALSE);
2006 foffset = ndps_string(tvb, hf_ndps_server_name, ndps_tree, foffset);
2008 proto_tree_add_item(ndps_tree, hf_ndps_connection, tvb, foffset, 2, FALSE);
2012 length=tvb_get_ntohl(tvb, foffset);
2013 foffset = ndps_string(tvb, hf_ndps_server_name, ndps_tree, foffset);
2018 if (tvb_get_ntohs(tvb, foffset)==0) /* NDPS 1.0 */
2021 if (tvb_get_ntohs(tvb, foffset)==0) /* NDPS 1.1 */
2026 proto_tree_add_item(ndps_tree, hf_ndps_connection, tvb, foffset, 2, FALSE);
2028 foffset = ndps_string(tvb, hf_ndps_user_name, ndps_tree, foffset);
2031 foffset = ndps_string(tvb, hf_ndps_server_name, ndps_tree, foffset);
2033 proto_tree_add_item(ndps_tree, hf_ndps_connection, tvb, foffset, 2, FALSE);
2035 foffset = ndps_string(tvb, hf_ndps_user_name, ndps_tree, foffset);
2036 foffset += 8; /* Don't know what these 8 bytes signify */
2037 proto_tree_add_item(ndps_tree, hf_ndps_items, tvb, foffset, 4, FALSE);
2039 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
2040 foffset = ndps_string(tvb, hf_ndps_tree, ndps_tree, foffset);
2050 event_object_set(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
2052 guint32 number_of_items=0;
2053 guint32 number_of_items2=0;
2063 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Event");
2064 atree = proto_item_add_subtree(aitem, ett_ndps);
2065 number_of_items = tvb_get_ntohl(tvb, foffset);
2067 for (i = 1 ; i <= number_of_items; i++ )
2069 bitem = proto_tree_add_item(atree, hf_ndps_event_type, tvb, foffset, 4, FALSE);
2070 btree = proto_item_add_subtree(bitem, ett_ndps);
2072 foffset = objectidentifier(tvb, btree, foffset);
2073 foffset += align_4(tvb, foffset);
2074 foffset = objectidentification(tvb, btree, foffset);
2075 foffset += align_4(tvb, foffset);
2076 proto_tree_add_item(btree, hf_ndps_object_op, tvb, foffset, 4, FALSE);
2078 proto_tree_add_uint(btree, hf_ndps_event_object_identifier, tvb, foffset, 4, FALSE);
2080 if(tvb_get_ntohl(tvb, foffset-4)==1)
2082 foffset = objectidentifier(tvb, btree, foffset);
2083 foffset += align_4(tvb, foffset);
2087 if(tvb_get_ntohl(tvb, foffset-4)==2)
2089 number_of_items2 = tvb_get_ntohl(tvb, foffset);
2091 for (j = 1 ; j <= number_of_items2; j++ )
2093 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Item %d", j);
2094 ctree = proto_item_add_subtree(citem, ett_ndps);
2095 foffset = objectidentifier(tvb, ctree, foffset);
2096 foffset += align_4(tvb, foffset);
2106 cardinal_seq(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
2108 guint32 number_of_items=0;
2114 number_of_items = tvb_get_ntohl(tvb, foffset);
2116 for (i = 1 ; i <= number_of_items; i++ )
2118 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Cardinal %d", i);
2119 atree = proto_item_add_subtree(aitem, ett_ndps);
2120 length = tvb_get_ntohl(tvb, foffset);
2122 proto_tree_add_item(atree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
2124 foffset += (length%2);
2131 server_entry(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
2133 guint32 number_of_items=0;
2135 guint32 data_type=0;
2143 foffset = ndps_string(tvb, hf_ndps_server_name, ndps_tree, foffset);
2144 aitem = proto_tree_add_item(ndps_tree, hf_ndps_server_type, tvb, foffset, 4, FALSE);
2145 atree = proto_item_add_subtree(aitem, ett_ndps);
2147 foffset = print_address(tvb, atree, foffset);
2148 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Server Info");
2149 btree = proto_item_add_subtree(bitem, ett_ndps);
2150 number_of_items = tvb_get_ntohl(tvb, foffset);
2152 for (i = 1 ; i <= number_of_items; i++ )
2154 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Info %d", i);
2155 ctree = proto_item_add_subtree(citem, ett_ndps);
2156 data_type = tvb_get_ntohl(tvb, foffset);
2157 proto_tree_add_item(ctree, hf_ndps_data_item_type, tvb, foffset, 4, FALSE);
2162 proto_tree_add_item(ctree, hf_info_int, tvb, foffset, 1, FALSE);
2166 proto_tree_add_item(ctree, hf_info_int16, tvb, foffset, 2, FALSE);
2170 proto_tree_add_item(ctree, hf_info_int32, tvb, foffset, 4, FALSE);
2173 case 3: /* Boolean */
2174 proto_tree_add_item(ctree, hf_info_boolean, tvb, foffset, 4, FALSE);
2177 case 4: /* String */
2179 foffset = ndps_string(tvb, hf_info_string, ctree, foffset);
2190 attribute_value(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
2194 guint32 number_of_items=0;
2195 guint32 number_of_items2=0;
2196 guint32 attribute_type=0;
2197 guint32 integer_or_oid=0;
2198 guint32 event_object_type=0;
2199 guint32 ignored_type=0;
2200 guint32 resource_type=0;
2201 guint32 identifier_type=0;
2202 guint32 criterion_type=0;
2203 guint32 card_enum_time=0;
2204 guint32 media_type=0;
2205 guint32 doc_content=0;
2206 guint32 page_size=0;
2207 guint32 medium_size=0;
2208 guint32 numbers_up=0;
2209 guint32 colorant_set=0;
2212 guint32 label_value=0;
2218 if (global_attribute_name==NULL)
2221 label = match_strval(label_value, object_ids_7);
2222 global_attribute_name = label;
2224 attribute_type = tvb_get_ntohl(tvb, foffset);
2227 proto_tree_add_item(ndps_tree, hf_obj_attribute_type, tvb, foffset, 4, FALSE);
2230 switch(attribute_type)
2233 proto_tree_add_item(ndps_tree, hf_ndps_data, tvb, foffset+4, tvb_get_ntohl(tvb, foffset), FALSE);
2236 case 2: /* Descriptive Name */
2237 case 3: /* Descriptor */
2238 case 6: /* Simple Name */
2239 case 40: /* Distinguished Name*/
2240 case 50: /* Font Reference */
2241 case 58: /* Locale */
2242 case 102: /* File Path */
2243 case 103: /* Uniform Resource Identifier */
2244 case 108: /* Extended Resource Identifier */
2245 foffset = ndps_string(tvb, hf_object_name, ndps_tree, foffset);
2247 case 4: /* Message */
2248 case 5: /* Error Message */
2249 case 38: /* Name or OID */
2250 foffset = name_or_id(tvb, ndps_tree, foffset);
2252 case 39: /* Name or OID Seq */
2253 number_of_items = tvb_get_ntohl(tvb, foffset);
2255 for (i = 1 ; i <= number_of_items; i++ )
2257 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Item %d", i);
2258 atree = proto_item_add_subtree(aitem, ett_ndps);
2259 foffset = name_or_id(tvb, atree, foffset);
2262 case 7: /* Distinguished Name String*/
2263 case 79: /* File Reference */
2264 foffset = ndps_string(tvb, hf_object_name, ndps_tree, foffset);
2265 foffset = name_or_id(tvb, ndps_tree, foffset);
2267 case 8: /* Distinguished Name String Seq */
2268 number_of_items = tvb_get_ntohl(tvb, foffset);
2270 for (i = 1 ; i <= number_of_items; i++ )
2272 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Name %d", i);
2273 atree = proto_item_add_subtree(aitem, ett_ndps);
2274 foffset = ndps_string(tvb, hf_object_name, atree, foffset);
2275 foffset = name_or_id(tvb, atree, foffset);
2278 case 9: /* Delta Time */
2280 case 11: /* Integer */
2281 case 13: /* Cardinal */
2282 case 15: /* Positive Integer */
2283 case 18: /* Maximum Integer */
2284 case 19: /* Minimum Integer */
2285 case 35: /* Percent */
2286 case 57: /* Job Priority */
2287 case 72: /* Sides */
2288 case 95: /* Enumeration */
2289 if (strcmp(global_attribute_name,"(Novell) Attribute PRINTER SECURITY LEVEL")==0)
2291 proto_tree_add_item(ndps_tree, hf_print_security, tvb, foffset, 4, FALSE);
2296 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2300 case 12: /* Integer Seq */
2301 case 14: /* Cardinal Seq */
2302 length = tvb_get_ntohl(tvb, foffset);
2304 proto_tree_add_item(ndps_tree, hf_info_int32, tvb, foffset, length, FALSE);
2307 case 16: /* Integer Range */
2308 case 17: /* Cardinal Range */
2309 proto_tree_add_item(ndps_tree, hf_ndps_lower_range, tvb, foffset, 4, FALSE);
2311 proto_tree_add_item(ndps_tree, hf_ndps_upper_range, tvb, foffset, 4, FALSE);
2314 case 20: /* Integer 64 */
2315 case 22: /* Cardinal 64 */
2316 case 24: /* Positive Integer 64 */
2317 case 31: /* Non-Negative Real */
2319 proto_tree_add_item(ndps_tree, hf_ndps_n64, tvb, foffset, 8, FALSE);
2322 case 21: /* Integer 64 Seq */
2323 case 23: /* Cardinal 64 Seq */
2324 case 30: /* Real Seq */
2325 number_of_items = tvb_get_ntohl(tvb, foffset);
2327 for (i = 1 ; i <= number_of_items; i++ )
2329 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Item %d", i);
2330 atree = proto_item_add_subtree(aitem, ett_ndps);
2331 proto_tree_add_item(atree, hf_ndps_n64, tvb, foffset, 8, FALSE);
2335 case 25: /* Integer 64 Range */
2336 case 26: /* Cardinal 64 Range */
2337 case 32: /* Real Range */
2338 case 33: /* Non-Negative Real Range */
2339 proto_tree_add_item(ndps_tree, hf_ndps_lower_range_n64, tvb, foffset, 8, FALSE);
2341 proto_tree_add_item(ndps_tree, hf_ndps_upper_range_n64, tvb, foffset, 8, FALSE);
2344 case 27: /* Maximum Integer 64 */
2345 proto_tree_add_item(ndps_tree, hf_ndps_lower_range_n64, tvb, foffset, 8, FALSE);
2348 case 28: /* Minimum Integer 64 */
2349 proto_tree_add_item(ndps_tree, hf_ndps_upper_range_n64, tvb, foffset, 8, FALSE);
2352 case 34: /* Boolean */
2353 proto_tree_add_item(ndps_tree, hf_ndps_attrib_boolean, tvb, foffset, 4, FALSE);
2356 case 36: /* Object Identifier */
2357 foffset = objectidentifier(tvb, ndps_tree, foffset);
2359 case 37: /* Object Identifier Seq */
2360 number_of_items = tvb_get_ntohl(tvb, foffset);
2362 for (i = 1 ; i <= number_of_items; i++ )
2364 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object %d", i);
2365 atree = proto_item_add_subtree(aitem, ett_ndps);
2366 foffset = objectidentifier(tvb, atree, foffset);
2369 case 41: /* Relative Distinguished Name Seq */
2370 number_of_items = tvb_get_ntohl(tvb, foffset);
2372 for (i = 1 ; i <= number_of_items; i++ )
2374 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Name %d", i);
2375 atree = proto_item_add_subtree(aitem, ett_ndps);
2376 foffset = ndps_string(tvb, hf_object_name, atree, foffset);
2379 case 42: /* Realization */
2380 proto_tree_add_item(ndps_tree, hf_ndps_realization, tvb, foffset, 4, FALSE);
2383 case 43: /* Medium Dimensions */
2384 proto_tree_add_item(ndps_tree, hf_ndps_xdimension_n64, tvb, foffset, 8, FALSE);
2386 proto_tree_add_item(ndps_tree, hf_ndps_ydimension_n64, tvb, foffset, 8, FALSE);
2389 case 44: /* Dimension */
2390 proto_tree_add_item(ndps_tree, hf_ndps_dim_value, tvb, foffset, 8, FALSE);
2392 if (tvb_get_ntohl(tvb, foffset-4) == 0) {
2393 proto_tree_add_item(ndps_tree, hf_ndps_n64, tvb, foffset, 8, FALSE);
2398 foffset = name_or_id(tvb, ndps_tree, foffset);
2400 proto_tree_add_item(ndps_tree, hf_ndps_dim_flag, tvb, foffset, 8, FALSE);
2402 proto_tree_add_item(ndps_tree, hf_ndps_n64, tvb, foffset, 8, FALSE);
2405 case 45: /* XY Dimensions */
2406 proto_tree_add_item(ndps_tree, hf_ndps_xydim_value, tvb, foffset, 8, FALSE);
2408 if (tvb_get_ntohl(tvb, foffset-4) == 1) {
2409 foffset = name_or_id(tvb, ndps_tree, foffset);
2413 proto_tree_add_item(ndps_tree, hf_ndps_xdimension_n64, tvb, foffset, 8, FALSE);
2415 proto_tree_add_item(ndps_tree, hf_ndps_ydimension_n64, tvb, foffset, 8, FALSE);
2418 proto_tree_add_item(ndps_tree, hf_ndps_dim_flag, tvb, foffset, 8, FALSE);
2420 proto_tree_add_item(ndps_tree, hf_ndps_n64, tvb, foffset, 8, FALSE);
2423 case 46: /* Locations */
2424 proto_tree_add_item(ndps_tree, hf_ndps_location_value, tvb, foffset, 8, FALSE);
2426 if (tvb_get_ntohl(tvb, foffset-4) == 0) {
2427 number_of_items = tvb_get_ntohl(tvb, foffset);
2429 for (i = 1 ; i <= number_of_items; i++ )
2431 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Location %d", i);
2432 atree = proto_item_add_subtree(aitem, ett_ndps);
2433 proto_tree_add_item(atree, hf_ndps_n64, tvb, foffset, 8, FALSE);
2439 foffset = name_or_id(tvb, ndps_tree, foffset);
2441 proto_tree_add_item(ndps_tree, hf_ndps_dim_flag, tvb, foffset, 8, FALSE);
2443 proto_tree_add_item(ndps_tree, hf_ndps_n64, tvb, foffset, 8, FALSE);
2447 proto_tree_add_item(ndps_tree, hf_ndps_xmin_n64, tvb, foffset, 8, FALSE);
2449 proto_tree_add_item(ndps_tree, hf_ndps_xmax_n64, tvb, foffset, 8, FALSE);
2451 proto_tree_add_item(ndps_tree, hf_ndps_ymin_n64, tvb, foffset, 8, FALSE);
2453 proto_tree_add_item(ndps_tree, hf_ndps_ymax_n64, tvb, foffset, 8, FALSE);
2456 case 48: /* Area Seq */
2457 number_of_items = tvb_get_ntohl(tvb, foffset);
2459 for (i = 1 ; i <= number_of_items; i++ )
2461 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Area %d", i);
2462 atree = proto_item_add_subtree(aitem, ett_ndps);
2463 proto_tree_add_item(atree, hf_ndps_xmin_n64, tvb, foffset, 8, FALSE);
2465 proto_tree_add_item(atree, hf_ndps_xmax_n64, tvb, foffset, 8, FALSE);
2467 proto_tree_add_item(atree, hf_ndps_ymin_n64, tvb, foffset, 8, FALSE);
2469 proto_tree_add_item(atree, hf_ndps_ymax_n64, tvb, foffset, 8, FALSE);
2474 proto_tree_add_item(ndps_tree, hf_ndps_edge_value, tvb, foffset, 4, FALSE);
2477 case 51: /* Cardinal or OID */
2478 proto_tree_add_item(ndps_tree, hf_ndps_cardinal_or_oid, tvb, foffset, 4, FALSE);
2480 if (tvb_get_ntohl(tvb, foffset-4)==0) {
2481 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2486 foffset = objectidentifier(tvb, ndps_tree, foffset);
2489 case 52: /* OID Cardinal Map */
2490 foffset = objectidentifier(tvb, ndps_tree, foffset);
2491 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2494 case 53: /* Cardinal or Name or OID */
2495 proto_tree_add_item(ndps_tree, hf_ndps_cardinal_name_or_oid, tvb, foffset, 4, FALSE);
2497 if (tvb_get_ntohl(tvb, foffset-4)==0) {
2498 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2503 foffset = name_or_id(tvb, ndps_tree, foffset);
2506 case 54: /* Positive Integer or OID */
2507 integer_or_oid = tvb_get_ntohl(tvb, foffset);
2508 proto_tree_add_uint(ndps_tree, hf_ndps_integer_or_oid, tvb, foffset, 4, integer_or_oid);
2510 if (integer_or_oid==0) {
2511 foffset = objectidentifier(tvb, ndps_tree, foffset);
2515 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2519 case 55: /* Event Handling Profile */
2520 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
2522 proto_tree_add_item(ndps_tree, hf_ndps_persistence, tvb, foffset, 4, FALSE);
2524 foffset = qualifiedname(tvb, ndps_tree, foffset);
2525 length = tvb_get_ntohl(tvb, foffset);
2527 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
2529 proto_tree_add_item(ndps_tree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
2531 foffset = name_or_id(tvb, ndps_tree, foffset);
2532 number_of_items = tvb_get_ntohl(tvb, foffset);
2533 for (i = 1 ; i <= number_of_items; i++ )
2535 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Address Item %d", i);
2536 atree = proto_item_add_subtree(aitem, ett_ndps);
2537 foffset += address_item(tvb, atree, foffset);
2539 number_of_items = tvb_get_ntohl(tvb, foffset);
2540 for (i = 1 ; i <= number_of_items; i++ )
2542 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Event %d", i);
2543 atree = proto_item_add_subtree(aitem, ett_ndps);
2544 proto_tree_add_item(atree, hf_ndps_event_type, tvb, foffset, 4, FALSE);
2546 foffset = objectidentifier(tvb, atree, foffset);
2547 foffset = objectidentification(tvb, atree, foffset);
2548 proto_tree_add_item(atree, hf_ndps_object_op, tvb, foffset, 4, FALSE);
2551 event_object_type = tvb_get_ntohl(tvb, foffset);
2552 proto_tree_add_uint(atree, hf_ndps_event_object_identifier, tvb, foffset, 4, event_object_type);
2554 if(event_object_type==1)
2556 foffset = objectidentifier(tvb, atree, foffset);
2560 if(event_object_type==0)
2562 number_of_items2 = tvb_get_ntohl(tvb, foffset);
2564 for (j = 1 ; j <= number_of_items2; j++ )
2566 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Object %d", i);
2567 btree = proto_item_add_subtree(bitem, ett_ndps);
2568 foffset = objectidentifier(tvb, btree, foffset);
2574 case 56: /* Octet String */
2575 case 63: /* Job Password */
2576 case 66: /* Print Checkpoint */
2577 foffset = ndps_string(tvb, hf_info_string, ndps_tree, foffset);
2579 case 59: /* Method Delivery Address */
2580 proto_tree_add_item(ndps_tree, hf_ndps_delivery_add_type, tvb, foffset, 4, FALSE);
2581 event_object_type = tvb_get_ntohl(tvb, foffset);
2583 switch(event_object_type)
2585 case 0: /*MHS ADDR*/
2586 case 1: /*DISTINGUISHED_NAME*/
2588 case 3: /*OCTET_STRING*/
2589 foffset = ndps_string(tvb, hf_info_string, ndps_tree, foffset);
2591 case 4: /*DIST_NAME_STRING*/
2592 foffset = ndps_string(tvb, hf_object_name, ndps_tree, foffset);
2593 foffset = name_or_id(tvb, ndps_tree, foffset);
2595 case 5: /*RPC_ADDRESS*/
2596 case 6: /*QUALIFIED_NAME*/
2597 foffset = objectidentifier(tvb, ndps_tree, foffset);
2598 foffset = qualifiedname(tvb, ndps_tree, foffset);
2604 case 60: /* Object Identification */
2605 foffset = objectidentification(tvb, ndps_tree, foffset);
2607 case 61: /* Results Profile */
2608 foffset = objectidentifier(tvb, ndps_tree, foffset);
2609 foffset = name_or_id(tvb, ndps_tree, foffset);
2610 foffset = address_item(tvb, ndps_tree, foffset);
2611 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2613 foffset = name_or_id(tvb, ndps_tree, foffset);
2615 case 62: /* Criteria */
2616 foffset = objectidentifier(tvb, ndps_tree, foffset);
2617 criterion_type = tvb_get_ntohl(tvb, foffset);
2618 proto_tree_add_uint(ndps_tree, hf_ndps_criterion_type, tvb, foffset, 4, criterion_type);
2620 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2623 case 64: /* Job Level */
2624 foffset = objectidentifier(tvb, ndps_tree, foffset);
2625 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2628 case 65: /* Job Categories */
2629 foffset = objectidentifier(tvb, ndps_tree, foffset);
2630 number_of_items = tvb_get_ntohl(tvb, foffset);
2632 for (i = 1 ; i <= number_of_items; i++ )
2634 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Job %d", i);
2635 atree = proto_item_add_subtree(aitem, ett_ndps);
2636 length = tvb_get_ntohl(tvb, foffset);
2638 proto_tree_add_item(atree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
2640 foffset += (length%2);
2643 case 67: /* Ignored Attribute */
2644 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2646 foffset = objectidentifier(tvb, ndps_tree, foffset);
2647 number_of_items = tvb_get_ntohl(tvb, foffset);
2649 for (i = 1 ; i <= number_of_items; i++ )
2651 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Ignored Attribute %d", i);
2652 atree = proto_item_add_subtree(aitem, ett_ndps);
2653 ignored_type = tvb_get_ntohl(tvb, foffset);
2654 proto_tree_add_uint(atree, hf_ndps_ignored_type, tvb, foffset, 4, ignored_type);
2656 if (ignored_type == 38)
2658 foffset = name_or_id(tvb, atree, foffset);
2662 foffset = objectidentifier(tvb, atree, foffset);
2666 case 68: /* Resource */
2667 resource_type = tvb_get_ntohl(tvb, foffset);
2668 proto_tree_add_uint(ndps_tree, hf_ndps_resource_type, tvb, foffset, 4, resource_type);
2670 if (resource_type == 0)
2672 foffset = name_or_id(tvb, ndps_tree, foffset);
2676 foffset = ndps_string(tvb, hf_ndps_tree, ndps_tree, foffset);
2679 case 69: /* Medium Substitution */
2680 foffset = name_or_id(tvb, ndps_tree, foffset);
2681 foffset = name_or_id(tvb, ndps_tree, foffset);
2683 case 70: /* Font Substitution */
2684 foffset = ndps_string(tvb, hf_ndps_tree, ndps_tree, foffset);
2685 foffset = ndps_string(tvb, hf_ndps_tree, ndps_tree, foffset);
2687 case 71: /* Resource Context Seq */
2688 number_of_items = tvb_get_ntohl(tvb, foffset);
2690 for (i = 1 ; i <= number_of_items; i++ )
2692 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Resource %d", i);
2693 atree = proto_item_add_subtree(aitem, ett_ndps);
2694 resource_type = tvb_get_ntohl(tvb, foffset);
2695 proto_tree_add_uint(atree, hf_ndps_resource_type, tvb, foffset, 4, resource_type);
2697 if (resource_type == 0)
2699 foffset = name_or_id(tvb, atree, foffset);
2703 foffset = ndps_string(tvb, hf_ndps_tree, atree, foffset);
2707 case 73: /* Page Select Seq */
2708 number_of_items = tvb_get_ntohl(tvb, foffset);
2710 for (i = 1 ; i <= number_of_items; i++ )
2712 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Page Select %d", i);
2713 atree = proto_item_add_subtree(aitem, ett_ndps);
2714 proto_tree_add_item(atree, hf_ndps_page_flag, tvb, foffset, 4, FALSE);
2716 identifier_type = tvb_get_ntohl(tvb, foffset);
2717 proto_tree_add_uint(atree, hf_ndps_identifier_type, tvb, foffset, 4, identifier_type);
2719 if (identifier_type == 0)
2721 proto_tree_add_item(atree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2724 if (identifier_type == 1)
2726 foffset = ndps_string(tvb, hf_ndps_tree, atree, foffset);
2728 if (identifier_type == 2)
2730 foffset = name_or_id(tvb, atree, foffset);
2732 proto_tree_add_item(atree, hf_ndps_page_flag, tvb, foffset, 4, FALSE);
2734 identifier_type = tvb_get_ntohl(tvb, foffset);
2735 proto_tree_add_uint(atree, hf_ndps_identifier_type, tvb, foffset, 4, identifier_type);
2737 if (identifier_type == 0)
2739 proto_tree_add_item(atree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2742 if (identifier_type == 1)
2744 foffset = ndps_string(tvb, hf_ndps_tree, atree, foffset);
2746 if (identifier_type == 2)
2748 foffset = name_or_id(tvb, atree, foffset);
2752 case 74: /* Page Media Select */
2753 media_type = tvb_get_ntohl(tvb, foffset);
2754 proto_tree_add_uint(ndps_tree, hf_ndps_media_type, tvb, foffset, 4, media_type);
2756 if (media_type == 0)
2758 foffset = name_or_id(tvb, ndps_tree, foffset);
2762 foffset = ndps_string(tvb, hf_ndps_tree, ndps_tree, foffset);
2763 number_of_items = tvb_get_ntohl(tvb, foffset);
2765 for (i = 1 ; i <= number_of_items; i++ )
2767 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Item %d", i);
2768 atree = proto_item_add_subtree(aitem, ett_ndps);
2769 proto_tree_add_item(atree, hf_ndps_page_flag, tvb, foffset, 4, FALSE);
2771 identifier_type = tvb_get_ntohl(tvb, foffset);
2772 proto_tree_add_uint(atree, hf_ndps_identifier_type, tvb, foffset, 4, identifier_type);
2774 if (identifier_type == 0)
2776 proto_tree_add_item(atree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2779 if (identifier_type == 1)
2781 foffset = ndps_string(tvb, hf_ndps_tree, atree, foffset);
2783 if (identifier_type == 2)
2785 foffset = name_or_id(tvb, atree, foffset);
2790 case 75: /* Document Content */
2791 doc_content = tvb_get_ntohl(tvb, foffset);
2792 proto_tree_add_uint(ndps_tree, hf_ndps_doc_content, tvb, foffset, 4, doc_content);
2794 if (doc_content == 0)
2796 length = tvb_get_ntohl(tvb, foffset);
2798 proto_tree_add_item(ndps_tree, hf_ndps_octet_string, tvb, foffset, length, FALSE);
2800 foffset += (length%2);
2804 foffset = ndps_string(tvb, hf_object_name, ndps_tree, foffset);
2805 foffset = name_or_id(tvb, ndps_tree, foffset);
2808 case 76: /* Page Size */
2809 page_size = tvb_get_ntohl(tvb, foffset);
2810 proto_tree_add_uint(ndps_tree, hf_ndps_page_size, tvb, foffset, 4, page_size);
2814 foffset = objectidentifier(tvb, ndps_tree, foffset);
2818 proto_tree_add_item(ndps_tree, hf_ndps_xdimension_n64, tvb, foffset, 8, FALSE);
2820 proto_tree_add_item(ndps_tree, hf_ndps_ydimension_n64, tvb, foffset, 8, FALSE);
2824 case 77: /* Presentation Direction */
2825 proto_tree_add_uint(ndps_tree, hf_ndps_direction, tvb, foffset, 4, FALSE);
2828 case 78: /* Page Order */
2829 proto_tree_add_uint(ndps_tree, hf_ndps_page_order, tvb, foffset, 4, FALSE);
2832 case 80: /* Medium Source Size */
2833 foffset = name_or_id(tvb, ndps_tree, foffset);
2834 medium_size = tvb_get_ntohl(tvb, foffset);
2835 proto_tree_add_uint(ndps_tree, hf_ndps_medium_size, tvb, foffset, 4, medium_size);
2837 if (medium_size == 0)
2839 page_size = tvb_get_ntohl(tvb, foffset);
2840 proto_tree_add_uint(ndps_tree, hf_ndps_page_size, tvb, foffset, 4, page_size);
2844 foffset = objectidentifier(tvb, ndps_tree, foffset);
2848 proto_tree_add_item(ndps_tree, hf_ndps_xdimension_n64, tvb, foffset, 8, FALSE);
2850 proto_tree_add_item(ndps_tree, hf_ndps_ydimension_n64, tvb, foffset, 8, FALSE);
2853 proto_tree_add_item(ndps_tree, hf_ndps_long_edge_feeds, tvb, foffset, 4, FALSE);
2855 proto_tree_add_item(ndps_tree, hf_ndps_xmin_n64, tvb, foffset, 8, FALSE);
2857 proto_tree_add_item(ndps_tree, hf_ndps_xmax_n64, tvb, foffset, 8, FALSE);
2859 proto_tree_add_item(ndps_tree, hf_ndps_ymin_n64, tvb, foffset, 8, FALSE);
2861 proto_tree_add_item(ndps_tree, hf_ndps_ymax_n64, tvb, foffset, 8, FALSE);
2866 proto_tree_add_item(ndps_tree, hf_ndps_lower_range_n64, tvb, foffset, 8, FALSE);
2868 proto_tree_add_item(ndps_tree, hf_ndps_upper_range_n64, tvb, foffset, 8, FALSE);
2870 proto_tree_add_item(ndps_tree, hf_ndps_inc_across_feed, tvb, foffset, 8, FALSE);
2872 proto_tree_add_item(ndps_tree, hf_ndps_lower_range_n64, tvb, foffset, 8, FALSE);
2874 proto_tree_add_item(ndps_tree, hf_ndps_upper_range_n64, tvb, foffset, 8, FALSE);
2876 proto_tree_add_item(ndps_tree, hf_ndps_size_inc_in_feed, tvb, foffset, 8, FALSE);
2878 proto_tree_add_item(ndps_tree, hf_ndps_long_edge_feeds, tvb, foffset, 4, FALSE);
2880 proto_tree_add_item(ndps_tree, hf_ndps_xmin_n64, tvb, foffset, 8, FALSE);
2882 proto_tree_add_item(ndps_tree, hf_ndps_xmax_n64, tvb, foffset, 8, FALSE);
2884 proto_tree_add_item(ndps_tree, hf_ndps_ymin_n64, tvb, foffset, 8, FALSE);
2886 proto_tree_add_item(ndps_tree, hf_ndps_ymax_n64, tvb, foffset, 8, FALSE);
2890 case 81: /* Input Tray Medium */
2891 foffset = name_or_id(tvb, ndps_tree, foffset);
2892 foffset = name_or_id(tvb, ndps_tree, foffset);
2894 case 82: /* Output Bins Characteristics */
2895 number_of_items = tvb_get_ntohl(tvb, foffset);
2897 for (i = 1 ; i <= number_of_items; i++ )
2899 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Page Information %d", i);
2900 atree = proto_item_add_subtree(aitem, ett_ndps);
2901 proto_tree_add_uint(atree, hf_ndps_page_order, tvb, foffset, 4, FALSE);
2903 proto_tree_add_uint(atree, hf_ndps_page_orientation, tvb, foffset, 4, FALSE);
2907 case 83: /* Page ID Type */
2908 proto_tree_add_uint(ndps_tree, hf_ndps_identifier_type, tvb, foffset, 4, FALSE);
2911 case 84: /* Level Range */
2912 foffset = objectidentifier(tvb, ndps_tree, foffset);
2913 proto_tree_add_item(ndps_tree, hf_ndps_lower_range, tvb, foffset, 4, FALSE);
2915 proto_tree_add_item(ndps_tree, hf_ndps_upper_range, tvb, foffset, 4, FALSE);
2918 case 85: /* Category Set */
2919 foffset = objectidentifier(tvb, ndps_tree, foffset);
2920 number_of_items = tvb_get_ntohl(tvb, foffset);
2922 for (i = 1 ; i <= number_of_items; i++ )
2924 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Category %d", i);
2925 atree = proto_item_add_subtree(aitem, ett_ndps);
2926 length = tvb_get_ntohl(tvb, foffset);
2928 proto_tree_add_item(atree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
2930 foffset += (length%2);
2932 number_of_items = tvb_get_ntohl(tvb, foffset);
2934 for (i = 1 ; i <= number_of_items; i++ )
2936 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Value %d", i);
2937 atree = proto_item_add_subtree(aitem, ett_ndps);
2938 length = tvb_get_ntohl(tvb, foffset);
2940 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
2942 foffset += (length%2);
2945 case 86: /* Numbers Up Supported */
2946 proto_tree_add_uint(ndps_tree, hf_ndps_numbers_up, tvb, foffset, 4, FALSE);
2947 numbers_up=tvb_get_ntohl(tvb, foffset);
2951 case 0: /*Cardinal*/
2952 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2955 case 1: /*Name or OID*/
2956 foffset = name_or_id(tvb, ndps_tree, foffset);
2958 case 2: /*Cardinal Range*/
2959 proto_tree_add_item(ndps_tree, hf_ndps_lower_range, tvb, foffset, 4, FALSE);
2961 proto_tree_add_item(ndps_tree, hf_ndps_upper_range, tvb, foffset, 4, FALSE);
2968 case 87: /* Finishing */
2969 case 88: /* Print Contained Object ID */
2970 foffset = ndps_string(tvb, hf_object_name, ndps_tree, foffset);
2971 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
2974 case 89: /* Print Config Object ID */
2975 foffset = ndps_string(tvb, hf_object_name, ndps_tree, foffset);
2976 foffset = qualifiedname(tvb, ndps_tree, foffset);
2978 case 90: /* Typed Name */
2979 foffset = ndps_string(tvb, hf_object_name, ndps_tree, foffset);
2980 proto_tree_add_item(ndps_tree, hf_level, tvb, foffset, 4, FALSE);
2982 proto_tree_add_item(ndps_tree, hf_interval, tvb, foffset, 4, FALSE);
2985 case 91: /* Network Address */
2986 proto_tree_add_item(ndps_tree, hf_ndps_address, tvb, foffset, 4, FALSE);
2988 length = tvb_get_ntohl(tvb, foffset);
2990 proto_tree_add_item(ndps_tree, hf_ndps_add_bytes, tvb, foffset, 4, FALSE);
2993 case 92: /* XY Dimensions Value */
2994 proto_tree_add_item(ndps_tree, hf_ndps_xydim_value, tvb, foffset, 8, FALSE);
2996 if (tvb_get_ntohl(tvb, foffset-4) == 1) {
2997 foffset = name_or_id(tvb, ndps_tree, foffset);
3001 if (tvb_get_ntohl(tvb, foffset-4) == 0)
3003 proto_tree_add_item(ndps_tree, hf_ndps_xdimension_n64, tvb, foffset, 8, FALSE);
3005 proto_tree_add_item(ndps_tree, hf_ndps_ydimension_n64, tvb, foffset, 8, FALSE);
3010 proto_tree_add_item(ndps_tree, hf_ndps_xdimension, tvb, foffset, 4, FALSE);
3012 proto_tree_add_item(ndps_tree, hf_ndps_ydimension, tvb, foffset, 4, FALSE);
3017 case 93: /* Name or OID Dimensions Map */
3018 foffset = name_or_id(tvb, ndps_tree, foffset);
3019 proto_tree_add_item(ndps_tree, hf_ndps_xdimension, tvb, foffset, 4, FALSE);
3021 proto_tree_add_item(ndps_tree, hf_ndps_ydimension, tvb, foffset, 4, FALSE);
3024 case 94: /* Printer State Reason */
3026 foffset = name_or_id(tvb, ndps_tree, foffset);
3027 proto_tree_add_item(ndps_tree, hf_ndps_state_severity, tvb, foffset, 4, FALSE);
3029 proto_tree_add_item(ndps_tree, hf_ndps_training, tvb, foffset, 4, FALSE);
3031 foffset = objectidentifier(tvb, ndps_tree, foffset);
3032 foffset += align_4(tvb, foffset);
3033 foffset = objectidentification(tvb, ndps_tree, foffset);
3034 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
3036 foffset = name_or_id(tvb, ndps_tree, foffset);
3038 case 96: /* Qualified Name */
3039 foffset = qualifiedname(tvb, ndps_tree, foffset);
3041 case 97: /* Qualified Name Set */
3042 number_of_items = tvb_get_ntohl(tvb, foffset);
3044 for (i = 1 ; i <= number_of_items; i++ )
3046 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Name %d", i);
3047 atree = proto_item_add_subtree(aitem, ett_ndps);
3048 foffset = qualifiedname(tvb, atree, foffset);
3051 case 98: /* Colorant Set */
3052 colorant_set = tvb_get_ntohl(tvb, foffset);
3053 proto_tree_add_item(ndps_tree, hf_ndps_colorant_set, tvb, foffset, 4, FALSE);
3055 if (colorant_set==0)
3057 foffset = name_or_id(tvb, ndps_tree, foffset);
3062 foffset = objectidentifier(tvb, ndps_tree, foffset);
3063 number_of_items = tvb_get_ntohl(tvb, foffset);
3065 for (i = 1 ; i <= number_of_items; i++ )
3067 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Colorant %d", i);
3068 atree = proto_item_add_subtree(aitem, ett_ndps);
3069 foffset = name_or_id(tvb, atree, foffset);
3073 case 99: /* Resource Printer ID */
3074 number_of_items = tvb_get_ntohl(tvb, foffset);
3076 for (i = 1 ; i <= number_of_items; i++ )
3078 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Printer %d", i);
3079 atree = proto_item_add_subtree(aitem, ett_ndps);
3080 foffset = ndps_string(tvb, hf_ndps_printer_type, atree, foffset);
3081 foffset = ndps_string(tvb, hf_ndps_printer_manuf, atree, foffset);
3082 foffset = ndps_string(tvb, hf_ndps_inf_file_name, atree, foffset);
3084 proto_tree_add_item(ndps_tree, hf_os_type, tvb, foffset, 4, FALSE);
3087 case 100: /* Event Object ID */
3088 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
3089 foffset = objectidentifier(tvb, ndps_tree, foffset);
3090 proto_tree_add_item(ndps_tree, hf_ndps_event_type, tvb, foffset, 4, FALSE);
3093 case 101: /* Qualified Name Map */
3094 foffset = qualifiedname(tvb, ndps_tree, foffset);
3095 foffset = qualifiedname(tvb, ndps_tree, foffset);
3097 case 104: /* Cardinal or Enum or Time */
3098 card_enum_time = tvb_get_ntohl(tvb, foffset);
3099 proto_tree_add_item(ndps_tree, hf_ndps_card_enum_time, tvb, foffset, 4, FALSE);
3101 if (card_enum_time==0)
3103 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
3108 if (card_enum_time==1)
3110 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
3115 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
3120 case 105: /* Print Contained Object ID Set */
3121 number_of_items = tvb_get_ntohl(tvb, foffset);
3123 for (i = 1 ; i <= number_of_items; i++ )
3125 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object %d", i);
3126 atree = proto_item_add_subtree(aitem, ett_ndps);
3127 foffset = ndps_string(tvb, hf_ndps_pa_name, atree, foffset);
3128 proto_tree_add_item(atree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
3132 case 106: /* Octet String Pair */
3133 length = tvb_get_ntohl(tvb, foffset);
3135 proto_tree_add_item(ndps_tree, hf_ndps_octet_string, tvb, foffset, length, FALSE);
3137 foffset += (length%2);
3138 length = tvb_get_ntohl(tvb, foffset);
3140 proto_tree_add_item(ndps_tree, hf_ndps_octet_string, tvb, foffset, length, FALSE);
3142 foffset += (length%2);
3144 case 107: /* Octet String Integer Pair */
3145 length = tvb_get_ntohl(tvb, foffset);
3147 proto_tree_add_item(ndps_tree, hf_ndps_octet_string, tvb, foffset, length, FALSE);
3149 foffset += (length%2);
3150 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
3152 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
3155 case 109: /* Event Handling Profile 2 */
3156 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
3158 proto_tree_add_item(ndps_tree, hf_ndps_persistence, tvb, foffset, 4, FALSE);
3160 foffset = qualifiedname(tvb, ndps_tree, foffset);
3161 length = tvb_get_ntohl(tvb, foffset);
3163 proto_tree_add_item(ndps_tree, hf_ndps_octet_string, tvb, foffset, length, FALSE);
3165 foffset += (length%2);
3166 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
3168 foffset = name_or_id(tvb, ndps_tree, foffset);
3169 proto_tree_add_item(ndps_tree, hf_ndps_delivery_add_type, tvb, foffset, 4, FALSE);
3170 event_object_type = tvb_get_ntohl(tvb, foffset);
3172 switch(event_object_type)
3174 case 0: /*MHS ADDR*/
3175 case 1: /*DISTINGUISHED_NAME*/
3177 foffset = ndps_string(tvb, hf_ndps_tree, ndps_tree, foffset);
3179 case 3: /*OCTET_STRING*/
3180 length = tvb_get_ntohl(tvb, foffset);
3182 proto_tree_add_item(ndps_tree, hf_ndps_octet_string, tvb, foffset, length, FALSE);
3184 foffset += (length%2);
3186 case 4: /*DIST_NAME_STRING*/
3187 foffset = ndps_string(tvb, hf_object_name, ndps_tree, foffset);
3188 foffset = name_or_id(tvb, ndps_tree, foffset);
3190 case 5: /*RPC_ADDRESS*/
3191 case 6: /*QUALIFIED_NAME*/
3192 foffset = objectidentifier(tvb, ndps_tree, foffset);
3193 foffset = qualifiedname(tvb, ndps_tree, foffset);
3198 number_of_items = tvb_get_ntohl(tvb, foffset);
3200 for (i = 1 ; i <= number_of_items; i++ )
3202 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Event %d", i);
3203 atree = proto_item_add_subtree(aitem, ett_ndps);
3204 foffset = ndps_string(tvb, hf_object_name, atree, foffset);
3205 foffset = objectidentifier(tvb, atree, foffset);
3206 proto_tree_add_item(atree, hf_ndps_event_type, tvb, foffset,
3210 foffset = objectidentifier(tvb, ndps_tree, foffset);
3211 foffset = qualifiedname(tvb, ndps_tree, foffset);
3212 number_of_items = tvb_get_ntohl(tvb, foffset);
3214 for (i = 1 ; i <= number_of_items; i++ )
3216 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object %d", i);
3217 atree = proto_item_add_subtree(aitem, ett_ndps);
3218 foffset = objectidentifier(tvb, atree, foffset);
3220 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
3222 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
3224 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
3226 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
3236 commonarguments(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
3238 guint32 number_of_items=0;
3245 number_of_items = tvb_get_ntohl(tvb, foffset);
3246 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Common Arguments");
3247 atree = proto_item_add_subtree(aitem, ett_ndps);
3249 for (i = 1 ; i <= number_of_items; i++ )
3251 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Argument %d", i);
3252 btree = proto_item_add_subtree(bitem, ett_ndps);
3253 foffset = attribute_value(tvb, atree, foffset);
3259 res_add_input_data(tvbuff_t* tvb, proto_tree *ndps_tree, int foffset)
3261 guint32 resource_type=0;
3263 proto_tree_add_item(ndps_tree, hf_res_type, tvb, foffset, 4, FALSE);
3264 resource_type = tvb_get_ntohl(tvb, foffset);
3266 switch (resource_type)
3268 case 0: /* Print Drivers */
3269 proto_tree_add_item(ndps_tree, hf_os_type, tvb, foffset, 4, FALSE);
3271 foffset = ndps_string(tvb, hf_ndps_prn_dir_name, ndps_tree, foffset);
3272 foffset = ndps_string(tvb, hf_ndps_prn_file_name, ndps_tree, foffset);
3274 case 1: /* Printer Definitions */
3275 foffset = ndps_string(tvb, hf_ndps_vendor_dir, ndps_tree, foffset);
3276 foffset = ndps_string(tvb, hf_ndps_prn_file_name, ndps_tree, foffset);
3278 case 2: /* Banner Page Files */
3279 foffset = ndps_string(tvb, hf_ndps_banner_name, ndps_tree, foffset);
3281 case 3: /* Font Types */
3282 proto_tree_add_item(ndps_tree, hf_os_type, tvb, foffset, 4, FALSE);
3284 proto_tree_add_item(ndps_tree, hf_font_type, tvb, foffset, 4, FALSE);
3286 foffset = ndps_string(tvb, hf_ndps_prn_file_name, ndps_tree, foffset);
3288 case 4: /* Generic Files/ Archive */
3289 case 5: /* Printer Driver Archive */
3290 proto_tree_add_item(ndps_tree, hf_os_type, tvb, foffset, 4, FALSE);
3292 foffset = ndps_string(tvb, hf_ndps_prn_dir_name, ndps_tree, foffset);
3293 proto_tree_add_item(ndps_tree, hf_archive_type, tvb, foffset, 4, FALSE);
3303 static const fragment_items ndps_frag_items = {
3308 &hf_ndps_segment_overlap,
3309 &hf_ndps_segment_overlap_conflict,
3310 &hf_ndps_segment_multiple_tails,
3311 &hf_ndps_segment_too_long_segment,
3312 &hf_ndps_segment_error,
3317 static dissector_handle_t ndps_data_handle;
3319 /* NDPS packets come in request/reply pairs. The request packets tell the
3320 * Function and Program numbers. The response, unfortunately, only
3321 * identifies itself via the Exchange ID; you have to know what type of NDPS
3322 * request the request packet contained in order to successfully parse the
3323 * response. A global method for doing this does not exist in ethereal yet
3324 * (NFS also requires it), so for now the NDPS section will keep its own hash
3325 * table keeping track of NDPS packets.
3327 * We construct a conversation specified by the client and server
3328 * addresses and the connection number; the key representing the unique
3329 * NDPS request then is composed of the pointer to the conversation
3330 * structure, cast to a "guint" (which may throw away the upper 32
3331 * bits of the pointer on a P64 platform, but the low-order 32 bits
3332 * are more likely to differ between conversations than the upper 32 bits),
3333 * and the sequence number.
3335 * The value stored in the hash table is the ncp_req_hash_value pointer. This
3336 * struct tells us the NDPS Program and Function and gives the NDPS_record pointer.
3339 conversation_t *conversation;
3341 } ndps_req_hash_key;
3346 guint32 ndps_frame_num;
3347 } ndps_req_hash_value;
3349 static GHashTable *ndps_req_hash = NULL;
3350 static GMemChunk *ndps_req_hash_keys = NULL;
3351 static GMemChunk *ndps_req_hash_values = NULL;
3353 /* Hash Functions */
3355 ndps_equal(gconstpointer v, gconstpointer v2)
3357 const ndps_req_hash_key *val1 = (const ndps_req_hash_key*)v;
3358 const ndps_req_hash_key *val2 = (const ndps_req_hash_key*)v2;
3360 if (val1->conversation == val2->conversation &&
3361 val1->ndps_xport == val2->ndps_xport ) {
3368 ndps_hash(gconstpointer v)
3370 const ndps_req_hash_key *ndps_key = (const ndps_req_hash_key*)v;
3371 return GPOINTER_TO_UINT(ndps_key->conversation) + ndps_key->ndps_xport;
3374 /* Initializes the hash table and the mem_chunk area each time a new
3375 * file is loaded or re-loaded in ethereal */
3377 ndps_init_protocol(void)
3380 fragment_table_init(&ndps_fragment_table);
3381 reassembled_table_init(&ndps_reassembled_table);
3384 g_hash_table_destroy(ndps_req_hash);
3385 if (ndps_req_hash_keys)
3386 g_mem_chunk_destroy(ndps_req_hash_keys);
3387 if (ndps_req_hash_values)
3388 g_mem_chunk_destroy(ndps_req_hash_values);
3390 ndps_req_hash = g_hash_table_new(ndps_hash, ndps_equal);
3391 ndps_req_hash_keys = g_mem_chunk_new("ndps_req_hash_keys",
3392 sizeof(ndps_req_hash_key),
3393 NDPS_PACKET_INIT_COUNT * sizeof(ndps_req_hash_key),
3395 ndps_req_hash_values = g_mem_chunk_new("ndps_req_hash_values",
3396 sizeof(ndps_req_hash_value),
3397 NDPS_PACKET_INIT_COUNT * sizeof(ndps_req_hash_value),
3401 /* After the sequential run, we don't need the ncp_request hash and keys
3402 * anymore; the lookups have already been done and the vital info
3403 * saved in the reply-packets' private_data in the frame_data struct. */
3405 ndps_postseq_cleanup(void)
3407 if (ndps_req_hash) {
3408 /* Destroy the hash, but don't clean up request_condition data. */
3409 g_hash_table_destroy(ndps_req_hash);
3410 ndps_req_hash = NULL;
3412 if (ndps_req_hash_keys) {
3413 g_mem_chunk_destroy(ndps_req_hash_keys);
3414 ndps_req_hash_keys = NULL;
3416 /* Don't free the ncp_req_hash_values, as they're
3417 * needed during random-access processing of the proto_tree.*/
3420 ndps_req_hash_value*
3421 ndps_hash_insert(conversation_t *conversation, guint32 ndps_xport)
3423 ndps_req_hash_key *request_key;
3424 ndps_req_hash_value *request_value;
3426 /* Now remember the request, so we can find it if we later
3428 request_key = g_mem_chunk_alloc(ndps_req_hash_keys);
3429 request_key->conversation = conversation;
3430 request_key->ndps_xport = ndps_xport;
3432 request_value = g_mem_chunk_alloc(ndps_req_hash_values);
3433 request_value->ndps_prog = 0;
3434 request_value->ndps_func = 0;
3435 request_value->ndps_frame_num = 0;
3437 g_hash_table_insert(ndps_req_hash, request_key, request_value);
3439 return request_value;
3442 /* Returns the ncp_rec*, or NULL if not found. */
3443 ndps_req_hash_value*
3444 ndps_hash_lookup(conversation_t *conversation, guint32 ndps_xport)
3446 ndps_req_hash_key request_key;
3448 request_key.conversation = conversation;
3449 request_key.ndps_xport = ndps_xport;
3451 return g_hash_table_lookup(ndps_req_hash, &request_key);
3454 /* ================================================================= */
3456 /* ================================================================= */
3459 dissect_ndps(tvbuff_t *tvb, packet_info *pinfo, proto_tree *ndps_tree)
3463 guint32 ndps_packet_type;
3464 guint32 ndps_rpc_version;
3466 guint32 ndps_hfname;
3468 const char *ndps_program_string;
3469 const char *ndps_func_string;
3472 ndps_packet_type = tvb_get_ntohl(tvb, 8);
3473 if (ndps_packet_type != 0 && ndps_packet_type != 1) { /* Packet Type */
3474 if (check_col(pinfo->cinfo, COL_INFO))
3475 col_set_str(pinfo->cinfo, COL_INFO, "(Continuation Data)");
3476 proto_tree_add_text(ndps_tree, tvb, 0, tvb_length_remaining(tvb, 0), "Data - (%d Bytes)", tvb_length_remaining(tvb, 0));
3480 proto_tree_add_item(ndps_tree, hf_ndps_record_mark, tvb,
3483 proto_tree_add_item(ndps_tree, hf_ndps_length, tvb,
3487 ndps_xid = tvb_get_ntohl(tvb, foffset);
3488 proto_tree_add_uint(ndps_tree, hf_ndps_xid, tvb, foffset, 4, ndps_xid);
3490 ndps_packet_type = tvb_get_ntohl(tvb, foffset);
3491 proto_tree_add_uint(ndps_tree, hf_ndps_packet_type, tvb, foffset, 4, ndps_packet_type);
3493 if(ndps_packet_type == 0x00000001) /* Reply packet */
3495 if (check_col(pinfo->cinfo, COL_INFO))
3496 col_set_str(pinfo->cinfo, COL_INFO, "R NDPS ");
3497 proto_tree_add_item(ndps_tree, hf_ndps_rpc_accept, tvb, foffset, 4, FALSE);
3498 if (tvb_get_ntohl(tvb, foffset)==0) {
3500 proto_tree_add_item(ndps_tree, hf_ndps_auth_null, tvb, foffset, 8, FALSE);
3506 proto_tree_add_item(ndps_tree, hf_ndps_rpc_rej_stat, tvb, foffset+4, 4, FALSE);
3509 dissect_ndps_reply(tvb, pinfo, ndps_tree, foffset);
3513 if (check_col(pinfo->cinfo, COL_INFO))
3514 col_set_str(pinfo->cinfo, COL_INFO, "C NDPS ");
3515 ndps_rpc_version = tvb_get_ntohl(tvb, foffset);
3516 proto_tree_add_item(ndps_tree, hf_ndps_rpc_version, tvb, foffset, 4, FALSE);
3518 ndps_prog = tvb_get_ntohl(tvb, foffset);
3519 ndps_program_string = match_strval(ndps_prog, spx_ndps_program_vals);
3520 if( ndps_program_string != NULL)
3522 proto_tree_add_item(ndps_tree, hf_spx_ndps_program, tvb, foffset, 4, FALSE);
3524 if (check_col(pinfo->cinfo, COL_INFO))
3526 col_append_str(pinfo->cinfo, COL_INFO, (const gchar*) ndps_program_string);
3527 col_append_str(pinfo->cinfo, COL_INFO, ", ");
3529 proto_tree_add_item(ndps_tree, hf_spx_ndps_version, tvb, foffset, 4, FALSE);
3531 ndps_func = tvb_get_ntohl(tvb, foffset);
3535 ndps_hfname = hf_spx_ndps_func_print;
3536 ndps_func_string = match_strval(ndps_func, spx_ndps_print_func_vals);
3539 ndps_hfname = hf_spx_ndps_func_broker;
3540 ndps_func_string = match_strval(ndps_func, spx_ndps_broker_func_vals);
3543 ndps_hfname = hf_spx_ndps_func_registry;
3544 ndps_func_string = match_strval(ndps_func, spx_ndps_registry_func_vals);
3547 ndps_hfname = hf_spx_ndps_func_notify;
3548 ndps_func_string = match_strval(ndps_func, spx_ndps_notify_func_vals);
3551 ndps_hfname = hf_spx_ndps_func_resman;
3552 ndps_func_string = match_strval(ndps_func, spx_ndps_resman_func_vals);
3555 ndps_hfname = hf_spx_ndps_func_delivery;
3556 ndps_func_string = match_strval(ndps_func, spx_ndps_deliver_func_vals);
3560 ndps_func_string = NULL;
3563 if(ndps_hfname != 0)
3565 proto_tree_add_item(ndps_tree, ndps_hfname, tvb, foffset, 4, FALSE);
3566 if (ndps_func_string != NULL)
3568 if (check_col(pinfo->cinfo, COL_INFO))
3569 col_append_str(pinfo->cinfo, COL_INFO, (const gchar*) ndps_func_string);
3572 proto_tree_add_item(ndps_tree, hf_ndps_auth_null, tvb, foffset, 16, FALSE);
3574 dissect_ndps_request(tvb, pinfo, ndps_tree, ndps_prog, ndps_func, foffset);
3582 get_ndps_pdu_len(tvbuff_t *tvb, int offset)
3587 * Get the length of the NDPS packet.
3589 plen = tvb_get_ntohs(tvb, offset + 2);
3592 * That length doesn't include the length of the record mark field
3593 * or the length field itself; add that in.
3594 * (XXX - is the field really a 31-bit length with the uppermost bit
3595 * being a record mark bit?)
3601 dissect_ndps_pdu(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
3603 proto_tree *ndps_tree = NULL;
3606 if (check_col(pinfo->cinfo, COL_PROTOCOL))
3607 col_set_str(pinfo->cinfo, COL_PROTOCOL, "NDPS");
3609 if (check_col(pinfo->cinfo, COL_INFO))
3610 col_clear(pinfo->cinfo, COL_INFO);
3613 ti = proto_tree_add_item(tree, proto_ndps, tvb, 0, -1, FALSE);
3614 ndps_tree = proto_item_add_subtree(ti, ett_ndps);
3616 dissect_ndps(tvb, pinfo, ndps_tree);
3620 ndps_defrag(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
3622 guint16 record_mark=0;
3623 guint16 ndps_length=0;
3625 tvbuff_t *next_tvb = NULL;
3626 fragment_data *fd_head;
3629 spx_info = pinfo->private_data;
3630 if (!ndps_defragment) {
3631 dissect_ndps(tvb, pinfo, tree);
3634 record_mark = tvb_get_ntohs(tvb, 0);
3635 ndps_length = tvb_get_ntohs(tvb, 2);
3636 if (ndps_length > tvb_length_remaining(tvb, 0) || ndps_fragmented || ndps_length==0)
3638 more_fragment = TRUE;
3639 ndps_fragmented = TRUE;
3644 tid = (pinfo->srcport+pinfo->destport);
3645 len = tvb_reported_length_remaining(tvb, 0);
3646 if ((frag_number + tvb_length_remaining(tvb, 0)-save_frag_length)<=10)
3648 more_fragment = FALSE;
3650 if (tvb_bytes_exist(tvb, 0, len))
3652 fd_head = fragment_add_seq_next(tvb, 0, pinfo, tid, ndps_fragment_table, ndps_reassembled_table, len, more_fragment);
3653 if (fd_head != NULL)
3655 if (fd_head->next != NULL)
3657 next_tvb = tvb_new_real_data(fd_head->data,
3658 fd_head->len, fd_head->len);
3659 tvb_set_child_real_data_tvbuff(tvb,
3661 add_new_data_source(pinfo,
3663 "Reassembled NDPS");
3664 /* Show all fragments. */
3667 show_fragment_seq_tree(fd_head,
3673 more_fragment = FALSE;
3674 save_frag_length = 0;
3676 ndps_fragmented=FALSE;
3680 next_tvb = tvb_new_subset(tvb, 0, -1, -1);
3685 if (save_frag_length == 0)
3687 save_frag_length = ndps_length; /* First Fragment */
3688 save_frag_seq = tid;
3690 if ((pinfo->srcport+pinfo->destport) == save_frag_seq)
3692 if (!pinfo->fd->flags.visited)
3694 frag_number += tvb_length_remaining(tvb, 0); /* Current offset */
3696 if (check_col(pinfo->cinfo, COL_INFO))
3700 col_append_fstr(pinfo->cinfo, COL_INFO, " [NDPS Fragment]");
3712 next_tvb = tvb_new_subset(tvb, 0, -1, -1);
3714 if (next_tvb == NULL)
3716 if ((pinfo->srcport+pinfo->destport) == save_frag_seq)
3718 next_tvb = tvb_new_subset (tvb, 0, -1, -1);
3719 call_dissector(ndps_data_handle, next_tvb, pinfo, tree);
3725 ndps_fragmented=FALSE;
3727 dissect_ndps(tvb, pinfo, tree);
3734 ndps_fragmented=FALSE;
3736 dissect_ndps(next_tvb, pinfo, tree);
3743 ndps_fragmented=FALSE;
3745 dissect_ndps(tvb, pinfo, tree);
3750 dissect_ndps_tcp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
3752 tcp_dissect_pdus(tvb, pinfo, tree, ndps_desegment, 4, get_ndps_pdu_len,
3758 dissect_ndps_ipx(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
3760 proto_tree *ndps_tree = NULL;
3763 if (check_col(pinfo->cinfo, COL_PROTOCOL))
3764 col_set_str(pinfo->cinfo, COL_PROTOCOL, "NDPS");
3766 if (check_col(pinfo->cinfo, COL_INFO))
3767 col_clear(pinfo->cinfo, COL_INFO);
3770 ti = proto_tree_add_item(tree, proto_ndps, tvb, 0, -1, FALSE);
3771 ndps_tree = proto_item_add_subtree(ti, ett_ndps);
3773 ndps_defrag(tvb, pinfo, ndps_tree);
3777 dissect_ndps_request(tvbuff_t *tvb, packet_info *pinfo, proto_tree *ndps_tree, guint32 ndps_prog, guint32 ndps_func, int foffset)
3779 ndps_req_hash_value *request_value = NULL;
3780 conversation_t *conversation;
3783 guint32 field_len=0;
3784 guint32 cred_type=0;
3785 guint32 resource_type=0;
3786 guint32 filter_type=0;
3787 guint32 print_type=0;
3789 guint32 number_of_items=0;
3790 guint32 number_of_items2=0;
3800 if (!pinfo->fd->flags.visited)
3803 /* This is the first time we've looked at this packet.
3804 Keep track of the Program and connection whence the request
3805 came, and the address and connection to which the request
3806 is being sent, so that we can match up calls with replies.
3807 (We don't include the sequence number, as we may want
3808 to have all packets over the same connection treated
3809 as being part of a single conversation so that we can
3810 let the user select that conversation to be displayed.) */
3812 conversation = find_conversation(&pinfo->src, &pinfo->dst,
3813 PT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->srcport, 0);
3815 if (conversation == NULL)
3817 /* It's not part of any conversation - create a new one. */
3818 conversation = conversation_new(&pinfo->src, &pinfo->dst,
3819 PT_NCP, (guint32) pinfo->srcport, (guint32) pinfo->srcport, 0);
3822 request_value = ndps_hash_insert(conversation, (guint32) pinfo->srcport);
3823 request_value->ndps_prog = ndps_prog;
3824 request_value->ndps_func = ndps_func;
3825 request_value->ndps_frame_num = pinfo->fd->num;
3829 case 0x060976: /* Print */
3832 case 0x00000001: /* Bind PSM */
3833 foffset = credentials(tvb, ndps_tree, foffset);
3835 case 0x00000002: /* Bind PA */
3836 foffset = credentials(tvb, ndps_tree, foffset);
3837 proto_tree_add_item(ndps_tree, hf_ndps_retrieve_restrictions, tvb, foffset, 4, FALSE);
3839 number_of_items=tvb_get_ntohl(tvb, foffset);
3841 for (i = 1 ; i <= number_of_items; i++ )
3843 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Security %d", i);
3844 atree = proto_item_add_subtree(aitem, ett_ndps);
3845 length = tvb_get_ntohl(tvb, foffset);
3847 proto_tree_add_item(atree, hf_bind_security, tvb, foffset, length, FALSE);
3849 foffset = qualifiedname(tvb, ndps_tree, foffset);
3851 case 0x00000003: /* Unbind */
3852 proto_tree_add_item(ndps_tree, hf_ndps_object, tvb, foffset,
3855 case 0x00000004: /* Print */
3856 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
3858 proto_tree_add_item(ndps_tree, hf_print_arg, tvb, foffset, 4, FALSE);
3859 print_type = tvb_get_ntohl(tvb, foffset);
3863 case 0: /* Create Job */
3864 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
3865 proto_tree_add_item(ndps_tree, hf_sub_complete, tvb, foffset, 4, FALSE);
3867 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Transfer Method");
3868 atree = proto_item_add_subtree(aitem, ett_ndps);
3869 number_of_items = tvb_get_ntohl(tvb, foffset);
3871 for (i = 1 ; i <= number_of_items; i++ )
3873 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Attribute %d", i);
3874 btree = proto_item_add_subtree(bitem, ett_ndps);
3875 foffset = objectidentifier(tvb, btree, foffset);
3876 number_of_items2 = tvb_get_ntohl(tvb, foffset);
3878 for (j = 1 ; j <= number_of_items2; j++ )
3880 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Value %d", j);
3881 ctree = proto_item_add_subtree(citem, ett_ndps);
3882 foffset = attribute_value(tvb, ctree, foffset);
3884 proto_tree_add_item(btree, hf_ndps_qualifier, tvb, foffset, 4, FALSE);
3887 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Document Content");
3888 atree = proto_item_add_subtree(aitem, ett_ndps);
3889 number_of_items = tvb_get_ntohl(tvb, foffset);
3891 for (i = 1 ; i <= number_of_items; i++ )
3893 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Type %d", i);
3894 btree = proto_item_add_subtree(bitem, ett_ndps);
3895 foffset = objectidentifier(tvb, btree, foffset);
3897 foffset += align_4(tvb, foffset);
3898 number_of_items = tvb_get_ntohl(tvb, foffset);
3900 proto_tree_add_item(atree, hf_doc_content, tvb, foffset, 4, FALSE);
3902 for (i = 1 ; i <= number_of_items; i++ )
3904 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Value %d", i);
3905 btree = proto_item_add_subtree(bitem, ett_ndps);
3906 if (tvb_get_ntohl(tvb, foffset-4)==0)
3908 if (tvb_get_ntohl(tvb, foffset) > tvb_length_remaining(tvb, foffset)) /* Segmented Data */
3910 proto_tree_add_item(btree, hf_ndps_data, tvb, foffset, tvb_length_remaining(tvb, foffset), FALSE);
3913 proto_tree_add_item(btree, hf_ndps_included_doc, tvb, foffset+4, tvb_get_ntohl(tvb, foffset), FALSE);
3914 foffset += tvb_get_ntohl(tvb, foffset)+4;
3915 foffset += (length%2);
3919 foffset = ndps_string(tvb, hf_ndps_ref_name, btree, foffset);
3920 foffset = name_or_id(tvb, btree, foffset);
3924 if (align_4(tvb, foffset)>0) {
3925 foffset += align_4(tvb, foffset);
3928 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Document Type");
3929 number_of_items = tvb_get_ntohl(tvb, foffset);
3930 atree = proto_item_add_subtree(aitem, ett_ndps);
3932 for (i = 1 ; i <= number_of_items; i++ )
3934 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Attribute %d", i);
3935 btree = proto_item_add_subtree(bitem, ett_ndps);
3936 foffset = objectidentifier(tvb, btree, foffset);
3937 number_of_items2 = tvb_get_ntohl(tvb, foffset);
3939 for (j = 1 ; j <= number_of_items2; j++ )
3941 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Value %d", j);
3942 ctree = proto_item_add_subtree(citem, ett_ndps);
3943 foffset = attribute_value(tvb, ctree, foffset);
3945 proto_tree_add_item(btree, hf_ndps_qualifier, tvb, foffset, 4, FALSE);
3948 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Document Attributes");
3949 number_of_items = tvb_get_ntohl(tvb, foffset);
3950 atree = proto_item_add_subtree(aitem, ett_ndps);
3952 for (i = 1 ; i <= number_of_items; i++ )
3954 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Attribute %d", i);
3955 btree = proto_item_add_subtree(bitem, ett_ndps);
3956 foffset = attribute_value(tvb, btree, foffset); /* Document Attributes */
3959 case 1: /* Add Job */
3960 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
3961 proto_tree_add_item(ndps_tree, hf_local_id, tvb, foffset, 4, FALSE);
3963 proto_tree_add_item(ndps_tree, hf_sub_complete, tvb, foffset, 4, FALSE);
3965 number_of_items = tvb_get_ntohl(tvb, foffset);
3966 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Transfer Method");
3967 atree = proto_item_add_subtree(aitem, ett_ndps);
3969 for (i = 1 ; i <= number_of_items; i++ )
3971 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Method %d", i);
3972 btree = proto_item_add_subtree(bitem, ett_ndps);
3973 foffset = objectidentifier(tvb, btree, foffset); /* Transfer Method */
3975 proto_tree_add_item(ndps_tree, hf_doc_content, tvb, foffset, 4, FALSE);
3977 number_of_items = tvb_get_ntohl(tvb, foffset);
3978 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Document Type");
3979 atree = proto_item_add_subtree(aitem, ett_ndps);
3981 for (i = 1 ; i <= number_of_items; i++ )
3983 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Type %d", i);
3984 btree = proto_item_add_subtree(bitem, ett_ndps);
3985 foffset = objectidentifier(tvb, btree, foffset); /* Document Type */
3987 foffset += align_4(tvb, foffset);
3988 number_of_items = tvb_get_ntohl(tvb, foffset);
3989 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Document Attributes");
3990 atree = proto_item_add_subtree(aitem, ett_ndps);
3992 for (i = 1 ; i <= number_of_items; i++ )
3994 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Attribute %d", i);
3995 btree = proto_item_add_subtree(bitem, ett_ndps);
3996 foffset = attribute_value(tvb, btree, foffset); /* Document Attributes */
3999 case 2: /* Close Job */
4000 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
4001 proto_tree_add_item(ndps_tree, hf_local_id, tvb, foffset, 4, FALSE);
4008 case 0x00000005: /* Modify Job */
4009 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4011 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
4012 proto_tree_add_item(ndps_tree, hf_local_id, tvb, foffset, 4, FALSE);
4014 proto_tree_add_item(ndps_tree, hf_ndps_document_number, tvb, foffset, 4, FALSE);
4016 number_of_items = tvb_get_ntohl(tvb, foffset);
4017 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Job Modifications");
4018 atree = proto_item_add_subtree(aitem, ett_ndps);
4020 for (i = 1 ; i <= number_of_items; i++ )
4022 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Modification %d", i);
4023 btree = proto_item_add_subtree(bitem, ett_ndps);
4024 foffset = attribute_value(tvb, btree, foffset); /* Job Modifications */
4026 number_of_items = tvb_get_ntohl(tvb, foffset);
4027 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Document Modifications");
4028 atree = proto_item_add_subtree(aitem, ett_ndps);
4030 for (i = 1 ; i <= number_of_items; i++ )
4032 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Modification %d", i);
4033 btree = proto_item_add_subtree(bitem, ett_ndps);
4034 foffset = attribute_value(tvb, btree, foffset); /* Document Modifications */
4037 case 0x00000006: /* Cancel Job */
4038 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4040 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
4041 proto_tree_add_item(ndps_tree, hf_local_id, tvb, foffset, 4, FALSE);
4043 proto_tree_add_item(ndps_tree, hf_ndps_document_number, tvb, foffset, 4, FALSE);
4045 number_of_items = tvb_get_ntohl(tvb, foffset);
4046 /* Start of nameorid */
4047 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Cancel Message");
4048 atree = proto_item_add_subtree(aitem, ett_ndps);
4049 foffset = name_or_id(tvb, atree, foffset);
4050 /* End of nameorid */
4051 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Retention Period");
4052 atree = proto_item_add_subtree(aitem, ett_ndps);
4053 proto_tree_add_item(atree, hf_ndps_status_flags, tvb, foffset, 4, FALSE);
4055 proto_tree_add_item(atree, hf_ndps_attribute_value, tvb, foffset, 4, FALSE);
4059 case 0x00000007: /* List Object Attributes */
4060 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4062 proto_tree_add_item(ndps_tree, hf_ndps_attrs_arg, tvb, foffset, 4, FALSE);
4064 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Continuation */
4066 length = tvb_get_ntohl(tvb, foffset);
4067 proto_tree_add_item(ndps_tree, hf_ndps_context, tvb, foffset, length, FALSE);
4069 foffset += (length%2);
4070 proto_tree_add_item(ndps_tree, hf_ndps_abort_flag, tvb, foffset, 4, FALSE);
4072 number_of_items = tvb_get_ntohl(tvb, foffset);
4074 for (i = 1 ; i <= number_of_items; i++ )
4076 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Attribute %d", i);
4077 atree = proto_item_add_subtree(aitem, ett_ndps);
4078 foffset = attribute_value(tvb, atree, foffset);
4081 else /* Specification */
4083 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object Class");
4084 atree = proto_item_add_subtree(aitem, ett_ndps);
4085 foffset = objectidentifier(tvb, atree, foffset);
4087 foffset += align_4(tvb, foffset);
4088 proto_tree_add_item(ndps_tree, hf_ndps_scope, tvb, foffset, 4, FALSE);
4090 if (tvb_get_ntohl(tvb, foffset-4)!=0) /* Scope Does not equal 0 */
4092 number_of_items = tvb_get_ntohl(tvb, foffset); /* Start of NWDPSelector */
4093 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Selector Option");
4094 atree = proto_item_add_subtree(aitem, ett_ndps);
4096 for (i = 1 ; i <= number_of_items; i++ )
4098 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Option %d", i);
4099 btree = proto_item_add_subtree(bitem, ett_ndps);
4100 foffset = objectidentification(tvb, btree, foffset);
4102 foffset += align_4(tvb, foffset);
4103 proto_tree_add_item(ndps_tree, hf_ndps_filter, tvb, foffset, 4, FALSE);
4104 filter_type = tvb_get_ntohl(tvb, foffset);
4106 /*if (filter_type == 0 || filter_type == 3 )
4108 foffset = filteritem(tvb, ndps_tree, foffset);
4112 aitem = proto_tree_add_item(ndps_tree, hf_ndps_item_count, tvb, foffset, 4, FALSE);
4113 atree = proto_item_add_subtree(aitem, ett_ndps);
4114 number_of_items = tvb_get_ntohl(tvb, foffset);
4116 for (i = 1 ; i <= number_of_items; i++ )
4118 foffset = filteritem(tvb, ndps_tree, foffset);
4121 proto_tree_add_item(ndps_tree, hf_ndps_time_limit, tvb, foffset, 4, FALSE);
4123 proto_tree_add_item(ndps_tree, hf_ndps_count_limit, tvb, foffset, 4, FALSE);
4124 foffset += 4; /* End of NWDPSelector */
4126 foffset += 4; /* Don't know what this is */
4127 number_of_items = tvb_get_ntohl(tvb, foffset); /* Start of NWDPObjectIdentifierSet */
4128 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Requested Attributes");
4129 atree = proto_item_add_subtree(aitem, ett_ndps);
4131 for (i = 1 ; i <= number_of_items; i++ )
4133 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Attribute %d", i);
4134 btree = proto_item_add_subtree(bitem, ett_ndps);
4135 foffset = objectidentifier(tvb, btree, foffset);
4136 } /* End of NWDPObjectIdentifierSet */
4137 if (number_of_items == 0)
4141 proto_tree_add_item(ndps_tree, hf_ndps_operator, tvb, foffset, 4, FALSE);
4143 foffset = commonarguments(tvb, ndps_tree, foffset);
4146 case 0x00000008: /* Promote Job */
4147 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4149 /* Start of NWDPPrtContainedObjectId */
4150 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Job ID");
4151 atree = proto_item_add_subtree(aitem, ett_ndps);
4152 foffset = ndps_string(tvb, hf_ndps_pa_name, atree, foffset);
4153 proto_tree_add_item(atree, hf_local_id, tvb, foffset, 4, FALSE);
4155 /* End of NWDPPrtContainedObjectId */
4156 /* Start of nameorid */
4157 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Message Option");
4158 atree = proto_item_add_subtree(aitem, ett_ndps);
4159 foffset = name_or_id(tvb, atree, foffset);
4160 /* End of nameorid */
4161 foffset = commonarguments(tvb, ndps_tree, foffset);
4163 case 0x00000009: /* Interrupt */
4164 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4166 proto_tree_add_item(ndps_tree, hf_interrupt_job_type, tvb, foffset, 4, FALSE);
4168 if (tvb_get_ntohl(tvb, foffset-4)==0)
4170 /* Start of NWDPPrtContainedObjectId */
4171 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Job ID");
4172 atree = proto_item_add_subtree(aitem, ett_ndps);
4173 foffset = ndps_string(tvb, hf_ndps_pa_name, atree, foffset);
4174 proto_tree_add_item(atree, hf_local_id, tvb, foffset, 4, FALSE);
4176 /* End of NWDPPrtContainedObjectId */
4180 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
4182 /* Start of nameorid */
4183 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Interrupt Message Option");
4184 atree = proto_item_add_subtree(aitem, ett_ndps);
4185 foffset = name_or_id(tvb, atree, foffset);
4186 /* End of nameorid */
4187 /* Start of NWDPPrtContainedObjectId */
4188 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Interrupting Job");
4189 atree = proto_item_add_subtree(aitem, ett_ndps);
4190 foffset = ndps_string(tvb, hf_ndps_pa_name, atree, foffset);
4191 proto_tree_add_item(atree, hf_local_id, tvb, foffset, 4, FALSE);
4193 /* End of NWDPPrtContainedObjectId */
4194 foffset = commonarguments(tvb, ndps_tree, foffset);
4196 case 0x0000000a: /* Pause */
4197 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4199 proto_tree_add_item(ndps_tree, hf_pause_job_type, tvb, foffset, 4, FALSE);
4201 if (tvb_get_ntohl(tvb, foffset-4)==0)
4203 /* Start of NWDPPrtContainedObjectId */
4204 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Job ID");
4205 atree = proto_item_add_subtree(aitem, ett_ndps);
4206 foffset = ndps_string(tvb, hf_ndps_pa_name, atree, foffset);
4207 proto_tree_add_item(atree, hf_local_id, tvb, foffset, 4, FALSE);
4209 /* End of NWDPPrtContainedObjectId */
4213 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
4215 /* Start of nameorid */
4216 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Pause Message Option");
4217 atree = proto_item_add_subtree(aitem, ett_ndps);
4218 foffset = name_or_id(tvb, atree, foffset);
4219 /* End of nameorid */
4220 foffset = commonarguments(tvb, ndps_tree, foffset);
4222 case 0x0000000b: /* Resume */
4223 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4225 /* Start of NWDPPrtContainedObjectId */
4226 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Job ID");
4227 atree = proto_item_add_subtree(aitem, ett_ndps);
4228 foffset = ndps_string(tvb, hf_ndps_pa_name, atree, foffset);
4229 proto_tree_add_item(atree, hf_local_id, tvb, foffset, 4, FALSE);
4231 /* End of NWDPPrtContainedObjectId */
4232 /* Start of nameorid */
4233 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Resume Message Option");
4234 atree = proto_item_add_subtree(aitem, ett_ndps);
4235 foffset = name_or_id(tvb, atree, foffset);
4236 /* End of nameorid */
4237 foffset = commonarguments(tvb, ndps_tree, foffset);
4239 case 0x0000000c: /* Clean */
4240 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4242 /* Start of nameorid */
4243 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Clean Message Option");
4244 atree = proto_item_add_subtree(aitem, ett_ndps);
4245 foffset = name_or_id(tvb, atree, foffset);
4246 /* End of nameorid */
4247 foffset = commonarguments(tvb, ndps_tree, foffset);
4249 case 0x0000000d: /* Create */
4250 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4252 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object Class");
4253 atree = proto_item_add_subtree(aitem, ett_ndps);
4254 foffset = objectidentifier(tvb, atree, foffset);
4255 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object ID");
4256 atree = proto_item_add_subtree(aitem, ett_ndps);
4257 foffset = objectidentification(tvb, atree, foffset);
4258 proto_tree_add_item(ndps_tree, hf_ndps_force, tvb, foffset, 4, FALSE);
4260 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Reference Object Option");
4261 atree = proto_item_add_subtree(aitem, ett_ndps);
4262 foffset = objectidentification(tvb, atree, foffset);
4263 /* Start of AttributeSet */
4264 number_of_items = tvb_get_ntohl(tvb, foffset);
4265 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object Attribute");
4266 atree = proto_item_add_subtree(aitem, ett_ndps);
4268 for (i = 1 ; i <= number_of_items; i++ )
4270 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Attribute %d", i);
4271 btree = proto_item_add_subtree(bitem, ett_ndps);
4272 foffset = attribute_value(tvb, btree, foffset); /* Object Attribute Set */
4274 /* End of AttributeSet */
4275 foffset = commonarguments(tvb, ndps_tree, foffset);
4277 case 0x0000000e: /* Delete */
4278 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4280 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object Class");
4281 atree = proto_item_add_subtree(aitem, ett_ndps);
4282 foffset = objectidentifier(tvb, atree, foffset);
4283 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object ID");
4284 atree = proto_item_add_subtree(aitem, ett_ndps);
4285 foffset = objectidentification(tvb, atree, foffset);
4286 foffset = commonarguments(tvb, ndps_tree, foffset);
4288 case 0x0000000f: /* Disable PA */
4289 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4291 /* Start of NameorID */
4292 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Disable PA Message Option");
4293 atree = proto_item_add_subtree(aitem, ett_ndps);
4294 foffset = name_or_id(tvb, atree, foffset);
4295 /* End of NameorID */
4296 foffset = commonarguments(tvb, ndps_tree, foffset);
4298 case 0x00000010: /* Enable PA */
4299 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4301 /* Start of NameorID */
4302 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Enable PA Message Option");
4303 atree = proto_item_add_subtree(aitem, ett_ndps);
4304 foffset = name_or_id(tvb, atree, foffset);
4305 /* End of NameorID */
4306 foffset = commonarguments(tvb, ndps_tree, foffset);
4308 case 0x00000011: /* Resubmit Jobs */
4309 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4311 foffset = qualifiedname(tvb, ndps_tree, foffset);
4312 foffset = address_item(tvb, ndps_tree, foffset);
4313 proto_tree_add_item(ndps_tree, hf_resubmit_op_type, tvb, foffset, 4, FALSE);
4315 number_of_items = tvb_get_ntohl(tvb, foffset); /* Start of ResubmitJob Set */
4316 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Resubmit Job");
4317 atree = proto_item_add_subtree(aitem, ett_ndps);
4318 proto_tree_add_item(atree, hf_ndps_item_count, tvb, foffset, 4, FALSE);
4320 for (i = 1 ; i <= number_of_items; i++ )
4322 /* Start of NWDPPrtContainedObjectId */
4323 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Job ID");
4324 btree = proto_item_add_subtree(bitem, ett_ndps);
4325 foffset = ndps_string(tvb, hf_ndps_pa_name, btree, foffset);
4326 proto_tree_add_item(btree, hf_local_id, tvb, foffset, 4, FALSE);
4328 /* End of NWDPPrtContainedObjectId */
4329 proto_tree_add_item(atree, hf_ndps_document_number, tvb, foffset, 4, FALSE);
4331 /* Start of AttributeSet */
4332 number_of_items = tvb_get_ntohl(tvb, foffset);
4333 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Job Attributes");
4334 btree = proto_item_add_subtree(bitem, ett_ndps);
4336 for (j = 1 ; j <= number_of_items; j++ )
4338 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Attribute %d", j);
4339 ctree = proto_item_add_subtree(citem, ett_ndps);
4340 foffset = attribute_value(tvb, ctree, foffset); /* Object Attribute Set */
4342 /* End of AttributeSet */
4343 /* Start of AttributeSet */
4344 number_of_items = tvb_get_ntohl(tvb, foffset);
4345 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Document Attributes");
4346 btree = proto_item_add_subtree(bitem, ett_ndps);
4348 for (j = 1 ; j <= number_of_items; j++ )
4350 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Attribute %d", j);
4351 ctree = proto_item_add_subtree(citem, ett_ndps);
4352 foffset = attribute_value(tvb, ctree, foffset); /* Object Attribute Set */
4354 /* End of AttributeSet */
4355 } /* End of ResubmitJob Set */
4356 /* Start of NameorID */
4357 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Resubmit Message Option");
4358 atree = proto_item_add_subtree(aitem, ett_ndps);
4359 foffset = name_or_id(tvb, atree, foffset);
4360 /* End of NameorID */
4361 foffset = commonarguments(tvb, ndps_tree, foffset);
4363 case 0x00000012: /* Set */
4364 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4366 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object Class");
4367 atree = proto_item_add_subtree(aitem, ett_ndps);
4368 foffset = objectidentifier(tvb, atree, foffset);
4369 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object ID");
4370 atree = proto_item_add_subtree(aitem, ett_ndps);
4371 foffset = objectidentification(tvb, atree, foffset);
4372 /* Start of AttributeSet */
4373 number_of_items = tvb_get_ntohl(tvb, foffset);
4374 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Attribute Modifications");
4375 atree = proto_item_add_subtree(aitem, ett_ndps);
4377 for (i = 1 ; i <= number_of_items; i++ )
4379 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Modification %d", i);
4380 btree = proto_item_add_subtree(bitem, ett_ndps);
4381 foffset = attribute_value(tvb, btree, foffset); /* Object Attribute Set */
4383 /* End of AttributeSet */
4384 foffset = commonarguments(tvb, ndps_tree, foffset);
4386 case 0x00000013: /* Shutdown PA */
4387 case 0x0000001e: /* Shutdown PSM */
4388 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4390 proto_tree_add_item(ndps_tree, hf_shutdown_type, tvb, foffset, 4, FALSE);
4392 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
4393 /* Start of NameorID */
4394 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Shutdown Message Option");
4395 atree = proto_item_add_subtree(aitem, ett_ndps);
4396 foffset = name_or_id(tvb, atree, foffset);
4397 /* End of NameorID */
4398 foffset = commonarguments(tvb, ndps_tree, foffset);
4399 case 0x00000014: /* Startup PA */
4400 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4402 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
4403 /* Start of NameorID */
4404 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Startup Message Option");
4405 atree = proto_item_add_subtree(aitem, ett_ndps);
4406 foffset = name_or_id(tvb, atree, foffset);
4407 /* End of NameorID */
4408 foffset = commonarguments(tvb, ndps_tree, foffset);
4410 case 0x00000015: /* Reorder Job */
4411 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4413 /* Start of NWDPPrtContainedObjectId */
4414 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Job Identification");
4415 atree = proto_item_add_subtree(aitem, ett_ndps);
4416 foffset = ndps_string(tvb, hf_ndps_pa_name, atree, foffset);
4417 proto_tree_add_item(atree, hf_local_id, tvb, foffset, 4, FALSE);
4419 /* End of NWDPPrtContainedObjectId */
4420 /* Start of NWDPPrtContainedObjectId */
4421 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Reference Job ID");
4422 atree = proto_item_add_subtree(aitem, ett_ndps);
4423 foffset = ndps_string(tvb, hf_ndps_pa_name, atree, foffset);
4424 proto_tree_add_item(atree, hf_local_id, tvb, foffset, 4, FALSE);
4426 /* End of NWDPPrtContainedObjectId */
4427 foffset = commonarguments(tvb, ndps_tree, foffset);
4429 case 0x00000016: /* Pause PA */
4430 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4432 /* Start of NameorID */
4433 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Pause Message Option");
4434 atree = proto_item_add_subtree(aitem, ett_ndps);
4435 foffset = name_or_id(tvb, atree, foffset);
4436 /* End of NameorID */
4437 foffset = commonarguments(tvb, ndps_tree, foffset);
4439 case 0x00000017: /* Resume PA */
4440 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4442 /* Start of NameorID */
4443 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Resume Message Option");
4444 atree = proto_item_add_subtree(aitem, ett_ndps);
4445 foffset = name_or_id(tvb, atree, foffset);
4446 /* End of NameorID */
4447 foffset = commonarguments(tvb, ndps_tree, foffset);
4449 case 0x00000018: /* Transfer Data */
4450 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4452 proto_tree_add_item(ndps_tree, hf_get_status_flag, tvb, foffset, 4, FALSE);
4454 proto_tree_add_item(ndps_tree, hf_ndps_data, tvb, foffset+4, tvb_get_ntohl(tvb, foffset), FALSE);
4456 case 0x00000019: /* Device Control */
4457 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4459 /* Start of Object Identifier */
4460 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Operation ID");
4461 atree = proto_item_add_subtree(aitem, ett_ndps);
4462 foffset = objectidentifier(tvb, atree, foffset);
4463 /* End of Object Identifier */
4464 foffset = commonarguments(tvb, ndps_tree, foffset);
4466 case 0x0000001a: /* Add Event Profile */
4467 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4469 /* Start of Eventhandling2 */
4470 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
4472 proto_tree_add_item(ndps_tree, hf_ndps_persistence, tvb, foffset, 4, FALSE);
4474 foffset = qualifiedname(tvb, ndps_tree, foffset);
4475 foffset = ndps_string(tvb, hf_ndps_supplier_name, ndps_tree, foffset);
4476 proto_tree_add_item(ndps_tree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
4478 /* Start of NameorID */
4479 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method ID");
4480 atree = proto_item_add_subtree(aitem, ett_ndps);
4481 foffset = name_or_id(tvb, atree, foffset);
4482 foffset += align_4(tvb, foffset);
4483 /* End of NameorID */
4484 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Delivery Address");
4485 atree = proto_item_add_subtree(aitem, ett_ndps);
4486 number_of_items = tvb_get_ntohl(tvb, foffset);
4488 for (i = 1 ; i <= number_of_items; i++ )
4490 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Address %d", i);
4491 btree = proto_item_add_subtree(bitem, ett_ndps);
4492 foffset = address_item(tvb, btree, foffset);
4494 foffset = event_object_set(tvb, ndps_tree, foffset);
4495 foffset = qualifiedname(tvb, ndps_tree, foffset);
4497 case 0x0000001b: /* Remove Event Profile */
4498 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4500 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
4503 case 0x0000001c: /* Modify Event Profile */
4504 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4506 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
4508 proto_tree_add_item(ndps_tree, hf_ndps_supplier_flag, tvb, foffset, 4, FALSE);
4510 if (tvb_get_ntohl(tvb, foffset-4)==TRUE)
4512 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Supplier ID");
4513 atree = proto_item_add_subtree(aitem, ett_ndps);
4514 length = tvb_get_ntohl(tvb, foffset);
4516 proto_tree_add_item(atree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
4519 aitem = proto_tree_add_item(ndps_tree, hf_ndps_language_flag, tvb, foffset, 4, FALSE);
4520 atree = proto_item_add_subtree(aitem, ett_ndps);
4522 if (tvb_get_ntohl(tvb, foffset-4)==TRUE)
4524 proto_tree_add_item(atree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
4527 aitem = proto_tree_add_item(ndps_tree, hf_ndps_method_flag, tvb, foffset, 4, FALSE);
4528 atree = proto_item_add_subtree(aitem, ett_ndps);
4530 if (tvb_get_ntohl(tvb, foffset-4)==TRUE)
4532 /* Start of NameorID */
4533 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Method ID");
4534 btree = proto_item_add_subtree(bitem, ett_ndps);
4535 foffset = name_or_id(tvb, btree, foffset);
4536 /* End of NameorID */
4538 aitem = proto_tree_add_item(ndps_tree, hf_ndps_delivery_address_flag, tvb, foffset, 4, FALSE);
4539 atree = proto_item_add_subtree(aitem, ett_ndps);
4541 if (tvb_get_ntohl(tvb, foffset-4)==TRUE)
4543 foffset = print_address(tvb, atree, foffset);
4545 foffset = event_object_set(tvb, ndps_tree, foffset);
4547 case 0x0000001d: /* List Event Profiles */
4548 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4550 proto_tree_add_item(ndps_tree, hf_ndps_list_profiles_type, tvb, foffset, 4, FALSE);
4552 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Spec */
4554 foffset = qualifiedname(tvb, ndps_tree, foffset);
4555 proto_tree_add_item(ndps_tree, hf_ndps_list_profiles_choice_type, tvb, foffset, 4, FALSE);
4557 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Choice */
4559 foffset = cardinal_seq(tvb, ndps_tree, foffset);
4563 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Consumer");
4564 atree = proto_item_add_subtree(aitem, ett_ndps);
4565 foffset = qualifiedname(tvb, atree, foffset);
4566 /* Start of NameorID */
4567 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method ID");
4568 atree = proto_item_add_subtree(aitem, ett_ndps);
4569 foffset = name_or_id(tvb, atree, foffset);
4570 /* End of NameorID */
4571 proto_tree_add_item(atree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
4574 proto_tree_add_item(ndps_tree, hf_ndps_list_profiles_result_type, tvb, foffset, 4, FALSE);
4576 /* Start of integeroption */
4577 proto_tree_add_item(ndps_tree, hf_ndps_integer_type_flag, tvb, foffset, 4, FALSE);
4579 if (tvb_get_ntohl(tvb, foffset-4)!=0)
4581 proto_tree_add_item(ndps_tree, hf_ndps_integer_type_value, tvb, foffset, 4, FALSE);
4584 /* End of integeroption */
4588 length = tvb_get_ntohl(tvb, foffset);
4589 proto_tree_add_item(ndps_tree, hf_ndps_context, tvb, foffset, length, FALSE);
4591 foffset += (length%2);
4592 proto_tree_add_item(ndps_tree, hf_ndps_abort_flag, tvb, foffset, 4, FALSE);
4596 case 0x0000001f: /* Cancel PSM Shutdown */
4597 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4599 /* Start of NameorID */
4600 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Cancel Shutdown Message Option");
4601 atree = proto_item_add_subtree(aitem, ett_ndps);
4602 foffset = name_or_id(tvb, atree, foffset);
4603 /* End of NameorID */
4604 foffset = commonarguments(tvb, ndps_tree, foffset);
4606 case 0x00000020: /* Set Printer DS Information */
4607 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4609 proto_tree_add_item(ndps_tree, hf_ndps_ds_info_type, tvb, foffset, 4, FALSE);
4611 foffset = ndps_string(tvb, hf_printer_name, ndps_tree, foffset);
4612 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "DS Object Name");
4613 atree = proto_item_add_subtree(aitem, ett_ndps);
4614 foffset = qualifiedname(tvb, atree, foffset);
4616 case 0x00000021: /* Clean User Jobs */
4617 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4619 /* Start of NameorID */
4620 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Clean Message Option");
4621 atree = proto_item_add_subtree(aitem, ett_ndps);
4622 foffset = name_or_id(tvb, atree, foffset);
4623 /* End of NameorID */
4624 foffset = commonarguments(tvb, ndps_tree, foffset);
4626 case 0x00000022: /* Map GUID to NDS Name */
4627 length = tvb_get_ntohl(tvb, foffset);
4629 proto_tree_add_item(ndps_tree, hf_ndps_guid, tvb, foffset, length, FALSE);
4632 case 0x00000023: /* AddEventProfile2 */
4633 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4635 /* Start of Eventhandling2 */
4636 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
4638 proto_tree_add_item(ndps_tree, hf_ndps_persistence, tvb, foffset, 4, FALSE);
4640 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Consumer Name");
4641 atree = proto_item_add_subtree(aitem, ett_ndps);
4642 foffset = qualifiedname(tvb, atree, foffset);
4643 foffset = ndps_string(tvb, hf_ndps_supplier_name, ndps_tree, foffset);
4644 proto_tree_add_item(ndps_tree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
4646 /* Start of NameorID */
4647 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method ID");
4648 atree = proto_item_add_subtree(aitem, ett_ndps);
4649 foffset = name_or_id(tvb, atree, foffset);
4650 foffset += align_4(tvb, foffset);
4651 /* End of NameorID */
4652 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Delivery Address");
4653 atree = proto_item_add_subtree(aitem, ett_ndps);
4654 number_of_items = tvb_get_ntohl(tvb, foffset);
4656 for (i = 1 ; i <= number_of_items; i++ )
4658 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Address %d", i);
4659 btree = proto_item_add_subtree(bitem, ett_ndps);
4660 foffset = address_item(tvb, btree, foffset);
4662 foffset = event_object_set(tvb, ndps_tree, foffset);
4663 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Account");
4664 atree = proto_item_add_subtree(aitem, ett_ndps);
4665 foffset = qualifiedname(tvb, atree, foffset);
4666 /* Start of object identifier set */
4667 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Notify Attributes");
4668 atree = proto_item_add_subtree(aitem, ett_ndps);
4669 number_of_items = tvb_get_ntohl(tvb, foffset);
4671 for (i = 1 ; i <= number_of_items; i++ )
4673 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Attribute %d", i);
4674 btree = proto_item_add_subtree(bitem, ett_ndps);
4675 foffset = objectidentifier(tvb, btree, foffset);
4677 /* End of object identifier set */
4678 proto_tree_add_item(ndps_tree, hf_notify_time_interval, tvb, foffset, 4, FALSE);
4680 proto_tree_add_item(ndps_tree, hf_notify_sequence_number, tvb, foffset, 4, FALSE);
4682 proto_tree_add_item(ndps_tree, hf_notify_lease_exp_time, tvb, foffset, 4, FALSE);
4684 foffset = ndps_string(tvb, hf_notify_printer_uri, ndps_tree, foffset);
4685 /* End of Eventhandling2 */
4687 case 0x00000024: /* ListEventProfiles2 */
4688 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4690 proto_tree_add_item(ndps_tree, hf_ndps_list_profiles_type, tvb, foffset, 4, FALSE);
4692 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Spec */
4694 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Supplier Alias");
4695 atree = proto_item_add_subtree(aitem, ett_ndps);
4696 foffset = qualifiedname(tvb, atree, foffset);
4697 proto_tree_add_item(ndps_tree, hf_ndps_list_profiles_choice_type, tvb, foffset, 4, FALSE);
4699 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Choice */
4701 foffset = cardinal_seq(tvb, ndps_tree, foffset);
4705 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Consumer");
4706 atree = proto_item_add_subtree(aitem, ett_ndps);
4707 foffset = qualifiedname(tvb, atree, foffset);
4708 /* Start of NameorID */
4709 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method ID");
4710 atree = proto_item_add_subtree(aitem, ett_ndps);
4711 foffset = name_or_id(tvb, atree, foffset);
4712 /* End of NameorID */
4713 proto_tree_add_item(atree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
4716 proto_tree_add_item(ndps_tree, hf_ndps_list_profiles_result_type, tvb, foffset, 4, FALSE);
4718 /* Start of integeroption */
4719 proto_tree_add_item(ndps_tree, hf_ndps_integer_type_flag, tvb, foffset, 4, FALSE);
4721 if (tvb_get_ntohl(tvb, foffset-4)!=0)
4723 proto_tree_add_item(ndps_tree, hf_ndps_integer_type_value, tvb, foffset, 4, FALSE);
4726 /* End of integeroption */
4730 length = tvb_get_ntohl(tvb, foffset);
4731 proto_tree_add_item(ndps_tree, hf_ndps_context, tvb, foffset, length, FALSE);
4733 foffset += (length%2);
4734 proto_tree_add_item(ndps_tree, hf_ndps_abort_flag, tvb, foffset, 4, FALSE);
4742 case 0x060977: /* Broker */
4745 case 0x00000001: /* Bind */
4746 foffset = credentials(tvb, ndps_tree, foffset);
4747 proto_tree_add_item(ndps_tree, hf_ndps_retrieve_restrictions, tvb, foffset, 4, FALSE);
4749 number_of_items=tvb_get_ntohl(tvb, foffset);
4751 for (i = 1 ; i <= number_of_items; i++ )
4753 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Security %d", i);
4754 atree = proto_item_add_subtree(aitem, ett_ndps);
4755 length = tvb_get_ntohl(tvb, foffset);
4757 proto_tree_add_item(atree, hf_bind_security, tvb, foffset, length, FALSE);
4760 case 0x00000002: /* Unbind */
4762 case 0x00000003: /* List Services */
4763 proto_tree_add_item(ndps_tree, hf_ndps_list_services_type, tvb, foffset, 4, FALSE);
4766 case 0x00000004: /* Enable Service */
4767 proto_tree_add_item(ndps_tree, hf_ndps_service_type, tvb, foffset, 4, FALSE);
4769 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Parameters");
4770 atree = proto_item_add_subtree(aitem, ett_ndps);
4771 proto_tree_add_item(atree, hf_ndps_item_count, tvb, foffset, 4, FALSE);
4773 for (i = 1 ; i <= number_of_items; i++ )
4775 length = tvb_get_ntohl(tvb, foffset);
4777 proto_tree_add_item(ndps_tree, hf_ndps_item_bytes, tvb, foffset, length, FALSE);
4781 case 0x00000005: /* Disable Service */
4782 proto_tree_add_item(ndps_tree, hf_ndps_list_services_type, tvb, foffset, 4, FALSE);
4785 case 0x00000006: /* Down Broker */
4786 case 0x00000007: /* Get Broker NDS Object Name */
4787 case 0x00000008: /* Get Broker Session Information */
4792 case 0x060978: /* Registry */
4795 case 0x00000001: /* Bind */
4796 foffset = credentials(tvb, ndps_tree, foffset);
4797 proto_tree_add_item(ndps_tree, hf_ndps_retrieve_restrictions, tvb, foffset, 4, FALSE);
4799 number_of_items=tvb_get_ntohl(tvb, foffset);
4801 for (i = 1 ; i <= number_of_items; i++ )
4803 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Security %d", i);
4804 atree = proto_item_add_subtree(aitem, ett_ndps);
4805 length = tvb_get_ntohl(tvb, foffset);
4807 proto_tree_add_item(atree, hf_bind_security, tvb, foffset, length, FALSE);
4810 case 0x00000002: /* Unbind */
4812 case 0x00000003: /* Register Server */
4813 foffset = server_entry(tvb, ndps_tree, foffset);
4815 case 0x00000004: /* Deregister Server */
4816 case 0x00000006: /* Deregister Registry */
4817 case 0x0000000b: /* Get Registry NDS Object Name */
4818 case 0x0000000c: /* Get Registry Session Information */
4821 case 0x00000005: /* Register Registry */
4822 foffset = ndps_string(tvb, hf_ndps_registry_name, ndps_tree, foffset);
4823 foffset = print_address(tvb, ndps_tree, foffset);
4825 case 0x00000007: /* Registry Update */
4826 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Add");
4827 atree = proto_item_add_subtree(aitem, ett_ndps);
4828 number_of_items = tvb_get_ntohl(tvb, foffset);
4830 for (i = 1 ; i <= number_of_items; i++ )
4832 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Entry %d", i);
4833 btree = proto_item_add_subtree(bitem, ett_ndps);
4834 foffset = server_entry(tvb, btree, foffset);
4836 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Remove");
4837 atree = proto_item_add_subtree(aitem, ett_ndps);
4838 number_of_items = tvb_get_ntohl(tvb, foffset);
4840 for (i = 1 ; i <= number_of_items; i++ )
4842 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Entry %d", i);
4843 btree = proto_item_add_subtree(bitem, ett_ndps);
4844 foffset = server_entry(tvb, btree, foffset);
4847 case 0x00000008: /* List Local Servers */
4848 case 0x00000009: /* List Servers */
4849 case 0x0000000a: /* List Known Registries */
4850 proto_tree_add_item(ndps_tree, hf_ndps_list_local_servers_type, tvb, foffset, 4, FALSE);
4852 if (tvb_get_ntohl(tvb, foffset-4)==0)
4854 /* Start of integeroption */
4855 proto_tree_add_item(ndps_tree, hf_ndps_integer_type_flag, tvb, foffset, 4, FALSE);
4857 if (tvb_get_ntohl(tvb, foffset-4)!=0)
4859 proto_tree_add_item(ndps_tree, hf_ndps_integer_type_value, tvb, foffset, 4, FALSE);
4862 /* End of integeroption */
4866 length = tvb_get_ntohl(tvb, foffset);
4867 proto_tree_add_item(ndps_tree, hf_ndps_context, tvb, foffset, length, FALSE);
4869 foffset += (length%2);
4870 proto_tree_add_item(ndps_tree, hf_ndps_abort_flag, tvb, foffset, 4, FALSE);
4878 case 0x060979: /* Notify */
4881 case 0x00000001: /* Notify Bind */
4882 foffset = credentials(tvb, ndps_tree, foffset);
4883 proto_tree_add_item(ndps_tree, hf_ndps_retrieve_restrictions, tvb, foffset, 4, FALSE);
4885 number_of_items=tvb_get_ntohl(tvb, foffset);
4887 for (i = 1 ; i <= number_of_items; i++ )
4889 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Security %d", i);
4890 atree = proto_item_add_subtree(aitem, ett_ndps);
4891 length = tvb_get_ntohl(tvb, foffset);
4893 proto_tree_add_item(atree, hf_bind_security, tvb, foffset, length, FALSE);
4896 case 0x00000002: /* Notify Unbind */
4897 case 0x0000000a: /* List Supported Languages */
4898 case 0x00000010: /* Get Notify NDS Object Name */
4899 case 0x00000011: /* Get Notify Session Information */
4902 case 0x00000003: /* Register Supplier */
4903 foffset = ndps_string(tvb, hf_ndps_supplier_name, ndps_tree, foffset);
4904 /* Start of QualifiedName Set*/
4905 aitem = proto_tree_add_item(ndps_tree, hf_ndps_item_count, tvb, foffset, 4, FALSE);
4906 atree = proto_item_add_subtree(aitem, ett_ndps);
4908 for (i = 1 ; i <= number_of_items; i++ )
4910 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Supplier Alias");
4911 btree = proto_item_add_subtree(bitem, ett_ndps);
4912 foffset = qualifiedname(tvb, btree, foffset);
4914 /* End of QualifiedName Set*/
4916 case 0x00000004: /* Deregister Supplier */
4917 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4920 case 0x00000005: /* Add Profile */
4921 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4923 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Supplier Alias");
4924 atree = proto_item_add_subtree(aitem, ett_ndps);
4925 foffset = qualifiedname(tvb, atree, foffset);
4926 /* Start of Eventhandling */
4927 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
4929 proto_tree_add_item(ndps_tree, hf_ndps_persistence, tvb, foffset, 4, FALSE);
4931 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Consumer Name");
4932 atree = proto_item_add_subtree(aitem, ett_ndps);
4933 foffset = qualifiedname(tvb, atree, foffset);
4934 length = tvb_get_ntohl(tvb, foffset);
4936 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
4938 proto_tree_add_item(ndps_tree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
4940 /* Start of NameorID */
4941 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method ID");
4942 atree = proto_item_add_subtree(aitem, ett_ndps);
4943 foffset = name_or_id(tvb, atree, foffset);
4944 /* End of NameorID */
4945 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Delivery Address");
4946 atree = proto_item_add_subtree(aitem, ett_ndps);
4947 number_of_items = tvb_get_ntohl(tvb, foffset);
4948 for (i = 1 ; i <= number_of_items; i++ )
4950 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Address %d", i);
4951 btree = proto_item_add_subtree(bitem, ett_ndps);
4952 foffset += address_item(tvb, btree, foffset);
4954 foffset = event_object_set(tvb, ndps_tree, foffset);
4955 /* End of Eventhandling */
4957 case 0x00000006: /* Remove Profile */
4958 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4960 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
4963 case 0x00000007: /* Modify Profile */
4964 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
4966 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
4968 proto_tree_add_item(ndps_tree, hf_ndps_supplier_flag, tvb, foffset, 4, FALSE);
4970 if (tvb_get_ntohl(tvb, foffset-4)==TRUE)
4972 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Supplier ID");
4973 atree = proto_item_add_subtree(aitem, ett_ndps);
4974 length = tvb_get_ntohl(tvb, foffset);
4976 proto_tree_add_item(atree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
4979 aitem = proto_tree_add_item(ndps_tree, hf_ndps_language_flag, tvb, foffset, 4, FALSE);
4980 atree = proto_item_add_subtree(aitem, ett_ndps);
4982 if (tvb_get_ntohl(tvb, foffset-4)==TRUE)
4984 proto_tree_add_item(atree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
4987 aitem = proto_tree_add_item(ndps_tree, hf_ndps_method_flag, tvb, foffset, 4, FALSE);
4988 atree = proto_item_add_subtree(aitem, ett_ndps);
4990 if (tvb_get_ntohl(tvb, foffset-4)==TRUE)
4992 /* Start of NameorID */
4993 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Method ID");
4994 btree = proto_item_add_subtree(bitem, ett_ndps);
4995 foffset = name_or_id(tvb, btree, foffset);
4996 /* End of NameorID */
4998 aitem = proto_tree_add_item(ndps_tree, hf_ndps_delivery_address_flag, tvb, foffset, 4, FALSE);
4999 atree = proto_item_add_subtree(aitem, ett_ndps);
5001 if (tvb_get_ntohl(tvb, foffset-4)==TRUE)
5003 foffset = print_address(tvb, atree, foffset);
5005 foffset = event_object_set(tvb, ndps_tree, foffset);
5007 case 0x00000008: /* List Profiles */
5008 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
5010 proto_tree_add_item(ndps_tree, hf_ndps_list_profiles_type, tvb, foffset, 4, FALSE);
5012 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Spec */
5014 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Supplier Alias");
5015 atree = proto_item_add_subtree(aitem, ett_ndps);
5016 foffset = qualifiedname(tvb, atree, foffset);
5017 proto_tree_add_item(atree, hf_ndps_list_profiles_choice_type, tvb, foffset, 4, FALSE);
5019 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Choice */
5021 foffset = cardinal_seq(tvb, ndps_tree, foffset);
5025 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Consumer");
5026 atree = proto_item_add_subtree(aitem, ett_ndps);
5027 foffset = qualifiedname(tvb, atree, foffset);
5028 /* Start of NameorID */
5029 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method ID");
5030 atree = proto_item_add_subtree(aitem, ett_ndps);
5031 foffset = name_or_id(tvb, atree, foffset);
5032 /* End of NameorID */
5033 proto_tree_add_item(atree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
5036 proto_tree_add_item(ndps_tree, hf_ndps_list_profiles_result_type, tvb, foffset, 4, FALSE);
5038 /* Start of integeroption */
5039 proto_tree_add_item(ndps_tree, hf_ndps_integer_type_flag, tvb, foffset, 4, FALSE);
5041 if (tvb_get_ntohl(tvb, foffset-4)!=0)
5043 proto_tree_add_item(ndps_tree, hf_ndps_integer_type_value, tvb, foffset, 4, FALSE);
5046 /* End of integeroption */
5050 length = tvb_get_ntohl(tvb, foffset);
5051 proto_tree_add_item(ndps_tree, hf_ndps_context, tvb, foffset, length, FALSE);
5053 foffset += (length%2);
5054 proto_tree_add_item(ndps_tree, hf_ndps_abort_flag, tvb, foffset, 4, FALSE);
5058 case 0x00000009: /* Report Event */
5059 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
5061 /* Start of ReportEventItemSet */
5062 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Event Items");
5063 atree = proto_item_add_subtree(aitem, ett_ndps);
5064 number_of_items = tvb_get_ntohl(tvb, foffset);
5065 for (i = 1 ; i <= number_of_items; i++ )
5067 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Item %d", i);
5068 btree = proto_item_add_subtree(bitem, ett_ndps);
5069 /* Start of ReportEventItem */
5070 proto_tree_add_item(btree, hf_ndps_event_type, tvb, foffset, 4, FALSE);
5072 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Containing Class");
5073 ctree = proto_item_add_subtree(citem, ett_ndps);
5074 foffset = objectidentifier(tvb, ctree, foffset);
5075 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Containing Object");
5076 ctree = proto_item_add_subtree(citem, ett_ndps);
5077 foffset = objectidentification(tvb, ctree, foffset);
5078 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Filter Class");
5079 ctree = proto_item_add_subtree(citem, ett_ndps);
5080 foffset = objectidentifier(tvb, ctree, foffset);
5081 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Object Class");
5082 ctree = proto_item_add_subtree(citem, ett_ndps);
5083 foffset = objectidentifier(tvb, ctree, foffset);
5084 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Object ID");
5085 ctree = proto_item_add_subtree(citem, ett_ndps);
5086 foffset = objectidentification(tvb, ctree, foffset);
5087 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Event Object ID");
5088 ctree = proto_item_add_subtree(citem, ett_ndps);
5089 foffset = objectidentifier(tvb, ctree, foffset);
5090 /* Start of AttributeSet */
5091 number_of_items = tvb_get_ntohl(tvb, foffset);
5092 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Attribute Modifications");
5093 ctree = proto_item_add_subtree(citem, ett_ndps);
5095 for (j = 1 ; j <= number_of_items; j++ )
5097 ditem = proto_tree_add_text(ctree, tvb, foffset, 0, "Modification %d", j);
5098 dtree = proto_item_add_subtree(ditem, ett_ndps);
5099 foffset = attribute_value(tvb, dtree, foffset); /* Object Attribute Set */
5101 /* End of AttributeSet */
5102 foffset = ndps_string(tvb, hf_ndps_message, btree, foffset);
5103 proto_tree_add_item(btree, hf_time, tvb, foffset, 4, FALSE);
5105 /* End of ReportEventItem */
5107 /* End of ReportEventItemSet */
5109 case 0x0000000b: /* Report Notification */
5110 /* Start of DestinationSet */
5111 number_of_items = tvb_get_ntohl(tvb, foffset);
5113 for (i = 1 ; i <= number_of_items; i++ )
5115 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Destination %d", i);
5116 atree = proto_item_add_subtree(aitem, ett_ndps);
5117 /* Start of Destination */
5118 /* Start of NameorID */
5119 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Method ID");
5120 btree = proto_item_add_subtree(bitem, ett_ndps);
5121 foffset = name_or_id(tvb, btree, foffset);
5122 /* End of NameorID */
5123 /* Start of NotifyDeliveryAddr */
5124 proto_tree_add_item(atree, hf_address_len, tvb, foffset, 4, FALSE);
5126 foffset = print_address(tvb, atree, foffset);
5127 /* End of NotifyDeliveryAddr */
5128 /* End of Destination */
5130 /* End of DestinationSet */
5131 foffset = ndps_string(tvb, hf_ndps_supplier_name, ndps_tree, foffset);
5132 proto_tree_add_item(ndps_tree, hf_ndps_event_type, tvb, foffset, 4, FALSE);
5134 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Containing Class");
5135 atree = proto_item_add_subtree(aitem, ett_ndps);
5136 foffset = objectidentifier(tvb, atree, foffset);
5137 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Containing Object");
5138 atree = proto_item_add_subtree(aitem, ett_ndps);
5139 foffset = objectidentification(tvb, atree, foffset);
5140 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Filter Class");
5141 atree = proto_item_add_subtree(aitem, ett_ndps);
5142 foffset = objectidentifier(tvb, atree, foffset);
5143 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object Class");
5144 atree = proto_item_add_subtree(aitem, ett_ndps);
5145 foffset = objectidentifier(tvb, atree, foffset);
5146 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object ID");
5147 atree = proto_item_add_subtree(aitem, ett_ndps);
5148 foffset = objectidentification(tvb, atree, foffset);
5149 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Event Object ID");
5150 atree = proto_item_add_subtree(aitem, ett_ndps);
5151 foffset = objectidentifier(tvb, atree, foffset);
5152 /* Start of AttributeSet */
5153 number_of_items = tvb_get_ntohl(tvb, foffset);
5154 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Attributes");
5155 atree = proto_item_add_subtree(aitem, ett_ndps);
5157 for (i = 1 ; i <= number_of_items; i++ )
5159 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Attribute %d", i);
5160 btree = proto_item_add_subtree(bitem, ett_ndps);
5161 foffset = attribute_value(tvb, btree, foffset);
5163 /* End of AttributeSet */
5164 foffset = ndps_string(tvb, hf_ndps_message, ndps_tree, foffset);
5165 proto_tree_add_item(ndps_tree, hf_time, tvb, foffset, 4, FALSE);
5167 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Account");
5168 atree = proto_item_add_subtree(aitem, ett_ndps);
5169 foffset = qualifiedname(tvb, atree, foffset);
5171 case 0x0000000c: /* Add Delivery Method */
5172 foffset = ndps_string(tvb, hf_ndps_file_name, ndps_tree, foffset);
5174 case 0x0000000d: /* Remove Delivery Method */
5175 /* Start of NameorID */
5176 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method ID");
5177 atree = proto_item_add_subtree(aitem, ett_ndps);
5178 foffset = name_or_id(tvb, atree, foffset);
5179 /* End of NameorID */
5181 case 0x0000000e: /* List Delivery Methods */
5182 cred_type = tvb_get_ntohl(tvb, foffset);
5183 proto_tree_add_item(ndps_tree, hf_delivery_method_type, tvb, foffset, 4, FALSE);
5187 case 0: /* Specification */
5188 /* Start of integeroption */
5189 proto_tree_add_item(ndps_tree, hf_ndps_integer_type_flag, tvb, foffset, 4, FALSE);
5191 if (tvb_get_ntohl(tvb, foffset-4)!=0)
5193 proto_tree_add_item(ndps_tree, hf_ndps_integer_type_value, tvb, foffset, 4, FALSE);
5196 /* End of integeroption */
5197 proto_tree_add_item(ndps_tree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
5200 case 1: /* Continuation */
5201 length = tvb_get_ntohl(tvb, foffset);
5202 proto_tree_add_item(ndps_tree, hf_ndps_context, tvb, foffset, length, FALSE);
5204 foffset += (length%2);
5205 proto_tree_add_item(ndps_tree, hf_ndps_abort_flag, tvb, foffset, 4, FALSE);
5212 case 0x0000000f: /* Get Delivery Method Information */
5213 /* Start of NameorID */
5214 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method ID");
5215 atree = proto_item_add_subtree(aitem, ett_ndps);
5216 foffset = name_or_id(tvb, atree, foffset);
5217 /* End of NameorID */
5218 proto_tree_add_item(ndps_tree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
5225 case 0x06097a: /* Resman */
5228 case 0x00000001: /* Bind */
5229 foffset = credentials(tvb, ndps_tree, foffset);
5230 proto_tree_add_item(ndps_tree, hf_ndps_retrieve_restrictions, tvb, foffset, 4, FALSE);
5232 number_of_items=tvb_get_ntohl(tvb, foffset);
5234 for (i = 1 ; i <= number_of_items; i++ )
5236 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Security %d", i);
5237 atree = proto_item_add_subtree(aitem, ett_ndps);
5238 length = tvb_get_ntohl(tvb, foffset);
5240 proto_tree_add_item(atree, hf_bind_security, tvb, foffset, length, FALSE);
5243 case 0x00000002: /* Unbind */
5244 case 0x00000008: /* Get Resource Manager NDS Object Name */
5245 case 0x00000009: /* Get Resource Manager Session Information */
5248 case 0x00000003: /* Add Resource File */
5249 proto_tree_add_item(ndps_tree, hf_packet_count, tvb, foffset, 4, FALSE);
5251 proto_tree_add_item(ndps_tree, hf_last_packet_flag, tvb, foffset, 4, FALSE);
5253 proto_tree_add_item(ndps_tree, hf_file_timestamp, tvb, foffset, 4, FALSE);
5255 foffset = res_add_input_data(tvb, ndps_tree, foffset);
5256 number_of_items=tvb_get_ntohl(tvb, foffset);
5258 for (i = 1 ; i <= number_of_items; i++ )
5260 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Item %d", i);
5261 atree = proto_item_add_subtree(aitem, ett_ndps);
5262 length=tvb_get_ntohl(tvb, foffset);
5263 if(tvb_length_remaining(tvb, foffset) < length)
5267 proto_tree_add_item(atree, hf_ndps_item_ptr, tvb, foffset, length, FALSE);
5271 case 0x00000004: /* Delete Resource File */
5272 foffset = res_add_input_data(tvb, ndps_tree, foffset);
5274 case 0x00000005: /* List Resources */
5275 proto_tree_add_item(ndps_tree, hf_ndps_max_items, tvb, foffset, 4, FALSE);
5277 proto_tree_add_item(ndps_tree, hf_ndps_status_flags, tvb, foffset, 4, FALSE);
5279 proto_tree_add_item(ndps_tree, hf_ndps_resource_list_type, tvb, foffset, 4, FALSE);
5280 resource_type = tvb_get_ntohl(tvb, foffset);
5282 switch (resource_type)
5284 case 0: /* Print Drivers */
5285 proto_tree_add_item(ndps_tree, hf_os_type, tvb, foffset, 4, FALSE);
5288 case 1: /* Printer Definitions */
5289 case 2: /* Printer Definitions Short */
5290 foffset = ndps_string(tvb, hf_ndps_vendor_dir, ndps_tree, foffset);
5292 case 3: /* Banner Page Files */
5293 proto_tree_add_item(ndps_tree, hf_banner_type, tvb, foffset, 4, FALSE);
5296 case 4: /* Font Types */
5297 proto_tree_add_item(ndps_tree, hf_font_type, tvb, foffset, 4, FALSE);
5299 proto_tree_add_item(ndps_tree, hf_os_type, tvb, foffset, 4, FALSE);
5302 case 5: /* Printer Driver Files */
5303 case 12: /* Printer Driver Files 2 */
5304 case 9: /* Generic Files */
5305 proto_tree_add_item(ndps_tree, hf_os_type, tvb, foffset, 4, FALSE);
5307 foffset = ndps_string(tvb, hf_ndps_printer_type, ndps_tree, foffset);
5308 foffset = ndps_string(tvb, hf_ndps_printer_manuf, ndps_tree, foffset);
5309 foffset = ndps_string(tvb, hf_ndps_inf_file_name, ndps_tree, foffset);
5310 field_len = tvb_get_ntohl(tvb, foffset);
5312 proto_tree_add_item(ndps_tree, hf_printer_id, tvb, foffset, field_len, FALSE);
5314 case 6: /* Printer Definition File */
5315 case 10: /* Printer Definition File 2 */
5316 foffset = ndps_string(tvb, hf_ndps_vendor_dir, ndps_tree, foffset);
5318 foffset = ndps_string(tvb, hf_ndps_printer_type, ndps_tree, foffset);
5319 foffset = ndps_string(tvb, hf_ndps_printer_manuf, ndps_tree, foffset);
5320 foffset = ndps_string(tvb, hf_ndps_inf_file_name, ndps_tree, foffset);
5321 field_len = tvb_get_ntohl(tvb, foffset);
5323 proto_tree_add_item(ndps_tree, hf_printer_id, tvb, foffset, field_len, FALSE);
5325 case 7: /* Font Files */
5326 proto_tree_add_item(ndps_tree, hf_os_type, tvb, foffset, 4, FALSE);
5328 proto_tree_add_item(ndps_tree, hf_font_type, tvb, foffset, 4, FALSE);
5330 foffset = ndps_string(tvb, hf_ndps_font_name, ndps_tree, foffset);
5332 case 8: /* Generic Type */
5333 case 11: /* Printer Driver Types 2 */
5334 case 13: /* Printer Driver Types Archive */
5335 foffset = ndps_string(tvb, hf_ndps_printer_manuf, ndps_tree, foffset);
5336 foffset = ndps_string(tvb, hf_ndps_printer_type, ndps_tree, foffset);
5337 foffset = ndps_string(tvb, hf_ndps_inf_file_name, ndps_tree, foffset);
5339 case 14: /* Languages Available */
5345 case 0x00000006: /* Get Resource File */
5346 proto_tree_add_item(ndps_tree, hf_get_status_flag, tvb, foffset, 4, FALSE);
5348 proto_tree_add_item(ndps_tree, hf_res_type, tvb, foffset, 4, FALSE);
5349 resource_type = tvb_get_ntohl(tvb, foffset);
5351 switch (resource_type)
5353 case 0: /* Print Drivers */
5354 proto_tree_add_item(ndps_tree, hf_os_type, tvb, foffset, 4, FALSE);
5356 foffset = ndps_string(tvb, hf_ndps_prn_dir_name, ndps_tree, foffset);
5357 foffset = ndps_string(tvb, hf_ndps_prn_file_name, ndps_tree, foffset);
5359 case 1: /* Printer Definitions */
5360 foffset = ndps_string(tvb, hf_ndps_vendor_dir, ndps_tree, foffset);
5361 foffset = ndps_string(tvb, hf_ndps_prn_file_name, ndps_tree, foffset);
5363 case 2: /* Banner Page Files */
5364 foffset = ndps_string(tvb, hf_ndps_banner_name, ndps_tree, foffset);
5366 case 3: /* Font Types */
5367 proto_tree_add_item(ndps_tree, hf_os_type, tvb, foffset, 4, FALSE);
5369 proto_tree_add_item(ndps_tree, hf_font_type, tvb, foffset, 4, FALSE);
5371 foffset = ndps_string(tvb, hf_ndps_prn_file_name, ndps_tree, foffset);
5373 case 4: /* Generic Files/ Archive */
5374 case 5: /* Printer Driver Archive */
5375 proto_tree_add_item(ndps_tree, hf_os_type, tvb, foffset, 4, FALSE);
5377 foffset = ndps_string(tvb, hf_ndps_prn_dir_name, ndps_tree, foffset);
5378 proto_tree_add_item(ndps_tree, hf_archive_type, tvb, foffset, 4, FALSE);
5385 case 0x00000007: /* Get Resource File Date */
5386 proto_tree_add_item(ndps_tree, hf_ndps_status_flags, tvb, foffset, 4, FALSE);
5388 foffset = res_add_input_data(tvb, ndps_tree, foffset);
5390 case 0x0000000a: /* Set Resource Language Context */
5391 proto_tree_add_item(ndps_tree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
5398 case 0x06097b: /* Delivery */
5401 case 0x00000001: /* Delivery Bind */
5402 foffset = credentials(tvb, ndps_tree, foffset);
5404 case 0x00000002: /* Delivery Unbind */
5407 case 0x00000003: /* Delivery Send */
5408 number_of_items = tvb_get_ntohl(tvb, foffset);
5410 for (i = 1 ; i <= number_of_items; i++ )
5412 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Item %d", i);
5413 atree = proto_item_add_subtree(aitem, ett_ndps);
5414 proto_tree_add_item(atree, hf_ndps_session, tvb, foffset, 4, FALSE);
5416 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Supplier ID");
5417 btree = proto_item_add_subtree(bitem, ett_ndps);
5418 length = tvb_get_ntohl(tvb, foffset);
5420 proto_tree_add_item(btree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
5422 proto_tree_add_item(btree, hf_ndps_event_type, tvb, foffset, 4, FALSE);
5424 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Containing Class");
5425 btree = proto_item_add_subtree(bitem, ett_ndps);
5426 foffset = objectidentifier(tvb, btree, foffset);
5427 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Containing Object");
5428 btree = proto_item_add_subtree(bitem, ett_ndps);
5429 foffset = objectidentification(tvb, btree, foffset);
5430 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Filter Class");
5431 btree = proto_item_add_subtree(bitem, ett_ndps);
5432 foffset = objectidentifier(tvb, btree, foffset);
5433 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Object Class");
5434 btree = proto_item_add_subtree(bitem, ett_ndps);
5435 foffset = objectidentifier(tvb, btree, foffset);
5436 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Object ID");
5437 btree = proto_item_add_subtree(bitem, ett_ndps);
5438 foffset = objectidentification(tvb, btree, foffset);
5439 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Event Object ID");
5440 btree = proto_item_add_subtree(bitem, ett_ndps);
5441 foffset = objectidentifier(tvb, btree, foffset);
5442 foffset = attribute_value(tvb, atree, foffset);
5443 foffset = ndps_string(tvb, hf_ndps_message, atree, foffset);
5444 proto_tree_add_item(atree, hf_time, tvb, foffset, 4, FALSE);
5446 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Account");
5447 btree = proto_item_add_subtree(bitem, ett_ndps);
5448 foffset = qualifiedname(tvb, btree, foffset);
5451 case 0x00000004: /* Delivery Send2 */
5452 number_of_items = tvb_get_ntohl(tvb, foffset);
5454 for (i = 1 ; i <= number_of_items; i++ )
5456 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object %d", i);
5457 atree = proto_item_add_subtree(aitem, ett_ndps);
5458 proto_tree_add_item(atree, hf_ndps_session, tvb, foffset, 4, FALSE);
5460 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Supplier ID");
5461 btree = proto_item_add_subtree(bitem, ett_ndps);
5462 length = tvb_get_ntohl(tvb, foffset);
5464 proto_tree_add_item(btree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
5466 proto_tree_add_item(atree, hf_ndps_event_type, tvb, foffset, 4, FALSE);
5468 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Containing Class");
5469 btree = proto_item_add_subtree(bitem, ett_ndps);
5470 foffset = objectidentifier(tvb, btree, foffset);
5471 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Containing Object");
5472 btree = proto_item_add_subtree(bitem, ett_ndps);
5473 foffset = objectidentification(tvb, btree, foffset);
5474 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Filter Class");
5475 btree = proto_item_add_subtree(bitem, ett_ndps);
5476 foffset = objectidentifier(tvb, btree, foffset);
5477 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Object Class");
5478 btree = proto_item_add_subtree(bitem, ett_ndps);
5479 foffset = objectidentifier(tvb, btree, foffset);
5480 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Object ID");
5481 btree = proto_item_add_subtree(bitem, ett_ndps);
5482 foffset = objectidentification(tvb, btree, foffset);
5483 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Event Object ID");
5484 btree = proto_item_add_subtree(bitem, ett_ndps);
5485 foffset = objectidentifier(tvb, btree, foffset);
5486 /* Start of AttributeSet */
5487 number_of_items = tvb_get_ntohl(tvb, foffset);
5488 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Attribute");
5489 btree = proto_item_add_subtree(bitem, ett_ndps);
5490 proto_tree_add_item(btree, hf_ndps_attributes, tvb, foffset, 4, FALSE);
5492 for (i = 1 ; i <= number_of_items; i++ )
5494 foffset = attribute_value(tvb, btree, foffset);
5496 /* End of AttributeSet */
5497 foffset = ndps_string(tvb, hf_ndps_message, atree, foffset);
5498 proto_tree_add_item(atree, hf_time, tvb, foffset, 4, FALSE);
5500 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Account");
5501 btree = proto_item_add_subtree(bitem, ett_ndps);
5502 foffset = qualifiedname(tvb, btree, foffset);
5516 ndps_error(tvbuff_t *tvb, packet_info *pinfo, proto_tree *ndps_tree, int foffset)
5518 guint32 number_of_items=0;
5519 guint32 problem_type=0;
5526 problem_type = tvb_get_ntohl(tvb, foffset);
5527 if (check_col(pinfo->cinfo, COL_INFO))
5528 col_add_fstr(pinfo->cinfo, COL_INFO, "R NDPS - Error");
5529 proto_tree_add_item(ndps_tree, hf_ndps_problem_type, tvb, foffset, 4, FALSE);
5531 switch(problem_type)
5533 case 0: /* Security Error */
5534 proto_tree_add_item(ndps_tree, hf_problem_type, tvb, foffset, 4, FALSE);
5536 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Standard Error */
5538 proto_tree_add_item(ndps_tree, hf_security_problem_type, tvb, foffset, 4, FALSE);
5541 else /* Extended Error */
5543 /* Start of objectidentifier */
5544 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Extended Error");
5545 atree = proto_item_add_subtree(aitem, ett_ndps);
5546 foffset = objectidentifier(tvb, atree, foffset);
5547 /* End of objectidentifier */
5549 /* Start of NameorID */
5550 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Message");
5551 atree = proto_item_add_subtree(aitem, ett_ndps);
5552 foffset = name_or_id(tvb, atree, foffset);
5553 /* End of NameorID */
5555 case 1: /* Service Error */
5556 proto_tree_add_item(ndps_tree, hf_problem_type, tvb, foffset, 4, FALSE);
5558 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Standard Error */
5560 proto_tree_add_item(ndps_tree, hf_service_problem_type, tvb, foffset, 4, FALSE);
5563 else /* Extended Error */
5565 /* Start of objectidentifier */
5566 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Extended Error");
5567 atree = proto_item_add_subtree(aitem, ett_ndps);
5568 foffset = objectidentifier(tvb, atree, foffset);
5569 /* End of objectidentifier */
5571 foffset = objectidentification(tvb, ndps_tree, foffset);
5572 foffset = attribute_value(tvb, ndps_tree, foffset); /* Object Attribute Set */
5573 proto_tree_add_item(ndps_tree, hf_ndps_lib_error, tvb, foffset, 4, FALSE);
5575 proto_tree_add_item(ndps_tree, hf_ndps_other_error, tvb, foffset, 4, FALSE);
5577 proto_tree_add_item(ndps_tree, hf_ndps_other_error_2, tvb, foffset, 4, FALSE);
5580 case 2: /* Access Error */
5581 proto_tree_add_item(ndps_tree, hf_problem_type, tvb, foffset, 4, FALSE);
5583 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Standard Error */
5585 proto_tree_add_item(ndps_tree, hf_access_problem_type, tvb, foffset, 4, FALSE);
5588 else /* Extended Error */
5590 /* Start of objectidentifier */
5591 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Extended Error");
5592 atree = proto_item_add_subtree(aitem, ett_ndps);
5593 foffset = objectidentifier(tvb, atree, foffset);
5594 /* End of objectidentifier */
5596 foffset = objectidentification(tvb, ndps_tree, foffset);
5598 case 3: /* Printer Error */
5599 proto_tree_add_item(ndps_tree, hf_problem_type, tvb, foffset, 4, FALSE);
5601 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Standard Error */
5603 proto_tree_add_item(ndps_tree, hf_printer_problem_type, tvb, foffset, 4, FALSE);
5606 else /* Extended Error */
5608 /* Start of objectidentifier */
5609 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Extended Error");
5610 atree = proto_item_add_subtree(aitem, ett_ndps);
5611 foffset = objectidentifier(tvb, atree, foffset);
5612 /* End of objectidentifier */
5614 foffset = objectidentification(tvb, ndps_tree, foffset);
5616 case 4: /* Selection Error */
5617 proto_tree_add_item(ndps_tree, hf_problem_type, tvb, foffset, 4, FALSE);
5619 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Standard Error */
5621 proto_tree_add_item(ndps_tree, hf_selection_problem_type, tvb, foffset, 4, FALSE);
5624 else /* Extended Error */
5626 /* Start of objectidentifier */
5627 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Extended Error");
5628 atree = proto_item_add_subtree(aitem, ett_ndps);
5629 foffset = objectidentifier(tvb, atree, foffset);
5630 /* End of objectidentifier */
5632 foffset = objectidentification(tvb, ndps_tree, foffset);
5633 foffset = attribute_value(tvb, ndps_tree, foffset); /* Object Attribute Set */
5635 case 5: /* Document Access Error */
5636 proto_tree_add_item(ndps_tree, hf_problem_type, tvb, foffset, 4, FALSE);
5638 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Standard Error */
5640 proto_tree_add_item(ndps_tree, hf_doc_access_problem_type, tvb, foffset, 4, FALSE);
5641 foffset = objectidentifier(tvb, ndps_tree, foffset);
5643 else /* Extended Error */
5645 /* Start of objectidentifier */
5646 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Extended Error");
5647 atree = proto_item_add_subtree(aitem, ett_ndps);
5648 foffset = objectidentifier(tvb, atree, foffset);
5649 /* End of objectidentifier */
5651 foffset = objectidentification(tvb, ndps_tree, foffset);
5653 case 6: /* Attribute Error */
5654 number_of_items = tvb_get_ntohl(tvb, foffset);
5656 for (i = 1 ; i <= number_of_items; i++ )
5658 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Item %d", i);
5659 atree = proto_item_add_subtree(aitem, ett_ndps);
5660 proto_tree_add_item(atree, hf_problem_type, tvb, foffset, 4, FALSE);
5662 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Standard Error */
5664 proto_tree_add_item(atree, hf_attribute_problem_type, tvb, foffset, 4, FALSE);
5667 else /* Extended Error */
5669 /* Start of objectidentifier */
5670 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Extended Error");
5671 btree = proto_item_add_subtree(bitem, ett_ndps);
5672 foffset = objectidentifier(tvb, btree, foffset);
5673 /* End of objectidentifier */
5675 foffset = attribute_value(tvb, atree, foffset); /* Object Attribute Set */
5678 case 7: /* Update Error */
5679 proto_tree_add_item(ndps_tree, hf_problem_type, tvb, foffset, 4, FALSE);
5681 if (tvb_get_ntohl(tvb, foffset-4)==0) /* Standard Error */
5683 proto_tree_add_item(ndps_tree, hf_update_problem_type, tvb, foffset, 4, FALSE);
5686 else /* Extended Error */
5688 /* Start of objectidentifier */
5689 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Extended Error");
5690 atree = proto_item_add_subtree(aitem, ett_ndps);
5691 foffset = objectidentifier(tvb, atree, foffset);
5692 /* End of objectidentifier */
5694 foffset = objectidentification(tvb, ndps_tree, foffset);
5703 return_code(tvbuff_t *tvb, packet_info *pinfo, proto_tree *ndps_tree, int foffset)
5705 proto_tree_add_item(ndps_tree, hf_ndps_return_code, tvb, foffset, 4, FALSE);
5707 if (check_col(pinfo->cinfo, COL_INFO) && tvb_get_ntohl(tvb, foffset-4) != 0)
5708 col_add_fstr(pinfo->cinfo, COL_INFO, "R NDPS - Error");
5709 if (tvb_get_ntohl(tvb, foffset-4) == 0)
5713 proto_tree_add_item(ndps_tree, hf_ndps_ext_error, tvb, foffset, 4, FALSE);
5719 dissect_ndps_reply(tvbuff_t *tvb, packet_info *pinfo, proto_tree *ndps_tree, int foffset)
5721 conversation_t *conversation = NULL;
5722 ndps_req_hash_value *request_value = NULL;
5734 guint32 number_of_items=0;
5735 guint32 number_of_items2=0;
5736 guint32 number_of_items3=0;
5738 guint32 ndps_func=0;
5739 guint32 ndps_prog=0;
5740 guint32 error_val=0;
5741 guint32 resource_type=0;
5743 if (!pinfo->fd->flags.visited) {
5744 /* Find the conversation whence the request would have come. */
5745 conversation = find_conversation(&pinfo->src, &pinfo->dst,
5746 PT_NCP, (guint32) pinfo->destport, (guint32) pinfo->destport, 0);
5747 if (conversation != NULL) {
5748 /* find the record telling us the request made that caused
5750 request_value = ndps_hash_lookup(conversation, (guint32) pinfo->destport);
5751 p_add_proto_data(pinfo->fd, proto_ndps, (void*) request_value);
5753 /* else... we haven't seen an NDPS Request for that conversation. */
5756 request_value = p_get_proto_data(pinfo->fd, proto_ndps);
5758 if (request_value) {
5759 ndps_prog = request_value->ndps_prog;
5760 ndps_func = request_value->ndps_func;
5761 proto_tree_add_uint_format(ndps_tree, hf_ndps_reqframe, tvb, 0,
5762 0, request_value->ndps_frame_num,
5763 "Response to Request in Frame Number: %u",
5764 request_value->ndps_frame_num);
5767 if (tvb_length_remaining(tvb, foffset) < 12 && tvb_get_ntohl(tvb, foffset) == 0) /* No error and no return data */
5769 proto_tree_add_uint(ndps_tree, hf_ndps_error_val, tvb, foffset, 4, error_val);
5770 if (check_col(pinfo->cinfo, COL_INFO))
5771 col_append_str(pinfo->cinfo, COL_INFO, "- Ok");
5774 if(ndps_func == 1 || ndps_func == 2)
5776 proto_tree_add_item(ndps_tree, hf_ndps_rpc_acc_stat, tvb, foffset, 4, FALSE);
5778 if (tvb_length_remaining(tvb,foffset) < 4 ) {
5779 if (check_col(pinfo->cinfo, COL_INFO))
5780 col_append_str(pinfo->cinfo, COL_INFO, "- Error");
5783 proto_tree_add_item(ndps_tree, hf_ndps_rpc_acc_results, tvb, foffset, 4, FALSE);
5785 if (tvb_length_remaining(tvb,foffset) < 4) {
5786 if (check_col(pinfo->cinfo, COL_INFO))
5787 col_append_str(pinfo->cinfo, COL_INFO, "- Error");
5791 error_val = tvb_get_ntohl(tvb, foffset);
5792 proto_tree_add_uint(ndps_tree, hf_ndps_error_val, tvb, foffset, 4, error_val);
5794 /* Some functions return an error with no data, 0 is ok */
5795 if (match_strval(tvb_get_ntohl(tvb, foffset), ndps_error_types) && tvb_length_remaining(tvb,foffset) < 8 && (tvb_get_ntohl(tvb, foffset)!=0))
5797 proto_tree_add_item(ndps_tree, hf_ndps_return_code, tvb, foffset, 4, FALSE);
5798 if (check_col(pinfo->cinfo, COL_INFO))
5799 col_append_str(pinfo->cinfo, COL_INFO, "- Error");
5802 if (check_col(pinfo->cinfo, COL_INFO))
5803 col_append_str(pinfo->cinfo, COL_INFO, "- Ok");
5806 case 0x060976: /* Print */
5809 case 0x00000001: /* Bind PSM */
5810 proto_tree_add_item(ndps_tree, hf_ndps_oid, tvb, foffset, 4, FALSE);
5814 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
5815 if(tvb_length_remaining(tvb, foffset) < 4)
5819 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
5822 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "PSM Name");
5823 atree = proto_item_add_subtree(aitem, ett_ndps);
5824 foffset = qualifiedname(tvb, atree, foffset);
5826 case 0x00000002: /* Bind PA */
5827 proto_tree_add_item(ndps_tree, hf_ndps_oid, tvb, foffset, 4, FALSE);
5831 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
5832 if(tvb_length_remaining(tvb, foffset) < 4)
5836 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
5839 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
5841 case 0x00000003: /* Unbind */
5843 case 0x00000004: /* Print */
5844 foffset = ndps_string(tvb, hf_ndps_pa_name, ndps_tree, foffset);
5845 proto_tree_add_item(ndps_tree, hf_local_id, tvb, foffset, 4, FALSE);
5849 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
5852 case 0x00000005: /* Modify Job */
5853 case 0x00000006: /* Cancel Job */
5854 case 0x00000008: /* Promote Job */
5855 case 0x0000000b: /* Resume */
5856 case 0x0000000d: /* Create */
5857 /* Start of AttributeSet */
5858 number_of_items = tvb_get_ntohl(tvb, foffset);
5859 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object Attribute Set");
5860 atree = proto_item_add_subtree(aitem, ett_ndps);
5862 for (i = 1 ; i <= number_of_items; i++ )
5864 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Attribute %d", i);
5865 btree = proto_item_add_subtree(bitem, ett_ndps);
5866 foffset = attribute_value(tvb, btree, foffset); /* Object Attribute Set */
5868 /* End of AttributeSet */
5871 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
5874 case 0x00000007: /* List Object Attributes */
5875 proto_tree_add_item(ndps_tree, hf_answer_time, tvb, foffset, 4, FALSE);
5877 /* Continuation Option */
5878 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Continuation Option");
5879 atree = proto_item_add_subtree(aitem, ett_ndps);
5880 number_of_items=tvb_get_ntohl(tvb, foffset);
5882 for (i = 1 ; i <= number_of_items; i++ )
5884 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Option %d", i);
5885 btree = proto_item_add_subtree(bitem, ett_ndps);
5886 length=tvb_get_ntohl(tvb, foffset);
5887 if(tvb_length_remaining(tvb, foffset) < length)
5891 proto_tree_add_item(btree, hf_ndps_item_ptr, tvb, foffset, length, FALSE);
5894 /* Limit Encountered Option */
5895 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Limit Encountered Option");
5896 atree = proto_item_add_subtree(aitem, ett_ndps);
5897 proto_tree_add_item(atree, hf_ndps_len, tvb, foffset, 4, FALSE);
5899 proto_tree_add_item(atree, hf_limit_enc, tvb, foffset, 4, FALSE);
5901 /* Object Results Set */
5902 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object Results Set");
5903 atree = proto_item_add_subtree(aitem, ett_ndps);
5904 number_of_items=tvb_get_ntohl(tvb, foffset);
5906 for (i = 1 ; i <= number_of_items; i++ )
5908 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Result %d", i);
5909 btree = proto_item_add_subtree(bitem, ett_ndps);
5910 foffset = objectidentification(tvb, btree, foffset);
5911 number_of_items2 = tvb_get_ntohl(tvb, foffset);
5913 for (j = 1 ; j <= number_of_items2; j++ )
5915 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Attribute %d", j);
5916 ctree = proto_item_add_subtree(citem, ett_ndps);
5917 foffset = objectidentifier(tvb, ctree, foffset);
5918 foffset += align_4(tvb, foffset);
5919 number_of_items3 = tvb_get_ntohl(tvb, foffset);
5921 for (k = 1 ; k <= number_of_items3; k++ )
5923 ditem = proto_tree_add_text(ctree, tvb, foffset, 0, "Value %d", k);
5924 dtree = proto_item_add_subtree(ditem, ett_ndps);
5925 foffset = attribute_value(tvb, dtree, foffset);
5926 foffset += align_4(tvb, foffset);
5928 proto_tree_add_item(ctree, hf_ndps_qualifier, tvb, foffset, 4, FALSE);
5931 foffset = objectidentifier(tvb, btree, foffset);
5936 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
5939 case 0x00000009: /* Interrupt */
5940 case 0x0000000a: /* Pause */
5941 /* Start of NWDPPrtContainedObjectId */
5942 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Job ID");
5943 atree = proto_item_add_subtree(aitem, ett_ndps);
5944 foffset = ndps_string(tvb, hf_ndps_pa_name, atree, foffset);
5945 proto_tree_add_item(atree, hf_local_id, tvb, foffset, 4, FALSE);
5947 /* End of NWDPPrtContainedObjectId */
5948 /* Start of AttributeSet */
5949 number_of_items = tvb_get_ntohl(tvb, foffset);
5950 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Object Attribute Set");
5951 atree = proto_item_add_subtree(aitem, ett_ndps);
5953 for (i = 1 ; i <= number_of_items; i++ )
5955 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Attribute %d", i);
5956 btree = proto_item_add_subtree(bitem, ett_ndps);
5957 foffset = attribute_value(tvb, btree, foffset); /* Object Attribute Set */
5959 /* End of AttributeSet */
5962 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
5965 case 0x0000000c: /* Clean */
5966 case 0x0000000e: /* Delete */
5967 case 0x0000000f: /* Disable PA */
5968 case 0x00000010: /* Enable PA */
5969 case 0x00000012: /* Set */
5970 case 0x00000013: /* Shutdown PA */
5971 case 0x00000014: /* Startup PA */
5972 case 0x00000018: /* Transfer Data */
5973 case 0x00000019: /* Device Control */
5974 case 0x0000001b: /* Remove Event Profile */
5975 case 0x0000001c: /* Modify Event Profile */
5976 case 0x0000001e: /* Shutdown PSM */
5977 case 0x0000001f: /* Cancel PSM Shutdown */
5978 case 0x00000020: /* Set Printer DS Information */
5979 case 0x00000021: /* Clean User Jobs */
5982 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
5985 case 0x00000011: /* Resubmit Jobs */
5986 number_of_items = tvb_get_ntohl(tvb, foffset); /* Start of ResubmitJob Set */
5987 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Resubmit Job");
5988 atree = proto_item_add_subtree(aitem, ett_ndps);
5990 for (i = 1 ; i <= number_of_items; i++ )
5992 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Job %d", i);
5993 btree = proto_item_add_subtree(bitem, ett_ndps);
5994 /* Start of NWDPPrtContainedObjectId */
5995 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Old Job");
5996 ctree = proto_item_add_subtree(citem, ett_ndps);
5997 foffset = ndps_string(tvb, hf_ndps_pa_name, ctree, foffset);
5998 proto_tree_add_item(ctree, hf_local_id, tvb, foffset, 4, FALSE);
6000 /* End of NWDPPrtContainedObjectId */
6001 /* Start of NWDPPrtContainedObjectId */
6002 citem = proto_tree_add_text(btree, tvb, foffset, 0, "New Job");
6003 ctree = proto_item_add_subtree(citem, ett_ndps);
6004 foffset = ndps_string(tvb, hf_ndps_pa_name, ctree, foffset);
6005 proto_tree_add_item(ctree, hf_local_id, tvb, foffset, 4, FALSE);
6007 /* End of NWDPPrtContainedObjectId */
6008 /* Start of AttributeSet */
6009 number_of_items2 = tvb_get_ntohl(tvb, foffset);
6010 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Job Status");
6011 ctree = proto_item_add_subtree(citem, ett_ndps);
6013 for (j = 1 ; j <= number_of_items2; j++ )
6015 ditem = proto_tree_add_text(ctree, tvb, foffset, 0, "Object %d", j);
6016 dtree = proto_item_add_subtree(ditem, ett_ndps);
6017 foffset = attribute_value(tvb, dtree, foffset); /* Object Attribute Set */
6019 /* End of AttributeSet */
6020 } /* End of ResubmitJob Set */
6023 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
6026 case 0x00000015: /* Reorder Job */
6027 /* Start of AttributeSet */
6028 number_of_items = tvb_get_ntohl(tvb, foffset);
6029 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Job Status");
6030 atree = proto_item_add_subtree(aitem, ett_ndps);
6032 for (i = 1 ; i <= number_of_items; i++ )
6034 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Object %d", i);
6035 btree = proto_item_add_subtree(bitem, ett_ndps);
6036 foffset = attribute_value(tvb, btree, foffset); /* Object Attribute Set */
6038 /* End of AttributeSet */
6041 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
6044 case 0x00000016: /* Pause PA */
6045 case 0x00000017: /* Resume PA */
6046 /* Start of AttributeSet */
6047 number_of_items = tvb_get_ntohl(tvb, foffset);
6048 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Printer Status");
6049 atree = proto_item_add_subtree(aitem, ett_ndps);
6051 for (i = 1 ; i <= number_of_items; i++ )
6053 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Object %d", i);
6054 btree = proto_item_add_subtree(bitem, ett_ndps);
6055 foffset = attribute_value(tvb, atree, foffset); /* Object Attribute Set */
6057 /* End of AttributeSet */
6060 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
6063 case 0x0000001a: /* Add Event Profile */
6064 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
6068 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
6071 case 0x0000001d: /* List Event Profiles */
6072 length = tvb_get_ntohl(tvb, foffset);
6074 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
6076 /* Start of Eventhandling */
6077 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
6079 proto_tree_add_item(ndps_tree, hf_ndps_persistence, tvb, foffset, 4, FALSE);
6081 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Consumer Name");
6082 atree = proto_item_add_subtree(aitem, ett_ndps);
6083 foffset = qualifiedname(tvb, atree, foffset);
6084 length = tvb_get_ntohl(tvb, foffset);
6086 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
6088 proto_tree_add_item(ndps_tree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
6090 /* Start of NameorID */
6091 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method ID");
6092 atree = proto_item_add_subtree(aitem, ett_ndps);
6093 foffset = name_or_id(tvb, atree, foffset);
6094 /* End of NameorID */
6095 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Delivery Address");
6096 atree = proto_item_add_subtree(aitem, ett_ndps);
6097 number_of_items = tvb_get_ntohl(tvb, foffset);
6098 for (i = 1 ; i <= number_of_items; i++ )
6100 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Address %d", i);
6101 btree = proto_item_add_subtree(bitem, ett_ndps);
6102 foffset += address_item(tvb, btree, foffset);
6104 foffset = event_object_set(tvb, ndps_tree, foffset);
6105 /* End of Eventhandling */
6106 length = tvb_get_ntohl(tvb, foffset);
6108 proto_tree_add_item(ndps_tree, hf_ndps_continuation_option, tvb, foffset, length, FALSE);
6112 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
6115 case 0x00000022: /* Map GUID to NDS Name */
6116 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "NDS Printer Name");
6117 atree = proto_item_add_subtree(aitem, ett_ndps);
6118 foffset = qualifiedname(tvb, atree, foffset);
6121 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
6124 case 0x00000023: /* AddEventProfile2 */
6125 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
6127 proto_tree_add_item(ndps_tree, hf_notify_lease_exp_time, tvb, foffset, 4, FALSE);
6131 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
6134 case 0x00000024: /* ListEventProfiles2 */
6135 number_of_items = tvb_get_ntohl(tvb, foffset);
6137 for (i = 1 ; i <= number_of_items; i++ )
6139 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Event %d", i);
6140 atree = proto_item_add_subtree(aitem, ett_ndps);
6141 /* Start of Eventhandling2 */
6142 proto_tree_add_item(atree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
6144 proto_tree_add_item(atree, hf_ndps_persistence, tvb, foffset, 4, FALSE);
6146 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Consumer Name");
6147 btree = proto_item_add_subtree(bitem, ett_ndps);
6148 foffset = qualifiedname(tvb, btree, foffset);
6149 foffset = ndps_string(tvb, hf_ndps_supplier_name, atree, foffset);
6150 proto_tree_add_item(atree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
6152 /* Start of NameorID */
6153 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Method ID");
6154 btree = proto_item_add_subtree(bitem, ett_ndps);
6155 foffset = name_or_id(tvb, btree, foffset);
6156 foffset += align_4(tvb, foffset);
6157 /* End of NameorID */
6158 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Delivery Address");
6159 btree = proto_item_add_subtree(bitem, ett_ndps);
6160 number_of_items = tvb_get_ntohl(tvb, foffset);
6162 for (i = 1 ; i <= number_of_items; i++ )
6164 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Address %d", i);
6165 ctree = proto_item_add_subtree(citem, ett_ndps);
6166 foffset = address_item(tvb, ctree, foffset);
6168 foffset = event_object_set(tvb, ndps_tree, foffset);
6169 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Account");
6170 btree = proto_item_add_subtree(bitem, ett_ndps);
6171 foffset = qualifiedname(tvb, btree, foffset);
6172 /* Start of object identifier set */
6173 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Notify Attributes");
6174 btree = proto_item_add_subtree(bitem, ett_ndps);
6175 number_of_items = tvb_get_ntohl(tvb, foffset);
6177 for (i = 1 ; i <= number_of_items; i++ )
6179 citem = proto_tree_add_text(btree, tvb, foffset, 0, "Attribute %d", i);
6180 ctree = proto_item_add_subtree(citem, ett_ndps);
6181 foffset = objectidentifier(tvb, ctree, foffset);
6183 /* End of object identifier set */
6184 proto_tree_add_item(atree, hf_notify_time_interval, tvb, foffset, 4, FALSE);
6186 proto_tree_add_item(atree, hf_notify_sequence_number, tvb, foffset, 4, FALSE);
6188 proto_tree_add_item(atree, hf_notify_lease_exp_time, tvb, foffset, 4, FALSE);
6190 foffset = ndps_string(tvb, hf_notify_printer_uri, atree, foffset);
6191 /* End of Eventhandling2 */
6192 proto_tree_add_item(ndps_tree, hf_ndps_continuation_option, tvb, foffset, length, FALSE);
6196 foffset = ndps_error(tvb, pinfo, ndps_tree, foffset);
6204 case 0x060977: /* Broker */
6207 case 0x00000001: /* Bind */
6208 case 0x00000002: /* Unbind */
6209 case 0x00000004: /* Enable Service */
6210 case 0x00000005: /* Disable Service */
6211 case 0x00000006: /* Down Broker */
6212 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6214 case 0x00000003: /* List Services */
6215 number_of_items = tvb_get_ntohl(tvb, foffset);
6217 for (i = 1 ; i <= number_of_items; i++ )
6219 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Service %d", i);
6220 atree = proto_item_add_subtree(aitem, ett_ndps);
6221 bitem = proto_tree_add_item(atree, hf_ndps_service_type, tvb, foffset, 4, FALSE);
6222 btree = proto_item_add_subtree(bitem, ett_ndps);
6224 proto_tree_add_item(btree, hf_ndps_service_enabled, tvb, foffset, 4, FALSE);
6227 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6229 case 0x00000007: /* Get Broker NDS Object Name */
6230 proto_tree_add_item(ndps_tree, hf_ndps_items, tvb, foffset,
6233 foffset = ndps_string(tvb, hf_ndps_broker_name, ndps_tree, foffset);
6234 foffset = ndps_string(tvb, hf_ndps_tree, ndps_tree, foffset);
6235 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6237 case 0x00000008: /* Get Broker Session Information */
6242 case 0x060978: /* Registry */
6245 case 0x00000001: /* Bind */
6246 number_of_items = tvb_get_ntohl(tvb, foffset);
6248 for (i = 1 ; i <= number_of_items; i++ )
6250 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Attribute %d", i);
6251 atree = proto_item_add_subtree(aitem, ett_ndps);
6252 length = tvb_get_ntohl(tvb, foffset);
6254 proto_tree_add_item(atree, hf_ndps_attribute_set, tvb, foffset, length, FALSE);
6257 case 0x00000002: /* Unbind */
6260 case 0x00000003: /* Register Server */
6261 case 0x00000004: /* Deregister Server */
6262 case 0x00000005: /* Register Registry */
6263 case 0x00000006: /* Deregister Registry */
6264 case 0x00000007: /* Registry Update */
6265 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6267 case 0x00000008: /* List Local Servers */
6268 case 0x00000009: /* List Servers */
6269 number_of_items = tvb_get_ntohl(tvb, foffset);
6271 for (i = 1 ; i <= number_of_items; i++ )
6273 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Item %d", i);
6274 atree = proto_item_add_subtree(aitem, ett_ndps);
6275 foffset = server_entry(tvb, atree, foffset);
6277 length = tvb_get_ntohl(tvb, foffset);
6279 proto_tree_add_item(ndps_tree, hf_ndps_continuation_option, tvb, foffset, length, FALSE);
6281 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6283 case 0x0000000a: /* List Known Registries */
6284 number_of_items = tvb_get_ntohl(tvb, foffset);
6285 proto_tree_add_item(ndps_tree, hf_ndps_item_count, tvb, foffset, 4, FALSE);
6287 for (i = 1 ; i <= number_of_items; i++ )
6289 aitem = proto_tree_add_item(ndps_tree, hf_ndps_client_server_type, tvb, foffset, 4, FALSE);
6290 atree = proto_item_add_subtree(aitem, ett_ndps);
6292 foffset = ndps_string(tvb, hf_ndps_registry_name, atree, foffset);
6293 foffset = print_address(tvb, atree, foffset);
6295 length = tvb_get_ntohl(tvb, foffset);
6297 proto_tree_add_item(ndps_tree, hf_ndps_continuation_option, tvb, foffset, length, FALSE);
6299 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6301 case 0x0000000b: /* Get Registry NDS Object Name */
6302 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "NDS Printer Name");
6303 atree = proto_item_add_subtree(aitem, ett_ndps);
6304 foffset = qualifiedname(tvb, atree, foffset);
6305 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6307 case 0x0000000c: /* Get Registry Session Information */
6308 proto_tree_add_item(ndps_tree, hf_ndps_session_type, tvb, foffset, 4, FALSE);
6310 proto_tree_add_item(ndps_tree, hf_time, tvb, foffset, 4, FALSE);
6312 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6318 case 0x060979: /* Notify */
6321 case 0x00000001: /* Notify Bind */
6322 number_of_items = tvb_get_ntohl(tvb, foffset);
6324 for (i = 1 ; i <= number_of_items; i++ )
6326 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Attribute %d", i);
6327 atree = proto_item_add_subtree(aitem, ett_ndps);
6328 length = tvb_get_ntohl(tvb, foffset);
6330 proto_tree_add_item(atree, hf_ndps_attribute_set, tvb, foffset, length, FALSE);
6333 case 0x00000002: /* Notify Unbind */
6336 case 0x00000003: /* Register Supplier */
6337 proto_tree_add_item(ndps_tree, hf_ndps_session, tvb, foffset, 4, FALSE);
6339 foffset = event_object_set(tvb, ndps_tree, foffset);
6340 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6342 case 0x00000004: /* Deregister Supplier */
6343 case 0x0000000b: /* Report Notification */
6344 case 0x0000000d: /* Remove Delivery Method */
6345 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6347 case 0x00000005: /* Add Profile */
6348 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
6350 foffset = event_object_set(tvb, ndps_tree, foffset);
6351 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6353 case 0x00000006: /* Remove Profile */
6354 case 0x00000007: /* Modify Profile */
6355 case 0x00000009: /* Report Event */
6356 foffset = event_object_set(tvb, ndps_tree, foffset);
6357 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6359 case 0x00000008: /* List Profiles */
6360 /* Start of ProfileResultSet */
6361 proto_tree_add_item(ndps_tree, hf_ndps_len, tvb, foffset, 4, FALSE);
6363 /* Start of Eventhandling */
6364 proto_tree_add_item(ndps_tree, hf_ndps_profile_id, tvb, foffset, 4, FALSE);
6366 proto_tree_add_item(ndps_tree, hf_ndps_persistence, tvb, foffset, 4, FALSE);
6368 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Consumer Name");
6369 atree = proto_item_add_subtree(aitem, ett_ndps);
6370 foffset = qualifiedname(tvb, atree, foffset);
6371 length = tvb_get_ntohl(tvb, foffset);
6373 proto_tree_add_item(ndps_tree, hf_ndps_attribute_value, tvb, foffset, length, FALSE);
6375 proto_tree_add_item(ndps_tree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
6377 /* Start of NameorID */
6378 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method ID");
6379 atree = proto_item_add_subtree(aitem, ett_ndps);
6380 foffset = name_or_id(tvb, atree, foffset);
6381 /* End of NameorID */
6382 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Delivery Address");
6383 atree = proto_item_add_subtree(aitem, ett_ndps);
6384 number_of_items = tvb_get_ntohl(tvb, foffset);
6385 for (i = 1 ; i <= number_of_items; i++ )
6387 foffset += address_item(tvb, atree, foffset);
6389 foffset = event_object_set(tvb, ndps_tree, foffset);
6390 /* End of Eventhandling */
6391 /* End of ProfileResultSet */
6392 length = tvb_get_ntohl(tvb, foffset);
6394 proto_tree_add_item(ndps_tree, hf_ndps_continuation_option, tvb, foffset, length, FALSE);
6396 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6398 case 0x0000000a: /* List Supported Languages */
6399 /* Start of IntegerSeq */
6400 length = tvb_get_ntohl(tvb, foffset);
6402 proto_tree_add_item(ndps_tree, hf_ndps_language_id, tvb, foffset, length, FALSE);
6404 /* End of IntegerSeq */
6405 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6407 case 0x0000000c: /* Add Delivery Method */
6408 /* Start of NameorID */
6409 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method ID");
6410 atree = proto_item_add_subtree(aitem, ett_ndps);
6411 foffset = name_or_id(tvb, atree, foffset);
6412 /* End of NameorID */
6413 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6415 case 0x0000000e: /* List Delivery Methods */
6416 /* Start of DeliveryMethodSet */
6417 number_of_items = tvb_get_ntohl(tvb, foffset);
6419 for (i = 1 ; i <= number_of_items; i++ )
6421 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method %d", i);
6422 atree = proto_item_add_subtree(aitem, ett_ndps);
6423 /* Start of DeliveryMethod */
6424 /* Start of NameorID */
6425 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Method ID");
6426 btree = proto_item_add_subtree(bitem, ett_ndps);
6427 foffset = name_or_id(tvb, btree, foffset);
6428 foffset += align_4(tvb, foffset);
6429 /* End of NameorID */
6430 foffset = ndps_string(tvb, hf_ndps_method_name, btree, foffset);
6431 foffset = ndps_string(tvb, hf_ndps_method_ver, btree, foffset);
6432 foffset = ndps_string(tvb, hf_ndps_file_name, btree, foffset);
6433 proto_tree_add_item(btree, hf_ndps_admin_submit, tvb, foffset, 4, FALSE);
6435 /* End of DeliveryMethod */
6437 /* End of DeliveryMethodSet */
6438 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6440 case 0x0000000f: /* Get Delivery Method Information */
6441 /* Start of DeliveryMethod */
6442 /* Start of NameorID */
6443 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Method ID");
6444 atree = proto_item_add_subtree(aitem, ett_ndps);
6445 foffset = name_or_id(tvb, atree, foffset);
6446 /* End of NameorID */
6447 foffset = ndps_string(tvb, hf_ndps_method_name, atree, foffset);
6448 foffset = ndps_string(tvb, hf_ndps_method_ver, atree, foffset);
6449 foffset = ndps_string(tvb, hf_ndps_file_name, atree, foffset);
6450 proto_tree_add_item(atree, hf_ndps_admin_submit, tvb, foffset, 4, FALSE);
6452 /* End of DeliveryMethod */
6453 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Delivery Address");
6454 atree = proto_item_add_subtree(aitem, ett_ndps);
6455 number_of_items = tvb_get_ntohl(tvb, foffset);
6456 for (i = 1 ; i <= number_of_items; i++ )
6458 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Address %d", i);
6459 btree = proto_item_add_subtree(bitem, ett_ndps);
6460 foffset += address_item(tvb, btree, foffset);
6462 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6464 case 0x00000010: /* Get Notify NDS Object Name */
6465 proto_tree_add_item(ndps_tree, hf_ndps_items, tvb, foffset,
6468 foffset = ndps_string(tvb, hf_ndps_broker_name, ndps_tree, foffset);
6469 foffset = ndps_string(tvb, hf_ndps_tree, ndps_tree, foffset);
6470 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6472 case 0x00000011: /* Get Notify Session Information */
6473 proto_tree_add_item(ndps_tree, hf_ndps_get_session_type, tvb, foffset, 4, FALSE);
6475 proto_tree_add_item(ndps_tree, hf_time, tvb, foffset, 4, FALSE);
6477 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6483 case 0x06097a: /* Resman */
6486 case 0x00000001: /* Bind */
6487 length = tvb_get_ntohl(tvb, foffset);
6489 proto_tree_add_item(ndps_tree, hf_ndps_attribute_set, tvb, foffset, length, FALSE);
6491 case 0x00000002: /* Unbind */
6494 case 0x00000003: /* Add Resource File */
6495 case 0x00000004: /* Delete Resource File */
6496 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6498 case 0x00000005: /* List Resources */
6499 proto_tree_add_item(ndps_tree, hf_ndps_return_code, tvb, foffset, 4, FALSE);
6501 if (check_col(pinfo->cinfo, COL_INFO) && tvb_get_ntohl(tvb, foffset-4) != 0)
6502 col_add_fstr(pinfo->cinfo, COL_INFO, "R NDPS - Error");
6503 if (tvb_get_ntohl(tvb, foffset-4) != 0)
6507 proto_tree_add_item(ndps_tree, hf_ndps_status_flags, tvb, foffset, 4, FALSE);
6509 proto_tree_add_item(ndps_tree, hf_ndps_resource_list_type, tvb, foffset, 4, FALSE);
6510 resource_type = tvb_get_ntohl(tvb, foffset);
6512 switch (resource_type)
6514 case 0: /* Print Drivers */
6515 case 1: /* Printer Definitions */
6516 case 2: /* Printer Definitions Short */
6517 number_of_items = tvb_get_ntohl(tvb, foffset);
6519 for (i = 1 ; i <= number_of_items; i++ )
6521 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Definition %d", i);
6522 atree = proto_item_add_subtree(aitem, ett_ndps);
6523 if (tvb_get_ntohl(tvb, foffset)==0) { /* Offset for old type support */
6526 foffset += 4; /* Item always == 1 */
6527 foffset = ndps_string(tvb, hf_ndps_printer_manuf, atree, foffset);
6528 if (tvb_get_ntohl(tvb, foffset)==0) {
6532 foffset = ndps_string(tvb, hf_ndps_printer_type, atree, foffset);
6533 if (tvb_get_ntohl(tvb, foffset)==0) {
6537 foffset = ndps_string(tvb, hf_ndps_inf_file_name, atree, foffset);
6540 case 3: /* Banner Page Files */
6541 number_of_items = tvb_get_ntohl(tvb, foffset);
6543 for (i = 1 ; i <= number_of_items; i++ )
6545 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Banner %d", i);
6546 atree = proto_item_add_subtree(aitem, ett_ndps);
6547 foffset = ndps_string(tvb, hf_ndps_banner_name, atree, foffset);
6550 case 4: /* Font Types */
6551 number_of_items = tvb_get_ntohl(tvb, foffset);
6553 for (i = 1 ; i <= number_of_items; i++ )
6555 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Font %d", i);
6556 atree = proto_item_add_subtree(aitem, ett_ndps);
6557 foffset = ndps_string(tvb, hf_font_type_name, atree, foffset);
6560 case 7: /* Font Files */
6561 number_of_items = tvb_get_ntohl(tvb, foffset);
6563 for (i = 1 ; i <= number_of_items; i++ )
6565 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Font File %d", i);
6566 atree = proto_item_add_subtree(aitem, ett_ndps);
6567 foffset = ndps_string(tvb, hf_font_file_name, atree, foffset);
6570 case 5: /* Printer Driver Files */
6571 case 12: /* Printer Driver Files 2 */
6572 case 9: /* Generic Files */
6573 number_of_items = tvb_get_ntohl(tvb, foffset);
6575 for (i = 1 ; i <= number_of_items; i++ )
6577 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "File %d", i);
6578 atree = proto_item_add_subtree(aitem, ett_ndps);
6579 foffset = ndps_string(tvb, hf_ndps_prn_file_name, atree, foffset);
6580 foffset = ndps_string(tvb, hf_ndps_prn_dir_name, atree, foffset);
6581 foffset = ndps_string(tvb, hf_ndps_inf_file_name, atree, foffset);
6584 case 6: /* Printer Definition File */
6585 number_of_items = tvb_get_ntohl(tvb, foffset);
6587 for (i = 1 ; i <= number_of_items; i++ )
6589 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Definition %d", i);
6590 atree = proto_item_add_subtree(aitem, ett_ndps);
6591 foffset = ndps_string(tvb, hf_ndps_prn_file_name, atree, foffset);
6592 foffset = ndps_string(tvb, hf_ndps_prn_dir_name, atree, foffset);
6593 foffset = ndps_string(tvb, hf_ndps_inf_file_name, atree, foffset);
6595 number_of_items = tvb_get_ntohl(tvb, foffset);
6597 for (i = 1 ; i <= number_of_items; i++ )
6599 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Item %d", i);
6600 atree = proto_item_add_subtree(aitem, ett_ndps);
6601 foffset = ndps_string(tvb, hf_ndps_def_file_name, atree, foffset);
6602 number_of_items2 = tvb_get_ntohl(tvb, foffset);
6603 bitem = proto_tree_add_item(atree, hf_ndps_win31_items, tvb, foffset, 4, FALSE);
6604 btree = proto_item_add_subtree(bitem, ett_ndps);
6606 for (i = 1 ; i <= number_of_items2; i++ )
6608 foffset = ndps_string(tvb, hf_ndps_windows_key, btree, foffset);
6610 number_of_items2 = tvb_get_ntohl(tvb, foffset);
6611 bitem = proto_tree_add_item(atree, hf_ndps_win95_items, tvb, foffset, 4, FALSE);
6612 btree = proto_item_add_subtree(bitem, ett_ndps);
6614 for (i = 1 ; i <= number_of_items2; i++ )
6616 foffset = ndps_string(tvb, hf_ndps_windows_key, btree, foffset);
6620 case 10: /* Printer Definition File 2 */
6621 foffset = ndps_string(tvb, hf_ndps_def_file_name, ndps_tree, foffset);
6622 number_of_items = tvb_get_ntohl(tvb, foffset);
6624 for (i = 1 ; i <= number_of_items; i++ )
6626 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "OS %d", i);
6627 atree = proto_item_add_subtree(aitem, ett_ndps);
6628 proto_tree_add_item(atree, hf_os_type, tvb, foffset, 4, FALSE);
6630 number_of_items2 = tvb_get_ntohl(tvb, foffset);
6632 for (i = 1 ; i <= number_of_items2; i++ )
6634 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Key %d", i);
6635 btree = proto_item_add_subtree(bitem, ett_ndps);
6636 foffset = ndps_string(tvb, hf_ndps_windows_key, btree, foffset);
6640 case 8: /* Generic Type */
6641 case 11: /* Printer Driver Types 2 */
6642 case 13: /* Printer Driver Types Archive */
6643 number_of_items = tvb_get_ntohl(tvb, foffset);
6645 for (i = 1 ; i <= number_of_items; i++ )
6647 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Type %d", i);
6648 atree = proto_item_add_subtree(aitem, ett_ndps);
6649 foffset = ndps_string(tvb, hf_ndps_printer_manuf, atree, foffset);
6650 foffset = ndps_string(tvb, hf_ndps_printer_type, atree, foffset);
6651 foffset = ndps_string(tvb, hf_ndps_prn_file_name, atree, foffset);
6652 foffset = ndps_string(tvb, hf_ndps_prn_dir_name, atree, foffset);
6653 proto_tree_add_item(atree, hf_archive_type, tvb, foffset, 4, FALSE);
6655 proto_tree_add_item(atree, hf_archive_file_size, tvb, foffset, 4, FALSE);
6659 case 14: /* Languages Available */
6660 number_of_items = tvb_get_ntohl(tvb, foffset);
6662 for (i = 1 ; i <= number_of_items; i++ )
6664 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Language %d", i);
6665 atree = proto_item_add_subtree(aitem, ett_ndps);
6666 proto_tree_add_item(atree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
6674 case 0x00000006: /* Get Resource File */
6675 proto_tree_add_item(ndps_tree, hf_ndps_return_code, tvb, foffset, 4, FALSE);
6677 if (check_col(pinfo->cinfo, COL_INFO) && tvb_get_ntohl(tvb, foffset-4) != 0)
6678 col_add_fstr(pinfo->cinfo, COL_INFO, "R NDPS - Error");
6679 if (tvb_get_ntohl(tvb, foffset-4) != 0)
6683 proto_tree_add_item(ndps_tree, hf_get_status_flag, tvb, foffset, 4, FALSE);
6685 proto_tree_add_item(ndps_tree, hf_file_timestamp, tvb, foffset, 4, FALSE);
6687 proto_tree_add_item(ndps_tree, hf_ndps_data, tvb, foffset, -1, FALSE);
6689 case 0x00000007: /* Get Resource File Date */
6690 proto_tree_add_item(ndps_tree, hf_ndps_return_code, tvb, foffset, 4, FALSE);
6692 if (check_col(pinfo->cinfo, COL_INFO) && tvb_get_ntohl(tvb, foffset-4) != 0)
6693 col_add_fstr(pinfo->cinfo, COL_INFO, "R NDPS - Error");
6694 if (tvb_get_ntohl(tvb, foffset-4) != 0)
6698 proto_tree_add_item(ndps_tree, hf_file_timestamp, tvb, foffset, 4, FALSE);
6701 case 0x00000008: /* Get Resource Manager NDS Object Name */
6702 foffset = qualifiedname(tvb, ndps_tree, foffset);
6703 proto_tree_add_uint(ndps_tree, hf_ndps_error_val, tvb, foffset, 4, error_val);
6706 case 0x00000009: /* Get Resource Manager Session Information */
6707 proto_tree_add_item(ndps_tree, hf_ndps_get_resman_session_type, tvb, foffset, 4, FALSE);
6709 proto_tree_add_item(ndps_tree, hf_time, tvb, foffset, 4, FALSE);
6711 foffset = return_code(tvb, pinfo, ndps_tree, foffset);
6713 case 0x0000000a: /* Set Resource Language Context */
6714 proto_tree_add_item(ndps_tree, hf_ndps_return_code, tvb, foffset, 4, FALSE);
6716 if (check_col(pinfo->cinfo, COL_INFO) && tvb_get_ntohl(tvb, foffset-4) != 0)
6717 col_add_fstr(pinfo->cinfo, COL_INFO, "R NDPS - Error");
6718 if (tvb_get_ntohl(tvb, foffset-4) != 0)
6722 proto_tree_add_item(ndps_tree, hf_ndps_language_id, tvb, foffset, 4, FALSE);
6729 case 0x06097b: /* Delivery */
6732 case 0x00000001: /* Delivery Bind */
6733 proto_tree_add_item(ndps_tree, hf_ndps_return_code, tvb, foffset, 4, FALSE);
6735 if (check_col(pinfo->cinfo, COL_INFO) && tvb_get_ntohl(tvb, foffset-4) != 0)
6736 col_add_fstr(pinfo->cinfo, COL_INFO, "R NDPS - Error");
6738 case 0x00000002: /* Delivery Unbind */
6741 case 0x00000003: /* Delivery Send */
6742 case 0x00000004: /* Delivery Send2 */
6743 proto_tree_add_item(ndps_tree, hf_ndps_return_code, tvb, foffset, 4, FALSE);
6745 if (check_col(pinfo->cinfo, COL_INFO) && tvb_get_ntohl(tvb, foffset-4) != 0)
6746 col_add_fstr(pinfo->cinfo, COL_INFO, "R NDPS - Error");
6747 if (tvb_get_ntohl(tvb, foffset-4) != 0)
6751 aitem = proto_tree_add_text(ndps_tree, tvb, foffset, 0, "Failed Items");
6752 atree = proto_item_add_subtree(aitem, ett_ndps);
6753 number_of_items=tvb_get_ntohl(tvb, foffset);
6755 for (i = 1 ; i <= number_of_items; i++ )
6757 bitem = proto_tree_add_text(atree, tvb, foffset, 0, "Item %d", i);
6758 btree = proto_item_add_subtree(bitem, ett_ndps);
6759 length=tvb_get_ntohl(tvb, foffset);
6760 if(tvb_length_remaining(tvb, foffset) < length)
6764 proto_tree_add_item(btree, hf_ndps_item_ptr, tvb, foffset, length, FALSE);
6779 proto_register_ndps(void)
6781 static hf_register_info hf_ndps[] = {
6782 { &hf_ndps_record_mark,
6783 { "Record Mark", "ndps.record_mark", FT_UINT16, BASE_HEX, NULL, 0x0,
6784 "Record Mark", HFILL }},
6786 { &hf_ndps_packet_type,
6787 { "Packet Type", "ndps.packet_type",
6788 FT_UINT32, BASE_HEX, VALS(ndps_packet_types), 0x0,
6789 "Packet Type", HFILL }},
6792 { "Record Length", "ndps.record_length",
6793 FT_UINT16, BASE_DEC, NULL, 0x0,
6794 "Record Length", HFILL }},
6797 { "Exchange ID", "ndps.xid",
6798 FT_UINT32, BASE_HEX, NULL, 0x0,
6799 "Exchange ID", HFILL }},
6801 { &hf_ndps_rpc_version,
6802 { "RPC Version", "ndps.rpc_version",
6803 FT_UINT32, BASE_HEX, NULL, 0x0,
6804 "RPC Version", HFILL }},
6806 { &hf_spx_ndps_program,
6807 { "NDPS Program Number", "spx.ndps_program",
6808 FT_UINT32, BASE_HEX, VALS(spx_ndps_program_vals), 0x0,
6809 "NDPS Program Number", HFILL }},
6811 { &hf_spx_ndps_version,
6812 { "Program Version", "spx.ndps_version",
6813 FT_UINT32, BASE_DEC, NULL, 0x0,
6814 "Program Version", HFILL }},
6817 { "NDPS Error", "spx.ndps_error",
6818 FT_UINT32, BASE_HEX, NULL, 0x0,
6819 "NDPS Error", HFILL }},
6821 { &hf_spx_ndps_func_print,
6822 { "Print Program", "spx.ndps_func_print",
6823 FT_UINT32, BASE_HEX, VALS(spx_ndps_print_func_vals), 0x0,
6824 "Print Program", HFILL }},
6826 { &hf_spx_ndps_func_notify,
6827 { "Notify Program", "spx.ndps_func_notify",
6828 FT_UINT32, BASE_HEX, VALS(spx_ndps_notify_func_vals), 0x0,
6829 "Notify Program", HFILL }},
6831 { &hf_spx_ndps_func_delivery,
6832 { "Delivery Program", "spx.ndps_func_delivery",
6833 FT_UINT32, BASE_HEX, VALS(spx_ndps_deliver_func_vals), 0x0,
6834 "Delivery Program", HFILL }},
6836 { &hf_spx_ndps_func_registry,
6837 { "Registry Program", "spx.ndps_func_registry",
6838 FT_UINT32, BASE_HEX, VALS(spx_ndps_registry_func_vals), 0x0,
6839 "Registry Program", HFILL }},
6841 { &hf_spx_ndps_func_resman,
6842 { "ResMan Program", "spx.ndps_func_resman",
6843 FT_UINT32, BASE_HEX, VALS(spx_ndps_resman_func_vals), 0x0,
6844 "ResMan Program", HFILL }},
6846 { &hf_spx_ndps_func_broker,
6847 { "Broker Program", "spx.ndps_func_broker",
6848 FT_UINT32, BASE_HEX, VALS(spx_ndps_broker_func_vals), 0x0,
6849 "Broker Program", HFILL }},
6852 { "Number of Items", "ndps.items",
6853 FT_UINT32, BASE_DEC, NULL, 0x0,
6854 "Number of Items", HFILL }},
6857 { "Number of Objects", "ndps.objects",
6858 FT_UINT32, BASE_DEC, NULL, 0x0,
6859 "Number of Objects", HFILL }},
6861 { &hf_ndps_attributes,
6862 { "Number of Attributes", "ndps.attributes",
6863 FT_UINT32, BASE_DEC, NULL, 0x0,
6864 "Number of Attributes", HFILL }},
6867 { "Server", "ndps.sbuffer",
6868 FT_UINT32, BASE_DEC, NULL, 0x0,
6872 { "Connection", "ndps.rbuffer",
6873 FT_UINT32, BASE_DEC, NULL, 0x0,
6874 "Connection", HFILL }},
6876 { &hf_ndps_user_name,
6877 { "Trustee Name", "ndps.user_name",
6878 FT_STRING, BASE_NONE, NULL, 0x0,
6879 "Trustee Name", HFILL }},
6881 { &hf_ndps_broker_name,
6882 { "Broker Name", "ndps.broker_name",
6883 FT_STRING, BASE_NONE, NULL, 0x0,
6884 "Broker Name", HFILL }},
6887 { "Printer Name", "ndps.pa_name",
6888 FT_STRING, BASE_NONE, NULL, 0x0,
6889 "Printer Name", HFILL }},
6892 { "Tree", "ndps.tree",
6893 FT_STRING, BASE_NONE, NULL, 0x0,
6896 { &hf_ndps_reqframe,
6897 { "Request Frame", "ndps.reqframe",
6898 FT_FRAMENUM, BASE_NONE, NULL, 0x0,
6899 "Request Frame", HFILL }},
6901 { &hf_ndps_error_val,
6902 { "Return Status", "ndps.error_val",
6903 FT_UINT32, BASE_HEX, VALS(ndps_error_types), 0x0,
6904 "Return Status", HFILL }},
6907 { "Object ID", "ndps.object",
6908 FT_UINT32, BASE_HEX, NULL, 0x0,
6909 "Object ID", HFILL }},
6911 { &hf_ndps_cred_type,
6912 { "Credential Type", "ndps.cred_type",
6913 FT_UINT32, BASE_HEX, VALS(ndps_credential_enum), 0x0,
6914 "Credential Type", HFILL }},
6916 { &hf_ndps_server_name,
6917 { "Server Name", "ndps.server_name",
6918 FT_STRING, BASE_DEC, NULL, 0x0,
6919 "Server Name", HFILL }},
6921 { &hf_ndps_connection,
6922 { "Connection", "ndps.connection",
6923 FT_UINT16, BASE_DEC, NULL, 0x0,
6924 "Connection", HFILL }},
6926 { &hf_ndps_ext_error,
6927 { "Extended Error Code", "ndps.ext_error",
6928 FT_UINT32, BASE_HEX, NULL, 0x0,
6929 "Extended Error Code", HFILL }},
6931 { &hf_ndps_auth_null,
6932 { "Auth Null", "ndps.auth_null",
6933 FT_BYTES, BASE_NONE, NULL, 0x0,
6934 "Auth Null", HFILL }},
6936 { &hf_ndps_rpc_accept,
6937 { "RPC Accept or Deny", "ndps.rpc_acc",
6938 FT_UINT32, BASE_HEX, VALS(true_false), 0x0,
6939 "RPC Accept or Deny", HFILL }},
6941 { &hf_ndps_rpc_acc_stat,
6942 { "RPC Accept Status", "ndps.rpc_acc_stat",
6943 FT_UINT32, BASE_HEX, VALS(accept_stat), 0x0,
6944 "RPC Accept Status", HFILL }},
6946 { &hf_ndps_rpc_rej_stat,
6947 { "RPC Reject Status", "ndps.rpc_rej_stat",
6948 FT_UINT32, BASE_HEX, VALS(reject_stat), 0x0,
6949 "RPC Reject Status", HFILL }},
6951 { &hf_ndps_rpc_acc_results,
6952 { "RPC Accept Results", "ndps.rpc_acc_res",
6953 FT_UINT32, BASE_HEX, NULL, 0x0,
6954 "RPC Accept Results", HFILL }},
6956 { &hf_ndps_problem_type,
6957 { "Problem Type", "ndps.rpc_prob_type",
6958 FT_UINT32, BASE_HEX, VALS(error_type_enum), 0x0,
6959 "Problem Type", HFILL }},
6961 { &hf_security_problem_type,
6962 { "Security Problem", "ndps.rpc_sec_prob",
6963 FT_UINT32, BASE_HEX, VALS(security_problem_enum), 0x0,
6964 "Security Problem", HFILL }},
6966 { &hf_service_problem_type,
6967 { "Service Problem", "ndps.rpc_serv_prob",
6968 FT_UINT32, BASE_HEX, VALS(service_problem_enum), 0x0,
6969 "Service Problem", HFILL }},
6971 { &hf_access_problem_type,
6972 { "Access Problem", "ndps.rpc_acc_prob",
6973 FT_UINT32, BASE_HEX, VALS(access_problem_enum), 0x0,
6974 "Access Problem", HFILL }},
6976 { &hf_printer_problem_type,
6977 { "Printer Problem", "ndps.rpc_print_prob",
6978 FT_UINT32, BASE_HEX, VALS(printer_problem_enum), 0x0,
6979 "Printer Problem", HFILL }},
6981 { &hf_selection_problem_type,
6982 { "Selection Problem", "ndps.rpc_sel_prob",
6983 FT_UINT32, BASE_HEX, VALS(selection_problem_enum), 0x0,
6984 "Selection Problem", HFILL }},
6986 { &hf_doc_access_problem_type,
6987 { "Document Access Problem", "ndps.rpc_doc_acc_prob",
6988 FT_UINT32, BASE_HEX, VALS(doc_access_problem_enum), 0x0,
6989 "Document Access Problem", HFILL }},
6991 { &hf_attribute_problem_type,
6992 { "Attribute Problem", "ndps.rpc_attr_prob",
6993 FT_UINT32, BASE_HEX, VALS(attribute_problem_enum), 0x0,
6994 "Attribute Problem", HFILL }},
6996 { &hf_update_problem_type,
6997 { "Update Problem", "ndps.rpc_update_prob",
6998 FT_UINT32, BASE_HEX, VALS(update_problem_enum), 0x0,
6999 "Update Problem", HFILL }},
7002 { "Object ID Type", "ndps.rpc_obj_id_type",
7003 FT_UINT32, BASE_HEX, VALS(obj_identification_enum), 0x0,
7004 "Object ID Type", HFILL }},
7006 { &hf_oid_struct_size,
7007 { "OID Struct Size", "ndps.rpc_oid_struct_size",
7008 FT_UINT16, BASE_HEX, NULL, 0x0,
7009 "OID Struct Size", HFILL }},
7012 { "Object Name", "ndps.ndps_object_name",
7013 FT_STRING, BASE_NONE, NULL, 0x0,
7014 "Object Name", HFILL }},
7016 { &hf_ndps_document_number,
7017 { "Document Number", "ndps.ndps_doc_num",
7018 FT_UINT32, BASE_HEX, NULL, 0x0,
7019 "Document Number", HFILL }},
7021 { &hf_ndps_nameorid,
7022 { "Name or ID Type", "ndps.ndps_nameorid",
7023 FT_UINT32, BASE_HEX, VALS(nameorid_enum), 0x0,
7024 "Name or ID Type", HFILL }},
7026 { &hf_local_object_name,
7027 { "Local Object Name", "ndps.ndps_loc_object_name",
7028 FT_STRING, BASE_NONE, NULL, 0x0,
7029 "Local Object Name", HFILL }},
7032 { "Printer Name", "ndps.ndps_printer_name",
7033 FT_STRING, BASE_NONE, NULL, 0x0,
7034 "Printer Name", HFILL }},
7036 { &hf_ndps_qualified_name,
7037 { "Qualified Name Type", "ndps.ndps_qual_name_type",
7038 FT_UINT32, BASE_HEX, VALS(qualified_name_enum), 0x0,
7039 "Qualified Name Type", HFILL }},
7041 { &hf_ndps_qualified_name2,
7042 { "Qualified Name Type", "ndps.ndps_qual_name_type2",
7043 FT_UINT32, BASE_HEX, VALS(qualified_name_enum2), 0x0,
7044 "Qualified Name Type", HFILL }},
7047 { &hf_ndps_item_count,
7048 { "Number of Items", "ndps.ndps_item_count",
7049 FT_UINT32, BASE_DEC, NULL, 0x0,
7050 "Number of Items", HFILL }},
7052 { &hf_ndps_qualifier,
7053 { "Qualifier", "ndps.ndps_qual",
7054 FT_UINT32, BASE_HEX, NULL, 0x0,
7055 "Qualifier", HFILL }},
7057 { &hf_ndps_lib_error,
7058 { "Lib Error", "ndps.ndps_lib_error",
7059 FT_UINT32, BASE_HEX, VALS(ndps_error_types), 0x0,
7060 "Lib Error", HFILL }},
7062 { &hf_ndps_other_error,
7063 { "Other Error", "ndps.ndps_other_error",
7064 FT_UINT32, BASE_HEX, VALS(ndps_error_types), 0x0,
7065 "Other Error", HFILL }},
7067 { &hf_ndps_other_error_2,
7068 { "Other Error 2", "ndps.ndps_other_error_2",
7069 FT_UINT32, BASE_HEX, VALS(ndps_error_types), 0x0,
7070 "Other Error 2", HFILL }},
7073 { "Session Handle", "ndps.ndps_session",
7074 FT_UINT32, BASE_HEX, NULL, 0x0,
7075 "Session Handle", HFILL }},
7077 { &hf_ndps_abort_flag,
7078 { "Abort?", "ndps.ndps_abort",
7079 FT_BOOLEAN, BASE_NONE, NULL, 0x0,
7082 { &hf_obj_attribute_type,
7083 { "Value Syntax", "ndps.ndps_attrib_type",
7084 FT_UINT32, BASE_HEX, VALS(ndps_attribute_enum), 0x0,
7085 "Value Syntax", HFILL }},
7087 { &hf_ndps_attribute_value,
7088 { "Value", "ndps.attribue_value",
7089 FT_UINT32, BASE_HEX, NULL, 0x0,
7092 { &hf_ndps_lower_range,
7093 { "Lower Range", "ndps.lower_range",
7094 FT_UINT32, BASE_HEX, NULL, 0x0,
7095 "Lower Range", HFILL }},
7097 { &hf_ndps_upper_range,
7098 { "Upper Range", "ndps.upper_range",
7099 FT_UINT32, BASE_HEX, NULL, 0x0,
7100 "Upper Range", HFILL }},
7103 { "Value", "ndps.n64",
7104 FT_BYTES, BASE_NONE, NULL, 0x0,
7107 { &hf_ndps_lower_range_n64,
7108 { "Lower Range", "ndps.lower_range_n64",
7109 FT_BYTES, BASE_NONE, NULL, 0x0,
7110 "Lower Range", HFILL }},
7112 { &hf_ndps_upper_range_n64,
7113 { "Upper Range", "ndps.upper_range_n64",
7114 FT_BYTES, BASE_NONE, NULL, 0x0,
7115 "Upper Range", HFILL }},
7117 { &hf_ndps_attrib_boolean,
7118 { "Value?", "ndps.ndps_attrib_boolean",
7119 FT_BOOLEAN, BASE_NONE, NULL, 0x0,
7122 { &hf_ndps_realization,
7123 { "Realization Type", "ndps.ndps_realization",
7124 FT_UINT32, BASE_HEX, VALS(ndps_realization_enum), 0x0,
7125 "Realization Type", HFILL }},
7127 { &hf_ndps_xdimension_n64,
7128 { "X Dimension", "ndps.xdimension_n64",
7129 FT_BYTES, BASE_NONE, NULL, 0x0,
7130 "X Dimension", HFILL }},
7132 { &hf_ndps_ydimension_n64,
7133 { "Y Dimension", "ndps.xdimension_n64",
7134 FT_BYTES, BASE_NONE, NULL, 0x0,
7135 "Y Dimension", HFILL }},
7137 { &hf_ndps_dim_value,
7138 { "Dimension Value Type", "ndps.ndps_dim_value",
7139 FT_UINT32, BASE_HEX, VALS(ndps_dim_value_enum), 0x0,
7140 "Dimension Value Type", HFILL }},
7142 { &hf_ndps_dim_flag,
7143 { "Dimension Flag", "ndps.ndps_dim_falg",
7144 FT_UINT32, BASE_HEX, NULL, 0x0,
7145 "Dimension Flag", HFILL }},
7147 { &hf_ndps_xydim_value,
7148 { "XY Dimension Value Type", "ndps.ndps_xydim_value",
7149 FT_UINT32, BASE_HEX, VALS(ndps_xydim_value_enum), 0x0,
7150 "XY Dimension Value Type", HFILL }},
7152 { &hf_ndps_location_value,
7153 { "Location Value Type", "ndps.ndps_location_value",
7154 FT_UINT32, BASE_HEX, VALS(ndps_location_value_enum), 0x0,
7155 "Location Value Type", HFILL }},
7157 { &hf_ndps_xmin_n64,
7158 { "Minimum X Dimension", "ndps.xmin_n64",
7159 FT_BYTES, BASE_NONE, NULL, 0x0,
7160 "Minimum X Dimension", HFILL }},
7162 { &hf_ndps_xmax_n64,
7163 { "Maximum X Dimension", "ndps.xmax_n64",
7164 FT_BYTES, BASE_NONE, NULL, 0x0,
7165 "Maximum X Dimension", HFILL }},
7167 { &hf_ndps_ymin_n64,
7168 { "Minimum Y Dimension", "ndps.ymin_n64",
7169 FT_BYTES, BASE_NONE, NULL, 0x0,
7170 "Minimum Y Dimension", HFILL }},
7172 { &hf_ndps_ymax_n64,
7173 { "Maximum Y Dimension", "ndps.ymax_n64",
7174 FT_BYTES, BASE_NONE, NULL, 0x0,
7175 "Maximum Y Dimension", HFILL }},
7177 { &hf_ndps_edge_value,
7178 { "Edge Value", "ndps.ndps_edge_value",
7179 FT_UINT32, BASE_HEX, VALS(ndps_edge_value_enum), 0x0,
7180 "Edge Value", HFILL }},
7182 { &hf_ndps_cardinal_or_oid,
7183 { "Cardinal or OID", "ndps.ndps_car_or_oid",
7184 FT_UINT32, BASE_HEX, VALS(ndps_card_or_oid_enum), 0x0,
7185 "Cardinal or OID", HFILL }},
7187 { &hf_ndps_cardinal_name_or_oid,
7188 { "Cardinal Name or OID", "ndps.ndps_car_name_or_oid",
7189 FT_UINT32, BASE_HEX, VALS(ndps_card_name_or_oid_enum), 0x0,
7190 "Cardinal Name or OID", HFILL }},
7192 { &hf_ndps_integer_or_oid,
7193 { "Integer or OID", "ndps.ndps_integer_or_oid",
7194 FT_UINT32, BASE_HEX, VALS(ndps_integer_or_oid_enum), 0x0,
7195 "Integer or OID", HFILL }},
7197 { &hf_ndps_profile_id,
7198 { "Profile ID", "ndps.ndps_profile_id",
7199 FT_UINT32, BASE_HEX, NULL, 0x0,
7200 "Profile ID", HFILL }},
7202 { &hf_ndps_persistence,
7203 { "Persistence", "ndps.ndps_persistence",
7204 FT_UINT32, BASE_HEX, VALS(ndps_persistence_enum), 0x0,
7205 "Persistence", HFILL }},
7207 { &hf_ndps_language_id,
7208 { "Language ID", "ndps.ndps_lang_id",
7209 FT_UINT32, BASE_HEX, NULL, 0x0,
7210 "Language ID", HFILL }},
7213 { "Address Type", "ndps.ndps_address_type",
7214 FT_UINT32, BASE_HEX, VALS(ndps_address_type_enum), 0x0,
7215 "Address Type", HFILL }},
7218 { "Address", "ndps.ndps_address",
7219 FT_UINT32, BASE_HEX, VALS(ndps_address_enum), 0x0,
7220 "Address", HFILL }},
7222 { &hf_ndps_add_bytes,
7223 { "Address Bytes", "ndps.add_bytes",
7224 FT_BYTES, BASE_NONE, NULL, 0x0,
7225 "Address Bytes", HFILL }},
7227 { &hf_ndps_event_type,
7228 { "Event Type", "ndps.ndps_event_type",
7229 FT_UINT32, BASE_HEX, NULL, 0x0,
7230 "Event Type", HFILL }},
7232 { &hf_ndps_event_object_identifier,
7233 { "Event Object Type", "ndps.ndps_event_object_identifier",
7234 FT_UINT32, BASE_HEX, VALS(ndps_event_object_enum), 0x0,
7235 "Event Object Type", HFILL }},
7237 { &hf_ndps_octet_string,
7238 { "Octet String", "ndps.octet_string",
7239 FT_BYTES, BASE_NONE, NULL, 0x0,
7240 "Octet String", HFILL }},
7243 { "Scope", "ndps.scope",
7244 FT_UINT32, BASE_HEX, NULL, 0x0,
7248 { "Address Length", "ndps.addr_len",
7249 FT_UINT32, BASE_DEC, NULL, 0x0,
7250 "Address Length", HFILL }},
7253 { "IPX Network", "ndps.net",
7254 FT_IPXNET, BASE_NONE, NULL, 0x0,
7258 { "Node", "ndps.node",
7259 FT_ETHER, BASE_NONE, NULL, 0x0,
7263 { "IPX Socket", "ndps.socket",
7264 FT_UINT16, BASE_HEX, NULL, 0x0,
7265 "IPX Socket", HFILL }},
7268 { "IP Port", "ndps.port",
7269 FT_UINT16, BASE_DEC, NULL, 0x0,
7270 "IP Port", HFILL }},
7273 { "IP Address", "ndps.ip",
7274 FT_IPv4, BASE_DEC, NULL, 0x0,
7275 "IP Address", HFILL }},
7277 { &hf_ndps_server_type,
7278 { "NDPS Server Type", "ndps.ndps_server_type",
7279 FT_UINT32, BASE_HEX, VALS(ndps_server_type_enum), 0x0,
7280 "NDPS Server Type", HFILL }},
7282 { &hf_ndps_service_type,
7283 { "NDPS Service Type", "ndps.ndps_service_type",
7284 FT_UINT32, BASE_HEX, VALS(ndps_service_type_enum), 0x0,
7285 "NDPS Service Type", HFILL }},
7287 { &hf_ndps_service_enabled,
7288 { "Service Enabled?", "ndps.ndps_service_enabled",
7289 FT_BOOLEAN, BASE_NONE, NULL, 0x0,
7290 "Service Enabled?", HFILL }},
7292 { &hf_ndps_method_name,
7293 { "Method Name", "ndps.method_name",
7294 FT_STRING, BASE_NONE, NULL, 0x0,
7295 "Method Name", HFILL }},
7297 { &hf_ndps_method_ver,
7298 { "Method Version", "ndps.method_ver",
7299 FT_STRING, BASE_NONE, NULL, 0x0,
7300 "Method Version", HFILL }},
7302 { &hf_ndps_file_name,
7303 { "File Name", "ndps.file_name",
7304 FT_STRING, BASE_NONE, NULL, 0x0,
7305 "File Name", HFILL }},
7307 { &hf_ndps_admin_submit,
7308 { "Admin Submit Flag?", "ndps.admin_submit_flag",
7309 FT_BOOLEAN, BASE_NONE, NULL, 0x0,
7310 "Admin Submit Flag?", HFILL }},
7313 { "Object ID", "ndps.oid",
7314 FT_BYTES, BASE_NONE, NULL, 0x0,
7315 "Object ID", HFILL }},
7317 { &hf_ndps_object_op,
7318 { "Operation", "ndps.ndps_object_op",
7319 FT_UINT32, BASE_HEX, VALS(ndps_object_op_enum), 0x0,
7320 "Operation", HFILL }},
7323 { "Answer Time", "ndps.answer_time",
7324 FT_UINT32, BASE_DEC, NULL, 0x0,
7325 "Answer Time", HFILL }},
7327 { &hf_oid_asn1_type,
7328 { "ASN.1 Type", "ndps.asn1_type",
7329 FT_UINT16, BASE_DEC, NULL, 0x0,
7330 "ASN.1 Type", HFILL }},
7332 { &hf_ndps_item_ptr,
7333 { "Item Pointer", "ndps.item_ptr",
7334 FT_BYTES, BASE_DEC, NULL, 0x0,
7335 "Item Pointer", HFILL }},
7338 { "Length", "ndps.ndps_len",
7339 FT_UINT16, BASE_DEC, NULL, 0x0,
7343 { "Limit Encountered", "ndps.ndps_limit_enc",
7344 FT_UINT32, BASE_HEX, VALS(ndps_limit_enc_enum), 0x0,
7345 "Limit Encountered", HFILL }},
7347 { &hf_ndps_delivery_add_type,
7348 { "Delivery Address Type", "ndps.ndps_delivery_add_type",
7349 FT_UINT32, BASE_HEX, VALS(ndps_delivery_add_enum), 0x0,
7350 "Delivery Address Type", HFILL }},
7352 { &hf_ndps_criterion_type,
7353 { "Criterion Type", "ndps.ndps_criterion_type",
7354 FT_UINT32, BASE_HEX, VALS(ndps_attribute_enum), 0x0,
7355 "Criterion Type", HFILL }},
7357 { &hf_ndps_ignored_type,
7358 { "Ignored Type", "ndps.ndps_ignored_type",
7359 FT_UINT32, BASE_HEX, VALS(ndps_attribute_enum), 0x0,
7360 "Ignored Type", HFILL }},
7362 { &hf_ndps_resource_type,
7363 { "Resource Type", "ndps.ndps_resource_type",
7364 FT_UINT32, BASE_HEX, VALS(ndps_resource_enum), 0x0,
7365 "Resource Type", HFILL }},
7367 { &hf_ndps_identifier_type,
7368 { "Identifier Type", "ndps.ndps_identifier_type",
7369 FT_UINT32, BASE_HEX, VALS(ndps_identifier_enum), 0x0,
7370 "Identifier Type", HFILL }},
7372 { &hf_ndps_page_flag,
7373 { "Page Flag", "ndps.ndps_page_flag",
7374 FT_UINT32, BASE_HEX, NULL, 0x0,
7375 "Page Flag", HFILL }},
7377 { &hf_ndps_media_type,
7378 { "Media Type", "ndps.ndps_media_type",
7379 FT_UINT32, BASE_HEX, VALS(ndps_media_enum), 0x0,
7380 "Media Type", HFILL }},
7382 { &hf_ndps_page_size,
7383 { "Page Size", "ndps.ndps_page_size",
7384 FT_UINT32, BASE_HEX, VALS(ndps_page_size_enum), 0x0,
7385 "Page Size", HFILL }},
7387 { &hf_ndps_direction,
7388 { "Direction", "ndps.ndps_direction",
7389 FT_UINT32, BASE_HEX, VALS(ndps_pres_direction_enum), 0x0,
7390 "Direction", HFILL }},
7392 { &hf_ndps_page_order,
7393 { "Page Order", "ndps.ndps_page_order",
7394 FT_UINT32, BASE_HEX, VALS(ndps_page_order_enum), 0x0,
7395 "Page Order", HFILL }},
7397 { &hf_ndps_medium_size,
7398 { "Medium Size", "ndps.ndps_medium_size",
7399 FT_UINT32, BASE_HEX, VALS(ndps_medium_size_enum), 0x0,
7400 "Medium Size", HFILL }},
7402 { &hf_ndps_long_edge_feeds,
7403 { "Long Edge Feeds?", "ndps.ndps_long_edge_feeds",
7404 FT_BOOLEAN, BASE_NONE, NULL, 0x0,
7405 "Long Edge Feeds?", HFILL }},
7407 { &hf_ndps_inc_across_feed,
7408 { "Increment Across Feed", "ndps.inc_across_feed",
7409 FT_BYTES, BASE_NONE, NULL, 0x0,
7410 "Increment Across Feed", HFILL }},
7412 { &hf_ndps_size_inc_in_feed,
7413 { "Size Increment in Feed", "ndps.size_inc_in_feed",
7414 FT_BYTES, BASE_NONE, NULL, 0x0,
7415 "Size Increment in Feed", HFILL }},
7417 { &hf_ndps_page_orientation,
7418 { "Page Orientation", "ndps.ndps_page_orientation",
7419 FT_UINT32, BASE_HEX, VALS(ndps_page_orientation_enum), 0x0,
7420 "Page Orientation", HFILL }},
7422 { &hf_ndps_numbers_up,
7423 { "Numbers Up", "ndps.ndps_numbers_up",
7424 FT_UINT32, BASE_HEX, VALS(ndps_numbers_up_enum), 0x0,
7425 "Numbers Up", HFILL }},
7427 { &hf_ndps_xdimension,
7428 { "X Dimension", "ndps.ndps_xdimension",
7429 FT_UINT32, BASE_HEX, NULL, 0x0,
7430 "X Dimension", HFILL }},
7432 { &hf_ndps_ydimension,
7433 { "Y Dimension", "ndps.ndps_ydimension",
7434 FT_UINT32, BASE_HEX, NULL, 0x0,
7435 "Y Dimension", HFILL }},
7437 { &hf_ndps_state_severity,
7438 { "State Severity", "ndps.ndps_state_severity",
7439 FT_UINT32, BASE_HEX, VALS(ndps_state_severity_enum), 0x0,
7440 "State Severity", HFILL }},
7442 { &hf_ndps_training,
7443 { "Training", "ndps.ndps_training",
7444 FT_UINT32, BASE_HEX, VALS(ndps_training_enum), 0x0,
7445 "Training", HFILL }},
7447 { &hf_ndps_colorant_set,
7448 { "Colorant Set", "ndps.ndps_colorant_set",
7449 FT_UINT32, BASE_HEX, VALS(ndps_colorant_set_enum), 0x0,
7450 "Colorant Set", HFILL }},
7452 { &hf_ndps_card_enum_time,
7453 { "Cardinal, Enum, or Time", "ndps.ndps_card_enum_time",
7454 FT_UINT32, BASE_HEX, VALS(ndps_card_enum_time_enum), 0x0,
7455 "Cardinal, Enum, or Time", HFILL }},
7457 { &hf_ndps_attrs_arg,
7458 { "List Attribute Operation", "ndps.ndps_attrs_arg",
7459 FT_UINT32, BASE_HEX, VALS(ndps_attrs_arg_enum), 0x0,
7460 "List Attribute Operation", HFILL }},
7463 { "Context", "ndps.context",
7464 FT_BYTES, BASE_NONE, NULL, 0x0,
7465 "Context", HFILL }},
7468 { "Filter Type", "ndps.ndps_filter",
7469 FT_UINT32, BASE_HEX, VALS(ndps_filter_enum), 0x0,
7470 "Filter Type", HFILL }},
7472 { &hf_ndps_item_filter,
7473 { "Filter Item Operation", "ndps.ndps_filter_item",
7474 FT_UINT32, BASE_HEX, VALS(ndps_filter_item_enum), 0x0,
7475 "Filter Item Operation", HFILL }},
7477 { &hf_ndps_substring_match,
7478 { "Substring Match", "ndps.ndps_substring_match",
7479 FT_UINT32, BASE_HEX, VALS(ndps_match_criteria_enum), 0x0,
7480 "Substring Match", HFILL }},
7482 { &hf_ndps_time_limit,
7483 { "Time Limit", "ndps.ndps_time_limit",
7484 FT_UINT32, BASE_DEC, NULL, 0x0,
7485 "Time Limit", HFILL }},
7487 { &hf_ndps_count_limit,
7488 { "Count Limit", "ndps.ndps_count_limit",
7489 FT_UINT32, BASE_DEC, NULL, 0x0,
7490 "Count Limit", HFILL }},
7492 { &hf_ndps_operator,
7493 { "Operator Type", "ndps.ndps_operator",
7494 FT_UINT32, BASE_DEC, VALS(ndps_operator_enum), 0x0,
7495 "Operator Type", HFILL }},
7497 { &hf_ndps_password,
7498 { "Password", "ndps.password",
7499 FT_BYTES, BASE_NONE, NULL, 0x0,
7500 "Password", HFILL }},
7502 { &hf_ndps_retrieve_restrictions,
7503 { "Retrieve Restrictions", "ndps.ndps_ret_restrict",
7504 FT_UINT32, BASE_DEC, NULL, 0x0,
7505 "Retrieve Restrictions", HFILL }},
7507 { &hf_bind_security,
7508 { "Bind Security Options", "ndps.ndps_bind_security",
7509 FT_UINT32, BASE_DEC, NULL, 0x0,
7510 "Bind Security Options", HFILL }},
7512 { &hf_ndps_max_items,
7513 { "Maximum Items in List", "ndps.ndps_max_items",
7514 FT_UINT32, BASE_DEC, NULL, 0x0,
7515 "Maximum Items in List", HFILL }},
7517 { &hf_ndps_status_flags,
7518 { "Status Flag", "ndps.ndps_status_flags",
7519 FT_UINT32, BASE_DEC, NULL, 0x0,
7520 "Status Flag", HFILL }},
7522 { &hf_ndps_resource_list_type,
7523 { "Resource Type", "ndps.ndps_resource_type",
7524 FT_UINT32, BASE_DEC, VALS(ndps_resource_type_enum), 0x0,
7525 "Resource Type", HFILL }},
7528 { "OS Type", "ndps.os_type",
7529 FT_UINT32, BASE_DEC, VALS(ndps_os_type_enum), 0x0,
7530 "OS Type", HFILL }},
7532 { &hf_ndps_printer_type,
7533 { "Printer Type", "ndps.prn_type",
7534 FT_STRING, BASE_NONE, NULL, 0x0,
7535 "Printer Type", HFILL }},
7537 { &hf_ndps_printer_manuf,
7538 { "Printer Manufacturer", "ndps.prn_manuf",
7539 FT_STRING, BASE_NONE, NULL, 0x0,
7540 "Printer Manufacturer", HFILL }},
7542 { &hf_ndps_inf_file_name,
7543 { "INF File Name", "ndps.inf_file_name",
7544 FT_STRING, BASE_NONE, NULL, 0x0,
7545 "INF File Name", HFILL }},
7547 { &hf_ndps_vendor_dir,
7548 { "Vendor Directory", "ndps.vendor_dir",
7549 FT_STRING, BASE_NONE, NULL, 0x0,
7550 "Vendor Directory", HFILL }},
7553 { "Banner Type", "ndps.banner_type",
7554 FT_UINT32, BASE_DEC, VALS(ndps_banner_type_enum), 0x0,
7555 "Banner Type", HFILL }},
7558 { "Font Type", "ndps.font_type",
7559 FT_UINT32, BASE_DEC, VALS(ndps_font_type_enum), 0x0,
7560 "Font Type", HFILL }},
7563 { "Printer ID", "ndps.printer_id",
7564 FT_BYTES, BASE_NONE, NULL, 0x0,
7565 "Printer ID", HFILL }},
7567 { &hf_ndps_font_name,
7568 { "Font Name", "ndps.font_name",
7569 FT_STRING, BASE_NONE, NULL, 0x0,
7570 "Font Name", HFILL }},
7572 { &hf_ndps_return_code,
7573 { "Return Code", "ndps.ret_code",
7574 FT_UINT32, BASE_HEX, VALS(ndps_error_types), 0x0,
7575 "Return Code", HFILL }},
7577 { &hf_ndps_banner_name,
7578 { "Banner Name", "ndps.banner_name",
7579 FT_STRING, BASE_NONE, NULL, 0x0,
7580 "Banner Name", HFILL }},
7582 { &hf_font_type_name,
7583 { "Font Type Name", "ndps.font_type_name",
7584 FT_STRING, BASE_NONE, NULL, 0x0,
7585 "Font Type Name", HFILL }},
7587 { &hf_font_file_name,
7588 { "Font File Name", "ndps.font_file_name",
7589 FT_STRING, BASE_NONE, NULL, 0x0,
7590 "Font File Name", HFILL }},
7592 { &hf_ndps_prn_file_name,
7593 { "Printer File Name", "ndps.print_file_name",
7594 FT_STRING, BASE_NONE, NULL, 0x0,
7595 "Printer File Name", HFILL }},
7597 { &hf_ndps_prn_dir_name,
7598 { "Printer Directory Name", "ndps.print_dir_name",
7599 FT_STRING, BASE_NONE, NULL, 0x0,
7600 "Printer Directory Name", HFILL }},
7602 { &hf_ndps_def_file_name,
7603 { "Printer Definition Name", "ndps.print_def_name",
7604 FT_STRING, BASE_NONE, NULL, 0x0,
7605 "Printer Definition Name", HFILL }},
7607 { &hf_ndps_win31_items,
7608 { "Windows 31 Keys", "ndps.win31_keys",
7609 FT_UINT32, BASE_DEC, NULL, 0x0,
7610 "Windows 31 Keys", HFILL }},
7612 { &hf_ndps_win95_items,
7613 { "Windows 95 Keys", "ndps.win95_keys",
7614 FT_UINT32, BASE_DEC, NULL, 0x0,
7615 "Windows 95 Keys", HFILL }},
7617 { &hf_ndps_windows_key,
7618 { "Windows Key", "ndps.windows_key",
7619 FT_STRING, BASE_NONE, NULL, 0x0,
7620 "Windows Key", HFILL }},
7623 { "Archive Type", "ndps.archive_type",
7624 FT_UINT32, BASE_DEC, VALS(ndps_archive_enum), 0x0,
7625 "Archive Type", HFILL }},
7627 { &hf_archive_file_size,
7628 { "Archive File Size", "ndps.archive_size",
7629 FT_UINT32, BASE_DEC, NULL, 0x0,
7630 "Archive File Size", HFILL }},
7632 { &hf_ndps_segment_overlap,
7633 { "Segment overlap", "ndps.segment.overlap", FT_BOOLEAN, BASE_NONE,
7634 NULL, 0x0, "Segment overlaps with other segments", HFILL }},
7636 { &hf_ndps_segment_overlap_conflict,
7637 { "Conflicting data in segment overlap", "ndps.segment.overlap.conflict",
7638 FT_BOOLEAN, BASE_NONE,
7639 NULL, 0x0, "Overlapping segments contained conflicting data", HFILL }},
7641 { &hf_ndps_segment_multiple_tails,
7642 { "Multiple tail segments found", "ndps.segment.multipletails",
7643 FT_BOOLEAN, BASE_NONE,
7644 NULL, 0x0, "Several tails were found when desegmenting the packet", HFILL }},
7646 { &hf_ndps_segment_too_long_segment,
7647 { "Segment too long", "ndps.segment.toolongsegment", FT_BOOLEAN, BASE_NONE,
7648 NULL, 0x0, "Segment contained data past end of packet", HFILL }},
7650 { &hf_ndps_segment_error,
7651 {"Desegmentation error", "ndps.segment.error", FT_FRAMENUM, BASE_NONE,
7652 NULL, 0x0, "Desegmentation error due to illegal segments", HFILL }},
7655 { "NDPS Fragment", "ndps.fragment", FT_FRAMENUM, BASE_NONE,
7656 NULL, 0x0, "NDPS Fragment", HFILL }},
7658 { &hf_ndps_segments,
7659 { "NDPS Fragments", "ndps.fragments", FT_NONE, BASE_NONE,
7660 NULL, 0x0, "NDPS Fragments", HFILL }},
7663 { "[Data]", "ndps.data", FT_NONE, BASE_NONE,
7664 NULL, 0x0, "[Data]", HFILL }},
7666 { &hf_get_status_flag,
7667 { "Get Status Flag", "ndps.get_status_flags",
7668 FT_UINT32, BASE_DEC, NULL, 0x0,
7669 "Get Status Flag", HFILL }},
7672 { "Resource Type", "ndps.res_type",
7673 FT_UINT32, BASE_DEC, VALS(ndps_res_type_enum), 0x0,
7674 "Resource Type", HFILL }},
7676 { &hf_file_timestamp,
7677 { "File Time Stamp", "ndps.file_time_stamp",
7678 FT_UINT32, BASE_DEC, NULL, 0x0,
7679 "File Time Stamp", HFILL }},
7682 { "Print Type", "ndps.print_arg",
7683 FT_UINT32, BASE_DEC, VALS(ndps_print_arg_enum), 0x0,
7684 "Print Type", HFILL }},
7687 { "Submission Complete?", "ndps.sub_complete", FT_BOOLEAN, BASE_NONE,
7688 NULL, 0x0, "Submission Complete?", HFILL }},
7691 { "Document Content", "ndps.doc_content",
7692 FT_UINT32, BASE_DEC, VALS(ndps_doc_content_enum), 0x0,
7693 "Document Content", HFILL }},
7695 { &hf_ndps_doc_name,
7696 { "Document Name", "ndps.doc_name",
7697 FT_STRING, BASE_NONE, NULL, 0x0,
7698 "Document Name", HFILL }},
7701 { "Local ID", "ndps.local_id",
7702 FT_UINT32, BASE_DEC, NULL, 0x0,
7703 "Local ID", HFILL }},
7705 { &hf_ndps_included_doc,
7706 { "Included Document", "ndps.included_doc",
7707 FT_BYTES, BASE_NONE, NULL, 0x0,
7708 "Included Document", HFILL }},
7710 { &hf_ndps_ref_name,
7711 { "Referenced Document Name", "ndps.ref_doc_name",
7712 FT_STRING, BASE_NONE, NULL, 0x0,
7713 "Referenced Document Name", HFILL }},
7715 { &hf_interrupt_job_type,
7716 { "Interrupt Job Identifier", "ndps.interrupt_job_type",
7717 FT_UINT32, BASE_DEC, VALS(ndps_interrupt_job_enum), 0x0,
7718 "Interrupt Job Identifier", HFILL }},
7720 { &hf_pause_job_type,
7721 { "Pause Job Identifier", "ndps.pause_job_type",
7722 FT_UINT32, BASE_DEC, VALS(ndps_pause_job_enum), 0x0,
7723 "Pause Job Identifier", HFILL }},
7726 { "Force?", "ndps.ndps_force",
7727 FT_BOOLEAN, BASE_NONE, NULL, 0x0,
7730 { &hf_resubmit_op_type,
7731 { "Resubmit Operation Type", "ndps.resubmit_op_type",
7732 FT_UINT32, BASE_DEC, VALS(ndps_resubmit_op_enum), 0x0,
7733 "Resubmit Operation Type", HFILL }},
7735 { &hf_shutdown_type,
7736 { "Shutdown Type", "ndps.shutdown_type",
7737 FT_UINT32, BASE_DEC, VALS(ndps_shutdown_enum), 0x0,
7738 "Shutdown Type", HFILL }},
7740 { &hf_ndps_supplier_flag,
7741 { "Supplier Data?", "ndps.supplier_flag",
7742 FT_BOOLEAN, BASE_NONE, NULL, 0x0,
7743 "Supplier Data?", HFILL }},
7745 { &hf_ndps_language_flag,
7746 { "Language Data?", "ndps.language_flag",
7747 FT_BOOLEAN, BASE_NONE, NULL, 0x0,
7748 "Language Data?", HFILL }},
7750 { &hf_ndps_method_flag,
7751 { "Method Data?", "ndps.method_flag",
7752 FT_BOOLEAN, BASE_NONE, NULL, 0x0,
7753 "Method Data?", HFILL }},
7755 { &hf_ndps_delivery_address_flag,
7756 { "Delivery Address Data?", "ndps.delivery_flag",
7757 FT_BOOLEAN, BASE_NONE, NULL, 0x0,
7758 "Delivery Address Data?", HFILL }},
7760 { &hf_ndps_list_profiles_type,
7761 { "List Profiles Type", "ndps.ndps_list_profiles_type",
7762 FT_UINT32, BASE_HEX, VALS(ndps_attrs_arg_enum), 0x0,
7763 "List Profiles Type", HFILL }},
7765 { &hf_ndps_list_profiles_choice_type,
7766 { "List Profiles Choice Type", "ndps.ndps_list_profiles_choice_type",
7767 FT_UINT32, BASE_HEX, VALS(ndps_list_profiles_choice_enum), 0x0,
7768 "List Profiles Choice Type", HFILL }},
7770 { &hf_ndps_list_profiles_result_type,
7771 { "List Profiles Result Type", "ndps.ndps_list_profiles_result_type",
7772 FT_UINT32, BASE_HEX, VALS(ndps_list_profiles_result_enum), 0x0,
7773 "List Profiles Result Type", HFILL }},
7775 { &hf_ndps_integer_type_flag,
7776 { "Integer Type Flag", "ndps.ndps_integer_type_flag",
7777 FT_UINT32, BASE_HEX, NULL, 0x0,
7778 "Integer Type Flag", HFILL }},
7780 { &hf_ndps_integer_type_value,
7781 { "Integer Type Value", "ndps.ndps_integer_type_value",
7782 FT_UINT32, BASE_HEX, NULL, 0x0,
7783 "Integer Type Value", HFILL }},
7785 { &hf_ndps_continuation_option,
7786 { "Continuation Option", "ndps.ndps_continuation_option",
7787 FT_BYTES, BASE_HEX, NULL, 0x0,
7788 "Continuation Option", HFILL }},
7790 { &hf_ndps_ds_info_type,
7791 { "DS Info Type", "ndps.ndps_ds_info_type",
7792 FT_UINT32, BASE_HEX, VALS(ndps_ds_info_enum), 0x0,
7793 "DS Info Type", HFILL }},
7796 { "GUID", "ndps.guid",
7797 FT_BYTES, BASE_NONE, NULL, 0x0,
7800 { &hf_ndps_list_services_type,
7801 { "Services Type", "ndps.ndps_list_services_type",
7802 FT_UINT32, BASE_HEX, VALS(ndps_list_services_enum), 0x0,
7803 "Services Type", HFILL }},
7805 { &hf_ndps_item_bytes,
7806 { "Item Ptr", "ndps.item_bytes",
7807 FT_BYTES, BASE_NONE, NULL, 0x0,
7808 "Item Ptr", HFILL }},
7810 { &hf_ndps_certified,
7811 { "Certified", "ndps.certified",
7812 FT_BYTES, BASE_NONE, NULL, 0x0,
7813 "Certified", HFILL }},
7815 { &hf_ndps_attribute_set,
7816 { "Attribute Set", "ndps.attribute_set",
7817 FT_BYTES, BASE_NONE, NULL, 0x0,
7818 "Attribute Set", HFILL }},
7820 { &hf_ndps_data_item_type,
7821 { "Item Type", "ndps.ndps_data_item_type",
7822 FT_UINT32, BASE_HEX, VALS(ndps_data_item_enum), 0x0,
7823 "Item Type", HFILL }},
7826 { "Integer Value", "ndps.info_int",
7827 FT_UINT8, BASE_HEX, NULL, 0x0,
7828 "Integer Value", HFILL }},
7831 { "16 Bit Integer Value", "ndps.info_int16",
7832 FT_UINT16, BASE_HEX, NULL, 0x0,
7833 "16 Bit Integer Value", HFILL }},
7836 { "32 Bit Integer Value", "ndps.info_int32",
7837 FT_UINT32, BASE_HEX, NULL, 0x0,
7838 "32 Bit Integer Value", HFILL }},
7841 { "Boolean Value", "ndps.info_boolean",
7842 FT_BOOLEAN, BASE_NONE, NULL, 0x0,
7843 "Boolean Value", HFILL }},
7846 { "String Value", "ndps.info_string",
7847 FT_STRING, BASE_NONE, NULL, 0x0,
7848 "String Value", HFILL }},
7851 { "Byte Value", "ndps.info_bytes",
7852 FT_BYTES, BASE_NONE, NULL, 0x0,
7853 "Byte Value", HFILL }},
7855 { &hf_ndps_list_local_servers_type,
7856 { "Server Type", "ndps.ndps_list_local_server_type",
7857 FT_UINT32, BASE_HEX, VALS(ndps_list_local_servers_enum), 0x0,
7858 "Server Type", HFILL }},
7860 { &hf_ndps_registry_name,
7861 { "Registry Name", "ndps.registry_name",
7862 FT_STRING, BASE_NONE, NULL, 0x0,
7863 "Registry Name", HFILL }},
7865 { &hf_ndps_client_server_type,
7866 { "Client/Server Type", "ndps.ndps_client_server_type",
7867 FT_UINT32, BASE_HEX, VALS(ndps_client_server_enum), 0x0,
7868 "Client/Server Type", HFILL }},
7870 { &hf_ndps_session_type,
7871 { "Session Type", "ndps.ndps_session_type",
7872 FT_UINT32, BASE_HEX, VALS(ndps_session_type_enum), 0x0,
7873 "Session Type", HFILL }},
7876 { "Time", "ndps.time",
7877 FT_UINT32, BASE_DEC, NULL, 0x0,
7880 { &hf_ndps_supplier_name,
7881 { "Supplier Name", "ndps.supplier_name",
7882 FT_STRING, BASE_NONE, NULL, 0x0,
7883 "Supplier Name", HFILL }},
7886 { "Message", "ndps.message",
7887 FT_STRING, BASE_NONE, NULL, 0x0,
7888 "Message", HFILL }},
7890 { &hf_delivery_method_type,
7891 { "Delivery Method Type", "ndps.delivery_method_type",
7892 FT_UINT32, BASE_HEX, VALS(ndps_delivery_method_enum), 0x0,
7893 "Delivery Method Type", HFILL }},
7895 { &hf_ndps_get_session_type,
7896 { "Session Type", "ndps.ndps_get_session_type",
7897 FT_UINT32, BASE_HEX, VALS(ndps_get_session_type_enum), 0x0,
7898 "Session Type", HFILL }},
7901 { "Packet Count", "ndps.packet_count",
7902 FT_UINT32, BASE_DEC, NULL, 0x0,
7903 "Packet Count", HFILL }},
7905 { &hf_last_packet_flag,
7906 { "Last Packet Flag", "ndps.last_packet_flag",
7907 FT_UINT32, BASE_DEC, NULL, 0x0,
7908 "Last Packet Flag", HFILL }},
7910 { &hf_ndps_get_resman_session_type,
7911 { "Session Type", "ndps.ndps_get_resman_session_type",
7912 FT_UINT32, BASE_HEX, VALS(ndps_get_resman_session_type_enum), 0x0,
7913 "Session Type", HFILL }},
7916 { "Problem Type", "ndps.ndps_get_resman_session_type",
7917 FT_UINT32, BASE_HEX, VALS(problem_type_enum), 0x0,
7918 "Problem Type", HFILL }},
7921 { "Number of Values", "ndps.values",
7922 FT_UINT32, BASE_HEX, NULL, 0x0,
7923 "Number of Values", HFILL }},
7925 { &hf_ndps_object_ids_7,
7926 { "Object ID Definition", "ndps.objectid_def7",
7927 FT_NONE, BASE_HEX, NULL,
7928 0x0, "Object ID Definition", HFILL }},
7930 { &hf_ndps_object_ids_8,
7931 { "Object ID Definition", "ndps.objectid_def8",
7932 FT_NONE, BASE_HEX, NULL,
7933 0x0, "Object ID Definition", HFILL }},
7935 { &hf_ndps_object_ids_9,
7936 { "Object ID Definition", "ndps.objectid_def9",
7937 FT_NONE, BASE_HEX, NULL,
7938 0x0, "Object ID Definition", HFILL }},
7940 { &hf_ndps_object_ids_10,
7941 { "Object ID Definition", "ndps.objectid_def10",
7942 FT_NONE, BASE_HEX, NULL,
7943 0x0, "Object ID Definition", HFILL }},
7945 { &hf_ndps_object_ids_11,
7946 { "Object ID Definition", "ndps.objectid_def11",
7947 FT_NONE, BASE_HEX, NULL,
7948 0x0, "Object ID Definition", HFILL }},
7950 { &hf_ndps_object_ids_12,
7951 { "Object ID Definition", "ndps.objectid_def12",
7952 FT_NONE, BASE_HEX, NULL,
7953 0x0, "Object ID Definition", HFILL }},
7955 { &hf_ndps_object_ids_13,
7956 { "Object ID Definition", "ndps.objectid_def13",
7957 FT_NONE, BASE_HEX, NULL,
7958 0x0, "Object ID Definition", HFILL }},
7960 { &hf_ndps_object_ids_14,
7961 { "Object ID Definition", "ndps.objectid_def14",
7962 FT_NONE, BASE_HEX, NULL,
7963 0x0, "Object ID Definition", HFILL }},
7965 { &hf_ndps_object_ids_15,
7966 { "Object ID Definition", "ndps.objectid_def15",
7967 FT_NONE, BASE_HEX, NULL,
7968 0x0, "Object ID Definition", HFILL }},
7970 { &hf_ndps_object_ids_16,
7971 { "Object ID Definition", "ndps.objectid_def16",
7972 FT_NONE, BASE_HEX, NULL,
7973 0x0, "Object ID Definition", HFILL }},
7975 { &hf_ndps_attribute_time,
7976 { "Time", "ndps.attribute_time",
7977 FT_ABSOLUTE_TIME, BASE_DEC, NULL, 0x0,
7980 { &hf_print_security,
7981 { "Printer Security", "ndps.print_security",
7982 FT_UINT32, BASE_HEX, VALS(ndps_print_security), 0x0,
7983 "Printer Security", HFILL }},
7985 { &hf_notify_time_interval,
7986 { "Notify Time Interval", "ndps.notify_time_interval",
7987 FT_UINT32, BASE_HEX, NULL, 0x0,
7988 "Notify Time Interval", HFILL }},
7990 { &hf_notify_sequence_number,
7991 { "Notify Sequence Number", "ndps.notify_seq_number",
7992 FT_UINT32, BASE_HEX, NULL, 0x0,
7993 "Notify Sequence Number", HFILL }},
7995 { &hf_notify_lease_exp_time,
7996 { "Notify Lease Expiration Time", "ndps.notify_lease_exp_time",
7997 FT_UINT32, BASE_HEX, NULL, 0x0,
7998 "Notify Lease Expiration Time", HFILL }},
8000 { &hf_notify_printer_uri,
8001 { "Notify Printer URI", "ndps.notify_printer_uri",
8002 FT_STRING, BASE_NONE, NULL, 0x0,
8003 "Notify Printer URI", HFILL }},
8006 { "Level", "ndps.level",
8007 FT_UINT32, BASE_HEX, NULL, 0x0,
8011 { "Interval", "ndps.interval",
8012 FT_UINT32, BASE_HEX, NULL, 0x0,
8013 "Interval", HFILL }},
8016 static gint *ett[] = {
8021 module_t *ndps_module;
8023 proto_ndps = proto_register_protocol("Novell Distributed Print System", "NDPS", "ndps");
8024 proto_register_field_array(proto_ndps, hf_ndps, array_length(hf_ndps));
8025 proto_register_subtree_array(ett, array_length(ett));
8027 ndps_module = prefs_register_protocol(proto_ndps, NULL);
8028 prefs_register_bool_preference(ndps_module, "desegment_tcp",
8029 "Desegment all NDPS messages spanning multiple TCP segments",
8030 "Whether the NDPS dissector should desegment all messages spanning multiple TCP segments",
8032 prefs_register_bool_preference(ndps_module, "desegment_spx",
8033 "Desegment all NDPS messages spanning multiple SPX packets",
8034 "Whether the NDPS dissector should desegment all messages spanning multiple SPX packets",
8036 prefs_register_bool_preference(ndps_module, "show_oid",
8037 "Display NDPS Details?",
8038 "Whether or not the NDPS dissector should show object id's and other details",
8041 register_init_routine(&ndps_init_protocol);
8042 register_postseq_cleanup_routine(&ndps_postseq_cleanup);
8046 proto_reg_handoff_ndps(void)
8048 dissector_handle_t ndps_handle, ndps_tcp_handle;
8050 ndps_handle = create_dissector_handle(dissect_ndps_ipx, proto_ndps);
8051 ndps_tcp_handle = create_dissector_handle(dissect_ndps_tcp, proto_ndps);
8053 dissector_add("spx.socket", SPX_SOCKET_PA, ndps_handle);
8054 dissector_add("spx.socket", SPX_SOCKET_BROKER, ndps_handle);
8055 dissector_add("spx.socket", SPX_SOCKET_SRS, ndps_handle);
8056 dissector_add("spx.socket", SPX_SOCKET_ENS, ndps_handle);
8057 dissector_add("spx.socket", SPX_SOCKET_RMS, ndps_handle);
8058 dissector_add("spx.socket", SPX_SOCKET_NOTIFY_LISTENER, ndps_handle);
8059 dissector_add("tcp.port", TCP_PORT_PA, ndps_tcp_handle);
8060 dissector_add("tcp.port", TCP_PORT_BROKER, ndps_tcp_handle);
8061 dissector_add("tcp.port", TCP_PORT_SRS, ndps_tcp_handle);
8062 dissector_add("tcp.port", TCP_PORT_ENS, ndps_tcp_handle);
8063 dissector_add("tcp.port", TCP_PORT_RMS, ndps_tcp_handle);
8064 dissector_add("tcp.port", TCP_PORT_NOTIFY_LISTENER, ndps_tcp_handle);
8065 ndps_data_handle = find_dissector("data");