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

Commit 3b25f516 authored by Vinit Deshapnde's avatar Vinit Deshapnde
Browse files

Consider current EAP TLS configurations as 'valid'

Multiple authentication methods are currently considered invalid; but
WPA_EAP and IEEE8021X are set simultaneously. This means we need to
fix code to consider them a valid combination.

Bug: 10325089

Change-Id: I2b4f4d75f21df78bfca66a930e85214c0cd6922e
parent 7354b834
Loading
Loading
Loading
Loading
+9 −1
Original line number Diff line number Diff line
@@ -355,8 +355,16 @@ public class WifiConfiguration implements Parcelable {
     */
    public boolean isValid() {
        if (allowedKeyManagement.cardinality() > 1) {
            if (allowedKeyManagement.cardinality() != 2) {
                return false;
            }
            if (allowedKeyManagement.get(KeyMgmt.WPA_EAP) == false) {
                return false;
            }
            if (allowedKeyManagement.get(KeyMgmt.IEEE8021X) == false) {
                return false;
            }
        }

        // TODO: Add more checks
        return true;