7.10. Firewall

The Firewall context acts as a firewall. It can be enabled for services sush as HTTP, FTP, SSH and SNMP.

7.10.1. Pre-defined variables

These are the read-only pre-defined variables available for each connection that is established.

Variable Type Example Description
$family string “ipv4” IP family of connecting client (“ipv4” or “ipv6”)
$protocol string “tcp” IP protocol of local server (“tcp” or “udp”)
$service string “ssh” Name of local service (“ssh”, “snmp”, “ftp” or “httpserver:X”)
$senderip string “” IP address of connecting client
$senderport number 41666 TCP/UDP port of connecting client
$serverip string “” IP address of local server
$serverport number 22 TCP/UDP port of local server

7.10.2. Functions


Allow IP connection to be established.

Returns:doesn’t return, script is terminated

Block IP connection from being established.

Returns:doesn’t return, script is terminated

7.10.3. On script error

On script error Block() is called.

7.10.4. On implicit termination

If not explicitly terminated then Allow() is called.