aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors
diff options
context:
space:
mode:
authorRonnie Sahlberg <ronnie_sahlberg@ozemail.com.au>2005-01-28 09:29:49 +0000
committerRonnie Sahlberg <ronnie_sahlberg@ozemail.com.au>2005-01-28 09:29:49 +0000
commit610da77693fcb3d857253e953cb687224249fd74 (patch)
tree219599a66d3ca408ff49b235bb556e1602596f37 /epan/dissectors
parent289fd317a0461cb3ad54b5c680719b62d47a60a0 (diff)
older MS DCE/RPC interfaces often use a construct that is to be treated as a 64 bit integer but in reality is a struct containing 2 32bit integers.
this construct is aligned on 4 byte boundaries in ndr and NOT 8 bytes as a real uint64 (== hyper) would be. rename the existing dissect_ndr_uint64 ro dissect_ndr_duint32 (double uint32) to make it reflect better the alignment of the type. svn path=/trunk/; revision=13184
Diffstat (limited to 'epan/dissectors')
-rw-r--r--epan/dissectors/packet-dcerpc-browser.c16
-rw-r--r--epan/dissectors/packet-dcerpc-lsa.c8
-rw-r--r--epan/dissectors/packet-dcerpc-ndr.c7
-rw-r--r--epan/dissectors/packet-dcerpc-netlogon.c4
-rw-r--r--epan/dissectors/packet-dcerpc-samr.c6
-rw-r--r--epan/dissectors/packet-dcerpc-srvsvc.c4
-rw-r--r--epan/dissectors/packet-dcerpc.h2
-rw-r--r--epan/dissectors/packet-dcom.h4
8 files changed, 28 insertions, 23 deletions
diff --git a/epan/dissectors/packet-dcerpc-browser.c b/epan/dissectors/packet-dcerpc-browser.c
index cbbac28214..38da56a299 100644
--- a/epan/dissectors/packet-dcerpc-browser.c
+++ b/epan/dissectors/packet-dcerpc-browser.c
@@ -471,13 +471,13 @@ dissect_browser_TYPE_5(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
guint8 *drep)
{
- offset = dissect_ndr_uint64(tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32(tvb, offset, pinfo, tree, drep,
hf_browser_unknown_hyper, NULL);
- offset = dissect_ndr_uint64(tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32(tvb, offset, pinfo, tree, drep,
hf_browser_unknown_hyper, NULL);
- offset = dissect_ndr_uint64(tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32(tvb, offset, pinfo, tree, drep,
hf_browser_unknown_hyper, NULL);
offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
@@ -525,7 +525,7 @@ dissect_browser_TYPE_5(tvbuff_t *tvb, int offset,
offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
hf_browser_unknown_long, NULL);
- offset = dissect_ndr_uint64(tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32(tvb, offset, pinfo, tree, drep,
hf_browser_unknown_hyper, NULL);
return offset;
@@ -646,13 +646,13 @@ dissect_browser_TYPE_11(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
guint8 *drep)
{
- offset = dissect_ndr_uint64(tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32(tvb, offset, pinfo, tree, drep,
hf_browser_unknown_hyper, NULL);
- offset = dissect_ndr_uint64(tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32(tvb, offset, pinfo, tree, drep,
hf_browser_unknown_hyper, NULL);
- offset = dissect_ndr_uint64(tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32(tvb, offset, pinfo, tree, drep,
hf_browser_unknown_hyper, NULL);
offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
@@ -664,7 +664,7 @@ dissect_browser_TYPE_11(tvbuff_t *tvb, int offset,
offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
hf_browser_unknown_long, NULL);
- offset = dissect_ndr_uint64(tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32(tvb, offset, pinfo, tree, drep,
hf_browser_unknown_hyper, NULL);
offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
diff --git a/epan/dissectors/packet-dcerpc-lsa.c b/epan/dissectors/packet-dcerpc-lsa.c
index ad99814799..de9852e05d 100644
--- a/epan/dissectors/packet-dcerpc-lsa.c
+++ b/epan/dissectors/packet-dcerpc-lsa.c
@@ -925,7 +925,7 @@ lsa_dissect_POLICY_DEFAULT_QUOTA_INFO(tvbuff_t *tvb, int offset,
hf_lsa_quota_pagefile, NULL);
/* */
- offset = dissect_ndr_uint64 (tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32 (tvb, offset, pinfo, tree, drep,
hf_lsa_unknown_hyper, NULL);
proto_item_set_len(item, offset-old_offset);
@@ -948,7 +948,7 @@ lsa_dissect_POLICY_MODIFICATION_INFO(tvbuff_t *tvb, int offset,
}
/* seq no */
- offset = dissect_ndr_uint64 (tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32 (tvb, offset, pinfo, tree, drep,
hf_lsa_mod_seq_no, NULL);
/* mtime */
@@ -1519,7 +1519,7 @@ lsa_dissect_auth_info(tvbuff_t *tvb, int offset,
}
/* update */
- offset = dissect_ndr_uint64 (tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32 (tvb, offset, pinfo, tree, drep,
hf_lsa_auth_update, NULL);
/* type */
@@ -2066,7 +2066,7 @@ lsa_dissect_LUID_AND_ATTRIBUTES(tvbuff_t *tvb, int offset,
offset = dissect_nt_LUID(tvb, offset, pinfo, tree, drep);
/* attr */
- offset = dissect_ndr_uint64 (tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32 (tvb, offset, pinfo, tree, drep,
hf_lsa_attr, NULL);
proto_item_set_len(item, offset-old_offset);
diff --git a/epan/dissectors/packet-dcerpc-ndr.c b/epan/dissectors/packet-dcerpc-ndr.c
index bfa3baad21..23ad96b929 100644
--- a/epan/dissectors/packet-dcerpc-ndr.c
+++ b/epan/dissectors/packet-dcerpc-ndr.c
@@ -101,8 +101,13 @@ dissect_ndr_uint32 (tvbuff_t *tvb, gint offset, packet_info *pinfo,
tree, drep, hfindex, pdata);
}
+/* Double uint32
+ This function dissects the 64bit datatype that is common for
+ ms interfaces and which is 32bit aligned.
+ It is really just 2 uint32's
+*/
int
-dissect_ndr_uint64 (tvbuff_t *tvb, gint offset, packet_info *pinfo,
+dissect_ndr_duint32 (tvbuff_t *tvb, gint offset, packet_info *pinfo,
proto_tree *tree, guint8 *drep,
int hfindex, unsigned char *pdata)
{
diff --git a/epan/dissectors/packet-dcerpc-netlogon.c b/epan/dissectors/packet-dcerpc-netlogon.c
index 2ef36e3bf9..bcaf4cf6a1 100644
--- a/epan/dissectors/packet-dcerpc-netlogon.c
+++ b/epan/dissectors/packet-dcerpc-netlogon.c
@@ -646,7 +646,7 @@ netlogon_dissect_LOGON_IDENTITY_INFO(tvbuff_t *tvb, int offset,
offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
hf_netlogon_param_ctrl, NULL);
- offset = dissect_ndr_uint64(tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32(tvb, offset, pinfo, tree, drep,
hf_netlogon_logon_id, NULL);
offset = dissect_ndr_counted_string(tvb, offset, pinfo, tree, drep,
@@ -3166,7 +3166,7 @@ netlogon_dissect_MODIFIED_COUNT(tvbuff_t *tvb, int offset,
packet_info *pinfo, proto_tree *tree,
guint8 *drep)
{
- offset = dissect_ndr_uint64(tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32(tvb, offset, pinfo, tree, drep,
hf_netlogon_modify_count, NULL);
return offset;
diff --git a/epan/dissectors/packet-dcerpc-samr.c b/epan/dissectors/packet-dcerpc-samr.c
index 6d2f387a14..a01fbe8509 100644
--- a/epan/dissectors/packet-dcerpc-samr.c
+++ b/epan/dissectors/packet-dcerpc-samr.c
@@ -2447,9 +2447,9 @@ samr_dissect_REPLICATION_STATUS(tvbuff_t *tvb, int offset,
tree = proto_item_add_subtree(item, ett_samr_replication_status);
}
- offset = dissect_ndr_uint64 (tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32 (tvb, offset, pinfo, tree, drep,
hf_samr_unknown_hyper, NULL);
- offset = dissect_ndr_uint64 (tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32 (tvb, offset, pinfo, tree, drep,
hf_samr_unknown_hyper, NULL);
offset = dissect_ndr_uint16 (tvb, offset, pinfo, tree, drep,
hf_samr_unknown_short, NULL);
@@ -3487,7 +3487,7 @@ samr_dissect_USER_INFO_22(tvbuff_t *tvb, int offset,
}
offset = samr_dissect_USER_INFO_21(tvb, offset, pinfo, tree, drep);
- offset = dissect_ndr_uint64 (tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32 (tvb, offset, pinfo, tree, drep,
hf_samr_revision, NULL);
proto_item_set_len(item, offset-old_offset);
diff --git a/epan/dissectors/packet-dcerpc-srvsvc.c b/epan/dissectors/packet-dcerpc-srvsvc.c
index 1e1d403777..634d5cee28 100644
--- a/epan/dissectors/packet-dcerpc-srvsvc.c
+++ b/epan/dissectors/packet-dcerpc-srvsvc.c
@@ -5608,10 +5608,10 @@ srvsvc_dissect_SERVER_STAT(tvbuff_t *tvb, int offset,
offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
hf_srvsvc_server_stat_syserrors, NULL);
- offset = dissect_ndr_uint64(tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32(tvb, offset, pinfo, tree, drep,
hf_srvsvc_server_stat_bytessent, NULL);
- offset = dissect_ndr_uint64(tvb, offset, pinfo, tree, drep,
+ offset = dissect_ndr_duint32(tvb, offset, pinfo, tree, drep,
hf_srvsvc_server_stat_bytesrcvd, NULL);
offset = dissect_ndr_uint32(tvb, offset, pinfo, tree, drep,
diff --git a/epan/dissectors/packet-dcerpc.h b/epan/dissectors/packet-dcerpc.h
index 81f8bef23c..68564233b0 100644
--- a/epan/dissectors/packet-dcerpc.h
+++ b/epan/dissectors/packet-dcerpc.h
@@ -151,7 +151,7 @@ int dissect_ndr_uint16 (tvbuff_t *tvb, gint offset, packet_info *pinfo,
int dissect_ndr_uint32 (tvbuff_t *tvb, gint offset, packet_info *pinfo,
proto_tree *tree, guint8 *drep,
int hfindex, guint32 *pdata);
-int dissect_ndr_uint64 (tvbuff_t *tvb, gint offset, packet_info *pinfo,
+int dissect_ndr_duint32 (tvbuff_t *tvb, gint offset, packet_info *pinfo,
proto_tree *tree, guint8 *drep,
int hfindex, unsigned char *pdata);
int dissect_ndr_float (tvbuff_t *tvb, gint offset, packet_info *pinfo,
diff --git a/epan/dissectors/packet-dcom.h b/epan/dissectors/packet-dcom.h
index c212a00ccb..85737640e1 100644
--- a/epan/dissectors/packet-dcom.h
+++ b/epan/dissectors/packet-dcom.h
@@ -47,9 +47,9 @@ dissect_dcom_that(tvbuff_t *tvb, int offset,
#define dissect_dcom_BYTE dissect_ndr_uint8
#define dissect_dcom_WORD dissect_ndr_uint16
#define dissect_dcom_DWORD dissect_ndr_uint32
-#define dissect_dcom_ID dissect_ndr_uint64
+#define dissect_dcom_ID dissect_ndr_duint32
#define dissect_dcom_UUID dissect_ndr_uuid_t
-#define dissect_dcom_FILETIME dissect_ndr_uint64 /* ToBeDone */
+#define dissect_dcom_FILETIME dissect_ndr_duint32 /* ToBeDone */
#define dissect_dcom_VARIANT_BOOL dissect_ndr_uint16
#define dissect_dcom_FLOAT dissect_ndr_float
#define dissect_dcom_DOUBLE dissect_ndr_double