Tinc1.1 generates Port automatically when port is occupied

Eric Feliksik feliksik at gmail.com
Mon Feb 2 19:46:11 CET 2015


I like the config generator of tinc 1.1! An issue to consider on the
default behavior:

It turns out 'tinc -n mynet init mynodename' makes up a default Port=...
when the standard port is taken:
"Warning: could not bind to port 655. Tinc will instead listen on port
22911".

It is nice that this is autodetected and warned, but I wonder whether it is
nice to let this automatic-adaptation a default behavior:
- if people are able to read it, you can just as well leave it to a warning
and suggest running again with a --autoport flag to enable automatic port
generation
- if you cannot read it (e.g. you use configuration management tools to
setup tinc and distribute keys), you're in trouble. it will silently do
things different from what you want.
- it is too clever to be expected. You might not have tested this scenario,
especially since it will work as expected if you run the configuration an
even number of times (!)

You can prevent this by  calling "tinc -n mynet set Port 655" explicitly of
course. But then you must first run into this issue to note it.

Cheers
Eric
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.tinc-vpn.org/pipermail/tinc/attachments/20150202/f98dcfa3/attachment.html>


More information about the tinc mailing list