Remove #pragma warning (MSVC) for PIDL generate dissector
[metze/wireshark/wip.git] / epan / dissectors / packet-dcerpc-winreg.c
1 /* DO NOT EDIT
2         This file was automatically generated by Pidl
3         from winreg.idl and winreg.cnf.
4
5         Pidl is a perl based IDL compiler for DCE/RPC idl files.
6         It is maintained by the Samba team, not the Wireshark team.
7         Instructions on how to download and install Pidl can be
8         found at http://wiki.wireshark.org/Pidl
9 */
10
11
12 #include "config.h"
13 #include <glib.h>
14 #include <string.h>
15 #include <epan/packet.h>
16
17 #include "packet-dcerpc.h"
18 #include "packet-dcerpc-nt.h"
19 #include "packet-windows-common.h"
20 #include "packet-dcerpc-winreg.h"
21 void proto_register_dcerpc_winreg(void);
22 void proto_reg_handoff_dcerpc_winreg(void);
23
24 /* Ett declarations */
25 static gint ett_dcerpc_winreg = -1;
26 static gint ett_winreg_security_secinfo = -1;
27 static gint ett_winreg_winreg_AccessMask = -1;
28 static gint ett_winreg_winreg_String = -1;
29 static gint ett_winreg_KeySecurityData = -1;
30 static gint ett_winreg_winreg_SecBuf = -1;
31 static gint ett_winreg_winreg_KeyOptions = -1;
32 static gint ett_winreg_winreg_StringBuf = -1;
33 static gint ett_winreg_winreg_ValNameBuf = -1;
34 static gint ett_winreg_winreg_NotifyChangeType = -1;
35 static gint ett_winreg_winreg_RestoreKeyFlags = -1;
36 static gint ett_winreg_KeySecurityAttribute = -1;
37 static gint ett_winreg_QueryMultipleValue = -1;
38
39
40 /* Header field declarations */
41 static gint hf_winreg_winreg_AccessMask_KEY_ENUMERATE_SUB_KEYS = -1;
42 static gint hf_winreg_winreg_NotifyChangeKeyValue_string2 = -1;
43 static gint hf_winreg_winreg_InitiateSystemShutdown_message = -1;
44 static gint hf_winreg_winreg_String_name = -1;
45 static gint hf_winreg_winreg_InitiateSystemShutdownEx_message = -1;
46 static gint hf_winreg_winreg_EnumValue_enum_index = -1;
47 static gint hf_winreg_access_mask = -1;
48 static gint hf_winreg_winreg_CreateKey_options = -1;
49 static gint hf_winreg_winreg_InitiateSystemShutdownEx_timeout = -1;
50 static gint hf_winreg_handle = -1;
51 static gint hf_winreg_winreg_QueryInfoKey_max_valnamelen = -1;
52 static gint hf_winreg_winreg_SecBuf_length = -1;
53 static gint hf_winreg_winreg_InitiateSystemShutdown_do_reboot = -1;
54 static gint hf_winreg_winreg_DeleteKeyEx_handle = -1;
55 static gint hf_winreg_winreg_QueryMultipleValues_buffer_size = -1;
56 static gint hf_winreg_winreg_CreateKey_new_handle = -1;
57 static gint hf_winreg_winreg_QueryMultipleValues2_needed = -1;
58 static gint hf_winreg_QueryMultipleValue_ve_valuelen = -1;
59 static gint hf_winreg_KeySecurityAttribute_sec_data = -1;
60 static gint hf_winreg_winreg_GetKeySecurity_sec_info = -1;
61 static gint hf_winreg_winreg_SaveKeyEx_handle = -1;
62 static gint hf_winreg_winreg_KeyOptions_REG_OPTION_VOLATILE = -1;
63 static gint hf_winreg_winreg_QueryMultipleValues2_num_values = -1;
64 static gint hf_winreg_winreg_SetKeySecurity_sec_info = -1;
65 static gint hf_winreg_winreg_StringBuf_size = -1;
66 static gint hf_winreg_winreg_SecBuf_sd = -1;
67 static gint hf_winreg_winreg_QueryInfoKey_secdescsize = -1;
68 static gint hf_winreg_winreg_NotifyChangeType_REG_NOTIFY_CHANGE_SECURITY = -1;
69 static gint hf_winreg_winreg_SetValue_name = -1;
70 static gint hf_winreg_winreg_RestoreKey_flags = -1;
71 static gint hf_winreg_QueryMultipleValue_ve_type = -1;
72 static gint hf_winreg_winreg_CreateKey_secdesc = -1;
73 static gint hf_winreg_winreg_DeleteKeyEx_reserved = -1;
74 static gint hf_winreg_winreg_InitiateSystemShutdownEx_force_apps = -1;
75 static gint hf_winreg_winreg_SetValue_type = -1;
76 static gint hf_winreg_opnum = -1;
77 static gint hf_winreg_winreg_EnumValue_name = -1;
78 static gint hf_winreg_winreg_LoadKey_filename = -1;
79 static gint hf_winreg_winreg_AccessMask_KEY_CREATE_LINK = -1;
80 static gint hf_winreg_winreg_DeleteValue_value = -1;
81 static gint hf_winreg_winreg_QueryMultipleValues2_offered = -1;
82 static gint hf_winreg_winreg_QueryMultipleValues_values_in = -1;
83 static gint hf_winreg_winreg_AccessMask_KEY_NOTIFY = -1;
84 static gint hf_winreg_winreg_OpenKey_parent_handle = -1;
85 static gint hf_winreg_winreg_QueryInfoKey_num_subkeys = -1;
86 static gint hf_winreg_winreg_AccessMask_KEY_WOW64_32KEY = -1;
87 static gint hf_winreg_winreg_SaveKeyEx_sec_attrib = -1;
88 static gint hf_winreg_winreg_QueryInfoKey_last_changed_time = -1;
89 static gint hf_winreg_winreg_KeyOptions_REG_OPTION_OPEN_LINK = -1;
90 static gint hf_winreg_winreg_OpenHKPD_access_mask = -1;
91 static gint hf_winreg_winreg_AbortSystemShutdown_server = -1;
92 static gint hf_winreg_winreg_QueryValue_type = -1;
93 static gint hf_winreg_sd_actual_size = -1;
94 static gint hf_winreg_winreg_RestoreKeyFlags_REG_FORCE_RESTORE = -1;
95 static gint hf_winreg_winreg_SecBuf_inherit = -1;
96 static gint hf_winreg_winreg_SetValue_size = -1;
97 static gint hf_winreg_winreg_SaveKey_handle = -1;
98 static gint hf_winreg_winreg_NotifyChangeType_REG_NOTIFY_CHANGE_LAST_SET = -1;
99 static gint hf_winreg_winreg_ReplaceKey_handle = -1;
100 static gint hf_winreg_winreg_GetVersion_version = -1;
101 static gint hf_winreg_winreg_ReplaceKey_old_file = -1;
102 static gint hf_winreg_winreg_AccessMask_KEY_QUERY_VALUE = -1;
103 static gint hf_winreg_winreg_CreateKey_action_taken = -1;
104 static gint hf_winreg_winreg_QueryInfoKey_num_values = -1;
105 static gint hf_winreg_winreg_RestoreKeyFlags_REG_WHOLE_HIVE_VOLATILE = -1;
106 static gint hf_winreg_winreg_NotifyChangeType_REG_NOTIFY_CHANGE_NAME = -1;
107 static gint hf_winreg_winreg_AccessMask_KEY_SET_VALUE = -1;
108 static gint hf_winreg_winreg_EnumKey_enum_index = -1;
109 static gint hf_winreg_winreg_RestoreKey_handle = -1;
110 static gint hf_winreg_winreg_SetValue_data = -1;
111 static gint hf_winreg_winreg_InitiateSystemShutdown_force_apps = -1;
112 static gint hf_winreg_winreg_NotifyChangeKeyValue_string1 = -1;
113 static gint hf_winreg_winreg_SaveKeyEx_flags = -1;
114 static gint hf_winreg_winreg_QueryMultipleValues_buffer = -1;
115 static gint hf_winreg_winreg_QueryInfoKey_classname = -1;
116 static gint hf_winreg_winreg_AccessMask_KEY_WOW64_64KEY = -1;
117 static gint hf_winreg_winreg_ReplaceKey_subkey = -1;
118 static gint hf_winreg_sd_max_size = -1;
119 static gint hf_winreg_winreg_QueryInfoKey_max_classlen = -1;
120 static gint hf_winreg_winreg_ValNameBuf_length = -1;
121 static gint hf_winreg_winreg_NotifyChangeKeyValue_notify_filter = -1;
122 static gint hf_winreg_winreg_UnLoadKey_subkey = -1;
123 static gint hf_winreg_winreg_ReplaceKey_new_file = -1;
124 static gint hf_winreg_winreg_SaveKeyEx_filename = -1;
125 static gint hf_winreg_QueryMultipleValue_ve_valuename = -1;
126 static gint hf_winreg_winreg_QueryMultipleValues2_key_handle = -1;
127 static gint hf_winreg_KeySecurityData_size = -1;
128 static gint hf_winreg_winreg_KeyOptions_REG_OPTION_BACKUP_RESTORE = -1;
129 static gint hf_winreg_winreg_EnumKey_name = -1;
130 static gint hf_winreg_winreg_LoadKey_keyname = -1;
131 static gint hf_winreg_winreg_QueryMultipleValues_key_handle = -1;
132 static gint hf_winreg_winreg_EnumValue_type = -1;
133 static gint hf_winreg_winreg_EnumKey_last_changed_time = -1;
134 static gint hf_winreg_winreg_EnumValue_size = -1;
135 static gint hf_winreg_winreg_SaveKey_sec_attrib = -1;
136 static gint hf_winreg_sd = -1;
137 static gint hf_winreg_winreg_KeyOptions_REG_OPTION_CREATE_LINK = -1;
138 static gint hf_winreg_winreg_OpenKey_options = -1;
139 static gint hf_winreg_winreg_SaveKey_filename = -1;
140 static gint hf_winreg_winreg_QueryValue_data = -1;
141 static gint hf_winreg_winreg_QueryMultipleValues2_buffer = -1;
142 static gint hf_winreg_winreg_InitiateSystemShutdown_hostname = -1;
143 static gint hf_winreg_winreg_UnLoadKey_handle = -1;
144 static gint hf_winreg_winreg_QueryMultipleValues_values_out = -1;
145 static gint hf_winreg_KeySecurityData_data = -1;
146 static gint hf_winreg_winreg_OpenKey_access_mask = -1;
147 static gint hf_winreg_winreg_OpenKey_keyname = -1;
148 static gint hf_winreg_winreg_InitiateSystemShutdownEx_do_reboot = -1;
149 static gint hf_winreg_winreg_NotifyChangeKeyValue_watch_subtree = -1;
150 static gint hf_winreg_winreg_DeleteKeyEx_access_mask = -1;
151 static gint hf_winreg_winreg_DeleteKeyEx_key = -1;
152 static gint hf_winreg_winreg_QueryValue_data_length = -1;
153 static gint hf_winreg_KeySecurityData_len = -1;
154 static gint hf_winreg_winreg_ValNameBuf_size = -1;
155 static gint hf_winreg_winreg_CreateKey_name = -1;
156 static gint hf_winreg_winreg_NotifyChangeType_REG_NOTIFY_CHANGE_ATTRIBUTES = -1;
157 static gint hf_winreg_winreg_String_name_len = -1;
158 static gint hf_winreg_winreg_DeleteKey_key = -1;
159 static gint hf_winreg_winreg_QueryValue_data_size = -1;
160 static gint hf_winreg_system_name = -1;
161 static gint hf_winreg_QueryMultipleValue_ve_valueptr = -1;
162 static gint hf_winreg_KeySecurityAttribute_data_size = -1;
163 static gint hf_winreg_winreg_QueryMultipleValues_num_values = -1;
164 static gint hf_winreg_winreg_StringBuf_name = -1;
165 static gint hf_winreg_winreg_NotifyChangeKeyValue_unknown2 = -1;
166 static gint hf_winreg_sd_offset = -1;
167 static gint hf_winreg_winreg_ValNameBuf_name = -1;
168 static gint hf_winreg_winreg_StringBuf_length = -1;
169 static gint hf_winreg_winreg_QueryMultipleValues2_values_in = -1;
170 static gint hf_winreg_winreg_String_name_size = -1;
171 static gint hf_winreg_winreg_NotifyChangeKeyValue_unknown = -1;
172 static gint hf_winreg_winreg_AccessMask_KEY_CREATE_SUB_KEY = -1;
173 static gint hf_winreg_winreg_RestoreKey_filename = -1;
174 static gint hf_winreg_winreg_RestoreKeyFlags_REG_REFRESH_HIVE = -1;
175 static gint hf_winreg_winreg_QueryInfoKey_max_valbufsize = -1;
176 static gint hf_winreg_winreg_InitiateSystemShutdownEx_reason = -1;
177 static gint hf_winreg_winreg_EnumValue_length = -1;
178 static gint hf_winreg_winreg_QueryInfoKey_max_subkeylen = -1;
179 static gint hf_winreg_winreg_InitiateSystemShutdown_timeout = -1;
180 static gint hf_winreg_winreg_InitiateSystemShutdownEx_hostname = -1;
181 static gint hf_winreg_KeySecurityAttribute_inherit = -1;
182 static gint hf_winreg_werror = -1;
183 static gint hf_winreg_winreg_QueryMultipleValues2_values_out = -1;
184 static gint hf_winreg_winreg_EnumKey_keyclass = -1;
185 static gint hf_winreg_winreg_CreateKey_keyclass = -1;
186 static gint hf_winreg_winreg_EnumValue_value = -1;
187 static gint hf_winreg_winreg_OpenHKCU_access_mask = -1;
188 static gint hf_winreg_winreg_QueryValue_value_name = -1;
189 static gint hf_winreg_winreg_RestoreKeyFlags_REG_NO_LAZY_FLUSH = -1;
190
191 static gint proto_dcerpc_winreg = -1;
192 /* Version information */
193
194
195 static e_uuid_t uuid_dcerpc_winreg = {
196         0x338cd001, 0x2244, 0x31f1,
197         { 0xaa, 0xaa, 0x90, 0x00, 0x38, 0x00, 0x10, 0x03 }
198 };
199 static guint16 ver_dcerpc_winreg = 1;
200
201 static const true_false_string winreg_AccessMask_KEY_QUERY_VALUE_tfs = {
202    "KEY_QUERY_VALUE is SET",
203    "KEY_QUERY_VALUE is NOT SET",
204 };
205 static const true_false_string winreg_AccessMask_KEY_SET_VALUE_tfs = {
206    "KEY_SET_VALUE is SET",
207    "KEY_SET_VALUE is NOT SET",
208 };
209 static const true_false_string winreg_AccessMask_KEY_CREATE_SUB_KEY_tfs = {
210    "KEY_CREATE_SUB_KEY is SET",
211    "KEY_CREATE_SUB_KEY is NOT SET",
212 };
213 static const true_false_string winreg_AccessMask_KEY_ENUMERATE_SUB_KEYS_tfs = {
214    "KEY_ENUMERATE_SUB_KEYS is SET",
215    "KEY_ENUMERATE_SUB_KEYS is NOT SET",
216 };
217 static const true_false_string winreg_AccessMask_KEY_NOTIFY_tfs = {
218    "KEY_NOTIFY is SET",
219    "KEY_NOTIFY is NOT SET",
220 };
221 static const true_false_string winreg_AccessMask_KEY_CREATE_LINK_tfs = {
222    "KEY_CREATE_LINK is SET",
223    "KEY_CREATE_LINK is NOT SET",
224 };
225 static const true_false_string winreg_AccessMask_KEY_WOW64_64KEY_tfs = {
226    "KEY_WOW64_64KEY is SET",
227    "KEY_WOW64_64KEY is NOT SET",
228 };
229 static const true_false_string winreg_AccessMask_KEY_WOW64_32KEY_tfs = {
230    "KEY_WOW64_32KEY is SET",
231    "KEY_WOW64_32KEY is NOT SET",
232 };
233 static int winreg_dissect_element_String_name_len(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
234 static int winreg_dissect_element_String_name_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
235 static int winreg_dissect_element_String_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
236 static int winreg_dissect_element_String_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
237 static int winreg_dissect_element_KeySecurityData_data(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
238 static int winreg_dissect_element_KeySecurityData_data_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
239 static int winreg_dissect_element_KeySecurityData_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
240 static int winreg_dissect_element_KeySecurityData_len(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
241 static int winreg_dissect_element_SecBuf_length(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
242 static int winreg_dissect_element_SecBuf_sd(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
243 static int winreg_dissect_element_SecBuf_inherit(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
244 static const true_false_string winreg_KeyOptions_REG_OPTION_VOLATILE_tfs = {
245    "REG_OPTION_VOLATILE is SET",
246    "REG_OPTION_VOLATILE is NOT SET",
247 };
248 static const true_false_string winreg_KeyOptions_REG_OPTION_CREATE_LINK_tfs = {
249    "REG_OPTION_CREATE_LINK is SET",
250    "REG_OPTION_CREATE_LINK is NOT SET",
251 };
252 static const true_false_string winreg_KeyOptions_REG_OPTION_BACKUP_RESTORE_tfs = {
253    "REG_OPTION_BACKUP_RESTORE is SET",
254    "REG_OPTION_BACKUP_RESTORE is NOT SET",
255 };
256 static const true_false_string winreg_KeyOptions_REG_OPTION_OPEN_LINK_tfs = {
257    "REG_OPTION_OPEN_LINK is SET",
258    "REG_OPTION_OPEN_LINK is NOT SET",
259 };
260 const value_string winreg_winreg_CreateAction_vals[] = {
261         { REG_ACTION_NONE, "REG_ACTION_NONE" },
262         { REG_CREATED_NEW_KEY, "REG_CREATED_NEW_KEY" },
263         { REG_OPENED_EXISTING_KEY, "REG_OPENED_EXISTING_KEY" },
264 { 0, NULL }
265 };
266 static int winreg_dissect_element_StringBuf_length(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
267 static int winreg_dissect_element_StringBuf_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
268 static int winreg_dissect_element_StringBuf_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
269 static int winreg_dissect_element_StringBuf_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
270 static int winreg_dissect_element_StringBuf_name__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
271 static int winreg_dissect_element_ValNameBuf_length(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
272 static int winreg_dissect_element_ValNameBuf_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
273 static int winreg_dissect_element_ValNameBuf_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
274 static int winreg_dissect_element_ValNameBuf_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
275 static int winreg_dissect_element_ValNameBuf_name__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
276 static const true_false_string winreg_NotifyChangeType_REG_NOTIFY_CHANGE_NAME_tfs = {
277    "REG_NOTIFY_CHANGE_NAME is SET",
278    "REG_NOTIFY_CHANGE_NAME is NOT SET",
279 };
280 static const true_false_string winreg_NotifyChangeType_REG_NOTIFY_CHANGE_ATTRIBUTES_tfs = {
281    "REG_NOTIFY_CHANGE_ATTRIBUTES is SET",
282    "REG_NOTIFY_CHANGE_ATTRIBUTES is NOT SET",
283 };
284 static const true_false_string winreg_NotifyChangeType_REG_NOTIFY_CHANGE_LAST_SET_tfs = {
285    "REG_NOTIFY_CHANGE_LAST_SET is SET",
286    "REG_NOTIFY_CHANGE_LAST_SET is NOT SET",
287 };
288 static const true_false_string winreg_NotifyChangeType_REG_NOTIFY_CHANGE_SECURITY_tfs = {
289    "REG_NOTIFY_CHANGE_SECURITY is SET",
290    "REG_NOTIFY_CHANGE_SECURITY is NOT SET",
291 };
292 static const true_false_string winreg_RestoreKeyFlags_REG_WHOLE_HIVE_VOLATILE_tfs = {
293    "REG_WHOLE_HIVE_VOLATILE is SET",
294    "REG_WHOLE_HIVE_VOLATILE is NOT SET",
295 };
296 static const true_false_string winreg_RestoreKeyFlags_REG_REFRESH_HIVE_tfs = {
297    "REG_REFRESH_HIVE is SET",
298    "REG_REFRESH_HIVE is NOT SET",
299 };
300 static const true_false_string winreg_RestoreKeyFlags_REG_NO_LAZY_FLUSH_tfs = {
301    "REG_NO_LAZY_FLUSH is SET",
302    "REG_NO_LAZY_FLUSH is NOT SET",
303 };
304 static const true_false_string winreg_RestoreKeyFlags_REG_FORCE_RESTORE_tfs = {
305    "REG_FORCE_RESTORE is SET",
306    "REG_FORCE_RESTORE is NOT SET",
307 };
308 static int winreg_dissect_element_KeySecurityAttribute_data_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
309 static int winreg_dissect_element_KeySecurityAttribute_sec_data(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
310 static int winreg_dissect_element_KeySecurityAttribute_inherit(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
311 static int winreg_dissect_element_QueryMultipleValue_ve_valuename(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
312 static int winreg_dissect_element_QueryMultipleValue_ve_valuename_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
313 static int winreg_dissect_element_QueryMultipleValue_ve_valuelen(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
314 static int winreg_dissect_element_QueryMultipleValue_ve_valueptr(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
315 static int winreg_dissect_element_QueryMultipleValue_ve_type(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
316 static int winreg_dissect_element_OpenHKCR_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
317 static int winreg_dissect_element_OpenHKCR_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
318 static int winreg_dissect_element_OpenHKCR_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
319 static int winreg_dissect_element_OpenHKCR_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
320 static int winreg_dissect_element_OpenHKCR_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
321 static int winreg_dissect_element_OpenHKCU_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
322 static int winreg_dissect_element_OpenHKCU_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
323 static int winreg_dissect_element_OpenHKCU_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
324 static int winreg_dissect_element_OpenHKCU_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
325 static int winreg_dissect_element_OpenHKCU_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
326 static int winreg_dissect_element_OpenHKLM_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
327 static int winreg_dissect_element_OpenHKLM_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
328 static int winreg_dissect_element_OpenHKLM_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
329 static int winreg_dissect_element_OpenHKLM_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
330 static int winreg_dissect_element_OpenHKLM_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
331 static int winreg_dissect_element_OpenHKPD_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
332 static int winreg_dissect_element_OpenHKPD_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
333 static int winreg_dissect_element_OpenHKPD_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
334 static int winreg_dissect_element_OpenHKPD_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
335 static int winreg_dissect_element_OpenHKPD_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
336 static int winreg_dissect_element_OpenHKU_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
337 static int winreg_dissect_element_OpenHKU_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
338 static int winreg_dissect_element_OpenHKU_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
339 static int winreg_dissect_element_OpenHKU_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
340 static int winreg_dissect_element_OpenHKU_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
341 static int winreg_dissect_element_CloseKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
342 static int winreg_dissect_element_CloseKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
343 static int winreg_dissect_element_CreateKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
344 static int winreg_dissect_element_CreateKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
345 static int winreg_dissect_element_CreateKey_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
346 static int winreg_dissect_element_CreateKey_keyclass(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
347 static int winreg_dissect_element_CreateKey_options(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
348 static int winreg_dissect_element_CreateKey_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
349 static int winreg_dissect_element_CreateKey_secdesc(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
350 static int winreg_dissect_element_CreateKey_secdesc_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
351 static int winreg_dissect_element_CreateKey_new_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
352 static int winreg_dissect_element_CreateKey_new_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
353 static int winreg_dissect_element_CreateKey_action_taken(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
354 static int winreg_dissect_element_CreateKey_action_taken_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
355 static int winreg_dissect_element_DeleteKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
356 static int winreg_dissect_element_DeleteKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
357 static int winreg_dissect_element_DeleteKey_key(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
358 static int winreg_dissect_element_DeleteValue_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
359 static int winreg_dissect_element_DeleteValue_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
360 static int winreg_dissect_element_DeleteValue_value(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
361 static int winreg_dissect_element_EnumKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
362 static int winreg_dissect_element_EnumKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
363 static int winreg_dissect_element_EnumKey_enum_index(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
364 static int winreg_dissect_element_EnumKey_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
365 static int winreg_dissect_element_EnumKey_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
366 static int winreg_dissect_element_EnumKey_keyclass(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
367 static int winreg_dissect_element_EnumKey_keyclass_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
368 static int winreg_dissect_element_EnumKey_last_changed_time(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
369 static int winreg_dissect_element_EnumKey_last_changed_time_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
370 static int winreg_dissect_element_EnumValue_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
371 static int winreg_dissect_element_EnumValue_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
372 static int winreg_dissect_element_EnumValue_enum_index(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
373 static int winreg_dissect_element_EnumValue_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
374 static int winreg_dissect_element_EnumValue_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
375 static int winreg_dissect_element_EnumValue_type(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
376 static int winreg_dissect_element_EnumValue_type_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
377 static int winreg_dissect_element_EnumValue_value(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
378 static int winreg_dissect_element_EnumValue_value_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
379 static int winreg_dissect_element_EnumValue_value__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
380 static int winreg_dissect_element_EnumValue_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
381 static int winreg_dissect_element_EnumValue_size_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
382 static int winreg_dissect_element_EnumValue_length(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
383 static int winreg_dissect_element_EnumValue_length_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
384 static int winreg_dissect_element_FlushKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
385 static int winreg_dissect_element_FlushKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
386 static int winreg_dissect_element_GetKeySecurity_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
387 static int winreg_dissect_element_GetKeySecurity_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
388 static int winreg_dissect_element_GetKeySecurity_sec_info(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
389 static int winreg_dissect_element_GetKeySecurity_sd(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
390 static int winreg_dissect_element_GetKeySecurity_sd_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
391 static int winreg_dissect_element_LoadKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
392 static int winreg_dissect_element_LoadKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
393 static int winreg_dissect_element_LoadKey_keyname(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
394 static int winreg_dissect_element_LoadKey_keyname_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
395 static int winreg_dissect_element_LoadKey_filename(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
396 static int winreg_dissect_element_LoadKey_filename_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
397 static int winreg_dissect_element_NotifyChangeKeyValue_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
398 static int winreg_dissect_element_NotifyChangeKeyValue_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
399 static int winreg_dissect_element_NotifyChangeKeyValue_watch_subtree(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
400 static int winreg_dissect_element_NotifyChangeKeyValue_notify_filter(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
401 static int winreg_dissect_element_NotifyChangeKeyValue_unknown(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
402 static int winreg_dissect_element_NotifyChangeKeyValue_string1(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
403 static int winreg_dissect_element_NotifyChangeKeyValue_string2(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
404 static int winreg_dissect_element_NotifyChangeKeyValue_unknown2(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
405 static int winreg_dissect_element_OpenKey_parent_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
406 static int winreg_dissect_element_OpenKey_parent_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
407 static int winreg_dissect_element_OpenKey_keyname(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
408 static int winreg_dissect_element_OpenKey_options(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
409 static int winreg_dissect_element_OpenKey_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
410 static int winreg_dissect_element_OpenKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
411 static int winreg_dissect_element_OpenKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
412 static int winreg_dissect_element_QueryInfoKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
413 static int winreg_dissect_element_QueryInfoKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
414 static int winreg_dissect_element_QueryInfoKey_classname(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
415 static int winreg_dissect_element_QueryInfoKey_classname_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
416 static int winreg_dissect_element_QueryInfoKey_num_subkeys(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
417 static int winreg_dissect_element_QueryInfoKey_num_subkeys_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
418 static int winreg_dissect_element_QueryInfoKey_max_subkeylen(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
419 static int winreg_dissect_element_QueryInfoKey_max_subkeylen_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
420 static int winreg_dissect_element_QueryInfoKey_max_classlen(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
421 static int winreg_dissect_element_QueryInfoKey_max_classlen_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
422 static int winreg_dissect_element_QueryInfoKey_num_values(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
423 static int winreg_dissect_element_QueryInfoKey_num_values_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
424 static int winreg_dissect_element_QueryInfoKey_max_valnamelen(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
425 static int winreg_dissect_element_QueryInfoKey_max_valnamelen_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
426 static int winreg_dissect_element_QueryInfoKey_max_valbufsize(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
427 static int winreg_dissect_element_QueryInfoKey_max_valbufsize_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
428 static int winreg_dissect_element_QueryInfoKey_secdescsize(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
429 static int winreg_dissect_element_QueryInfoKey_secdescsize_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
430 static int winreg_dissect_element_QueryInfoKey_last_changed_time(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
431 static int winreg_dissect_element_QueryInfoKey_last_changed_time_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
432 static int winreg_dissect_element_QueryValue_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
433 static int winreg_dissect_element_QueryValue_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
434 static int winreg_dissect_element_QueryValue_value_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
435 static int winreg_dissect_element_QueryValue_value_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
436 static int winreg_dissect_element_QueryValue_type(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
437 static int winreg_dissect_element_QueryValue_type_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
438 static int winreg_dissect_element_QueryValue_data(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
439 static int winreg_dissect_element_QueryValue_data_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
440 static int winreg_dissect_element_QueryValue_data__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
441 static int winreg_dissect_element_QueryValue_data_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
442 static int winreg_dissect_element_QueryValue_data_size_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
443 static int winreg_dissect_element_QueryValue_data_length(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
444 static int winreg_dissect_element_QueryValue_data_length_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
445 static int winreg_dissect_element_ReplaceKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
446 static int winreg_dissect_element_ReplaceKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
447 static int winreg_dissect_element_ReplaceKey_subkey(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
448 static int winreg_dissect_element_ReplaceKey_subkey_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
449 static int winreg_dissect_element_ReplaceKey_new_file(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
450 static int winreg_dissect_element_ReplaceKey_new_file_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
451 static int winreg_dissect_element_ReplaceKey_old_file(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
452 static int winreg_dissect_element_ReplaceKey_old_file_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
453 static int winreg_dissect_element_RestoreKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
454 static int winreg_dissect_element_RestoreKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
455 static int winreg_dissect_element_RestoreKey_filename(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
456 static int winreg_dissect_element_RestoreKey_filename_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
457 static int winreg_dissect_element_RestoreKey_flags(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
458 static int winreg_dissect_element_SaveKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
459 static int winreg_dissect_element_SaveKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
460 static int winreg_dissect_element_SaveKey_filename(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
461 static int winreg_dissect_element_SaveKey_filename_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
462 static int winreg_dissect_element_SaveKey_sec_attrib(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
463 static int winreg_dissect_element_SaveKey_sec_attrib_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
464 static int winreg_dissect_element_SetKeySecurity_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
465 static int winreg_dissect_element_SetKeySecurity_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
466 static int winreg_dissect_element_SetKeySecurity_sec_info(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
467 static int winreg_dissect_element_SetKeySecurity_sd(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
468 static int winreg_dissect_element_SetKeySecurity_sd_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
469 static int winreg_dissect_element_SetValue_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
470 static int winreg_dissect_element_SetValue_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
471 static int winreg_dissect_element_SetValue_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
472 static int winreg_dissect_element_SetValue_type(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
473 static int winreg_dissect_element_SetValue_data(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
474 static int winreg_dissect_element_SetValue_data_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
475 static int winreg_dissect_element_SetValue_data__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
476 static int winreg_dissect_element_SetValue_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
477 static int winreg_dissect_element_UnLoadKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
478 static int winreg_dissect_element_UnLoadKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
479 static int winreg_dissect_element_UnLoadKey_subkey(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
480 static int winreg_dissect_element_UnLoadKey_subkey_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
481 static int winreg_dissect_element_InitiateSystemShutdown_hostname(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
482 static int winreg_dissect_element_InitiateSystemShutdown_hostname_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
483 static int winreg_dissect_element_InitiateSystemShutdown_message(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
484 static int winreg_dissect_element_InitiateSystemShutdown_message_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
485 static int winreg_dissect_element_InitiateSystemShutdown_timeout(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
486 static int winreg_dissect_element_InitiateSystemShutdown_force_apps(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
487 static int winreg_dissect_element_InitiateSystemShutdown_do_reboot(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
488 static int winreg_dissect_element_AbortSystemShutdown_server(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
489 static int winreg_dissect_element_AbortSystemShutdown_server_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
490 static int winreg_dissect_element_GetVersion_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
491 static int winreg_dissect_element_GetVersion_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
492 static int winreg_dissect_element_GetVersion_version(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
493 static int winreg_dissect_element_GetVersion_version_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
494 static int winreg_dissect_element_OpenHKCC_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
495 static int winreg_dissect_element_OpenHKCC_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
496 static int winreg_dissect_element_OpenHKCC_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
497 static int winreg_dissect_element_OpenHKCC_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
498 static int winreg_dissect_element_OpenHKCC_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
499 static int winreg_dissect_element_OpenHKDD_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
500 static int winreg_dissect_element_OpenHKDD_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
501 static int winreg_dissect_element_OpenHKDD_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
502 static int winreg_dissect_element_OpenHKDD_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
503 static int winreg_dissect_element_OpenHKDD_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
504 static int winreg_dissect_element_QueryMultipleValues_key_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
505 static int winreg_dissect_element_QueryMultipleValues_key_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
506 static int winreg_dissect_element_QueryMultipleValues_values_in(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
507 static int winreg_dissect_element_QueryMultipleValues_values_in_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
508 static int winreg_dissect_element_QueryMultipleValues_values_in__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
509 static int winreg_dissect_element_QueryMultipleValues_values_out(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
510 static int winreg_dissect_element_QueryMultipleValues_values_out_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
511 static int winreg_dissect_element_QueryMultipleValues_values_out__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
512 static int winreg_dissect_element_QueryMultipleValues_num_values(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
513 static int winreg_dissect_element_QueryMultipleValues_buffer(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
514 static int winreg_dissect_element_QueryMultipleValues_buffer_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
515 static int winreg_dissect_element_QueryMultipleValues_buffer__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
516 static int winreg_dissect_element_QueryMultipleValues_buffer_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
517 static int winreg_dissect_element_QueryMultipleValues_buffer_size_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
518 static int winreg_dissect_element_InitiateSystemShutdownEx_hostname(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
519 static int winreg_dissect_element_InitiateSystemShutdownEx_hostname_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
520 static int winreg_dissect_element_InitiateSystemShutdownEx_message(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
521 static int winreg_dissect_element_InitiateSystemShutdownEx_message_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
522 static int winreg_dissect_element_InitiateSystemShutdownEx_timeout(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
523 static int winreg_dissect_element_InitiateSystemShutdownEx_force_apps(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
524 static int winreg_dissect_element_InitiateSystemShutdownEx_do_reboot(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
525 static int winreg_dissect_element_InitiateSystemShutdownEx_reason(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
526 static int winreg_dissect_element_SaveKeyEx_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
527 static int winreg_dissect_element_SaveKeyEx_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
528 static int winreg_dissect_element_SaveKeyEx_filename(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
529 static int winreg_dissect_element_SaveKeyEx_filename_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
530 static int winreg_dissect_element_SaveKeyEx_sec_attrib(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
531 static int winreg_dissect_element_SaveKeyEx_sec_attrib_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
532 static int winreg_dissect_element_SaveKeyEx_flags(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
533 static int winreg_dissect_element_OpenHKPT_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
534 static int winreg_dissect_element_OpenHKPT_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
535 static int winreg_dissect_element_OpenHKPT_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
536 static int winreg_dissect_element_OpenHKPT_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
537 static int winreg_dissect_element_OpenHKPT_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
538 static int winreg_dissect_element_OpenHKPN_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
539 static int winreg_dissect_element_OpenHKPN_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
540 static int winreg_dissect_element_OpenHKPN_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
541 static int winreg_dissect_element_OpenHKPN_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
542 static int winreg_dissect_element_OpenHKPN_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
543 static int winreg_dissect_element_QueryMultipleValues2_key_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
544 static int winreg_dissect_element_QueryMultipleValues2_key_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
545 static int winreg_dissect_element_QueryMultipleValues2_values_in(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
546 static int winreg_dissect_element_QueryMultipleValues2_values_in_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
547 static int winreg_dissect_element_QueryMultipleValues2_values_in__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
548 static int winreg_dissect_element_QueryMultipleValues2_values_out(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
549 static int winreg_dissect_element_QueryMultipleValues2_values_out_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
550 static int winreg_dissect_element_QueryMultipleValues2_values_out__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
551 static int winreg_dissect_element_QueryMultipleValues2_num_values(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
552 static int winreg_dissect_element_QueryMultipleValues2_buffer(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
553 static int winreg_dissect_element_QueryMultipleValues2_buffer_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
554 static int winreg_dissect_element_QueryMultipleValues2_buffer__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
555 static int winreg_dissect_element_QueryMultipleValues2_offered(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
556 static int winreg_dissect_element_QueryMultipleValues2_offered_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
557 static int winreg_dissect_element_QueryMultipleValues2_needed(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
558 static int winreg_dissect_element_QueryMultipleValues2_needed_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
559 static int winreg_dissect_element_DeleteKeyEx_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
560 static int winreg_dissect_element_DeleteKeyEx_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
561 static int winreg_dissect_element_DeleteKeyEx_key(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
562 static int winreg_dissect_element_DeleteKeyEx_key_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
563 static int winreg_dissect_element_DeleteKeyEx_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
564 static int winreg_dissect_element_DeleteKeyEx_reserved(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_);
565  #include "packet-dcerpc-lsa.h"
566 static void
567 winreg_specific_rights(tvbuff_t *tvb, gint offset, proto_tree *tree, guint32 access)
568 {
569         proto_tree_add_boolean(tree, hf_winreg_winreg_AccessMask_KEY_WOW64_32KEY, tvb, offset, 4, access);
570         proto_tree_add_boolean(tree, hf_winreg_winreg_AccessMask_KEY_WOW64_64KEY, tvb, offset, 4, access);
571         proto_tree_add_boolean(tree, hf_winreg_winreg_AccessMask_KEY_CREATE_LINK, tvb, offset, 4, access);
572         proto_tree_add_boolean(tree, hf_winreg_winreg_AccessMask_KEY_NOTIFY, tvb, offset, 4, access);
573         proto_tree_add_boolean(tree, hf_winreg_winreg_AccessMask_KEY_ENUMERATE_SUB_KEYS, tvb, offset, 4, access);
574         proto_tree_add_boolean(tree, hf_winreg_winreg_AccessMask_KEY_CREATE_SUB_KEY, tvb, offset, 4, access);
575         proto_tree_add_boolean(tree, hf_winreg_winreg_AccessMask_KEY_SET_VALUE, tvb, offset, 4, access);
576         proto_tree_add_boolean(tree, hf_winreg_winreg_AccessMask_KEY_QUERY_VALUE, tvb, offset, 4, access);
577 }
578 struct access_mask_info winreg_access_mask_info = {
579         "WINREG",               /* Name of specific rights */
580         winreg_specific_rights, /* Dissection function */
581         NULL,                   /* Generic mapping table */
582         NULL                    /* Standard mapping table */
583 };
584 static int
585 winreg_dissect_element_KeySecurityData_data_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, dcerpc_info* di, guint8 *drep)
586 {
587         guint32 len;
588         if(di->conformant_run){
589                 /*just a run to handle conformant arrays, nothing to dissect */
590                 return offset;
591         }
592         /* this is a varying and conformant array */
593         offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, di, drep, hf_winreg_sd_max_size, NULL);
594         offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, di, drep, hf_winreg_sd_offset, NULL);
595         offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, di, drep, hf_winreg_sd_actual_size, &len);
596         dissect_nt_sec_desc(tvb, offset, pinfo, tree, drep, TRUE, len,
597                 &winreg_access_mask_info);
598         offset += len;
599         return offset;
600 }
601 int
602 winreg_dissect_bitmap_AccessMask(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, dcerpc_info* di, guint8 *drep, int hf_index _U_, guint32 param _U_)
603 {
604         offset = dissect_nt_access_mask(
605                 tvb, offset, pinfo, tree, di, drep, hf_winreg_access_mask,
606                 &winreg_access_mask_info, NULL);
607         return offset;
608 }
609 /* winreg_String :
610  *      typedef [public,noejs] struct {
611  *              [value(strlen_m_term(name)*2)] uint16 name_len;
612  *              [value(strlen_m_term(name)*2)] uint16 name_size;
613  *              [string,charset(UTF16)] uint16 *name;
614  *      } winreg_String;
615  */
616 static int
617 cnf_dissect_winreg_String(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, dcerpc_info* di, guint8 *drep, guint32 param, int hfindex)
618 {
619         proto_item *item = NULL;
620         proto_tree *tree = NULL;
621         int old_offset;
622         header_field_info *hf_info;
623         ALIGN_TO_4_BYTES;
624         old_offset = offset;
625         hf_info=proto_registrar_get_nth(hfindex);
626         if (parent_tree) {
627                 tree = proto_tree_add_subtree_format(parent_tree, tvb, offset, 0, ett_winreg_winreg_String, &item, "%s: ", hf_info->name);
628         }
629         
630         offset = winreg_dissect_element_String_name_len(tvb, offset, pinfo, tree, di, drep);
631         offset = winreg_dissect_element_String_name_size(tvb, offset, pinfo, tree, di, drep);
632         offset = dissect_ndr_pointer_cb(
633                 tvb, offset, pinfo, tree, di, drep,
634                 dissect_ndr_wchar_cvstring, NDR_POINTER_UNIQUE,
635                 hf_info->name, hfindex, cb_wstr_postprocess,
636                 GINT_TO_POINTER(param));
637         proto_item_set_len(item, offset-old_offset);
638         return offset;
639 }
640
641
642 /* IDL: bitmap { */
643 /* IDL: } */
644
645 int
646 winreg_dissect_bitmap_security_secinfo(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *parent_tree _U_, dcerpc_info* di _U_, guint8 *drep _U_, int hf_index _U_, guint32 param _U_)
647 {
648         proto_item *item = NULL;
649         proto_tree *tree = NULL;
650
651         guint32 flags;
652         ALIGN_TO_4_BYTES;
653
654         if (parent_tree) {
655                 item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, 4, DREP_ENC_INTEGER(drep));
656                 tree = proto_item_add_subtree(item,ett_winreg_security_secinfo);
657         }
658
659         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, -1, &flags);
660         proto_item_append_text(item, ": ");
661
662         if (!flags)
663                 proto_item_append_text(item, "(No values set)");
664
665         if (flags) {
666                 proto_item_append_text(item, "Unknown bitmap value 0x%x", flags);
667         }
668
669         return offset;
670 }
671
672
673 /* IDL: bitmap { */
674 /* IDL:         KEY_QUERY_VALUE =  0x00001 , */
675 /* IDL:         KEY_SET_VALUE =  0x00002 , */
676 /* IDL:         KEY_CREATE_SUB_KEY =  0x00004 , */
677 /* IDL:         KEY_ENUMERATE_SUB_KEYS =  0x00008 , */
678 /* IDL:         KEY_NOTIFY =  0x00010 , */
679 /* IDL:         KEY_CREATE_LINK =  0x00020 , */
680 /* IDL:         KEY_WOW64_64KEY =  0x00100 , */
681 /* IDL:         KEY_WOW64_32KEY =  0x00200 , */
682 /* IDL: } */
683
684
685 /* IDL: struct { */
686 /* IDL:         [value(strlen_m_term(name)*2)] uint16 name_len; */
687 /* IDL:         [value(strlen_m_term(name)*2)] uint16 name_size; */
688 /* IDL:         [unique(1)] [charset(UTF16)] uint16 *name; */
689 /* IDL: } */
690
691 static int
692 winreg_dissect_element_String_name_len(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
693 {
694         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_String_name_len, 0);
695
696         return offset;
697 }
698
699 static int
700 winreg_dissect_element_String_name_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
701 {
702         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_String_name_size, 0);
703
704         return offset;
705 }
706
707 static int
708 winreg_dissect_element_String_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
709 {
710         offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_String_name_, NDR_POINTER_UNIQUE, "Pointer to Name (uint16)",hf_winreg_winreg_String_name);
711
712         return offset;
713 }
714
715 static int
716 winreg_dissect_element_String_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
717 {
718         char *data;
719
720         offset = dissect_ndr_cvstring(tvb, offset, pinfo, tree, di, drep, sizeof(guint16), hf_winreg_winreg_String_name, FALSE, &data);
721         proto_item_append_text(tree, ": %s", data);
722
723         return offset;
724 }
725
726 int
727 winreg_dissect_struct_String(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *parent_tree _U_, dcerpc_info* di _U_, guint8 *drep _U_, int hf_index _U_, guint32 param _U_)
728 {
729         proto_item *item = NULL;
730         proto_tree *tree = NULL;
731         int old_offset;
732
733         ALIGN_TO_4_BYTES;
734
735         old_offset = offset;
736
737         if (parent_tree) {
738                 item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, ENC_NA);
739                 tree = proto_item_add_subtree(item, ett_winreg_winreg_String);
740         }
741         
742         offset = winreg_dissect_element_String_name_len(tvb, offset, pinfo, tree, di, drep);
743
744         offset = winreg_dissect_element_String_name_size(tvb, offset, pinfo, tree, di, drep);
745
746         offset = winreg_dissect_element_String_name(tvb, offset, pinfo, tree, di, drep);
747
748
749         proto_item_set_len(item, offset-old_offset);
750
751
752         if (di->call_data->flags & DCERPC_IS_NDR64) {
753                 ALIGN_TO_4_BYTES;
754         }
755
756         return offset;
757 }
758
759
760 /* IDL: struct { */
761 /* IDL:         [unique(1)] [length_is(len)] [size_is(size)] uint8 *data; */
762 /* IDL:         uint32 size; */
763 /* IDL:         uint32 len; */
764 /* IDL: } */
765
766 static int
767 winreg_dissect_element_KeySecurityData_data(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
768 {
769         offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_KeySecurityData_data_, NDR_POINTER_UNIQUE, "Pointer to Data (uint8)",hf_winreg_KeySecurityData_data);
770
771         return offset;
772 }
773
774 static int
775 winreg_dissect_element_KeySecurityData_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
776 {
777         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_KeySecurityData_size, 0);
778
779         return offset;
780 }
781
782 static int
783 winreg_dissect_element_KeySecurityData_len(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
784 {
785         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_KeySecurityData_len, 0);
786
787         return offset;
788 }
789
790 int
791 winreg_dissect_struct_KeySecurityData(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *parent_tree _U_, dcerpc_info* di _U_, guint8 *drep _U_, int hf_index _U_, guint32 param _U_)
792 {
793         proto_item *item = NULL;
794         proto_tree *tree = NULL;
795         int old_offset;
796
797         ALIGN_TO_5_BYTES;
798
799         old_offset = offset;
800
801         if (parent_tree) {
802                 item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, ENC_NA);
803                 tree = proto_item_add_subtree(item, ett_winreg_KeySecurityData);
804         }
805         
806         offset = winreg_dissect_element_KeySecurityData_data(tvb, offset, pinfo, tree, di, drep);
807
808         offset = winreg_dissect_element_KeySecurityData_size(tvb, offset, pinfo, tree, di, drep);
809
810         offset = winreg_dissect_element_KeySecurityData_len(tvb, offset, pinfo, tree, di, drep);
811
812
813         proto_item_set_len(item, offset-old_offset);
814
815
816         if (di->call_data->flags & DCERPC_IS_NDR64) {
817                 ALIGN_TO_5_BYTES;
818         }
819
820         return offset;
821 }
822
823
824 /* IDL: struct { */
825 /* IDL:         uint32 length; */
826 /* IDL:         KeySecurityData sd; */
827 /* IDL:         uint8 inherit; */
828 /* IDL: } */
829
830 static int
831 winreg_dissect_element_SecBuf_length(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
832 {
833         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_SecBuf_length, 0);
834
835         return offset;
836 }
837
838 static int
839 winreg_dissect_element_SecBuf_sd(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
840 {
841         offset = winreg_dissect_struct_KeySecurityData(tvb,offset,pinfo,tree,di,drep,hf_winreg_winreg_SecBuf_sd,0);
842
843         return offset;
844 }
845
846 static int
847 winreg_dissect_element_SecBuf_inherit(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
848 {
849         offset = PIDL_dissect_uint8(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_SecBuf_inherit, 0);
850
851         return offset;
852 }
853
854 int
855 winreg_dissect_struct_SecBuf(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *parent_tree _U_, dcerpc_info* di _U_, guint8 *drep _U_, int hf_index _U_, guint32 param _U_)
856 {
857         proto_item *item = NULL;
858         proto_tree *tree = NULL;
859         int old_offset;
860
861         ALIGN_TO_5_BYTES;
862
863         old_offset = offset;
864
865         if (parent_tree) {
866                 item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, ENC_NA);
867                 tree = proto_item_add_subtree(item, ett_winreg_winreg_SecBuf);
868         }
869         
870         offset = winreg_dissect_element_SecBuf_length(tvb, offset, pinfo, tree, di, drep);
871
872         offset = winreg_dissect_element_SecBuf_sd(tvb, offset, pinfo, tree, di, drep);
873
874         offset = winreg_dissect_element_SecBuf_inherit(tvb, offset, pinfo, tree, di, drep);
875
876
877         proto_item_set_len(item, offset-old_offset);
878
879
880         if (di->call_data->flags & DCERPC_IS_NDR64) {
881                 ALIGN_TO_5_BYTES;
882         }
883
884         return offset;
885 }
886
887
888 /* IDL: bitmap { */
889 /* IDL:         REG_OPTION_VOLATILE =  0x00000001 , */
890 /* IDL:         REG_OPTION_CREATE_LINK =  0x00000002 , */
891 /* IDL:         REG_OPTION_BACKUP_RESTORE =  0x00000004 , */
892 /* IDL:         REG_OPTION_OPEN_LINK =  0x00000008 , */
893 /* IDL: } */
894
895 int
896 winreg_dissect_bitmap_KeyOptions(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *parent_tree _U_, dcerpc_info* di _U_, guint8 *drep _U_, int hf_index _U_, guint32 param _U_)
897 {
898         proto_item *item = NULL;
899         proto_tree *tree = NULL;
900
901         guint32 flags;
902         ALIGN_TO_4_BYTES;
903
904         if (parent_tree) {
905                 item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, 4, DREP_ENC_INTEGER(drep));
906                 tree = proto_item_add_subtree(item,ett_winreg_winreg_KeyOptions);
907         }
908
909         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, -1, &flags);
910         proto_item_append_text(item, ": ");
911
912         if (!flags)
913                 proto_item_append_text(item, "(No values set)");
914
915         proto_tree_add_boolean(tree, hf_winreg_winreg_KeyOptions_REG_OPTION_VOLATILE, tvb, offset-4, 4, flags);
916         if (flags&( 0x00000001 )){
917                 proto_item_append_text(item, "REG_OPTION_VOLATILE");
918                 if (flags & (~( 0x00000001 )))
919                         proto_item_append_text(item, ", ");
920         }
921         flags&=(~( 0x00000001 ));
922
923         proto_tree_add_boolean(tree, hf_winreg_winreg_KeyOptions_REG_OPTION_CREATE_LINK, tvb, offset-4, 4, flags);
924         if (flags&( 0x00000002 )){
925                 proto_item_append_text(item, "REG_OPTION_CREATE_LINK");
926                 if (flags & (~( 0x00000002 )))
927                         proto_item_append_text(item, ", ");
928         }
929         flags&=(~( 0x00000002 ));
930
931         proto_tree_add_boolean(tree, hf_winreg_winreg_KeyOptions_REG_OPTION_BACKUP_RESTORE, tvb, offset-4, 4, flags);
932         if (flags&( 0x00000004 )){
933                 proto_item_append_text(item, "REG_OPTION_BACKUP_RESTORE");
934                 if (flags & (~( 0x00000004 )))
935                         proto_item_append_text(item, ", ");
936         }
937         flags&=(~( 0x00000004 ));
938
939         proto_tree_add_boolean(tree, hf_winreg_winreg_KeyOptions_REG_OPTION_OPEN_LINK, tvb, offset-4, 4, flags);
940         if (flags&( 0x00000008 )){
941                 proto_item_append_text(item, "REG_OPTION_OPEN_LINK");
942                 if (flags & (~( 0x00000008 )))
943                         proto_item_append_text(item, ", ");
944         }
945         flags&=(~( 0x00000008 ));
946
947         if (flags) {
948                 proto_item_append_text(item, "Unknown bitmap value 0x%x", flags);
949         }
950
951         return offset;
952 }
953
954
955 /* IDL: enum { */
956 /* IDL:         REG_ACTION_NONE=0, */
957 /* IDL:         REG_CREATED_NEW_KEY=1, */
958 /* IDL:         REG_OPENED_EXISTING_KEY=2, */
959 /* IDL: } */
960
961 int
962 winreg_dissect_enum_CreateAction(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_, int hf_index _U_, guint32 *param _U_)
963 {
964         guint32 parameter=0;
965         if(param){
966                 parameter=(guint32)*param;
967         }
968         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_index, &parameter);
969         if(param){
970                 *param=(guint32)parameter;
971         }
972         return offset;
973 }
974
975
976 /* IDL: struct { */
977 /* IDL:         [value(strlen_m_term_null(name)*2)] uint16 length; */
978 /* IDL:         uint16 size; */
979 /* IDL:         [unique(1)] [length_is(length/2)] [charset(UTF16)] [size_is(size/2)] uint16 *name; */
980 /* IDL: } */
981
982 static int
983 winreg_dissect_element_StringBuf_length(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
984 {
985         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_StringBuf_length, 0);
986
987         return offset;
988 }
989
990 static int
991 winreg_dissect_element_StringBuf_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
992 {
993         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_StringBuf_size, 0);
994
995         return offset;
996 }
997
998 static int
999 winreg_dissect_element_StringBuf_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1000 {
1001         offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_StringBuf_name_, NDR_POINTER_UNIQUE, "Pointer to Name (uint16)",hf_winreg_winreg_StringBuf_name);
1002
1003         return offset;
1004 }
1005
1006 static int
1007 winreg_dissect_element_StringBuf_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1008 {
1009         offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_StringBuf_name__);
1010
1011         return offset;
1012 }
1013
1014 static int
1015 winreg_dissect_element_StringBuf_name__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1016 {
1017         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_StringBuf_name, 0);
1018
1019         return offset;
1020 }
1021
1022 int
1023 winreg_dissect_struct_StringBuf(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *parent_tree _U_, dcerpc_info* di _U_, guint8 *drep _U_, int hf_index _U_, guint32 param _U_)
1024 {
1025         proto_item *item = NULL;
1026         proto_tree *tree = NULL;
1027         int old_offset;
1028
1029         ALIGN_TO_5_BYTES;
1030
1031         old_offset = offset;
1032
1033         if (parent_tree) {
1034                 item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, ENC_NA);
1035                 tree = proto_item_add_subtree(item, ett_winreg_winreg_StringBuf);
1036         }
1037         
1038         offset = winreg_dissect_element_StringBuf_length(tvb, offset, pinfo, tree, di, drep);
1039
1040         offset = winreg_dissect_element_StringBuf_size(tvb, offset, pinfo, tree, di, drep);
1041
1042         offset = winreg_dissect_element_StringBuf_name(tvb, offset, pinfo, tree, di, drep);
1043
1044
1045         proto_item_set_len(item, offset-old_offset);
1046
1047
1048         if (di->call_data->flags & DCERPC_IS_NDR64) {
1049                 ALIGN_TO_5_BYTES;
1050         }
1051
1052         return offset;
1053 }
1054
1055
1056 /* IDL: struct { */
1057 /* IDL:         [value(strlen_m_term(name)*2)] uint16 length; */
1058 /* IDL:         uint16 size; */
1059 /* IDL:         [unique(1)] [length_is(length/2)] [charset(UTF16)] [size_is(size/2)] uint16 *name; */
1060 /* IDL: } */
1061
1062 static int
1063 winreg_dissect_element_ValNameBuf_length(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1064 {
1065         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_ValNameBuf_length, 0);
1066
1067         return offset;
1068 }
1069
1070 static int
1071 winreg_dissect_element_ValNameBuf_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1072 {
1073         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_ValNameBuf_size, 0);
1074
1075         return offset;
1076 }
1077
1078 static int
1079 winreg_dissect_element_ValNameBuf_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1080 {
1081         offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_ValNameBuf_name_, NDR_POINTER_UNIQUE, "Pointer to Name (uint16)",hf_winreg_winreg_ValNameBuf_name);
1082
1083         return offset;
1084 }
1085
1086 static int
1087 winreg_dissect_element_ValNameBuf_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1088 {
1089         offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_ValNameBuf_name__);
1090
1091         return offset;
1092 }
1093
1094 static int
1095 winreg_dissect_element_ValNameBuf_name__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1096 {
1097         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_ValNameBuf_name, 0);
1098
1099         return offset;
1100 }
1101
1102 int
1103 winreg_dissect_struct_ValNameBuf(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *parent_tree _U_, dcerpc_info* di _U_, guint8 *drep _U_, int hf_index _U_, guint32 param _U_)
1104 {
1105         proto_item *item = NULL;
1106         proto_tree *tree = NULL;
1107         int old_offset;
1108
1109         ALIGN_TO_5_BYTES;
1110
1111         old_offset = offset;
1112
1113         if (parent_tree) {
1114                 item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, ENC_NA);
1115                 tree = proto_item_add_subtree(item, ett_winreg_winreg_ValNameBuf);
1116         }
1117         
1118         offset = winreg_dissect_element_ValNameBuf_length(tvb, offset, pinfo, tree, di, drep);
1119
1120         offset = winreg_dissect_element_ValNameBuf_size(tvb, offset, pinfo, tree, di, drep);
1121
1122         offset = winreg_dissect_element_ValNameBuf_name(tvb, offset, pinfo, tree, di, drep);
1123
1124
1125         proto_item_set_len(item, offset-old_offset);
1126
1127
1128         if (di->call_data->flags & DCERPC_IS_NDR64) {
1129                 ALIGN_TO_5_BYTES;
1130         }
1131
1132         return offset;
1133 }
1134
1135
1136 /* IDL: bitmap { */
1137 /* IDL:         REG_NOTIFY_CHANGE_NAME =  0x00000001 , */
1138 /* IDL:         REG_NOTIFY_CHANGE_ATTRIBUTES =  0x00000002 , */
1139 /* IDL:         REG_NOTIFY_CHANGE_LAST_SET =  0x00000004 , */
1140 /* IDL:         REG_NOTIFY_CHANGE_SECURITY =  0x00000008 , */
1141 /* IDL: } */
1142
1143 int
1144 winreg_dissect_bitmap_NotifyChangeType(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *parent_tree _U_, dcerpc_info* di _U_, guint8 *drep _U_, int hf_index _U_, guint32 param _U_)
1145 {
1146         proto_item *item = NULL;
1147         proto_tree *tree = NULL;
1148
1149         guint32 flags;
1150         ALIGN_TO_4_BYTES;
1151
1152         if (parent_tree) {
1153                 item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, 4, DREP_ENC_INTEGER(drep));
1154                 tree = proto_item_add_subtree(item,ett_winreg_winreg_NotifyChangeType);
1155         }
1156
1157         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, -1, &flags);
1158         proto_item_append_text(item, ": ");
1159
1160         if (!flags)
1161                 proto_item_append_text(item, "(No values set)");
1162
1163         proto_tree_add_boolean(tree, hf_winreg_winreg_NotifyChangeType_REG_NOTIFY_CHANGE_NAME, tvb, offset-4, 4, flags);
1164         if (flags&( 0x00000001 )){
1165                 proto_item_append_text(item, "REG_NOTIFY_CHANGE_NAME");
1166                 if (flags & (~( 0x00000001 )))
1167                         proto_item_append_text(item, ", ");
1168         }
1169         flags&=(~( 0x00000001 ));
1170
1171         proto_tree_add_boolean(tree, hf_winreg_winreg_NotifyChangeType_REG_NOTIFY_CHANGE_ATTRIBUTES, tvb, offset-4, 4, flags);
1172         if (flags&( 0x00000002 )){
1173                 proto_item_append_text(item, "REG_NOTIFY_CHANGE_ATTRIBUTES");
1174                 if (flags & (~( 0x00000002 )))
1175                         proto_item_append_text(item, ", ");
1176         }
1177         flags&=(~( 0x00000002 ));
1178
1179         proto_tree_add_boolean(tree, hf_winreg_winreg_NotifyChangeType_REG_NOTIFY_CHANGE_LAST_SET, tvb, offset-4, 4, flags);
1180         if (flags&( 0x00000004 )){
1181                 proto_item_append_text(item, "REG_NOTIFY_CHANGE_LAST_SET");
1182                 if (flags & (~( 0x00000004 )))
1183                         proto_item_append_text(item, ", ");
1184         }
1185         flags&=(~( 0x00000004 ));
1186
1187         proto_tree_add_boolean(tree, hf_winreg_winreg_NotifyChangeType_REG_NOTIFY_CHANGE_SECURITY, tvb, offset-4, 4, flags);
1188         if (flags&( 0x00000008 )){
1189                 proto_item_append_text(item, "REG_NOTIFY_CHANGE_SECURITY");
1190                 if (flags & (~( 0x00000008 )))
1191                         proto_item_append_text(item, ", ");
1192         }
1193         flags&=(~( 0x00000008 ));
1194
1195         if (flags) {
1196                 proto_item_append_text(item, "Unknown bitmap value 0x%x", flags);
1197         }
1198
1199         return offset;
1200 }
1201
1202
1203 /* IDL: bitmap { */
1204 /* IDL:         REG_WHOLE_HIVE_VOLATILE =  0x00000001 , */
1205 /* IDL:         REG_REFRESH_HIVE =  0x00000002 , */
1206 /* IDL:         REG_NO_LAZY_FLUSH =  0x00000004 , */
1207 /* IDL:         REG_FORCE_RESTORE =  0x00000008 , */
1208 /* IDL: } */
1209
1210 int
1211 winreg_dissect_bitmap_RestoreKeyFlags(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *parent_tree _U_, dcerpc_info* di _U_, guint8 *drep _U_, int hf_index _U_, guint32 param _U_)
1212 {
1213         proto_item *item = NULL;
1214         proto_tree *tree = NULL;
1215
1216         guint32 flags;
1217         ALIGN_TO_4_BYTES;
1218
1219         if (parent_tree) {
1220                 item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, 4, DREP_ENC_INTEGER(drep));
1221                 tree = proto_item_add_subtree(item,ett_winreg_winreg_RestoreKeyFlags);
1222         }
1223
1224         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, -1, &flags);
1225         proto_item_append_text(item, ": ");
1226
1227         if (!flags)
1228                 proto_item_append_text(item, "(No values set)");
1229
1230         proto_tree_add_boolean(tree, hf_winreg_winreg_RestoreKeyFlags_REG_WHOLE_HIVE_VOLATILE, tvb, offset-4, 4, flags);
1231         if (flags&( 0x00000001 )){
1232                 proto_item_append_text(item, "REG_WHOLE_HIVE_VOLATILE");
1233                 if (flags & (~( 0x00000001 )))
1234                         proto_item_append_text(item, ", ");
1235         }
1236         flags&=(~( 0x00000001 ));
1237
1238         proto_tree_add_boolean(tree, hf_winreg_winreg_RestoreKeyFlags_REG_REFRESH_HIVE, tvb, offset-4, 4, flags);
1239         if (flags&( 0x00000002 )){
1240                 proto_item_append_text(item, "REG_REFRESH_HIVE");
1241                 if (flags & (~( 0x00000002 )))
1242                         proto_item_append_text(item, ", ");
1243         }
1244         flags&=(~( 0x00000002 ));
1245
1246         proto_tree_add_boolean(tree, hf_winreg_winreg_RestoreKeyFlags_REG_NO_LAZY_FLUSH, tvb, offset-4, 4, flags);
1247         if (flags&( 0x00000004 )){
1248                 proto_item_append_text(item, "REG_NO_LAZY_FLUSH");
1249                 if (flags & (~( 0x00000004 )))
1250                         proto_item_append_text(item, ", ");
1251         }
1252         flags&=(~( 0x00000004 ));
1253
1254         proto_tree_add_boolean(tree, hf_winreg_winreg_RestoreKeyFlags_REG_FORCE_RESTORE, tvb, offset-4, 4, flags);
1255         if (flags&( 0x00000008 )){
1256                 proto_item_append_text(item, "REG_FORCE_RESTORE");
1257                 if (flags & (~( 0x00000008 )))
1258                         proto_item_append_text(item, ", ");
1259         }
1260         flags&=(~( 0x00000008 ));
1261
1262         if (flags) {
1263                 proto_item_append_text(item, "Unknown bitmap value 0x%x", flags);
1264         }
1265
1266         return offset;
1267 }
1268
1269
1270 /* IDL: struct { */
1271 /* IDL:         uint32 data_size; */
1272 /* IDL:         KeySecurityData sec_data; */
1273 /* IDL:         uint8 inherit; */
1274 /* IDL: } */
1275
1276 static int
1277 winreg_dissect_element_KeySecurityAttribute_data_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1278 {
1279         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_KeySecurityAttribute_data_size, 0);
1280
1281         return offset;
1282 }
1283
1284 static int
1285 winreg_dissect_element_KeySecurityAttribute_sec_data(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1286 {
1287         offset = winreg_dissect_struct_KeySecurityData(tvb,offset,pinfo,tree,di,drep,hf_winreg_KeySecurityAttribute_sec_data,0);
1288
1289         return offset;
1290 }
1291
1292 static int
1293 winreg_dissect_element_KeySecurityAttribute_inherit(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1294 {
1295         offset = PIDL_dissect_uint8(tvb, offset, pinfo, tree, di, drep, hf_winreg_KeySecurityAttribute_inherit, 0);
1296
1297         return offset;
1298 }
1299
1300 int
1301 winreg_dissect_struct_KeySecurityAttribute(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *parent_tree _U_, dcerpc_info* di _U_, guint8 *drep _U_, int hf_index _U_, guint32 param _U_)
1302 {
1303         proto_item *item = NULL;
1304         proto_tree *tree = NULL;
1305         int old_offset;
1306
1307         ALIGN_TO_5_BYTES;
1308
1309         old_offset = offset;
1310
1311         if (parent_tree) {
1312                 item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, ENC_NA);
1313                 tree = proto_item_add_subtree(item, ett_winreg_KeySecurityAttribute);
1314         }
1315         
1316         offset = winreg_dissect_element_KeySecurityAttribute_data_size(tvb, offset, pinfo, tree, di, drep);
1317
1318         offset = winreg_dissect_element_KeySecurityAttribute_sec_data(tvb, offset, pinfo, tree, di, drep);
1319
1320         offset = winreg_dissect_element_KeySecurityAttribute_inherit(tvb, offset, pinfo, tree, di, drep);
1321
1322
1323         proto_item_set_len(item, offset-old_offset);
1324
1325
1326         if (di->call_data->flags & DCERPC_IS_NDR64) {
1327                 ALIGN_TO_5_BYTES;
1328         }
1329
1330         return offset;
1331 }
1332
1333
1334 /* IDL: struct { */
1335 /* IDL:         [unique(1)] winreg_ValNameBuf *ve_valuename; */
1336 /* IDL:         uint32 ve_valuelen; */
1337 /* IDL:         uint32 ve_valueptr; */
1338 /* IDL:         winreg_Type ve_type; */
1339 /* IDL: } */
1340
1341 static int
1342 winreg_dissect_element_QueryMultipleValue_ve_valuename(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1343 {
1344         offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValue_ve_valuename_, NDR_POINTER_UNIQUE, "Pointer to Ve Valuename (winreg_ValNameBuf)",hf_winreg_QueryMultipleValue_ve_valuename);
1345
1346         return offset;
1347 }
1348
1349 static int
1350 winreg_dissect_element_QueryMultipleValue_ve_valuename_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1351 {
1352         offset = winreg_dissect_struct_ValNameBuf(tvb,offset,pinfo,tree,di,drep,hf_winreg_QueryMultipleValue_ve_valuename,0);
1353
1354         return offset;
1355 }
1356
1357 static int
1358 winreg_dissect_element_QueryMultipleValue_ve_valuelen(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1359 {
1360         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_QueryMultipleValue_ve_valuelen, 0);
1361
1362         return offset;
1363 }
1364
1365 static int
1366 winreg_dissect_element_QueryMultipleValue_ve_valueptr(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1367 {
1368         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_QueryMultipleValue_ve_valueptr, 0);
1369
1370         return offset;
1371 }
1372
1373 static int
1374 winreg_dissect_element_QueryMultipleValue_ve_type(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1375 {
1376         offset=misc_dissect_enum_winreg_Type(tvb, offset, pinfo, tree, di, drep, hf_winreg_QueryMultipleValue_ve_type, 0);
1377
1378         return offset;
1379 }
1380
1381 int
1382 winreg_dissect_struct_QueryMultipleValue(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *parent_tree _U_, dcerpc_info* di _U_, guint8 *drep _U_, int hf_index _U_, guint32 param _U_)
1383 {
1384         proto_item *item = NULL;
1385         proto_tree *tree = NULL;
1386         int old_offset;
1387
1388         ALIGN_TO_5_BYTES;
1389
1390         old_offset = offset;
1391
1392         if (parent_tree) {
1393                 item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, ENC_NA);
1394                 tree = proto_item_add_subtree(item, ett_winreg_QueryMultipleValue);
1395         }
1396         
1397         offset = winreg_dissect_element_QueryMultipleValue_ve_valuename(tvb, offset, pinfo, tree, di, drep);
1398
1399         offset = winreg_dissect_element_QueryMultipleValue_ve_valuelen(tvb, offset, pinfo, tree, di, drep);
1400
1401         offset = winreg_dissect_element_QueryMultipleValue_ve_valueptr(tvb, offset, pinfo, tree, di, drep);
1402
1403         offset = winreg_dissect_element_QueryMultipleValue_ve_type(tvb, offset, pinfo, tree, di, drep);
1404
1405
1406         proto_item_set_len(item, offset-old_offset);
1407
1408
1409         if (di->call_data->flags & DCERPC_IS_NDR64) {
1410                 ALIGN_TO_5_BYTES;
1411         }
1412
1413         return offset;
1414 }
1415
1416 static int
1417 winreg_dissect_element_OpenHKCR_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1418 {
1419         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKCR_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_system_name);
1420
1421         return offset;
1422 }
1423
1424 static int
1425 winreg_dissect_element_OpenHKCR_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1426 {
1427         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_system_name, 0);
1428
1429         return offset;
1430 }
1431
1432 static int
1433 winreg_dissect_element_OpenHKCR_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1434 {
1435         offset = winreg_dissect_bitmap_AccessMask(tvb, offset, pinfo, tree, di, drep, hf_winreg_access_mask, 0);
1436
1437         return offset;
1438 }
1439
1440 static int
1441 winreg_dissect_element_OpenHKCR_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1442 {
1443         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKCR_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
1444
1445         return offset;
1446 }
1447
1448 static int
1449 winreg_dissect_element_OpenHKCR_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1450 {
1451         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, PIDL_POLHND_OPEN);
1452
1453         return offset;
1454 }
1455
1456 /* IDL: WERROR winreg_OpenHKCR( */
1457 /* IDL: [unique(1)] [in] uint16 *system_name, */
1458 /* IDL: [in] winreg_AccessMask access_mask, */
1459 /* IDL: [out] [ref] policy_handle *handle */
1460 /* IDL: ); */
1461
1462 static int
1463 winreg_dissect_OpenHKCR_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1464 {
1465         guint32 status;
1466
1467         di->dcerpc_procedure_name="OpenHKCR";
1468         offset = winreg_dissect_element_OpenHKCR_handle(tvb, offset, pinfo, tree, di, drep);
1469         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1470
1471         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
1472
1473         if (status != 0)
1474                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
1475
1476         return offset;
1477 }
1478
1479 static int
1480 winreg_dissect_OpenHKCR_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1481 {
1482         di->dcerpc_procedure_name="OpenHKCR";
1483         offset = winreg_dissect_element_OpenHKCR_system_name(tvb, offset, pinfo, tree, di, drep);
1484         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1485         offset = winreg_dissect_element_OpenHKCR_access_mask(tvb, offset, pinfo, tree, di, drep);
1486         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1487         return offset;
1488 }
1489
1490 static int
1491 winreg_dissect_element_OpenHKCU_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1492 {
1493         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKCU_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_system_name);
1494
1495         return offset;
1496 }
1497
1498 static int
1499 winreg_dissect_element_OpenHKCU_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1500 {
1501         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_system_name, 0);
1502
1503         return offset;
1504 }
1505
1506 static int
1507 winreg_dissect_element_OpenHKCU_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1508 {
1509         offset = winreg_dissect_bitmap_AccessMask(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_OpenHKCU_access_mask, 0);
1510
1511         return offset;
1512 }
1513
1514 static int
1515 winreg_dissect_element_OpenHKCU_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1516 {
1517         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKCU_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
1518
1519         return offset;
1520 }
1521
1522 static int
1523 winreg_dissect_element_OpenHKCU_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1524 {
1525         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, PIDL_POLHND_OPEN);
1526
1527         return offset;
1528 }
1529
1530 /* IDL: WERROR winreg_OpenHKCU( */
1531 /* IDL: [unique(1)] [in] uint16 *system_name, */
1532 /* IDL: [in] winreg_AccessMask access_mask, */
1533 /* IDL: [out] [ref] policy_handle *handle */
1534 /* IDL: ); */
1535
1536 static int
1537 winreg_dissect_OpenHKCU_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1538 {
1539         guint32 status;
1540
1541         di->dcerpc_procedure_name="OpenHKCU";
1542         offset = winreg_dissect_element_OpenHKCU_handle(tvb, offset, pinfo, tree, di, drep);
1543         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1544
1545         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
1546
1547         if (status != 0)
1548                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
1549
1550         return offset;
1551 }
1552
1553 static int
1554 winreg_dissect_OpenHKCU_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1555 {
1556         di->dcerpc_procedure_name="OpenHKCU";
1557         offset = winreg_dissect_element_OpenHKCU_system_name(tvb, offset, pinfo, tree, di, drep);
1558         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1559         offset = winreg_dissect_element_OpenHKCU_access_mask(tvb, offset, pinfo, tree, di, drep);
1560         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1561         return offset;
1562 }
1563
1564 static int
1565 winreg_dissect_element_OpenHKLM_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1566 {
1567         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKLM_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_system_name);
1568
1569         return offset;
1570 }
1571
1572 static int
1573 winreg_dissect_element_OpenHKLM_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1574 {
1575         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_system_name, 0);
1576
1577         return offset;
1578 }
1579
1580 static int
1581 winreg_dissect_element_OpenHKLM_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1582 {
1583         offset = winreg_dissect_bitmap_AccessMask(tvb, offset, pinfo, tree, di, drep, hf_winreg_access_mask, 0);
1584
1585         return offset;
1586 }
1587
1588 static int
1589 winreg_dissect_element_OpenHKLM_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1590 {
1591         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKLM_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
1592
1593         return offset;
1594 }
1595
1596 static int
1597 winreg_dissect_element_OpenHKLM_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1598 {
1599         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, PIDL_POLHND_OPEN);
1600
1601         return offset;
1602 }
1603
1604 /* IDL: WERROR winreg_OpenHKLM( */
1605 /* IDL: [unique(1)] [in] uint16 *system_name, */
1606 /* IDL: [in] winreg_AccessMask access_mask, */
1607 /* IDL: [out] [ref] policy_handle *handle */
1608 /* IDL: ); */
1609
1610 static int
1611 winreg_dissect_OpenHKLM_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1612 {
1613         guint32 status;
1614
1615         di->dcerpc_procedure_name="OpenHKLM";
1616         offset = winreg_dissect_element_OpenHKLM_handle(tvb, offset, pinfo, tree, di, drep);
1617         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1618
1619         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
1620
1621         if (status != 0)
1622                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
1623
1624         return offset;
1625 }
1626
1627 static int
1628 winreg_dissect_OpenHKLM_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1629 {
1630         di->dcerpc_procedure_name="OpenHKLM";
1631         offset = winreg_dissect_element_OpenHKLM_system_name(tvb, offset, pinfo, tree, di, drep);
1632         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1633         offset = winreg_dissect_element_OpenHKLM_access_mask(tvb, offset, pinfo, tree, di, drep);
1634         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1635         return offset;
1636 }
1637
1638 static int
1639 winreg_dissect_element_OpenHKPD_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1640 {
1641         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKPD_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_system_name);
1642
1643         return offset;
1644 }
1645
1646 static int
1647 winreg_dissect_element_OpenHKPD_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1648 {
1649         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_system_name, 0);
1650
1651         return offset;
1652 }
1653
1654 static int
1655 winreg_dissect_element_OpenHKPD_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1656 {
1657         offset = winreg_dissect_bitmap_AccessMask(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_OpenHKPD_access_mask, 0);
1658
1659         return offset;
1660 }
1661
1662 static int
1663 winreg_dissect_element_OpenHKPD_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1664 {
1665         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKPD_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
1666
1667         return offset;
1668 }
1669
1670 static int
1671 winreg_dissect_element_OpenHKPD_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1672 {
1673         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, PIDL_POLHND_OPEN);
1674
1675         return offset;
1676 }
1677
1678 /* IDL: WERROR winreg_OpenHKPD( */
1679 /* IDL: [unique(1)] [in] uint16 *system_name, */
1680 /* IDL: [in] winreg_AccessMask access_mask, */
1681 /* IDL: [out] [ref] policy_handle *handle */
1682 /* IDL: ); */
1683
1684 static int
1685 winreg_dissect_OpenHKPD_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1686 {
1687         guint32 status;
1688
1689         di->dcerpc_procedure_name="OpenHKPD";
1690         offset = winreg_dissect_element_OpenHKPD_handle(tvb, offset, pinfo, tree, di, drep);
1691         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1692
1693         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
1694
1695         if (status != 0)
1696                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
1697
1698         return offset;
1699 }
1700
1701 static int
1702 winreg_dissect_OpenHKPD_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1703 {
1704         di->dcerpc_procedure_name="OpenHKPD";
1705         offset = winreg_dissect_element_OpenHKPD_system_name(tvb, offset, pinfo, tree, di, drep);
1706         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1707         offset = winreg_dissect_element_OpenHKPD_access_mask(tvb, offset, pinfo, tree, di, drep);
1708         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1709         return offset;
1710 }
1711
1712 static int
1713 winreg_dissect_element_OpenHKU_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1714 {
1715         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKU_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_system_name);
1716
1717         return offset;
1718 }
1719
1720 static int
1721 winreg_dissect_element_OpenHKU_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1722 {
1723         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_system_name, 0);
1724
1725         return offset;
1726 }
1727
1728 static int
1729 winreg_dissect_element_OpenHKU_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1730 {
1731         offset = winreg_dissect_bitmap_AccessMask(tvb, offset, pinfo, tree, di, drep, hf_winreg_access_mask, 0);
1732
1733         return offset;
1734 }
1735
1736 static int
1737 winreg_dissect_element_OpenHKU_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1738 {
1739         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKU_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
1740
1741         return offset;
1742 }
1743
1744 static int
1745 winreg_dissect_element_OpenHKU_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1746 {
1747         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, PIDL_POLHND_OPEN);
1748
1749         return offset;
1750 }
1751
1752 /* IDL: WERROR winreg_OpenHKU( */
1753 /* IDL: [unique(1)] [in] uint16 *system_name, */
1754 /* IDL: [in] winreg_AccessMask access_mask, */
1755 /* IDL: [out] [ref] policy_handle *handle */
1756 /* IDL: ); */
1757
1758 static int
1759 winreg_dissect_OpenHKU_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1760 {
1761         guint32 status;
1762
1763         di->dcerpc_procedure_name="OpenHKU";
1764         offset = winreg_dissect_element_OpenHKU_handle(tvb, offset, pinfo, tree, di, drep);
1765         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1766
1767         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
1768
1769         if (status != 0)
1770                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
1771
1772         return offset;
1773 }
1774
1775 static int
1776 winreg_dissect_OpenHKU_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1777 {
1778         di->dcerpc_procedure_name="OpenHKU";
1779         offset = winreg_dissect_element_OpenHKU_system_name(tvb, offset, pinfo, tree, di, drep);
1780         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1781         offset = winreg_dissect_element_OpenHKU_access_mask(tvb, offset, pinfo, tree, di, drep);
1782         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1783         return offset;
1784 }
1785
1786 static int
1787 winreg_dissect_element_CloseKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1788 {
1789         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_CloseKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
1790
1791         return offset;
1792 }
1793
1794 static int
1795 winreg_dissect_element_CloseKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1796 {
1797         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, PIDL_POLHND_CLOSE);
1798
1799         return offset;
1800 }
1801
1802 /* IDL: WERROR winreg_CloseKey( */
1803 /* IDL: [out] [in] [ref] policy_handle *handle */
1804 /* IDL: ); */
1805
1806 static int
1807 winreg_dissect_CloseKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1808 {
1809         guint32 status;
1810
1811         di->dcerpc_procedure_name="CloseKey";
1812         offset = winreg_dissect_element_CloseKey_handle(tvb, offset, pinfo, tree, di, drep);
1813         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1814
1815         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
1816
1817         if (status != 0)
1818                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
1819
1820         return offset;
1821 }
1822
1823 static int
1824 winreg_dissect_CloseKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1825 {
1826         di->dcerpc_procedure_name="CloseKey";
1827         offset = winreg_dissect_element_CloseKey_handle(tvb, offset, pinfo, tree, di, drep);
1828         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1829         return offset;
1830 }
1831
1832 static int
1833 winreg_dissect_element_CreateKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1834 {
1835         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_CreateKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
1836
1837         return offset;
1838 }
1839
1840 static int
1841 winreg_dissect_element_CreateKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1842 {
1843         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
1844
1845         return offset;
1846 }
1847
1848 static int
1849 winreg_dissect_element_CreateKey_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1850 {
1851         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 2|PIDL_SET_COL_INFO, hf_winreg_winreg_CreateKey_name);
1852
1853         return offset;
1854 }
1855
1856 static int
1857 winreg_dissect_element_CreateKey_keyclass(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1858 {
1859         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_CreateKey_keyclass);
1860
1861         return offset;
1862 }
1863
1864 static int
1865 winreg_dissect_element_CreateKey_options(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1866 {
1867         offset = winreg_dissect_bitmap_KeyOptions(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_CreateKey_options, 0);
1868
1869         return offset;
1870 }
1871
1872 static int
1873 winreg_dissect_element_CreateKey_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1874 {
1875         offset = winreg_dissect_bitmap_AccessMask(tvb, offset, pinfo, tree, di, drep, hf_winreg_access_mask, 0);
1876
1877         return offset;
1878 }
1879
1880 static int
1881 winreg_dissect_element_CreateKey_secdesc(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1882 {
1883         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_CreateKey_secdesc_, NDR_POINTER_UNIQUE, "Pointer to Secdesc (winreg_SecBuf)",hf_winreg_winreg_CreateKey_secdesc);
1884
1885         return offset;
1886 }
1887
1888 static int
1889 winreg_dissect_element_CreateKey_secdesc_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1890 {
1891         offset = winreg_dissect_struct_SecBuf(tvb,offset,pinfo,tree,di,drep,hf_winreg_winreg_CreateKey_secdesc,0);
1892
1893         return offset;
1894 }
1895
1896 static int
1897 winreg_dissect_element_CreateKey_new_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1898 {
1899         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_CreateKey_new_handle_, NDR_POINTER_REF, "Pointer to New Handle (policy_handle)",hf_winreg_winreg_CreateKey_new_handle);
1900
1901         return offset;
1902 }
1903
1904 static int
1905 winreg_dissect_element_CreateKey_new_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1906 {
1907         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_CreateKey_new_handle, PIDL_POLHND_OPEN);
1908
1909         return offset;
1910 }
1911
1912 static int
1913 winreg_dissect_element_CreateKey_action_taken(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1914 {
1915         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_CreateKey_action_taken_, NDR_POINTER_UNIQUE, "Pointer to Action Taken (winreg_CreateAction)",hf_winreg_winreg_CreateKey_action_taken);
1916
1917         return offset;
1918 }
1919
1920 static int
1921 winreg_dissect_element_CreateKey_action_taken_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1922 {
1923         offset = winreg_dissect_enum_CreateAction(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_CreateKey_action_taken, 0);
1924
1925         return offset;
1926 }
1927
1928 /* IDL: WERROR winreg_CreateKey( */
1929 /* IDL: [in] [ref] policy_handle *handle, */
1930 /* IDL: [in] winreg_String name, */
1931 /* IDL: [in] winreg_String keyclass, */
1932 /* IDL: [in] winreg_KeyOptions options, */
1933 /* IDL: [in] winreg_AccessMask access_mask, */
1934 /* IDL: [unique(1)] [in] winreg_SecBuf *secdesc, */
1935 /* IDL: [out] [ref] policy_handle *new_handle, */
1936 /* IDL: [out] [unique(1)] [in] winreg_CreateAction *action_taken */
1937 /* IDL: ); */
1938
1939 static int
1940 winreg_dissect_CreateKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1941 {
1942         guint32 status;
1943
1944         di->dcerpc_procedure_name="CreateKey";
1945         offset = winreg_dissect_element_CreateKey_new_handle(tvb, offset, pinfo, tree, di, drep);
1946         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1947
1948         offset = winreg_dissect_element_CreateKey_action_taken(tvb, offset, pinfo, tree, di, drep);
1949         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1950
1951         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
1952
1953         if (status != 0)
1954                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
1955
1956         return offset;
1957 }
1958
1959 static int
1960 winreg_dissect_CreateKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1961 {
1962         di->dcerpc_procedure_name="CreateKey";
1963         offset = winreg_dissect_element_CreateKey_handle(tvb, offset, pinfo, tree, di, drep);
1964         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1965         offset = winreg_dissect_element_CreateKey_name(tvb, offset, pinfo, tree, di, drep);
1966         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1967         offset = winreg_dissect_element_CreateKey_keyclass(tvb, offset, pinfo, tree, di, drep);
1968         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1969         offset = winreg_dissect_element_CreateKey_options(tvb, offset, pinfo, tree, di, drep);
1970         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1971         offset = winreg_dissect_element_CreateKey_access_mask(tvb, offset, pinfo, tree, di, drep);
1972         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1973         offset = winreg_dissect_element_CreateKey_secdesc(tvb, offset, pinfo, tree, di, drep);
1974         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1975         offset = winreg_dissect_element_CreateKey_action_taken(tvb, offset, pinfo, tree, di, drep);
1976         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
1977         return offset;
1978 }
1979
1980 static int
1981 winreg_dissect_element_DeleteKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1982 {
1983         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_DeleteKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
1984
1985         return offset;
1986 }
1987
1988 static int
1989 winreg_dissect_element_DeleteKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1990 {
1991         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
1992
1993         return offset;
1994 }
1995
1996 static int
1997 winreg_dissect_element_DeleteKey_key(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
1998 {
1999         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 2|PIDL_SET_COL_INFO, hf_winreg_winreg_DeleteKey_key);
2000
2001         return offset;
2002 }
2003
2004 /* IDL: WERROR winreg_DeleteKey( */
2005 /* IDL: [in] [ref] policy_handle *handle, */
2006 /* IDL: [in] winreg_String key */
2007 /* IDL: ); */
2008
2009 static int
2010 winreg_dissect_DeleteKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2011 {
2012         guint32 status;
2013
2014         di->dcerpc_procedure_name="DeleteKey";
2015         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
2016
2017         if (status != 0)
2018                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
2019
2020         return offset;
2021 }
2022
2023 static int
2024 winreg_dissect_DeleteKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2025 {
2026         di->dcerpc_procedure_name="DeleteKey";
2027         offset = winreg_dissect_element_DeleteKey_handle(tvb, offset, pinfo, tree, di, drep);
2028         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2029         offset = winreg_dissect_element_DeleteKey_key(tvb, offset, pinfo, tree, di, drep);
2030         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2031         return offset;
2032 }
2033
2034 static int
2035 winreg_dissect_element_DeleteValue_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2036 {
2037         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_DeleteValue_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
2038
2039         return offset;
2040 }
2041
2042 static int
2043 winreg_dissect_element_DeleteValue_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2044 {
2045         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
2046
2047         return offset;
2048 }
2049
2050 static int
2051 winreg_dissect_element_DeleteValue_value(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2052 {
2053         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_DeleteValue_value);
2054
2055         return offset;
2056 }
2057
2058 /* IDL: WERROR winreg_DeleteValue( */
2059 /* IDL: [in] [ref] policy_handle *handle, */
2060 /* IDL: [in] winreg_String value */
2061 /* IDL: ); */
2062
2063 static int
2064 winreg_dissect_DeleteValue_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2065 {
2066         guint32 status;
2067
2068         di->dcerpc_procedure_name="DeleteValue";
2069         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
2070
2071         if (status != 0)
2072                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
2073
2074         return offset;
2075 }
2076
2077 static int
2078 winreg_dissect_DeleteValue_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2079 {
2080         di->dcerpc_procedure_name="DeleteValue";
2081         offset = winreg_dissect_element_DeleteValue_handle(tvb, offset, pinfo, tree, di, drep);
2082         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2083         offset = winreg_dissect_element_DeleteValue_value(tvb, offset, pinfo, tree, di, drep);
2084         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2085         return offset;
2086 }
2087
2088 static int
2089 winreg_dissect_element_EnumKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2090 {
2091         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_EnumKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
2092
2093         return offset;
2094 }
2095
2096 static int
2097 winreg_dissect_element_EnumKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2098 {
2099         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
2100
2101         return offset;
2102 }
2103
2104 static int
2105 winreg_dissect_element_EnumKey_enum_index(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2106 {
2107         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_EnumKey_enum_index, 0);
2108
2109         return offset;
2110 }
2111
2112 static int
2113 winreg_dissect_element_EnumKey_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2114 {
2115         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_EnumKey_name_, NDR_POINTER_REF, "Pointer to Name (winreg_StringBuf)",hf_winreg_winreg_EnumKey_name);
2116
2117         return offset;
2118 }
2119
2120 static int
2121 winreg_dissect_element_EnumKey_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2122 {
2123         offset = winreg_dissect_struct_StringBuf(tvb,offset,pinfo,tree,di,drep,hf_winreg_winreg_EnumKey_name,0);
2124
2125         return offset;
2126 }
2127
2128 static int
2129 winreg_dissect_element_EnumKey_keyclass(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2130 {
2131         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_EnumKey_keyclass_, NDR_POINTER_UNIQUE, "Pointer to Keyclass (winreg_StringBuf)",hf_winreg_winreg_EnumKey_keyclass);
2132
2133         return offset;
2134 }
2135
2136 static int
2137 winreg_dissect_element_EnumKey_keyclass_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2138 {
2139         offset = winreg_dissect_struct_StringBuf(tvb,offset,pinfo,tree,di,drep,hf_winreg_winreg_EnumKey_keyclass,0);
2140
2141         return offset;
2142 }
2143
2144 static int
2145 winreg_dissect_element_EnumKey_last_changed_time(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2146 {
2147         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_EnumKey_last_changed_time_, NDR_POINTER_UNIQUE, "Pointer to Last Changed Time (NTTIME)",hf_winreg_winreg_EnumKey_last_changed_time);
2148
2149         return offset;
2150 }
2151
2152 static int
2153 winreg_dissect_element_EnumKey_last_changed_time_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2154 {
2155         offset = dissect_ndr_nt_NTTIME(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_EnumKey_last_changed_time);
2156
2157         return offset;
2158 }
2159
2160 /* IDL: WERROR winreg_EnumKey( */
2161 /* IDL: [in] [ref] policy_handle *handle, */
2162 /* IDL: [in] uint32 enum_index, */
2163 /* IDL: [out] [in] [ref] winreg_StringBuf *name, */
2164 /* IDL: [out] [unique(1)] [in] winreg_StringBuf *keyclass, */
2165 /* IDL: [out] [unique(1)] [in] NTTIME *last_changed_time */
2166 /* IDL: ); */
2167
2168 static int
2169 winreg_dissect_EnumKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2170 {
2171         guint32 status;
2172
2173         di->dcerpc_procedure_name="EnumKey";
2174         offset = winreg_dissect_element_EnumKey_name(tvb, offset, pinfo, tree, di, drep);
2175         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2176
2177         offset = winreg_dissect_element_EnumKey_keyclass(tvb, offset, pinfo, tree, di, drep);
2178         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2179
2180         offset = winreg_dissect_element_EnumKey_last_changed_time(tvb, offset, pinfo, tree, di, drep);
2181         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2182
2183         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
2184
2185         if (status != 0)
2186                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
2187
2188         return offset;
2189 }
2190
2191 static int
2192 winreg_dissect_EnumKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2193 {
2194         di->dcerpc_procedure_name="EnumKey";
2195         offset = winreg_dissect_element_EnumKey_handle(tvb, offset, pinfo, tree, di, drep);
2196         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2197         offset = winreg_dissect_element_EnumKey_enum_index(tvb, offset, pinfo, tree, di, drep);
2198         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2199         offset = winreg_dissect_element_EnumKey_name(tvb, offset, pinfo, tree, di, drep);
2200         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2201         offset = winreg_dissect_element_EnumKey_keyclass(tvb, offset, pinfo, tree, di, drep);
2202         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2203         offset = winreg_dissect_element_EnumKey_last_changed_time(tvb, offset, pinfo, tree, di, drep);
2204         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2205         return offset;
2206 }
2207
2208 static int
2209 winreg_dissect_element_EnumValue_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2210 {
2211         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_EnumValue_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
2212
2213         return offset;
2214 }
2215
2216 static int
2217 winreg_dissect_element_EnumValue_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2218 {
2219         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
2220
2221         return offset;
2222 }
2223
2224 static int
2225 winreg_dissect_element_EnumValue_enum_index(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2226 {
2227         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_EnumValue_enum_index, 0);
2228
2229         return offset;
2230 }
2231
2232 static int
2233 winreg_dissect_element_EnumValue_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2234 {
2235         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_EnumValue_name_, NDR_POINTER_REF, "Pointer to Name (winreg_ValNameBuf)",hf_winreg_winreg_EnumValue_name);
2236
2237         return offset;
2238 }
2239
2240 static int
2241 winreg_dissect_element_EnumValue_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2242 {
2243         offset = winreg_dissect_struct_ValNameBuf(tvb,offset,pinfo,tree,di,drep,hf_winreg_winreg_EnumValue_name,0);
2244
2245         return offset;
2246 }
2247
2248 static int
2249 winreg_dissect_element_EnumValue_type(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2250 {
2251         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_EnumValue_type_, NDR_POINTER_UNIQUE, "Pointer to Type (winreg_Type)",hf_winreg_winreg_EnumValue_type);
2252
2253         return offset;
2254 }
2255
2256 static int
2257 winreg_dissect_element_EnumValue_type_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2258 {
2259         offset=misc_dissect_enum_winreg_Type(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_EnumValue_type, 0);
2260
2261         return offset;
2262 }
2263
2264 static int
2265 winreg_dissect_element_EnumValue_value(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2266 {
2267         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_EnumValue_value_, NDR_POINTER_UNIQUE, "Pointer to Value (uint8)",hf_winreg_winreg_EnumValue_value);
2268
2269         return offset;
2270 }
2271
2272 static int
2273 winreg_dissect_element_EnumValue_value_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2274 {
2275         offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_EnumValue_value__);
2276
2277         return offset;
2278 }
2279
2280 static int
2281 winreg_dissect_element_EnumValue_value__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2282 {
2283         offset = PIDL_dissect_uint8(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_EnumValue_value, 0);
2284
2285         return offset;
2286 }
2287
2288 static int
2289 winreg_dissect_element_EnumValue_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2290 {
2291         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_EnumValue_size_, NDR_POINTER_UNIQUE, "Pointer to Size (uint32)",hf_winreg_winreg_EnumValue_size);
2292
2293         return offset;
2294 }
2295
2296 static int
2297 winreg_dissect_element_EnumValue_size_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2298 {
2299         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_EnumValue_size, 0);
2300
2301         return offset;
2302 }
2303
2304 static int
2305 winreg_dissect_element_EnumValue_length(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2306 {
2307         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_EnumValue_length_, NDR_POINTER_UNIQUE, "Pointer to Length (uint32)",hf_winreg_winreg_EnumValue_length);
2308
2309         return offset;
2310 }
2311
2312 static int
2313 winreg_dissect_element_EnumValue_length_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2314 {
2315         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_EnumValue_length, 0);
2316
2317         return offset;
2318 }
2319
2320 /* IDL: WERROR winreg_EnumValue( */
2321 /* IDL: [in] [ref] policy_handle *handle, */
2322 /* IDL: [in] uint32 enum_index, */
2323 /* IDL: [out] [in] [ref] winreg_ValNameBuf *name, */
2324 /* IDL: [out] [unique(1)] [in] winreg_Type *type, */
2325 /* IDL: [unique(1)] [out] [in] [range(0,0x4000000)] [length_is(length?*length:0)] [size_is(size?*size:0)] uint8 *value, */
2326 /* IDL: [out] [unique(1)] [in] uint32 *size, */
2327 /* IDL: [out] [unique(1)] [in] uint32 *length */
2328 /* IDL: ); */
2329
2330 static int
2331 winreg_dissect_EnumValue_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2332 {
2333         guint32 status;
2334
2335         di->dcerpc_procedure_name="EnumValue";
2336         offset = winreg_dissect_element_EnumValue_name(tvb, offset, pinfo, tree, di, drep);
2337         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2338
2339         offset = winreg_dissect_element_EnumValue_type(tvb, offset, pinfo, tree, di, drep);
2340         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2341
2342         offset = winreg_dissect_element_EnumValue_value(tvb, offset, pinfo, tree, di, drep);
2343         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2344
2345         offset = winreg_dissect_element_EnumValue_size(tvb, offset, pinfo, tree, di, drep);
2346         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2347
2348         offset = winreg_dissect_element_EnumValue_length(tvb, offset, pinfo, tree, di, drep);
2349         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2350
2351         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
2352
2353         if (status != 0)
2354                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
2355
2356         return offset;
2357 }
2358
2359 static int
2360 winreg_dissect_EnumValue_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2361 {
2362         di->dcerpc_procedure_name="EnumValue";
2363         offset = winreg_dissect_element_EnumValue_handle(tvb, offset, pinfo, tree, di, drep);
2364         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2365         offset = winreg_dissect_element_EnumValue_enum_index(tvb, offset, pinfo, tree, di, drep);
2366         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2367         offset = winreg_dissect_element_EnumValue_name(tvb, offset, pinfo, tree, di, drep);
2368         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2369         offset = winreg_dissect_element_EnumValue_type(tvb, offset, pinfo, tree, di, drep);
2370         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2371         offset = winreg_dissect_element_EnumValue_value(tvb, offset, pinfo, tree, di, drep);
2372         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2373         offset = winreg_dissect_element_EnumValue_size(tvb, offset, pinfo, tree, di, drep);
2374         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2375         offset = winreg_dissect_element_EnumValue_length(tvb, offset, pinfo, tree, di, drep);
2376         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2377         return offset;
2378 }
2379
2380 static int
2381 winreg_dissect_element_FlushKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2382 {
2383         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_FlushKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
2384
2385         return offset;
2386 }
2387
2388 static int
2389 winreg_dissect_element_FlushKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2390 {
2391         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
2392
2393         return offset;
2394 }
2395
2396 /* IDL: WERROR winreg_FlushKey( */
2397 /* IDL: [in] [ref] policy_handle *handle */
2398 /* IDL: ); */
2399
2400 static int
2401 winreg_dissect_FlushKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2402 {
2403         guint32 status;
2404
2405         di->dcerpc_procedure_name="FlushKey";
2406         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
2407
2408         if (status != 0)
2409                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
2410
2411         return offset;
2412 }
2413
2414 static int
2415 winreg_dissect_FlushKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2416 {
2417         di->dcerpc_procedure_name="FlushKey";
2418         offset = winreg_dissect_element_FlushKey_handle(tvb, offset, pinfo, tree, di, drep);
2419         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2420         return offset;
2421 }
2422
2423 static int
2424 winreg_dissect_element_GetKeySecurity_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2425 {
2426         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_GetKeySecurity_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
2427
2428         return offset;
2429 }
2430
2431 static int
2432 winreg_dissect_element_GetKeySecurity_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2433 {
2434         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
2435
2436         return offset;
2437 }
2438
2439 static int
2440 winreg_dissect_element_GetKeySecurity_sec_info(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2441 {
2442                 offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_GetKeySecurity_sec_info, NULL);
2443
2444         return offset;
2445 }
2446
2447 static int
2448 winreg_dissect_element_GetKeySecurity_sd(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2449 {
2450         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_GetKeySecurity_sd_, NDR_POINTER_REF, "Pointer to Sd (KeySecurityData)",hf_winreg_sd);
2451
2452         return offset;
2453 }
2454
2455 static int
2456 winreg_dissect_element_GetKeySecurity_sd_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2457 {
2458         offset = winreg_dissect_struct_KeySecurityData(tvb,offset,pinfo,tree,di,drep,hf_winreg_sd,0);
2459
2460         return offset;
2461 }
2462
2463 /* IDL: WERROR winreg_GetKeySecurity( */
2464 /* IDL: [in] [ref] policy_handle *handle, */
2465 /* IDL: [in] security_secinfo sec_info, */
2466 /* IDL: [out] [in] [ref] KeySecurityData *sd */
2467 /* IDL: ); */
2468
2469 static int
2470 winreg_dissect_GetKeySecurity_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2471 {
2472         guint32 status;
2473
2474         di->dcerpc_procedure_name="GetKeySecurity";
2475         offset = winreg_dissect_element_GetKeySecurity_sd(tvb, offset, pinfo, tree, di, drep);
2476         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2477
2478         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
2479
2480         if (status != 0)
2481                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
2482
2483         return offset;
2484 }
2485
2486 static int
2487 winreg_dissect_GetKeySecurity_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2488 {
2489         di->dcerpc_procedure_name="GetKeySecurity";
2490         offset = winreg_dissect_element_GetKeySecurity_handle(tvb, offset, pinfo, tree, di, drep);
2491         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2492         offset = winreg_dissect_element_GetKeySecurity_sec_info(tvb, offset, pinfo, tree, di, drep);
2493         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2494         offset = winreg_dissect_element_GetKeySecurity_sd(tvb, offset, pinfo, tree, di, drep);
2495         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2496         return offset;
2497 }
2498
2499 static int
2500 winreg_dissect_element_LoadKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2501 {
2502         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_LoadKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
2503
2504         return offset;
2505 }
2506
2507 static int
2508 winreg_dissect_element_LoadKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2509 {
2510         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
2511
2512         return offset;
2513 }
2514
2515 static int
2516 winreg_dissect_element_LoadKey_keyname(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2517 {
2518         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_LoadKey_keyname_, NDR_POINTER_UNIQUE, "Pointer to Keyname (winreg_String)",hf_winreg_winreg_LoadKey_keyname);
2519
2520         return offset;
2521 }
2522
2523 static int
2524 winreg_dissect_element_LoadKey_keyname_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2525 {
2526         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_LoadKey_keyname);
2527
2528         return offset;
2529 }
2530
2531 static int
2532 winreg_dissect_element_LoadKey_filename(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2533 {
2534         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_LoadKey_filename_, NDR_POINTER_UNIQUE, "Pointer to Filename (winreg_String)",hf_winreg_winreg_LoadKey_filename);
2535
2536         return offset;
2537 }
2538
2539 static int
2540 winreg_dissect_element_LoadKey_filename_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2541 {
2542         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_LoadKey_filename);
2543
2544         return offset;
2545 }
2546
2547 /* IDL: WERROR winreg_LoadKey( */
2548 /* IDL: [in] [ref] policy_handle *handle, */
2549 /* IDL: [unique(1)] [in] winreg_String *keyname, */
2550 /* IDL: [unique(1)] [in] winreg_String *filename */
2551 /* IDL: ); */
2552
2553 static int
2554 winreg_dissect_LoadKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2555 {
2556         guint32 status;
2557
2558         di->dcerpc_procedure_name="LoadKey";
2559         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
2560
2561         if (status != 0)
2562                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
2563
2564         return offset;
2565 }
2566
2567 static int
2568 winreg_dissect_LoadKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2569 {
2570         di->dcerpc_procedure_name="LoadKey";
2571         offset = winreg_dissect_element_LoadKey_handle(tvb, offset, pinfo, tree, di, drep);
2572         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2573         offset = winreg_dissect_element_LoadKey_keyname(tvb, offset, pinfo, tree, di, drep);
2574         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2575         offset = winreg_dissect_element_LoadKey_filename(tvb, offset, pinfo, tree, di, drep);
2576         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2577         return offset;
2578 }
2579
2580 static int
2581 winreg_dissect_element_NotifyChangeKeyValue_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2582 {
2583         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_NotifyChangeKeyValue_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
2584
2585         return offset;
2586 }
2587
2588 static int
2589 winreg_dissect_element_NotifyChangeKeyValue_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2590 {
2591         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
2592
2593         return offset;
2594 }
2595
2596 static int
2597 winreg_dissect_element_NotifyChangeKeyValue_watch_subtree(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2598 {
2599         offset = PIDL_dissect_uint8(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_NotifyChangeKeyValue_watch_subtree, 0);
2600
2601         return offset;
2602 }
2603
2604 static int
2605 winreg_dissect_element_NotifyChangeKeyValue_notify_filter(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2606 {
2607         offset = winreg_dissect_bitmap_NotifyChangeType(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_NotifyChangeKeyValue_notify_filter, 0);
2608
2609         return offset;
2610 }
2611
2612 static int
2613 winreg_dissect_element_NotifyChangeKeyValue_unknown(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2614 {
2615         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_NotifyChangeKeyValue_unknown, 0);
2616
2617         return offset;
2618 }
2619
2620 static int
2621 winreg_dissect_element_NotifyChangeKeyValue_string1(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2622 {
2623         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_NotifyChangeKeyValue_string1);
2624
2625         return offset;
2626 }
2627
2628 static int
2629 winreg_dissect_element_NotifyChangeKeyValue_string2(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2630 {
2631         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_NotifyChangeKeyValue_string2);
2632
2633         return offset;
2634 }
2635
2636 static int
2637 winreg_dissect_element_NotifyChangeKeyValue_unknown2(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2638 {
2639         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_NotifyChangeKeyValue_unknown2, 0);
2640
2641         return offset;
2642 }
2643
2644 /* IDL: WERROR winreg_NotifyChangeKeyValue( */
2645 /* IDL: [in] [ref] policy_handle *handle, */
2646 /* IDL: [in] uint8 watch_subtree, */
2647 /* IDL: [in] winreg_NotifyChangeType notify_filter, */
2648 /* IDL: [in] uint32 unknown, */
2649 /* IDL: [in] winreg_String string1, */
2650 /* IDL: [in] winreg_String string2, */
2651 /* IDL: [in] uint32 unknown2 */
2652 /* IDL: ); */
2653
2654 static int
2655 winreg_dissect_NotifyChangeKeyValue_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2656 {
2657         guint32 status;
2658
2659         di->dcerpc_procedure_name="NotifyChangeKeyValue";
2660         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
2661
2662         if (status != 0)
2663                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
2664
2665         return offset;
2666 }
2667
2668 static int
2669 winreg_dissect_NotifyChangeKeyValue_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2670 {
2671         di->dcerpc_procedure_name="NotifyChangeKeyValue";
2672         offset = winreg_dissect_element_NotifyChangeKeyValue_handle(tvb, offset, pinfo, tree, di, drep);
2673         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2674         offset = winreg_dissect_element_NotifyChangeKeyValue_watch_subtree(tvb, offset, pinfo, tree, di, drep);
2675         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2676         offset = winreg_dissect_element_NotifyChangeKeyValue_notify_filter(tvb, offset, pinfo, tree, di, drep);
2677         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2678         offset = winreg_dissect_element_NotifyChangeKeyValue_unknown(tvb, offset, pinfo, tree, di, drep);
2679         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2680         offset = winreg_dissect_element_NotifyChangeKeyValue_string1(tvb, offset, pinfo, tree, di, drep);
2681         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2682         offset = winreg_dissect_element_NotifyChangeKeyValue_string2(tvb, offset, pinfo, tree, di, drep);
2683         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2684         offset = winreg_dissect_element_NotifyChangeKeyValue_unknown2(tvb, offset, pinfo, tree, di, drep);
2685         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2686         return offset;
2687 }
2688
2689 static int
2690 winreg_dissect_element_OpenKey_parent_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2691 {
2692         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenKey_parent_handle_, NDR_POINTER_REF, "Pointer to Parent Handle (policy_handle)",hf_winreg_winreg_OpenKey_parent_handle);
2693
2694         return offset;
2695 }
2696
2697 static int
2698 winreg_dissect_element_OpenKey_parent_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2699 {
2700         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_OpenKey_parent_handle, 0);
2701
2702         return offset;
2703 }
2704
2705 static int
2706 winreg_dissect_element_OpenKey_keyname(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2707 {
2708         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 2|PIDL_SET_COL_INFO|PIDL_STR_SAVE, hf_winreg_winreg_OpenKey_keyname);
2709
2710         return offset;
2711 }
2712
2713 static int
2714 winreg_dissect_element_OpenKey_options(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2715 {
2716         offset = winreg_dissect_bitmap_KeyOptions(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_OpenKey_options, 0);
2717
2718         return offset;
2719 }
2720
2721 static int
2722 winreg_dissect_element_OpenKey_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2723 {
2724         offset = winreg_dissect_bitmap_AccessMask(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_OpenKey_access_mask, 0);
2725
2726         return offset;
2727 }
2728
2729 static int
2730 winreg_dissect_element_OpenKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2731 {
2732         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
2733
2734         return offset;
2735 }
2736
2737 static int
2738 winreg_dissect_element_OpenKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2739 {
2740         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, PIDL_POLHND_OPEN);
2741
2742         return offset;
2743 }
2744
2745 /* IDL: WERROR winreg_OpenKey( */
2746 /* IDL: [in] [ref] policy_handle *parent_handle, */
2747 /* IDL: [in] winreg_String keyname, */
2748 /* IDL: [in] winreg_KeyOptions options, */
2749 /* IDL: [in] winreg_AccessMask access_mask, */
2750 /* IDL: [out] [ref] policy_handle *handle */
2751 /* IDL: ); */
2752
2753 static int
2754 winreg_dissect_OpenKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2755 {
2756         guint32 status;
2757
2758         di->dcerpc_procedure_name="OpenKey";
2759         offset = winreg_dissect_element_OpenKey_handle(tvb, offset, pinfo, tree, di, drep);
2760         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2761
2762         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
2763
2764         if (status != 0)
2765                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
2766
2767         return offset;
2768 }
2769
2770 static int
2771 winreg_dissect_OpenKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2772 {
2773         di->dcerpc_procedure_name="OpenKey";
2774         offset = winreg_dissect_element_OpenKey_parent_handle(tvb, offset, pinfo, tree, di, drep);
2775         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2776         offset = winreg_dissect_element_OpenKey_keyname(tvb, offset, pinfo, tree, di, drep);
2777         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2778         offset = winreg_dissect_element_OpenKey_options(tvb, offset, pinfo, tree, di, drep);
2779         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2780         offset = winreg_dissect_element_OpenKey_access_mask(tvb, offset, pinfo, tree, di, drep);
2781         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2782         return offset;
2783 }
2784
2785 static int
2786 winreg_dissect_element_QueryInfoKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2787 {
2788         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryInfoKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
2789
2790         return offset;
2791 }
2792
2793 static int
2794 winreg_dissect_element_QueryInfoKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2795 {
2796         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
2797
2798         return offset;
2799 }
2800
2801 static int
2802 winreg_dissect_element_QueryInfoKey_classname(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2803 {
2804         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryInfoKey_classname_, NDR_POINTER_REF, "Pointer to Classname (winreg_String)",hf_winreg_winreg_QueryInfoKey_classname);
2805
2806         return offset;
2807 }
2808
2809 static int
2810 winreg_dissect_element_QueryInfoKey_classname_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2811 {
2812         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_QueryInfoKey_classname);
2813
2814         return offset;
2815 }
2816
2817 static int
2818 winreg_dissect_element_QueryInfoKey_num_subkeys(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2819 {
2820         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryInfoKey_num_subkeys_, NDR_POINTER_REF, "Pointer to Num Subkeys (uint32)",hf_winreg_winreg_QueryInfoKey_num_subkeys);
2821
2822         return offset;
2823 }
2824
2825 static int
2826 winreg_dissect_element_QueryInfoKey_num_subkeys_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2827 {
2828         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryInfoKey_num_subkeys, 0);
2829
2830         return offset;
2831 }
2832
2833 static int
2834 winreg_dissect_element_QueryInfoKey_max_subkeylen(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2835 {
2836         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryInfoKey_max_subkeylen_, NDR_POINTER_REF, "Pointer to Max Subkeylen (uint32)",hf_winreg_winreg_QueryInfoKey_max_subkeylen);
2837
2838         return offset;
2839 }
2840
2841 static int
2842 winreg_dissect_element_QueryInfoKey_max_subkeylen_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2843 {
2844         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryInfoKey_max_subkeylen, 0);
2845
2846         return offset;
2847 }
2848
2849 static int
2850 winreg_dissect_element_QueryInfoKey_max_classlen(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2851 {
2852         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryInfoKey_max_classlen_, NDR_POINTER_REF, "Pointer to Max Classlen (uint32)",hf_winreg_winreg_QueryInfoKey_max_classlen);
2853
2854         return offset;
2855 }
2856
2857 static int
2858 winreg_dissect_element_QueryInfoKey_max_classlen_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2859 {
2860         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryInfoKey_max_classlen, 0);
2861
2862         return offset;
2863 }
2864
2865 static int
2866 winreg_dissect_element_QueryInfoKey_num_values(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2867 {
2868         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryInfoKey_num_values_, NDR_POINTER_REF, "Pointer to Num Values (uint32)",hf_winreg_winreg_QueryInfoKey_num_values);
2869
2870         return offset;
2871 }
2872
2873 static int
2874 winreg_dissect_element_QueryInfoKey_num_values_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2875 {
2876         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryInfoKey_num_values, 0);
2877
2878         return offset;
2879 }
2880
2881 static int
2882 winreg_dissect_element_QueryInfoKey_max_valnamelen(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2883 {
2884         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryInfoKey_max_valnamelen_, NDR_POINTER_REF, "Pointer to Max Valnamelen (uint32)",hf_winreg_winreg_QueryInfoKey_max_valnamelen);
2885
2886         return offset;
2887 }
2888
2889 static int
2890 winreg_dissect_element_QueryInfoKey_max_valnamelen_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2891 {
2892         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryInfoKey_max_valnamelen, 0);
2893
2894         return offset;
2895 }
2896
2897 static int
2898 winreg_dissect_element_QueryInfoKey_max_valbufsize(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2899 {
2900         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryInfoKey_max_valbufsize_, NDR_POINTER_REF, "Pointer to Max Valbufsize (uint32)",hf_winreg_winreg_QueryInfoKey_max_valbufsize);
2901
2902         return offset;
2903 }
2904
2905 static int
2906 winreg_dissect_element_QueryInfoKey_max_valbufsize_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2907 {
2908         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryInfoKey_max_valbufsize, 0);
2909
2910         return offset;
2911 }
2912
2913 static int
2914 winreg_dissect_element_QueryInfoKey_secdescsize(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2915 {
2916         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryInfoKey_secdescsize_, NDR_POINTER_REF, "Pointer to Secdescsize (uint32)",hf_winreg_winreg_QueryInfoKey_secdescsize);
2917
2918         return offset;
2919 }
2920
2921 static int
2922 winreg_dissect_element_QueryInfoKey_secdescsize_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2923 {
2924         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryInfoKey_secdescsize, 0);
2925
2926         return offset;
2927 }
2928
2929 static int
2930 winreg_dissect_element_QueryInfoKey_last_changed_time(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2931 {
2932         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryInfoKey_last_changed_time_, NDR_POINTER_REF, "Pointer to Last Changed Time (NTTIME)",hf_winreg_winreg_QueryInfoKey_last_changed_time);
2933
2934         return offset;
2935 }
2936
2937 static int
2938 winreg_dissect_element_QueryInfoKey_last_changed_time_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2939 {
2940         offset = dissect_ndr_nt_NTTIME(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryInfoKey_last_changed_time);
2941
2942         return offset;
2943 }
2944
2945 /* IDL: WERROR winreg_QueryInfoKey( */
2946 /* IDL: [in] [ref] policy_handle *handle, */
2947 /* IDL: [out] [in] [ref] winreg_String *classname, */
2948 /* IDL: [out] [ref] uint32 *num_subkeys, */
2949 /* IDL: [out] [ref] uint32 *max_subkeylen, */
2950 /* IDL: [out] [ref] uint32 *max_classlen, */
2951 /* IDL: [out] [ref] uint32 *num_values, */
2952 /* IDL: [out] [ref] uint32 *max_valnamelen, */
2953 /* IDL: [out] [ref] uint32 *max_valbufsize, */
2954 /* IDL: [out] [ref] uint32 *secdescsize, */
2955 /* IDL: [out] [ref] NTTIME *last_changed_time */
2956 /* IDL: ); */
2957
2958 static int
2959 winreg_dissect_QueryInfoKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
2960 {
2961         guint32 status;
2962
2963         di->dcerpc_procedure_name="QueryInfoKey";
2964         offset = winreg_dissect_element_QueryInfoKey_classname(tvb, offset, pinfo, tree, di, drep);
2965         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2966
2967         offset = winreg_dissect_element_QueryInfoKey_num_subkeys(tvb, offset, pinfo, tree, di, drep);
2968         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2969
2970         offset = winreg_dissect_element_QueryInfoKey_max_subkeylen(tvb, offset, pinfo, tree, di, drep);
2971         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2972
2973         offset = winreg_dissect_element_QueryInfoKey_max_classlen(tvb, offset, pinfo, tree, di, drep);
2974         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2975
2976         offset = winreg_dissect_element_QueryInfoKey_num_values(tvb, offset, pinfo, tree, di, drep);
2977         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2978
2979         offset = winreg_dissect_element_QueryInfoKey_max_valnamelen(tvb, offset, pinfo, tree, di, drep);
2980         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2981
2982         offset = winreg_dissect_element_QueryInfoKey_max_valbufsize(tvb, offset, pinfo, tree, di, drep);
2983         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2984
2985         offset = winreg_dissect_element_QueryInfoKey_secdescsize(tvb, offset, pinfo, tree, di, drep);
2986         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2987
2988         offset = winreg_dissect_element_QueryInfoKey_last_changed_time(tvb, offset, pinfo, tree, di, drep);
2989         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
2990
2991         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
2992
2993         if (status != 0)
2994                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
2995
2996         return offset;
2997 }
2998
2999 static int
3000 winreg_dissect_QueryInfoKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3001 {
3002         di->dcerpc_procedure_name="QueryInfoKey";
3003         offset = winreg_dissect_element_QueryInfoKey_handle(tvb, offset, pinfo, tree, di, drep);
3004         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3005         offset = winreg_dissect_element_QueryInfoKey_classname(tvb, offset, pinfo, tree, di, drep);
3006         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3007         return offset;
3008 }
3009
3010 static int
3011 winreg_dissect_element_QueryValue_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3012 {
3013         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryValue_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
3014
3015         return offset;
3016 }
3017
3018 static int
3019 winreg_dissect_element_QueryValue_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3020 {
3021         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
3022
3023         return offset;
3024 }
3025
3026 static int
3027 winreg_dissect_element_QueryValue_value_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3028 {
3029         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryValue_value_name_, NDR_POINTER_REF, "Pointer to Value Name (winreg_String)",hf_winreg_winreg_QueryValue_value_name);
3030
3031         return offset;
3032 }
3033
3034 static int
3035 winreg_dissect_element_QueryValue_value_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3036 {
3037         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_QueryValue_value_name);
3038
3039         return offset;
3040 }
3041
3042 static int
3043 winreg_dissect_element_QueryValue_type(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3044 {
3045         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryValue_type_, NDR_POINTER_UNIQUE, "Pointer to Type (winreg_Type)",hf_winreg_winreg_QueryValue_type);
3046
3047         return offset;
3048 }
3049
3050 static int
3051 winreg_dissect_element_QueryValue_type_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3052 {
3053         offset=misc_dissect_enum_winreg_Type(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryValue_type, 0);
3054
3055         return offset;
3056 }
3057
3058 static int
3059 winreg_dissect_element_QueryValue_data(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3060 {
3061         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryValue_data_, NDR_POINTER_UNIQUE, "Pointer to Data (uint8)",hf_winreg_winreg_QueryValue_data);
3062
3063         return offset;
3064 }
3065
3066 static int
3067 winreg_dissect_element_QueryValue_data_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3068 {
3069         offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryValue_data__);
3070
3071         return offset;
3072 }
3073
3074 static int
3075 winreg_dissect_element_QueryValue_data__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3076 {
3077         offset = PIDL_dissect_uint8(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryValue_data, 0);
3078
3079         return offset;
3080 }
3081
3082 static int
3083 winreg_dissect_element_QueryValue_data_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3084 {
3085         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryValue_data_size_, NDR_POINTER_UNIQUE, "Pointer to Data Size (uint32)",hf_winreg_winreg_QueryValue_data_size);
3086
3087         return offset;
3088 }
3089
3090 static int
3091 winreg_dissect_element_QueryValue_data_size_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3092 {
3093         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryValue_data_size, 0);
3094
3095         return offset;
3096 }
3097
3098 static int
3099 winreg_dissect_element_QueryValue_data_length(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3100 {
3101         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryValue_data_length_, NDR_POINTER_UNIQUE, "Pointer to Data Length (uint32)",hf_winreg_winreg_QueryValue_data_length);
3102
3103         return offset;
3104 }
3105
3106 static int
3107 winreg_dissect_element_QueryValue_data_length_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3108 {
3109         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryValue_data_length, 0);
3110
3111         return offset;
3112 }
3113
3114 /* IDL: WERROR winreg_QueryValue( */
3115 /* IDL: [in] [ref] policy_handle *handle, */
3116 /* IDL: [in] [ref] winreg_String *value_name, */
3117 /* IDL: [out] [unique(1)] [in] winreg_Type *type, */
3118 /* IDL: [unique(1)] [out] [in] [range(0,0x4000000)] [length_is(data_length?*data_length:0)] [size_is(data_size?*data_size:0)] uint8 *data, */
3119 /* IDL: [out] [unique(1)] [in] uint32 *data_size, */
3120 /* IDL: [out] [unique(1)] [in] uint32 *data_length */
3121 /* IDL: ); */
3122
3123 static int
3124 winreg_dissect_QueryValue_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3125 {
3126         guint32 status;
3127
3128         di->dcerpc_procedure_name="QueryValue";
3129         offset = winreg_dissect_element_QueryValue_type(tvb, offset, pinfo, tree, di, drep);
3130         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3131
3132         offset = winreg_dissect_element_QueryValue_data(tvb, offset, pinfo, tree, di, drep);
3133         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3134
3135         offset = winreg_dissect_element_QueryValue_data_size(tvb, offset, pinfo, tree, di, drep);
3136         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3137
3138         offset = winreg_dissect_element_QueryValue_data_length(tvb, offset, pinfo, tree, di, drep);
3139         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3140
3141         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
3142
3143         if (status != 0)
3144                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
3145
3146         return offset;
3147 }
3148
3149 static int
3150 winreg_dissect_QueryValue_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3151 {
3152         di->dcerpc_procedure_name="QueryValue";
3153         offset = winreg_dissect_element_QueryValue_handle(tvb, offset, pinfo, tree, di, drep);
3154         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3155         offset = winreg_dissect_element_QueryValue_value_name(tvb, offset, pinfo, tree, di, drep);
3156         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3157         offset = winreg_dissect_element_QueryValue_type(tvb, offset, pinfo, tree, di, drep);
3158         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3159         offset = winreg_dissect_element_QueryValue_data(tvb, offset, pinfo, tree, di, drep);
3160         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3161         offset = winreg_dissect_element_QueryValue_data_size(tvb, offset, pinfo, tree, di, drep);
3162         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3163         offset = winreg_dissect_element_QueryValue_data_length(tvb, offset, pinfo, tree, di, drep);
3164         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3165         return offset;
3166 }
3167
3168 static int
3169 winreg_dissect_element_ReplaceKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3170 {
3171         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_ReplaceKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_ReplaceKey_handle);
3172
3173         return offset;
3174 }
3175
3176 static int
3177 winreg_dissect_element_ReplaceKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3178 {
3179         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_ReplaceKey_handle, 0);
3180
3181         return offset;
3182 }
3183
3184 static int
3185 winreg_dissect_element_ReplaceKey_subkey(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3186 {
3187         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_ReplaceKey_subkey_, NDR_POINTER_REF, "Pointer to Subkey (winreg_String)",hf_winreg_winreg_ReplaceKey_subkey);
3188
3189         return offset;
3190 }
3191
3192 static int
3193 winreg_dissect_element_ReplaceKey_subkey_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3194 {
3195         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_ReplaceKey_subkey);
3196
3197         return offset;
3198 }
3199
3200 static int
3201 winreg_dissect_element_ReplaceKey_new_file(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3202 {
3203         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_ReplaceKey_new_file_, NDR_POINTER_REF, "Pointer to New File (winreg_String)",hf_winreg_winreg_ReplaceKey_new_file);
3204
3205         return offset;
3206 }
3207
3208 static int
3209 winreg_dissect_element_ReplaceKey_new_file_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3210 {
3211         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_ReplaceKey_new_file);
3212
3213         return offset;
3214 }
3215
3216 static int
3217 winreg_dissect_element_ReplaceKey_old_file(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3218 {
3219         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_ReplaceKey_old_file_, NDR_POINTER_REF, "Pointer to Old File (winreg_String)",hf_winreg_winreg_ReplaceKey_old_file);
3220
3221         return offset;
3222 }
3223
3224 static int
3225 winreg_dissect_element_ReplaceKey_old_file_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3226 {
3227         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_ReplaceKey_old_file);
3228
3229         return offset;
3230 }
3231
3232 /* IDL: WERROR winreg_ReplaceKey( */
3233 /* IDL: [in] [ref] policy_handle *handle, */
3234 /* IDL: [in] [ref] winreg_String *subkey, */
3235 /* IDL: [in] [ref] winreg_String *new_file, */
3236 /* IDL: [in] [ref] winreg_String *old_file */
3237 /* IDL: ); */
3238
3239 static int
3240 winreg_dissect_ReplaceKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3241 {
3242         guint32 status;
3243
3244         di->dcerpc_procedure_name="ReplaceKey";
3245         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
3246
3247         if (status != 0)
3248                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
3249
3250         return offset;
3251 }
3252
3253 static int
3254 winreg_dissect_ReplaceKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3255 {
3256         di->dcerpc_procedure_name="ReplaceKey";
3257         offset = winreg_dissect_element_ReplaceKey_handle(tvb, offset, pinfo, tree, di, drep);
3258         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3259         offset = winreg_dissect_element_ReplaceKey_subkey(tvb, offset, pinfo, tree, di, drep);
3260         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3261         offset = winreg_dissect_element_ReplaceKey_new_file(tvb, offset, pinfo, tree, di, drep);
3262         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3263         offset = winreg_dissect_element_ReplaceKey_old_file(tvb, offset, pinfo, tree, di, drep);
3264         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3265         return offset;
3266 }
3267
3268 static int
3269 winreg_dissect_element_RestoreKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3270 {
3271         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_RestoreKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_RestoreKey_handle);
3272
3273         return offset;
3274 }
3275
3276 static int
3277 winreg_dissect_element_RestoreKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3278 {
3279         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_RestoreKey_handle, 0);
3280
3281         return offset;
3282 }
3283
3284 static int
3285 winreg_dissect_element_RestoreKey_filename(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3286 {
3287         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_RestoreKey_filename_, NDR_POINTER_REF, "Pointer to Filename (winreg_String)",hf_winreg_winreg_RestoreKey_filename);
3288
3289         return offset;
3290 }
3291
3292 static int
3293 winreg_dissect_element_RestoreKey_filename_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3294 {
3295         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_RestoreKey_filename);
3296
3297         return offset;
3298 }
3299
3300 static int
3301 winreg_dissect_element_RestoreKey_flags(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3302 {
3303         offset = winreg_dissect_bitmap_RestoreKeyFlags(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_RestoreKey_flags, 0);
3304
3305         return offset;
3306 }
3307
3308 /* IDL: WERROR winreg_RestoreKey( */
3309 /* IDL: [in] [ref] policy_handle *handle, */
3310 /* IDL: [in] [ref] winreg_String *filename, */
3311 /* IDL: [in] winreg_RestoreKeyFlags flags */
3312 /* IDL: ); */
3313
3314 static int
3315 winreg_dissect_RestoreKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3316 {
3317         guint32 status;
3318
3319         di->dcerpc_procedure_name="RestoreKey";
3320         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
3321
3322         if (status != 0)
3323                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
3324
3325         return offset;
3326 }
3327
3328 static int
3329 winreg_dissect_RestoreKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3330 {
3331         di->dcerpc_procedure_name="RestoreKey";
3332         offset = winreg_dissect_element_RestoreKey_handle(tvb, offset, pinfo, tree, di, drep);
3333         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3334         offset = winreg_dissect_element_RestoreKey_filename(tvb, offset, pinfo, tree, di, drep);
3335         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3336         offset = winreg_dissect_element_RestoreKey_flags(tvb, offset, pinfo, tree, di, drep);
3337         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3338         return offset;
3339 }
3340
3341 static int
3342 winreg_dissect_element_SaveKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3343 {
3344         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_SaveKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_SaveKey_handle);
3345
3346         return offset;
3347 }
3348
3349 static int
3350 winreg_dissect_element_SaveKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3351 {
3352         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_SaveKey_handle, 0);
3353
3354         return offset;
3355 }
3356
3357 static int
3358 winreg_dissect_element_SaveKey_filename(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3359 {
3360         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_SaveKey_filename_, NDR_POINTER_REF, "Pointer to Filename (winreg_String)",hf_winreg_winreg_SaveKey_filename);
3361
3362         return offset;
3363 }
3364
3365 static int
3366 winreg_dissect_element_SaveKey_filename_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3367 {
3368         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_SaveKey_filename);
3369
3370         return offset;
3371 }
3372
3373 static int
3374 winreg_dissect_element_SaveKey_sec_attrib(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3375 {
3376         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_SaveKey_sec_attrib_, NDR_POINTER_UNIQUE, "Pointer to Sec Attrib (KeySecurityAttribute)",hf_winreg_winreg_SaveKey_sec_attrib);
3377
3378         return offset;
3379 }
3380
3381 static int
3382 winreg_dissect_element_SaveKey_sec_attrib_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3383 {
3384         offset = winreg_dissect_struct_KeySecurityAttribute(tvb,offset,pinfo,tree,di,drep,hf_winreg_winreg_SaveKey_sec_attrib,0);
3385
3386         return offset;
3387 }
3388
3389 /* IDL: WERROR winreg_SaveKey( */
3390 /* IDL: [in] [ref] policy_handle *handle, */
3391 /* IDL: [in] [ref] winreg_String *filename, */
3392 /* IDL: [unique(1)] [in] KeySecurityAttribute *sec_attrib */
3393 /* IDL: ); */
3394
3395 static int
3396 winreg_dissect_SaveKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3397 {
3398         guint32 status;
3399
3400         di->dcerpc_procedure_name="SaveKey";
3401         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
3402
3403         if (status != 0)
3404                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
3405
3406         return offset;
3407 }
3408
3409 static int
3410 winreg_dissect_SaveKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3411 {
3412         di->dcerpc_procedure_name="SaveKey";
3413         offset = winreg_dissect_element_SaveKey_handle(tvb, offset, pinfo, tree, di, drep);
3414         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3415         offset = winreg_dissect_element_SaveKey_filename(tvb, offset, pinfo, tree, di, drep);
3416         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3417         offset = winreg_dissect_element_SaveKey_sec_attrib(tvb, offset, pinfo, tree, di, drep);
3418         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3419         return offset;
3420 }
3421
3422 static int
3423 winreg_dissect_element_SetKeySecurity_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3424 {
3425         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_SetKeySecurity_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
3426
3427         return offset;
3428 }
3429
3430 static int
3431 winreg_dissect_element_SetKeySecurity_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3432 {
3433         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
3434
3435         return offset;
3436 }
3437
3438 static int
3439 winreg_dissect_element_SetKeySecurity_sec_info(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3440 {
3441                 offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_GetKeySecurity_sec_info, NULL);
3442
3443         return offset;
3444 }
3445
3446 static int
3447 winreg_dissect_element_SetKeySecurity_sd(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3448 {
3449         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_SetKeySecurity_sd_, NDR_POINTER_REF, "Pointer to Sd (KeySecurityData)",hf_winreg_sd);
3450
3451         return offset;
3452 }
3453
3454 static int
3455 winreg_dissect_element_SetKeySecurity_sd_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3456 {
3457         offset = winreg_dissect_struct_KeySecurityData(tvb,offset,pinfo,tree,di,drep,hf_winreg_sd,0);
3458
3459         return offset;
3460 }
3461
3462 /* IDL: WERROR winreg_SetKeySecurity( */
3463 /* IDL: [in] [ref] policy_handle *handle, */
3464 /* IDL: [in] security_secinfo sec_info, */
3465 /* IDL: [in] [ref] KeySecurityData *sd */
3466 /* IDL: ); */
3467
3468 static int
3469 winreg_dissect_SetKeySecurity_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3470 {
3471         guint32 status;
3472
3473         di->dcerpc_procedure_name="SetKeySecurity";
3474         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
3475
3476         if (status != 0)
3477                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
3478
3479         return offset;
3480 }
3481
3482 static int
3483 winreg_dissect_SetKeySecurity_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3484 {
3485         di->dcerpc_procedure_name="SetKeySecurity";
3486         offset = winreg_dissect_element_SetKeySecurity_handle(tvb, offset, pinfo, tree, di, drep);
3487         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3488         offset = winreg_dissect_element_SetKeySecurity_sec_info(tvb, offset, pinfo, tree, di, drep);
3489         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3490         offset = winreg_dissect_element_SetKeySecurity_sd(tvb, offset, pinfo, tree, di, drep);
3491         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3492         return offset;
3493 }
3494
3495 static int
3496 winreg_dissect_element_SetValue_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3497 {
3498         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_SetValue_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
3499
3500         return offset;
3501 }
3502
3503 static int
3504 winreg_dissect_element_SetValue_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3505 {
3506         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
3507
3508         return offset;
3509 }
3510
3511 static int
3512 winreg_dissect_element_SetValue_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3513 {
3514         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 2|PIDL_SET_COL_INFO, hf_winreg_winreg_SetValue_name);
3515
3516         return offset;
3517 }
3518
3519 static int
3520 winreg_dissect_element_SetValue_type(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3521 {
3522         offset=misc_dissect_enum_winreg_Type(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_SetValue_type, 0);
3523
3524         return offset;
3525 }
3526
3527 static int
3528 winreg_dissect_element_SetValue_data(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3529 {
3530         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_SetValue_data_, NDR_POINTER_REF, "Pointer to Data (uint8)",hf_winreg_winreg_SetValue_data);
3531
3532         return offset;
3533 }
3534
3535 static int
3536 winreg_dissect_element_SetValue_data_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3537 {
3538         offset = dissect_ndr_ucarray(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_SetValue_data__);
3539
3540         return offset;
3541 }
3542
3543 static int
3544 winreg_dissect_element_SetValue_data__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3545 {
3546         offset = PIDL_dissect_uint8(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_SetValue_data, 0);
3547
3548         return offset;
3549 }
3550
3551 static int
3552 winreg_dissect_element_SetValue_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3553 {
3554         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_SetValue_size, 0);
3555
3556         return offset;
3557 }
3558
3559 /* IDL: WERROR winreg_SetValue( */
3560 /* IDL: [in] [ref] policy_handle *handle, */
3561 /* IDL: [in] winreg_String name, */
3562 /* IDL: [in] winreg_Type type, */
3563 /* IDL: [in] [ref] [size_is(size)] uint8 *data, */
3564 /* IDL: [in] uint32 size */
3565 /* IDL: ); */
3566
3567 static int
3568 winreg_dissect_SetValue_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3569 {
3570         guint32 status;
3571
3572         di->dcerpc_procedure_name="SetValue";
3573         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
3574
3575         if (status != 0)
3576                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
3577
3578         return offset;
3579 }
3580
3581 static int
3582 winreg_dissect_SetValue_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3583 {
3584         di->dcerpc_procedure_name="SetValue";
3585         offset = winreg_dissect_element_SetValue_handle(tvb, offset, pinfo, tree, di, drep);
3586         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3587         offset = winreg_dissect_element_SetValue_name(tvb, offset, pinfo, tree, di, drep);
3588         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3589         offset = winreg_dissect_element_SetValue_type(tvb, offset, pinfo, tree, di, drep);
3590         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3591         offset = winreg_dissect_element_SetValue_data(tvb, offset, pinfo, tree, di, drep);
3592         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3593         offset = winreg_dissect_element_SetValue_size(tvb, offset, pinfo, tree, di, drep);
3594         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3595         return offset;
3596 }
3597
3598 static int
3599 winreg_dissect_element_UnLoadKey_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3600 {
3601         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_UnLoadKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_UnLoadKey_handle);
3602
3603         return offset;
3604 }
3605
3606 static int
3607 winreg_dissect_element_UnLoadKey_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3608 {
3609         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_UnLoadKey_handle, 0);
3610
3611         return offset;
3612 }
3613
3614 static int
3615 winreg_dissect_element_UnLoadKey_subkey(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3616 {
3617         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_UnLoadKey_subkey_, NDR_POINTER_REF, "Pointer to Subkey (winreg_String)",hf_winreg_winreg_UnLoadKey_subkey);
3618
3619         return offset;
3620 }
3621
3622 static int
3623 winreg_dissect_element_UnLoadKey_subkey_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3624 {
3625         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_UnLoadKey_subkey);
3626
3627         return offset;
3628 }
3629
3630 /* IDL: WERROR winreg_UnLoadKey( */
3631 /* IDL: [in] [ref] policy_handle *handle, */
3632 /* IDL: [in] [ref] winreg_String *subkey */
3633 /* IDL: ); */
3634
3635 static int
3636 winreg_dissect_UnLoadKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3637 {
3638         guint32 status;
3639
3640         di->dcerpc_procedure_name="UnLoadKey";
3641         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
3642
3643         if (status != 0)
3644                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
3645
3646         return offset;
3647 }
3648
3649 static int
3650 winreg_dissect_UnLoadKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3651 {
3652         di->dcerpc_procedure_name="UnLoadKey";
3653         offset = winreg_dissect_element_UnLoadKey_handle(tvb, offset, pinfo, tree, di, drep);
3654         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3655         offset = winreg_dissect_element_UnLoadKey_subkey(tvb, offset, pinfo, tree, di, drep);
3656         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3657         return offset;
3658 }
3659
3660 static int
3661 winreg_dissect_element_InitiateSystemShutdown_hostname(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3662 {
3663         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_InitiateSystemShutdown_hostname_, NDR_POINTER_UNIQUE, "Pointer to Hostname (uint16)",hf_winreg_winreg_InitiateSystemShutdown_hostname);
3664
3665         return offset;
3666 }
3667
3668 static int
3669 winreg_dissect_element_InitiateSystemShutdown_hostname_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3670 {
3671         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_InitiateSystemShutdown_hostname, 0);
3672
3673         return offset;
3674 }
3675
3676 static int
3677 winreg_dissect_element_InitiateSystemShutdown_message(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3678 {
3679         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_InitiateSystemShutdown_message_, NDR_POINTER_UNIQUE, "Pointer to Message (lsa_StringLarge)",hf_winreg_winreg_InitiateSystemShutdown_message);
3680
3681         return offset;
3682 }
3683
3684 static int
3685 winreg_dissect_element_InitiateSystemShutdown_message_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3686 {
3687         offset=lsarpc_dissect_struct_lsa_StringLarge(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_InitiateSystemShutdown_message, 0);
3688
3689         return offset;
3690 }
3691
3692 static int
3693 winreg_dissect_element_InitiateSystemShutdown_timeout(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3694 {
3695         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_InitiateSystemShutdown_timeout, 0);
3696
3697         return offset;
3698 }
3699
3700 static int
3701 winreg_dissect_element_InitiateSystemShutdown_force_apps(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3702 {
3703         offset = PIDL_dissect_uint8(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_InitiateSystemShutdown_force_apps, 0);
3704
3705         return offset;
3706 }
3707
3708 static int
3709 winreg_dissect_element_InitiateSystemShutdown_do_reboot(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3710 {
3711         offset = PIDL_dissect_uint8(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_InitiateSystemShutdown_do_reboot, 0);
3712
3713         return offset;
3714 }
3715
3716 /* IDL: WERROR winreg_InitiateSystemShutdown( */
3717 /* IDL: [unique(1)] [in] uint16 *hostname, */
3718 /* IDL: [unique(1)] [in] lsa_StringLarge *message, */
3719 /* IDL: [in] uint32 timeout, */
3720 /* IDL: [in] uint8 force_apps, */
3721 /* IDL: [in] uint8 do_reboot */
3722 /* IDL: ); */
3723
3724 static int
3725 winreg_dissect_InitiateSystemShutdown_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3726 {
3727         guint32 status;
3728
3729         di->dcerpc_procedure_name="InitiateSystemShutdown";
3730         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
3731
3732         if (status != 0)
3733                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
3734
3735         return offset;
3736 }
3737
3738 static int
3739 winreg_dissect_InitiateSystemShutdown_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3740 {
3741         di->dcerpc_procedure_name="InitiateSystemShutdown";
3742         offset = winreg_dissect_element_InitiateSystemShutdown_hostname(tvb, offset, pinfo, tree, di, drep);
3743         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3744         offset = winreg_dissect_element_InitiateSystemShutdown_message(tvb, offset, pinfo, tree, di, drep);
3745         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3746         offset = winreg_dissect_element_InitiateSystemShutdown_timeout(tvb, offset, pinfo, tree, di, drep);
3747         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3748         offset = winreg_dissect_element_InitiateSystemShutdown_force_apps(tvb, offset, pinfo, tree, di, drep);
3749         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3750         offset = winreg_dissect_element_InitiateSystemShutdown_do_reboot(tvb, offset, pinfo, tree, di, drep);
3751         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3752         return offset;
3753 }
3754
3755 static int
3756 winreg_dissect_element_AbortSystemShutdown_server(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3757 {
3758         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_AbortSystemShutdown_server_, NDR_POINTER_UNIQUE, "Pointer to Server (uint16)",hf_winreg_winreg_AbortSystemShutdown_server);
3759
3760         return offset;
3761 }
3762
3763 static int
3764 winreg_dissect_element_AbortSystemShutdown_server_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3765 {
3766         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_AbortSystemShutdown_server, 0);
3767
3768         return offset;
3769 }
3770
3771 /* IDL: WERROR winreg_AbortSystemShutdown( */
3772 /* IDL: [unique(1)] [in] uint16 *server */
3773 /* IDL: ); */
3774
3775 static int
3776 winreg_dissect_AbortSystemShutdown_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3777 {
3778         guint32 status;
3779
3780         di->dcerpc_procedure_name="AbortSystemShutdown";
3781         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
3782
3783         if (status != 0)
3784                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
3785
3786         return offset;
3787 }
3788
3789 static int
3790 winreg_dissect_AbortSystemShutdown_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3791 {
3792         di->dcerpc_procedure_name="AbortSystemShutdown";
3793         offset = winreg_dissect_element_AbortSystemShutdown_server(tvb, offset, pinfo, tree, di, drep);
3794         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3795         return offset;
3796 }
3797
3798 static int
3799 winreg_dissect_element_GetVersion_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3800 {
3801         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_GetVersion_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
3802
3803         return offset;
3804 }
3805
3806 static int
3807 winreg_dissect_element_GetVersion_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3808 {
3809         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, 0);
3810
3811         return offset;
3812 }
3813
3814 static int
3815 winreg_dissect_element_GetVersion_version(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3816 {
3817         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_GetVersion_version_, NDR_POINTER_REF, "Pointer to Version (uint32)",hf_winreg_winreg_GetVersion_version);
3818
3819         return offset;
3820 }
3821
3822 static int
3823 winreg_dissect_element_GetVersion_version_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3824 {
3825         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_GetVersion_version, 0);
3826
3827         return offset;
3828 }
3829
3830 /* IDL: WERROR winreg_GetVersion( */
3831 /* IDL: [in] [ref] policy_handle *handle, */
3832 /* IDL: [out] [ref] uint32 *version */
3833 /* IDL: ); */
3834
3835 static int
3836 winreg_dissect_GetVersion_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3837 {
3838         guint32 status;
3839
3840         di->dcerpc_procedure_name="GetVersion";
3841         offset = winreg_dissect_element_GetVersion_version(tvb, offset, pinfo, tree, di, drep);
3842         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3843
3844         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
3845
3846         if (status != 0)
3847                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
3848
3849         return offset;
3850 }
3851
3852 static int
3853 winreg_dissect_GetVersion_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3854 {
3855         di->dcerpc_procedure_name="GetVersion";
3856         offset = winreg_dissect_element_GetVersion_handle(tvb, offset, pinfo, tree, di, drep);
3857         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3858         return offset;
3859 }
3860
3861 static int
3862 winreg_dissect_element_OpenHKCC_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3863 {
3864         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKCC_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_system_name);
3865
3866         return offset;
3867 }
3868
3869 static int
3870 winreg_dissect_element_OpenHKCC_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3871 {
3872         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_system_name, 0);
3873
3874         return offset;
3875 }
3876
3877 static int
3878 winreg_dissect_element_OpenHKCC_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3879 {
3880         offset = winreg_dissect_bitmap_AccessMask(tvb, offset, pinfo, tree, di, drep, hf_winreg_access_mask, 0);
3881
3882         return offset;
3883 }
3884
3885 static int
3886 winreg_dissect_element_OpenHKCC_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3887 {
3888         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKCC_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
3889
3890         return offset;
3891 }
3892
3893 static int
3894 winreg_dissect_element_OpenHKCC_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3895 {
3896         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, PIDL_POLHND_OPEN);
3897
3898         return offset;
3899 }
3900
3901 /* IDL: WERROR winreg_OpenHKCC( */
3902 /* IDL: [unique(1)] [in] uint16 *system_name, */
3903 /* IDL: [in] winreg_AccessMask access_mask, */
3904 /* IDL: [out] [ref] policy_handle *handle */
3905 /* IDL: ); */
3906
3907 static int
3908 winreg_dissect_OpenHKCC_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3909 {
3910         guint32 status;
3911
3912         di->dcerpc_procedure_name="OpenHKCC";
3913         offset = winreg_dissect_element_OpenHKCC_handle(tvb, offset, pinfo, tree, di, drep);
3914         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3915
3916         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
3917
3918         if (status != 0)
3919                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
3920
3921         return offset;
3922 }
3923
3924 static int
3925 winreg_dissect_OpenHKCC_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3926 {
3927         di->dcerpc_procedure_name="OpenHKCC";
3928         offset = winreg_dissect_element_OpenHKCC_system_name(tvb, offset, pinfo, tree, di, drep);
3929         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3930         offset = winreg_dissect_element_OpenHKCC_access_mask(tvb, offset, pinfo, tree, di, drep);
3931         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3932         return offset;
3933 }
3934
3935 static int
3936 winreg_dissect_element_OpenHKDD_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3937 {
3938         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKDD_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_system_name);
3939
3940         return offset;
3941 }
3942
3943 static int
3944 winreg_dissect_element_OpenHKDD_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3945 {
3946         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_system_name, 0);
3947
3948         return offset;
3949 }
3950
3951 static int
3952 winreg_dissect_element_OpenHKDD_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3953 {
3954         offset = winreg_dissect_bitmap_AccessMask(tvb, offset, pinfo, tree, di, drep, hf_winreg_access_mask, 0);
3955
3956         return offset;
3957 }
3958
3959 static int
3960 winreg_dissect_element_OpenHKDD_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3961 {
3962         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKDD_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
3963
3964         return offset;
3965 }
3966
3967 static int
3968 winreg_dissect_element_OpenHKDD_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3969 {
3970         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, PIDL_POLHND_OPEN);
3971
3972         return offset;
3973 }
3974
3975 /* IDL: WERROR winreg_OpenHKDD( */
3976 /* IDL: [unique(1)] [in] uint16 *system_name, */
3977 /* IDL: [in] winreg_AccessMask access_mask, */
3978 /* IDL: [out] [ref] policy_handle *handle */
3979 /* IDL: ); */
3980
3981 static int
3982 winreg_dissect_OpenHKDD_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
3983 {
3984         guint32 status;
3985
3986         di->dcerpc_procedure_name="OpenHKDD";
3987         offset = winreg_dissect_element_OpenHKDD_handle(tvb, offset, pinfo, tree, di, drep);
3988         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
3989
3990         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
3991
3992         if (status != 0)
3993                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
3994
3995         return offset;
3996 }
3997
3998 static int
3999 winreg_dissect_OpenHKDD_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4000 {
4001         di->dcerpc_procedure_name="OpenHKDD";
4002         offset = winreg_dissect_element_OpenHKDD_system_name(tvb, offset, pinfo, tree, di, drep);
4003         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4004         offset = winreg_dissect_element_OpenHKDD_access_mask(tvb, offset, pinfo, tree, di, drep);
4005         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4006         return offset;
4007 }
4008
4009 static int
4010 winreg_dissect_element_QueryMultipleValues_key_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4011 {
4012         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues_key_handle_, NDR_POINTER_REF, "Pointer to Key Handle (policy_handle)",hf_winreg_winreg_QueryMultipleValues_key_handle);
4013
4014         return offset;
4015 }
4016
4017 static int
4018 winreg_dissect_element_QueryMultipleValues_key_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4019 {
4020         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryMultipleValues_key_handle, 0);
4021
4022         return offset;
4023 }
4024
4025 static int
4026 winreg_dissect_element_QueryMultipleValues_values_in(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4027 {
4028         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues_values_in_, NDR_POINTER_REF, "Pointer to Values In (QueryMultipleValue)",hf_winreg_winreg_QueryMultipleValues_values_in);
4029
4030         return offset;
4031 }
4032
4033 static int
4034 winreg_dissect_element_QueryMultipleValues_values_in_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4035 {
4036         offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues_values_in__);
4037
4038         return offset;
4039 }
4040
4041 static int
4042 winreg_dissect_element_QueryMultipleValues_values_in__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4043 {
4044         offset = winreg_dissect_struct_QueryMultipleValue(tvb,offset,pinfo,tree,di,drep,hf_winreg_winreg_QueryMultipleValues_values_in,0);
4045
4046         return offset;
4047 }
4048
4049 static int
4050 winreg_dissect_element_QueryMultipleValues_values_out(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4051 {
4052         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues_values_out_, NDR_POINTER_REF, "Pointer to Values Out (QueryMultipleValue)",hf_winreg_winreg_QueryMultipleValues_values_out);
4053
4054         return offset;
4055 }
4056
4057 static int
4058 winreg_dissect_element_QueryMultipleValues_values_out_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4059 {
4060         offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues_values_out__);
4061
4062         return offset;
4063 }
4064
4065 static int
4066 winreg_dissect_element_QueryMultipleValues_values_out__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4067 {
4068         offset = winreg_dissect_struct_QueryMultipleValue(tvb,offset,pinfo,tree,di,drep,hf_winreg_winreg_QueryMultipleValues_values_out,0);
4069
4070         return offset;
4071 }
4072
4073 static int
4074 winreg_dissect_element_QueryMultipleValues_num_values(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4075 {
4076         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryMultipleValues_num_values, 0);
4077
4078         return offset;
4079 }
4080
4081 static int
4082 winreg_dissect_element_QueryMultipleValues_buffer(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4083 {
4084         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues_buffer_, NDR_POINTER_UNIQUE, "Pointer to Buffer (uint8)",hf_winreg_winreg_QueryMultipleValues_buffer);
4085
4086         return offset;
4087 }
4088
4089 static int
4090 winreg_dissect_element_QueryMultipleValues_buffer_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4091 {
4092         offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues_buffer__);
4093
4094         return offset;
4095 }
4096
4097 static int
4098 winreg_dissect_element_QueryMultipleValues_buffer__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4099 {
4100         offset = PIDL_dissect_uint8(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryMultipleValues_buffer, 0);
4101
4102         return offset;
4103 }
4104
4105 static int
4106 winreg_dissect_element_QueryMultipleValues_buffer_size(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4107 {
4108         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues_buffer_size_, NDR_POINTER_REF, "Pointer to Buffer Size (uint32)",hf_winreg_winreg_QueryMultipleValues_buffer_size);
4109
4110         return offset;
4111 }
4112
4113 static int
4114 winreg_dissect_element_QueryMultipleValues_buffer_size_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4115 {
4116         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryMultipleValues_buffer_size, 0);
4117
4118         return offset;
4119 }
4120
4121 /* IDL: WERROR winreg_QueryMultipleValues( */
4122 /* IDL: [in] [ref] policy_handle *key_handle, */
4123 /* IDL: [in] [ref] [length_is(num_values)] [size_is(num_values)] QueryMultipleValue *values_in, */
4124 /* IDL: [out] [ref] [length_is(num_values)] [size_is(num_values)] QueryMultipleValue *values_out, */
4125 /* IDL: [in] uint32 num_values, */
4126 /* IDL: [out] [unique(1)] [in] [length_is(*buffer_size)] [size_is(*buffer_size)] uint8 *buffer, */
4127 /* IDL: [out] [in] [ref] uint32 *buffer_size */
4128 /* IDL: ); */
4129
4130 static int
4131 winreg_dissect_QueryMultipleValues_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4132 {
4133         guint32 status;
4134
4135         di->dcerpc_procedure_name="QueryMultipleValues";
4136         offset = winreg_dissect_element_QueryMultipleValues_values_out(tvb, offset, pinfo, tree, di, drep);
4137         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4138
4139         offset = winreg_dissect_element_QueryMultipleValues_buffer(tvb, offset, pinfo, tree, di, drep);
4140         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4141
4142         offset = winreg_dissect_element_QueryMultipleValues_buffer_size(tvb, offset, pinfo, tree, di, drep);
4143         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4144
4145         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
4146
4147         if (status != 0)
4148                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
4149
4150         return offset;
4151 }
4152
4153 static int
4154 winreg_dissect_QueryMultipleValues_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4155 {
4156         di->dcerpc_procedure_name="QueryMultipleValues";
4157         offset = winreg_dissect_element_QueryMultipleValues_key_handle(tvb, offset, pinfo, tree, di, drep);
4158         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4159         offset = winreg_dissect_element_QueryMultipleValues_values_in(tvb, offset, pinfo, tree, di, drep);
4160         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4161         offset = winreg_dissect_element_QueryMultipleValues_num_values(tvb, offset, pinfo, tree, di, drep);
4162         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4163         offset = winreg_dissect_element_QueryMultipleValues_buffer(tvb, offset, pinfo, tree, di, drep);
4164         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4165         offset = winreg_dissect_element_QueryMultipleValues_buffer_size(tvb, offset, pinfo, tree, di, drep);
4166         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4167         return offset;
4168 }
4169
4170 static int
4171 winreg_dissect_element_InitiateSystemShutdownEx_hostname(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4172 {
4173         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_InitiateSystemShutdownEx_hostname_, NDR_POINTER_UNIQUE, "Pointer to Hostname (uint16)",hf_winreg_winreg_InitiateSystemShutdownEx_hostname);
4174
4175         return offset;
4176 }
4177
4178 static int
4179 winreg_dissect_element_InitiateSystemShutdownEx_hostname_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4180 {
4181         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_InitiateSystemShutdownEx_hostname, 0);
4182
4183         return offset;
4184 }
4185
4186 static int
4187 winreg_dissect_element_InitiateSystemShutdownEx_message(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4188 {
4189         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_InitiateSystemShutdownEx_message_, NDR_POINTER_UNIQUE, "Pointer to Message (lsa_StringLarge)",hf_winreg_winreg_InitiateSystemShutdownEx_message);
4190
4191         return offset;
4192 }
4193
4194 static int
4195 winreg_dissect_element_InitiateSystemShutdownEx_message_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4196 {
4197         offset=lsarpc_dissect_struct_lsa_StringLarge(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_InitiateSystemShutdownEx_message, 0);
4198
4199         return offset;
4200 }
4201
4202 static int
4203 winreg_dissect_element_InitiateSystemShutdownEx_timeout(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4204 {
4205         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_InitiateSystemShutdownEx_timeout, 0);
4206
4207         return offset;
4208 }
4209
4210 static int
4211 winreg_dissect_element_InitiateSystemShutdownEx_force_apps(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4212 {
4213         offset = PIDL_dissect_uint8(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_InitiateSystemShutdownEx_force_apps, 0);
4214
4215         return offset;
4216 }
4217
4218 static int
4219 winreg_dissect_element_InitiateSystemShutdownEx_do_reboot(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4220 {
4221         offset = PIDL_dissect_uint8(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_InitiateSystemShutdownEx_do_reboot, 0);
4222
4223         return offset;
4224 }
4225
4226 static int
4227 winreg_dissect_element_InitiateSystemShutdownEx_reason(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4228 {
4229         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_InitiateSystemShutdownEx_reason, 0);
4230
4231         return offset;
4232 }
4233
4234 /* IDL: WERROR winreg_InitiateSystemShutdownEx( */
4235 /* IDL: [unique(1)] [in] uint16 *hostname, */
4236 /* IDL: [unique(1)] [in] lsa_StringLarge *message, */
4237 /* IDL: [in] uint32 timeout, */
4238 /* IDL: [in] uint8 force_apps, */
4239 /* IDL: [in] uint8 do_reboot, */
4240 /* IDL: [in] uint32 reason */
4241 /* IDL: ); */
4242
4243 static int
4244 winreg_dissect_InitiateSystemShutdownEx_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4245 {
4246         guint32 status;
4247
4248         di->dcerpc_procedure_name="InitiateSystemShutdownEx";
4249         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
4250
4251         if (status != 0)
4252                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
4253
4254         return offset;
4255 }
4256
4257 static int
4258 winreg_dissect_InitiateSystemShutdownEx_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4259 {
4260         di->dcerpc_procedure_name="InitiateSystemShutdownEx";
4261         offset = winreg_dissect_element_InitiateSystemShutdownEx_hostname(tvb, offset, pinfo, tree, di, drep);
4262         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4263         offset = winreg_dissect_element_InitiateSystemShutdownEx_message(tvb, offset, pinfo, tree, di, drep);
4264         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4265         offset = winreg_dissect_element_InitiateSystemShutdownEx_timeout(tvb, offset, pinfo, tree, di, drep);
4266         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4267         offset = winreg_dissect_element_InitiateSystemShutdownEx_force_apps(tvb, offset, pinfo, tree, di, drep);
4268         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4269         offset = winreg_dissect_element_InitiateSystemShutdownEx_do_reboot(tvb, offset, pinfo, tree, di, drep);
4270         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4271         offset = winreg_dissect_element_InitiateSystemShutdownEx_reason(tvb, offset, pinfo, tree, di, drep);
4272         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4273         return offset;
4274 }
4275
4276 static int
4277 winreg_dissect_element_SaveKeyEx_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4278 {
4279         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_SaveKeyEx_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_SaveKeyEx_handle);
4280
4281         return offset;
4282 }
4283
4284 static int
4285 winreg_dissect_element_SaveKeyEx_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4286 {
4287         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_SaveKeyEx_handle, 0);
4288
4289         return offset;
4290 }
4291
4292 static int
4293 winreg_dissect_element_SaveKeyEx_filename(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4294 {
4295         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_SaveKeyEx_filename_, NDR_POINTER_REF, "Pointer to Filename (winreg_String)",hf_winreg_winreg_SaveKeyEx_filename);
4296
4297         return offset;
4298 }
4299
4300 static int
4301 winreg_dissect_element_SaveKeyEx_filename_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4302 {
4303         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_SaveKeyEx_filename);
4304
4305         return offset;
4306 }
4307
4308 static int
4309 winreg_dissect_element_SaveKeyEx_sec_attrib(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4310 {
4311         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_SaveKeyEx_sec_attrib_, NDR_POINTER_UNIQUE, "Pointer to Sec Attrib (KeySecurityAttribute)",hf_winreg_winreg_SaveKeyEx_sec_attrib);
4312
4313         return offset;
4314 }
4315
4316 static int
4317 winreg_dissect_element_SaveKeyEx_sec_attrib_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4318 {
4319         offset = winreg_dissect_struct_KeySecurityAttribute(tvb,offset,pinfo,tree,di,drep,hf_winreg_winreg_SaveKeyEx_sec_attrib,0);
4320
4321         return offset;
4322 }
4323
4324 static int
4325 winreg_dissect_element_SaveKeyEx_flags(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4326 {
4327         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_SaveKeyEx_flags, 0);
4328
4329         return offset;
4330 }
4331
4332 /* IDL: WERROR winreg_SaveKeyEx( */
4333 /* IDL: [in] [ref] policy_handle *handle, */
4334 /* IDL: [in] [ref] winreg_String *filename, */
4335 /* IDL: [unique(1)] [in] KeySecurityAttribute *sec_attrib, */
4336 /* IDL: [in] uint32 flags */
4337 /* IDL: ); */
4338
4339 static int
4340 winreg_dissect_SaveKeyEx_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4341 {
4342         guint32 status;
4343
4344         di->dcerpc_procedure_name="SaveKeyEx";
4345         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
4346
4347         if (status != 0)
4348                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
4349
4350         return offset;
4351 }
4352
4353 static int
4354 winreg_dissect_SaveKeyEx_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4355 {
4356         di->dcerpc_procedure_name="SaveKeyEx";
4357         offset = winreg_dissect_element_SaveKeyEx_handle(tvb, offset, pinfo, tree, di, drep);
4358         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4359         offset = winreg_dissect_element_SaveKeyEx_filename(tvb, offset, pinfo, tree, di, drep);
4360         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4361         offset = winreg_dissect_element_SaveKeyEx_sec_attrib(tvb, offset, pinfo, tree, di, drep);
4362         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4363         offset = winreg_dissect_element_SaveKeyEx_flags(tvb, offset, pinfo, tree, di, drep);
4364         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4365         return offset;
4366 }
4367
4368 static int
4369 winreg_dissect_element_OpenHKPT_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4370 {
4371         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKPT_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_system_name);
4372
4373         return offset;
4374 }
4375
4376 static int
4377 winreg_dissect_element_OpenHKPT_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4378 {
4379         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_system_name, 0);
4380
4381         return offset;
4382 }
4383
4384 static int
4385 winreg_dissect_element_OpenHKPT_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4386 {
4387         offset = winreg_dissect_bitmap_AccessMask(tvb, offset, pinfo, tree, di, drep, hf_winreg_access_mask, 0);
4388
4389         return offset;
4390 }
4391
4392 static int
4393 winreg_dissect_element_OpenHKPT_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4394 {
4395         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKPT_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
4396
4397         return offset;
4398 }
4399
4400 static int
4401 winreg_dissect_element_OpenHKPT_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4402 {
4403         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, PIDL_POLHND_OPEN);
4404
4405         return offset;
4406 }
4407
4408 /* IDL: WERROR winreg_OpenHKPT( */
4409 /* IDL: [unique(1)] [in] uint16 *system_name, */
4410 /* IDL: [in] winreg_AccessMask access_mask, */
4411 /* IDL: [out] [ref] policy_handle *handle */
4412 /* IDL: ); */
4413
4414 static int
4415 winreg_dissect_OpenHKPT_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4416 {
4417         guint32 status;
4418
4419         di->dcerpc_procedure_name="OpenHKPT";
4420         offset = winreg_dissect_element_OpenHKPT_handle(tvb, offset, pinfo, tree, di, drep);
4421         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4422
4423         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
4424
4425         if (status != 0)
4426                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
4427
4428         return offset;
4429 }
4430
4431 static int
4432 winreg_dissect_OpenHKPT_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4433 {
4434         di->dcerpc_procedure_name="OpenHKPT";
4435         offset = winreg_dissect_element_OpenHKPT_system_name(tvb, offset, pinfo, tree, di, drep);
4436         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4437         offset = winreg_dissect_element_OpenHKPT_access_mask(tvb, offset, pinfo, tree, di, drep);
4438         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4439         return offset;
4440 }
4441
4442 static int
4443 winreg_dissect_element_OpenHKPN_system_name(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4444 {
4445         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKPN_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_system_name);
4446
4447         return offset;
4448 }
4449
4450 static int
4451 winreg_dissect_element_OpenHKPN_system_name_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4452 {
4453         offset = PIDL_dissect_uint16(tvb, offset, pinfo, tree, di, drep, hf_winreg_system_name, 0);
4454
4455         return offset;
4456 }
4457
4458 static int
4459 winreg_dissect_element_OpenHKPN_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4460 {
4461         offset = winreg_dissect_bitmap_AccessMask(tvb, offset, pinfo, tree, di, drep, hf_winreg_access_mask, 0);
4462
4463         return offset;
4464 }
4465
4466 static int
4467 winreg_dissect_element_OpenHKPN_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4468 {
4469         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_OpenHKPN_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_handle);
4470
4471         return offset;
4472 }
4473
4474 static int
4475 winreg_dissect_element_OpenHKPN_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4476 {
4477         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_handle, PIDL_POLHND_OPEN);
4478
4479         return offset;
4480 }
4481
4482 /* IDL: WERROR winreg_OpenHKPN( */
4483 /* IDL: [unique(1)] [in] uint16 *system_name, */
4484 /* IDL: [in] winreg_AccessMask access_mask, */
4485 /* IDL: [out] [ref] policy_handle *handle */
4486 /* IDL: ); */
4487
4488 static int
4489 winreg_dissect_OpenHKPN_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4490 {
4491         guint32 status;
4492
4493         di->dcerpc_procedure_name="OpenHKPN";
4494         offset = winreg_dissect_element_OpenHKPN_handle(tvb, offset, pinfo, tree, di, drep);
4495         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4496
4497         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
4498
4499         if (status != 0)
4500                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
4501
4502         return offset;
4503 }
4504
4505 static int
4506 winreg_dissect_OpenHKPN_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4507 {
4508         di->dcerpc_procedure_name="OpenHKPN";
4509         offset = winreg_dissect_element_OpenHKPN_system_name(tvb, offset, pinfo, tree, di, drep);
4510         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4511         offset = winreg_dissect_element_OpenHKPN_access_mask(tvb, offset, pinfo, tree, di, drep);
4512         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4513         return offset;
4514 }
4515
4516 static int
4517 winreg_dissect_element_QueryMultipleValues2_key_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4518 {
4519         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues2_key_handle_, NDR_POINTER_REF, "Pointer to Key Handle (policy_handle)",hf_winreg_winreg_QueryMultipleValues2_key_handle);
4520
4521         return offset;
4522 }
4523
4524 static int
4525 winreg_dissect_element_QueryMultipleValues2_key_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4526 {
4527         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryMultipleValues2_key_handle, 0);
4528
4529         return offset;
4530 }
4531
4532 static int
4533 winreg_dissect_element_QueryMultipleValues2_values_in(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4534 {
4535         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues2_values_in_, NDR_POINTER_REF, "Pointer to Values In (QueryMultipleValue)",hf_winreg_winreg_QueryMultipleValues2_values_in);
4536
4537         return offset;
4538 }
4539
4540 static int
4541 winreg_dissect_element_QueryMultipleValues2_values_in_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4542 {
4543         offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues2_values_in__);
4544
4545         return offset;
4546 }
4547
4548 static int
4549 winreg_dissect_element_QueryMultipleValues2_values_in__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4550 {
4551         offset = winreg_dissect_struct_QueryMultipleValue(tvb,offset,pinfo,tree,di,drep,hf_winreg_winreg_QueryMultipleValues2_values_in,0);
4552
4553         return offset;
4554 }
4555
4556 static int
4557 winreg_dissect_element_QueryMultipleValues2_values_out(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4558 {
4559         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues2_values_out_, NDR_POINTER_REF, "Pointer to Values Out (QueryMultipleValue)",hf_winreg_winreg_QueryMultipleValues2_values_out);
4560
4561         return offset;
4562 }
4563
4564 static int
4565 winreg_dissect_element_QueryMultipleValues2_values_out_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4566 {
4567         offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues2_values_out__);
4568
4569         return offset;
4570 }
4571
4572 static int
4573 winreg_dissect_element_QueryMultipleValues2_values_out__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4574 {
4575         offset = winreg_dissect_struct_QueryMultipleValue(tvb,offset,pinfo,tree,di,drep,hf_winreg_winreg_QueryMultipleValues2_values_out,0);
4576
4577         return offset;
4578 }
4579
4580 static int
4581 winreg_dissect_element_QueryMultipleValues2_num_values(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4582 {
4583         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryMultipleValues2_num_values, 0);
4584
4585         return offset;
4586 }
4587
4588 static int
4589 winreg_dissect_element_QueryMultipleValues2_buffer(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4590 {
4591         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues2_buffer_, NDR_POINTER_UNIQUE, "Pointer to Buffer (uint8)",hf_winreg_winreg_QueryMultipleValues2_buffer);
4592
4593         return offset;
4594 }
4595
4596 static int
4597 winreg_dissect_element_QueryMultipleValues2_buffer_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4598 {
4599         offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues2_buffer__);
4600
4601         return offset;
4602 }
4603
4604 static int
4605 winreg_dissect_element_QueryMultipleValues2_buffer__(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4606 {
4607         offset = PIDL_dissect_uint8(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryMultipleValues2_buffer, 0);
4608
4609         return offset;
4610 }
4611
4612 static int
4613 winreg_dissect_element_QueryMultipleValues2_offered(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4614 {
4615         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues2_offered_, NDR_POINTER_REF, "Pointer to Offered (uint32)",hf_winreg_winreg_QueryMultipleValues2_offered);
4616
4617         return offset;
4618 }
4619
4620 static int
4621 winreg_dissect_element_QueryMultipleValues2_offered_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4622 {
4623         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryMultipleValues2_offered, 0);
4624
4625         return offset;
4626 }
4627
4628 static int
4629 winreg_dissect_element_QueryMultipleValues2_needed(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4630 {
4631         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_QueryMultipleValues2_needed_, NDR_POINTER_REF, "Pointer to Needed (uint32)",hf_winreg_winreg_QueryMultipleValues2_needed);
4632
4633         return offset;
4634 }
4635
4636 static int
4637 winreg_dissect_element_QueryMultipleValues2_needed_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4638 {
4639         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_QueryMultipleValues2_needed, 0);
4640
4641         return offset;
4642 }
4643
4644 /* IDL: WERROR winreg_QueryMultipleValues2( */
4645 /* IDL: [in] [ref] policy_handle *key_handle, */
4646 /* IDL: [in] [ref] [length_is(num_values)] [size_is(num_values)] QueryMultipleValue *values_in, */
4647 /* IDL: [out] [ref] [length_is(num_values)] [size_is(num_values)] QueryMultipleValue *values_out, */
4648 /* IDL: [in] uint32 num_values, */
4649 /* IDL: [out] [unique(1)] [in] [length_is(*offered)] [size_is(*offered)] uint8 *buffer, */
4650 /* IDL: [in] [ref] uint32 *offered, */
4651 /* IDL: [out] [ref] uint32 *needed */
4652 /* IDL: ); */
4653
4654 static int
4655 winreg_dissect_QueryMultipleValues2_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4656 {
4657         guint32 status;
4658
4659         di->dcerpc_procedure_name="QueryMultipleValues2";
4660         offset = winreg_dissect_element_QueryMultipleValues2_values_out(tvb, offset, pinfo, tree, di, drep);
4661         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4662
4663         offset = winreg_dissect_element_QueryMultipleValues2_buffer(tvb, offset, pinfo, tree, di, drep);
4664         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4665
4666         offset = winreg_dissect_element_QueryMultipleValues2_needed(tvb, offset, pinfo, tree, di, drep);
4667         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4668
4669         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
4670
4671         if (status != 0)
4672                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
4673
4674         return offset;
4675 }
4676
4677 static int
4678 winreg_dissect_QueryMultipleValues2_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4679 {
4680         di->dcerpc_procedure_name="QueryMultipleValues2";
4681         offset = winreg_dissect_element_QueryMultipleValues2_key_handle(tvb, offset, pinfo, tree, di, drep);
4682         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4683         offset = winreg_dissect_element_QueryMultipleValues2_values_in(tvb, offset, pinfo, tree, di, drep);
4684         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4685         offset = winreg_dissect_element_QueryMultipleValues2_num_values(tvb, offset, pinfo, tree, di, drep);
4686         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4687         offset = winreg_dissect_element_QueryMultipleValues2_buffer(tvb, offset, pinfo, tree, di, drep);
4688         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4689         offset = winreg_dissect_element_QueryMultipleValues2_offered(tvb, offset, pinfo, tree, di, drep);
4690         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4691         return offset;
4692 }
4693
4694 static int
4695 winreg_dissect_element_DeleteKeyEx_handle(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4696 {
4697         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_DeleteKeyEx_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_DeleteKeyEx_handle);
4698
4699         return offset;
4700 }
4701
4702 static int
4703 winreg_dissect_element_DeleteKeyEx_handle_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4704 {
4705         offset = PIDL_dissect_policy_hnd(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_DeleteKeyEx_handle, 0);
4706
4707         return offset;
4708 }
4709
4710 static int
4711 winreg_dissect_element_DeleteKeyEx_key(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4712 {
4713         offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, di, drep, winreg_dissect_element_DeleteKeyEx_key_, NDR_POINTER_REF, "Pointer to Key (winreg_String)",hf_winreg_winreg_DeleteKeyEx_key);
4714
4715         return offset;
4716 }
4717
4718 static int
4719 winreg_dissect_element_DeleteKeyEx_key_(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4720 {
4721         offset=cnf_dissect_winreg_String(tvb, offset, pinfo, tree, di, drep, 0, hf_winreg_winreg_DeleteKeyEx_key);
4722
4723         return offset;
4724 }
4725
4726 static int
4727 winreg_dissect_element_DeleteKeyEx_access_mask(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4728 {
4729         offset = winreg_dissect_bitmap_AccessMask(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_DeleteKeyEx_access_mask, 0);
4730
4731         return offset;
4732 }
4733
4734 static int
4735 winreg_dissect_element_DeleteKeyEx_reserved(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4736 {
4737         offset = PIDL_dissect_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_winreg_DeleteKeyEx_reserved, 0);
4738
4739         return offset;
4740 }
4741
4742 /* IDL: WERROR winreg_DeleteKeyEx( */
4743 /* IDL: [in] [ref] policy_handle *handle, */
4744 /* IDL: [in] [ref] winreg_String *key, */
4745 /* IDL: [in] winreg_AccessMask access_mask, */
4746 /* IDL: [in] uint32 reserved */
4747 /* IDL: ); */
4748
4749 static int
4750 winreg_dissect_DeleteKeyEx_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4751 {
4752         guint32 status;
4753
4754         di->dcerpc_procedure_name="DeleteKeyEx";
4755         offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, di, drep, hf_winreg_werror, &status);
4756
4757         if (status != 0)
4758                 col_append_fstr(pinfo->cinfo, COL_INFO, ", Error: %s", val_to_str(status, WERR_errors, "Unknown DOS error 0x%08x"));
4759
4760         return offset;
4761 }
4762
4763 static int
4764 winreg_dissect_DeleteKeyEx_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, dcerpc_info* di _U_, guint8 *drep _U_)
4765 {
4766         di->dcerpc_procedure_name="DeleteKeyEx";
4767         offset = winreg_dissect_element_DeleteKeyEx_handle(tvb, offset, pinfo, tree, di, drep);
4768         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4769         offset = winreg_dissect_element_DeleteKeyEx_key(tvb, offset, pinfo, tree, di, drep);
4770         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4771         offset = winreg_dissect_element_DeleteKeyEx_access_mask(tvb, offset, pinfo, tree, di, drep);
4772         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4773         offset = winreg_dissect_element_DeleteKeyEx_reserved(tvb, offset, pinfo, tree, di, drep);
4774         offset = dissect_deferred_pointers(pinfo, tvb, offset, di, drep);
4775         return offset;
4776 }
4777
4778
4779 static dcerpc_sub_dissector winreg_dissectors[] = {
4780         { 0, "OpenHKCR",
4781            winreg_dissect_OpenHKCR_request, winreg_dissect_OpenHKCR_response},
4782         { 1, "OpenHKCU",
4783            winreg_dissect_OpenHKCU_request, winreg_dissect_OpenHKCU_response},
4784         { 2, "OpenHKLM",
4785            winreg_dissect_OpenHKLM_request, winreg_dissect_OpenHKLM_response},
4786         { 3, "OpenHKPD",
4787            winreg_dissect_OpenHKPD_request, winreg_dissect_OpenHKPD_response},
4788         { 4, "OpenHKU",
4789            winreg_dissect_OpenHKU_request, winreg_dissect_OpenHKU_response},
4790         { 5, "CloseKey",
4791            winreg_dissect_CloseKey_request, winreg_dissect_CloseKey_response},
4792         { 6, "CreateKey",
4793            winreg_dissect_CreateKey_request, winreg_dissect_CreateKey_response},
4794         { 7, "DeleteKey",
4795            winreg_dissect_DeleteKey_request, winreg_dissect_DeleteKey_response},
4796         { 8, "DeleteValue",
4797            winreg_dissect_DeleteValue_request, winreg_dissect_DeleteValue_response},
4798         { 9, "EnumKey",
4799            winreg_dissect_EnumKey_request, winreg_dissect_EnumKey_response},
4800         { 10, "EnumValue",
4801            winreg_dissect_EnumValue_request, winreg_dissect_EnumValue_response},
4802         { 11, "FlushKey",
4803            winreg_dissect_FlushKey_request, winreg_dissect_FlushKey_response},
4804         { 12, "GetKeySecurity",
4805            winreg_dissect_GetKeySecurity_request, winreg_dissect_GetKeySecurity_response},
4806         { 13, "LoadKey",
4807            winreg_dissect_LoadKey_request, winreg_dissect_LoadKey_response},
4808         { 14, "NotifyChangeKeyValue",
4809            winreg_dissect_NotifyChangeKeyValue_request, winreg_dissect_NotifyChangeKeyValue_response},
4810         { 15, "OpenKey",
4811            winreg_dissect_OpenKey_request, winreg_dissect_OpenKey_response},
4812         { 16, "QueryInfoKey",
4813            winreg_dissect_QueryInfoKey_request, winreg_dissect_QueryInfoKey_response},
4814         { 17, "QueryValue",
4815            winreg_dissect_QueryValue_request, winreg_dissect_QueryValue_response},
4816         { 18, "ReplaceKey",
4817            winreg_dissect_ReplaceKey_request, winreg_dissect_ReplaceKey_response},
4818         { 19, "RestoreKey",
4819            winreg_dissect_RestoreKey_request, winreg_dissect_RestoreKey_response},
4820         { 20, "SaveKey",
4821            winreg_dissect_SaveKey_request, winreg_dissect_SaveKey_response},
4822         { 21, "SetKeySecurity",
4823            winreg_dissect_SetKeySecurity_request, winreg_dissect_SetKeySecurity_response},
4824         { 22, "SetValue",
4825            winreg_dissect_SetValue_request, winreg_dissect_SetValue_response},
4826         { 23, "UnLoadKey",
4827            winreg_dissect_UnLoadKey_request, winreg_dissect_UnLoadKey_response},
4828         { 24, "InitiateSystemShutdown",
4829            winreg_dissect_InitiateSystemShutdown_request, winreg_dissect_InitiateSystemShutdown_response},
4830         { 25, "AbortSystemShutdown",
4831            winreg_dissect_AbortSystemShutdown_request, winreg_dissect_AbortSystemShutdown_response},
4832         { 26, "GetVersion",
4833            winreg_dissect_GetVersion_request, winreg_dissect_GetVersion_response},
4834         { 27, "OpenHKCC",
4835            winreg_dissect_OpenHKCC_request, winreg_dissect_OpenHKCC_response},
4836         { 28, "OpenHKDD",
4837            winreg_dissect_OpenHKDD_request, winreg_dissect_OpenHKDD_response},
4838         { 29, "QueryMultipleValues",
4839            winreg_dissect_QueryMultipleValues_request, winreg_dissect_QueryMultipleValues_response},
4840         { 30, "InitiateSystemShutdownEx",
4841            winreg_dissect_InitiateSystemShutdownEx_request, winreg_dissect_InitiateSystemShutdownEx_response},
4842         { 31, "SaveKeyEx",
4843            winreg_dissect_SaveKeyEx_request, winreg_dissect_SaveKeyEx_response},
4844         { 32, "OpenHKPT",
4845            winreg_dissect_OpenHKPT_request, winreg_dissect_OpenHKPT_response},
4846         { 33, "OpenHKPN",
4847            winreg_dissect_OpenHKPN_request, winreg_dissect_OpenHKPN_response},
4848         { 34, "QueryMultipleValues2",
4849            winreg_dissect_QueryMultipleValues2_request, winreg_dissect_QueryMultipleValues2_response},
4850         { 35, "DeleteKeyEx",
4851            winreg_dissect_DeleteKeyEx_request, winreg_dissect_DeleteKeyEx_response},
4852         { 0, NULL, NULL, NULL }
4853 };
4854
4855 void proto_register_dcerpc_winreg(void)
4856 {
4857         static hf_register_info hf[] = {
4858         { &hf_winreg_winreg_AccessMask_KEY_ENUMERATE_SUB_KEYS,
4859                 { "Key Enumerate Sub Keys", "winreg.winreg_AccessMask.KEY_ENUMERATE_SUB_KEYS", FT_BOOLEAN, 32, TFS(&winreg_AccessMask_KEY_ENUMERATE_SUB_KEYS_tfs), ( 0x00008 ), NULL, HFILL }},
4860         { &hf_winreg_winreg_NotifyChangeKeyValue_string2,
4861                 { "String2", "winreg.winreg_NotifyChangeKeyValue.string2", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
4862         { &hf_winreg_winreg_InitiateSystemShutdown_message,
4863                 { "Message", "winreg.winreg_InitiateSystemShutdown.message", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
4864         { &hf_winreg_winreg_String_name,
4865                 { "Name", "winreg.winreg_String.name", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
4866         { &hf_winreg_winreg_InitiateSystemShutdownEx_message,
4867                 { "Message", "winreg.winreg_InitiateSystemShutdownEx.message", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
4868         { &hf_winreg_winreg_EnumValue_enum_index,
4869                 { "Enum Index", "winreg.winreg_EnumValue.enum_index", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4870         { &hf_winreg_access_mask,
4871                 { "Access Mask", "winreg.access_mask", FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL }},
4872         { &hf_winreg_winreg_CreateKey_options,
4873                 { "Options", "winreg.winreg_CreateKey.options", FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL }},
4874         { &hf_winreg_winreg_InitiateSystemShutdownEx_timeout,
4875                 { "Timeout", "winreg.winreg_InitiateSystemShutdownEx.timeout", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4876         { &hf_winreg_handle,
4877                 { "Handle", "winreg.handle", FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL }},
4878         { &hf_winreg_winreg_QueryInfoKey_max_valnamelen,
4879                 { "Max Valnamelen", "winreg.winreg_QueryInfoKey.max_valnamelen", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4880         { &hf_winreg_winreg_SecBuf_length,
4881                 { "Length", "winreg.winreg_SecBuf.length", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4882         { &hf_winreg_winreg_InitiateSystemShutdown_do_reboot,
4883                 { "Do Reboot", "winreg.winreg_InitiateSystemShutdown.do_reboot", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
4884         { &hf_winreg_winreg_DeleteKeyEx_handle,
4885                 { "Handle", "winreg.winreg_DeleteKeyEx.handle", FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL }},
4886         { &hf_winreg_winreg_QueryMultipleValues_buffer_size,
4887                 { "Buffer Size", "winreg.winreg_QueryMultipleValues.buffer_size", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4888         { &hf_winreg_winreg_CreateKey_new_handle,
4889                 { "New Handle", "winreg.winreg_CreateKey.new_handle", FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL }},
4890         { &hf_winreg_winreg_QueryMultipleValues2_needed,
4891                 { "Needed", "winreg.winreg_QueryMultipleValues2.needed", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4892         { &hf_winreg_QueryMultipleValue_ve_valuelen,
4893                 { "Ve Valuelen", "winreg.QueryMultipleValue.ve_valuelen", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4894         { &hf_winreg_KeySecurityAttribute_sec_data,
4895                 { "Sec Data", "winreg.KeySecurityAttribute.sec_data", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
4896         { &hf_winreg_winreg_GetKeySecurity_sec_info,
4897                 { "Sec Info", "winreg.winreg_GetKeySecurity.sec_info", FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL }},
4898         { &hf_winreg_winreg_SaveKeyEx_handle,
4899                 { "Handle", "winreg.winreg_SaveKeyEx.handle", FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL }},
4900         { &hf_winreg_winreg_KeyOptions_REG_OPTION_VOLATILE,
4901                 { "Reg Option Volatile", "winreg.winreg_KeyOptions.REG_OPTION_VOLATILE", FT_BOOLEAN, 32, TFS(&winreg_KeyOptions_REG_OPTION_VOLATILE_tfs), ( 0x00000001 ), NULL, HFILL }},
4902         { &hf_winreg_winreg_QueryMultipleValues2_num_values,
4903                 { "Num Values", "winreg.winreg_QueryMultipleValues2.num_values", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4904         { &hf_winreg_winreg_SetKeySecurity_sec_info,
4905                 { "Sec Info", "winreg.winreg_SetKeySecurity.sec_info", FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL }},
4906         { &hf_winreg_winreg_StringBuf_size,
4907                 { "Size", "winreg.winreg_StringBuf.size", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
4908         { &hf_winreg_winreg_SecBuf_sd,
4909                 { "Sd", "winreg.winreg_SecBuf.sd", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
4910         { &hf_winreg_winreg_QueryInfoKey_secdescsize,
4911                 { "Secdescsize", "winreg.winreg_QueryInfoKey.secdescsize", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4912         { &hf_winreg_winreg_NotifyChangeType_REG_NOTIFY_CHANGE_SECURITY,
4913                 { "Reg Notify Change Security", "winreg.winreg_NotifyChangeType.REG_NOTIFY_CHANGE_SECURITY", FT_BOOLEAN, 32, TFS(&winreg_NotifyChangeType_REG_NOTIFY_CHANGE_SECURITY_tfs), ( 0x00000008 ), NULL, HFILL }},
4914         { &hf_winreg_winreg_SetValue_name,
4915                 { "Name", "winreg.winreg_SetValue.name", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
4916         { &hf_winreg_winreg_RestoreKey_flags,
4917                 { "Flags", "winreg.winreg_RestoreKey.flags", FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL }},
4918         { &hf_winreg_QueryMultipleValue_ve_type,
4919                 { "Ve Type", "winreg.QueryMultipleValue.ve_type", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
4920         { &hf_winreg_winreg_CreateKey_secdesc,
4921                 { "Secdesc", "winreg.winreg_CreateKey.secdesc", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
4922         { &hf_winreg_winreg_DeleteKeyEx_reserved,
4923                 { "Reserved", "winreg.winreg_DeleteKeyEx.reserved", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4924         { &hf_winreg_winreg_InitiateSystemShutdownEx_force_apps,
4925                 { "Force Apps", "winreg.winreg_InitiateSystemShutdownEx.force_apps", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
4926         { &hf_winreg_winreg_SetValue_type,
4927                 { "Type", "winreg.winreg_SetValue.type", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
4928         { &hf_winreg_opnum,
4929                 { "Operation", "winreg.opnum", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
4930         { &hf_winreg_winreg_EnumValue_name,
4931                 { "Name", "winreg.winreg_EnumValue.name", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
4932         { &hf_winreg_winreg_LoadKey_filename,
4933                 { "Filename", "winreg.winreg_LoadKey.filename", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
4934         { &hf_winreg_winreg_AccessMask_KEY_CREATE_LINK,
4935                 { "Key Create Link", "winreg.winreg_AccessMask.KEY_CREATE_LINK", FT_BOOLEAN, 32, TFS(&winreg_AccessMask_KEY_CREATE_LINK_tfs), ( 0x00020 ), NULL, HFILL }},
4936         { &hf_winreg_winreg_DeleteValue_value,
4937                 { "Value", "winreg.winreg_DeleteValue.value", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
4938         { &hf_winreg_winreg_QueryMultipleValues2_offered,
4939                 { "Offered", "winreg.winreg_QueryMultipleValues2.offered", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4940         { &hf_winreg_winreg_QueryMultipleValues_values_in,
4941                 { "Values In", "winreg.winreg_QueryMultipleValues.values_in", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
4942         { &hf_winreg_winreg_AccessMask_KEY_NOTIFY,
4943                 { "Key Notify", "winreg.winreg_AccessMask.KEY_NOTIFY", FT_BOOLEAN, 32, TFS(&winreg_AccessMask_KEY_NOTIFY_tfs), ( 0x00010 ), NULL, HFILL }},
4944         { &hf_winreg_winreg_OpenKey_parent_handle,
4945                 { "Parent Handle", "winreg.winreg_OpenKey.parent_handle", FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL }},
4946         { &hf_winreg_winreg_QueryInfoKey_num_subkeys,
4947                 { "Num Subkeys", "winreg.winreg_QueryInfoKey.num_subkeys", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4948         { &hf_winreg_winreg_AccessMask_KEY_WOW64_32KEY,
4949                 { "Key Wow64 32key", "winreg.winreg_AccessMask.KEY_WOW64_32KEY", FT_BOOLEAN, 32, TFS(&winreg_AccessMask_KEY_WOW64_32KEY_tfs), ( 0x00200 ), NULL, HFILL }},
4950         { &hf_winreg_winreg_SaveKeyEx_sec_attrib,
4951                 { "Sec Attrib", "winreg.winreg_SaveKeyEx.sec_attrib", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
4952         { &hf_winreg_winreg_QueryInfoKey_last_changed_time,
4953                 { "Last Changed Time", "winreg.winreg_QueryInfoKey.last_changed_time", FT_ABSOLUTE_TIME, ABSOLUTE_TIME_LOCAL, NULL, 0, NULL, HFILL }},
4954         { &hf_winreg_winreg_KeyOptions_REG_OPTION_OPEN_LINK,
4955                 { "Reg Option Open Link", "winreg.winreg_KeyOptions.REG_OPTION_OPEN_LINK", FT_BOOLEAN, 32, TFS(&winreg_KeyOptions_REG_OPTION_OPEN_LINK_tfs), ( 0x00000008 ), NULL, HFILL }},
4956         { &hf_winreg_winreg_OpenHKPD_access_mask,
4957                 { "Access Mask", "winreg.winreg_OpenHKPD.access_mask", FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL }},
4958         { &hf_winreg_winreg_AbortSystemShutdown_server,
4959                 { "Server", "winreg.winreg_AbortSystemShutdown.server", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
4960         { &hf_winreg_winreg_QueryValue_type,
4961                 { "Type", "winreg.winreg_QueryValue.type", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
4962         { &hf_winreg_sd_actual_size,
4963                 { "Actual Size", "winreg.sd.actual_size", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4964         { &hf_winreg_winreg_RestoreKeyFlags_REG_FORCE_RESTORE,
4965                 { "Reg Force Restore", "winreg.winreg_RestoreKeyFlags.REG_FORCE_RESTORE", FT_BOOLEAN, 32, TFS(&winreg_RestoreKeyFlags_REG_FORCE_RESTORE_tfs), ( 0x00000008 ), NULL, HFILL }},
4966         { &hf_winreg_winreg_SecBuf_inherit,
4967                 { "Inherit", "winreg.winreg_SecBuf.inherit", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
4968         { &hf_winreg_winreg_SetValue_size,
4969                 { "Size", "winreg.winreg_SetValue.size", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4970         { &hf_winreg_winreg_SaveKey_handle,
4971                 { "Handle", "winreg.winreg_SaveKey.handle", FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL }},
4972         { &hf_winreg_winreg_NotifyChangeType_REG_NOTIFY_CHANGE_LAST_SET,
4973                 { "Reg Notify Change Last Set", "winreg.winreg_NotifyChangeType.REG_NOTIFY_CHANGE_LAST_SET", FT_BOOLEAN, 32, TFS(&winreg_NotifyChangeType_REG_NOTIFY_CHANGE_LAST_SET_tfs), ( 0x00000004 ), NULL, HFILL }},
4974         { &hf_winreg_winreg_ReplaceKey_handle,
4975                 { "Handle", "winreg.winreg_ReplaceKey.handle", FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL }},
4976         { &hf_winreg_winreg_GetVersion_version,
4977                 { "Version", "winreg.winreg_GetVersion.version", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4978         { &hf_winreg_winreg_ReplaceKey_old_file,
4979                 { "Old File", "winreg.winreg_ReplaceKey.old_file", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
4980         { &hf_winreg_winreg_AccessMask_KEY_QUERY_VALUE,
4981                 { "Key Query Value", "winreg.winreg_AccessMask.KEY_QUERY_VALUE", FT_BOOLEAN, 32, TFS(&winreg_AccessMask_KEY_QUERY_VALUE_tfs), ( 0x00001 ), NULL, HFILL }},
4982         { &hf_winreg_winreg_CreateKey_action_taken,
4983                 { "Action Taken", "winreg.winreg_CreateKey.action_taken", FT_UINT32, BASE_DEC, VALS(winreg_winreg_CreateAction_vals), 0, NULL, HFILL }},
4984         { &hf_winreg_winreg_QueryInfoKey_num_values,
4985                 { "Num Values", "winreg.winreg_QueryInfoKey.num_values", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4986         { &hf_winreg_winreg_RestoreKeyFlags_REG_WHOLE_HIVE_VOLATILE,
4987                 { "Reg Whole Hive Volatile", "winreg.winreg_RestoreKeyFlags.REG_WHOLE_HIVE_VOLATILE", FT_BOOLEAN, 32, TFS(&winreg_RestoreKeyFlags_REG_WHOLE_HIVE_VOLATILE_tfs), ( 0x00000001 ), NULL, HFILL }},
4988         { &hf_winreg_winreg_NotifyChangeType_REG_NOTIFY_CHANGE_NAME,
4989                 { "Reg Notify Change Name", "winreg.winreg_NotifyChangeType.REG_NOTIFY_CHANGE_NAME", FT_BOOLEAN, 32, TFS(&winreg_NotifyChangeType_REG_NOTIFY_CHANGE_NAME_tfs), ( 0x00000001 ), NULL, HFILL }},
4990         { &hf_winreg_winreg_AccessMask_KEY_SET_VALUE,
4991                 { "Key Set Value", "winreg.winreg_AccessMask.KEY_SET_VALUE", FT_BOOLEAN, 32, TFS(&winreg_AccessMask_KEY_SET_VALUE_tfs), ( 0x00002 ), NULL, HFILL }},
4992         { &hf_winreg_winreg_EnumKey_enum_index,
4993                 { "Enum Index", "winreg.winreg_EnumKey.enum_index", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
4994         { &hf_winreg_winreg_RestoreKey_handle,
4995                 { "Handle", "winreg.winreg_RestoreKey.handle", FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL }},
4996         { &hf_winreg_winreg_SetValue_data,
4997                 { "Data", "winreg.winreg_SetValue.data", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
4998         { &hf_winreg_winreg_InitiateSystemShutdown_force_apps,
4999                 { "Force Apps", "winreg.winreg_InitiateSystemShutdown.force_apps", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
5000         { &hf_winreg_winreg_NotifyChangeKeyValue_string1,
5001                 { "String1", "winreg.winreg_NotifyChangeKeyValue.string1", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5002         { &hf_winreg_winreg_SaveKeyEx_flags,
5003                 { "Flags", "winreg.winreg_SaveKeyEx.flags", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5004         { &hf_winreg_winreg_QueryMultipleValues_buffer,
5005                 { "Buffer", "winreg.winreg_QueryMultipleValues.buffer", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
5006         { &hf_winreg_winreg_QueryInfoKey_classname,
5007                 { "Classname", "winreg.winreg_QueryInfoKey.classname", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5008         { &hf_winreg_winreg_AccessMask_KEY_WOW64_64KEY,
5009                 { "Key Wow64 64key", "winreg.winreg_AccessMask.KEY_WOW64_64KEY", FT_BOOLEAN, 32, TFS(&winreg_AccessMask_KEY_WOW64_64KEY_tfs), ( 0x00100 ), NULL, HFILL }},
5010         { &hf_winreg_winreg_ReplaceKey_subkey,
5011                 { "Subkey", "winreg.winreg_ReplaceKey.subkey", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5012         { &hf_winreg_sd_max_size,
5013                 { "Max Size", "winreg.sd.max_size", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5014         { &hf_winreg_winreg_QueryInfoKey_max_classlen,
5015                 { "Max Classlen", "winreg.winreg_QueryInfoKey.max_classlen", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5016         { &hf_winreg_winreg_ValNameBuf_length,
5017                 { "Length", "winreg.winreg_ValNameBuf.length", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
5018         { &hf_winreg_winreg_NotifyChangeKeyValue_notify_filter,
5019                 { "Notify Filter", "winreg.winreg_NotifyChangeKeyValue.notify_filter", FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL }},
5020         { &hf_winreg_winreg_UnLoadKey_subkey,
5021                 { "Subkey", "winreg.winreg_UnLoadKey.subkey", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5022         { &hf_winreg_winreg_ReplaceKey_new_file,
5023                 { "New File", "winreg.winreg_ReplaceKey.new_file", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5024         { &hf_winreg_winreg_SaveKeyEx_filename,
5025                 { "Filename", "winreg.winreg_SaveKeyEx.filename", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5026         { &hf_winreg_QueryMultipleValue_ve_valuename,
5027                 { "Ve Valuename", "winreg.QueryMultipleValue.ve_valuename", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
5028         { &hf_winreg_winreg_QueryMultipleValues2_key_handle,
5029                 { "Key Handle", "winreg.winreg_QueryMultipleValues2.key_handle", FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL }},
5030         { &hf_winreg_KeySecurityData_size,
5031                 { "Size", "winreg.KeySecurityData.size", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5032         { &hf_winreg_winreg_KeyOptions_REG_OPTION_BACKUP_RESTORE,
5033                 { "Reg Option Backup Restore", "winreg.winreg_KeyOptions.REG_OPTION_BACKUP_RESTORE", FT_BOOLEAN, 32, TFS(&winreg_KeyOptions_REG_OPTION_BACKUP_RESTORE_tfs), ( 0x00000004 ), NULL, HFILL }},
5034         { &hf_winreg_winreg_EnumKey_name,
5035                 { "Name", "winreg.winreg_EnumKey.name", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
5036         { &hf_winreg_winreg_LoadKey_keyname,
5037                 { "Keyname", "winreg.winreg_LoadKey.keyname", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5038         { &hf_winreg_winreg_QueryMultipleValues_key_handle,
5039                 { "Key Handle", "winreg.winreg_QueryMultipleValues.key_handle", FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL }},
5040         { &hf_winreg_winreg_EnumValue_type,
5041                 { "Type", "winreg.winreg_EnumValue.type", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
5042         { &hf_winreg_winreg_EnumKey_last_changed_time,
5043                 { "Last Changed Time", "winreg.winreg_EnumKey.last_changed_time", FT_ABSOLUTE_TIME, ABSOLUTE_TIME_LOCAL, NULL, 0, NULL, HFILL }},
5044         { &hf_winreg_winreg_EnumValue_size,
5045                 { "Size", "winreg.winreg_EnumValue.size", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5046         { &hf_winreg_winreg_SaveKey_sec_attrib,
5047                 { "Sec Attrib", "winreg.winreg_SaveKey.sec_attrib", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
5048         { &hf_winreg_sd,
5049                 { "KeySecurityData", "winreg.sd", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
5050         { &hf_winreg_winreg_KeyOptions_REG_OPTION_CREATE_LINK,
5051                 { "Reg Option Create Link", "winreg.winreg_KeyOptions.REG_OPTION_CREATE_LINK", FT_BOOLEAN, 32, TFS(&winreg_KeyOptions_REG_OPTION_CREATE_LINK_tfs), ( 0x00000002 ), NULL, HFILL }},
5052         { &hf_winreg_winreg_OpenKey_options,
5053                 { "Options", "winreg.winreg_OpenKey.options", FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL }},
5054         { &hf_winreg_winreg_SaveKey_filename,
5055                 { "Filename", "winreg.winreg_SaveKey.filename", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5056         { &hf_winreg_winreg_QueryValue_data,
5057                 { "Data", "winreg.winreg_QueryValue.data", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
5058         { &hf_winreg_winreg_QueryMultipleValues2_buffer,
5059                 { "Buffer", "winreg.winreg_QueryMultipleValues2.buffer", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
5060         { &hf_winreg_winreg_InitiateSystemShutdown_hostname,
5061                 { "Hostname", "winreg.winreg_InitiateSystemShutdown.hostname", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
5062         { &hf_winreg_winreg_UnLoadKey_handle,
5063                 { "Handle", "winreg.winreg_UnLoadKey.handle", FT_BYTES, BASE_NONE, NULL, 0, NULL, HFILL }},
5064         { &hf_winreg_winreg_QueryMultipleValues_values_out,
5065                 { "Values Out", "winreg.winreg_QueryMultipleValues.values_out", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
5066         { &hf_winreg_KeySecurityData_data,
5067                 { "Data", "winreg.KeySecurityData.data", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
5068         { &hf_winreg_winreg_OpenKey_access_mask,
5069                 { "Access Mask", "winreg.winreg_OpenKey.access_mask", FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL }},
5070         { &hf_winreg_winreg_OpenKey_keyname,
5071                 { "Keyname", "winreg.winreg_OpenKey.keyname", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5072         { &hf_winreg_winreg_InitiateSystemShutdownEx_do_reboot,
5073                 { "Do Reboot", "winreg.winreg_InitiateSystemShutdownEx.do_reboot", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
5074         { &hf_winreg_winreg_NotifyChangeKeyValue_watch_subtree,
5075                 { "Watch Subtree", "winreg.winreg_NotifyChangeKeyValue.watch_subtree", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
5076         { &hf_winreg_winreg_DeleteKeyEx_access_mask,
5077                 { "Access Mask", "winreg.winreg_DeleteKeyEx.access_mask", FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL }},
5078         { &hf_winreg_winreg_DeleteKeyEx_key,
5079                 { "Key", "winreg.winreg_DeleteKeyEx.key", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5080         { &hf_winreg_winreg_QueryValue_data_length,
5081                 { "Data Length", "winreg.winreg_QueryValue.data_length", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5082         { &hf_winreg_KeySecurityData_len,
5083                 { "Len", "winreg.KeySecurityData.len", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5084         { &hf_winreg_winreg_ValNameBuf_size,
5085                 { "Size", "winreg.winreg_ValNameBuf.size", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
5086         { &hf_winreg_winreg_CreateKey_name,
5087                 { "Name", "winreg.winreg_CreateKey.name", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5088         { &hf_winreg_winreg_NotifyChangeType_REG_NOTIFY_CHANGE_ATTRIBUTES,
5089                 { "Reg Notify Change Attributes", "winreg.winreg_NotifyChangeType.REG_NOTIFY_CHANGE_ATTRIBUTES", FT_BOOLEAN, 32, TFS(&winreg_NotifyChangeType_REG_NOTIFY_CHANGE_ATTRIBUTES_tfs), ( 0x00000002 ), NULL, HFILL }},
5090         { &hf_winreg_winreg_String_name_len,
5091                 { "Name Len", "winreg.winreg_String.name_len", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
5092         { &hf_winreg_winreg_DeleteKey_key,
5093                 { "Key", "winreg.winreg_DeleteKey.key", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5094         { &hf_winreg_winreg_QueryValue_data_size,
5095                 { "Data Size", "winreg.winreg_QueryValue.data_size", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5096         { &hf_winreg_system_name,
5097                 { "System Name", "winreg.system_name", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
5098         { &hf_winreg_QueryMultipleValue_ve_valueptr,
5099                 { "Ve Valueptr", "winreg.QueryMultipleValue.ve_valueptr", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5100         { &hf_winreg_KeySecurityAttribute_data_size,
5101                 { "Data Size", "winreg.KeySecurityAttribute.data_size", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5102         { &hf_winreg_winreg_QueryMultipleValues_num_values,
5103                 { "Num Values", "winreg.winreg_QueryMultipleValues.num_values", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5104         { &hf_winreg_winreg_StringBuf_name,
5105                 { "Name", "winreg.winreg_StringBuf.name", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
5106         { &hf_winreg_winreg_NotifyChangeKeyValue_unknown2,
5107                 { "Unknown2", "winreg.winreg_NotifyChangeKeyValue.unknown2", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5108         { &hf_winreg_sd_offset,
5109                 { "Offset", "winreg.sd.offset", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5110         { &hf_winreg_winreg_ValNameBuf_name,
5111                 { "Name", "winreg.winreg_ValNameBuf.name", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
5112         { &hf_winreg_winreg_StringBuf_length,
5113                 { "Length", "winreg.winreg_StringBuf.length", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
5114         { &hf_winreg_winreg_QueryMultipleValues2_values_in,
5115                 { "Values In", "winreg.winreg_QueryMultipleValues2.values_in", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
5116         { &hf_winreg_winreg_String_name_size,
5117                 { "Name Size", "winreg.winreg_String.name_size", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
5118         { &hf_winreg_winreg_NotifyChangeKeyValue_unknown,
5119                 { "Unknown", "winreg.winreg_NotifyChangeKeyValue.unknown", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5120         { &hf_winreg_winreg_AccessMask_KEY_CREATE_SUB_KEY,
5121                 { "Key Create Sub Key", "winreg.winreg_AccessMask.KEY_CREATE_SUB_KEY", FT_BOOLEAN, 32, TFS(&winreg_AccessMask_KEY_CREATE_SUB_KEY_tfs), ( 0x00004 ), NULL, HFILL }},
5122         { &hf_winreg_winreg_RestoreKey_filename,
5123                 { "Filename", "winreg.winreg_RestoreKey.filename", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5124         { &hf_winreg_winreg_RestoreKeyFlags_REG_REFRESH_HIVE,
5125                 { "Reg Refresh Hive", "winreg.winreg_RestoreKeyFlags.REG_REFRESH_HIVE", FT_BOOLEAN, 32, TFS(&winreg_RestoreKeyFlags_REG_REFRESH_HIVE_tfs), ( 0x00000002 ), NULL, HFILL }},
5126         { &hf_winreg_winreg_QueryInfoKey_max_valbufsize,
5127                 { "Max Valbufsize", "winreg.winreg_QueryInfoKey.max_valbufsize", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5128         { &hf_winreg_winreg_InitiateSystemShutdownEx_reason,
5129                 { "Reason", "winreg.winreg_InitiateSystemShutdownEx.reason", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5130         { &hf_winreg_winreg_EnumValue_length,
5131                 { "Length", "winreg.winreg_EnumValue.length", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5132         { &hf_winreg_winreg_QueryInfoKey_max_subkeylen,
5133                 { "Max Subkeylen", "winreg.winreg_QueryInfoKey.max_subkeylen", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5134         { &hf_winreg_winreg_InitiateSystemShutdown_timeout,
5135                 { "Timeout", "winreg.winreg_InitiateSystemShutdown.timeout", FT_UINT32, BASE_DEC, NULL, 0, NULL, HFILL }},
5136         { &hf_winreg_winreg_InitiateSystemShutdownEx_hostname,
5137                 { "Hostname", "winreg.winreg_InitiateSystemShutdownEx.hostname", FT_UINT16, BASE_DEC, NULL, 0, NULL, HFILL }},
5138         { &hf_winreg_KeySecurityAttribute_inherit,
5139                 { "Inherit", "winreg.KeySecurityAttribute.inherit", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
5140         { &hf_winreg_werror,
5141                 { "Windows Error", "winreg.werror", FT_UINT32, BASE_HEX, VALS(WERR_errors), 0, NULL, HFILL }},
5142         { &hf_winreg_winreg_QueryMultipleValues2_values_out,
5143                 { "Values Out", "winreg.winreg_QueryMultipleValues2.values_out", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
5144         { &hf_winreg_winreg_EnumKey_keyclass,
5145                 { "Keyclass", "winreg.winreg_EnumKey.keyclass", FT_NONE, BASE_NONE, NULL, 0, NULL, HFILL }},
5146         { &hf_winreg_winreg_CreateKey_keyclass,
5147                 { "Keyclass", "winreg.winreg_CreateKey.keyclass", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5148         { &hf_winreg_winreg_EnumValue_value,
5149                 { "Value", "winreg.winreg_EnumValue.value", FT_UINT8, BASE_DEC, NULL, 0, NULL, HFILL }},
5150         { &hf_winreg_winreg_OpenHKCU_access_mask,
5151                 { "Access Mask", "winreg.winreg_OpenHKCU.access_mask", FT_UINT32, BASE_HEX, NULL, 0, NULL, HFILL }},
5152         { &hf_winreg_winreg_QueryValue_value_name,
5153                 { "Value Name", "winreg.winreg_QueryValue.value_name", FT_STRING, BASE_NONE, NULL, 0, NULL, HFILL }},
5154         { &hf_winreg_winreg_RestoreKeyFlags_REG_NO_LAZY_FLUSH,
5155                 { "Reg No Lazy Flush", "winreg.winreg_RestoreKeyFlags.REG_NO_LAZY_FLUSH", FT_BOOLEAN, 32, TFS(&winreg_RestoreKeyFlags_REG_NO_LAZY_FLUSH_tfs), ( 0x00000004 ), NULL, HFILL }},
5156         };
5157
5158
5159         static gint *ett[] = {
5160                 &ett_dcerpc_winreg,
5161                 &ett_winreg_security_secinfo,
5162                 &ett_winreg_winreg_AccessMask,
5163                 &ett_winreg_winreg_String,
5164                 &ett_winreg_KeySecurityData,
5165                 &ett_winreg_winreg_SecBuf,
5166                 &ett_winreg_winreg_KeyOptions,
5167                 &ett_winreg_winreg_StringBuf,
5168                 &ett_winreg_winreg_ValNameBuf,
5169                 &ett_winreg_winreg_NotifyChangeType,
5170                 &ett_winreg_winreg_RestoreKeyFlags,
5171                 &ett_winreg_KeySecurityAttribute,
5172                 &ett_winreg_QueryMultipleValue,
5173         };
5174
5175         proto_dcerpc_winreg = proto_register_protocol("Remote Registry Service", "WINREG", "winreg");
5176         proto_register_field_array(proto_dcerpc_winreg, hf, array_length (hf));
5177         proto_register_subtree_array(ett, array_length(ett));
5178 }
5179
5180 void proto_reg_handoff_dcerpc_winreg(void)
5181 {
5182         dcerpc_init_uuid(proto_dcerpc_winreg, ett_dcerpc_winreg,
5183                 &uuid_dcerpc_winreg, ver_dcerpc_winreg,
5184                 winreg_dissectors, hf_winreg_opnum);
5185 }