diff options
author | Ronnie Sahlberg <ronnie_sahlberg@ozemail.com.au> | 2003-05-30 11:30:09 +0000 |
---|---|---|
committer | Ronnie Sahlberg <ronnie_sahlberg@ozemail.com.au> | 2003-05-30 11:30:09 +0000 |
commit | ecc98ba7fc271a4967259ed855561587a85dfa3a (patch) | |
tree | 1bda8a733f8df93739f3c8502f3a10c3a8f664fd /packet-dcerpc-lsa.c | |
parent | c48ce9b402652854b677196bcf6ee0db30898c2b (diff) |
Some minor updates to LSA.
* Add a few missing dissections of return codes in reply packets
* fix a problem in LsaQuerySecret where two of the parameters are actually
unique pointer to unique pointer to object and not just one level of pointers.
* update the dissection of LSA_SECRET to look more correct in some captures.
Anyone that knows the content of the LSA_SECRET object is welcome to mail a description to me.
svn path=/trunk/; revision=7765
Diffstat (limited to 'packet-dcerpc-lsa.c')
-rw-r--r-- | packet-dcerpc-lsa.c | 33 |
1 files changed, 23 insertions, 10 deletions
diff --git a/packet-dcerpc-lsa.c b/packet-dcerpc-lsa.c index ea1f0331f3..e8aec64102 100644 --- a/packet-dcerpc-lsa.c +++ b/packet-dcerpc-lsa.c @@ -3,7 +3,7 @@ * Copyright 2001,2003 Tim Potter <tpot@samba.org> * 2002 Added LSA command dissectors Ronnie Sahlberg * - * $Id: packet-dcerpc-lsa.c,v 1.83 2003/05/23 05:20:58 tpot Exp $ + * $Id: packet-dcerpc-lsa.c,v 1.84 2003/05/30 11:30:09 sahlberg Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@ethereal.com> @@ -240,8 +240,8 @@ lsa_dissect_pointer_STRING(tvbuff_t *tvb, int offset, static int lsa_dissect_LSA_SECRET_data(tvbuff_t *tvb, int offset, - packet_info *pinfo, proto_tree *tree, - char *drep) + packet_info *pinfo, proto_tree *tree, + char *drep) { guint32 len; dcerpc_info *di; @@ -252,6 +252,10 @@ lsa_dissect_LSA_SECRET_data(tvbuff_t *tvb, int offset, return offset; } + /* this is probably a varying and conformant array */ + offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep, + hf_lsa_sd_size, &len); + offset+=4; offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep, hf_lsa_sd_size, &len); proto_tree_add_item(tree, hf_lsa_secret, tvb, offset, len, FALSE); @@ -259,6 +263,7 @@ lsa_dissect_LSA_SECRET_data(tvbuff_t *tvb, int offset, return offset; } + int lsa_dissect_LSA_SECRET(tvbuff_t *tvb, int offset, packet_info *pinfo, proto_tree *parent_tree, @@ -277,9 +282,11 @@ lsa_dissect_LSA_SECRET(tvbuff_t *tvb, int offset, /* XXX need to figure this one out */ offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep, hf_lsa_sd_size, NULL); - offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep, - lsa_dissect_LSA_SECRET_data, NDR_POINTER_UNIQUE, - "LSA SECRET data:", -1); + offset = dissect_ndr_uint32 (tvb, offset, pinfo, tree, drep, + hf_lsa_sd_size, NULL); + offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep, + lsa_dissect_LSA_SECRET_data, NDR_POINTER_UNIQUE, + "LSA_SECRET data: pointer", -1); proto_item_set_len(item, offset-old_offset); return offset; @@ -2783,7 +2790,7 @@ lsa_dissect_lsaquerysecret_rqst(tvbuff_t *tvb, int offset, /* [in, out, unique] LSA_SECRET **curr_val */ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep, - lsa_dissect_LSA_SECRET, NDR_POINTER_UNIQUE, + lsa_dissect_LSA_SECRET_pointer, NDR_POINTER_UNIQUE, "LSA_SECRET pointer: curr_val", -1); /* [in, out, unique] LARGE_INTEGER *curr_mtime */ @@ -2793,7 +2800,7 @@ lsa_dissect_lsaquerysecret_rqst(tvbuff_t *tvb, int offset, /* [in, out, unique] LSA_SECRET **old_val */ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep, - lsa_dissect_LSA_SECRET, NDR_POINTER_UNIQUE, + lsa_dissect_LSA_SECRET_pointer, NDR_POINTER_UNIQUE, "LSA_SECRET pointer: old_val", -1); /* [in, out, unique] LARGE_INTEGER *old_mtime */ @@ -2811,7 +2818,7 @@ lsa_dissect_lsaquerysecret_reply(tvbuff_t *tvb, int offset, { /* [in, out, unique] LSA_SECRET **curr_val */ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep, - lsa_dissect_LSA_SECRET, NDR_POINTER_UNIQUE, + lsa_dissect_LSA_SECRET_pointer, NDR_POINTER_UNIQUE, "LSA_SECRET pointer: curr_val", -1); /* [in, out, unique] LARGE_INTEGER *curr_mtime */ @@ -2821,7 +2828,7 @@ lsa_dissect_lsaquerysecret_reply(tvbuff_t *tvb, int offset, /* [in, out, unique] LSA_SECRET **old_val */ offset = dissect_ndr_pointer(tvb, offset, pinfo, tree, drep, - lsa_dissect_LSA_SECRET, NDR_POINTER_UNIQUE, + lsa_dissect_LSA_SECRET_pointer, NDR_POINTER_UNIQUE, "LSA_SECRET pointer: old_val", -1); /* [in, out, unique] LARGE_INTEGER *old_mtime */ @@ -2829,6 +2836,9 @@ lsa_dissect_lsaquerysecret_reply(tvbuff_t *tvb, int offset, lsa_dissect_pointer_NTTIME, NDR_POINTER_UNIQUE, "NTIME pointer: old_mtime", hf_lsa_old_mtime); + offset = dissect_ntstatus( + tvb, offset, pinfo, tree, drep, hf_lsa_rc, NULL); + return offset; } @@ -3803,6 +3813,9 @@ lsa_dissect_lsafunction_38_reply(tvbuff_t *tvb, int offset, lsa_dissect_LSA_SECURITY_DESCRIPTOR, NDR_POINTER_UNIQUE, "LSA_SECURITY_DESCRIPTOR pointer: psd)", -1); + offset = dissect_ntstatus( + tvb, offset, pinfo, tree, drep, hf_lsa_rc, NULL); + return offset; } |