X-Git-Url: http://git.meshlink.io/?p=meshlink;a=blobdiff_plain;f=src%2Fmeshlink_internal.h;h=84368ee8cac938881897fc1dcc29b12600568128;hp=a40de535a8dbc911f80ef10507354bbb9936e8ec;hb=fa05f996c5500c056a36c1d43e33a407f876643c;hpb=6086a7fc1ecdf197d3937cec5f291b83c5d68454 diff --git a/src/meshlink_internal.h b/src/meshlink_internal.h index a40de535..84368ee8 100644 --- a/src/meshlink_internal.h +++ b/src/meshlink_internal.h @@ -41,6 +41,9 @@ static const char meshlink_invitation_label[] = "MeshLink invitation"; static const char meshlink_tcp_label[] = "MeshLink TCP"; static const char meshlink_udp_label[] = "MeshLink UDP"; +#define MESHLINK_CONFIG_VERSION 1 +#define MESHLINK_INVITATION_VERSION 1 + struct CattaServer; struct CattaSServiceBrowser; struct CattaSimplePoll; @@ -68,6 +71,9 @@ struct meshlink_open_params { dev_class_t devclass; int netns; + + const void *key; + size_t keylen; }; /// A handle for an instance of MeshLink. @@ -76,7 +82,7 @@ struct meshlink_handle { void *priv; char *appname; - dev_class_t devclass; + int32_t devclass; char *confbase; FILE *conffile; @@ -100,7 +106,6 @@ struct meshlink_handle { struct node_t *self; - struct splay_tree_t *config; struct splay_tree_t *edges; struct splay_tree_t *nodes; @@ -136,6 +141,7 @@ struct meshlink_handle { hash_t *node_udp_cache; struct connection_t *everyone; + struct ecdsa *private_key; struct ecdsa *invitation_key; int invitation_timeout; @@ -162,6 +168,7 @@ struct meshlink_handle { char *catta_servicetype; int netns; + void *config_key; }; /// A handle for a MeshLink node.