driftnet is a clone of EtherPEG. It sniffs the network for images and
displays them. Fun to use at conferences and airports with open WLAN. Use at own risk. With help and OK jasper@
This commit is contained in:
parent
4723f05ae4
commit
f6fce1ddfc
31
x11/driftnet/Makefile
Normal file
31
x11/driftnet/Makefile
Normal file
@ -0,0 +1,31 @@
|
||||
# $OpenBSD: Makefile,v 1.1.1.1 2007/04/30 13:38:50 claudio Exp $
|
||||
|
||||
COMMENT= "network sniffer that grabs and displays images"
|
||||
|
||||
DISTNAME= driftnet-0.1.6
|
||||
CATEGORIES= x11
|
||||
|
||||
HOMEPAGE= http://www.ex-parrot.com/~chris/driftnet/
|
||||
|
||||
MAINTAINER= Claudio Jeker <claudio@openbsd.org>
|
||||
|
||||
# GPL
|
||||
PERMIT_PACKAGE_CDROM= Yes
|
||||
PERMIT_PACKAGE_FTP= Yes
|
||||
PERMIT_DISTFILES_CDROM= Yes
|
||||
PERMIT_DISTFILES_FTP= Yes
|
||||
WANTLIB= X11 Xext Xi c glib gmodule m pcap pthread
|
||||
|
||||
MASTER_SITES= http://www.ex-parrot.com/~chris/driftnet/
|
||||
|
||||
MODULES= devel/gettext
|
||||
|
||||
LIB_DEPENDS= gtk.>=1,gdk.>=1::x11/gtk+ \
|
||||
ungif.>=5::graphics/libungif \
|
||||
jpeg.>=62::graphics/jpeg
|
||||
|
||||
USE_X11= Yes
|
||||
|
||||
NO_REGRESS= Yes
|
||||
|
||||
.include <bsd.port.mk>
|
5
x11/driftnet/distinfo
Normal file
5
x11/driftnet/distinfo
Normal file
@ -0,0 +1,5 @@
|
||||
MD5 (driftnet-0.1.6.tar.gz) = jhHXd3BFL5e7PCP1EEiYFQ==
|
||||
RMD160 (driftnet-0.1.6.tar.gz) = AQV/PLmS+qU3qLGI4RbG8hAWz6w=
|
||||
SHA1 (driftnet-0.1.6.tar.gz) = J5yzpZbzVOfpxqw8xFaz0R3O0v8=
|
||||
SHA256 (driftnet-0.1.6.tar.gz) = 299+rTrhSxCfiMht7et1JL6MJXqnc6eBiRIW8BM3PW0=
|
||||
SIZE (driftnet-0.1.6.tar.gz) = 36989
|
76
x11/driftnet/patches/patch-Makefile
Normal file
76
x11/driftnet/patches/patch-Makefile
Normal file
@ -0,0 +1,76 @@
|
||||
$OpenBSD: patch-Makefile,v 1.1.1.1 2007/04/30 13:38:50 claudio Exp $
|
||||
--- Makefile.orig Tue Jul 9 21:26:41 2002
|
||||
+++ Makefile Tue Apr 24 15:05:24 2007
|
||||
@@ -16,18 +16,18 @@
|
||||
#CC = gcc
|
||||
|
||||
# Basic compiler, linker flags; should not need any changes.
|
||||
-CFLAGS += -g -Wall
|
||||
-LDFLAGS += -g
|
||||
+#CFLAGS += -g -Wall
|
||||
+#LDFLAGS += -g
|
||||
|
||||
# You might need these if libpcap is installed somewhere random.
|
||||
-CFLAGS += -I/usr/include/pcap
|
||||
+CFLAGS += -I/usr/local/include
|
||||
#LDFLAGS += -L/path/to/libpcap.so
|
||||
|
||||
# Required on Linux to get BSDish definitions of the TCP/IP structs.
|
||||
-CFLAGS += -D_BSD_SOURCE
|
||||
+#CFLAGS += -D_BSD_SOURCE
|
||||
|
||||
# We always need the pcap and pthread libraries.
|
||||
-LDLIBS += -lpcap -lpthread
|
||||
+LDLIBS += -lpcap -pthread
|
||||
|
||||
# Optional C compiler and linker flags. Typical driftnet builds have support
|
||||
# for displaying captured images in an X window, and need the following flags:
|
||||
@@ -72,7 +72,7 @@ BINS = driftnet
|
||||
|
||||
OBJS = $(SRCS:.c=.o)
|
||||
|
||||
-default: driftnet driftnet.1
|
||||
+all: driftnet driftnet.1
|
||||
|
||||
driftnet: depend $(OBJS)
|
||||
$(CC) -o driftnet $(OBJS) $(LDFLAGS) $(LDLIBS)
|
||||
@@ -80,15 +80,9 @@ driftnet: depend $(OBJS)
|
||||
driftnet.1: driftnet.1.in Makefile
|
||||
( echo '.\" DO NOT EDIT THIS FILE-- edit driftnet.1.in instead' ; sed s/@@@VERSION@@@/$(VERSION)/ ) < driftnet.1.in > driftnet.1
|
||||
|
||||
-endianness: endian
|
||||
- ./endian > endianness
|
||||
+%.o: %.c Makefile
|
||||
+ $(CC) $(CFLAGS) -c -o $@ $<
|
||||
|
||||
-endian: endian.c
|
||||
- $(CC) $(CFLAGS) -o endian endian.c
|
||||
-
|
||||
-%.o: %.c Makefile endianness
|
||||
- $(CC) $(CFLAGS) `cat endianness` -c -o $@ $<
|
||||
-
|
||||
clean: nodepend
|
||||
rm -f *~ *.bak *.o core $(BINS) TAGS driftnet.1 endian endianness
|
||||
|
||||
@@ -102,13 +96,19 @@ tarball: nodepend $(SRCS) $(HDRS) $(TXTS)
|
||||
rm -rf driftnet-$(VERSION)
|
||||
mv driftnet-$(VERSION).tar.gz ..
|
||||
|
||||
-depend: endianness
|
||||
- makedepend -- $(CFLAGS) `cat endianness` -- $(SRCS)
|
||||
+depend:
|
||||
+ makedepend -- $(CFLAGS) -- $(SRCS)
|
||||
touch depend
|
||||
rm -f Makefile.bak
|
||||
|
||||
nodepend:
|
||||
makedepend -- --
|
||||
rm -f depend Makefile.bak
|
||||
+
|
||||
+install:
|
||||
+ ${INSTALL} ${INSTALL_COPY} ${INSTALL_STRIP} -o ${BINOWN} -g ${BINGRP} \
|
||||
+ -m ${BINMODE} driftnet ${PREFIX}/bin/driftnet
|
||||
+ ${INSTALL} ${INSTALL_COPY} -o ${MANOWN} -g ${MANGRP} -m ${MANMODE} \
|
||||
+ driftnet.1 ${PREFIX}/man/man1/driftnet.1
|
||||
|
||||
# DO NOT DELETE
|
29
x11/driftnet/patches/patch-img_h
Normal file
29
x11/driftnet/patches/patch-img_h
Normal file
@ -0,0 +1,29 @@
|
||||
$OpenBSD: patch-img_h,v 1.1.1.1 2007/04/30 13:38:50 claudio Exp $
|
||||
--- img.h.orig Tue Apr 24 14:45:52 2007
|
||||
+++ img.h Tue Apr 24 14:47:02 2007
|
||||
@@ -20,13 +20,15 @@
|
||||
# include <stdint.h> /* C99 standard */
|
||||
#endif
|
||||
|
||||
+#include <sys/endian.h>
|
||||
+
|
||||
#include <stdio.h>
|
||||
|
||||
typedef uint8_t chan;
|
||||
typedef uint32_t pel;
|
||||
|
||||
/* Yuk. GDKRGB expects data in a specific ordering. */
|
||||
-#if defined(DRIFTNET_LITTLE_ENDIAN)
|
||||
+#if defined(_LITTLE_ENDIAN)
|
||||
# define PEL(r, g, b) ((pel)((chan)(r) | ((chan)(g) << 8) | ((chan)(b) << 16)))
|
||||
# define PELA(r, g, b, a) ((pel)((chan)(r) | ((chan)(g) << 8) | ((chan)(b) << 16) | ((chan)(a) << 24)))
|
||||
|
||||
@@ -34,7 +36,7 @@ typedef uint32_t pel;
|
||||
# define GETG(p) ((chan)(((p) & (pel)0x0000ff00) >> 8))
|
||||
# define GETB(p) ((chan)(((p) & (pel)0x00ff0000) >> 16))
|
||||
# define GETA(p) ((chan)(((p) & (pel)0xff000000) >> 24))
|
||||
-#elif defined(DRIFTNET_BIG_ENDIAN)
|
||||
+#elif defined(_BIG_ENDIAN)
|
||||
# define PEL(r, g, b) ((pel)(((chan)(r) << 24) | ((chan)(g) << 16) | ((chan)(b) << 8)))
|
||||
# define PELA(r, g, b, a) ((pel)(((chan)(r) << 24) | ((chan)(g) << 16) | ((chan)(b) << 8) | ((chan)(a))))
|
||||
|
3
x11/driftnet/pkg/DESCR
Normal file
3
x11/driftnet/pkg/DESCR
Normal file
@ -0,0 +1,3 @@
|
||||
Driftnet watches network traffic, and picks out and displays JPEG and
|
||||
GIF images for display. It can also extract MPEG audio data from the
|
||||
network and play it with an external helper app. Use at own risk.
|
3
x11/driftnet/pkg/PLIST
Normal file
3
x11/driftnet/pkg/PLIST
Normal file
@ -0,0 +1,3 @@
|
||||
@comment $OpenBSD: PLIST,v 1.1.1.1 2007/04/30 13:38:50 claudio Exp $
|
||||
bin/driftnet
|
||||
@man man/man1/driftnet.1
|
Loading…
Reference in New Issue
Block a user