Wi-Fi Configuration (wpa_pps)

Updated: April 19, 2023

PPS interface for Wi-Fi configuration

Syntax:

wpa_pps [-a] [-c file] [-d] [-h path] [-i iface] [-j ap_iface] 
        [-p path] [-r sec] [-u code] [-x] [-y path] &

Runs on:

QNX Neutrino

Options:

-a
On exit, the wpa_pps process won't disconnect and disable Wi-Fi networks.
-c file
Configuration file to use (default: /etc/wpa_pps.conf).
-d
Enable debug messages (to stdout).
-h path
Path and name of the binary to execute when configured for Access Point mode.
For this option, you should specify the hostapd version appropriate for your target platform. This could be either the version shipped with the wireless driver or the generic version included with QNX SDP 7. For example, on targets with a TI WiLink 8 module, the driver-specific binary is specified as follows: -h /usr/sbin/hostapd_ti18xx. Other targets can use version 2.5, as shown in the sample commands below.
For more details on hostapd, see the hostapd-version entry in the Utilities Reference.
-i iface
Wi-Fi interface to use. This must be the last argument on the command line, and its setting depends on the driver used (e.g., -i bcm0).
-j ap_iface
Access Point (AP) interface to use.
-p path
Path for the wpa_supplicant control interface (e.g., /var/run/wpa_supplicant).
-r sec
Number of seconds between updates of the connected network's RSSI (default: 10). To never do any updates, specify -1.
-u code
The two-letter country code. This option applies only to the TI chipset MCP 8.5 SP1.
-x
Use P-format for the SSID in wpa_supplicant.
-y path
Path for the roleAp.bin file. This option applies only to the TI chipset AP operation.

Description:

The wpa_pps service offers a PPS interface for configuring Wi-Fi Protected Access (WPA) connections. The Wi-Fi Manager component in the Networking Middleware C API interacts with this service through numerous PPS objects. Because client applications are meant to use the C API and no longer talk directly to wpa_pps through PPS, these objects aren't documented. However, for the C API calls to have any effect, you must launch this service during system startup.

For information about QNX support for networking, see Networking Architecture in the System Architecture guide.

Examples:

The command line for starting wpa_pps depends on the intended role of the target system—Station (client) or Access Point (server). Suppose your target system uses a Marvell Wi-Fi chipset and you want to run in Station mode using a configuration file stored in /var/etc/ while outputting debug messages. You would then launch wpa_pps as follows:
wpa_pps -d -c /var/etc/wpa_pps.conf -i mrvl_mlan0 &
For Access Point mode, you also need the options -h to name the right version of hostapd to run (which performs IEEE 802.11 authentication of clients), and -j to name the access point interface:
wpa_pps -d -c /var/etc/wpa_pps.conf -j mrvl_uap0 \
 -h /usr/sbin/hostapd-2.5 -i mrvl_mlan0 &

Configuration:

The service reads a configuration file (by default, /etc/wpa_pps.conf) to learn the requested WPA supplicant settings. To configure WPA behavior, edit the parameters in this JSON file. The file supports the following fields:
_enable
Whether the saved network is allowed to connect to its access point (if it's available); either 0 or 1
auth_alg
Authentication type used by WEP (must be OPEN)
eap
EAP authentication method, one of FAST (Flexible Authentication via Secure Tunneling), PEAP (Protected Extensible Authentication Protocol), TLS (Transport Layer Security), or TTLS (Tunneled Transport Layer Security)
group_cipher
Cipher method for the WPA-PSK or WPA2-PSK protocols used for broadcast or multicast data; either CCMP or TKIP
identity
EAP authentication username
key_mgmt
Authentication protocol to use over the network, one of NONE, WPA_PSK, or WPA-EAP
pairwise_cipher
Cipher method for the WPA-PSK or WPA2-PSK protocols used for unicast data between a pair of devices; either CCMP or TKIP
password
EAP authentication password when the method is TTLS or PEAP
phase1
Phase 1 encapsulation used for EAP authentication when the method is TTLS or PEAP. This value can be omitted to use the default encapsulation.
phase2
Phase 2 encapsulation used for EAP authentication when the method is TTLS or PEAP (this in turn uses MSCHAPv2 and so the value must be auth=MSCHAPV2)
priority
Network profile priority. The higher the priority, the sooner the network will be matched against a Wi-Fi scan result.
private_key
Private key file used for EAP authentication with the TLS method only
private_key_password
Private key password used for EAP authentication with the TLS method only
psk
Passphrase used for the WPA-PSK and WPA2-PSK authentication protocols
ssid
SSID name of the access point for this saved Wi-Fi network
A sample configuration is:
{
  "auth_alg":"OPEN",
  "pairwise_cipher":"CCMP",
  "group_cipher":"CCMP",
  "key_mgmt":"WPA-PSK",
  "psk":"abcdabcd",
  "ssid":"QWA_WLEG",
  "_enable":"0"
}