Ver. 2.0.1
This commit is contained in:
parent
8676769506
commit
fe8ecadd7f
1
.gitignore
vendored
1
.gitignore
vendored
@ -43,3 +43,4 @@ wireshark-1.2.10.tar.bz2
|
||||
/wireshark-1.12.6.tar.bz2
|
||||
/wireshark-1.12.7.tar.bz2
|
||||
/wireshark-1.12.8.tar.bz2
|
||||
/wireshark-2.0.1.tar.bz2
|
||||
|
2
sources
2
sources
@ -1 +1 @@
|
||||
988a4595a4a87dafb3c4870ea40e89b5 wireshark-1.12.8.tar.bz2
|
||||
c1610ab2238965363b811e5188750fb1 wireshark-2.0.1.tar.bz2
|
||||
|
@ -7,7 +7,7 @@ diff --git a/epan/wslua/template-init.lua b/epan/wslua/template-init.lua
|
||||
index 3fe2aca..2b48f9b 100644
|
||||
--- a/epan/wslua/template-init.lua
|
||||
+++ b/epan/wslua/template-init.lua
|
||||
@@ -43,7 +43,7 @@ if running_superuser then
|
||||
@@ -41,7 +41,7 @@ if running_superuser then
|
||||
local disabled_lib = {}
|
||||
setmetatable(disabled_lib,{ __index = function() error("this package ".. hint) end } );
|
||||
|
||||
|
@ -7,11 +7,11 @@ because of permissions.
|
||||
|
||||
Signed-off-by: Jan Safranek <jsafrane@redhat.com>
|
||||
|
||||
diff --git a/capture_sync.c b/capture_sync.c
|
||||
diff --git a/capchild/capture_sync.c b/capchild/capture_sync.c
|
||||
index 2f9d2cc..b18e47f 100644
|
||||
--- a/capture_sync.c
|
||||
+++ b/capture_sync.c
|
||||
@@ -374,6 +374,7 @@ sync_pipe_start(capture_options *capture_opts, capture_session *cap_session, voi
|
||||
--- a/capchild/capture_sync.c
|
||||
+++ b/capchild/capture_sync.c
|
||||
@@ -382,6 +382,7 @@ sync_pipe_start(capture_options *capture_opts, capture_session *cap_session, voi
|
||||
gchar *signal_pipe_name;
|
||||
#else
|
||||
char errmsg[1024+1];
|
||||
@ -19,7 +19,7 @@ index 2f9d2cc..b18e47f 100644
|
||||
int sync_pipe[2]; /* pipe used to send messages from child to parent */
|
||||
enum PIPES { PIPE_READ, PIPE_WRITE }; /* Constants 0 and 1 for PIPE_READ and PIPE_WRITE */
|
||||
#endif
|
||||
@@ -649,8 +650,11 @@ sync_pipe_start(capture_options *capture_opts, capture_session *cap_session, voi
|
||||
@@ -730,8 +731,11 @@ sync_pipe_start(capture_options *capture_opts, capture_session *cap_session, voi
|
||||
dup2(sync_pipe[PIPE_WRITE], 2);
|
||||
ws_close(sync_pipe[PIPE_READ]);
|
||||
execv(argv[0], argv);
|
||||
@ -33,7 +33,7 @@ index 2f9d2cc..b18e47f 100644
|
||||
sync_pipe_errmsg_to_parent(2, errmsg, "");
|
||||
|
||||
/* Exit with "_exit()", so that we don't close the connection
|
||||
@@ -745,6 +749,7 @@ sync_pipe_open_command(char** argv, int *data_read_fd,
|
||||
@@ -826,6 +830,7 @@ sync_pipe_open_command(char** argv, int *data_read_fd,
|
||||
PROCESS_INFORMATION pi;
|
||||
#else
|
||||
char errmsg[1024+1];
|
||||
@ -41,7 +41,7 @@ index 2f9d2cc..b18e47f 100644
|
||||
int sync_pipe[2]; /* pipe used to send messages from child to parent */
|
||||
int data_pipe[2]; /* pipe used to send data from child to parent */
|
||||
#endif
|
||||
@@ -879,8 +884,11 @@ sync_pipe_open_command(char** argv, int *data_read_fd,
|
||||
@@ -998,8 +1003,11 @@ sync_pipe_open_command(char** argv, int *data_read_fd,
|
||||
ws_close(sync_pipe[PIPE_READ]);
|
||||
ws_close(sync_pipe[PIPE_WRITE]);
|
||||
execv(argv[0], argv);
|
||||
|
@ -7,7 +7,7 @@ diff --git a/plugins/profinet/packet-dcom-cba.c b/plugins/profinet/packet-dcom-c
|
||||
index 0f1658a..f7fd322 100644
|
||||
--- a/plugins/profinet/packet-dcom-cba.c
|
||||
+++ b/plugins/profinet/packet-dcom-cba.c
|
||||
@@ -557,7 +557,7 @@ dissect_ICBAPhysicalDevice_get_LogicalDevice_rqst(tvbuff_t *tvb, int offset,
|
||||
@@ -555,7 +555,7 @@ dissect_ICBAPhysicalDevice_get_LogicalDevice_rqst(tvbuff_t *tvb, int offset,
|
||||
packet_info *pinfo, proto_tree *tree, dcerpc_info *di, guint8 *drep)
|
||||
{
|
||||
guint32 u32Pointer;
|
||||
|
@ -8,9 +8,9 @@ diff --git a/wireshark.desktop b/wireshark.desktop
|
||||
index 9e3ddcd..828eca7 100644
|
||||
--- a/wireshark.desktop
|
||||
+++ b/wireshark.desktop
|
||||
@@ -75,4 +75,4 @@ Terminal=false
|
||||
MimeType=application/vnd.tcpdump.pcap;application/x-pcapng;application/x-snoop;application/x-iptrace;application/x-lanalyzer;application/x-nettl;application/x-radcom;application/x-etherpeek;application/x-visualnetworks;application/x-netinstobserver;application/x-5view;
|
||||
@@ -108,4 +108,4 @@ Terminal=false
|
||||
MimeType=application/vnd.tcpdump.pcap;application/x-pcapng;application/x-snoop;application/x-iptrace;application/x-lanalyzer;application/x-nettl;application/x-radcom;application/x-etherpeek;application/x-visualnetworks;application/x-netinstobserver;application/x-5view;application/x-tektronix-rf5;
|
||||
# Category entry according to:
|
||||
# http://standards.freedesktop.org/menu-spec/1.0/
|
||||
-Categories=System;Monitor;GTK;
|
||||
+Categories=Application;Network;GTK;
|
||||
-Categories=System;Monitor;Qt;
|
||||
+Categories=Application;Network;Qt;
|
||||
|
@ -1,27 +1,28 @@
|
||||
From: =?UTF-8?q?Radek=20Vok=C3=A1l?= <rvokal@fedoraproject.org>
|
||||
Date: Thu, 17 Dec 2009 09:17:07 +0000
|
||||
Subject: [PATCH] Add pkgconfig entry
|
||||
commit 7a47641e4b8b152264bb5d85807821a3d982eeae
|
||||
Author: Radek Vokal <rvokal@fedoraproject.org>
|
||||
Date: Wed Jan 6 09:37:49 2016 +0100
|
||||
|
||||
Add pkgconfig entry
|
||||
|
||||
diff --git a/Makefile.am b/Makefile.am
|
||||
index c60d873..40a6e4d 100644
|
||||
index 913e064..30f8107 100644
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -53,6 +53,9 @@ EXTRA_PROGRAMS = wireshark wireshark-qt tshark tfshark capinfos captype editcap
|
||||
mergecap dftest randpkt text2pcap dumpcap reordercap rawshark \
|
||||
wireshark_cxx echld_test
|
||||
@@ -55,6 +55,9 @@ EXTRA_PROGRAMS = wireshark-gtk wireshark tshark tfshark capinfos captype editcap
|
||||
dist_pkgdata_DATA = COPYING manuf services cfilters colorfilters dfilters \
|
||||
smi_modules ipmap.html pdml2html.xsl
|
||||
|
||||
+pkgconfigdir = $(libdir)/pkgconfig
|
||||
+pkgconfig_DATA = wireshark.pc
|
||||
+
|
||||
#
|
||||
# Wireshark configuration files are put in $(pkgdatadir).
|
||||
# Install global profiles in the "profiles" subdirectory
|
||||
#
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 20eb3b3..8c9b79c 100644
|
||||
index dc8c307..dedd1a4 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -2779,6 +2779,7 @@ AC_CONFIG_HEADERS(config.h)
|
||||
@@ -3101,6 +3101,7 @@ AC_CONFIG_HEADERS(config.h)
|
||||
AC_OUTPUT(
|
||||
Makefile
|
||||
doxygen.cfg
|
||||
@ -30,13 +31,13 @@ index 20eb3b3..8c9b79c 100644
|
||||
_CUSTOM_ASN1_AC_OUTPUT_
|
||||
asn1/acp133/Makefile
|
||||
diff --git a/wireshark.pc.in b/wireshark.pc.in
|
||||
index 91bf28b..2e2fcdc 100644
|
||||
index 826b230..fec2d25 100644
|
||||
--- a/wireshark.pc.in
|
||||
+++ b/wireshark.pc.in
|
||||
@@ -1,14 +1,11 @@
|
||||
-prefix=@CMAKE_INSTALL_PREFIX@
|
||||
-exec_prefix=${prefix}
|
||||
-libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@
|
||||
-libdir=@ABSOLUTE_CMAKE_INSTALL_LIBDIR@
|
||||
-sharedlibdir=${libdir}
|
||||
-includedir=${prefix}/include/wireshark
|
||||
-plugindir=@PLUGIN_INSTALL_DIR@
|
||||
@ -54,6 +55,6 @@ index 91bf28b..2e2fcdc 100644
|
||||
-Cflags: -I${includedir}
|
||||
+Description: Network Traffic Analyzer
|
||||
+Version: @PACKAGE_VERSION@
|
||||
+Requires: glib-2.0 gmodule-2.0
|
||||
+Requires: Qt
|
||||
+Libs: -L@libdir@ -lwireshark -lwiretap
|
||||
+Cflags: -DWS_VAR_IMPORT=extern -DHAVE_STDARG_H -DWS_MSVC_NORETURN= -I@includedir@/wireshark -I@includedir@/wireshark/epan
|
||||
|
@ -1,13 +1,14 @@
|
||||
From: Peter Lemenkov <lemenkov@gmail.com>
|
||||
Date: Fri, 13 Sep 2013 15:25:12 +0400
|
||||
Subject: [PATCH] Install autoconf-related file
|
||||
commit fa2961b8614827f170351d8d3a21961ffc28eabb
|
||||
Author: Peter Lemenkov <lemenkov@gmail.com>
|
||||
Date: Wed Jan 6 09:41:45 2016 +0100
|
||||
|
||||
Install autoconf-related file
|
||||
|
||||
diff --git a/Makefile.am b/Makefile.am
|
||||
index 40a6e4d..82f7fdf 100644
|
||||
index 30f8107..0b13c6f 100644
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -56,6 +56,9 @@ EXTRA_PROGRAMS = wireshark wireshark-qt tshark tfshark capinfos captype editcap
|
||||
@@ -58,6 +58,9 @@ dist_pkgdata_DATA = COPYING manuf services cfilters colorfilters dfilters \
|
||||
pkgconfigdir = $(libdir)/pkgconfig
|
||||
pkgconfig_DATA = wireshark.pc
|
||||
|
||||
@ -15,115 +16,8 @@ index 40a6e4d..82f7fdf 100644
|
||||
+autoconfig_DATA = wireshark.m4
|
||||
+
|
||||
#
|
||||
# Wireshark configuration files are put in $(pkgdatadir).
|
||||
# Install global profiles in the "profiles" subdirectory
|
||||
#
|
||||
diff --git a/wireshark-autoconf.m4 b/wireshark-autoconf.m4
|
||||
deleted file mode 100644
|
||||
index d8015d8..0000000
|
||||
--- a/wireshark-autoconf.m4
|
||||
+++ /dev/null
|
||||
@@ -1,101 +0,0 @@
|
||||
-dnl AM_PATH_WIRESHARK([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]])
|
||||
-dnl Test for wireshark development files, and define WIRESHARK_CFLAGS,
|
||||
-dnl WIRESHARK_LIBS and WIRESHARK_VERSION.
|
||||
-dnl
|
||||
-AC_DEFUN([AM_PATH_WIRESHARK],[
|
||||
- AC_ARG_WITH(wireshark-prefix,
|
||||
- [ --with-wireshark-prefix=PFX Prefix where wireshark libraries are installed (optional)],
|
||||
- wireshark_config_prefix="$withval", wireshark_config_prefix="")
|
||||
-
|
||||
- wireshark_found=no
|
||||
- if test "$wireshark_config_prefix" != "" ; then
|
||||
- AM_PATH_GLIB_2_0(,,,[gmodule])
|
||||
- WIRESHARK_CFLAGS="-DWS_VAR_IMPORT=extern -DWS_MSVC_NORETURN= -I$wireshark_config_prefix/include/wireshark -I$wireshark_config_prefix/include/wireshark/epan -I/usr/include/wireshark -I/usr/include/wireshark/epan $GLIB_CFLAGS"
|
||||
- WIRESHARK_LIBS="-L$wireshark_config_prefix/lib -lwireshark -lwiretap $GLIB_LIBS"
|
||||
- wireshark_found=yes
|
||||
- else
|
||||
- PKG_PROG_PKG_CONFIG()
|
||||
- PKG_CHECK_MODULES(WIRESHARK, wireshark, wireshark_found=yes)
|
||||
- fi
|
||||
-
|
||||
- ac_save_CFLAGS="$CFLAGS"
|
||||
- ac_save_CLIBS="$LIBS"
|
||||
- CFLAGS="$CFLAGS $WIRESHARK_CFLAGS"
|
||||
- LIBS="$WIRESHARK_LIBS $LIBS"
|
||||
- min_wireshark_version=ifelse([$1], ,0.0.0,[$1])
|
||||
- if test $wireshark_found = yes; then
|
||||
- AC_MSG_CHECKING(for wireshark version >= $min_wireshark_version)
|
||||
- wireshark_found=no
|
||||
- AC_TRY_RUN([
|
||||
-#include <stdlib.h>
|
||||
-#include <stdio.h>
|
||||
-#include <string.h>
|
||||
-#include <gmodule.h>
|
||||
-#include <epan/packet.h>
|
||||
-#include <epan/prefs.h>
|
||||
-
|
||||
-int
|
||||
-main()
|
||||
-
|
||||
-{
|
||||
- int ws_major_version, ws_minor_version, ws_micro_version;
|
||||
- int major, minor, micro;
|
||||
- char **tmp_version;
|
||||
-
|
||||
- tmp_version = (char *) strdup("$min_wireshark_version");
|
||||
- major = 0;
|
||||
- minor = 0;
|
||||
- micro = 0;
|
||||
- sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ);
|
||||
- free(tmp_version);
|
||||
- tmp_version = (char *) epan_get_version();
|
||||
- sscanf(tmp_version, "%d.%d.%d",
|
||||
- &ws_major_version, &ws_minor_version, &ws_micro_version);
|
||||
-
|
||||
- if (ws_major_version > major ||
|
||||
- (ws_major_version == major && ws_minor_version > minor) ||
|
||||
- (ws_major_version == major && ws_minor_version == minor &&
|
||||
- ws_micro_version >= micro))
|
||||
- return 0;
|
||||
-
|
||||
- printf("\n*** An old version of wireshark (%d.%d.%d) was found.\n",
|
||||
- ws_major_version, ws_minor_version, ws_micro_version);
|
||||
- printf("*** You need a version of wireshark not older than %d.%d.%d. ",
|
||||
- major, minor, micro);
|
||||
- return 1;
|
||||
-}
|
||||
- ], wireshark_found=yes)
|
||||
- fi
|
||||
-
|
||||
- if test "$wireshark_found" != no; then
|
||||
- AC_LANG_PUSH(C)
|
||||
- AC_LINK_IFELSE([AC_LANG_PROGRAM([
|
||||
-#include <stdlib.h>
|
||||
-#include <stdio.h>
|
||||
-#include <string.h>
|
||||
-#include <gmodule.h>
|
||||
-#include <epan/packet.h>
|
||||
-#include <epan/prefs.h>
|
||||
-], [puts(epan_get_version());])], [WIRESHARK_VERSION=`./conftest$ac_exeext`],
|
||||
-wireshark_found=no)
|
||||
-
|
||||
- AC_LANG_POP
|
||||
- fi
|
||||
-
|
||||
- CFLAGS="$ac_save_CFLAGS"
|
||||
- LIBS="$ac_save_LIBS"
|
||||
-
|
||||
- if test "$wireshark_found" != no; then
|
||||
- AC_MSG_RESULT(yes)
|
||||
- ifelse([$2],, :, [$2])
|
||||
- else
|
||||
- AC_MSG_RESULT(no)
|
||||
- WIRESHARK_CFLAGS=""
|
||||
- WIRESHARK_LIBS=""
|
||||
- WIRESHARK_VERSION=""
|
||||
- ifelse([$3], , :, [$3])
|
||||
- fi
|
||||
- AC_SUBST(WIRESHARK_CFLAGS)
|
||||
- AC_SUBST(WIRESHARK_LIBS)
|
||||
- AC_SUBST(WIRESHARK_VERSION)
|
||||
-])
|
||||
diff --git a/wireshark.m4 b/wireshark.m4
|
||||
new file mode 100644
|
||||
index 0000000..d8015d8
|
||||
|
@ -1,28 +1,44 @@
|
||||
From: Peter Hatina <phatina@redhat.com>
|
||||
Date: Tue, 24 Sep 2013 10:55:09 +0200
|
||||
Subject: [PATCH] move default temporary directory to /var/tmp
|
||||
commit b32de2f6e35b4e7d6ea4d0477db91b12861c09d6
|
||||
Author: Peter Hatina <phatina@gmail.com>
|
||||
Date: Tue Jan 12 13:56:59 2016 +0100
|
||||
|
||||
Conflicts:
|
||||
wsutil/Makefile.common
|
||||
wsutil/filesystem.c
|
||||
wsutil/tempfile.c
|
||||
|
||||
Change-Id: I881c17e1fa3cb292dabe7612bc06748cccfcfcda
|
||||
Move default temporary directory to /var/tmp
|
||||
|
||||
diff --git a/ui/gtk/about_dlg.c b/ui/gtk/about_dlg.c
|
||||
index 0ed474a..fb3275b 100644
|
||||
--- a/ui/gtk/about_dlg.c
|
||||
+++ b/ui/gtk/about_dlg.c
|
||||
@@ -30,6 +30,7 @@
|
||||
#include <wsutil/filesystem.h>
|
||||
#include <wsutil/copyright_info.h>
|
||||
#include <wsutil/ws_version_info.h>
|
||||
+#include <wsutil/wstmpdir.h> /* for get_tmp_dir() */
|
||||
#ifdef HAVE_LIBSMI
|
||||
#include <epan/oids.h>
|
||||
#endif
|
||||
@@ -407,7 +408,7 @@ about_folders_page_new(void)
|
||||
"capture files");
|
||||
|
||||
/* temp */
|
||||
- about_folders_row(table, "Temp", g_get_tmp_dir(),
|
||||
+ about_folders_row(table, "Temp", get_tmp_dir(),
|
||||
"untitled capture files");
|
||||
|
||||
/* pers conf */
|
||||
diff --git a/ui/gtk/proto_help.c b/ui/gtk/proto_help.c
|
||||
index 6de7daa..a644615 100644
|
||||
index 79cafd4..47eec6c 100644
|
||||
--- a/ui/gtk/proto_help.c
|
||||
+++ b/ui/gtk/proto_help.c
|
||||
@@ -42,6 +42,8 @@
|
||||
#include <epan/strutil.h>
|
||||
#include <epan/proto.h>
|
||||
@@ -37,6 +37,8 @@
|
||||
#include "../file.h"
|
||||
|
||||
|
||||
+#include <wsutil/wstmpdir.h> /* for get_tmp_dir() */
|
||||
+
|
||||
#include "ui/gtk/proto_help.h"
|
||||
|
||||
/*
|
||||
@@ -160,7 +162,7 @@ void proto_help_init(void)
|
||||
@@ -155,7 +157,7 @@ void proto_help_init(void)
|
||||
/* Start loop */
|
||||
|
||||
#ifdef PH_DEBUG_LOG
|
||||
@ -31,61 +47,155 @@ index 6de7daa..a644615 100644
|
||||
#endif
|
||||
|
||||
for (i = 0; i < PH_CONF_DIRS; i++) {
|
||||
diff --git a/ui/qt/about_dialog.cpp b/ui/qt/about_dialog.cpp
|
||||
index c0899a0..4fada89 100644
|
||||
--- a/ui/qt/about_dialog.cpp
|
||||
+++ b/ui/qt/about_dialog.cpp
|
||||
@@ -49,6 +49,7 @@
|
||||
#include "file.h"
|
||||
#include "wsutil/file_util.h"
|
||||
#include "wsutil/tempfile.h"
|
||||
+#include "wsutil/wstmpdir.h" /* for get_tmp_dir() */
|
||||
#include "wsutil/plugins.h"
|
||||
#include "wsutil/copyright_info.h"
|
||||
#include "wsutil/ws_version_info.h"
|
||||
@@ -184,7 +185,7 @@ AboutDialog::AboutDialog(QWidget *parent) :
|
||||
message += about_folders_row("\"File\" dialogs", get_last_open_dir(), "capture files");
|
||||
|
||||
/* temp */
|
||||
- message += about_folders_row("Temp", g_get_tmp_dir(), "untitled capture files");
|
||||
+ message += about_folders_row("Temp", get_tmp_dir(), "untitled capture files");
|
||||
|
||||
/* pers conf */
|
||||
message += about_folders_row("Personal configuration",
|
||||
diff --git a/ui/qt/iax2_analysis_dialog.cpp b/ui/qt/iax2_analysis_dialog.cpp
|
||||
index e1ef186..b672b31 100644
|
||||
--- a/ui/qt/iax2_analysis_dialog.cpp
|
||||
+++ b/ui/qt/iax2_analysis_dialog.cpp
|
||||
@@ -41,6 +41,8 @@
|
||||
#include <wsutil/g711.h>
|
||||
#include <wsutil/pint.h>
|
||||
|
||||
+#include <wsutil/wstmpdir.h> /* for get_tmp_dir() */
|
||||
+
|
||||
#include <QFileDialog>
|
||||
#include <QMessageBox>
|
||||
#include <QPushButton>
|
||||
@@ -271,10 +273,10 @@ Iax2AnalysisDialog::Iax2AnalysisDialog(QWidget &parent, CaptureFile &cf) :
|
||||
|
||||
// We keep our temp files open for the lifetime of the dialog. The GTK+
|
||||
// UI opens and closes at various points.
|
||||
- QString tempname = QString("%1/wireshark_iax2_f").arg(QDir::tempPath());
|
||||
+ QString tempname = QString("%1/wireshark_iax2_f").arg(get_tmp_dir());
|
||||
fwd_tempfile_ = new QTemporaryFile(tempname, this);
|
||||
fwd_tempfile_->open();
|
||||
- tempname = QString("%1/wireshark_iax2_r").arg(QDir::tempPath());
|
||||
+ tempname = QString("%1/wireshark_iax2_r").arg(get_tmp_dir());
|
||||
rev_tempfile_ = new QTemporaryFile(tempname, this);
|
||||
rev_tempfile_->open();
|
||||
|
||||
diff --git a/ui/qt/rtp_analysis_dialog.cpp b/ui/qt/rtp_analysis_dialog.cpp
|
||||
index 87322df..fbe9ffa 100644
|
||||
--- a/ui/qt/rtp_analysis_dialog.cpp
|
||||
+++ b/ui/qt/rtp_analysis_dialog.cpp
|
||||
@@ -38,6 +38,8 @@
|
||||
#include <wsutil/g711.h>
|
||||
#include <wsutil/pint.h>
|
||||
|
||||
+#include <wsutil/wstmpdir.h> /* for get_tmp_dir() */
|
||||
+
|
||||
#include <QFileDialog>
|
||||
#include <QMessageBox>
|
||||
#include <QPushButton>
|
||||
@@ -321,10 +323,10 @@ RtpAnalysisDialog::RtpAnalysisDialog(QWidget &parent, CaptureFile &cf, struct _r
|
||||
|
||||
// We keep our temp files open for the lifetime of the dialog. The GTK+
|
||||
// UI opens and closes at various points.
|
||||
- QString tempname = QString("%1/wireshark_rtp_f").arg(QDir::tempPath());
|
||||
+ QString tempname = QString("%1/wireshark_rtp_f").arg(get_tmp_dir());
|
||||
fwd_tempfile_ = new QTemporaryFile(tempname, this);
|
||||
fwd_tempfile_->open();
|
||||
- tempname = QString("%1/wireshark_rtp_r").arg(QDir::tempPath());
|
||||
+ tempname = QString("%1/wireshark_rtp_r").arg(get_tmp_dir());
|
||||
rev_tempfile_ = new QTemporaryFile(tempname, this);
|
||||
rev_tempfile_->open();
|
||||
|
||||
diff --git a/ui/qt/rtp_audio_stream.cpp b/ui/qt/rtp_audio_stream.cpp
|
||||
index 1346a4d..4d34a3b 100644
|
||||
--- a/ui/qt/rtp_audio_stream.cpp
|
||||
+++ b/ui/qt/rtp_audio_stream.cpp
|
||||
@@ -33,6 +33,7 @@
|
||||
#include <ui/rtp_stream.h>
|
||||
|
||||
#include <wsutil/nstime.h>
|
||||
+#include <wsutil/wstmpdir.h> /* for get_tmp_dir() */
|
||||
|
||||
#include <QAudioFormat>
|
||||
#include <QAudioOutput>
|
||||
@@ -71,7 +72,7 @@ RtpAudioStream::RtpAudioStream(QObject *parent, _rtp_stream_info *rtp_stream) :
|
||||
visual_sample_rate_, SPEEX_RESAMPLER_QUALITY_MIN, NULL);
|
||||
ws_codec_resampler_skip_zeros(visual_resampler_);
|
||||
|
||||
- QString tempname = QString("%1/wireshark_rtp_stream").arg(QDir::tempPath());
|
||||
+ QString tempname = QString("%1/wireshark_rtp_stream").arg(get_tmp_dir());
|
||||
tempfile_ = new QTemporaryFile(tempname, this);
|
||||
tempfile_->open();
|
||||
|
||||
diff --git a/wsutil/Makefile.common b/wsutil/Makefile.common
|
||||
index 75c31bd..81648a7 100644
|
||||
index e24f015..49f0a95 100644
|
||||
--- a/wsutil/Makefile.common
|
||||
+++ b/wsutil/Makefile.common
|
||||
@@ -62,7 +62,8 @@ LIBWSUTIL_SRC = \
|
||||
time_util.c \
|
||||
type_util.c \
|
||||
@@ -71,7 +71,8 @@ LIBWSUTIL_SRC = \
|
||||
ws_mempbrk.c \
|
||||
u3.c \
|
||||
- unicode-utils.c
|
||||
+ unicode-utils.c \
|
||||
unicode-utils.c \
|
||||
- ws_version_info.c
|
||||
+ ws_version_info.c \
|
||||
+ wstmpdir.c
|
||||
|
||||
# Header files that don't declare replacement functions for functions
|
||||
# present in the APIs/ABIs of some, but not all, targets.
|
||||
@@ -128,7 +129,8 @@ libwsutil_nonrepl_INCLUDES = \
|
||||
ws_diag_control.h \
|
||||
ws_mempbrk.h \
|
||||
ws_mempbrk_int.h \
|
||||
- ws_version_info.h
|
||||
+ ws_version_info.h \
|
||||
+ wstmpdir.h
|
||||
|
||||
# Header files that are not generated from other files
|
||||
LIBWSUTIL_INCLUDES = \
|
||||
@@ -104,7 +105,8 @@ LIBWSUTIL_INCLUDES = \
|
||||
time_util.h \
|
||||
type_util.h \
|
||||
u3.h \
|
||||
- unicode-utils.h
|
||||
+ unicode-utils.h \
|
||||
+ wstmpdir.h
|
||||
|
||||
#
|
||||
# Editor modelines - https://www.wireshark.org/tools/modelines.html
|
||||
diff --git a/wsutil/tempfile.c b/wsutil/tempfile.c
|
||||
index ccefe30..ac40319 100644
|
||||
index 93bd66f..757b6c8 100644
|
||||
--- a/wsutil/tempfile.c
|
||||
+++ b/wsutil/tempfile.c
|
||||
@@ -48,6 +48,7 @@
|
||||
@@ -44,6 +44,7 @@
|
||||
|
||||
#include "tempfile.h"
|
||||
#include <wsutil/file_util.h>
|
||||
+#include <wsutil/wstmpdir.h> /* For get_tmp_dir() */
|
||||
+#include <wsutil/wstmpdir.h> /* for get_tmp_dir() */
|
||||
|
||||
#ifndef __set_errno
|
||||
#define __set_errno(x) errno=(x)
|
||||
@@ -150,7 +151,7 @@ mkdtemp (char *template)
|
||||
@@ -146,7 +147,7 @@ mkdtemp (char *path_template)
|
||||
*/
|
||||
char *get_tempfile_path(const char *filename)
|
||||
{
|
||||
- return g_strdup_printf("%s" G_DIR_SEPARATOR_S "%s", g_get_tmp_dir(), filename);
|
||||
+ return g_strdup_printf("%s" G_DIR_SEPARATOR_S "%s", get_tmp_dir(), filename);
|
||||
- return g_strdup_printf("%s" G_DIR_SEPARATOR_S "%s", g_get_tmp_dir(), filename);
|
||||
+ return g_strdup_printf("%s" G_DIR_SEPARATOR_S "%s", get_tmp_dir(), filename);
|
||||
}
|
||||
|
||||
#define MAX_TEMPFILES 3
|
||||
@@ -207,7 +208,7 @@ create_tempfile(char **namebuf, const char *pfx)
|
||||
tf[idx].path = (char *)g_malloc(tf[idx].len);
|
||||
}
|
||||
@@ -203,7 +204,7 @@ create_tempfile(char **namebuf, const char *pfx)
|
||||
tf[idx].path = (char *)g_malloc(tf[idx].len);
|
||||
}
|
||||
|
||||
- tmp_dir = g_get_tmp_dir();
|
||||
+ tmp_dir = get_tmp_dir();
|
||||
- tmp_dir = g_get_tmp_dir();
|
||||
+ tmp_dir = get_tmp_dir();
|
||||
|
||||
#ifdef _WIN32
|
||||
_tzset();
|
||||
@@ -241,7 +242,7 @@ create_tempfile(char **namebuf, const char *pfx)
|
||||
_tzset();
|
||||
@@ -237,7 +238,7 @@ create_tempfile(char **namebuf, const char *pfx)
|
||||
|
||||
/**
|
||||
* Create a directory with the given prefix (e.g. "wireshark"). The path
|
||||
@ -94,15 +204,37 @@ index ccefe30..ac40319 100644
|
||||
*
|
||||
* @param namebuf
|
||||
* @param pfx A prefix for the temporary directory.
|
||||
@@ -269,7 +270,7 @@ create_tempdir(char **namebuf, const char *pfx)
|
||||
/*
|
||||
* We can't use get_tempfile_path here because we're called from dumpcap.c.
|
||||
*/
|
||||
- tmp_dir = g_get_tmp_dir();
|
||||
+ tmp_dir = get_tmp_dir();
|
||||
@@ -265,7 +266,7 @@ create_tempdir(char **namebuf, const char *pfx)
|
||||
/*
|
||||
* We can't use get_tempfile_path here because we're called from dumpcap.c.
|
||||
*/
|
||||
- tmp_dir = g_get_tmp_dir();
|
||||
+ tmp_dir = get_tmp_dir();
|
||||
|
||||
while (g_snprintf(td_path[idx], td_path_len[idx], "%s%c%s" TMP_FILE_SUFFIX, tmp_dir, G_DIR_SEPARATOR, pfx) > td_path_len[idx]) {
|
||||
td_path_len[idx] *= 2;
|
||||
while (g_snprintf(td_path[idx], td_path_len[idx], "%s%c%s" TMP_FILE_SUFFIX, tmp_dir, G_DIR_SEPARATOR, pfx) > td_path_len[idx]) {
|
||||
td_path_len[idx] *= 2;
|
||||
diff --git a/wsutil/tempfile.h b/wsutil/tempfile.h
|
||||
index f595632..5e22227 100644
|
||||
--- a/wsutil/tempfile.h
|
||||
+++ b/wsutil/tempfile.h
|
||||
@@ -45,7 +45,7 @@ WS_DLL_PUBLIC char *get_tempfile_path(const char *filename);
|
||||
|
||||
/**
|
||||
* Create a tempfile with the given prefix (e.g. "wireshark"). The path
|
||||
- * is created using g_get_tmp_dir and mkstemp.
|
||||
+ * is created using get_tmp_dir and mkstemp.
|
||||
*
|
||||
* @param namebuf [in,out] If not NULL, receives the full path of the temp file.
|
||||
* Must NOT be freed.
|
||||
@@ -56,7 +56,7 @@ WS_DLL_PUBLIC int create_tempfile(char **namebuf, const char *pfx);
|
||||
|
||||
/**
|
||||
* Create a directory with the given prefix (e.g. "wireshark"). The path
|
||||
- * is created using g_get_tmp_dir and mkdtemp.
|
||||
+ * is created using get_tmp_dir and mkdtemp.
|
||||
*
|
||||
* @param namebuf If not NULL, receives the full path of the temp directory.
|
||||
* Must NOT be freed.
|
||||
diff --git a/wsutil/wstmpdir.c b/wsutil/wstmpdir.c
|
||||
new file mode 100644
|
||||
index 0000000..d8b733b
|
||||
|
@ -8,13 +8,13 @@ index 828eca7..eef3503 100644
|
||||
--- a/wireshark.desktop
|
||||
+++ b/wireshark.desktop
|
||||
@@ -69,8 +69,8 @@ Comment[fi]=Verkkoliikenne analysaattori
|
||||
Comment[fr]=Analyseur de trafic réseau
|
||||
Comment[sv]=Nätverkstrafikanalysator
|
||||
Comment[vi]=Trình phân tích giao thông mạng
|
||||
Comment[uk]=Аналізатор мережевого трафіку
|
||||
Icon=wireshark
|
||||
-TryExec=wireshark
|
||||
-Exec=wireshark %f
|
||||
+TryExec=/usr/sbin/wireshark
|
||||
+Exec=/usr/sbin/wireshark %f
|
||||
Terminal=false
|
||||
MimeType=application/vnd.tcpdump.pcap;application/x-pcapng;application/x-snoop;application/x-iptrace;application/x-lanalyzer;application/x-nettl;application/x-radcom;application/x-etherpeek;application/x-visualnetworks;application/x-netinstobserver;application/x-5view;
|
||||
MimeType=application/vnd.tcpdump.pcap;application/x-pcapng;application/x-snoop;application/x-iptrace;application/x-lanalyzer;application/x-nettl;application/x-radcom;application/x-etherpeek;application/x-visualnetworks;application/x-netinstobserver;application/x-5view;application/x-tektronix-rf5;
|
||||
# Category entry according to:
|
||||
|
@ -1,171 +0,0 @@
|
||||
From: Peter Lemenkov <lemenkov@gmail.com>
|
||||
Date: Thu, 13 Aug 2015 18:13:45 +0300
|
||||
Subject: [PATCH] Allow redefining all ports for RADIUS
|
||||
|
||||
RADIUS configuration sometimes uses more ports - for example, one for
|
||||
authentication, another one for accounting. Sometimes it uses the entire
|
||||
port ranges. In case of FreeRADIUS 2.x.x server it might look like this:
|
||||
|
||||
...
|
||||
listen {
|
||||
type = auth
|
||||
ipaddr = *
|
||||
port = 13812
|
||||
}
|
||||
listen {
|
||||
type = acct
|
||||
ipaddr = *
|
||||
port = 13813
|
||||
}
|
||||
...
|
||||
|
||||
Unfortunately we allow only one port to be redefined, not more. So it
|
||||
forces a person who's analyzing a traffic from such a RADIUS server
|
||||
manually select "Decode as" every time for each port.
|
||||
|
||||
It was requested at least once to lift this limitation:
|
||||
|
||||
* https://ask.wireshark.org/questions/2189/decode-multiple-ports-as-radius
|
||||
|
||||
So let's fix it!
|
||||
|
||||
With this commit it's possible to set a port ranges for RADIUS dissector
|
||||
to handle. An example (default) configuration looks like (see
|
||||
~/.wireshark/preferences):
|
||||
|
||||
radius.ports: 1645,1646,1700,1812,1813,3799
|
||||
|
||||
Old "alternate_port" preference is marked as obsolete. It won't be shown
|
||||
to a user but it will still be used if exists (remained from a previous
|
||||
installations).
|
||||
|
||||
*Ver. 2*:
|
||||
Old alternate_port value is copied to the ports range, thus making
|
||||
transition even more smooth.
|
||||
|
||||
Change-Id: Ibdd6f4f9fa1e0ac186147cec380bbfc62d509b17
|
||||
Signed-off-by: Peter Lemenkov <lemenkov@gmail.com>
|
||||
Reviewed-on: https://code.wireshark.org/review/10015
|
||||
Petri-Dish: Anders Broman <a.broman58@gmail.com>
|
||||
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
|
||||
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
|
||||
Reviewed-by: Anders Broman <a.broman58@gmail.com>
|
||||
|
||||
Conflicts:
|
||||
epan/dissectors/packet-radius.c
|
||||
|
||||
diff --git a/epan/dissectors/packet-radius.c b/epan/dissectors/packet-radius.c
|
||||
index 7cc440e..5f9e52e 100644
|
||||
--- a/epan/dissectors/packet-radius.c
|
||||
+++ b/epan/dissectors/packet-radius.c
|
||||
@@ -95,12 +95,16 @@ typedef struct {
|
||||
#define RD_HDR_LENGTH 4
|
||||
#define HDR_LENGTH (RD_HDR_LENGTH + AUTHENTICATOR_LENGTH)
|
||||
|
||||
-#define UDP_PORT_RADIUS 1645
|
||||
-#define UDP_PORT_RADIUS_NEW 1812
|
||||
-#define UDP_PORT_RADACCT 1646
|
||||
-#define UDP_PORT_RADACCT_NEW 1813
|
||||
-#define UDP_PORT_DAE_OLD 1700 /* DAE: pre RFC */
|
||||
-#define UDP_PORT_DAE 3799 /* DAE: rfc3576 */
|
||||
+/*
|
||||
+ * Default RADIUS ports:
|
||||
+ * 1645 (Authentication, pre RFC 2865)
|
||||
+ * 1646 (Accounting, pre RFC 2866)
|
||||
+ * 1812 (Authentication, RFC 2865)
|
||||
+ * 1813 (Accounting, RFC 2866)
|
||||
+ * 1700 (Dynamic Authorization Extensions, pre RFC 3576)
|
||||
+ * 3799 (Dynamic Authorization Extensions, RFC 3576)
|
||||
+*/
|
||||
+#define DEFAULT_RADIUS_PORT_RANGE "1645,1646,1700,1812,1813,3799"
|
||||
|
||||
static radius_dictionary_t* dict = NULL;
|
||||
|
||||
@@ -152,6 +156,7 @@ static dissector_handle_t eap_handle;
|
||||
static const gchar* shared_secret = "";
|
||||
static gboolean show_length = FALSE;
|
||||
static guint alt_port_pref = 0;
|
||||
+static range_t *global_ports_range;
|
||||
static guint request_ttl = 5;
|
||||
|
||||
static guint8 authenticator[AUTHENTICATOR_LENGTH];
|
||||
@@ -1938,12 +1943,22 @@ extern void radius_register_avp_dissector(guint32 vendor_id, guint32 attribute_i
|
||||
static void
|
||||
radius_init_protocol(void)
|
||||
{
|
||||
+ module_t *radius_module = prefs_find_module("radius");
|
||||
+ pref_t *alternate_port;
|
||||
+
|
||||
if (radius_calls != NULL)
|
||||
{
|
||||
g_hash_table_destroy(radius_calls);
|
||||
radius_calls = NULL;
|
||||
}
|
||||
|
||||
+ if (radius_module) {
|
||||
+ /* Find alternate_port preference and mark it obsolete (thus hiding it from a user) */
|
||||
+ alternate_port = prefs_find_preference(radius_module, "alternate_port");
|
||||
+ if (! prefs_get_preference_obsolete(alternate_port))
|
||||
+ prefs_set_preference_obsolete(alternate_port);
|
||||
+ }
|
||||
+
|
||||
radius_calls = g_hash_table_new(radius_call_hash, radius_call_equal);
|
||||
}
|
||||
|
||||
@@ -2116,6 +2131,10 @@ proto_register_radius(void)
|
||||
&show_length);
|
||||
prefs_register_uint_preference(radius_module, "alternate_port","Alternate Port",
|
||||
"An alternate UDP port to decode as RADIUS", 10, &alt_port_pref);
|
||||
+
|
||||
+ range_convert_str(&global_ports_range, DEFAULT_RADIUS_PORT_RANGE, MAX_UDP_PORT);
|
||||
+ prefs_register_range_preference(radius_module, "ports","RADIUS ports",
|
||||
+ "A list of UDP ports to decode as RADIUS", &global_ports_range, MAX_UDP_PORT);
|
||||
prefs_register_uint_preference(radius_module, "request_ttl", "Request TimeToLive",
|
||||
"Time to live for a radius request used for matching it with a response", 10, &request_ttl);
|
||||
radius_tap = register_tap("radius");
|
||||
@@ -2134,29 +2153,32 @@ proto_reg_handoff_radius(void)
|
||||
{
|
||||
static gboolean initialized = FALSE;
|
||||
static dissector_handle_t radius_handle;
|
||||
- static guint alt_port;
|
||||
+ static range_t *ports_range;
|
||||
|
||||
if (!initialized) {
|
||||
radius_handle = find_dissector("radius");
|
||||
- dissector_add_uint("udp.port", UDP_PORT_RADIUS, radius_handle);
|
||||
- dissector_add_uint("udp.port", UDP_PORT_RADIUS_NEW, radius_handle);
|
||||
- dissector_add_uint("udp.port", UDP_PORT_RADACCT, radius_handle);
|
||||
- dissector_add_uint("udp.port", UDP_PORT_RADACCT_NEW, radius_handle);
|
||||
- dissector_add_uint("udp.port", UDP_PORT_DAE_OLD, radius_handle);
|
||||
- dissector_add_uint("udp.port", UDP_PORT_DAE, radius_handle);
|
||||
-
|
||||
eap_handle = find_dissector("eap");
|
||||
|
||||
initialized = TRUE;
|
||||
} else {
|
||||
- if (alt_port != 0)
|
||||
- dissector_delete_uint("udp.port", alt_port, radius_handle);
|
||||
+ dissector_delete_uint_range("udp.port", ports_range, radius_handle);
|
||||
+ g_free(ports_range);
|
||||
}
|
||||
|
||||
- if (alt_port_pref != 0)
|
||||
- dissector_add_uint("udp.port", alt_port_pref, radius_handle);
|
||||
+ if (alt_port_pref != 0) {
|
||||
+ /* Append it to the range of ports but only if necessary */
|
||||
+ if (!value_is_in_range(global_ports_range, alt_port_pref)) {
|
||||
+ global_ports_range = (range_t*)g_realloc(global_ports_range,
|
||||
+ /* see epan/range.c:range_copy function */
|
||||
+ sizeof (range_t) - sizeof (range_admin_t) + (global_ports_range->nranges + 1) * sizeof (range_admin_t));
|
||||
+ global_ports_range->ranges[global_ports_range->nranges].low = alt_port_pref;
|
||||
+ global_ports_range->ranges[global_ports_range->nranges].high = alt_port_pref;
|
||||
+ global_ports_range->nranges++;
|
||||
+ }
|
||||
+ }
|
||||
|
||||
- alt_port = alt_port_pref;
|
||||
+ ports_range = range_copy(global_ports_range);
|
||||
+ dissector_add_uint_range("udp.port", ports_range, radius_handle);
|
||||
}
|
||||
|
||||
/*
|
26
wireshark-0011-Fix-FTBFS-Qt-Color-utils-arm.patch
Normal file
26
wireshark-0011-Fix-FTBFS-Qt-Color-utils-arm.patch
Normal file
@ -0,0 +1,26 @@
|
||||
diff --git a/ui/qt/color_utils.cpp b/ui/qt/color_utils.cpp
|
||||
index e150a14..4fcbe9d 100644
|
||||
--- a/ui/qt/color_utils.cpp
|
||||
+++ b/ui/qt/color_utils.cpp
|
||||
@@ -99,7 +99,7 @@ const color_t ColorUtils::toColorT(const QColor color)
|
||||
|
||||
QRgb ColorUtils::alphaBlend(const QColor &color1, const QColor &color2, qreal alpha)
|
||||
{
|
||||
- alpha = qBound(0.0, alpha, 1.0);
|
||||
+ alpha = qBound<qreal>(0.0, alpha, 1.0);
|
||||
|
||||
int r1 = color1.red() * alpha;
|
||||
int g1 = color1.green() * alpha;
|
||||
diff --git a/ui/qt/main_window_slots.cpp b/ui/qt/main_window_slots.cpp
|
||||
index 3c9a616..56dd3ea 100644
|
||||
--- a/ui/qt/main_window_slots.cpp
|
||||
+++ b/ui/qt/main_window_slots.cpp
|
||||
@@ -2226,7 +2226,7 @@ void MainWindow::zoomText()
|
||||
mono_font_ = QFont(wsApp->monospaceFont());
|
||||
qreal zoom_size = wsApp->monospaceFont().pointSize() * 2 * qPow(1.1, recent.gui_zoom_level);
|
||||
zoom_size = qRound(zoom_size) / 2.0;
|
||||
- zoom_size = qMax(zoom_size, 1.0);
|
||||
+ zoom_size = qMax<qreal>(zoom_size, 1.0);
|
||||
mono_font_.setPointSizeF(zoom_size);
|
||||
emit monospaceFontChanged(mono_font_);
|
||||
}
|
254
wireshark.spec
254
wireshark.spec
@ -2,30 +2,19 @@
|
||||
|
||||
%global with_adns 0
|
||||
%global with_lua 0
|
||||
%global with_gtk2 0
|
||||
|
||||
%if 0%{?rhel} != 0
|
||||
#RHEL:
|
||||
%global with_portaudio 0
|
||||
%global with_GeoIP 0
|
||||
%if 0%{?rhel} <= 6
|
||||
# RHEL6: use GTK2
|
||||
%global with_gtk2 1
|
||||
%endif
|
||||
%else
|
||||
%global with_portaudio 1
|
||||
%global with_GeoIP 1
|
||||
%endif
|
||||
|
||||
%global with_portaudio 1
|
||||
%global with_GeoIP 1
|
||||
|
||||
Summary: Network traffic analyzer
|
||||
Name: wireshark
|
||||
Version: 1.12.8
|
||||
Release: 2%{?dist}
|
||||
Version: 2.0.1
|
||||
Release: 1%{?dist}
|
||||
License: GPL+
|
||||
Group: Applications/Internet
|
||||
Url: http://www.wireshark.org/
|
||||
Source0: http://wireshark.org/download/src/%{name}-%{version}.tar.bz2
|
||||
Source1: 90-wireshark-usbmon.rules
|
||||
Requires: %{name}-cli = %{version}-%{release}
|
||||
# Fedora-specific
|
||||
Patch1: wireshark-0001-enable-Lua-support.patch
|
||||
# Fedora-specific
|
||||
@ -44,12 +33,15 @@ Patch7: wireshark-0007-Install-autoconf-related-file.patch
|
||||
Patch8: wireshark-0008-move-default-temporary-directory-to-var-tmp.patch
|
||||
# Fedora-specific
|
||||
Patch9: wireshark-0009-Fix-paths-in-a-wireshark.desktop-file.patch
|
||||
# Backported from upstream - https://code.wireshark.org/review/#/c/10015/
|
||||
Patch10: wireshark-0010-Allow-redefining-all-ports-for-RADIUS.patch
|
||||
# Fedora-specific, see https://bugzilla.redhat.com/1274831
|
||||
Patch11: wireshark-0011-Patch-fixing-the-wireshark-autoconf-macros.patch
|
||||
Patch10: wireshark-0010-Patch-fixing-the-wireshark-autoconf-macros.patch
|
||||
# Qt-specific
|
||||
Patch11: wireshark-0011-Fix-FTBFS-Qt-Color-utils-arm.patch
|
||||
|
||||
Url: http://www.wireshark.org/
|
||||
%package cli
|
||||
Summary: Network traffic analyzer
|
||||
Group: Applications/Internet
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
BuildRequires: libpcap-devel >= 0.9
|
||||
BuildRequires: libsmi-devel
|
||||
BuildRequires: zlib-devel, bzip2-devel
|
||||
@ -76,20 +68,10 @@ BuildRequires: adns-devel
|
||||
%else
|
||||
BuildRequires: c-ares-devel
|
||||
%endif
|
||||
%if %{with_portaudio}
|
||||
BuildRequires: portaudio-devel
|
||||
%endif
|
||||
%if %{with_lua}
|
||||
BuildRequires: lua-devel
|
||||
%endif
|
||||
%if %{with_gtk2}
|
||||
BuildRequires: gtk2-devel
|
||||
%else
|
||||
BuildRequires: gtk3-devel
|
||||
%endif
|
||||
|
||||
# Temporary hack - wireshark-1.8.0 is not compilable with upstream
|
||||
# Makefile.in / configure, they need to be regenerated
|
||||
BuildRequires: libtool, automake, autoconf
|
||||
|
||||
Requires(pre): shadow-utils
|
||||
@ -97,23 +79,48 @@ Requires(pre): shadow-utils
|
||||
Requires: adns
|
||||
%endif
|
||||
|
||||
%package gnome
|
||||
Summary: Gnome desktop integration for wireshark
|
||||
%package qt
|
||||
Summary: Wireshark's Qt-based GUI
|
||||
Group: Applications/Internet
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
Requires: %{name}-cli = %{version}-%{release}
|
||||
Requires: xdg-utils
|
||||
Requires: hicolor-icon-theme
|
||||
%if %{with_gtk2}
|
||||
Requires: gtk2
|
||||
%else
|
||||
Requires: gtk3
|
||||
%endif
|
||||
Requires: qt >= 4.7.0
|
||||
BuildRequires: qt-devel >= 4.7.0
|
||||
%if %{with_portaudio}
|
||||
Requires: portaudio
|
||||
BuildRequires: portaudio-devel
|
||||
%endif
|
||||
%if %{with_GeoIP}
|
||||
Requires: GeoIP
|
||||
%endif
|
||||
Requires(post): /usr/sbin/update-alternatives
|
||||
Requires(postun): /usr/sbin/update-alternatives
|
||||
BuildRequires: gcc-c++
|
||||
|
||||
%package gtk
|
||||
Summary: Wireshark's GTK+-based GUI
|
||||
Group: Applications/Internet
|
||||
Requires: %{name}-cli = %{version}-%{release}
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
# This package used to be called wireshark-gnome.
|
||||
Provides: wireshark-gnome = %{version}-%{release}
|
||||
Obsoletes: wireshark-gnome < 2.0.0
|
||||
Requires: gtk3 >= 3.0.0
|
||||
BuildRequires: gtk3-devel > 3.0.0
|
||||
%if %{with_portaudio}
|
||||
Requires: portaudio
|
||||
BuildRequires: portaudio-devel
|
||||
%endif
|
||||
%if %{with_GeoIP}
|
||||
Requires: GeoIP
|
||||
%endif
|
||||
Requires: xdg-utils
|
||||
Requires: hicolor-icon-theme
|
||||
BuildRequires: desktop-file-utils
|
||||
Requires(post): desktop-file-utils
|
||||
Requires(post): /usr/sbin/update-alternatives
|
||||
Requires(postun): /usr/sbin/update-alternatives
|
||||
|
||||
%package devel
|
||||
Summary: Development headers and libraries for wireshark
|
||||
@ -122,15 +129,27 @@ Requires: %{name} = %{version}-%{release} glibc-devel glib2-devel
|
||||
|
||||
|
||||
%description
|
||||
Wireshark is a network traffic analyzer for Unix-ish operating systems.
|
||||
Metapackage with installs %{name}-cli and %{name}-qt.
|
||||
|
||||
This package lays base for libpcap, a packet capture and filtering
|
||||
library, contains command-line utilities, contains plugins and
|
||||
documentation for wireshark. A graphical user interface is packaged
|
||||
separately to GTK+ package.
|
||||
%description cli
|
||||
Wireshark allows you to examine protocol data stored in files or as it is
|
||||
captured from wired or wireless (WiFi or Bluetooth) networks, USB devices,
|
||||
and many other sources. It supports dozens of protocol capture file formats
|
||||
and understands more than a thousand protocols.
|
||||
|
||||
%description gnome
|
||||
Contains wireshark for Gnome 2 and desktop integration file
|
||||
It has many powerful features including a rich display filter language
|
||||
and the ability to reassemble multiple protocol packets in order to, for
|
||||
example, view a complete TCP stream, save the contents of a file which was
|
||||
transferred over HTTP or CIFS, or play back an RTP audio stream.
|
||||
|
||||
This package contains command-line utilities, plugins, and documentation for
|
||||
Wireshark. A Qt graphical user interface is packaged separately.
|
||||
|
||||
%description qt
|
||||
This package contains the Qt Wireshark GUI and desktop integration files.
|
||||
|
||||
%description gtk
|
||||
This package contains the GTK+ Wireshark GUI and desktop integration files.
|
||||
|
||||
%description devel
|
||||
The wireshark-devel package contains the header files, developer
|
||||
@ -149,29 +168,12 @@ and plugins.
|
||||
%patch3 -p1 -b .profinet_crash
|
||||
%patch4 -p1 -b .add_autoconf
|
||||
%patch5 -p1 -b .restore_group
|
||||
|
||||
# Somebody forgot to add this file into tarball (fixed in wireshark-1.12.1)
|
||||
echo "prefix=@CMAKE_INSTALL_PREFIX@
|
||||
exec_prefix=\${prefix}
|
||||
libdir=\${prefix}/@CMAKE_INSTALL_LIBDIR@
|
||||
sharedlibdir=\${libdir}
|
||||
includedir=\${prefix}/include/wireshark
|
||||
plugindir=@PLUGIN_INSTALL_DIR@
|
||||
|
||||
Name: wireshark
|
||||
Description: wireshark network packet dissection library
|
||||
Version: @PROJECT_VERSION@
|
||||
|
||||
Requires:
|
||||
Libs: -L\${libdir} -L\${sharedlibdir} -lwireshark
|
||||
Cflags: -I\${includedir}" > wireshark.pc.in
|
||||
|
||||
%patch6 -p1 -b .add_pkgconfig
|
||||
%patch7 -p1 -b .install_autoconf
|
||||
%patch8 -p1 -b .tmp_dir
|
||||
%patch9 -p1 -b .fix_paths
|
||||
%patch10 -p1 -b .radius_ports
|
||||
%patch11 -p1 -b .64bit
|
||||
%patch10 -p1 -b .64bit
|
||||
%patch11 -p1 -b .ftbfs_arm
|
||||
|
||||
%build
|
||||
%ifarch s390 s390x sparcv9 sparc64
|
||||
@ -193,12 +195,8 @@ autoreconf -ivf
|
||||
--with-libsmi \
|
||||
--with-gnu-ld \
|
||||
--with-pic \
|
||||
%if %{with_gtk2}
|
||||
--with-gtk2 \
|
||||
--with-gtk3=no \
|
||||
%else
|
||||
--with-gtk3=yes \
|
||||
%endif
|
||||
--with-gtk3 \
|
||||
--with-qt \
|
||||
%if %{with_adns}
|
||||
--with-adns \
|
||||
%else
|
||||
@ -222,7 +220,8 @@ autoreconf -ivf
|
||||
--with-ssl \
|
||||
--disable-warnings-as-errors \
|
||||
--with-plugins=%{_libdir}/%{name}/plugins \
|
||||
--with-libnl
|
||||
--with-libnl \
|
||||
--disable-androiddump
|
||||
|
||||
#remove rpath
|
||||
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
|
||||
@ -232,13 +231,13 @@ make %{?_smp_mflags}
|
||||
|
||||
%install
|
||||
make DESTDIR=%{buildroot} install
|
||||
make DESTDIR=%{buildroot} install_desktop_files
|
||||
|
||||
# Install python stuff.
|
||||
mkdir -p %{buildroot}%{python_sitearch}
|
||||
install -m 644 tools/wireshark_be.py tools/wireshark_gen.py %{buildroot}%{python_sitearch}
|
||||
|
||||
desktop-file-validate %{buildroot}%{_datadir}/applications/wireshark.desktop
|
||||
desktop-file-validate %{buildroot}%{_datadir}/applications/wireshark-gtk.desktop
|
||||
|
||||
#install devel files (inspired by debian/wireshark-dev.header-files)
|
||||
install -d -m 0755 %{buildroot}%{_includedir}/wireshark
|
||||
@ -265,6 +264,11 @@ install -m 644 wsutil/*.h "${IDIR}/wsutil"
|
||||
install -m 644 ws_symbol_export.h "${IDIR}/"
|
||||
install -m 644 %{SOURCE1} %{buildroot}/%{_sysconfdir}/udev/rules.d/
|
||||
|
||||
# Change the program name for 'alternatives'
|
||||
mv %{buildroot}%{_sbindir}/wireshark %{buildroot}%{_sbindir}/wireshark-qt
|
||||
|
||||
touch %{buildroot}%{_sbindir}/%{name}
|
||||
|
||||
# Register as an application to be visible in the software center
|
||||
#
|
||||
# NOTE: It would be *awesome* if this file was maintained by the upstream
|
||||
@ -309,25 +313,53 @@ rm -f %{buildroot}%{_libdir}/%{name}/plugins/*.la
|
||||
# Remove .la files in libdir
|
||||
rm -f %{buildroot}%{_libdir}/*.la
|
||||
|
||||
%pre
|
||||
# Remove idl2wrs
|
||||
rm -f %{buildroot}%{_sbindir}/idl2wrs
|
||||
|
||||
%pre cli
|
||||
getent group wireshark >/dev/null || groupadd -r wireshark
|
||||
getent group usbmon >/dev/null || groupadd -r usbmon
|
||||
|
||||
%post
|
||||
# If we have a pre-alternatives wireshark binary out there, get rid of it.
|
||||
# (With 'alternatives' %{_sbindir}/wireshark should be a symlink.)
|
||||
%pre gtk
|
||||
if [ -f %{_sbindir}/wireshark ]; then
|
||||
rm -f %{_sbindir}/wireshark
|
||||
fi
|
||||
|
||||
# If we have a pre-alternatives wireshark binary out there, get rid of it.
|
||||
# (With 'alternatives' %{_sbindir}/wireshark should be a symlink.)
|
||||
%pre qt
|
||||
if [ -f %{_sbindir}/wireshark ]; then
|
||||
rm -f %{_sbindir}/wireshark
|
||||
fi
|
||||
|
||||
%post cli
|
||||
/sbin/ldconfig
|
||||
/usr/bin/udevadm trigger --subsystem-match=usbmon
|
||||
|
||||
%postun -p /sbin/ldconfig
|
||||
|
||||
%post gnome
|
||||
update-desktop-database &> /dev/null ||:
|
||||
%post gtk
|
||||
update-desktop-database %{_datadir}/applications &> /dev/null || :
|
||||
update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
|
||||
touch --no-create %{_datadir}/icons/gnome &>/dev/null || :
|
||||
touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
|
||||
touch --no-create %{_datadir}/mime/packages &> /dev/null || :
|
||||
update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
|
||||
gtk-update-icon-cache -t %{_datadir}/icons/hicolor &>/dev/null || :
|
||||
/usr/sbin/update-alternatives --install %{_sbindir}/wireshark \
|
||||
%{name} %{_sbindir}/wireshark-gtk 10
|
||||
|
||||
%postun gnome
|
||||
%post qt
|
||||
update-desktop-database &> /dev/null ||:
|
||||
touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
|
||||
touch --no-create %{_datadir}/mime/packages &> /dev/null || :
|
||||
update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
|
||||
/usr/sbin/update-alternatives --install %{_sbindir}/wireshark \
|
||||
%{name} %{_sbindir}/wireshark-qt 50
|
||||
|
||||
%postun cli -p /sbin/ldconfig
|
||||
|
||||
%postun gtk
|
||||
update-desktop-database &> /dev/null || :
|
||||
if [ $1 -eq 0 ] ; then
|
||||
touch --no-create %{_datadir}/icons/gnome &>/dev/null
|
||||
gtk-update-icon-cache %{_datadir}/icons/gnome &>/dev/null || :
|
||||
@ -337,14 +369,24 @@ if [ $1 -eq 0 ] ; then
|
||||
|
||||
touch --no-create %{_datadir}/mime/packages &> /dev/null || :
|
||||
update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
|
||||
|
||||
/usr/sbin/update-alternatives --remove %{name} %{_sbindir}/wireshark-gtk
|
||||
fi
|
||||
|
||||
%posttrans
|
||||
%postun qt
|
||||
update-desktop-database &> /dev/null || :
|
||||
if [ $1 -eq 0 ] ; then
|
||||
/usr/sbin/update-alternatives --remove %{name} %{_sbindir}/wireshark-qt
|
||||
fi
|
||||
|
||||
%posttrans cli
|
||||
gtk-update-icon-cache %{_datadir}/icons/gnome &>/dev/null || :
|
||||
gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
|
||||
update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
|
||||
|
||||
%files
|
||||
|
||||
%files cli
|
||||
%doc AUTHORS COPYING ChangeLog INSTALL NEWS README*
|
||||
%{_sbindir}/editcap
|
||||
%{_sbindir}/tshark
|
||||
@ -360,8 +402,9 @@ update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
|
||||
%{_sysconfdir}/udev/rules.d/90-wireshark-usbmon.rules
|
||||
%{python_sitearch}/*.py*
|
||||
%{_libdir}/lib*.so.*
|
||||
%{_libdir}/wireshark
|
||||
%{_libdir}/wireshark/plugins
|
||||
%dir %{_libdir}/wireshark
|
||||
%dir %{_libdir}/wireshark/plugins
|
||||
%{_libdir}/wireshark/plugins/*.so
|
||||
%{_mandir}/man1/editcap.*
|
||||
%{_mandir}/man1/tshark.*
|
||||
%{_mandir}/man1/mergecap.*
|
||||
@ -373,33 +416,33 @@ update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
|
||||
%{_mandir}/man1/dftest.*
|
||||
%{_mandir}/man1/randpkt.*
|
||||
%{_mandir}/man1/reordercap.*
|
||||
%{_datadir}/wireshark
|
||||
%dir %{_datadir}/wireshark
|
||||
%{_datadir}/wireshark/*
|
||||
%if %{with_lua}
|
||||
%exclude %{_datadir}/wireshark/init.lua
|
||||
%endif
|
||||
|
||||
|
||||
%files gnome
|
||||
%files gtk
|
||||
%{_datadir}/appdata/%{name}.appdata.xml
|
||||
%{_datadir}/applications/wireshark.desktop
|
||||
%{_datadir}/icons/hicolor/16x16/apps/wireshark.png
|
||||
%{_datadir}/icons/hicolor/24x24/apps/wireshark.png
|
||||
%{_datadir}/icons/hicolor/32x32/apps/wireshark.png
|
||||
%{_datadir}/icons/hicolor/48x48/apps/wireshark.png
|
||||
%{_datadir}/icons/hicolor/64x64/apps/wireshark.png
|
||||
%{_datadir}/icons/hicolor/128x128/apps/wireshark.png
|
||||
%{_datadir}/icons/hicolor/256x256/apps/wireshark.png
|
||||
%{_datadir}/icons/hicolor/16x16/mimetypes/application-wireshark-doc.png
|
||||
%{_datadir}/icons/hicolor/24x24/mimetypes/application-wireshark-doc.png
|
||||
%{_datadir}/icons/hicolor/32x32/mimetypes/application-wireshark-doc.png
|
||||
%{_datadir}/icons/hicolor/48x48/mimetypes/application-wireshark-doc.png
|
||||
%{_datadir}/icons/hicolor/64x64/mimetypes/application-wireshark-doc.png
|
||||
%{_datadir}/icons/hicolor/128x128/mimetypes/application-wireshark-doc.png
|
||||
%{_datadir}/icons/hicolor/256x256/mimetypes/application-wireshark-doc.png
|
||||
%{_datadir}/applications/wireshark-gtk.desktop
|
||||
%{_datadir}/icons/hicolor/*/apps/*
|
||||
%{_datadir}/icons/hicolor/*/mimetypes/*
|
||||
%{_datadir}/icons/hicolor/scalable/apps/wireshark.svg
|
||||
%{_datadir}/mime/packages/wireshark.xml
|
||||
%{_sbindir}/wireshark
|
||||
%{_sbindir}/wireshark-gtk
|
||||
%{_mandir}/man1/wireshark.*
|
||||
%ghost %{_sbindir}/wireshark
|
||||
|
||||
%files qt
|
||||
%{_datadir}/appdata/%{name}.appdata.xml
|
||||
%{_datadir}/applications/wireshark.desktop
|
||||
%{_datadir}/icons/hicolor/*/apps/*
|
||||
%{_datadir}/icons/hicolor/*/mimetypes/*
|
||||
%{_datadir}/icons/hicolor/scalable/apps/wireshark.svg
|
||||
%{_datadir}/mime/packages/wireshark.xml
|
||||
%{_sbindir}/wireshark-qt
|
||||
%{_mandir}/man1/wireshark.*
|
||||
%ghost %{_sbindir}/wireshark
|
||||
|
||||
%files devel
|
||||
%doc doc/README.*
|
||||
@ -412,6 +455,11 @@ update-mime-database %{?fedora:-n} %{_datadir}/mime &> /dev/null || :
|
||||
%{_datadir}/aclocal/*
|
||||
|
||||
%changelog
|
||||
* Thu Jan 14 2016 Peter Hatina <phatina@redhat.com> - 2.0.1-1
|
||||
- Ver. 2.0.1
|
||||
- Introduced wireshark metapackage for wireshark-cli and wireshark-gtk
|
||||
- wireshark-qt and wireshark-gtk contain the GUI applications
|
||||
|
||||
* Tue Nov 3 2015 Peter Lemenkov <lemenkov@gmail.com> - 1.12.8-2
|
||||
- Fixed Wireshark detection in external projects using wireshark.m4 script.
|
||||
See https://bugzilla.redhat.com/1274831 for further details.
|
||||
|
Loading…
Reference in New Issue
Block a user