]> git.meshlink.io Git - meshlink-tiny/blobdiff - src/net.c
Remove all support for channels.
[meshlink-tiny] / src / net.c
index 101c95792dc3eb76476205a85dd3f68bd0b149b7..d930d1fdd7a2c36e61ee4b11a88f9e32a7a43cf7 100644 (file)
--- a/src/net.c
+++ b/src/net.c
@@ -101,12 +101,6 @@ static void timeout_handler(event_loop_t *loop, void *data) {
                }
 
                // Also make sure that if outstanding key requests for the UDP counterpart of a connection has timed out, we restart it.
-               if(c->node) {
-                       if(c->node->status.waitingforkey && c->node->last_req_key + pingtimeout < mesh->loop.now.tv_sec) {
-                               send_req_key(mesh, c->node);
-                       }
-               }
-
                if(c->status.active && c->last_key_renewal + 3600 < mesh->loop.now.tv_sec) {
                        devtool_sptps_renewal_probe((meshlink_node_t *)c->node);
 
@@ -191,21 +185,6 @@ static void periodic_handler(event_loop_t *loop, void *data) {
                                logger(mesh, MESHLINK_DEBUG, "Could not update %s", n->name);
                        }
                }
-
-               if(n->status.reachable && n->status.validkey && n->last_req_key + 3600 < mesh->loop.now.tv_sec) {
-                       logger(mesh, MESHLINK_DEBUG, "SPTPS key renewal for node %s", n->name);
-                       devtool_sptps_renewal_probe((meshlink_node_t *)n);
-
-                       if(!sptps_force_kex(&n->sptps)) {
-                               logger(mesh, MESHLINK_ERROR, "SPTPS key renewal for node %s failed", n->name);
-                               n->status.validkey = false;
-                               sptps_stop(&n->sptps);
-                               n->status.waitingforkey = false;
-                               n->last_req_key = -3600;
-                       } else {
-                               n->last_req_key = mesh->loop.now.tv_sec;
-                       }
-               }
        }
 
        timeout_set(&mesh->loop, data, &(struct timespec) {