mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
Fixed a bug in the known-hosts script.
This commit is contained in:
parent
1dd3ba7f7d
commit
a3e91c5b33
1 changed files with 4 additions and 1 deletions
|
@ -43,7 +43,10 @@ event connection_established(c: connection) &priority=5
|
||||||
|
|
||||||
for ( host in set(id$orig_h, id$resp_h) )
|
for ( host in set(id$orig_h, id$resp_h) )
|
||||||
{
|
{
|
||||||
if ( host !in known_hosts && addr_matches_host(host, host_tracking) )
|
if ( host !in known_hosts &&
|
||||||
|
c$orig$state == TCP_ESTABLISHED &&
|
||||||
|
c$resp$state == TCP_ESTABLISHED &&
|
||||||
|
addr_matches_host(host, host_tracking) )
|
||||||
{
|
{
|
||||||
add known_hosts[host];
|
add known_hosts[host];
|
||||||
Log::write(Known::HOSTS_LOG, [$ts=network_time(), $host=host]);
|
Log::write(Known::HOSTS_LOG, [$ts=network_time(), $host=host]);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue