SafeNet Setup guides
Guides / MikroTik

MikroTik routers

Connect a MikroTik hotspot to SafeNet with one script. Vouchers, customer accounts and speed limits.

Guest's phone
→
MikroTik hotspot
→
Internet
MikroTik
⇄
SafeNetsecure VPN tunnel

Your MikroTik keeps running its own hotspot and login page. SafeNet adds a secure VPN tunnel to the router, and the router asks SafeNet whether each voucher code or customer account is valid, how long it lasts and how fast it may go. It works from any internet connection, even without a fixed public IP.

What you need

1. Set up the hotspot on the MikroTik

If the router already runs a hotspot, skip this. Otherwise, in Winbox: IP → Hotspot → Hotspot Setup, choose the interface guests connect to (usually the bridge or Wi-Fi), and accept the defaults. Skip creating a local hotspot user.

2. Add the router in SafeNet

  1. Pick the siteChoose the site in SafeNet's top bar.
  2. Add the routerOpen Routers (VPN), type a name (for example "Kariakoo hotspot"), choose MikroTik, and click Add router.
  3. Copy the scriptSafeNet shows a setup script made for this router. Click Copy script. Keep it private: it contains the router's VPN key and RADIUS secret.

3. Paste the script into the router

  1. Open a terminalIn Winbox or WebFig, click New Terminal.
  2. Paste and runPaste the whole script and press Enter. It creates the VPN tunnel, points the hotspot at SafeNet, and allows one device per code.
  3. Check the connectionRun:
    /interface wireguard peers print
    A recent "last-handshake" means the tunnel works. Within a minute the router shows as Connected on SafeNet's Routers page.

4. Test it

  1. Make a voucherIn SafeNet: Vouchers → Generate, one voucher for 1 hour.
  2. Log inJoin the hotspot Wi-Fi. On the MikroTik login page, type the voucher code as both the username and the password.
  3. See it in SafeNetThe session appears on the Live page with its data usage.

Speed limits from your SafeNet plans are sent to the MikroTik automatically. Buying packages with mobile money on the login page is available with Omada access points and the SafeNet gateway box; on MikroTik, sell vouchers.