WifiConfiguration: Fix isEnterprise
Add a check for the eap method in Enterpriseconfig associated with the WifiConfiguration. BUG: 31275240 Change-Id: I21aabb09bdd21e29a80d4b9c6ea0e2b1f0d7e2df
This commit is contained in:
@@ -1407,8 +1407,10 @@ public class WifiConfiguration implements Parcelable {
|
||||
* @hide
|
||||
*/
|
||||
public boolean isEnterprise() {
|
||||
return allowedKeyManagement.get(KeyMgmt.WPA_EAP) ||
|
||||
allowedKeyManagement.get(KeyMgmt.IEEE8021X);
|
||||
return (allowedKeyManagement.get(KeyMgmt.WPA_EAP)
|
||||
|| allowedKeyManagement.get(KeyMgmt.IEEE8021X))
|
||||
&& enterpriseConfig != null
|
||||
&& enterpriseConfig.getEapMethod() != WifiEnterpriseConfig.Eap.NONE;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user