mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00

Fixed most @load dependency issues in the process. The test is still failing in a "known" way due to hot.conn.bro and scan.bro. Adressess #545
23 lines
463 B
Text
23 lines
463 B
Text
@load base/frameworks/metrics/main
|
|
@load base/protocols/ssl/main
|
|
|
|
redef enum Metrics::ID += {
|
|
SSL_SERVERNAME,
|
|
};
|
|
|
|
event bro_init()
|
|
{
|
|
Metrics::add_filter(SSL_SERVERNAME,
|
|
[$name="no-google-ssl-servers",
|
|
$pred(entry: Metrics::Entry) = {
|
|
return (/google\.com$/ !in entry$index);
|
|
},
|
|
$break_interval=10secs
|
|
]);
|
|
}
|
|
|
|
event SSL::log_ssl(rec: SSL::Info)
|
|
{
|
|
if ( rec?$server_name )
|
|
Metrics::add_data(SSL_SERVERNAME, [$index=rec$server_name]);
|
|
}
|