Merge remote-tracking branch 'origin/topic/awelzel/fix-listen-websocket-ubsan-port-count-confusion'

* origin/topic/awelzel/fix-listen-websocket-ubsan-port-count-confusion:
  cluster/cluster.bif: Fix CountVal casted to PortVal
This commit is contained in:
Arne Welzel 2025-04-23 15:55:46 +02:00
commit 68bc6111ed
3 changed files with 8 additions and 2 deletions

View file

@ -1,3 +1,9 @@
7.2.0-dev.602 | 2025-04-23 15:55:46 +0200
* cluster/cluster.bif: Fix CountVal casted to PortVal (Arne Welzel, Corelight)
Thanks UBSAN!
7.2.0-dev.600 | 2025-04-23 15:07:47 +0200
* CI: No more Ubuntu 20.04 [skip ci] (Arne Welzel, Corelight)

View file

@ -1 +1 @@
7.2.0-dev.600
7.2.0-dev.602

View file

@ -197,7 +197,7 @@ function Cluster::__listen_websocket%(options: WebSocketServerOptions%): bool
static_cast<uint16_t>(options_rec->GetField<zeek::PortVal>("listen_port")->Port()),
};
server_options.max_event_queue_size = options_rec->GetField<zeek::PortVal>("max_event_queue_size")->AsCount();
server_options.max_event_queue_size = options_rec->GetField<zeek::CountVal>("max_event_queue_size")->Get();
server_options.tls_options = std::move(tls_options);
auto result = zeek::cluster::manager->ListenWebSocket(server_options);