meshlink
4 days agoSpeed up reconnections on network interface changes. master
Guus Sliepen [Fri, 19 Jul 2019 12:50:25 +0000 (14:50 +0200)]
Speed up reconnections on network interface changes.

Catta informs us whenever an interface comes online or goes offline. If we
detect that there are no online interfaces, immediately terminate all meta-
connections. Otherwise, reset the ping timers and reconnection timers for
outgoing connections.

4 days agoFix a small memory leak.
Guus Sliepen [Fri, 19 Jul 2019 12:44:29 +0000 (14:44 +0200)]
Fix a small memory leak.

When registering ourselves to Catta, we called meshlink_get_fingerprint()
without freeing the returned string afterwards.

4 days agoFix potential segmentation fault on node reachability change.
Guus Sliepen [Fri, 19 Jul 2019 12:40:36 +0000 (14:40 +0200)]
Fix potential segmentation fault on node reachability change.

2 weeks agoInform UTCP when a node is offline, so it will start connection timeouts.
Guus Sliepen [Sun, 7 Jul 2019 16:12:18 +0000 (18:12 +0200)]
Inform UTCP when a node is offline, so it will start connection timeouts.

When there are open channels to a node that is offline for longer than the
connection timeout, the channels will be marked closed, and callbacks will
be fired.

2 weeks agoUpdate UTCP to correctly handle timeouts sending data.
Guus Sliepen [Sun, 7 Jul 2019 14:52:02 +0000 (16:52 +0200)]
Update UTCP to correctly handle timeouts sending data.

Also add a test case that checks whether we get a callback when sent data
is not acked in a reasonable amount of time.

2 weeks agoPrevent meshlink_join() when the joining node is already part of a mesh.
Guus Sliepen [Thu, 4 Jul 2019 18:40:09 +0000 (20:40 +0200)]
Prevent meshlink_join() when the joining node is already part of a mesh.

5 weeks agoFix compiler warnings in the test suites.
Guus Sliepen [Thu, 13 Jun 2019 21:30:12 +0000 (23:30 +0200)]
Fix compiler warnings in the test suites.

5 weeks agoSpeed up initial autoconnect after joining a mesh.
Guus Sliepen [Thu, 30 May 2019 21:34:35 +0000 (23:34 +0200)]
Speed up initial autoconnect after joining a mesh.

When we just joined a mesh, we quickly want to establish redundant
connections. We do this by resetting the outgoing timer if we receive a
public key for a node that we are trying to connect to, and by speeding up
the autoconnect algorithm if we don't have 3 connections (in progress) yet.

5 weeks agoAutoconnect to reachable nodes without known public keys
Guus Sliepen [Thu, 23 May 2019 21:20:01 +0000 (23:20 +0200)]
Autoconnect to reachable nodes without known public keys

We must allow the autoconnect algorithm to try connections to nodes that
are online but for which we don't have a public key, otherwise we risk
that no connections are formed at all, except to the inviting node.

5 weeks agoEnsure we can pass arbitrary binary blobs for keys.
Guus Sliepen [Thu, 2 May 2019 22:24:29 +0000 (00:24 +0200)]
Ensure we can pass arbitrary binary blobs for keys.

5 weeks agoAdd encrypted key rotation feature api
sairoop-elear [Thu, 25 Apr 2019 03:38:31 +0000 (09:08 +0530)]
Add encrypted key rotation feature api

5 weeks agoModify meshlink configuration base file structre
sairoop-elear [Sun, 21 Apr 2019 03:45:42 +0000 (09:15 +0530)]
Modify meshlink configuration base file structre

5 weeks agoAdd unit test cases for encrypted storage key rotation
sairoop-elear [Fri, 12 Apr 2019 11:36:15 +0000 (17:06 +0530)]
Add unit test cases for encrypted storage key rotation

5 weeks agoVarious fixes for the encrypted storage support.
Guus Sliepen [Wed, 13 Mar 2019 22:13:06 +0000 (23:13 +0100)]
Various fixes for the encrypted storage support.

- create_initial_config_files() and node_write_config() are now the only
  functions that generate the content of new config files from scratch.
- All public API functions that change config files now immediately
  write them out.
- Config files of nodes that join using an invitation file are immediately
  written out.
- Ensure nodes marked dirty have their config files written out in
  periodic_handler(), and on meshlink_stop().
- Fix some memory leaks.
- Write out updated config files, and recreate mesh->self in meshlink_set_port().

5 weeks agoAdd support for opening a MeshLink instance without permanent storage.
Guus Sliepen [Mon, 11 Mar 2019 21:02:30 +0000 (22:02 +0100)]
Add support for opening a MeshLink instance without permanent storage.

5 weeks agoAdd missing declaration of chacha_ivsetup_96().
Guus Sliepen [Wed, 19 Dec 2018 20:24:25 +0000 (21:24 +0100)]
Add missing declaration of chacha_ivsetup_96().

5 weeks agoAdd support for encrypted storage.
Guus Sliepen [Fri, 14 Dec 2018 21:21:17 +0000 (22:21 +0100)]
Add support for encrypted storage.

This is a large overhaul of how configuration files are handled. All files
are now in PackMessage format, and are read from disk in to memory in one
go, and also saved to disk from memory in one go, using functions in conf.c.

5 weeks agoAdd the PackMessage library.
Guus Sliepen [Mon, 17 Dec 2018 02:12:55 +0000 (03:12 +0100)]
Add the PackMessage library.

6 weeks agoMake retry outgoing logic instantaneously connect when a change is discovered on...
lakshminarayanagurram [Fri, 24 May 2019 01:20:07 +0000 (06:50 +0530)]
Make retry outgoing logic instantaneously connect when a change is discovered on any node in catta

6 weeks agoAdd test cases for random port bindings
lakshminarayanagurram [Tue, 4 Jun 2019 02:03:33 +0000 (07:33 +0530)]
Add test cases for random port bindings

6 weeks agoMake meshlink_set_port() return false if we didn't bind to the requested port.
Guus Sliepen [Mon, 20 May 2019 09:18:23 +0000 (11:18 +0200)]
Make meshlink_set_port() return false if we didn't bind to the requested port.

7 weeks agoRe-enable building the chatpp example.
Guus Sliepen [Fri, 31 May 2019 14:27:33 +0000 (16:27 +0200)]
Re-enable building the chatpp example.

7 weeks agoAdd missing symbols to meshlink.sym.
Guus Sliepen [Fri, 31 May 2019 14:27:11 +0000 (16:27 +0200)]
Add missing symbols to meshlink.sym.

Also ensure automake treats it as a dependency, so it will rebuild the
library correctly whenever it is updated.

7 weeks agoUpdate android build
sairoop-elear [Mon, 13 May 2019 00:52:15 +0000 (06:22 +0530)]
Update android build

Fix compiling warnings

7 weeks agoUpdate README.android.
Guus Sliepen [Fri, 31 May 2019 11:19:26 +0000 (13:19 +0200)]
Update README.android.

Emphasize getting a recent version of the NDK, and also set the CXX
variable to ensure the C++ examples are compiled properly for Android.

Also ensure that README.android is a valid Markdown/CommonMark file.

8 weeks agoAdd meta-connection attempt callback feature
sairoop-elear [Thu, 25 Apr 2019 05:19:43 +0000 (10:49 +0530)]
Add meta-connection attempt callback feature

8 weeks agoAdd meshlink_get_submesh API
Lakshminarayana Gurram [Tue, 23 Apr 2019 04:20:09 +0000 (09:50 +0530)]
Add meshlink_get_submesh API

* Add meshlink_get_submesh API

* Modify submesh test vector to test meshlink_get_submesh API

8 weeks agoAdd condition check in auto connect for blacklisted nodes
Lakshminarayana Gurram [Tue, 16 Apr 2019 06:39:35 +0000 (12:09 +0530)]
Add condition check in auto connect for blacklisted nodes

* Add condition check in auto connect for blacklisted nodes

* Add test vector to test autoconnect

3 months agoAdd functions to get the amount of bytes in chanenl send and receive buffers.
Guus Sliepen [Sun, 17 Mar 2019 21:01:43 +0000 (22:01 +0100)]
Add functions to get the amount of bytes in chanenl send and receive buffers.

meshlink_channel_get_sendq() and meshlink_channel_get_recvq() call the
underlying UTCP connection's utcp_get_sendq() and utcp_get_recvq().
These return the amount of bytes waiting in the send and receive buffers.
In particular, a non-zero value for sendq means that sent data has not been
ACKed by the peer yet.

4 months agoRemove extra locks causing deadlocks for wait_sync_flag function
SS Roop [Mon, 18 Mar 2019 07:01:01 +0000 (12:31 +0530)]
Remove extra locks causing deadlocks for wait_sync_flag function

4 months agoFix spelling errors.
Guus Sliepen [Sun, 17 Mar 2019 20:46:45 +0000 (21:46 +0100)]
Fix spelling errors.

Found by codespell.

4 months agoMake Doxygen more strict, and fix errors in the documentation.
Guus Sliepen [Sun, 17 Mar 2019 20:41:42 +0000 (21:41 +0100)]
Make Doxygen more strict, and fix errors in the documentation.

4 months agoRemove make check warnings
SS Roop [Tue, 26 Feb 2019 21:58:30 +0000 (03:28 +0530)]
Remove make check warnings

4 months agoAdd blackbox test cases for submesh
Lakshminarayana Gurram [Tue, 5 Mar 2019 12:19:48 +0000 (17:49 +0530)]
Add blackbox test cases for submesh

4 months agoFix NULL checking of addrinfo structure in try_bind function
Lakshminarayana Gurram [Fri, 8 Mar 2019 05:10:59 +0000 (10:40 +0530)]
Fix NULL checking of addrinfo structure in try_bind function

4 months agoCheck for astyle version 3 before formatting the code.
Guus Sliepen [Tue, 12 Mar 2019 19:56:20 +0000 (20:56 +0100)]
Check for astyle version 3 before formatting the code.

Unfortunately, code formatters change their behaviour between versions.
The code currently requires astyle version 3.x, so check this before
running astyle. If the wrong version is installed, print an error.

4 months agoReduce locking in Catta callback functions to a minimum.
Guus Sliepen [Mon, 17 Dec 2018 02:14:45 +0000 (03:14 +0100)]
Reduce locking in Catta callback functions to a minimum.

4 months agoAdd a groupchat example program that uses the submesh feature.
lakshminarayanagurram [Mon, 25 Feb 2019 10:02:24 +0000 (11:02 +0100)]
Add a groupchat example program that uses the submesh feature.

4 months agoAdd devtool_get_all_submeshes().
lakshminarayanagurram [Mon, 25 Feb 2019 10:01:38 +0000 (11:01 +0100)]
Add devtool_get_all_submeshes().

4 months agoImprove support for submeshes.
lakshminarayanagurram [Mon, 25 Feb 2019 10:00:35 +0000 (11:00 +0100)]
Improve support for submeshes.

4 months agoAdd channel disconnection fix when node blacklisted
SS Roop [Tue, 12 Feb 2019 17:32:59 +0000 (23:02 +0530)]
Add channel disconnection fix when node blacklisted

5 months agoFix building the channels test.
Guus Sliepen [Tue, 19 Feb 2019 21:11:58 +0000 (22:11 +0100)]
Fix building the channels test.

5 months agoDo not define struct meshlink_open_params at all in meshlink.h.
Guus Sliepen [Tue, 19 Feb 2019 21:11:33 +0000 (22:11 +0100)]
Do not define struct meshlink_open_params at all in meshlink.h.

5 months agoDon't try to build node_* binaries for the optimal PMTU test cases anymore.
Guus Sliepen [Tue, 19 Feb 2019 21:10:36 +0000 (22:10 +0100)]
Don't try to build node_* binaries for the optimal PMTU test cases anymore.

5 months agoAdd test case for channel blacklist
sairoop-elear [Tue, 19 Feb 2019 20:38:53 +0000 (21:38 +0100)]
Add test case for channel blacklist

5 months agoCode formatting.
Guus Sliepen [Tue, 19 Feb 2019 20:41:58 +0000 (21:41 +0100)]
Code formatting.

5 months agoAdd optimal pmtu test cases
Guus Sliepen [Mon, 11 Feb 2019 18:18:54 +0000 (19:18 +0100)]
Add optimal pmtu test cases

5 months agoUpdate invite API in blackbox test cases
sairoop-elear [Fri, 8 Feb 2019 08:05:33 +0000 (13:35 +0530)]
Update invite API in blackbox test cases

5 months agoAdd network namespace test framework
sairoop-elear [Wed, 6 Feb 2019 05:06:34 +0000 (10:36 +0530)]
Add network namespace test framework

5 months agoModified meshlink_invite to generate invites for submesh
Lakshminarayana Gurram [Wed, 6 Feb 2019 02:47:30 +0000 (08:17 +0530)]
Modified meshlink_invite to generate invites for submesh

5 months agoAdded meshlink_submesh_open
Lakshminarayana Gurram [Wed, 6 Feb 2019 02:33:35 +0000 (08:03 +0530)]
Added meshlink_submesh_open

5 months agoAdd a test case for meshlink_get_all_nodes_by_dev_class().
Guus Sliepen [Thu, 31 Jan 2019 21:47:56 +0000 (22:47 +0100)]
Add a test case for meshlink_get_all_nodes_by_dev_class().

5 months agoAdd API functions to query nodes by device class.
Guus Sliepen [Thu, 31 Jan 2019 21:38:48 +0000 (22:38 +0100)]
Add API functions to query nodes by device class.

5 months agoAdd test cases for the PMTU discovery mechanism.
Guus Sliepen [Thu, 31 Jan 2019 21:21:52 +0000 (22:21 +0100)]
Add test cases for the PMTU discovery mechanism.

5 months agoUpdate the blackbox test infrastructure.
Guus Sliepen [Thu, 31 Jan 2019 21:20:40 +0000 (22:20 +0100)]
Update the blackbox test infrastructure.

5 months agoProvide a way to open MeshLink in its own network namespace.
Guus Sliepen [Sat, 26 Jan 2019 20:38:53 +0000 (21:38 +0100)]
Provide a way to open MeshLink in its own network namespace.

This causes all sockets from MeshLink to be opened in the given network
namespace, without affecting the application's namespace. Note that since
callback functions run inside MeshLink's own thread, the callback functions
inherit MeshLink's network namespace.

6 months agoOnly compile the monitor example application if ncurses is available.
Guus Sliepen [Wed, 16 Jan 2019 18:10:20 +0000 (19:10 +0100)]
Only compile the monitor example application if ncurses is available.

8 months agoCode formatting.
Guus Sliepen [Tue, 20 Nov 2018 15:21:58 +0000 (16:21 +0100)]
Code formatting.

8 months agoFix indentation.
Guus Sliepen [Tue, 20 Nov 2018 15:12:45 +0000 (16:12 +0100)]
Fix indentation.

8 months agoFix discovering node addresses from edges.
Guus Sliepen [Tue, 20 Nov 2018 15:10:17 +0000 (16:10 +0100)]
Fix discovering node addresses from edges.

The logic always skipped the first unique address found via edges, and since
in most cases there is only one such address, this would skip them altogether.

8 months agoSimplify rate limiting of incoming connections.
Guus Sliepen [Tue, 20 Nov 2018 15:07:44 +0000 (16:07 +0100)]
Simplify rate limiting of incoming connections.

We now really allow max_connection_burst connections per second, rather
than only allowing one second per connection on average, but allowing
a burst of max_connection_burst connections to go through.

8 months agoFix a potential segfault.
Guus Sliepen [Tue, 20 Nov 2018 15:01:12 +0000 (16:01 +0100)]
Fix a potential segfault.

This was found by Lakshminarayana Gurram.

8 months agoRemove debug messages printed to stderr.
Guus Sliepen [Tue, 20 Nov 2018 14:59:34 +0000 (15:59 +0100)]
Remove debug messages printed to stderr.

8 months agoFix socket leak every time meshlink_invite() is called.
Guus Sliepen [Tue, 20 Nov 2018 14:58:41 +0000 (15:58 +0100)]
Fix socket leak every time meshlink_invite() is called.

getlocaladdrname() would leak a socket every time it was called, which is
twice for every call to meshlink_invite() using the default flags.

8 months agoTry all CanonicalAddress and Address statements.
Guus Sliepen [Sun, 18 Nov 2018 23:03:27 +0000 (00:03 +0100)]
Try all CanonicalAddress and Address statements.

8 months agoAdd autoconf checks for LXC and cmocka.
Guus Sliepen [Sun, 18 Nov 2018 14:15:13 +0000 (15:15 +0100)]
Add autoconf checks for LXC and cmocka.

If LXC or cmocka are not installed, don't build the blackbox test suite.

8 months agoAdd the blackbox channel connection tests.
Guus Sliepen [Sun, 18 Nov 2018 13:50:08 +0000 (14:50 +0100)]
Add the blackbox channel connection tests.

8 months agoAdd the blackbox container based test suite.
Elear Solutions Dev [Thu, 8 Nov 2018 20:01:10 +0000 (21:01 +0100)]
Add the blackbox container based test suite.

This test suite uses LXC containers to simulate various nodes connected
to each other in different network topologies, and allows for realistic
testing of the MeshLink library.

9 months agoReally add both local and external address to the invitation URL.
Guus Sliepen [Tue, 9 Oct 2018 21:27:05 +0000 (23:27 +0200)]
Really add both local and external address to the invitation URL.

Also make sure we add both IPv4 and IPv6 if possible, use numeric addresses
unless hostnames resolve back to the same numeric address.

Add meshlink_invite_ex() that takes a flag that makes URL generation more
configurable.

9 months agoReformat the code.
Guus Sliepen [Tue, 9 Oct 2018 14:08:20 +0000 (16:08 +0200)]
Reformat the code.

9 months agoAdd an example using curses to monitor the state of MeshLink.
Guus Sliepen [Tue, 9 Oct 2018 14:06:50 +0000 (16:06 +0200)]
Add an example using curses to monitor the state of MeshLink.

9 months agoLock meshlink.conf to ensure only one instance can run at a time.
Guus Sliepen [Tue, 9 Oct 2018 12:06:04 +0000 (14:06 +0200)]
Lock meshlink.conf to ensure only one instance can run at a time.

10 months agoFix "Connection from (null)" log message.
Guus Sliepen [Thu, 30 Aug 2018 17:52:18 +0000 (19:52 +0200)]
Fix "Connection from (null)" log message.

10 months agoAlways add both CanonicalAddress and any local address to the invitation URL.
Guus Sliepen [Thu, 30 Aug 2018 17:45:13 +0000 (19:45 +0200)]
Always add both CanonicalAddress and any local address to the invitation URL.

We don't know in advance if the invitee will be on the LAN or outside
the LAN, and because hairpin routing is not working on many home
routers, it is safer to add all possible addresses.

Also, add the port number to each individual address in the URL, instead
of allowing only one port number.

10 months agoAdd missing code for the duplicate node testcase.
Guus Sliepen [Thu, 30 Aug 2018 17:44:08 +0000 (19:44 +0200)]
Add missing code for the duplicate node testcase.

11 months agoAdd duplicate node detection callback.
Guus Sliepen [Sun, 12 Aug 2018 15:09:20 +0000 (17:09 +0200)]
Add duplicate node detection callback.

MeshLink can detect if two nodes are online simultaneously using the same
Name. Normally, one or both of the duplicate nodes will terminate its
connection. Now there is a duplicate node callback that will be called when
the local node detects a duplicate node. One use for this is to blacklist
the duplicate node and/or notify the user of the problem.

11 months agoRemove the -fPIE and -pie compiler flags.
Guus Sliepen [Tue, 7 Aug 2018 18:43:19 +0000 (20:43 +0200)]
Remove the -fPIE and -pie compiler flags.

Since we are building a library, these flags shouldn't be used. They
appear to cause problems when linking libmeshlink into another shared
library.

12 months agoUpdate UTCP to allow meshlink_channel_send() immediately.
Guus Sliepen [Sun, 22 Jul 2018 11:32:01 +0000 (13:32 +0200)]
Update UTCP to allow meshlink_channel_send() immediately.

12 months agoAllow compiling without support for Catta.
Guus Sliepen [Sat, 21 Jul 2018 15:52:07 +0000 (17:52 +0200)]
Allow compiling without support for Catta.

Configuring with --disable-catta will cause MeshLink to not be linked to
the Catta library, and local discovery will not be available.

12 months agoAdd COPYING.README, detailing license obligations for users of MeshLink.
Guus Sliepen [Sat, 21 Jul 2018 15:10:35 +0000 (17:10 +0200)]
Add COPYING.README, detailing license obligations for users of MeshLink.

MeshLink itself depends on other libraries, and this document mainly
summarizes what obligations users of the MeshLink library have when they
distribute their software in binary form.

12 months agoPass appname in the ID string during invitations as well.
Guus Sliepen [Sun, 15 Jul 2018 09:19:19 +0000 (11:19 +0200)]
Pass appname in the ID string during invitations as well.

12 months agoPass appname in the ID string.
Guus Sliepen [Tue, 3 Jul 2018 18:21:40 +0000 (20:21 +0200)]
Pass appname in the ID string.

This is completely ignored by MeshLink itself at the moment, but is just
a hint to any proxy/relay.

12 months agoRemove old host config files when joining using an invitation.
Guus Sliepen [Tue, 26 Jun 2018 15:10:53 +0000 (17:10 +0200)]
Remove old host config files when joining using an invitation.

12 months agoAdd meshlink_set_invitation_timeout().
Guus Sliepen [Tue, 26 Jun 2018 14:42:57 +0000 (16:42 +0200)]
Add meshlink_set_invitation_timeout().

This sets a global timeout for invitation files. If a node tries to join
with an invitation whose file is older than the timeout, the invitation is
rejected.

12 months agoFix a compiler warning.
Guus Sliepen [Tue, 26 Jun 2018 14:33:29 +0000 (16:33 +0200)]
Fix a compiler warning.

12 months agoAdd meshlink_set_canonical_address().
Guus Sliepen [Tue, 26 Jun 2018 14:12:28 +0000 (16:12 +0200)]
Add meshlink_set_canonical_address().

This introduces the concept of a canonical address for a node, which is
its "official" address/port. It is only set manually, and never updated
or removed when other addresses have been discovered for this node.

Also, this changed meshlink_add_address(mesh, address) to be equivalent to
meshlink_set_canonical_address(mesh, meshlink_get_self(mesh), address, NULL).
While not strictly equivalent to the old behaviour, it matches the
documented intent of this function.

12 months agoFix valgrind warnings about reading uninitialized bytes.
Guus Sliepen [Tue, 26 Jun 2018 14:09:54 +0000 (16:09 +0200)]
Fix valgrind warnings about reading uninitialized bytes.

This is caused by memcpy()ing sockaddr_t structs that have only been
partially written to.

12 months agoUpdate .gitignore files.
Guus Sliepen [Tue, 26 Jun 2018 14:07:35 +0000 (16:07 +0200)]
Update .gitignore files.

12 months agoFix a potential segfault when closing a stopped meshlink handle.
Guus Sliepen [Tue, 26 Jun 2018 12:23:04 +0000 (14:23 +0200)]
Fix a potential segfault when closing a stopped meshlink handle.

If meshlink_stop() was called before meshlink_close(), the latter would
cause pthread_join() being called on a thread that was already joined.

12 months agoFix a potential segfault when closing a meshlink handle.
Guus Sliepen [Tue, 26 Jun 2018 12:20:17 +0000 (14:20 +0200)]
Fix a potential segfault when closing a meshlink handle.

Freeing the UTCP instance of a node would result in meshlink_send() being
called on a node that was already partially freed.

13 months agoDon't allow any unused variables in invitation files.
Guus Sliepen [Thu, 21 Jun 2018 13:26:10 +0000 (15:26 +0200)]
Don't allow any unused variables in invitation files.

13 months agoCode reformatting.
Guus Sliepen [Tue, 5 Jun 2018 18:33:08 +0000 (20:33 +0200)]
Code reformatting.

13 months agoFix a potential NULL-pointer dereference when generating invitations.
Guus Sliepen [Tue, 5 Jun 2018 18:31:04 +0000 (20:31 +0200)]
Fix a potential NULL-pointer dereference when generating invitations.

Closes #47 on GitHub.

14 months agoUse getsockname() to get a listening sockets actual address in meshlink_stop().
Guus Sliepen [Mon, 21 May 2018 20:03:47 +0000 (22:03 +0200)]
Use getsockname() to get a listening sockets actual address in meshlink_stop().

This should be better than sending a packet to the listening address,
which might be a link-local address for which a valid scope-id is
necessary, and which might not be in listen_socket.sa.

14 months agoEnsure -export-symbols-regex is not lost.
Guus Sliepen [Tue, 8 May 2018 15:05:00 +0000 (17:05 +0200)]
Ensure -export-symbols-regex is not lost.

An earlier commit accidentily caused libmeshlink_la_LDFLAGS to be
overwritten later in src/Makefile.am, and this caused
-export-symbols-regex to be dropped, thereby exposing internal symbols
of the library.

14 months agoEnable Catta by default, as documented.
Guus Sliepen [Sun, 6 May 2018 21:08:24 +0000 (23:08 +0200)]
Enable Catta by default, as documented.

14 months agoTry to be smarter generating invitation URLs.
Guus Sliepen [Sun, 6 May 2018 20:46:36 +0000 (22:46 +0200)]
Try to be smarter generating invitation URLs.

If we have a symbol hostname associated with us, use that. Otherwise, try
to find out which external addresses we have for both IPv4 and IPv6. If we
cannot connect to www.meshlink.io, then use the local address used for
outgoing connections as a fallback. Also, don't forget to add a port number
in all cases.

The generated invitation URL can now contain two addresses in the hostname
part, separated by a comma.

14 months agoAllow multiple addresses in an invitation URL.
Guus Sliepen [Thu, 3 May 2018 20:33:58 +0000 (22:33 +0200)]
Allow multiple addresses in an invitation URL.

This allows the address field in an invitation URL to be a
comma-separated list. The goal is to allow both IPv4 and IPv6 addresses
to be encoded in a single URL.

This commit also ensures that if a hostname is given, that all address
records associated with that hostname are tried.

14 months agoFix all compiler warnings found using -Wall -W -pedantic.
Guus Sliepen [Tue, 1 May 2018 13:24:35 +0000 (15:24 +0200)]
Fix all compiler warnings found using -Wall -W -pedantic.

Using both GCC 8 and Clang 7.

14 months agoCheck the return value of check_port().
Guus Sliepen [Tue, 1 May 2018 12:10:45 +0000 (14:10 +0200)]
Check the return value of check_port().

When initializing a new MeshLink instance, fail if there is no port
available for listening. When starting an already configured instance,
if no Port statement is found in the local node's host config file,
select and add a new one.