2005-10-03 11:36:24 +00:00
|
|
|
/* t38_analysis.c
|
2006-05-22 07:29:40 +00:00
|
|
|
* T.38 fax analysis for Wireshark
|
2005-10-03 11:36:24 +00:00
|
|
|
*
|
|
|
|
* $Id$
|
|
|
|
*
|
|
|
|
* Copyright 2005 Verso Technologies Inc.
|
|
|
|
* By Alejandro Vaquero <alejandro.vaquero@verso.com>
|
|
|
|
*
|
|
|
|
*
|
2006-05-21 05:12:17 +00:00
|
|
|
* Wireshark - Network traffic analyzer
|
|
|
|
* By Gerald Combs <gerald@wireshark.org>
|
2005-10-03 11:36:24 +00:00
|
|
|
* Copyright 1998 Gerald Combs
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* as published by the Free Software Foundation; either version 2
|
|
|
|
* of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifdef HAVE_CONFIG_H
|
|
|
|
# include "config.h"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#include <string.h>
|
|
|
|
|
|
|
|
#include "graph_analysis.h"
|
|
|
|
|
|
|
|
#include "globals.h"
|
|
|
|
|
|
|
|
#include <epan/tap.h>
|
|
|
|
#include <epan/epan_dissect.h>
|
|
|
|
#include <epan/dissectors/packet-t38.h>
|
|
|
|
#include <epan/dissectors/packet-rtp.h>
|
|
|
|
#include <epan/conversation.h>
|
|
|
|
#include <epan/stat_cmd_args.h>
|
2006-01-15 15:01:14 +00:00
|
|
|
#include "stat_menu.h"
|
2005-10-03 11:36:24 +00:00
|
|
|
|
|
|
|
#include "main.h"
|
|
|
|
#include "alert_box.h"
|
|
|
|
#include "simple_dialog.h"
|
|
|
|
#include "graph_analysis.h"
|
2005-10-03 22:23:04 +00:00
|
|
|
#include "gui_stat_menu.h"
|
2005-10-03 11:36:24 +00:00
|
|
|
|
2006-01-15 15:01:14 +00:00
|
|
|
void voip_calls_init_tap(const char *);
|
2005-10-03 11:36:24 +00:00
|
|
|
|
|
|
|
/****************************************************************************/
|
2006-01-15 15:01:14 +00:00
|
|
|
/* user confirmed the info dialog */
|
|
|
|
/* callback from dialog */
|
|
|
|
static void t38_analysis_answered_cb(gpointer dialog _U_, gint btn _U_, gpointer data _U_)
|
2005-10-03 11:36:24 +00:00
|
|
|
{
|
2006-01-15 15:01:14 +00:00
|
|
|
voip_calls_init_tap("");
|
2005-10-03 11:36:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/****************************************************************************/
|
|
|
|
/* entry point from main menu */
|
2006-01-15 15:01:14 +00:00
|
|
|
static void t38_analysis_cb(GtkWidget *w _U_, gpointer data _U_)
|
2005-10-03 11:36:24 +00:00
|
|
|
{
|
2006-01-15 15:01:14 +00:00
|
|
|
gpointer dialog;
|
2005-10-03 11:36:24 +00:00
|
|
|
|
2006-01-15 15:01:14 +00:00
|
|
|
/* We have moved this directly to the VoIP Calls */
|
|
|
|
dialog = simple_dialog(ESD_TYPE_INFO, ESD_BTN_OK,
|
|
|
|
"This feature has been moved to the \"VoIP Calls\"");
|
|
|
|
simple_dialog_set_cb(dialog, t38_analysis_answered_cb, NULL);
|
2005-10-03 11:36:24 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/****************************************************************************/
|
|
|
|
static void
|
2006-02-11 13:05:24 +00:00
|
|
|
t38_analysis_init(const char *dummy _U_, void* userdata _U_)
|
2005-10-03 11:36:24 +00:00
|
|
|
{
|
|
|
|
t38_analysis_cb(NULL, NULL);
|
|
|
|
}
|
|
|
|
|
|
|
|
/****************************************************************************/
|
|
|
|
void
|
|
|
|
register_tap_listener_t38_analysis(void)
|
|
|
|
{
|
2006-02-11 13:05:24 +00:00
|
|
|
register_stat_cmd_arg("t38", t38_analysis_init,NULL);
|
2005-10-03 11:36:24 +00:00
|
|
|
|
|
|
|
|
|
|
|
register_stat_menu_item("Fax T38 Analysis...", REGISTER_STAT_GROUP_TELEPHONY,
|
|
|
|
t38_analysis_cb, NULL, NULL, NULL);
|
|
|
|
}
|