View | Details | Raw Unified | Return to bug 202952
Collapse All | Expand All

(-)net-mgmt/aircrack-ng/Makefile (-10 / +7 lines)
Lines 3-8 Link Here
3
3
4
PORTNAME=	aircrack-ng
4
PORTNAME=	aircrack-ng
5
DISTVERSION=	1.2-rc1
5
DISTVERSION=	1.2-rc1
6
PORTREVISION=	1
6
CATEGORIES=	net-mgmt security
7
CATEGORIES=	net-mgmt security
7
MASTER_SITES=	http://download.aircrack-ng.org/ \
8
MASTER_SITES=	http://download.aircrack-ng.org/ \
8
		http://bsd-geek.de/FreeBSD/distfiles/
9
		http://bsd-geek.de/FreeBSD/distfiles/
Lines 13-25 Link Here
13
LICENSE=	GPLv2 BSD3CLAUSE APACHE20
14
LICENSE=	GPLv2 BSD3CLAUSE APACHE20
14
LICENSE_COMB=	dual
15
LICENSE_COMB=	dual
15
16
16
USES=		cpe gmake dos2unix
17
USES=		cpe dos2unix gmake
17
CPE_VERSION=	${DISTVERSION:C/-.*//}
18
CPE_VERSION=	${DISTVERSION:C/-.*//}
18
CPE_UPDATE=	${DISTVERSION:C/^[^-]*$//:C/.*-//}
19
CPE_UPDATE=	${DISTVERSION:C/^[^-]*$//:C/.*-//}
19
DOS2UNIX_FILES=	src/osdep/byteorder.h
20
DOS2UNIX_FILES=	src/osdep/byteorder.h
20
MAKE_ARGS=	unstable=true libnl=false prefix=${PREFIX}
21
MAKE_ARGS=	unstable=true libnl=false prefix=${PREFIX}
21
USE_OPENSSL=	yes
22
USE_OPENSSL=	yes
22
SUB_FILES=	pkg-message
23
23
24
BIN_FILES=	airdecloak-ng buddy-ng aircrack-ng airdecap-ng ivstools \
24
BIN_FILES=	airdecloak-ng buddy-ng aircrack-ng airdecap-ng ivstools \
25
		makeivs-ng packetforge-ng wpaclean kstats
25
		makeivs-ng packetforge-ng wpaclean kstats
Lines 28-43 Link Here
28
28
29
OPTIONS_DEFINE=	SQLITE
29
OPTIONS_DEFINE=	SQLITE
30
OPTIONS_SUB=	yes
30
OPTIONS_SUB=	yes
31
31
SQLITE_DESC=	Use SQLite for storing pre-computed key tables
32
SQLITE_DESC=	Use SQLite for storing pre-computed key tables
33
SQLITE_USE=	SQLITE=yes
34
SQLITE_MAKE_ARGS=	SQLITE=true
35
SQLITE_CFLAGS=	-I${LOCALBASE}/include
36
SQLITE_VARS=	BIN_FILES+=airolib-ng
32
37
33
.include <bsd.port.options.mk>
34
35
.if ${PORT_OPTIONS:MSQLITE}
36
USE_SQLITE=	yes
37
MAKE_ARGS+=	SQLITE=true
38
BIN_FILES+=	airolib-ng
39
.endif
40
41
post-patch:
38
post-patch:
42
	@${REINPLACE_CMD} \
39
	@${REINPLACE_CMD} \
43
		-e 's|-I/usr/local|-I${LOCALBASE}|' \
40
		-e 's|-I/usr/local|-I${LOCALBASE}|' \
(-)net-mgmt/aircrack-ng/files/patch-src_crypto.h (-2 / +2 lines)
Lines 1-5 Link Here
1
--- src/crypto.h.orig	2014-07-12 04:24:03.000000000 +0200
1
--- src/crypto.h.orig	2014-07-12 02:24:03 UTC
2
+++ src/crypto.h	2014-11-02 21:23:28.529312627 +0100
2
+++ src/crypto.h
3
@@ -34,6 +34,7 @@
3
@@ -34,6 +34,7 @@
4
 
4
 
5
 #ifndef _CRYPTO_H
5
 #ifndef _CRYPTO_H
(-)net-mgmt/aircrack-ng/files/patch-src_osdep_byteorder.h (-2 / +2 lines)
Lines 1-5 Link Here
1
--- src/osdep/byteorder.h.orig	2013-03-04 18:32:55.000000000 +0100
1
--- src/osdep/byteorder.h.orig	2015-09-07 17:11:56 UTC
2
+++ src/osdep/byteorder.h	2013-09-29 13:48:25.382520852 +0200
2
+++ src/osdep/byteorder.h
3
@@ -181,7 +181,7 @@
3
@@ -181,7 +181,7 @@
4
 	 * Solaris
4
 	 * Solaris
5
 	 * -------
5
 	 * -------
(-)net-mgmt/aircrack-ng/files/patch-src_osdep_freebsd.c (-62 / +6 lines)
Lines 1-54 Link Here
1
--- src/osdep/freebsd.c.orig	2011-09-25 00:05:54.000000000 +0200
1
--- src/osdep/freebsd.c.orig	2011-09-24 22:05:54 UTC
2
+++ src/osdep/freebsd.c	2013-12-20 17:15:28.184126473 +0100
2
+++ src/osdep/freebsd.c
3
@@ -53,7 +53,9 @@ struct priv_fbsd {
3
@@ -389,7 +389,7 @@ static int do_fbsd_open(struct wif *wi, 
4
 	unsigned char			pf_buf[4096];
5
 	unsigned char			*pf_next;
6
 	int				pf_totlen;
7
+#if __FreeBSD_version > 700018
8
         struct ieee80211_bpf_params	pf_txparams;
9
+#endif
10
 
4
 
11
 	/* setchan */
12
 	int				pf_s;
13
@@ -280,13 +282,16 @@ static int fbsd_read(struct wif *wi, uns
14
 static int fbsd_write(struct wif *wi, unsigned char *h80211, int len,
15
 		      struct tx_info *ti)
16
 {
17
+#if __FreeBSD_version > 700018
18
         struct iovec iov[2];
19
+#endif
20
 	struct priv_fbsd *pf = wi_priv(wi);
21
 	int rc;
22
 
23
 	/* XXX make use of ti */
24
 	if (ti) {}
25
 
26
+#if __FreeBSD_version > 700018
27
 	iov[0].iov_base = &pf->pf_txparams;
28
 	iov[0].iov_len = pf->pf_txparams.ibp_len;
29
 
30
@@ -294,12 +299,19 @@ static int fbsd_write(struct wif *wi, un
31
         iov[1].iov_len = len;
32
 
33
 	rc = writev(pf->pf_fd, iov, 2);
34
+#else
35
+	rc = write(pf->pf_fd, h80211, len);
36
+#endif
37
 	if (rc == -1)
38
 		return rc;
39
+#if __FreeBSD_version > 700018
40
 	if (rc < (int) iov[0].iov_len)
41
 		return 0;
42
 
43
 	return rc - iov[0].iov_len;
44
+#else
45
+	return 0;
46
+#endif
47
 }
48
 
49
 static int fbsd_set_channel(struct wif *wi, int chan)
50
@@ -389,7 +401,7 @@ static int do_fbsd_open(struct wif *wi, 
51
 
52
         memset(&ifr, 0, sizeof(ifr));
5
         memset(&ifr, 0, sizeof(ifr));
53
         strcpy(ifr.ifr_name, iface);
6
         strcpy(ifr.ifr_name, iface);
54
-        ifr.ifr_media = ifmr.ifm_current | IFM_IEEE80211_MONITOR;
7
-        ifr.ifr_media = ifmr.ifm_current | IFM_IEEE80211_MONITOR;
Lines 56-62 Link Here
56
         if (ioctl(s, SIOCSIFMEDIA, &ifr) == -1)
9
         if (ioctl(s, SIOCSIFMEDIA, &ifr) == -1)
57
 		goto close_sock;
10
 		goto close_sock;
58
 
11
 
59
@@ -510,6 +522,39 @@ static int fbsd_set_mac(struct wif *wi, 
12
@@ -510,6 +510,39 @@ static int fbsd_set_mac(struct wif *wi, 
60
 	return ioctl(priv->pf_s, SIOCSIFLLADDR, ifr);
13
 	return ioctl(priv->pf_s, SIOCSIFLLADDR, ifr);
61
 }
14
 }
62
 
15
 
Lines 96-102 Link Here
96
 static struct wif *fbsd_open(char *iface)
49
 static struct wif *fbsd_open(char *iface)
97
 {
50
 {
98
 	struct wif *wi;
51
 	struct wif *wi;
99
@@ -530,7 +575,9 @@ static struct wif *fbsd_open(char *iface
52
@@ -530,7 +563,9 @@ static struct wif *fbsd_open(char *iface
100
 	wi->wi_set_mac		= fbsd_set_mac;
53
 	wi->wi_set_mac		= fbsd_set_mac;
101
 	wi->wi_get_rate		= fbsd_get_rate;
54
 	wi->wi_get_rate		= fbsd_get_rate;
102
 	wi->wi_set_rate		= fbsd_set_rate;
55
 	wi->wi_set_rate		= fbsd_set_rate;
Lines 107-117 Link Here
107
 
60
 
108
 	/* setup iface */
61
 	/* setup iface */
109
 	fd = do_fbsd_open(wi, iface);
62
 	fd = do_fbsd_open(wi, iface);
110
@@ -542,13 +589,17 @@ static struct wif *fbsd_open(char *iface
63
@@ -544,6 +579,8 @@ static struct wif *fbsd_open(char *iface
111
 	/* setup private state */
112
 	pf = wi_priv(wi);
113
 	pf->pf_fd = fd;
64
 	pf->pf_fd = fd;
114
+#if __FreeBSD_version > 700018
115
         pf->pf_txparams.ibp_vers = IEEE80211_BPF_VERSION;
65
         pf->pf_txparams.ibp_vers = IEEE80211_BPF_VERSION;
116
 	pf->pf_txparams.ibp_len = sizeof(struct ieee80211_bpf_params) - 6;
66
 	pf->pf_txparams.ibp_len = sizeof(struct ieee80211_bpf_params) - 6;
117
+	pf->pf_txparams.ibp_rate0 = 2;         /* 1 MB/s XXX */
67
+	pf->pf_txparams.ibp_rate0 = 2;         /* 1 MB/s XXX */
Lines 119-127 Link Here
119
 	pf->pf_txparams.ibp_rate1 = 2;         /* 1 MB/s XXX */
69
 	pf->pf_txparams.ibp_rate1 = 2;         /* 1 MB/s XXX */
120
 	pf->pf_txparams.ibp_try1 = 1;          /* no retransmits */
70
 	pf->pf_txparams.ibp_try1 = 1;          /* no retransmits */
121
 	pf->pf_txparams.ibp_flags = IEEE80211_BPF_NOACK;
71
 	pf->pf_txparams.ibp_flags = IEEE80211_BPF_NOACK;
122
 	pf->pf_txparams.ibp_power = 100;       /* nominal max */
123
 	pf->pf_txparams.ibp_pri = WME_AC_VO;   /* high priority */
124
+#endif
125
 
126
 	return wi;
127
 }
(-)net-mgmt/aircrack-ng/files/patch-src_osdep_radiotap_platform.h (-2 / +2 lines)
Lines 1-5 Link Here
1
--- src/osdep/radiotap/platform.h.orig	2014-04-01 19:18:03.439632822 +0200
1
--- src/osdep/radiotap/platform.h.orig	2014-03-22 20:26:59 UTC
2
+++ src/osdep/radiotap/platform.h	2014-04-01 19:18:19.900626663 +0200
2
+++ src/osdep/radiotap/platform.h
3
@@ -3,7 +3,7 @@
3
@@ -3,7 +3,7 @@
4
 #ifndef _BSD_SOURCE
4
 #ifndef _BSD_SOURCE
5
 #define _BSD_SOURCE
5
 #define _BSD_SOURCE
(-)net-mgmt/aircrack-ng/files/patch-src_osdep_radiotap_radiotap.c (-2 / +2 lines)
Lines 1-5 Link Here
1
--- src/osdep/radiotap/radiotap.c.orig	2014-04-01 19:20:56.379623336 +0200
1
--- src/osdep/radiotap/radiotap.c.orig	2014-03-31 01:39:15 UTC
2
+++ src/osdep/radiotap/radiotap.c	2014-04-01 19:22:54.880614337 +0200
2
+++ src/osdep/radiotap/radiotap.c
3
@@ -19,6 +19,16 @@
3
@@ -19,6 +19,16 @@
4
 	#include "../byteorder.h"
4
 	#include "../byteorder.h"
5
 #endif
5
 #endif
(-)net-mgmt/aircrack-ng/files/pkg-message.in (-10 lines)
Lines 1-10 Link Here
1
==============================================================================
2
3
Due to the addition of virtual access points (VAP) in FreeBSD 8 you need to
4
create a new wlan device in monitor mode to use with airodump-ng. To do so,
5
issue the following command:
6
	ifconfig ${VAP_INTERFACE} create wlandev ${INTERFACE} wlanmode monitor
7
8
Then run airodump-ng(1) with the newly created interface ${VAP_INTERFACE}.
9
10
==============================================================================

Return to bug 202952