From: Bart Polot Date: Wed, 26 Oct 2016 04:20:54 +0000 (+0000) Subject: - don't complain about AX messages pre-KX X-Git-Tag: initial-import-from-subversion-38251~42 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=bbdbdc3a614060c7d2f156985ae1fb76209cebc9;p=oweals%2Fgnunet.git - don't complain about AX messages pre-KX --- diff --git a/src/cadet/gnunet-service-cadet_tunnel.c b/src/cadet/gnunet-service-cadet_tunnel.c index fc715a419..05cd5f066 100644 --- a/src/cadet/gnunet-service-cadet_tunnel.c +++ b/src/cadet/gnunet-service-cadet_tunnel.c @@ -2203,10 +2203,13 @@ GCT_handle_encrypted (struct CadetTunnel *t, if (-1 == decrypted_size) { - GNUNET_break_op (0); GNUNET_STATISTICS_update (stats, "# unable to decrypt", 1, GNUNET_NO); - LOG (GNUNET_ERROR_TYPE_WARNING, "Wrong crypto on tunnel %s\n", GCT_2s (t)); - GCT_debug (t, GNUNET_ERROR_TYPE_WARNING); + if (CADET_TUNNEL_KEY_PING <= t->estate) + { + GNUNET_break_op (0); + LOG (GNUNET_ERROR_TYPE_WARNING, "Wrong crypto, tunnel %s\n", GCT_2s (t)); + GCT_debug (t, GNUNET_ERROR_TYPE_WARNING); + } return; } GCT_change_estate (t, CADET_TUNNEL_KEY_OK);