aboutsummaryrefslogtreecommitdiffstats
path: root/security/n2n
diff options
context:
space:
mode:
authorfarrokhi <farrokhi@FreeBSD.org>2018-08-18 17:06:53 +0800
committerfarrokhi <farrokhi@FreeBSD.org>2018-08-18 17:06:53 +0800
commit6a524bea642ef8f7e2ec67d92100fe0703bc10d9 (patch)
tree77125c466248664d92326095e44e192bfab675b1 /security/n2n
parent8ad4a9adca08442365a7e896b77717c67c170096 (diff)
downloadfreebsd-ports-gnome-6a524bea642ef8f7e2ec67d92100fe0703bc10d9.tar.gz
freebsd-ports-gnome-6a524bea642ef8f7e2ec67d92100fe0703bc10d9.tar.zst
freebsd-ports-gnome-6a524bea642ef8f7e2ec67d92100fe0703bc10d9.zip
New Port: security/n2n: Layer Two Peer-to-peer VPN
Diffstat (limited to 'security/n2n')
-rw-r--r--security/n2n/Makefile33
-rw-r--r--security/n2n/distinfo3
-rw-r--r--security/n2n/files/patch-Makefile13
-rw-r--r--security/n2n/files/patch-tuntap__freebsd.c20
-rw-r--r--security/n2n/pkg-descr10
5 files changed, 79 insertions, 0 deletions
diff --git a/security/n2n/Makefile b/security/n2n/Makefile
new file mode 100644
index 000000000000..483a05018154
--- /dev/null
+++ b/security/n2n/Makefile
@@ -0,0 +1,33 @@
+# Created by: Babak Farrokhi <farrokhi@FreeBSD.org>
+# $FreeBSD$
+
+PORTNAME= n2n
+PORTVERSION= 2.4
+CATEGORIES= security net
+
+MAINTAINER= farrokhi@FreeBSD.org
+COMMENT= Layer Two Peer-to-peer VPN
+
+LICENSE= GPLv3
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+USES= gmake ssl
+
+USE_GITHUB= yes
+GH_ACCOUNT= ntop
+GH_PROJECT= ${PORTNAME}
+
+PLIST_FILES= sbin/edge \
+ sbin/supernode \
+ man/man1/supernode.1.gz \
+ man/man7/n2n.7.gz \
+ man/man8/edge.8.gz
+
+do-install:
+ ${INSTALL_PROGRAM} ${WRKSRC}/edge ${STAGEDIR}${PREFIX}/sbin
+ ${INSTALL_PROGRAM} ${WRKSRC}/supernode ${STAGEDIR}${PREFIX}/sbin
+ ${INSTALL_MAN} ${WRKSRC}/edge.8 ${STAGEDIR}${MANPREFIX}/man/man8
+ ${INSTALL_MAN} ${WRKSRC}/supernode.1 ${STAGEDIR}${MANPREFIX}/man/man1
+ ${INSTALL_MAN} ${WRKSRC}/n2n.7 ${STAGEDIR}${MANPREFIX}/man/man7
+
+.include <bsd.port.mk>
diff --git a/security/n2n/distinfo b/security/n2n/distinfo
new file mode 100644
index 000000000000..fa5c976d28b2
--- /dev/null
+++ b/security/n2n/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1534574950
+SHA256 (ntop-n2n-2.4_GH0.tar.gz) = acbf5792935b84fb6516b9a2133a0f6f70023ee6ee4ca0d2d4248cab187f3c04
+SIZE (ntop-n2n-2.4_GH0.tar.gz) = 501614
diff --git a/security/n2n/files/patch-Makefile b/security/n2n/files/patch-Makefile
new file mode 100644
index 000000000000..cab4da7f3c20
--- /dev/null
+++ b/security/n2n/files/patch-Makefile
@@ -0,0 +1,13 @@
+--- Makefile.orig 2018-08-17 12:16:07 UTC
++++ Makefile
+@@ -4,8 +4,8 @@ N2N_OSNAME=$(shell uname -p)
+
+ ########
+
+-CC=gcc
+-DEBUG?=-g3
++CC?=gcc
++#DEBUG?=-g3
+ #OPTIMIZATION?=-O2
+ WARN?=-Wall -Wshadow -Wpointer-arith -Wmissing-declarations -Wnested-externs
+
diff --git a/security/n2n/files/patch-tuntap__freebsd.c b/security/n2n/files/patch-tuntap__freebsd.c
new file mode 100644
index 000000000000..08b1fc0a462d
--- /dev/null
+++ b/security/n2n/files/patch-tuntap__freebsd.c
@@ -0,0 +1,20 @@
+--- tuntap_freebsd.c.orig 2018-08-18 08:16:29 UTC
++++ tuntap_freebsd.c
+@@ -20,7 +20,7 @@
+
+ #ifdef __FreeBSD__
+
+-void tun_close(tuntap_dev *device);
++void tuntap_close(tuntap_dev *device);
+
+ /* ********************************** */
+
+@@ -78,7 +78,7 @@ int tuntap_open(tuntap_dev *device /* ignored */,
+
+ fd = popen(buf, "r");
+ if(fd < 0) {
+- tun_close(device);
++ tuntap_close(device);
+ return(-1);
+ } else {
+ int a, b, c, d, e, f;
diff --git a/security/n2n/pkg-descr b/security/n2n/pkg-descr
new file mode 100644
index 000000000000..475d4d1cdd0b
--- /dev/null
+++ b/security/n2n/pkg-descr
@@ -0,0 +1,10 @@
+n2n is a layer-two peer-to-peer virtual private network (VPN) which allows
+users to exploit features typical of P2P applications at network instead of
+application level. This means that users can gain native IP visibility
+(e.g. two PCs belonging to the same n2n network can ping each other) and be
+reachable with the same network IP address regardless of the network where
+they currently belong. In a nutshell, as OpenVPN moved SSL from application
+(e.g. used to implement the https protocol) to network protocol, n2n moves
+P2P from application to network level.
+
+WWW: https://www.ntop.org/products/n2n/