aboutsummaryrefslogtreecommitdiff
path: root/net/pwnat
diff options
context:
space:
mode:
authorVinícius Zavam <egypcio@FreeBSD.org>2020-06-01 17:31:11 +0000
committerVinícius Zavam <egypcio@FreeBSD.org>2020-06-01 17:31:11 +0000
commit8e6278637249e4dfeabc711d743f0bef153b2171 (patch)
treeac26e3163d54adc05dd1942ee2657d3646ca5f75 /net/pwnat
parentea91bcdb1eac6c02e5b078e8c04d6d584434a880 (diff)
downloadports-8e6278637249e4dfeabc711d743f0bef153b2171.tar.gz
ports-8e6278637249e4dfeabc711d743f0bef153b2171.zip
[NEW] net/pwnat: NAT punching tool based on udptunnel
pwnat, pronounced "poe-nat", is a tool that allows any number of clients behind NATs to communicate with a server behind a separate NAT with *no* port forwarding *no* DMZ setup, and *no* 3rd party involvement. The server does not need to know anything about the clients trying to connect. WWW: https://samy.pl/pwnat
Notes
Notes: svn path=/head/; revision=537495
Diffstat (limited to 'net/pwnat')
-rw-r--r--net/pwnat/Makefile33
-rw-r--r--net/pwnat/distinfo3
-rw-r--r--net/pwnat/files/pwnat.in24
-rw-r--r--net/pwnat/pkg-descr19
4 files changed, 79 insertions, 0 deletions
diff --git a/net/pwnat/Makefile b/net/pwnat/Makefile
new file mode 100644
index 000000000000..a2b12b2144c2
--- /dev/null
+++ b/net/pwnat/Makefile
@@ -0,0 +1,33 @@
+# $FreeBSD$
+
+PORTNAME= pwnat
+PORTVERSION= g20171222
+CATEGORIES= net
+
+MAINTAINER= egypcio@FreeBSD.org
+COMMENT= NAT punching tool based on udptunnel
+
+LICENSE= GPLv3
+
+ONLY_FOR_ARCHS= amd64 i386
+ONLY_FOR_ARCHS_REASON= Fails to patch while running in embedded systems
+
+USES= gmake
+USE_RC_SUBR= ${PORTNAME}
+USE_GITHUB= yes
+GH_ACCOUNT= samyk
+GH_TAGNAME= 5de412c
+
+PLIST_FILES= bin/${PORTNAME}
+
+post-patch:
+ ${REINPLACE_CMD} -e 's/CC=.*/CC=${CC}/g' \
+ ${WRKSRC}/Makefile
+ ${REINPLACE_CMD} -e 's/CFLAGS=.*/CFLAGS=${CFLAGS}/g' \
+ ${WRKSRC}/Makefile
+
+do-install:
+ ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}/${PREFIX}/bin
+ ${STRIP_CMD} ${STAGEDIR}/${PREFIX}/bin/${PORTNAME}
+
+.include <bsd.port.mk>
diff --git a/net/pwnat/distinfo b/net/pwnat/distinfo
new file mode 100644
index 000000000000..73d8f47df984
--- /dev/null
+++ b/net/pwnat/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1590674954
+SHA256 (samyk-pwnat-g20171222-5de412c_GH0.tar.gz) = 9a8333f0f6002b98f53d734657367ff2d9e42d048512eec6e1f3d98d588758e7
+SIZE (samyk-pwnat-g20171222-5de412c_GH0.tar.gz) = 41856
diff --git a/net/pwnat/files/pwnat.in b/net/pwnat/files/pwnat.in
new file mode 100644
index 000000000000..9c22c0507580
--- /dev/null
+++ b/net/pwnat/files/pwnat.in
@@ -0,0 +1,24 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+# PROVIDE: pwnat
+# REQUIRE: DAEMON
+# KEYWORD: shutdown
+#
+# pwnat_enable (bool) Default: NO
+# pwnat_flags (str) Default:
+#
+
+. /etc/rc.subr
+
+name="pwnat"
+rcvar="${name}_enable"
+command="%%PREFIX%%/bin/${name}"
+
+: ${pwnat_enable:="NO"}
+: ${pwnat_flags:=""}
+
+load_rc_config $name
+
+run_rc_command "$1"
diff --git a/net/pwnat/pkg-descr b/net/pwnat/pkg-descr
new file mode 100644
index 000000000000..dc80a1b68741
--- /dev/null
+++ b/net/pwnat/pkg-descr
@@ -0,0 +1,19 @@
+pwnat, pronounced "poe-nat", is a tool that allows any
+number of clients behind NATs to communicate with a
+server behind a separate NAT with *no* port forwarding
+*no* DMZ setup, and *no* 3rd party involvement. The server
+does not need to know anything about the clients trying
+to connect.
+
+Simply put, this is a proxy server that works behind a NAT,
+even when the client is behind a different NAT, without any
+3rd party or network changes.
+
+There is no middle man, no proxy, no 3rd party,
+no UPnP/STUN/ICE required, no spoofing, and no DNS tricks.
+
+More importantly, the client can then connect to any
+host or port on any remote host or to a fixed host and
+port decided by the server.
+
+WWW: https://samy.pl/pwnat