In the "Announce change to UAS or SAM" NETLOGON message, dissect the
authorguy <guy@f5534014-38df-0310-8fa8-9805f1628bb7>
Fri, 25 Jan 2002 09:42:21 +0000 (09:42 +0000)
committerguy <guy@f5534014-38df-0310-8fa8-9805f1628bb7>
Fri, 25 Jan 2002 09:42:21 +0000 (09:42 +0000)
"Large Serial Number" as a 64-bit little-endian integer, and dissect the
"NT Date/Time" as a FILETIME by calling "dissect_smb_64bit_time()".

Export "dissect_smb_64bit_time()" so that we can do so.

git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@4609 f5534014-38df-0310-8fa8-9805f1628bb7

packet-smb-common.h
packet-smb-logon.c
packet-smb.c

index b9430ac69f62c74ae13495c603c248001ca15f99..5102b97b7b0e6d2ec6338dc5717584a572f4aad5 100644 (file)
@@ -1,8 +1,8 @@
 /* packet-smb-common.h
- * Routines for smb packet dissection
+ * Routines for SMB packet dissection
  * Copyright 1999, Richard Sharpe <rsharpe@ns.aus.com>
  *
- * $Id: packet-smb-common.h,v 1.6 2002/01/25 08:02:01 guy Exp $
+ * $Id: packet-smb-common.h,v 1.7 2002/01/25 09:42:21 guy Exp $
  *
  * Ethereal - Network traffic analyzer
  * By Gerald Combs <gerald@ethereal.com>
@@ -58,6 +58,8 @@ int display_unicode_string(tvbuff_t *tvb, packet_info *pinfo,
 
 int display_ms_string(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int offset, int hf_index);
 
+int dissect_smb_64bit_time(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int offset, char *str, int hf_date);
+
 int dissect_nt_sid(tvbuff_t *tvb, packet_info *pinfo, int offset, proto_tree *parent_tree, char *name);
 
 #endif
index 4e01d04b97c8017776907dc3f4b8af0df52a1b42..0a241357162486d40f416149b4b267101537b949 100644 (file)
@@ -2,7 +2,7 @@
  * Routines for SMB net logon packet dissection
  * Copyright 2000, Jeffrey C. Foster <jfoste@woodward.com>
  *
- * $Id: packet-smb-logon.c,v 1.23 2002/01/25 08:02:01 guy Exp $
+ * $Id: packet-smb-logon.c,v 1.24 2002/01/25 09:42:21 guy Exp $
  *
  * Ethereal - Network traffic analyzer
  * By Gerald Combs <gerald@ethereal.com>
@@ -465,12 +465,11 @@ dissect_announce_change(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int
                offset += 4;
 
                proto_tree_add_item(info_tree, hf_large_serial, tvb, offset, 8,
-                   FALSE);
+                   TRUE);
                offset += 8;
 
-               proto_tree_add_item(info_tree, hf_nt_date_time, tvb, offset, 8,
-                   FALSE);
-               offset += 8;
+               offset = dissect_smb_64bit_time(tvb, pinfo, info_tree, offset,
+                   "NT Date/Time", hf_nt_date_time);
 
                info_count--;
        }
@@ -979,14 +978,12 @@ proto_register_smb_logon( void)
                        { "Database Index", "netlogon.db_index", FT_UINT32, BASE_DEC,
                          NULL, 0, "NETLOGON Database Index", HFILL }},
 
-               /* XXX - 64-bit integer? */
                { &hf_large_serial,
-                       { "Large Serial Number", "netlogon.large_serial", FT_BYTES, BASE_NONE,
+                       { "Large Serial Number", "netlogon.large_serial", FT_UINT64, BASE_DEC,
                          NULL, 0, "NETLOGON Large Serial Number", HFILL }},
 
-               /* XXX - 64-bit FILETIME */
                { &hf_nt_date_time,
-                       { "NT Date/Time", "netlogon.nt_date_time", FT_BYTES, BASE_NONE,
+                       { "NT Date/Time", "netlogon.nt_date_time", FT_ABSOLUTE_TIME, BASE_NONE,
                          NULL, 0, "NETLOGON NT Date/Time", HFILL }},
        };
 
index 6e0bfab9505d295a0fb6eb0914885cceb081781d..00c71ac25c116d5cf9bada2fdd9fa3b519928270 100644 (file)
@@ -3,7 +3,7 @@
  * Copyright 1999, Richard Sharpe <rsharpe@ns.aus.com>
  * 2001  Rewrite by Ronnie Sahlberg and Guy Harris
  *
- * $Id: packet-smb.c,v 1.198 2002/01/25 08:02:01 guy Exp $
+ * $Id: packet-smb.c,v 1.199 2002/01/25 09:42:21 guy Exp $
  *
  * Ethereal - Network traffic analyzer
  * By Gerald Combs <gerald@ethereal.com>
@@ -1097,7 +1097,7 @@ dissect_smb_UTIME(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, int offse
        return offset;
 }
 
-static int
+int
 dissect_smb_64bit_time(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int offset, char *str, int hf_date)
 {
        proto_item *item = NULL;