Why isolate WiFi clients?

Because on an open network, or even one just shared with guests, the person at the next table is one step away from your smartphone: file shares, printers, services left open. With isolation on, the access point doesn’t forward traffic from one wireless client to another: each one sees only the router and the internet.

How do you turn it on with the RouterOS 7 wifi package?

The wifi package gathers settings into reusable profiles. The one we care about is in the datapath:

/interface wifi datapath add name=dp-ospiti bridge=bridge-ospiti client-isolation=yes
/interface wifi configuration add name=cfg-ospiti ssid="Guests" mode=ap \
    datapath=dp-ospiti security.authentication-types=wpa2-psk,wpa3-psk security.passphrase="changeme"
/interface wifi set [find default-name=wifi1] configuration=cfg-ospiti disabled=no

The same configuration is used with the CAPsMAN of the wifi package: you assign cfg-ospiti to the access points through the provisioning rules, and every AP that receives it isolates its clients.

/interface wifi capsman set enabled=yes interfaces=bridge-ospiti
/interface wifi provisioning add action=create-dynamic-enabled master-configuration=cfg-ospiti \
    supported-bands=2ghz-ax,2ghz-n,5ghz-ax,5ghz-ac

And with the old wireless package?

On devices that still use wireless, isolation on a single access point is achieved by removing default forwarding on the interface:

/interface wireless set [find default-name=wlan1] default-forwarding=no

With the “legacy” CAPsMAN (v1, the /caps-man menu) it was the datapath, as in the original 2015 article:

/caps-man datapath set [find name=datapath1] client-to-client-forwarding=no

Does isolation apply across different access points too?

This is the point people trip over most. client-isolation blocks traffic between clients of the same access point. If the APs forward traffic locally in their bridge (local forwarding), two clients on two different APs can still see each other through the wired network.

To close that path too there are two options:

  • send all guest traffic through the central router, on a dedicated VLAN, and filter it there;
  • use the bridge horizon on the ports toward the APs: ports with the same horizon value don’t exchange traffic with each other.
    /interface bridge port set [find interface=ether2] horizon=1
    /interface bridge port set [find interface=ether3] horizon=1

With horizon=1 on both, what comes in on ether2 doesn’t go out on ether3 and vice versa: the access points talk only to the router.

How do I check that it works?

With two smartphones on the guest network: from one, try a ping to the other’s address (you read it in the DHCP leases). With isolation on, the ping gets no answer, while browsing still works.

/ip dhcp-server lease print where server=dhcp-ospiti
/interface wifi registration-table print

Frequently asked questions

Where do you enable client isolation in RouterOS 7?

With the wifi package you enable it in the datapath, with client-isolation=yes, and the datapath is assigned to the interface’s or the CAPsMAN’s configuration.

Does client isolation also block internet access?

No. Client isolation blocks only direct traffic between wireless clients; traffic to the router and therefore to the internet goes through normally.

Are two clients on different access points isolated?

Not necessarily. Client isolation acts on the single access point; to isolate clients connected to different APs as well, you need a dedicated VLAN filtered by the router or the bridge horizon on the ports toward the APs.

What did client-to-client-forwarding do?

It was the datapath option of the legacy CAPsMAN in RouterOS 6 (the /caps-man menu): set to no, it stopped clients of the same access point from talking to each other.

This howto updates to RouterOS 7 a 2015 article from my old blog wirelessguru.it, now offline.