X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;f=src%2Fprotocol_auth.c;h=107280c153898cd7c12520ac00256b631d76e7d9;hb=cf3f161b0cbe847a484ea2c4fb215b963acbb805;hp=c810877f9b863b24724af501f0fb3fc2a50c3b4a;hpb=2c424175639d62ea806b79173dfe6f554cf3ceb9;p=meshlink diff --git a/src/protocol_auth.c b/src/protocol_auth.c index c810877f..107280c1 100644 --- a/src/protocol_auth.c +++ b/src/protocol_auth.c @@ -314,22 +314,15 @@ bool id_h(connection_t *c, const char *request) { return false; } - if(mesh->bypass_security) { - if(!c->config_tree) - init_configuration(&c->config_tree); - c->allow_request = ACK; - return send_ack(c); - } - if(!c->config_tree) { init_configuration(&c->config_tree); - if(!read_host_config(c->config_tree, c->name)) { + if(!read_host_config(mesh, c->config_tree, c->name)) { logger(DEBUG_ALWAYS, LOG_ERR, "Peer %s had unknown identity (%s)", c->hostname, c->name); return false; } - read_ecdsa_public_key(c); + read_ecdsa_public_key(mesh, c); } else { if(c->protocol_minor && !ecdsa_active(c->ecdsa)) c->protocol_minor = 1;