Skip to content

WifiAuthentication

com.rvi.domain.WifiAuthentication · Enum · SocialCard 1.0.3

Selects how a client authenticates to the advertised Wi-Fi network.

Choose OPEN for a network with no password. Choose WPA2_PERSONAL for a network with a shared WPA2-Personal password. Pair the selection with the matching WifiEncryption value.

final WifiAuthentication authentication = WifiAuthentication.OPEN;
final NDefWifi guest = new NDefWifiCreator()
.ssid("Guest")
.authentication(authentication)
.encryption(WifiEncryption.NONE)
.build();
System.out.println(guest.authentication());
Java imports
import com.rvi.application.creator.NDefWifiCreator;
import com.rvi.domain.NDefWifi;
import com.rvi.domain.WifiAuthentication;
import com.rvi.domain.WifiEncryption;

The builder defaults to WPA2-Personal. Set both authentication and encryption explicitly for open networks.

The enum has two constants in 1.0.3. NDefWifi validates the authentication and encryption combination and the encoder maps the enum to the authentication identifier in the Wi-Fi credential payload.

WifiEncryption · NDefWifi · NDefWifiCreator

Method signatures in the Javadoc · All API types