This cookbook will provide the integration guide to make mikrotik platform work with kiwire system.
The guide are provided using the Mikrotik Winbox program as an interface with the RouterOS. The Winbox program can be obtained from the MikroTik website – http://www.mikrotik.com/download)
Basic Router Setup
Before you follow the instructions in this guide it’s important that you decide which port you will assign the role of WAN, and whether you plan to use the inbuilt WiFi for the hotspot or one of the LAN ports in conjunction with additional APs
The WAN port is where you connect the MikroTik to your existing router, for our guide we use Ethernet port 1 on the router –
Click on IP > DHCP Client
Click on the “+” and enter the below setting
Select the interface you want to be the WAN port.
Click on System > NTP Client. Enter primary and secondary NTP servers. To find NTP servers, go to http://www.pool.ntp.org/ and select the location’s continent on the right side of the page. You’ll find NTP servers there.
Be sure to leave TimeZoneName: manual, and TimeZone: 00:00 in System > Clock. (Don’t set your own timezone, because the router has to show the GMT time!)
You need to change the router’s NASID. The NASID setting in the Mikrotik is located under System > Identity. Default is ‘MikroTik’.
To enable the mikrotik Hotspot to redirect the user traffic to kiwire , please upload the 2 files bellow into the Hotspot folder in mikrotik. This folder can be access by using the files function and drag and drop the 2 files into it.
IP DHCP via RADIUS
To enable dhcp server assignment to users using the kiwire policy dhcp profile , you are require to configure Mikrotik DHCP to use Radius as its primary source of lease control . the step involved are :
- Make sure “Use RADIUS” is checked in the setting for the DHCP server under
IP-> DHCP SERVER
2 . Make sure Radius server setting DHCP is checked. under “RADIUS”
Wallgarden/Whitelist for Mikrotik
In the IP > Hotspot menu, it is necessary to open the Walled Garden tab and specify which sites the end-user will be able to visit without being authenticated.
It is mandatory to add the Welcome Portal URL into this list (see Mikrotik), otherwise the end-user will not be able to visit the authentication page. Furthermore, you must allow the following Dst. Host values:
Use DNS instead of ip for hotspot login
- Click on the ip->DNS then enter the mikrotik ip address in the server
Eg: Mikrotik ip address:192.168.0.8 , Kiwire ip address: 192.168.2.201
- Click on the static button , Enter a hostname then bind with kiwire ip address.
- Click on DHCP Server .Select Network tab and add Domain Every DHCP network will be assign with a different Domain
- Edit login.html as below
The schedule script will enable automatic download of wallgarden list and firewall list into the mikrotik nas on an interval.
- Login to winbox
- Go to System > Scheduler and add a new task by pressing the plus sign.
- Under the field Name type “firewall”
- set the Interval to 01:00:00
- Paste the following text into it, replace the ip of “192.168.0.202” with your kiwire server ip.