Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8f1d70ea authored by Jimmy Chen's avatar Jimmy Chen
Browse files

wifi: add SAE-PK feature querying API

Bug: 160642415
Test: build
Change-Id: I2a729185897660d3406ca5eb8a86984ee6582325
parent cf061c1f
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -31642,6 +31642,7 @@ package android.net.wifi {
    method public boolean isWapiSupported();
    method public boolean isWifiEnabled();
    method public boolean isWifiStandardSupported(int);
    method public boolean isWpa3ApValidationSupported();
    method public boolean isWpa3SaeSupported();
    method public boolean isWpa3SuiteBSupported();
    method @Deprecated public boolean pingSupplicant();
+1 −0
Original line number Diff line number Diff line
@@ -342,6 +342,7 @@ package android.net.wifi {
    method public boolean isWapiSupported();
    method public boolean isWifiEnabled();
    method public boolean isWifiStandardSupported(int);
    method public boolean isWpa3ApValidationSupported();
    method public boolean isWpa3SaeSupported();
    method public boolean isWpa3SuiteBSupported();
    method @Deprecated public boolean pingSupplicant();
+10 −0
Original line number Diff line number Diff line
@@ -2425,6 +2425,9 @@ public class WifiManager {
    /** @hide */
    public static final long WIFI_FEATURE_FILS_SHA384     = 0x8000000000L; // FILS-SHA384

    /** @hide */
    public static final long WIFI_FEATURE_SAE_PK          = 0x10000000000L; // SAE-PK

    private long getSupportedFeatures() {
        try {
            return mService.getSupportedFeatures();
@@ -5329,6 +5332,13 @@ public class WifiManager {
        return isFeatureSupported(WIFI_FEATURE_WAPI);
    }

    /**
     * @return true if this device supports WPA3 AP validation.
     */
    public boolean isWpa3ApValidationSupported() {
        return isFeatureSupported(WIFI_FEATURE_SAE_PK);
    }

    /**
     * Gets the factory Wi-Fi MAC addresses.
     * @return Array of String representing Wi-Fi MAC addresses sorted lexically or an empty Array