[Wi-Fi] Revert "support SAE password identifier in wifi dialog"
Revert it because SPEC is not clear now. Bug: 143379656 Test: manual Click "Add network" in wi-Fi picker and edit a WAP3-personal Wi-Fi network Change-Id: Ifa859d53c29d0fa83f22cc2d0e50294d0a5c7fc9
This commit is contained in:
@@ -341,25 +341,6 @@
|
|||||||
style="@style/wifi_item_content"
|
style="@style/wifi_item_content"
|
||||||
android:text="@string/wifi_show_password" />
|
android:text="@string/wifi_show_password" />
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout android:id="@+id/sae_password_id_layout"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
style="@style/wifi_item"
|
|
||||||
android:visibility="gone">
|
|
||||||
<TextView
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
style="@style/wifi_item_label"
|
|
||||||
android:text="@string/wifi_sae_password_id" />
|
|
||||||
|
|
||||||
<EditText android:id="@+id/sae_password_id"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
style="@style/wifi_item_edit_content"
|
|
||||||
android:singleLine="true"
|
|
||||||
android:inputType="textNoSuggestions" />
|
|
||||||
</LinearLayout>
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout android:id="@+id/wifi_advanced_toggle"
|
<LinearLayout android:id="@+id/wifi_advanced_toggle"
|
||||||
|
@@ -2003,8 +2003,6 @@
|
|||||||
<string name="wifi_eap_anonymous">Anonymous identity</string>
|
<string name="wifi_eap_anonymous">Anonymous identity</string>
|
||||||
<!-- Label for the password of the secured network -->
|
<!-- Label for the password of the secured network -->
|
||||||
<string name="wifi_password">Password</string>
|
<string name="wifi_password">Password</string>
|
||||||
<!-- Label for the sae password id of the secured network [CHAR LIMIT=32] -->
|
|
||||||
<string name="wifi_sae_password_id">SAE password identifier</string>
|
|
||||||
<!-- Label for the check box to show password -->
|
<!-- Label for the check box to show password -->
|
||||||
<string name="wifi_show_password">Show password</string>
|
<string name="wifi_show_password">Show password</string>
|
||||||
<!-- Label for the RadioGroup to choose wifi ap band -->
|
<!-- Label for the RadioGroup to choose wifi ap band -->
|
||||||
|
@@ -142,7 +142,6 @@ public class WifiConfigController implements TextWatcher,
|
|||||||
@VisibleForTesting
|
@VisibleForTesting
|
||||||
int mAccessPointSecurity;
|
int mAccessPointSecurity;
|
||||||
private TextView mPasswordView;
|
private TextView mPasswordView;
|
||||||
private TextView mSaePasswordIdView;
|
|
||||||
private ImageButton mSsidScanButton;
|
private ImageButton mSsidScanButton;
|
||||||
|
|
||||||
private String mUnspecifiedCertString;
|
private String mUnspecifiedCertString;
|
||||||
@@ -811,11 +810,6 @@ public class WifiConfigController implements TextWatcher,
|
|||||||
String password = mPasswordView.getText().toString();
|
String password = mPasswordView.getText().toString();
|
||||||
config.preSharedKey = '"' + password + '"';
|
config.preSharedKey = '"' + password + '"';
|
||||||
}
|
}
|
||||||
if (mSaePasswordIdView.length() != 0) {
|
|
||||||
config.saePasswordId = mSaePasswordIdView.getText().toString();
|
|
||||||
} else {
|
|
||||||
config.saePasswordId = null;
|
|
||||||
}
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case AccessPoint.SECURITY_OWE:
|
case AccessPoint.SECURITY_OWE:
|
||||||
@@ -1002,23 +996,6 @@ public class WifiConfigController implements TextWatcher,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mSaePasswordIdView == null) {
|
|
||||||
mSaePasswordIdView = (TextView) mView.findViewById(R.id.sae_password_id);
|
|
||||||
mSaePasswordIdView.setOnEditorActionListener(this);
|
|
||||||
mSaePasswordIdView.setOnKeyListener(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (mAccessPointSecurity == AccessPoint.SECURITY_SAE) {
|
|
||||||
mView.findViewById(R.id.sae_password_id_layout).setVisibility(View.VISIBLE);
|
|
||||||
if (mAccessPoint != null && mAccessPoint.isSaved()) {
|
|
||||||
if (!TextUtils.isEmpty(mAccessPoint.getConfig().saePasswordId)) {
|
|
||||||
mSaePasswordIdView.setText(mAccessPoint.getConfig().saePasswordId);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
setSaePasswordIdInvisible();
|
|
||||||
}
|
|
||||||
|
|
||||||
if (mAccessPointSecurity != AccessPoint.SECURITY_EAP &&
|
if (mAccessPointSecurity != AccessPoint.SECURITY_EAP &&
|
||||||
mAccessPointSecurity != AccessPoint.SECURITY_EAP_SUITE_B) {
|
mAccessPointSecurity != AccessPoint.SECURITY_EAP_SUITE_B) {
|
||||||
mView.findViewById(R.id.eap).setVisibility(View.GONE);
|
mView.findViewById(R.id.eap).setVisibility(View.GONE);
|
||||||
@@ -1326,11 +1303,6 @@ public class WifiConfigController implements TextWatcher,
|
|||||||
mView.findViewById(R.id.show_password_layout).setVisibility(View.GONE);
|
mView.findViewById(R.id.show_password_layout).setVisibility(View.GONE);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setSaePasswordIdInvisible() {
|
|
||||||
mSaePasswordIdView.setText("");
|
|
||||||
mView.findViewById(R.id.sae_password_id_layout).setVisibility(View.GONE);
|
|
||||||
}
|
|
||||||
|
|
||||||
private void setEapMethodInvisible() {
|
private void setEapMethodInvisible() {
|
||||||
mView.findViewById(R.id.eap).setVisibility(View.GONE);
|
mView.findViewById(R.id.eap).setVisibility(View.GONE);
|
||||||
}
|
}
|
||||||
|
@@ -142,7 +142,6 @@ public class WifiConfigController2 implements TextWatcher,
|
|||||||
@VisibleForTesting
|
@VisibleForTesting
|
||||||
int mWifiEntrySecurity;
|
int mWifiEntrySecurity;
|
||||||
private TextView mPasswordView;
|
private TextView mPasswordView;
|
||||||
private TextView mSaePasswordIdView;
|
|
||||||
private ImageButton mSsidScanButton;
|
private ImageButton mSsidScanButton;
|
||||||
|
|
||||||
private String mUnspecifiedCertString;
|
private String mUnspecifiedCertString;
|
||||||
@@ -805,11 +804,6 @@ public class WifiConfigController2 implements TextWatcher,
|
|||||||
String password = mPasswordView.getText().toString();
|
String password = mPasswordView.getText().toString();
|
||||||
config.preSharedKey = '"' + password + '"';
|
config.preSharedKey = '"' + password + '"';
|
||||||
}
|
}
|
||||||
if (mSaePasswordIdView.length() != 0) {
|
|
||||||
config.saePasswordId = mSaePasswordIdView.getText().toString();
|
|
||||||
} else {
|
|
||||||
config.saePasswordId = null;
|
|
||||||
}
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case WifiEntry.SECURITY_OWE:
|
case WifiEntry.SECURITY_OWE:
|
||||||
@@ -996,23 +990,6 @@ public class WifiConfigController2 implements TextWatcher,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mSaePasswordIdView == null) {
|
|
||||||
mSaePasswordIdView = (TextView) mView.findViewById(R.id.sae_password_id);
|
|
||||||
mSaePasswordIdView.setOnEditorActionListener(this);
|
|
||||||
mSaePasswordIdView.setOnKeyListener(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (mWifiEntrySecurity == WifiEntry.SECURITY_SAE) {
|
|
||||||
mView.findViewById(R.id.sae_password_id_layout).setVisibility(View.VISIBLE);
|
|
||||||
if (mWifiEntry != null && mWifiEntry.isSaved()) {
|
|
||||||
if (!TextUtils.isEmpty(mWifiEntry.getWifiConfiguration().saePasswordId)) {
|
|
||||||
mSaePasswordIdView.setText(mWifiEntry.getWifiConfiguration().saePasswordId);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
setSaePasswordIdInvisible();
|
|
||||||
}
|
|
||||||
|
|
||||||
if (mWifiEntrySecurity != WifiEntry.SECURITY_EAP
|
if (mWifiEntrySecurity != WifiEntry.SECURITY_EAP
|
||||||
&& mWifiEntrySecurity != WifiEntry.SECURITY_EAP_SUITE_B) {
|
&& mWifiEntrySecurity != WifiEntry.SECURITY_EAP_SUITE_B) {
|
||||||
mView.findViewById(R.id.eap).setVisibility(View.GONE);
|
mView.findViewById(R.id.eap).setVisibility(View.GONE);
|
||||||
@@ -1322,11 +1299,6 @@ public class WifiConfigController2 implements TextWatcher,
|
|||||||
mView.findViewById(R.id.show_password_layout).setVisibility(View.GONE);
|
mView.findViewById(R.id.show_password_layout).setVisibility(View.GONE);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void setSaePasswordIdInvisible() {
|
|
||||||
mSaePasswordIdView.setText("");
|
|
||||||
mView.findViewById(R.id.sae_password_id_layout).setVisibility(View.GONE);
|
|
||||||
}
|
|
||||||
|
|
||||||
private void setEapMethodInvisible() {
|
private void setEapMethodInvisible() {
|
||||||
mView.findViewById(R.id.eap).setVisibility(View.GONE);
|
mView.findViewById(R.id.eap).setVisibility(View.GONE);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user