2 * Routines for NetWare's NDPS
3 * Greg Morris <gmorris@novell.com>
4 * Copyright (c) Novell, Inc. 2002-2003
6 * Wireshark - Network traffic analyzer
7 * By Gerald Combs <gerald@wireshark.org>
8 * Copyright 1998 Gerald Combs
10 * SPDX-License-Identifier: GPL-2.0-or-later
15 #include <epan/packet.h>
16 #include <epan/exceptions.h>
17 #include <epan/prefs.h>
18 #include <epan/reassemble.h>
19 #include <epan/expert.h>
20 #include <epan/strutil.h>
21 #include <epan/proto_data.h>
22 #include <epan/wmem_scopes.h>
24 #include "packet-ipx.h"
25 #include "packet-tcp.h"
26 #include "packet-ndps.h"
28 void proto_register_ndps(void);
29 void proto_reg_handoff_ndps(void);
31 static dissector_handle_t ndps_handle
, ndps_tcp_handle
;
33 /* Limit the number of items we can add to the tree. */
34 #define NDPS_MAX_ITEMS 100
36 /* Table for reassembly of fragments. */
37 static reassembly_table ndps_reassembly_table
;
39 /* desegmentation of ndps */
40 static bool ndps_defragment
= true;
42 static uint32_t tid
= 1;
45 static bool ndps_show_oids
=false;
47 /* Global Attribute for evaluation of Values */
48 static const char *global_attribute_name
;
50 static int dissect_ndps_request(tvbuff_t
*, packet_info
*, proto_tree
*, uint32_t, uint32_t, int);
52 static int dissect_ndps_reply(tvbuff_t
*, packet_info
*, proto_tree
*, int);
54 static int hf_ndps_segments
;
55 static int hf_ndps_segment
;
56 static int hf_ndps_segment_overlap
;
57 static int hf_ndps_segment_overlap_conflict
;
58 static int hf_ndps_segment_multiple_tails
;
59 static int hf_ndps_segment_too_long_segment
;
60 static int hf_ndps_segment_error
;
61 static int hf_ndps_segment_count
;
62 static int hf_ndps_reassembled_length
;
64 static int ett_ndps_segments
;
65 static int ett_ndps_segment
;
67 static int proto_ndps
;
68 static int hf_ndps_record_mark
;
69 static int hf_ndps_length
;
70 static int hf_ndps_xid
;
71 static int hf_ndps_packet_type
;
72 static int hf_ndps_rpc_version
;
73 /* static int hf_ndps_error; */
74 static int hf_ndps_num_objects
;
75 static int hf_ndps_num_attributes
;
76 /* static int hf_ndps_sbuffer; */
77 /* static int hf_ndps_rbuffer; */
78 static int hf_ndps_user_name
;
79 static int hf_ndps_broker_name
;
80 static int hf_ndps_num_results
;
81 static int hf_ndps_num_options
;
82 static int hf_ndps_num_jobs
;
83 static int hf_ndps_pa_name
;
84 static int hf_ndps_tree
;
85 static int hf_ndps_reqframe
;
86 static int hf_ndps_error_val
;
87 static int hf_ndps_ext_error
;
88 static int hf_ndps_object
;
89 static int hf_ndps_cred_type
;
90 static int hf_ndps_server_name
;
91 static int hf_ndps_connection
;
92 static int hf_ndps_auth_null
;
93 static int hf_ndps_rpc_accept
;
94 static int hf_ndps_rpc_acc_stat
;
95 static int hf_ndps_rpc_rej_stat
;
96 static int hf_ndps_rpc_acc_results
;
97 static int hf_ndps_problem_type
;
98 static int hf_security_problem_type
;
99 static int hf_service_problem_type
;
100 static int hf_access_problem_type
;
101 static int hf_printer_problem_type
;
102 static int hf_selection_problem_type
;
103 static int hf_doc_access_problem_type
;
104 static int hf_attribute_problem_type
;
105 static int hf_update_problem_type
;
106 static int hf_obj_id_type
;
107 static int hf_oid_struct_size
;
108 static int hf_object_name
;
109 static int hf_ndps_document_number
;
110 static int hf_ndps_nameorid
;
111 static int hf_ndps_local_object_name
;
112 static int hf_ndps_printer_name
;
113 static int hf_ndps_qualified_name
;
114 static int hf_ndps_item_count
;
115 static int hf_ndps_num_passwords
;
116 static int hf_ndps_num_servers
;
117 static int hf_ndps_num_locations
;
118 static int hf_ndps_num_areas
;
119 static int hf_ndps_num_address_items
;
120 static int hf_ndps_num_job_categories
;
121 static int hf_ndps_num_page_selects
;
122 static int hf_ndps_num_page_informations
;
123 static int hf_ndps_num_names
;
124 static int hf_ndps_num_categories
;
125 static int hf_ndps_num_colorants
;
126 static int hf_ndps_num_events
;
127 static int hf_ndps_num_args
;
128 static int hf_ndps_num_transfer_methods
;
129 static int hf_ndps_num_doc_types
;
130 static int hf_ndps_num_destinations
;
131 static int hf_ndps_qualifier
;
132 static int hf_ndps_lib_error
;
133 static int hf_ndps_other_error
;
134 static int hf_ndps_other_error_2
;
135 static int hf_ndps_session
;
136 static int hf_ndps_abort_flag
;
137 static int hf_ndps_obj_attribute_type
;
138 static int hf_ndps_attribute_value
;
139 static int hf_ndps_lower_range
;
140 static int hf_ndps_upper_range
;
141 static int hf_ndps_n64
;
142 static int hf_ndps_lower_range_n64
;
143 static int hf_ndps_upper_range_n64
;
144 static int hf_ndps_attrib_boolean
;
145 static int hf_ndps_realization
;
146 static int hf_ndps_xdimension_n64
;
147 static int hf_ndps_ydimension_n64
;
148 static int hf_ndps_dim_value
;
149 static int hf_ndps_dim_flag
;
150 static int hf_ndps_xydim_value
;
151 static int hf_ndps_location_value
;
152 static int hf_ndps_xmin_n64
;
153 static int hf_ndps_xmax_n64
;
154 static int hf_ndps_ymin_n64
;
155 static int hf_ndps_ymax_n64
;
156 static int hf_ndps_edge_value
;
157 static int hf_ndps_cardinal_or_oid
;
158 static int hf_ndps_cardinal_name_or_oid
;
159 static int hf_ndps_integer_or_oid
;
160 static int hf_ndps_profile_id
;
161 static int hf_ndps_persistence
;
162 static int hf_ndps_language_count
;
163 static int hf_ndps_language_id
;
164 static int hf_address_type
;
165 static int hf_ndps_address
;
166 static int hf_ndps_add_bytes
;
167 static int hf_ndps_event_type
;
168 static int hf_ndps_event_object_identifier
;
169 static int hf_ndps_octet_string
;
170 static int hf_ndps_scope
;
171 static int hf_address_len
;
172 static int hf_ndps_net
;
173 static int hf_ndps_node
;
174 static int hf_ndps_socket
;
175 static int hf_ndps_port
;
176 static int hf_ndps_ip
;
177 static int hf_ndps_server_type
;
178 static int hf_ndps_num_services
;
179 static int hf_ndps_service_type
;
180 static int hf_ndps_service_enabled
;
181 static int hf_ndps_method_name
;
182 static int hf_ndps_method_ver
;
183 static int hf_ndps_file_name
;
184 static int hf_ndps_admin_submit
;
185 static int hf_ndps_oid
;
186 static int hf_ndps_object_op
;
187 static int hf_answer_time
;
188 static int hf_oid_asn1_type
;
189 static int hf_ndps_item_ptr
;
190 static int hf_ndps_len
;
191 static int hf_ndps_limit_enc
;
192 static int hf_ndps_delivery_add_count
;
193 /* static int hf_ndps_qualified_name2; */
194 static int hf_ndps_delivery_add_type
;
195 static int hf_ndps_criterion_type
;
196 static int hf_ndps_num_ignored_attributes
;
197 static int hf_ndps_ignored_type
;
198 static int hf_ndps_num_resources
;
199 static int hf_ndps_resource_type
;
200 static int hf_ndps_identifier_type
;
201 static int hf_ndps_page_flag
;
202 static int hf_ndps_media_type
;
203 static int hf_ndps_doc_content
;
204 static int hf_ndps_page_size
;
205 static int hf_ndps_direction
;
206 static int hf_ndps_page_order
;
207 static int hf_ndps_medium_size
;
208 static int hf_ndps_long_edge_feeds
;
209 static int hf_ndps_inc_across_feed
;
210 static int hf_ndps_size_inc_in_feed
;
211 static int hf_ndps_page_orientation
;
212 static int hf_ndps_numbers_up
;
213 static int hf_ndps_xdimension
;
214 static int hf_ndps_ydimension
;
215 static int hf_ndps_state_severity
;
216 static int hf_ndps_training
;
217 static int hf_ndps_colorant_set
;
218 static int hf_ndps_card_enum_time
;
219 static int hf_ndps_attrs_arg
;
220 static int hf_ndps_context_len
;
221 static int hf_ndps_context
;
222 static int hf_ndps_filter
;
223 /* static int hf_ndps_item_filter; */
224 /* static int hf_ndps_substring_match; */
225 static int hf_ndps_time_limit
;
226 static int hf_ndps_count_limit
;
227 static int hf_ndps_operator
;
228 static int hf_ndps_password
;
229 static int hf_ndps_retrieve_restrictions
;
230 static int hf_ndps_bind_security_option_count
;
231 static int hf_bind_security
;
232 static int hf_ndps_max_items
;
233 static int hf_ndps_status_flags
;
234 static int hf_ndps_resource_list_type
;
235 static int hf_os_count
;
236 static int hf_os_type
;
237 static int hf_ndps_printer_type_count
;
238 static int hf_ndps_printer_type
;
239 static int hf_ndps_printer_manuf
;
240 static int hf_ndps_inf_file_name
;
241 static int hf_ndps_vendor_dir
;
242 static int hf_banner_type
;
243 static int hf_font_type
;
244 static int hf_printer_id
;
245 static int hf_ndps_font_name
;
246 static int hf_ndps_return_code
;
247 /* static int hf_ndps_banner_count; */
248 static int hf_ndps_banner_name
;
249 static int hf_ndps_font_type_count
;
250 static int hf_font_type_name
;
251 static int hf_ndps_font_file_count
;
252 static int hf_font_file_name
;
253 static int hf_ndps_printer_def_count
;
254 static int hf_ndps_prn_file_name
;
255 static int hf_ndps_prn_dir_name
;
256 static int hf_ndps_def_file_name
;
257 static int hf_ndps_num_win31_keys
;
258 static int hf_ndps_num_win95_keys
;
259 static int hf_ndps_num_windows_keys
;
260 static int hf_ndps_windows_key
;
261 static int hf_archive_type
;
262 static int hf_archive_file_size
;
263 static int hf_ndps_data
;
264 static int hf_get_status_flag
;
265 static int hf_res_type
;
266 static int hf_file_timestamp
;
267 static int hf_sub_complete
;
268 static int hf_doc_content
;
269 /* static int hf_ndps_doc_name; */
270 static int hf_print_arg
;
271 static int hf_local_id
;
272 static int hf_ndps_included_doc_len
;
273 static int hf_ndps_included_doc
;
274 static int hf_ndps_ref_name
;
275 static int hf_interrupt_job_type
;
276 static int hf_pause_job_type
;
277 static int hf_ndps_force
;
278 static int hf_resubmit_op_type
;
279 static int hf_shutdown_type
;
280 static int hf_ndps_supplier_flag
;
281 static int hf_ndps_language_flag
;
282 static int hf_ndps_method_flag
;
283 static int hf_ndps_delivery_address_flag
;
284 static int hf_ndps_list_profiles_type
;
285 static int hf_ndps_list_profiles_choice_type
;
286 static int hf_ndps_list_profiles_result_type
;
287 static int hf_ndps_integer_type_flag
;
288 static int hf_ndps_integer_type_value
;
289 static int hf_ndps_continuation_option
;
290 static int hf_ndps_ds_info_type
;
291 static int hf_ndps_guid
;
292 static int hf_ndps_list_services_type
;
293 static int hf_ndps_item_bytes
;
294 static int hf_ndps_certified
;
295 static int hf_ndps_attribute_set
;
296 static int hf_ndps_data_item_type
;
297 static int hf_info_int
;
298 static int hf_info_int16
;
299 static int hf_info_int32
;
300 static int hf_info_boolean
;
301 static int hf_info_string
;
302 /* static int hf_info_bytes; */
303 static int hf_ndps_list_local_servers_type
;
304 static int hf_ndps_registry_name
;
305 static int hf_ndps_client_server_type
;
306 static int hf_ndps_session_type
;
308 static int hf_ndps_supplier_name
;
309 static int hf_ndps_message
;
310 static int hf_ndps_delivery_method_count
;
311 static int hf_delivery_method_type
;
312 static int hf_ndps_get_session_type
;
313 static int hf_packet_count
;
314 static int hf_last_packet_flag
;
315 static int hf_ndps_get_resman_session_type
;
316 static int hf_problem_type
;
317 static int hf_ndps_num_values
;
318 static int hf_ndps_object_ids_7
;
319 static int hf_ndps_object_ids_8
;
320 static int hf_ndps_object_ids_9
;
321 static int hf_ndps_object_ids_10
;
322 static int hf_ndps_object_ids_11
;
323 static int hf_ndps_object_ids_12
;
324 static int hf_ndps_object_ids_13
;
325 static int hf_ndps_object_ids_14
;
326 static int hf_ndps_object_ids_15
;
327 static int hf_ndps_object_ids_16
;
328 /* static int hf_ndps_attribute_time; */
329 static int hf_print_security
;
330 static int hf_notify_time_interval
;
331 static int hf_notify_sequence_number
;
332 static int hf_notify_lease_exp_time
;
333 static int hf_notify_printer_uri
;
335 static int hf_interval
;
336 static int hf_ndps_other_error_string
;
338 static int hf_spx_ndps_program
;
339 static int hf_spx_ndps_version
;
340 static int hf_spx_ndps_func_print
;
341 static int hf_spx_ndps_func_registry
;
342 static int hf_spx_ndps_func_notify
;
343 static int hf_spx_ndps_func_resman
;
344 static int hf_spx_ndps_func_delivery
;
345 static int hf_spx_ndps_func_broker
;
349 static expert_field ei_ndps_problem_type
;
350 static expert_field ei_ndps_return_code
;
351 static expert_field ei_ndps_rpc_acc_stat
;
352 static expert_field ei_ndps_truncated
;
355 /* desegmentation of NDPS over TCP */
356 static bool ndps_desegment
= true;
358 static const value_string true_false
[] = {
359 { 0x00000000, "Accept" },
360 { 0x00000001, "Deny" },
364 static const value_string ndps_limit_enc_enum
[] = {
365 { 0x00000000, "Time" },
366 { 0x00000001, "Count" },
367 { 0x00000002, "Error" },
371 static const value_string problem_type_enum
[] = {
372 { 0x00000000, "Standard" },
373 { 0x00000001, "Extended" },
377 static const value_string accept_stat
[] = {
378 { 0x00000000, "Success" },
379 { 0x00000001, "Program Unavailable" },
380 { 0x00000002, "Program Mismatch" },
381 { 0x00000003, "Procedure Unavailable" },
382 { 0x00000004, "Garbage Arguments" },
383 { 0x00000005, "System Error" },
387 static const value_string reject_stat
[] = {
388 { 0x00000000, "RPC Mismatch" },
389 { 0x00000001, "Authentication Error" },
393 static const value_string error_type_enum
[] = {
394 { 0x00000000, "Security Error" },
395 { 0x00000001, "Service Error" },
396 { 0x00000002, "Access Error" },
397 { 0x00000003, "Printer Error" },
398 { 0x00000004, "Selection Error" },
399 { 0x00000005, "Document Access Error" },
400 { 0x00000006, "Attribute Error" },
401 { 0x00000007, "Update Error" },
405 static const value_string security_problem_enum
[] = {
406 { 0x00000000, "Authentication" },
407 { 0x00000001, "Credentials" },
408 { 0x00000002, "Rights" },
409 { 0x00000003, "Invalid PAC" },
413 static const value_string service_problem_enum
[] = {
414 { 0x00000000, "Sever Busy" },
415 { 0x00000001, "Server Unavailable" },
416 { 0x00000002, "Complex Operation" },
417 { 0x00000003, "Resource Limit" },
418 { 0x00000004, "Unclassified Server Error" },
419 { 0x00000005, "Too Many Items in List" },
420 { 0x00000006, "Resource not Available" },
421 { 0x00000007, "Cancel Document Support" },
422 { 0x00000008, "Modify Document Support" },
423 { 0x00000009, "Multiple Document Support" },
424 { 0x0000000a, "Parameter Valid Support" },
425 { 0x0000000b, "Invalid Checkpoint" },
426 { 0x0000000c, "Continuation Context" },
427 { 0x0000000d, "Pause Limit Exceeded" },
428 { 0x0000000e, "Unsupported Operation" },
429 { 0x0000000f, "Notify Service Error" },
430 { 0x00000010, "Accounting Service Error" },
433 static value_string_ext service_problem_enum_ext
= VALUE_STRING_EXT_INIT(service_problem_enum
);
435 static const value_string access_problem_enum
[] = {
436 { 0x00000000, "Wrong Object Class" },
437 { 0x00000001, "Lack of Access Rights" },
438 { 0x00000002, "Can't Interrupt Job" },
439 { 0x00000003, "Wrong Object State" },
440 { 0x00000004, "Client Not Bound" },
441 { 0x00000005, "Not Available" },
442 { 0x00000006, "Notify Service Not Connected" },
443 { 0x00000007, "PDS Not Connected" },
447 static const value_string printer_problem_enum
[] = {
448 { 0x00000000, "Printer Error" },
449 { 0x00000001, "Printer Needs Attention" },
450 { 0x00000002, "Printer Needs Key Operator" },
454 static const value_string selection_problem_enum
[] = {
455 { 0x00000000, "Invalid ID" },
456 { 0x00000001, "Unknown ID" },
457 { 0x00000002, "Object Exists" },
458 { 0x00000003, "ID Changed" },
462 static const value_string doc_access_problem_enum
[] = {
463 { 0x00000000, "Access Not Available" },
464 { 0x00000001, "Time Expired" },
465 { 0x00000002, "Access Denied" },
466 { 0x00000003, "Unknown Document" },
467 { 0x00000004, "No Documents in Job" },
471 static const value_string attribute_problem_enum
[] = {
472 { 0x00000000, "Invalid Syntax" },
473 { 0x00000001, "Undefined Type" },
474 { 0x00000002, "Wrong Matching" },
475 { 0x00000003, "Constraint Violated" },
476 { 0x00000004, "Unsupported Type" },
477 { 0x00000005, "Illegal Modification" },
478 { 0x00000006, "Consists With Other Attribute" },
479 { 0x00000007, "Undefined Attribute Value" },
480 { 0x00000008, "Unsupported Value" },
481 { 0x00000009, "Invalid Noncompulsed Modification" },
482 { 0x0000000a, "Per Job Inadmissible" },
483 { 0x0000000b, "Not Multivalued" },
484 { 0x0000000c, "Mandatory Omitted" },
485 { 0x0000000d, "Illegal For Class" },
488 static value_string_ext attribute_problem_enum_ext
= VALUE_STRING_EXT_INIT(attribute_problem_enum
);
490 static const value_string update_problem_enum
[] = {
491 { 0x00000000, "No Modifications Allowed" },
492 { 0x00000001, "Insufficient Rights" },
493 { 0x00000002, "Previous Operation Incomplete" },
494 { 0x00000003, "Cancel Not Possible" },
498 static const value_string obj_identification_enum
[] = {
499 { 0x00000000, "Printer Contained Object ID" },
500 { 0x00000001, "Document Identifier" },
501 { 0x00000002, "Object Identifier" },
502 { 0x00000003, "Object Name" },
503 { 0x00000004, "Name or Object ID" },
504 { 0x00000005, "Simple Name" },
505 { 0x00000006, "Printer Configuration Object ID" },
506 { 0x00000007, "Qualified Name" },
507 { 0x00000008, "Event Object ID" },
511 static const value_string nameorid_enum
[] = {
512 { 0x00000000, "None" },
513 { 0x00000001, "Global" },
514 { 0x00000002, "Local" },
518 static const value_string qualified_name_enum
[] = {
519 { 0x00000000, "None" },
520 { 0x00000001, "Simple" },
521 { 0x00000002, "NDS" },
526 static const value_string qualified_name_enum2
[] = {
527 { 0x00000000, "NDS" },
532 static const value_string spx_ndps_program_vals
[] = {
533 { 0x00060976, "Print Program" },
534 { 0x00060977, "Broker Program" },
535 { 0x00060978, "Registry Program" },
536 { 0x00060979, "Notify Program" },
537 { 0x0006097a, "Resource Manager Program" },
538 { 0x0006097b, "Programmatic Delivery Program" },
542 static const value_string spx_ndps_print_func_vals
[] = {
543 { 0x00000000, "None" },
544 { 0x00000001, "Bind PSM" },
545 { 0x00000002, "Bind PA" },
546 { 0x00000003, "Unbind" },
547 { 0x00000004, "Print" },
548 { 0x00000005, "Modify Job" },
549 { 0x00000006, "Cancel Job" },
550 { 0x00000007, "List Object Attributes" },
551 { 0x00000008, "Promote Job" },
552 { 0x00000009, "Interrupt" },
553 { 0x0000000a, "Pause" },
554 { 0x0000000b, "Resume" },
555 { 0x0000000c, "Clean" },
556 { 0x0000000d, "Create" },
557 { 0x0000000e, "Delete" },
558 { 0x0000000f, "Disable PA" },
559 { 0x00000010, "Enable PA" },
560 { 0x00000011, "Resubmit Jobs" },
561 { 0x00000012, "Set" },
562 { 0x00000013, "Shutdown PA" },
563 { 0x00000014, "Startup PA" },
564 { 0x00000015, "Reorder Job" },
565 { 0x00000016, "Pause PA" },
566 { 0x00000017, "Resume PA" },
567 { 0x00000018, "Transfer Data" },
568 { 0x00000019, "Device Control" },
569 { 0x0000001a, "Add Event Profile" },
570 { 0x0000001b, "Remove Event Profile" },
571 { 0x0000001c, "Modify Event Profile" },
572 { 0x0000001d, "List Event Profiles" },
573 { 0x0000001e, "Shutdown PSM" },
574 { 0x0000001f, "Cancel PSM Shutdown" },
575 { 0x00000020, "Set Printer DS Information" },
576 { 0x00000021, "Clean User Jobs" },
577 { 0x00000022, "Map GUID to NDS Name" },
578 { 0x00000023, "Add Event Profile 2" },
579 { 0x00000024, "List Event Profile 2" },
582 static value_string_ext spx_ndps_print_func_vals_ext
= VALUE_STRING_EXT_INIT(spx_ndps_print_func_vals
);
584 static const value_string spx_ndps_notify_func_vals
[] = {
585 { 0x00000000, "None" },
586 { 0x00000001, "Notify Bind" },
587 { 0x00000002, "Notify Unbind" },
588 { 0x00000003, "Register Supplier" },
589 { 0x00000004, "Deregister Supplier" },
590 { 0x00000005, "Add Profile" },
591 { 0x00000006, "Remove Profile" },
592 { 0x00000007, "Modify Profile" },
593 { 0x00000008, "List Profiles" },
594 { 0x00000009, "Report Event" },
595 { 0x0000000a, "List Supported Languages" },
596 { 0x0000000b, "Report Notification" },
597 { 0x0000000c, "Add Delivery Method" },
598 { 0x0000000d, "Remove Delivery Method" },
599 { 0x0000000e, "List Delivery Methods" },
600 { 0x0000000f, "Get Delivery Method Information" },
601 { 0x00000010, "Get Notify NDS Object Name" },
602 { 0x00000011, "Get Notify Session Information" },
605 static value_string_ext spx_ndps_notify_func_vals_ext
= VALUE_STRING_EXT_INIT(spx_ndps_notify_func_vals
);
607 static const value_string spx_ndps_deliver_func_vals
[] = {
608 { 0x00000000, "None" },
609 { 0x00000001, "Delivery Bind" },
610 { 0x00000002, "Delivery Unbind" },
611 { 0x00000003, "Delivery Send" },
612 { 0x00000004, "Delivery Send2" },
616 static const value_string spx_ndps_registry_func_vals
[] = {
617 { 0x00000000, "None" },
618 { 0x00000001, "Bind" },
619 { 0x00000002, "Unbind" },
620 { 0x00000003, "Register Server" },
621 { 0x00000004, "Deregister Server" },
622 { 0x00000005, "Register Registry" },
623 { 0x00000006, "Deregister Registry" },
624 { 0x00000007, "Registry Update" },
625 { 0x00000008, "List Local Servers" },
626 { 0x00000009, "List Servers" },
627 { 0x0000000a, "List Known Registries" },
628 { 0x0000000b, "Get Registry NDS Object Name" },
629 { 0x0000000c, "Get Registry Session Information" },
632 static value_string_ext spx_ndps_registry_func_vals_ext
= VALUE_STRING_EXT_INIT(spx_ndps_registry_func_vals
);
634 static const value_string spx_ndps_resman_func_vals
[] = {
635 { 0x00000000, "None" },
636 { 0x00000001, "Bind" },
637 { 0x00000002, "Unbind" },
638 { 0x00000003, "Add Resource File" },
639 { 0x00000004, "Delete Resource File" },
640 { 0x00000005, "List Resources" },
641 { 0x00000006, "Get Resource File" },
642 { 0x00000007, "Get Resource File Date" },
643 { 0x00000008, "Get Resource Manager NDS Object Name" },
644 { 0x00000009, "Get Resource Manager Session Information" },
645 { 0x0000000a, "Set Resource Language Context" },
648 static value_string_ext spx_ndps_resman_func_vals_ext
= VALUE_STRING_EXT_INIT(spx_ndps_resman_func_vals
);
650 static const value_string spx_ndps_broker_func_vals
[] = {
651 { 0x00000000, "None" },
652 { 0x00000001, "Bind" },
653 { 0x00000002, "Unbind" },
654 { 0x00000003, "List Services" },
655 { 0x00000004, "Enable Service" },
656 { 0x00000005, "Disable Service" },
657 { 0x00000006, "Down Broker" },
658 { 0x00000007, "Get Broker NDS Object Name" },
659 { 0x00000008, "Get Broker Session Information" },
662 static value_string_ext spx_ndps_broker_func_vals_ext
= VALUE_STRING_EXT_INIT(spx_ndps_broker_func_vals
);
664 static const value_string ndps_packet_types
[] = {
665 { 0x00000000, "Request" },
666 { 0x00000001, "Reply" },
670 static const value_string ndps_realization_enum
[] = {
671 { 0x00000000, "Logical" },
672 { 0x00000001, "Physical" },
673 { 0x00000002, "Logical & Physical" },
677 static const value_string ndps_dim_value_enum
[] = {
678 { 0x00000000, "Numeric" },
679 { 0x00000001, "Named" },
683 static const value_string ndps_xydim_value_enum
[] = {
684 { 0x00000000, "Real" },
685 { 0x00000001, "Named" },
686 { 0x00000002, "Cardinal" },
690 static const value_string ndps_location_value_enum
[] = {
691 { 0x00000000, "Numeric" },
692 { 0x00000001, "Named" },
696 static const value_string ndps_edge_value_enum
[] = {
697 { 0x00000000, "Bottom" },
698 { 0x00000001, "Right" },
699 { 0x00000002, "Top" },
700 { 0x00000003, "Left" },
704 static const value_string ndps_card_or_oid_enum
[] = {
705 { 0x00000000, "Number" },
706 { 0x00000001, "ID" },
710 static const value_string ndps_card_name_or_oid_enum
[] = {
711 { 0x00000000, "Number" },
712 { 0x00000001, "ID" },
716 static const value_string ndps_integer_or_oid_enum
[] = {
717 { 0x00000000, "ID" },
718 { 0x00000001, "Number" },
722 static const value_string ndps_persistence_enum
[] = {
723 { 0x00000000, "Permanent" },
724 { 0x00000001, "Volatile" },
728 static const value_string ndps_address_type_enum
[] = {
729 { 0x00000000, "User" },
730 { 0x00000001, "Server" },
731 { 0x00000002, "Volume" },
732 { 0x00000003, "Organization Unit" },
733 { 0x00000004, "Organization" },
734 { 0x00000005, "Group" },
735 { 0x00000006, "Distinguished Name" },
736 { 0x00000007, "User or Container" },
737 { 0x00000008, "Case Exact String" },
738 { 0x00000009, "Case Ignore String" },
739 { 0x0000000a, "Numeric String" },
740 { 0x0000000b, "DOS File Name" },
741 { 0x0000000c, "Phone Number" },
742 { 0x0000000d, "Boolean" },
743 { 0x0000000e, "Integer" },
744 { 0x0000000f, "Network Address" },
745 { 0x00000010, "Choice" },
746 { 0x00000011, "GroupWise User" },
749 static value_string_ext ndps_address_type_enum_ext
= VALUE_STRING_EXT_INIT(ndps_address_type_enum
);
751 static const value_string ndps_address_enum
[] = {
752 { 0x00000000, "IPX" },
753 { 0x00000001, "IP" },
754 { 0x00000002, "SDLC" },
755 { 0x00000003, "Token Ring to Ethernet" },
756 { 0x00000004, "OSI" },
757 { 0x00000005, "AppleTalk" },
758 { 0x00000006, "Count" },
763 static const value_string ndps_server_type_enum
[] = {
764 { 0x00000000, "All" },
765 { 0x00000001, "Public Access Printer Agent" },
766 { 0x00000002, "Notification Server" },
767 { 0x00000003, "Resource Manager" },
768 { 0x00000004, "Network Port Handler" },
772 static const value_string ndps_event_object_enum
[] = {
773 { 0x00000000, "Object" },
774 { 0x00000001, "Filter" },
775 { 0x00000002, "Detail" },
779 static const value_string ndps_service_type_enum
[] = {
780 { 0x00000000, "SRS" },
781 { 0x00000001, "ENS" },
782 { 0x00000002, "RMS" },
786 static const value_string ndps_delivery_add_enum
[] = {
787 { 0x00000000, "MHS Address" },
788 { 0x00000001, "Distinguished Name" },
789 { 0x00000002, "Text" },
790 { 0x00000003, "Octet String" },
791 { 0x00000004, "Distinguished Name String" },
792 { 0x00000005, "RPC Address" },
793 { 0x00000006, "Qualified Name" },
797 static const value_string ndps_resource_enum
[] = {
798 { 0x00000000, "Name or ID" },
799 { 0x00000001, "Text" },
804 static const value_string ndps_identifier_enum
[] = {
805 { 0x00000000, "ID Nominal Number" },
806 { 0x00000001, "ID Alpha-numeric" },
807 { 0x00000002, "ID Tag" },
811 static const value_string ndps_media_enum
[] = {
812 { 0x00000000, "Select All Pages" },
813 { 0x00000001, "Selected Pages" },
817 static const value_string ndps_page_size_enum
[] = {
818 { 0x00000000, "ID" },
819 { 0x00000001, "Dimensions" },
823 static const value_string ndps_pres_direction_enum
[] = {
824 { 0x00000000, "Right to Bottom" },
825 { 0x00000001, "Left to Bottom" },
826 { 0x00000002, "Bidirectional to Bottom" },
827 { 0x00000003, "Right to Top" },
828 { 0x00000004, "Left to Top" },
829 { 0x00000005, "Bidirectional to Top" },
830 { 0x00000006, "Bottom to Right" },
831 { 0x00000007, "Bottom to Left" },
832 { 0x00000008, "Top to Left" },
833 { 0x00000009, "Top to Right" },
836 static value_string_ext ndps_pres_direction_enum_ext
= VALUE_STRING_EXT_INIT(ndps_pres_direction_enum
);
838 static const value_string ndps_page_order_enum
[] = {
839 { 0x00000000, "Unknown" },
840 { 0x00000001, "First to Last" },
841 { 0x00000002, "Last to First" },
845 static const value_string ndps_medium_size_enum
[] = {
846 { 0x00000000, "Discrete" },
847 { 0x00000001, "Continuous" },
851 static const value_string ndps_page_orientation_enum
[] = {
852 { 0x00000000, "Unknown" },
853 { 0x00000001, "Face Up" },
854 { 0x00000002, "Face Down" },
858 static const value_string ndps_print_security
[] = {
859 { 0x00000001, "Low" },
860 { 0x00000002, "Medium" },
861 { 0x00000003, "High" },
865 static const value_string ndps_numbers_up_enum
[] = {
866 { 0x00000000, "Cardinal" },
867 { 0x00000001, "Name or Object ID" },
868 { 0x00000002, "Cardinal Range" },
873 static const value_string ndps_state_severity_enum
[] = {
874 { 0x00000001, "Other" },
875 { 0x00000002, "Warning" },
876 { 0x00000003, "Critical" },
881 static const value_string ndps_training_enum
[] = {
882 { 0x00000001, "Other" },
883 { 0x00000002, "Unknown" },
884 { 0x00000003, "Untrained" },
885 { 0x00000004, "Trained" },
886 { 0x00000005, "Field Service" },
887 { 0x00000006, "Management" },
891 static const value_string ndps_colorant_set_enum
[] = {
892 { 0x00000000, "Name" },
893 { 0x00000001, "Description" },
897 static const value_string ndps_card_enum_time_enum
[] = {
898 { 0x00000000, "Cardinal" },
899 { 0x00000001, "Enumeration" },
900 { 0x00000002, "Time" },
904 static const value_string ndps_attrs_arg_enum
[] = {
905 { 0x00000000, "Continuation" },
906 { 0x00000001, "Specification" },
911 static const value_string ndps_filter_enum
[] = {
912 { 0x00000000, "Item" },
913 { 0x00000001, "And" },
914 { 0x00000002, "Or" },
915 { 0x00000003, "Not" },
921 static const value_string ndps_filter_item_enum
[] = {
922 { 0x00000000, "Equality" },
923 { 0x00000001, "Substrings" },
924 { 0x00000002, "Greater then or Equal to" },
925 { 0x00000003, "Less then or Equal to" },
926 { 0x00000004, "Present" },
927 { 0x00000005, "Subset of" },
928 { 0x00000006, "Superset of" },
929 { 0x00000007, "Non NULL Set Intersect" },
933 static const value_string ndps_match_criteria_enum
[] = {
934 { 0x00000000, "Exact" },
935 { 0x00000001, "Case Insensitive" },
936 { 0x00000002, "Same Letter" },
937 { 0x00000003, "Approximate" },
942 static const value_string ndps_operator_enum
[] = {
943 { 0x00000000, "Attributes" },
944 { 0x00000002, "Ordered Jobs" },
948 static const value_string ndps_resource_type_enum
[] = {
949 { 0x00000000, "Printer Drivers" },
950 { 0x00000001, "Printer Definitions" },
951 { 0x00000002, "Printer Definitions Short" },
952 { 0x00000003, "Banner Page Files" },
953 { 0x00000004, "Font Types" },
954 { 0x00000005, "Printer Driver Files" },
955 { 0x00000006, "Printer Definition File" },
956 { 0x00000007, "Font Files" },
957 { 0x00000008, "Generic Type" },
958 { 0x00000009, "Generic Files" },
959 { 0x0000000a, "Printer Definition File 2" },
960 { 0x0000000b, "Printer Driver Types 2" },
961 { 0x0000000c, "Printer Driver Files 2" },
962 { 0x0000000d, "Printer Driver Types Archive" },
963 { 0x0000000e, "Languages Available" },
966 static value_string_ext ndps_resource_type_enum_ext
= VALUE_STRING_EXT_INIT(ndps_resource_type_enum
);
968 static const value_string ndps_os_type_enum
[] = {
969 { 0x00000000, "DOS" },
970 { 0x00000001, "Windows 3.1" },
971 { 0x00000002, "Windows 95" },
972 { 0x00000003, "Windows NT" },
973 { 0x00000004, "OS2" },
974 { 0x00000005, "MAC" },
975 { 0x00000006, "UNIX" },
976 { 0x00000007, "Windows NT 4.0" },
977 { 0x00000008, "Windows 2000/XP" },
978 { 0x00000009, "Windows 98" },
979 { 0xffffffff, "None" },
982 static value_string_ext ndps_os_type_enum_ext
= VALUE_STRING_EXT_INIT(ndps_os_type_enum
);
984 static const value_string ndps_banner_type_enum
[] = {
985 { 0x00000000, "All" },
986 { 0x00000001, "PCL" },
987 { 0x00000002, "PostScript" },
988 { 0x00000003, "ASCII Text" },
992 static const value_string ndps_font_type_enum
[] = {
993 { 0x00000000, "TrueType" },
994 { 0x00000001, "PostScript" },
995 { 0x00000002, "System" },
996 { 0x00000003, "SPD" },
997 { 0x00000004, "True Doc" },
1001 static const value_string ndps_archive_enum
[] = {
1002 { 0x00000000, "ZIP" },
1003 { 0x00000001, "JAR" },
1008 static const value_string ndps_res_type_enum
[] = {
1009 { 0x00000000, "Printer Driver" },
1010 { 0x00000001, "Printer Definition" },
1011 { 0x00000002, "Banner Page" },
1012 { 0x00000003, "Font" },
1013 { 0x00000004, "Generic Resource" },
1014 { 0x00000005, "Print Driver Archive" },
1018 static const value_string ndps_print_arg_enum
[] = {
1019 { 0x00000000, "Create Job" },
1020 { 0x00000001, "Add Document" },
1021 { 0x00000002, "Close Job" },
1025 static const value_string ndps_doc_content_enum
[] = {
1026 { 0x00000000, "Content Included" },
1027 { 0x00000001, "Content Referenced" },
1031 static const value_string ndps_interrupt_job_enum
[] = {
1032 { 0x00000000, "Job ID" },
1033 { 0x00000001, "Name" },
1037 static const value_string ndps_pause_job_enum
[] = {
1038 { 0x00000000, "Job ID" },
1039 { 0x00000001, "Name" },
1043 static const value_string ndps_resubmit_op_enum
[] = {
1044 { 0x00000000, "Copy" },
1045 { 0x00000001, "Move" },
1049 static const value_string ndps_shutdown_enum
[] = {
1050 { 0x00000000, "Do Current Jobs" },
1051 { 0x00000001, "Immediate" },
1052 { 0x00000002, "Do Pending Jobs" },
1056 static const value_string ndps_list_profiles_choice_enum
[] = {
1057 { 0x00000000, "ID" },
1058 { 0x00000001, "Filter" },
1062 static const value_string ndps_list_profiles_result_enum
[] = {
1063 { 0x00000000, "Complete" },
1064 { 0x00000001, "No Event Objects" },
1065 { 0x00000002, "Profile ID's" },
1069 static const value_string ndps_ds_info_enum
[] = {
1070 { 0x00000000, "Add" },
1071 { 0x00000001, "Remove" },
1072 { 0x00000002, "Update" },
1076 static const value_string ndps_list_services_enum
[] = {
1077 { 0x00000000, "Supported" },
1078 { 0x00000001, "Enabled" },
1082 static const value_string ndps_data_item_enum
[] = {
1083 { 0x00000000, "Int8" },
1084 { 0x00000001, "Int16" },
1085 { 0x00000002, "Int32" },
1086 { 0x00000003, "Boolean" },
1087 { 0x00000004, "Character String" },
1088 { 0x00000005, "Byte String" },
1092 static const value_string ndps_list_local_servers_enum
[] = {
1093 { 0x00000000, "Specification" },
1094 { 0x00000001, "Continuation" },
1098 static const value_string ndps_delivery_method_enum
[] = {
1099 { 0x00000000, "Specification" },
1100 { 0x00000001, "Continuation" },
1104 static const value_string ndps_attribute_enum
[] = {
1105 { 0x00000000, "Null" },
1106 { 0x00000001, "Text" },
1107 { 0x00000002, "Descriptive Name" },
1108 { 0x00000003, "Descriptor" },
1109 { 0x00000004, "Message" },
1110 { 0x00000005, "Error Message" },
1111 { 0x00000006, "Simple Name" },
1112 { 0x00000007, "Distinguished Name String" },
1113 { 0x00000008, "Distinguished Name Seq" },
1114 { 0x00000009, "Delta Time" },
1115 { 0x0000000a, "Time" },
1116 { 0x0000000b, "Integer" },
1117 { 0x0000000c, "Integer Seq" },
1118 { 0x0000000d, "Cardinal" },
1119 { 0x0000000e, "Cardinal Seq" },
1120 { 0x0000000f, "Positive Integer" },
1121 { 0x00000010, "Integer Range" },
1122 { 0x00000011, "Cardinal Range" },
1123 { 0x00000012, "Maximum Integer" },
1124 { 0x00000013, "Minimum Integer" },
1125 { 0x00000014, "Integer 64" },
1126 { 0x00000015, "Integer 64 Seq" },
1127 { 0x00000016, "Cardinal 64" },
1128 { 0x00000017, "Cardinal 64 Seq" },
1129 { 0x00000018, "Positive Integer 64" },
1130 { 0x00000019, "Integer 64 Range" },
1131 { 0x0000001a, "Cardinal 64 Range" },
1132 { 0x0000001b, "Maximum Integer 64" },
1133 { 0x0000001c, "Minimum Integer 64" },
1134 { 0x0000001d, "Real" },
1135 { 0x0000001e, "Real Seq" },
1136 { 0x0000001f, "Non-Negative Real" },
1137 { 0x00000020, "Real Range" },
1138 { 0x00000021, "Non-Negative Real Range" },
1139 { 0x00000022, "Boolean" },
1140 { 0x00000023, "Percent" },
1141 { 0x00000024, "Object Identifier" },
1142 { 0x00000025, "Object Identifier Seq" },
1143 { 0x00000026, "Name or OID" },
1144 { 0x00000027, "Name or OID Seq" },
1145 { 0x00000028, "Distinguished Name" },
1146 { 0x00000029, "Relative Distinguished Name Seq" },
1147 { 0x0000002a, "Realization" },
1148 { 0x0000002b, "Medium Dimensions" },
1149 { 0x0000002c, "Dimension" },
1150 { 0x0000002d, "XY Dimensions" },
1151 { 0x0000002e, "Locations" },
1152 { 0x0000002f, "Area" },
1153 { 0x00000030, "Area Seq" },
1154 { 0x00000031, "Edge" },
1155 { 0x00000032, "Font Reference" },
1156 { 0x00000033, "Cardinal or OID" },
1157 { 0x00000034, "OID Cardinal Map" },
1158 { 0x00000035, "Cardinal or Name or OID" },
1159 { 0x00000036, "Positive Integer or OID" },
1160 { 0x00000037, "Event Handling Profile" },
1161 { 0x00000038, "Octet String" },
1162 { 0x00000039, "Priority" },
1163 { 0x0000003a, "Locale" },
1164 { 0x0000003b, "Method Delivery Address" },
1165 { 0x0000003c, "Object Identification" },
1166 { 0x0000003d, "Results Profile" },
1167 { 0x0000003e, "Criteria" },
1168 { 0x0000003f, "Job Password" },
1169 { 0x00000040, "Job Level" },
1170 { 0x00000041, "Job Categories" },
1171 { 0x00000042, "Print Checkpoint" },
1172 { 0x00000043, "Ignored Attribute" },
1173 { 0x00000044, "Resource" },
1174 { 0x00000045, "Medium Substitution" },
1175 { 0x00000046, "Font Substitution" },
1176 { 0x00000047, "Resource Context Seq" },
1177 { 0x00000048, "Sides" },
1178 { 0x00000049, "Page Select Seq" },
1179 { 0x0000004a, "Page Media Select" },
1180 { 0x0000004b, "Document Content" },
1181 { 0x0000004c, "Page Size" },
1182 { 0x0000004d, "Presentation Direction" },
1183 { 0x0000004e, "Page Order" },
1184 { 0x0000004f, "File Reference" },
1185 { 0x00000050, "Medium Source Size" },
1186 { 0x00000051, "Input Tray Medium" },
1187 { 0x00000052, "Output Bins Chars" },
1188 { 0x00000053, "Page ID Type" },
1189 { 0x00000054, "Level Range" },
1190 { 0x00000055, "Category Set" },
1191 { 0x00000056, "Numbers Up Supported" },
1192 { 0x00000057, "Finishing" },
1193 { 0x00000058, "Print Contained Object ID" },
1194 { 0x00000059, "Print Config Object ID" },
1195 { 0x0000005a, "Typed Name" },
1196 { 0x0000005b, "Network Address" },
1197 { 0x0000005c, "XY Dimensions Value" },
1198 { 0x0000005d, "Name or OID Dimensions Map" },
1199 { 0x0000005e, "Printer State Reason" },
1200 { 0x0000005f, "Enumeration" },
1201 { 0x00000060, "Qualified Name" },
1202 { 0x00000061, "Qualified Name Set" },
1203 { 0x00000062, "Colorant Set" },
1204 { 0x00000063, "Resource Printer ID" },
1205 { 0x00000064, "Event Object ID" },
1206 { 0x00000065, "Qualified Name Map" },
1207 { 0x00000066, "File Path" },
1208 { 0x00000067, "Uniform Resource Identifier" },
1209 { 0x00000068, "Cardinal or Enum or Time" },
1210 { 0x00000069, "Print Contained Object ID Set" },
1211 { 0x0000006a, "Octet String Pair" },
1212 { 0x0000006b, "Octet String Integer Pair" },
1213 { 0x0000006c, "Extended Resource Identifier" },
1214 { 0x0000006d, "Event Handling Profile 2" },
1217 static value_string_ext ndps_attribute_enum_ext
= VALUE_STRING_EXT_INIT(ndps_attribute_enum
);
1219 /* XXX: There are a number of duplicate values in the following. */
1220 /* (I've commented out the duplicate values which would not have
1221 been found via a linear search in the original (unsorted)
1222 version of this value_string array). */
1224 static const value_string ndps_error_types
[] = {
1225 { 0x00000000, "Ok" },
1226 { 0x00000001, "Error" },
1227 /* { 0x01000001, "Invalid Parameter" },*/ /* Dup */
1228 { 0x01000002, "Parameter Value Unrecognized" },
1229 { 0x01000003, "Call Back Error" },
1230 { 0x01000004, "Standard IO Error" },
1231 { 0x01000005, "NDS Error" },
1232 { 0x01000006, "Unicode Error" },
1233 { 0x01000007, "Invalid Operator" },
1234 { 0x01000009, "Parameter Value Unsupported" },
1235 { 0x0100000a, "Windows Error" },
1236 { 0x0100000b, "WSA Last Error" },
1237 { 0x0100000c, "SLP Error" },
1238 { 0x0100000d, "NetWare Client Error" },
1239 { 0x03000005, "NDS Error with Position" },
1240 { 0x030a0001, "No Memory" },
1241 { 0x030a0009, "Artificial Memory Limit" },
1242 { 0x030a000c, "Memory Allocated with Wrong NLM ID" },
1244 { 0xffffe872, "(-6030) Error Abort Transaction" },
1245 { 0xffffe873, "(-6029) Attribute Maintenance in Progress" },
1246 { 0xffffe874, "(-6028) Error Must Wait Checkpoint" },
1247 { 0xffffe875, "(-6027) Unsupported Version" },
1248 { 0xffffe876, "(-6026) Referral Device Full" },
1249 { 0xffffe877, "(-6025) Error Backup Active" },
1250 { 0xffffe878, "(-6024) Referral File Not Found" },
1251 { 0xffffe879, "(-6023) Bad Referral File Number" },
1252 { 0xffffe87a, "(-6022) Error Referral Trans Gap" },
1253 { 0xffffe87b, "(-6021) Invalid File Sequence" },
1254 { 0xffffe87c, "(-6020) Bad Referral Serial Number" },
1255 { 0xffffe87d, "(-6019) Bad Referral Database Serial Number" },
1256 { 0xffffe87e, "(-6018) Serial Number Mismatch" },
1257 { 0xffffe87f, "(-6017) No Such Schema" },
1258 { 0xffffe880, "(-6016) Error Returning Partial Results" },
1259 { 0xffffe881, "(-6015) Server in Skulk" },
1260 { 0xffffe882, "(-6014) Error Old View" },
1261 { 0xffffe883, "(-6013) Error Setting up for Write" },
1262 { 0xffffe884, "(-6012) Error Setting Up for Read" },
1263 { 0xffffe885, "(-6011) Error Flushing File" },
1264 { 0xffffe886, "(-6010) Error Initializing IO System" },
1265 { 0xffffe887, "(-6009) Error Renaming File" },
1266 { 0xffffe888, "(-6008) Error Deleting File" },
1267 { 0xffffe889, "(-6007) Error Checking File Existence" },
1268 { 0xffffe88a, "(-6006) Error Getting Free Blocks" },
1269 { 0xffffe88b, "(-6005) Error Expanding File" },
1270 { 0xffffe88c, "(-6004) Error Getting File Info" },
1271 { 0xffffe88d, "(-6003) Error Closing File" },
1272 { 0xffffe88e, "(-6002) Error Parsing File Name" },
1273 { 0xffffe88f, "(-6001) Error Truncating File" },
1275 { 0xFFFFFAFD, "Notify Failed to Authenticate Connection Error" },
1276 { 0xFFFFFAFE, "Notify Failed to Authenticate Internal Error" },
1277 { 0xFFFFFAFF, "Notify Failed to Authenticate Protocol Mismatch" },
1279 { 0xFFFFFB00, "Notify Failed to Authenticate" },
1280 { 0xFFFFFB01, "Notify Duplicate Session ID" },
1281 { 0xFFFFFB02, "Notify Unknown Attribute Object ID" },
1282 { 0xFFFFFB03, "Notify Invalid SLP URL Format" },
1283 { 0xFFFFFB04, "Notify Invalid SLP Attribute Format" },
1284 { 0xFFFFFB05, "Notify Failed to Launch RPC Server" },
1285 { 0xFFFFFB06, "Notify No Protocols Available" },
1286 { 0xFFFFFB07, "Notify Failed to Startup Winsock" },
1287 { 0xFFFFFB08, "Notify IP Not Supported By Method" },
1288 { 0xFFFFFB09, "Notify IPX Not Supported By Method" },
1289 { 0xFFFFFB0A, "Notify No Filter Provided" },
1290 { 0xFFFFFB0B, "Notify Maximum Methods Supported" },
1291 { 0xFFFFFB0C, "Notify Broker Has No File Rights" },
1292 { 0xFFFFFB0D, "Notify Bad Volume in Address" },
1293 { 0xFFFFFB0E, "Notify Failed to Send Notification" },
1294 { 0xFFFFFB0F, "Notify User Object No Default Server" },
1295 { 0xFFFFFB10, "Notify Unsupported Delivery Address Type" },
1296 { 0xFFFFFB11, "Notify Delivery Method Rejected Address" },
1297 { 0xFFFFFB12, "Notify Foreign NDS Tree Name" },
1298 { 0xFFFFFB13, "Notify Service Not Fully Enabled" },
1299 { 0xFFFFFB14, "Notify Using Unknown Methods" },
1300 { 0xFFFFFB15, "Notify Public Already Defined" },
1301 { 0xFFFFFB16, "Notify Unresolved External" },
1302 { 0xFFFFFB17, "Notify Autoload Modules Not Loaded" },
1303 { 0xFFFFFB18, "Notify Can't Load at Startup" },
1304 { 0xFFFFFB19, "Notify Inconsistent File Format" },
1305 { 0xFFFFFB1A, "Notify Initialization Failure" },
1306 { 0xFFFFFB1B, "Notify Already in Progress" },
1307 { 0xFFFFFB1C, "Notify Reentrant Initialization Failure" },
1308 { 0xFFFFFB1D, "Notify Wrong NLM File Version" },
1309 { 0xFFFFFB1E, "Notify Not NLM File Format" },
1310 { 0xFFFFFB1F, "Notify Error Reading File" },
1311 { 0xFFFFFB20, "Notify Could Not Find File" },
1312 { 0xFFFFFB21, "Notify Invalid Continuation Handle" },
1313 { 0xFFFFFB22, "Notify Unknown Continuation Handle" },
1314 { 0xFFFFFB23, "Notify Bad Method Filename" },
1315 { 0xFFFFFB24, "Notify No Persistent Storage" },
1316 { 0xFFFFFB25, "Notify No Effective Rights" },
1317 { 0xFFFFFB26, "Notify Initialization Error" },
1318 { 0xFFFFFB27, "Notify Unknown RPC Session" },
1319 { 0xFFFFFB28, "Notify Option Not Supported" },
1320 { 0xFFFFFB29, "Notify Unknown Notify Handle" },
1321 { 0xFFFFFB2A, "Notify Empty Event Object Set" },
1322 { 0xFFFFFB2B, "Notify Failed to Register With Any Server" },
1323 { 0xFFFFFB2C, "Notify No Service Registry Available" },
1324 { 0xFFFFFB2D, "Notify Not Admin Type Session" },
1325 { 0xFFFFFB2E, "Notify Not Supplied Type of Session" },
1326 { 0xFFFFFB2F, "Notify User Interface Not Supported" },
1327 { 0xFFFFFB30, "Notify Failed to Make Change Permanent" },
1328 { 0xFFFFFB31, "Notify Unknown Designator" },
1329 { 0xFFFFFB32, "Notify Unknown Object ID" },
1330 { 0xFFFFFB33, "Notify Error Writing Database" },
1331 { 0xFFFFFB34, "Notify Unknown Attribute Value" },
1332 { 0xFFFFFB35, "Notify Unknown Choice" },
1333 { 0xFFFFFB36, "Notify Invalid Credentials" },
1334 { 0xFFFFFB37, "Notify Duplicate Session ID" },
1335 { 0xFFFFFB38, "Notify Invalid Arguments" },
1336 { 0xFFFFFB39, "Notify Can't Load Delivery Method" },
1337 { 0xFFFFFB3A, "Notify Queue Empty" },
1338 { 0xFFFFFB3B, "Notify Unknown Language ID" },
1339 { 0xFFFFFB3C, "Out of Notify Entries" },
1340 { 0xFFFFFB3D, "Notify Unknown Modify Operation" },
1341 { 0xFFFFFB3E, "Notify Service Disabled" },
1342 { 0xFFFFFB3F, "Notify Unknown Method" },
1343 { 0xFFFFFB40, "Notify Method Already Installed" },
1344 { 0xFFFFFB41, "Notify Unknown Event Object ID" },
1345 { 0xFFFFFB42, "Corrupted Notify Database" },
1346 { 0xFFFFFB43, "Wrong Notify Database Version" },
1347 { 0xFFFFFB44, "Notify Error Writing File" },
1348 { 0xFFFFFB45, "Notify Error Reading File" },
1349 { 0xFFFFFB46, "Notify Unknown Notify Profile" },
1350 { 0xFFFFFB47, "Notify Unknown Session" },
1351 { 0xFFFFFB48, "Notify No Attribute Values" },
1352 { 0xFFFFFB49, "Notify DS Value Size Too Large" },
1353 { 0xFFFFFB4A, "Notify Service Name Must be Fully Distinguished" },
1354 { 0xFFFFFB4B, "Notify Failed Login" },
1355 { 0xFFFFFB4C, "Notify Failed to Create Context" },
1356 { 0xFFFFFB4D, "Notify Failed to Get Messages" },
1357 { 0xFFFFFB4E, "Notify Failed to Create Thread" },
1358 { 0xFFFFFB4F, "Notify Bad NetWare Version" },
1359 { 0xFFFFFB50, "Notify Out of Memory" }, /* Notification Service Errors */
1360 { 0xFFFFFB99, "Registry Invalid Continuation Handle" },
1361 { 0xFFFFFB9A, "Registry Not in List Iteration" },
1362 { 0xFFFFFB9B, "Registry Option Not Supported" },
1363 { 0xFFFFFB9C, "Registry Unknown Designator" },
1364 { 0xFFFFFB9D, "Not Registry Type Session" },
1365 { 0xFFFFFB9E, "Registry Not Server Type Session" },
1366 { 0xFFFFFB9F, "Registry Server Type Session" },
1367 { 0xFFFFFBA0, "Registry Type Session" },
1368 { 0xFFFFFBA1, "Registry Invalid Credential" },
1369 { 0xFFFFFBA2, "Registry Unknown Server Entry" },
1370 { 0xFFFFFBA3, "Registry Duplicate Session ID" },
1371 { 0xFFFFFBA4, "Registry Invalid Arguments" },
1372 { 0xFFFFFBA5, "Registry Can't Create Client" },
1373 { 0xFFFFFBA6, "Registry Can't Bind to Registry" },
1374 { 0xFFFFFBA7, "Registry Duplicate Server Entry" },
1375 { 0xFFFFFBA8, "Registry Can't Start Advertise" },
1376 { 0xFFFFFBA9, "Registry Unknown Modify Operation" },
1377 { 0xFFFFFBAA, "Registry Service Disabled" },
1378 { 0xFFFFFBAB, "Registry Unknown Session" },
1379 { 0xFFFFFBAC, "Registry No Attribute Values" },
1380 { 0xFFFFFBAD, "Registry DS Value Size Too Large" },
1381 { 0xFFFFFBAE, "Registry Service Name Must Be Fully Distinguished" },
1382 { 0xFFFFFBAF, "Registry Failed to Get Messages" },
1383 { 0xFFFFFBB0, "Registry Failed to Create Thread" },
1384 { 0xFFFFFBB1, "Registry Failed Login" },
1385 { 0xFFFFFBB2, "Registry Failed to Create Context" },
1386 { 0xFFFFFBB3, "Registry Bad NetWare Version" },
1387 { 0xFFFFFBB4, "Registry Out of Memory" }, /* SRS Errors */
1388 { 0xFFFFFBEE, "Broker Service Failed to Initialize" },
1389 { 0xFFFFFBEF, "Broker Other Broker Using Object" },
1390 { 0xFFFFFBF0, "Broker Public Already Defined" },
1391 { 0xFFFFFBF1, "Broker Unresolved External" },
1392 { 0xFFFFFBF2, "Broker Autoload Modules Not Loaded" },
1393 { 0xFFFFFBF3, "Broker Can't Load at Startup" },
1394 { 0xFFFFFBF4, "Broker Inconsistent File Format" },
1395 { 0xFFFFFBF5, "Broker Initialize Failure" },
1396 { 0xFFFFFBF6, "Broker Already in Progress" },
1397 { 0xFFFFFBF7, "Broker Reentrant Initialization Failure" },
1398 { 0xFFFFFBF8, "Broker Wrong NLM File Version" },
1399 { 0xFFFFFBF9, "Broker Not NLM File Format" },
1400 { 0xFFFFFBFA, "Broker Error Reading File" },
1401 { 0xFFFFFBFB, "Broker Could Not Find File" },
1402 { 0xFFFFFBFC, "Broker No Effective Rights" },
1403 { 0xFFFFFBFD, "Broker Option Not Supported" },
1404 { 0xFFFFFBFE, "Broker Not Admin Type Session" },
1405 { 0xFFFFFBFF, "Broker Failed to Make Change Permanent" },
1407 { 0xFFFFFC00, "Broker Unknown Designator" },
1408 { 0xFFFFFC01, "Broker Invalid Credential" },
1409 { 0xFFFFFC02, "Broker Service Already Disabled" },
1410 { 0xFFFFFC03, "Broker Service Already Enabled" },
1411 { 0xFFFFFC04, "Broker Unknown Service" },
1412 { 0xFFFFFC05, "Broker Duplicate Session ID" },
1413 { 0xFFFFFC06, "Broker Invalid Arguments" },
1414 { 0xFFFFFC07, "Broker Unknown Modify Operation" },
1415 { 0xFFFFFC08, "Broker Service Disabled" },
1416 { 0xFFFFFC09, "Broker Unknown Session" },
1417 { 0xFFFFFC0A, "Broker No Attribute Values" },
1418 { 0xFFFFFC0B, "Broker DS Value Size Too Large" },
1419 { 0xFFFFFC0C, "Broker Uninitialized Module" },
1420 { 0xFFFFFC0D, "Broker Service Name Must be Fully Distinguished" },
1421 { 0xFFFFFC0E, "Broker Failed to Allocate Resources" },
1422 { 0xFFFFFC0F, "Broker Failed to Get Messages" },
1423 { 0xFFFFFC10, "Broker Failed to Initialize NUT" },
1424 { 0xFFFFFC11, "Broker Failed to Create Thread" },
1425 { 0xFFFFFC12, "Invalid Broker Name" },
1426 { 0xFFFFFC13, "Invalid Broker Password" },
1427 { 0xFFFFFC14, "Not Broker Class" },
1428 { 0xFFFFFC15, "Broker Name Not Given" },
1429 { 0xFFFFFC16, "Broker Wrong Command Line Arguments" },
1430 { 0xFFFFFC17, "Broker Bad NetWare Version" },
1431 { 0xFFFFFC18, "Broker Out of Memory" }, /* Broker Errors */
1432 { 0xFFFFFC2F, "Resource Manager Failed to Write INF in Address" },
1433 { 0xFFFFFC30, "Resource Manager File is Zero Length" },
1434 { 0xFFFFFC31, "Resource Manager Can't Create Resource Reference" },
1435 { 0xFFFFFC32, "Resource Manager Can't Initialize NDPS Library" },
1436 { 0xFFFFFC33, "Resource Manager No Rights to Remote Resdir" },
1437 { 0xFFFFFC34, "Resource Manager Failed to Authenticate Connection Error" },
1438 { 0xFFFFFC35, "Resource Manager Failed to Authenticate Internal Error" },
1439 { 0xFFFFFC36, "Resource Manager Failed to Authenticate Protocol Mismatch" },
1440 { 0xFFFFFC37, "Resource Manager Failed to Authenticate" },
1441 { 0xFFFFFC38, "Resource Manager Unresolved External" },
1442 { 0xFFFFFC39, "Resource Manager Invalid SLP URL Format" },
1443 { 0xFFFFFC3A, "Resource Manager Invalid SLP Attribute Format" },
1444 { 0xFFFFFC3B, "Resource Manager Failed to Launch RPC Server" },
1445 { 0xFFFFFC3C, "Resource Manager No Protocols Available" },
1446 { 0xFFFFFC3D, "Resource Manager Failed to Start Winsock" },
1447 { 0xFFFFFC3E, "Resource Manager Connection Lost RMS Data" },
1448 { 0xFFFFFC3F, "Resource Manager Duplicate TIRPC Session" },
1449 { 0xFFFFFC40, "Resource Manager Font Manager Failure" },
1450 { 0xFFFFFC41, "Resource Manager Font Manager Path Too Long" },
1451 { 0xFFFFFC42, "Resource Manager Font Manager Bad Parameter" },
1452 { 0xFFFFFC43, "Resource Manager Font Manager System Error" },
1453 { 0xFFFFFC44, "Resource Manager Font Manager Not Initialized" },
1454 { 0xFFFFFC45, "Resource Manager Font Manager No Such Font" },
1455 { 0xFFFFFC46, "Resource Manager Font Manager Corrupt Index File" },
1456 { 0xFFFFFC47, "Resource Manager Font Manager Sequence Error" },
1457 { 0xFFFFFC48, "Resource Manager Font Manager Reentrancy" },
1458 { 0xFFFFFC49, "Resource Manager Font Manager IO Error" },
1459 { 0xFFFFFC4B, "Resource Manager Session Being Removed" },
1460 { 0xFFFFFC4C, "Resource Manager Unknown RPC Session" },
1461 { 0xFFFFFC4D, "Resource Manager Document ID Format Error" },
1462 { 0xFFFFFC4E, "Resource Manager Bad File Attribute" },
1463 { 0xFFFFFC4F, "Resource Manager No Effective Rights" },
1464 { 0xFFFFFC50, "Resource Manager Not Admin Session" },
1465 { 0xFFFFFC51, "Resource Manager Unknown Designator" },
1466 { 0xFFFFFC52, "Resource Manager Failed to Register to Any Server" },
1467 { 0xFFFFFC53, "Resource Manager No Service Registry Available" },
1468 { 0xFFFFFC54, "Resource Manager Initialization Error" },
1469 { 0xFFFFFC55, "Resource Manager Invalid Arguments" },
1470 { 0xFFFFFC56, "Resource Manager Unicode Convention Error" },
1471 { 0xFFFFFC57, "Resource Manager Option Not Supported" },
1472 { 0xFFFFFC58, "Resource Manager No Printer Types in List" },
1473 { 0xFFFFFC59, "Resource Manager Printer Definition Type Unknown" },
1474 { 0xFFFFFC5A, "Resource Manager No Banner Files Present" },
1475 { 0xFFFFFC5B, "Resource Manager OS Not Supported" },
1476 { 0xFFFFFC5C, "Resource Manager List Type Unknown" },
1477 { 0xFFFFFC5D, "Resource Manager Banner Type Invalid" },
1478 { 0xFFFFFC5E, "Resource Manager No Such Filename" },
1479 { 0xFFFFFC5F, "Resource Manager Resource Type Invalid" },
1480 { 0xFFFFFC60, "Resource Manager Write File Error" },
1481 { 0xFFFFFC61, "Resource Manager Read File Error" },
1482 { 0xFFFFFC62, "Resource Manager File Open Error" },
1483 { 0xFFFFFC63, "Resource Manager No INF Files Present" },
1484 { 0xFFFFFC64, "Resource Manager No Printer Type in INF File" },
1485 { 0xFFFFFC65, "Resource Manager INF File Format Error" },
1486 { 0xFFFFFC66, "Resource Manager NPD Files Generation Error" },
1487 { 0xFFFFFC67, "Resource Manager Failed to Login" },
1488 { 0xFFFFFC68, "Resource Manager Failed to Create Context" },
1489 { 0xFFFFFC69, "Resource Manager Failed to Get Messages" },
1490 { 0xFFFFFC6A, "Resource Manager Failed to Register With any Server" },
1491 { 0xFFFFFC6B, "Resource Manager No Service Registry Available" },
1492 { 0xFFFFFC6C, "Resource Manager Invalid Credentials" },
1493 { 0xFFFFFC6D, "Resource Manager Duplicate Session ID" },
1494 { 0xFFFFFC6E, "Resource Manager Unknown Modify Operation" },
1495 { 0xFFFFFC6F, "Resource Manager Service Disabled" },
1496 { 0xFFFFFC70, "Resource Manager Error Writing File" },
1497 { 0xFFFFFC71, "Resource Manager Error Reading File" },
1498 { 0xFFFFFC72, "Resource Manager Unknown Session" },
1499 { 0xFFFFFC73, "Resource Manager No Attribute Values" },
1500 { 0xFFFFFC74, "Resource Manager DS Value Size Too Large" },
1501 { 0xFFFFFC75, "Resource Manager Service Name Must be Fully Distinguished" },
1502 { 0xFFFFFC76, "Resource Manager Failed to Create Thread" },
1503 { 0xFFFFFC77, "Resource Manager Invalid Broker Name" },
1504 { 0xFFFFFC78, "Resource Manager Invalid Broker Password" },
1505 { 0xFFFFFC79, "Resource Manager Broker Name Not Given" },
1506 { 0xFFFFFC7A, "Resource Manager Wrong Command Line Arguments" },
1507 { 0xFFFFFC7B, "Resource Manager Bad NetWare Version" },
1508 { 0xFFFFFC7C, "Resource Manager Out of Memory" }, /* ResMan Errors */
1510 { 0xFFFFFC6D, "Database Descriptor Being Deleted" },
1511 { 0xFFFFFC6E, "Database Descriptor In Use" },
1512 { 0xFFFFFC6F, "Database Object Exists" },
1513 { 0xFFFFFC70, "Database Already Deleted" },
1514 { 0xFFFFFC71, "Database Can't Delete Printer Agent Directory" },
1515 { 0xFFFFFC72, "Database Can't Write Index File" },
1516 { 0xFFFFFC73, "Database Can't Write Data File" },
1517 { 0xFFFFFC74, "Database Can't Read Index File" },
1518 { 0xFFFFFC75, "Database Can't Read Data File" },
1519 { 0xFFFFFC76, "Database Can't Rename File" },
1520 { 0xFFFFFC77, "Database Index File Not Open" },
1521 { 0xFFFFFC78, "Database Can't Open Index File" },
1522 { 0xFFFFFC79, "Database Can't Open Data File" },
1523 { 0xFFFFFC7A, "Database Can't Find Data File" },
1524 { 0xFFFFFC7B, "Database Can't Create File" },
1526 { 0xFFFFFCAD, "NDPSM SRS Service Error" },
1527 { 0xFFFFFCAE, "NDPSM Broker Server Connecting" },
1528 { 0xFFFFFCAF, "NDPSM Failed Validation" },
1529 { 0xFFFFFCB0, "NDPSM RMS Service Error" },
1530 { 0xFFFFFCB1, "NDPSM Accounting Service Error" },
1531 { 0xFFFFFCB2, "NDPSM Could not Create Account Reference" },
1532 { 0xFFFFFCB3, "NDPSM Changing Connection" },
1533 { 0xFFFFFCB4, "NDPSM No Scheduler" },
1534 { 0xFFFFFCB5, "NDPSM Job is Active" },
1535 { 0xFFFFFCB6, "NDPSM Can't Write Document File" },
1536 { 0xFFFFFCB7, "NDPSM Can't Open Document File" },
1537 { 0xFFFFFCB8, "NDPSM Can't Delete Document File" },
1538 { 0xFFFFFCB9, "NDPSM Can't Create Document File" },
1539 { 0xFFFFFCBA, "NDPSM Too Many NetWare Servers" },
1540 { 0xFFFFFCBB, "NDPSM Can't Attach" },
1541 { 0xFFFFFCBC, "NDPSM Already Attached" },
1542 { 0xFFFFFCBD, "NDPSM No Mandatory Attribute" },
1543 { 0xFFFFFCBE, "NDPSM PDS Refuses Rename" },
1544 { 0xFFFFFCBF, "NDPSM Duplicate Value" },
1545 { 0xFFFFFCC0, "NDPSM RPC Failure" },
1546 { 0xFFFFFCC1, "NDPSM Session Not Found" },
1547 { 0xFFFFFCC2, "NDPSM PDS Not Responding" },
1548 { 0xFFFFFCC3, "NDPSM Medium Needs Mounted" },
1549 { 0xFFFFFCC4, "NDPSM Notification Service Error" },
1550 { 0xFFFFFCC5, "NDPSM PSM Going Down" },
1551 { 0xFFFFFCC6, "NDPSM PSM Initializing" },
1552 { 0xFFFFFCC7, "NDPSM Version Incompatible" },
1553 { 0xFFFFFCC8, "NDPSM Object Not Locked" },
1554 { 0xFFFFFCC9, "NDPSM Bad Printer Agent Handle" },
1555 { 0xFFFFFCCA, "NDPSM Printer Agent Paused" },
1556 { 0xFFFFFCCB, "NDPSM Printer Agent Disabled" },
1557 { 0xFFFFFCCC, "NDPSM Printer Agent Going Down" },
1558 { 0xFFFFFCCD, "NDPSM Printer Agent Initializing" },
1559 { 0xFFFFFCCE, "NDPSM Communications Error" },
1560 { 0xFFFFFCCF, "NDPSM Job Not Found" },
1561 { 0xFFFFFCD0, "NDPSM Invalid Value Syntax" },
1562 { 0xFFFFFCD1, "NDPSM Values Not Comparable" },
1563 { 0xFFFFFCD2, "NDPSM Value Not Found" },
1564 { 0xFFFFFCD3, "NDPSM Attribute Not Found" },
1565 { 0xFFFFFCD4, "NDPSM Object Not Found" },
1566 { 0xFFFFFCD5, "NDPSM Bad Parameter" },
1567 { 0xFFFFFCD6, "NDPSM Invalid Class" },
1568 { 0xFFFFFCD7, "NDPSM No PDS" },
1569 { 0xFFFFFCD8, "NDPSM Error Accessing Database" },
1570 { 0xFFFFFCD9, "NDPSM Unsupported Operation" },
1571 { 0xFFFFFCDA, "NDPSM Undefined Type" },
1572 { 0xFFFFFCDB, "NDPSM Unsupported Type" },
1573 { 0xFFFFFCDC, "NDPSM Job Retention Limit" },
1574 { 0xFFFFFCDD, "NDPSM Job Storage Limit" },
1575 { 0xFFFFFCDE, "NDPSM Memory Not Found" },
1576 { 0xFFFFFCDF, "NDPSM No Memory" }, /* NDPSM Errors */
1577 { 0xfffffce1, "(-799) Error Getting File Size" },
1578 { 0xfffffce2, "(-798) Error Positioning in File" },
1579 { 0xfffffce3, "(-797) Error Direct Writing File" },
1580 { 0xfffffce4, "(-796) Error Writing File" },
1581 { 0xfffffce5, "(-795) Error Direct Reading File" },
1582 { 0xfffffce6, "(-794) Error Reading File" },
1583 { 0xfffffce7, "(-793) Error Direct Creating File" },
1584 { 0xfffffce8, "(-792) Error Creating File" },
1585 { 0xfffffce9, "(-791) Error Direct Opening File" },
1586 { 0xfffffcea, "(-790) Error Opening File" },
1587 { 0xfffffceb, "(-789) Invalid Template" },
1588 { 0xfffffcec, "(-788) Error Schema Partition" },
1589 { 0xfffffced, "(-787) Illegal Schema Attribute" },
1590 { 0xfffffcee, "(-786) DIB IO Failure" },
1591 { 0xfffffcef, "(-785) DIB Error" },
1592 { 0xfffffcf0, "(-784) Wait Timeout" },
1593 { 0xfffffcf1, "(-783) VRDIM Not Initialized" },
1594 { 0xfffffcf2, "(-782) Root Unreachable" },
1595 { 0xfffffcf3, "(-781) Entry Not Local" },
1596 { 0xfffffcf4, "(-780) Request not Supported" },
1597 { 0xfffffcf5, "(-779) Error Cannot Go Remote" },
1598 { 0xfffffcf6, "(-778) VpVector and VpvUser which must be correlated, are out of sync" },
1599 { 0xfffffcf7, "(-777) Attempted to modify an object's attribute that is not stored on the sparse replica" },
1600 { 0xfffffcf8, "(-776) Attempted to perform an NDS operation, and the DS agent on this server is closing" },
1601 { 0xfffffcf9, "(-775) Invalid OID Format" },
1602 { 0xfffffcfa, "(-774) Repairing DIB" },
1603 { 0xfffffcfb, "(-773) Iterator Syntax" },
1604 { 0xfffffcfc, "(-772) Illegal Transaction Operation" },
1605 { 0xfffffcfd, "(-771) Transaction Active" },
1606 { 0xfffffcfe, "(-770) No Transaction Active" },
1607 { 0xfffffcff, "(-769) Duplicate Naming" },
1609 { 0xfffffd00, "(-768) Query Maximum Count" },
1610 { 0xfffffd01, "(-767) Query Timeout" },
1611 { 0xfffffd02, "(-766) Incompatible Replica Version" },
1612 { 0xfffffd03, "(-765) EOF Hit" },
1613 { 0xfffffd04, "(-764) BOF Hit" },
1614 { 0xfffffd05, "(-763) Verb Exceeds Table Length" },
1615 { 0xfffffd06, "(-762) Verb Locked" },
1616 { 0xfffffd07, "(-761) Have Seen State" },
1617 { 0xfffffd08, "(-760) Auxiliary On Alias" },
1618 { 0xfffffd09, "(-759) Auxiliary Not Effective" },
1619 { 0xfffffd0a, "(-758) Auxiliary Not Container" },
1620 { 0xfffffd0b, "(-757) Auxiliary Has Containment" },
1621 { 0xfffffd0c, "(-756) Stream Exists" },
1622 { 0xfffffd0d, "(-755) Invalid Synchronization Data" },
1623 { 0xfffffd0e, "(-754) Callback Cancel" },
1624 { 0xfffffd0f, "(-753) Incompatible OS" },
1625 { 0xfffffd10, "(-752) GUID Failure" },
1626 { 0xfffffd11, "(-751) Unknown Target" },
1627 { 0xfffffd12, "(-750) Operation Cancelled" },
1628 { 0xfffffd13, "(-749) Too Many Referrals" },
1629 { 0xfffffd14, "(-748) Connection Timeout" },
1630 { 0xfffffd15, "(-747) Would Block" },
1631 { 0xfffffd16, "(-746) Zero Creation Time" },
1632 { 0xfffffd17, "(-745) Cache in Use" },
1633 { 0xfffffd18, "(-744) Invalid Control State" },
1634 { 0xfffffd19, "(-743) Invalid Control Function" },
1635 { 0xfffffd1a, "(-742) Wrong DS Version" },
1636 { 0xfffffd1b, "(-741) Name Type Not Supported" },
1637 { 0xfffffd1c, "(-740) SAS Already Registered" },
1638 { 0xfffffd1d, "(-739) Invalid SAS Version" },
1639 { 0xfffffd1e, "(-738) SAS Locked" },
1640 { 0xfffffd1f, "(-737) No Such Template" },
1641 { 0xfffffd20, "(-736) End of Stream" },
1642 { 0xfffffd21, "(-735) Nothing to Abort" },
1643 { 0xfffffd24, "(-732) Database Locked" },
1644 { 0xfffffd25, "(-731) Value Data" },
1645 { 0xfffffd26, "(-730) MASV Bad Range" },
1646 { 0xfffffd27, "(-729) MASV Not Found" },
1647 { 0xfffffd28, "(-728) MASV Already Exists" },
1648 { 0xfffffd29, "(-727) MASV Failure" },
1649 { 0xfffffd2a, "(-726) MASV Invalid Request" },
1650 { 0xfffffd2b, "(-725) MASV No Access" },
1651 { 0xfffffd2c, "(-724) DClient Unavailable" },
1652 { 0xFFFFFD2D, "JPM Accounting Already Serviced" },
1653 { 0xFFFFFD2E, "JPM No CLIB Context" },
1654 { 0xFFFFFD2F, "JPM Printer Agent Shutdown" },
1655 { 0xFFFFFD30, "JPM Printer Agent Paused" },
1656 { 0xFFFFFD31, "JPM Version Incompatible" },
1657 { 0xFFFFFD32, "JPM Print Handler Not Registered" },
1658 { 0xFFFFFD33, "JPM Document Already Closed" },
1659 { 0xFFFFFD34, "JPM Job Already Closed" },
1660 { 0xFFFFFD35, "JPM Bad Object Type" },
1661 { 0xFFFFFD36, "JPM Could not Access Database" },
1662 { 0xFFFFFD37, "JPM Job Not Found" },
1663 { 0xFFFFFD38, "JPM No Job" },
1664 { 0xFFFFFD39, "JPM Printer Agent Already Serviced By PDS" },
1665 { 0xFFFFFD3A, "JPM Not Accepting Requests" },
1666 { 0xFFFFFD3B, "JPM Invalid Request" },
1667 { 0xFFFFFD3C, "JPM Printer Agent Not Found" },
1668 { 0xFFFFFD3D, "JPM Request Queue Full" },
1669 { 0xFFFFFD3E, "JPM Unsupported Operation" },
1670 { 0xFFFFFD3F, "JPM Bad Document Handle" },
1671 { 0xFFFFFD40, "JPM Bad Job Handle" },
1672 { 0xFFFFFD41, "JPM Bad Printer Agent Handle" },
1673 { 0xFFFFFD42, "JPM Failed to Read Document File" },
1674 { 0xFFFFFD43, "JPM Failed to Open Document" },
1675 { 0xFFFFFD44, "JPM Execute Request Later" },
1677 { 0xfffffd2d, "(-723) Stream Not Found" },
1678 { 0xfffffd2e, "(-722) Operational Schema Mismatch" },
1679 { 0xfffffd2f, "(-721) No Such Federation Link" },
1680 { 0xfffffd30, "(-720) Connection Denied" },
1681 { 0xfffffd31, "(-719) Invalid Value Handle" },
1682 { 0xfffffd32, "(-718) Invalid Entry Handle" },
1683 { 0xfffffd33, "(-717) CRC Failure" },
1684 { 0xfffffd34, "(-716) Checksumming Not Supported" },
1685 { 0xfffffd35, "(-715) Checksum Failure" },
1686 { 0xfffffd36, "(-714) Not Implemented" },
1687 { 0xfffffd37, "(-713) Invalid Delimiters" },
1688 { 0xfffffd38, "(-712) Invalid Escape Character" },
1689 { 0xfffffd39, "(-711) Invalid Code Page" },
1690 { 0xfffffd3a, "(-710) Database Read Fail" },
1691 { 0xfffffd3b, "(-709) Insufficient Sockets" },
1692 { 0xfffffd3c, "(-708) Invalid Response" },
1693 { 0xfffffd3d, "(-707) Invalid Signature" },
1694 { 0xfffffd3e, "(-706) Not a Sibling" },
1695 { 0xfffffd3f, "(-705) Duplicate Containment" },
1696 { 0xfffffd40, "(-704) No Master Replica" },
1697 { 0xfffffd41, "(-703) Duplicate Template" },
1698 { 0xfffffd42, "(-702) Invalid Parameter" },
1699 { 0xfffffd43, "(-701) Synchronization Disabled" },
1700 { 0xfffffd44, "(-700) Obsolete API" },
1702 { 0xfffffd45, "(-699) Fatal" },
1703 { 0xfffffd46, "(-698) Replica in Skulk" },
1704 { 0xfffffd47, "(-697) DS Cannot Reload" },
1705 { 0xfffffd48, "(-696) DS Loader Busy" },
1706 { 0xfffffd49, "(-695) Agent Already Registered" },
1707 { 0xfffffd4a, "(-694) Lost Entry" },
1708 { 0xfffffd4b, "(-693) Missing Reference" },
1709 { 0xfffffd4c, "(-692) Incorrect Base Class" },
1710 { 0xfffffd4d, "(-691) Modification Time Not Current" },
1711 { 0xfffffd4e, "(-690) Invalid RDN" },
1712 { 0xfffffd4f, "(-689) Invalid Subordinate Count" },
1713 { 0xfffffd50, "(-688) Cache Overflow" },
1714 { 0xfffffd51, "(-687) Cannot Abort" },
1715 { 0xfffffd52, "(-686) Not a Leaf Partition" },
1716 { 0xfffffd53, "(-685) Move in Progress" },
1717 { 0xfffffd54, "(-684) Secure NCP Violation" },
1718 { 0xfffffd55, "(-683) Invalid API Version" },
1719 { 0xfffffd56, "(-682) Auditing Failed" },
1720 { 0xfffffd57, "(-681) Alias of an Alias" },
1721 { 0xfffffd58, "(-680) Transport Modified" },
1722 { 0xfffffd59, "(-679) Partition Already Exists" },
1723 { 0xfffffd5a, "(-678) Duplicate ACL" },
1724 { 0xfffffd5b, "(-677) Invalid Identity" },
1725 { 0xfffffd5c, "(-676) Invalid Connection Handle" },
1726 { 0xfffffd5d, "(-675) Invalid Task" },
1727 { 0xfffffd5e, "(-674) Invalid Name Service" },
1728 { 0xfffffd5f, "(-673) Replica Not On" },
1729 { 0xfffffd60, "(-672) No Access" },
1730 { 0xfffffd61, "(-671) No Such Parent" },
1731 { 0xfffffd62, "(-670) Invalid Context" },
1732 { 0xfffffd63, "(-669) Failed Authentication" },
1733 { 0xfffffd64, "(-668) Entry Not Container" },
1734 { 0xfffffd65, "(-667) Partition Root" },
1735 { 0xfffffd66, "(-666) Incompatible DS Version" },
1736 { 0xfffffd67, "(-665) New Epoch" },
1737 { 0xfffffd68, "(-664) Old Epoch" },
1738 { 0xfffffd69, "(-663) DS Locked" },
1739 { 0xfffffd6a, "(-662) DS Volume IO Failure" },
1740 { 0xfffffd6b, "(-661) DS Volume Not Mounted" },
1741 { 0xfffffd6c, "(-660) Record in Use" },
1742 { 0xfffffd6d, "(-659) Time Not Synchronized" },
1743 { 0xfffffd6e, "(-658) Skulk in Progress" },
1744 { 0xfffffd6f, "(-657) Schema Sync in Progress" },
1745 { 0xfffffd70, "(-656) Crucial Replica" },
1746 { 0xfffffd71, "(-655) Multiple Replicas" },
1747 { 0xfffffd72, "(-654) Partition Busy" },
1748 { 0xfffffd73, "(-653) Duplicate Optional" },
1749 { 0xfffffd74, "(-652) Duplicate Mandatory" },
1750 { 0xfffffd75, "(-651) Ambiguous Naming" },
1751 { 0xfffffd76, "(-650) Ambiguous Containment" },
1752 { 0xfffffd77, "(-649) Insufficient Buffer" },
1753 { 0xfffffd78, "(-648) Insufficient Stack" },
1754 { 0xfffffd79, "(-647) Not Root Partition" },
1755 { 0xfffffd7a, "(-646) Bad Naming Attributes" },
1756 { 0xfffffd7b, "(-645) Class Already Exists" },
1757 { 0xfffffd7c, "(-644) Schema is in Use" },
1758 { 0xfffffd7d, "(-643) Schema is Non-removable" },
1759 { 0xfffffd7e, "(-642) Invalid Iteration" },
1760 { 0xfffffd7f, "(-641) Invalid Request" },
1761 { 0xfffffd80, "(-640) Invalid Certificate" },
1762 { 0xfffffd81, "(-639) Incomplete Authentication" },
1763 { 0xfffffd82, "(-638) No Character Mapping" },
1764 { 0xfffffd83, "(-637) Previous Move in Progress" },
1765 { 0xfffffd84, "(-636) Unreachable Server" },
1766 { 0xfffffd85, "(-635) Remote Failure" },
1767 { 0xfffffd86, "(-634) No Referrals" },
1768 { 0xfffffd87, "(-633) Invalid Entry for Root" },
1769 { 0xfffffd88, "(-632) System Failure" },
1770 { 0xfffffd89, "(-631) Illegal Replica Type" },
1771 { 0xfffffd8a, "(-630) Different Tree" },
1772 { 0xfffffd8b, "(-629) Entry is Not Leaf" },
1773 { 0xfffffd8c, "(-628) Object Class Violation" },
1774 { 0xfffffd8d, "(-627) Can't Remove Naming Value" },
1775 { 0xfffffd8e, "(-626) All Referrals Failed" },
1776 { 0xfffffd8f, "(-625) Transport Failure" },
1777 { 0xfffffd90, "(-624) Replica Already Exists" },
1778 { 0xfffffd91, "(-623) Syntax Invalid in Name" },
1779 { 0xfffffd92, "(-622) Invalid Transport" },
1780 { 0xfffffd93, "(-621) Transaction Tracking Disabled" },
1781 { 0xfffffd94, "(-620) Comparison Failed" },
1782 { 0xfffffd95, "(-619) Invalid Comparison" },
1783 { 0xfffffd96, "(-618) Inconsistent Database" },
1784 { 0xfffffd97, "(-617) Database Format" },
1785 { 0xfffffd98, "(-616) Maximum Entries Exist" },
1786 { 0xfffffd99, "(-615) Attribute Already Exists" },
1787 { 0xfffffd9a, "(-614) Duplicate Value" },
1788 { 0xfffffd9b, "(-613) Syntax Violation" },
1789 { 0xfffffd9c, "(-612) Can't Have Multiple Values" },
1790 { 0xfffffd9d, "(-611) Illegal Containment" },
1791 { 0xfffffd9e, "(-610) Illegal DS Name" },
1792 { 0xfffffd9f, "(-609) Missing Mandatory" },
1793 { 0xfffffda0, "(-608) Illegal Attribute" },
1794 { 0xfffffda1, "(-607) Not Effective Class" },
1795 { 0xfffffda2, "(-606) Entry Already Exists" },
1796 { 0xfffffda3, "(-605) No Such Partition" },
1797 { 0xfffffda4, "(-604) No Such Class" },
1798 { 0xfffffda5, "(-603) No Such Attribute" },
1799 { 0xfffffda6, "(-602) No Such Value" },
1800 { 0xfffffda7, "(-601) No Such Entry" },
1802 { 0xfffffe97, "(-361) Iterator Invalid Scope" },
1803 { 0xfffffe98, "(-360) Iterator Invalid Search Data" },
1804 { 0xfffffe99, "(-359) Iterator Invalid Position" },
1805 { 0xfffffe9a, "(-358) Iterator Invalid Handle" },
1806 { 0xfffffe9b, "(-357) NDS for NT - Sync Disabled" },
1807 { 0xfffffe9c, "(-356) NDS for NT - No Domain" },
1808 { 0xfffffe9d, "(-355) Not NDS for NT" },
1809 { 0xfffffe9e, "(-354) Rename Not Allowed" },
1810 { 0xfffffe9f, "(-353) DN Too Long" },
1811 { 0xfffffea0, "(-352) No Writable Replicas" },
1812 { 0xfffffea1, "(-351) Attempt to Authenticate" },
1813 { 0xfffffea2, "(-350) Not Context Owner" },
1814 { 0xfffffea3, "(-349) Unicode Already Loaded" },
1815 { 0xfffffea4, "(-348) Unicode File Not Found" },
1816 { 0xfffffea5, "(-347) Schema Name Too Long" },
1817 { 0xfffffea6, "(-346) Unicode Translation" },
1818 { 0xfffffea7, "(-345) Invalid DS Version" },
1819 { 0xfffffea8, "(-344) Invalid TDS" },
1820 { 0xfffffea9, "(-343) Attribute Name Too Long" },
1821 { 0xfffffeaa, "(-342) Invalid DS Name" },
1822 { 0xfffffeab, "(-341) No Such Syntax" },
1823 { 0xfffffeac, "(-340) Transport Failed" },
1824 { 0xfffffead, "(-339) Failed Server Authentication" },
1825 { 0xfffffeae, "(-338) Invalid Password Characters" },
1826 { 0xfffffeaf, "(-337) Not Logged In" },
1827 { 0xfffffeb0, "(-336) Data Store Failure" },
1828 { 0xfffffeb1, "(-335) Duplicate Type" },
1829 { 0xfffffeb2, "(-334) RDN Too Long" },
1830 { 0xfffffeb3, "(-333) No Connection" },
1831 { 0xfffffeb4, "(-332) No Server Found" },
1832 { 0xfffffeb5, "(-331) Null Pointer" },
1833 { 0xfffffeb6, "(-330) Invalid Server Response" },
1834 { 0xfffffeb7, "(-329) Invalid Union Tag" },
1835 { 0xfffffeb8, "(-328) Unicode Error during Context Creation" },
1836 { 0xfffffeba, "(-326) Invalid Filter Syntax" },
1837 { 0xfffffebb, "(-325) Invalid Attribute Syntax" },
1838 { 0xfffffebc, "(-324) Invalid Replica Type" },
1839 { 0xfffffebd, "(-323) Buffer Zero Length" },
1840 { 0xfffffebe, "(-322) Invalid Iteration Handle" },
1841 { 0xfffffebf, "(-321) Unable to Attach" },
1842 { 0xfffffec0, "(-320) Can't Add Root" },
1843 { 0xfffffec1, "(-319) Internal Error" },
1844 { 0xfffffec2, "(-318) Country Name Too Long" },
1845 { 0xfffffec3, "(-317) Inconsistent MultiAVA" },
1846 { 0xfffffec4, "(-316) Too Many Tokens" },
1847 { 0xfffffec5, "(-315) Expected RDN Delimiter" },
1848 { 0xfffffec6, "(-314) Invalid Object Name" },
1849 { 0xfffffec7, "(-313) Filter Tree Empty" },
1850 { 0xfffffec8, "(-312) Attribute Type Not Expected" },
1851 { 0xfffffec9, "(-311) Attribute Type Expected" },
1852 { 0xfffffeca, "(-310) Expected Equals" },
1853 { 0xfffffecb, "(-309) Expected Identifier" },
1854 { 0xfffffecc, "(-308) Bad Verb" },
1855 { 0xfffffecd, "(-307) Buffer Empty" },
1856 { 0xfffffece, "(-306) Bad Syntax" },
1857 { 0xfffffecf, "(-305) List Empty" },
1858 { 0xfffffed0, "(-304) Buffer Full" },
1859 { 0xfffffed1, "(-303) Bad Context" },
1860 { 0xfffffed2, "(-302) Bad Key" },
1861 { 0xfffffed3, "(-301) Not Enough Memory" },
1863 { 0xffffff01, "(-255) Hard Failure" },
1864 { 0xffffff02, "(-254) Bindery Locked/Directory Locked/Spool Delete/Trustee not Found/Timeout" },
1865 { 0xffffff03, "(-253) Bad Station Number" },
1866 { 0xffffff04, "(-252) Message Queue Full/Target Already Has Message/No Such Object" },
1867 { 0xffffff05, "(-251) Unknown Request/No Such Property" },
1868 { 0xffffff06, "(-250) Temp Remap" },
1869 { 0xffffff07, "(-249) No Property Read Rights" },
1870 { 0xffffff08, "(-248) No Property Write Rights" },
1871 { 0xffffff09, "(-247) No Property Create Rights" },
1872 { 0xffffff0a, "(-246) No Property Delete Rights" },
1873 { 0xffffff0b, "(-245) No Object Create Rights" },
1874 { 0xffffff0c, "(-244) No Object Delete Rights" },
1875 { 0xffffff0d, "(-243) No Object Rename Rights" },
1876 { 0xffffff0e, "(-242) No Object Read Rights" },
1877 { 0xffffff0f, "(-241) Bindery Security" },
1878 { 0xffffff10, "(-240) Illegal Wildcard" },
1879 { 0xffffff11, "(-239) Illegal Name" },
1880 { 0xffffff12, "(-238) Object Already Exists" },
1881 { 0xffffff13, "(-237) Property Already Exists" },
1882 { 0xffffff14, "(-236) No Such Value Set" },
1883 { 0xffffff15, "(-235) Property Not Group" },
1884 { 0xffffff16, "(-234) No Such Member" },
1885 { 0xffffff17, "(-233) Member Already Exists" },
1886 { 0xffffff18, "(-232) Write to Group Property" },
1887 { 0xffffff20, "(-224) No Login Connection Available" },
1888 { 0xffffff21, "(-223) Password Expired" },
1889 { 0xffffff22, "(-222) Bad Password" },
1890 { 0xffffff24, "(-220) Login Account Expired" },
1891 { 0xffffff25, "(-219) Queue Maximum Servers/Node Address Violation" },
1892 { 0xffffff26, "(-218) Queue Halted/Bad Login Time" },
1893 { 0xffffff27, "(-217) Queue Station Not Server/Maximum Logins Exceeded" },
1894 { 0xffffff28, "(-216) Queue Not Active/Password Too Short" },
1895 { 0xffffff29, "(-215) Queue In Service/Duplicate Password" },
1896 { 0xffffff2a, "(-214) No Queue Job Rights/Unencrypted Not Allowed" },
1897 { 0xffffff2b, "(-213) No Queue Job" },
1898 { 0xffffff2c, "(-212) Queue Full" },
1899 { 0xffffff2d, "(-211) No Queue Rights" },
1900 { 0xffffff2e, "(-210) No Queue Server" },
1901 { 0xffffff2f, "(-209) No Queue" },
1902 { 0xffffff30, "(-208) Queue IO Failure" },
1903 { 0xffffff3a, "(-198) No Console Rights" },
1904 { 0xffffff3b, "(-197) Intruder Login Lockout" },
1905 { 0xffffff3c, "(-196) Accounting Disabled" },
1906 { 0xffffff3d, "(-195) Too Many Holds" },
1907 { 0xffffff3e, "(-194) Credit Limit Exceeded" },
1908 { 0xffffff3f, "(-193) No Account Balance" },
1909 { 0xffffff40, "(-192) No Accounting Privileges" },
1910 { 0xffffff41, "(-191) Invalid Name Space" },
1911 { 0xffffff42, "(-190) Invalid Data Stream" },
1912 { 0xffffff43, "(-189) Login Encryption Required" },
1913 { 0xffffff44, "(-188) Login Signing Required" },
1914 { 0xffffff58, "(-168) Access Denied" },
1915 { 0xffffff59, "(-167) Invalid Resource Tag" },
1916 { 0xffffff5a, "(-166) Already in Use" },
1917 { 0xffffff5b, "(-165) Invalid Open/Create Mode" },
1918 { 0xffffff5c, "(-164) Rename Directory Invalid" },
1919 { 0xffffff5d, "(-163) Transaction Restarted" },
1920 { 0xffffff5e, "(-162) IO Locked" },
1921 { 0xffffff5f, "(-161) Directory IO Error" },
1922 { 0xffffff60, "(-160) Directory Not Empty" },
1923 { 0xffffff61, "(-159) Directory Active" },
1924 { 0xffffff62, "(-158) Bad File Name" },
1925 { 0xffffff63, "(-157) No Directory Handles" },
1926 { 0xffffff64, "(-156) Invalid Path/No Such Extension" },
1927 { 0xffffff65, "(-155) Bad Directory Handle" },
1928 { 0xffffff66, "(-154) Rename Across Volume" },
1929 { 0xffffff67, "(-153) Directory Full" },
1930 { 0xffffff68, "(-152) Invalid Volume" },
1931 { 0xffffff69, "(-151) No Spool Space" },
1932 { 0xffffff6a, "(-150) No Alloc Space/Target Not a Subdirectory/Insufficient Memory" },
1933 { 0xffffff6b, "(-149) File Detached" },
1934 { 0xffffff6c, "(-148) No Write Privilege" },
1935 { 0xffffff6d, "(-147) No Read Privilege" },
1936 { 0xffffff6e, "(-146) All Names Exist" },
1937 { 0xffffff6f, "(-145) Some names Exist" },
1938 { 0xffffff70, "(-144) All Read Only" },
1939 { 0xffffff71, "(-143) Some Read Only" },
1940 { 0xffffff72, "(-142) All File in Use" },
1941 { 0xffffff73, "(-141) Some File in Use" },
1942 { 0xffffff74, "(-140) No Set Privilege" },
1943 { 0xffffff75, "(-139) No Rename Privilege" },
1944 { 0xffffff76, "(-138) No Delete Privilege" },
1945 { 0xffffff77, "(-137) No Search Privilege" },
1946 { 0xffffff78, "(-136) Invalid File Handle" },
1947 { 0xffffff79, "(-135) Create File with Invalid Name" },
1948 { 0xffffff7a, "(-134) Create Duplicate When Read Only" },
1949 { 0xffffff7b, "(-133) No Create Delete Privilege" },
1950 { 0xffffff7c, "(-132) No Create Privilege" },
1951 { 0xffffff7d, "(-131) Hard IO Error" },
1952 { 0xffffff7e, "(-130) No Open Privilege" },
1953 { 0xffffff7f, "(-129) Out of Handles" },
1954 { 0xffffff80, "(-128) Lock Fail" },
1955 { 0xffffff81, "(-127) Lock Waiting" },
1956 { 0xffffff82, "(-126) NCP Boundary Check Failed" },
1957 { 0xffffff83, "(-125) Connection Not Logged In" },
1958 { 0xffffff84, "(-124) Connection Not Authenticated" },
1959 { 0xffffff85, "(-123) Connection Already Logged In" },
1960 { 0xffffff86, "(-122) Connection Already Temporary" },
1961 { 0xffffff87, "(-121) No Items Found" },
1962 { 0xffffff88, "(-120) RR Volume Flag Not Set" },
1963 { 0xffffff89, "(-119) Buffer too Small" },
1965 { 0xffffffff, "(-1) Insufficient Space" },
1968 static value_string_ext ndps_error_types_ext
= VALUE_STRING_EXT_INIT(ndps_error_types
);
1970 static const value_string ndps_credential_enum
[] = {
1979 static const value_string ndps_object_op_enum
[] = {
1983 { 3, "Delete Object" },
1987 static const value_string ndps_client_server_enum
[] = {
1990 { 2, "Client and Server" },
1994 static const value_string ndps_session_type_enum
[] = {
2003 static const value_string ndps_get_session_type_enum
[] = {
2011 static const value_string ndps_get_resman_session_type_enum
[] = {
2019 align_4(tvbuff_t
*tvb
, int aoffset
)
2021 if(tvb_captured_length_remaining(tvb
, aoffset
) > 4 )
2029 * XXX - is there something in the packet to indicate whether a string
2030 * is ASCII or Unicode, or is it a characteristic of the attribute?
2031 * Currently, we use a heuristic - if the length is odd, we assume
2032 * it's ASCII (as it's a length in bytes, not characters), otherwise if
2033 * if the length is 2, we assume it's ASCII (as strings are null-
2034 * terminated, so a Unicode string would have to be at least 4 bytes),
2035 * otherwise if the second byte of the string is 0, we assume it's
2036 * Unicode (as an ASCII string would, in that case, have at least two
2037 * characters before the terminating NUL).
2040 ndps_string(tvbuff_t
* tvb
, int hfinfo
, proto_tree
*ndps_tree
, int offset
, char **stringval
)
2042 int foffset
= offset
;
2043 uint32_t str_length
;
2046 str_length
= tvb_get_ntohl(tvb
, foffset
);
2050 proto_tree_add_string(ndps_tree
, hfinfo
, tvb
, offset
, 4, "<Not Specified>");
2051 if (stringval
!= NULL
)
2052 *stringval
= wmem_strdup(wmem_packet_scope(), "");
2055 if (str_length
<= 2 || (str_length
& 0x01) || tvb_get_uint8(tvb
, foffset
+ 1) != 0) {
2059 string
= tvb_get_string_enc(wmem_packet_scope(), tvb
, foffset
, str_length
, ENC_ASCII
|ENC_NA
); /* XXX - extended ASCII? */;
2064 string
= tvb_get_string_enc(wmem_packet_scope(), tvb
, foffset
, str_length
, ENC_UTF_16
|ENC_LITTLE_ENDIAN
);
2066 foffset
+= str_length
;
2067 proto_tree_add_string(ndps_tree
, hfinfo
, tvb
, offset
, str_length
+ 4, string
);
2068 foffset
+= align_4(tvb
, foffset
);
2069 if (stringval
!= NULL
)
2070 *stringval
= string
;
2075 objectidentifier(tvbuff_t
* tvb
, proto_tree
*ndps_tree
, int foffset
)
2078 const char *label
=NULL
;
2079 uint32_t label_value
=0;
2084 length
= tvb_get_ntohl(tvb
, foffset
);
2091 proto_tree_add_uint(ndps_tree
, hf_oid_struct_size
, tvb
, foffset
, 4, length
);
2097 label_value
= tvb_get_ntohl(tvb
, foffset
+5);
2098 label
= try_val_to_str(label_value
, object_ids_7
);
2101 label
= wmem_strdup(wmem_packet_scope(), "Unknown ID");
2104 aitem
= proto_tree_add_uint_format(ndps_tree
, hf_ndps_object_ids_7
, tvb
, foffset
, length
, label_value
, "%s", label
);
2107 label_value
= tvb_get_ntohl(tvb
, foffset
+6);
2108 label
= try_val_to_str(label_value
, object_ids_8
);
2111 label
= wmem_strdup(wmem_packet_scope(), "Unknown ID");
2114 aitem
= proto_tree_add_uint_format(ndps_tree
, hf_ndps_object_ids_8
, tvb
, foffset
, length
, label_value
, "%s", label
);
2117 label_value
= tvb_get_ntohl(tvb
, foffset
+7);
2118 label
= try_val_to_str(label_value
, object_ids_9
);
2121 label
= wmem_strdup(wmem_packet_scope(), "Unknown ID");
2124 aitem
= proto_tree_add_uint_format(ndps_tree
, hf_ndps_object_ids_9
, tvb
, foffset
, length
, label_value
, "%s", label
);
2127 label_value
= tvb_get_ntohl(tvb
, foffset
+8);
2128 label
= try_val_to_str(label_value
, object_ids_10
);
2131 label
= wmem_strdup(wmem_packet_scope(), "Unknown ID");
2134 aitem
= proto_tree_add_uint_format(ndps_tree
, hf_ndps_object_ids_10
, tvb
, foffset
, length
, label_value
, "%s", label
);
2137 label_value
= tvb_get_ntohl(tvb
, foffset
+9);
2138 label
= try_val_to_str(label_value
, object_ids_11
);
2141 label
= wmem_strdup(wmem_packet_scope(), "Unknown ID");
2144 aitem
= proto_tree_add_uint_format(ndps_tree
, hf_ndps_object_ids_11
, tvb
, foffset
, length
, label_value
, "%s", label
);
2147 label_value
= tvb_get_ntohl(tvb
, foffset
+10);
2148 label
= try_val_to_str(label_value
, object_ids_12
);
2151 label
= wmem_strdup(wmem_packet_scope(), "Unknown ID");
2154 aitem
= proto_tree_add_uint_format(ndps_tree
, hf_ndps_object_ids_12
, tvb
, foffset
, length
, label_value
, "%s", label
);
2157 label_value
= tvb_get_ntohl(tvb
, foffset
+11);
2158 label
= try_val_to_str(label_value
, object_ids_13
);
2161 label
= wmem_strdup(wmem_packet_scope(), "Unknown ID");
2164 aitem
= proto_tree_add_uint_format(ndps_tree
, hf_ndps_object_ids_13
, tvb
, foffset
, length
, label_value
, "%s", label
);
2167 label_value
= tvb_get_ntohl(tvb
, foffset
+12);
2168 label
= try_val_to_str(label_value
, object_ids_14
);
2171 label
= wmem_strdup(wmem_packet_scope(), "Unknown ID");
2174 aitem
= proto_tree_add_uint_format(ndps_tree
, hf_ndps_object_ids_14
, tvb
, foffset
, length
, label_value
, "%s", label
);
2177 label_value
= tvb_get_ntohl(tvb
, foffset
+13);
2178 label
= try_val_to_str(label_value
, object_ids_15
);
2181 label
= wmem_strdup(wmem_packet_scope(), "Unknown ID");
2184 aitem
= proto_tree_add_uint_format(ndps_tree
, hf_ndps_object_ids_15
, tvb
, foffset
, length
, label_value
, "%s", label
);
2187 label_value
= tvb_get_ntohl(tvb
, foffset
+14);
2188 label
= try_val_to_str(label_value
, object_ids_16
);
2191 label
= wmem_strdup(wmem_packet_scope(), "Unknown ID");
2194 aitem
= proto_tree_add_uint_format(ndps_tree
, hf_ndps_object_ids_16
, tvb
, foffset
, length
, label_value
, "%s", label
);
2197 aitem
= proto_tree_add_uint_format(ndps_tree
, hf_ndps_object_ids_7
, tvb
, foffset
, length
, 1, "Unknown ID");
2204 label
= try_val_to_str(label_value
, object_ids_7
);
2208 atree
= proto_item_add_subtree(aitem
, ett_ndps
);
2209 proto_tree_add_item(atree
, hf_oid_asn1_type
, tvb
, foffset
, 1, ENC_BIG_ENDIAN
);
2211 length
= tvb_get_uint8(tvb
, foffset
);
2213 proto_tree_add_item(atree
, hf_ndps_oid
, tvb
, foffset
, length
, ENC_NA
);
2220 tvb_ensure_bytes_exist(tvb
, foffset
, length
);
2226 length
= tvb_get_uint8(tvb
, foffset
);
2228 tvb_ensure_bytes_exist(tvb
, foffset
, length
);
2232 global_attribute_name
= label
;
2233 return foffset
+(length
%2);
2237 name_or_id(tvbuff_t
* tvb
, proto_tree
*ndps_tree
, int foffset
)
2239 uint32_t name_or_id_val
;
2241 name_or_id_val
= tvb_get_ntohl(tvb
, foffset
);
2242 proto_tree_add_uint(ndps_tree
, hf_ndps_nameorid
, tvb
, foffset
, 4, name_or_id_val
);
2244 switch (name_or_id_val
)
2246 case 1: /* Global */
2247 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
2251 foffset
= ndps_string(tvb
, hf_ndps_local_object_name
, ndps_tree
, foffset
, NULL
);
2254 foffset
+= align_4(tvb
, foffset
);
2259 qualifiedname(tvbuff_t
* tvb
, proto_tree
*ndps_tree
, int foffset
)
2261 uint32_t qualified_name_type
=0;
2263 qualified_name_type
= tvb_get_ntohl(tvb
, foffset
);
2264 proto_tree_add_uint(ndps_tree
, hf_ndps_qualified_name
, tvb
, foffset
, 4, qualified_name_type
);
2266 if (qualified_name_type
!= 0) {
2267 if (qualified_name_type
== 1) {
2268 foffset
= ndps_string(tvb
, hf_ndps_printer_name
, ndps_tree
, foffset
, NULL
);
2272 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
2273 foffset
= ndps_string(tvb
, hf_ndps_tree
, ndps_tree
, foffset
, NULL
);
2280 objectidentification(tvbuff_t
* tvb
, proto_tree
*ndps_tree
, int foffset
)
2282 uint32_t object_type
=0;
2286 object_type
= tvb_get_ntohl(tvb
, foffset
);
2287 aitem
= proto_tree_add_item(ndps_tree
, hf_obj_id_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2288 atree
= proto_item_add_subtree(aitem
, ett_ndps
);
2292 case 0: /* Printer Contained Object ID */
2293 foffset
= ndps_string(tvb
, hf_ndps_printer_name
, atree
, foffset
, NULL
);
2294 proto_tree_add_item(atree
, hf_ndps_object
, tvb
, foffset
,
2298 case 1: /* Document Identifier */
2299 foffset
= ndps_string(tvb
, hf_ndps_printer_name
, atree
, foffset
, NULL
);
2300 proto_tree_add_item(atree
, hf_ndps_document_number
, tvb
, foffset
,
2304 case 2: /* Object Identifier */
2305 foffset
= objectidentifier(tvb
, atree
, foffset
);
2307 case 3: /* Object Name */
2308 foffset
= ndps_string(tvb
, hf_object_name
, atree
, foffset
, NULL
);
2309 if (foffset
> tvb_captured_length_remaining(tvb
, foffset
)) {
2312 foffset
= name_or_id(tvb
, atree
, foffset
);
2314 case 4: /* Name or Object ID */
2315 foffset
= name_or_id(tvb
, atree
, foffset
);
2317 case 5: /* Simple Name */
2318 foffset
= ndps_string(tvb
, hf_object_name
, atree
, foffset
, NULL
);
2320 case 6: /* Printer Configuration Object ID */
2321 foffset
= ndps_string(tvb
, hf_ndps_printer_name
, atree
, foffset
, NULL
);
2323 case 7: /* Qualified Name */
2324 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
2326 case 8: /* Event Object ID */
2327 foffset
= ndps_string(tvb
, hf_object_name
, atree
, foffset
, NULL
);
2328 foffset
= objectidentifier(tvb
, atree
, foffset
);
2329 proto_tree_add_item(atree
, hf_ndps_event_type
, tvb
, foffset
,
2339 print_address(tvbuff_t
* tvb
, proto_tree
*ndps_tree
, int foffset
)
2341 uint32_t addr_type
=0;
2342 uint32_t addr_len
=0;
2344 addr_type
= tvb_get_ntohl(tvb
, foffset
);
2345 proto_tree_add_uint(ndps_tree
, hf_ndps_address
, tvb
, foffset
, 4, addr_type
);
2347 addr_len
= tvb_get_ntohl(tvb
, foffset
);
2348 proto_tree_add_item(ndps_tree
, hf_address_len
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2351 * XXX - are these address types the same as the NDS_PTYPE_ #defines
2352 * in packet-ncp2222.inc?
2354 * XXX - should this code - and the code in packet-ncp2222.inc to
2355 * dissect addresses - check the length for the types it supports?
2360 proto_tree_add_item(ndps_tree
, hf_ndps_net
, tvb
, foffset
, 4, ENC_NA
);
2361 proto_tree_add_item(ndps_tree
, hf_ndps_node
, tvb
, foffset
+4, 6, ENC_NA
);
2362 proto_tree_add_item(ndps_tree
, hf_ndps_socket
, tvb
, foffset
+10, 2, ENC_BIG_ENDIAN
);
2365 proto_tree_add_item(ndps_tree
, hf_ndps_port
, tvb
, foffset
, 2, ENC_BIG_ENDIAN
);
2366 proto_tree_add_item(ndps_tree
, hf_ndps_ip
, tvb
, foffset
+2, 4, ENC_BIG_ENDIAN
);
2371 tvb_ensure_bytes_exist(tvb
, foffset
, addr_len
);
2372 foffset
+= addr_len
;
2373 return foffset
+(addr_len
%4);
2377 address_item(tvbuff_t
* tvb
, proto_tree
*ndps_tree
, int foffset
)
2379 uint32_t addr_type
=0;
2381 addr_type
= tvb_get_ntohl(tvb
, foffset
);
2382 proto_tree_add_uint(ndps_tree
, hf_address_type
, tvb
, foffset
, 4, addr_type
);
2394 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
2401 foffset
= ndps_string(tvb
, hf_object_name
, ndps_tree
, foffset
, NULL
);
2404 proto_tree_add_item(ndps_tree
, hf_ndps_attrib_boolean
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2408 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2412 foffset
= print_address(tvb
, ndps_tree
, foffset
);
2417 foffset
= ndps_string(tvb
, hf_object_name
, ndps_tree
, foffset
, NULL
);
2424 credentials(tvbuff_t
* tvb
, packet_info
*pinfo
, proto_tree
*ndps_tree
, int foffset
)
2426 uint32_t cred_type
=0;
2428 uint32_t number_of_items
;
2431 proto_item
*aitem
, *expert_item
;
2433 cred_type
= tvb_get_ntohl(tvb
, foffset
);
2434 proto_tree_add_item(ndps_tree
, hf_ndps_cred_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2439 foffset
= ndps_string(tvb
, hf_ndps_user_name
, ndps_tree
, foffset
, NULL
);
2440 number_of_items
=tvb_get_ntohl(tvb
, foffset
);
2441 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_passwords
, tvb
, foffset
, 4, number_of_items
);
2443 for (ii
= 0; ii
< number_of_items
; ii
++ )
2445 if (ii
>= NDPS_MAX_ITEMS
) {
2446 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
2449 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Password %d", ii
+1);
2450 length
= tvb_get_ntohl(tvb
, foffset
);
2454 proto_tree_add_item(atree
, hf_ndps_password
, tvb
, foffset
, length
, ENC_NA
);
2456 proto_item_set_end(aitem
, tvb
, foffset
);
2461 length
= tvb_get_ntohl(tvb
, foffset
);
2465 proto_tree_add_item(ndps_tree
, hf_ndps_certified
, tvb
, foffset
, length
, ENC_NA
);
2470 foffset
= ndps_string(tvb
, hf_ndps_server_name
, ndps_tree
, foffset
, NULL
);
2472 proto_tree_add_item(ndps_tree
, hf_ndps_connection
, tvb
, foffset
, 2, ENC_BIG_ENDIAN
);
2476 length
=tvb_get_ntohl(tvb
, foffset
);
2477 foffset
= ndps_string(tvb
, hf_ndps_server_name
, ndps_tree
, foffset
, NULL
);
2482 if (tvb_get_ntohs(tvb
, foffset
)==0) /* NDPS 1.0 */
2485 if (tvb_get_ntohs(tvb
, foffset
)==0) /* NDPS 1.1 */
2490 proto_tree_add_item(ndps_tree
, hf_ndps_connection
, tvb
, foffset
, 2, ENC_BIG_ENDIAN
);
2492 foffset
= ndps_string(tvb
, hf_ndps_user_name
, ndps_tree
, foffset
, NULL
);
2495 foffset
= ndps_string(tvb
, hf_ndps_server_name
, ndps_tree
, foffset
, NULL
);
2497 proto_tree_add_item(ndps_tree
, hf_ndps_connection
, tvb
, foffset
, 2, ENC_BIG_ENDIAN
);
2499 foffset
= ndps_string(tvb
, hf_ndps_user_name
, ndps_tree
, foffset
, NULL
);
2500 foffset
+= 8; /* Don't know what these 8 bytes signify */
2501 proto_tree_add_item(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2502 foffset
+= 4; /* XXX - what does this count? */
2503 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
2504 foffset
= ndps_string(tvb
, hf_ndps_tree
, ndps_tree
, foffset
, NULL
);
2514 event_object_set(tvbuff_t
* tvb
, packet_info
*pinfo
, proto_tree
*ndps_tree
, int foffset
)
2516 uint32_t number_of_items
;
2517 uint32_t number_of_items2
;
2520 uint32_t object_identifier
;
2521 proto_tree
*atree
, *btree
, *ctree
;
2522 proto_item
*aitem
, *bitem
, *citem
, *expert_item
;
2524 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Event");
2525 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
2526 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_events
, tvb
, foffset
, 4, number_of_items
);
2528 for (ii
= 0; ii
< number_of_items
; ii
++ )
2530 if (ii
>= NDPS_MAX_ITEMS
) {
2531 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
2534 btree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Event %u", ii
+1);
2535 proto_tree_add_item(btree
, hf_ndps_event_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2537 foffset
= objectidentifier(tvb
, btree
, foffset
);
2538 foffset
+= align_4(tvb
, foffset
);
2539 foffset
= objectidentification(tvb
, btree
, foffset
);
2540 foffset
+= align_4(tvb
, foffset
);
2541 proto_tree_add_item(btree
, hf_ndps_object_op
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2543 object_identifier
= tvb_get_ntohl(tvb
, foffset
);
2544 proto_tree_add_uint(btree
, hf_ndps_event_object_identifier
, tvb
, foffset
, 4, object_identifier
);
2546 switch (object_identifier
)
2549 foffset
= objectidentifier(tvb
, btree
, foffset
);
2550 foffset
+= align_4(tvb
, foffset
);
2554 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
2555 expert_item
= proto_tree_add_uint(btree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items2
);
2557 for (jj
= 0; jj
< number_of_items2
; jj
++ )
2559 if (jj
>= NDPS_MAX_ITEMS
) {
2560 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
2563 ctree
= proto_tree_add_subtree_format(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Item %u", jj
+1);
2564 foffset
= objectidentifier(tvb
, ctree
, foffset
);
2565 foffset
+= align_4(tvb
, foffset
);
2566 proto_item_set_end(citem
, tvb
, foffset
);
2570 proto_item_set_end(bitem
, tvb
, foffset
);
2572 proto_item_set_end(aitem
, tvb
, foffset
);
2578 cardinal_seq(tvbuff_t
* tvb
, packet_info
* pinfo
, proto_tree
*ndps_tree
, int foffset
)
2580 uint32_t number_of_items
;
2584 proto_item
*aitem
, *expert_item
;
2586 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
2587 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
2589 for (ii
= 0; ii
< number_of_items
; ii
++ )
2591 if (ii
>= NDPS_MAX_ITEMS
) {
2592 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
2595 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Cardinal %u", ii
+1);
2596 length
= tvb_get_ntohl(tvb
, foffset
);
2600 proto_tree_add_item(atree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
2602 tvb_ensure_bytes_exist(tvb
, foffset
, length
+length
%2);
2604 foffset
+= (length
%2);
2605 proto_item_set_end(aitem
, tvb
, foffset
);
2612 server_entry(tvbuff_t
* tvb
, packet_info
* pinfo
, proto_tree
*ndps_tree
, int foffset
)
2615 uint32_t number_of_items
;
2618 proto_tree
*atree
, *btree
;
2619 proto_item
*aitem
, *bitem
, *expert_item
;
2621 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Server Info");
2622 foffset
= ndps_string(tvb
, hf_ndps_server_name
, ndps_tree
, foffset
, &server_name
);
2623 proto_item_append_text(aitem
, ": %s", format_text(pinfo
->pool
, server_name
, strlen(server_name
)));
2624 proto_tree_add_item(atree
, hf_ndps_server_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2626 foffset
= print_address(tvb
, atree
, foffset
);
2627 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
2628 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_servers
, tvb
, foffset
, 4, number_of_items
);
2630 for (ii
= 0; ii
< number_of_items
; ii
++ )
2632 if (ii
>= NDPS_MAX_ITEMS
) {
2633 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
2636 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Info %u", ii
+1);
2637 data_type
= tvb_get_ntohl(tvb
, foffset
);
2638 proto_tree_add_item(btree
, hf_ndps_data_item_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2643 proto_tree_add_item(btree
, hf_info_int
, tvb
, foffset
, 1, ENC_BIG_ENDIAN
);
2647 proto_tree_add_item(btree
, hf_info_int16
, tvb
, foffset
, 2, ENC_BIG_ENDIAN
);
2651 proto_tree_add_item(btree
, hf_info_int32
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2654 case 3: /* Boolean */
2655 proto_tree_add_item(btree
, hf_info_boolean
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2658 case 4: /* String */
2660 foffset
= ndps_string(tvb
, hf_info_string
, btree
, foffset
, NULL
);
2665 proto_item_set_end(bitem
, tvb
, foffset
);
2667 proto_item_set_end(aitem
, tvb
, foffset
);
2673 attribute_value(tvbuff_t
* tvb
, packet_info
* pinfo
, proto_tree
*ndps_tree
, int foffset
)
2677 uint32_t number_of_items
;
2678 uint32_t number_of_items2
;
2679 uint32_t attribute_type
;
2680 uint32_t integer_or_oid
;
2681 uint32_t event_object_type
;
2682 uint32_t ignored_type
;
2683 uint32_t resource_type
;
2684 uint32_t identifier_type
;
2685 uint32_t criterion_type
;
2686 uint32_t card_enum_time
;
2687 uint32_t media_type
;
2688 uint32_t doc_content
;
2690 uint32_t medium_size
;
2691 uint32_t numbers_up
;
2692 uint32_t colorant_set
;
2698 uint32_t label_value
;
2699 proto_tree
*atree
, *btree
;
2700 proto_item
*aitem
, *bitem
, *expert_item
;
2702 if (global_attribute_name
==NULL
)
2705 label
= try_val_to_str(label_value
, object_ids_7
);
2706 global_attribute_name
= label
;
2708 attribute_type
= tvb_get_ntohl(tvb
, foffset
);
2711 proto_tree_add_item(ndps_tree
, hf_ndps_obj_attribute_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2714 switch(attribute_type
)
2717 proto_tree_add_item(ndps_tree
, hf_ndps_data
, tvb
, foffset
+4, tvb_get_ntohl(tvb
, foffset
), ENC_NA
);
2720 case 2: /* Descriptive Name */
2721 case 3: /* Descriptor */
2722 case 6: /* Simple Name */
2723 case 40: /* Distinguished Name*/
2724 case 50: /* Font Reference */
2725 case 58: /* Locale */
2726 case 102: /* File Path */
2727 case 103: /* Uniform Resource Identifier */
2728 case 108: /* Extended Resource Identifier */
2729 foffset
= ndps_string(tvb
, hf_object_name
, ndps_tree
, foffset
, NULL
);
2731 case 4: /* Message */
2732 case 5: /* Error Message */
2733 case 38: /* Name or OID */
2734 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
2736 case 39: /* Name or OID Seq */
2737 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
2738 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
2740 for (ii
= 0; ii
< number_of_items
; ii
++ )
2742 if (ii
>= NDPS_MAX_ITEMS
) {
2743 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
2746 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Item %d", ii
+1);
2747 foffset
= name_or_id(tvb
, atree
, foffset
);
2748 proto_item_set_end(aitem
, tvb
, foffset
);
2751 case 7: /* Distinguished Name String*/
2752 case 79: /* File Reference */
2753 foffset
= ndps_string(tvb
, hf_object_name
, ndps_tree
, foffset
, NULL
);
2754 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
2756 case 8: /* Distinguished Name String Seq */
2757 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
2758 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
2760 for (ii
= 0; ii
< number_of_items
; ii
++ )
2762 if (ii
>= NDPS_MAX_ITEMS
) {
2763 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
2766 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Name %u", ii
+1);
2767 foffset
= ndps_string(tvb
, hf_object_name
, atree
, foffset
, NULL
);
2768 foffset
= name_or_id(tvb
, atree
, foffset
);
2769 proto_item_set_end(aitem
, tvb
, foffset
);
2772 case 9: /* Delta Time */
2774 case 11: /* Integer */
2775 case 13: /* Cardinal */
2776 case 15: /* Positive Integer */
2777 case 18: /* Maximum Integer */
2778 case 19: /* Minimum Integer */
2779 case 35: /* Percent */
2780 case 57: /* Job Priority */
2781 case 72: /* Sides */
2782 case 95: /* Enumeration */
2783 if (global_attribute_name
!= NULL
&&
2784 strcmp(global_attribute_name
,"(Novell) Attribute PRINTER SECURITY LEVEL")==0)
2786 proto_tree_add_item(ndps_tree
, hf_print_security
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2791 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2795 case 12: /* Integer Seq */
2796 case 14: /* Cardinal Seq */
2797 length
= tvb_get_ntohl(tvb
, foffset
);
2801 proto_tree_add_item(ndps_tree
, hf_info_int32
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
2803 tvb_ensure_bytes_exist(tvb
, foffset
, length
);
2806 case 16: /* Integer Range */
2807 case 17: /* Cardinal Range */
2808 proto_tree_add_item(ndps_tree
, hf_ndps_lower_range
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2810 proto_tree_add_item(ndps_tree
, hf_ndps_upper_range
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2813 case 20: /* Integer 64 */
2814 case 22: /* Cardinal 64 */
2815 case 24: /* Positive Integer 64 */
2816 case 31: /* Non-Negative Real */
2818 proto_tree_add_item(ndps_tree
, hf_ndps_n64
, tvb
, foffset
, 8, ENC_NA
);
2821 case 21: /* Integer 64 Seq */
2822 case 23: /* Cardinal 64 Seq */
2823 case 30: /* Real Seq */
2824 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
2825 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
2827 for (ii
= 0; ii
< number_of_items
; ii
++ )
2829 if (ii
>= NDPS_MAX_ITEMS
) {
2830 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
2833 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Item %u", ii
+1);
2834 proto_tree_add_item(atree
, hf_ndps_n64
, tvb
, foffset
, 8, ENC_NA
);
2836 proto_item_set_end(aitem
, tvb
, foffset
);
2839 case 25: /* Integer 64 Range */
2840 case 26: /* Cardinal 64 Range */
2841 case 32: /* Real Range */
2842 case 33: /* Non-Negative Real Range */
2843 proto_tree_add_item(ndps_tree
, hf_ndps_lower_range_n64
, tvb
, foffset
, 8, ENC_NA
);
2845 proto_tree_add_item(ndps_tree
, hf_ndps_upper_range_n64
, tvb
, foffset
, 8, ENC_NA
);
2848 case 27: /* Maximum Integer 64 */
2849 proto_tree_add_item(ndps_tree
, hf_ndps_lower_range_n64
, tvb
, foffset
, 8, ENC_NA
);
2852 case 28: /* Minimum Integer 64 */
2853 proto_tree_add_item(ndps_tree
, hf_ndps_upper_range_n64
, tvb
, foffset
, 8, ENC_NA
);
2856 case 34: /* Boolean */
2857 proto_tree_add_item(ndps_tree
, hf_ndps_attrib_boolean
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2860 case 36: /* Object Identifier */
2861 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
2863 case 37: /* Object Identifier Seq */
2864 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
2865 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_objects
, tvb
, foffset
, 4, number_of_items
);
2867 for (ii
= 0; ii
< number_of_items
; ii
++ )
2869 if (ii
>= NDPS_MAX_ITEMS
) {
2870 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
2873 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object %d", ii
+1);
2874 foffset
= objectidentifier(tvb
, atree
, foffset
);
2875 proto_item_set_end(aitem
, tvb
, foffset
);
2878 case 41: /* Relative Distinguished Name Seq */
2879 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
2880 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_names
, tvb
, foffset
, 4, number_of_items
);
2882 for (ii
= 0; ii
< number_of_items
; ii
++ )
2884 if (ii
>= NDPS_MAX_ITEMS
) {
2885 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
2888 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Name %u", ii
+1);
2889 foffset
= ndps_string(tvb
, hf_object_name
, atree
, foffset
, NULL
);
2890 proto_item_set_end(aitem
, tvb
, foffset
);
2893 case 42: /* Realization */
2894 proto_tree_add_item(ndps_tree
, hf_ndps_realization
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2897 case 43: /* Medium Dimensions */
2898 proto_tree_add_item(ndps_tree
, hf_ndps_xdimension_n64
, tvb
, foffset
, 8, ENC_NA
);
2900 proto_tree_add_item(ndps_tree
, hf_ndps_ydimension_n64
, tvb
, foffset
, 8, ENC_NA
);
2903 case 44: /* Dimension */
2904 dimension
= tvb_get_ntohl(tvb
, foffset
);
2905 proto_tree_add_uint(ndps_tree
, hf_ndps_dim_value
, tvb
, foffset
, 4, dimension
);
2907 if (dimension
== 0) {
2908 proto_tree_add_item(ndps_tree
, hf_ndps_n64
, tvb
, foffset
, 8, ENC_NA
);
2913 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
2915 proto_tree_add_item(ndps_tree
, hf_ndps_dim_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2917 proto_tree_add_item(ndps_tree
, hf_ndps_n64
, tvb
, foffset
, 8, ENC_NA
);
2920 case 45: /* XY Dimensions */
2921 dimension
= tvb_get_ntohl(tvb
, foffset
);
2922 proto_tree_add_uint(ndps_tree
, hf_ndps_xydim_value
, tvb
, foffset
, 4, dimension
);
2924 if (dimension
== 1) {
2925 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
2929 proto_tree_add_item(ndps_tree
, hf_ndps_xdimension_n64
, tvb
, foffset
, 8, ENC_NA
);
2931 proto_tree_add_item(ndps_tree
, hf_ndps_ydimension_n64
, tvb
, foffset
, 8, ENC_NA
);
2934 proto_tree_add_item(ndps_tree
, hf_ndps_dim_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2936 proto_tree_add_item(ndps_tree
, hf_ndps_n64
, tvb
, foffset
, 8, ENC_NA
);
2939 case 46: /* Locations */
2940 location
= tvb_get_ntohl(tvb
, foffset
);
2941 proto_tree_add_uint(ndps_tree
, hf_ndps_location_value
, tvb
, foffset
, 4, location
);
2943 if (location
== 0) {
2944 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
2945 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_locations
, tvb
, foffset
, 4, number_of_items
);
2947 for (ii
= 0; ii
< number_of_items
; ii
++ )
2949 if (ii
>= NDPS_MAX_ITEMS
) {
2950 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
2953 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Location %u", ii
+1);
2954 proto_tree_add_item(atree
, hf_ndps_n64
, tvb
, foffset
, 8, ENC_NA
);
2956 proto_item_set_end(aitem
, tvb
, foffset
);
2961 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
2963 proto_tree_add_item(ndps_tree
, hf_ndps_dim_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
2965 proto_tree_add_item(ndps_tree
, hf_ndps_n64
, tvb
, foffset
, 8, ENC_NA
);
2969 proto_tree_add_item(ndps_tree
, hf_ndps_xmin_n64
, tvb
, foffset
, 8, ENC_NA
);
2971 proto_tree_add_item(ndps_tree
, hf_ndps_xmax_n64
, tvb
, foffset
, 8, ENC_NA
);
2973 proto_tree_add_item(ndps_tree
, hf_ndps_ymin_n64
, tvb
, foffset
, 8, ENC_NA
);
2975 proto_tree_add_item(ndps_tree
, hf_ndps_ymax_n64
, tvb
, foffset
, 8, ENC_NA
);
2978 case 48: /* Area Seq */
2979 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
2980 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_areas
, tvb
, foffset
, 4, number_of_items
);
2982 for (ii
= 0; ii
< number_of_items
; ii
++ )
2984 if (ii
>= NDPS_MAX_ITEMS
) {
2985 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
2988 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Area %u", ii
+1);
2989 proto_tree_add_item(atree
, hf_ndps_xmin_n64
, tvb
, foffset
, 8, ENC_NA
);
2991 proto_tree_add_item(atree
, hf_ndps_xmax_n64
, tvb
, foffset
, 8, ENC_NA
);
2993 proto_tree_add_item(atree
, hf_ndps_ymin_n64
, tvb
, foffset
, 8, ENC_NA
);
2995 proto_tree_add_item(atree
, hf_ndps_ymax_n64
, tvb
, foffset
, 8, ENC_NA
);
2997 proto_item_set_end(aitem
, tvb
, foffset
);
3001 proto_tree_add_item(ndps_tree
, hf_ndps_edge_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3004 case 51: /* Cardinal or OID */
3005 cardinal
= tvb_get_ntohl(tvb
, foffset
);
3006 proto_tree_add_uint(ndps_tree
, hf_ndps_cardinal_or_oid
, tvb
, foffset
, 4, cardinal
);
3009 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3014 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3017 case 52: /* OID Cardinal Map */
3018 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3019 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3022 case 53: /* Cardinal or Name or OID */
3023 cardinal
= tvb_get_ntohl(tvb
, foffset
);
3024 proto_tree_add_uint(ndps_tree
, hf_ndps_cardinal_name_or_oid
, tvb
, foffset
, 4, cardinal
);
3027 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3032 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3035 case 54: /* Positive Integer or OID */
3036 integer_or_oid
= tvb_get_ntohl(tvb
, foffset
);
3037 proto_tree_add_uint(ndps_tree
, hf_ndps_integer_or_oid
, tvb
, foffset
, 4, integer_or_oid
);
3039 if (integer_or_oid
==0) {
3040 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3044 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3048 case 55: /* Event Handling Profile */
3049 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3051 proto_tree_add_item(ndps_tree
, hf_ndps_persistence
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3053 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
3054 length
= tvb_get_ntohl(tvb
, foffset
);
3058 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
3061 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3063 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3065 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3066 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_address_items
, tvb
, foffset
, 4, number_of_items
);
3068 for (ii
= 0; ii
< number_of_items
; ii
++ )
3070 if (ii
>= NDPS_MAX_ITEMS
) {
3071 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3074 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Address Item %u", ii
+1);
3075 foffset
= address_item(tvb
, atree
, foffset
);
3076 proto_item_set_end(aitem
, tvb
, foffset
);
3078 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3079 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_events
, tvb
, foffset
, 4, number_of_items
);
3081 for (ii
= 0; ii
< number_of_items
; ii
++ )
3083 if (ii
>= NDPS_MAX_ITEMS
) {
3084 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3087 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Event %u", ii
+1);
3088 proto_tree_add_item(atree
, hf_ndps_event_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3090 foffset
= objectidentifier(tvb
, atree
, foffset
);
3091 foffset
+= align_4(tvb
, foffset
);
3092 foffset
= objectidentification(tvb
, atree
, foffset
);
3093 proto_tree_add_item(atree
, hf_ndps_object_op
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3095 event_object_type
= tvb_get_ntohl(tvb
, foffset
);
3096 proto_tree_add_uint(atree
, hf_ndps_event_object_identifier
, tvb
, foffset
, 4, event_object_type
);
3098 switch (event_object_type
)
3101 /* Number of Objects */
3102 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
3103 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_objects
, tvb
, foffset
, 4, number_of_items2
);
3105 for (jj
= 0; jj
< number_of_items2
; jj
++ )
3107 if (jj
>= NDPS_MAX_ITEMS
) {
3108 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3111 foffset
= objectidentifier(tvb
, atree
, foffset
);
3117 foffset
= objectidentifier(tvb
, atree
, foffset
);
3121 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
3122 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_objects
, tvb
, foffset
, 4, number_of_items2
);
3124 for (jj
= 0; jj
< number_of_items2
; jj
++ )
3126 if (jj
>= NDPS_MAX_ITEMS
) {
3127 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3130 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Object %u", jj
+1);
3131 foffset
= objectidentifier(tvb
, btree
, foffset
);
3132 proto_item_set_end(bitem
, tvb
, foffset
);
3136 proto_item_set_end(aitem
, tvb
, foffset
);
3139 case 56: /* Octet String */
3140 case 63: /* Job Password */
3141 case 66: /* Print Checkpoint */
3142 length
= tvb_get_ntohl(tvb
, foffset
);
3143 ndps_string(tvb
, hf_info_string
, ndps_tree
, foffset
, NULL
);
3144 foffset
+= length
+2;
3145 foffset
+= align_4(tvb
, foffset
);
3147 case 59: /* Method Delivery Address */
3148 proto_tree_add_item(ndps_tree
, hf_ndps_delivery_add_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3149 event_object_type
= tvb_get_ntohl(tvb
, foffset
);
3151 switch(event_object_type
)
3153 case 0: /*MHS ADDR*/
3154 case 1: /*DISTINGUISHED_NAME*/
3156 case 3: /*OCTET_STRING*/
3157 foffset
= ndps_string(tvb
, hf_info_string
, ndps_tree
, foffset
, NULL
);
3159 case 4: /*DIST_NAME_STRING*/
3160 foffset
= ndps_string(tvb
, hf_object_name
, ndps_tree
, foffset
, NULL
);
3161 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3163 case 5: /*RPC_ADDRESS*/
3164 case 6: /*QUALIFIED_NAME*/
3165 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3166 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
3172 case 60: /* Object Identification */
3173 foffset
= objectidentification(tvb
, ndps_tree
, foffset
);
3175 case 61: /* Results Profile */
3176 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3177 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3178 foffset
= address_item(tvb
, ndps_tree
, foffset
);
3179 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3181 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3183 case 62: /* Criteria */
3184 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3185 criterion_type
= tvb_get_ntohl(tvb
, foffset
);
3186 proto_tree_add_uint(ndps_tree
, hf_ndps_criterion_type
, tvb
, foffset
, 4, criterion_type
);
3188 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3191 case 64: /* Job Level */
3192 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3193 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3196 case 65: /* Job Categories */
3197 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3198 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3199 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_job_categories
, tvb
, foffset
, 4, number_of_items
);
3201 for (ii
= 0; ii
< number_of_items
; ii
++ )
3203 if (ii
>= NDPS_MAX_ITEMS
) {
3204 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3207 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Job %u", ii
+1);
3208 length
= tvb_get_ntohl(tvb
, foffset
);
3212 proto_tree_add_item(atree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
3214 tvb_ensure_bytes_exist(tvb
, foffset
, length
+length
%2);
3216 foffset
+= (length
%2);
3217 proto_item_set_end(aitem
, tvb
, foffset
);
3220 case 67: /* Ignored Attribute */
3221 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3223 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3224 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3225 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_ignored_attributes
, tvb
, foffset
, 4, number_of_items
);
3227 for (ii
= 0; ii
< number_of_items
; ii
++ )
3229 if (ii
>= NDPS_MAX_ITEMS
) {
3230 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3233 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Ignored Attribute %u", ii
+1);
3234 ignored_type
= tvb_get_ntohl(tvb
, foffset
);
3235 proto_tree_add_uint(atree
, hf_ndps_ignored_type
, tvb
, foffset
, 4, ignored_type
);
3237 if (ignored_type
== 38)
3239 foffset
= name_or_id(tvb
, atree
, foffset
);
3243 foffset
= objectidentifier(tvb
, atree
, foffset
);
3245 proto_item_set_end(aitem
, tvb
, foffset
);
3248 case 68: /* Resource */
3249 resource_type
= tvb_get_ntohl(tvb
, foffset
);
3250 proto_tree_add_uint(ndps_tree
, hf_ndps_resource_type
, tvb
, foffset
, 4, resource_type
);
3252 if (resource_type
== 0)
3254 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3258 foffset
= ndps_string(tvb
, hf_ndps_tree
, ndps_tree
, foffset
, NULL
);
3261 case 69: /* Medium Substitution */
3262 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3263 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3265 case 70: /* Font Substitution */
3266 foffset
= ndps_string(tvb
, hf_ndps_tree
, ndps_tree
, foffset
, NULL
);
3267 foffset
= ndps_string(tvb
, hf_ndps_tree
, ndps_tree
, foffset
, NULL
);
3269 case 71: /* Resource Context Seq */
3270 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3271 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_resources
, tvb
, foffset
, 4, number_of_items
);
3273 for (ii
= 0; ii
< number_of_items
; ii
++ )
3275 if (ii
>= NDPS_MAX_ITEMS
) {
3276 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3279 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Resource %u", ii
+1);
3280 resource_type
= tvb_get_ntohl(tvb
, foffset
);
3281 proto_tree_add_uint(atree
, hf_ndps_resource_type
, tvb
, foffset
, 4, resource_type
);
3283 if (resource_type
== 0)
3285 foffset
= name_or_id(tvb
, atree
, foffset
);
3289 foffset
= ndps_string(tvb
, hf_ndps_tree
, atree
, foffset
, NULL
);
3291 proto_item_set_end(aitem
, tvb
, foffset
);
3294 case 73: /* Page Select Seq */
3295 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3296 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_page_selects
, tvb
, foffset
, 4, number_of_items
);
3298 for (ii
= 0; ii
< number_of_items
; ii
++ )
3300 if (ii
>= NDPS_MAX_ITEMS
) {
3301 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3304 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Page Select %u", ii
+1);
3305 proto_tree_add_item(atree
, hf_ndps_page_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3307 identifier_type
= tvb_get_ntohl(tvb
, foffset
);
3308 proto_tree_add_uint(atree
, hf_ndps_identifier_type
, tvb
, foffset
, 4, identifier_type
);
3310 if (identifier_type
== 0)
3312 proto_tree_add_item(atree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3315 if (identifier_type
== 1)
3317 foffset
= ndps_string(tvb
, hf_ndps_tree
, atree
, foffset
, NULL
);
3319 if (identifier_type
== 2)
3321 foffset
= name_or_id(tvb
, atree
, foffset
);
3323 proto_tree_add_item(atree
, hf_ndps_page_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3325 identifier_type
= tvb_get_ntohl(tvb
, foffset
);
3326 proto_tree_add_uint(atree
, hf_ndps_identifier_type
, tvb
, foffset
, 4, identifier_type
);
3328 if (identifier_type
== 0)
3330 proto_tree_add_item(atree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3333 if (identifier_type
== 1)
3335 foffset
= ndps_string(tvb
, hf_ndps_tree
, atree
, foffset
, NULL
);
3337 if (identifier_type
== 2)
3339 foffset
= name_or_id(tvb
, atree
, foffset
);
3341 proto_item_set_end(aitem
, tvb
, foffset
);
3344 case 74: /* Page Media Select */
3345 media_type
= tvb_get_ntohl(tvb
, foffset
);
3346 proto_tree_add_uint(ndps_tree
, hf_ndps_media_type
, tvb
, foffset
, 4, media_type
);
3348 if (media_type
== 0)
3350 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3354 foffset
= ndps_string(tvb
, hf_ndps_tree
, ndps_tree
, foffset
, NULL
);
3355 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3356 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
3358 for (ii
= 0; ii
< number_of_items
; ii
++ )
3360 if (ii
>= NDPS_MAX_ITEMS
) {
3361 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3364 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Item %u", ii
+1);
3365 proto_tree_add_item(atree
, hf_ndps_page_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3367 identifier_type
= tvb_get_ntohl(tvb
, foffset
);
3368 proto_tree_add_uint(atree
, hf_ndps_identifier_type
, tvb
, foffset
, 4, identifier_type
);
3370 if (identifier_type
== 0)
3372 proto_tree_add_item(atree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3375 if (identifier_type
== 1)
3377 foffset
= ndps_string(tvb
, hf_ndps_tree
, atree
, foffset
, NULL
);
3379 if (identifier_type
== 2)
3381 foffset
= name_or_id(tvb
, atree
, foffset
);
3383 proto_item_set_end(aitem
, tvb
, foffset
);
3387 case 75: /* Document Content */
3388 doc_content
= tvb_get_ntohl(tvb
, foffset
);
3389 proto_tree_add_uint(ndps_tree
, hf_ndps_doc_content
, tvb
, foffset
, 4, doc_content
);
3391 if (doc_content
== 0)
3393 length
= tvb_get_ntohl(tvb
, foffset
);
3397 proto_tree_add_item(ndps_tree
, hf_ndps_octet_string
, tvb
, foffset
, length
, ENC_NA
);
3400 foffset
+= (length
%2);
3404 foffset
= ndps_string(tvb
, hf_object_name
, ndps_tree
, foffset
, NULL
);
3405 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3408 case 76: /* Page Size */
3409 page_size
= tvb_get_ntohl(tvb
, foffset
);
3410 proto_tree_add_uint(ndps_tree
, hf_ndps_page_size
, tvb
, foffset
, 4, page_size
);
3414 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3418 proto_tree_add_item(ndps_tree
, hf_ndps_xdimension_n64
, tvb
, foffset
, 8, ENC_NA
);
3420 proto_tree_add_item(ndps_tree
, hf_ndps_ydimension_n64
, tvb
, foffset
, 8, ENC_NA
);
3424 case 77: /* Presentation Direction */
3425 proto_tree_add_item(ndps_tree
, hf_ndps_direction
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3428 case 78: /* Page Order */
3429 proto_tree_add_item(ndps_tree
, hf_ndps_page_order
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3432 case 80: /* Medium Source Size */
3433 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3434 medium_size
= tvb_get_ntohl(tvb
, foffset
);
3435 proto_tree_add_uint(ndps_tree
, hf_ndps_medium_size
, tvb
, foffset
, 4, medium_size
);
3437 if (medium_size
== 0)
3439 page_size
= tvb_get_ntohl(tvb
, foffset
);
3440 proto_tree_add_uint(ndps_tree
, hf_ndps_page_size
, tvb
, foffset
, 4, page_size
);
3444 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3448 proto_tree_add_item(ndps_tree
, hf_ndps_xdimension_n64
, tvb
, foffset
, 8, ENC_NA
);
3450 proto_tree_add_item(ndps_tree
, hf_ndps_ydimension_n64
, tvb
, foffset
, 8, ENC_NA
);
3453 proto_tree_add_item(ndps_tree
, hf_ndps_long_edge_feeds
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3455 proto_tree_add_item(ndps_tree
, hf_ndps_xmin_n64
, tvb
, foffset
, 8, ENC_NA
);
3457 proto_tree_add_item(ndps_tree
, hf_ndps_xmax_n64
, tvb
, foffset
, 8, ENC_NA
);
3459 proto_tree_add_item(ndps_tree
, hf_ndps_ymin_n64
, tvb
, foffset
, 8, ENC_NA
);
3461 proto_tree_add_item(ndps_tree
, hf_ndps_ymax_n64
, tvb
, foffset
, 8, ENC_NA
);
3466 proto_tree_add_item(ndps_tree
, hf_ndps_lower_range_n64
, tvb
, foffset
, 8, ENC_NA
);
3468 proto_tree_add_item(ndps_tree
, hf_ndps_upper_range_n64
, tvb
, foffset
, 8, ENC_NA
);
3470 proto_tree_add_item(ndps_tree
, hf_ndps_inc_across_feed
, tvb
, foffset
, 8, ENC_NA
);
3472 proto_tree_add_item(ndps_tree
, hf_ndps_lower_range_n64
, tvb
, foffset
, 8, ENC_NA
);
3474 proto_tree_add_item(ndps_tree
, hf_ndps_upper_range_n64
, tvb
, foffset
, 8, ENC_NA
);
3476 proto_tree_add_item(ndps_tree
, hf_ndps_size_inc_in_feed
, tvb
, foffset
, 8, ENC_NA
);
3478 proto_tree_add_item(ndps_tree
, hf_ndps_long_edge_feeds
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3480 proto_tree_add_item(ndps_tree
, hf_ndps_xmin_n64
, tvb
, foffset
, 8, ENC_NA
);
3482 proto_tree_add_item(ndps_tree
, hf_ndps_xmax_n64
, tvb
, foffset
, 8, ENC_NA
);
3484 proto_tree_add_item(ndps_tree
, hf_ndps_ymin_n64
, tvb
, foffset
, 8, ENC_NA
);
3486 proto_tree_add_item(ndps_tree
, hf_ndps_ymax_n64
, tvb
, foffset
, 8, ENC_NA
);
3490 case 81: /* Input Tray Medium */
3491 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3492 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3494 case 82: /* Output Bins Characteristics */
3495 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3496 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_page_informations
, tvb
, foffset
, 4, number_of_items
);
3498 for (ii
= 0; ii
< number_of_items
; ii
++ )
3500 if (ii
>= NDPS_MAX_ITEMS
) {
3501 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3504 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Page Information %u", ii
+1);
3505 proto_tree_add_item(atree
, hf_ndps_page_order
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3507 proto_tree_add_item(atree
, hf_ndps_page_orientation
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3509 proto_item_set_end(aitem
, tvb
, foffset
);
3512 case 83: /* Page ID Type */
3513 proto_tree_add_item(ndps_tree
, hf_ndps_identifier_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3516 case 84: /* Level Range */
3517 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3518 proto_tree_add_item(ndps_tree
, hf_ndps_lower_range
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3520 proto_tree_add_item(ndps_tree
, hf_ndps_upper_range
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3523 case 85: /* Category Set */
3524 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3525 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3526 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_categories
, tvb
, foffset
, 4, number_of_items
);
3528 for (ii
= 0; ii
< number_of_items
; ii
++ )
3530 if (ii
>= NDPS_MAX_ITEMS
) {
3531 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3534 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Category %u", ii
+1);
3535 length
= tvb_get_ntohl(tvb
, foffset
);
3539 proto_tree_add_item(atree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
3542 foffset
+= (length
%2);
3544 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3545 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_values
, tvb
, foffset
, 4, number_of_items
);
3547 for (ii
= 0; ii
< number_of_items
; ii
++ )
3549 if (ii
>= NDPS_MAX_ITEMS
) {
3550 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3553 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Value %d", ii
+1);
3554 length
= tvb_get_ntohl(tvb
, foffset
);
3558 proto_tree_add_item(atree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
3560 tvb_ensure_bytes_exist(tvb
, foffset
, length
+length
%2);
3562 foffset
+= (length
%2);
3563 proto_item_set_end(aitem
, tvb
, foffset
);
3566 case 86: /* Numbers Up Supported */
3567 numbers_up
=tvb_get_ntohl(tvb
, foffset
);
3568 proto_tree_add_uint(ndps_tree
, hf_ndps_numbers_up
, tvb
, foffset
, 4, numbers_up
);
3572 case 0: /*Cardinal*/
3573 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3576 case 1: /*Name or OID*/
3577 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3579 case 2: /*Cardinal Range*/
3580 proto_tree_add_item(ndps_tree
, hf_ndps_lower_range
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3582 proto_tree_add_item(ndps_tree
, hf_ndps_upper_range
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3589 case 87: /* Finishing */
3590 case 88: /* Print Contained Object ID */
3591 foffset
= ndps_string(tvb
, hf_object_name
, ndps_tree
, foffset
, NULL
);
3592 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3595 case 89: /* Print Config Object ID */
3596 foffset
= ndps_string(tvb
, hf_object_name
, ndps_tree
, foffset
, NULL
);
3597 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
3599 case 90: /* Typed Name */
3600 foffset
= ndps_string(tvb
, hf_object_name
, ndps_tree
, foffset
, NULL
);
3601 proto_tree_add_item(ndps_tree
, hf_level
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3603 proto_tree_add_item(ndps_tree
, hf_interval
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3606 case 91: /* Network Address */
3607 proto_tree_add_item(ndps_tree
, hf_ndps_address
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3609 length
= tvb_get_ntohl(tvb
, foffset
);
3613 proto_tree_add_item(ndps_tree
, hf_ndps_add_bytes
, tvb
, foffset
, 4, ENC_NA
);
3617 case 92: /* XY Dimensions Value */
3618 dimension
= tvb_get_ntohl(tvb
, foffset
);
3619 proto_tree_add_uint(ndps_tree
, hf_ndps_xydim_value
, tvb
, foffset
, 4, dimension
);
3624 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3628 proto_tree_add_item(ndps_tree
, hf_ndps_xdimension_n64
, tvb
, foffset
, 8, ENC_NA
);
3630 proto_tree_add_item(ndps_tree
, hf_ndps_ydimension_n64
, tvb
, foffset
, 8, ENC_NA
);
3635 proto_tree_add_item(ndps_tree
, hf_ndps_xdimension
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3637 proto_tree_add_item(ndps_tree
, hf_ndps_ydimension
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3642 case 93: /* Name or OID Dimensions Map */
3643 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3644 proto_tree_add_item(ndps_tree
, hf_ndps_xdimension
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3646 proto_tree_add_item(ndps_tree
, hf_ndps_ydimension
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3649 case 94: /* Printer State Reason */
3651 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3652 proto_tree_add_item(ndps_tree
, hf_ndps_state_severity
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3654 proto_tree_add_item(ndps_tree
, hf_ndps_training
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3656 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3657 foffset
+= align_4(tvb
, foffset
);
3658 foffset
= objectidentification(tvb
, ndps_tree
, foffset
);
3659 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3661 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3662 foffset
+= 4*number_of_items
;
3663 /*foffset += align_4(tvb, foffset);*/
3664 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3667 case 96: /* Qualified Name */
3668 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
3670 case 97: /* Qualified Name Set */
3671 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3672 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_names
, tvb
, foffset
, 4, number_of_items
);
3674 for (ii
= 0; ii
< number_of_items
; ii
++ )
3676 if (ii
>= NDPS_MAX_ITEMS
) {
3677 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3680 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Name %u", ii
+1);
3681 foffset
= qualifiedname(tvb
, atree
, foffset
);
3682 proto_item_set_end(aitem
, tvb
, foffset
);
3685 case 98: /* Colorant Set */
3686 colorant_set
= tvb_get_ntohl(tvb
, foffset
);
3687 proto_tree_add_item(ndps_tree
, hf_ndps_colorant_set
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3689 if (colorant_set
==0)
3691 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3696 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3697 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3698 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_colorants
, tvb
, foffset
, 4, number_of_items
);
3700 for (ii
= 0; ii
< number_of_items
; ii
++ )
3702 if (ii
>= NDPS_MAX_ITEMS
) {
3703 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3706 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Colorant %u", ii
+1);
3707 foffset
= name_or_id(tvb
, atree
, foffset
);
3708 proto_item_set_end(aitem
, tvb
, foffset
);
3712 case 99: /* Resource Printer ID */
3713 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3714 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_printer_def_count
, tvb
, foffset
, 4, number_of_items
);
3716 for (ii
= 0; ii
< number_of_items
; ii
++ )
3718 if (ii
>= NDPS_MAX_ITEMS
) {
3719 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3722 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Printer %u", ii
+1);
3723 foffset
= ndps_string(tvb
, hf_ndps_printer_type
, atree
, foffset
, NULL
);
3724 foffset
= ndps_string(tvb
, hf_ndps_printer_manuf
, atree
, foffset
, NULL
);
3725 foffset
= ndps_string(tvb
, hf_ndps_inf_file_name
, atree
, foffset
, NULL
);
3726 proto_item_set_end(aitem
, tvb
, foffset
);
3728 proto_tree_add_item(ndps_tree
, hf_os_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3731 case 100: /* Event Object ID */
3732 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
3733 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3734 proto_tree_add_item(ndps_tree
, hf_ndps_event_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3737 case 101: /* Qualified Name Map */
3738 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
3739 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
3741 case 104: /* Cardinal or Enum or Time */
3742 card_enum_time
= tvb_get_ntohl(tvb
, foffset
);
3743 proto_tree_add_item(ndps_tree
, hf_ndps_card_enum_time
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3745 switch (card_enum_time
)
3748 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3753 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3758 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3763 case 105: /* Print Contained Object ID Set */
3764 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3765 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_objects
, tvb
, foffset
, 4, number_of_items
);
3767 for (ii
= 0; ii
< number_of_items
; ii
++ )
3769 if (ii
>= NDPS_MAX_ITEMS
) {
3770 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3773 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object %u", ii
+1);
3774 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, atree
, foffset
, NULL
);
3775 proto_tree_add_item(atree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3777 proto_item_set_end(aitem
, tvb
, foffset
);
3780 case 106: /* Octet String Pair */
3781 length
= tvb_get_ntohl(tvb
, foffset
);
3785 proto_tree_add_item(ndps_tree
, hf_ndps_octet_string
, tvb
, foffset
, length
, ENC_NA
);
3788 foffset
+= (length
%2);
3789 length
= tvb_get_ntohl(tvb
, foffset
);
3793 proto_tree_add_item(ndps_tree
, hf_ndps_octet_string
, tvb
, foffset
, length
, ENC_NA
);
3796 foffset
+= (length
%2);
3798 case 107: /* Octet String Integer Pair */
3799 length
= tvb_get_ntohl(tvb
, foffset
);
3803 proto_tree_add_item(ndps_tree
, hf_ndps_octet_string
, tvb
, foffset
, length
, ENC_NA
);
3806 foffset
+= (length
%2);
3807 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3809 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3812 case 109: /* Event Handling Profile 2 */
3813 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3815 proto_tree_add_item(ndps_tree
, hf_ndps_persistence
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3817 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
3818 length
= tvb_get_ntohl(tvb
, foffset
);
3822 proto_tree_add_item(ndps_tree
, hf_ndps_octet_string
, tvb
, foffset
, length
, ENC_NA
);
3825 foffset
+= (length
%2);
3826 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3828 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3829 proto_tree_add_item(ndps_tree
, hf_ndps_delivery_add_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3830 event_object_type
= tvb_get_ntohl(tvb
, foffset
);
3832 switch(event_object_type
)
3834 case 0: /*MHS ADDR*/
3835 case 1: /*DISTINGUISHED_NAME*/
3837 foffset
= ndps_string(tvb
, hf_ndps_tree
, ndps_tree
, foffset
, NULL
);
3839 case 3: /*OCTET_STRING*/
3840 length
= tvb_get_ntohl(tvb
, foffset
);
3844 proto_tree_add_item(ndps_tree
, hf_ndps_octet_string
, tvb
, foffset
, length
, ENC_NA
);
3847 foffset
+= (length
%2);
3849 case 4: /*DIST_NAME_STRING*/
3850 foffset
= ndps_string(tvb
, hf_object_name
, ndps_tree
, foffset
, NULL
);
3851 foffset
= name_or_id(tvb
, ndps_tree
, foffset
);
3853 case 5: /*RPC_ADDRESS*/
3854 case 6: /*QUALIFIED_NAME*/
3855 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3856 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
3861 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3862 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_events
, tvb
, foffset
, 4, number_of_items
);
3864 for (ii
= 0; ii
< number_of_items
; ii
++ )
3866 if (ii
>= NDPS_MAX_ITEMS
) {
3867 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3870 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Event %u", ii
+1);
3871 foffset
= ndps_string(tvb
, hf_object_name
, atree
, foffset
, NULL
);
3872 foffset
= objectidentifier(tvb
, atree
, foffset
);
3873 proto_tree_add_item(atree
, hf_ndps_event_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3875 proto_item_set_end(aitem
, tvb
, foffset
);
3877 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
3878 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
3879 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3880 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_objects
, tvb
, foffset
, 4, number_of_items
);
3882 for (ii
= 0; ii
< number_of_items
; ii
++ )
3884 if (ii
>= NDPS_MAX_ITEMS
) {
3885 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3888 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object %u", ii
+1);
3889 foffset
= objectidentifier(tvb
, atree
, foffset
);
3890 proto_item_set_end(aitem
, tvb
, foffset
);
3892 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3894 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3896 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3898 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
3908 commonarguments(tvbuff_t
* tvb
, packet_info
* pinfo
, proto_tree
*ndps_tree
, int foffset
)
3910 uint32_t number_of_items
;
3912 proto_tree
*atree
, *btree
;
3913 proto_item
*aitem
, *bitem
, *expert_item
;
3915 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Common Arguments");
3916 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
3917 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_args
, tvb
, foffset
, 4, number_of_items
);
3919 for (ii
= 0; ii
< number_of_items
; ii
++ )
3921 if (ii
>= NDPS_MAX_ITEMS
) {
3922 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
3925 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Argument %u", ii
+1);
3926 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
);
3927 proto_item_set_end(bitem
, tvb
, foffset
);
3929 proto_item_set_end(aitem
, tvb
, foffset
);
3934 res_add_input_data(tvbuff_t
* tvb
, proto_tree
*ndps_tree
, int foffset
)
3936 uint32_t resource_type
=0;
3938 resource_type
= tvb_get_ntohl(tvb
, foffset
);
3939 proto_tree_add_uint(ndps_tree
, hf_res_type
, tvb
, foffset
, 4, resource_type
);
3941 switch (resource_type
)
3943 case 0: /* Print Drivers */
3944 proto_tree_add_item(ndps_tree
, hf_os_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3946 foffset
= ndps_string(tvb
, hf_ndps_prn_dir_name
, ndps_tree
, foffset
, NULL
);
3947 foffset
= ndps_string(tvb
, hf_ndps_prn_file_name
, ndps_tree
, foffset
, NULL
);
3949 case 1: /* Printer Definitions */
3950 foffset
= ndps_string(tvb
, hf_ndps_vendor_dir
, ndps_tree
, foffset
, NULL
);
3951 foffset
= ndps_string(tvb
, hf_ndps_prn_file_name
, ndps_tree
, foffset
, NULL
);
3953 case 2: /* Banner Page Files */
3954 foffset
= ndps_string(tvb
, hf_ndps_banner_name
, ndps_tree
, foffset
, NULL
);
3956 case 3: /* Font Types */
3957 proto_tree_add_item(ndps_tree
, hf_os_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3959 proto_tree_add_item(ndps_tree
, hf_font_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3961 foffset
= ndps_string(tvb
, hf_ndps_prn_file_name
, ndps_tree
, foffset
, NULL
);
3963 case 4: /* Generic Files/ Archive */
3964 case 5: /* Printer Driver Archive */
3965 proto_tree_add_item(ndps_tree
, hf_os_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3967 foffset
= ndps_string(tvb
, hf_ndps_prn_dir_name
, ndps_tree
, foffset
, NULL
);
3968 proto_tree_add_item(ndps_tree
, hf_archive_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
3978 static const fragment_items ndps_frag_items
= {
3983 &hf_ndps_segment_overlap
,
3984 &hf_ndps_segment_overlap_conflict
,
3985 &hf_ndps_segment_multiple_tails
,
3986 &hf_ndps_segment_too_long_segment
,
3987 &hf_ndps_segment_error
,
3988 &hf_ndps_segment_count
,
3990 &hf_ndps_reassembled_length
,
3991 /* Reassembled data field */
3996 /* NDPS packets come in request/reply pairs. The request packets tell the
3997 * Function and Program numbers. The response, unfortunately, only
3998 * identifies itself via the Exchange ID; you have to know what type of NDPS
3999 * request the request packet contained in order to successfully parse the
4000 * response. A global method for doing this does not exist in wireshark yet
4001 * (NFS also requires it), so for now the NDPS section will keep its own hash
4002 * table keeping track of NDPS packets.
4004 * We construct a conversation specified by the client and server
4005 * addresses and the connection number; the key representing the unique
4006 * NDPS request then is composed of the pointer to the conversation
4007 * structure, cast to a "uint" (which may throw away the upper 32
4008 * bits of the pointer on a P64 platform, but the low-order 32 bits
4009 * are more likely to differ between conversations than the upper 32 bits),
4010 * and the sequence number.
4012 * The value stored in the hash table is the ncp_req_hash_value pointer. This
4013 * struct tells us the NDPS Program and Function and gives the NDPS_record pointer.
4016 conversation_t
*conversation
;
4017 uint32_t ndps_xport
;
4018 } ndps_req_hash_key
;
4023 uint32_t ndps_frame_num
;
4025 uint32_t ndps_end_frag
;
4026 } ndps_req_hash_value
;
4028 static wmem_map_t
*ndps_req_hash
;
4030 /* Hash Functions */
4032 ndps_equal(const void *v
, const void *v2
)
4034 const ndps_req_hash_key
*val1
= (const ndps_req_hash_key
*)v
;
4035 const ndps_req_hash_key
*val2
= (const ndps_req_hash_key
*)v2
;
4037 if (val1
->conversation
== val2
->conversation
&&
4038 val1
->ndps_xport
== val2
->ndps_xport
) {
4045 ndps_hash(const void *v
)
4047 const ndps_req_hash_key
*ndps_key
= (const ndps_req_hash_key
*)v
;
4048 return GPOINTER_TO_UINT(ndps_key
->conversation
) + ndps_key
->ndps_xport
;
4051 static ndps_req_hash_value
*
4052 ndps_hash_insert(conversation_t
*conversation
, uint32_t ndps_xport
)
4054 ndps_req_hash_key
*request_key
;
4055 ndps_req_hash_value
*request_value
;
4057 /* Now remember the request, so we can find it if we later
4059 request_key
= wmem_new(wmem_file_scope(), ndps_req_hash_key
);
4060 request_key
->conversation
= conversation
;
4061 request_key
->ndps_xport
= ndps_xport
;
4063 request_value
= wmem_new(wmem_file_scope(), ndps_req_hash_value
);
4064 request_value
->ndps_prog
= 0;
4065 request_value
->ndps_func
= 0;
4066 request_value
->ndps_frame_num
= 0;
4067 request_value
->ndps_frag
= false;
4068 request_value
->ndps_end_frag
= 0;
4070 wmem_map_insert(ndps_req_hash
, request_key
, request_value
);
4072 return request_value
;
4075 /* Returns the ncp_rec*, or NULL if not found. */
4076 static ndps_req_hash_value
*
4077 ndps_hash_lookup(conversation_t
*conversation
, uint32_t ndps_xport
)
4079 ndps_req_hash_key request_key
;
4081 request_key
.conversation
= conversation
;
4082 request_key
.ndps_xport
= ndps_xport
;
4084 return (ndps_req_hash_value
*)wmem_map_lookup(ndps_req_hash
, &request_key
);
4087 /* ================================================================= */
4089 /* ================================================================= */
4092 dissect_ndps(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*ndps_tree
)
4096 uint32_t ndps_packet_type
;
4098 uint32_t ndps_hfname
;
4100 const char *ndps_program_string
;
4101 const char *ndps_func_string
;
4104 ndps_packet_type
= tvb_get_ntohl(tvb
, 8);
4105 if (ndps_packet_type
!= 0 && ndps_packet_type
!= 1) { /* Packet Type */
4106 col_set_str(pinfo
->cinfo
, COL_INFO
, "(Continuation Data)");
4107 proto_tree_add_bytes_format(ndps_tree
, hf_ndps_data
, tvb
, 0, -1, NULL
, "Data - (%d Bytes)", tvb_reported_length(tvb
));
4111 proto_tree_add_item(ndps_tree
, hf_ndps_record_mark
, tvb
,
4112 foffset
, 2, ENC_BIG_ENDIAN
);
4114 proto_tree_add_item(ndps_tree
, hf_ndps_length
, tvb
,
4115 foffset
, 2, ENC_BIG_ENDIAN
);
4118 ndps_xid
= tvb_get_ntohl(tvb
, foffset
);
4119 proto_tree_add_uint(ndps_tree
, hf_ndps_xid
, tvb
, foffset
, 4, ndps_xid
);
4121 ndps_packet_type
= tvb_get_ntohl(tvb
, foffset
);
4122 proto_tree_add_uint(ndps_tree
, hf_ndps_packet_type
, tvb
, foffset
, 4, ndps_packet_type
);
4124 if(ndps_packet_type
== 0x00000001) /* Reply packet */
4126 col_set_str(pinfo
->cinfo
, COL_INFO
, "R NDPS ");
4127 proto_tree_add_item(ndps_tree
, hf_ndps_rpc_accept
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4128 if (tvb_get_ntohl(tvb
, foffset
)==0) {
4130 proto_tree_add_item(ndps_tree
, hf_ndps_auth_null
, tvb
, foffset
, 8, ENC_NA
);
4136 proto_tree_add_item(ndps_tree
, hf_ndps_rpc_rej_stat
, tvb
, foffset
+4, 4, ENC_BIG_ENDIAN
);
4139 dissect_ndps_reply(tvb
, pinfo
, ndps_tree
, foffset
);
4143 col_set_str(pinfo
->cinfo
, COL_INFO
, "C NDPS ");
4144 proto_tree_add_item(ndps_tree
, hf_ndps_rpc_version
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4146 ndps_prog
= tvb_get_ntohl(tvb
, foffset
);
4147 ndps_program_string
= try_val_to_str(ndps_prog
, spx_ndps_program_vals
);
4148 if( ndps_program_string
!= NULL
)
4150 proto_tree_add_item(ndps_tree
, hf_spx_ndps_program
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4152 col_append_str(pinfo
->cinfo
, COL_INFO
, (const char*) ndps_program_string
);
4153 col_append_str(pinfo
->cinfo
, COL_INFO
, ", ");
4155 proto_tree_add_item(ndps_tree
, hf_spx_ndps_version
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4157 ndps_func
= tvb_get_ntohl(tvb
, foffset
);
4161 ndps_hfname
= hf_spx_ndps_func_print
;
4162 ndps_func_string
= try_val_to_str_ext(ndps_func
, &spx_ndps_print_func_vals_ext
);
4165 ndps_hfname
= hf_spx_ndps_func_broker
;
4166 ndps_func_string
= try_val_to_str_ext(ndps_func
, &spx_ndps_broker_func_vals_ext
);
4169 ndps_hfname
= hf_spx_ndps_func_registry
;
4170 ndps_func_string
= try_val_to_str_ext(ndps_func
, &spx_ndps_registry_func_vals_ext
);
4173 ndps_hfname
= hf_spx_ndps_func_notify
;
4174 ndps_func_string
= try_val_to_str_ext(ndps_func
, &spx_ndps_notify_func_vals_ext
);
4177 ndps_hfname
= hf_spx_ndps_func_resman
;
4178 ndps_func_string
= try_val_to_str_ext(ndps_func
, &spx_ndps_resman_func_vals_ext
);
4181 ndps_hfname
= hf_spx_ndps_func_delivery
;
4182 ndps_func_string
= try_val_to_str(ndps_func
, spx_ndps_deliver_func_vals
);
4186 ndps_func_string
= NULL
;
4189 if(ndps_hfname
!= 0)
4191 proto_tree_add_item(ndps_tree
, ndps_hfname
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4192 if (ndps_func_string
!= NULL
)
4194 col_append_str(pinfo
->cinfo
, COL_INFO
, (const char*) ndps_func_string
);
4197 proto_tree_add_item(ndps_tree
, hf_ndps_auth_null
, tvb
, foffset
, 16, ENC_NA
);
4199 dissect_ndps_request(tvb
, pinfo
, ndps_tree
, ndps_prog
, ndps_func
, foffset
);
4207 get_ndps_pdu_len(packet_info
*pinfo _U_
, tvbuff_t
*tvb
, int offset
, void *data _U_
)
4209 return tvb_get_ntohs(tvb
, offset
+2) + 4;
4213 dissect_ndps_pdu(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
, void* data _U_
)
4215 proto_tree
*ndps_tree
;
4218 col_set_str(pinfo
->cinfo
, COL_PROTOCOL
, "NDPS");
4220 col_clear(pinfo
->cinfo
, COL_INFO
);
4222 ti
= proto_tree_add_item(tree
, proto_ndps
, tvb
, 0, -1, ENC_NA
);
4223 ndps_tree
= proto_item_add_subtree(ti
, ett_ndps
);
4225 dissect_ndps(tvb
, pinfo
, ndps_tree
);
4226 return tvb_captured_length(tvb
);
4232 * SPX EOM not being set indicates we are inside or at the
4233 * beginning of a fragment. But when the end of the fragment
4234 * is encountered the flag is set. So we must mark what the
4235 * frame number is of the end fragment so that we will be
4236 * able to redissect if the user clicks on the packet
4237 * or resorts/filters the trace.
4239 * Once we are certain that we are in a fragment sequence
4240 * then we can just process each fragment in this conversation
4241 * until we reach the eom message packet. We can tell we are at
4242 * the final fragment because it is flagged as SPX EOM.
4244 * We will be able to easily determine if a conversation is a fragment
4245 * with the exception of the last packet in the fragment. So remember
4246 * the last fragment packet number.
4249 ndps_defrag(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
, spx_info
*spx_info_p
)
4252 tvbuff_t
*next_tvb
= NULL
;
4253 fragment_head
*fd_head
;
4254 ndps_req_hash_value
*request_value
= NULL
;
4255 conversation_t
*conversation
;
4257 /* Check to see if defragmentation is enabled in the dissector */
4258 if (!ndps_defragment
) {
4259 dissect_ndps(tvb
, pinfo
, tree
);
4262 /* Has this already been dissected? */
4263 if (!pinfo
->fd
->visited
)
4265 /* Lets see if this is a new conversation */
4266 conversation
= find_conversation(pinfo
->num
, &pinfo
->src
, &pinfo
->dst
,
4267 CONVERSATION_NCP
, (uint32_t) pinfo
->srcport
, (uint32_t) pinfo
->srcport
, 0);
4269 if (conversation
== NULL
)
4271 /* It's not part of any conversation - create a new one. */
4272 conversation
= conversation_new(pinfo
->num
, &pinfo
->src
, &pinfo
->dst
,
4273 CONVERSATION_NCP
, (uint32_t) pinfo
->srcport
, (uint32_t) pinfo
->srcport
, 0);
4276 /* So now we need to get the request info for this conversation */
4277 request_value
= ndps_hash_lookup(conversation
, (uint32_t) pinfo
->srcport
);
4278 if (request_value
== NULL
)
4280 /* We haven't seen a packet with this conversation yet so create one. */
4281 request_value
= ndps_hash_insert(conversation
, (uint32_t) pinfo
->srcport
);
4283 /* Add it to pinfo so we can get it on further dissection requests */
4284 p_add_proto_data(wmem_file_scope(), pinfo
, proto_ndps
, 0, (void*) request_value
);
4288 /* Get request value data */
4289 request_value
= (ndps_req_hash_value
*)p_get_proto_data(wmem_file_scope(), pinfo
, proto_ndps
, 0);
4293 /* Can't find the original request packet so this is not any fragment packet */
4294 dissect_ndps(tvb
, pinfo
, tree
);
4297 /* Check to see of this is a fragment. If so then mark as a fragment. */
4298 if (!spx_info_p
->eom
) {
4299 request_value
->ndps_frag
= true;
4301 /* Now we process the fragments */
4302 if (request_value
->ndps_frag
|| (request_value
->ndps_end_frag
== pinfo
->num
))
4307 tid
= (pinfo
->srcport
+pinfo
->destport
);
4308 len
= tvb_reported_length(tvb
);
4309 if (tvb_captured_length(tvb
) >= len
)
4311 fd_head
= fragment_add_seq_next(&ndps_reassembly_table
, tvb
, 0, pinfo
, tid
, NULL
, len
, !spx_info_p
->eom
);
4312 if (fd_head
!= NULL
)
4314 /* Is this the last fragment? EOM will indicate */
4315 if (fd_head
->next
!= NULL
&& spx_info_p
->eom
)
4317 proto_item
*frag_tree_item
;
4319 next_tvb
= tvb_new_chain(tvb
, fd_head
->tvb_data
);
4320 add_new_data_source(pinfo
,
4322 "Reassembled NDPS");
4323 /* Show all fragments. */
4326 show_fragment_seq_tree(fd_head
,
4329 next_tvb
, &frag_tree_item
);
4332 /* Remember this fragment number so we can dissect again */
4333 request_value
->ndps_end_frag
= pinfo
->num
;
4338 /* This is either a beginning or middle fragment on second dissection */
4339 next_tvb
= tvb_new_subset_remaining(tvb
, 0);
4340 if (!spx_info_p
->eom
)
4342 col_append_str(pinfo
->cinfo
, COL_INFO
, "[NDPS Fragment]");
4348 /* Fragment from first pass of dissection */
4349 if (!spx_info_p
->eom
)
4351 col_append_str(pinfo
->cinfo
, COL_INFO
, "[NDPS Fragment]");
4360 * There are no bytes so Dissect this
4362 next_tvb
= tvb_new_subset_remaining(tvb
, 0);
4364 if (next_tvb
== NULL
)
4366 /* This is a fragment packet */
4367 next_tvb
= tvb_new_subset_remaining (tvb
, 0);
4368 call_data_dissector(next_tvb
, pinfo
, tree
);
4372 /* This is the end fragment so dissect and mark end */
4373 if (spx_info_p
->eom
) {
4374 request_value
->ndps_frag
= false;
4375 dissect_ndps(next_tvb
, pinfo
, tree
);
4381 /* This is not any fragment packet */
4382 request_value
->ndps_frag
= false;
4383 dissect_ndps(tvb
, pinfo
, tree
);
4388 dissect_ndps_tcp(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
, void* data
)
4390 tcp_dissect_pdus(tvb
, pinfo
, tree
, ndps_desegment
, 4, get_ndps_pdu_len
, dissect_ndps_pdu
, data
);
4391 return tvb_captured_length(tvb
);
4396 dissect_ndps_ipx(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
, void* data
)
4398 proto_tree
*ndps_tree
;
4401 /* Reject the packet if data is NULL */
4405 col_set_str(pinfo
->cinfo
, COL_PROTOCOL
, "NDPS");
4407 col_clear(pinfo
->cinfo
, COL_INFO
);
4409 ti
= proto_tree_add_item(tree
, proto_ndps
, tvb
, 0, -1, ENC_NA
);
4410 ndps_tree
= proto_item_add_subtree(ti
, ett_ndps
);
4412 ndps_defrag(tvb
, pinfo
, ndps_tree
, (spx_info
*)data
);
4413 return tvb_captured_length(tvb
);
4417 dissect_ndps_request(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*ndps_tree
, uint32_t ndps_prog
, uint32_t ndps_func
, int foffset
)
4419 ndps_req_hash_value
*request_value
= NULL
;
4420 conversation_t
*conversation
;
4425 uint32_t resource_type
;
4426 uint32_t filter_type
;
4427 uint32_t print_type
;
4429 uint32_t number_of_items
;
4430 uint32_t number_of_items2
;
4431 uint32_t doc_content
;
4432 uint32_t list_attr_op
;
4435 uint32_t supplier_flag
;
4438 bool delivery_address_flag
;
4439 uint32_t profiles_type
;
4440 uint32_t profiles_choice_type
;
4441 uint32_t integer_type_flag
;
4442 uint32_t local_servers_type
;
4443 int length_remaining
;
4444 proto_tree
*atree
, *btree
, *ctree
, *dtree
;
4445 proto_item
*aitem
, *bitem
, *citem
, *ditem
, *expert_item
;
4447 if (!pinfo
->fd
->visited
)
4449 /* This is the first time we've looked at this packet.
4450 Keep track of the Program and connection whence the request
4451 came, and the address and connection to which the request
4452 is being sent, so that we can match up calls with replies.
4453 (We don't include the sequence number, as we may want
4454 to have all packets over the same connection treated
4455 as being part of a single conversation so that we can
4456 let the user select that conversation to be displayed.) */
4458 conversation
= find_conversation(pinfo
->num
, &pinfo
->src
, &pinfo
->dst
,
4459 CONVERSATION_NCP
, (uint32_t) pinfo
->srcport
, (uint32_t) pinfo
->srcport
, 0);
4461 if (conversation
== NULL
)
4463 /* It's not part of any conversation - create a new one. */
4464 conversation
= conversation_new(pinfo
->num
, &pinfo
->src
, &pinfo
->dst
,
4465 CONVERSATION_NCP
, (uint32_t) pinfo
->srcport
, (uint32_t) pinfo
->srcport
, 0);
4468 request_value
= ndps_hash_insert(conversation
, (uint32_t) pinfo
->srcport
);
4469 request_value
->ndps_prog
= ndps_prog
;
4470 request_value
->ndps_func
= ndps_func
;
4471 request_value
->ndps_frame_num
= pinfo
->num
;
4475 case 0x060976: /* Print */
4478 case 0x00000001: /* Bind PSM */
4479 foffset
= credentials(tvb
, pinfo
, ndps_tree
, foffset
);
4481 case 0x00000002: /* Bind PA */
4482 foffset
= credentials(tvb
, pinfo
, ndps_tree
, foffset
);
4483 proto_tree_add_item(ndps_tree
, hf_ndps_retrieve_restrictions
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4485 number_of_items
=tvb_get_ntohl(tvb
, foffset
);
4486 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_bind_security_option_count
, tvb
, foffset
, 4, number_of_items
);
4488 for (ii
= 0; ii
< number_of_items
; ii
++ )
4490 if (ii
>= NDPS_MAX_ITEMS
) {
4491 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4494 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Security %u", ii
+1);
4495 length
= tvb_get_ntohl(tvb
, foffset
);
4498 proto_tree_add_uint(atree
, hf_bind_security
, tvb
, foffset
, 4, length
);
4501 proto_item_set_end(aitem
, tvb
, foffset
);
4503 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
4505 case 0x00000003: /* Unbind */
4506 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
,
4509 case 0x00000004: /* Print */
4510 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4512 print_type
= tvb_get_ntohl(tvb
, foffset
);
4513 proto_tree_add_uint(ndps_tree
, hf_print_arg
, tvb
, foffset
, 4, print_type
);
4517 case 0: /* Create Job */
4518 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
4519 proto_tree_add_item(ndps_tree
, hf_sub_complete
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4521 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Transfer Method");
4522 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4523 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_objects
, tvb
, foffset
, 4, number_of_items
);
4525 for (ii
= 0; ii
< number_of_items
; ii
++ )
4527 if (ii
>= NDPS_MAX_ITEMS
) {
4528 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4531 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Attribute %u", ii
+1);
4532 foffset
= objectidentifier(tvb
, btree
, foffset
);
4533 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
4534 expert_item
= proto_tree_add_uint(btree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items2
);
4536 for (jj
= 0; jj
< number_of_items2
; jj
++ )
4538 if (jj
>= NDPS_MAX_ITEMS
) {
4539 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4542 ctree
= proto_tree_add_subtree_format(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Value %u", jj
+1);
4543 foffset
= attribute_value(tvb
, pinfo
, ctree
, foffset
);
4544 proto_item_set_end(citem
, tvb
, foffset
);
4546 proto_tree_add_item(btree
, hf_ndps_qualifier
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4548 proto_item_set_end(bitem
, tvb
, foffset
);
4550 proto_item_set_end(aitem
, tvb
, foffset
);
4551 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Document Content");
4552 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4553 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_objects
, tvb
, foffset
, 4, number_of_items
);
4555 for (ii
= 0; ii
< number_of_items
; ii
++ )
4557 if (ii
>= NDPS_MAX_ITEMS
) {
4558 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4561 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Type %u", ii
+1);
4562 foffset
= objectidentifier(tvb
, btree
, foffset
);
4563 proto_item_set_end(bitem
, tvb
, foffset
);
4565 foffset
+= align_4(tvb
, foffset
);
4566 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4567 proto_tree_add_uint(atree
, hf_ndps_num_objects
, tvb
, foffset
, 4, number_of_items
);
4569 doc_content
= tvb_get_ntohl(tvb
, foffset
);
4570 expert_item
= proto_tree_add_uint(atree
, hf_doc_content
, tvb
, foffset
, 4, doc_content
);
4572 for (ii
= 0; ii
< number_of_items
; ii
++ )
4574 if (ii
>= NDPS_MAX_ITEMS
) {
4575 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4578 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Value %u", ii
+1);
4581 length
= tvb_get_ntohl(tvb
, foffset
);
4582 proto_tree_add_uint(btree
, hf_ndps_included_doc_len
, tvb
, foffset
, 4, length
);
4584 length_remaining
= tvb_reported_length_remaining(tvb
, foffset
);
4585 if (length_remaining
== -1 || length
> (uint32_t) length_remaining
) /* Segmented Data */
4587 proto_tree_add_item(btree
, hf_ndps_data
, tvb
, foffset
, -1, ENC_NA
);
4592 proto_tree_add_item(btree
, hf_ndps_included_doc
, tvb
, foffset
, length
, ENC_NA
);
4595 foffset
+= (length
%2);
4599 foffset
= ndps_string(tvb
, hf_ndps_ref_name
, btree
, foffset
, NULL
);
4600 foffset
= name_or_id(tvb
, btree
, foffset
);
4602 proto_item_set_end(bitem
, tvb
, foffset
);
4604 proto_item_set_end(aitem
, tvb
, foffset
);
4606 if (align_4(tvb
, foffset
)>0) {
4607 foffset
+= align_4(tvb
, foffset
);
4609 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Document Type");
4610 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4611 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_objects
, tvb
, foffset
, 4, number_of_items
);
4613 for (ii
= 0; ii
< number_of_items
; ii
++ )
4615 if (ii
>= NDPS_MAX_ITEMS
) {
4616 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4619 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Attribute %u", ii
+1);
4620 foffset
= objectidentifier(tvb
, btree
, foffset
);
4621 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
4622 expert_item
= proto_tree_add_uint(btree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items2
);
4624 for (jj
= 0; jj
< number_of_items2
; jj
++ )
4626 if (jj
>= NDPS_MAX_ITEMS
) {
4627 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4630 ctree
= proto_tree_add_subtree_format(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Value %u", jj
+1);
4631 foffset
= attribute_value(tvb
, pinfo
, ctree
, foffset
);
4632 proto_item_set_end(citem
, tvb
, foffset
);
4634 proto_tree_add_item(btree
, hf_ndps_qualifier
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4636 proto_item_set_end(bitem
, tvb
, foffset
);
4638 proto_item_set_end(aitem
, tvb
, foffset
);
4639 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Document Attributes");
4640 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4641 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
4643 for (ii
= 0; ii
< number_of_items
; ii
++ )
4645 if (ii
>= NDPS_MAX_ITEMS
) {
4646 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4649 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Attribute %u", ii
+1);
4650 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
); /* Document Attributes */
4651 proto_item_set_end(bitem
, tvb
, foffset
);
4654 case 1: /* Add Job */
4655 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
4656 proto_tree_add_item(ndps_tree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4658 proto_tree_add_item(ndps_tree
, hf_sub_complete
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4660 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Transfer Method");
4661 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4662 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_transfer_methods
, tvb
, foffset
, 4, number_of_items
);
4664 for (ii
= 0; ii
< number_of_items
; ii
++ )
4666 if (ii
>= NDPS_MAX_ITEMS
) {
4667 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4670 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Method %u", ii
+1);
4671 foffset
= objectidentifier(tvb
, btree
, foffset
); /* Transfer Method */
4672 proto_item_set_end(bitem
, tvb
, foffset
);
4674 proto_tree_add_item(ndps_tree
, hf_doc_content
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4676 proto_item_set_end(aitem
, tvb
, foffset
);
4677 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Document Type");
4678 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4679 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_doc_types
, tvb
, foffset
, 4, number_of_items
);
4681 for (ii
= 0; ii
< number_of_items
; ii
++ )
4683 if (ii
>= NDPS_MAX_ITEMS
) {
4684 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4687 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Type %u", ii
+1);
4688 foffset
= objectidentifier(tvb
, btree
, foffset
); /* Document Type */
4689 proto_item_set_end(bitem
, tvb
, foffset
);
4691 foffset
+= align_4(tvb
, foffset
);
4692 proto_item_set_end(aitem
, tvb
, foffset
);
4693 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Document Attributes");
4694 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4695 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
4697 for (ii
= 0; ii
< number_of_items
; ii
++ )
4699 if (ii
>= NDPS_MAX_ITEMS
) {
4700 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4703 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Attribute %u", ii
+1);
4704 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
); /* Document Attributes */
4705 proto_item_set_end(bitem
, tvb
, foffset
);
4707 proto_item_set_end(aitem
, tvb
, foffset
);
4709 case 2: /* Close Job */
4710 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
4711 proto_tree_add_item(ndps_tree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4718 case 0x00000005: /* Modify Job */
4719 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4721 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
4722 proto_tree_add_item(ndps_tree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4724 proto_tree_add_item(ndps_tree
, hf_ndps_document_number
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4726 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Job Modifications");
4727 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4728 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
4730 for (ii
= 0; ii
< number_of_items
; ii
++ )
4732 if (ii
>= NDPS_MAX_ITEMS
) {
4733 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4736 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Modification %u", ii
+1);
4737 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
); /* Job Modifications */
4738 proto_item_set_end(bitem
, tvb
, foffset
);
4740 proto_item_set_end(aitem
, tvb
, foffset
);
4741 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Document Modifications");
4742 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4743 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
4745 for (ii
= 0; ii
< number_of_items
; ii
++ )
4747 if (ii
>= NDPS_MAX_ITEMS
) {
4748 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4751 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Modification %u", ii
+1);
4752 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
); /* Document Modifications */
4753 proto_item_set_end(bitem
, tvb
, foffset
);
4755 proto_item_set_end(aitem
, tvb
, foffset
);
4757 case 0x00000006: /* Cancel Job */
4758 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4760 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
4761 proto_tree_add_item(ndps_tree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4763 proto_tree_add_item(ndps_tree
, hf_ndps_document_number
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4765 /* XXX - what does this count? */
4766 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4767 proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
4769 /* Start of nameorid */
4770 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Cancel Message");
4771 foffset
= name_or_id(tvb
, atree
, foffset
);
4772 proto_item_set_end(aitem
, tvb
, foffset
);
4773 /* End of nameorid */
4774 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Retention Period");
4775 proto_tree_add_item(atree
, hf_ndps_status_flags
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4777 proto_tree_add_item(atree
, hf_ndps_attribute_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4779 proto_item_set_end(aitem
, tvb
, foffset
);
4781 case 0x00000007: /* List Object Attributes */
4782 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4784 list_attr_op
= tvb_get_ntohl(tvb
, foffset
);
4785 proto_tree_add_uint(ndps_tree
, hf_ndps_attrs_arg
, tvb
, foffset
, 4, list_attr_op
);
4787 if (list_attr_op
==0) /* Continuation */
4789 length
= tvb_get_ntohl(tvb
, foffset
);
4790 proto_tree_add_uint(ndps_tree
, hf_ndps_context_len
, tvb
, foffset
, 4, length
);
4794 proto_tree_add_item(ndps_tree
, hf_ndps_context
, tvb
, foffset
, length
, ENC_NA
);
4797 foffset
+= (length
%2);
4798 proto_tree_add_item(ndps_tree
, hf_ndps_abort_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4800 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4801 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
4803 for (ii
= 0; ii
< number_of_items
; ii
++ )
4805 if (ii
>= NDPS_MAX_ITEMS
) {
4806 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4809 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Attribute %u", ii
+1);
4810 foffset
= attribute_value(tvb
, pinfo
, atree
, foffset
);
4811 proto_item_set_end(aitem
, tvb
, foffset
);
4814 else /* Specification */
4816 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object Class");
4817 foffset
= objectidentifier(tvb
, atree
, foffset
);
4818 proto_item_set_end(aitem
, tvb
, foffset
);
4820 foffset
+= align_4(tvb
, foffset
);
4821 scope
= tvb_get_ntohl(tvb
, foffset
);
4822 proto_tree_add_uint(ndps_tree
, hf_ndps_scope
, tvb
, foffset
, 4, scope
);
4824 if (scope
!=0) /* Scope Does not equal 0 */
4826 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Selector Option");
4827 number_of_items
= tvb_get_ntohl(tvb
, foffset
); /* Start of NWDPSelector */
4828 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_options
, tvb
, foffset
, 4, number_of_items
);
4830 for (ii
= 0; ii
< number_of_items
; ii
++ )
4832 if (ii
>= NDPS_MAX_ITEMS
) {
4833 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4836 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Option %u", ii
+1);
4837 foffset
= objectidentification(tvb
, btree
, foffset
);
4838 proto_item_set_end(bitem
, tvb
, foffset
);
4840 proto_item_set_end(aitem
, tvb
, foffset
);
4841 foffset
+= align_4(tvb
, foffset
);
4842 filter_type
= tvb_get_ntohl(tvb
, foffset
);
4843 proto_tree_add_uint(ndps_tree
, hf_ndps_filter
, tvb
, foffset
, 4, filter_type
);
4846 if (filter_type
== 0 || filter_type
== 3 )
4848 foffset
= filteritem(tvb
, ndps_tree
, foffset
);
4852 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Filter Items");
4853 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
4854 expert_item
= proto_tree_add_uint(atree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
4856 for (ii
= 0; ii
< number_of_items
; ii
++ )
4858 if (ii
>= NDPS_MAX_ITEMS
) {
4859 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4862 foffset
= filteritem(tvb
, ndps_tree
, foffset
);
4864 proto_item_set_end(aitem
, tvb
, foffset
);
4867 proto_tree_add_item(ndps_tree
, hf_ndps_time_limit
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4869 proto_tree_add_item(ndps_tree
, hf_ndps_count_limit
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4870 foffset
+= 4; /* End of NWDPSelector */
4872 foffset
+= 4; /* Don't know what this is */
4873 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Requested Attributes");
4874 number_of_items
= tvb_get_ntohl(tvb
, foffset
); /* Start of NWDPObjectIdentifierSet */
4875 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_objects
, tvb
, foffset
, 4, number_of_items
);
4877 for (ii
= 0; ii
< number_of_items
; ii
++ )
4879 if (ii
>= NDPS_MAX_ITEMS
) {
4880 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
4883 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Attribute %u", ii
+1);
4884 foffset
= objectidentifier(tvb
, btree
, foffset
);
4885 proto_item_set_end(bitem
, tvb
, foffset
);
4887 proto_item_set_end(aitem
, tvb
, foffset
); /* End of NWDPObjectIdentifierSet */
4888 if (number_of_items
== 0)
4892 proto_tree_add_item(ndps_tree
, hf_ndps_operator
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4894 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
4897 case 0x00000008: /* Promote Job */
4898 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4900 /* Start of NWDPPrtContainedObjectId */
4901 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Job ID");
4902 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, atree
, foffset
, NULL
);
4903 proto_tree_add_item(atree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4905 proto_item_set_end(aitem
, tvb
, foffset
);
4906 /* End of NWDPPrtContainedObjectId */
4907 /* Start of nameorid */
4908 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Message Option");
4909 foffset
= name_or_id(tvb
, atree
, foffset
);
4910 proto_item_set_end(aitem
, tvb
, foffset
);
4911 /* End of nameorid */
4912 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
4914 case 0x00000009: /* Interrupt */
4915 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4917 job_type
= tvb_get_ntohl(tvb
, foffset
);
4918 proto_tree_add_uint(ndps_tree
, hf_interrupt_job_type
, tvb
, foffset
, 4, job_type
);
4922 /* Start of NWDPPrtContainedObjectId */
4923 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Job ID");
4924 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, atree
, foffset
, NULL
);
4925 proto_tree_add_item(atree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4927 proto_item_set_end(aitem
, tvb
, foffset
);
4928 /* End of NWDPPrtContainedObjectId */
4932 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
4934 /* Start of nameorid */
4935 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Interrupt Message Option");
4936 foffset
= name_or_id(tvb
, atree
, foffset
);
4937 proto_item_set_end(aitem
, tvb
, foffset
);
4938 /* End of nameorid */
4939 /* Start of NWDPPrtContainedObjectId */
4940 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Interrupting Job");
4941 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, atree
, foffset
, NULL
);
4942 proto_tree_add_item(atree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4944 proto_item_set_end(aitem
, tvb
, foffset
);
4945 /* End of NWDPPrtContainedObjectId */
4946 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
4948 case 0x0000000a: /* Pause */
4949 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4951 job_type
= tvb_get_ntohl(tvb
, foffset
);
4952 proto_tree_add_uint(ndps_tree
, hf_pause_job_type
, tvb
, foffset
, 4, job_type
);
4956 /* Start of NWDPPrtContainedObjectId */
4957 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Job ID");
4958 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, atree
, foffset
, NULL
);
4959 proto_tree_add_item(atree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4961 proto_item_set_end(aitem
, tvb
, foffset
);
4962 /* End of NWDPPrtContainedObjectId */
4966 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
4968 /* Start of nameorid */
4969 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Pause Message Option");
4970 foffset
= name_or_id(tvb
, atree
, foffset
);
4971 proto_item_set_end(aitem
, tvb
, foffset
);
4972 /* End of nameorid */
4973 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
4975 case 0x0000000b: /* Resume */
4976 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4978 /* Start of NWDPPrtContainedObjectId */
4979 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Job ID");
4980 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, atree
, foffset
, NULL
);
4981 proto_tree_add_item(atree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4983 proto_item_set_end(aitem
, tvb
, foffset
);
4984 /* End of NWDPPrtContainedObjectId */
4985 /* Start of nameorid */
4986 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Resume Message Option");
4987 foffset
= name_or_id(tvb
, atree
, foffset
);
4988 proto_item_set_end(aitem
, tvb
, foffset
);
4989 /* End of nameorid */
4990 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
4992 case 0x0000000c: /* Clean */
4993 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
4995 /* Start of nameorid */
4996 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Clean Message Option");
4997 foffset
= name_or_id(tvb
, atree
, foffset
);
4998 proto_item_set_end(aitem
, tvb
, foffset
);
4999 /* End of nameorid */
5000 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5002 case 0x0000000d: /* Create */
5003 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5005 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object Class");
5006 foffset
= objectidentifier(tvb
, atree
, foffset
);
5007 proto_item_set_end(aitem
, tvb
, foffset
);
5008 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object ID");
5009 foffset
= objectidentification(tvb
, atree
, foffset
);
5010 proto_item_set_end(aitem
, tvb
, foffset
);
5011 proto_tree_add_item(ndps_tree
, hf_ndps_force
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5013 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Reference Object Option");
5014 foffset
= objectidentification(tvb
, atree
, foffset
);
5015 proto_item_set_end(aitem
, tvb
, foffset
);
5016 /* Start of AttributeSet */
5017 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object Attribute");
5018 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
5019 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
5021 for (ii
= 0; ii
< number_of_items
; ii
++ )
5023 if (ii
>= NDPS_MAX_ITEMS
) {
5024 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5027 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Attribute %u", ii
+1);
5028 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
); /* Object Attribute Set */
5029 proto_item_set_end(bitem
, tvb
, foffset
);
5031 proto_item_set_end(aitem
, tvb
, foffset
);
5032 /* End of AttributeSet */
5033 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5035 case 0x0000000e: /* Delete */
5036 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5038 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object Class");
5039 foffset
= objectidentifier(tvb
, atree
, foffset
);
5040 proto_item_set_end(aitem
, tvb
, foffset
);
5041 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object ID");
5042 foffset
= objectidentification(tvb
, atree
, foffset
);
5043 proto_item_set_end(aitem
, tvb
, foffset
);
5044 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5046 case 0x0000000f: /* Disable PA */
5047 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5049 /* Start of NameorID */
5050 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Disable PA Message Option");
5051 foffset
= name_or_id(tvb
, atree
, foffset
);
5052 proto_item_set_end(aitem
, tvb
, foffset
);
5053 /* End of NameorID */
5054 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5056 case 0x00000010: /* Enable PA */
5057 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5059 /* Start of NameorID */
5060 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Enable PA Message Option");
5061 foffset
= name_or_id(tvb
, atree
, foffset
);
5062 proto_item_set_end(aitem
, tvb
, foffset
);
5063 /* End of NameorID */
5064 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5066 case 0x00000011: /* Resubmit Jobs */
5067 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5069 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
5070 foffset
= address_item(tvb
, ndps_tree
, foffset
);
5071 proto_tree_add_item(ndps_tree
, hf_resubmit_op_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5073 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Resubmit Job");
5074 number_of_items
= tvb_get_ntohl(tvb
, foffset
); /* Start of ResubmitJob Set */
5075 expert_item
= proto_tree_add_uint(atree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
5077 for (ii
= 0; ii
< number_of_items
; ii
++ )
5079 if (ii
>= NDPS_MAX_ITEMS
) {
5080 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5083 /* Start of NWDPPrtContainedObjectId */
5084 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Job ID");
5085 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, btree
, foffset
, NULL
);
5086 proto_tree_add_item(btree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5088 proto_item_set_end(bitem
, tvb
, foffset
);
5089 /* End of NWDPPrtContainedObjectId */
5090 proto_tree_add_item(atree
, hf_ndps_document_number
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5092 /* Start of AttributeSet */
5093 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Job Attributes");
5094 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
5095 expert_item
= proto_tree_add_uint(btree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items2
);
5097 for (jj
= 0; jj
< number_of_items2
; jj
++ )
5099 if (jj
>= NDPS_MAX_ITEMS
) {
5100 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5103 ctree
= proto_tree_add_subtree_format(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Attribute %u", jj
+1);
5104 foffset
= attribute_value(tvb
, pinfo
, ctree
, foffset
); /* Object Attribute Set */
5105 proto_item_set_end(citem
, tvb
, foffset
);
5107 proto_item_set_end(bitem
, tvb
, foffset
);
5108 /* End of AttributeSet */
5109 /* Start of AttributeSet */
5110 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Document Attributes");
5111 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
5112 expert_item
= proto_tree_add_uint(btree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items2
);
5114 for (jj
= 0; jj
< number_of_items2
; jj
++ )
5116 if (jj
>= NDPS_MAX_ITEMS
) {
5117 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5120 ctree
= proto_tree_add_subtree_format(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Attribute %u", jj
+1);
5121 foffset
= attribute_value(tvb
, pinfo
, ctree
, foffset
); /* Object Attribute Set */
5122 proto_item_set_end(citem
, tvb
, foffset
);
5124 proto_item_set_end(bitem
, tvb
, foffset
);
5125 /* End of AttributeSet */
5127 proto_item_set_end(aitem
, tvb
, foffset
); /* End of ResubmitJob Set */
5128 /* Start of NameorID */
5129 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Resubmit Message Option");
5130 foffset
= name_or_id(tvb
, atree
, foffset
);
5131 proto_item_set_end(aitem
, tvb
, foffset
);
5132 /* End of NameorID */
5133 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5135 case 0x00000012: /* Set */
5136 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5138 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object Class");
5139 foffset
= objectidentifier(tvb
, atree
, foffset
);
5140 proto_item_set_end(aitem
, tvb
, foffset
);
5141 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object ID");
5142 foffset
= objectidentification(tvb
, atree
, foffset
);
5143 /* Start of AttributeSet */
5144 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Attribute Modifications");
5145 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
5146 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
5148 for (ii
= 0; ii
< number_of_items
; ii
++ )
5150 if (ii
>= NDPS_MAX_ITEMS
) {
5151 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5154 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Modification `%d", ii
+1);
5155 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
); /* Object Attribute Set */
5156 proto_item_set_end(bitem
, tvb
, foffset
);
5158 proto_item_set_end(aitem
, tvb
, foffset
);
5159 /* End of AttributeSet */
5160 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5162 case 0x00000013: /* Shutdown PA */
5163 case 0x0000001e: /* Shutdown PSM */
5164 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5166 proto_tree_add_item(ndps_tree
, hf_shutdown_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5168 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
5169 /* Start of NameorID */
5170 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Shutdown Message Option");
5171 foffset
= name_or_id(tvb
, atree
, foffset
);
5172 proto_item_set_end(aitem
, tvb
, foffset
);
5173 /* End of NameorID */
5174 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5176 case 0x00000014: /* Startup PA */
5177 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5179 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
5180 /* Start of NameorID */
5181 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Startup Message Option");
5182 foffset
= name_or_id(tvb
, atree
, foffset
);
5183 proto_item_set_end(aitem
, tvb
, foffset
);
5184 /* End of NameorID */
5185 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5187 case 0x00000015: /* Reorder Job */
5188 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5190 /* Start of NWDPPrtContainedObjectId */
5191 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Job Identification");
5192 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, atree
, foffset
, NULL
);
5193 proto_tree_add_item(atree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5195 proto_item_set_end(aitem
, tvb
, foffset
);
5196 /* End of NWDPPrtContainedObjectId */
5197 /* Start of NWDPPrtContainedObjectId */
5198 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Reference Job ID");
5199 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, atree
, foffset
, NULL
);
5200 proto_tree_add_item(atree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5202 proto_item_set_end(aitem
, tvb
, foffset
);
5203 /* End of NWDPPrtContainedObjectId */
5204 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5206 case 0x00000016: /* Pause PA */
5207 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5209 /* Start of NameorID */
5210 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Pause Message Option");
5211 foffset
= name_or_id(tvb
, atree
, foffset
);
5212 proto_item_set_end(aitem
, tvb
, foffset
);
5213 /* End of NameorID */
5214 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5216 case 0x00000017: /* Resume PA */
5217 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5219 /* Start of NameorID */
5220 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Resume Message Option");
5221 foffset
= name_or_id(tvb
, atree
, foffset
);
5222 proto_item_set_end(aitem
, tvb
, foffset
);
5223 /* End of NameorID */
5224 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5226 case 0x00000018: /* Transfer Data */
5227 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5229 proto_tree_add_item(ndps_tree
, hf_get_status_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5231 proto_tree_add_item(ndps_tree
, hf_ndps_data
, tvb
, foffset
+4, tvb_get_ntohl(tvb
, foffset
), ENC_NA
);
5233 case 0x00000019: /* Device Control */
5234 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5236 /* Start of Object Identifier */
5237 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Operation ID");
5238 foffset
= objectidentifier(tvb
, atree
, foffset
);
5239 proto_item_set_end(aitem
, tvb
, foffset
);
5240 /* End of Object Identifier */
5241 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5243 case 0x0000001a: /* Add Event Profile */
5244 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5246 /* Start of Eventhandling2 */
5247 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5249 proto_tree_add_item(ndps_tree
, hf_ndps_persistence
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5251 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
5252 foffset
= ndps_string(tvb
, hf_ndps_supplier_name
, ndps_tree
, foffset
, NULL
);
5253 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5255 /* Start of NameorID */
5256 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
5257 foffset
= name_or_id(tvb
, atree
, foffset
);
5258 foffset
+= align_4(tvb
, foffset
);
5259 proto_item_set_end(aitem
, tvb
, foffset
);
5260 /* End of NameorID */
5261 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Delivery Address");
5262 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
5263 expert_item
= proto_tree_add_uint(atree
, hf_ndps_delivery_add_count
, tvb
, foffset
, 4, number_of_items
);
5265 for (ii
= 0; ii
< number_of_items
; ii
++ )
5267 if (ii
>= NDPS_MAX_ITEMS
) {
5268 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5271 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Address %u", ii
+1);
5272 foffset
= address_item(tvb
, btree
, foffset
);
5273 proto_item_set_end(bitem
, tvb
, foffset
);
5275 proto_item_set_end(aitem
, tvb
, foffset
);
5276 foffset
= event_object_set(tvb
, pinfo
, ndps_tree
, foffset
);
5277 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
5279 case 0x0000001b: /* Remove Event Profile */
5280 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5282 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5285 case 0x0000001c: /* Modify Event Profile */
5286 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5288 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5290 proto_tree_add_item_ret_uint(ndps_tree
, hf_ndps_supplier_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
, &supplier_flag
);
5294 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Supplier ID");
5295 length
= tvb_get_ntohl(tvb
, foffset
);
5299 proto_tree_add_item(atree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
5301 tvb_ensure_bytes_exist(tvb
, foffset
, length
);
5303 proto_item_set_end(aitem
, tvb
, foffset
);
5305 proto_tree_add_item_ret_boolean(ndps_tree
, hf_ndps_language_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
, &language_flag
);
5309 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5312 proto_tree_add_item_ret_boolean(ndps_tree
, hf_ndps_method_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
, &method_flag
);
5316 /* Start of NameorID */
5317 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
5318 foffset
= name_or_id(tvb
, atree
, foffset
);
5319 proto_item_set_end(aitem
, tvb
, foffset
);
5320 /* End of NameorID */
5322 proto_tree_add_item_ret_boolean(ndps_tree
, hf_ndps_delivery_address_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
, &delivery_address_flag
);
5324 if (delivery_address_flag
)
5326 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Delivery Address");
5327 foffset
= print_address(tvb
, atree
, foffset
);
5328 proto_item_set_end(aitem
, tvb
, foffset
);
5330 foffset
= event_object_set(tvb
, pinfo
, ndps_tree
, foffset
);
5332 case 0x0000001d: /* List Event Profiles */
5333 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5335 profiles_type
= tvb_get_ntohl(tvb
, foffset
);
5336 proto_tree_add_uint(ndps_tree
, hf_ndps_list_profiles_type
, tvb
, foffset
, 4, profiles_type
);
5338 if (profiles_type
==0) /* Spec */
5340 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
5341 profiles_choice_type
= tvb_get_ntohl(tvb
, foffset
);
5342 proto_tree_add_uint(ndps_tree
, hf_ndps_list_profiles_choice_type
, tvb
, foffset
, 4, profiles_choice_type
);
5344 if (profiles_choice_type
==0) /* Choice */
5346 foffset
= cardinal_seq(tvb
, pinfo
, ndps_tree
, foffset
);
5350 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Consumer");
5351 foffset
= qualifiedname(tvb
, atree
, foffset
);
5352 proto_item_set_end(aitem
, tvb
, foffset
);
5353 /* Start of NameorID */
5354 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
5355 foffset
= name_or_id(tvb
, atree
, foffset
);
5356 /* End of NameorID */
5357 proto_tree_add_item(atree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5359 proto_item_set_end(aitem
, tvb
, foffset
);
5361 proto_tree_add_item(ndps_tree
, hf_ndps_list_profiles_result_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5363 /* Start of integeroption */
5364 integer_type_flag
= tvb_get_ntohl(tvb
, foffset
);
5365 proto_tree_add_uint(ndps_tree
, hf_ndps_integer_type_flag
, tvb
, foffset
, 4, integer_type_flag
);
5367 if (integer_type_flag
!=0)
5369 proto_tree_add_item(ndps_tree
, hf_ndps_integer_type_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5372 /* End of integeroption */
5376 length
= tvb_get_ntohl(tvb
, foffset
);
5377 proto_tree_add_uint(ndps_tree
, hf_ndps_context_len
, tvb
, foffset
, 4, length
);
5381 proto_tree_add_item(ndps_tree
, hf_ndps_context
, tvb
, foffset
, length
, ENC_NA
);
5384 foffset
+= (length
%2);
5385 proto_tree_add_item(ndps_tree
, hf_ndps_abort_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5389 case 0x0000001f: /* Cancel PSM Shutdown */
5390 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5392 /* Start of NameorID */
5393 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Cancel Shutdown Message Option");
5394 foffset
= name_or_id(tvb
, atree
, foffset
);
5395 proto_item_set_end(aitem
, tvb
, foffset
);
5396 /* End of NameorID */
5397 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5399 case 0x00000020: /* Set Printer DS Information */
5400 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5402 proto_tree_add_item(ndps_tree
, hf_ndps_ds_info_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5404 foffset
= ndps_string(tvb
, hf_ndps_printer_name
, ndps_tree
, foffset
, NULL
);
5405 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "DS Object Name");
5406 foffset
= qualifiedname(tvb
, atree
, foffset
);
5407 proto_item_set_end(aitem
, tvb
, foffset
);
5409 case 0x00000021: /* Clean User Jobs */
5410 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5412 /* Start of NameorID */
5413 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Clean Message Option");
5414 foffset
= name_or_id(tvb
, atree
, foffset
);
5415 proto_item_set_end(aitem
, tvb
, foffset
);
5416 /* End of NameorID */
5417 foffset
= commonarguments(tvb
, pinfo
, ndps_tree
, foffset
);
5419 case 0x00000022: /* Map GUID to NDS Name */
5420 length
= tvb_get_ntohl(tvb
, foffset
);
5424 proto_tree_add_item(ndps_tree
, hf_ndps_guid
, tvb
, foffset
, length
, ENC_NA
);
5428 case 0x00000023: /* AddEventProfile2 */
5429 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5431 /* Start of Eventhandling2 */
5432 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5434 proto_tree_add_item(ndps_tree
, hf_ndps_persistence
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5436 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Consumer Name");
5437 foffset
= qualifiedname(tvb
, atree
, foffset
);
5438 proto_item_set_end(aitem
, tvb
, foffset
);
5439 foffset
= ndps_string(tvb
, hf_ndps_supplier_name
, ndps_tree
, foffset
, NULL
);
5440 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5442 /* Start of NameorID */
5443 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
5444 foffset
= name_or_id(tvb
, atree
, foffset
);
5445 foffset
+= align_4(tvb
, foffset
);
5446 proto_item_set_end(aitem
, tvb
, foffset
);
5447 /* End of NameorID */
5448 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Delivery Address");
5449 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
5450 expert_item
= proto_tree_add_uint(atree
, hf_ndps_delivery_add_count
, tvb
, foffset
, 4, number_of_items
);
5452 for (ii
= 0; ii
< number_of_items
; ii
++ )
5454 if (ii
>= NDPS_MAX_ITEMS
) {
5455 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5458 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Address %u", ii
+1);
5459 foffset
= address_item(tvb
, btree
, foffset
);
5460 proto_item_set_end(bitem
, tvb
, foffset
);
5462 proto_item_set_end(aitem
, tvb
, foffset
);
5463 foffset
= event_object_set(tvb
, pinfo
, ndps_tree
, foffset
);
5464 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Account");
5465 foffset
= qualifiedname(tvb
, atree
, foffset
);
5466 proto_item_set_end(aitem
, tvb
, foffset
);
5467 /* Start of object identifier set */
5468 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Notify Attributes");
5469 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
5470 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
5472 for (ii
= 0; ii
< number_of_items
; ii
++ )
5474 if (ii
>= NDPS_MAX_ITEMS
) {
5475 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5478 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Attribute %u", ii
+1);
5479 foffset
= objectidentifier(tvb
, btree
, foffset
);
5480 proto_item_set_end(bitem
, tvb
, foffset
);
5482 proto_item_set_end(aitem
, tvb
, foffset
);
5483 /* End of object identifier set */
5484 proto_tree_add_item(ndps_tree
, hf_notify_time_interval
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5486 proto_tree_add_item(ndps_tree
, hf_notify_sequence_number
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5488 proto_tree_add_item(ndps_tree
, hf_notify_lease_exp_time
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5490 foffset
= ndps_string(tvb
, hf_notify_printer_uri
, ndps_tree
, foffset
, NULL
);
5491 /* End of Eventhandling2 */
5493 case 0x00000024: /* ListEventProfiles2 */
5494 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5496 profiles_type
= tvb_get_ntohl(tvb
, foffset
);
5497 proto_tree_add_uint(ndps_tree
, hf_ndps_list_profiles_type
, tvb
, foffset
, 4, profiles_type
);
5499 if (profiles_type
==0) /* Spec */
5501 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Supplier Alias");
5502 foffset
= qualifiedname(tvb
, atree
, foffset
);
5503 proto_item_set_end(aitem
, tvb
, foffset
);
5504 profiles_choice_type
= tvb_get_ntohl(tvb
, foffset
);
5505 proto_tree_add_uint(ndps_tree
, hf_ndps_list_profiles_choice_type
, tvb
, foffset
, 4, profiles_choice_type
);
5507 if (profiles_choice_type
==0) /* Choice */
5509 foffset
= cardinal_seq(tvb
, pinfo
, ndps_tree
, foffset
);
5513 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Consumer");
5514 foffset
= qualifiedname(tvb
, atree
, foffset
);
5515 proto_item_set_end(aitem
, tvb
, foffset
);
5516 /* Start of NameorID */
5517 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
5518 foffset
= name_or_id(tvb
, atree
, foffset
);
5519 proto_item_set_end(aitem
, tvb
, foffset
);
5520 /* End of NameorID */
5521 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5524 proto_tree_add_item(ndps_tree
, hf_ndps_list_profiles_result_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5526 /* Start of integeroption */
5527 integer_type_flag
= tvb_get_ntohl(tvb
, foffset
);
5528 proto_tree_add_uint(ndps_tree
, hf_ndps_integer_type_flag
, tvb
, foffset
, 4, integer_type_flag
);
5530 if (integer_type_flag
!=0)
5532 proto_tree_add_item(ndps_tree
, hf_ndps_integer_type_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5535 /* End of integeroption */
5539 length
= tvb_get_ntohl(tvb
, foffset
);
5540 proto_tree_add_uint(ndps_tree
, hf_ndps_context_len
, tvb
, foffset
, 4, length
);
5544 proto_tree_add_item(ndps_tree
, hf_ndps_context
, tvb
, foffset
, length
, ENC_NA
);
5547 foffset
+= (length
%2);
5548 proto_tree_add_item(ndps_tree
, hf_ndps_abort_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5556 case 0x060977: /* Broker */
5559 case 0x00000001: /* Bind */
5560 foffset
= credentials(tvb
, pinfo
, ndps_tree
, foffset
);
5561 proto_tree_add_item(ndps_tree
, hf_ndps_retrieve_restrictions
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5563 number_of_items
=tvb_get_ntohl(tvb
, foffset
);
5564 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_bind_security_option_count
, tvb
, foffset
, 4, number_of_items
);
5566 for (ii
= 0; ii
< number_of_items
; ii
++ )
5568 if (ii
>= NDPS_MAX_ITEMS
) {
5569 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5572 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Security %u", ii
+1);
5573 length
= tvb_get_ntohl(tvb
, foffset
);
5577 proto_tree_add_item(atree
, hf_bind_security
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
5579 proto_item_set_end(aitem
, tvb
, foffset
);
5582 case 0x00000002: /* Unbind */
5584 case 0x00000003: /* List Services */
5585 proto_tree_add_item(ndps_tree
, hf_ndps_list_services_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5588 case 0x00000004: /* Enable Service */
5589 proto_tree_add_item(ndps_tree
, hf_ndps_service_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5591 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Parameters");
5592 number_of_items
=tvb_get_ntohl(tvb
, foffset
);
5593 expert_item
= proto_tree_add_uint(atree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
5595 for (ii
= 0; ii
< number_of_items
; ii
++ )
5597 if (ii
>= NDPS_MAX_ITEMS
) {
5598 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5601 length
= tvb_get_ntohl(tvb
, foffset
);
5605 proto_tree_add_item(atree
, hf_ndps_item_bytes
, tvb
, foffset
, length
, ENC_NA
);
5609 proto_item_set_end(aitem
, tvb
, foffset
);
5611 case 0x00000005: /* Disable Service */
5612 proto_tree_add_item(ndps_tree
, hf_ndps_list_services_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5615 case 0x00000006: /* Down Broker */
5616 case 0x00000007: /* Get Broker NDS Object Name */
5617 case 0x00000008: /* Get Broker Session Information */
5622 case 0x060978: /* Registry */
5625 case 0x00000001: /* Bind */
5626 foffset
= credentials(tvb
, pinfo
, ndps_tree
, foffset
);
5627 proto_tree_add_item(ndps_tree
, hf_ndps_retrieve_restrictions
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5629 number_of_items
=tvb_get_ntohl(tvb
, foffset
);
5630 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_bind_security_option_count
, tvb
, foffset
, 4, number_of_items
);
5632 for (ii
= 0; ii
< number_of_items
; ii
++ )
5634 if (ii
>= NDPS_MAX_ITEMS
) {
5635 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5638 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Security %d", ii
+1);
5639 length
= tvb_get_ntohl(tvb
, foffset
);
5643 proto_tree_add_item(atree
, hf_bind_security
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
5645 proto_item_set_end(aitem
, tvb
, foffset
);
5648 case 0x00000002: /* Unbind */
5650 case 0x00000003: /* Register Server */
5651 foffset
= server_entry(tvb
, pinfo
, ndps_tree
, foffset
);
5653 case 0x00000004: /* Deregister Server */
5654 case 0x00000006: /* Deregister Registry */
5655 case 0x0000000b: /* Get Registry NDS Object Name */
5656 case 0x0000000c: /* Get Registry Session Information */
5659 case 0x00000005: /* Register Registry */
5660 foffset
= ndps_string(tvb
, hf_ndps_registry_name
, ndps_tree
, foffset
, NULL
);
5661 foffset
= print_address(tvb
, ndps_tree
, foffset
);
5663 case 0x00000007: /* Registry Update */
5664 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Add");
5665 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
5666 expert_item
= proto_tree_add_uint(atree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
5668 for (ii
= 0; ii
< number_of_items
; ii
++ )
5670 if (ii
>= NDPS_MAX_ITEMS
) {
5671 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5674 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Entry %u", ii
+1);
5675 foffset
= server_entry(tvb
, pinfo
, btree
, foffset
);
5676 proto_item_set_end(bitem
, tvb
, foffset
);
5678 proto_item_set_end(aitem
, tvb
, foffset
);
5679 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Remove");
5680 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
5681 expert_item
= proto_tree_add_uint(atree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
5683 for (ii
= 0; ii
< number_of_items
; ii
++ )
5685 if (ii
>= NDPS_MAX_ITEMS
) {
5686 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5689 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Entry %u", ii
+1);
5690 foffset
= server_entry(tvb
, pinfo
, btree
, foffset
);
5691 proto_item_set_end(bitem
, tvb
, foffset
);
5693 proto_item_set_end(aitem
, tvb
, foffset
);
5695 case 0x00000008: /* List Local Servers */
5696 case 0x00000009: /* List Servers */
5697 case 0x0000000a: /* List Known Registries */
5698 local_servers_type
= tvb_get_ntohl(tvb
, foffset
);
5699 proto_tree_add_uint(ndps_tree
, hf_ndps_list_local_servers_type
, tvb
, foffset
, 4, local_servers_type
);
5701 if (local_servers_type
==0)
5703 /* Start of integeroption */
5704 integer_type_flag
= tvb_get_ntohl(tvb
, foffset
);
5705 proto_tree_add_uint(ndps_tree
, hf_ndps_integer_type_flag
, tvb
, foffset
, 4, integer_type_flag
);
5707 if (integer_type_flag
!=0)
5709 proto_tree_add_item(ndps_tree
, hf_ndps_integer_type_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5712 /* End of integeroption */
5716 length
= tvb_get_ntohl(tvb
, foffset
);
5717 proto_tree_add_uint(ndps_tree
, hf_ndps_context_len
, tvb
, foffset
, 4, length
);
5721 proto_tree_add_item(ndps_tree
, hf_ndps_context
, tvb
, foffset
, length
, ENC_NA
);
5724 foffset
+= (length
%2);
5725 proto_tree_add_item(ndps_tree
, hf_ndps_abort_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5733 case 0x060979: /* Notify */
5736 case 0x00000001: /* Notify Bind */
5737 foffset
= credentials(tvb
, pinfo
, ndps_tree
, foffset
);
5738 proto_tree_add_item(ndps_tree
, hf_ndps_retrieve_restrictions
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5740 number_of_items
=tvb_get_ntohl(tvb
, foffset
);
5741 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
5743 for (ii
= 0; ii
< number_of_items
; ii
++ )
5745 if (ii
>= NDPS_MAX_ITEMS
) {
5746 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5749 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Security %d", ii
+1);
5750 length
= tvb_get_ntohl(tvb
, foffset
);
5754 proto_tree_add_item(atree
, hf_bind_security
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
5756 proto_item_set_end(aitem
, tvb
, foffset
);
5759 case 0x00000002: /* Notify Unbind */
5760 case 0x0000000a: /* List Supported Languages */
5761 case 0x00000010: /* Get Notify NDS Object Name */
5762 case 0x00000011: /* Get Notify Session Information */
5765 case 0x00000003: /* Register Supplier */
5766 foffset
= ndps_string(tvb
, hf_ndps_supplier_name
, ndps_tree
, foffset
, NULL
);
5767 /* Start of QualifiedName Set*/
5768 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
5769 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
5771 for (ii
= 0; ii
< number_of_items
; ii
++ )
5773 if (ii
>= NDPS_MAX_ITEMS
) {
5774 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
5777 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Supplier Alias %u", ii
+1);
5778 foffset
= qualifiedname(tvb
, atree
, foffset
);
5779 proto_item_set_end(aitem
, tvb
, foffset
);
5781 /* End of QualifiedName Set*/
5783 case 0x00000004: /* Deregister Supplier */
5784 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5787 case 0x00000005: /* Add Profile */
5788 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5790 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Supplier Alias");
5791 foffset
= qualifiedname(tvb
, atree
, foffset
);
5792 proto_item_set_end(aitem
, tvb
, foffset
);
5793 /* Start of Eventhandling */
5794 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5796 proto_tree_add_item(ndps_tree
, hf_ndps_persistence
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5798 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Consumer Name");
5799 foffset
= qualifiedname(tvb
, atree
, foffset
);
5800 proto_item_set_end(aitem
, tvb
, foffset
);
5801 length
= tvb_get_ntohl(tvb
, foffset
);
5805 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
5808 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5810 /* Start of NameorID */
5811 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
5812 foffset
= name_or_id(tvb
, atree
, foffset
);
5813 proto_item_set_end(aitem
, tvb
, foffset
);
5814 /* End of NameorID */
5815 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
5816 proto_tree_add_uint(ndps_tree
, hf_ndps_delivery_add_count
, tvb
, foffset
, 4, number_of_items
);
5818 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Delivery Addresses");
5819 for (ii
= 0; ii
< number_of_items
; ii
++ )
5821 if (ii
>= NDPS_MAX_ITEMS
) {
5822 expert_add_info(pinfo
, aitem
, &ei_ndps_truncated
);
5825 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Address %d", ii
+1);
5826 foffset
= address_item(tvb
, btree
, foffset
);
5827 proto_item_set_end(bitem
, tvb
, foffset
);
5829 proto_item_set_end(aitem
, tvb
, foffset
);
5830 foffset
= event_object_set(tvb
, pinfo
, ndps_tree
, foffset
);
5831 /* End of Eventhandling */
5833 case 0x00000006: /* Remove Profile */
5834 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5836 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5839 case 0x00000007: /* Modify Profile */
5840 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5842 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5844 proto_tree_add_item_ret_uint(ndps_tree
, hf_ndps_supplier_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
, &supplier_flag
);
5848 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Supplier ID");
5849 length
= tvb_get_ntohl(tvb
, foffset
);
5853 proto_tree_add_item(atree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
5855 tvb_ensure_bytes_exist(tvb
, foffset
, length
);
5857 proto_item_set_end(aitem
, tvb
, foffset
);
5859 proto_tree_add_item_ret_boolean(ndps_tree
, hf_ndps_language_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
, &language_flag
);
5863 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5866 proto_tree_add_item_ret_boolean(ndps_tree
, hf_ndps_method_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
, &method_flag
);
5870 /* Start of NameorID */
5871 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
5872 foffset
= name_or_id(tvb
, atree
, foffset
);
5873 proto_item_set_end(aitem
, tvb
, foffset
);
5874 /* End of NameorID */
5876 proto_tree_add_item_ret_boolean(ndps_tree
, hf_ndps_delivery_address_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
, &delivery_address_flag
);
5878 if (delivery_address_flag
)
5880 foffset
= print_address(tvb
, ndps_tree
, foffset
);
5882 foffset
= event_object_set(tvb
, pinfo
, ndps_tree
, foffset
);
5884 case 0x00000008: /* List Profiles */
5885 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5887 profiles_type
= tvb_get_ntohl(tvb
, foffset
);
5888 proto_tree_add_uint(ndps_tree
, hf_ndps_list_profiles_type
, tvb
, foffset
, 4, profiles_type
);
5890 if (profiles_type
==0) /* Spec */
5892 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Supplier Alias");
5893 foffset
= qualifiedname(tvb
, atree
, foffset
);
5894 profiles_choice_type
= tvb_get_ntohl(tvb
, foffset
);
5895 proto_tree_add_uint(atree
, hf_ndps_list_profiles_choice_type
, tvb
, foffset
, 4, profiles_choice_type
);
5897 proto_item_set_end(aitem
, tvb
, foffset
);
5898 if (profiles_choice_type
==0) /* Choice */
5900 foffset
= cardinal_seq(tvb
, pinfo
, ndps_tree
, foffset
);
5904 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Consumer");
5905 foffset
= qualifiedname(tvb
, atree
, foffset
);
5906 proto_item_set_end(aitem
, tvb
, foffset
);
5907 /* Start of NameorID */
5908 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
5909 foffset
= name_or_id(tvb
, atree
, foffset
);
5910 /* End of NameorID */
5911 proto_tree_add_item(atree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5913 proto_item_set_end(aitem
, tvb
, foffset
);
5915 proto_tree_add_item(ndps_tree
, hf_ndps_list_profiles_result_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5917 /* Start of integeroption */
5918 integer_type_flag
= tvb_get_ntohl(tvb
, foffset
);
5919 proto_tree_add_uint(ndps_tree
, hf_ndps_integer_type_flag
, tvb
, foffset
, 4, integer_type_flag
);
5921 if (integer_type_flag
!=0)
5923 proto_tree_add_item(ndps_tree
, hf_ndps_integer_type_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5926 /* End of integeroption */
5930 length
= tvb_get_ntohl(tvb
, foffset
);
5931 proto_tree_add_uint(ndps_tree
, hf_ndps_context_len
, tvb
, foffset
, 4, length
);
5935 proto_tree_add_item(ndps_tree
, hf_ndps_context
, tvb
, foffset
, length
, ENC_NA
);
5938 foffset
+= (length
%2);
5939 proto_tree_add_item(ndps_tree
, hf_ndps_abort_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5943 case 0x00000009: /* Report Event */
5944 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5946 /* Start of ReportEventItemSet */
5947 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
5948 proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
5950 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Event Items");
5951 for (ii
= 0; ii
< number_of_items
; ii
++ )
5953 if (ii
>= NDPS_MAX_ITEMS
) {
5954 expert_add_info(pinfo
, aitem
, &ei_ndps_truncated
);
5957 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Item %d", ii
+1);
5958 /* Start of ReportEventItem */
5959 proto_tree_add_item(btree
, hf_ndps_event_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5961 ctree
= proto_tree_add_subtree(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Containing Class");
5962 foffset
= objectidentifier(tvb
, ctree
, foffset
);
5963 proto_item_set_end(citem
, tvb
, foffset
);
5964 ctree
= proto_tree_add_subtree(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Containing Object");
5965 foffset
= objectidentification(tvb
, ctree
, foffset
);
5966 proto_item_set_end(citem
, tvb
, foffset
);
5967 ctree
= proto_tree_add_subtree(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Filter Class");
5968 foffset
= objectidentifier(tvb
, ctree
, foffset
);
5969 ctree
= proto_tree_add_subtree(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Object Class");
5970 foffset
= objectidentifier(tvb
, ctree
, foffset
);
5971 proto_item_set_end(citem
, tvb
, foffset
);
5972 ctree
= proto_tree_add_subtree(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Object ID");
5973 foffset
= objectidentification(tvb
, ctree
, foffset
);
5974 proto_item_set_end(citem
, tvb
, foffset
);
5975 ctree
= proto_tree_add_subtree(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Event Object ID");
5976 foffset
= objectidentifier(tvb
, ctree
, foffset
);
5977 proto_item_set_end(citem
, tvb
, foffset
);
5978 /* Start of AttributeSet */
5979 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
5980 proto_tree_add_uint(btree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
5982 ctree
= proto_tree_add_subtree(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Attribute Modifications");
5983 for (jj
= 0; jj
< number_of_items
; jj
++ )
5985 if (jj
>= NDPS_MAX_ITEMS
) {
5986 expert_add_info(pinfo
, citem
, &ei_ndps_truncated
);
5989 dtree
= proto_tree_add_subtree_format(ctree
, tvb
, foffset
, -1, ett_ndps
, &ditem
, "Modification %d", jj
+1);
5990 foffset
= attribute_value(tvb
, pinfo
, dtree
, foffset
); /* Object Attribute Set */
5991 proto_item_set_end(ditem
, tvb
, foffset
);
5993 proto_item_set_end(citem
, tvb
, foffset
);
5994 /* End of AttributeSet */
5995 foffset
= ndps_string(tvb
, hf_ndps_message
, btree
, foffset
, NULL
);
5996 proto_tree_add_item(btree
, hf_time
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
5998 proto_item_set_end(bitem
, tvb
, foffset
);
5999 /* End of ReportEventItem */
6001 proto_item_set_end(aitem
, tvb
, foffset
);
6002 /* End of ReportEventItemSet */
6004 case 0x0000000b: /* Report Notification */
6005 /* Start of DestinationSet */
6006 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
6007 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_destinations
, tvb
, foffset
, 4, number_of_items
);
6009 for (ii
= 0; ii
< number_of_items
; ii
++ )
6011 if (ii
>= NDPS_MAX_ITEMS
) {
6012 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
6015 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Destination %d", ii
+1);
6016 /* Start of Destination */
6017 /* Start of NameorID */
6018 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Method ID");
6019 foffset
= name_or_id(tvb
, btree
, foffset
);
6020 proto_item_set_end(bitem
, tvb
, foffset
);
6021 /* End of NameorID */
6022 /* Start of NotifyDeliveryAddr */
6023 proto_tree_add_item(atree
, hf_address_len
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6025 foffset
= print_address(tvb
, atree
, foffset
);
6026 /* End of NotifyDeliveryAddr */
6027 proto_item_set_end(aitem
, tvb
, foffset
);
6028 /* End of Destination */
6030 /* End of DestinationSet */
6031 foffset
= ndps_string(tvb
, hf_ndps_supplier_name
, ndps_tree
, foffset
, NULL
);
6032 proto_tree_add_item(ndps_tree
, hf_ndps_event_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6034 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Containing Class");
6035 foffset
= objectidentifier(tvb
, atree
, foffset
);
6036 proto_item_set_end(aitem
, tvb
, foffset
);
6037 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Containing Object");
6038 foffset
= objectidentification(tvb
, atree
, foffset
);
6039 proto_item_set_end(aitem
, tvb
, foffset
);
6040 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Filter Class");
6041 foffset
= objectidentifier(tvb
, atree
, foffset
);
6042 proto_item_set_end(aitem
, tvb
, foffset
);
6043 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object Class");
6044 foffset
= objectidentifier(tvb
, atree
, foffset
);
6045 proto_item_set_end(aitem
, tvb
, foffset
);
6046 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object ID");
6047 foffset
= objectidentification(tvb
, atree
, foffset
);
6048 proto_item_set_end(aitem
, tvb
, foffset
);
6049 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Event Object ID");
6050 foffset
= objectidentifier(tvb
, atree
, foffset
);
6051 proto_item_set_end(aitem
, tvb
, foffset
);
6052 /* Start of AttributeSet */
6053 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
6054 proto_tree_add_uint(ndps_tree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
6056 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Attributes");
6057 for (ii
= 0; ii
< number_of_items
; ii
++ )
6059 if (ii
>= NDPS_MAX_ITEMS
) {
6060 expert_add_info(pinfo
, aitem
, &ei_ndps_truncated
);
6063 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Attribute %d", ii
+1);
6064 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
);
6065 proto_item_set_end(bitem
, tvb
, foffset
);
6067 proto_item_set_end(aitem
, tvb
, foffset
);
6068 /* End of AttributeSet */
6069 foffset
= ndps_string(tvb
, hf_ndps_message
, ndps_tree
, foffset
, NULL
);
6070 proto_tree_add_item(ndps_tree
, hf_time
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6072 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Account");
6073 foffset
= qualifiedname(tvb
, atree
, foffset
);
6074 proto_item_set_end(aitem
, tvb
, foffset
);
6076 case 0x0000000c: /* Add Delivery Method */
6077 foffset
= ndps_string(tvb
, hf_ndps_file_name
, ndps_tree
, foffset
, NULL
);
6079 case 0x0000000d: /* Remove Delivery Method */
6080 /* Start of NameorID */
6081 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
6082 foffset
= name_or_id(tvb
, atree
, foffset
);
6083 proto_item_set_end(aitem
, tvb
, foffset
);
6084 /* End of NameorID */
6086 case 0x0000000e: /* List Delivery Methods */
6087 cred_type
= tvb_get_ntohl(tvb
, foffset
);
6088 proto_tree_add_item(ndps_tree
, hf_delivery_method_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6092 case 0: /* Specification */
6093 /* Start of integeroption */
6094 integer_type_flag
= tvb_get_ntohl(tvb
, foffset
);
6095 proto_tree_add_uint(ndps_tree
, hf_ndps_integer_type_flag
, tvb
, foffset
, 4, integer_type_flag
);
6097 if (integer_type_flag
!=0)
6099 proto_tree_add_item(ndps_tree
, hf_ndps_integer_type_value
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6102 /* End of integeroption */
6103 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6106 case 1: /* Continuation */
6107 length
= tvb_get_ntohl(tvb
, foffset
);
6108 proto_tree_add_uint(ndps_tree
, hf_ndps_context_len
, tvb
, foffset
, 4, length
);
6112 proto_tree_add_item(ndps_tree
, hf_ndps_context
, tvb
, foffset
, length
, ENC_NA
);
6115 foffset
+= (length
%2);
6116 proto_tree_add_item(ndps_tree
, hf_ndps_abort_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6123 case 0x0000000f: /* Get Delivery Method Information */
6124 /* Start of NameorID */
6125 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
6126 foffset
= name_or_id(tvb
, atree
, foffset
);
6127 proto_item_set_end(aitem
, tvb
, foffset
);
6128 /* End of NameorID */
6129 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6136 case 0x06097a: /* Resman */
6139 case 0x00000001: /* Bind */
6140 foffset
= credentials(tvb
, pinfo
, ndps_tree
, foffset
);
6141 proto_tree_add_item(ndps_tree
, hf_ndps_retrieve_restrictions
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6143 number_of_items
=tvb_get_ntohl(tvb
, foffset
);
6144 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_bind_security_option_count
, tvb
, foffset
, 4, number_of_items
);
6146 for (ii
= 0; ii
< number_of_items
; ii
++ )
6148 if (ii
>= NDPS_MAX_ITEMS
) {
6149 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
6152 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Security %d", ii
+1);
6153 length
= tvb_get_ntohl(tvb
, foffset
);
6157 proto_tree_add_item(atree
, hf_bind_security
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
6159 proto_item_set_end(aitem
, tvb
, foffset
);
6162 case 0x00000002: /* Unbind */
6163 case 0x00000008: /* Get Resource Manager NDS Object Name */
6164 case 0x00000009: /* Get Resource Manager Session Information */
6167 case 0x00000003: /* Add Resource File */
6168 proto_tree_add_item(ndps_tree
, hf_packet_count
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6170 proto_tree_add_item(ndps_tree
, hf_last_packet_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6172 proto_tree_add_item(ndps_tree
, hf_file_timestamp
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6174 foffset
= res_add_input_data(tvb
, ndps_tree
, foffset
);
6175 number_of_items
=tvb_get_ntohl(tvb
, foffset
);
6176 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
6178 for (ii
= 0; ii
< number_of_items
; ii
++ )
6180 if (ii
>= NDPS_MAX_ITEMS
) {
6181 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
6184 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Item %d", ii
+1);
6185 length
=tvb_get_ntohl(tvb
, foffset
);
6186 length_remaining
= tvb_reported_length_remaining(tvb
, foffset
);
6187 if(length_remaining
== -1 || (uint32_t) length_remaining
< length
)
6191 proto_tree_add_item(atree
, hf_ndps_item_ptr
, tvb
, foffset
, length
, ENC_NA
);
6193 proto_item_set_end(aitem
, tvb
, foffset
);
6196 case 0x00000004: /* Delete Resource File */
6197 foffset
= res_add_input_data(tvb
, ndps_tree
, foffset
);
6199 case 0x00000005: /* List Resources */
6200 proto_tree_add_item(ndps_tree
, hf_ndps_max_items
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6202 proto_tree_add_item(ndps_tree
, hf_ndps_status_flags
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6204 proto_tree_add_item(ndps_tree
, hf_ndps_resource_list_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6205 resource_type
= tvb_get_ntohl(tvb
, foffset
);
6207 switch (resource_type
)
6209 case 0: /* Print Drivers */
6210 proto_tree_add_item(ndps_tree
, hf_os_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6213 case 1: /* Printer Definitions */
6214 case 2: /* Printer Definitions Short */
6215 foffset
= ndps_string(tvb
, hf_ndps_vendor_dir
, ndps_tree
, foffset
, NULL
);
6217 case 3: /* Banner Page Files */
6218 proto_tree_add_item(ndps_tree
, hf_banner_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6221 case 4: /* Font Types */
6222 proto_tree_add_item(ndps_tree
, hf_font_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6224 proto_tree_add_item(ndps_tree
, hf_os_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6227 case 5: /* Printer Driver Files */
6228 case 12: /* Printer Driver Files 2 */
6229 case 9: /* Generic Files */
6230 proto_tree_add_item(ndps_tree
, hf_os_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6232 foffset
= ndps_string(tvb
, hf_ndps_printer_type
, ndps_tree
, foffset
, NULL
);
6233 foffset
= ndps_string(tvb
, hf_ndps_printer_manuf
, ndps_tree
, foffset
, NULL
);
6234 foffset
= ndps_string(tvb
, hf_ndps_inf_file_name
, ndps_tree
, foffset
, NULL
);
6235 field_len
= tvb_get_ntohl(tvb
, foffset
);
6237 proto_tree_add_item(ndps_tree
, hf_printer_id
, tvb
, foffset
, field_len
, ENC_NA
);
6239 case 6: /* Printer Definition File */
6240 case 10: /* Printer Definition File 2 */
6241 foffset
= ndps_string(tvb
, hf_ndps_vendor_dir
, ndps_tree
, foffset
, NULL
);
6243 foffset
= ndps_string(tvb
, hf_ndps_printer_type
, ndps_tree
, foffset
, NULL
);
6244 foffset
= ndps_string(tvb
, hf_ndps_printer_manuf
, ndps_tree
, foffset
, NULL
);
6245 foffset
= ndps_string(tvb
, hf_ndps_inf_file_name
, ndps_tree
, foffset
, NULL
);
6246 field_len
= tvb_get_ntohl(tvb
, foffset
);
6248 proto_tree_add_item(ndps_tree
, hf_printer_id
, tvb
, foffset
, field_len
, ENC_NA
);
6250 case 7: /* Font Files */
6251 proto_tree_add_item(ndps_tree
, hf_os_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6253 proto_tree_add_item(ndps_tree
, hf_font_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6255 foffset
= ndps_string(tvb
, hf_ndps_font_name
, ndps_tree
, foffset
, NULL
);
6257 case 8: /* Generic Type */
6258 case 11: /* Printer Driver Types 2 */
6259 case 13: /* Printer Driver Types Archive */
6260 foffset
= ndps_string(tvb
, hf_ndps_printer_manuf
, ndps_tree
, foffset
, NULL
);
6261 foffset
= ndps_string(tvb
, hf_ndps_printer_type
, ndps_tree
, foffset
, NULL
);
6262 foffset
= ndps_string(tvb
, hf_ndps_inf_file_name
, ndps_tree
, foffset
, NULL
);
6264 case 14: /* Languages Available */
6270 case 0x00000006: /* Get Resource File */
6271 proto_tree_add_item(ndps_tree
, hf_get_status_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6273 proto_tree_add_item(ndps_tree
, hf_res_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6274 resource_type
= tvb_get_ntohl(tvb
, foffset
);
6276 switch (resource_type
)
6278 case 0: /* Print Drivers */
6279 proto_tree_add_item(ndps_tree
, hf_os_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6281 foffset
= ndps_string(tvb
, hf_ndps_prn_dir_name
, ndps_tree
, foffset
, NULL
);
6282 foffset
= ndps_string(tvb
, hf_ndps_prn_file_name
, ndps_tree
, foffset
, NULL
);
6284 case 1: /* Printer Definitions */
6285 foffset
= ndps_string(tvb
, hf_ndps_vendor_dir
, ndps_tree
, foffset
, NULL
);
6286 foffset
= ndps_string(tvb
, hf_ndps_prn_file_name
, ndps_tree
, foffset
, NULL
);
6288 case 2: /* Banner Page Files */
6289 foffset
= ndps_string(tvb
, hf_ndps_banner_name
, ndps_tree
, foffset
, NULL
);
6291 case 3: /* Font Types */
6292 proto_tree_add_item(ndps_tree
, hf_os_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6294 proto_tree_add_item(ndps_tree
, hf_font_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6296 foffset
= ndps_string(tvb
, hf_ndps_prn_file_name
, ndps_tree
, foffset
, NULL
);
6298 case 4: /* Generic Files/ Archive */
6299 case 5: /* Printer Driver Archive */
6300 proto_tree_add_item(ndps_tree
, hf_os_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6302 foffset
= ndps_string(tvb
, hf_ndps_prn_dir_name
, ndps_tree
, foffset
, NULL
);
6303 proto_tree_add_item(ndps_tree
, hf_archive_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6310 case 0x00000007: /* Get Resource File Date */
6311 proto_tree_add_item(ndps_tree
, hf_ndps_status_flags
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6313 foffset
= res_add_input_data(tvb
, ndps_tree
, foffset
);
6315 case 0x0000000a: /* Set Resource Language Context */
6316 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6323 case 0x06097b: /* Delivery */
6326 case 0x00000001: /* Delivery Bind */
6327 foffset
= credentials(tvb
, pinfo
, ndps_tree
, foffset
);
6329 case 0x00000002: /* Delivery Unbind */
6332 case 0x00000003: /* Delivery Send */
6333 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
6334 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
6336 for (ii
= 0; ii
< number_of_items
; ii
++ )
6338 if (ii
>= NDPS_MAX_ITEMS
) {
6339 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
6342 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Item %d", ii
+1);
6343 proto_tree_add_item(atree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6345 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Supplier ID");
6346 length
= tvb_get_ntohl(tvb
, foffset
);
6350 proto_tree_add_item(btree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
6353 proto_tree_add_item(btree
, hf_ndps_event_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6355 proto_item_set_end(bitem
, tvb
, foffset
);
6356 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Containing Class");
6357 foffset
= objectidentifier(tvb
, btree
, foffset
);
6358 proto_item_set_end(bitem
, tvb
, foffset
);
6359 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Containing Object");
6360 foffset
= objectidentification(tvb
, btree
, foffset
);
6361 proto_item_set_end(bitem
, tvb
, foffset
);
6362 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Filter Class");
6363 foffset
= objectidentifier(tvb
, btree
, foffset
);
6364 proto_item_set_end(bitem
, tvb
, foffset
);
6365 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Object Class");
6366 foffset
= objectidentifier(tvb
, btree
, foffset
);
6367 proto_item_set_end(bitem
, tvb
, foffset
);
6368 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Object ID");
6369 foffset
= objectidentification(tvb
, btree
, foffset
);
6370 proto_item_set_end(bitem
, tvb
, foffset
);
6371 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Event Object ID");
6372 foffset
= objectidentifier(tvb
, btree
, foffset
);
6373 foffset
= attribute_value(tvb
, pinfo
, atree
, foffset
);
6374 foffset
= ndps_string(tvb
, hf_ndps_message
, atree
, foffset
, NULL
);
6375 proto_tree_add_item(atree
, hf_time
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6377 proto_item_set_end(bitem
, tvb
, foffset
);
6378 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Account");
6379 foffset
= qualifiedname(tvb
, btree
, foffset
);
6380 proto_item_set_end(bitem
, tvb
, foffset
);
6381 proto_item_set_end(aitem
, tvb
, foffset
);
6384 case 0x00000004: /* Delivery Send2 */
6385 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
6386 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_objects
, tvb
, foffset
, 4, number_of_items
);
6388 for (ii
= 0; ii
< number_of_items
; ii
++ )
6390 if (ii
>= NDPS_MAX_ITEMS
) {
6391 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
6394 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object %d", ii
+1);
6395 proto_tree_add_item(atree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6397 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Supplier ID");
6398 length
= tvb_get_ntohl(tvb
, foffset
);
6402 proto_tree_add_item(btree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
6405 proto_tree_add_item(atree
, hf_ndps_event_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6407 proto_item_set_end(bitem
, tvb
, foffset
);
6408 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Containing Class");
6409 foffset
= objectidentifier(tvb
, btree
, foffset
);
6410 proto_item_set_end(bitem
, tvb
, foffset
);
6411 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Containing Object");
6412 foffset
= objectidentification(tvb
, btree
, foffset
);
6413 proto_item_set_end(bitem
, tvb
, foffset
);
6414 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Filter Class");
6415 foffset
= objectidentifier(tvb
, btree
, foffset
);
6416 proto_item_set_end(bitem
, tvb
, foffset
);
6417 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Object Class");
6418 foffset
= objectidentifier(tvb
, btree
, foffset
);
6419 proto_item_set_end(bitem
, tvb
, foffset
);
6420 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Object ID");
6421 foffset
= objectidentification(tvb
, btree
, foffset
);
6422 proto_item_set_end(bitem
, tvb
, foffset
);
6423 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Event Object ID");
6424 foffset
= objectidentifier(tvb
, btree
, foffset
);
6425 proto_item_set_end(bitem
, tvb
, foffset
);
6426 /* Start of AttributeSet */
6427 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
6428 proto_tree_add_uint(atree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items2
);
6430 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Attribute");
6431 for (jj
= 0; jj
< number_of_items2
; jj
++ )
6433 if (jj
>= NDPS_MAX_ITEMS
) {
6434 expert_add_info(pinfo
, bitem
, &ei_ndps_truncated
);
6437 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
);
6439 proto_item_set_end(bitem
, tvb
, foffset
);
6440 /* End of AttributeSet */
6441 foffset
= ndps_string(tvb
, hf_ndps_message
, atree
, foffset
, NULL
);
6442 proto_tree_add_item(atree
, hf_time
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6444 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Account");
6445 foffset
= qualifiedname(tvb
, btree
, foffset
);
6446 proto_item_set_end(bitem
, tvb
, foffset
);
6447 proto_item_set_end(aitem
, tvb
, foffset
);
6461 ndps_error(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*ndps_tree
, int foffset
)
6463 uint32_t number_of_items
;
6464 uint32_t ndps_problem_type
;
6465 uint32_t problem_type
;
6471 proto_item
*expert_item
;
6473 ndps_problem_type
= tvb_get_ntohl(tvb
, foffset
);
6474 col_set_str(pinfo
->cinfo
, COL_INFO
, "R NDPS - Error");
6475 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_problem_type
, tvb
, foffset
, 4, ndps_problem_type
);
6476 expert_add_info_format(pinfo
, expert_item
, &ei_ndps_problem_type
, "Fault: %s", val_to_str(ndps_problem_type
, error_type_enum
, "Unknown NDPS Error (0x%08x)"));
6478 switch(ndps_problem_type
)
6480 case 0: /* Security Error */
6481 problem_type
= tvb_get_ntohl(tvb
, foffset
);
6482 proto_tree_add_uint(ndps_tree
, hf_problem_type
, tvb
, foffset
, 4, problem_type
);
6484 if (problem_type
==0) /* Standard Error */
6486 proto_tree_add_item(ndps_tree
, hf_security_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6489 else /* Extended Error */
6491 /* Start of objectidentifier */
6492 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Extended Error");
6493 foffset
= objectidentifier(tvb
, atree
, foffset
);
6494 proto_item_set_end(aitem
, tvb
, foffset
);
6495 /* End of objectidentifier */
6497 /* Start of NameorID */
6498 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Message");
6499 foffset
= name_or_id(tvb
, atree
, foffset
);
6500 proto_item_set_end(aitem
, tvb
, foffset
);
6501 /* End of NameorID */
6503 case 1: /* Service Error */
6504 proto_tree_add_item(ndps_tree
, hf_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6506 if (tvb_get_ntohl(tvb
, foffset
-4)==0) /* Standard Error */
6508 proto_tree_add_item(ndps_tree
, hf_service_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6511 else /* Extended Error */
6513 /* Start of objectidentifier */
6514 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Extended Error");
6515 foffset
= objectidentifier(tvb
, atree
, foffset
);
6516 proto_item_set_end(aitem
, tvb
, foffset
);
6517 /* End of objectidentifier */
6519 foffset
= objectidentification(tvb
, ndps_tree
, foffset
);
6520 foffset
= attribute_value(tvb
, pinfo
, ndps_tree
, foffset
); /* Object Attribute Set */
6521 proto_tree_add_item(ndps_tree
, hf_ndps_lib_error
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6523 proto_tree_add_item(ndps_tree
, hf_ndps_other_error
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6525 proto_tree_add_item(ndps_tree
, hf_ndps_other_error_2
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6527 if (tvb_reported_length_remaining(tvb
, foffset
) >= 4) {
6528 foffset
= ndps_string(tvb
, hf_ndps_other_error_string
, ndps_tree
, foffset
, NULL
);
6531 case 2: /* Access Error */
6532 proto_tree_add_item(ndps_tree
, hf_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6534 if (tvb_get_ntohl(tvb
, foffset
-4)==0) /* Standard Error */
6536 proto_tree_add_item(ndps_tree
, hf_access_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6539 else /* Extended Error */
6541 /* Start of objectidentifier */
6542 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Extended Error");
6543 foffset
= objectidentifier(tvb
, atree
, foffset
);
6544 proto_item_set_end(aitem
, tvb
, foffset
);
6545 /* End of objectidentifier */
6547 foffset
= objectidentification(tvb
, ndps_tree
, foffset
);
6549 case 3: /* Printer Error */
6550 proto_tree_add_item(ndps_tree
, hf_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6552 if (tvb_get_ntohl(tvb
, foffset
-4)==0) /* Standard Error */
6554 proto_tree_add_item(ndps_tree
, hf_printer_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6557 else /* Extended Error */
6559 /* Start of objectidentifier */
6560 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Extended Error");
6561 foffset
= objectidentifier(tvb
, atree
, foffset
);
6562 proto_item_set_end(aitem
, tvb
, foffset
);
6563 /* End of objectidentifier */
6565 foffset
= objectidentification(tvb
, ndps_tree
, foffset
);
6567 case 4: /* Selection Error */
6568 proto_tree_add_item(ndps_tree
, hf_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6570 if (tvb_get_ntohl(tvb
, foffset
-4)==0) /* Standard Error */
6572 proto_tree_add_item(ndps_tree
, hf_selection_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6575 else /* Extended Error */
6577 /* Start of objectidentifier */
6578 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Extended Error");
6579 foffset
= objectidentifier(tvb
, atree
, foffset
);
6580 proto_item_set_end(aitem
, tvb
, foffset
);
6581 /* End of objectidentifier */
6583 foffset
= objectidentification(tvb
, ndps_tree
, foffset
);
6584 foffset
= attribute_value(tvb
, pinfo
, ndps_tree
, foffset
); /* Object Attribute Set */
6586 case 5: /* Document Access Error */
6587 proto_tree_add_item(ndps_tree
, hf_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6589 if (tvb_get_ntohl(tvb
, foffset
-4)==0) /* Standard Error */
6591 proto_tree_add_item(ndps_tree
, hf_doc_access_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6592 foffset
= objectidentifier(tvb
, ndps_tree
, foffset
);
6594 else /* Extended Error */
6596 /* Start of objectidentifier */
6597 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Extended Error");
6598 foffset
= objectidentifier(tvb
, atree
, foffset
);
6599 proto_item_set_end(aitem
, tvb
, foffset
);
6600 /* End of objectidentifier */
6602 foffset
= objectidentification(tvb
, ndps_tree
, foffset
);
6604 case 6: /* Attribute Error */
6605 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
6606 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
6608 for (ii
= 0; ii
< number_of_items
; ii
++ )
6610 if (ii
>= NDPS_MAX_ITEMS
) {
6611 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
6614 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Item %d", ii
+1);
6615 proto_tree_add_item(atree
, hf_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6617 if (tvb_get_ntohl(tvb
, foffset
-4)==0) /* Standard Error */
6619 proto_tree_add_item(atree
, hf_attribute_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6622 else /* Extended Error */
6624 /* Start of objectidentifier */
6625 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Extended Error");
6626 foffset
= objectidentifier(tvb
, btree
, foffset
);
6627 proto_item_set_end(bitem
, tvb
, foffset
);
6628 /* End of objectidentifier */
6630 foffset
= attribute_value(tvb
, pinfo
, atree
, foffset
); /* Object Attribute Set */
6631 proto_item_set_end(aitem
, tvb
, foffset
);
6634 case 7: /* Update Error */
6635 proto_tree_add_item(ndps_tree
, hf_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6637 if (tvb_get_ntohl(tvb
, foffset
-4)==0) /* Standard Error */
6639 proto_tree_add_item(ndps_tree
, hf_update_problem_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6642 else /* Extended Error */
6644 /* Start of objectidentifier */
6645 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Extended Error");
6646 foffset
= objectidentifier(tvb
, atree
, foffset
);
6647 proto_item_set_end(aitem
, tvb
, foffset
);
6648 /* End of objectidentifier */
6650 foffset
= objectidentification(tvb
, ndps_tree
, foffset
);
6659 return_code(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*ndps_tree
, int foffset
)
6661 uint32_t expert_status
;
6662 proto_item
*expert_item
;
6664 expert_status
= tvb_get_ntohl(tvb
, foffset
);
6665 expert_item
= proto_tree_add_item(ndps_tree
, hf_ndps_return_code
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6666 if (expert_status
!= 0) {
6667 expert_add_info_format(pinfo
, expert_item
, &ei_ndps_return_code
, "Fault: %s",
6668 val_to_str_ext(expert_status
, &ndps_error_types_ext
, "Unknown NDPS Error (0x%08x)"));
6671 if (tvb_get_ntohl(tvb
, foffset
-4) != 0)
6672 col_set_str(pinfo
->cinfo
, COL_INFO
, "R NDPS - Error");
6673 if (tvb_get_ntohl(tvb
, foffset
-4) == 0)
6677 proto_tree_add_item(ndps_tree
, hf_ndps_ext_error
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6683 dissect_ndps_reply(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*ndps_tree
, int foffset
)
6685 conversation_t
*conversation
= NULL
;
6686 ndps_req_hash_value
*request_value
= NULL
;
6698 uint32_t number_of_items
=0;
6699 uint32_t number_of_items2
=0;
6700 uint32_t number_of_items3
=0;
6702 uint32_t ndps_func
=0;
6703 uint32_t ndps_prog
=0;
6704 uint32_t error_val
=0;
6705 uint32_t resource_type
=0;
6706 int length_remaining
;
6707 proto_item
*expert_item
;
6708 uint32_t expert_status
;
6710 if (!pinfo
->fd
->visited
) {
6711 /* Find the conversation whence the request would have come. */
6712 conversation
= find_conversation(pinfo
->num
, &pinfo
->src
, &pinfo
->dst
,
6713 CONVERSATION_NCP
, (uint32_t) pinfo
->destport
, (uint32_t) pinfo
->destport
, 0);
6714 if (conversation
!= NULL
) {
6715 /* find the record telling us the request made that caused
6717 request_value
= ndps_hash_lookup(conversation
, (uint32_t) pinfo
->destport
);
6718 p_add_proto_data(wmem_file_scope(), pinfo
, proto_ndps
, 0, (void*) request_value
);
6720 /* else... we haven't seen an NDPS Request for that conversation. */
6723 request_value
= (ndps_req_hash_value
*)p_get_proto_data(wmem_file_scope(), pinfo
, proto_ndps
, 0);
6725 if (request_value
) {
6726 ndps_prog
= request_value
->ndps_prog
;
6727 ndps_func
= request_value
->ndps_func
;
6728 proto_tree_add_uint_format(ndps_tree
, hf_ndps_reqframe
, tvb
, 0,
6729 0, request_value
->ndps_frame_num
,
6730 "Response to Request in Frame Number: %u",
6731 request_value
->ndps_frame_num
);
6734 if (tvb_reported_length_remaining(tvb
, foffset
) < 12 && tvb_get_ntohl(tvb
, foffset
) == 0) /* No error and no return data */
6736 proto_tree_add_uint(ndps_tree
, hf_ndps_error_val
, tvb
, foffset
, 4, error_val
);
6737 col_append_str(pinfo
->cinfo
, COL_INFO
, "- Ok");
6740 if(ndps_func
== 1 || ndps_func
== 2)
6742 expert_item
= proto_tree_add_item(ndps_tree
, hf_ndps_rpc_acc_stat
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6743 expert_status
= tvb_get_ntohl(tvb
, foffset
);
6744 if (expert_status
!= 0) {
6745 expert_add_info_format(pinfo
, expert_item
, &ei_ndps_rpc_acc_stat
, "Fault: %s", val_to_str(expert_status
, accept_stat
, "Unknown NDPS Error (0x%08x)"));
6748 if (tvb_reported_length_remaining(tvb
,foffset
) < 4 ) {
6749 col_append_str(pinfo
->cinfo
, COL_INFO
, "- Error");
6752 proto_tree_add_item(ndps_tree
, hf_ndps_rpc_acc_results
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6754 if (tvb_reported_length_remaining(tvb
,foffset
) < 4) {
6755 col_append_str(pinfo
->cinfo
, COL_INFO
, "- Error");
6759 error_val
= tvb_get_ntohl(tvb
, foffset
);
6760 proto_tree_add_uint(ndps_tree
, hf_ndps_error_val
, tvb
, foffset
, 4, error_val
);
6762 /* Some functions return an error with no data, 0 is ok */
6763 if (try_val_to_str_ext(tvb_get_ntohl(tvb
, foffset
), &ndps_error_types_ext
) && tvb_reported_length_remaining(tvb
,foffset
) < 8 && (tvb_get_ntohl(tvb
, foffset
)!=0))
6765 expert_status
= tvb_get_ntohl(tvb
, foffset
);
6766 expert_item
= proto_tree_add_item(ndps_tree
, hf_ndps_return_code
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6767 expert_add_info_format(pinfo
, expert_item
, &ei_ndps_return_code
, "Fault: %s", val_to_str_ext(expert_status
, &ndps_error_types_ext
, "Unknown NDPS Error (0x%08x)"));
6768 col_append_str(pinfo
->cinfo
, COL_INFO
, "- Error");
6771 col_append_str(pinfo
->cinfo
, COL_INFO
, "- Ok");
6774 case 0x060976: /* Print */
6777 case 0x00000001: /* Bind PSM */
6778 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6782 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
6783 if(tvb_reported_length_remaining(tvb
, foffset
) < 4)
6787 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6790 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "PSM Name");
6791 foffset
= qualifiedname(tvb
, atree
, foffset
);
6792 proto_item_set_end(aitem
, tvb
, foffset
);
6794 case 0x00000002: /* Bind PA */
6795 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6799 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
6800 if(tvb_reported_length_remaining(tvb
, foffset
) < 4)
6804 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6807 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
6809 case 0x00000003: /* Unbind */
6811 case 0x00000004: /* Print */
6812 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ndps_tree
, foffset
, NULL
);
6813 proto_tree_add_item(ndps_tree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6817 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
6820 case 0x00000005: /* Modify Job */
6821 case 0x00000006: /* Cancel Job */
6822 case 0x00000008: /* Promote Job */
6823 case 0x0000000b: /* Resume */
6824 case 0x0000000d: /* Create */
6825 /* Start of AttributeSet */
6826 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
6827 proto_tree_add_uint(ndps_tree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
6829 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object Attribute Set");
6830 for (ii
= 0; ii
< number_of_items
; ii
++ )
6832 if (ii
>= NDPS_MAX_ITEMS
) {
6833 expert_add_info(pinfo
, aitem
, &ei_ndps_truncated
);
6836 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Attribute %d", ii
+1);
6837 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
); /* Object Attribute Set */
6838 proto_item_set_end(bitem
, tvb
, foffset
);
6840 proto_item_set_end(aitem
, tvb
, foffset
);
6841 /* End of AttributeSet */
6844 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
6847 case 0x00000007: /* List Object Attributes */
6848 proto_tree_add_item(ndps_tree
, hf_answer_time
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6850 /* Continuation Option */
6851 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Continuation Option");
6852 number_of_items
=tvb_get_ntohl(tvb
, foffset
);
6853 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_options
, tvb
, foffset
, 4, number_of_items
);
6855 for (ii
= 0; ii
< number_of_items
; ii
++ )
6857 if (ii
>= NDPS_MAX_ITEMS
) {
6858 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
6861 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Option %d", ii
+1);
6862 length
=tvb_get_ntohl(tvb
, foffset
);
6863 length_remaining
= tvb_reported_length_remaining(tvb
, foffset
);
6864 if(length_remaining
== -1 || (uint32_t) length_remaining
< length
)
6868 proto_tree_add_item(btree
, hf_ndps_item_ptr
, tvb
, foffset
, length
, ENC_NA
);
6870 proto_item_set_end(bitem
, tvb
, foffset
);
6872 proto_item_set_end(aitem
, tvb
, foffset
);
6873 /* Limit Encountered Option */
6874 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Limit Encountered Option");
6875 proto_tree_add_item(atree
, hf_ndps_len
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6877 proto_tree_add_item(atree
, hf_ndps_limit_enc
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6879 proto_item_set_end(aitem
, tvb
, foffset
);
6880 /* Object Results Set */
6881 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object Results Set");
6882 number_of_items
=tvb_get_ntohl(tvb
, foffset
);
6883 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_results
, tvb
, foffset
, 4, number_of_items
);
6885 for (ii
= 0; ii
< number_of_items
; ii
++ )
6887 if (ii
>= NDPS_MAX_ITEMS
) {
6888 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
6891 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Results: (%d)", ii
+1);
6895 foffset
= objectidentification(tvb
, btree
, foffset
);
6896 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
6897 expert_item
= proto_tree_add_uint(btree
, hf_ndps_num_objects
, tvb
, foffset
, 4, number_of_items2
);
6899 for (jj
= 0; jj
< number_of_items2
; jj
++ )
6901 if (jj
>= NDPS_MAX_ITEMS
) {
6902 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
6905 ctree
= proto_tree_add_subtree_format(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Object: (%d)", jj
+1);
6906 foffset
= objectidentifier(tvb
, ctree
, foffset
);
6907 foffset
+= align_4(tvb
, foffset
);
6908 number_of_items3
= tvb_get_ntohl(tvb
, foffset
);
6909 expert_item
= proto_tree_add_uint(ctree
, hf_ndps_num_values
, tvb
, foffset
, 4, number_of_items3
);
6911 for (kk
= 0; kk
< number_of_items3
; kk
++ )
6913 if (kk
>= NDPS_MAX_ITEMS
) {
6914 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
6917 dtree
= proto_tree_add_subtree_format(ctree
, tvb
, foffset
, -1, ett_ndps
, &ditem
, "Value: (%d)", kk
+1);
6918 foffset
= attribute_value(tvb
, pinfo
, dtree
, foffset
);
6919 proto_item_set_end(ditem
, tvb
, foffset
);
6921 proto_tree_add_item(ctree
, hf_ndps_qualifier
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6923 foffset
+= align_4(tvb
, foffset
);
6924 proto_item_set_end(citem
, tvb
, foffset
);
6927 /*foffset += align_4(tvb, foffset);*/
6928 foffset
= objectidentifier(tvb
, btree
, foffset
);
6929 /*foffset += align_4(tvb, foffset);*/
6930 proto_item_set_end(bitem
, tvb
, foffset
);
6932 proto_item_set_end(aitem
, tvb
, foffset
);
6935 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
6938 case 0x00000009: /* Interrupt */
6939 case 0x0000000a: /* Pause */
6940 /* Start of NWDPPrtContainedObjectId */
6941 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Job ID");
6942 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, atree
, foffset
, NULL
);
6943 proto_tree_add_item(atree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
6945 proto_item_set_end(aitem
, tvb
, foffset
);
6946 /* End of NWDPPrtContainedObjectId */
6947 /* Start of AttributeSet */
6948 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
6949 proto_tree_add_uint(ndps_tree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
6951 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Object Attribute Set");
6952 for (ii
= 0; ii
< number_of_items
; ii
++ )
6954 if (ii
>= NDPS_MAX_ITEMS
) {
6955 expert_add_info(pinfo
, aitem
, &ei_ndps_truncated
);
6958 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Attribute %d", ii
+1);
6959 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
); /* Object Attribute Set */
6960 proto_item_set_end(bitem
, tvb
, foffset
);
6962 proto_item_set_end(aitem
, tvb
, foffset
);
6963 /* End of AttributeSet */
6966 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
6969 case 0x0000000c: /* Clean */
6970 case 0x0000000e: /* Delete */
6971 case 0x0000000f: /* Disable PA */
6972 case 0x00000010: /* Enable PA */
6973 case 0x00000012: /* Set */
6974 case 0x00000013: /* Shutdown PA */
6975 case 0x00000014: /* Startup PA */
6976 case 0x00000018: /* Transfer Data */
6977 case 0x00000019: /* Device Control */
6978 case 0x0000001b: /* Remove Event Profile */
6979 case 0x0000001c: /* Modify Event Profile */
6980 case 0x0000001e: /* Shutdown PSM */
6981 case 0x0000001f: /* Cancel PSM Shutdown */
6982 case 0x00000020: /* Set Printer DS Information */
6983 case 0x00000021: /* Clean User Jobs */
6986 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
6989 case 0x00000011: /* Resubmit Jobs */
6990 number_of_items
= tvb_get_ntohl(tvb
, foffset
); /* Start of ResubmitJob Set */
6991 proto_tree_add_uint(ndps_tree
, hf_ndps_num_jobs
, tvb
, foffset
, 4, number_of_items
);
6993 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Resubmit Job");
6994 for (ii
= 0; ii
< number_of_items
; ii
++ )
6996 if (ii
>= NDPS_MAX_ITEMS
) {
6997 expert_add_info(pinfo
, aitem
, &ei_ndps_truncated
);
7000 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Job %d", ii
+1);
7001 /* Start of NWDPPrtContainedObjectId */
7002 ctree
= proto_tree_add_subtree(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Old Job");
7003 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ctree
, foffset
, NULL
);
7004 proto_tree_add_item(ctree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7006 proto_item_set_end(citem
, tvb
, foffset
);
7007 /* End of NWDPPrtContainedObjectId */
7008 /* Start of NWDPPrtContainedObjectId */
7009 ctree
= proto_tree_add_subtree(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "New Job");
7010 foffset
= ndps_string(tvb
, hf_ndps_pa_name
, ctree
, foffset
, NULL
);
7011 proto_tree_add_item(ctree
, hf_local_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7013 proto_item_set_end(citem
, tvb
, foffset
);
7014 /* End of NWDPPrtContainedObjectId */
7015 /* Start of AttributeSet */
7016 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
7017 proto_tree_add_uint(ctree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items2
);
7019 ctree
= proto_tree_add_subtree(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Job Status");
7020 for (jj
= 0; jj
< number_of_items2
; jj
++ )
7022 if (jj
>= NDPS_MAX_ITEMS
) {
7023 expert_add_info(pinfo
, citem
, &ei_ndps_truncated
);
7026 dtree
= proto_tree_add_subtree_format(ctree
, tvb
, foffset
, -1, ett_ndps
, &ditem
, "Object %d", jj
+1);
7027 foffset
= attribute_value(tvb
, pinfo
, dtree
, foffset
); /* Object Attribute Set */
7028 proto_item_set_end(ditem
, tvb
, foffset
);
7030 proto_item_set_end(citem
, tvb
, foffset
);
7031 proto_item_set_end(bitem
, tvb
, foffset
);
7032 /* End of AttributeSet */
7034 proto_item_set_end(aitem
, tvb
, foffset
);
7035 /* End of ResubmitJob Set */
7038 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
7041 case 0x00000015: /* Reorder Job */
7042 /* Start of AttributeSet */
7043 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Job Status");
7044 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7045 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
7047 for (ii
= 0; ii
< number_of_items
; ii
++ )
7049 if (ii
>= NDPS_MAX_ITEMS
) {
7050 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7053 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Object %d", ii
+1);
7054 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
); /* Object Attribute Set */
7055 proto_item_set_end(bitem
, tvb
, foffset
);
7057 proto_item_set_end(aitem
, tvb
, foffset
);
7058 /* End of AttributeSet */
7061 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
7064 case 0x00000016: /* Pause PA */
7065 case 0x00000017: /* Resume PA */
7066 /* Start of AttributeSet */
7067 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Printer Status");
7068 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7069 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
7071 for (ii
= 0; ii
< number_of_items
; ii
++ )
7073 if (ii
>= NDPS_MAX_ITEMS
) {
7074 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7077 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Object %d", ii
+1);
7078 foffset
= attribute_value(tvb
, pinfo
, btree
, foffset
); /* Object Attribute Set */
7079 proto_item_set_end(bitem
, tvb
, foffset
);
7081 proto_item_set_end(aitem
, tvb
, foffset
);
7082 /* End of AttributeSet */
7085 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
7088 case 0x0000001a: /* Add Event Profile */
7089 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7093 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
7096 case 0x0000001d: /* List Event Profiles */
7097 length
= tvb_get_ntohl(tvb
, foffset
);
7101 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
7104 /* Start of Eventhandling */
7105 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7107 proto_tree_add_item(ndps_tree
, hf_ndps_persistence
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7109 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Consumer Name");
7110 foffset
= qualifiedname(tvb
, atree
, foffset
);
7111 length
= tvb_get_ntohl(tvb
, foffset
);
7115 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
7118 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7120 proto_item_set_end(aitem
, tvb
, foffset
);
7121 /* Start of NameorID */
7122 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
7123 foffset
= name_or_id(tvb
, atree
, foffset
);
7124 proto_item_set_end(aitem
, tvb
, foffset
);
7125 /* End of NameorID */
7126 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Delivery Addresses");
7127 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7128 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_delivery_add_count
, tvb
, foffset
, 4, number_of_items
);
7130 for (ii
= 0; ii
< number_of_items
; ii
++ )
7132 if (ii
>= NDPS_MAX_ITEMS
) {
7133 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7136 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Address %d", ii
+1);
7137 foffset
= address_item(tvb
, btree
, foffset
);
7138 proto_item_set_end(bitem
, tvb
, foffset
);
7140 proto_item_set_end(aitem
, tvb
, foffset
);
7141 foffset
= event_object_set(tvb
, pinfo
, ndps_tree
, foffset
);
7142 /* End of Eventhandling */
7143 length
= tvb_get_ntohl(tvb
, foffset
);
7147 proto_tree_add_item(ndps_tree
, hf_ndps_continuation_option
, tvb
, foffset
, length
, ENC_NA
);
7152 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
7155 case 0x00000022: /* Map GUID to NDS Name */
7156 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "NDS Printer Name");
7157 foffset
= qualifiedname(tvb
, atree
, foffset
);
7158 proto_item_set_end(aitem
, tvb
, foffset
);
7161 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
7164 case 0x00000023: /* AddEventProfile2 */
7165 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7167 proto_tree_add_item(ndps_tree
, hf_notify_lease_exp_time
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7171 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
7174 case 0x00000024: /* ListEventProfiles2 */
7175 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7176 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_events
, tvb
, foffset
, 4, number_of_items
);
7178 for (ii
= 0; ii
< number_of_items
; ii
++ )
7180 if (ii
>= NDPS_MAX_ITEMS
) {
7181 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7184 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Event %d", ii
+1);
7185 /* Start of Eventhandling2 */
7186 proto_tree_add_item(atree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7188 proto_tree_add_item(atree
, hf_ndps_persistence
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7190 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Consumer Name");
7191 foffset
= qualifiedname(tvb
, btree
, foffset
);
7192 foffset
= ndps_string(tvb
, hf_ndps_supplier_name
, atree
, foffset
, NULL
);
7193 proto_tree_add_item(atree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7195 proto_item_set_end(bitem
, tvb
, foffset
);
7196 /* Start of NameorID */
7197 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Method ID");
7198 foffset
= name_or_id(tvb
, btree
, foffset
);
7199 foffset
+= align_4(tvb
, foffset
);
7200 proto_item_set_end(bitem
, tvb
, foffset
);
7201 /* End of NameorID */
7202 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
7203 proto_tree_add_uint(atree
, hf_ndps_delivery_add_count
, tvb
, foffset
, 4, number_of_items2
);
7205 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Delivery Addresses");
7206 for (jj
= 0; jj
< number_of_items2
; jj
++ )
7208 if (jj
>= NDPS_MAX_ITEMS
) {
7209 expert_add_info(pinfo
, bitem
, &ei_ndps_truncated
);
7212 ctree
= proto_tree_add_subtree_format(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Address %d", ii
+1);
7213 foffset
= address_item(tvb
, ctree
, foffset
);
7214 proto_item_set_end(citem
, tvb
, foffset
);
7216 proto_item_set_end(bitem
, tvb
, foffset
);
7217 foffset
= event_object_set(tvb
, pinfo
, atree
, foffset
);
7218 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Account");
7219 foffset
= qualifiedname(tvb
, btree
, foffset
);
7220 proto_item_set_end(bitem
, tvb
, foffset
);
7221 /* Start of object identifier set */
7222 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Notify Attributes");
7223 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
7224 expert_item
= proto_tree_add_uint(btree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items2
);
7226 for (jj
= 0; jj
< number_of_items2
; jj
++ )
7228 if (jj
>= NDPS_MAX_ITEMS
) {
7229 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7232 ctree
= proto_tree_add_subtree_format(btree
, tvb
, foffset
, -1, ett_ndps
, &citem
, "Attribute %d", ii
+1);
7233 foffset
= objectidentifier(tvb
, ctree
, foffset
);
7234 proto_item_set_end(citem
, tvb
, foffset
);
7236 proto_item_set_end(bitem
, tvb
, foffset
);
7237 /* End of object identifier set */
7238 proto_tree_add_item(atree
, hf_notify_time_interval
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7240 proto_tree_add_item(atree
, hf_notify_sequence_number
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7242 proto_tree_add_item(atree
, hf_notify_lease_exp_time
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7244 foffset
= ndps_string(tvb
, hf_notify_printer_uri
, atree
, foffset
, NULL
);
7245 proto_item_set_end(aitem
, tvb
, foffset
);
7246 /* End of Eventhandling2 */
7247 length
= tvb_get_ntohl(tvb
, foffset
); /* Added on 10-17-03 */
7251 proto_tree_add_item(ndps_tree
, hf_ndps_continuation_option
, tvb
, foffset
, length
, ENC_NA
);
7256 foffset
= ndps_error(tvb
, pinfo
, ndps_tree
, foffset
);
7264 case 0x060977: /* Broker */
7267 case 0x00000001: /* Bind */
7268 case 0x00000002: /* Unbind */
7269 case 0x00000004: /* Enable Service */
7270 case 0x00000005: /* Disable Service */
7271 case 0x00000006: /* Down Broker */
7272 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7274 case 0x00000003: /* List Services */
7275 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7276 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_services
, tvb
, foffset
, 4, number_of_items
);
7278 for (ii
= 0; ii
< number_of_items
; ii
++ )
7280 if (ii
>= NDPS_MAX_ITEMS
) {
7281 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7284 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Service %d", ii
+1);
7285 proto_tree_add_item(atree
, hf_ndps_service_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7287 proto_tree_add_item(atree
, hf_ndps_service_enabled
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7289 proto_item_set_end(aitem
, tvb
, foffset
);
7291 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7293 case 0x00000007: /* Get Broker NDS Object Name */
7294 proto_tree_add_item(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
,
7295 4, ENC_BIG_ENDIAN
); /* XXX - what does this count? */
7297 foffset
= ndps_string(tvb
, hf_ndps_broker_name
, ndps_tree
, foffset
, NULL
);
7298 foffset
= ndps_string(tvb
, hf_ndps_tree
, ndps_tree
, foffset
, NULL
);
7299 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7301 case 0x00000008: /* Get Broker Session Information */
7306 case 0x060978: /* Registry */
7309 case 0x00000001: /* Bind */
7310 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7311 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
7313 for (ii
= 0; ii
< number_of_items
; ii
++ )
7315 if (ii
>= NDPS_MAX_ITEMS
) {
7316 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7319 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Attribute %d", ii
+1);
7320 length
= tvb_get_ntohl(tvb
, foffset
);
7324 proto_tree_add_item(atree
, hf_ndps_attribute_set
, tvb
, foffset
, length
, ENC_NA
);
7326 proto_item_set_end(aitem
, tvb
, foffset
);
7329 case 0x00000002: /* Unbind */
7332 case 0x00000003: /* Register Server */
7333 case 0x00000004: /* Deregister Server */
7334 case 0x00000005: /* Register Registry */
7335 case 0x00000006: /* Deregister Registry */
7336 case 0x00000007: /* Registry Update */
7337 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7339 case 0x00000008: /* List Local Servers */
7340 case 0x00000009: /* List Servers */
7341 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7342 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
7344 for (ii
= 0; ii
< number_of_items
; ii
++ )
7346 if (ii
>= NDPS_MAX_ITEMS
) {
7347 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7350 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Item %d", ii
+1);
7351 foffset
= server_entry(tvb
, pinfo
, atree
, foffset
);
7352 proto_item_set_end(aitem
, tvb
, foffset
);
7354 length
= tvb_get_ntohl(tvb
, foffset
);
7358 proto_tree_add_item(ndps_tree
, hf_ndps_continuation_option
, tvb
, foffset
, length
, ENC_NA
);
7361 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7363 case 0x0000000a: /* List Known Registries */
7364 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7365 expert_item
= proto_tree_add_item(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7367 for (ii
= 0; ii
< number_of_items
; ii
++ )
7369 if (ii
>= NDPS_MAX_ITEMS
) {
7370 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7373 aitem
= proto_tree_add_item(ndps_tree
, hf_ndps_client_server_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7374 atree
= proto_item_add_subtree(aitem
, ett_ndps
);
7376 foffset
= ndps_string(tvb
, hf_ndps_registry_name
, atree
, foffset
, NULL
);
7377 foffset
= print_address(tvb
, atree
, foffset
);
7379 length
= tvb_get_ntohl(tvb
, foffset
);
7383 proto_tree_add_item(ndps_tree
, hf_ndps_continuation_option
, tvb
, foffset
, length
, ENC_NA
);
7386 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7388 case 0x0000000b: /* Get Registry NDS Object Name */
7389 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "NDS Printer Name");
7390 foffset
= qualifiedname(tvb
, atree
, foffset
);
7391 proto_item_set_end(aitem
, tvb
, foffset
);
7392 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7394 case 0x0000000c: /* Get Registry Session Information */
7395 proto_tree_add_item(ndps_tree
, hf_ndps_session_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7397 proto_tree_add_item(ndps_tree
, hf_time
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7399 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7405 case 0x060979: /* Notify */
7408 case 0x00000001: /* Notify Bind */
7409 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7410 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_num_attributes
, tvb
, foffset
, 4, number_of_items
);
7412 for (ii
= 0; ii
< number_of_items
; ii
++ )
7414 if (ii
>= NDPS_MAX_ITEMS
) {
7415 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7418 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Attribute %d", ii
+1);
7419 length
= tvb_get_ntohl(tvb
, foffset
);
7423 proto_tree_add_item(atree
, hf_ndps_attribute_set
, tvb
, foffset
, length
, ENC_NA
);
7425 proto_item_set_end(aitem
, tvb
, foffset
);
7428 case 0x00000002: /* Notify Unbind */
7431 case 0x00000003: /* Register Supplier */
7432 proto_tree_add_item(ndps_tree
, hf_ndps_session
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7434 foffset
= event_object_set(tvb
, pinfo
, ndps_tree
, foffset
);
7435 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7437 case 0x00000004: /* Deregister Supplier */
7438 case 0x0000000b: /* Report Notification */
7439 case 0x0000000d: /* Remove Delivery Method */
7440 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7442 case 0x00000005: /* Add Profile */
7443 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7445 foffset
= event_object_set(tvb
, pinfo
, ndps_tree
, foffset
);
7446 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7448 case 0x00000006: /* Remove Profile */
7449 case 0x00000007: /* Modify Profile */
7450 case 0x00000009: /* Report Event */
7451 foffset
= event_object_set(tvb
, pinfo
, ndps_tree
, foffset
);
7452 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7454 case 0x00000008: /* List Profiles */
7455 /* Start of ProfileResultSet */
7456 proto_tree_add_item(ndps_tree
, hf_ndps_len
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7458 /* Start of Eventhandling */
7459 proto_tree_add_item(ndps_tree
, hf_ndps_profile_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7461 proto_tree_add_item(ndps_tree
, hf_ndps_persistence
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7463 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Consumer Name");
7464 foffset
= qualifiedname(tvb
, atree
, foffset
);
7465 proto_item_set_end(aitem
, tvb
, foffset
);
7466 length
= tvb_get_ntohl(tvb
, foffset
);
7470 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_value
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
7473 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7475 /* Start of NameorID */
7476 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
7477 foffset
= name_or_id(tvb
, atree
, foffset
);
7478 proto_item_set_end(aitem
, tvb
, foffset
);
7479 /* End of NameorID */
7480 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Delivery Addresses");
7481 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7482 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_delivery_add_count
, tvb
, foffset
, 4, number_of_items
);
7484 for (ii
= 0; ii
< number_of_items
; ii
++ )
7486 if (ii
>= NDPS_MAX_ITEMS
) {
7487 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7490 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Address %d", ii
+1);
7491 foffset
= address_item(tvb
, btree
, foffset
);
7492 proto_item_set_end(bitem
, tvb
, foffset
);
7494 proto_item_set_end(aitem
, tvb
, foffset
);
7495 foffset
= event_object_set(tvb
, pinfo
, ndps_tree
, foffset
);
7496 /* End of Eventhandling */
7497 /* End of ProfileResultSet */
7498 length
= tvb_get_ntohl(tvb
, foffset
);
7502 proto_tree_add_item(ndps_tree
, hf_ndps_continuation_option
, tvb
, foffset
, length
, ENC_NA
);
7505 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7507 case 0x0000000a: /* List Supported Languages */
7508 /* Start of IntegerSeq */
7509 length
= tvb_get_ntohl(tvb
, foffset
);
7513 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, length
, ENC_BIG_ENDIAN
);
7516 /* End of IntegerSeq */
7517 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7519 case 0x0000000c: /* Add Delivery Method */
7520 /* Start of NameorID */
7521 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
7522 foffset
= name_or_id(tvb
, atree
, foffset
);
7523 proto_item_set_end(aitem
, tvb
, foffset
);
7524 /* End of NameorID */
7525 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7527 case 0x0000000e: /* List Delivery Methods */
7528 /* Start of DeliveryMethodSet */
7529 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7530 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_delivery_method_count
, tvb
, foffset
, 4, number_of_items
);
7532 for (ii
= 0; ii
< number_of_items
; ii
++ )
7534 if (ii
>= NDPS_MAX_ITEMS
) {
7535 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7538 /* Start of DeliveryMethod */
7539 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method %d", ii
+1);
7540 /* Start of NameorID */
7541 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Method ID");
7542 foffset
= name_or_id(tvb
, btree
, foffset
);
7543 foffset
+= align_4(tvb
, foffset
);
7544 proto_item_set_end(bitem
, tvb
, foffset
);
7545 /* End of NameorID */
7546 foffset
= ndps_string(tvb
, hf_ndps_method_name
, atree
, foffset
, NULL
);
7547 foffset
= ndps_string(tvb
, hf_ndps_method_ver
, atree
, foffset
, NULL
);
7548 foffset
= ndps_string(tvb
, hf_ndps_file_name
, atree
, foffset
, NULL
);
7549 proto_tree_add_item(atree
, hf_ndps_admin_submit
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7551 proto_item_set_end(aitem
, tvb
, foffset
);
7552 /* End of DeliveryMethod */
7554 /* End of DeliveryMethodSet */
7555 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7557 case 0x0000000f: /* Get Delivery Method Information */
7558 /* Start of DeliveryMethod */
7559 /* Start of NameorID */
7560 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Method ID");
7561 foffset
= name_or_id(tvb
, atree
, foffset
);
7562 /* End of NameorID */
7563 foffset
= ndps_string(tvb
, hf_ndps_method_name
, atree
, foffset
, NULL
);
7564 foffset
= ndps_string(tvb
, hf_ndps_method_ver
, atree
, foffset
, NULL
);
7565 foffset
= ndps_string(tvb
, hf_ndps_file_name
, atree
, foffset
, NULL
);
7566 proto_tree_add_item(atree
, hf_ndps_admin_submit
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7568 proto_item_set_end(aitem
, tvb
, foffset
);
7569 /* End of DeliveryMethod */
7570 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7571 proto_tree_add_uint(ndps_tree
, hf_ndps_delivery_add_count
, tvb
, foffset
, 4, number_of_items
);
7573 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Delivery Addresses");
7574 for (ii
= 0; ii
< number_of_items
; ii
++ )
7576 if (ii
>= NDPS_MAX_ITEMS
) {
7577 expert_add_info(pinfo
, aitem
, &ei_ndps_truncated
);
7580 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Address %d", ii
+1);
7581 foffset
= address_item(tvb
, btree
, foffset
);
7582 proto_item_set_end(bitem
, tvb
, foffset
);
7584 proto_item_set_end(aitem
, tvb
, foffset
);
7585 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7587 case 0x00000010: /* Get Notify NDS Object Name */
7588 proto_tree_add_item(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
,
7589 4, ENC_BIG_ENDIAN
); /* XXX - what does this count? */
7591 foffset
= ndps_string(tvb
, hf_ndps_broker_name
, ndps_tree
, foffset
, NULL
);
7592 foffset
= ndps_string(tvb
, hf_ndps_tree
, ndps_tree
, foffset
, NULL
);
7593 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7595 case 0x00000011: /* Get Notify Session Information */
7596 proto_tree_add_item(ndps_tree
, hf_ndps_get_session_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7598 proto_tree_add_item(ndps_tree
, hf_time
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7600 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7606 case 0x06097a: /* Resman */
7609 case 0x00000001: /* Bind */
7610 length
= tvb_get_ntohl(tvb
, foffset
);
7614 proto_tree_add_item(ndps_tree
, hf_ndps_attribute_set
, tvb
, foffset
, length
, ENC_NA
);
7617 case 0x00000002: /* Unbind */
7620 case 0x00000003: /* Add Resource File */
7621 case 0x00000004: /* Delete Resource File */
7622 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7624 case 0x00000005: /* List Resources */
7625 proto_tree_add_item(ndps_tree
, hf_ndps_return_code
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7627 if (tvb_get_ntohl(tvb
, foffset
-4) != 0)
7628 col_set_str(pinfo
->cinfo
, COL_INFO
, "R NDPS - Error");
7629 if (tvb_get_ntohl(tvb
, foffset
-4) != 0)
7633 proto_tree_add_item(ndps_tree
, hf_ndps_status_flags
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7635 proto_tree_add_item(ndps_tree
, hf_ndps_resource_list_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7636 resource_type
= tvb_get_ntohl(tvb
, foffset
);
7638 switch (resource_type
)
7640 case 0: /* Print Drivers */
7641 case 1: /* Printer Definitions */
7642 case 2: /* Printer Definitions Short */
7643 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7644 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_printer_def_count
, tvb
, foffset
, 4, number_of_items
);
7646 for (ii
= 0; ii
< number_of_items
; ii
++ )
7648 if (ii
>= NDPS_MAX_ITEMS
) {
7649 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7652 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Definition %d", ii
+1);
7653 if (tvb_get_ntohl(tvb
, foffset
)==0) { /* Offset for old type support */
7656 foffset
+= 4; /* Item always == 1 */
7657 foffset
= ndps_string(tvb
, hf_ndps_printer_manuf
, atree
, foffset
, NULL
);
7658 if (tvb_get_ntohl(tvb
, foffset
)==0) {
7662 foffset
= ndps_string(tvb
, hf_ndps_printer_type
, atree
, foffset
, NULL
);
7663 if (tvb_get_ntohl(tvb
, foffset
)==0) {
7667 foffset
= ndps_string(tvb
, hf_ndps_inf_file_name
, atree
, foffset
, NULL
);
7668 proto_item_set_end(aitem
, tvb
, foffset
);
7671 case 3: /* Banner Page Files */
7672 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7673 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
7675 for (ii
= 0; ii
< number_of_items
; ii
++ )
7677 if (ii
>= NDPS_MAX_ITEMS
) {
7678 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7681 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Banner %d", ii
+1);
7682 foffset
= ndps_string(tvb
, hf_ndps_banner_name
, atree
, foffset
, NULL
);
7683 proto_item_set_end(aitem
, tvb
, foffset
);
7686 case 4: /* Font Types */
7687 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7688 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_font_type_count
, tvb
, foffset
, 4, number_of_items
);
7690 for (ii
= 0; ii
< number_of_items
; ii
++ )
7692 if (ii
>= NDPS_MAX_ITEMS
) {
7693 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7696 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Font %d", ii
+1);
7697 foffset
= ndps_string(tvb
, hf_font_type_name
, atree
, foffset
, NULL
);
7698 proto_item_set_end(aitem
, tvb
, foffset
);
7701 case 7: /* Font Files */
7702 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7703 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_font_file_count
, tvb
, foffset
, 4, number_of_items
);
7705 for (ii
= 0; ii
< number_of_items
; ii
++ )
7707 if (ii
>= NDPS_MAX_ITEMS
) {
7708 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7711 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Font File %d", ii
+1);
7712 foffset
= ndps_string(tvb
, hf_font_file_name
, atree
, foffset
, NULL
);
7713 proto_item_set_end(aitem
, tvb
, foffset
);
7716 case 5: /* Printer Driver Files */
7717 case 12: /* Printer Driver Files 2 */
7718 case 9: /* Generic Files */
7719 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7720 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_printer_def_count
, tvb
, foffset
, 4, number_of_items
);
7722 for (ii
= 0; ii
< number_of_items
; ii
++ )
7724 if (ii
>= NDPS_MAX_ITEMS
) {
7725 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7728 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "File %d", ii
+1);
7729 foffset
= ndps_string(tvb
, hf_ndps_prn_file_name
, atree
, foffset
, NULL
);
7730 foffset
= ndps_string(tvb
, hf_ndps_prn_dir_name
, atree
, foffset
, NULL
);
7731 foffset
= ndps_string(tvb
, hf_ndps_inf_file_name
, atree
, foffset
, NULL
);
7732 proto_item_set_end(aitem
, tvb
, foffset
);
7735 case 6: /* Printer Definition File */
7736 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7737 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_printer_def_count
, tvb
, foffset
, 4, number_of_items
);
7739 for (ii
= 0; ii
< number_of_items
; ii
++ )
7741 if (ii
>= NDPS_MAX_ITEMS
) {
7742 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7745 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Definition %d", ii
+1);
7746 foffset
= ndps_string(tvb
, hf_ndps_prn_file_name
, atree
, foffset
, NULL
);
7747 foffset
= ndps_string(tvb
, hf_ndps_prn_dir_name
, atree
, foffset
, NULL
);
7748 foffset
= ndps_string(tvb
, hf_ndps_inf_file_name
, atree
, foffset
, NULL
);
7749 proto_item_set_end(aitem
, tvb
, foffset
);
7751 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7752 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
7754 for (ii
= 0; ii
< number_of_items
; ii
++ )
7756 if (ii
>= NDPS_MAX_ITEMS
) {
7757 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7760 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Item %d", ii
+1);
7761 foffset
= ndps_string(tvb
, hf_ndps_def_file_name
, atree
, foffset
, NULL
);
7762 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
7763 proto_tree_add_uint(atree
, hf_ndps_num_win31_keys
, tvb
, foffset
, 4, number_of_items2
);
7764 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, 4, ett_ndps
, &bitem
, "Windows 3.1 Keys");
7766 for (jj
= 0; jj
< number_of_items2
; jj
++ )
7768 if (jj
>= NDPS_MAX_ITEMS
) {
7769 expert_add_info(pinfo
, bitem
, &ei_ndps_truncated
);
7772 foffset
= ndps_string(tvb
, hf_ndps_windows_key
, btree
, foffset
, NULL
);
7774 proto_item_set_end(bitem
, tvb
, foffset
);
7775 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
7776 proto_tree_add_uint(atree
, hf_ndps_num_win95_keys
, tvb
, foffset
, 4, number_of_items2
);
7777 btree
= proto_tree_add_subtree(atree
, tvb
, foffset
, 4, ett_ndps
, &bitem
, "Windows 95 Keys");
7779 for (jj
= 0; jj
< number_of_items2
; jj
++ )
7781 if (jj
>= NDPS_MAX_ITEMS
) {
7782 expert_add_info(pinfo
, bitem
, &ei_ndps_truncated
);
7785 foffset
= ndps_string(tvb
, hf_ndps_windows_key
, btree
, foffset
, NULL
);
7787 proto_item_set_end(bitem
, tvb
, foffset
);
7788 proto_item_set_end(aitem
, tvb
, foffset
);
7791 case 10: /* Printer Definition File 2 */
7792 foffset
= ndps_string(tvb
, hf_ndps_def_file_name
, ndps_tree
, foffset
, NULL
);
7793 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7794 expert_item
= proto_tree_add_uint(ndps_tree
, hf_os_count
, tvb
, foffset
, 4, number_of_items
);
7796 for (ii
= 0; ii
< number_of_items
; ii
++ )
7798 if (ii
>= NDPS_MAX_ITEMS
) {
7799 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7802 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "OS %d", ii
+1);
7803 proto_tree_add_item(atree
, hf_os_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7805 number_of_items2
= tvb_get_ntohl(tvb
, foffset
);
7806 expert_item
= proto_tree_add_uint(atree
, hf_ndps_num_windows_keys
, tvb
, foffset
, 4, number_of_items2
);
7808 for (jj
= 0; jj
< number_of_items2
; jj
++ )
7810 if (jj
>= NDPS_MAX_ITEMS
) {
7811 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7814 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Key %d", jj
+1);
7815 foffset
= ndps_string(tvb
, hf_ndps_windows_key
, btree
, foffset
, NULL
);
7816 proto_item_set_end(bitem
, tvb
, foffset
);
7818 proto_item_set_end(aitem
, tvb
, foffset
);
7821 case 8: /* Generic Type */
7822 case 11: /* Printer Driver Types 2 */
7823 case 13: /* Printer Driver Types Archive */
7824 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7825 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_printer_type_count
, tvb
, foffset
, 4, number_of_items
);
7827 for (ii
= 0; ii
< number_of_items
; ii
++ )
7829 if (ii
>= NDPS_MAX_ITEMS
) {
7830 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7833 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Type %d", ii
+1);
7834 foffset
= ndps_string(tvb
, hf_ndps_printer_manuf
, atree
, foffset
, NULL
);
7835 foffset
= ndps_string(tvb
, hf_ndps_printer_type
, atree
, foffset
, NULL
);
7836 foffset
= ndps_string(tvb
, hf_ndps_prn_file_name
, atree
, foffset
, NULL
);
7837 foffset
= ndps_string(tvb
, hf_ndps_prn_dir_name
, atree
, foffset
, NULL
);
7838 proto_tree_add_item(atree
, hf_archive_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7840 proto_tree_add_item(atree
, hf_archive_file_size
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7842 proto_item_set_end(aitem
, tvb
, foffset
);
7845 case 14: /* Languages Available */
7846 number_of_items
= tvb_get_ntohl(tvb
, foffset
);
7847 expert_item
= proto_tree_add_uint(ndps_tree
, hf_ndps_language_count
, tvb
, foffset
, 4, number_of_items
);
7849 for (ii
= 0; ii
< number_of_items
; ii
++ )
7851 if (ii
>= NDPS_MAX_ITEMS
) {
7852 expert_add_info(pinfo
, expert_item
, &ei_ndps_truncated
);
7855 atree
= proto_tree_add_subtree_format(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Language %d", ii
+1);
7856 proto_tree_add_item(atree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7858 proto_item_set_end(aitem
, tvb
, foffset
);
7865 case 0x00000006: /* Get Resource File */
7866 proto_tree_add_item(ndps_tree
, hf_ndps_return_code
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7868 if (tvb_get_ntohl(tvb
, foffset
-4) != 0)
7869 col_set_str(pinfo
->cinfo
, COL_INFO
, "R NDPS - Error");
7870 if (tvb_get_ntohl(tvb
, foffset
-4) != 0)
7874 proto_tree_add_item(ndps_tree
, hf_get_status_flag
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7876 proto_tree_add_item(ndps_tree
, hf_file_timestamp
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7878 proto_tree_add_item(ndps_tree
, hf_ndps_data
, tvb
, foffset
, -1, ENC_NA
);
7880 case 0x00000007: /* Get Resource File Date */
7881 proto_tree_add_item(ndps_tree
, hf_ndps_return_code
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7883 if (tvb_get_ntohl(tvb
, foffset
-4) != 0)
7884 col_set_str(pinfo
->cinfo
, COL_INFO
, "R NDPS - Error");
7885 if (tvb_get_ntohl(tvb
, foffset
-4) != 0)
7889 proto_tree_add_item(ndps_tree
, hf_file_timestamp
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7892 case 0x00000008: /* Get Resource Manager NDS Object Name */
7893 foffset
= qualifiedname(tvb
, ndps_tree
, foffset
);
7894 proto_tree_add_uint(ndps_tree
, hf_ndps_error_val
, tvb
, foffset
, 4, error_val
);
7897 case 0x00000009: /* Get Resource Manager Session Information */
7898 proto_tree_add_item(ndps_tree
, hf_ndps_get_resman_session_type
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7900 proto_tree_add_item(ndps_tree
, hf_time
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7902 foffset
= return_code(tvb
, pinfo
, ndps_tree
, foffset
);
7904 case 0x0000000a: /* Set Resource Language Context */
7905 proto_tree_add_item(ndps_tree
, hf_ndps_return_code
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7907 if (tvb_get_ntohl(tvb
, foffset
-4) != 0)
7908 col_set_str(pinfo
->cinfo
, COL_INFO
, "R NDPS - Error");
7909 if (tvb_get_ntohl(tvb
, foffset
-4) != 0)
7913 proto_tree_add_item(ndps_tree
, hf_ndps_language_id
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7920 case 0x06097b: /* Delivery */
7923 case 0x00000001: /* Delivery Bind */
7924 proto_tree_add_item(ndps_tree
, hf_ndps_return_code
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7926 if (tvb_get_ntohl(tvb
, foffset
-4) != 0)
7927 col_set_str(pinfo
->cinfo
, COL_INFO
, "R NDPS - Error");
7929 case 0x00000002: /* Delivery Unbind */
7932 case 0x00000003: /* Delivery Send */
7933 case 0x00000004: /* Delivery Send2 */
7934 proto_tree_add_item(ndps_tree
, hf_ndps_return_code
, tvb
, foffset
, 4, ENC_BIG_ENDIAN
);
7936 if (tvb_get_ntohl(tvb
, foffset
-4) != 0)
7937 col_set_str(pinfo
->cinfo
, COL_INFO
, "R NDPS - Error");
7938 if (tvb_get_ntohl(tvb
, foffset
-4) != 0)
7942 number_of_items
=tvb_get_ntohl(tvb
, foffset
);
7943 proto_tree_add_uint(ndps_tree
, hf_ndps_item_count
, tvb
, foffset
, 4, number_of_items
);
7945 atree
= proto_tree_add_subtree(ndps_tree
, tvb
, foffset
, -1, ett_ndps
, &aitem
, "Failed Items");
7946 for (ii
= 0; ii
< number_of_items
; ii
++ )
7948 if (ii
>= NDPS_MAX_ITEMS
) {
7949 expert_add_info(pinfo
, aitem
, &ei_ndps_truncated
);
7952 btree
= proto_tree_add_subtree_format(atree
, tvb
, foffset
, -1, ett_ndps
, &bitem
, "Item %d", ii
+1);
7953 length
=tvb_get_ntohl(tvb
, foffset
);
7954 length_remaining
= tvb_reported_length_remaining(tvb
, foffset
);
7955 if(length_remaining
== -1 || (uint32_t) length_remaining
< length
)
7959 proto_tree_add_item(btree
, hf_ndps_item_ptr
, tvb
, foffset
, length
, ENC_NA
);
7961 proto_item_set_end(bitem
, tvb
, foffset
);
7963 proto_item_set_end(aitem
, tvb
, foffset
);
7976 proto_register_ndps(void)
7978 static hf_register_info hf_ndps
[] = {
7979 { &hf_ndps_record_mark
,
7980 { "Record Mark", "ndps.record_mark", FT_UINT16
, BASE_HEX
, NULL
, 0x0,
7983 { &hf_ndps_packet_type
,
7984 { "Packet Type", "ndps.packet_type",
7985 FT_UINT32
, BASE_HEX
, VALS(ndps_packet_types
), 0x0,
7989 { "Record Length", "ndps.record_length",
7990 FT_UINT16
, BASE_DEC
, NULL
, 0x0,
7994 { "Exchange ID", "ndps.xid",
7995 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
7998 { &hf_ndps_rpc_version
,
7999 { "RPC Version", "ndps.rpc_version",
8000 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8003 { &hf_spx_ndps_program
,
8004 { "NDPS Program Number", "spx.ndps_program",
8005 FT_UINT32
, BASE_HEX
, VALS(spx_ndps_program_vals
), 0x0,
8008 { &hf_spx_ndps_version
,
8009 { "Program Version", "spx.ndps_version",
8010 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8015 { "NDPS Error", "spx.ndps_error",
8016 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8020 { &hf_ndps_other_error_string
,
8021 { "Extended Error String", "ndps.ext_err_string",
8022 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8025 { &hf_spx_ndps_func_print
,
8026 { "Print Program", "spx.ndps_func_print",
8027 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &spx_ndps_print_func_vals_ext
, 0x0,
8030 { &hf_spx_ndps_func_notify
,
8031 { "Notify Program", "spx.ndps_func_notify",
8032 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &spx_ndps_notify_func_vals_ext
, 0x0,
8035 { &hf_spx_ndps_func_delivery
,
8036 { "Delivery Program", "spx.ndps_func_delivery",
8037 FT_UINT32
, BASE_HEX
, VALS(spx_ndps_deliver_func_vals
), 0x0,
8040 { &hf_spx_ndps_func_registry
,
8041 { "Registry Program", "spx.ndps_func_registry",
8042 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &spx_ndps_registry_func_vals_ext
, 0x0,
8045 { &hf_spx_ndps_func_resman
,
8046 { "ResMan Program", "spx.ndps_func_resman",
8047 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &spx_ndps_resman_func_vals_ext
, 0x0,
8050 { &hf_spx_ndps_func_broker
,
8051 { "Broker Program", "spx.ndps_func_broker",
8052 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &spx_ndps_broker_func_vals_ext
, 0x0,
8055 { &hf_ndps_num_objects
,
8056 { "Number of Objects", "ndps.num_objects",
8057 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8060 { &hf_ndps_num_attributes
,
8061 { "Number of Attributes", "ndps.num_attributes",
8062 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8067 { "Server", "ndps.sbuffer",
8068 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8074 { "Connection", "ndps.rbuffer",
8075 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8079 { &hf_ndps_user_name
,
8080 { "Trustee Name", "ndps.user_name",
8081 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8084 { &hf_ndps_broker_name
,
8085 { "Broker Name", "ndps.broker_name",
8086 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8089 { &hf_ndps_num_results
,
8090 { "Number of Results", "ndps.num_results",
8091 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8094 { &hf_ndps_num_options
,
8095 { "Number of Options", "ndps.num_options",
8096 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8099 { &hf_ndps_num_jobs
,
8100 { "Number of Jobs", "ndps.num_jobs",
8101 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8105 { "Printer Name", "ndps.pa_name",
8106 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8110 { "Tree", "ndps.tree",
8111 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8114 { &hf_ndps_reqframe
,
8115 { "Request Frame", "ndps.reqframe",
8116 FT_FRAMENUM
, BASE_NONE
, NULL
, 0x0,
8119 { &hf_ndps_error_val
,
8120 { "Return Status", "ndps.error_val",
8121 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &ndps_error_types_ext
, 0x0,
8125 { "Object ID", "ndps.object",
8126 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8129 { &hf_ndps_cred_type
,
8130 { "Credential Type", "ndps.cred_type",
8131 FT_UINT32
, BASE_HEX
, VALS(ndps_credential_enum
), 0x0,
8134 { &hf_ndps_server_name
,
8135 { "Server Name", "ndps.server_name",
8136 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8139 { &hf_ndps_connection
,
8140 { "Connection", "ndps.connection",
8141 FT_UINT16
, BASE_DEC
, NULL
, 0x0,
8144 { &hf_ndps_ext_error
,
8145 { "Extended Error Code", "ndps.ext_error",
8146 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8149 { &hf_ndps_auth_null
,
8150 { "Auth Null", "ndps.auth_null",
8151 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8154 { &hf_ndps_rpc_accept
,
8155 { "RPC Accept or Deny", "ndps.rpc_acc",
8156 FT_UINT32
, BASE_HEX
, VALS(true_false
), 0x0,
8159 { &hf_ndps_rpc_acc_stat
,
8160 { "RPC Accept Status", "ndps.rpc_acc_stat",
8161 FT_UINT32
, BASE_HEX
, VALS(accept_stat
), 0x0,
8164 { &hf_ndps_rpc_rej_stat
,
8165 { "RPC Reject Status", "ndps.rpc_rej_stat",
8166 FT_UINT32
, BASE_HEX
, VALS(reject_stat
), 0x0,
8169 { &hf_ndps_rpc_acc_results
,
8170 { "RPC Accept Results", "ndps.rpc_acc_res",
8171 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8174 { &hf_ndps_problem_type
,
8175 { "Problem Type", "ndps.rpc_prob_type",
8176 FT_UINT32
, BASE_HEX
, VALS(error_type_enum
), 0x0,
8179 { &hf_security_problem_type
,
8180 { "Security Problem", "ndps.rpc_sec_prob",
8181 FT_UINT32
, BASE_HEX
, VALS(security_problem_enum
), 0x0,
8184 { &hf_service_problem_type
,
8185 { "Service Problem", "ndps.rpc_serv_prob",
8186 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &service_problem_enum_ext
, 0x0,
8189 { &hf_access_problem_type
,
8190 { "Access Problem", "ndps.rpc_acc_prob",
8191 FT_UINT32
, BASE_HEX
, VALS(access_problem_enum
), 0x0,
8194 { &hf_printer_problem_type
,
8195 { "Printer Problem", "ndps.rpc_print_prob",
8196 FT_UINT32
, BASE_HEX
, VALS(printer_problem_enum
), 0x0,
8199 { &hf_selection_problem_type
,
8200 { "Selection Problem", "ndps.rpc_sel_prob",
8201 FT_UINT32
, BASE_HEX
, VALS(selection_problem_enum
), 0x0,
8204 { &hf_doc_access_problem_type
,
8205 { "Document Access Problem", "ndps.rpc_doc_acc_prob",
8206 FT_UINT32
, BASE_HEX
, VALS(doc_access_problem_enum
), 0x0,
8209 { &hf_attribute_problem_type
,
8210 { "Attribute Problem", "ndps.rpc_attr_prob",
8211 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &attribute_problem_enum_ext
, 0x0,
8214 { &hf_update_problem_type
,
8215 { "Update Problem", "ndps.rpc_update_prob",
8216 FT_UINT32
, BASE_HEX
, VALS(update_problem_enum
), 0x0,
8220 { "Object ID Type", "ndps.rpc_obj_id_type",
8221 FT_UINT32
, BASE_HEX
, VALS(obj_identification_enum
), 0x0,
8224 { &hf_oid_struct_size
,
8225 { "OID Struct Size", "ndps.rpc_oid_struct_size",
8226 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8230 { "Object Name", "ndps.object_name",
8231 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8234 { &hf_ndps_document_number
,
8235 { "Document Number", "ndps.doc_num",
8236 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8239 { &hf_ndps_doc_content
,
8240 { "Document Content", "ndps.doc_content",
8241 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8244 { &hf_ndps_nameorid
,
8245 { "Name or ID Type", "ndps.nameorid",
8246 FT_UINT32
, BASE_HEX
, VALS(nameorid_enum
), 0x0,
8249 { &hf_ndps_local_object_name
,
8250 { "Local Object Name", "ndps.loc_object_name",
8251 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8254 { &hf_ndps_printer_name
,
8255 { "Printer Name", "ndps.printer_name",
8256 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8259 { &hf_ndps_qualified_name
,
8260 { "Qualified Name Type", "ndps.qual_name_type",
8261 FT_UINT32
, BASE_HEX
, VALS(qualified_name_enum
), 0x0,
8265 { &hf_ndps_qualified_name2
,
8266 { "Qualified Name Type", "ndps.qual_name_type2",
8267 FT_UINT32
, BASE_HEX
, VALS(qualified_name_enum2
), 0x0,
8271 { &hf_ndps_item_count
,
8272 { "Number of Items", "ndps.item_count",
8273 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8276 { &hf_ndps_num_passwords
,
8277 { "Number of Passwords", "ndps.num_passwords",
8278 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8281 { &hf_ndps_num_servers
,
8282 { "Number of Servers", "ndps.num_servers",
8283 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8286 { &hf_ndps_num_locations
,
8287 { "Number of Locations", "ndps.num_locations",
8288 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8291 { &hf_ndps_num_areas
,
8292 { "Number of Areas", "ndps.num_areas",
8293 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8296 { &hf_ndps_num_address_items
,
8297 { "Number of Address Items", "ndps.num_address_items",
8298 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8301 { &hf_ndps_num_job_categories
,
8302 { "Number of Job Categories", "ndps.num_job_categories",
8303 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8306 { &hf_ndps_num_page_selects
,
8307 { "Number of Page Select Items", "ndps.num_page_selects",
8308 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8311 { &hf_ndps_num_page_informations
,
8312 { "Number of Page Information Items", "ndps.num_page_informations",
8313 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8316 { &hf_ndps_num_names
,
8317 { "Number of Names", "ndps.num_names",
8318 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8321 { &hf_ndps_num_categories
,
8322 { "Number of Categories", "ndps.num_categories",
8323 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8326 { &hf_ndps_num_colorants
,
8327 { "Number of Colorants", "ndps.num_colorants",
8328 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8331 { &hf_ndps_num_events
,
8332 { "Number of Events", "ndps.num_events",
8333 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8336 { &hf_ndps_num_args
,
8337 { "Number of Arguments", "ndps.num_argss",
8338 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8341 { &hf_ndps_num_transfer_methods
,
8342 { "Number of Transfer Methods", "ndps.num_transfer_methods",
8343 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8346 { &hf_ndps_num_doc_types
,
8347 { "Number of Document Types", "ndps.num_doc_types",
8348 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8351 { &hf_ndps_num_destinations
,
8352 { "Number of Destinations", "ndps.num_destinations",
8353 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8356 { &hf_ndps_qualifier
,
8357 { "Qualifier", "ndps.qual",
8358 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8361 { &hf_ndps_lib_error
,
8362 { "Library Error", "ndps.lib_error",
8363 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &ndps_error_types_ext
, 0x0,
8366 { &hf_ndps_other_error
,
8367 { "Other Error", "ndps.other_error",
8368 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &ndps_error_types_ext
, 0x0,
8371 { &hf_ndps_other_error_2
,
8372 { "Other Error 2", "ndps.other_error_2",
8373 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &ndps_error_types_ext
, 0x0,
8377 { "Session Handle", "ndps.session",
8378 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8381 { &hf_ndps_abort_flag
,
8382 { "Abort?", "ndps.abort",
8383 FT_BOOLEAN
, BASE_NONE
, NULL
, 0x0,
8386 { &hf_ndps_obj_attribute_type
,
8387 { "Value Syntax", "ndps.attrib_type",
8388 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &ndps_attribute_enum_ext
, 0x0,
8391 { &hf_ndps_attribute_value
,
8392 { "Value", "ndps.attribute_value",
8393 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8396 { &hf_ndps_lower_range
,
8397 { "Lower Range", "ndps.lower_range",
8398 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8401 { &hf_ndps_upper_range
,
8402 { "Upper Range", "ndps.upper_range",
8403 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8407 { "Value", "ndps.n64",
8408 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8411 { &hf_ndps_lower_range_n64
,
8412 { "Lower Range", "ndps.lower_range_n64",
8413 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8416 { &hf_ndps_upper_range_n64
,
8417 { "Upper Range", "ndps.upper_range_n64",
8418 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8421 { &hf_ndps_attrib_boolean
,
8422 { "Value?", "ndps.attrib_boolean",
8423 FT_BOOLEAN
, BASE_NONE
, NULL
, 0x0,
8426 { &hf_ndps_realization
,
8427 { "Realization Type", "ndps.realization",
8428 FT_UINT32
, BASE_HEX
, VALS(ndps_realization_enum
), 0x0,
8431 { &hf_ndps_xdimension_n64
,
8432 { "X Dimension", "ndps.xdimension_n64",
8433 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8436 { &hf_ndps_ydimension_n64
,
8437 { "Y Dimension", "ndps.ydimension_n64",
8438 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8441 { &hf_ndps_dim_value
,
8442 { "Dimension Value Type", "ndps.dim_value",
8443 FT_UINT32
, BASE_HEX
, VALS(ndps_dim_value_enum
), 0x0,
8446 { &hf_ndps_dim_flag
,
8447 { "Dimension Flag", "ndps.dim_falg",
8448 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8451 { &hf_ndps_xydim_value
,
8452 { "XY Dimension Value Type", "ndps.xydim_value",
8453 FT_UINT32
, BASE_HEX
, VALS(ndps_xydim_value_enum
), 0x0,
8456 { &hf_ndps_location_value
,
8457 { "Location Value Type", "ndps.location_value",
8458 FT_UINT32
, BASE_HEX
, VALS(ndps_location_value_enum
), 0x0,
8461 { &hf_ndps_xmin_n64
,
8462 { "Minimum X Dimension", "ndps.xmin_n64",
8463 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8466 { &hf_ndps_xmax_n64
,
8467 { "Maximum X Dimension", "ndps.xmax_n64",
8468 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8471 { &hf_ndps_ymin_n64
,
8472 { "Minimum Y Dimension", "ndps.ymin_n64",
8473 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8476 { &hf_ndps_ymax_n64
,
8477 { "Maximum Y Dimension", "ndps.ymax_n64",
8478 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8481 { &hf_ndps_edge_value
,
8482 { "Edge Value", "ndps.edge_value",
8483 FT_UINT32
, BASE_HEX
, VALS(ndps_edge_value_enum
), 0x0,
8486 { &hf_ndps_cardinal_or_oid
,
8487 { "Cardinal or OID", "ndps.car_or_oid",
8488 FT_UINT32
, BASE_HEX
, VALS(ndps_card_or_oid_enum
), 0x0,
8491 { &hf_ndps_cardinal_name_or_oid
,
8492 { "Cardinal Name or OID", "ndps.car_name_or_oid",
8493 FT_UINT32
, BASE_HEX
, VALS(ndps_card_name_or_oid_enum
), 0x0,
8496 { &hf_ndps_integer_or_oid
,
8497 { "Integer or OID", "ndps.integer_or_oid",
8498 FT_UINT32
, BASE_HEX
, VALS(ndps_integer_or_oid_enum
), 0x0,
8501 { &hf_ndps_profile_id
,
8502 { "Profile ID", "ndps.profile_id",
8503 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8506 { &hf_ndps_persistence
,
8507 { "Persistence", "ndps.persistence",
8508 FT_UINT32
, BASE_HEX
, VALS(ndps_persistence_enum
), 0x0,
8511 { &hf_ndps_language_count
,
8512 { "Number of Languages", "ndps.language_count",
8513 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8516 { &hf_ndps_language_id
,
8517 { "Language ID", "ndps.lang_id",
8518 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8522 { "Address Type", "ndps.address_type",
8523 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &ndps_address_type_enum_ext
, 0x0,
8527 { "Address", "ndps.address",
8528 FT_UINT32
, BASE_HEX
, VALS(ndps_address_enum
), 0x0,
8531 { &hf_ndps_add_bytes
,
8532 { "Address Bytes", "ndps.add_bytes",
8533 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8536 { &hf_ndps_event_type
,
8537 { "Event Type", "ndps.event_type",
8538 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8541 { &hf_ndps_event_object_identifier
,
8542 { "Event Object Type", "ndps.event_object_identifier",
8543 FT_UINT32
, BASE_HEX
, VALS(ndps_event_object_enum
), 0x0,
8546 { &hf_ndps_octet_string
,
8547 { "Octet String", "ndps.octet_string",
8548 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8552 { "Scope", "ndps.scope",
8553 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8557 { "Address Length", "ndps.addr_len",
8558 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8562 { "IPX Network", "ndps.net",
8563 FT_IPXNET
, BASE_NONE
, NULL
, 0x0,
8567 { "Node", "ndps.node",
8568 FT_ETHER
, BASE_NONE
, NULL
, 0x0,
8572 { "IPX Socket", "ndps.socket",
8573 FT_UINT16
, BASE_HEX
, NULL
, 0x0,
8577 { "IP Port", "ndps.port",
8578 FT_UINT16
, BASE_DEC
, NULL
, 0x0,
8582 { "IP Address", "ndps.ip",
8583 FT_IPv4
, BASE_NONE
, NULL
, 0x0,
8586 { &hf_ndps_server_type
,
8587 { "NDPS Server Type", "ndps.server_type",
8588 FT_UINT32
, BASE_HEX
, VALS(ndps_server_type_enum
), 0x0,
8591 { &hf_ndps_num_services
,
8592 { "Number of Services", "ndps.num_services",
8593 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8596 { &hf_ndps_service_type
,
8597 { "NDPS Service Type", "ndps.service_type",
8598 FT_UINT32
, BASE_HEX
, VALS(ndps_service_type_enum
), 0x0,
8601 { &hf_ndps_service_enabled
,
8602 { "Service Enabled?", "ndps.service_enabled",
8603 FT_BOOLEAN
, BASE_NONE
, NULL
, 0x0,
8606 { &hf_ndps_method_name
,
8607 { "Method Name", "ndps.method_name",
8608 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8611 { &hf_ndps_method_ver
,
8612 { "Method Version", "ndps.method_ver",
8613 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8616 { &hf_ndps_file_name
,
8617 { "File Name", "ndps.file_name",
8618 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8621 { &hf_ndps_admin_submit
,
8622 { "Admin Submit Flag?", "ndps.admin_submit_flag",
8623 FT_BOOLEAN
, BASE_NONE
, NULL
, 0x0,
8627 { "Object ID", "ndps.oid",
8628 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8631 { &hf_ndps_object_op
,
8632 { "Operation", "ndps.object_op",
8633 FT_UINT32
, BASE_HEX
, VALS(ndps_object_op_enum
), 0x0,
8637 { "Answer Time", "ndps.answer_time",
8638 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8641 { &hf_oid_asn1_type
,
8642 { "ASN.1 Type", "ndps.asn1_type",
8643 FT_UINT16
, BASE_DEC
, NULL
, 0x0,
8646 { &hf_ndps_item_ptr
,
8647 { "Item Pointer", "ndps.item_ptr",
8648 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8652 { "Length", "ndps.len",
8653 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8656 { &hf_ndps_limit_enc
,
8657 { "Limit Encountered", "ndps.limit_enc",
8658 FT_UINT32
, BASE_HEX
, VALS(ndps_limit_enc_enum
), 0x0,
8661 { &hf_ndps_delivery_add_count
,
8662 { "Number of Delivery Addresses", "ndps.delivery_add_count",
8663 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8666 { &hf_ndps_delivery_add_type
,
8667 { "Delivery Address Type", "ndps.delivery_add_type",
8668 FT_UINT32
, BASE_HEX
, VALS(ndps_delivery_add_enum
), 0x0,
8671 { &hf_ndps_criterion_type
,
8672 { "Criterion Type", "ndps.criterion_type",
8673 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &ndps_attribute_enum_ext
, 0x0,
8676 { &hf_ndps_num_ignored_attributes
,
8677 { "Number of Ignored Attributes", "ndps.num_ignored_attributes",
8678 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8681 { &hf_ndps_ignored_type
,
8682 { "Ignored Type", "ndps.ignored_type",
8683 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &ndps_attribute_enum_ext
, 0x0,
8686 { &hf_ndps_num_resources
,
8687 { "Number of Resources", "ndps.num_resources",
8688 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8691 { &hf_ndps_resource_type
,
8692 { "Resource Type", "ndps.resource_type",
8693 FT_UINT32
, BASE_HEX
, VALS(ndps_resource_enum
), 0x0,
8696 { &hf_ndps_identifier_type
,
8697 { "Identifier Type", "ndps.identifier_type",
8698 FT_UINT32
, BASE_HEX
, VALS(ndps_identifier_enum
), 0x0,
8701 { &hf_ndps_page_flag
,
8702 { "Page Flag", "ndps.page_flag",
8703 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8706 { &hf_ndps_media_type
,
8707 { "Media Type", "ndps.media_type",
8708 FT_UINT32
, BASE_HEX
, VALS(ndps_media_enum
), 0x0,
8711 { &hf_ndps_page_size
,
8712 { "Page Size", "ndps.page_size",
8713 FT_UINT32
, BASE_HEX
, VALS(ndps_page_size_enum
), 0x0,
8716 { &hf_ndps_direction
,
8717 { "Direction", "ndps.direction",
8718 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &ndps_pres_direction_enum_ext
, 0x0,
8721 { &hf_ndps_page_order
,
8722 { "Page Order", "ndps.page_order",
8723 FT_UINT32
, BASE_HEX
, VALS(ndps_page_order_enum
), 0x0,
8726 { &hf_ndps_medium_size
,
8727 { "Medium Size", "ndps.medium_size",
8728 FT_UINT32
, BASE_HEX
, VALS(ndps_medium_size_enum
), 0x0,
8731 { &hf_ndps_long_edge_feeds
,
8732 { "Long Edge Feeds?", "ndps.long_edge_feeds",
8733 FT_BOOLEAN
, BASE_NONE
, NULL
, 0x0,
8736 { &hf_ndps_inc_across_feed
,
8737 { "Increment Across Feed", "ndps.inc_across_feed",
8738 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8741 { &hf_ndps_size_inc_in_feed
,
8742 { "Size Increment in Feed", "ndps.size_inc_in_feed",
8743 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8746 { &hf_ndps_page_orientation
,
8747 { "Page Orientation", "ndps.page_orientation",
8748 FT_UINT32
, BASE_HEX
, VALS(ndps_page_orientation_enum
), 0x0,
8751 { &hf_ndps_numbers_up
,
8752 { "Numbers Up", "ndps.numbers_up",
8753 FT_UINT32
, BASE_HEX
, VALS(ndps_numbers_up_enum
), 0x0,
8756 { &hf_ndps_xdimension
,
8757 { "X Dimension", "ndps.xdimension",
8758 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8761 { &hf_ndps_ydimension
,
8762 { "Y Dimension", "ndps.ydimension",
8763 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
8766 { &hf_ndps_state_severity
,
8767 { "State Severity", "ndps.state_severity",
8768 FT_UINT32
, BASE_HEX
, VALS(ndps_state_severity_enum
), 0x0,
8771 { &hf_ndps_training
,
8772 { "Training", "ndps.training",
8773 FT_UINT32
, BASE_HEX
, VALS(ndps_training_enum
), 0x0,
8776 { &hf_ndps_colorant_set
,
8777 { "Colorant Set", "ndps.colorant_set",
8778 FT_UINT32
, BASE_HEX
, VALS(ndps_colorant_set_enum
), 0x0,
8781 { &hf_ndps_card_enum_time
,
8782 { "Cardinal, Enum, or Time", "ndps.card_enum_time",
8783 FT_UINT32
, BASE_HEX
, VALS(ndps_card_enum_time_enum
), 0x0,
8786 { &hf_ndps_attrs_arg
,
8787 { "List Attribute Operation", "ndps.attrs_arg",
8788 FT_UINT32
, BASE_HEX
, VALS(ndps_attrs_arg_enum
), 0x0,
8791 { &hf_ndps_context_len
,
8792 { "Context Length", "ndps.context_len",
8793 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8797 { "Context", "ndps.context",
8798 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8802 { "Filter Type", "ndps.filter",
8803 FT_UINT32
, BASE_HEX
, VALS(ndps_filter_enum
), 0x0,
8807 { &hf_ndps_item_filter
,
8808 { "Filter Item Operation", "ndps.filter_item",
8809 FT_UINT32
, BASE_HEX
, VALS(ndps_filter_item_enum
), 0x0,
8814 { &hf_ndps_substring_match
,
8815 { "Substring Match", "ndps.substring_match",
8816 FT_UINT32
, BASE_HEX
, VALS(ndps_match_criteria_enum
), 0x0,
8820 { &hf_ndps_time_limit
,
8821 { "Time Limit", "ndps.time_limit",
8822 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8825 { &hf_ndps_count_limit
,
8826 { "Count Limit", "ndps.count_limit",
8827 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8830 { &hf_ndps_operator
,
8831 { "Operator Type", "ndps.operator",
8832 FT_UINT32
, BASE_DEC
, VALS(ndps_operator_enum
), 0x0,
8835 { &hf_ndps_password
,
8836 { "Password", "ndps.password",
8837 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8840 { &hf_ndps_retrieve_restrictions
,
8841 { "Retrieve Restrictions", "ndps.ret_restrict",
8842 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8845 { &hf_ndps_bind_security_option_count
,
8846 { "Number of Bind Security Options", "ndps.bind_security_count",
8847 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8850 { &hf_bind_security
,
8851 { "Bind Security Options", "ndps.bind_security",
8852 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8855 { &hf_ndps_max_items
,
8856 { "Maximum Items in List", "ndps.max_items",
8857 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8860 { &hf_ndps_status_flags
,
8861 { "Status Flag", "ndps.status_flags",
8862 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8865 { &hf_ndps_resource_list_type
,
8866 { "Resource Type", "ndps.resource_type",
8867 FT_UINT32
, BASE_DEC
| BASE_EXT_STRING
, &ndps_resource_type_enum_ext
, 0x0,
8871 { "Number of OSes", "ndps.os_count",
8872 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8876 { "OS Type", "ndps.os_type",
8877 FT_UINT32
, BASE_DEC
| BASE_EXT_STRING
, &ndps_os_type_enum_ext
, 0x0,
8880 { &hf_ndps_printer_type_count
,
8881 { "Number of Printer Types", "ndps.printer_type_count",
8882 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8885 { &hf_ndps_printer_type
,
8886 { "Printer Type", "ndps.prn_type",
8887 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8890 { &hf_ndps_printer_manuf
,
8891 { "Printer Manufacturer", "ndps.prn_manuf",
8892 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8895 { &hf_ndps_inf_file_name
,
8896 { "INF File Name", "ndps.inf_file_name",
8897 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8900 { &hf_ndps_vendor_dir
,
8901 { "Vendor Directory", "ndps.vendor_dir",
8902 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8906 { "Banner Type", "ndps.banner_type",
8907 FT_UINT32
, BASE_DEC
, VALS(ndps_banner_type_enum
), 0x0,
8911 { "Font Type", "ndps.font_type",
8912 FT_UINT32
, BASE_DEC
, VALS(ndps_font_type_enum
), 0x0,
8916 { "Printer ID", "ndps.printer_id",
8917 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
8920 { &hf_ndps_font_name
,
8921 { "Font Name", "ndps.font_name",
8922 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8925 { &hf_ndps_return_code
,
8926 { "Return Code", "ndps.ret_code",
8927 FT_UINT32
, BASE_HEX
| BASE_EXT_STRING
, &ndps_error_types_ext
, 0x0,
8931 { &hf_ndps_banner_count
,
8932 { "Number of Banners", "ndps.banner_count",
8933 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8937 { &hf_ndps_banner_name
,
8938 { "Banner Name", "ndps.banner_name",
8939 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8942 { &hf_ndps_font_type_count
,
8943 { "Number of Font Types", "ndps.font_type_count",
8944 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8947 { &hf_font_type_name
,
8948 { "Font Type Name", "ndps.font_type_name",
8949 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8952 { &hf_ndps_font_file_count
,
8953 { "Number of Font Files", "ndps.font_file_count",
8954 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8957 { &hf_font_file_name
,
8958 { "Font File Name", "ndps.font_file_name",
8959 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8962 { &hf_ndps_printer_def_count
,
8963 { "Number of Printer Definitions", "ndps.printer_def_count",
8964 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8967 { &hf_ndps_prn_file_name
,
8968 { "Printer File Name", "ndps.print_file_name",
8969 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8972 { &hf_ndps_prn_dir_name
,
8973 { "Printer Directory Name", "ndps.print_dir_name",
8974 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8977 { &hf_ndps_def_file_name
,
8978 { "Printer Definition Name", "ndps.print_def_name",
8979 FT_STRING
, BASE_NONE
, NULL
, 0x0,
8982 { &hf_ndps_num_win31_keys
,
8983 { "Number of Windows 3.1 Keys", "ndps.num_win31_keys",
8984 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8987 { &hf_ndps_num_win95_keys
,
8988 { "Number of Windows 95 Keys", "ndps.num_win95_keys",
8989 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8992 { &hf_ndps_num_windows_keys
,
8993 { "Number of Windows Keys", "ndps.num_windows_keys",
8994 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
8997 { &hf_ndps_windows_key
,
8998 { "Windows Key", "ndps.windows_key",
8999 FT_STRING
, BASE_NONE
, NULL
, 0x0,
9003 { "Archive Type", "ndps.archive_type",
9004 FT_UINT32
, BASE_DEC
, VALS(ndps_archive_enum
), 0x0,
9007 { &hf_archive_file_size
,
9008 { "Archive File Size", "ndps.archive_size",
9009 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
9012 { &hf_ndps_segment_overlap
,
9013 { "Segment overlap", "ndps.segment.overlap", FT_BOOLEAN
, BASE_NONE
,
9014 NULL
, 0x0, "Segment overlaps with other segments", HFILL
}},
9016 { &hf_ndps_segment_overlap_conflict
,
9017 { "Conflicting data in segment overlap", "ndps.segment.overlap.conflict",
9018 FT_BOOLEAN
, BASE_NONE
,
9019 NULL
, 0x0, "Overlapping segments contained conflicting data", HFILL
}},
9021 { &hf_ndps_segment_multiple_tails
,
9022 { "Multiple tail segments found", "ndps.segment.multipletails",
9023 FT_BOOLEAN
, BASE_NONE
,
9024 NULL
, 0x0, "Several tails were found when desegmenting the packet", HFILL
}},
9026 { &hf_ndps_segment_too_long_segment
,
9027 { "Segment too long", "ndps.segment.toolongsegment", FT_BOOLEAN
, BASE_NONE
,
9028 NULL
, 0x0, "Segment contained data past end of packet", HFILL
}},
9030 { &hf_ndps_segment_error
,
9031 {"Desegmentation error", "ndps.segment.error", FT_FRAMENUM
, BASE_NONE
,
9032 NULL
, 0x0, "Desegmentation error due to illegal segments", HFILL
}},
9034 { &hf_ndps_segment_count
,
9035 {"Segment count", "ndps.segment.count", FT_UINT32
, BASE_DEC
,
9036 NULL
, 0x0, NULL
, HFILL
}},
9038 { &hf_ndps_reassembled_length
,
9039 {"Reassembled NDPS length", "ndps.reassembled.length", FT_UINT32
, BASE_DEC
,
9040 NULL
, 0x0, "The total length of the reassembled payload", HFILL
}},
9043 { "NDPS Fragment", "ndps.fragment", FT_FRAMENUM
, BASE_NONE
,
9044 NULL
, 0x0, NULL
, HFILL
}},
9046 { &hf_ndps_segments
,
9047 { "NDPS Fragments", "ndps.fragments", FT_NONE
, BASE_NONE
,
9048 NULL
, 0x0, NULL
, HFILL
}},
9051 { "Data", "ndps.data", FT_BYTES
, BASE_NONE
,
9052 NULL
, 0x0, NULL
, HFILL
}},
9054 { &hf_get_status_flag
,
9055 { "Get Status Flag", "ndps.get_status_flags",
9056 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
9060 { "Resource Type", "ndps.res_type",
9061 FT_UINT32
, BASE_DEC
, VALS(ndps_res_type_enum
), 0x0,
9064 { &hf_file_timestamp
,
9065 { "File Time Stamp", "ndps.file_time_stamp",
9066 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
9070 { "Print Type", "ndps.print_arg",
9071 FT_UINT32
, BASE_DEC
, VALS(ndps_print_arg_enum
), 0x0,
9075 { "Submission Complete?", "ndps.sub_complete", FT_BOOLEAN
, BASE_NONE
,
9076 NULL
, 0x0, NULL
, HFILL
}},
9079 { "Document Content", "ndps.doc_content",
9080 FT_UINT32
, BASE_DEC
, VALS(ndps_doc_content_enum
), 0x0,
9084 { &hf_ndps_doc_name
,
9085 { "Document Name", "ndps.doc_name",
9086 FT_STRING
, BASE_NONE
, NULL
, 0x0,
9091 { "Local ID", "ndps.local_id",
9092 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
9095 { &hf_ndps_included_doc_len
,
9096 { "Included Document Length", "ndps.included_doc_len",
9097 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
9100 { &hf_ndps_included_doc
,
9101 { "Included Document", "ndps.included_doc",
9102 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
9105 { &hf_ndps_ref_name
,
9106 { "Referenced Document Name", "ndps.ref_doc_name",
9107 FT_STRING
, BASE_NONE
, NULL
, 0x0,
9110 { &hf_interrupt_job_type
,
9111 { "Interrupt Job Identifier", "ndps.interrupt_job_type",
9112 FT_UINT32
, BASE_DEC
, VALS(ndps_interrupt_job_enum
), 0x0,
9115 { &hf_pause_job_type
,
9116 { "Pause Job Identifier", "ndps.pause_job_type",
9117 FT_UINT32
, BASE_DEC
, VALS(ndps_pause_job_enum
), 0x0,
9121 { "Force?", "ndps.force",
9122 FT_BOOLEAN
, BASE_NONE
, NULL
, 0x0,
9125 { &hf_resubmit_op_type
,
9126 { "Resubmit Operation Type", "ndps.resubmit_op_type",
9127 FT_UINT32
, BASE_DEC
, VALS(ndps_resubmit_op_enum
), 0x0,
9130 { &hf_shutdown_type
,
9131 { "Shutdown Type", "ndps.shutdown_type",
9132 FT_UINT32
, BASE_DEC
, VALS(ndps_shutdown_enum
), 0x0,
9135 { &hf_ndps_supplier_flag
,
9136 { "Supplier Data?", "ndps.supplier_flag",
9137 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
9140 { &hf_ndps_language_flag
,
9141 { "Language Data?", "ndps.language_flag",
9142 FT_BOOLEAN
, BASE_NONE
, NULL
, 0x0,
9145 { &hf_ndps_method_flag
,
9146 { "Method Data?", "ndps.method_flag",
9147 FT_BOOLEAN
, BASE_NONE
, NULL
, 0x0,
9150 { &hf_ndps_delivery_address_flag
,
9151 { "Delivery Address Data?", "ndps.delivery_flag",
9152 FT_BOOLEAN
, BASE_NONE
, NULL
, 0x0,
9155 { &hf_ndps_list_profiles_type
,
9156 { "List Profiles Type", "ndps.list_profiles_type",
9157 FT_UINT32
, BASE_HEX
, VALS(ndps_attrs_arg_enum
), 0x0,
9160 { &hf_ndps_list_profiles_choice_type
,
9161 { "List Profiles Choice Type", "ndps.list_profiles_choice_type",
9162 FT_UINT32
, BASE_HEX
, VALS(ndps_list_profiles_choice_enum
), 0x0,
9165 { &hf_ndps_list_profiles_result_type
,
9166 { "List Profiles Result Type", "ndps.list_profiles_result_type",
9167 FT_UINT32
, BASE_HEX
, VALS(ndps_list_profiles_result_enum
), 0x0,
9170 { &hf_ndps_integer_type_flag
,
9171 { "Integer Type Flag", "ndps.integer_type_flag",
9172 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
9175 { &hf_ndps_integer_type_value
,
9176 { "Integer Type Value", "ndps.integer_type_value",
9177 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
9180 { &hf_ndps_continuation_option
,
9181 { "Continuation Option", "ndps.continuation_option",
9182 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
9185 { &hf_ndps_ds_info_type
,
9186 { "DS Info Type", "ndps.ds_info_type",
9187 FT_UINT32
, BASE_HEX
, VALS(ndps_ds_info_enum
), 0x0,
9191 { "GUID", "ndps.guid",
9192 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
9195 { &hf_ndps_list_services_type
,
9196 { "Services Type", "ndps.list_services_type",
9197 FT_UINT32
, BASE_HEX
, VALS(ndps_list_services_enum
), 0x0,
9200 { &hf_ndps_item_bytes
,
9201 { "Item Ptr", "ndps.item_bytes",
9202 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
9205 { &hf_ndps_certified
,
9206 { "Certified", "ndps.certified",
9207 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
9210 { &hf_ndps_attribute_set
,
9211 { "Attribute Set", "ndps.attribute_set",
9212 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
9215 { &hf_ndps_data_item_type
,
9216 { "Item Type", "ndps.data_item_type",
9217 FT_UINT32
, BASE_HEX
, VALS(ndps_data_item_enum
), 0x0,
9221 { "Integer Value", "ndps.info_int",
9222 FT_UINT8
, BASE_HEX
, NULL
, 0x0,
9226 { "16 Bit Integer Value", "ndps.info_int16",
9227 FT_UINT16
, BASE_HEX
, NULL
, 0x0,
9231 { "32 Bit Integer Value", "ndps.info_int32",
9232 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
9236 { "Boolean Value", "ndps.info_boolean",
9237 FT_BOOLEAN
, BASE_NONE
, NULL
, 0x0,
9241 { "String Value", "ndps.info_string",
9242 FT_STRING
, BASE_NONE
, NULL
, 0x0,
9247 { "Byte Value", "ndps.info_bytes",
9248 FT_BYTES
, BASE_NONE
, NULL
, 0x0,
9252 { &hf_ndps_list_local_servers_type
,
9253 { "Server Type", "ndps.list_local_server_type",
9254 FT_UINT32
, BASE_HEX
, VALS(ndps_list_local_servers_enum
), 0x0,
9257 { &hf_ndps_registry_name
,
9258 { "Registry Name", "ndps.registry_name",
9259 FT_STRING
, BASE_NONE
, NULL
, 0x0,
9262 { &hf_ndps_client_server_type
,
9263 { "Client/Server Type", "ndps.client_server_type",
9264 FT_UINT32
, BASE_HEX
, VALS(ndps_client_server_enum
), 0x0,
9267 { &hf_ndps_session_type
,
9268 { "Session Type", "ndps.session_type",
9269 FT_UINT32
, BASE_HEX
, VALS(ndps_session_type_enum
), 0x0,
9273 { "Time", "ndps.time",
9274 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
9277 { &hf_ndps_supplier_name
,
9278 { "Supplier Name", "ndps.supplier_name",
9279 FT_STRING
, BASE_NONE
, NULL
, 0x0,
9283 { "Message", "ndps.message",
9284 FT_STRING
, BASE_NONE
, NULL
, 0x0,
9287 { &hf_ndps_delivery_method_count
,
9288 { "Number of Delivery Methods", "ndps.delivery_method_count",
9289 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
9292 { &hf_delivery_method_type
,
9293 { "Delivery Method Type", "ndps.delivery_method_type",
9294 FT_UINT32
, BASE_HEX
, VALS(ndps_delivery_method_enum
), 0x0,
9297 { &hf_ndps_get_session_type
,
9298 { "Session Type", "ndps.get_session_type",
9299 FT_UINT32
, BASE_HEX
, VALS(ndps_get_session_type_enum
), 0x0,
9303 { "Packet Count", "ndps.packet_count",
9304 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
9307 { &hf_last_packet_flag
,
9308 { "Last Packet Flag", "ndps.last_packet_flag",
9309 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
9312 { &hf_ndps_get_resman_session_type
,
9313 { "Session Type", "ndps.get_resman_session_type",
9314 FT_UINT32
, BASE_HEX
, VALS(ndps_get_resman_session_type_enum
), 0x0,
9318 { "Problem Type", "ndps.problem_type",
9319 FT_UINT32
, BASE_HEX
, VALS(problem_type_enum
), 0x0,
9322 { &hf_ndps_num_values
,
9323 { "Number of Values", "ndps.num_values",
9324 FT_UINT32
, BASE_DEC
, NULL
, 0x0,
9327 { &hf_ndps_object_ids_7
,
9328 { "Object ID Definition", "ndps.objectid_def7",
9329 FT_UINT32
, BASE_DEC
, NULL
,
9330 0x0, NULL
, HFILL
}},
9332 { &hf_ndps_object_ids_8
,
9333 { "Object ID Definition", "ndps.objectid_def8",
9334 FT_UINT32
, BASE_DEC
, NULL
,
9335 0x0, NULL
, HFILL
}},
9337 { &hf_ndps_object_ids_9
,
9338 { "Object ID Definition", "ndps.objectid_def9",
9339 FT_UINT32
, BASE_DEC
, NULL
,
9340 0x0, NULL
, HFILL
}},
9342 { &hf_ndps_object_ids_10
,
9343 { "Object ID Definition", "ndps.objectid_def10",
9344 FT_UINT32
, BASE_DEC
, NULL
,
9345 0x0, NULL
, HFILL
}},
9347 { &hf_ndps_object_ids_11
,
9348 { "Object ID Definition", "ndps.objectid_def11",
9349 FT_UINT32
, BASE_DEC
, NULL
,
9350 0x0, NULL
, HFILL
}},
9352 { &hf_ndps_object_ids_12
,
9353 { "Object ID Definition", "ndps.objectid_def12",
9354 FT_UINT32
, BASE_DEC
, NULL
,
9355 0x0, NULL
, HFILL
}},
9357 { &hf_ndps_object_ids_13
,
9358 { "Object ID Definition", "ndps.objectid_def13",
9359 FT_UINT32
, BASE_DEC
, NULL
,
9360 0x0, NULL
, HFILL
}},
9362 { &hf_ndps_object_ids_14
,
9363 { "Object ID Definition", "ndps.objectid_def14",
9364 FT_UINT32
, BASE_DEC
, NULL
,
9365 0x0, NULL
, HFILL
}},
9367 { &hf_ndps_object_ids_15
,
9368 { "Object ID Definition", "ndps.objectid_def15",
9369 FT_UINT32
, BASE_DEC
, NULL
,
9370 0x0, NULL
, HFILL
}},
9372 { &hf_ndps_object_ids_16
,
9373 { "Object ID Definition", "ndps.objectid_def16",
9374 FT_UINT32
, BASE_DEC
, NULL
,
9375 0x0, NULL
, HFILL
}},
9378 { &hf_ndps_attribute_time
,
9379 { "Time", "ndps.attribute_time",
9380 FT_ABSOLUTE_TIME
, ABSOLUTE_TIME_LOCAL
, NULL
, 0x0,
9384 { &hf_print_security
,
9385 { "Printer Security", "ndps.print_security",
9386 FT_UINT32
, BASE_HEX
, VALS(ndps_print_security
), 0x0,
9389 { &hf_notify_time_interval
,
9390 { "Notify Time Interval", "ndps.notify_time_interval",
9391 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
9394 { &hf_notify_sequence_number
,
9395 { "Notify Sequence Number", "ndps.notify_seq_number",
9396 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
9399 { &hf_notify_lease_exp_time
,
9400 { "Notify Lease Expiration Time", "ndps.notify_lease_exp_time",
9401 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
9404 { &hf_notify_printer_uri
,
9405 { "Notify Printer URI", "ndps.notify_printer_uri",
9406 FT_STRING
, BASE_NONE
, NULL
, 0x0,
9410 { "Level", "ndps.level",
9411 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
9415 { "Interval", "ndps.interval",
9416 FT_UINT32
, BASE_HEX
, NULL
, 0x0,
9420 static int *ett
[] = {
9426 static ei_register_info ei
[] = {
9427 { &ei_ndps_problem_type
, { "ndps.problem_type.expert", PI_RESPONSE_CODE
, PI_NOTE
, "Fault", EXPFILL
}},
9428 { &ei_ndps_return_code
, { "ndps.return_code.expert", PI_RESPONSE_CODE
, PI_NOTE
, "Fault", EXPFILL
}},
9429 { &ei_ndps_rpc_acc_stat
, { "ndps.rpc_acc_stat.expert", PI_RESPONSE_CODE
, PI_NOTE
, "Fault", EXPFILL
}},
9430 { &ei_ndps_truncated
, { "ndps.truncated", PI_PROTOCOL
, PI_WARN
, "Truncated", EXPFILL
}},
9433 module_t
*ndps_module
;
9434 expert_module_t
* expert_ndps
;
9436 proto_ndps
= proto_register_protocol("Novell Distributed Print System", "NDPS", "ndps");
9437 proto_register_field_array(proto_ndps
, hf_ndps
, array_length(hf_ndps
));
9438 proto_register_subtree_array(ett
, array_length(ett
));
9439 expert_ndps
= expert_register_protocol(proto_ndps
);
9440 expert_register_field_array(expert_ndps
, ei
, array_length(ei
));
9442 ndps_handle
= register_dissector("ndps.ipx", dissect_ndps_ipx
, proto_ndps
);
9443 ndps_tcp_handle
= register_dissector("ndps.tcp", dissect_ndps_tcp
, proto_ndps
);
9445 ndps_module
= prefs_register_protocol(proto_ndps
, NULL
);
9446 prefs_register_bool_preference(ndps_module
, "desegment_tcp",
9447 "Reassemble NDPS messages spanning multiple TCP segments",
9448 "Whether the NDPS dissector should reassemble messages spanning multiple TCP segments."
9449 " To use this option, you must also enable \"Allow subdissectors to reassemble TCP streams\" in the TCP protocol settings.",
9451 prefs_register_bool_preference(ndps_module
, "desegment_spx",
9452 "Reassemble fragmented NDPS messages spanning multiple SPX packets",
9453 "Whether the NDPS dissector should reassemble fragmented NDPS messages spanning multiple SPX packets",
9455 prefs_register_bool_preference(ndps_module
, "show_oid",
9456 "Display NDPS Details",
9457 "Whether or not the NDPS dissector should show object id's and other details",
9460 reassembly_table_register(&ndps_reassembly_table
,
9461 &addresses_reassembly_table_functions
);
9463 ndps_req_hash
= wmem_map_new_autoreset(wmem_epan_scope(), wmem_file_scope(), ndps_hash
, ndps_equal
);
9467 proto_reg_handoff_ndps(void)
9469 dissector_add_uint("spx.socket", SPX_SOCKET_PA
, ndps_handle
);
9470 dissector_add_uint("spx.socket", SPX_SOCKET_BROKER
, ndps_handle
);
9471 dissector_add_uint("spx.socket", SPX_SOCKET_SRS
, ndps_handle
);
9472 dissector_add_uint("spx.socket", SPX_SOCKET_ENS
, ndps_handle
);
9473 dissector_add_uint("spx.socket", SPX_SOCKET_RMS
, ndps_handle
);
9474 dissector_add_uint("spx.socket", SPX_SOCKET_NOTIFY_LISTENER
, ndps_handle
);
9475 dissector_add_uint_range_with_preference("tcp.port", TCP_PORT_RANGE
, ndps_tcp_handle
);
9479 * Editor modelines - https://www.wireshark.org/tools/modelines.html
9484 * indent-tabs-mode: nil
9487 * vi: set shiftwidth=4 tabstop=8 expandtab:
9488 * :indentSize=4:tabSize=8:noTabs=true: