Add packet-ansi_map.h to the distribution.
[obnox/wireshark/wip.git] / packet-fcct.h
1 /* packet-fcct.h
2  *
3  * $Id: packet-fcct.h,v 1.3 2003/06/30 21:50:17 guy Exp $
4  *
5  * Ethereal - Network traffic analyzer
6  * By Gerald Combs <gerald@ethereal.com>
7  * Copyright 1998 Gerald Combs
8  * 
9  * This program is free software; you can redistribute it and/or
10  * modify it under the terms of the GNU General Public License
11  * as published by the Free Software Foundation; either version 2
12  * of the License, or (at your option) any later version.
13  * 
14  * This program is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17  * GNU General Public License for more details.
18  * 
19  * You should have received a copy of the GNU General Public License
20  * along with this program; if not, write to the Free Software
21  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
22  */
23
24 #ifndef __PACKET_FCCT_H_
25 #define __PACKET_FCCT_H_
26
27 /* Well-known GSTYPEs */
28 #define FCCT_GSTYPE_KEYSVC   0xF7
29 #define FCCT_GSTYPE_ALIASSVC 0xF8
30 #define FCCT_GSTYPE_MGMTSVC  0xFA
31 #define FCCT_GSTYPE_TIMESVC  0xFB
32 #define FCCT_GSTYPE_DIRSVC   0xFC
33
34 /* Well-known GSSUBTYPES */
35 /* Actual servers serving the directory service type identified by subtype */ 
36 #define FCCT_GSSUBTYPE_DNS  0x02
37 #define FCCT_GSSUBTYPE_IP   0x03
38 #define FCCT_GSSUBTYPE_FCS  0x01
39 #define FCCT_GSSUBTYPE_UNS  0x02
40 #define FCCT_GSSUBTYPE_FZS  0x03
41 #define FCCT_GSSUBTYPE_AS   0x01
42 #define FCCT_GSSUBTYPE_TS   0x01
43
44 /* Derived field: Server servicing the request */
45 #define FCCT_GSRVR_DNS       0x1
46 #define FCCT_GSRVR_IP        0x2
47 #define FCCT_GSRVR_FCS       0x3
48 #define FCCT_GSRVR_UNS       0x4
49 #define FCCT_GSRVR_FZS       0x5
50 #define FCCT_GSRVR_AS        0x6
51 #define FCCT_GSRVR_TS        0x7
52 #define FCCT_GSRVR_KS        0x8
53 #define FCCT_GSRVR_UNKNOWN   0xFF
54
55 /* Reject code definitions */
56 #define FCCT_RJT_INVCMDCODE    0x1
57 #define FCCT_RJT_INVVERSION    0x2
58 #define FCCT_RJT_LOGICALERR    0x3
59 #define FCCT_RJT_INVSIZE       0x4
60 #define FCCT_RJT_LOGICALBSY    0x5
61 #define FCCT_RJT_PROTOERR      0x7
62 #define FCCT_RJT_GENFAIL       0x9
63 #define FCCT_RJT_CMDNOTSUPP    0xB
64
65 #define FCCT_MSG_REQ_MAX       0x8000 /* All opcodes below this are requests */
66 #define FCCT_MSG_RJT           0x8001 /* Reject CT message */
67 #define FCCT_MSG_ACC           0x8002 /* Accept CT message */
68
69 #define FCCT_PRMBL_SIZE        16
70 #define FCCT_EXTPRMBL_SIZE     88
71
72 extern const value_string fc_ct_rjt_code_vals [];
73
74 typedef struct _fc_ct_preamble {
75     guint32 in_id:24,
76             revision:8;
77     guint8  gstype;
78     guint8  gssubtype;
79     guint8  options;
80     guint8  rsvd1;
81     guint16 opcode;
82     guint16 maxres_size;
83     guint8  rsvd2;
84     guint8  rjt_code;
85     guint8  rjt_code_det;
86     guint8  rjt_code_vendor;
87 } fc_ct_preamble;
88
89 typedef struct _fc_ct_ext_hdr {
90     guint32 auth_said;
91     guint32 tid;
92     guint32 req_pname[2];
93     guint32 timestamp[2];
94     guint32 auth_hashblk[15];
95 } fc_ct_ext_hdr;
96
97 #endif