"uint" is defined on all platforms; use "guint" instead.
[obnox/wireshark/wip.git] / follow.h
1 /* follow.h
2  *
3  * $Id: follow.h,v 1.11 2002/01/21 07:36:31 guy Exp $
4  *
5  * Copyright 1998 Mike Hall <mlh@io.com>
6  *
7  * Ethereal - Network traffic analyzer
8  * By Gerald Combs <gerald@ethereal.com>
9  * Copyright 1998 Gerald Combs
10  * 
11  * This program is free software; you can redistribute it and/or
12  * modify it under the terms of the GNU General Public License
13  * as published by the Free Software Foundation; either version 2
14  * of the License, or (at your option) any later version.
15  * 
16  * This program is distributed in the hope that it will be useful,
17  * but WITHOUT ANY WARRANTY; without even the implied warranty of
18  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19  * GNU General Public License for more details.
20  * 
21  * You should have received a copy of the GNU General Public License
22  * along with this program; if not, write to the Free Software
23  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
24  *
25  */
26
27 #ifndef __FOLLOW_H__
28 #define __FOLLOW_H__
29
30 #include <epan/packet.h>
31
32 #define MAX_IPADDR_LEN  16
33
34 extern gboolean incomplete_tcp_stream;
35
36 typedef struct _tcp_frag {
37   u_long              seq;
38   u_long              len;
39   u_long              data_len;
40   u_char             *data;
41   struct _tcp_frag   *next;
42 } tcp_frag;
43
44 typedef struct _tcp_stream_chunk {
45   guint8      src_addr[MAX_IPADDR_LEN];
46   guint16     src_port;
47   guint32     dlen;
48 } tcp_stream_chunk;
49
50 char* build_follow_filter( packet_info * );
51 void reassemble_tcp( u_long, u_long, const char*, u_long, int, 
52                      address *, address *, u_int, u_int );
53 void  reset_tcp_reassembly( void );
54
55 typedef struct {
56         guint8          ip_address[2][MAX_IPADDR_LEN];
57         guint32         tcp_port[2];
58         unsigned int    bytes_written[2];
59         gboolean        is_ipv6;
60 } follow_tcp_stats_t;
61
62 void follow_tcp_stats(follow_tcp_stats_t* stats);
63
64 #endif