aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--dns/dnshijacker/Makefile7
-rw-r--r--dns/dnshijacker/files/patch-dnshijacker.c11
2 files changed, 17 insertions, 1 deletions
diff --git a/dns/dnshijacker/Makefile b/dns/dnshijacker/Makefile
index 94a627cf4670..25b066a0c254 100644
--- a/dns/dnshijacker/Makefile
+++ b/dns/dnshijacker/Makefile
@@ -7,7 +7,7 @@
PORTNAME= dnshijacker
PORTVERSION= 1.3
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= dns security
MASTER_SITES= http://pedram.redhive.com/downloads/
@@ -19,7 +19,10 @@ BUILD_DEPENDS= ${LOCALBASE}/lib/libnet.a:${PORTSDIR}/net/libnet
LDFLAGS+= -lpcap -lnet
PLIST_FILES= bin/dnshijacker
+
+.if !defined(NOPORTDOCS)
PORTDOCS= README
+.endif
do-build:
cd ${WRKSRC} && \
@@ -29,7 +32,9 @@ do-build:
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/dnshijacker ${PREFIX}/bin
+.if !defined(NOPORTDOCS)
${MKDIR} ${DOCSDIR}
${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}
+.endif
.include <bsd.port.mk>
diff --git a/dns/dnshijacker/files/patch-dnshijacker.c b/dns/dnshijacker/files/patch-dnshijacker.c
new file mode 100644
index 000000000000..a88cf7369e9c
--- /dev/null
+++ b/dns/dnshijacker/files/patch-dnshijacker.c
@@ -0,0 +1,11 @@
+--- dnshijacker.c.orig Thu Apr 21 00:40:59 2005
++++ dnshijacker.c Thu Apr 21 00:41:29 2005
+@@ -733,7 +733,7 @@
+ * source and destination are swapped here because we are spoofing a reply
+ */
+
+- libnet_build_ip(LIBNET_UDP_H + LIBNET_DNS_H,
++ libnet_build_ip(packet_size - LIBNET_IP_H,
+ 0, /* ip tos */
+ 0, /* ip id */
+ 0, /* fragmentation bits */