Wi-Fi Protected Setup#
Wi-Fi Protected Setup (WPS) is a standard for easy and secure wireless network setup and connections. The OSD driver supports the following configuration method:
Push Button Method
WPS uses the following terms to describe the entities participating in the network setup:
Access Point: WLAN access point
Registrar: A device that controls a network and can authorize addition of new devices. This may be either in the AP ("internal Registrar") or in an external device, e.g., a laptop, ("external Registrar")
Enrollee: A device that is being authorized to use the network
It should also be noted that the AP and a client device may change roles (i.e., AP acts as an Enrollee and client device as a Registrar) when WPS is used to configure the access point.)
STA Mode WPS Configuration#
A WPS Configuration file is used for setting up a connection with a remote Access Point. A sample WPS configuration file is given below for reference.
ctrl_interface=/var/run/wpa_supplicant
update_config=1
uuid=12345678-9abc-def0-1234-56789abcdef0
device_name=RSI_P2P_DEVICE
manufacturer=Redpine Signals, Inc.model_name=M2MCombo
model_number=9117
serial_number=03
device_type=1-0050F204-1
os_version=01020300
config_methods=display push_button keypad
The steps for configuring WPS in Client mode are as follows:
Start the driver in Client mode.
To start the supplicant, run the following command without any network block:
# wpa_supplicant -i <vap_name> -D nl80211 -c <wps_conf_file> -ddddt
For Push Button method:
Push the button on the Access Point
run the following command for the n-Link® STA
# wpa_cli -i <vap_name> -p <path of ctrl sockets> wps_pbc <bssid>
This is the Access Point's MAC address. If the BSSID is not known, the input parameter will be the string named "any"
Wait for the STA to parse all the WPS Access Points.
AP Mode WPS Push Button Configuration
WPS support is not enabled in default Hostapd application. Enable the below configuration in hostpad build configuration (.config) and compile hostpad.
CONFIG_WPS=y
CONFIG_WPS_UPNP=y
Enable the changes below in hostpad configuration file.
wpa_key_mgmt=WPA-PSK
wpa_psk_file=/etc/hostapd.psk
eap_server=1<br>wps_state=2
ap_setup_locked=1<br>uuid=12345678-9abc-def0-1234-56789abcdef0<br>device_name=SiWx917_n-Link
model_name=OneBox-Mobile
serial_number=000000000001<br>device_type=1-0050F204-1
os_version=01020300<br>config_methods=display push_button keypad
The steps for configuring WPS in AP mode are as follows:
Start the driver in AP mode.
Start the Hostapd with configuration file as input (ex: ap.conf), as given below.
# hostapd ap.conf –dddt > log_file &
Run the following command for push button. This pbc mode lasts up to two minutes, within two minutes a client needs to be connected else AP will move out of WPS-PBC.
# hostapdcli wps_pbc
For station in WPS-PBC user can follow the steps in STA mode WPS configuration section and try connecting with AP .