* Routines for DCERPC over SMB packet disassembly
* Copyright 2001, Tim Potter <tpot@samba.org>
*
- * $Id: packet-dcerpc-nt.h,v 1.23 2002/05/09 02:44:22 tpot Exp $
+ * $Id: packet-dcerpc-nt.h,v 1.27 2002/06/28 01:23:26 tpot Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@ethereal.com>
int prs_UNISTR2(tvbuff_t *tvb, int offset, packet_info *pinfo,
proto_tree *tree, int flags, char **data, char *name);
-int prs_policy_hnd(tvbuff_t *tvb, int offset, packet_info *pinfo,
- proto_tree *tree, const guint8 **data);
-
/* Routines for handling deferral of referants in NDR */
#define PARSE_SCALARS 1
-#define ALIGN_TO_4_BYTES {if(offset&0x03)offset=(offset&0xfffffffc)+4;}
+#define ALIGN_TO_4_BYTES \
+ { dcerpc_info *xzdi; \
+ xzdi=pinfo->private_data; \
+ if(!xzdi->conformant_run) { \
+ if(offset&0x03) { \
+ offset=(offset&0xfffffffc)+4; \
+ } \
+ } \
+ }
int
dissect_ndr_nt_UNICODE_STRING_str(tvbuff_t *tvb, int offset,
* Policy handle hashing
*/
+/* Store open and close packet numbers for a policy handle */
+
+void
+dcerpc_smb_store_pol_pkts(e_ctx_hnd *policy_hnd, guint32 open_frame,
+ guint32 close_frame);
+
+/* Store a name with a policy handle */
+
+void
+dcerpc_smb_store_pol_name(e_ctx_hnd *policy_hnd, char *name);
+
+/* Fetch details stored with a policy handle */
+
gboolean
-dcerpc_smb_fetch_pol(const guint8 *policy_hnd, char **name,
+dcerpc_smb_fetch_pol(e_ctx_hnd *policy_hnd, char **name,
guint32 *open_frame, guint32 *close_frame);
-void
-dcerpc_smb_store_pol(const guint8 *policy_hnd, char *name,
- guint32 open_frame, guint32 close_frame);
/* Check for unparsed data at the end of a frame */
int
dissect_nt_policy_hnd(tvbuff_t *tvb, gint offset, packet_info *pinfo,
proto_tree *tree, char *drep, int hfindex,
- e_ctx_hnd *pdata);
+ e_ctx_hnd *pdata, gboolean is_open, gboolean is_close);
int
dissect_nt_GUID(tvbuff_t *tvb, int offset,
proto_tree *tree, char *drep,
int hfindex, int length, guint8 **pdata);
+int dissect_dcerpc_uint16s(tvbuff_t *tvb, gint offset, packet_info *pinfo,
+ proto_tree *tree, char *drep,
+ int hfindex, int length, guint16 **pdata);
+
+int dissect_ndr_uint16s(tvbuff_t *tvb, gint offset, packet_info *pinfo,
+ proto_tree *tree, char *drep,
+ int hfindex, int length, guint16 **pdata);
+
#endif /* packet-dcerpc-nt.h */