Add UPnP support to tincd.
authorEtienne Dechamps <etienne@edechamps.fr>
Sun, 15 Nov 2015 13:40:07 +0000 (13:40 +0000)
committerEtienne Dechamps <etienne@edechamps.fr>
Sat, 21 Nov 2015 16:17:59 +0000 (16:17 +0000)
commit513bffe1fee07bcbcb50691e221874adc1507857
tree5c8ad8b354cedc00000c286d7c2837dcee548bb0
parent2bb567c6a31e333ebdd16d6d076ba9976e6ed4fb
Add UPnP support to tincd.

This commit makes tincd capable of discovering UPnP-IGD devices on the
local network, and add mappings (port redirects) for its TCP and/or UDP
port.

The goal is to improve reliability and performance of tinc with nodes
sitting behind home routers that support UPnP, by making it less reliant
on UDP Hole Punching, which is prone to failure when "hostile" NATs are
involved.

The way this is implemented is by leveraging the libminiupnpc library,
which we have just added a new dependency on. We use pthread to run the
UPnP client code in a dedicated thread; we can't use the tinc event loop
because libminiupnpc doesn't have a non-blocking API.
bash_completion.d/tinc
doc/tinc.conf.5.in
doc/tinc.texi
src/Makefile.am
src/net_setup.c
src/tincctl.c
src/upnp.c [new file with mode: 0644]
src/upnp.h [new file with mode: 0644]