summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcelo Góes <vanquirius@gentoo.org>2006-05-27 21:44:28 +0000
committerMarcelo Góes <vanquirius@gentoo.org>2006-05-27 21:44:28 +0000
commit2f02a3fe3f68a12b22bc1883245609a29423eefd (patch)
tree5f8437e02bcb39769bec93a891a88f6c19642505 /net-analyzer/ethereal
parentStable on alpha. (diff)
downloadgentoo-2-2f02a3fe3f68a12b22bc1883245609a29423eefd.tar.gz
gentoo-2-2f02a3fe3f68a12b22bc1883245609a29423eefd.tar.bz2
gentoo-2-2f02a3fe3f68a12b22bc1883245609a29423eefd.zip
Add ringbuffer patch from upstream's svn. Fixes bug 134193. Thanks to Randy B <aoz.syn at gmail dot com>.
(Portage version: 2.0.54)
Diffstat (limited to 'net-analyzer/ethereal')
-rw-r--r--net-analyzer/ethereal/ChangeLog9
-rw-r--r--net-analyzer/ethereal/Manifest25
-rw-r--r--net-analyzer/ethereal/ethereal-0.99.0-r1.ebuild133
-rw-r--r--net-analyzer/ethereal/files/digest-ethereal-0.99.0-r11
-rw-r--r--net-analyzer/ethereal/files/ethereal-0.99.0-ringbuffer.patch121
5 files changed, 266 insertions, 23 deletions
diff --git a/net-analyzer/ethereal/ChangeLog b/net-analyzer/ethereal/ChangeLog
index 3f4ff88d4f99..11ef66c92500 100644
--- a/net-analyzer/ethereal/ChangeLog
+++ b/net-analyzer/ethereal/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for net-analyzer/ethereal
# Copyright 2002-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-analyzer/ethereal/ChangeLog,v 1.179 2006/04/26 19:05:50 squinky86 Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/ethereal/ChangeLog,v 1.180 2006/05/27 21:44:28 vanquirius Exp $
+
+*ethereal-0.99.0-r1 (27 May 2006)
+
+ 27 May 2006; Marcelo Goes <vanquirius@gentoo.org>
+ +files/ethereal-0.99.0-ringbuffer.patch, +ethereal-0.99.0-r1.ebuild:
+ Add ringbuffer patch from upstream's svn. Fixes bug 134193. Thanks to Randy
+ B <aoz.syn at gmail dot com>.
26 Apr 2006; Jon Hood <squinky86@gentoo.org> ethereal-0.99.0.ebuild:
Stable on amd64, #130505.
diff --git a/net-analyzer/ethereal/Manifest b/net-analyzer/ethereal/Manifest
index 2262d24500cf..9409ffc74d4d 100644
--- a/net-analyzer/ethereal/Manifest
+++ b/net-analyzer/ethereal/Manifest
@@ -1,33 +1,14 @@
MD5 300cc3fc8d0468549538436e86e49111 ChangeLog 16979
-RMD160 81875a0b65cec41c890442fe33510325042241ab ChangeLog 16979
-SHA256 5c5d8536b68dfd3237dc0ba07ff436c12c7429b3c08ea770deac9f555e75eec5 ChangeLog 16979
MD5 37e925f02777b6168f6aad1db53116ec ethereal-0.10.14-r1.ebuild 3814
-RMD160 d98d22045ff4b6bfe509923cf292df1a952d8eeb ethereal-0.10.14-r1.ebuild 3814
-SHA256 61feaf092e58a06c8699711a9662b3def73295e2e36c3225b86d9eda6769552a ethereal-0.10.14-r1.ebuild 3814
MD5 eeb4a9b83362b84c0348c0d07a199818 ethereal-0.10.14.ebuild 3576
-RMD160 ecf41482a4ff4829e952e1c4ae60c2552e677254 ethereal-0.10.14.ebuild 3576
-SHA256 209920ddc054e769197ab637b4b2b163e1bed9dc1b206cfd12f786a07801e275 ethereal-0.10.14.ebuild 3576
+MD5 28b5365ca36999626ff38902b3f31e71 ethereal-0.99.0-r1.ebuild 4032
MD5 cab9bc5c5ad755308755b0b4768903e6 ethereal-0.99.0.ebuild 3951
-RMD160 a2d0a1f6710a22bc3f687551eb819cbfb4920471 ethereal-0.99.0.ebuild 3951
-SHA256 a5f09f69eaa48664c37b0891d4d45487be2fb9313351a12bd98e253ccf37a4fe ethereal-0.99.0.ebuild 3951
MD5 69227b87384c88f096f371b52f9dac4d files/digest-ethereal-0.10.14 256
-RMD160 6e3cd361f5ed6da23247588730796d99d13d53bb files/digest-ethereal-0.10.14 256
-SHA256 b87f7f32aa677e6b5a5a45cf6f61b9b4728b74d0f7908495fd55974e38d01b96 files/digest-ethereal-0.10.14 256
MD5 69227b87384c88f096f371b52f9dac4d files/digest-ethereal-0.10.14-r1 256
-RMD160 6e3cd361f5ed6da23247588730796d99d13d53bb files/digest-ethereal-0.10.14-r1 256
-SHA256 b87f7f32aa677e6b5a5a45cf6f61b9b4728b74d0f7908495fd55974e38d01b96 files/digest-ethereal-0.10.14-r1 256
MD5 c6839261e43bcc0927402c529a6e23cf files/digest-ethereal-0.99.0 253
-RMD160 24f9dbe348849fa1cd1b1c7cd98a04b846a214cf files/digest-ethereal-0.99.0 253
-SHA256 9a280483030d81621ca6b38e6d82686f8b926dc5861de6e143f8c034433ad81a files/digest-ethereal-0.99.0 253
+MD5 dec12a734c165e9eb5635cd9c868d303 files/digest-ethereal-0.99.0-r1 69
MD5 9423b7a0f04e4e124835eacfe33c8d48 files/ethereal-0.10.14-asneeded.patch 847
-RMD160 83896f31fb4b84940f17cb48a70073e849968543 files/ethereal-0.10.14-asneeded.patch 847
-SHA256 2815e1f321400e74c01953a72b330e6080a5b65a5360d594ceeb8b1a7d2e7c03 files/ethereal-0.10.14-asneeded.patch 847
MD5 99292dc5864a5d38a12bf357dab75e6f files/ethereal-0.10.14-capture_loop.patch 1985
-RMD160 5d435678e4bf265899b9e95654c049ecc3d33435 files/ethereal-0.10.14-capture_loop.patch 1985
-SHA256 68b2a0997e2224fc0a26f7dcbc440e4b0b1574c845716072d554cdc422f55126 files/ethereal-0.10.14-capture_loop.patch 1985
MD5 73f8c14539d2443f77ef38a60454afa1 files/ethereal-0.99.0-as-needed.patch 921
-RMD160 6967cbb5ce3da80ac35f657140942235d453a5e9 files/ethereal-0.99.0-as-needed.patch 921
-SHA256 ad30c8dc12fa4c2b425a7d4b883c4414aad6eefc0dceacbb020046b8944b7d21 files/ethereal-0.99.0-as-needed.patch 921
+MD5 4b9e0c28bf3d8bf7f9d616f10ef86044 files/ethereal-0.99.0-ringbuffer.patch 5456
MD5 94e03a4ff2917efc81b0e0f07040afde metadata.xml 241
-RMD160 e54fec44f06e7d8c93e399d9bd98e56f231920be metadata.xml 241
-SHA256 684412188c16efe278e263e010f4bf09d33f17f2762d4829516e3e3a47ab3c02 metadata.xml 241
diff --git a/net-analyzer/ethereal/ethereal-0.99.0-r1.ebuild b/net-analyzer/ethereal/ethereal-0.99.0-r1.ebuild
new file mode 100644
index 000000000000..1dfe588bb252
--- /dev/null
+++ b/net-analyzer/ethereal/ethereal-0.99.0-r1.ebuild
@@ -0,0 +1,133 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-analyzer/ethereal/ethereal-0.99.0-r1.ebuild,v 1.1 2006/05/27 21:44:28 vanquirius Exp $
+
+inherit libtool flag-o-matic eutils autotools libtool
+
+DESCRIPTION="A commercial-quality network protocol analyzer"
+HOMEPAGE="http://www.ethereal.com/"
+SRC_URI="mirror://ethereal/${P}.tar.bz2
+ mirror://sourceforge/ethereal/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~ia64 ~ppc ~ppc64 ~sparc ~x86"
+IUSE="adns gtk ipv6 snmp ssl kerberos threads"
+
+RDEPEND=">=sys-libs/zlib-1.1.4
+ snmp? ( >=net-analyzer/net-snmp-5.1.1 )
+ >=dev-util/pkgconfig-0.15.0
+ gtk? ( >=dev-libs/glib-2.0.4
+ =x11-libs/gtk+-2*
+ x11-libs/pango
+ dev-libs/atk )
+ !gtk? ( =dev-libs/glib-1.2* )
+ ssl? ( >=dev-libs/openssl-0.9.6e )
+ !ssl? ( net-libs/gnutls )
+ net-libs/libpcap
+ >=dev-libs/libpcre-4.2
+ adns? ( net-libs/adns )
+ kerberos? ( virtual/krb5 )"
+# lua fails with version 5.0 and 5.1 not in portage yet - 2006-04-25
+# lua? ( dev-lang/lua )"
+
+DEPEND="${RDEPEND}
+ dev-lang/perl
+ sys-devel/bison
+ sys-devel/flex
+ sys-apps/sed"
+
+pkg_setup() {
+ # bug 119208
+ if built_with_use dev-lang/perl minimal ; then
+ ewarn "ethereal will not build if dev-lang/perl is compiled with"
+ ewarn "USE=minimal. Rebuild dev-lang/perl with USE=-minimal and try again."
+ ebeep 5
+ die "dev-lang/perl compiled with USE=minimal"
+ fi
+}
+
+src_unpack() {
+ unpack ${A}
+ # bug 117716
+ epatch "${FILESDIR}/${P}-as-needed.patch"
+ cd "${S}"
+ AT_M4DIR="${S}/aclocal-fallback" eautomake
+ elibtoolize
+
+ # bug 134193 - from upstream's svn
+ epatch "${FILESDIR}"/${P}-ringbuffer.patch
+}
+
+src_compile() {
+
+ replace-flags -O? -O
+
+ # Fix gcc-3.4 segfault #49238
+ #[ "`gcc-version`" == "3.4" ] && append-flags -fno-unroll-loops
+
+ local myconf
+
+ if use gtk; then
+ einfo "Building with gtk support"
+ else
+ einfo "Building without gtk support"
+ myconf="${myconf} --disable-ethereal"
+ # the asn1 plugin needs gtk
+ sed -i -e '/plugins.asn1/d' Makefile.in || die "sed failed"
+ sed -i -e '/^SUBDIRS/s/asn1//' plugins/Makefile.in || die "sed failed"
+ fi
+
+ # $(use_with lua) \
+ econf \
+ $(use_with ssl) \
+ $(use_enable ipv6) \
+ $(use_with adns) \
+ $(use_with kerberos krb5) \
+ $(use_with snmp net-snmp) \
+ $(use_enable gtk gtk2) \
+ $(use_enable threads) \
+ --without-ucd-snmp \
+ --enable-dftest \
+ --enable-randpkt \
+ --sysconfdir=/etc/ethereal \
+ --enable-editcap \
+ --enable-capinfos \
+ --enable-text2pcap \
+ --enable-dftest \
+ --enable-randpkt \
+ ${myconf} || die "bad ./configure"
+
+ # fixes an access violation caused by libnetsnmp - see bug 79068
+ use snmp && export MIBDIRS="${D}/usr/share/snmp/mibs"
+
+ emake || die "compile problem"
+}
+
+src_install() {
+ dodir /usr/lib/ethereal/plugins/${PV}
+ make DESTDIR="${D}" install || die
+
+ dodoc AUTHORS ChangeLog NEWS README*
+
+ insinto /usr/share/icons/hicolor/16x16/apps
+ newins "${S}"/image/hi16-app-ethereal.png ethereal.png
+ insinto /usr/share/icons/hicolor/32x32/apps
+ newins "${S}"/image/hi32-app-ethereal.png ethereal.png
+ insinto /usr/share/icons/hicolor/48x48/apps
+ newins "${S}"/image/hi48-app-ethereal.png ethereal.png
+ make_desktop_entry ethereal "Ethereal" ethereal
+}
+
+pkg_postinst() {
+ ewarn "Due to a history of security flaws in this piece of software, it may contain more flaws."
+ ewarn "To protect yourself against malicious damage due to potential flaws in this product we recommend"
+ ewarn "you take the following security precautions when running ethereal in an untrusted environment:"
+ ewarn "do no run any longer than you need to;"
+ ewarn "use in a root jail - prefereably one that has been hardened with grsec like rootjail protections;"
+ ewarn "use a hardened operating system;"
+ ewarn "do not listen to addition interfaces;"
+ ewarn "if possible, run behind a firewall;"
+ ewarn "take a capture with tcpdump and analyze running ethereal as a least privileged user;"
+ ewarn "and subscribe to ethereal's announce list to be notified of newly discovered vulnerabilities."
+}
diff --git a/net-analyzer/ethereal/files/digest-ethereal-0.99.0-r1 b/net-analyzer/ethereal/files/digest-ethereal-0.99.0-r1
new file mode 100644
index 000000000000..aa938fced1bb
--- /dev/null
+++ b/net-analyzer/ethereal/files/digest-ethereal-0.99.0-r1
@@ -0,0 +1 @@
+MD5 f9905b9d347acdc05af664a7553f7f76 ethereal-0.99.0.tar.bz2 8884587
diff --git a/net-analyzer/ethereal/files/ethereal-0.99.0-ringbuffer.patch b/net-analyzer/ethereal/files/ethereal-0.99.0-ringbuffer.patch
new file mode 100644
index 000000000000..3f5e74c76694
--- /dev/null
+++ b/net-analyzer/ethereal/files/ethereal-0.99.0-ringbuffer.patch
@@ -0,0 +1,121 @@
+diff --exclude='*~' -Naur ethereal-0.99.0.orig/capture_loop.c ethereal-0.99.0/capture_loop.c
+--- ethereal-0.99.0.orig/capture_loop.c 2006-05-27 18:18:33.000000000 -0300
++++ ethereal-0.99.0/capture_loop.c 2006-05-27 18:19:08.000000000 -0300
+@@ -744,7 +744,8 @@
+
+ /* Set up to write to the capture file. */
+ if (capture_opts->multi_files_on) {
+- ld->pdh = ringbuf_init_libpcap_fdopen(ld->linktype, file_snaplen, &err);
++ ld->pdh = ringbuf_init_libpcap_fdopen(ld->linktype, file_snaplen,
++ &ld->bytes_written, &err);
+ } else {
+ ld->pdh = libpcap_fdopen(save_file_fd, ld->linktype, file_snaplen,
+ &ld->bytes_written, &err);
+@@ -1233,7 +1234,7 @@
+
+ /* Switch to the next ringbuffer file */
+ if (ringbuf_switch_file(&ld.pdh, &capture_opts->save_file,
+- &save_file_fd, &ld.err)) {
++ &save_file_fd, &ld.bytes_written, &ld.err)) {
+ /* File switch succeeded: reset the conditions */
+ cnd_reset(cnd_autostop_size);
+ if (cnd_file_duration) {
+@@ -1303,7 +1304,8 @@
+ }
+
+ /* Switch to the next ringbuffer file */
+- if (ringbuf_switch_file(&ld.pdh, &capture_opts->save_file, &save_file_fd, &ld.err)) {
++ if (ringbuf_switch_file(&ld.pdh, &capture_opts->save_file,
++ &save_file_fd, &ld.bytes_written, &ld.err)) {
+ /* file switch succeeded: reset the conditions */
+ cnd_reset(cnd_file_duration);
+ if(cnd_autostop_size)
+diff --exclude='*~' -Naur ethereal-0.99.0.orig/ringbuffer.c ethereal-0.99.0/ringbuffer.c
+--- ethereal-0.99.0.orig/ringbuffer.c 2006-05-27 18:18:33.000000000 -0300
++++ ethereal-0.99.0/ringbuffer.c 2006-05-27 18:19:15.000000000 -0300
+@@ -88,7 +88,6 @@
+
+ int fd; /* Current ringbuffer file descriptor */
+ FILE *pdh;
+- long bytes_written; /* Bytes written to the current file */
+ } ringbuf_data;
+
+ static ringbuf_data rb_data;
+@@ -231,14 +230,15 @@
+ * Calls libpcap_fdopen() for the current ringbuffer file
+ */
+ FILE *
+-ringbuf_init_libpcap_fdopen(int linktype, int snaplen, int *err)
++ringbuf_init_libpcap_fdopen(int linktype, int snaplen,
++ long *bytes_written, int *err)
+ {
+
+ rb_data.linktype = linktype;
+ rb_data.snaplen = snaplen;
+
+- rb_data.pdh = libpcap_fdopen(rb_data.fd, linktype, snaplen,
+- &rb_data.bytes_written, err);
++ rb_data.pdh = libpcap_fdopen(rb_data.fd, linktype, snaplen, bytes_written,
++ err);
+ return rb_data.pdh;
+ }
+
+@@ -246,7 +246,8 @@
+ * Switches to the next ringbuffer file
+ */
+ gboolean
+-ringbuf_switch_file(FILE **pdh, gchar **save_file, int *save_file_fd, int *err)
++ringbuf_switch_file(FILE **pdh, gchar **save_file, int *save_file_fd,
++ long *bytes_written, int *err)
+ {
+ int next_file_num;
+ rb_file *next_rfile = NULL;
+@@ -274,7 +275,7 @@
+ }
+
+ if (ringbuf_init_libpcap_fdopen(rb_data.linktype, rb_data.snaplen,
+- err) == NULL) {
++ bytes_written, err) == NULL) {
+ return FALSE;
+ }
+
+diff --exclude='*~' -Naur ethereal-0.99.0.orig/ringbuffer.h ethereal-0.99.0/ringbuffer.h
+--- ethereal-0.99.0.orig/ringbuffer.h 2006-05-27 18:18:33.000000000 -0300
++++ ethereal-0.99.0/ringbuffer.h 2006-05-27 18:19:16.000000000 -0300
+@@ -40,8 +40,10 @@
+
+ int ringbuf_init(const char *capture_name, guint num_files);
+ const gchar *ringbuf_current_filename(void);
+-FILE *ringbuf_init_libpcap_fdopen(int linktype, int snaplen, int *err);
+-gboolean ringbuf_switch_file(FILE **pdh, gchar **save_file, int *save_file_fd, int *err);
++FILE *ringbuf_init_libpcap_fdopen(int linktype, int snaplen,
++ long *bytes_written, int *err);
++gboolean ringbuf_switch_file(FILE **pdh, gchar **save_file, int *save_file_fd,
++ long *bytes_written, int *err);
+ gboolean ringbuf_libpcap_dump_close(gchar **save_file, int *err);
+ void ringbuf_free(void);
+ void ringbuf_error_cleanup(void);
+diff --exclude='*~' -Naur ethereal-0.99.0.orig/tethereal.c ethereal-0.99.0/tethereal.c
+--- ethereal-0.99.0.orig/tethereal.c 2006-05-27 18:18:33.000000000 -0300
++++ ethereal-0.99.0/tethereal.c 2006-05-27 18:19:21.000000000 -0300
+@@ -1716,7 +1716,9 @@
+ its maximum size. */
+ if (capture_opts.multi_files_on) {
+ /* Switch to the next ringbuffer file */
+- if (ringbuf_switch_file(&ld.pdh, &capture_opts.save_file, &save_file_fd, &loop_err)) {
++ if (ringbuf_switch_file(&ld.pdh, &capture_opts.save_file,
++ &save_file_fd, &ld.bytes_written,
++ &loop_err)) {
+ /* File switch succeeded: reset the condition */
+ cnd_reset(cnd_autostop_size);
+ if (cnd_file_duration) {
+@@ -1889,7 +1891,8 @@
+ */
+ if (cnd_file_duration != NULL && cnd_eval(cnd_file_duration)) {
+ /* time elapsed for this ring file, switch to the next */
+- if (ringbuf_switch_file(&ld->pdh, &ld->save_file, &save_file_fd, &loop_err)) {
++ if (ringbuf_switch_file(&ld->pdh, &ld->save_file, &save_file_fd,
++ &ld->bytes_written, &loop_err)) {
+ /* File switch succeeded: reset the condition */
+ cnd_reset(cnd_file_duration);
+ } else {