User Tools

Site Tools


IWD & AP Mode

iwd supports very basic AP mode functionality.

Hotspot / Connection Sharing Example

The easiest way to set this up is to create a new Access Point profile. For detailed documentation of all properties, please refer to 'man 5 iwd.ap'. First create '/var/lib/iwd/ap' directory if it doesn't exist yet:

# sudo mkdir -p /var/lib/iwd/ap/

Then place the following contents in the file /var/lib/iwd/ap/<ssid>.ap where <ssid> will be used as the SSID of the Access Point when it is started:



With iwd started, start iwctl and switch your device into ap mode, then start the AP mode with the just-created profile:

[iwd]# device wlan0 set-property Mode ap
[iwd]# ap wlan0 start-profile test

Set up NAT:

# sudo sysctl -w net.ipv4.ip_forward=1
net.ipv4.ip_forward = 1
# sudo iptables -t nat -A POSTROUTING -s -j MASQUERADE

You should now be able to connect to SSID 'test' and be able to reach whatever outside world that the box running the access point mode can reach.

ap_mode.txt · Last modified: 2021/05/26 23:27 by Denis Kenzior