# $Id: site.bro,v 1.3 2003/06/16 04:50:21 vern Exp $
#
# Definitions describing a site - which networks are "local"
# and "neighbors", and servers running particular services.

# Networks that are considered "local".
const local_nets: set[subnet] &redef;

# Networks that are considered "neighbors".  
const neighbor_nets: set[subnet] &redef;

# Servers for some common services.
const dns_servers: set[subnet] &redef;
const http_servers: set[subnet] &redef;
const smtp_servers: set[subnet] &redef;
const telnet_servers: set[subnet] &redef;
const sql_servers: set[subnet] &redef;

# Ports for some common services.
const http_ports = { 80/tcp, 443/tcp, 8000/tcp, 8001/tcp, 8080/tcp };
const oracle_ports = { 1521/tcp };

# Function that returns true if an address corresponds to one of
# the local networks, false if not. 
function is_local_addr(a: addr): bool
	{
	return a in local_nets;
	}
