summaryrefslogtreecommitdiff
path: root/src/com/android/settings/wifi/WifiConfigController.java
diff options
context:
space:
mode:
authorArc Wang <arcwang@google.com>2019-12-03 11:26:04 +0800
committerArc Wang <arcwang@google.com>2019-12-06 18:17:07 +0800
commit5f23a436607a06d3a145a573841ca192be42934c (patch)
tree872bdfea26c6deca1ddf236b1d4b7427d0ddc959 /src/com/android/settings/wifi/WifiConfigController.java
parenta78de60472840a920dd5b1d085cb68a298d6e243 (diff)
[Wi-Fi] Fix transition mode problems
Replace SECURITY_PSK_SAE_TRANSITION & SECURITY_OWE_TRANSITION with AccessPpoint#isPskSaeTransitionMode() & AccessPpoint#isPskOweTransitionMode() Bug: 144320676 Bug: 144320649 Bug: 144325162 Bug: 144321574 Test: make RunSettingsRoboTests ROBOTEST_FILTER=com.android.settings.wifi Change-Id: Ic3c7ac1238a51b6e215ed63761720d2bc371d012
Diffstat (limited to 'src/com/android/settings/wifi/WifiConfigController.java')
-rw-r--r--src/com/android/settings/wifi/WifiConfigController.java34
1 files changed, 1 insertions, 33 deletions
diff --git a/src/com/android/settings/wifi/WifiConfigController.java b/src/com/android/settings/wifi/WifiConfigController.java
index 9fb7546309..5065ccb35a 100644
--- a/src/com/android/settings/wifi/WifiConfigController.java
+++ b/src/com/android/settings/wifi/WifiConfigController.java
@@ -607,35 +607,6 @@ public class WifiConfigController implements TextWatcher,
}
}
- /**
- * Special handling for WPA2/WPA3 and OWE in Transition mode: The key
- * SECURITY_PSK_SAE_TRANSITION and SECURITY_OWE_TRANSITION are pseudo keys which result by the
- * scan results, but never appears in the saved networks.
- * A saved network is either WPA3 for supporting devices or WPA2 for non-supporting devices,
- * or, OWE for supporting devices or Open for non-supporting devices.
- *
- * @param accessPointSecurity Access point current security type
- * @return Converted security type (if required)
- */
- private int convertSecurityTypeForMatching(int accessPointSecurity) {
- if (accessPointSecurity == AccessPoint.SECURITY_PSK_SAE_TRANSITION) {
- if (mWifiManager.isWpa3SaeSupported()) {
- return AccessPoint.SECURITY_SAE;
- } else {
- return AccessPoint.SECURITY_PSK;
- }
- }
- if (accessPointSecurity == AccessPoint.SECURITY_OWE_TRANSITION) {
- if (mWifiManager.isEnhancedOpenSupported()) {
- return AccessPoint.SECURITY_OWE;
- } else {
- return AccessPoint.SECURITY_NONE;
- }
- }
-
- return accessPointSecurity;
- }
-
public WifiConfiguration getConfig() {
if (mMode == WifiConfigUiBase.MODE_VIEW) {
return null;
@@ -658,8 +629,6 @@ public class WifiConfigController implements TextWatcher,
config.shared = mSharedCheckBox.isChecked();
- mAccessPointSecurity = convertSecurityTypeForMatching(mAccessPointSecurity);
-
switch (mAccessPointSecurity) {
case AccessPoint.SECURITY_NONE:
config.allowedKeyManagement.set(KeyMgmt.NONE);
@@ -1017,8 +986,7 @@ public class WifiConfigController implements TextWatcher,
private void showSecurityFields(boolean refreshEapMethods, boolean refreshCertificates) {
if (mAccessPointSecurity == AccessPoint.SECURITY_NONE ||
- mAccessPointSecurity == AccessPoint.SECURITY_OWE ||
- mAccessPointSecurity == AccessPoint.SECURITY_OWE_TRANSITION) {
+ mAccessPointSecurity == AccessPoint.SECURITY_OWE) {
mView.findViewById(R.id.security_fields).setVisibility(View.GONE);
return;
}