diff options
author | Jörg Mayer <jmayer@loplof.de> | 2005-09-16 08:55:51 +0000 |
---|---|---|
committer | Jörg Mayer <jmayer@loplof.de> | 2005-09-16 08:55:51 +0000 |
commit | f6264ee8d2c343d608aa21f7a9c2351a7769eb28 (patch) | |
tree | aa1953c89874a908b47efd8c41ad606108f7f863 /epan | |
parent | 22b16cde93a7fa72e58411dcbd08ad0bdb604842 (diff) |
Move the packet-dcerpc-*.[hc] from pidl/ back to dissectors.
This makes Ethereal build again - there's no real reason that
ethereal fails to build for such a long time on so many platforms.
svn path=/trunk/; revision=15835
Diffstat (limited to 'epan')
-rw-r--r-- | epan/dissectors/Makefile.common | 12 | ||||
-rw-r--r-- | epan/dissectors/packet-dcerpc-atsvc.c | 1506 | ||||
-rw-r--r-- | epan/dissectors/packet-dcerpc-atsvc.h | 23 | ||||
-rw-r--r-- | epan/dissectors/packet-dcerpc-initshutdown.c | 489 | ||||
-rw-r--r-- | epan/dissectors/packet-dcerpc-initshutdown.h | 19 | ||||
-rw-r--r-- | epan/dissectors/packet-dcerpc-winreg.c | 3588 | ||||
-rw-r--r-- | epan/dissectors/packet-dcerpc-winreg.h | 45 |
7 files changed, 5676 insertions, 6 deletions
diff --git a/epan/dissectors/Makefile.common b/epan/dissectors/Makefile.common index e375829cc9..7fc3e122b9 100644 --- a/epan/dissectors/Makefile.common +++ b/epan/dissectors/Makefile.common @@ -48,14 +48,14 @@ GENERATED_FILES = $(GENERATED_HEADER_FILES) $(GENERATED_C_FILES) # pidl dissectors PIDL_DISSECTOR_SRC = \ - pidl/packet-dcerpc-atsvc.c \ - pidl/packet-dcerpc-initshutdown.c \ - pidl/packet-dcerpc-winreg.c + packet-dcerpc-atsvc.c \ + packet-dcerpc-initshutdown.c \ + packet-dcerpc-winreg.c PIDL_DISSECTOR_INCLUDES = \ - pidl/packet-dcerpc-atsvc.h \ - pidl/packet-dcerpc-initshutdown.h \ - pidl/packet-dcerpc-winreg.h + packet-dcerpc-atsvc.h \ + packet-dcerpc-initshutdown.h \ + packet-dcerpc-winreg.h # the dissector sources (without any helpers) DISSECTOR_SRC = \ diff --git a/epan/dissectors/packet-dcerpc-atsvc.c b/epan/dissectors/packet-dcerpc-atsvc.c new file mode 100644 index 0000000000..4092413ee9 --- /dev/null +++ b/epan/dissectors/packet-dcerpc-atsvc.c @@ -0,0 +1,1506 @@ +/* DO NOT EDIT + This filter was automatically generated + from atsvc.idl and atsvc.cnf. + + Pidl is a perl based IDL compiler for DCE/RPC idl files. + It is maintained by the Samba team, not the Ethereal team. + Instructions on how to download and install Pidl can be + found at http://wiki.ethereal.com/Pidl +*/ + + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include <glib.h> +#include <string.h> +#include <epan/packet.h> + +#include "packet-dcerpc.h" +#include "packet-dcerpc-nt.h" +#include "packet-windows-common.h" +#include "packet-dcerpc-atsvc.h" + +/* Ett declarations */ +static gint ett_dcerpc_atsvc = -1; +static gint ett_atsvc_atsvc_DaysOfMonth = -1; +static gint ett_atsvc_atsvc_Flags = -1; +static gint ett_atsvc_atsvc_DaysOfWeek = -1; +static gint ett_atsvc_atsvc_JobInfo = -1; +static gint ett_atsvc_atsvc_JobEnumInfo = -1; +static gint ett_atsvc_atsvc_enum_ctr = -1; + + +/* Header field declarations */ +static gint hf_atsvc_atsvc_JobEnumInfo_days_of_month = -1; +static gint hf_atsvc_atsvc_JobEnum_resume_handle = -1; +static gint hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_THURSDAY = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Eight = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Third = -1; +static gint hf_atsvc_atsvc_JobInfo_days_of_week = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Twentyseventh = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Twentyth = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Seventeenth = -1; +static gint hf_atsvc_atsvc_Flags_JOB_RUN_PERIODICALLY = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Fifth = -1; +static gint hf_atsvc_job_info = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Thitteenth = -1; +static gint hf_atsvc_atsvc_enum_ctr_entries_read = -1; +static gint hf_atsvc_atsvc_enum_ctr_first_entry = -1; +static gint hf_atsvc_atsvc_Flags_JOB_EXEC_ERROR = -1; +static gint hf_atsvc_atsvc_Flags_JOB_NONINTERACTIVE = -1; +static gint hf_atsvc_opnum = -1; +static gint hf_atsvc_atsvc_Flags_JOB_RUNS_TODAY = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Eighteenth = -1; +static gint hf_atsvc_job_id = -1; +static gint hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_SATURDAY = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Ninteenth = -1; +static gint hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_MONDAY = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Twentysecond = -1; +static gint hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_FRIDAY = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Second = -1; +static gint hf_atsvc_status = -1; +static gint hf_atsvc_atsvc_JobEnum_ctr = -1; +static gint hf_atsvc_atsvc_JobInfo_command = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Sixteenth = -1; +static gint hf_atsvc_atsvc_JobEnumInfo_command = -1; +static gint hf_atsvc_atsvc_Flags_JOB_ADD_CURRENT_DATE = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Thirtyfirst = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Fourth = -1; +static gint hf_atsvc_atsvc_JobEnumInfo_days_of_week = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_First = -1; +static gint hf_atsvc_atsvc_JobEnumInfo_job_time = -1; +static gint hf_atsvc_atsvc_JobEnum_total_entries = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Twentyninth = -1; +static gint hf_atsvc_atsvc_JobDel_max_job_id = -1; +static gint hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_TUESDAY = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Twentythird = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Fifteenth = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Twentyeighth = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Twelfth = -1; +static gint hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_WEDNESDAY = -1; +static gint hf_atsvc_atsvc_JobInfo_flags = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Seventh = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Twentyfirst = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Tenth = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Fourteenth = -1; +static gint hf_atsvc_atsvc_JobEnum_preferred_max_len = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Twentyfourth = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Twentyfifth = -1; +static gint hf_atsvc_servername = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Thirtieth = -1; +static gint hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_SUNDAY = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Sixth = -1; +static gint hf_atsvc_atsvc_JobDel_min_job_id = -1; +static gint hf_atsvc_atsvc_JobInfo_job_time = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Ninth = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Eleventh = -1; +static gint hf_atsvc_atsvc_DaysOfMonth_Twentysixth = -1; +static gint hf_atsvc_atsvc_JobInfo_days_of_month = -1; +static gint hf_atsvc_atsvc_JobEnumInfo_flags = -1; + +static gint proto_dcerpc_atsvc = -1; +/* Version information */ + + +static e_uuid_t uuid_dcerpc_atsvc = { + 0x1ff70682, 0x0a51, 0x30e8, + { 0x07, 0x6d, 0x74, 0x0b, 0xe8, 0xce, 0xe9, 0x8b } +}; +static guint16 ver_dcerpc_atsvc = 1; + +static const true_false_string atsvc_DaysOfMonth_First_tfs = { + "First is SET", + "First is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Second_tfs = { + "Second is SET", + "Second is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Third_tfs = { + "Third is SET", + "Third is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Fourth_tfs = { + "Fourth is SET", + "Fourth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Fifth_tfs = { + "Fifth is SET", + "Fifth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Sixth_tfs = { + "Sixth is SET", + "Sixth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Seventh_tfs = { + "Seventh is SET", + "Seventh is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Eight_tfs = { + "Eight is SET", + "Eight is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Ninth_tfs = { + "Ninth is SET", + "Ninth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Tenth_tfs = { + "Tenth is SET", + "Tenth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Eleventh_tfs = { + "Eleventh is SET", + "Eleventh is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Twelfth_tfs = { + "Twelfth is SET", + "Twelfth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Thitteenth_tfs = { + "Thitteenth is SET", + "Thitteenth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Fourteenth_tfs = { + "Fourteenth is SET", + "Fourteenth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Fifteenth_tfs = { + "Fifteenth is SET", + "Fifteenth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Sixteenth_tfs = { + "Sixteenth is SET", + "Sixteenth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Seventeenth_tfs = { + "Seventeenth is SET", + "Seventeenth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Eighteenth_tfs = { + "Eighteenth is SET", + "Eighteenth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Ninteenth_tfs = { + "Ninteenth is SET", + "Ninteenth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Twentyth_tfs = { + "Twentyth is SET", + "Twentyth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Twentyfirst_tfs = { + "Twentyfirst is SET", + "Twentyfirst is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Twentysecond_tfs = { + "Twentysecond is SET", + "Twentysecond is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Twentythird_tfs = { + "Twentythird is SET", + "Twentythird is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Twentyfourth_tfs = { + "Twentyfourth is SET", + "Twentyfourth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Twentyfifth_tfs = { + "Twentyfifth is SET", + "Twentyfifth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Twentysixth_tfs = { + "Twentysixth is SET", + "Twentysixth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Twentyseventh_tfs = { + "Twentyseventh is SET", + "Twentyseventh is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Twentyeighth_tfs = { + "Twentyeighth is SET", + "Twentyeighth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Twentyninth_tfs = { + "Twentyninth is SET", + "Twentyninth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Thirtieth_tfs = { + "Thirtieth is SET", + "Thirtieth is NOT SET", +}; +static const true_false_string atsvc_DaysOfMonth_Thirtyfirst_tfs = { + "Thirtyfirst is SET", + "Thirtyfirst is NOT SET", +}; +static const true_false_string atsvc_Flags_JOB_RUN_PERIODICALLY_tfs = { + "JOB_RUN_PERIODICALLY is SET", + "JOB_RUN_PERIODICALLY is NOT SET", +}; +static const true_false_string atsvc_Flags_JOB_EXEC_ERROR_tfs = { + "JOB_EXEC_ERROR is SET", + "JOB_EXEC_ERROR is NOT SET", +}; +static const true_false_string atsvc_Flags_JOB_RUNS_TODAY_tfs = { + "JOB_RUNS_TODAY is SET", + "JOB_RUNS_TODAY is NOT SET", +}; +static const true_false_string atsvc_Flags_JOB_ADD_CURRENT_DATE_tfs = { + "JOB_ADD_CURRENT_DATE is SET", + "JOB_ADD_CURRENT_DATE is NOT SET", +}; +static const true_false_string atsvc_Flags_JOB_NONINTERACTIVE_tfs = { + "JOB_NONINTERACTIVE is SET", + "JOB_NONINTERACTIVE is NOT SET", +}; +static const true_false_string atsvc_DaysOfWeek_DAYSOFWEEK_MONDAY_tfs = { + "DAYSOFWEEK_MONDAY is SET", + "DAYSOFWEEK_MONDAY is NOT SET", +}; +static const true_false_string atsvc_DaysOfWeek_DAYSOFWEEK_TUESDAY_tfs = { + "DAYSOFWEEK_TUESDAY is SET", + "DAYSOFWEEK_TUESDAY is NOT SET", +}; +static const true_false_string atsvc_DaysOfWeek_DAYSOFWEEK_WEDNESDAY_tfs = { + "DAYSOFWEEK_WEDNESDAY is SET", + "DAYSOFWEEK_WEDNESDAY is NOT SET", +}; +static const true_false_string atsvc_DaysOfWeek_DAYSOFWEEK_THURSDAY_tfs = { + "DAYSOFWEEK_THURSDAY is SET", + "DAYSOFWEEK_THURSDAY is NOT SET", +}; +static const true_false_string atsvc_DaysOfWeek_DAYSOFWEEK_FRIDAY_tfs = { + "DAYSOFWEEK_FRIDAY is SET", + "DAYSOFWEEK_FRIDAY is NOT SET", +}; +static const true_false_string atsvc_DaysOfWeek_DAYSOFWEEK_SATURDAY_tfs = { + "DAYSOFWEEK_SATURDAY is SET", + "DAYSOFWEEK_SATURDAY is NOT SET", +}; +static const true_false_string atsvc_DaysOfWeek_DAYSOFWEEK_SUNDAY_tfs = { + "DAYSOFWEEK_SUNDAY is SET", + "DAYSOFWEEK_SUNDAY is NOT SET", +}; +static int atsvc_dissect_element_JobInfo_job_time(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobInfo_days_of_month(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobInfo_days_of_week(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobInfo_flags(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobInfo_command(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobInfo_command_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnumInfo_job_id(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnumInfo_job_time(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnumInfo_days_of_month(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnumInfo_days_of_week(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnumInfo_flags(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnumInfo_command(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnumInfo_command_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_enum_ctr_entries_read(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_enum_ctr_first_entry(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_enum_ctr_first_entry_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_enum_ctr_first_entry__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobAdd_servername(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobAdd_servername_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobAdd_job_info(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobAdd_job_info_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobAdd_job_id(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobDel_servername(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobDel_servername_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobDel_min_job_id(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobDel_max_job_id(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnum_servername(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnum_servername_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnum_ctr(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnum_ctr_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnum_preferred_max_len(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnum_total_entries(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnum_resume_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobEnum_resume_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobGetInfo_servername(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobGetInfo_servername_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobGetInfo_job_id(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobGetInfo_job_info(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int atsvc_dissect_element_JobGetInfo_job_info_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); + +/* IDL: typedef bitmap { */ +/* IDL: First = 0x00000001 , */ +/* IDL: Second = 0x00000002 , */ +/* IDL: Third = 0x00000004 , */ +/* IDL: Fourth = 0x00000008 , */ +/* IDL: Fifth = 0x00000010 , */ +/* IDL: Sixth = 0x00000020 , */ +/* IDL: Seventh = 0x00000040 , */ +/* IDL: Eight = 0x00000080 , */ +/* IDL: Ninth = 0x00000100 , */ +/* IDL: Tenth = 0x00000200 , */ +/* IDL: Eleventh = 0x00000400 , */ +/* IDL: Twelfth = 0x00000800 , */ +/* IDL: Thitteenth = 0x00001000 , */ +/* IDL: Fourteenth = 0x00002000 , */ +/* IDL: Fifteenth = 0x00004000 , */ +/* IDL: Sixteenth = 0x00008000 , */ +/* IDL: Seventeenth = 0x00010000 , */ +/* IDL: Eighteenth = 0x00020000 , */ +/* IDL: Ninteenth = 0x00040000 , */ +/* IDL: Twentyth = 0x00080000 , */ +/* IDL: Twentyfirst = 0x00100000 , */ +/* IDL: Twentysecond = 0x00200000 , */ +/* IDL: Twentythird = 0x00400000 , */ +/* IDL: Twentyfourth = 0x00800000 , */ +/* IDL: Twentyfifth = 0x01000000 , */ +/* IDL: Twentysixth = 0x02000000 , */ +/* IDL: Twentyseventh = 0x04000000 , */ +/* IDL: Twentyeighth = 0x08000000 , */ +/* IDL: Twentyninth = 0x10000000 , */ +/* IDL: Thirtieth = 0x20000000 , */ +/* IDL: Thirtyfirst = 0x40000000 , */ +/* IDL: } atsvc_DaysOfMonth; */ + +int +atsvc_dissect_bitmap_DaysOfMonth(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + + guint32 flags; + ALIGN_TO_4_BYTES; + + if(parent_tree) { + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, 4, TRUE); + tree = proto_item_add_subtree(item,ett_atsvc_atsvc_DaysOfMonth); + } + + offset = dissect_ndr_uint32(tvb, offset, pinfo, NULL, drep, -1, &flags); + proto_item_append_text(item, ": "); + + if (!flags) + proto_item_append_text(item, "(No values set)"); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_First, tvb, offset-4, 4, flags); + if (flags&( 0x00000001 )){ + proto_item_append_text(item, "First"); + if (flags & (~( 0x00000001 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00000001 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Second, tvb, offset-4, 4, flags); + if (flags&( 0x00000002 )){ + proto_item_append_text(item, "Second"); + if (flags & (~( 0x00000002 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00000002 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Third, tvb, offset-4, 4, flags); + if (flags&( 0x00000004 )){ + proto_item_append_text(item, "Third"); + if (flags & (~( 0x00000004 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00000004 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Fourth, tvb, offset-4, 4, flags); + if (flags&( 0x00000008 )){ + proto_item_append_text(item, "Fourth"); + if (flags & (~( 0x00000008 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00000008 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Fifth, tvb, offset-4, 4, flags); + if (flags&( 0x00000010 )){ + proto_item_append_text(item, "Fifth"); + if (flags & (~( 0x00000010 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00000010 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Sixth, tvb, offset-4, 4, flags); + if (flags&( 0x00000020 )){ + proto_item_append_text(item, "Sixth"); + if (flags & (~( 0x00000020 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00000020 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Seventh, tvb, offset-4, 4, flags); + if (flags&( 0x00000040 )){ + proto_item_append_text(item, "Seventh"); + if (flags & (~( 0x00000040 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00000040 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Eight, tvb, offset-4, 4, flags); + if (flags&( 0x00000080 )){ + proto_item_append_text(item, "Eight"); + if (flags & (~( 0x00000080 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00000080 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Ninth, tvb, offset-4, 4, flags); + if (flags&( 0x00000100 )){ + proto_item_append_text(item, "Ninth"); + if (flags & (~( 0x00000100 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00000100 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Tenth, tvb, offset-4, 4, flags); + if (flags&( 0x00000200 )){ + proto_item_append_text(item, "Tenth"); + if (flags & (~( 0x00000200 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00000200 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Eleventh, tvb, offset-4, 4, flags); + if (flags&( 0x00000400 )){ + proto_item_append_text(item, "Eleventh"); + if (flags & (~( 0x00000400 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00000400 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Twelfth, tvb, offset-4, 4, flags); + if (flags&( 0x00000800 )){ + proto_item_append_text(item, "Twelfth"); + if (flags & (~( 0x00000800 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00000800 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Thitteenth, tvb, offset-4, 4, flags); + if (flags&( 0x00001000 )){ + proto_item_append_text(item, "Thitteenth"); + if (flags & (~( 0x00001000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00001000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Fourteenth, tvb, offset-4, 4, flags); + if (flags&( 0x00002000 )){ + proto_item_append_text(item, "Fourteenth"); + if (flags & (~( 0x00002000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00002000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Fifteenth, tvb, offset-4, 4, flags); + if (flags&( 0x00004000 )){ + proto_item_append_text(item, "Fifteenth"); + if (flags & (~( 0x00004000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00004000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Sixteenth, tvb, offset-4, 4, flags); + if (flags&( 0x00008000 )){ + proto_item_append_text(item, "Sixteenth"); + if (flags & (~( 0x00008000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00008000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Seventeenth, tvb, offset-4, 4, flags); + if (flags&( 0x00010000 )){ + proto_item_append_text(item, "Seventeenth"); + if (flags & (~( 0x00010000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00010000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Eighteenth, tvb, offset-4, 4, flags); + if (flags&( 0x00020000 )){ + proto_item_append_text(item, "Eighteenth"); + if (flags & (~( 0x00020000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00020000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Ninteenth, tvb, offset-4, 4, flags); + if (flags&( 0x00040000 )){ + proto_item_append_text(item, "Ninteenth"); + if (flags & (~( 0x00040000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00040000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Twentyth, tvb, offset-4, 4, flags); + if (flags&( 0x00080000 )){ + proto_item_append_text(item, "Twentyth"); + if (flags & (~( 0x00080000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00080000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Twentyfirst, tvb, offset-4, 4, flags); + if (flags&( 0x00100000 )){ + proto_item_append_text(item, "Twentyfirst"); + if (flags & (~( 0x00100000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00100000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Twentysecond, tvb, offset-4, 4, flags); + if (flags&( 0x00200000 )){ + proto_item_append_text(item, "Twentysecond"); + if (flags & (~( 0x00200000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00200000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Twentythird, tvb, offset-4, 4, flags); + if (flags&( 0x00400000 )){ + proto_item_append_text(item, "Twentythird"); + if (flags & (~( 0x00400000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00400000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Twentyfourth, tvb, offset-4, 4, flags); + if (flags&( 0x00800000 )){ + proto_item_append_text(item, "Twentyfourth"); + if (flags & (~( 0x00800000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x00800000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Twentyfifth, tvb, offset-4, 4, flags); + if (flags&( 0x01000000 )){ + proto_item_append_text(item, "Twentyfifth"); + if (flags & (~( 0x01000000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x01000000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Twentysixth, tvb, offset-4, 4, flags); + if (flags&( 0x02000000 )){ + proto_item_append_text(item, "Twentysixth"); + if (flags & (~( 0x02000000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x02000000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Twentyseventh, tvb, offset-4, 4, flags); + if (flags&( 0x04000000 )){ + proto_item_append_text(item, "Twentyseventh"); + if (flags & (~( 0x04000000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x04000000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Twentyeighth, tvb, offset-4, 4, flags); + if (flags&( 0x08000000 )){ + proto_item_append_text(item, "Twentyeighth"); + if (flags & (~( 0x08000000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x08000000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Twentyninth, tvb, offset-4, 4, flags); + if (flags&( 0x10000000 )){ + proto_item_append_text(item, "Twentyninth"); + if (flags & (~( 0x10000000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x10000000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Thirtieth, tvb, offset-4, 4, flags); + if (flags&( 0x20000000 )){ + proto_item_append_text(item, "Thirtieth"); + if (flags & (~( 0x20000000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x20000000 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfMonth_Thirtyfirst, tvb, offset-4, 4, flags); + if (flags&( 0x40000000 )){ + proto_item_append_text(item, "Thirtyfirst"); + if (flags & (~( 0x40000000 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x40000000 )); + + if(flags){ + proto_item_append_text(item, "Unknown bitmap value 0x%x", flags); + } + + return offset; +} + +/* IDL: typedef bitmap { */ +/* IDL: JOB_RUN_PERIODICALLY = 0x01 , */ +/* IDL: JOB_EXEC_ERROR = 0x02 , */ +/* IDL: JOB_RUNS_TODAY = 0x04 , */ +/* IDL: JOB_ADD_CURRENT_DATE = 0x08 , */ +/* IDL: JOB_NONINTERACTIVE = 0x10 , */ +/* IDL: } atsvc_Flags; */ + +int +atsvc_dissect_bitmap_Flags(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + + guint8 flags; + + if(parent_tree) { + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, 1, TRUE); + tree = proto_item_add_subtree(item,ett_atsvc_atsvc_Flags); + } + + offset = dissect_ndr_uint8(tvb, offset, pinfo, NULL, drep, -1, &flags); + proto_item_append_text(item, ": "); + + if (!flags) + proto_item_append_text(item, "(No values set)"); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_Flags_JOB_RUN_PERIODICALLY, tvb, offset-1, 1, flags); + if (flags&( 0x01 )){ + proto_item_append_text(item, "JOB_RUN_PERIODICALLY"); + if (flags & (~( 0x01 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x01 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_Flags_JOB_EXEC_ERROR, tvb, offset-1, 1, flags); + if (flags&( 0x02 )){ + proto_item_append_text(item, "JOB_EXEC_ERROR"); + if (flags & (~( 0x02 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x02 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_Flags_JOB_RUNS_TODAY, tvb, offset-1, 1, flags); + if (flags&( 0x04 )){ + proto_item_append_text(item, "JOB_RUNS_TODAY"); + if (flags & (~( 0x04 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x04 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_Flags_JOB_ADD_CURRENT_DATE, tvb, offset-1, 1, flags); + if (flags&( 0x08 )){ + proto_item_append_text(item, "JOB_ADD_CURRENT_DATE"); + if (flags & (~( 0x08 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x08 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_Flags_JOB_NONINTERACTIVE, tvb, offset-1, 1, flags); + if (flags&( 0x10 )){ + proto_item_append_text(item, "JOB_NONINTERACTIVE"); + if (flags & (~( 0x10 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x10 )); + + if(flags){ + proto_item_append_text(item, "Unknown bitmap value 0x%x", flags); + } + + return offset; +} + +/* IDL: typedef bitmap { */ +/* IDL: DAYSOFWEEK_MONDAY = 0x01 , */ +/* IDL: DAYSOFWEEK_TUESDAY = 0x02 , */ +/* IDL: DAYSOFWEEK_WEDNESDAY = 0x04 , */ +/* IDL: DAYSOFWEEK_THURSDAY = 0x08 , */ +/* IDL: DAYSOFWEEK_FRIDAY = 0x10 , */ +/* IDL: DAYSOFWEEK_SATURDAY = 0x20 , */ +/* IDL: DAYSOFWEEK_SUNDAY = 0x40 , */ +/* IDL: } atsvc_DaysOfWeek; */ + +int +atsvc_dissect_bitmap_DaysOfWeek(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + + guint8 flags; + + if(parent_tree) { + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, 1, TRUE); + tree = proto_item_add_subtree(item,ett_atsvc_atsvc_DaysOfWeek); + } + + offset = dissect_ndr_uint8(tvb, offset, pinfo, NULL, drep, -1, &flags); + proto_item_append_text(item, ": "); + + if (!flags) + proto_item_append_text(item, "(No values set)"); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_MONDAY, tvb, offset-1, 1, flags); + if (flags&( 0x01 )){ + proto_item_append_text(item, "DAYSOFWEEK_MONDAY"); + if (flags & (~( 0x01 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x01 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_TUESDAY, tvb, offset-1, 1, flags); + if (flags&( 0x02 )){ + proto_item_append_text(item, "DAYSOFWEEK_TUESDAY"); + if (flags & (~( 0x02 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x02 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_WEDNESDAY, tvb, offset-1, 1, flags); + if (flags&( 0x04 )){ + proto_item_append_text(item, "DAYSOFWEEK_WEDNESDAY"); + if (flags & (~( 0x04 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x04 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_THURSDAY, tvb, offset-1, 1, flags); + if (flags&( 0x08 )){ + proto_item_append_text(item, "DAYSOFWEEK_THURSDAY"); + if (flags & (~( 0x08 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x08 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_FRIDAY, tvb, offset-1, 1, flags); + if (flags&( 0x10 )){ + proto_item_append_text(item, "DAYSOFWEEK_FRIDAY"); + if (flags & (~( 0x10 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x10 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_SATURDAY, tvb, offset-1, 1, flags); + if (flags&( 0x20 )){ + proto_item_append_text(item, "DAYSOFWEEK_SATURDAY"); + if (flags & (~( 0x20 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x20 )); + + proto_tree_add_boolean(tree, hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_SUNDAY, tvb, offset-1, 1, flags); + if (flags&( 0x40 )){ + proto_item_append_text(item, "DAYSOFWEEK_SUNDAY"); + if (flags & (~( 0x40 ))) + proto_item_append_text(item, ", "); + } + flags&=(~( 0x40 )); + + if(flags){ + proto_item_append_text(item, "Unknown bitmap value 0x%x", flags); + } + + return offset; +} + +/* IDL: typedef struct { */ +/* IDL: uint32 job_time; */ +/* IDL: atsvc_DaysOfMonth days_of_month; */ +/* IDL: atsvc_DaysOfWeek days_of_week; */ +/* IDL: atsvc_Flags flags; */ +/* IDL: [unique(1)] unistr *command; */ +/* IDL: } atsvc_JobInfo; */ + +static int +atsvc_dissect_element_JobInfo_job_time(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobInfo_job_time,NULL); + + return offset; +} + +static int +atsvc_dissect_element_JobInfo_days_of_month(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = atsvc_dissect_bitmap_DaysOfMonth(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobInfo_days_of_month, 0); + + return offset; +} + +static int +atsvc_dissect_element_JobInfo_days_of_week(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = atsvc_dissect_bitmap_DaysOfWeek(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobInfo_days_of_week, 0); + + return offset; +} + +static int +atsvc_dissect_element_JobInfo_flags(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = atsvc_dissect_bitmap_Flags(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobInfo_flags, 0); + + return offset; +} + +static int +atsvc_dissect_element_JobInfo_command(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, drep, atsvc_dissect_element_JobInfo_command_, NDR_POINTER_UNIQUE, "Pointer to Command (unistr)",hf_atsvc_atsvc_JobInfo_command); + + return offset; +} + +static int +atsvc_dissect_element_JobInfo_command_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + + return offset; +} + +int +atsvc_dissect_struct_JobInfo(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + int old_offset; + + ALIGN_TO_4_BYTES; + + old_offset = offset; + + if(parent_tree){ + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, TRUE); + tree = proto_item_add_subtree(item, ett_atsvc_atsvc_JobInfo); + } + + offset = atsvc_dissect_element_JobInfo_job_time(tvb, offset, pinfo, tree, drep); + + offset = atsvc_dissect_element_JobInfo_days_of_month(tvb, offset, pinfo, tree, drep); + + offset = atsvc_dissect_element_JobInfo_days_of_week(tvb, offset, pinfo, tree, drep); + + offset = atsvc_dissect_element_JobInfo_flags(tvb, offset, pinfo, tree, drep); + + offset = atsvc_dissect_element_JobInfo_command(tvb, offset, pinfo, tree, drep); + + + proto_item_set_len(item, offset-old_offset); + + return offset; +} + +/* IDL: typedef struct { */ +/* IDL: uint32 job_id; */ +/* IDL: uint32 job_time; */ +/* IDL: atsvc_DaysOfMonth days_of_month; */ +/* IDL: atsvc_DaysOfWeek days_of_week; */ +/* IDL: atsvc_Flags flags; */ +/* IDL: [unique(1)] unistr *command; */ +/* IDL: } atsvc_JobEnumInfo; */ + +static int +atsvc_dissect_element_JobEnumInfo_job_id(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_atsvc_job_id,NULL); + + return offset; +} + +static int +atsvc_dissect_element_JobEnumInfo_job_time(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobEnumInfo_job_time,NULL); + + return offset; +} + +static int +atsvc_dissect_element_JobEnumInfo_days_of_month(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = atsvc_dissect_bitmap_DaysOfMonth(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobEnumInfo_days_of_month, 0); + + return offset; +} + +static int +atsvc_dissect_element_JobEnumInfo_days_of_week(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = atsvc_dissect_bitmap_DaysOfWeek(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobEnumInfo_days_of_week, 0); + + return offset; +} + +static int +atsvc_dissect_element_JobEnumInfo_flags(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = atsvc_dissect_bitmap_Flags(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobEnumInfo_flags, 0); + + return offset; +} + +static int +atsvc_dissect_element_JobEnumInfo_command(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, drep, atsvc_dissect_element_JobEnumInfo_command_, NDR_POINTER_UNIQUE, "Pointer to Command (unistr)",hf_atsvc_atsvc_JobEnumInfo_command); + + return offset; +} + +static int +atsvc_dissect_element_JobEnumInfo_command_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + + return offset; +} + +int +atsvc_dissect_struct_JobEnumInfo(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + int old_offset; + + ALIGN_TO_4_BYTES; + + old_offset = offset; + + if(parent_tree){ + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, TRUE); + tree = proto_item_add_subtree(item, ett_atsvc_atsvc_JobEnumInfo); + } + + offset = atsvc_dissect_element_JobEnumInfo_job_id(tvb, offset, pinfo, tree, drep); + + offset = atsvc_dissect_element_JobEnumInfo_job_time(tvb, offset, pinfo, tree, drep); + + offset = atsvc_dissect_element_JobEnumInfo_days_of_month(tvb, offset, pinfo, tree, drep); + + offset = atsvc_dissect_element_JobEnumInfo_days_of_week(tvb, offset, pinfo, tree, drep); + + offset = atsvc_dissect_element_JobEnumInfo_flags(tvb, offset, pinfo, tree, drep); + + offset = atsvc_dissect_element_JobEnumInfo_command(tvb, offset, pinfo, tree, drep); + + + proto_item_set_len(item, offset-old_offset); + + return offset; +} + +/* IDL: typedef struct { */ +/* IDL: uint32 entries_read; */ +/* IDL: [unique(1)] [size_is(entries_read)] atsvc_JobEnumInfo *first_entry; */ +/* IDL: } atsvc_enum_ctr; */ + +static int +atsvc_dissect_element_enum_ctr_entries_read(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_enum_ctr_entries_read,NULL); + + return offset; +} + +static int +atsvc_dissect_element_enum_ctr_first_entry(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, drep, atsvc_dissect_element_enum_ctr_first_entry_, NDR_POINTER_UNIQUE, "Pointer to First Entry (atsvc_JobEnumInfo)",hf_atsvc_atsvc_enum_ctr_first_entry); + + return offset; +} + +static int +atsvc_dissect_element_enum_ctr_first_entry_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_ucarray(tvb, offset, pinfo, tree, drep, atsvc_dissect_element_enum_ctr_first_entry__); + + return offset; +} + +static int +atsvc_dissect_element_enum_ctr_first_entry__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = atsvc_dissect_struct_JobEnumInfo(tvb,offset,pinfo,tree,drep,hf_atsvc_atsvc_enum_ctr_first_entry,0); + + return offset; +} + +int +atsvc_dissect_struct_enum_ctr(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + int old_offset; + + ALIGN_TO_4_BYTES; + + old_offset = offset; + + if(parent_tree){ + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, TRUE); + tree = proto_item_add_subtree(item, ett_atsvc_atsvc_enum_ctr); + } + + offset = atsvc_dissect_element_enum_ctr_entries_read(tvb, offset, pinfo, tree, drep); + + offset = atsvc_dissect_element_enum_ctr_first_entry(tvb, offset, pinfo, tree, drep); + + + proto_item_set_len(item, offset-old_offset); + + return offset; +} + +static int +atsvc_dissect_element_JobAdd_servername(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, atsvc_dissect_element_JobAdd_servername_, NDR_POINTER_UNIQUE, "Pointer to Servername (unistr)",hf_atsvc_servername); + + return offset; +} + +static int +atsvc_dissect_element_JobAdd_servername_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + + return offset; +} + +static int +atsvc_dissect_element_JobAdd_job_info(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, atsvc_dissect_element_JobAdd_job_info_, NDR_POINTER_REF, "Pointer to Job Info (atsvc_JobInfo)",hf_atsvc_job_info); + + return offset; +} + +static int +atsvc_dissect_element_JobAdd_job_info_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = atsvc_dissect_struct_JobInfo(tvb,offset,pinfo,tree,drep,hf_atsvc_job_info,0); + + return offset; +} + +static int +atsvc_dissect_element_JobAdd_job_id(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_atsvc_job_id,NULL); + + return offset; +} + +/* IDL: NTSTATUS atsvc_JobAdd( */ +/* IDL: [unique(1)] [in] unistr *servername, */ +/* IDL: [in] [ref] atsvc_JobInfo *job_info, */ +/* IDL: [out] uint32 job_id */ +/* IDL: ); */ + +static int +atsvc_dissect_JobAdd_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = atsvc_dissect_element_JobAdd_job_id(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep, hf_atsvc_status, NULL); + return offset; +} + +static int +atsvc_dissect_JobAdd_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = atsvc_dissect_element_JobAdd_servername(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = atsvc_dissect_element_JobAdd_job_info(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +atsvc_dissect_element_JobDel_servername(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, atsvc_dissect_element_JobDel_servername_, NDR_POINTER_UNIQUE, "Pointer to Servername (unistr)",hf_atsvc_servername); + + return offset; +} + +static int +atsvc_dissect_element_JobDel_servername_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + + return offset; +} + +static int +atsvc_dissect_element_JobDel_min_job_id(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobDel_min_job_id,NULL); + + return offset; +} + +static int +atsvc_dissect_element_JobDel_max_job_id(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobDel_max_job_id,NULL); + + return offset; +} + +/* IDL: NTSTATUS atsvc_JobDel( */ +/* IDL: [unique(1)] [in] unistr *servername, */ +/* IDL: [in] uint32 min_job_id, */ +/* IDL: [in] uint32 max_job_id */ +/* IDL: ); */ + +static int +atsvc_dissect_JobDel_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep, hf_atsvc_status, NULL); + return offset; +} + +static int +atsvc_dissect_JobDel_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = atsvc_dissect_element_JobDel_servername(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = atsvc_dissect_element_JobDel_min_job_id(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = atsvc_dissect_element_JobDel_max_job_id(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +atsvc_dissect_element_JobEnum_servername(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, atsvc_dissect_element_JobEnum_servername_, NDR_POINTER_UNIQUE, "Pointer to Servername (unistr)",hf_atsvc_servername); + + return offset; +} + +static int +atsvc_dissect_element_JobEnum_servername_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + + return offset; +} + +static int +atsvc_dissect_element_JobEnum_ctr(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, atsvc_dissect_element_JobEnum_ctr_, NDR_POINTER_REF, "Pointer to Ctr (atsvc_enum_ctr)",hf_atsvc_atsvc_JobEnum_ctr); + + return offset; +} + +static int +atsvc_dissect_element_JobEnum_ctr_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = atsvc_dissect_struct_enum_ctr(tvb,offset,pinfo,tree,drep,hf_atsvc_atsvc_JobEnum_ctr,0); + + return offset; +} + +static int +atsvc_dissect_element_JobEnum_preferred_max_len(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobEnum_preferred_max_len,NULL); + + return offset; +} + +static int +atsvc_dissect_element_JobEnum_total_entries(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobEnum_total_entries,NULL); + + return offset; +} + +static int +atsvc_dissect_element_JobEnum_resume_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, atsvc_dissect_element_JobEnum_resume_handle_, NDR_POINTER_UNIQUE, "Pointer to Resume Handle (uint32)",hf_atsvc_atsvc_JobEnum_resume_handle); + + return offset; +} + +static int +atsvc_dissect_element_JobEnum_resume_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_atsvc_atsvc_JobEnum_resume_handle,NULL); + + return offset; +} + +/* IDL: NTSTATUS atsvc_JobEnum( */ +/* IDL: [unique(1)] [in] unistr *servername, */ +/* IDL: [out] [in] [ref] atsvc_enum_ctr *ctr, */ +/* IDL: [in] uint32 preferred_max_len, */ +/* IDL: [out] uint32 total_entries, */ +/* IDL: [unique(1)] [out] [in] uint32 *resume_handle */ +/* IDL: ); */ + +static int +atsvc_dissect_JobEnum_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = atsvc_dissect_element_JobEnum_ctr(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = atsvc_dissect_element_JobEnum_total_entries(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = atsvc_dissect_element_JobEnum_resume_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep, hf_atsvc_status, NULL); + return offset; +} + +static int +atsvc_dissect_JobEnum_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = atsvc_dissect_element_JobEnum_servername(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = atsvc_dissect_element_JobEnum_ctr(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = atsvc_dissect_element_JobEnum_preferred_max_len(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = atsvc_dissect_element_JobEnum_resume_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +atsvc_dissect_element_JobGetInfo_servername(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, atsvc_dissect_element_JobGetInfo_servername_, NDR_POINTER_UNIQUE, "Pointer to Servername (unistr)",hf_atsvc_servername); + + return offset; +} + +static int +atsvc_dissect_element_JobGetInfo_servername_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + + return offset; +} + +static int +atsvc_dissect_element_JobGetInfo_job_id(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_atsvc_job_id,NULL); + + return offset; +} + +static int +atsvc_dissect_element_JobGetInfo_job_info(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, atsvc_dissect_element_JobGetInfo_job_info_, NDR_POINTER_UNIQUE, "Pointer to Job Info (atsvc_JobInfo)",hf_atsvc_job_info); + + return offset; +} + +static int +atsvc_dissect_element_JobGetInfo_job_info_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = atsvc_dissect_struct_JobInfo(tvb,offset,pinfo,tree,drep,hf_atsvc_job_info,0); + + return offset; +} + +/* IDL: NTSTATUS atsvc_JobGetInfo( */ +/* IDL: [unique(1)] [in] unistr *servername, */ +/* IDL: [in] uint32 job_id, */ +/* IDL: [unique(1)] [out] atsvc_JobInfo *job_info */ +/* IDL: ); */ + +static int +atsvc_dissect_JobGetInfo_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = atsvc_dissect_element_JobGetInfo_job_info(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep, hf_atsvc_status, NULL); + return offset; +} + +static int +atsvc_dissect_JobGetInfo_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = atsvc_dissect_element_JobGetInfo_servername(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = atsvc_dissect_element_JobGetInfo_job_id(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + + +static dcerpc_sub_dissector atsvc_dissectors[] = { + { 0, "JobAdd", + atsvc_dissect_JobAdd_request, atsvc_dissect_JobAdd_response}, + { 1, "JobDel", + atsvc_dissect_JobDel_request, atsvc_dissect_JobDel_response}, + { 2, "JobEnum", + atsvc_dissect_JobEnum_request, atsvc_dissect_JobEnum_response}, + { 3, "JobGetInfo", + atsvc_dissect_JobGetInfo_request, atsvc_dissect_JobGetInfo_response}, + { 0, NULL, NULL, NULL } +}; + +void proto_register_dcerpc_atsvc(void) +{ + static hf_register_info hf[] = { + { &hf_atsvc_atsvc_JobEnumInfo_days_of_month, + { "Days Of Month", "atsvc.atsvc_JobEnumInfo.days_of_month", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_JobEnum_resume_handle, + { "Resume Handle", "atsvc.atsvc_JobEnum.resume_handle", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_THURSDAY, + { "Daysofweek Thursday", "atsvc.atsvc_DaysOfWeek.DAYSOFWEEK_THURSDAY", FT_BOOLEAN, 8, TFS(&atsvc_DaysOfWeek_DAYSOFWEEK_THURSDAY_tfs), ( 0x08 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Eight, + { "Eight", "atsvc.atsvc_DaysOfMonth.Eight", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Eight_tfs), ( 0x00000080 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Third, + { "Third", "atsvc.atsvc_DaysOfMonth.Third", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Third_tfs), ( 0x00000004 ), "", HFILL }}, + { &hf_atsvc_atsvc_JobInfo_days_of_week, + { "Days Of Week", "atsvc.atsvc_JobInfo.days_of_week", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Twentyseventh, + { "Twentyseventh", "atsvc.atsvc_DaysOfMonth.Twentyseventh", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Twentyseventh_tfs), ( 0x04000000 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Twentyth, + { "Twentyth", "atsvc.atsvc_DaysOfMonth.Twentyth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Twentyth_tfs), ( 0x00080000 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Seventeenth, + { "Seventeenth", "atsvc.atsvc_DaysOfMonth.Seventeenth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Seventeenth_tfs), ( 0x00010000 ), "", HFILL }}, + { &hf_atsvc_atsvc_Flags_JOB_RUN_PERIODICALLY, + { "Job Run Periodically", "atsvc.atsvc_Flags.JOB_RUN_PERIODICALLY", FT_BOOLEAN, 8, TFS(&atsvc_Flags_JOB_RUN_PERIODICALLY_tfs), ( 0x01 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Fifth, + { "Fifth", "atsvc.atsvc_DaysOfMonth.Fifth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Fifth_tfs), ( 0x00000010 ), "", HFILL }}, + { &hf_atsvc_job_info, + { "JobInfo", "atcvs.job_info", FT_NONE, BASE_HEX, NULL, 0, "JobInfo structure", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Thitteenth, + { "Thitteenth", "atsvc.atsvc_DaysOfMonth.Thitteenth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Thitteenth_tfs), ( 0x00001000 ), "", HFILL }}, + { &hf_atsvc_atsvc_enum_ctr_entries_read, + { "Entries Read", "atsvc.atsvc_enum_ctr.entries_read", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_enum_ctr_first_entry, + { "First Entry", "atsvc.atsvc_enum_ctr.first_entry", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_Flags_JOB_EXEC_ERROR, + { "Job Exec Error", "atsvc.atsvc_Flags.JOB_EXEC_ERROR", FT_BOOLEAN, 8, TFS(&atsvc_Flags_JOB_EXEC_ERROR_tfs), ( 0x02 ), "", HFILL }}, + { &hf_atsvc_atsvc_Flags_JOB_NONINTERACTIVE, + { "Job Noninteractive", "atsvc.atsvc_Flags.JOB_NONINTERACTIVE", FT_BOOLEAN, 8, TFS(&atsvc_Flags_JOB_NONINTERACTIVE_tfs), ( 0x10 ), "", HFILL }}, + { &hf_atsvc_opnum, + { "Operation", "atsvc.opnum", FT_UINT16, BASE_DEC, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_Flags_JOB_RUNS_TODAY, + { "Job Runs Today", "atsvc.atsvc_Flags.JOB_RUNS_TODAY", FT_BOOLEAN, 8, TFS(&atsvc_Flags_JOB_RUNS_TODAY_tfs), ( 0x04 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Eighteenth, + { "Eighteenth", "atsvc.atsvc_DaysOfMonth.Eighteenth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Eighteenth_tfs), ( 0x00020000 ), "", HFILL }}, + { &hf_atsvc_job_id, + { "Job Id", "atsvc.job_id", FT_UINT32, BASE_DEC, NULL, 0, "Identifier of the scheduled job", HFILL }}, + { &hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_SATURDAY, + { "Daysofweek Saturday", "atsvc.atsvc_DaysOfWeek.DAYSOFWEEK_SATURDAY", FT_BOOLEAN, 8, TFS(&atsvc_DaysOfWeek_DAYSOFWEEK_SATURDAY_tfs), ( 0x20 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Ninteenth, + { "Ninteenth", "atsvc.atsvc_DaysOfMonth.Ninteenth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Ninteenth_tfs), ( 0x00040000 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_MONDAY, + { "Daysofweek Monday", "atsvc.atsvc_DaysOfWeek.DAYSOFWEEK_MONDAY", FT_BOOLEAN, 8, TFS(&atsvc_DaysOfWeek_DAYSOFWEEK_MONDAY_tfs), ( 0x01 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Twentysecond, + { "Twentysecond", "atsvc.atsvc_DaysOfMonth.Twentysecond", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Twentysecond_tfs), ( 0x00200000 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_FRIDAY, + { "Daysofweek Friday", "atsvc.atsvc_DaysOfWeek.DAYSOFWEEK_FRIDAY", FT_BOOLEAN, 8, TFS(&atsvc_DaysOfWeek_DAYSOFWEEK_FRIDAY_tfs), ( 0x10 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Second, + { "Second", "atsvc.atsvc_DaysOfMonth.Second", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Second_tfs), ( 0x00000002 ), "", HFILL }}, + { &hf_atsvc_status, + { "Status", "atsvc.status", FT_UINT32, BASE_HEX, VALS(NT_errors), 0, "", HFILL }}, + { &hf_atsvc_atsvc_JobEnum_ctr, + { "Ctr", "atsvc.atsvc_JobEnum.ctr", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_JobInfo_command, + { "Command", "atsvc.atsvc_JobInfo.command", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Sixteenth, + { "Sixteenth", "atsvc.atsvc_DaysOfMonth.Sixteenth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Sixteenth_tfs), ( 0x00008000 ), "", HFILL }}, + { &hf_atsvc_atsvc_JobEnumInfo_command, + { "Command", "atsvc.atsvc_JobEnumInfo.command", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_Flags_JOB_ADD_CURRENT_DATE, + { "Job Add Current Date", "atsvc.atsvc_Flags.JOB_ADD_CURRENT_DATE", FT_BOOLEAN, 8, TFS(&atsvc_Flags_JOB_ADD_CURRENT_DATE_tfs), ( 0x08 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Thirtyfirst, + { "Thirtyfirst", "atsvc.atsvc_DaysOfMonth.Thirtyfirst", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Thirtyfirst_tfs), ( 0x40000000 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Fourth, + { "Fourth", "atsvc.atsvc_DaysOfMonth.Fourth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Fourth_tfs), ( 0x00000008 ), "", HFILL }}, + { &hf_atsvc_atsvc_JobEnumInfo_days_of_week, + { "Days Of Week", "atsvc.atsvc_JobEnumInfo.days_of_week", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_First, + { "First", "atsvc.atsvc_DaysOfMonth.First", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_First_tfs), ( 0x00000001 ), "", HFILL }}, + { &hf_atsvc_atsvc_JobEnumInfo_job_time, + { "Job Time", "atsvc.atsvc_JobEnumInfo.job_time", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_JobEnum_total_entries, + { "Total Entries", "atsvc.atsvc_JobEnum.total_entries", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Twentyninth, + { "Twentyninth", "atsvc.atsvc_DaysOfMonth.Twentyninth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Twentyninth_tfs), ( 0x10000000 ), "", HFILL }}, + { &hf_atsvc_atsvc_JobDel_max_job_id, + { "Max Job Id", "atsvc.atsvc_JobDel.max_job_id", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_TUESDAY, + { "Daysofweek Tuesday", "atsvc.atsvc_DaysOfWeek.DAYSOFWEEK_TUESDAY", FT_BOOLEAN, 8, TFS(&atsvc_DaysOfWeek_DAYSOFWEEK_TUESDAY_tfs), ( 0x02 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Twentythird, + { "Twentythird", "atsvc.atsvc_DaysOfMonth.Twentythird", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Twentythird_tfs), ( 0x00400000 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Fifteenth, + { "Fifteenth", "atsvc.atsvc_DaysOfMonth.Fifteenth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Fifteenth_tfs), ( 0x00004000 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Twentyeighth, + { "Twentyeighth", "atsvc.atsvc_DaysOfMonth.Twentyeighth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Twentyeighth_tfs), ( 0x08000000 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Twelfth, + { "Twelfth", "atsvc.atsvc_DaysOfMonth.Twelfth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Twelfth_tfs), ( 0x00000800 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_WEDNESDAY, + { "Daysofweek Wednesday", "atsvc.atsvc_DaysOfWeek.DAYSOFWEEK_WEDNESDAY", FT_BOOLEAN, 8, TFS(&atsvc_DaysOfWeek_DAYSOFWEEK_WEDNESDAY_tfs), ( 0x04 ), "", HFILL }}, + { &hf_atsvc_atsvc_JobInfo_flags, + { "Flags", "atsvc.atsvc_JobInfo.flags", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Seventh, + { "Seventh", "atsvc.atsvc_DaysOfMonth.Seventh", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Seventh_tfs), ( 0x00000040 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Twentyfirst, + { "Twentyfirst", "atsvc.atsvc_DaysOfMonth.Twentyfirst", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Twentyfirst_tfs), ( 0x00100000 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Tenth, + { "Tenth", "atsvc.atsvc_DaysOfMonth.Tenth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Tenth_tfs), ( 0x00000200 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Fourteenth, + { "Fourteenth", "atsvc.atsvc_DaysOfMonth.Fourteenth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Fourteenth_tfs), ( 0x00002000 ), "", HFILL }}, + { &hf_atsvc_atsvc_JobEnum_preferred_max_len, + { "Preferred Max Len", "atsvc.atsvc_JobEnum.preferred_max_len", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Twentyfourth, + { "Twentyfourth", "atsvc.atsvc_DaysOfMonth.Twentyfourth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Twentyfourth_tfs), ( 0x00800000 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Twentyfifth, + { "Twentyfifth", "atsvc.atsvc_DaysOfMonth.Twentyfifth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Twentyfifth_tfs), ( 0x01000000 ), "", HFILL }}, + { &hf_atsvc_servername, + { "Server", "atsvc.server", FT_STRING, BASE_HEX, NULL, 0, "Name of the server", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Thirtieth, + { "Thirtieth", "atsvc.atsvc_DaysOfMonth.Thirtieth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Thirtieth_tfs), ( 0x20000000 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfWeek_DAYSOFWEEK_SUNDAY, + { "Daysofweek Sunday", "atsvc.atsvc_DaysOfWeek.DAYSOFWEEK_SUNDAY", FT_BOOLEAN, 8, TFS(&atsvc_DaysOfWeek_DAYSOFWEEK_SUNDAY_tfs), ( 0x40 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Sixth, + { "Sixth", "atsvc.atsvc_DaysOfMonth.Sixth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Sixth_tfs), ( 0x00000020 ), "", HFILL }}, + { &hf_atsvc_atsvc_JobDel_min_job_id, + { "Min Job Id", "atsvc.atsvc_JobDel.min_job_id", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_JobInfo_job_time, + { "Job Time", "atsvc.atsvc_JobInfo.job_time", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Ninth, + { "Ninth", "atsvc.atsvc_DaysOfMonth.Ninth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Ninth_tfs), ( 0x00000100 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Eleventh, + { "Eleventh", "atsvc.atsvc_DaysOfMonth.Eleventh", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Eleventh_tfs), ( 0x00000400 ), "", HFILL }}, + { &hf_atsvc_atsvc_DaysOfMonth_Twentysixth, + { "Twentysixth", "atsvc.atsvc_DaysOfMonth.Twentysixth", FT_BOOLEAN, 32, TFS(&atsvc_DaysOfMonth_Twentysixth_tfs), ( 0x02000000 ), "", HFILL }}, + { &hf_atsvc_atsvc_JobInfo_days_of_month, + { "Days Of Month", "atsvc.atsvc_JobInfo.days_of_month", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_atsvc_atsvc_JobEnumInfo_flags, + { "Flags", "atsvc.atsvc_JobEnumInfo.flags", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + }; + + + static gint *ett[] = { + &ett_dcerpc_atsvc, + &ett_atsvc_atsvc_DaysOfMonth, + &ett_atsvc_atsvc_Flags, + &ett_atsvc_atsvc_DaysOfWeek, + &ett_atsvc_atsvc_JobInfo, + &ett_atsvc_atsvc_JobEnumInfo, + &ett_atsvc_atsvc_enum_ctr, + }; + + proto_dcerpc_atsvc = proto_register_protocol("Microsoft AT-Scheduler Service", "ATSVC", "atsvc"); + proto_register_field_array(proto_dcerpc_atsvc, hf, array_length (hf)); + proto_register_subtree_array(ett, array_length(ett)); +} + +void proto_reg_handoff_dcerpc_atsvc(void) +{ + dcerpc_init_uuid(proto_dcerpc_atsvc, ett_dcerpc_atsvc, + &uuid_dcerpc_atsvc, ver_dcerpc_atsvc, + atsvc_dissectors, hf_atsvc_opnum); +} diff --git a/epan/dissectors/packet-dcerpc-atsvc.h b/epan/dissectors/packet-dcerpc-atsvc.h new file mode 100644 index 0000000000..10ad9a58d1 --- /dev/null +++ b/epan/dissectors/packet-dcerpc-atsvc.h @@ -0,0 +1,23 @@ +/* autogenerated by pidl */ + +/* DO NOT EDIT + This filter was automatically generated + from atsvc.idl and atsvc.cnf. + + Pidl is a perl based IDL compiler for DCE/RPC idl files. + It is maintained by the Samba team, not the Ethereal team. + Instructions on how to download and install Pidl can be + found at http://wiki.ethereal.com/Pidl +*/ + + +#ifndef __PACKET_DCERPC_ATSVC_H +#define __PACKET_DCERPC_ATSVC_H + +int atsvc_dissect_bitmap_DaysOfMonth(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep, int hf_index, guint32 param); +int atsvc_dissect_bitmap_Flags(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep, int hf_index, guint32 param); +int atsvc_dissect_bitmap_DaysOfWeek(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep, int hf_index, guint32 param); +int atsvc_dissect_struct_JobInfo(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_); +int atsvc_dissect_struct_JobEnumInfo(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_); +int atsvc_dissect_struct_enum_ctr(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_); +#endif /* __PACKET_DCERPC_ATSVC_H */ diff --git a/epan/dissectors/packet-dcerpc-initshutdown.c b/epan/dissectors/packet-dcerpc-initshutdown.c new file mode 100644 index 0000000000..102c34cf3e --- /dev/null +++ b/epan/dissectors/packet-dcerpc-initshutdown.c @@ -0,0 +1,489 @@ +/* DO NOT EDIT + This filter was automatically generated + from librpc/idl/initshutdown.idl and librpc/idl/initshutdown.cnf. + + Pidl is a perl based IDL compiler for DCE/RPC idl files. + It is maintained by the Samba team, not the Ethereal team. + Instructions on how to download and install Pidl can be + found at http://wiki.ethereal.com/Pidl +*/ + + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include <glib.h> +#include <string.h> +#include <epan/packet.h> + +#include "packet-dcerpc.h" +#include "packet-dcerpc-nt.h" +#include "packet-windows-common.h" +#include "packet-dcerpc-initshutdown.h" + +/* Ett declarations */ +static gint ett_dcerpc_initshutdown = -1; +static gint ett_initshutdown_initshutdown_String_sub = -1; +static gint ett_initshutdown_initshutdown_String = -1; + + +/* Header field declarations */ +static gint hf_initshutdown_initshutdown_String_name_len = -1; +static gint hf_initshutdown_opnum = -1; +static gint hf_initshutdown_initshutdown_Init_hostname = -1; +static gint hf_initshutdown_initshutdown_String_sub_name = -1; +static gint hf_initshutdown_initshutdown_String_sub_name_size = -1; +static gint hf_initshutdown_initshutdown_InitEx_reason = -1; +static gint hf_initshutdown_initshutdown_InitEx_force_apps = -1; +static gint hf_initshutdown_initshutdown_InitEx_timeout = -1; +static gint hf_initshutdown_initshutdown_Init_timeout = -1; +static gint hf_initshutdown_initshutdown_String_name_size = -1; +static gint hf_initshutdown_initshutdown_Init_force_apps = -1; +static gint hf_initshutdown_initshutdown_InitEx_hostname = -1; +static gint hf_initshutdown_initshutdown_Init_reboot = -1; +static gint hf_initshutdown_initshutdown_InitEx_reboot = -1; +static gint hf_initshutdown_initshutdown_Init_message = -1; +static gint hf_initshutdown_werror = -1; +static gint hf_initshutdown_initshutdown_InitEx_message = -1; +static gint hf_initshutdown_initshutdown_Abort_server = -1; +static gint hf_initshutdown_initshutdown_String_name = -1; + +static gint proto_dcerpc_initshutdown = -1; +/* Version information */ + + +static e_uuid_t uuid_dcerpc_initshutdown = { + 0x894de0c0, 0x0d55, 0x11d3, + { 0xa3, 0x22, 0x00, 0xc0, 0x4f, 0xa3, 0x21, 0xa1 } +}; +static guint16 ver_dcerpc_initshutdown = 1; + +static int initshutdown_dissect_element_String_sub_name_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_String_sub_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_String_name_len(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_String_name_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_String_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_String_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_Init_hostname(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_Init_hostname_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_Init_message(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_Init_message_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_Init_timeout(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_Init_force_apps(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_Init_reboot(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_Abort_server(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_Abort_server_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_InitEx_hostname(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_InitEx_hostname_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_InitEx_message(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_InitEx_message_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_InitEx_timeout(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_InitEx_force_apps(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_InitEx_reboot(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int initshutdown_dissect_element_InitEx_reason(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); + +/* IDL: typedef struct { */ +/* IDL: [value(strlen_m_term(name))] uint32 name_size; */ +/* IDL: [flag(LIBNDR_FLAG_STR_LEN4|LIBNDR_FLAG_STR_NOTERM)] string name; */ +/* IDL: } initshutdown_String_sub; */ + +static int +initshutdown_dissect_element_String_sub_name_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_String_sub_name_size,NULL); + + return offset; +} + +static int +initshutdown_dissect_element_String_sub_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + + return offset; +} + +int +initshutdown_dissect_struct_String_sub(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + int old_offset; + + ALIGN_TO_4_BYTES; + + old_offset = offset; + + if(parent_tree){ + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, TRUE); + tree = proto_item_add_subtree(item, ett_initshutdown_initshutdown_String_sub); + } + + offset = initshutdown_dissect_element_String_sub_name_size(tvb, offset, pinfo, tree, drep); + + offset = initshutdown_dissect_element_String_sub_name(tvb, offset, pinfo, tree, drep); + + + proto_item_set_len(item, offset-old_offset); + + return offset; +} + +/* IDL: typedef struct { */ +/* IDL: [value(strlen_m(r->name->name)*2)] uint16 name_len; */ +/* IDL: [value(strlen_m_term(r->name->name)*2)] uint16 name_size; */ +/* IDL: [unique(1)] initshutdown_String_sub *name; */ +/* IDL: } initshutdown_String; */ + +static int +initshutdown_dissect_element_String_name_len(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_String_name_len,NULL); + + return offset; +} + +static int +initshutdown_dissect_element_String_name_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_String_name_size,NULL); + + return offset; +} + +static int +initshutdown_dissect_element_String_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, drep, initshutdown_dissect_element_String_name_, NDR_POINTER_UNIQUE, "Pointer to Name (initshutdown_String_sub)",hf_initshutdown_initshutdown_String_name); + + return offset; +} + +static int +initshutdown_dissect_element_String_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = initshutdown_dissect_struct_String_sub(tvb,offset,pinfo,tree,drep,hf_initshutdown_initshutdown_String_name,0); + + return offset; +} + +int +initshutdown_dissect_struct_String(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + int old_offset; + + ALIGN_TO_4_BYTES; + + old_offset = offset; + + if(parent_tree){ + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, TRUE); + tree = proto_item_add_subtree(item, ett_initshutdown_initshutdown_String); + } + + offset = initshutdown_dissect_element_String_name_len(tvb, offset, pinfo, tree, drep); + + offset = initshutdown_dissect_element_String_name_size(tvb, offset, pinfo, tree, drep); + + offset = initshutdown_dissect_element_String_name(tvb, offset, pinfo, tree, drep); + + + proto_item_set_len(item, offset-old_offset); + + return offset; +} + +static int +initshutdown_dissect_element_Init_hostname(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, initshutdown_dissect_element_Init_hostname_, NDR_POINTER_UNIQUE, "Pointer to Hostname (uint16)",hf_initshutdown_initshutdown_Init_hostname); + + return offset; +} + +static int +initshutdown_dissect_element_Init_hostname_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_Init_hostname,NULL); + + return offset; +} + +static int +initshutdown_dissect_element_Init_message(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, initshutdown_dissect_element_Init_message_, NDR_POINTER_UNIQUE, "Pointer to Message (initshutdown_String)",hf_initshutdown_initshutdown_Init_message); + + return offset; +} + +static int +initshutdown_dissect_element_Init_message_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = initshutdown_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_initshutdown_initshutdown_Init_message,0); + + return offset; +} + +static int +initshutdown_dissect_element_Init_timeout(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_Init_timeout,NULL); + + return offset; +} + +static int +initshutdown_dissect_element_Init_force_apps(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_Init_force_apps,NULL); + + return offset; +} + +static int +initshutdown_dissect_element_Init_reboot(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_Init_reboot,NULL); + + return offset; +} + +/* IDL: WERROR initshutdown_Init( */ +/* IDL: [unique(1)] [in] uint16 *hostname, */ +/* IDL: [unique(1)] [in] initshutdown_String *message, */ +/* IDL: [in] uint32 timeout, */ +/* IDL: [in] uint8 force_apps, */ +/* IDL: [in] uint8 reboot */ +/* IDL: ); */ + +static int +initshutdown_dissect_Init_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_initshutdown_werror, NULL); + return offset; +} + +static int +initshutdown_dissect_Init_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = initshutdown_dissect_element_Init_hostname(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = initshutdown_dissect_element_Init_message(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = initshutdown_dissect_element_Init_timeout(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = initshutdown_dissect_element_Init_force_apps(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = initshutdown_dissect_element_Init_reboot(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +initshutdown_dissect_element_Abort_server(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, initshutdown_dissect_element_Abort_server_, NDR_POINTER_UNIQUE, "Pointer to Server (uint16)",hf_initshutdown_initshutdown_Abort_server); + + return offset; +} + +static int +initshutdown_dissect_element_Abort_server_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_Abort_server,NULL); + + return offset; +} + +/* IDL: WERROR initshutdown_Abort( */ +/* IDL: [unique(1)] [in] uint16 *server */ +/* IDL: ); */ + +static int +initshutdown_dissect_Abort_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_initshutdown_werror, NULL); + return offset; +} + +static int +initshutdown_dissect_Abort_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = initshutdown_dissect_element_Abort_server(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +initshutdown_dissect_element_InitEx_hostname(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, initshutdown_dissect_element_InitEx_hostname_, NDR_POINTER_UNIQUE, "Pointer to Hostname (uint16)",hf_initshutdown_initshutdown_InitEx_hostname); + + return offset; +} + +static int +initshutdown_dissect_element_InitEx_hostname_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_InitEx_hostname,NULL); + + return offset; +} + +static int +initshutdown_dissect_element_InitEx_message(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, initshutdown_dissect_element_InitEx_message_, NDR_POINTER_UNIQUE, "Pointer to Message (initshutdown_String)",hf_initshutdown_initshutdown_InitEx_message); + + return offset; +} + +static int +initshutdown_dissect_element_InitEx_message_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = initshutdown_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_initshutdown_initshutdown_InitEx_message,0); + + return offset; +} + +static int +initshutdown_dissect_element_InitEx_timeout(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_InitEx_timeout,NULL); + + return offset; +} + +static int +initshutdown_dissect_element_InitEx_force_apps(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_InitEx_force_apps,NULL); + + return offset; +} + +static int +initshutdown_dissect_element_InitEx_reboot(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_InitEx_reboot,NULL); + + return offset; +} + +static int +initshutdown_dissect_element_InitEx_reason(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_initshutdown_initshutdown_InitEx_reason,NULL); + + return offset; +} + +/* IDL: WERROR initshutdown_InitEx( */ +/* IDL: [unique(1)] [in] uint16 *hostname, */ +/* IDL: [unique(1)] [in] initshutdown_String *message, */ +/* IDL: [in] uint32 timeout, */ +/* IDL: [in] uint8 force_apps, */ +/* IDL: [in] uint8 reboot, */ +/* IDL: [in] uint32 reason */ +/* IDL: ); */ + +static int +initshutdown_dissect_InitEx_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_initshutdown_werror, NULL); + return offset; +} + +static int +initshutdown_dissect_InitEx_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = initshutdown_dissect_element_InitEx_hostname(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = initshutdown_dissect_element_InitEx_message(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = initshutdown_dissect_element_InitEx_timeout(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = initshutdown_dissect_element_InitEx_force_apps(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = initshutdown_dissect_element_InitEx_reboot(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = initshutdown_dissect_element_InitEx_reason(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + + +static dcerpc_sub_dissector initshutdown_dissectors[] = { + { 0, "Init", + initshutdown_dissect_Init_request, initshutdown_dissect_Init_response}, + { 1, "Abort", + initshutdown_dissect_Abort_request, initshutdown_dissect_Abort_response}, + { 2, "InitEx", + initshutdown_dissect_InitEx_request, initshutdown_dissect_InitEx_response}, + { 0, NULL, NULL, NULL } +}; + +void proto_register_dcerpc_initshutdown(void) +{ + static hf_register_info hf[] = { + { &hf_initshutdown_initshutdown_String_name_len, + { "Name Len", "initshutdown.initshutdown_String.name_len", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_opnum, + { "Operation", "initshutdown.opnum", FT_UINT16, BASE_DEC, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_Init_hostname, + { "Hostname", "initshutdown.initshutdown_Init.hostname", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_String_sub_name, + { "Name", "initshutdown.initshutdown_String_sub.name", FT_STRING, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_String_sub_name_size, + { "Name Size", "initshutdown.initshutdown_String_sub.name_size", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_InitEx_reason, + { "Reason", "initshutdown.initshutdown_InitEx.reason", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_InitEx_force_apps, + { "Force Apps", "initshutdown.initshutdown_InitEx.force_apps", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_InitEx_timeout, + { "Timeout", "initshutdown.initshutdown_InitEx.timeout", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_Init_timeout, + { "Timeout", "initshutdown.initshutdown_Init.timeout", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_String_name_size, + { "Name Size", "initshutdown.initshutdown_String.name_size", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_Init_force_apps, + { "Force Apps", "initshutdown.initshutdown_Init.force_apps", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_InitEx_hostname, + { "Hostname", "initshutdown.initshutdown_InitEx.hostname", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_Init_reboot, + { "Reboot", "initshutdown.initshutdown_Init.reboot", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_InitEx_reboot, + { "Reboot", "initshutdown.initshutdown_InitEx.reboot", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_Init_message, + { "Message", "initshutdown.initshutdown_Init.message", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_werror, + { "Windows Error", "initshutdown.werror", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_InitEx_message, + { "Message", "initshutdown.initshutdown_InitEx.message", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_Abort_server, + { "Server", "initshutdown.initshutdown_Abort.server", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_initshutdown_initshutdown_String_name, + { "Name", "initshutdown.initshutdown_String.name", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + }; + + + static gint *ett[] = { + &ett_dcerpc_initshutdown, + &ett_initshutdown_initshutdown_String_sub, + &ett_initshutdown_initshutdown_String, + }; + + proto_dcerpc_initshutdown = proto_register_protocol("Init shutdown service", "INITSHUTDOWN", "initshutdown"); + proto_register_field_array(proto_dcerpc_initshutdown, hf, array_length (hf)); + proto_register_subtree_array(ett, array_length(ett)); +} + +void proto_reg_handoff_dcerpc_initshutdown(void) +{ + dcerpc_init_uuid(proto_dcerpc_initshutdown, ett_dcerpc_initshutdown, + &uuid_dcerpc_initshutdown, ver_dcerpc_initshutdown, + initshutdown_dissectors, hf_initshutdown_opnum); +} diff --git a/epan/dissectors/packet-dcerpc-initshutdown.h b/epan/dissectors/packet-dcerpc-initshutdown.h new file mode 100644 index 0000000000..5027819d6c --- /dev/null +++ b/epan/dissectors/packet-dcerpc-initshutdown.h @@ -0,0 +1,19 @@ +/* autogenerated by pidl */ + +/* DO NOT EDIT + This filter was automatically generated + from librpc/idl/initshutdown.idl and librpc/idl/initshutdown.cnf. + + Pidl is a perl based IDL compiler for DCE/RPC idl files. + It is maintained by the Samba team, not the Ethereal team. + Instructions on how to download and install Pidl can be + found at http://wiki.ethereal.com/Pidl +*/ + + +#ifndef __PACKET_DCERPC_INITSHUTDOWN_H +#define __PACKET_DCERPC_INITSHUTDOWN_H + +int initshutdown_dissect_struct_String_sub(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_); +int initshutdown_dissect_struct_String(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_); +#endif /* __PACKET_DCERPC_INITSHUTDOWN_H */ diff --git a/epan/dissectors/packet-dcerpc-winreg.c b/epan/dissectors/packet-dcerpc-winreg.c new file mode 100644 index 0000000000..8f5d3022b8 --- /dev/null +++ b/epan/dissectors/packet-dcerpc-winreg.c @@ -0,0 +1,3588 @@ +/* DO NOT EDIT + This filter was automatically generated + from librpc/idl/winreg.idl and librpc/idl/winreg.cnf. + + Pidl is a perl based IDL compiler for DCE/RPC idl files. + It is maintained by the Samba team, not the Ethereal team. + Instructions on how to download and install Pidl can be + found at http://wiki.ethereal.com/Pidl +*/ + + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include <glib.h> +#include <string.h> +#include <epan/packet.h> + +#include "packet-dcerpc.h" +#include "packet-dcerpc-nt.h" +#include "packet-windows-common.h" +#include "packet-dcerpc-winreg.h" + +/* Ett declarations */ +static gint ett_dcerpc_winreg = -1; +static gint ett_winreg_winreg_String = -1; +static gint ett_winreg_KeySecurityData = -1; +static gint ett_winreg_winreg_SecBuf = -1; +static gint ett_winreg_winreg_StringBuf = -1; +static gint ett_winreg_QueryMultipleValue = -1; + + +/* Header field declarations */ +static gint hf_winreg_winreg_OpenHKCC_access_required = -1; +static gint hf_winreg_winreg_NotifyChangeKeyValue_string2 = -1; +static gint hf_winreg_winreg_InitiateSystemShutdown_message = -1; +static gint hf_winreg_winreg_String_name = -1; +static gint hf_winreg_winreg_InitiateSystemShutdownEx_message = -1; +static gint hf_winreg_winreg_InitiateSystemShutdown_reboot = -1; +static gint hf_winreg_winreg_OpenHKPN_access_required = -1; +static gint hf_winreg_winreg_EnumValue_enum_index = -1; +static gint hf_winreg_winreg_CreateKey_options = -1; +static gint hf_winreg_winreg_InitiateSystemShutdownEx_timeout = -1; +static gint hf_winreg_winreg_QueryValue_size = -1; +static gint hf_winreg_winreg_QueryInfoKey_max_valnamelen = -1; +static gint hf_winreg_winreg_SecBuf_length = -1; +static gint hf_winreg_winreg_InitiateSystemShutdownEx_reboot = -1; +static gint hf_winreg_winreg_OpenHKCC_handle = -1; +static gint hf_winreg_winreg_QueryMultipleValues_buffer_size = -1; +static gint hf_winreg_winreg_OpenHKCU_handle = -1; +static gint hf_winreg_winreg_CreateKey_new_handle = -1; +static gint hf_winreg_winreg_OpenHKPT_handle = -1; +static gint hf_winreg_winreg_EnumKey_class = -1; +static gint hf_winreg_winreg_GetKeySecurity_handle = -1; +static gint hf_winreg_winreg_OpenHKCR_handle = -1; +static gint hf_winreg_winreg_OpenHKLM_access_required = -1; +static gint hf_winreg_winreg_OpenHKPN_system_name = -1; +static gint hf_winreg_winreg_OpenHKU_access_required = -1; +static gint hf_winreg_QueryMultipleValue_name = -1; +static gint hf_winreg_winreg_GetKeySecurity_sec_info = -1; +static gint hf_winreg_winreg_StringBuf_size = -1; +static gint hf_winreg_winreg_OpenHKCR_access_required = -1; +static gint hf_winreg_winreg_SecBuf_sd = -1; +static gint hf_winreg_winreg_CreateKey_class = -1; +static gint hf_winreg_winreg_QueryInfoKey_secdescsize = -1; +static gint hf_winreg_winreg_SetValue_name = -1; +static gint hf_winreg_winreg_OpenHKPT_system_name = -1; +static gint hf_winreg_winreg_CreateKey_secdesc = -1; +static gint hf_winreg_winreg_InitiateSystemShutdownEx_force_apps = -1; +static gint hf_winreg_winreg_SetValue_type = -1; +static gint hf_winreg_winreg_EnumValue_handle = -1; +static gint hf_winreg_winreg_DeleteValue_handle = -1; +static gint hf_winreg_opnum = -1; +static gint hf_winreg_winreg_EnumValue_name = -1; +static gint hf_winreg_winreg_LoadKey_filename = -1; +static gint hf_winreg_winreg_DeleteValue_value = -1; +static gint hf_winreg_winreg_OpenHKCU_access_required = -1; +static gint hf_winreg_winreg_NotifyChangeKeyValue_handle = -1; +static gint hf_winreg_winreg_OpenHKDD_handle = -1; +static gint hf_winreg_winreg_QueryInfoKey_num_subkeys = -1; +static gint hf_winreg_winreg_QueryInfoKey_last_changed_time = -1; +static gint hf_winreg_winreg_AbortSystemShutdown_server = -1; +static gint hf_winreg_winreg_QueryValue_type = -1; +static gint hf_winreg_winreg_CloseKey_handle = -1; +static gint hf_winreg_winreg_OpenHKU_system_name = -1; +static gint hf_winreg_winreg_OpenHKDD_system_name = -1; +static gint hf_winreg_winreg_DeleteKey_handle = -1; +static gint hf_winreg_winreg_SecBuf_inherit = -1; +static gint hf_winreg_winreg_SetValue_size = -1; +static gint hf_winreg_winreg_QueryMultipleValues_values = -1; +static gint hf_winreg_winreg_OpenHKCC_system_name = -1; +static gint hf_winreg_winreg_GetVersion_version = -1; +static gint hf_winreg_winreg_CreateKey_action_taken = -1; +static gint hf_winreg_winreg_QueryInfoKey_num_values = -1; +static gint hf_winreg_winreg_SetKeySecurity_data = -1; +static gint hf_winreg_winreg_EnumKey_enum_index = -1; +static gint hf_winreg_winreg_SetValue_data = -1; +static gint hf_winreg_winreg_InitiateSystemShutdown_force_apps = -1; +static gint hf_winreg_winreg_NotifyChangeKeyValue_string1 = -1; +static gint hf_winreg_winreg_QueryMultipleValues_buffer = -1; +static gint hf_winreg_winreg_SetValue_handle = -1; +static gint hf_winreg_winreg_CreateKey_access_required = -1; +static gint hf_winreg_winreg_NotifyChangeKeyValue_notify_filter = -1; +static gint hf_winreg_winreg_OpenHKCU_system_name = -1; +static gint hf_winreg_KeySecurityData_size = -1; +static gint hf_winreg_winreg_OpenHKU_handle = -1; +static gint hf_winreg_winreg_OpenHKPD_handle = -1; +static gint hf_winreg_winreg_EnumKey_name = -1; +static gint hf_winreg_winreg_LoadKey_keyname = -1; +static gint hf_winreg_winreg_QueryMultipleValues_key_handle = -1; +static gint hf_winreg_winreg_EnumValue_type = -1; +static gint hf_winreg_winreg_EnumKey_last_changed_time = -1; +static gint hf_winreg_winreg_GetVersion_handle = -1; +static gint hf_winreg_winreg_EnumValue_size = -1; +static gint hf_winreg_winreg_OpenKey_handle = -1; +static gint hf_winreg_winreg_OpenHKPN_handle = -1; +static gint hf_winreg_winreg_QueryValue_data = -1; +static gint hf_winreg_winreg_QueryInfoKey_max_subkeysize = -1; +static gint hf_winreg_winreg_OpenHKPD_system_name = -1; +static gint hf_winreg_winreg_InitiateSystemShutdown_hostname = -1; +static gint hf_winreg_KeySecurityData_data = -1; +static gint hf_winreg_winreg_OpenKey_access_mask = -1; +static gint hf_winreg_winreg_QueryValue_handle = -1; +static gint hf_winreg_winreg_OpenKey_keyname = -1; +static gint hf_winreg_QueryMultipleValue_type = -1; +static gint hf_winreg_winreg_NotifyChangeKeyValue_watch_subtree = -1; +static gint hf_winreg_winreg_SetKeySecurity_handle = -1; +static gint hf_winreg_winreg_OpenHKDD_access_required = -1; +static gint hf_winreg_KeySecurityData_len = -1; +static gint hf_winreg_winreg_CreateKey_name = -1; +static gint hf_winreg_winreg_OpenHKPD_access_required = -1; +static gint hf_winreg_winreg_String_name_len = -1; +static gint hf_winreg_winreg_DeleteKey_key = -1; +static gint hf_winreg_QueryMultipleValue_length = -1; +static gint hf_winreg_winreg_OpenHKPT_access_required = -1; +static gint hf_winreg_winreg_QueryMultipleValues_num_values = -1; +static gint hf_winreg_winreg_QueryInfoKey_handle = -1; +static gint hf_winreg_winreg_StringBuf_name = -1; +static gint hf_winreg_winreg_NotifyChangeKeyValue_unknown2 = -1; +static gint hf_winreg_winreg_FlushKey_handle = -1; +static gint hf_winreg_winreg_OpenHKLM_system_name = -1; +static gint hf_winreg_winreg_CreateKey_handle = -1; +static gint hf_winreg_winreg_StringBuf_length = -1; +static gint hf_winreg_winreg_OpenHKCR_system_name = -1; +static gint hf_winreg_winreg_OpenHKLM_handle = -1; +static gint hf_winreg_winreg_String_name_size = -1; +static gint hf_winreg_winreg_NotifyChangeKeyValue_unknown = -1; +static gint hf_winreg_winreg_QueryValue_length = -1; +static gint hf_winreg_winreg_OpenKey_unknown = -1; +static gint hf_winreg_winreg_QueryInfoKey_max_valbufsize = -1; +static gint hf_winreg_winreg_InitiateSystemShutdownEx_reason = -1; +static gint hf_winreg_winreg_EnumValue_length = -1; +static gint hf_winreg_winreg_QueryInfoKey_max_subkeylen = -1; +static gint hf_winreg_winreg_InitiateSystemShutdown_timeout = -1; +static gint hf_winreg_winreg_QueryInfoKey_class = -1; +static gint hf_winreg_winreg_InitiateSystemShutdownEx_hostname = -1; +static gint hf_winreg_werror = -1; +static gint hf_winreg_winreg_EnumValue_value = -1; +static gint hf_winreg_winreg_SetKeySecurity_access_mask = -1; +static gint hf_winreg_winreg_GetKeySecurity_sd = -1; +static gint hf_winreg_winreg_QueryValue_value_name = -1; +static gint hf_winreg_winreg_LoadKey_handle = -1; +static gint hf_winreg_winreg_EnumKey_handle = -1; +static gint hf_winreg_QueryMultipleValue_offset = -1; + +static gint proto_dcerpc_winreg = -1; +/* Version information */ + + +static e_uuid_t uuid_dcerpc_winreg = { + 0x338cd001, 0x2244, 0x31f1, + { 0xaa, 0xaa, 0x90, 0x00, 0x38, 0x00, 0x10, 0x03 } +}; +static guint16 ver_dcerpc_winreg = 1; + +const value_string winreg_winreg_Type_vals[] = { + { REG_NONE, "REG_NONE" }, + { REG_SZ, "REG_SZ" }, + { REG_EXPAND_SZ, "REG_EXPAND_SZ" }, + { REG_BINARY, "REG_BINARY" }, + { REG_DWORD, "REG_DWORD" }, + { REG_DWORD_BIG_ENDIAN, "REG_DWORD_BIG_ENDIAN" }, + { REG_LINK, "REG_LINK" }, + { REG_MULTI_SZ, "REG_MULTI_SZ" }, + { REG_RESOURCE_LIST, "REG_RESOURCE_LIST" }, + { REG_FULL_RESOURCE_DESCRIPTOR, "REG_FULL_RESOURCE_DESCRIPTOR" }, + { REG_RESOURCE_REQUIREMENTS_LIST, "REG_RESOURCE_REQUIREMENTS_LIST" }, + { REG_QWORD, "REG_QWORD" }, +{ 0, NULL } +}; +static int winreg_dissect_element_String_name_len(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_String_name_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_String_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_String_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_KeySecurityData_data(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_KeySecurityData_data_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_KeySecurityData_data__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_KeySecurityData_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_KeySecurityData_len(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SecBuf_length(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SecBuf_sd(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SecBuf_inherit(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +const value_string winreg_winreg_CreateAction_vals[] = { + { REG_ACTION_NONE, "REG_ACTION_NONE" }, + { REG_CREATED_NEW_KEY, "REG_CREATED_NEW_KEY" }, + { REG_OPENED_EXISTING_KEY, "REG_OPENED_EXISTING_KEY" }, +{ 0, NULL } +}; +static int winreg_dissect_element_StringBuf_length(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_StringBuf_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_StringBuf_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_StringBuf_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_StringBuf_name__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValue_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValue_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValue_type(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValue_offset(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValue_length(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCR_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCR_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCR_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCR_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCR_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCU_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCU_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCU_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCU_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCU_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKLM_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKLM_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKLM_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKLM_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKLM_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPD_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPD_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPD_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPD_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPD_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKU_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKU_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKU_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKU_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKU_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CloseKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CloseKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CreateKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CreateKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CreateKey_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CreateKey_class(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CreateKey_options(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CreateKey_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CreateKey_secdesc(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CreateKey_secdesc_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CreateKey_new_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CreateKey_new_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CreateKey_action_taken(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_CreateKey_action_taken_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_DeleteKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_DeleteKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_DeleteKey_key(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_DeleteValue_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_DeleteValue_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_DeleteValue_value(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumKey_enum_index(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumKey_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumKey_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumKey_class(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumKey_class_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumKey_last_changed_time(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumKey_last_changed_time_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_enum_index(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_type(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_type_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_value(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_value_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_value__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_size_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_length(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_EnumValue_length_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_FlushKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_FlushKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_GetKeySecurity_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_GetKeySecurity_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_GetKeySecurity_sec_info(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_GetKeySecurity_sd(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_GetKeySecurity_sd_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_LoadKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_LoadKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_LoadKey_keyname(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_LoadKey_keyname_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_LoadKey_filename(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_LoadKey_filename_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_NotifyChangeKeyValue_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_NotifyChangeKeyValue_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_NotifyChangeKeyValue_watch_subtree(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_NotifyChangeKeyValue_notify_filter(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_NotifyChangeKeyValue_unknown(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_NotifyChangeKeyValue_string1(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_NotifyChangeKeyValue_string2(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_NotifyChangeKeyValue_unknown2(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenKey_keyname(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenKey_unknown(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenKey_access_mask(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryInfoKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryInfoKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryInfoKey_class(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryInfoKey_num_subkeys(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryInfoKey_max_subkeylen(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryInfoKey_max_subkeysize(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryInfoKey_num_values(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryInfoKey_max_valnamelen(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryInfoKey_max_valbufsize(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryInfoKey_secdescsize(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryInfoKey_last_changed_time(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryValue_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryValue_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryValue_value_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryValue_type(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryValue_type_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryValue_data(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryValue_data_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryValue_data__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryValue_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryValue_size_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryValue_length(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryValue_length_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetKeySecurity_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetKeySecurity_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetKeySecurity_access_mask(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetKeySecurity_data(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetKeySecurity_data_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetValue_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetValue_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetValue_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetValue_type(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetValue_data(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetValue_data_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetValue_data__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_SetValue_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdown_hostname(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdown_hostname_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdown_message(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdown_message_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdown_timeout(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdown_force_apps(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdown_reboot(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_AbortSystemShutdown_server(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_AbortSystemShutdown_server_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_GetVersion_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_GetVersion_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_GetVersion_version(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCC_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCC_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCC_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCC_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKCC_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKDD_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKDD_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKDD_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKDD_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKDD_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValues_key_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValues_key_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValues_values(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValues_values_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValues_values__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValues_num_values(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValues_buffer(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValues_buffer_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValues_buffer__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValues_buffer_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_QueryMultipleValues_buffer_size_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdownEx_hostname(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdownEx_hostname_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdownEx_message(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdownEx_message_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdownEx_timeout(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdownEx_force_apps(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdownEx_reboot(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_InitiateSystemShutdownEx_reason(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPT_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPT_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPT_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPT_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPT_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPN_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPN_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPN_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPN_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); +static int winreg_dissect_element_OpenHKPN_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep); + +/* IDL: typedef enum { */ +/* IDL: REG_NONE=0, */ +/* IDL: REG_SZ=1, */ +/* IDL: REG_EXPAND_SZ=2, */ +/* IDL: REG_BINARY=3, */ +/* IDL: REG_DWORD=4, */ +/* IDL: REG_DWORD_BIG_ENDIAN=5, */ +/* IDL: REG_LINK=6, */ +/* IDL: REG_MULTI_SZ=7, */ +/* IDL: REG_RESOURCE_LIST=8, */ +/* IDL: REG_FULL_RESOURCE_DESCRIPTOR=9, */ +/* IDL: REG_RESOURCE_REQUIREMENTS_LIST=10, */ +/* IDL: REG_QWORD=11, */ +/* IDL: } winreg_Type; */ + +int +winreg_dissect_enum_Type(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_index, NULL); + return offset; +} + +/* IDL: typedef struct { */ +/* IDL: [value(strlen_m_term(name)*2)] uint16 name_len; */ +/* IDL: [value(strlen_m_term(name)*2)] uint16 name_size; */ +/* IDL: [unique(1)] [flag(LIBNDR_FLAG_STR_SIZE4|LIBNDR_FLAG_STR_LEN4)] string *name; */ +/* IDL: } winreg_String; */ + +static int +winreg_dissect_element_String_name_len(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_String_name_len,NULL); + + return offset; +} + +static int +winreg_dissect_element_String_name_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_String_name_size,NULL); + + return offset; +} + +static int +winreg_dissect_element_String_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_String_name_, NDR_POINTER_UNIQUE, "Pointer to Name (string)",hf_winreg_winreg_String_name); + + return offset; +} + +static int +winreg_dissect_element_String_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + char *data; + + offset = dissect_ndr_cvstring(tvb, offset, pinfo, tree, drep, 2, hf_winreg_winreg_String_name, FALSE, &data); + proto_item_append_text(tree, ": %s", data); + + return offset; +} + +int +winreg_dissect_struct_String(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + int old_offset; + + ALIGN_TO_4_BYTES; + + old_offset = offset; + + if(parent_tree){ + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, TRUE); + tree = proto_item_add_subtree(item, ett_winreg_winreg_String); + } + + offset = winreg_dissect_element_String_name_len(tvb, offset, pinfo, tree, drep); + + offset = winreg_dissect_element_String_name_size(tvb, offset, pinfo, tree, drep); + + offset = winreg_dissect_element_String_name(tvb, offset, pinfo, tree, drep); + + + proto_item_set_len(item, offset-old_offset); + + return offset; +} + +/* IDL: typedef struct { */ +/* IDL: [unique(1)] [length_is(len)] [size_is(size)] uint8 *data; */ +/* IDL: uint32 size; */ +/* IDL: uint32 len; */ +/* IDL: } KeySecurityData; */ + +static int +winreg_dissect_element_KeySecurityData_data(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_KeySecurityData_data_, NDR_POINTER_UNIQUE, "Pointer to Data (uint8)",hf_winreg_KeySecurityData_data); + + return offset; +} + +static int +winreg_dissect_element_KeySecurityData_data_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, drep, winreg_dissect_element_KeySecurityData_data__); + + return offset; +} + +static int +winreg_dissect_element_KeySecurityData_data__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_winreg_KeySecurityData_data,NULL); + + return offset; +} + +static int +winreg_dissect_element_KeySecurityData_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_KeySecurityData_size,NULL); + + return offset; +} + +static int +winreg_dissect_element_KeySecurityData_len(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_KeySecurityData_len,NULL); + + return offset; +} + +int +winreg_dissect_struct_KeySecurityData(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + int old_offset; + + ALIGN_TO_4_BYTES; + + old_offset = offset; + + if(parent_tree){ + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, TRUE); + tree = proto_item_add_subtree(item, ett_winreg_KeySecurityData); + } + + offset = winreg_dissect_element_KeySecurityData_data(tvb, offset, pinfo, tree, drep); + + offset = winreg_dissect_element_KeySecurityData_size(tvb, offset, pinfo, tree, drep); + + offset = winreg_dissect_element_KeySecurityData_len(tvb, offset, pinfo, tree, drep); + + + proto_item_set_len(item, offset-old_offset); + + return offset; +} + +/* IDL: typedef struct { */ +/* IDL: uint32 length; */ +/* IDL: KeySecurityData sd; */ +/* IDL: uint8 inherit; */ +/* IDL: } winreg_SecBuf; */ + +static int +winreg_dissect_element_SecBuf_length(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_SecBuf_length,NULL); + + return offset; +} + +static int +winreg_dissect_element_SecBuf_sd(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_KeySecurityData(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_SecBuf_sd,0); + + return offset; +} + +static int +winreg_dissect_element_SecBuf_inherit(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_SecBuf_inherit,NULL); + + return offset; +} + +int +winreg_dissect_struct_SecBuf(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + int old_offset; + + ALIGN_TO_4_BYTES; + + old_offset = offset; + + if(parent_tree){ + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, TRUE); + tree = proto_item_add_subtree(item, ett_winreg_winreg_SecBuf); + } + + offset = winreg_dissect_element_SecBuf_length(tvb, offset, pinfo, tree, drep); + + offset = winreg_dissect_element_SecBuf_sd(tvb, offset, pinfo, tree, drep); + + offset = winreg_dissect_element_SecBuf_inherit(tvb, offset, pinfo, tree, drep); + + + proto_item_set_len(item, offset-old_offset); + + return offset; +} + +/* IDL: typedef enum { */ +/* IDL: REG_ACTION_NONE=0, */ +/* IDL: REG_CREATED_NEW_KEY=1, */ +/* IDL: REG_OPENED_EXISTING_KEY=2, */ +/* IDL: } winreg_CreateAction; */ + +int +winreg_dissect_enum_CreateAction(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_index, NULL); + return offset; +} + +/* IDL: typedef struct { */ +/* IDL: uint16 length; */ +/* IDL: uint16 size; */ +/* IDL: [unique(1)] [length_is(length/2)] [charset(UTF16)] [size_is(size/2)] uint16 *name; */ +/* IDL: } winreg_StringBuf; */ + +static int +winreg_dissect_element_StringBuf_length(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_StringBuf_length,NULL); + + return offset; +} + +static int +winreg_dissect_element_StringBuf_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_StringBuf_size,NULL); + + return offset; +} + +static int +winreg_dissect_element_StringBuf_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_StringBuf_name_, NDR_POINTER_UNIQUE, "Pointer to Name (uint16)",hf_winreg_winreg_StringBuf_name); + + return offset; +} + +static int +winreg_dissect_element_StringBuf_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, drep, winreg_dissect_element_StringBuf_name__); + + return offset; +} + +static int +winreg_dissect_element_StringBuf_name__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_StringBuf_name,NULL); + + return offset; +} + +int +winreg_dissect_struct_StringBuf(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + int old_offset; + + ALIGN_TO_4_BYTES; + + old_offset = offset; + + if(parent_tree){ + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, TRUE); + tree = proto_item_add_subtree(item, ett_winreg_winreg_StringBuf); + } + + offset = winreg_dissect_element_StringBuf_length(tvb, offset, pinfo, tree, drep); + + offset = winreg_dissect_element_StringBuf_size(tvb, offset, pinfo, tree, drep); + + offset = winreg_dissect_element_StringBuf_name(tvb, offset, pinfo, tree, drep); + + + proto_item_set_len(item, offset-old_offset); + + return offset; +} + +/* IDL: typedef struct { */ +/* IDL: [unique(1)] winreg_String *name; */ +/* IDL: winreg_Type type; */ +/* IDL: uint32 offset; */ +/* IDL: uint32 length; */ +/* IDL: } QueryMultipleValue; */ + +static int +winreg_dissect_element_QueryMultipleValue_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_embedded_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryMultipleValue_name_, NDR_POINTER_UNIQUE, "Pointer to Name (winreg_String)",hf_winreg_QueryMultipleValue_name); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValue_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_QueryMultipleValue_name,0); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValue_type(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_enum_Type(tvb, offset, pinfo, tree, drep, hf_winreg_QueryMultipleValue_type, 0); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValue_offset(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_QueryMultipleValue_offset,NULL); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValue_length(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_QueryMultipleValue_length,NULL); + + return offset; +} + +int +winreg_dissect_struct_QueryMultipleValue(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_) +{ + proto_item *item = NULL; + proto_tree *tree = NULL; + int old_offset; + + ALIGN_TO_4_BYTES; + + old_offset = offset; + + if(parent_tree){ + item = proto_tree_add_item(parent_tree, hf_index, tvb, offset, -1, TRUE); + tree = proto_item_add_subtree(item, ett_winreg_QueryMultipleValue); + } + + offset = winreg_dissect_element_QueryMultipleValue_name(tvb, offset, pinfo, tree, drep); + + offset = winreg_dissect_element_QueryMultipleValue_type(tvb, offset, pinfo, tree, drep); + + offset = winreg_dissect_element_QueryMultipleValue_offset(tvb, offset, pinfo, tree, drep); + + offset = winreg_dissect_element_QueryMultipleValue_length(tvb, offset, pinfo, tree, drep); + + + proto_item_set_len(item, offset-old_offset); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCR_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKCR_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_winreg_OpenHKCR_system_name); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCR_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKCR_system_name,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCR_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKCR_access_required,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCR_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKCR_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_OpenHKCR_handle); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCR_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKCR_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +/* IDL: WERROR winreg_OpenHKCR( */ +/* IDL: [unique(1)] [in] uint16 *system_name, */ +/* IDL: [in] uint32 access_required, */ +/* IDL: [out] [ref] policy_handle *handle */ +/* IDL: ); */ + +static int +winreg_dissect_OpenHKCR_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKCR_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_OpenHKCR_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKCR_system_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_OpenHKCR_access_required(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_OpenHKCU_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKCU_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_winreg_OpenHKCU_system_name); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCU_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKCU_system_name,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCU_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKCU_access_required,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCU_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKCU_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_OpenHKCU_handle); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCU_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKCU_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +/* IDL: WERROR winreg_OpenHKCU( */ +/* IDL: [unique(1)] [in] uint16 *system_name, */ +/* IDL: [in] uint32 access_required, */ +/* IDL: [out] [ref] policy_handle *handle */ +/* IDL: ); */ + +static int +winreg_dissect_OpenHKCU_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKCU_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_OpenHKCU_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKCU_system_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_OpenHKCU_access_required(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_OpenHKLM_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKLM_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_winreg_OpenHKLM_system_name); + + return offset; +} + +static int +winreg_dissect_element_OpenHKLM_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKLM_system_name,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKLM_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKLM_access_required,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKLM_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKLM_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_OpenHKLM_handle); + + return offset; +} + +static int +winreg_dissect_element_OpenHKLM_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKLM_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +/* IDL: WERROR winreg_OpenHKLM( */ +/* IDL: [unique(1)] [in] uint16 *system_name, */ +/* IDL: [in] uint32 access_required, */ +/* IDL: [out] [ref] policy_handle *handle */ +/* IDL: ); */ + +static int +winreg_dissect_OpenHKLM_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKLM_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_OpenHKLM_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKLM_system_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_OpenHKLM_access_required(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_OpenHKPD_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKPD_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_winreg_OpenHKPD_system_name); + + return offset; +} + +static int +winreg_dissect_element_OpenHKPD_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKPD_system_name,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKPD_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKPD_access_required,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKPD_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKPD_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_OpenHKPD_handle); + + return offset; +} + +static int +winreg_dissect_element_OpenHKPD_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKPD_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +/* IDL: WERROR winreg_OpenHKPD( */ +/* IDL: [unique(1)] [in] uint16 *system_name, */ +/* IDL: [in] uint32 access_required, */ +/* IDL: [out] [ref] policy_handle *handle */ +/* IDL: ); */ + +static int +winreg_dissect_OpenHKPD_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKPD_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_OpenHKPD_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKPD_system_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_OpenHKPD_access_required(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_OpenHKU_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKU_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_winreg_OpenHKU_system_name); + + return offset; +} + +static int +winreg_dissect_element_OpenHKU_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKU_system_name,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKU_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKU_access_required,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKU_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKU_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_OpenHKU_handle); + + return offset; +} + +static int +winreg_dissect_element_OpenHKU_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKU_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +/* IDL: WERROR winreg_OpenHKU( */ +/* IDL: [unique(1)] [in] uint16 *system_name, */ +/* IDL: [in] uint32 access_required, */ +/* IDL: [out] [ref] policy_handle *handle */ +/* IDL: ); */ + +static int +winreg_dissect_OpenHKU_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKU_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_OpenHKU_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKU_system_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_OpenHKU_access_required(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_CloseKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_CloseKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_CloseKey_handle); + + return offset; +} + +static int +winreg_dissect_element_CloseKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_CloseKey_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +/* IDL: WERROR winreg_CloseKey( */ +/* IDL: [out] [in] [ref] policy_handle *handle */ +/* IDL: ); */ + +static int +winreg_dissect_CloseKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_CloseKey_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_CloseKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_CloseKey_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_CreateKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_CreateKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_CreateKey_handle); + + return offset; +} + +static int +winreg_dissect_element_CreateKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_CreateKey_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_CreateKey_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_CreateKey_name,0); + + return offset; +} + +static int +winreg_dissect_element_CreateKey_class(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_CreateKey_class,0); + + return offset; +} + +static int +winreg_dissect_element_CreateKey_options(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_CreateKey_options,NULL); + + return offset; +} + +static int +winreg_dissect_element_CreateKey_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_CreateKey_access_required,NULL); + + return offset; +} + +static int +winreg_dissect_element_CreateKey_secdesc(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_CreateKey_secdesc_, NDR_POINTER_UNIQUE, "Pointer to Secdesc (winreg_SecBuf)",hf_winreg_winreg_CreateKey_secdesc); + + return offset; +} + +static int +winreg_dissect_element_CreateKey_secdesc_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_SecBuf(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_CreateKey_secdesc,0); + + return offset; +} + +static int +winreg_dissect_element_CreateKey_new_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_CreateKey_new_handle_, NDR_POINTER_REF, "Pointer to New Handle (policy_handle)",hf_winreg_winreg_CreateKey_new_handle); + + return offset; +} + +static int +winreg_dissect_element_CreateKey_new_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_CreateKey_new_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_CreateKey_action_taken(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_CreateKey_action_taken_, NDR_POINTER_UNIQUE, "Pointer to Action Taken (winreg_CreateAction)",hf_winreg_winreg_CreateKey_action_taken); + + return offset; +} + +static int +winreg_dissect_element_CreateKey_action_taken_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_enum_CreateAction(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_CreateKey_action_taken, 0); + + return offset; +} + +/* IDL: WERROR winreg_CreateKey( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [in] winreg_String name, */ +/* IDL: [in] winreg_String class, */ +/* IDL: [in] uint32 options, */ +/* IDL: [in] uint32 access_required, */ +/* IDL: [unique(1)] [in] winreg_SecBuf *secdesc, */ +/* IDL: [out] [ref] policy_handle *new_handle, */ +/* IDL: [out] [unique(1)] [in] winreg_CreateAction *action_taken */ +/* IDL: ); */ + +static int +winreg_dissect_CreateKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_CreateKey_new_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_CreateKey_action_taken(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_CreateKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_CreateKey_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_CreateKey_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_CreateKey_class(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_CreateKey_options(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_CreateKey_access_required(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_CreateKey_secdesc(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_CreateKey_action_taken(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_DeleteKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_DeleteKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_DeleteKey_handle); + + return offset; +} + +static int +winreg_dissect_element_DeleteKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_DeleteKey_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_DeleteKey_key(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_DeleteKey_key,0); + + return offset; +} + +/* IDL: WERROR winreg_DeleteKey( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [in] winreg_String key */ +/* IDL: ); */ + +static int +winreg_dissect_DeleteKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_DeleteKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_DeleteKey_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_DeleteKey_key(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_DeleteValue_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_DeleteValue_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_DeleteValue_handle); + + return offset; +} + +static int +winreg_dissect_element_DeleteValue_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_DeleteValue_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_DeleteValue_value(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_DeleteValue_value,0); + + return offset; +} + +/* IDL: WERROR winreg_DeleteValue( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [in] winreg_String value */ +/* IDL: ); */ + +static int +winreg_dissect_DeleteValue_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_DeleteValue_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_DeleteValue_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_DeleteValue_value(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_EnumKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_EnumKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_EnumKey_handle); + + return offset; +} + +static int +winreg_dissect_element_EnumKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_EnumKey_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_EnumKey_enum_index(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_EnumKey_enum_index,NULL); + + return offset; +} + +static int +winreg_dissect_element_EnumKey_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_EnumKey_name_, NDR_POINTER_REF, "Pointer to Name (winreg_StringBuf)",hf_winreg_winreg_EnumKey_name); + + return offset; +} + +static int +winreg_dissect_element_EnumKey_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_StringBuf(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_EnumKey_name,0); + + return offset; +} + +static int +winreg_dissect_element_EnumKey_class(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_EnumKey_class_, NDR_POINTER_UNIQUE, "Pointer to Class (winreg_StringBuf)",hf_winreg_winreg_EnumKey_class); + + return offset; +} + +static int +winreg_dissect_element_EnumKey_class_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_StringBuf(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_EnumKey_class,0); + + return offset; +} + +static int +winreg_dissect_element_EnumKey_last_changed_time(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_EnumKey_last_changed_time_, NDR_POINTER_UNIQUE, "Pointer to Last Changed Time (NTTIME)",hf_winreg_winreg_EnumKey_last_changed_time); + + return offset; +} + +static int +winreg_dissect_element_EnumKey_last_changed_time_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_nt_NTTIME(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_EnumKey_last_changed_time); + + return offset; +} + +/* IDL: WERROR winreg_EnumKey( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [in] uint32 enum_index, */ +/* IDL: [out] [in] [ref] winreg_StringBuf *name, */ +/* IDL: [out] [unique(1)] [in] winreg_StringBuf *class, */ +/* IDL: [out] [unique(1)] [in] NTTIME *last_changed_time */ +/* IDL: ); */ + +static int +winreg_dissect_EnumKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_EnumKey_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_EnumKey_class(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_EnumKey_last_changed_time(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_EnumKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_EnumKey_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_EnumKey_enum_index(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_EnumKey_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_EnumKey_class(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_EnumKey_last_changed_time(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_EnumValue_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_EnumValue_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_EnumValue_handle); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_EnumValue_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_enum_index(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_EnumValue_enum_index,NULL); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_EnumValue_name_, NDR_POINTER_REF, "Pointer to Name (winreg_StringBuf)",hf_winreg_winreg_EnumValue_name); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_StringBuf(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_EnumValue_name,0); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_type(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_EnumValue_type_, NDR_POINTER_UNIQUE, "Pointer to Type (winreg_Type)",hf_winreg_winreg_EnumValue_type); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_type_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_enum_Type(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_EnumValue_type, 0); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_value(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_EnumValue_value_, NDR_POINTER_UNIQUE, "Pointer to Value (uint8)",hf_winreg_winreg_EnumValue_value); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_value_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, drep, winreg_dissect_element_EnumValue_value__); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_value__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_EnumValue_value,NULL); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_EnumValue_size_, NDR_POINTER_UNIQUE, "Pointer to Size (uint32)",hf_winreg_winreg_EnumValue_size); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_size_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_EnumValue_size,NULL); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_length(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_EnumValue_length_, NDR_POINTER_UNIQUE, "Pointer to Length (uint32)",hf_winreg_winreg_EnumValue_length); + + return offset; +} + +static int +winreg_dissect_element_EnumValue_length_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_EnumValue_length,NULL); + + return offset; +} + +/* IDL: WERROR winreg_EnumValue( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [in] uint32 enum_index, */ +/* IDL: [out] [in] [ref] winreg_StringBuf *name, */ +/* IDL: [out] [unique(1)] [in] winreg_Type *type, */ +/* IDL: [out] [unique(1)] [in] [length_is(*length)] [size_is(*size)] uint8 *value, */ +/* IDL: [out] [unique(1)] [in] uint32 *size, */ +/* IDL: [out] [unique(1)] [in] uint32 *length */ +/* IDL: ); */ + +static int +winreg_dissect_EnumValue_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_EnumValue_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_EnumValue_type(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_EnumValue_value(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_EnumValue_size(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_EnumValue_length(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_EnumValue_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_EnumValue_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_EnumValue_enum_index(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_EnumValue_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_EnumValue_type(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_EnumValue_value(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_EnumValue_size(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_EnumValue_length(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_FlushKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_FlushKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_FlushKey_handle); + + return offset; +} + +static int +winreg_dissect_element_FlushKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_FlushKey_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +/* IDL: WERROR winreg_FlushKey( */ +/* IDL: [in] [ref] policy_handle *handle */ +/* IDL: ); */ + +static int +winreg_dissect_FlushKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_FlushKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_FlushKey_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_GetKeySecurity_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_GetKeySecurity_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_GetKeySecurity_handle); + + return offset; +} + +static int +winreg_dissect_element_GetKeySecurity_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_GetKeySecurity_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_GetKeySecurity_sec_info(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_GetKeySecurity_sec_info, NULL); + + return offset; +} + +static int +winreg_dissect_element_GetKeySecurity_sd(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_GetKeySecurity_sd_, NDR_POINTER_REF, "Pointer to Sd (KeySecurityData)",hf_winreg_winreg_GetKeySecurity_sd); + + return offset; +} + +static int +winreg_dissect_element_GetKeySecurity_sd_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_KeySecurityData(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_GetKeySecurity_sd,0); + + return offset; +} + +/* IDL: WERROR winreg_GetKeySecurity( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [in] security_secinfo sec_info, */ +/* IDL: [out] [in] [ref] KeySecurityData *sd */ +/* IDL: ); */ + +static int +winreg_dissect_GetKeySecurity_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_GetKeySecurity_sd(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_GetKeySecurity_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_GetKeySecurity_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_GetKeySecurity_sec_info(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_GetKeySecurity_sd(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_LoadKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_LoadKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_LoadKey_handle); + + return offset; +} + +static int +winreg_dissect_element_LoadKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_LoadKey_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_LoadKey_keyname(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_LoadKey_keyname_, NDR_POINTER_UNIQUE, "Pointer to Keyname (winreg_String)",hf_winreg_winreg_LoadKey_keyname); + + return offset; +} + +static int +winreg_dissect_element_LoadKey_keyname_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_LoadKey_keyname,0); + + return offset; +} + +static int +winreg_dissect_element_LoadKey_filename(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_LoadKey_filename_, NDR_POINTER_UNIQUE, "Pointer to Filename (winreg_String)",hf_winreg_winreg_LoadKey_filename); + + return offset; +} + +static int +winreg_dissect_element_LoadKey_filename_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_LoadKey_filename,0); + + return offset; +} + +/* IDL: WERROR winreg_LoadKey( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [unique(1)] [in] winreg_String *keyname, */ +/* IDL: [unique(1)] [in] winreg_String *filename */ +/* IDL: ); */ + +static int +winreg_dissect_LoadKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_LoadKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_LoadKey_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_LoadKey_keyname(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_LoadKey_filename(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_NotifyChangeKeyValue_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_NotifyChangeKeyValue_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_NotifyChangeKeyValue_handle); + + return offset; +} + +static int +winreg_dissect_element_NotifyChangeKeyValue_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_NotifyChangeKeyValue_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_NotifyChangeKeyValue_watch_subtree(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_NotifyChangeKeyValue_watch_subtree,NULL); + + return offset; +} + +static int +winreg_dissect_element_NotifyChangeKeyValue_notify_filter(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_NotifyChangeKeyValue_notify_filter,NULL); + + return offset; +} + +static int +winreg_dissect_element_NotifyChangeKeyValue_unknown(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_NotifyChangeKeyValue_unknown,NULL); + + return offset; +} + +static int +winreg_dissect_element_NotifyChangeKeyValue_string1(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_NotifyChangeKeyValue_string1,0); + + return offset; +} + +static int +winreg_dissect_element_NotifyChangeKeyValue_string2(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_NotifyChangeKeyValue_string2,0); + + return offset; +} + +static int +winreg_dissect_element_NotifyChangeKeyValue_unknown2(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_NotifyChangeKeyValue_unknown2,NULL); + + return offset; +} + +/* IDL: WERROR winreg_NotifyChangeKeyValue( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [in] uint8 watch_subtree, */ +/* IDL: [in] uint32 notify_filter, */ +/* IDL: [in] uint32 unknown, */ +/* IDL: [in] winreg_String string1, */ +/* IDL: [in] winreg_String string2, */ +/* IDL: [in] uint32 unknown2 */ +/* IDL: ); */ + +static int +winreg_dissect_NotifyChangeKeyValue_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_NotifyChangeKeyValue_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_NotifyChangeKeyValue_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_NotifyChangeKeyValue_watch_subtree(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_NotifyChangeKeyValue_notify_filter(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_NotifyChangeKeyValue_unknown(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_NotifyChangeKeyValue_string1(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_NotifyChangeKeyValue_string2(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_NotifyChangeKeyValue_unknown2(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_OpenKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_OpenKey_handle); + + return offset; +} + +static int +winreg_dissect_element_OpenKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenKey_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_OpenKey_keyname(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_OpenKey_keyname,0); + + return offset; +} + +static int +winreg_dissect_element_OpenKey_unknown(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenKey_unknown,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenKey_access_mask(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenKey_access_mask,NULL); + + return offset; +} + +/* IDL: WERROR winreg_OpenKey( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [in] winreg_String keyname, */ +/* IDL: [in] uint32 unknown, */ +/* IDL: [in] uint32 access_mask, */ +/* IDL: [out] [ref] policy_handle *handle */ +/* IDL: ); */ + +static int +winreg_dissect_OpenKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenKey_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_OpenKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenKey_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_OpenKey_keyname(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_OpenKey_unknown(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_OpenKey_access_mask(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_QueryInfoKey_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryInfoKey_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_QueryInfoKey_handle); + + return offset; +} + +static int +winreg_dissect_element_QueryInfoKey_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryInfoKey_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_QueryInfoKey_class(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_QueryInfoKey_class,0); + + return offset; +} + +static int +winreg_dissect_element_QueryInfoKey_num_subkeys(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryInfoKey_num_subkeys,NULL); + + return offset; +} + +static int +winreg_dissect_element_QueryInfoKey_max_subkeylen(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryInfoKey_max_subkeylen,NULL); + + return offset; +} + +static int +winreg_dissect_element_QueryInfoKey_max_subkeysize(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryInfoKey_max_subkeysize,NULL); + + return offset; +} + +static int +winreg_dissect_element_QueryInfoKey_num_values(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryInfoKey_num_values,NULL); + + return offset; +} + +static int +winreg_dissect_element_QueryInfoKey_max_valnamelen(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryInfoKey_max_valnamelen,NULL); + + return offset; +} + +static int +winreg_dissect_element_QueryInfoKey_max_valbufsize(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryInfoKey_max_valbufsize,NULL); + + return offset; +} + +static int +winreg_dissect_element_QueryInfoKey_secdescsize(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryInfoKey_secdescsize,NULL); + + return offset; +} + +static int +winreg_dissect_element_QueryInfoKey_last_changed_time(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_nt_NTTIME(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryInfoKey_last_changed_time); + + return offset; +} + +/* IDL: WERROR winreg_QueryInfoKey( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [in] winreg_String class, */ +/* IDL: [out] winreg_String class, */ +/* IDL: [out] uint32 num_subkeys, */ +/* IDL: [out] uint32 max_subkeylen, */ +/* IDL: [out] uint32 max_subkeysize, */ +/* IDL: [out] uint32 num_values, */ +/* IDL: [out] uint32 max_valnamelen, */ +/* IDL: [out] uint32 max_valbufsize, */ +/* IDL: [out] uint32 secdescsize, */ +/* IDL: [out] NTTIME last_changed_time */ +/* IDL: ); */ + +static int +winreg_dissect_QueryInfoKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_QueryInfoKey_class(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryInfoKey_num_subkeys(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryInfoKey_max_subkeylen(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryInfoKey_max_subkeysize(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryInfoKey_num_values(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryInfoKey_max_valnamelen(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryInfoKey_max_valbufsize(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryInfoKey_secdescsize(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryInfoKey_last_changed_time(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_QueryInfoKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_QueryInfoKey_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_QueryInfoKey_class(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_QueryValue_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryValue_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_QueryValue_handle); + + return offset; +} + +static int +winreg_dissect_element_QueryValue_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryValue_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_QueryValue_value_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_QueryValue_value_name,0); + + return offset; +} + +static int +winreg_dissect_element_QueryValue_type(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryValue_type_, NDR_POINTER_UNIQUE, "Pointer to Type (winreg_Type)",hf_winreg_winreg_QueryValue_type); + + return offset; +} + +static int +winreg_dissect_element_QueryValue_type_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_enum_Type(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryValue_type, 0); + + return offset; +} + +static int +winreg_dissect_element_QueryValue_data(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryValue_data_, NDR_POINTER_UNIQUE, "Pointer to Data (uint8)",hf_winreg_winreg_QueryValue_data); + + return offset; +} + +static int +winreg_dissect_element_QueryValue_data_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryValue_data__); + + return offset; +} + +static int +winreg_dissect_element_QueryValue_data__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryValue_data,NULL); + + return offset; +} + +static int +winreg_dissect_element_QueryValue_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryValue_size_, NDR_POINTER_UNIQUE, "Pointer to Size (uint32)",hf_winreg_winreg_QueryValue_size); + + return offset; +} + +static int +winreg_dissect_element_QueryValue_size_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryValue_size,NULL); + + return offset; +} + +static int +winreg_dissect_element_QueryValue_length(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryValue_length_, NDR_POINTER_UNIQUE, "Pointer to Length (uint32)",hf_winreg_winreg_QueryValue_length); + + return offset; +} + +static int +winreg_dissect_element_QueryValue_length_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryValue_length,NULL); + + return offset; +} + +/* IDL: WERROR winreg_QueryValue( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [in] winreg_String value_name, */ +/* IDL: [unique(1)] [out] [in] winreg_Type *type, */ +/* IDL: [unique(1)] [out] [in] [length_is(*length)] [size_is(*size)] uint8 *data, */ +/* IDL: [unique(1)] [out] [in] uint32 *size, */ +/* IDL: [unique(1)] [out] [in] uint32 *length */ +/* IDL: ); */ + +static int +winreg_dissect_QueryValue_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_QueryValue_type(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryValue_data(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryValue_size(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryValue_length(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_QueryValue_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_QueryValue_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_QueryValue_value_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_QueryValue_type(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_QueryValue_data(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_QueryValue_size(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_QueryValue_length(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +/* IDL: WERROR winreg_ReplaceKey( */ +/* IDL: */ +/* IDL: ); */ + +static int +winreg_dissect_ReplaceKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_ReplaceKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + return offset; +} + +/* IDL: WERROR winreg_RestoreKey( */ +/* IDL: */ +/* IDL: ); */ + +static int +winreg_dissect_RestoreKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_RestoreKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + return offset; +} + +/* IDL: WERROR winreg_SaveKey( */ +/* IDL: */ +/* IDL: ); */ + +static int +winreg_dissect_SaveKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_SaveKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + return offset; +} + +static int +winreg_dissect_element_SetKeySecurity_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_SetKeySecurity_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_SetKeySecurity_handle); + + return offset; +} + +static int +winreg_dissect_element_SetKeySecurity_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_SetKeySecurity_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_SetKeySecurity_access_mask(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_SetKeySecurity_access_mask,NULL); + + return offset; +} + +static int +winreg_dissect_element_SetKeySecurity_data(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_SetKeySecurity_data_, NDR_POINTER_REF, "Pointer to Data (KeySecurityData)",hf_winreg_winreg_SetKeySecurity_data); + + return offset; +} + +static int +winreg_dissect_element_SetKeySecurity_data_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_KeySecurityData(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_SetKeySecurity_data,0); + + return offset; +} + +/* IDL: WERROR winreg_SetKeySecurity( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [in] uint32 access_mask, */ +/* IDL: [out] [in] [ref] KeySecurityData *data */ +/* IDL: ); */ + +static int +winreg_dissect_SetKeySecurity_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_SetKeySecurity_data(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_SetKeySecurity_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_SetKeySecurity_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_SetKeySecurity_access_mask(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_SetKeySecurity_data(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_SetValue_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_SetValue_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_SetValue_handle); + + return offset; +} + +static int +winreg_dissect_element_SetValue_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_SetValue_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_SetValue_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_SetValue_name,0); + + return offset; +} + +static int +winreg_dissect_element_SetValue_type(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_enum_Type(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_SetValue_type, 0); + + return offset; +} + +static int +winreg_dissect_element_SetValue_data(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_SetValue_data_, NDR_POINTER_REF, "Pointer to Data (uint8)",hf_winreg_winreg_SetValue_data); + + return offset; +} + +static int +winreg_dissect_element_SetValue_data_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_ucarray(tvb, offset, pinfo, tree, drep, winreg_dissect_element_SetValue_data__); + + return offset; +} + +static int +winreg_dissect_element_SetValue_data__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_SetValue_data,NULL); + + return offset; +} + +static int +winreg_dissect_element_SetValue_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_SetValue_size,NULL); + + return offset; +} + +/* IDL: WERROR winreg_SetValue( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [in] winreg_String name, */ +/* IDL: [in] winreg_Type type, */ +/* IDL: [in] [ref] [size_is(size)] uint8 *data, */ +/* IDL: [in] uint32 size */ +/* IDL: ); */ + +static int +winreg_dissect_SetValue_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_SetValue_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_SetValue_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_SetValue_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_SetValue_type(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_SetValue_data(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_SetValue_size(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +/* IDL: WERROR winreg_UnLoadKey( */ +/* IDL: */ +/* IDL: ); */ + +static int +winreg_dissect_UnLoadKey_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_UnLoadKey_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdown_hostname(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_InitiateSystemShutdown_hostname_, NDR_POINTER_UNIQUE, "Pointer to Hostname (uint16)",hf_winreg_winreg_InitiateSystemShutdown_hostname); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdown_hostname_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_InitiateSystemShutdown_hostname,NULL); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdown_message(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_InitiateSystemShutdown_message_, NDR_POINTER_UNIQUE, "Pointer to Message (initshutdown_String)",hf_winreg_winreg_InitiateSystemShutdown_message); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdown_message_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = initshutdown_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_InitiateSystemShutdown_message,0); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdown_timeout(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_InitiateSystemShutdown_timeout,NULL); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdown_force_apps(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_InitiateSystemShutdown_force_apps,NULL); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdown_reboot(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_InitiateSystemShutdown_reboot,NULL); + + return offset; +} + +/* IDL: WERROR winreg_InitiateSystemShutdown( */ +/* IDL: [unique(1)] [in] uint16 *hostname, */ +/* IDL: [unique(1)] [in] initshutdown_String *message, */ +/* IDL: [in] uint32 timeout, */ +/* IDL: [in] uint8 force_apps, */ +/* IDL: [in] uint8 reboot */ +/* IDL: ); */ + +static int +winreg_dissect_InitiateSystemShutdown_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_InitiateSystemShutdown_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_InitiateSystemShutdown_hostname(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_InitiateSystemShutdown_message(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_InitiateSystemShutdown_timeout(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_InitiateSystemShutdown_force_apps(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_InitiateSystemShutdown_reboot(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_AbortSystemShutdown_server(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_AbortSystemShutdown_server_, NDR_POINTER_UNIQUE, "Pointer to Server (uint16)",hf_winreg_winreg_AbortSystemShutdown_server); + + return offset; +} + +static int +winreg_dissect_element_AbortSystemShutdown_server_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_AbortSystemShutdown_server,NULL); + + return offset; +} + +/* IDL: WERROR winreg_AbortSystemShutdown( */ +/* IDL: [unique(1)] [in] uint16 *server */ +/* IDL: ); */ + +static int +winreg_dissect_AbortSystemShutdown_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_AbortSystemShutdown_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_AbortSystemShutdown_server(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_GetVersion_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_GetVersion_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_GetVersion_handle); + + return offset; +} + +static int +winreg_dissect_element_GetVersion_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_GetVersion_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_GetVersion_version(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_GetVersion_version,NULL); + + return offset; +} + +/* IDL: WERROR winreg_GetVersion( */ +/* IDL: [in] [ref] policy_handle *handle, */ +/* IDL: [out] uint32 version */ +/* IDL: ); */ + +static int +winreg_dissect_GetVersion_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_GetVersion_version(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_GetVersion_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_GetVersion_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_OpenHKCC_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKCC_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_winreg_OpenHKCC_system_name); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCC_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKCC_system_name,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCC_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKCC_access_required,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCC_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKCC_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_OpenHKCC_handle); + + return offset; +} + +static int +winreg_dissect_element_OpenHKCC_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKCC_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +/* IDL: WERROR winreg_OpenHKCC( */ +/* IDL: [unique(1)] [in] uint16 *system_name, */ +/* IDL: [in] uint32 access_required, */ +/* IDL: [out] [ref] policy_handle *handle */ +/* IDL: ); */ + +static int +winreg_dissect_OpenHKCC_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKCC_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_OpenHKCC_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKCC_system_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_OpenHKCC_access_required(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_OpenHKDD_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKDD_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_winreg_OpenHKDD_system_name); + + return offset; +} + +static int +winreg_dissect_element_OpenHKDD_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKDD_system_name,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKDD_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKDD_access_required,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKDD_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKDD_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_OpenHKDD_handle); + + return offset; +} + +static int +winreg_dissect_element_OpenHKDD_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKDD_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +/* IDL: WERROR winreg_OpenHKDD( */ +/* IDL: [unique(1)] [in] uint16 *system_name, */ +/* IDL: [in] uint32 access_required, */ +/* IDL: [out] [ref] policy_handle *handle */ +/* IDL: ); */ + +static int +winreg_dissect_OpenHKDD_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKDD_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_OpenHKDD_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKDD_system_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_OpenHKDD_access_required(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValues_key_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryMultipleValues_key_handle_, NDR_POINTER_REF, "Pointer to Key Handle (policy_handle)",hf_winreg_winreg_QueryMultipleValues_key_handle); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValues_key_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryMultipleValues_key_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValues_values(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryMultipleValues_values_, NDR_POINTER_REF, "Pointer to Values (QueryMultipleValue)",hf_winreg_winreg_QueryMultipleValues_values); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValues_values_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryMultipleValues_values__); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValues_values__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = winreg_dissect_struct_QueryMultipleValue(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_QueryMultipleValues_values,0); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValues_num_values(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryMultipleValues_num_values,NULL); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValues_buffer(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryMultipleValues_buffer_, NDR_POINTER_UNIQUE, "Pointer to Buffer (uint8)",hf_winreg_winreg_QueryMultipleValues_buffer); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValues_buffer_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_ucvarray(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryMultipleValues_buffer__); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValues_buffer__(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryMultipleValues_buffer,NULL); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValues_buffer_size(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_QueryMultipleValues_buffer_size_, NDR_POINTER_REF, "Pointer to Buffer Size (uint32)",hf_winreg_winreg_QueryMultipleValues_buffer_size); + + return offset; +} + +static int +winreg_dissect_element_QueryMultipleValues_buffer_size_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_QueryMultipleValues_buffer_size,NULL); + + return offset; +} + +/* IDL: WERROR winreg_QueryMultipleValues( */ +/* IDL: [in] [ref] policy_handle *key_handle, */ +/* IDL: [out] [in] [ref] [length_is(num_values)] [size_is(num_values)] QueryMultipleValue *values, */ +/* IDL: [in] uint32 num_values, */ +/* IDL: [unique(1)] [out] [in] [length_is(*buffer_size)] [size_is(*buffer_size)] uint8 *buffer, */ +/* IDL: [out] [in] [ref] uint32 *buffer_size */ +/* IDL: ); */ + +static int +winreg_dissect_QueryMultipleValues_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_QueryMultipleValues_values(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryMultipleValues_buffer(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = winreg_dissect_element_QueryMultipleValues_buffer_size(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_QueryMultipleValues_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_QueryMultipleValues_key_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_QueryMultipleValues_values(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_QueryMultipleValues_num_values(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_QueryMultipleValues_buffer(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_QueryMultipleValues_buffer_size(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdownEx_hostname(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_InitiateSystemShutdownEx_hostname_, NDR_POINTER_UNIQUE, "Pointer to Hostname (uint16)",hf_winreg_winreg_InitiateSystemShutdownEx_hostname); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdownEx_hostname_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_InitiateSystemShutdownEx_hostname,NULL); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdownEx_message(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_InitiateSystemShutdownEx_message_, NDR_POINTER_UNIQUE, "Pointer to Message (initshutdown_String)",hf_winreg_winreg_InitiateSystemShutdownEx_message); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdownEx_message_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = initshutdown_dissect_struct_String(tvb,offset,pinfo,tree,drep,hf_winreg_winreg_InitiateSystemShutdownEx_message,0); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdownEx_timeout(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_InitiateSystemShutdownEx_timeout,NULL); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdownEx_force_apps(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_InitiateSystemShutdownEx_force_apps,NULL); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdownEx_reboot(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint8(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_InitiateSystemShutdownEx_reboot,NULL); + + return offset; +} + +static int +winreg_dissect_element_InitiateSystemShutdownEx_reason(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_InitiateSystemShutdownEx_reason,NULL); + + return offset; +} + +/* IDL: WERROR winreg_InitiateSystemShutdownEx( */ +/* IDL: [unique(1)] [in] uint16 *hostname, */ +/* IDL: [unique(1)] [in] initshutdown_String *message, */ +/* IDL: [in] uint32 timeout, */ +/* IDL: [in] uint8 force_apps, */ +/* IDL: [in] uint8 reboot, */ +/* IDL: [in] uint32 reason */ +/* IDL: ); */ + +static int +winreg_dissect_InitiateSystemShutdownEx_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_InitiateSystemShutdownEx_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_InitiateSystemShutdownEx_hostname(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_InitiateSystemShutdownEx_message(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_InitiateSystemShutdownEx_timeout(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_InitiateSystemShutdownEx_force_apps(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_InitiateSystemShutdownEx_reboot(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_InitiateSystemShutdownEx_reason(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +/* IDL: WERROR winreg_SaveKeyEx( */ +/* IDL: */ +/* IDL: ); */ + +static int +winreg_dissect_SaveKeyEx_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_SaveKeyEx_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + return offset; +} + +static int +winreg_dissect_element_OpenHKPT_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKPT_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_winreg_OpenHKPT_system_name); + + return offset; +} + +static int +winreg_dissect_element_OpenHKPT_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKPT_system_name,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKPT_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKPT_access_required,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKPT_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKPT_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_OpenHKPT_handle); + + return offset; +} + +static int +winreg_dissect_element_OpenHKPT_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKPT_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +/* IDL: WERROR winreg_OpenHKPT( */ +/* IDL: [unique(1)] [in] uint16 *system_name, */ +/* IDL: [in] uint32 access_required, */ +/* IDL: [out] [ref] policy_handle *handle */ +/* IDL: ); */ + +static int +winreg_dissect_OpenHKPT_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKPT_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_OpenHKPT_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKPT_system_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_OpenHKPT_access_required(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +static int +winreg_dissect_element_OpenHKPN_system_name(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKPN_system_name_, NDR_POINTER_UNIQUE, "Pointer to System Name (uint16)",hf_winreg_winreg_OpenHKPN_system_name); + + return offset; +} + +static int +winreg_dissect_element_OpenHKPN_system_name_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint16(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKPN_system_name,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKPN_access_required(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKPN_access_required,NULL); + + return offset; +} + +static int +winreg_dissect_element_OpenHKPN_handle(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_ndr_toplevel_pointer(tvb, offset, pinfo, tree, drep, winreg_dissect_element_OpenHKPN_handle_, NDR_POINTER_REF, "Pointer to Handle (policy_handle)",hf_winreg_winreg_OpenHKPN_handle); + + return offset; +} + +static int +winreg_dissect_element_OpenHKPN_handle_(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep) +{ + offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep, hf_winreg_winreg_OpenHKPN_handle, NULL, NULL, 0&0x01, 0&0x02); + + return offset; +} + +/* IDL: WERROR winreg_OpenHKPN( */ +/* IDL: [unique(1)] [in] uint16 *system_name, */ +/* IDL: [in] uint32 access_required, */ +/* IDL: [out] [ref] policy_handle *handle */ +/* IDL: ); */ + +static int +winreg_dissect_OpenHKPN_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKPN_handle(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_OpenHKPN_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = winreg_dissect_element_OpenHKPN_system_name(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + offset = winreg_dissect_element_OpenHKPN_access_required(tvb, offset, pinfo, tree, drep); + offset = dissect_deferred_pointers(pinfo, tvb, offset, drep); + return offset; +} + +/* IDL: WERROR winreg_QueryMultipleValues2( */ +/* IDL: */ +/* IDL: ); */ + +static int +winreg_dissect_QueryMultipleValues2_response(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep, hf_winreg_werror, NULL); + return offset; +} + +static int +winreg_dissect_QueryMultipleValues2_request(tvbuff_t *tvb _U_, int offset _U_, packet_info *pinfo _U_, proto_tree *tree _U_, guint8 *drep _U_) +{ + return offset; +} + + +static dcerpc_sub_dissector winreg_dissectors[] = { + { 0, "OpenHKCR", + winreg_dissect_OpenHKCR_request, winreg_dissect_OpenHKCR_response}, + { 1, "OpenHKCU", + winreg_dissect_OpenHKCU_request, winreg_dissect_OpenHKCU_response}, + { 2, "OpenHKLM", + winreg_dissect_OpenHKLM_request, winreg_dissect_OpenHKLM_response}, + { 3, "OpenHKPD", + winreg_dissect_OpenHKPD_request, winreg_dissect_OpenHKPD_response}, + { 4, "OpenHKU", + winreg_dissect_OpenHKU_request, winreg_dissect_OpenHKU_response}, + { 5, "CloseKey", + winreg_dissect_CloseKey_request, winreg_dissect_CloseKey_response}, + { 6, "CreateKey", + winreg_dissect_CreateKey_request, winreg_dissect_CreateKey_response}, + { 7, "DeleteKey", + winreg_dissect_DeleteKey_request, winreg_dissect_DeleteKey_response}, + { 8, "DeleteValue", + winreg_dissect_DeleteValue_request, winreg_dissect_DeleteValue_response}, + { 9, "EnumKey", + winreg_dissect_EnumKey_request, winreg_dissect_EnumKey_response}, + { 10, "EnumValue", + winreg_dissect_EnumValue_request, winreg_dissect_EnumValue_response}, + { 11, "FlushKey", + winreg_dissect_FlushKey_request, winreg_dissect_FlushKey_response}, + { 12, "GetKeySecurity", + winreg_dissect_GetKeySecurity_request, winreg_dissect_GetKeySecurity_response}, + { 13, "LoadKey", + winreg_dissect_LoadKey_request, winreg_dissect_LoadKey_response}, + { 14, "NotifyChangeKeyValue", + winreg_dissect_NotifyChangeKeyValue_request, winreg_dissect_NotifyChangeKeyValue_response}, + { 15, "OpenKey", + winreg_dissect_OpenKey_request, winreg_dissect_OpenKey_response}, + { 16, "QueryInfoKey", + winreg_dissect_QueryInfoKey_request, winreg_dissect_QueryInfoKey_response}, + { 17, "QueryValue", + winreg_dissect_QueryValue_request, winreg_dissect_QueryValue_response}, + { 18, "ReplaceKey", + winreg_dissect_ReplaceKey_request, winreg_dissect_ReplaceKey_response}, + { 19, "RestoreKey", + winreg_dissect_RestoreKey_request, winreg_dissect_RestoreKey_response}, + { 20, "SaveKey", + winreg_dissect_SaveKey_request, winreg_dissect_SaveKey_response}, + { 21, "SetKeySecurity", + winreg_dissect_SetKeySecurity_request, winreg_dissect_SetKeySecurity_response}, + { 22, "SetValue", + winreg_dissect_SetValue_request, winreg_dissect_SetValue_response}, + { 23, "UnLoadKey", + winreg_dissect_UnLoadKey_request, winreg_dissect_UnLoadKey_response}, + { 24, "InitiateSystemShutdown", + winreg_dissect_InitiateSystemShutdown_request, winreg_dissect_InitiateSystemShutdown_response}, + { 25, "AbortSystemShutdown", + winreg_dissect_AbortSystemShutdown_request, winreg_dissect_AbortSystemShutdown_response}, + { 26, "GetVersion", + winreg_dissect_GetVersion_request, winreg_dissect_GetVersion_response}, + { 27, "OpenHKCC", + winreg_dissect_OpenHKCC_request, winreg_dissect_OpenHKCC_response}, + { 28, "OpenHKDD", + winreg_dissect_OpenHKDD_request, winreg_dissect_OpenHKDD_response}, + { 29, "QueryMultipleValues", + winreg_dissect_QueryMultipleValues_request, winreg_dissect_QueryMultipleValues_response}, + { 30, "InitiateSystemShutdownEx", + winreg_dissect_InitiateSystemShutdownEx_request, winreg_dissect_InitiateSystemShutdownEx_response}, + { 31, "SaveKeyEx", + winreg_dissect_SaveKeyEx_request, winreg_dissect_SaveKeyEx_response}, + { 32, "OpenHKPT", + winreg_dissect_OpenHKPT_request, winreg_dissect_OpenHKPT_response}, + { 33, "OpenHKPN", + winreg_dissect_OpenHKPN_request, winreg_dissect_OpenHKPN_response}, + { 34, "QueryMultipleValues2", + winreg_dissect_QueryMultipleValues2_request, winreg_dissect_QueryMultipleValues2_response}, + { 0, NULL, NULL, NULL } +}; + +void proto_register_dcerpc_winreg(void) +{ + static hf_register_info hf[] = { + { &hf_winreg_winreg_OpenHKCC_access_required, + { "Access Required", "winreg.winreg_OpenHKCC.access_required", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_NotifyChangeKeyValue_string2, + { "String2", "winreg.winreg_NotifyChangeKeyValue.string2", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_InitiateSystemShutdown_message, + { "Message", "winreg.winreg_InitiateSystemShutdown.message", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_String_name, + { "Name", "winreg.winreg_String.name", FT_STRING, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_InitiateSystemShutdownEx_message, + { "Message", "winreg.winreg_InitiateSystemShutdownEx.message", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_InitiateSystemShutdown_reboot, + { "Reboot", "winreg.winreg_InitiateSystemShutdown.reboot", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKPN_access_required, + { "Access Required", "winreg.winreg_OpenHKPN.access_required", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_EnumValue_enum_index, + { "Enum Index", "winreg.winreg_EnumValue.enum_index", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_CreateKey_options, + { "Options", "winreg.winreg_CreateKey.options", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_InitiateSystemShutdownEx_timeout, + { "Timeout", "winreg.winreg_InitiateSystemShutdownEx.timeout", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryValue_size, + { "Size", "winreg.winreg_QueryValue.size", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryInfoKey_max_valnamelen, + { "Max Valnamelen", "winreg.winreg_QueryInfoKey.max_valnamelen", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_SecBuf_length, + { "Length", "winreg.winreg_SecBuf.length", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_InitiateSystemShutdownEx_reboot, + { "Reboot", "winreg.winreg_InitiateSystemShutdownEx.reboot", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKCC_handle, + { "Handle", "winreg.winreg_OpenHKCC.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryMultipleValues_buffer_size, + { "Buffer Size", "winreg.winreg_QueryMultipleValues.buffer_size", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKCU_handle, + { "Handle", "winreg.winreg_OpenHKCU.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_CreateKey_new_handle, + { "New Handle", "winreg.winreg_CreateKey.new_handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKPT_handle, + { "Handle", "winreg.winreg_OpenHKPT.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_EnumKey_class, + { "Class", "winreg.winreg_EnumKey.class", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_GetKeySecurity_handle, + { "Handle", "winreg.winreg_GetKeySecurity.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKCR_handle, + { "Handle", "winreg.winreg_OpenHKCR.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKLM_access_required, + { "Access Required", "winreg.winreg_OpenHKLM.access_required", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKPN_system_name, + { "System Name", "winreg.winreg_OpenHKPN.system_name", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKU_access_required, + { "Access Required", "winreg.winreg_OpenHKU.access_required", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_QueryMultipleValue_name, + { "Name", "winreg.QueryMultipleValue.name", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_GetKeySecurity_sec_info, + { "Sec Info", "winreg.winreg_GetKeySecurity.sec_info", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_StringBuf_size, + { "Size", "winreg.winreg_StringBuf.size", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKCR_access_required, + { "Access Required", "winreg.winreg_OpenHKCR.access_required", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_SecBuf_sd, + { "Sd", "winreg.winreg_SecBuf.sd", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_CreateKey_class, + { "Class", "winreg.winreg_CreateKey.class", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryInfoKey_secdescsize, + { "Secdescsize", "winreg.winreg_QueryInfoKey.secdescsize", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_SetValue_name, + { "Name", "winreg.winreg_SetValue.name", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKPT_system_name, + { "System Name", "winreg.winreg_OpenHKPT.system_name", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_CreateKey_secdesc, + { "Secdesc", "winreg.winreg_CreateKey.secdesc", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_InitiateSystemShutdownEx_force_apps, + { "Force Apps", "winreg.winreg_InitiateSystemShutdownEx.force_apps", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_SetValue_type, + { "Type", "winreg.winreg_SetValue.type", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_EnumValue_handle, + { "Handle", "winreg.winreg_EnumValue.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_DeleteValue_handle, + { "Handle", "winreg.winreg_DeleteValue.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_opnum, + { "Operation", "winreg.opnum", FT_UINT16, BASE_DEC, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_EnumValue_name, + { "Name", "winreg.winreg_EnumValue.name", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_LoadKey_filename, + { "Filename", "winreg.winreg_LoadKey.filename", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_DeleteValue_value, + { "Value", "winreg.winreg_DeleteValue.value", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKCU_access_required, + { "Access Required", "winreg.winreg_OpenHKCU.access_required", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_NotifyChangeKeyValue_handle, + { "Handle", "winreg.winreg_NotifyChangeKeyValue.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKDD_handle, + { "Handle", "winreg.winreg_OpenHKDD.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryInfoKey_num_subkeys, + { "Num Subkeys", "winreg.winreg_QueryInfoKey.num_subkeys", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryInfoKey_last_changed_time, + { "Last Changed Time", "winreg.winreg_QueryInfoKey.last_changed_time", FT_ABSOLUTE_TIME, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_AbortSystemShutdown_server, + { "Server", "winreg.winreg_AbortSystemShutdown.server", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryValue_type, + { "Type", "winreg.winreg_QueryValue.type", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_CloseKey_handle, + { "Handle", "winreg.winreg_CloseKey.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKU_system_name, + { "System Name", "winreg.winreg_OpenHKU.system_name", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKDD_system_name, + { "System Name", "winreg.winreg_OpenHKDD.system_name", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_DeleteKey_handle, + { "Handle", "winreg.winreg_DeleteKey.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_SecBuf_inherit, + { "Inherit", "winreg.winreg_SecBuf.inherit", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_SetValue_size, + { "Size", "winreg.winreg_SetValue.size", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryMultipleValues_values, + { "Values", "winreg.winreg_QueryMultipleValues.values", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKCC_system_name, + { "System Name", "winreg.winreg_OpenHKCC.system_name", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_GetVersion_version, + { "Version", "winreg.winreg_GetVersion.version", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_CreateKey_action_taken, + { "Action Taken", "winreg.winreg_CreateKey.action_taken", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryInfoKey_num_values, + { "Num Values", "winreg.winreg_QueryInfoKey.num_values", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_SetKeySecurity_data, + { "Data", "winreg.winreg_SetKeySecurity.data", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_EnumKey_enum_index, + { "Enum Index", "winreg.winreg_EnumKey.enum_index", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_SetValue_data, + { "Data", "winreg.winreg_SetValue.data", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_InitiateSystemShutdown_force_apps, + { "Force Apps", "winreg.winreg_InitiateSystemShutdown.force_apps", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_NotifyChangeKeyValue_string1, + { "String1", "winreg.winreg_NotifyChangeKeyValue.string1", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryMultipleValues_buffer, + { "Buffer", "winreg.winreg_QueryMultipleValues.buffer", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_SetValue_handle, + { "Handle", "winreg.winreg_SetValue.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_CreateKey_access_required, + { "Access Required", "winreg.winreg_CreateKey.access_required", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_NotifyChangeKeyValue_notify_filter, + { "Notify Filter", "winreg.winreg_NotifyChangeKeyValue.notify_filter", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKCU_system_name, + { "System Name", "winreg.winreg_OpenHKCU.system_name", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_KeySecurityData_size, + { "Size", "winreg.KeySecurityData.size", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKU_handle, + { "Handle", "winreg.winreg_OpenHKU.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKPD_handle, + { "Handle", "winreg.winreg_OpenHKPD.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_EnumKey_name, + { "Name", "winreg.winreg_EnumKey.name", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_LoadKey_keyname, + { "Keyname", "winreg.winreg_LoadKey.keyname", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryMultipleValues_key_handle, + { "Key Handle", "winreg.winreg_QueryMultipleValues.key_handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_EnumValue_type, + { "Type", "winreg.winreg_EnumValue.type", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_EnumKey_last_changed_time, + { "Last Changed Time", "winreg.winreg_EnumKey.last_changed_time", FT_ABSOLUTE_TIME, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_GetVersion_handle, + { "Handle", "winreg.winreg_GetVersion.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_EnumValue_size, + { "Size", "winreg.winreg_EnumValue.size", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenKey_handle, + { "Handle", "winreg.winreg_OpenKey.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKPN_handle, + { "Handle", "winreg.winreg_OpenHKPN.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryValue_data, + { "Data", "winreg.winreg_QueryValue.data", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryInfoKey_max_subkeysize, + { "Max Subkeysize", "winreg.winreg_QueryInfoKey.max_subkeysize", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKPD_system_name, + { "System Name", "winreg.winreg_OpenHKPD.system_name", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_InitiateSystemShutdown_hostname, + { "Hostname", "winreg.winreg_InitiateSystemShutdown.hostname", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_KeySecurityData_data, + { "Data", "winreg.KeySecurityData.data", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenKey_access_mask, + { "Access Mask", "winreg.winreg_OpenKey.access_mask", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryValue_handle, + { "Handle", "winreg.winreg_QueryValue.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenKey_keyname, + { "Keyname", "winreg.winreg_OpenKey.keyname", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_QueryMultipleValue_type, + { "Type", "winreg.QueryMultipleValue.type", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_NotifyChangeKeyValue_watch_subtree, + { "Watch Subtree", "winreg.winreg_NotifyChangeKeyValue.watch_subtree", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_SetKeySecurity_handle, + { "Handle", "winreg.winreg_SetKeySecurity.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKDD_access_required, + { "Access Required", "winreg.winreg_OpenHKDD.access_required", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_KeySecurityData_len, + { "Len", "winreg.KeySecurityData.len", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_CreateKey_name, + { "Name", "winreg.winreg_CreateKey.name", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKPD_access_required, + { "Access Required", "winreg.winreg_OpenHKPD.access_required", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_String_name_len, + { "Name Len", "winreg.winreg_String.name_len", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_DeleteKey_key, + { "Key", "winreg.winreg_DeleteKey.key", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_QueryMultipleValue_length, + { "Length", "winreg.QueryMultipleValue.length", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKPT_access_required, + { "Access Required", "winreg.winreg_OpenHKPT.access_required", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryMultipleValues_num_values, + { "Num Values", "winreg.winreg_QueryMultipleValues.num_values", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryInfoKey_handle, + { "Handle", "winreg.winreg_QueryInfoKey.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_StringBuf_name, + { "Name", "winreg.winreg_StringBuf.name", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_NotifyChangeKeyValue_unknown2, + { "Unknown2", "winreg.winreg_NotifyChangeKeyValue.unknown2", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_FlushKey_handle, + { "Handle", "winreg.winreg_FlushKey.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKLM_system_name, + { "System Name", "winreg.winreg_OpenHKLM.system_name", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_CreateKey_handle, + { "Handle", "winreg.winreg_CreateKey.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_StringBuf_length, + { "Length", "winreg.winreg_StringBuf.length", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKCR_system_name, + { "System Name", "winreg.winreg_OpenHKCR.system_name", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenHKLM_handle, + { "Handle", "winreg.winreg_OpenHKLM.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_String_name_size, + { "Name Size", "winreg.winreg_String.name_size", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_NotifyChangeKeyValue_unknown, + { "Unknown", "winreg.winreg_NotifyChangeKeyValue.unknown", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryValue_length, + { "Length", "winreg.winreg_QueryValue.length", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_OpenKey_unknown, + { "Unknown", "winreg.winreg_OpenKey.unknown", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryInfoKey_max_valbufsize, + { "Max Valbufsize", "winreg.winreg_QueryInfoKey.max_valbufsize", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_InitiateSystemShutdownEx_reason, + { "Reason", "winreg.winreg_InitiateSystemShutdownEx.reason", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_EnumValue_length, + { "Length", "winreg.winreg_EnumValue.length", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryInfoKey_max_subkeylen, + { "Max Subkeylen", "winreg.winreg_QueryInfoKey.max_subkeylen", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_InitiateSystemShutdown_timeout, + { "Timeout", "winreg.winreg_InitiateSystemShutdown.timeout", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryInfoKey_class, + { "Class", "winreg.winreg_QueryInfoKey.class", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_InitiateSystemShutdownEx_hostname, + { "Hostname", "winreg.winreg_InitiateSystemShutdownEx.hostname", FT_UINT16, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_werror, + { "Windows Error", "winreg.werror", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_EnumValue_value, + { "Value", "winreg.winreg_EnumValue.value", FT_UINT8, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_SetKeySecurity_access_mask, + { "Access Mask", "winreg.winreg_SetKeySecurity.access_mask", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_GetKeySecurity_sd, + { "Sd", "winreg.winreg_GetKeySecurity.sd", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_QueryValue_value_name, + { "Value Name", "winreg.winreg_QueryValue.value_name", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_LoadKey_handle, + { "Handle", "winreg.winreg_LoadKey.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_winreg_EnumKey_handle, + { "Handle", "winreg.winreg_EnumKey.handle", FT_NONE, BASE_HEX, NULL, 0, "", HFILL }}, + { &hf_winreg_QueryMultipleValue_offset, + { "Offset", "winreg.QueryMultipleValue.offset", FT_UINT32, BASE_HEX, NULL, 0, "", HFILL }}, + }; + + + static gint *ett[] = { + &ett_dcerpc_winreg, + &ett_winreg_winreg_String, + &ett_winreg_KeySecurityData, + &ett_winreg_winreg_SecBuf, + &ett_winreg_winreg_StringBuf, + &ett_winreg_QueryMultipleValue, + }; + + proto_dcerpc_winreg = proto_register_protocol("Remote Registry Service", "WINREG", "winreg"); + proto_register_field_array(proto_dcerpc_winreg, hf, array_length (hf)); + proto_register_subtree_array(ett, array_length(ett)); +} + +void proto_reg_handoff_dcerpc_winreg(void) +{ + dcerpc_init_uuid(proto_dcerpc_winreg, ett_dcerpc_winreg, + &uuid_dcerpc_winreg, ver_dcerpc_winreg, + winreg_dissectors, hf_winreg_opnum); +} diff --git a/epan/dissectors/packet-dcerpc-winreg.h b/epan/dissectors/packet-dcerpc-winreg.h new file mode 100644 index 0000000000..5db62b57f2 --- /dev/null +++ b/epan/dissectors/packet-dcerpc-winreg.h @@ -0,0 +1,45 @@ +/* autogenerated by pidl */ + +/* DO NOT EDIT + This filter was automatically generated + from librpc/idl/winreg.idl and librpc/idl/winreg.cnf. + + Pidl is a perl based IDL compiler for DCE/RPC idl files. + It is maintained by the Samba team, not the Ethereal team. + Instructions on how to download and install Pidl can be + found at http://wiki.ethereal.com/Pidl +*/ + + +#ifndef __PACKET_DCERPC_WINREG_H +#define __PACKET_DCERPC_WINREG_H + +#include "packet-dcerpc-lsa.h" + +#include "packet-dcerpc-initshutdown.h" + +#define REG_NONE (0) +#define REG_SZ (1) +#define REG_EXPAND_SZ (2) +#define REG_BINARY (3) +#define REG_DWORD (4) +#define REG_DWORD_BIG_ENDIAN (5) +#define REG_LINK (6) +#define REG_MULTI_SZ (7) +#define REG_RESOURCE_LIST (8) +#define REG_FULL_RESOURCE_DESCRIPTOR (9) +#define REG_RESOURCE_REQUIREMENTS_LIST (10) +#define REG_QWORD (11) +extern const value_string winreg_winreg_Type_vals[]; +int winreg_dissect_enum_Type(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep, int hf_index, guint32 param); +int winreg_dissect_struct_String(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_); +int winreg_dissect_struct_KeySecurityData(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_); +int winreg_dissect_struct_SecBuf(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_); +#define REG_ACTION_NONE (0) +#define REG_CREATED_NEW_KEY (1) +#define REG_OPENED_EXISTING_KEY (2) +extern const value_string winreg_winreg_CreateAction_vals[]; +int winreg_dissect_enum_CreateAction(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *tree, guint8 *drep, int hf_index, guint32 param); +int winreg_dissect_struct_StringBuf(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_); +int winreg_dissect_struct_QueryMultipleValue(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, guint8 *drep, int hf_index, guint32 param _U_); +#endif /* __PACKET_DCERPC_WINREG_H */ |