mirror of
https://github.com/ponces/treble_aosp.git
synced 2025-02-16 16:05:50 +00:00
86 lines
5.3 KiB
Diff
86 lines
5.3 KiB
Diff
From 9172607accb1b91db9aca5a9a042c22455c38599 Mon Sep 17 00:00:00 2001
|
|
From: Alberto Ponces <ponces26@gmail.com>
|
|
Date: Thu, 2 Nov 2023 10:23:56 +0000
|
|
Subject: [PATCH 4/4] Revert "[Wi-Fi] Check if domain field is not empty when
|
|
users choose a ca certificate"
|
|
|
|
Change-Id: I52ede9eb6b5164e147578e2dc2756cc722fe36ef
|
|
---
|
|
.../android/settings/wifi/WifiConfigController.java | 11 ++++++-----
|
|
.../android/settings/wifi/WifiConfigController2.java | 11 ++++++-----
|
|
2 files changed, 12 insertions(+), 10 deletions(-)
|
|
|
|
diff --git a/src/com/android/settings/wifi/WifiConfigController.java b/src/com/android/settings/wifi/WifiConfigController.java
|
|
index dc49850e7fa..4d03f9e3d81 100644
|
|
--- a/src/com/android/settings/wifi/WifiConfigController.java
|
|
+++ b/src/com/android/settings/wifi/WifiConfigController.java
|
|
@@ -556,11 +556,11 @@ public class WifiConfigController implements TextWatcher,
|
|
// Disallow submit if the user has not selected a CA certificate for an EAP network
|
|
// configuration.
|
|
enabled = false;
|
|
- } else if (!caCertSelection.equals(mDoNotValidateEapServerString)
|
|
+ } else if (caCertSelection.equals(mUseSystemCertsString)
|
|
&& mEapDomainView != null
|
|
&& mView.findViewById(R.id.l_domain).getVisibility() != View.GONE
|
|
&& TextUtils.isEmpty(mEapDomainView.getText().toString())) {
|
|
- // Disallow submit if the user chooses to use a certificate for EAP server
|
|
+ // Disallow submit if the user chooses to use a system certificate for EAP server
|
|
// validation, but does not provide a domain.
|
|
enabled = false;
|
|
}
|
|
@@ -597,12 +597,13 @@ public class WifiConfigController implements TextWatcher,
|
|
// Display warning if user chooses not to validate the EAP server with a
|
|
// user-supplied CA certificate in an EAP network configuration.
|
|
mView.findViewById(R.id.no_ca_cert_warning).setVisibility(View.VISIBLE);
|
|
- } else if (!caCertSelection.equals(mUnspecifiedCertString)
|
|
+ } else if (caCertSelection.equals(mUseSystemCertsString)
|
|
&& mEapDomainView != null
|
|
&& mView.findViewById(R.id.l_domain).getVisibility() != View.GONE
|
|
&& TextUtils.isEmpty(mEapDomainView.getText().toString())) {
|
|
- // Display warning if user chooses to use a certificate without restricting the
|
|
- // server domain that these certificates can be used to validate.
|
|
+ // Display warning if user chooses to use pre-installed public CA certificates
|
|
+ // without restricting the server domain that these certificates can be used to
|
|
+ // validate.
|
|
mView.findViewById(R.id.no_domain_warning).setVisibility(View.VISIBLE);
|
|
}
|
|
}
|
|
diff --git a/src/com/android/settings/wifi/WifiConfigController2.java b/src/com/android/settings/wifi/WifiConfigController2.java
|
|
index 3114941e8d6..9a3892c8722 100644
|
|
--- a/src/com/android/settings/wifi/WifiConfigController2.java
|
|
+++ b/src/com/android/settings/wifi/WifiConfigController2.java
|
|
@@ -555,11 +555,11 @@ public class WifiConfigController2 implements TextWatcher,
|
|
// Disallow submit if the user has not selected a CA certificate for an EAP network
|
|
// configuration.
|
|
enabled = false;
|
|
- } else if (!caCertSelection.equals(mDoNotValidateEapServerString)
|
|
+ } else if (caCertSelection.equals(mUseSystemCertsString)
|
|
&& mEapDomainView != null
|
|
&& mView.findViewById(R.id.l_domain).getVisibility() != View.GONE
|
|
&& TextUtils.isEmpty(mEapDomainView.getText().toString())) {
|
|
- // Disallow submit if the user chooses to use a certificate for EAP server
|
|
+ // Disallow submit if the user chooses to use a system certificate for EAP server
|
|
// validation, but does not provide a domain.
|
|
enabled = false;
|
|
}
|
|
@@ -596,12 +596,13 @@ public class WifiConfigController2 implements TextWatcher,
|
|
// Display warning if user chooses not to validate the EAP server with a
|
|
// user-supplied CA certificate in an EAP network configuration.
|
|
mView.findViewById(R.id.no_ca_cert_warning).setVisibility(View.VISIBLE);
|
|
- } else if (!caCertSelection.equals(mUnspecifiedCertString)
|
|
+ } else if (caCertSelection.equals(mUseSystemCertsString)
|
|
&& mEapDomainView != null
|
|
&& mView.findViewById(R.id.l_domain).getVisibility() != View.GONE
|
|
&& TextUtils.isEmpty(mEapDomainView.getText().toString())) {
|
|
- // Display warning if user chooses to use a certificate without restricting the
|
|
- // server domain that these certificates can be used to validate.
|
|
+ // Display warning if user chooses to use pre-installed public CA certificates
|
|
+ // without restricting the server domain that these certificates can be used to
|
|
+ // validate.
|
|
mView.findViewById(R.id.no_domain_warning).setVisibility(View.VISIBLE);
|
|
}
|
|
}
|
|
--
|
|
2.34.1
|
|
|