InterWorx Control Panel integrates with the APF iptables firewall system. Uses have fine grained control over the firewall configuation on the server, including individual port control, and global IP access and deny lists.
The following procedures explain how to configure firewall options using InterWorx Control Panel. The most common configuration options are exposed in the InterWorx Control Panel interface. As with many of the system services, a system administrator still retains the ability to configure the service by editing the configuration file directly.
Firewall Debug Mode
When Debug Mode is On, the firewall rules will automatically flush every 5 minutes. This allows you to test your firewall rules and prevent you from locking yourself out of your system. Once you have the firewall set up, turn debug off.
Default Type of Service
Setting this option affects network response. The following options are:
Minimum delay - Set this option when low latency (the time it takes for a data to travel from the source host to destination host) is most important.
Maximum throughput - Set this option when the volume of data transmitted in any period of time is important, and latency is less important.
Maximum reliability - Set this option when it is important that you have some certainty that the data will arrive at the destination without retransmission being required.
TCP Drop Policy
Setting this option determines how TCP packets are filtered. The following options are:
Reset - Sends a tcp-reset. This is the TCP/IP default.
Drop - Drops the packet.
Reject - Rejects the packet.
UDP Drop Policy
Setting this option determines how UDP packets are filtered. The following options are:
Reset - Sends a tcp-reset response. This is the TCP/IP default.
Drop - Drops the packet.
Reject - Rejects the packet.
Prohibit - Sends an icmp-host-prohibited response.
Block Multicasting
Set this option if you intend to participate in the MBONE, a high bandwidth network on top of the Internet which carries audio and video broadcasts.
Block Private Networks
Set this option to block all private IPv4 addresses. Leave this option off if this host resides behind a firewall with NAT or routing scheme that otherwise uses private addressing.
Maximum Sessions
This is the maximum number of "sessions" (connection tracking entries) that can be handled simultaneously by the firewall in kernel memory. Increasing this value too high will simply waste memory; setting it too low may result in some or all connections being refused, in paticular during denial of service attacks.
Sysctl TCP
These are sysctl hook changes to further harden the kernel from network attack trends by lowering standard time-out values and other time based packet responses.
The following procedures explain how to add Trusted IPs and Blocked IPs to the firewall configuration. Trusted IPs will be allowed through the firewall across all ports, while Blocked IPs will be denied access across all ports. IPs not listed in either Trusted IPs or Blocked IPs will be subject to the per-port rules in the Port Access section.
The advanced IP syntax not only gives you control over the IP address, but also the protocol (udp or tcp), flow direction (inbound or outbound), and port. The advanced syntax is:
protocol:flow:port:ip
protocol: Either udp or tcp. protocol is optional, and if not given, tcp is assumed.
flow: in or out. If protocol is given, then flow is required, otherwise flow is optional. If flow is not given, in is assumed.
s/d=port: A single port number. You must also specify if the port is the source port (s=), where the packet originates from, or the destination port (d=), where the packet will end up.
s/d=ip: A valid IP address. You may use an IP address or an IP address and mask. You must also specify if the IP address is the source IP (s=), where the packet originates from, or the destination IP (d=), where the packet will end up.
Click the Server menu item if it is not already open.
Click the Firewall menu item.
Locate the Port Access section.
You will see a list of all the ports that are currently open in some state or another, with four drop-down lists corresponding to TCP In, TCP Out, UDP In, and UDP Out.
Choose Open for the protocols you wish to open. For example, if you wish to open incoming and outgoing TCP choose Open for both drop-down lists.
Select Commit Changes from the drop-down list at the bottom of the table.
You will see the following message at the top of the screen: Ports configuration updated:
Click the Server menu item if it is not already open.
Click the Firewall menu item.
Locate the Port Access section.
You will see a list of all the ports that are currently open in some state or another, with four drop-down lists corresponding to TCP In, TCP Out, UDP In, and UDP Out.
Choose Closed for the protocols you wish to close. For example, if you wish to close incoming and outgoing UDP choose Closed for both drop-down lists.
Select Commit Changes from the drop-down list at the bottom of the table.
You will see the following message at the top of the screen: Ports configuration updated:
Setting all four options to Closed essentially deletes the port.
Click the Server menu item if it is not already open.
Click the Firewall menu item.
Locate the Port Access section.
You will see a list of all the ports that are currently open in some state or another, with a checkbox next to each.
Mark the checkboxes for the ports you would like to delete. You may also click [ Check All ] to select all the ports with a single click.
Select Delete from the drop-down list at the bottom of the table.
You will see the following message at the top of the screen: Ports deleted from configuration:
The NodeWorx interface will always display a default list of commonly used ports. Deleting a commonly used port will not remove it from the table, but instead show the port as closed across all four options.
Firewall Overview
InterWorx Control Panel integrates with the APF iptables firewall system. Uses have fine grained control over the firewall configuation on the server, including individual port control, and global IP access and deny lists.
Table of Contents
Manage FireWall Options
The following procedures explain how to configure firewall options using InterWorx Control Panel. The most common configuration options are exposed in the InterWorx Control Panel interface. As with many of the system services, a system administrator still retains the ability to configure the service by editing the configuration file directly.
Firewall Options Reference
Firewall Debug Mode
When Debug Mode is On, the firewall rules will automatically flush every 5 minutes. This allows you to test your firewall rules and prevent you from locking yourself out of your system. Once you have the firewall set up, turn debug off.
Default Type of Service
Setting this option affects network response. The following options are:
Linux Network Adminstrators Guide
TCP Drop Policy
Setting this option determines how TCP packets are filtered. The following options are:
tcp-reset. This is the TCP/IP default.UDP Drop Policy
Setting this option determines how UDP packets are filtered. The following options are:
tcp-resetresponse. This is the TCP/IP default.icmp-host-prohibitedresponse.Block Multicasting
Set this option if you intend to participate in the MBONE, a high bandwidth network on top of the Internet which carries audio and video broadcasts.
More about MBONE
Block Private Networks
Set this option to block all private IPv4 addresses. Leave this option off if this host resides behind a firewall with NAT or routing scheme that otherwise uses private addressing.
Maximum Sessions
This is the maximum number of "sessions" (connection tracking entries) that can be handled simultaneously by the firewall in kernel memory. Increasing this value too high will simply waste memory; setting it too low may result in some or all connections being refused, in paticular during denial of service attacks.
Sysctl TCP
These are sysctl hook changes to further harden the kernel from network attack trends by lowering standard time-out values and other time based packet responses.
Procedure
Trusted IP's
The following procedures explain how to add Trusted IPs and Blocked IPs to the firewall configuration. Trusted IPs will be allowed through the firewall across all ports, while Blocked IPs will be denied access across all ports. IPs not listed in either Trusted IPs or Blocked IPs will be subject to the per-port rules in the Port Access section.
Procedure - Add an IP Address
Procedure - Remove an IP Address
Firewall IP Address Reference
Simple Syntax
192.168.1.10and169.254.43.11are valid entries.10.0.1.0/24and192.0.0.0/8are valid entries.Advanced Syntax
The advanced IP syntax not only gives you control over the IP address, but also the protocol (
udportcp), flow direction (inbound or outbound), and port. The advanced syntax is:protocol: Eitherudportcp.protocolis optional, and if not given,tcpis assumed.flow:inorout. Ifprotocolis given, thenflowis required, otherwiseflowis optional. Ifflowis not given,inis assumed.s/d=port: A single port number. You must also specify if the port is the source port (s=), where the packet originates from, or the destination port (d=), where the packet will end up.s/d=ip: A valid IP address. You may use an IP address or an IP address and mask. You must also specify if the IP address is the source IP (s=), where the packet originates from, or the destination IP (d=), where the packet will end up.Example 1
Inbound TCP to destination port 3306 from 172.60.32.0/24
Example 2
Inbound TCP from port 3000 from 24.202.16.11
Example 3
Outbound TCP to destination port 22 to destination host 65.114.132.9
Example 4
Inbound UDP to destination port 1024 from destination host 43.213.13.20
Manage Firewall Rules
The following procedures explain how to manage custom port access rules. You can add new open ports, and edit, close, or delete existing ports.
Procedure - Add a Port
Procedure - Open a Port
Procedure - Close a Port
Procedure - Delete a Port