From fb34ab4a52491dd7fd51b565ca9efc0e6d60fda4 Mon Sep 17 00:00:00 2001 From: Arne Welzel Date: Thu, 11 Jan 2024 20:17:45 +0100 Subject: [PATCH] Merge remote-tracking branch 'origin/topic/awelzel/3540-known-hosts-expire-time' * origin/topic/awelzel/3540-known-hosts-expire-time: Known: Keep &create_expire on local tables/sets valid (cherry picked from commit 2ce4823c7acec6fb7b84ae1f7b5e172c6da5187e) --- scripts/policy/protocols/conn/known-hosts.zeek | 4 ++-- scripts/policy/protocols/conn/known-services.zeek | 4 ++-- scripts/policy/protocols/ssl/known-certs.zeek | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/scripts/policy/protocols/conn/known-hosts.zeek b/scripts/policy/protocols/conn/known-hosts.zeek index 822bd26ad5..14b09d9196 100644 --- a/scripts/policy/protocols/conn/known-hosts.zeek +++ b/scripts/policy/protocols/conn/known-hosts.zeek @@ -121,7 +121,7 @@ event Cluster::node_up(name: string, id: string) return; # Drop local suppression cache on workers to force HRW key repartitioning. - Known::hosts = set(); + clear_table(Known::hosts); } event Cluster::node_down(name: string, id: string) @@ -133,7 +133,7 @@ event Cluster::node_down(name: string, id: string) return; # Drop local suppression cache on workers to force HRW key repartitioning. - Known::hosts = set(); + clear_table(Known::hosts); } event Known::host_found(info: HostsInfo) diff --git a/scripts/policy/protocols/conn/known-services.zeek b/scripts/policy/protocols/conn/known-services.zeek index 3c323525fd..e868868f70 100644 --- a/scripts/policy/protocols/conn/known-services.zeek +++ b/scripts/policy/protocols/conn/known-services.zeek @@ -187,7 +187,7 @@ event Cluster::node_up(name: string, id: string) return; # Drop local suppression cache on workers to force HRW key repartitioning. - Known::services = table(); + clear_table(Known::services); } event Cluster::node_down(name: string, id: string) @@ -199,7 +199,7 @@ event Cluster::node_down(name: string, id: string) return; # Drop local suppression cache on workers to force HRW key repartitioning. - Known::services = table(); + clear_table(Known::services); } event service_info_commit(info: ServicesInfo) diff --git a/scripts/policy/protocols/ssl/known-certs.zeek b/scripts/policy/protocols/ssl/known-certs.zeek index a5dd1d2382..d5008da394 100644 --- a/scripts/policy/protocols/ssl/known-certs.zeek +++ b/scripts/policy/protocols/ssl/known-certs.zeek @@ -146,7 +146,7 @@ event Cluster::node_up(name: string, id: string) return; # Drop local suppression cache on workers to force HRW key repartitioning. - Known::certs = table(); + clear_table(Known::certs); } event Cluster::node_down(name: string, id: string) @@ -158,7 +158,7 @@ event Cluster::node_down(name: string, id: string) return; # Drop local suppression cache on workers to force HRW key repartitioning. - Known::certs = table(); + clear_table(Known::certs); } event ssl_established(c: connection) &priority=3