]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
log "list of supported TLS groups" only once
authorRoger Dingledine <arma@torproject.org>
Mon, 9 Jun 2025 01:50:36 +0000 (21:50 -0400)
committerRoger Dingledine <arma@torproject.org>
Mon, 9 Jun 2025 02:08:43 +0000 (22:08 -0400)
We had been logging it every two hours forever, even though it's based
on the version of OpenSSL we're using it so it will never change.

Fixes bug #41093.

The fix is an improvement on commit ba88ad6b which addressed #41058.

Not adding a changes file since those commits haven't gone out in a
release yet either.

src/lib/tls/tortls_openssl.c

index 8cc8f1f33f842dc85d3a481426255e48f57be81e..a1f24c676187070bb3d414afe24ff5c81294c12f 100644 (file)
@@ -713,7 +713,12 @@ tor_tls_context_new(crypto_pk_t *identity, unsigned int key_lifetime,
       }
       int r = (int) SSL_CTX_set1_groups_list(result->ctx, list);
       if (r == 1) {
-        log_notice(LD_NET, "Set list of supported TLS groups to: %s", list);
+        static bool have_logged_already = false;
+        if (!have_logged_already) {
+          /* say it only once at startup, since the answer won't change */
+          log_notice(LD_NET, "Set list of supported TLS groups to: %s", list);
+          have_logged_already = true;
+        }
         success = true;
         break;
       }