Untested support for AiroPeek captures.
[metze/wireshark/wip.git] / smb.h
diff --git a/smb.h b/smb.h
index ac5ab5258d1ec6be999162f73245c7f5eb48857e..a54e5ada625ace756b66d4dee56eb0365c6aa048 100644 (file)
--- a/smb.h
+++ b/smb.h
@@ -2,7 +2,7 @@
  * Defines for smb packet dissection
  * Copyright 1999, Richard Sharpe <rsharpe@ns.aus.com>
  *
- * $Id: smb.h,v 1.26 2001/11/21 06:25:58 guy Exp $
+ * $Id: smb.h,v 1.32 2002/01/08 05:52:05 guy Exp $
  *
  * Ethereal - Network traffic analyzer
  * By Gerald Combs <gerald@ethereal.com>
 #define SMBE_unsup 50              /* Request unsupported, returned by Win 95, RJS 20Jun98 */
 #define SMBE_nosuchshare 67        /* Share does not exits */
 #define SMBE_filexists 80          /* File in operation already exists */
+#define SMBE_invalidparam 87      /* Invalid parameter */
 #define SMBE_cannotopen 110        /* Cannot open the file specified */
+#define SMBE_insufficientbuffer 122/* Insufficient buffer size */
 #define SMBE_unknownlevel 124
+#define SMBE_alreadyexists 183     /* File already exists */
 #define SMBE_badpipe 230           /* Named pipe invalid */
 #define SMBE_pipebusy 231          /* All instances of pipe are busy */
 #define SMBE_pipeclosing 232       /* named pipe close in progress */
 #define SMBE_unknownipc 2142
 #define SMBE_noipc 66              /* don't support ipc */
 
+/* These errors seem to be only returned by the NT printer driver system */
+
+#define SMBE_unknownprinterdriver 1797 /* Unknown printer driver */
+#define SMBE_invalidprintername 1801   /* Invalid printer name */
+#define SMBE_printeralreadyexists 1802 /* Printer already exists */
+#define SMBE_invaliddatatype 1804      /* Invalid datatype */
+#define SMBE_invalidenvironment 1805   /* Invalid environment */
+#define SMBE_printerdriverinuse 3001   /* Printer driver in use */
+
 /* Error codes for the ERRSRV class */
 
 #define SMBE_error 1               /* Non specific error code */
@@ -241,13 +253,24 @@ typedef struct {
 #define TRANSACTION_PIPE       0
 #define TRANSACTION_MAILSLOT   1
 
+/* this is the structure which is associated with each conversation */
+typedef struct conv_tables {
+       /* these two tables are used to match requests with responses */
+       GHashTable *unmatched;
+       GHashTable *matched;
+       /* this tables is used by DCERPC over SMB reassembly*/
+       GHashTable *dcerpc_fid_to_frame;
+} conv_tables_t;
+
 typedef struct smb_info {
-  int cmd, mid;
+  int cmd;
   gboolean unicode;            /* Are strings in this SMB Unicode? */
   gboolean request;            /* Is this a request? */
   gboolean unidir;
+  int info_level;
   int info_count;
   smb_saved_info_t *sip;       /* smb_saved_info_t, if any, for this */
+  conv_tables_t *ct;
 } smb_info_t;
 
 /*
@@ -268,4 +291,12 @@ extern void add_fid(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
 extern int dissect_ipc_state(tvbuff_t *tvb, packet_info *pinfo,
     proto_tree *parent_tree, int offset, gboolean setstate);
 
+extern gboolean smb_dcerpc_reassembly;
+extern GHashTable *dcerpc_fragment_table;
+
+/*
+ * NT and DOS error codes used by other dissectors.
+ */
+extern const value_string NT_errors[];
+extern const value_string DOS_errors[];
 #endif