Using ZeroShell as a NetBalancer, QoS server & Captive Portal.



Similar documents
Zero Shell Implementation Scenarios

1:1 NAT in ZeroShell. Requirements. Overview. Network Setup

Zeroshell as filtering bridge with connection tracking log and HAVP proxy

Netgear TA612VMNF & TA612VLD Netgear WGR613VAL. Quality of Service (QOS) function

REQUIREMENTS AND INSTALLATION OF THE NEFSIS DEDICATED SERVER

Table of Contents 1. Introduction Installing Sxblue Server Principle of Operation Server Configuration

Application Description

PowerLink Bandwidth Aggregation Redundant WAN Link and VPN Fail-Over Solutions

DSL-G604T Install Guides

Multi-Homing Dual WAN Firewall Router

Com.X Router/Firewall Module. Use Cases. White Paper. Version 1.0, 21 May Far South Networks

Firewall VPN Router. Quick Installation Guide M73-APO09-380

NEFSIS DEDICATED SERVER

Virtual Server in SP883

Load Balance Mechanism

QoS (Quality of Service)

Best Practices: Pass-Through w/bypass (Bridge Mode)

Penetration Testing LAB Setup Guide

Setting up and creating a Local Area Network (LAN) within Windows XP by Buzzons

Shield Pro. Quick Start Guide

Cyclope Internet Filtering Proxy. - Installation Guide -

Installation Guide For Choic Enterprise Edition

Firewall Security: Policies, Testing and Performance Evaluation

How Subnets Work in Practice. Fred Marshall Coastal Computers & Networks

Network Terminology Review

VPN Configuration Guide. Linksys (Belkin) LRT214 / LRT224 Gigabit VPN Router

SETTING UP REMOTE ACCESS ON EYEMAX PC BASED DVR.

Setting up pfsense as a Stateful Bridging Firewall.

Chapter 2 Connecting the FVX538 to the Internet

D-Link Central WiFiManager Configuration Guide

How to configure your Thomson SpeedTouch 780WL for ADSL2+

USB Functions for Windows 7

StorSimple Appliance Quick Start Guide

DRO-210i LOAD BALANCING ROUTER. Review Package Contents

Chapter 15: Advanced Networks

Configuring Static IP for your Pace Devices

Sophos UTM Software Appliance

How to configure DNAT in order to publish internal services via Internet

Firewall Design Principles Firewall Characteristics Types of Firewalls

MULTI WAN TECHNICAL OVERVIEW

In this lab you will explore the Windows XP Firewall and configure some advanced settings.

You can attach accounts to this domain name (eg. or which also increases your corporate branding.

Using SonicWALL NetExtender to Access FTP Servers

Quick Start Guide. Cerberus FTP is distributed in Canada through C&C Software. Visit us today at

Websense Web Security Gateway: What to do when a Web site does not load as expected

Introduction. Just So You Know... PCI Can Be Difficult

Steltronic Focus. Main Desk Internet connection

Chapter 3 Security and Firewall Protection

Cyclope Internet Filtering Proxy

Setting Up Your Personally- Owned Computer

Edgewater Routers User Guide

Lab - Configure a Windows XP Firewall

6.0. Getting Started Guide

Getting Started with PRTG Network Monitor 2012 Paessler AG

Ecessa Proxy VoIP Manual

NetSpective Global Proxy Configuration Guide

Broadband Phone Gateway BPG510 Technical Users Guide

Draytek Vigor 2820/2830 Configuration. A guide for Exa Resellers and IT Contractors

About Firewall Protection

Point to Point Broadband Internet Service Business

Client Configuration Guide

INTERNET SECURITY: THE ROLE OF FIREWALL SYSTEM

Load Balancing. Outlook Web Access. Web Mail Using Equalizer

Setting up VNC, SAMBA and SSH on Ubuntu Linux PCs Getting More Benefit out of Your Local Area Network

Fireware XTM Traffic Management

Using Protection Engine for Cloud Services for URL Filtering, Malware Protection and Proxy Integration Hands-On Lab

GFI Product Manual. Web security, monitoring and Internet access control. Administrator Guide

Before You Begin, Your Computer Must Meet the System Requirements

Edgewater Routers User Guide

Configuring WAN Failover & Load-Balancing

Configuring the BIG-IP and Check Point VPN-1 /FireWall-1

Creating your fi rst CloudTrax network

Vega 100G and Vega 200G Gamma Config Guide

Half Bridge mode }These options are all found under Misc Configuration

Quickstart guide to Configuring WebTitan

Chapter 4 Firewall Protection and Content Filtering

The PostBase Connectivity Wizard

N-CAP Users Guide Everything You Need to Know About Using the Internet! How Firewalls Work

EZblue BusinessServer The All - In - One Server For Your Home And Business

Quick Start. Nighthawk X8 AC5300 Tri-Band WiFi Router Model R8500. Package Contents. NETGEAR, Inc. 350 East Plumeria Drive San Jose, CA USA

Linux Squid Proxy Server

Quick Installation Guide

Using a VPN with Niagara Systems. v0.3 6, July 2013

EZblue BusinessServer The All - In - One Server For Your Home And Business

Step-by-Step Configuration

PaperStream Connect. Setup Guide. Version Copyright Fujitsu

Setting Up Your Personally- Owned Computer

Management Software. Web Browser User s Guide AT-S106. For the AT-GS950/48 Gigabit Ethernet Smart Switch. Version Rev.

Introduction. What is a Remote Console? What is the Server Service? A Remote Control Enabled (RCE) Console

Internet Services. Amcom. Support & Troubleshooting Guide

Software installation and configuration IEC-line series

Smart Tips. Enabling WAN Load Balancing. Key Features. Network Diagram. Overview. Featured Products. WAN Failover. Enabling WAN Load Balancing Page 1

Campus VPN. Version 1.0 September 22, 2008

Quick Start Guide. Installation and Setup

What is Bitdefender BOX?

WEBTITAN CLOUD. User Identification Guide BLOCK WEB THREATS BOOST PRODUCTIVITY REDUCE LIABILITIES

Explaining DMZ s and Port Forwarding for home networking, broadband routers, and NAT connection sharing. First some definitions (greatly simplified)

Barracuda Link Balancer Administrator s Guide

Broadband Services from MTNL. User's Guide

Transcription:

Using ZeroShell as a NetBalancer, QoS server & Captive Portal. (Among other things) By Jose Menendez orallo at gmail dot com

Acknowledgments: Let me start this document by thanking all the people that works or contributes to this magnificent piece of software, starting by Fulvio Ricciardi and extending those thanks to all the people that contributed documents or participates on the ZeroShell forums, particularly Atheling for all the help he gave me personally and his fix for the NetBalancer/QoS combo. My Scenario: I m by no means a network guru, I am a programmer by training and by trade. I work at a small/medium company where we have no network administrator so the IT department (two programmers) has been put in charge of anything and everything computer related. We have a LAN with about 60/70 computers. Off of those computers most do administrative tasks via a web interface, some do some FTP traffic and the most critical application on our office is that several times a week we broadcast a web conference to students. Our internet connection is based on two adsl lines one with 18MB download speed and 800kbps upload speed and the other line with 6MB download speed with 400kbps upload speed. When we started we had manually assigned IPs on each computer some on router 1 and some our router 2. Basically we left the broadcasting studio alone on router 2 to guarantee that nobody on the LAN would steal their bandwidth in the middle of a class. The Goals: We basically need to accomplish 3 things. First we need to provide internet service to all the users on the LAN consistently (regardless of the fact that one or the other DSL line might go down once in a while) Second we need to guarantee that the broadcasting studio has always enough bandwidth to broadcast the classes. And Lastly we need to implement some basic HTTP proxy with a blacklist of sites and a captive portal so all the users are aware that they are connected to the internet via a company computer.

The ZeroShell Solution: I m not going to go into much detail on the basic installation of ZeroShell, because it is simple enough and most important there is plenty of documentation about it. We installed ZS on a computer with two inexpensive 100Mb/s full duplex RTL 8139/8139C/8139C+ network cards one facing the LAN and the other one facing the WAN. The LAN is going to be on the 172.16.1.XXX segment and the routers each will stay with their current configuration, DSL1 will stay on 192.168.1.1 and DSL2 will stay on 192.168.2.1. Here is a basic diagram of our network layout Note 1 It has been pointed out that ZS should be physically placed between the routers and the switches to make sure no client changes his/her network configuration and bypasses the ZS setup. We partially agree with this notion, but right now it is not an option for us, the only place where we can place the ZS box is in our office. And our users do not have administrator rights so they can t really change their network settings. First we proceed to the NIC configuration by going to the System/Setup/Network tab on the web interface, and we Add IP 172.16.1.1/255.255.255.0 to ETH00 and we add IPs 192.168.1.254/255.255.255.0 and 192.168.2.254/255.255.255.0 to ETH01. ETH00 will face the LAN and ETH01 will face the internet routers.

The first goal is to provide Net Balancing on our two internet connections so if for some reason one of the DSL connections goes down, all the users on the LAN can still work so we go to the Network/NetBalancer/Manage tab enabled the checkmark to make the net balancing active and added our two routers. We clicked on Add, then we gave each router/gateway a name, entered the IP address of each router and clicked on Save. Then we disabled the default gateway that ZS adds by default. So now the NetBalancer looks like this:

Then we proceeded to enable the ICMP failover checking, to accomplish this, we added some IPs to the Failover IP Addresses list (we added, one of google s IPs, one of cnn.com s and one of yahoo s if I remember correctly). One side note to the NetBalancing, since we had put NB in place, some users experienced some problems using some sites that require authentication, in particular I had problems managing some websites using Plesk as the interface and one user had problems using a particular web forum based on some software package called mvnforum. The solution to this problem is going to the NetBalancing, balancing rules and creating a rule that sends those users always through the same gateway regardless. Apparently Plesk and mvnforum check the IP headers and if a user goes through one gateway one minute and the other gateway 5 minutes later they lose the authentication So first goal accomplished!!! On to the next goal, QoS. Reading through the ZS forums we found out that there was a glitch on ZS that makes that you can t use Net Balancing AND QoS at the same time. I had some contacts on the forum with Atheling, as he answered some of my posts. On one of his posts he said that he had created a patch to fix the QoS/NB conflict, so I asked him if I could get a copy. He was kind enough to send it to me, so I installed it and proceeded to test it, and it works like a charm! The patch that Atheling created can be found on the ZeroShell forums on the following thread: http://www.zeroshell.net/eng/forum/viewtopic.php?t=2125 Note 2 I installed the patch by first copying the patch to the kerbynet.cgi folder and issuing the following command:

patch p0 < Zeroshell.3.patch Then the system responded with: patching file scripts/fw_initrules patching file scripts/fw_makerule patching file scripts/fw_start patching file scripts/fw_viewchain patching file scripts/nb_fw patching file scripts/nb_setautomarking Then to make the changes permanent, since most of the system resides on RAM and its reloaded every time the system is rebooted, I made a copy of the patched files and placed them on a folder I created under /Database which is on the HDD and therefore does not disappear on reboot, and I put the following script on the preboot script on the cron tab. for file in /Database/custom/* do cp ${file} /root/kerbynet.cgi/scripts/ done So first we created some classes to group users by, we created seven groups based on the type of activities that each user does and the physical location within the building. We had segmented the LAN by location/ip so this came in handy. For example each classroom has its own consecutive IP range, the broadcast studio has another consecutive IP range, the reception area has its own consecutive IP range, etc, etc This is what our class manager looks like now: Note 3 The bandwidths are managed manually for now on the interface manager until we fine tune the numbers via trial and error so the numbers on the class manager are not representative.

Next we added the classifying rules on the classifier, by clicking add, entering the IP ranges for each range, and assigning them to a TARGET CLASS at the bottom of the configuration screen. Then we went back to the Interface Manager of the QoS and enabled the newly created classes with their rules. And voilá, we had QoS up and running. Setting up the Captive Portal: For our needs we don t need to create a user account for each user that logs into the system, management just want users to be aware that they are connected to the internet via a company computer in the hopes that they will feel monitored and they will be on their best behavior while on the internet at work. So we created a generic usuario account that all the users on the LAN share and use to connect to the internet via the captive portal.

Then we enable local authentication on the captive portal and added some items to the Free Authorized Services area at the bottom of the captive portal. We added one for the office printer opening port 9100 for it and some other ports that are used to connect to our mail servers. Later we went on to the Language tab and translated the portal to Spanish.

Finally we needed to setup a list of sites that are not to be accessed from our LAN. So we went to the HTTP Proxy area of ZS, enabled it and went to the Blacklist manager and entered the list of sites that management wants blocked. Then we added a general rule to capture the LAN traffic on ETH00 and some exceptions (not capture) for the people that are authorized to be off the proxy and get unrestricted web access and we are done with our third and last goal. Note 4 Since we were at it, we added ClamAV protection to our LAN by simply enabling the Virus Scanning via the drop list, selecting the number of updates per day and selecting the mirror for our country. Conclusions: In general ZeroShell was a breeze to install, we had some minor issues with the storage, but pretty much everything is documented on the ZeroShell site and/or the ZeroShell forums. Chances are that if you run into a problem while installing it, someone has had the problem before, fixed it and documented it. Configuring ZeroShell was also easy, we think that if we had a better background in network stuff we wouldn t have had most of the problems we had, and even so, it was just a matter of

reading a lot of documentation and posts of the forums to find out what each thing was supposed to do, and how it did it and then just translating that to ZeroShell. I hope this manual helps people with goals similar to the ones we had, and if anything needs to be clarified, corrected or removed from this document, do not hesitate to contact me at orallo at gmail dot com and will do so as soon as possible. Finally I would like to reiterate our thanks to Mr. Fulvio Ricciardi for this excellent piece of software and we look forward to future updates that will hopefully include even more and better features if that s even possible. Thank You.