D-Link DFL-1600 - Security Appliance User Manual

Manual is about: NetDefendOS Network Security Firewall

Summary of DFL-1600 - Security Appliance

  • Page 1

    Network security solution http://www.Dlink.Com netdefendos ver. 2.27.03 network security firewall user manual security security.

  • Page 2: User Manual

    User manual dfl-210/260/260e/800/860/860e dfl-1600/1660/2500/2560/2560g netdefendos version 2.27.03 d-link corporation no. 289, sinhu 3rd rd, neihu district, taipei city 114, taiwan r.O.C. Http://www.Dlink.Com published 2010-11-11 copyright © 2010

  • Page 3

    User manual dfl-210/260/260e/800/860/860e dfl-1600/1660/2500/2560/2560g netdefendos version 2.27.03 published 2010-11-11 copyright © 2010 copyright notice this publication, including all photographs, illustrations and software, is protected under international copyright laws, with all rights reserve...

  • Page 4: Table Of Contents

    Table of contents preface ...............................................................................................................14 1. Netdefendos overview ....................................................................................16 1.1. Features ......................................

  • Page 5

    3.2.3. Icmp services ............................................................................89 3.2.4. Custom ip protocol services ..........................................................91 3.2.5. Service groups ............................................................................91 3.2...

  • Page 6

    4.7. Transparent mode ................................................................................ 212 4.7.1. Overview ................................................................................. 212 4.7.2. Enabling internet access ..............................................................

  • Page 7

    7. Address translation ........................................................................................ 340 7.1. Overview ............................................................................................ 340 7.2. Nat ...................................................................

  • Page 8

    9.7.2. Troubleshooting certificates ........................................................ 443 9.7.3. Ipsec troubleshooting commands ................................................ 444 9.7.4. Management interface failure with vpn ........................................ 445 9.7.5. Specific error ...

  • Page 9

    13.1. Ip level settings ................................................................................ 511 13.2. Tcp level settings ............................................................................. 515 13.3. Icmp level settings .............................................................

  • Page 10: List Of Figures

    List of figures 1.1. Packet flow schematic part i ...........................................................................23 1.2. Packet flow schematic part ii ..........................................................................24 1.3. Packet flow schematic part iii ...........................

  • Page 11

    10.9. A server load balancing configuration .......................................................... 480 10.10. Connections from three clients ................................................................... 483 10.11. Stickiness and round-robin ....................................................

  • Page 12: List Of Examples

    List of examples 1. Example notation .............................................................................................14 2.1. Enabling remote management via https ...........................................................33 2.2. Enabling ssh remote access ..................................

  • Page 13

    4.14. Igmp - no address translation .................................................................... 206 4.15. If1 configuration ........................................................................................ 207 4.16. If2 configuration - group translation .................................

  • Page 14: Preface

    Preface intended audience the target audience for this reference guide is administrators who are responsible for configuring and managing netdefend firewalls which are running the netdefendos operating system. This guide assumes that the reader has some basic knowledge of networks and network securi...

  • Page 15

    Items in the tree-view list at the left of the interface or in the menu bar or in a context menu need to be opened followed by information about the data items that need to be entered: 1. Go to item x > item y > item z 2. Now enter: • dataitem1: datavalue1 • dataitem2: datavalue2 highlighted content...

  • Page 16: 1.1. Features

    Chapter 1. Netdefendos overview this chapter outlines the key features of netdefendos. • features, page 16 • netdefendos architecture, page 19 • netdefendos state engine packet flow, page 23 1.1. Features d-link netdefendos is the base software engine that drives and controls the range of netdefend ...

  • Page 17

    Vpn netdefendos supports a range of virtual private network (vpn) solutions. Netdefendos supports ipsec, l2tp and pptp based vpns concurrently, can act as either server or client for all of the vpn types, and can provide individual security policies for each vpn tunnel. The details for this can be f...

  • Page 18

    Enables a device running netdefendos to distribute network load to multiple hosts. These features are discussed in detail in chapter 10, traffic management. Note threshold rules are only available on certain d-link netdefend product models. Operations and maintenance administrator management of netd...

  • Page 19

    1.2. Netdefendos architecture 1.2.1. State-based architecture the netdefendos architecture is centered around the concept of state-based connections. Traditional ip routers or switches commonly inspect all packets and then perform forwarding decisions based on information found in the packet headers...

  • Page 20: 1.2.3. Basic Packet Flow

    Netdefendos rule sets finally, rules which are defined by the administrator in the various rule sets are used for actually implementing netdefendos security policies. The most fundamental set of rules are the ip rules, which are used to define the layer 3 ip filtering policy as well as carrying out ...

  • Page 21

    • source and destination interfaces • source and destination network • ip protocol (for example tcp, udp, icmp) • tcp/udp ports • icmp types • point in time in reference to a predefined schedule if a match cannot be found, the packet is dropped. If a rule is found that matches the new connection, th...

  • Page 22

    Processing such as encryption or encapsulation might occur. The next section provides a set of diagrams illustrating the flow of packets through netdefendos. 1.2.3. Basic packet flow chapter 1. Netdefendos overview 22.

  • Page 23

    1.3. Netdefendos state engine packet flow the diagrams in this section provide a summary of the flow of packets through the netdefendos state-engine. There are three diagrams, each flowing into the next. It is not necessary to understand these diagrams, however, they can be useful as a reference whe...

  • Page 24

    Figure 1.2. Packet flow schematic part ii the packet flow is continued on the following page. 1.3. Netdefendos state engine packet flow chapter 1. Netdefendos overview 24.

  • Page 25

    Figure 1.3. Packet flow schematic part iii 1.3. Netdefendos state engine packet flow chapter 1. Netdefendos overview 25.

  • Page 26

    Apply rules the figure below presents the detailed logic of the apply rules function in figure 1.2, “packet flow schematic part ii” above. Figure 1.4. Expanded apply rules logic 1.3. Netdefendos state engine packet flow chapter 1. Netdefendos overview 26.

  • Page 27

    1.3. Netdefendos state engine packet flow chapter 1. Netdefendos overview 27.

  • Page 28: 2.1. Managing Netdefendos

    Chapter 2. Management and maintenance this chapter describes the management, operations and maintenance related aspects of netdefendos. • managing netdefendos, page 28 • events and logging, page 57 • radius accounting, page 62 • hardware monitoring, page 67 • snmp monitoring, page 69 • the pcapdump ...

  • Page 29

    Transfer between the administrator's workstation and the netdefend firewall. Various files used by netdefendos can be both uploaded and downloaded with scp. This feature is fully described in section 2.1.6, “secure copy”. Console boot menu before netdefendos starts running, a console connected direc...

  • Page 30: 2.1.3. The Web Interface

    If one administrator logs in, then a second or more will be allowed to login but they will only have audit privileges. In other words the second or more administrators who login will only be able to read configurations and will not be able to change them. 2.1.3. The web interface netdefendos provide...

  • Page 31

    Enter the username and password and click the login button. The factory default username and password is admin and admin . If the user credentials are correct, you will be transferred to the main web interface page. First time web interface logon and the setup wizard when logging on for the first ti...

  • Page 32

    For information about the default user name and password, see section 2.1.2, “the default administrator account” . Note: remote management access access to the web interface is regulated by the configured remote management policy. By default, the system will only allow web access from the internal n...

  • Page 33

    I. Update center - manually update or schedule updates of the intrusion detection and antivirus signatures. Ii. License - view license details or enter activation code. Iii. Backup - make a backup of the configuration to a local computer or restore a previously downloaded backup. Iv. Reset - restart...

  • Page 34: 2.1.4. The Cli

    Web interface 1. Go to system > remote management > add > http/https management 2. Enter a name for the http/https remote management policy, for example https 3. Check the https checkbox 4. Select the following from the dropdown lists: • user database: adminusers • interface: any • network: all-nets...

  • Page 35

    Interface on an ip rule. • show - displays the current categories or display the values of a particular object. • delete - deletes a specific object. Cli command structure cli commands usually begin with the structure: . For example, to display an ip address object called my_address, the command wou...

  • Page 36

    Been entered. For example, when creating an ip rule for a particular ip rule set, the command line might begin: add iprule if the tab key is now pressed, the mandatory parameters are displayed by netdefendos: a value is required for the following properties: action destinationnetwork sourceinterface...

  • Page 37

    Add logreceiversyslog example address=example_ip logseverity=emergency however, if the "." character is used instead: add logreceiversyslog example address=example_ip logseverity=. (tab) a list of all possible values is given: add logreceiversyslog example address=example_ip logseverity=emergency,al...

  • Page 38

    Specifying multiple property values sometimes a command property may need multiple values. For example, some commands use the property accountingservers and more than one value can be specified for this property. When specifying multiple values, they should be separated by a comma "," character. For...

  • Page 39

    Netdefendos for hostnames to be translated to ip addresses. Serial console cli access the serial console port is a local rs-232 port on the netdefend firewall that allows direct access to the netdefendos cli through a serial connection to a pc or dumb terminal. To locate the serial console port on d...

  • Page 40

    • interface: lan • network: lannet 4. Click ok logging on to the cli when access to the cli has been established to netdefendos through the serial console or an ssh client, the administrator will need to logon to the system before being able to execute any cli command. This authentication step is ne...

  • Page 41

    Gw-world:/> where device is the model number of the netdefend firewall. This can be customized, for example, to my-prompt:/>, by using the cli command: gw-world:/> set device name="my-prompt" the cli reference guide uses the command prompt gw-world:/> throughout. Tip: the cli prompt is the webui dev...

  • Page 42

    Address book, starting with the interface ip: gw-world:/> set address ip4address if2_ip address=10.8.1.34 the network ip address for the interface must also be set to the appropriate value: gw-world:/> set address ip4address if2_net address=10.8.1.0/24 in this example, local ip addresses are used fo...

  • Page 43: 2.1.5. Cli Scripts

    Using the -disconnect option of the sessionmanager command. The sessionmanager command options are fully documented in the cli reference guide. 2.1.5. Cli scripts to allow the administrator to easily store and execute sets of cli commands, netdefendos provides a feature called cli scripting. A cli s...

  • Page 44

    Note: the symbol $0 is reserved notice that the name of the first variable is $1. The variable $0 is reserved and is always replaced before execution by the name of the script file itself. For example, a script called my_script.Sgs is to be executed with ip address 126.12.11.01 replacing all occurre...

  • Page 45

    To move the example my_script.Sgs to non-volatile memory the command would be: gw-world:/> script -store -name=my_script.Sgs alternatively, all scripts can be moved to non-volatile memory with the command: gw-world:/> script -store -all removing scripts to remove a saved script. The script -remove c...

  • Page 46: 2.1.6. Secure Copy

    Add ip4address if1_ip address=10.6.60.10 add ip4address if1_net address=10.6.60.0/24 add ip4address if1_br address=10.6.60.255 add ip4address if1_dns1 address=141.1.1.1 " " " the file new_script_sgs can then be downloaded with scp to the local management workstation and then uploaded and executed on...

  • Page 47

    Format for scp client software. Scp command format scp command syntax is straightforward for most console based clients. The basic command used here is scp followed by the source and destination for the file transfer. Upload is performed with the command: > scp download is done with the command: > s...

  • Page 48

    Apart from the individual files, the objects types listed are: • httpalgbanners/ - the banner files for user authentication html. Uploading these is described further in section 6.3.4.4, “customizing html pages”. • httpauthbanner/ - the banner files for html alg dynamic content filtering. Uploading ...

  • Page 49

    Accessing the console boot menu the boot menu is only accessible through a console device attached directly to the serial console located on the netdefend firewall. It can be accessed through the console after the netdefend firewall is powered up and before netdefendos is fully started. After poweri...

  • Page 50

    Initial options with a console password set if a console password is set then the initial options that appear when netdefendos loading is interrupted with a key press are shown below. The 1. Start firewall option re-continues the interrupted netdefendos startup process. If the 2. Login option is cho...

  • Page 51

    Default: 30 webui http port specifies the http port for the web interface. Default: 80 webui https port specifies the http(s) port for the web interface. Default: 443 https certificate specifies which certificate to use for https traffic. Only rsa certificates are supported. Default: https 2.1.9. Wo...

  • Page 52

    Command-line interface gw-world:/> show service a list of all services will be displayed, grouped by their respective type. Web interface 1. Go to objects > services 2. A web page listing all services will be presented. A list contains the following basic elements: • add button - displays a dropdown...

  • Page 53

    Example 2.5. Editing a configuration object when the behavior of netdefendos is changed, it is most likely necessary to modify one or several configuration objects. This example shows how to edit the comments property of the telnet service. Command-line interface gw-world:/> set service servicetcpud...

  • Page 54

    Web interface 1. Go to objects > address book 2. Click on the add button 3. In the dropdown menu displayed, select ip address 4. In the name text box, enter myhost 5. Enter 192.168.10.10 in the ip address textbox 6. Click ok 7. Verify that the new ip4 address object has been added to the list exampl...

  • Page 55

    Example 2.9. Listing modified configuration objects this example shows how to list configuration objects that have been modified. Command-line interface gw-world:/> show -changes type object ------------- ------ - ip4address myhost * servicetcpudp telnet a "+" character in front of the row indicates...

  • Page 56

    The web browser will automatically try to connect back to the web interface after 10 seconds. If the connection succeeds, this is interpreted by netdefendos as confirmation that remote management is still working. The new configuration is then automatically committed. Note: changes must be committed...

  • Page 57: 2.2. Events And Logging

    2.2. Events and logging 2.2.1. Overview the ability to log and analyze system activities is an essential feature of netdefendos. Logging enables not only monitoring of system status and health, but also allows auditing of network usage and assists in trouble-shooting. Log message generation netdefen...

  • Page 58

    By default, netdefendos sends all messages of level info and above to configured log servers. The debug category is intended for troubleshooting only and should only be turned on if required when trying to solve a problem. All log messages of all severity levels are found listed in the netdefendos l...

  • Page 59

    Syslog is a standardized protocol for sending log data although there is no standardized format for the log messages themselves. The format used by netdefendos is well suited to automated processing, filtering and searching. Although the exact format of each log entry depends on how a syslog receive...

  • Page 60: 2.2.6. Snmp Traps

    2.2.6. Snmp traps the snmp protocol simple network management protocol (snmp) is a means for communicating between a network management system (nms) and a managed device. Snmp defines 3 types of messages: a read command for an nms to examine a managed device, a write command to alter the state of a ...

  • Page 61

    Web interface 1. Go to log & event receivers > add > snmp2ceventreceiver 2. Specify a name for the event receiver, for example my_snmp 3. Enter 195.11.22.55 as the ip address 4. Enter an snmp community string if needed by the trap receiver 5. Click ok the system will now be sending snmp traps for al...

  • Page 62: 2.3. Radius Accounting

    2.3. Radius accounting 2.3.1. Overview within a network environment containing large numbers of users, it is advantageous to have one or a cluster of central servers that maintain user account information and are responsible for authentication and authorization tasks. The central database residing o...

  • Page 63

    Authentication server. • how authenticated - how the user was authenticated. This is set to either radius if the user was authenticated via radius, or local if the user was authenticated via a local user database. • delay time - the time delay (in seconds) since the accountingrequest packet was sent...

  • Page 64

    Tip: the meaning of the asterisk after a list entry the asterisk "*" symbol after an entry in the list above indicates that the sending of the parameter is optional and is configurable. 2.3.3. Interim accounting messages in addition to start and stop messages netdefendos can optionally periodically ...

  • Page 65

    Firewalls. This means that accounting information is automatically updated on both cluster members whenever a connection is closed. Two special accounting events are also used by the active unit to keep the passive unit synchronized: • an accountingstart event is sent to the inactive member in an ha...

  • Page 66

    Continue to be logged in. Disabling the setting will mean that the user will be logged out if the radius accounting server cannot be reached even though the user has been previously authenticated. Default: enabled logout at shutdown if there is an orderly shutdown of the netdefend firewall by the ad...

  • Page 67: 2.4. Hardware Monitoring

    2.4. Hardware monitoring availability certain d-link hardware models allow the administrator to use the cli to query the current value of various hardware operational parameters such as the current temperature inside the firewall. This feature is referred to as hardware monitoring. The d-link netdef...

  • Page 68

    The -verbose option displays the current values plus the configured ranges: gw-world:/> hwm -a -v 2 sensors available poll interval time = 500ms name [type][number] = low_limit] current_value [high_limit (unit) ----------------------------------------------------------------- sys temp [temp ][ 0] = ...

  • Page 69: 2.5. Snmp Monitoring

    2.5. Snmp monitoring overview simple network management protocol (snmp) is a standardized protocol for management of network devices. An snmp compliant client can connect to a network device which supports the snmp protocol to query and control it. Netdefendos supports snmp version 1 and version 2. ...

  • Page 70

    Snmp access. Port 161 is usually used for snmp and netdefendos always expects snmp traffic on that port. Remote access encryption it should be noted that snmp version 1 or 2c access means that the community string will be sent as plain text over a network. This is clearly insecure if a remote client...

  • Page 71

    Default: enabled snmp request limit maximum number of snmp requests that will be processed each second by netdefendos. Should snmp requests exceed this rate then the excess requests will be ignored by netdefendos. Default: 100 system contact the contact person for the managed node. Default: n/a syst...

  • Page 72: 2.6. The Pcapdump Command

    2.6. The pcapdump command a valuable diagnostic tool is the ability to examine the packets that enter and leave the interfaces of a netdefend firewall. For this purpose, netdefendos provides the cli command pcapdump which not only allows the examination of packet streams entering and leaving interfa...

  • Page 73

    It is possible to have multiple pcapdump executions being performed at the same time. The following points describe this feature: 1. All capture from all executions goes to the same memory buffer. The command can be launched multiple times with different interfaces specified. In this case the packet...

  • Page 74

    The name of the file used for pcapdump output must comply with the following rules: • excluding the filename extension, the name may not exceed 8 characters in length. • the filename extension cannot exceed 3 characters in length. • the filename and extension can only contain the characters a-z, 0-9...

  • Page 75: 2.7. Maintenance

    2.7. Maintenance 2.7.1. Auto-update mechanism a number of the netdefendos security features rely on external servers for automatic updates and content filtering. The intrusion prevention and detection system and anti-virus modules require access to updated signature databases in order to provide pro...

  • Page 76

    Since a full system backup includes a netdefendos version, compatability is not an issue with these types of backup. With configuration only backups, the following should be noted: • a configuration backup created on a higher netdefendos version should never be uploaded to a lower netdefendos versio...

  • Page 77

    Backup and restore using the webui as an alternative to using scp, the administrator can initiate a backup or restore of the configuration or complete system directly through the webui. The example below illustrates how this is done. Example 2.15. Performing a complete system backup in this example ...

  • Page 78

    To reset the netdefend dfl-210, 260, 260e, 800, 860 and 860e models, hold down the reset button located at the rear of the unit for 10-15 seconds while powering on the unit. After that, release the reset button and the unit will continue to load and startup with its default factory settings. The ip ...

  • Page 79

    2.7.3. Restore to factory defaults chapter 2. Management and maintenance 79.

  • Page 80: Chapter 3. Fundamentals

    Chapter 3. Fundamentals this chapter describes the fundamental logical objects which make up a netdefendos configuration. These objects include such items as ip addresses and ip rules. Some exist by default and some must be defined by the administrator. In addition, the chapter explains the differen...

  • Page 81

    Ip network an ip network is represented using classless inter domain routing (cidr) form. Cidr uses a forward slash and a digit (0-32) to denote the size of the network as a postfix. This is also known as the netmask. /24 corresponds to a class c net with 256 addresses (netmask 255.255.255.0), /27 c...

  • Page 82: 3.1.3. Ethernet Addresses

    This example adds a range of ip addresses from 192.168.10.16 to 192.168.10.21 and names the range wwwservers: command-line interface gw-world:/> add address ip4address wwwservers address=192.168.10.16-192.168.10.21 web interface 1. Go to objects > address book > add > ip address 2. Specify a suitabl...

  • Page 83: 3.1.4. Address Groups

    The following example adds an ethernet address object named wwwsrv1_mac with the numerical mac address 08-a3-67-bc-2e-f2. Command-line interface gw-world:/> add address ethernetaddress wwwsrv1_mac address=08-a3-67-bc-2e-f2 web interface 1. Go to objects > address book > add > ethernet address 2. Spe...

  • Page 84

    3.1.5. Auto-generated address objects to simplify the configuration, a number of address objects in the address book are automatically created by netdefendos when the system starts for the first time and these objects are used in various parts of the initial configuration. The following address obje...

  • Page 85: 3.2. Services

    3.2. Services 3.2.1. Overview a service object is a reference to a specific ip protocol with associated parameters. A service definition is usually based on one of the major transport protocols such as tcp or udp which is associated with a specific source and/or destination port number(s). For examp...

  • Page 86

    Name comments ------------ -------------------------------------------------- all_icmp all icmp services " " web interface 1. Go to objects > services example 3.7. Viewing a specific service to view a specific service in the system: command-line interface gw-world:/> show service servicetcpudp echo ...

  • Page 87

    Let us now take a closer look at tcp/udp services. Tcp and udp based services most applications use tcp and/or udp as transport protocol for transferring data over ip networks. Transmission control protocol (tcp) is a connection-oriented protocol that includes mechanisms for reliable point to point ...

  • Page 88

    Tip: specifying source ports it is usual with many services that the source ports are left as their default value which is the range 0-65535 (corresponding to all possible source ports). With certain application, it can be useful to also specify the source port if this is always within a limited ran...

  • Page 89: 3.2.3. Icmp Services

    To refer to all protocols. However, using this is not recommended and specifying a narrower service provides better security. If, for example, the requirement is only to filter using the principal protocols of tcp, udp and icmp then the service group all_tcpudpicmp can be used instead. Tip: the http...

  • Page 90

    Icmp messages are delivered in ip packets, and includes a message type that specifies the format of the icmp message and a code that is used to further qualify the message. For example, the message type destination unreachable uses the code parameter to specify the exact reason for the error. Either...

  • Page 91: 3.2.5. Service Groups

    3.2.4. Custom ip protocol services services that run over ip and perform application/transport layer functions can be uniquely identified by ip protocol numbers. Ip can carry data for a number of different protocols. These protocols are each identified by a unique ip protocol number specified in a f...

  • Page 92

    Configuration and decrease the ability to troubleshoot problems. 3.2.6. Custom service timeouts any service can have its custom timeouts set. These can also be set globally in netdefendos but it is more usual to change these values individually in a custom service. The timeout settings that can be c...

  • Page 93: 3.3. Interfaces

    3.3. Interfaces 3.3.1. Overview an interface is an important logical building block in netdefendos. All network traffic that transits through, originates from or is terminated in the netdefend firewall, does so through one or more interfaces. Source and destination interfaces an interface can be vie...

  • Page 94

    Tunnel interfaces are used when network traffic is being tunneled between the system and another tunnel end-point in the network, before it gets routed to its final destination. Vpn tunnels are often used to implement virtual private networks (vpns) which can secure communication between two firewal...

  • Page 95: 3.3.2. Ethernet Interfaces

    Should it be desirable to disable an interface so that no traffic can flow through it, this can be done with the cli using the command: gw-world:/> set interface ethernet -disable where is the interface to be disabled. To re-enable an interface, the command is: gw-world:/> set interface ethernet -en...

  • Page 96

    The names of the ethernet interfaces are predefined by the system, and are mapped to the names of the physical interfaces. The names of the ethernet interfaces can be changed to better reflect their usage. For example, if an interface named dmz is connected to a wireless lan, it might be convenient ...

  • Page 97

    All addresses received from the dhcp server are assigned to corresponding ip4address objects. In this way, dynamically assigned addresses can be used throughout the configuration in the same way as static addresses. By default, the objects in use are the same ones as defined in section 3.1.5, “auto-...

  • Page 98

    I. Make the interface a member of all routing tables. This option is enabled by default and means that traffic arriving on the interface will be routed according to the main routing table. Routes for the interface ip will be inserted into all routing tables. Ii. The alternative to the above is to in...

  • Page 99

    The difference between logical and physical interfaces can sometimes be confusing. The logical ethernet interfaces are those which are referred to in a netdefendos configuration. When using the web interface, only the logical interfaces are visible and can be managed. When using the cli, both the lo...

  • Page 100

    Address: 0.0.0.0 userauthgroups: nodefinedcredentials: no comments: default gateway for interface wan by using the tab key at the end of a line, tab completion can be used to complete the command: gw-world:/> show address ip4address interfaceaddresses/wan_ [] [ []]: interfaceaddresses/wan_br interfa...

  • Page 101: 3.3.3. Vlan

    Those interfaces that physically exist but are not part of the configuration are indicated with a minus "-" symbol at the left. These will be deleted after the configuration is activated. If a deleted interface in the interface list is to be restored, this can be done with the undelete command: gw-w...

  • Page 102

    Interfaces on a netdefend firewall need not limit how many totally separated external networks can be connected. Another typical usage of vlans is to group together clients in an organisation so that the traffic belonging to different groups is kept completely separate in different vlans. Traffic ca...

  • Page 103

    Figure 3.1. Vlan connections with netdefendos vlans, the physical connections are as follows: • one of more vlans are configured on a physical netdefend firewall interface and this is connected directly to a switch. This link acts as a vlan trunk. The switch used must support port based vlans. This ...

  • Page 104

    License limitations the number of vlan interfaces that can be defined for a netdefendos installation is limited by the parameters of the license used. Different hardware models have different licenses and different limits on vlans. Summary of vlan setup below are the key steps for setting up a vlan ...

  • Page 105: 3.3.4. Pppoe

    • interface: lan • vlan id: 10 • ip address: vlan10_ip • network: all-nets 3. Click ok 3.3.4. Pppoe point-to-point protocol over ethernet (pppoe) is a tunneling protocol used for connecting multiple users on an ethernet network to the internet through a common serial interface, such as a single dsl ...

  • Page 106

    Source interface. For outbound traffic, the pppoe tunnel interface will be the destination interface. As with any interface, one or more routes are defined so netdefendos knows what ip addresses it should accept traffic from and which to send traffic to through the pppoe tunnel. The pppoe client can...

  • Page 107: 3.3.5. Gre Tunnels

    Pppoe cannot be used with ha for reasons connected with the way ip addresses are shared in a netdefendos high availability cluster, pppoe will not operate correctly. It should there not be configured with ha. Example 3.11. Configuring a pppoe client this example shows how to configure a pppoe client...

  • Page 108

    • tunneling ipv6 traffic across an ipv4 network. • where a udp data stream is to be multicast and it is necessary to transit through a network device which does not support multicasting. Gre allows tunneling though the network device. Gre security and performance a gre tunnel does not use any encryp...

  • Page 109

    • address to use as source ip - it is possible to specify a particular ip address as the source interface ip for the gre tunnel. The tunnel setup will appear to be initiated by this ip address instead of the ip address of the interface that actually sets up the tunnel. This might be done if, for exa...

  • Page 110

    2. Create a gre tunnel object called gre_to_b with the following parameters: • ip address: ip_gre • remote network: remote_net_b • remote endpoint: remote_gw • use session key: 1 • additional encapulation checksum: enabled 3. Define a route in the main routing table which routes all traffic to remot...

  • Page 111: 3.3.6. Interface Groups

    Ipsec tunnels have a status of being either up or not up. With gre tunnels in netdefendos this does not really apply. The gre tunnel is up if it exists in the configuration. However, we can check on the what is going on with a gre tunnel. For example, if the tunnel is called gre_interface then we ca...

  • Page 112: 3.4. Arp

    3.4. Arp 3.4.1. Overview address resolution protocol (arp) allows the mapping of a network layer protocol (osi layer 3) address to a data link layer hardware address (osi layer 2). In data networks it is used to resolve an ip address into its corresponding ethernet address. Arp operates at the osi l...

  • Page 113

    Valid for. For example, the first entry has an expiry value of 45 which means that this entry will be rendered invalid and removed from the arp cache in 45 seconds. If traffic is going to be sent to the 192.168.0.10 ip address after the expiration, netdefendos will issue a new arp request. The defau...

  • Page 114

    Hash tables are used to rapidly look up entries in the arp cache. For maximum efficiency, a hash table should be twice as large as the entries it is indexing, so if the largest directly connected lan contains 500 ip addresses, the size of the arp entry hash table should be at least 1000. The adminis...

  • Page 115

    2. Select the following from the dropdown lists: • mode: static • interface: lan 3. Enter the following: • ip address: 192.168.10.15 • mac: 4b-86-f6-c5-a2-14 4. Click ok published arp objects netdefendos supports publishing ip addresses on a particular interface, optionally along with a specific mac...

  • Page 116

    Figure 3.2. An arp publish ethernet frame the publish option uses the real mac address of the sending interface for the address (1) in the ethernet frame. In rare cases, some network equipment will require that both mac addresses in the response (1 and 2 above) are the same. In this case xpublish is...

  • Page 117

    It is possible for a host on a connected network to send an arp reply to netdefendos even though a corresponding arp request was not issued. This is known as an unsolicited arp reply. According to the arp specification, the recipient should accept these types of arp replies. However, because this co...

  • Page 118

    Arp query no sender handles arp queries that have a sender ip of 0.0.0.0. Such sender ips are never valid in responses, but network units that have not yet learned of their ip address sometimes ask arp questions with an "unspecified" sender ip. Default: droplog arp sender ip determines if the ip sen...

  • Page 119

    Requests. Default: enabled arp expire specifies how long a normal dynamic item in the arp table is to be retained before it is removed from the table. Default: 900 seconds (15 minutes) arp expire unknown specifies in seconds how long netdefendos is to remember addresses that cannot be reached. This ...

  • Page 120

    Arp ip collision determines the behavior when receiving an arp request with a sender ip address that collides with one already used on the receive interface. Possible actions: drop or notify. Default: drop 3.4.5. Arp advanced settings summary chapter 3. Fundamentals 120

  • Page 121: 3.5. Ip Rule Sets

    3.5. Ip rule sets 3.5.1. Security policies before examining ip rule sets in detail, we will first look at the generic concept of security polices to which ip rule sets belong. Security policy characteristics netdefendos security policies are configured by the administrator to regulate the way in whi...

  • Page 122

    These rules determine the routing table to be used by traffic and are described in section 4.3, “policy-based routing”. • authentication rules these determine which traffic triggers authentication to take place (source net/interface only) and are described in chapter 8, user authentication. Ip rules...

  • Page 123

    Creating a drop all rule traffic that does not match any rule in the ip rule set is, by default, dropped by netdefendos. For logging purposes it is nevertheless recommended that an explicit ip rule with an action of drop for all source/destination networks/interfaces, and with logging enabled, is pl...

  • Page 124: 3.5.2. Ip Rule Evaluation

    This description of traffic flow is an extremely simplified version of the full flow description found in section 1.3, “netdefendos state engine packet flow”. For example, before the route lookup is done, netdefendos first checks that traffic from the source network should, in fact, be arriving on t...

  • Page 125: 3.5.3. Ip Rule Actions

    Rule. 3.5.3. Ip rule actions a rule consists of two parts: the filtering parameters and the action to take if there is a match with those parameters. As described above, the parameters of any netdefendos rule, including ip rules are: • source interface • source network • destination interface • dest...

  • Page 126

    Using reject in certain situations the reject action is recommended instead of the drop action because a "polite" reply is required from netdefendos. An example of such a situation is when responding to the ident user identification protocol. Some applications will pause for a timeout if drop is use...

  • Page 127

    Configuration changes must be saved by then issuing an activate followed by a commit command. Web interface 1. Go to rules > ip rules > add > iprule 2. Specify a suitable name for the rule, for example lan_http 3. Now enter: • name: a suitable name for the rule. For example lan_http • action: allow ...

  • Page 128

    A simple example as an example, consider the ip rule set main which contains just two rules to allow web surfing from an internal network and a third drop-all rule to catch any other traffic so that it can be logged: note the screen images used in this example show just the first few columns of the ...

  • Page 129

    A group editing dialog will be displayed which allows two functions: • specify the title the title of the group can be any text that is required and can contain new lines as well as empty lines. There is also no requirement that the group name is unique since it is used purely as a label. • change t...

  • Page 130

    If an object precedes a group or is in any position other than immediately following the group, then this is done in a multi-step process: i. Right click the object and select the move to option. Ii. Enter the index of the position immediately following the target group. Iii. After the object has be...

  • Page 131: 3.6. Schedules

    3.6. Schedules in some scenarios, it might be useful to control not only what functionality is enabled, but also when that functionality is being used. For instance, the it policy of an enterprise might stipulate that web traffic from a certain department is only allowed access outside that departme...

  • Page 132

    Example 3.17. Setting up a time-scheduled policy this example creates a schedule object for office hours on weekdays, and attaches the object to an ip rule that allows http traffic. Command-line interface gw-world:/> add scheduleprofile officehours mon=8-17 tue=8-17 wed=8-17 thu=8-17 fri=8-17 now cr...

  • Page 133: 3.7. Certificates

    3.7. Certificates 3.7.1. Overview x.509 netdefendos supports digital certificates that comply with the itu-t x.509 standard. This involves the use of an x.509 certificate hierarchy with public-key cryptography to accomplish key distribution and entity authentication. References in this manual to a c...

  • Page 134

    Validity time a certificate is not valid forever. Each certificate contains the dates between which the certificate is valid. When this validity period expires, the certificate can no longer be used, and a new certificate has to be issued. Important make sure the netdefendos date and time are set co...

  • Page 135

    There are two types of certificates that can be uploaded: self-signed certificates and remote certificates belonging to a remote peer or ca server. Self-signed certificates can be generated by using one of a number of freely available utilities for doing this. Example 3.18. Uploading a certificate t...

  • Page 136

    • take out the relevant parts of the .Pem file to form the required .Cer and .Key files. The detailed steps for the above stages are as follows: 1. Create the gateway certificate on the windows ca server and export it to a .Pfx file on the local netdefendos management workstation disk. 2. Now conver...

  • Page 137: 3.8. Date And Time

    3.8. Date and time 3.8.1. Overview correctly setting the date and time is important for netdefendos to operate properly. Time scheduled policies, auto-update of the idp and anti-virus databases, and other product features such as digital certificates require that the system clock is accurately set. ...

  • Page 138: 3.8.3. Time Servers

    The world is divided up into a number of time zones with greenwich mean time (gmt) in london at zero longitude being taken as the base time zone. All other time zones going east and west from zero longitude are taken as being gmt plus or minus a given integer number of hours. All locations counted a...

  • Page 139

    The hardware clock which netdefendos uses can sometimes become fast or slow after a period of operation. This is normal behavior in most network and computer equipment and is solved by utilizing time servers. Netdefendos is able to adjust the clock automatically based on information received from on...

  • Page 140

    3. Now enter: • time server type: sntp • primary time server: dns:ntp1.Sp.Se • secondary time server: dns:ntp2.Sp.Se 4. Click ok the time server urls must have the prefix dns: to specify that they should be resolved with a dns server. Netdefendos must therefore also have a dns server defined so this...

  • Page 141

    Sometimes it might be necessary to override the maximum adjustment. For example, if time synchronization has just been enabled and the initial time difference is greater than the maximum adjust value. It is then possible to manually force a synchronization and disregard the maximum adjustment parame...

  • Page 142

    Time zone offset in minutes. Default: 0 dst offset daylight saving time offset in minutes. Default: 0 dst start date what month and day dst starts, in the format mm-dd. Default: none dst end date what month and day dst ends, in the format mm-dd. Default: none time sync server type type of server for...

  • Page 143

    Maximum time drift in seconds that a server is allowed to adjust. Default: 600 group interval interval according to which server responses will be grouped. Default: 10 3.8.4. Settings summary for date and time chapter 3. Fundamentals 143.

  • Page 144: 3.9. Dns

    3.9. Dns overview a dns server can resolve a fully qualified domain name (fqdn) into the corresponding numeric ip address. Fqdns are unambiguous textual domain names which specify a node's unique position in the internet's dns tree hierarchy. Fqdn resolution allows the actual physical ip address to ...

  • Page 145

    Dynamic dns a dns feature offered by netdefendos is the ability to explicitly inform dns servers when the external ip address of the netdefend firewall has changed. This is sometimes referred to as dynamic dns and is useful where the netdefend firewall has an external ip address that can change. Dyn...

  • Page 146

    3.9. Dns chapter 3. Fundamentals 146.

  • Page 147: Chapter 4. Routing

    Chapter 4. Routing this chapter describes how to configure ip routing in netdefendos. • overview, page 147 • static routing, page 148 • policy-based routing, page 165 • route load balancing, page 170 • ospf, page 176 • multicast routing, page 199 • transparent mode, page 212 4.1. Overview ip routing...

  • Page 148: 4.2. Static Routing

    4.2. Static routing the most basic form of routing is known as static routing. The word "static" refers to the fact that entries in the routing table are manually added and are therefore permanent (or static) by nature. Due to this manual approach, static routing is most appropriate to use in smalle...

  • Page 149

    This parameter usually does not need to be specified. If it is specified, netdefendos responds to arp queries sent to this address. A special section below explains this parameter in more depth. Local ip address and gateway are mutually exclusive and either one or the other should be specified. • me...

  • Page 150

    Route # interface destination gateway 4 wan all-nets 195.66.77.4 the above routing table provides the following information: • route #1 all packets going to hosts on the 192.168.0.0/24 network should be sent out on the lan interface. As no gateway is specified for the route entry, the host is assume...

  • Page 151

    Communicate with the netdefend firewall because arp won't function between the clients and the interface. To solve this problem we would add a new route to netdefendos which would have the following parameters: • interface: the interface on which the second network is found. • network: the ip addres...

  • Page 152: 4.2.2. Static Routing

    Switch which imposes no controls on traffic passing between those networks. Caution should therefore be exercised before using this feature. All traffic must have two associated routes something that is not intuitive when trying to understand routing in netdefendos is the fact that all traffic must ...

  • Page 153

    ==================================================================== interface list 0x1 ........................... Ms tcp loopback interface 0x10003 ...00 13 d4 51 8d dd ...... Intel(r) pro/1000 ct network 0x20004 ...00 53 45 00 00 00 ...... Wan (ppp/slip) interface ================================...

  • Page 154

    Displaying routing tables it is important to note that routing tables that are initially configured by the administrator can have routes added, deleted and changed automatically during live operation and these changes will appear when the routing table contents are displayed. These routing table cha...

  • Page 155

    Route in the main routing table for each physical interface. These routes are assigned a default ip address object in the address book and these ip objects must have their addresses changed to the appropriate range for traffic to flow. Note: the metric for default routes is 100 the metric assigned t...

  • Page 156: 4.2.3. Route Failover

    This example illustrates how to display the core routes in the active routing table. Command-line interface gw-world:/> routes -all flags network iface gateway local ip metric ----- ------------------ ---------- ------------- -------- ------ 127.0.0.1 core (shared ip) 0 192.168.0.1 core (iface ip) 0...

  • Page 157

    Figure 4.3. A route failover scenario for isp access setting up route failover to set up route failover, route monitoring must be enabled and this is an option that is enabled on a route by route basis. To enable route failover in a scenario with a preferred and a backup route, the preferred route w...

  • Page 158

    Lowest metric value for sending data (if two routes have the same metric, the route found first in the routing table will be chosen). A primary, preferred route should have a lower metric (for example "10"), and a secondary, failover route should have a higher metric value (for example "20"). Multip...

  • Page 159

    The routing table consequently contains the following default route: interface destination gateway metric monitoring wan all-nets 195.66.77.1 10 off now a secondary route is added over a backup dsl connection and route monitoring is enabled for this. The updated routing table will look like this: ro...

  • Page 160

    As part of route properties host monitoring can be enabled and a single route can have multiple hosts associated with it for monitoring. Multiple hosts can provide a higher certainty that any network problem resides in the local network rather than because one remote host itself is down. In associat...

  • Page 161

    The reachability required option an important option that can be enabled for a host is the reachability required option. When this is selected, the host must be determined as accessible in order for that route to be considered to be functioning. Even if other hosts are accessible, this option says t...

  • Page 162: 4.2.6. Proxy Arp

    Ping poll interval the time in milliseconds between sending a ping to hosts. Default: 1000 grace time the length of time in seconds between startup or reconfigure and monitoring start. Default: 30 consecutive fails the number of consecutive failures that occurs before a route is marked as being unav...

  • Page 163

    Pretending to be the target host. After receiving the reply, host a then sends data directly to netdefendos which forwards the data to host b. In the process netdefendos checks the traffic against the configured rule sets. Setting up proxy arp setting up proxy arp is done by specifying the option fo...

  • Page 164

    Proxy arp and high availability clusters in ha clusters, switch routes cannot be used and transparent mode is therefore not an option. However, proxy arp does function with ha and is consequently the only way to implement transparent mode functionality with a cluster. Not all interfaces can make use...

  • Page 165: 4.3. Policy-Based Routing

    4.3. Policy-based routing 4.3.1. Overview policy-based routing (pbr) is an extension to the standard routing described previously. It offers administrators significant flexibility in implementing routing decision policies by being able to define rules so alternative routing tables are used. Normal r...

  • Page 166

    When looking up policy-based rules, it is the first matching rule found that is triggered. 4.3.4. Routing table selection when a packet corresponding to a new connection first arrives, the processing steps are as follows to determine which routing table is chosen: 1. The routing rules must first be ...

  • Page 167

    Important: ensure all-nets appears in the main table a common mistake with policy-based routing is the absence of the default route with a destination interface of all-nets in the default main routing table. If there is no route that is an exact match then the absence of a default all-nets route wil...

  • Page 168

    Example 4.5. Policy-based routing configuration this example illustrates a multiple isp scenario which is a common use of policy-based routing. The following is assumed: • each isp will provide an ip network from its network range. A 2 isp scenario is assumed in this case, with the network 10.10.10....

  • Page 169

    Note rules in the above example are added for both inbound and outbound connections. 4.3.5. The ordering parameter chapter 4. Routing 169.

  • Page 170: 4.4. Route Load Balancing

    4.4. Route load balancing overview netdefendos provides the option to perform route load balancing (rlb). This is the ability to distribute traffic over multiple alternate routes using one of a number of distribution algorithms. The purpose of this feature is to provide the following: • balancing of...

  • Page 171

    Done according to which algorithm is selected in the table's rlb instance object: • round robin successive routes are chosen from the matching routes in a "round robin" fashion provided that the metric of the routes is the same. This results in route lookups being spread evenly across matching route...

  • Page 172

    Figure 4.6. The rlb spillover algorithm spillover limits are set separately for ingoing and outgoing traffic with only one of these typically being specified. If both are specified then only one of them needs to be exceeded continuously for hold timer seconds for the next matching route to be chosen...

  • Page 173

    When that new route's interface limits are also exceeded then the route with the next highest metric is taken and so on. As soon as any route with a lower metric falls below its interface limit for its hold timer number of seconds, then it reverts to being the chosen route. • if there is no alternat...

  • Page 174

    Figure 4.7. A route load balancing scenario we first need to define two routes to these two isps in the main routing table as shown below: route no. Interface destination gateway metric 1 wan1 all-nets gw1 100 2 wan2 all-nets gw2 100 we will not use the spillover algorithm in this example so the rou...

  • Page 175

    In this example, the details of the rlb scenario described above will be implemented. The assumption is made that the various ip address book objects needed have already been defined. The ip objects wan1 and wan2 represent the interfaces that connect to the two isps and the ip objects gw1 and gw2 re...

  • Page 176: 4.5. Ospf

    4.5. Ospf the feature called dynamic routing is implemented with netdefendos using the ospf architecture. This section begins by looking generally at what dynamic routing is and how it can be implemented. It then goes on to look at how ospf can provide dynamic routing followed by a description of ho...

  • Page 177

    Each router broadcasts its attached links and link costs to all other routers in the network. When a router receives these broadcasts it runs the ls algorithm and calculates its own set of least-cost paths. Any change of the link state will be sent everywhere in the network, so that all routers keep...

  • Page 178

    Allows b's routing table information to be automatically shared with a. In the same way, ospf allows firewall b to automatically become aware that network x is attached to firewall a. Under ospf, this exchange of routing information is completely automatic. Ospf provides route redundancy if we now t...

  • Page 179: 4.5.2. Ospf Concepts

    Routing metrics are the criteria that a routing algorithm will use to compute the "best" route to a destination. A routing protocol relies on one or several metrics to evaluate links across a network and to determine the optimal path. The principal metrics used include: path length the sum of the co...

  • Page 180

    Authentication. All ospf protocol exchanges can, if required, be authenticated. This means that only routers with the correct authentication can join an as. Different authentication schemes can be used and with netdefendos the scheme can be either a passphrase or an md5 digest. It is possible to con...

  • Page 181

    The priorities advertised by all the routers. If there is already a dr on the network, the router will accept that one, regardless of its own router priority. With netdefendos, the dr and the bdr are automatically assigned. Neighbors routers that are in the same area become neighbors in that area. N...

  • Page 182

    This virtual link is established between two area border routers (abrs) that are on one common area, with one of the abrs connected to the backbone area. In the example below two routers are connected to the same area (area 1) but just one of them, fw1, is connected physically to the backbone area. ...

  • Page 183

    Figure 4.11. Virtual links with partitioned backbone the virtual link is configured between fw1 and fw2 on area 1 as it is used as the transit area. In the configuration, only the router id has to be configured, as in the example above show fw2 need to have a virtual link to fw1 with the router id 1...

  • Page 184: 4.5.3. Ospf Components

    The key aspect of an ospf setup is that connected netdefend firewalls share the information in their routing tables so that traffic entering an interface on one of the firewalls can be automatically routed so that it exits the interface on another gateway which is attached to the correct destination...

  • Page 185

    Not the cluster. Note when running ospf on a ha cluster there is a need for a private master and private slave router id as well as the shared router id. Reference bandwidth set the reference bandwidth that is used when calculating the default interface cost for routes. If bandwidth is used instead ...

  • Page 186

    Note: authentication must be the same on all routers if a passphrase or md5 authentication is configured for ospf, the passphrase or authentication key must be the same on all ospf routers in that autonomous system. In other words, the ospf authentication method must be replicated on all netdefend f...

  • Page 187

    There can only be one backbone area and it forms the central portion of an as. Routing information that is exchanged between different area always transits the backbone area. Is stub area enable this option if the area is a stub area. Become default router it is possible to configure if the firewall...

  • Page 188

    An ospf neighbour object. Using vpn tunnels is discussed further in section 4.5.5, “setting up ospf”. • point-to-multipoint - the point-to-multipoint interface type is a collection of point-to-point networks, where there is more then one router in a link that does not have osi layer 2 broadcast/mult...

  • Page 189

    Sometimes there is a need to include networks into the ospf routing process, without running ospf on the interface connected to that network. This is done by enabling the option: no ospf routers connected to this interface ("passive"). This is an alternative to using a dynamic routing policy to impo...

  • Page 190

    Authentication use default for as use the values configured in the as properties page. Note: linking partitioned backbones if the backbone area is partitioned, a virtual link is used to connect the different parts. In most, simple ospf scenarios, ospf vlink objects will not be needed. 4.5.4. Dynamic...

  • Page 191

    Ospf requires at least an import rule by default, netdefendos will not import or export any routes. For ospf to function, it is therefore mandatory to define at least one dynamic routing rule which will be an import rule. This import rule specifies the local ospf router process object. This enables ...

  • Page 192

    From ospf as specifies the from which ospf as (in other words, an ospf router process) the route should be imported from into either a routing table or another as. From routing table specifies from which routing table a route should be imported into the ospf as or copied into another routing table. ...

  • Page 193: 4.5.5. Setting Up Ospf

    A routing action is used to manipulate and export routing changes to one or more local routing tables. Destination specifies into which routing table the route changes to the ospf as should be imported. Offset metric increases the metric by this value. Offset metric type 2 increases the type 2 route...

  • Page 194

    • the advanced option no ospf routers connected to this interface must be enabled if the physical interface does not connect directly to another ospf router (in other words, with another netdefend firewall that acts as an ospf router). For example, the interface may only be connected to a network of...

  • Page 195

    Ospf routing information exchange begins automatically as the new configurations are created in the above steps and then deployed, ospf will automatically start and begin exchanging routing information. Since ospf is a dynamic and distributed system, it does not matter in which order the configurati...

  • Page 196: 4.5.6. An Ospf Example

    This network is used just as a convenience with ospf setup and will never be associated with a real physical network. 3. Define an ospf interface for the tunnel define an netdefendos ospf interface object which has the ipsec tunnel for the interface parameter. Specify the type parameter to be point-...

  • Page 197

    Example 4.7. Creating an ospf router process on the first firewall involved in the ospf as, create an ospf router process. Web interface 1. Go to routing > ospf > add > ospf routing process 2. Specify a suitable name for the process, for example as_0 3. Click ok this should be repeated for all the n...

  • Page 198

    Web interface 1. Go to routing > dynamic routing rules > add > dynamic routing policy rule 2. Specify a suitable name for the rule. For example, importospfroutes. 3. Select the option from ospf process 4. Move as0 from available to selected 5. Choose all-nets in the ...Or is within filter option 6. ...

  • Page 199: 4.6. Multicast Routing

    4.6. Multicast routing 4.6.1. Overview the multicast problem certain types of internet interactions, such as conferencing and video broadcasts, require a single client or host to send the same packet to multiple receivers. This could be achieved through the sender duplicating the packet with differe...

  • Page 200

    4.6.2. Multicast forwarding with sat multiplex rules the sat multiplex rule is used to achieve duplication and forwarding of packets through more than one interface. This feature implements multicast forwarding in netdefendos, where a multicast packet is sent through several interfaces. Note that si...

  • Page 201

    Figure 4.14. Multicast forwarding - no address translation note: sat multiplex rules must have a matching allow rule remember to add an allow rule that matches the sat multiplex rule. The matching rule could also be a nat rule for source address translation (see below) but cannot be a fwdfast or sat...

  • Page 202

    B. Create an ip rule: 1. Go to rules > ip rules > add > ip rule 2. Under general enter. • name: a name for the rule, for example multicast_multiplex • action: multiplex sat • service: multicast_service 3. Under address filter enter: • source interface: wan • source network: 192.168.10.1 • destinatio...

  • Page 203

    Figure 4.15. Multicast forwarding - address translation this scenario is based on the previous scenario but this time the multicast group is translated. When the multicast streams 239.192.10.0/24 are forwarded through the if2 interface, the multicast groups should be translated into 237.192.10.0/24....

  • Page 204: 4.6.3. Igmp Configuration

    • action: multiplex sat • service: multicast_service 3. Under address filter enter: • source interface: wan • source network: 192.168.10.1 • destination interface: core • destination network: 239.192.10.0/24 4. Click the multiplex sat tab 5. Add interface if1 but leave the ipaddress empty 6. Add int...

  • Page 205

    Figure 4.16. Multicast snoop mode figure 4.17. Multicast proxy mode in snoop mode, the netdefend firewall will act transparently between the hosts and another igmp router. It will not send any igmp queries. It will only forward queries and reports between the other router and the hosts. In proxy mod...

  • Page 206

    Example 4.14. Igmp - no address translation the following example requires a configured interface group ifgrpclients including interfaces if1, if2 and if3. The ip address of the upstream igmp router is known as upstreamrouterip. Two rules are needed. The first one is a report rule that allows the cl...

  • Page 207

    4.6.3.2. Igmp rules configuration - address translation the following examples illustrates the igmp rules needed to configure igmp according to the address translation scenario described above in section 4.6.2.2, “multicast forwarding - address translation scenario”. We need two igmp report rules, o...

  • Page 208

    • destination network: auto • multicast source: 192.168.10.1 • multicast group: 239.192.10.0/24 4. Click ok example 4.16. If2 configuration - group translation the following steps needs to be executed to create the report and query rule pair for if2 which translates the multicast group. Note that th...

  • Page 209

    • multicast source: 192.168.10.1 • multicast group: 239.192.10.0/24 4. Click ok advanced igmp settings there are a number of igmp advanced settings which are global and apply to all interfaces which do not have igmp settings explicitly specified for them. 4.6.4. Advanced igmp settings auto add multi...

  • Page 210

    Group-and-source specific query. Global setting on interfaces without an overriding igmp setting. Default: 5,000 igmp max total requests the maximum global number of igmp messages to process each second. Default: 1000 igmp max interface requests the maximum number of requests per interface and secon...

  • Page 211

    The time in milliseconds between repetitions of an initial membership report. Global setting on interfaces without an overriding igmp setting. Default: 1,000 4.6.4. Advanced igmp settings chapter 4. Routing 211.

  • Page 212: 4.7. Transparent Mode

    4.7. Transparent mode 4.7.1. Overview transparent mode usage the netdefendos transparent mode feature allows a netdefend firewall to be placed at a point in a network without any reconfiguration of the network and without hosts being aware of its presence. All netdefendos features can then be used t...

  • Page 213

    The osi model. If the firewall is placed into a network for the first time, or if network topology changes, the routing configuration must therefore be checked and adjusted to ensure that the routing table is consistent with the new layout. Reconfiguration of ip settings may be required for pre-exis...

  • Page 214

    The network. Discovery is done by netdefendos sending out arp as well as icmp (ping) requests, acting as the initiating sender of the original ip packet for the destination on the interfaces specified in the switch route. If an arp reply is received, netdefendos will update the cam table and layer 3...

  • Page 215

    Routing table will be connected together by netdefendos and no matter how interfaces are associated with the switch routes, transparency will exist between them. For example, if the interfaces if1 to if6 appear in a switch routes in routing table a, the resulting interconnections will be as illustra...

  • Page 216

    Mode. Two vlan interfaces with the same vlan id are defined on the two physical interfaces and they are called vlan5_if1 and vlan5_if2. For the vlan to operate in transparent mode we create a routing table with the ordering set to only and which contains the following 2 switch routes: network interf...

  • Page 217

    • configure dhcp relay to the dhcp server ip address 255.255.255.255. 4.7.2. Enabling internet access a common misunderstanding when setting up transparent mode is how to correctly set up access to the public internet. Below is a typical scenario where a number of users on an ip network called lanne...

  • Page 218

    Netdefendos may also need internet access the netdefend firewall also needs to find the public internet if it is to perform netdefendos functions such as dns lookup, web content filtering or anti-virus and idp updating. To allow this, individual "normal" non-switch routes need to be set up in the ro...

  • Page 219

    Figure 4.20. Transparent mode scenario 1 example 4.17. Setting up transparent mode for scenario 1 web interface configure the interfaces: 1. Go to interfaces > ethernet > edit (wan) 2. Now enter: • ip address: 10.0.0.1 • network: 10.0.0.0/24 • default gateway: 10.0.0.1 • transparent mode: enable 3. ...

  • Page 220

    • source interface: lan • destination interface: any • source network: 10.0.0.0/24 • destination network: all-nets (0.0.0.0/0) 3. Click ok scenario 2 here the netdefend firewall in transparent mode separates server resources from an internal network by connecting them to a separate interface without...

  • Page 221

    1. Go to interfaces > ethernet > edit (lan) 2. Now enter: • ip address: 10.0.0.1 • network: 10.0.0.0/24 • transparent mode: disable • add route for interface network: disable 3. Click ok 4. Go to interfaces > ethernet > edit (dmz) 5. Now enter: • ip address: 10.0.0.2 • network: 10.0.0.0/24 • transpa...

  • Page 222

    3. Click ok 4. Go to rules > ip rules > add > iprule 5. Now enter: • name: http-wan-to-dmz • action: sat • service: http • source interface: wan • destination interface: dmz • source network: all-nets • destination network: wan_ip • translate: select destination ip • new ip address: 10.1.4.10 6. Cli...

  • Page 223

    Figure 4.22. An example bpdu relaying scenario implementing bpdu relaying the netdefendos bdpu relaying implementation only carries stp messages. These stp messages can be of three types: • normal spanning tree protocol (stp) • rapid spanning tree protocol (rstp) • multiple spanning tree protocol (m...

  • Page 224

    Default: enabled decrement ttl enable this if the ttl should be decremented each time a packet traverses the firewall in transparent mode. Default: disabled dynamic cam size this setting can be used to manually configure the size of the cam table. Normally dynamic is the preferred value to use. Defa...

  • Page 225

    Null enet sender defines what to do when receiving a packet that has the sender hardware (mac) address in ethernet header set to null (0000:0000:0000). Options: • drop - drop packets • droplog - drop and log packets default: droplog broadcast enet sender defines what to do when receiving a packet th...

  • Page 226

    • drop - drop the packets • droplog - drop packets log the event default: drop relay mpls when set to ignore all incoming mpls packets are relayed in transparent mode. Options: • ignore - let the packets pass but do not log • log - let the packets pass and log the event • drop - drop the packets • d...

  • Page 227

    4.7.5. Advanced settings for transparent mode chapter 4. Routing 227.

  • Page 228: Chapter 5. Dhcp Services

    Chapter 5. Dhcp services this chapter describes dhcp services in netdefendos. • overview, page 228 • dhcp servers, page 229 • dhcp relaying, page 235 • ip pools, page 238 5.1. Overview dynamic host configuration protocol (dhcp) is a protocol that allows network administrators to automatically assign...

  • Page 229: 5.2. Dhcp Servers

    5.2. Dhcp servers dhcp servers assign and manage the ip addresses taken from a specified address pool. In netdefendos, dhcp servers are not limited to serving a single range of ip addresses but can use any ip address range that can be specified by a netdefendos ip address object. Multiple dhcp serve...

  • Page 230

    The following options can be configured for a dhcp server: general parameters name a symbolic name for the server. Used as an interface reference but also used as a reference in log messages. Interface filter the source interface on which netdefendos will listen for dhcp requests. This can be a sing...

  • Page 231

    This example shows how to set up a dhcp server called dhcpserver1 which assigns and manages ip addresses from an ip address pool called dhcprange1. This example assumes that an ip range for the dhcp server has already been created. Command-line interface gw-world:/> add dhcpserver dhcpserver1 interf...

  • Page 232: 5.2.1. Static Dhcp Hosts

    The asterisk "*" before a mac address means that the dhcp server does not track the client using the mac address but instead tracks the client through a client identifier which the client has given to the server. Tip: lease database saving dhcp leases are, by default, remembered by netdefendos betwe...

  • Page 233: 5.2.2. Custom Options

    Can be specified as this parameter. The option exists to also specify if the identifier will be sent as an ascii or hexadecimal value. Example 5.3. Static dhcp host assignment this example shows how to assign the ip address 192.168.1.1 to the mac address 00-90-12-13-14-15. The examples assumes that ...

  • Page 234

    Custom option parameters the following parameters can be set for a custom option: code this is the code that describes the type of information being sent to the client. A large list of possible codes exists. Type this describes the type of data which will be sent. For example, if the type is string ...

  • Page 235: 5.3. Dhcp Relaying

    5.3. Dhcp relaying the dhcp problem with dhcp, clients send requests to locate the dhcp server(s) using broadcast messages. However, broadcasts are normally only propagated across the local network. This means that the dhcp server and client always need to be on the same physical network. In a large...

  • Page 236

    • name: ipgrp-dhcp • interfaces: select vlan1 and vlan2 from the available list and put them into the selected list. 3. Click ok adding a dhcp relayer called as vlan-to-dhcpserver: 1. Go to system > dhcp > add > dhcp relay 2. Now enter: • name: vlan-to-dhcpserver • action: relay • source interface: ...

  • Page 237

    Will be reduced down to this value. Default: 10000 seconds max auto routes how many relays that can be active at the same time. Default: 256 auto save policy what policy should be used to save the relay list to the disk, possible settings are disabled, reconfshut, or reconfshuttimer. Default: reconf...

  • Page 238: 5.4. Ip Pools

    5.4. Ip pools overview an ip pool is used to offer other subsystems access to a cache of dhcp ip addresses. These addresses are gathered into a pool by internally maintaining a series of dhcp clients (one dhcp client per ip address). More than one dhcp server can be used by a pool and can either be ...

  • Page 239

    Receive interface a "simulated" virtual dhcp server receiving interface. This setting is used to simulate a receiving interface when an ip pool is obtaining ip addresses from internal dhcp servers. This is needed since the filtering criteria of a dhcp server includes a receive interface. An internal...

  • Page 240

    Other options in the ippool command allow the administrator to change the pool size and to free up ip addresses. The complete list of command options can be found in the cli reference guide. Example 5.5. Creating an ip pool this example shows the creation of an ip pool object that will use the dhcp ...

  • Page 241

    5.4. Ip pools chapter 5. Dhcp services 241.

  • Page 242: 6.1. Access Rules

    Chapter 6. Security mechanisms this chapter describes netdefendos security features. • access rules, page 242 • algs, page 245 • web content filtering, page 297 • anti-virus scanning, page 314 • intrusion detection and prevention, page 320 • denial-of-service attack prevention, page 332 • blacklisti...

  • Page 243: 6.1.2. Ip Spoofing

    6.1.2. Ip spoofing traffic that pretends it comes from a trusted host can be sent by an attacker to try and get past a firewall's security mechanisms. Such an attack is commonly known as spoofing. Ip spoofing is one of the most common spoofing attacks. Trusted ip addresses are used to bypass filteri...

  • Page 244

    If, for some reason, the default access rule log message is continuously being generated by some source and needs to be turned off, then the way to do this is to specify an access rule for that source with an action of drop. Troubleshooting access rule related problems it should be noted that access...

  • Page 245: 6.2. Algs

    6.2. Algs 6.2.1. Overview to complement low-level packet filtering, which only inspects packet headers in protocols such as ip, tcp, udp, and icmp, netdefend firewalls provide application layer gateways (algs) which provide filtering at the higher application osi level. An alg object acts as a media...

  • Page 246: 6.2.2. The Http Alg

    Maximum connection sessions the service associated with an alg has a configurable parameter associated with it called max sessions and the default value varies according to the type of alg. For instance, the default value for the http alg is 1000. This means that a 1000 connections are allowed in to...

  • Page 247

    Anti-virus scanning, if it is enabled, is always applied to the http traffic even if it is whitelisted. These features are described in depth in section 6.3.3, “static content filtering”. • dynamic content filtering - access to specific urls can be allowed or blocked according to policies for certai...

  • Page 248

    Note: similarities with other netdefendos features the verify mime type and allow/block selected types options work in the same way for the ftp, pop3 and smtp algs. • download file size limit - a file size limit can additionally be specified for any single download (this option is only available for...

  • Page 249: 6.2.3. The Ftp Alg

    Equivalent to a large number of possible urls. The wildcard character "*" can be used to represent any sequence of characters. For example, the entry *.Some_domain.Com will block all pages whose urls end with some_domain.Com. If we want to now explicitly allow one particular page then this can be do...

  • Page 250

    Consider a scenario where an ftp client on the internal network connects through the firewall to an ftp server on the internet. The ip rule is then configured to allow network traffic from the ftp client to port 21 on the ftp server. When active mode is used, netdefendos does not know that the ftp s...

  • Page 251

    Figure 6.3. Ftp alg hybrid mode note: hybrid conversion is automatic hybrid mode does not need to enabled. The conversion between modes occurs automatically within the ftp alg. Connection restriction options the ftp alg has two options to restrict which type of mode the ftp client and the ftp server...

  • Page 252

    • allow the site exec command to be sent to an ftp server by a client. • allow the resume command even if content scanning terminated the connection. Note: some commands are never allowed some commands, such as encryption instructions, are never allowed. Encryption would mean that the ftp command ch...

  • Page 253

    The netdefendos anti-virus subsystem can be enabled to scan all ftp downloads searching for malicious code. Suspect files can be de dropped or just logged. This feature is common to a number of algs and is described fully in section 6.4, “anti-virus scanning”. Ftp alg with zonedefense used together ...

  • Page 254

    In this case, we will set the ftp alg restrictions as follows. • enable the allow client to use active mode ftp alg option so clients can use both active and passive modes. • disable the allow server to use passive mode ftp alg option. This is more secure for the server as it will never receive pass...

  • Page 255

    • alg: select ftp-inbound created above 3. Click ok c. Define a rule to allow connections to the public ip on port 21 and forward that to the internal ftp server: 1. Go to rules > ip rules > add > iprule 2. Now enter: • name: sat-ftp-inbound • action: sat • service: ftp-inbound-service 3. For addres...

  • Page 256

    • source interface: any • destination interface: core • source network: all-nets • destination network: wan_ip 4. Click ok example 6.3. Protecting ftp clients in this scenario shown below the netdefend firewall is protecting a workstation that will connect to ftp servers on the internet. In this cas...

  • Page 257

    2. Enter name: ftp-outbound 3. Uncheck allow client to use active mode 4. Check allow server to use passive mode 5. Click ok b. Create the service 1. Go to objects > services > add > tcp/udp service 2. Now enter: • name: ftp-outbound-service • type: select tcp from the dropdown list • destination: 2...

  • Page 258: 6.2.4. The Tftp Alg

    • destination interface: wan • source network: lannet • destination network: all-nets 4. Check use interface address 5. Click ok setting up ftp servers with passive mode an important point about ftp server setup needs to be made if the ftp alg is being used along with passive mode. Usually, the ftp ...

  • Page 259: 6.2.5. The Smtp Alg

    Tftp request options as long as the remove request option described above is set to false (options are not removed) then the following request option settings can be applied: maximum blocksize the maximum blocksize allowed can be specified. The allowed range is 0 to 65,464 bytes. The default value i...

  • Page 260

    The administrator should therefore add a reasonable margin above the anticipated email size when setting this limit. Email address blacklisting a blacklist of sender or recipient email addresses can be specified so that mail from/to those addresses is blocked. The blacklist is applied after the whit...

  • Page 261

    Figure 6.4. Smtp alg processing order using wildcards in white and blacklists entries made in the white and blacklists can make use of wildcarding to have a single entry cover a large number of potential email addresses. The wildcard character "*" can be used to represent any sequence of characters....

  • Page 262

    Capa=pipelining to indicate that the pipelining extension was removed from the smtp server reply to an ehlo client command. Although esmtp extensions may be removed by the alg and related log messages generated, this does not mean that any emails are dropped. Email transfers will take place as usual...

  • Page 263

    • dropping email which has a very high probability of being spam. • letting through but flagging email that has a moderate probability of being spam. The netdefendos anti-spam implementation smtp functions as a protocol for sending emails between servers. Netdefendos applies spam filtering to emails...

  • Page 264

    Servers are queried to assess the likelihood that the email is spam, based on its origin address. The netdefendos administrator assigns a weight greater than zero to each configured server so that a weighted sum can then be calculated based on all responses. The administrator can configure one of th...

  • Page 265

    And this is what the email's recipient will see in the summary of their inbox contents. The individual user could then decide to set up their own filters in the local client to deal with such tagged emails, possibly sending it to a separate folder. Adding x-spam information if an email is determined...

  • Page 266

    Logging there are three types of logging done by the spam filtering module: • logging of dropped or spam tagged emails - these log messages include the source email address and ip as well as its weighted points score and which dnsbls caused the event. • dnsbls not responding - dnsbl query timeouts a...

  • Page 267

    For the dnsbl subsystem overall: • number of emails checked. • number of emails spam tagged. • number of dropped emails. For each dnsbl server accessed: • number of positive (is spam) responses from each configured dnsbl server. • number of queries sent to each configured dnsbl server. • number of f...

  • Page 268: 6.2.6. The Pop3 Alg

    Blacklist: zen.Spamhaus.Org status : active weight value : 25 number of mails checked : 56 number of matches in list : 3 number of failed checks (times disabled) : 0 to clean out the dnsbl cache for my_smtp_alg and to reset all its statistical counters, the following command option can be used: gw-w...

  • Page 269: 6.2.7. The Pptp Alg

    Can be dropped or just logged. This feature is common to a number of algs and is described fully in section 6.4, “anti-virus scanning”. 6.2.7. The pptp alg why the pptp alg is needed the pptp alg is provided to deal with a specific issue when pptp tunnels are used with nat. Let us suppose we have tw...

  • Page 270: 6.2.8. The Sip Alg

    Pptp-ctl can be used for this purpose. Alternatively, a new custom service object can be defined, for example called pptp_service. The service must have the following characteristics: i. Select the type (the protocol) as tcp. Ii. The source port range can be the default of 0-65535. Iii. Set the dest...

  • Page 271

    Note: traffic shaping will not work with the sip alg any traffic connections that trigger an ip rule with a service object that uses the sip alg cannot be also subject to traffic shaping. Sip components the following components are the logical building blocks for sip communication: user agents these...

  • Page 272

    Maximum sessions per id the number of simultaneous sessions that a single client can be involved with is restricted by this value. The default number is 5. Maximum registration time the maximum time for registration with a sip registrar. The default value is 3600 seconds. Sip signal timeout the maxi...

  • Page 273

    (sometimes described as sip pinholes) for allowing the media data traffic to flow through the netdefend firewall. Tip make sure there are no preceding rules already in the ip rule set disallowing or allowing the same kind of traffic. Sip usage scenarios netdefendos supports a variety of sip usage sc...

  • Page 274

    The sip proxy in the above diagram could alternatively be located remotely across the internet. The proxy should be configured with the record-route feature enabled to insure all sip traffic to and from the office clients will be sent through the sip proxy. This is recommended since the attack surfa...

  • Page 275

    Sends its own ip address as contact information to the sip proxy. Netdefendos registers the client's local contact information and uses this to redirect incoming requests to the user. The alg takes care of the address translations needed. 4. Ensure the clients are correctly configured. The sip proxy...

  • Page 276

    This scenario can be implemented in two ways: • using nat to hide the network topology. • without nat so the network topology is exposed. Solution a - using nat here, the proxy and the local clients are hidden behind the ip address of the netdefend firewall. The setup steps are as follows: 1. Define...

  • Page 277

    If record-route is enabled then the source network for outbound traffic from proxy users can be further restricted in the above rules by using "ip_proxy" as indicated. When an incoming call is received, the sip alg will follow the sat rule and forward the sip request to the proxy server. The proxy w...

  • Page 278

    The exchanges illustrated are as follows: • 1,2 - an initial invite is sent to the outbound local proxy server on the dmz. • 3,4 - the proxy server sends the sip messages towards the destination on the internet. • 5,6 - a remote client or proxy server replies to the local proxy server. • 7,8 - the l...

  • Page 279

    Dmz interface as the contact address. • an allow rule for outbound traffic from the proxy behind the dmz interface to the remote clients on the internet. • an allow rule for inbound sip traffic from the sip proxy behind the dmz interface to the ip address of the netdefend firewall. This rule will ha...

  • Page 280: 6.2.9. The H.323 Alg

    • destination port set to 5060 (the default sip signalling port) • type set to tcp/udp 3. Define four rules in the ip rule set: • an allow rule for outbound traffic from the clients on the internal network to the proxy located on the dmz interface. • an allow rule for outbound traffic from the proxy...

  • Page 281

    Gateways an h.323 gateway connects two dissimilar networks and translates traffic between them. It provides connectivity between h.323 networks and non-h.323 networks such as public switched telephone networks (pstn), translating protocols and converting media streams. A gateway is not required for ...

  • Page 282

    • the h.323 alg supports version 5 of the h.323 specification. This specification is built upon h.225.0 v5 and h.245 v10. • in addition to support voice and video calls, the h.323 alg supports application sharing over the t.120 protocol. T.120 uses tcp to transport data while voice and video is tran...

  • Page 283

    Web interface outgoing rule: 1. Go to rules > ip rules > add > iprule 2. Now enter: • name: h323allowout • action: allow • service: h323 • source interface: lan • destination interface: any • source network: lannet • destination network: 0.0.0.0/0 (all-nets) • comment: allow outgoing calls 3. Click ...

  • Page 284

    Example 6.5. H.323 with private ip addresses in this scenario a h.323 phone is connected to the netdefend firewall on a network with private ip addresses. To make it possible to place a call from this phone to another h.323 phone on the internet, and to allow h.323 phones on the internet to call thi...

  • Page 285

    • destination interface: core • source network: 0.0.0.0/0 (all-nets) • destination network: wan_ip (external ip of the firewall) • comment: allow incoming calls to h.323 phone at ip-phone 3. Click ok to place a call to the phone behind the netdefend firewall, place a call to the external ip address ...

  • Page 286

    Incoming rule: 1. Go to rules > ip rules > add > iprule 2. Now enter: • name: h323allowin • action: allow • service: h323 • source interface: any • destination interface: lan • source network: 0.0.0.0/0 (all-nets) • destination network: lannet • comment: allow incoming calls 3. Click ok example 6.7....

  • Page 287

    • source interface: any • destination interface: core • source network: 0.0.0.0/0 (all-nets) • destination network: wan_ip (external ip of the firewall) • comment: allow incoming calls to h.323 phone at ip-phone 3. For sat enter translate destination ip address: to new ip address: ip-phone (ip addre...

  • Page 288

    Web interface incoming gatekeeper rules: 1. Go to rules > ip rules > add > iprule 2. Now enter: • name: h323in • action: sat • service: h323-gatekeeper • source interface: any • destination interface: core • source network: 0.0.0.0/0 (all-nets) • destination network: wan_ip (external ip of the firew...

  • Page 289

    2. Now enter: • name: h323in • action: allow • service: h323-gatekeeper • source interface: lan • destination interface: dmz • source network: lannet • destination network: ip-gatekeeper (ip address of the gatekeeper) • comment: allow incoming communication with the gatekeeper 3. Click ok note: outg...

  • Page 290

    2. Now enter: • name: h323out • action: nat • service: h323-gatekeeper • source interface: lan • destination interface: any • source network: lannet • destination network: 0.0.0.0/0 (all-nets) • comment: allow outgoing communication with a gatekeeper 3. Click ok note: outgoing calls do not need a sp...

  • Page 291

    The head office has placed a h.323 gatekeeper in the dmz of the corporate netdefend firewall. This firewall should be configured as follows: web interface 1. Go to rules > ip rules > add > iprule 2. Now enter: • name: lantogk • action: allow • service: h323-gatekeeper • source interface: lan • desti...

  • Page 292

    • source interface: lan • destination interface: dmz • source network: lannet • destination network: ip-gateway • comment: allow h.323 entities on lannet to call phones connected to the h.323 gateway on the dmz 3. Click ok 1. Go to rules > ip rules > add > iprule 2. Now enter: • name: gwtolan • acti...

  • Page 293

    3. Click ok example 6.11. Configuring remote offices for h.323 if the branch and remote office h.323 phones and applications are to be configured to use the h.323 gatekeeper at the head office, the netdefend firewalls in the remote and branch offices should be configured as follows: (this rule shoul...

  • Page 294: 6.2.10. The Tls Alg

    The communication between "external" phones and the gatekeeper to make sure that it is possible for internal phones to call the external phones that are registered with the gatekeeper. 6.2.10. The tls alg overview transport layer security (tls) is a protocol that provides secure communications over ...

  • Page 295

    Figure 6.7. Tls termination advantages of using netdefendos for tls termination tls can be implemented directly in the server to which clients connect, however, if the servers are protected behind a netdefend firewall, then netdefendos can take on the role of the tls endpoint. Netdefendos then perfo...

  • Page 296

    4. Associate the tls alg object with the newly created service object. 5. Create a nat or allow ip rule for the targeted traffic and associate the custom service object with it. 6. Optionally, a sat rule can be created to change the destination port for the unencrypted traffic. Alternatively an slb_...

  • Page 297: 6.3.1. Overview

    6.3. Web content filtering 6.3.1. Overview web traffic is one of the biggest sources for security issues and misuse of the internet. Inappropriate surfing habits can expose a network to many security threats as well as legal and regulatory liabilities. Productivity and internet bandwidth can also be...

  • Page 298

    Removing such legitimate code could, at best, cause the web site to look distorted, at worst, cause it to not work in a browser at all. Active content handling should therefore only be used when the consequences are well understood. Example 6.13. Stripping activex and java applets this example shows...

  • Page 299

    */*.Gif good. This will block all files with .Gif as the file name extension. Www.Example.Com bad. This will only block the first request to the web site. Surfing to www.Example.Com/index.Html, for example, will not be blocked. *example.Com/* bad. This will also cause www.Myexample.Com to be blocked...

  • Page 300

    6. Enter */*.Exe in the url textbox 7. Click ok finally, make an exception from the blacklist by creating a whitelist: 1. Go to objects > alg 2. In the table, click on the recently created http alg to view its properties 3. Click the http url tab 4. Now click add and select http alg url from the men...

  • Page 301

    Community, such as a group of university students, often surfs to a limited range of websites. Figure 6.8. Dynamic content filtering flow if the requested web page url is not present in the databases, then the webpage content at the url will automatically be downloaded to d-link's central data wareh...

  • Page 302

    Activation dynamic content filtering is a feature that is enabled by taking out a separate subscription to the service. This is an addition to the normal netdefendos license. Once a subscription is taken out, an http application layer gateway (alg) object should be defined with dynamic content filte...

  • Page 303

    1. Go to objects > alg > add > http alg 2. Specify a suitable name for the alg, for example content_filtering 3. Click the web content filtering tab 4. Select enabled in the mode list 5. In the blocked categories list, select search sites and click the >> button. 6. Click ok then, create a service o...

  • Page 304

    Easier to evaluate if the goals of site blocking are being met. Example 6.16. Enabling audit mode this example is based on the same scenario as the previous example, but now with audit mode enabled. Command-line interface first, create an http application layer gateway (alg) object: gw-world:/> add ...

  • Page 305

    Manually propose a new classification of sites. This mechanism can be enabled on a per-http alg level, which means that the administrator can choose to enable this functionality for regular users or for a selected user group only. If reclassification is enabled and a user requests a web site which i...

  • Page 306

    Of each category. Category 1: adult content a web site may be classified under the adult content category if its content includes the description or depiction of erotic or sexual acts or sexually oriented material such as pornography. Exceptions to this are web sites that contain information relatin...

  • Page 307

    • www.Flythere.Nu • www.Reallycheaptix.Com.Au category 6: shopping a web site may be classified under the shopping category if its content includes any form of advertisement of goods or services to be exchanged for money, and may also include the facilities to perform that transaction online. Includ...

  • Page 308

    Computer game related software, or playing or participating in online games. Examples might be: • www.Gamesunlimited.Com • www.Gameplace.Com category 11: investment sites a web site may be classified under the investment sites category if its content includes information, services or facilities pert...

  • Page 309

    • www.Political.Com category 16: sports a web site may be classified under the sports category if its content includes information or instructions relating to recreational or professional sports, or reviews on sporting events and sports scores. Examples might be: • www.Sportstoday.Com • www.Soccerba...

  • Page 310

    Category 21: health sites a web site may be classified under the health sites category if its content includes health related information or services, including sexuality and sexual health, as well as support groups, hospital and surgical information and medical journals. Examples might be: • www.Th...

  • Page 311

    • highschoolessays.Org • www.Learn-at-home.Com category 27: advertising a web site may be classified under the advertising category if its main focus includes providing advertising related information or services. Examples might be: • www.Admessages.Com • www.Tripleclick.Com category 28: drugs/alcoh...

  • Page 312

    Category 32: non-managed unclassified sites and sites that do not fit one of the other categories will be placed in this category. It is unusual to block this category since this could result in most harmless urls being blocked. 6.3.4.4. Customizing html pages dynamic web content filtering make use ...

  • Page 313

    Tip: saving changes in the above example, more than one html file can be edited in a session but the save button should be pressed to save any edits before beginning editing on another file. Uploading with scp it is possible to upload new http banner files using scp. The steps to do this are: 1. Sin...

  • Page 314: 6.4. Anti-Virus Scanning

    6.4. Anti-virus scanning 6.4.1. Overview the netdefendos anti-virus module protects against malicious code carried in file downloads. Files may be downloaded as part of a web-page in an http transfer, in an ftp download, or perhaps as an attachment to an email delivered through smtp. Malicious code ...

  • Page 315

    Types of file downloads scanned as described above, anti-virus scanning is enabled on a per alg basis and can scan file downloads associated with the http, ftp, smtp and pop3 algs. More specifically: • any uncompressed file type transferred through these algs can be scanned. • if the download has be...

  • Page 316: 6.4.6. Anti-Virus Options

    6.4.4. The signature database safestream netdefendos anti-virus scanning is implemented by d-link using the "safestream" virus signature database. The safestream database is created and maintained by kaspersky, a company which is a world leader in the field of virus detection. The database provides ...

  • Page 317

    The excluded list is checked. 3. Compression ratio limit when scanning compressed files, netdefendos must apply decompression to examine the file's contents. Some types of data can result in very high compression ratios where the compressed file is a small fraction of the original uncompressed file ...

  • Page 318

    3. This reconfiguration causes a failover so the passive unit becomes the active unit. 4. When the update is completed, the newly active unit also downloads the files for the update and performs a reconfiguration. 5. This second reconfiguration causes another failover so the passive unit reverts bac...

  • Page 319

    Web interface a. First, create an http alg object: 1. Go to objects > alg > add > http alg 2. Specify a suitable name for the alg, for instance anti_virus 3. Click the antivirus tab 4. Select protect in the mode dropdown list 5. Click ok b. Then, create a service object using the new http alg: 1. Go...

  • Page 320: 6.5.1. Overview

    6.5. Intrusion detection and prevention 6.5.1. Overview intrusion definition computer servers can sometimes have vulnerabilities which leave them exposed to attacks carried by network traffic. Worms, trojans and backdoor exploits are examples of such attacks which, if successful, can potentially com...

  • Page 321

    • maintenance idp maintenance idp is the base idp system included as standard with the netdefend dfl 210, 800, 1600 and 2500. Maintenance idp is a simplified idp that gives basic protection against idp attacks. It is upgradeable to the higher level and more comprehensive advanced idp which is discus...

  • Page 322: 6.5.3. Idp Rules

    A new, updated signature database is downloaded automatically by netdefendos system at a configurable interval. This is done via an http connection to the d-link server network which delivers the latest signature database updates. If the server's signature database has a newer version than the curre...

  • Page 323

    Idp signature selection when using the web interface, all idp signatures in the local signature database are shown under the heading idp signatures. This displays a two level tree of all signatures ordered by group. However, its purpose is for reference only and it is not possible to add signatures ...

  • Page 324

    Initial packet processing the initial order of packet processing with idp is as follows: 1. A packet arrives at the firewall and netdefendos performs normal verification. If the packet is part of a new connection then it is checked against the ip rule set before being passed to the idp module. If th...

  • Page 325

    Subsystem but are acceptable to the target application. Detection action if an insertion/evasion attack is detected with the insertion/evasion protect option enabled, netdefendos automatically corrects the data stream by removing the extraneous data associated with the attack. Insertion/evasion log ...

  • Page 326

    An advisory is a explanatory textual description of a signature. Reading a signature's advisory will explain to the administrator what the signature will search for. Due to the changing nature of the signature database, advisories are not included in d-link documentation but instead, are available o...

  • Page 327: 6.5.7. Idp Actions

    • http 3. Signature group sub-category the third level of naming further specifies the target of the group and often specifies the application, for example mssql. The sub-category may not be necessary if the type and category are sufficient to specify the group, for example app_itunes. Listing of id...

  • Page 328

    Idp blacklisting the protect option includes the option that the particular host or network that triggers the idp rule can be added to a blacklist of offending traffic sources. This means that all subsequent traffic coming from a blacklisted source with be automatically dropped by netdefendos. For m...

  • Page 329

    • smtp server: smtp-server • server port: 25 • specify alternative email addresses (up to 3) • sender: hostmaster • subject: log event from netdefendos • minimum repeat delay: 600 • hold time: 120 • log threshold: 2 • click ok idp rules: 1. Go to idp > idp rules 2. Select a rule and choose edit 3. S...

  • Page 330

    Sourcenetwork=wannet destinationinterface=dmz destinationnetwork=ip_mailserver name=idpmailsrvrule specify the rule action: gw-world:/> cc idprule idpmailsrvrule gw-world:/idpmailsrvrule> add idpruleaction action=protect idpservity=all signatures=ips_mail_smtp web interface create an idp rule: this ...

  • Page 331

    To instead specify indvidual signatures or a list of signatures for an idp rule. Individual signatures are identified by their unique number id and multiple signatures is specified as a comma seperated list of these ids. For example, to specify signatures with the id 68343, the cli in the above exam...

  • Page 332: 6.6.1. Overview

    6.6. Denial-of-service attack prevention 6.6.1. Overview by embracing the internet, enterprises experience new business opportunities and growth. The enterprise network and the applications that run over it are business critical. Not only can a company reach a larger number of customers via the inte...

  • Page 333: Boink And Nestea

    Intended victim. "jolt" is simply a purpose-written program for generating such packets on operating systems whose ping commands refuse to generate oversized packets. The triggering factor is that the last fragment makes the total packet size exceed 65535 bytes, which is the highest number that a 16...

  • Page 334

    • by stripping the urg bit by default from all tcp segments traversing the system (configurable via advanced settings > tcp > tcpurg). Winnuke attacks will usually show up in netdefendos logs as normal drops with the name of the ip rule that disallowed the connection attempt. For connections allowed...

  • Page 335: 6.6.9. The Jolt2 Attack

    The traffic shaping feature built into netdefendos also help absorb some of the flood before it reaches protected servers. 6.6.8. Tcp syn flood attacks tcp syn flood attacks work by sending large amounts of tcp syn packets to a given port and then not responding to syn acks sent in response. This wi...

  • Page 336

    A more sophisticated form of dos is the distributed denial of service (dos) attack. Ddos attacks involve breaking into hundreds or thousands of machines all over the internet to installs ddos software on them, allowing the hacker to control all these burgled machines to launch coordinated attacks on...

  • Page 337

    6.7. Blacklisting hosts and networks overview netdefendos implements a blacklist of host or network ip addresses which can be utilized to protect against traffic coming from specific internet sources. Certain netdefendos subsystems have the ability to optionally blacklist a host or network when cert...

  • Page 338

    Blacklisted, it still does not prevent netdefendos mechanisms such as threshold rules from dropping or denying connections from that source. What whitelisting does is prevent a source being added to a blacklist if that is the action a rule has specified. For further details on usage see section 6.5....

  • Page 339

    6.7. Blacklisting hosts and networks chapter 6. Security mechanisms 339.

  • Page 340: 7.1. Overview

    Chapter 7. Address translation this chapter describes netdefendos address translation capabilities. • overview, page 340 • nat, page 341 • nat pools, page 346 • sat, page 349 7.1. Overview the ability of netdefendos to change the ip address of packets as they pass through the netdefend firewall is k...

  • Page 341: 7.2. Nat

    7.2. Nat dynamic network address translation (nat) provides a mechanism for translating original source ip addresses to a different address. Outgoing packets then appear to come from a different ip address and incoming packets back to that address have their ip address translated back to the origina...

  • Page 342

    Address on the firewall then this will constitute two, unique ip pairs. The 64,500 figure is therefore not a limitation for the entire netdefend firewall. Tip: use nat pools to get around the connection limit the connection maximum per unique ip pair is normally adequate for all but the most extreme...

  • Page 343

    195.55.66.77:80 => 195.11.22.33:32789 4. Netdefendos receives the packet and compares it to its list of open connections. Once it finds the connection in question, it restores the original address and forwards the packet. 195.55.66.77:80 => 192.168.1.5:1038 5. The original sender now receives the re...

  • Page 344

    Web interface 1. Go to rules > ip rules > add > iprule 2. Specify a suitable name for the rule, for example nat_http 3. Now enter: • action: nat • service: http • source interface: lan • source network: lannet • destination interface: any • destination network: all-nets 4. Under the nat tab, make su...

  • Page 345

    Anonymize traffic between clients and servers across the public internet so that the client's public ip address is not present in any server access requests or peer to peer traffic. We shall examine the typical case where the netdefend firewall acts as a pptp server and terminates the pptp tunnel fo...

  • Page 346: 7.3. Nat Pools

    7.3. Nat pools overview network address translation (nat) provides a way to have multiple internal clients and hosts with unique private internal ip addresses communicate to remote hosts through a single external public ip address (this is discussed in depth in section 7.2, “nat”). When multiple pub...

  • Page 347

    There is only one state table per nat pool so that if a single nat pool is re-used in multiple nat ip rules they share the same state table. Stateless nat pools the stateless option means that no state table is maintained and the external ip address chosen for each new connection is the one that has...

  • Page 348

    This example creates a nat pool with the external ip address range 10.6.13.10 to 10.16.13.15 which is then used in a nat ip rule for http traffic on the wan interface. Web interface a. First create an object in the address book for the address range: 1. Go to objects > address book > add > ip addres...

  • Page 349: 7.4. Sat

    7.4. Sat netdefendos can translate entire ranges of ip addresses and/or ports. Such translations are transpositions, each address or port is mapped to a corresponding address or port in the new range, rather than translating them all to the same address or port. In netdefendos this functionality is ...

  • Page 350

    The illustration below shows a typical network arrangement with the netdefend firewall mediating communications between the public internet and servers in the dmz, and between the dmz and local clients on a network called lan. Figure 7.4. The role of the dmz note: the dmz port could be any port on a...

  • Page 351

    Then create a corresponding allow rule: gw-world:/main> add iprule action=allow service=http sourceinterface=any sourcenetwork=all-nets destinationinterface=core destinationnetwork=wan_ip name=allow_http_to_dmz web interface first create a sat rule: 1. Go to rules > ip rules > add > iprule 2. Specif...

  • Page 352

    # action src iface src net dest iface dest net parameters 3 nat lan lannet wan all-nets all now, what is wrong with this rule set? If we assume that we want to implement address translation for reasons of security as well as functionality, we discover that this rule set makes our internal addresses ...

  • Page 353

    # action src iface src net dest iface dest net parameters 2 allow any all-nets core wan_ip http these two rules allow us to access the web server via the netdefend firewall's external ip address. Rule 1 states that address translation can take place if the connection has been permitted, and rule 2 p...

  • Page 354

    Another possible solution to this problem is to allow internal clients to speak directly to 10.0.0.2 and this would completely avoid all the problems associated with address translation. However, this is not always practical. 7.4.2. Translation of multiple ip addresses (m:n) a single sat rule can be...

  • Page 355

    Address=10.10.10.5 publish the public ip addresses on the wan interface using arp publish. One arp item is needed for every ip address: gw-world:/> add arp interface=wan ip=195.55.66.77 mode=publish repeat this for all the five public ip addresses. Next, change the current category to be the main ip...

  • Page 356: 7.4.4. Port Translation

    3. Now enter: • action: sat • servce: http • source interface:any • source network: all-nets • destination interface: wan • destination network: wwwsrv_pub 4. Switch to the sat tab 5. Make sure that the destination ip address option is selected 6. In the new ip address dropdown list, select wwwsrv_p...

  • Page 357

    Port translation (pat) (also known as port address translation) can be used to modify the source or destination port. # action src iface src net dest iface dest net parameters 1 sat any all-nets wan wwwsrv_pub tcp 80-85 setdest 192.168.0.50 1000 this rule produces a 1:1 translation of all ports in t...

  • Page 358

    The two above rules may both be carried out concurrently on the same connection. In this instance, internal sender addresses will be translated to addresses in pubnet in a 1:1 relationship. In addition, if anyone tries to connect to the public address of the web server, the destination address will ...

  • Page 359

    What happens now? • external traffic to wan_ip:80 will match rules 1 and 4, and will be sent to wwwsrv. Correct. • return traffic from wwwsrv:80 will match rules 2 and 3. The replies will therefore be dynamically address translated. This changes the source port to a completely different port, which ...

  • Page 360

    7.4.7. Sat and fwdfast rules chapter 7. Address translation 360

  • Page 361: 8.1. Overview

    Chapter 8. User authentication this chapter describes how netdefendos implements user authentication. • overview, page 361 • authentication setup, page 363 • customizing html pages, page 379 8.1. Overview in situations where individual users connect to protected resources through the netdefend firew...

  • Page 362

    To remain secure, passwords should also: • not be recorded anywhere in written form. • never be revealed to anyone else. • changed on a regular basis such as every three months. 8.1. Overview chapter 8. User authentication 362.

  • Page 363: 8.2. Authentication Setup

    8.2. Authentication setup 8.2.1. Setup summary the following list summarizes the steps for user authentication setup with netdefendos: • have an authentication source which consists of a database of users, each with a username/password combination. Any of the following can be an authentication sourc...

  • Page 364

    The purpose of this is to restrict access to certain networks to a particular group by having ip rules which will only apply to members of that group. To gain access to a resource there must be an ip rule that allows it and the client must belong to the same group as the rule's source network group....

  • Page 365

    When the user connects, there is an automatic checking of the keys used by the client to verify their identity. Once verified, there is no need for the user to input their username and password. To make use of this feature, the relevant ssh client key object or objects must first be defined separate...

  • Page 366

    One or more ldap servers can be associated as a list within a user authentication rule. The ordering of the list determines the order in which server access is attempted. The first server in the list has the highest precedence and will be used first. If authentication fails or the server is unreacha...

  • Page 367

    The following general parameters are used for configuration of each server: • name the name given to the server object for reference purposes in netdefendos. For example, netdefendos authentication rules may be defined which reference this name. This value has nothing to do with the name attribute d...

  • Page 368

    Successful authentication. The domain name is the host name of the ldap server, for example myldapserver. The choices for this parameter are: i. None - this will not modify the username in any way. For example, testuser. Ii. Username prefix - when authenticating, this will put \ in front of the user...

  • Page 369

    • domain name the domain name is used when formatting usernames. This is the first part of the full domain name. In our examples above, the domain name is myldapserver. The full domain name is a dot separated set of labels, for example, myldapserver.Local.Eu.Com. This option is only available if the...

  • Page 370

    If the domain is mydomain.Com then the username for myuser might need to be specified as myuser@mydomain.Com. With some ldap servers this might be myuser@domain mydomain.Com\myuser or even mydomain\myuser. The format depends entirely on the ldap server and what it expects. Real-time monitoring stati...

  • Page 371

    Figure 8.1. Normal ldap authentication the processing is different if a group membership is being retrieved since a request is sent to the ldap server to search for memberships and any group memberships are then sent back in the response. B. Ppp authentication with chap, ms-chapv1 or ms-chapv2 encry...

  • Page 372

    Figure 8.2. Ldap for ppp with chap, ms-chapv1 or ms-chapv2 important: the link to the ldap server must be protected since the ldap server is sending back passwords in plain text to netdefendos, the link between the netdefend firewall and the server must be protected. A vpn link should be used if the...

  • Page 373

    This is the ike authentication method which is used as part of vpn tunnel establishment with ipsec. Xauth is an extension to the normal ike exchange and provides an addition to normal ipsec security which means that clients accessing a vpn must provide a login username and password. It should be not...

  • Page 374

    The maximum time that a connection can exist (no value is specified by default). If an authentication server is being used then the option to use timeouts received from the authentication server can be enabled to have these values set from the server. Multiple logins an authentication rule can speci...

  • Page 375: 8.2.8. Http Authentication

    Any packets from an ip address that fails authentication are discarded. 8.2.7. A group usage example to illustrate authentication group usage, lets suppose that there are a set of users which will login from a network 192.168.1.0/24 connected to the lan interface. The requirement is to restrict acce...

  • Page 376

    Combination. A realm string can optionally be specified which will appear in the browser's dialog. Form is recommended over basicauth because in some cases the browser might hold the login data in its cache. • if the agent is set to https then the host certificate and root certificate have to be cho...

  • Page 377

    Example 8.1. Creating an authentication user group in the example of an authentication address object in the address book, a user group "users" is used to enable user authentication on "lannet". This example shows how to configure the user group in the netdefendos database. Web interface step a 1. G...

  • Page 378

    • destination network lan_ip 3. Click ok b. Set up the authentication rule 1. Go to user authentication > user authentication rules > add > user authentication rule 2. Now enter: • name: httplogin • agent: http • authentication source: local • interface: lan • originator ip: lannet 3. For local user...

  • Page 379

    F. Shared secret: enter a text string here for basic encryption of the radius messages g. Confirm secret: retype the string to confirm the one typed above 3. Click ok 8.3. Customizing html pages user authentication makes use of a set of html files to present information to the user during the authen...

  • Page 380

    • %ipaddr% - the ip address which is being browsed from. • %reason% - the reason that access was denied. • - the web page url for redirects. The %redirurl% parameter in certain banner web pages, the parameter %redirurl% appears. This is a placeholder for the original url which was requested before t...

  • Page 381

    2. A new auth banner files object must exist which the edited file(s) is uploaded to. If the object is called ua_html, the cli command to create this object is: gw-world:/> add httpauthbanners ua_html this creates an object which contains a copy of all the default user auth banner files. 3. The modi...

  • Page 382

    8.3. Customizing html pages chapter 8. User authentication 382.

  • Page 383: Chapter 9. Vpn

    Chapter 9. Vpn this chapter describes the virtual private network (vpn) functionality in netdefendos. • overview, page 383 • vpn quick start, page 387 • ipsec components, page 397 • ipsec tunnels, page 412 • pptp/l2tp, page 431 • ca server access, page 440 • vpn troubleshooting, page 443 9.1. Overvi...

  • Page 384: 9.1.2. Vpn Encryption

    2. Client to lan connection - where many remote clients need to connect to an internal network over the internet. In this case, the internal network is protected by the netdefend firewall to which the client connects and the vpn tunnel is set up between them. 9.1.2. Vpn encryption encryption of vpn ...

  • Page 385: 9.1.4. Key Distribution

    • restricting access through the vpn to needed services only, since mobile computers are vulnerable. • creating dmzs for services that need to be shared with other companies through vpns. • adapting vpn access policies for different groups of users. • creating key distribution policies. Endpoint sec...

  • Page 386

    “the tls alg”. 9.1.5. The tls alternative for vpn chapter 9. Vpn 386.

  • Page 387: 9.2. Vpn Quick Start

    9.2. Vpn quick start overview later sections in this chapter will explore vpn components in detail. To help put those later sections in context, this section is a quick start summary of the steps needed for vpn setup. It outlines the individual steps in setting up vpns for the most common scenarios....

  • Page 388

    9.2.1. Ipsec lan to lan with pre-shared keys 1. Create a pre-shared key object. 2. Optionally create a new ike algorithms object and/or an ipsec algorithms object if the default algorithm proposal lists do not provide a set of algorithms that are acceptable to the tunnel remote end point. This will ...

  • Page 389

    Action src interface src network dest interface dest network service allow ipsec_tunnel remote_net lan lannet all the service used in these rules is all but it could be a predefined service. 6. Define a new netdefendos route which specifies that the vpn tunnel ipsec_tunnel is the interface to use fo...

  • Page 390

    Considered adequate. Two self-signed certificates are required and the same two are used at either end of the tunnel but their usage is reversed. In other words: one certificate is used as the root certificate at one end, call it side a, and as the host certificate at the other end, call it side b. ...

  • Page 391

    The group string for a user can be specified if its group's access is to be restricted to certain source networks. Group can be specified (with the same text string) in the authentication section of an ip object. If that ip object is then used as the source network of a rule in the ip rule set, that...

  • Page 392

    • create a config mode pool object (there can only be one associated with a netdefendos installation) and in it specify the address range. • enable the ike config mode pool option in the ipsec tunnel object ipsec_tunnel. 2. If client ip addresses are to be retrieved through dhcp: • create an ip pool...

  • Page 393

    The step to set up user authentication is optional since this is additional security to certificates. Note: the system time and date should be correct the netdefendos date and time should be set correctly since certificates have an expiry date and time. Also review section 9.6, “ca server access”, w...

  • Page 394

    • set inner ip address to ip_int. • set tunnel protocol to l2tp. • set outer interface filter to ipsec_tunnel. • set outer server ip to ip_ext. • select the microsoft point-to-point encryption allowed. Since ipsec encryption is used this can be set to be none only, otherwise double encryption will d...

  • Page 395

    The setup described above are: 1. The netdefendos date and time must be set correctly since certificates can expire. 2. Load a gateway certificate and root certificate into netdefendos. 3. When setting up the ipsec tunnel object, specify the certificates to use under authentication. This is done by:...

  • Page 396

    • enable proxy arp on the int interface. • as in l2tp, enable the insertion of new routes automatically into the main routing table. 3. Define a user authentication rule, this is almost identical to l2tp: agent auth source src network interface client source ip ppp local all-nets pptp_tunnel all-net...

  • Page 397: 9.3. Ipsec Components

    9.3. Ipsec components this section looks at the ipsec standards and describes in general terms the various components, techniques and algorithms that are used in ipsec based vpns. 9.3.1. Overview internet protocol security (ipsec) is a set of protocols defined by the internet engineering task force ...

  • Page 398

    An sa is unidirectional and relates to traffic flow in one direction only. For the bidirectional traffic that is usually found in a vpn, there is therefore a need for more than one sa per connection. In most cases, where only one of esp or ah is used, two sas will be created for each connection, one...

  • Page 399

    Two vpn firewalls or vpn clients to each other, by confirming that the remote device has a matching pre-shared key. However, since we do not want to publish to much of the negotiation in plaintext, we first agree upon a way of protecting the rest of the ike negotiation. This is done, as described in...

  • Page 400

    Remote device, which will decrypt/authenticate the data, extract it from its tunnel and pass it on to its final destination. This way, an eavesdropper will only see encrypted traffic going from one of vpn endpoint to another. In transport mode, the traffic will not be tunneled, and is hence not appl...

  • Page 401

    Note netdefendos does not support ah. Ike encryption this specifies the encryption algorithm used in the ike negotiation, and depending on the algorithm, the size of the encryption key used. The algorithms supported by netdefendos ipsec are: • aes • blowfish • twofish • cast128 • 3des • des des is o...

  • Page 402

    Phase-1 sa every time a phase-2 negotiation has been finished, making sure no more than one phase-2 negotiation is encrypted using the same key. Pfs is generally not needed, since it is very unlikely that any encryption or authentication keys will be compromised. Pfs dh group this specifies the diff...

  • Page 403: 9.3.3. Ike Authentication

    Through a series of plain text exchanges. Even though the exchanges between the parties might be monitored by a third party, diffie-hellman makes it extremely difficult for the third party to determine what the agreed shared secret key is and to decrypt data that is encrypted using the key. Diffie-h...

  • Page 404

    Pre-shared keying has a lot of advantages over manual keying. These include endpoint authentication, which is what the psks are really for. It also includes all the benefits of using ike. Instead of using a fixed set of encryption keys, session keys will be used for a limited period of time, where a...

  • Page 405: 9.3.5. Nat Traversal

    Figure 9.1. The ah protocol ah uses a cryptographic hash function to produce a mac from the data in the ip packet. This mac is then transmitted with the packet, allowing the remote endpoint to verify the integrity of the original ip packet, making sure the data has not been tampered with on its way ...

  • Page 406

    Evolved. Nat traversal is an add-on to the ike and ipsec protocols that allows them to function when being nated. Netdefendos supports the rfc3947 standard for nat-traversal with ike. Nat traversal is divided into two parts: • additions to ike that lets ipsec peers tell each other that they support ...

  • Page 407

    Recommended setting unless the two firewalls have the same external ip address. • ip - an ip address can be manually entered • dns - a dns address can be manually entered • email - an email address can be manually entered 9.3.6. Algorithm proposal lists to agree on the vpn connection parameters, a n...

  • Page 408: 9.3.7. Pre-Shared Keys

    2. Enter a name for the list, for example esp-l2tptunnel 3. Now check the following: • des • 3des • sha1 • md5 4. Click ok then, apply the algorithm proposal list to the ipsec tunnel: 1. Go to interfaces > ipsec 2. Select the target ipsec tunnel 3. Select the recently created esp-l2tptunnel in the i...

  • Page 409

    Now apply the pre-shared key to the ipsec tunnel: gw-world:/> set interface ipsectunnel myipsectunnel psk=mypsk web interface first create a pre-shared key: 1. Go to objects > authentication objects > add > pre-shared key 2. Enter a name for the pre-shared key, for example mypsk 3. Choose hexadecima...

  • Page 410

    Will contain one id with the type dn, distinguished name, as the primary identifier. Note that this example does not illustrate how to add the specific ipsec tunnel object. Command-line interface first create an identification list: gw-world:/> add idlist myidlist then, create an id: gw-world:/> cc ...

  • Page 411

    4. Select the appropriate certificate in the root certificate(s) and gateway certificate controls 5. Select myidlist in the identification list 6. Click ok 9.3.8. Identification lists chapter 9. Vpn 411.

  • Page 412: 9.4. Ipsec Tunnels

    9.4. Ipsec tunnels this section looks more closely at ipsec tunnels in netdefendos, their definition, options and usage. 9.4.1. Overview an ipsec tunnel defines an endpoint of an encrypted tunnel. Each ipsec tunnel is interpreted as a logical interface by netdefendos, with the same filtering, traffi...

  • Page 413

    Performance of the netdefendos ipsec engine and explicitly dropping such traffic with an ip rule is an efficient way of preventing it reaching the engine. In other words, ip rules can be used to have complete control over all traffic related to the tunnel. Dead peer detection dead peer detection (dp...

  • Page 414: 9.4.3. Roaming Clients

    • section 9.2.2, “ipsec lan to lan with certificates”. • section 9.2.3, “ipsec roaming clients with pre-shared keys”. • section 9.2.4, “ipsec roaming clients with certificates”. In addition to the quick start section, more explanation of tunnel setup is given below. 9.4.2. Lan to lan tunnels with pr...

  • Page 415

    Example 9.4. Setting up a psk based vpn tunnel for roaming clients this example describes how to configure an ipsec tunnel at the head office netdefend firewall for roaming clients that connect to the office to gain remote access. The head office network uses the 10.0.1.0/24 network span with extern...

  • Page 416

    Web interface a. Create a self-signed certificate for ipsec authentication: the step to actually create self-signed certificates is performed outside the webui using a suitable software product. The certificate should be in the pem (privacy enhanced mail) file format. B. Upload all the client self-s...

  • Page 417

    Tunnels based on ca server certificates setting up client tunnels using a ca issued certificate is largely the same as using self-signed certificates with the exception of a couple of steps. It is the responsibility of the administrator to acquire the appropriate certificate from an issuing authorit...

  • Page 418

    • choose x.509 certificates as the authentication method • root certificate(s): select the ca server root certificate imported earlier and add it to the selected list • gateway certificate: choose the newly created firewall certificate • identification list: select the id list that is to be associat...

  • Page 419

    Web interface 1. Go to objects > vpn objects > ike config mode pool 2. The config mode pool object properties web page now appears 3. Select use a predefined ippool object 4. Choose the ip_pool1 object from the ip pool drop-down list 5. Click ok after defining the config mode object, the only remain...

  • Page 420

    Web interface 1. Go to objects > vpn objects > ldap > add > ldap server 2. Now enter: • ip address: 192.168.101.146 • username: myusername • password: mypassword • confirm password: mypassword • port: 389 3. Click ok 9.4.5. Troubleshooting with ikesnoop vpn tunnel negotiation when setting up ipsec t...

  • Page 421

    Negotiation and the server refers to the device which is the responder. Step 1. Client initiates exchange by sending a supported algorithm list the verbose option output initially shows the proposed list of algorithms that the client first sends to the server. This list details the protocols and enc...

  • Page 422

    Life duration : 43200 life type : kilobytes life duration : 50000 vid (vendor id) payload data length : 16 bytes vendor id : 8f 9c c9 4e 01 24 8e cd f1 47 59 4c 28 4b 21 3b description : ssh communications security quicksec 2.1.0 vid (vendor id) payload data length : 16 bytes vendor id : 27 ba b5 dc...

  • Page 423

    Sa (security association) payload data length : 52 bytes doi : 1 (ipsec doi) proposal 1/1 protocol 1/1 protocol id : isakmp spi size : 0 transform 1/1 transform id : ike encryption algorithm : rijndael-cbc (aes) key length : 128 hash algorithm : md5 authentication method : pre-shared key group descr...

  • Page 424

    Nat-d (nat detection) payload data length : 16 bytes step 4. Server sends key exchange data the server now sends key exchange data back to the client. Ikesnoop: sending ike packet to 192.168.0.10:500 exchange type : identity protection (main mode) isakmp version : 1.0 flags : cookies : 0x6098238b67d...

  • Page 425

    Step 6. Server id response the server now responds with its own id. Ikesnoop: sending ike packet to 192.168.0.10:500 exchange type : identity protection (main mode) isakmp version : 1.0 flags : e (encryption) cookies : 0x6098238b67d97ea6 -> 0x5e347cb76e95a message id : 0x00000000 packet length : 60 ...

  • Page 426

    Key length : 128 authentication algorithm : hmac-md5 sa life type : seconds sa life duration : 21600 sa life type : kilobytes sa life duration : 50000 encapsulation mode : tunnel transform 4/4 transform id : blowfish key length : 128 authentication algorithm : hmac-sha-1 sa life type : seconds sa li...

  • Page 427

    Protocol id : esp spi size : 4 spi value : 0xafba2d15 transform 1/1 transform id : rijndael (aes) key length : 128 authentication algorithm : hmac-md5 sa life type : seconds sa life duration : 21600 sa life type : kilobytes sa life duration : 50000 encapsulation mode : tunnel nonce (nonce) payload d...

  • Page 428

    Specifies the total number of ipsec tunnels allowed. This value is initially taken from the maximum tunnels allowed by the license. The setting is used by netdefendos to allocate memory for ipsec. If it is desirable to have less memory allocated for ipsec then this setting can be reduced. Increasing...

  • Page 429

    Ipsec cert cache max certs maximum number of certificates/crls that can be held in the internal certificate cache. When the certificate cache is full, entries will be removed according to an lru (least recently used) algorithm. Default: 1024 ipsec gateway name cache time length of time in millisecon...

  • Page 430

    Sent. If the other side of the tunnel has not sent a response to any messages then it is considered to be dead (not reachable). The sa will then be placed in the dead cache. This setting is used with ikev1 only. Default: 15 seconds 9.4.6. Ipsec advanced settings chapter 9. Vpn 430

  • Page 431: 9.5. Pptp/l2Tp

    9.5. Pptp/l2tp the access by a client using a modem link over dial-up public switched networks, possibly with an unpredictable ip address, to protected networks via a vpn poses particular problems. Both the pptp and l2tp protocols provide two different means of achieving vpn access from remote clien...

  • Page 432: 9.5.2. L2Tp Servers

    Tcp port 1723 and/or ip protocol 47 before the pptp connection can be made to the netdefend firewall. Examining the log can indicate if this problem occurred, with a log message of the following form appearing: error ppp lcp_negotiation_stalled ppp_terminated example 9.10. Setting up a pptp server t...

  • Page 433

    Example 9.11. Setting up an l2tp server this example shows how to setup a l2tp network server. The example assumes that you have created some ip address objects. You will have to specify the ip address of the l2tp server interface, an outer ip address (that the l2tp server should listen to) and an i...

  • Page 434

    1. Go to user authentication > local user databases > add > local user database 2. Enter a suitable name for the user database, for example userdb 3. Go to user authentication > local user databases > userdb > add > user 4. Now enter: • username: testuser • password: mypassword • confirm password: m...

  • Page 435

    Command-line interface gw-world:/> add interface l2tpserver l2tp_tunnel ip=lan_ip interface=l2tp_ipsec serverip=wan_ip ippool=l2tp_pool tunnelprotocol=l2tp allowedroutes=all-nets proxyarpinterfaces=lan web interface 1. Go to interfaces > l2tp servers > add > l2tpserver 2. Enter a name for the l2tp t...

  • Page 436

    Command-line interface first, change the current category to be the main ip rule set: gw-world:/> cc ipruleset main now, add the ip rules: gw-world:/main> add iprule action=allow service=all_services sourceinterface=l2tp_tunnel sourcenetwork=l2tp_pool destinationinterface=any destinationnetwork=all-...

  • Page 437: 9.5.4. Pptp/l2Tp Clients

    L2tp before rules pass l2tp traffic sent to the netdefend firewall directly to the l2tp server without consulting the rule set. Default: enabled pptp before rules pass pptp traffic sent to the netdefend firewall directly to the pptp server without consulting the rule set. Default: enabled max ppp re...

  • Page 438

    Note: the default pptp/l2tp route a pptp/l2tp server will not provide information such as gateway or broadcast addresses, as this is not used with pptp/l2tp tunnels. When using pptp/l2tp, the default route is normally routed directly across the pptp/l2tp tunnel without a specified gateway. Authentic...

  • Page 439

    Figure 9.3. Pptp client usage 9.5.4. Pptp/l2tp clients chapter 9. Vpn 439.

  • Page 440: 9.6. Ca Server Access

    9.6. Ca server access overview where certificates are used, the two sides of a vpn tunnel exchange their certificates during the tunnel setup negotiation and either may then try to validate the received certificate by accessing a ca server. A certificate contains a url (the crl distribution point) w...

  • Page 441

    3. The ca server is a commercial server on the public internet. In this, the simplest case, public dns servers will resolve the fqdn. The only requirement is that netdefendos will need to have at least one public dns server address configured to resolve the fqdns in the certificates it receives. • i...

  • Page 442

    As explained previously, the address of the private ca server must be resolvable through public dns servers for certificate validation requests coming from the public internet. If the certificate queries are coming only from the netdefend firewall and the ca server is on the internal side of the fir...

  • Page 443: 9.7. Vpn Troubleshooting

    9.7. Vpn troubleshooting this section deals with how to troubleshoot the common problems that are found with vpn. 9.7.1. General troubleshooting in all types of vpns some basic troubleshooting checks can be made: • check that all ip addresses have been specified correctly. • check that all pre-share...

  • Page 444

    If certificates have been used in a vpn solution then the following should be looked at as a source of potential problems: • check that the correct certificates have been used for the right purposes. • check that the certificate .Cer and .Key files have the same filename. For example, my_cert.Key an...

  • Page 445

    Another example of what to avoid with many tunnels is: gw-world:/> ipsectunnels -num=all in these circumstances, using the option with a small number, for example -num=10, is recommended. The ikesnoop console command a common problem with setting up ipsec is a list of proposed algorithms that is una...

  • Page 446

    1. Could not find acceptable proposal / no proposal chosen this is the most common ipsec related error message. It means that depending on which side initiates tunnel setup, the negotiations in either the ike or the ipsec phase of setup failed since they were unable to find a matching proposal that ...

  • Page 447

    The problem is solved if we reorder the list and move vpn-3 above l2tp. The gateway office3gw will be then matched correctly and vpn-3 will be the tunnel selected by netdefendos. 3. Ike_invalid_payload, ike_invalid_cookie in this case the ipsec engine in netdefendos receives an ipsec ike packet but ...

  • Page 448: 9.7.6. Specific Symptoms

    Note: l2tp with microsoft vista with l2tp, microsoft vista tries by default to contact and download the crl list, while microsoft xp does not. This can be turned off in vista. • if multiple similar or roaming tunnels exist and there is a need to separate them using id lists, a possible cause can be ...

  • Page 449

    By using ikesnoop when both sides initiate the tunnel, it should be simple to compare the network that both sides are sending in phase-2. With that information it should be possible to spot the network problem. It can be the case that it is a network size mismatch or that it does not match at all. 9...

  • Page 450

    9.7.6. Specific symptoms chapter 9. Vpn 450

  • Page 451: 10.1. Traffic Shaping

    Chapter 10. Traffic management this chapter describes how netdefendos can manage network traffic. • traffic shaping, page 451 • idp traffic shaping, page 472 • threshold rules, page 477 • server load balancing, page 480 10.1. Traffic shaping 10.1.1. Overview qos with tcp/ip a weakness of tcp/ip is t...

  • Page 452

    Traffic shaping objectives traffic shaping operates by measuring and queuing ip packets with respect to a number of configurable parameters. The objectives are: • applying bandwidth limits and queuing packets that exceed configured limits, then sending them later when bandwidth demands are lower. • ...

  • Page 453

    Pipe rules one or more pipe rules make up the netdefendos pipe rule set which determine what traffic will flow through which pipes. Each pipe rule is defined like other netdefendos secuirity policies: by specifying the source/destination interface/network as well as the service to which the rule is ...

  • Page 454

    Of 8 pipes. Explicitly excluding traffic from shaping if no pipe is specified in a pipe rule list then traffic that triggers the rule will not flow through any pipe. It also means that the triggering traffic will not be subject to any other matching pipe rules that might be found later in the rule s...

  • Page 455

    Web interface 1. Go to traffic management > traffic shaping > pipes > add > pipe 2. Specify a suitable name for the pipe, for instance std-in 3. Enter 2000 in the total textbox under pipe limits 4. Click ok traffic needs to be passed through the pipe and this is done by using the pipe in a pipe rule...

  • Page 456

    Attempting to flow is 4 mbps. Since the pipe limit is 2 mbps, the actual flow will be close to 1 mbps in each direction. Raising the total pipe limit to 4 mbps will not solve the problem since the single pipe will not know that 2 mbps of inbound and 2 mbps of outbound are the intended limits. The re...

  • Page 457: 10.1.6. Precedences

    Requests followed by long inbound responses. A surf-in pipe is therefore first created for inbound traffic with a 125 kbps limit. Next, a new pipe rule is set up for surfing that uses the surf-in pipe and it is placed before the rule that directs everything else through the std-in pipe. That way web...

  • Page 458

    Default precedence which is 0. There are 8 possible precedence levels eight precedences exist which are numbered from 0 to 7. Precedence 0 is the least important (lowest priority) precedence and 7 is the most important (highest priority) precedence. A precedence can be viewed as a separate traffic q...

  • Page 459

    • default precedence: 0 • maximum precedence: 7 as described above, the default precedence is the precedence taken by a packet if it is not explicitly assigned by a pipe rule. The minimum and maximum precedences define the precedence range that the pipe will handle. If a packet arrives with an alrea...

  • Page 460

    Figure 10.5. Minimum and maximum pipe precedence lowest precedence limits it is usually is not needed to have a limit specified for the lowest (best effort) precedence since this precedence simply uses any spare bandwidth not used by higher precedences. However, a limit could be specified if there i...

  • Page 461

    The need for guarantees a problem can occur however if prioritized traffic is a continuous stream such as real-time audio, resulting in continuous use of all available bandwidth and resulting in unacceptably long queuing times for other services such as surfing, dns or ftp. A means is required to en...

  • Page 462: 10.1.7. Pipe Groups

    Set the priority assignment for both rules to use defaults from first pipe; the default precedence of both the ssh-in and telnet-in pipes is 2. Using this approach rather than hard-coding precedence 2 in the rule set, it is easy to change the precedence of all ssh and telnet traffic by changing the ...

  • Page 463

    Specifying group limits once the way the method of grouping is selected, the next step is to specify the group limits. These limits can consist of one or both of the following: • group limit total this value specifies a limit for each user within the grouping. For example, if the grouping is by sour...

  • Page 464

    Figure 10.6. Traffic grouped by ip address another simple groups example consider another situation where the total bandwidth limit for a pipe is 400 bps. If the aim is to allocate this bandwidth amongst many destination ip addresses so that no single ip address can take more then 100 bps of bandwid...

  • Page 465

    If a total group limit of 100 bps is also specified with dynamic balancing, then this still means that no single user may take more than that amount of bandwidth. Precedences and dynamic balancing as discussed, in addition to specifying a total limit for a grouping, limits can be specified for each ...

  • Page 466

    Fixed bandwidth resource. An isp might use this approach to limit individual user bandwidth by specifying a "per destination ip" grouping. Knowing when the pipe is full is not important since the only constraint is on each user. If precedences were used the pipe maximum would have to be used. Limits...

  • Page 467

    • select the traffic to manage through pipe rules. • pipe rules send traffic through pipes. • a pipe can have a limit which is the maximum amount of traffic allowed. • a pipe can only know when it is full if a total limit for the pipe is specified. • a single pipe should handle traffic in only one d...

  • Page 468

    Figure 10.7. A basic traffic shaping scenario the reason for using 2 different pipes in this case, is that these are easier to match to the physical link capacity. This is especially true with asynchronous links such as adsl. First, two pipes called in-pipe and out-pipe need to be created with the f...

  • Page 469

    Rule name forward pipes return pipes source interface source network dest interface dest network selected service prece dence voip out-pipe in-pipe lan lannet wan all-nets h323 6 citrix out-pipe in-pipe lan lannet wan all-nets citrix 4 other out-pipe in-pipe lan lannet wan all-nets all 2 these rules...

  • Page 470

    Total: 1700 • vpn-out • priority 6: voip 500 kpbs • priority 0: best effort total: 1700 • in-pipe • priority 6: voip 500 kpbs total: 2000 • out-pipe • priority 6: voip 500 kpbs total: 2000 the following pipe rules are then needed to force traffic into the correct pipes and precedence levels: rule na...

  • Page 471

    Note: sat and arped ip addresses if the sat is from an arped ip address, the wan interface needs to be the destination. 10.1.10. More pipe examples chapter 10. Traffic management 471.

  • Page 472: 10.2. Idp Traffic Shaping

    10.2. Idp traffic shaping 10.2.1. Overview the idp traffic shaping feature is traffic shaping that is performed based on information coming from the netdefendos intrusion detection and prevention (idp) subsystem (for more information on idp see section 6.5, “intrusion detection and prevention”). App...

  • Page 473: 10.2.3. Processing Flow

    Information followed by a number of data transfer connections to other hosts. It is the initial connection that idp detects and the time window specifies the expected period afterwards when other connections will be opened and subject to traffic shaping. Connections opened after the time window has ...

  • Page 474: 10.2.5. A P2P Scenario

    Excluding hosts to avoid these unintended consequences, we specify the ip addresses of client a and client b in the network range but not host x. This tells netdefendos that host x is not relevant in making a decision about including new non-idp-triggering connections in traffic shaping. It may seem...

  • Page 475

    10.2.6. Viewing traffic shaping objects viewing hosts idp traffic shaping has a special cli command associated with it called idppipes and this can examine and manipulate the hosts which are currently subject to traffic shaping. To display all hosts being traffic shaped by idp traffic shaping, the c...

  • Page 476: 10.2.8. Logging

    10.2.7. Guaranteeing instead of limiting bandwidth if desired, idp traffic shaping can be used to do the opposite of limiting bandwidth for certain applications. If the administrator wants to guarantee a bandwidth level, say 10 megabits, for an application then an idp rule can be set up to trigger f...

  • Page 477: 10.3. Threshold Rules

    10.3. Threshold rules 10.3.1. Overview the objective of a threshold rule is to have a means of detecting abnormal connection activity as well as reacting to it. An example of a cause for such abnormal activity might be an internal host becoming infected with a virus that is making repeated connectio...

  • Page 478: 10.3.3. Grouping

    This function is extremely useful when nat pools are required due to the large number of connections generated by p2p users. 10.3.3. Grouping the two groupings are as follows: • host based - the threshold is applied separately to connections from different ip addresses. • network based - the thresho...

  • Page 479

    Netdefendos. The length of time, in seconds, for which the source is blacklisted can also be set. This feature is discussed further in section 6.7, “blacklisting hosts and networks”. 10.3.8. Threshold rule blacklisting chapter 10. Traffic management 479.

  • Page 480: 10.4.1. Overview

    10.4. Server load balancing 10.4.1. Overview the server load balancing (slb) feature allows the administrator to spread client application requests over a number of servers through the use of ip rules with an action of slb_sat. Slb is a powerful tool that can improve the following aspects of network...

  • Page 481

    Figure 10.9. A server load balancing configuration additional benefits of slb besides improving performance and scalability, slb provides other benefits: • slb increases the reliability of network applications by actively monitoring the servers sharing the load. Netdefendos slb can detect when a ser...

  • Page 482

    Receiving over a certain time period. This time period is known as the window time. Slb sends the next request to the server that has received the least number of connections during the last window time number of seconds. The window time is a setting that the administrator can change. The default va...

  • Page 483

    The consequence of a full table can be that stickiness will be lost for any discarded source ip addresses. The administrator should therefore try to ensure that the max slots parameter is set to a value that can accommodate the expected number of connections that require stickiness. The default valu...

  • Page 484

    Figure 10.11. Stickiness and round-robin if the connection-rate algorithm is applied instead, r1 and r2 will be sent to the same server because of stickiness, but the subsequent requests r3 and r4 will be routed to another server since the number of new connections on each server within the window t...

  • Page 485

    10.4.6. Setting up slb_sat rules the key component in setting up slb are ip rules that have slb_sat as the action. The steps that should be followed for setting up such rules are: 1. Define an ip address object for each server for which slb is to enabled. 2. Define an ip address group object which i...

  • Page 486

    Web interface a. Create an object for each of the webservers: 1. Go to objects > address book > add > ip address 2. Enter a suitable name, for example server1 3. Enter the ip address as 192.168.1.10 4. Click ok 5. Repeat the above to create an object called server2 for the 192.168.1.11 ip address b....

  • Page 487

    1. Go to rules > ip rule sets > main > add > ip rule 2. Enter: • name: web_slb_alw • action: allow • service: http • source interface: any • source network: all-nets • destination interface: core • destination network: ip_ext 3. Click ok 10.4.6. Setting up slb_sat rules chapter 10. Traffic managemen...

  • Page 488

    10.4.6. Setting up slb_sat rules chapter 10. Traffic management 488.

  • Page 489: 11.1. Overview

    Chapter 11. High availability this chapter describes the high availability fault-tolerance feature in netdefend firewalls. • overview, page 489 • ha mechanisms, page 491 • setting up ha, page 494 • ha issues, page 498 • upgrading an ha cluster, page 500 • ha advanced settings, page 502 11.1. Overvie...

  • Page 490

    Interface and all other interfaces from one unit to the other. These packets allow the health of both units to be monitored. Heartbeat packets are sent in both directions so that the passive unit knows about the health of the active unit and the active unit knows about the health of the passive. The...

  • Page 491: 11.2. Ha Mechanisms

    11.2. Ha mechanisms this section discusses in more depth the mechanisms netdefendos uses to implement the high availability feature. Basic principles d-link ha provides a redundant, state-synchronized hardware configuration. The state of the active unit, such as the connection table and other vital ...

  • Page 492

    Failover time the time for failover is typically about one second which means that clients may experience a failover as a slight burst of packet loss. In the case of tcp, the failover time is well within the range of normal retransmit timeouts so tcp will retransmit the lost packets within a very sh...

  • Page 493

    Should such a failure occur then the consequence is that both units will continue to function but they will lose their synchronization with each other. In other words, the inactive unit will no longer have a correct copy of the state of the active unit. A failover will not occur in this situation si...

  • Page 494: 11.3. Setting Up Ha

    11.3. Setting up ha this section provides a step-by-step guide for setting up an ha cluster. 11.3.1. Ha hardware setup the steps for the setup of hardware in an ha cluster are as follows: 1. Start with two physically similar netdefend firewalls. Both may be newly purchased or an existing unit may ha...

  • Page 495

    The illustration below shows the arrangement of typical ha cluster connections in a network. All interfaces on the master unit would normally also have corresponding interfaces on the slave unit and these would be connected to the same networks. This is achieved by connecting the same interfaces on ...

  • Page 496

    4. Set the cluster id. This must be unique for each cluster. 5. Choose the sync interface. 6. Select the node type to be master. 7. Go to objects > address book and create an ip4 ha address object for each interface pair. Each must contain the master and slave interface ip addresses for the pair. Cr...

  • Page 497

    • if this is not the first cluster in a network then the cluster id must be changed for the cluster so that it is unique (the default value is 0). The cluster id determines that the mac address for the cluster is unique. • enabling the advanced setting use unique share mac is recommended so that eac...

  • Page 498: 11.4. Ha Issues

    11.4. Ha issues the following points should be kept in mind when managing and configuring an ha cluster. All cluster interfaces need ip addresses all interfaces on both ha cluster units should have a valid private ip4 address object assigned to them. The predefined ip object local host could be assi...

  • Page 499

    If ospf is to work then there must be another designated router available in the same ospf area as the cluster. Ideally, there will also be a second, backup designated router to provide ospf metrics if the main designated router should fail. Pppoe tunnels and dhcp clients for reasons connected with ...

  • Page 500

    11.5. Upgrading an ha cluster the netdefendos software versions running on the master and slave in an ha cluster should be the same. When a new netdefendos version becomes available and is to be installed on both units, the upgrade is done one unit at a time. The central principal in the upgrade pro...

  • Page 501

    Console and issue the ha -deactivate command. This will cause the active unit to become inactive, and the inactive to become active. Gw-world:/> ha -deactivate ha was: active ha going inactive... To check that the failover has completed successfully, an ha command can be issued again and the text "i...

  • Page 502

    11.6. Ha advanced settings the following netdefendos advanced settings are available for high availability: sync buffer size how much sync data, in kbytes, to buffer while waiting for acknowledgments from the cluster peer. Default: 1024 sync packet max burst the maximum number of state sync packets ...

  • Page 503

    11.6. Ha advanced settings chapter 11. High availability 503.

  • Page 504: Chapter 12. Zonedefense

    Chapter 12. Zonedefense this chapter describes the d-link zonedefense feature. • overview, page 504 • zonedefense switches, page 505 • zonedefense operation, page 506 12.1. Overview zonedefense controls switches zonedefense allows a netdefend firewall to control locally attached switches. It can be ...

  • Page 505: 12.2. Zonedefense Switches

    12.2. Zonedefense switches switch information regarding every switch that is to be controlled by the firewall has to be manually specified in the firewall configuration. The information needed in order to control a switch includes: • the ip address of the management interface of the switch • the swi...

  • Page 506: 12.3.1. Snmp

    12.3. Zonedefense operation 12.3.1. Snmp simple network management protocol (snmp) is an application layer protocol for complex network management. Snmp allows the managers and managed devices in a network to communicate with each other. Snmp managers a typical managing device, such as a netdefend f...

  • Page 507

    As a complement to threshold rules, it is also possible to manually define hosts and networks that are to be statically blocked or excluded. Manually blocked hosts and networks can be blocked by default or based on a schedule. It is also possible to specify which protocols and protocol port numbers ...

  • Page 508: 12.3.5. Limitations

    2. For addresses choose the object name of the firewall's interface address 192.168.1.1 from the available list and put it into the selected list. 3. Click ok configure an http threshold of 10 connections/second: 1. Go to traffic management > threshold rules > add > threshold rule 2. For the thresho...

  • Page 509

    Of latency time to implement blocking once the rule is triggered. Some models can activate blocking in less than a second while some models may require a minute or more. A second difference is the maximum number of rules supported by different switches. Some switches support a maximum of 50 rules wh...

  • Page 510

    12.3.5. Limitations chapter 12. Zonedefense 510

  • Page 511: 13.1. Ip Level Settings

    Chapter 13. Advanced settings this chapter describes the additional configurable advanced settings for netdefendos that are not already described in the manual. In the web interface these settings are found under system > advanced settings. The settings are divided up into the following categories: ...

  • Page 512

    Block 0000 src block 0.0.0.0 as source address. Default: drop block 0 net block 0.* as source addresses. Default: droplog block 127 net block 127.* as source addresses. Default: droplog block multicast src block multicast both source addresses (224.0.0.0 - 255.255.255.255). Default: droplog ttl min ...

  • Page 513

    Default: validatelogbad securemoteudp compatibility allow ip data to contain eight bytes more than the udp total length field specifies. Checkpoint securemote violates nat-t drafts. Default: disabled ip option sizes verifies the size of "ip options". These options are small blocks of information tha...

  • Page 514

    Ip reserved flag indicates what netdefendos will do if there is data in the "reserved" fields of ip headers. In normal circumstances, these fields should read 0. Used by os fingerprinting. Default: droplog strip dontfragment strip the don't fragment flag for packets equal to or smaller than the size...

  • Page 515: 13.2. Tcp Level Settings

    13.2. Tcp level settings tcp option sizes verifies the size of tcp options. This function acts in the same way as ipoptionsizes described above. Default: validatelogbad tcp mss min determines the minimum permissible size of the tcp mss. Packets containing maximum segment sizes below this limit are h...

  • Page 516

    Tcp auto clamping automatically clamp tcp mss according to mtu of involved interfaces, in addition to tcpmssmax. Default: enabled tcp zero unused ack determines whether netdefendos should set the ack sequence number field in tcp packets to zero if it is not used. Some operating systems reveal sequen...

  • Page 517

    Initially intended to be used in negotiating for the use of better checksums in tcp. However, these are not understood by any today's standard systems. As netdefendos cannot understand checksum algorithms other than the standard algorithm, these options can never be accepted. The altchkreq option is...

  • Page 518

    Tcp syn/fin the tcp fin flag together with syn; normally invalid (strip=strip fin). Default: droplog tcp fin/urg specifies how netdefendos will deal with tcp packets with both fin (finish, close connection) and urg flags turned on. This should normally never occur, as it is not usually attempted to ...

  • Page 519

    Tcp sequence number validation is only possible on connections tracked by the state-engine (not on packets forwarded using a fwdfast rule). Possible values are: ignore - do not validate. Means that sequence number validation is completely turned off. Validatesilent - validate and pass on. Validatelo...

  • Page 520: 13.3. Icmp Level Settings

    13.3. Icmp level settings icmp sends per sec limit specifies the maximum number of icmp messages netdefendos may generate per second. This includes ping replies, destination unreachable messages and also tcp rst packets. In other words, this setting limits how many rejects per second may be generate...

  • Page 521: 13.4. State Settings

    13.4. State settings connection replace allows new additions to the netdefendos connection list to replace the oldest connections if there is no available space. Default: replacelog log open fails in some instances where the rules section determines that a packet should be allowed through, the state...

  • Page 522

    Default: log log connection usage this generates a log message for every packet that passes through a connection that is set up in the netdefendos state-engine. Traffic whose destination is the netdefend firewall itself, for example netdefendos management traffic, is not subject to this setting. The...

  • Page 523

    13.5. Connection timeout settings the settings in this section specify how long a connection can remain idle, that is to say with no data being sent through it, before it is automatically closed. Please note that each connection has two timeout values: one for each direction. A connection is closed ...

  • Page 524

    Other idle lifetime specifies in seconds how long connections using an unknown protocol can remain idle before it is closed. Default: 130 13.5. Connection timeout settings chapter 13. Advanced settings 524.

  • Page 525

    13.6. Length limit settings this section contains information about the size limits imposed on the protocols directly under ip level, such as tcp, udp and icmp. The values specified here concern the ip data contained in packets. In the case of ethernet, a single packet can contain up to 1480 bytes o...

  • Page 526

    Specifies in bytes the maximum size of an ah packet. Ah, authentication header, is used by ipsec where only authentication is applied. This value should be set at the size of the largest packet allowed to pass through the vpn connections, regardless of its original protocol, plus approx. 50 bytes. D...

  • Page 527

    13.7. Fragmentation settings ip is able to transport up to 65536 bytes of data. However, most media, such as ethernet, cannot carry such huge packets. To compensate, the ip stack fragments the data to be sent into separate packets, each one given their own ip header and information that will help th...

  • Page 528

    Default: check8 – compare 8 random locations, a total of 32 bytes failed fragment reassembly reassemblies may fail due to one of the following causes: • some of the fragments did not arrive within the time stipulated by the reasstimeout or reasstimelimit settings. This may mean that one or more frag...

  • Page 529

    • nolog - no logging is carried out under normal circumstances. • logsuspect - logs duplicated fragments if the reassembly procedure has been affected by "suspect" fragments. • logall - always logs duplicated fragments. Default: logsuspect fragmented icmp other than icmp echo (ping), icmp messages s...

  • Page 530

    Reassembly illegal limit once a whole packet has been marked as illegal, netdefendos is able to retain this in memory for this number of seconds in order to prevent further fragments of that packet from arriving. Default: 60 13.7. Fragmentation settings chapter 13. Advanced settings 530

  • Page 531

    13.8. Local fragment reassembly settings max concurrent maximum number of concurrent local reassemblies. Default: 256 max size maximum size of a locally reassembled packet. Default: 10000 large buffers number of large ( over 2k) local reassembly buffers (of the above size). Default: 32 13.8. Local f...

  • Page 532

    13.9. Miscellaneous settings udp source port 0 how to treat udp packets with source port 0. Default: droplog port 0 how to treat tcp/udp packets with destination port 0 and tcp packets with source port 0. Default: droplog watchdog time number of non-responsive seconds before watchdog is triggered (0...

  • Page 533

    13.9. Miscellaneous settings chapter 13. Advanced settings 533.

  • Page 534: Overview

    Appendix a. Subscribing to updates overview the netdefendos anti-virus (av) module, the intrusion detection and prevention (idp) module and the dynamic web content filtering module all function using external d-link databases which contain details of the latest viruses, security threats and url cate...

  • Page 535

    An anti-virus update can similarly be initiated with the command: gw-world:/> updatecenter -update antivirus querying update status to get the status of idp updates use the command: gw-world:/> updatecenter -status idp to get the status of av updates: gw-world:/> updatecenter -status antivirus query...

  • Page 536

    Appendix b. Idp signature groups for idp scanning, the following signature groups are available for selection. These groups are only available for the d-link advanced idp service. There is a version of each group under the three types of ids, ips and policy. For further information see section 6.5, ...

  • Page 537

    Group name intrusion type ftp_formatstring format string attack ftp_general ftp protocol and implementation ftp_login login attacks ftp_overflow ftp buffer overflow game_bomberclone bomberclone game game_general generic game servers/clients game_unreal unreal game server http_apache apache httpd htt...

  • Page 538

    Group name intrusion type pop3_dos denial of service for pop pop3_general post office protocol v3 pop3_login-attacks password guessing and related login attack pop3_overflow pop3 server overflow pop3_request-errors request error portmapper_general portmapper print_general lp printing server: lpr lpd...

  • Page 539

    Group name intrusion type tftp_operation operation attack tftp_overflow tftp buffer overflow attack tftp_reply tftp reply attack tftp_request tftp request attack trojan_general trojan udp_general general udp udp_popup pop-up window for ms windows upnp_general upnp version_cvs cvs version_svn subvers...

  • Page 540

    Appendix c. Verified mime filetypes some netdefendos application layer gateways (algs) have the optional ability to verify that the contents of a downloaded file matches the type that the filetype in the filename indicates. The filetypes for which mime verification can be done are listed in this app...

  • Page 541

    Filetype extension application cpl windows control panel extension file dbm database file dcx graphics multipage pcx bitmap file deb debian linux package file djvu djvu file dll windows dynamic link library file dpa dpa archive data dvi tex device independent document eet eet archive egg allegro dat...

  • Page 542

    Filetype extension application mpv mpeg-1 video file microsoft files microsoft office files, and other microsoft files msa atari msa archive data niff, nif navy interchange file format bitmap noa nancy video codec nsf nes sound file obj, o windows object file, linux object file ocx object linking an...

  • Page 543

    Filetype extension application tfm tex font metric data tiff, tif tagged image format file tnef transport neutral encapsulation format torrent bittorrent metainfo file ttf truetype font txw yamaha tx wave audio files ufa ufa archive data vcf vcard file viv vivoactive player streaming video file wav ...

  • Page 544

    Appendix d. The osi framework overview the open systems interconnection model defines a framework for inter-computer communications. It categorizes different protocols for a great variety of network applications into seven smaller, more manageable layers. The model describes how data from an applica...

  • Page 545: Alphabetical Index

    Alphabetical index a access rules, 242 accounting, 62 interim messages, 64 limitations with nat, 65 messages, 62 system shutdowns, 65 address book, 80 ethernet addresses in, 82 folders, 84 ip addresses in, 80 address groups, 83 excluding addresses, 83 address translation, 340 admin account, 29 chang...

  • Page 546

    Banner files in user authentication, 379 in web content filtering, 312 blacklisting hosts and networks, 337 threshold rules, 478 urls, 298 wildcarding, 298 with idp, 327 block 0000 src setting, 511 block 0 net setting, 512 block 127 net setting, 512 blocking applications with idp, 320 block multicas...

  • Page 547

    Pcapdump, 72 diffie-hellman (see dh groups) diffserv, 451 directed broadcasts setting, 513 distance vector algorithms, 176 dmz, 349 dns, 144 dynamic lookup, 144 dns black lists for spam filtering, 263 documentation, 18 dos attack (see denial of service) downloading files with scp, 46 dpd expire time...

  • Page 548

    Http uri normalization in idp, 323 i icmp sends per sec limit setting, 520 icmp unreachable message, 125 ident and ip rules, 125 identification lists, 409 idp, 320 blacklisting, 327 http uri normalization, 323 signature groups, 326 signatures, 325 signature wildcarding, 327 smtp log receivers, 328 t...

  • Page 549

    Advanced settings, 61 memlog, 58 snmp traps, 60 syslog, 58 login authentication, 372 log messages, 57 log non ip4 setting, 511 log open fails setting, 521 logout at shutdown (radius) setting, 65, 66 logout from cli, 41 log oversized packets setting, 526 log received ttl 0 setting, 511 log reverse op...

  • Page 550

    Port forwarding (see sat) port mirroring (see pcapdump) ppp authentication with ldap, 370 pppoe, 105 client configuration, 105 unnumbered support, 106 with ha, 106 pptp, 431 advanced settings, 436 alg, 269 client, 437 problem with nat, 438 quick start guide, 395 server, 431 pptp before rules setting...

  • Page 551

    Log receiver with idp, 328 whitelist precedence, 260 snmp advanced settings, 70 community string, 69 mib, 69 monitoring, 69 traps, 60 with ip rules, 69 snmp before rules setting, 70 snmp request limit setting, 70, 71 source based routing, 165 spam filtering, 262 caching, 266 logging, 265 tagging, 26...

  • Page 552

    V validation timeout setting, 50 virtual lan (see vlan) virtual private networks (see vpn) vlan, 101 advanced settings, 104 license limitations, 103 port based, 102 trunk, 102 voice over ip with h.323, 280 with sip, 270 voip (see voice over ip) vpn, 383 planning, 384 quick start guide, 387 troublesh...