/* packet-dcerpc-samr.c
- * Routines for SMB \\PIPE\\samr packet disassembly
+ * Routines for SMB \PIPE\samr packet disassembly
* Copyright 2001, Tim Potter <tpot@samba.org>
* 2002 Added all command dissectors Ronnie Sahlberg
*
- * $Id: packet-dcerpc-samr.c,v 1.23 2002/03/11 00:15:20 sahlberg Exp $
+ * $Id: packet-dcerpc-samr.c,v 1.33 2002/04/22 00:09:21 guy Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
#include <glib.h>
#include <epan/packet.h>
+#include <string.h>
#include "packet-dcerpc.h"
#include "packet-dcerpc-nt.h"
#include "packet-dcerpc-samr.h"
static int hf_nt_acb_autolock = -1;
static gint ett_dcerpc_samr = -1;
-gint ett_nt_unicode_string = -1; /* used by packet-dcerpc-nt.c*/
static gint ett_samr_user_dispinfo_1 = -1;
static gint ett_samr_user_dispinfo_1_array = -1;
static gint ett_samr_user_dispinfo_2 = -1;
static gint ett_samr_names = -1;
static gint ett_samr_rids = -1;
static gint ett_nt_acct_ctrl = -1;
-
+static gint ett_samr_sid_and_attributes_array = -1;
+static gint ett_samr_sid_and_attributes = -1;
+static gint ett_samr_hnd = -1;
static e_uuid_t uuid_dcerpc_samr = {
0x12345778, 0x1234, 0xabcd,
static guint16 ver_dcerpc_samr = 1;
-static int
-samr_dissect_SID(tvbuff_t *tvb, int offset,
+int
+dissect_ndr_nt_SID(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
char *drep)
{
}
static int
-samr_dissect_SID_ptr(tvbuff_t *tvb, int offset,
+dissect_ndr_nt_SID_ptr(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
char *drep)
{
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
- samr_dissect_SID, NDR_POINTER_UNIQUE,
+ dissect_ndr_nt_SID, NDR_POINTER_UNIQUE,
"SID pointer", -1, 1);
return offset;
}
*/
static int
-samr_dissect_context_handle_reply(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+samr_dissect_open_user_rqst(tvbuff_t *tvb, int offset, packet_info *pinfo,
+ proto_tree *tree, char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ dcerpc_info *di = (dcerpc_info *)pinfo->private_data;
+ dcerpc_call_value *dcv = (dcerpc_call_value *)di->call_data;
+ guint32 rid;
+
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "OpenUser request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+ hf_samr_access, NULL);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_rid, &rid);
+
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_append_fstr(pinfo->cinfo, COL_INFO, ", rid 0x%x", rid);
+
+ dcv->private_data = (void *)rid;
return offset;
}
-
static int
-samr_dissect_open_user_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+samr_dissect_open_user_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_access, NULL);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rid, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "OpenUser response");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
static int
-samr_dissect_query_dispinfo_rqst (tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+samr_dissect_query_dispinfo_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryDispInfo request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
hf_samr_level, NULL);
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_max_entries, NULL);
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_pref_maxsize, NULL);
+
return offset;
}
}
static int
-samr_dissect_query_dispinfo_reply (tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+samr_dissect_query_dispinfo_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryDispInfo response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_long, NDR_POINTER_REF,
"", hf_samr_total_size, 0);
return offset;
}
-
static int
samr_dissect_get_display_enumeration_index_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo,
+ proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "GetDispEnumIndex request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
hf_samr_level, NULL);
+
offset = dissect_ndr_nt_STRING(tvb, offset, pinfo, tree, drep,
hf_samr_acct_name, 0);
+
return offset;
}
-
static int
samr_dissect_get_display_enumeration_index_reply(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "GetDispEnumIndex response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_long, NDR_POINTER_REF,
"", hf_samr_index, 0);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
return offset;
}
+static int
+samr_dissect_get_usrdom_pwinfo_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "GetPwInfo request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ return offset;
+}
+
static int
samr_dissect_get_usrdom_pwinfo_reply(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "GetPwInfo response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_PASSWORD_INFO, NDR_POINTER_REF,
"", -1, 0);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
static int
samr_dissect_connect2_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "Connect2 request");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_connect2_server, NDR_POINTER_UNIQUE,
- "Server", hf_samr_server, 0);
+ "Server", hf_samr_server, 1);
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_access, NULL);
packet_info *pinfo, proto_tree *tree,
char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "Connect2 response");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+ return offset;
+}
+
+static int
+samr_dissect_connect_anon_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "ConnectAnon request");
+
+ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
+ samr_dissect_connect2_server, NDR_POINTER_UNIQUE,
+ "Server", hf_samr_server, 1);
+
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+ hf_samr_access, NULL);
+
return offset;
}
+static int
+samr_dissect_connect_anon_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "ConnectAnon response");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+ return offset;
+}
static int
samr_dissect_USER_GROUP(tvbuff_t *tvb, int offset,
return offset;
}
+static int
+samr_dissect_get_user_groups_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "GetUserGroups request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_get_groups_for_user_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "GetUserGroups request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ return offset;
+}
+
static int
samr_dissect_get_groups_for_user_reply(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "GetUserGroups response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_USER_GROUP_ARRAY_ptr, NDR_POINTER_REF,
"", -1, 0);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
static int
samr_dissect_open_domain_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "OpenDomain request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_access, NULL);
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
- samr_dissect_SID, NDR_POINTER_REF,
+ dissect_ndr_nt_SID, NDR_POINTER_REF,
"", -1, 0);
return offset;
}
packet_info *pinfo, proto_tree *tree,
char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
- return offset;
-}
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "OpenDomain response");
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
static int
samr_dissect_context_handle_SID(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
- samr_dissect_SID, NDR_POINTER_REF,
+ dissect_ndr_nt_SID, NDR_POINTER_REF,
"SID", -1, 0);
return offset;
}
static int
-samr_dissect_context_handle(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+samr_dissect_add_member_to_group_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "AddGroupMem request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_group, NULL);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_rid, NULL);
+
return offset;
}
-
static int
-samr_dissect_rc(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+samr_dissect_add_member_to_group_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "AddGroupMem response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
return offset;
}
static int
-samr_dissect_add_member_to_group_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+samr_dissect_unknown_3c_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_group, NULL);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rid, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "Unknown 0x3c request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
return offset;
}
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "Unknown 0x3c response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_short, NDR_POINTER_REF,
"", hf_samr_unknown_short, 0);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
-
-
static int
samr_dissect_create_alias_in_domain_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "CreateAlias request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_UNICODE_STRING, NDR_POINTER_REF,
"Account Name", hf_samr_acct_name, 0);
+
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_access, NULL);
+
return offset;
}
packet_info *pinfo, proto_tree *tree,
char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "CreateAlias response");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_rid, NULL);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
-
static int
samr_dissect_query_information_alias_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryAliasInfo request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
hf_samr_level, NULL);
return offset;
}
+static int
+samr_dissect_query_information_alias_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryAliasInfo response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
static int
samr_dissect_ALIAS_INFO_1 (tvbuff_t *tvb, int offset,
return offset;
}
-static int
-samr_dissect_query_information_alias_reply(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
-{
- offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
- samr_dissect_ALIAS_INFO_ptr, NDR_POINTER_REF,
- "", -1, 0);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
- return offset;
-}
-
static int
samr_dissect_set_information_alias_rqst(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SetAliasInfo request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
hf_samr_level, NULL);
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
return offset;
}
+static int
+samr_dissect_set_information_alias_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SetAliasInfo response");
+
+ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
+ samr_dissect_ALIAS_INFO_ptr, NDR_POINTER_REF,
+ "", -1, 0);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+ return offset;
+}
static int
samr_dissect_CRYPT_PASSWORD(tvbuff_t *tvb, int offset,
static int
samr_dissect_oem_change_password_user2_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "OEMChangePassword request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_STRING, NDR_POINTER_UNIQUE,
"Server", hf_samr_server, 0);
return offset;
}
+static int
+samr_dissect_oem_change_password_user2_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "OEMChangePassword response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
static int
samr_dissect_unicode_change_password_user2_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "UnicodeChangePassword request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_UNICODE_STRING, NDR_POINTER_UNIQUE,
"Server", hf_samr_server, 0);
return offset;
}
+static int
+samr_dissect_unicode_change_password_user2_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "UnicodeChangePassword response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
static int
samr_dissect_unknown_3b_rqst(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "Unknown 0x3b request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
hf_samr_unknown_short, NULL);
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
return offset;
}
+static int
+samr_dissect_unknown_3b_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "Unknown 0x3b response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
static int
samr_dissect_create_user2_in_domain_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
-
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "CreateDomUser request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_UNICODE_STRING, NDR_POINTER_REF,
"Account Name", hf_samr_acct_name, 0);
packet_info *pinfo, proto_tree *tree,
char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "CreateDomUser response");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_unknown_long, NULL);
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_rid, NULL);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
static int
samr_dissect_get_display_enumeration_index2_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "GetDispEnumIndex2 request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
hf_samr_level, NULL);
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "GetDispEnumIndex2 response");
+
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_index, NULL);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
static int
samr_dissect_change_password_user_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "ChangePassword request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint8 (tvb, offset, pinfo, tree, drep,
hf_samr_unknown_char, NULL);
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
return offset;
}
+static int
+samr_dissect_change_password_user_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "ChangePassword response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
static int
samr_dissect_set_member_attributes_of_group_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SetGroupAttr request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_attrib, NULL);
return offset;
}
+static int
+samr_dissect_set_member_attributes_of_group_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SetGroupAttr response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
static int
samr_dissect_GROUP_INFO_1 (tvbuff_t *tvb, int offset,
}
static int
-samr_dissect_query_information_group_rqst (tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+samr_dissect_query_information_group_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryGroupInfo request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
hf_samr_level, NULL);
+
return offset;
}
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryGroupInfo response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_GROUP_INFO_ptr, NDR_POINTER_REF,
"", -1, 0);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
static int
-samr_dissect_set_information_group_rqst (tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+samr_dissect_set_information_group_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SetGroupInfo request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
hf_samr_level, NULL);
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
return offset;
}
+static int
+samr_dissect_set_information_group_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SetGroupInfo response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
static int
-samr_dissect_get_domain_password_information_rqst (tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+samr_dissect_get_domain_password_information_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "GetPasswordInfo request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_STRING, NDR_POINTER_UNIQUE,
return offset;
}
+static int
+samr_dissect_get_domain_password_information_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "GetPasswordInfo response");
+
+ /*
+ * XXX - really? Not the same as
+ * "samr_dissect_get_usrdom_pwinfo_reply()"?
+ */
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ return offset;
+}
static int
samr_dissect_DOMAIN_INFO_1(tvbuff_t *tvb, int offset,
}
static int
-samr_dissect_query_information_domain_reply(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+samr_dissect_set_information_domain_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
- samr_dissect_DOMAIN_INFO_ptr, NDR_POINTER_REF,
- "", hf_samr_domain, 0);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
- return offset;
-}
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SetDomainInfo request");
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
-static int
-samr_dissect_set_information_domain_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
-{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
hf_samr_level, NULL);
offset = samr_dissect_DOMAIN_INFO(tvb, offset, pinfo, tree, drep);
+
return offset;
}
+static int
+samr_dissect_set_information_domain_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SetDomainInfo response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+ return offset;
+}
static int
samr_dissect_lookup_domain_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryDomainInfo request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_UNICODE_STRING, NDR_POINTER_REF,
"", hf_samr_domain, 0);
+
return offset;
}
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryDomainInfo reponse");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
- samr_dissect_SID_ptr, NDR_POINTER_REF,
+ dissect_ndr_nt_SID_ptr, NDR_POINTER_REF,
"", -1, 0);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
-static int
-samr_dissect_PSID(tvbuff_t *tvb, int offset,
+int
+dissect_ndr_nt_PSID(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *parent_tree,
char *drep)
{
}
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
- samr_dissect_SID, NDR_POINTER_UNIQUE,
+ dissect_ndr_nt_SID, NDR_POINTER_UNIQUE,
"SID", -1, 0);
proto_item_set_len(item, offset-old_offset);
static int
-samr_dissect_PSID_ARRAY_sids (tvbuff_t *tvb, int offset,
+dissect_ndr_nt_PSID_ARRAY_sids (tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
char *drep)
{
offset = dissect_ndr_ucarray(tvb, offset, pinfo, tree, drep,
- samr_dissect_PSID);
+ dissect_ndr_nt_PSID);
return offset;
}
-static int
-samr_dissect_PSID_ARRAY(tvbuff_t *tvb, int offset,
+int
+dissect_ndr_nt_PSID_ARRAY(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *parent_tree,
char *drep)
{
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_count, &count);
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
- samr_dissect_PSID_ARRAY_sids, NDR_POINTER_UNIQUE,
+ dissect_ndr_nt_PSID_ARRAY_sids, NDR_POINTER_UNIQUE,
"PSID_ARRAY", -1, 0);
proto_item_set_len(item, offset-old_offset);
return offset;
}
+/* called from NETLOGON but placed here since where are where the hf_fields are defined */
+int
+dissect_ndr_nt_SID_AND_ATTRIBUTES(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *parent_tree,
+ char *drep)
+{
+ proto_item *item=NULL;
+ proto_tree *tree=NULL;
+ int old_offset=offset;
+
+ if(parent_tree){
+ item = proto_tree_add_text(parent_tree, tvb, offset, 0,
+ "SID_AND_ATTRIBUTES:");
+ tree = proto_item_add_subtree(item, ett_samr_sid_and_attributes);
+ }
+
+ offset = dissect_ndr_nt_PSID(tvb, offset, pinfo, tree, drep);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_attrib, NULL);
+
+ return offset;
+}
+
+int
+dissect_ndr_nt_SID_AND_ATTRIBUTES_ARRAY(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *parent_tree,
+ char *drep)
+{
+ guint32 count;
+ proto_item *item=NULL;
+ proto_tree *tree=NULL;
+ int old_offset=offset;
+
+ if(parent_tree){
+ item = proto_tree_add_text(parent_tree, tvb, offset, 0,
+ "SID_AND_ATTRIBUTES array:");
+ tree = proto_item_add_subtree(item, ett_samr_sid_and_attributes_array);
+ }
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_count, &count);
+ offset = dissect_ndr_ucarray(tvb, offset, pinfo, tree, drep,
+ dissect_ndr_nt_SID_AND_ATTRIBUTES);
+
+ proto_item_set_len(item, offset-old_offset);
+ return offset;
+}
+
+
static int
samr_dissect_index(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
return offset;
}
-
static int
samr_dissect_get_alias_membership_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "GetAliasMem request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
- samr_dissect_PSID_ARRAY, NDR_POINTER_REF,
+ dissect_ndr_nt_PSID_ARRAY, NDR_POINTER_REF,
"", -1, 0);
+
+ return offset;
+}
+
+static int
+samr_dissect_get_alias_membership_response(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "GetAliasMem response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
return offset;
}
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "GetAliasMem response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_INDEX_ARRAY, NDR_POINTER_REF,
"", hf_samr_alias, 0);
+
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_rc, NULL);
+
return offset;
}
-
static int
samr_dissect_IDX_AND_NAME(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *parent_tree,
static int
samr_dissect_enum_domains_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "EnumDomains request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_long, NDR_POINTER_REF,
"", hf_samr_resume_hnd, 0);
+
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_pref_maxsize, NULL);
+
return offset;
}
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "EnumDomains response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_long, NDR_POINTER_REF,
"", hf_samr_resume_hnd, 0);
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_long, NDR_POINTER_REF,
"", hf_samr_entries, 0);
- offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
return offset;
}
static int
samr_dissect_enum_dom_groups_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "EnumDomGroups request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_long, NDR_POINTER_REF,
"", hf_samr_resume_hnd, 0);
hf_samr_mask, NULL);
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_pref_maxsize, NULL);
+
return offset;
}
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "EnumDomGroups response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_long, NDR_POINTER_REF,
"", hf_samr_resume_hnd, 0);
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_long, NDR_POINTER_REF,
"", hf_samr_entries, 0);
- offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_enum_dom_aliases_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "EnumDomAliases request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
+ samr_dissect_pointer_long, NDR_POINTER_REF,
+ "", hf_samr_resume_hnd, 0);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_mask, NULL);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_pref_maxsize, NULL);
+
return offset;
}
static int
-samr_dissect_enum_dom_alias_reply(tvbuff_t *tvb, int offset,
+samr_dissect_enum_dom_aliases_reply(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "EnumDomAliases response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_long, NDR_POINTER_REF,
"", hf_samr_resume_hnd, 0);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_IDX_AND_NAME_ARRAY_ptr, NDR_POINTER_REF,
"", hf_samr_alias_name, 0);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_pointer_long, NDR_POINTER_REF,
"", hf_samr_entries, 0);
- offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_get_members_in_alias_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "GetAliasMem request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
return offset;
}
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "GetAliasMem response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
- samr_dissect_PSID_ARRAY, NDR_POINTER_REF,
+ dissect_ndr_nt_PSID_ARRAY, NDR_POINTER_REF,
"", -1, 0);
- offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
static int
samr_dissect_set_information_user2_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SetUserInfo request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
hf_samr_level, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_USER_INFO, NDR_POINTER_REF,
"", -1, 0);
}
static int
-samr_dissect_query_userinfo_reply(tvbuff_t *tvb, int offset,
+samr_dissect_set_information_user2_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SetUserInfo response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_unknown_2f_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "Unknown 0x2f request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
+ hf_samr_level, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_unknown_2f_reply(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "Unknown 0x2f response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_USER_INFO_ptr, NDR_POINTER_REF,
"", -1, 0);
- offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
hf_samr_rc, NULL);
return offset;
}
static int
-samr_dissect_query_groupmem_reply(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
+samr_dissect_query_groupmem_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryGroupMem request");
+
+ offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+ return offset;
+}
+
+static int
+samr_dissect_query_groupmem_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryGroupMem response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_MEMBER_ARRAY_ptr, NDR_POINTER_REF,
"", -1, 0);
- offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
static int
samr_dissect_set_sec_object_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SetSecObject request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_info_type, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_BUFFER, NDR_POINTER_REF,
"", -1, 0);
return offset;
}
+static int
+samr_dissect_set_sec_object_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SetSecObject response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
static int
samr_dissect_query_sec_object_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QuerySecObject request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
hf_samr_info_type, NULL);
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QuerySecObject response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_BUFFER_ptr, NDR_POINTER_REF,
"", -1, 0);
- offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
static int
samr_dissect_lookup_names_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "LookupNames request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
hf_samr_count, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_LOOKUP_NAMES, NDR_POINTER_REF,
"", -1, 0);
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "LookupNames response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_INDEX_ARRAY, NDR_POINTER_REF,
"", hf_samr_rid, 0);
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_INDEX_ARRAY, NDR_POINTER_REF,
"", hf_samr_type, 0);
- offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
- hf_samr_rc, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
return offset;
}
static int
samr_dissect_lookup_rids_rqst(tvbuff_t *tvb, int offset,
- packet_info *pinfo, proto_tree *tree,
- char *drep)
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
{
- offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
- hf_samr_hnd, NULL);
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "LookupRids request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
hf_samr_count, NULL);
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_LOOKUP_RIDS, NDR_POINTER_REF,
"", -1, 0);
packet_info *pinfo, proto_tree *tree,
char *drep)
{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "LookupRids response");
+
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_UNICODE_STRING_ARRAY, NDR_POINTER_REF,
"", hf_samr_rid, 0);
offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
samr_dissect_INDEX_ARRAY, NDR_POINTER_REF,
"", hf_samr_type, 0);
- offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_close_hnd_rqst(tvbuff_t *tvb, int offset, packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "Close request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_close_hnd_reply(tvbuff_t *tvb, int offset, packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "Close response");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
hf_samr_rc, NULL);
return offset;
}
+static int
+samr_dissect_shutdown_sam_server_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SamShutdown request");
+
+ offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_shutdown_sam_server_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "SamShutdown response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_delete_dom_group_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "DeleteGroup request");
+
+ offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_delete_dom_group_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "DeleteGroup response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_remove_member_from_group_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "DeleteGroupMem request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_group, NULL);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_rid, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_remove_member_from_group_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "DeleteGroupMem response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_delete_dom_alias_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "DeleteAlias request");
+
+ offset = dissect_ndr_ctx_hnd (tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_delete_dom_alias_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "DeleteAlias response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_add_alias_member_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "AddAliasMem request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
+ dissect_ndr_nt_SID, NDR_POINTER_REF,
+ "SID", -1, 0);
+ return offset;
+}
+
+static int
+samr_dissect_add_alias_member_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "AddAliasMem response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_remove_alias_member_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "RemoveAliasMem request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
+ dissect_ndr_nt_SID, NDR_POINTER_REF,
+ "SID", -1, 0);
+ return offset;
+}
+
+static int
+samr_dissect_remove_alias_member_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "RemoveAliasMem response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_delete_dom_user_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "DeleteDomUser request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_delete_dom_user_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "DeleteDomUser response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_test_private_fns_domain_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "TestPrivateFnsDomain request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_test_private_fns_domain_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "TestPrivateFnsDomain response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+ return offset;
+}
+
+static int
+samr_dissect_test_private_fns_user_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "TestPrivateFnsUser request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_test_private_fns_user_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "TestPrivateFnsUser response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_remove_member_from_foreign_domain_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "RemoveForeignMember request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
+ dissect_ndr_nt_SID, NDR_POINTER_REF,
+ "SID", -1, 0);
+ return offset;
+}
+
+static int
+samr_dissect_remove_member_from_foreign_domain_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "RemoveForeignMember response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_remove_multiple_members_from_alias_rqst(tvbuff_t *tvb,
+ int offset,
+ packet_info *pinfo,
+ proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "RemoveMultipleMembersFromAlias request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
+ dissect_ndr_nt_PSID_ARRAY, NDR_POINTER_REF,
+ "", -1, 0);
+
+ return offset;
+}
+
+static int
+samr_dissect_remove_multiple_members_from_alias_reply(tvbuff_t *tvb,
+ int offset,
+ packet_info *pinfo,
+ proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "RemoveMultipleMembersFromAlias response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_open_group_rqst(tvbuff_t *tvb, int offset, packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ dcerpc_info *di = (dcerpc_info *)pinfo->private_data;
+ dcerpc_call_value *dcv = (dcerpc_call_value *)di->call_data;
+ guint32 rid;
+
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "OpenGroup request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_access, NULL);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_rid, &rid);
+
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_append_fstr(pinfo->cinfo, COL_INFO, ", rid 0x%x", rid);
+
+ dcv->private_data = (void *)rid;
+
+ return offset;
+}
+
+static int
+samr_dissect_open_group_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "OpenGroup response");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_open_alias_rqst(tvbuff_t *tvb, int offset, packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ dcerpc_info *di = (dcerpc_info *)pinfo->private_data;
+ dcerpc_call_value *dcv = (dcerpc_call_value *)di->call_data;
+ guint32 rid;
+
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "OpenAlias request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_access, NULL);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_rid, &rid);
+
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_append_fstr(pinfo->cinfo, COL_INFO, ", rid 0x%x", rid);
+
+ dcv->private_data = (void *)rid;
+
+ return offset;
+}
+
+static int
+samr_dissect_open_alias_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "OpenAlias response");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_add_multiple_members_to_alias_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "AddMultipleMembersToAlias request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
+ dissect_ndr_nt_PSID_ARRAY, NDR_POINTER_REF,
+ "", -1, 0);
+
+ return offset;
+}
+
+static int
+samr_dissect_add_multiple_members_to_alias_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO,
+ "AddMultipleMembersToAlias response");
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_create_group_in_domain_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "CreateGroup request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
+ samr_dissect_pointer_UNICODE_STRING, NDR_POINTER_REF,
+ "Account Name", hf_samr_acct_name, 0);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_access, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_create_group_in_domain_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "CreateGroup response");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_rid, NULL);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_query_information_domain_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryDomInfo request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
+ hf_samr_level, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_query_information_domain_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo, proto_tree *tree,
+ char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryDomInfo response");
+
+ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
+ samr_dissect_DOMAIN_INFO_ptr, NDR_POINTER_REF,
+ "", hf_samr_domain, 0);
+
+ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_query_information_user_rqst(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryUserInfo request");
+
+ offset = dissect_nt_policy_hnd(tvb, offset, pinfo, tree, drep,
+ hf_samr_hnd, NULL);
+
+ offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
+ hf_samr_level, NULL);
+
+ return offset;
+}
+
+static int
+samr_dissect_query_information_user_reply(tvbuff_t *tvb, int offset,
+ packet_info *pinfo,
+ proto_tree *tree, char *drep)
+{
+ if (check_col(pinfo->cinfo, COL_INFO))
+ col_set_str(pinfo->cinfo, COL_INFO, "QueryUserInfo response");
+
+ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep,
+ samr_dissect_USER_INFO_ptr, NDR_POINTER_REF,
+ "", -1, 0);
+
+ offset = dissect_ntstatus(tvb, offset, pinfo, tree, drep,
+ hf_samr_rc, NULL);
+
+ return offset;
+}
static dcerpc_sub_dissector dcerpc_samr_dissectors[] = {
{ SAMR_CONNECT_ANON, "CONNECT_ANON",
- samr_dissect_connect2_rqst,
- samr_dissect_context_handle_reply },
+ samr_dissect_connect_anon_rqst,
+ samr_dissect_connect_anon_reply },
{ SAMR_CLOSE_HND, "CLOSE_HND",
- samr_dissect_context_handle,
- samr_dissect_context_handle_reply },
+ samr_dissect_close_hnd_rqst,
+ samr_dissect_close_hnd_reply },
{ SAMR_SET_SEC_OBJECT, "SET_SEC_OBJECT",
samr_dissect_set_sec_object_rqst,
- samr_dissect_rc },
+ samr_dissect_set_sec_object_reply },
{ SAMR_QUERY_SEC_OBJECT, "QUERY_SEC_OBJECT",
samr_dissect_query_sec_object_rqst,
samr_dissect_query_sec_object_reply },
{ SAMR_SHUTDOWN_SAM_SERVER, "SHUTDOWN_SAM_SERVER",
- samr_dissect_context_handle,
- samr_dissect_rc },
+ samr_dissect_shutdown_sam_server_rqst,
+ samr_dissect_shutdown_sam_server_reply },
{ SAMR_LOOKUP_DOMAIN, "LOOKUP_DOMAIN",
samr_dissect_lookup_domain_rqst,
samr_dissect_lookup_domain_reply },
samr_dissect_query_information_domain_reply },
{ SAMR_SET_DOMAIN_INFO, "SET_INFORMATION_DOMAIN",
samr_dissect_set_information_domain_rqst,
- samr_dissect_rc },
+ samr_dissect_set_information_domain_reply },
{ SAMR_CREATE_DOM_GROUP, "CREATE_GROUP_IN_DOMAIN",
samr_dissect_create_alias_in_domain_rqst,
samr_dissect_create_alias_in_domain_reply },
samr_dissect_enum_dom_groups_rqst,
samr_dissect_enum_dom_groups_reply },
{ SAMR_CREATE_USER_IN_DOMAIN, "CREATE_USER_IN_DOMAIN",
- samr_dissect_create_alias_in_domain_rqst,
- samr_dissect_create_alias_in_domain_reply },
+ samr_dissect_create_group_in_domain_rqst,
+ samr_dissect_create_group_in_domain_reply },
{ SAMR_ENUM_DOM_USERS, "ENUM_DOM_USERS",
samr_dissect_enum_dom_groups_rqst,
samr_dissect_enum_dom_groups_reply },
samr_dissect_create_alias_in_domain_rqst,
samr_dissect_create_alias_in_domain_reply },
{ SAMR_ENUM_DOM_ALIASES, "ENUM_DOM_ALIASES",
- samr_dissect_enum_dom_groups_rqst,
- samr_dissect_enum_dom_alias_reply },
+ samr_dissect_enum_dom_aliases_rqst,
+ samr_dissect_enum_dom_aliases_reply },
{ SAMR_GET_ALIAS_MEMBERSHIP, "GET_ALIAS_MEMBERSHIP",
samr_dissect_get_alias_membership_rqst,
samr_dissect_get_alias_membership_reply },
samr_dissect_lookup_rids_rqst,
samr_dissect_lookup_rids_reply },
{ SAMR_OPEN_GROUP, "OPEN_GROUP",
- samr_dissect_open_user_rqst,
- samr_dissect_context_handle_reply },
+ samr_dissect_open_group_rqst,
+ samr_dissect_open_group_reply },
{ SAMR_QUERY_GROUPINFO, "QUERY_INFORMATION_GROUP",
samr_dissect_query_information_group_rqst,
samr_dissect_query_information_group_reply },
{ SAMR_SET_GROUPINFO, "SET_INFORMATION_GROUP",
samr_dissect_set_information_group_rqst,
- samr_dissect_rc },
+ samr_dissect_set_information_group_reply },
{ SAMR_ADD_GROUPMEM, "ADD_MEMBER_TO_GROUP",
samr_dissect_add_member_to_group_rqst,
- samr_dissect_rc },
+ samr_dissect_add_member_to_group_reply },
{ SAMR_DELETE_DOM_GROUP, "DELETE_DOM_GROUP",
- samr_dissect_context_handle,
- samr_dissect_rc },
+ samr_dissect_delete_dom_group_rqst,
+ samr_dissect_delete_dom_group_reply },
{ SAMR_DEL_GROUPMEM, "REMOVE_MEMBER_FROM_GROUP",
- samr_dissect_add_member_to_group_rqst,
- samr_dissect_rc },
+ samr_dissect_remove_member_from_group_rqst,
+ samr_dissect_remove_member_from_group_reply },
{ SAMR_QUERY_GROUPMEM, "QUERY_GROUPMEM",
- samr_dissect_context_handle,
+ samr_dissect_query_groupmem_rqst,
samr_dissect_query_groupmem_reply },
{ SAMR_SET_MEMBER_ATTRIBUTES_OF_GROUP, "SET_MEMBER_ATTRIBUTES_OF_GROUP",
samr_dissect_set_member_attributes_of_group_rqst,
- samr_dissect_rc },
+ samr_dissect_set_member_attributes_of_group_reply },
{ SAMR_OPEN_ALIAS, "OPEN_ALIAS",
- samr_dissect_open_user_rqst,
- samr_dissect_context_handle_reply },
+ samr_dissect_open_alias_rqst,
+ samr_dissect_open_alias_reply },
{ SAMR_QUERY_ALIASINFO, "QUERY_INFORMATION_ALIAS",
samr_dissect_query_information_alias_rqst,
samr_dissect_query_information_alias_reply },
{ SAMR_SET_ALIASINFO, "SET_INFORMATION_ALIAS",
samr_dissect_set_information_alias_rqst,
- samr_dissect_rc },
+ samr_dissect_set_information_alias_reply },
{ SAMR_DELETE_DOM_ALIAS, "DELETE_DOM_ALIAS",
- samr_dissect_context_handle,
- samr_dissect_rc },
+ samr_dissect_delete_dom_alias_rqst,
+ samr_dissect_delete_dom_alias_reply },
{ SAMR_ADD_ALIASMEM, "ADD_MEMBER_TO_ALIAS",
- samr_dissect_context_handle_SID,
- samr_dissect_rc },
+ samr_dissect_add_alias_member_rqst,
+ samr_dissect_add_alias_member_reply },
{ SAMR_DEL_ALIASMEM, "REMOVE_MEMBER_FROM_ALIAS",
- samr_dissect_context_handle_SID,
- samr_dissect_rc },
+ samr_dissect_remove_alias_member_rqst,
+ samr_dissect_remove_alias_member_reply },
{ SAMR_GET_MEMBERS_IN_ALIAS, "GET_MEMBERS_IN_ALIAS",
- samr_dissect_context_handle,
+ samr_dissect_get_members_in_alias_rqst,
samr_dissect_get_members_in_alias_reply },
{ SAMR_OPEN_USER, "OPEN_USER",
samr_dissect_open_user_rqst,
- samr_dissect_context_handle_reply },
+ samr_dissect_open_user_reply },
{ SAMR_DELETE_DOM_USER, "DELETE_DOM_USER",
- samr_dissect_context_handle,
- samr_dissect_rc },
+ samr_dissect_delete_dom_user_rqst,
+ samr_dissect_delete_dom_user_reply },
{ SAMR_QUERY_USERINFO, "QUERY_USERINFO",
- samr_dissect_query_information_alias_rqst,
- samr_dissect_query_userinfo_reply },
+ samr_dissect_query_information_user_rqst,
+ samr_dissect_query_information_user_reply },
{ SAMR_SET_USERINFO2, "SET_USERINFO2",
samr_dissect_set_information_user2_rqst,
- samr_dissect_rc },
+ samr_dissect_set_information_user2_reply },
{ SAMR_CHANGE_PASSWORD_USER, "CHANGE_PASSWORD_USER",
samr_dissect_change_password_user_rqst,
- samr_dissect_rc },
+ samr_dissect_change_password_user_reply },
{ SAMR_GET_GROUPS_FOR_USER, "GET_GROUPS_FOR_USER",
- samr_dissect_context_handle,
+ samr_dissect_get_groups_for_user_rqst,
samr_dissect_get_groups_for_user_reply },
{ SAMR_QUERY_DISPINFO, "QUERY_DISPINFO",
samr_dissect_query_dispinfo_rqst,
samr_dissect_get_display_enumeration_index_rqst,
samr_dissect_get_display_enumeration_index_reply },
{ SAMR_TEST_PRIVATE_FUNCTIONS_DOMAIN, "TEST_PRIVATE_FUNCTIONS_DOMAIN",
- samr_dissect_context_handle,
- samr_dissect_rc },
+ samr_dissect_test_private_fns_domain_rqst,
+ samr_dissect_test_private_fns_domain_reply },
{ SAMR_TEST_PRIVATE_FUNCTIONS_USER, "TEST_PRIVATE_FUNCTIONS_USER",
- samr_dissect_context_handle,
- samr_dissect_rc },
+ samr_dissect_test_private_fns_user_rqst,
+ samr_dissect_test_private_fns_user_reply },
{ SAMR_GET_USRDOM_PWINFO, "GET_USRDOM_PWINFO",
- samr_dissect_context_handle,
+ samr_dissect_get_usrdom_pwinfo_rqst,
samr_dissect_get_usrdom_pwinfo_reply },
{ SAMR_REMOVE_MEMBER_FROM_FOREIGN_DOMAIN, "REMOVE_MEMBER_FROM_FOREIGN_DOMAIN",
- samr_dissect_context_handle_SID,
- samr_dissect_rc },
+ samr_dissect_remove_member_from_foreign_domain_rqst,
+ samr_dissect_remove_member_from_foreign_domain_reply },
{ SAMR_QUERY_INFORMATION_DOMAIN2, "QUERY_INFORMATION_DOMAIN2",
- samr_dissect_query_information_alias_rqst,
+ samr_dissect_query_information_domain_rqst,
samr_dissect_query_information_domain_reply },
{ SAMR_UNKNOWN_2f, "UNKNOWN_2f",
- samr_dissect_query_information_alias_rqst,
- samr_dissect_query_userinfo_reply },
+ samr_dissect_unknown_2f_rqst,
+ samr_dissect_unknown_2f_reply },
{ SAMR_QUERY_DISPINFO2, "QUERY_INFORMATION_DISPLAY2",
samr_dissect_query_dispinfo_rqst,
samr_dissect_query_dispinfo_reply },
samr_dissect_query_dispinfo_rqst,
samr_dissect_query_dispinfo_reply },
{ SAMR_ADD_MULTIPLE_MEMBERS_TO_ALIAS, "ADD_MULTIPLE_MEMBERS_TO_ALIAS",
- samr_dissect_get_alias_membership_rqst,
- samr_dissect_rc },
+ samr_dissect_add_multiple_members_to_alias_rqst,
+ samr_dissect_add_multiple_members_to_alias_reply },
{ SAMR_REMOVE_MULTIPLE_MEMBERS_FROM_ALIAS, "REMOVE_MULTIPLE_MEMBERS_FROM_ALIAS",
- samr_dissect_get_alias_membership_rqst,
- samr_dissect_rc },
+ samr_dissect_remove_multiple_members_from_alias_rqst,
+ samr_dissect_remove_multiple_members_from_alias_reply },
{ SAMR_OEM_CHANGE_PASSWORD_USER2, "OEM_CHANGE_PASSWORD_USER2",
samr_dissect_oem_change_password_user2_rqst,
- samr_dissect_rc },
+ samr_dissect_oem_change_password_user2_reply },
{ SAMR_UNICODE_CHANGE_PASSWORD_USER2, "UNICODE_CHANGE_PASSWORD_USER2",
samr_dissect_unicode_change_password_user2_rqst,
- samr_dissect_rc },
+ samr_dissect_unicode_change_password_user2_reply },
{ SAMR_GET_DOM_PWINFO, "GET_DOMAIN_PASSWORD_INFORMATION",
samr_dissect_get_domain_password_information_rqst,
- samr_dissect_get_usrdom_pwinfo_reply },
- { SAMR_CONNECT2, "CONNECT2",
+ samr_dissect_get_domain_password_information_reply },
+ { SAMR_CONNECT2, "CONNECT2",
samr_dissect_connect2_rqst,
samr_dissect_connect2_reply },
{ SAMR_SET_USERINFO, "SET_USERINFO",
samr_dissect_set_information_user2_rqst,
- samr_dissect_rc },
+ samr_dissect_set_information_user2_reply },
{ SAMR_UNKNOWN_3B, "UNKNOWN_3B",
samr_dissect_unknown_3b_rqst,
- samr_dissect_rc },
- { SAMR_UNKNOWN_3C, "SAMR_UNKNOWN_3C",
- samr_dissect_context_handle,
+ samr_dissect_unknown_3b_reply },
+ { SAMR_UNKNOWN_3C, "UNKNOWN_3C",
+ samr_dissect_unknown_3c_rqst,
samr_dissect_unknown_3c_reply },
{0, NULL, NULL, NULL },
};
NULL, 0, "Resume handle", HFILL }},
{ &hf_samr_country, {
"Country", "samr.country", FT_UINT16, BASE_DEC,
- NULL, 0, "Country setting for this user", HFILL }},
+ VALS(ms_country_codes), 0, "Country setting for this user", HFILL }},
{ &hf_samr_codepage, {
"Codepage", "samr.codepage", FT_UINT16, BASE_DEC,
NULL, 0, "Codepage setting for this user", HFILL }},
};
static gint *ett[] = {
&ett_dcerpc_samr,
- &ett_nt_unicode_string,
&ett_samr_user_dispinfo_1,
&ett_samr_user_dispinfo_1_array,
&ett_samr_user_dispinfo_2,
&ett_samr_member_array,
&ett_samr_names,
&ett_samr_rids,
-
+ &ett_samr_sid_and_attributes_array,
+ &ett_samr_sid_and_attributes,
&ett_nt_acct_ctrl,
};