aboutsummaryrefslogtreecommitdiffstats
path: root/packet-smb.c
diff options
context:
space:
mode:
authorGilbert Ramirez <gram@alumni.rice.edu>1999-11-30 03:46:46 +0000
committerGilbert Ramirez <gram@alumni.rice.edu>1999-11-30 03:46:46 +0000
commitde6c24bdb69bb094447203c6aea4d6c8ce85c088 (patch)
tree54617cb12cfff455146363875689464fe82aceb1 /packet-smb.c
parentced3198a2baf713d23ee19ba34d860edb05bb389 (diff)
downloadwireshark-de6c24bdb69bb094447203c6aea4d6c8ce85c088.tar.gz
wireshark-de6c24bdb69bb094447203c6aea4d6c8ce85c088.tar.bz2
wireshark-de6c24bdb69bb094447203c6aea4d6c8ce85c088.zip
Check sanity of EntCount in lanman decode before going off and
marking 26 * EntCount bytes as Server entries. svn path=/trunk/; revision=1160
Diffstat (limited to 'packet-smb.c')
-rw-r--r--packet-smb.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/packet-smb.c b/packet-smb.c
index e6b35bc186..cb9694863a 100644
--- a/packet-smb.c
+++ b/packet-smb.c
@@ -2,7 +2,7 @@
* Routines for smb packet dissection
* Copyright 1999, Richard Sharpe <rsharpe@ns.aus.com>
*
- * $Id: packet-smb.c,v 1.48 1999/11/27 02:17:49 sharpe Exp $
+ * $Id: packet-smb.c,v 1.49 1999/11/30 03:46:46 gram Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@unicom.net>
@@ -10146,6 +10146,10 @@ dissect_pipe_lanman(const u_char *pd, int offset, frame_data *fd, proto_tree *pa
loc_offset += 2;
+ if (! BYTES_ARE_IN_FRAME(loc_offset, 26 * EntCount) ) {
+ return 1;
+ }
+
if (tree) {
ti = proto_tree_add_text(lanman_tree, loc_offset, 26 * EntCount, "Servers");