2 * IAX2 analysis addition for Wireshark
6 * based on rtp_analysis.c
7 * Copyright 2003, Alcatel Business Systems
8 * By Lars Ruoff <lars.ruoff@gmx.net>
11 * Copyright 2003, Iskratel, Ltd, Kranj
12 * By Miha Jemec <m.jemec@iskratel.si>
14 * Wireshark - Network traffic analyzer
15 * By Gerald Combs <gerald@wireshark.org>
16 * Copyright 1998 Gerald Combs
18 * This program is free software; you can redistribute it and/or
19 * modify it under the terms of the GNU General Public License
20 * as published by the Free Software Foundation; either version 2
21 * of the License, or (at your option) any later version.
23 * This program is distributed in the hope that it will be useful,
24 * but WITHOUT ANY WARRANTY; without even the implied warranty of
25 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
26 * GNU General Public License for more details.
28 * You should have received a copy of the GNU General Public License
29 * along with this program; if not, write to the Free Software
30 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
33 #ifndef __IAX2_ANALYSIS_H__
34 #define __IAX2_ANALYSIS_H__
37 #include <epan/address.h>
38 #include <epan/packet_info.h>
56 /****************************************************************************/
57 /* structure that holds the information about the forward and reversed direction */
58 typedef struct _iax2_bw_history_item {
61 } iax2_bw_history_item;
65 typedef struct _tap_iax2_stat_t {
66 gboolean first_packet; /* do not use in code that is called after rtp_packet_analyse */
67 /* use (flags & STAT_FLAG_FIRST) instead */
68 /* all of the following fields will be initialized after
69 rtp_packet_analyse has been called */
70 guint32 flags; /* see STAT_FLAG-defines below */
73 guint32 delta_timestamp;
75 iax2_bw_history_item bw_history[BUFF_BW];
76 guint16 bw_start_index;
98 #define PT_UNDEFINED -1
100 /* status flags for the flags parameter in tap_iax2_stat_t */
101 #define STAT_FLAG_FIRST 0x001
102 #define STAT_FLAG_MARKER 0x002
103 #define STAT_FLAG_WRONG_SEQ 0x004
104 #define STAT_FLAG_PT_CHANGE 0x008
105 #define STAT_FLAG_PT_CN 0x010
106 #define STAT_FLAG_FOLLOW_PT_CN 0x020
107 #define STAT_FLAG_REG_PT_CHANGE 0x040
108 #define STAT_FLAG_WRONG_TIMESTAMP 0x080
113 /* function for analysing an RTP packet. Called from rtp_analysis and rtp_streams */
114 extern int iax2_packet_analyse(tap_iax2_stat_t *statinfo,
116 const struct _iax2_info_t *iax2info);
119 #endif /* __IAX2_ANALYSIS_H__ */