Fix a crash when we have a malformed public ECDSA key of another node.
authorGuus Sliepen <guus@tinc-vpn.org>
Mon, 12 May 2014 13:56:29 +0000 (15:56 +0200)
committerGuus Sliepen <guus@tinc-vpn.org>
Mon, 12 May 2014 13:56:29 +0000 (15:56 +0200)
src/protocol_auth.c

index 52afa09..0904afd 100644 (file)
@@ -379,7 +379,8 @@ bool id_h(connection_t *c, const char *request) {
                }
 
                if(experimental)
-                       read_ecdsa_public_key(c);
+                       if(!read_ecdsa_public_key(c))
+                               return false;
        } else {
                if(c->protocol_minor && !ecdsa_active(c->ecdsa))
                        c->protocol_minor = 1;