wifi: add support for GCMP_128
GCMP_128 is required for supporting 60GHz (WiGig)
connections.
Bug: 147495505
Test: Manual - enable wifi and connect to an access point
Test: atest FrameworksWifiTests
Test: atest FrameworksWifiApiTests
Change-Id: Iea30338dc5a23b4c28b72c688346d35763dd0005
diff --git a/api/current.txt b/api/current.txt
index e678d16..5f32dec 100644
--- a/api/current.txt
+++ b/api/current.txt
@@ -31303,6 +31303,7 @@
@Deprecated public static class WifiConfiguration.GroupCipher {
field @Deprecated public static final int CCMP = 3; // 0x3
+ field @Deprecated public static final int GCMP_128 = 7; // 0x7
field @Deprecated public static final int GCMP_256 = 5; // 0x5
field @Deprecated public static final int SMS4 = 6; // 0x6
field @Deprecated public static final int TKIP = 2; // 0x2
@@ -31332,6 +31333,7 @@
@Deprecated public static class WifiConfiguration.PairwiseCipher {
field @Deprecated public static final int CCMP = 2; // 0x2
+ field @Deprecated public static final int GCMP_128 = 5; // 0x5
field @Deprecated public static final int GCMP_256 = 3; // 0x3
field @Deprecated public static final int NONE = 0; // 0x0
field @Deprecated public static final int SMS4 = 4; // 0x4
diff --git a/wifi/api/current.txt b/wifi/api/current.txt
index d0742c7..3f5c673 100644
--- a/wifi/api/current.txt
+++ b/wifi/api/current.txt
@@ -144,6 +144,7 @@
@Deprecated public static class WifiConfiguration.GroupCipher {
field @Deprecated public static final int CCMP = 3; // 0x3
+ field @Deprecated public static final int GCMP_128 = 7; // 0x7
field @Deprecated public static final int GCMP_256 = 5; // 0x5
field @Deprecated public static final int SMS4 = 6; // 0x6
field @Deprecated public static final int TKIP = 2; // 0x2
@@ -173,6 +174,7 @@
@Deprecated public static class WifiConfiguration.PairwiseCipher {
field @Deprecated public static final int CCMP = 2; // 0x2
+ field @Deprecated public static final int GCMP_128 = 5; // 0x5
field @Deprecated public static final int GCMP_256 = 3; // 0x3
field @Deprecated public static final int NONE = 0; // 0x0
field @Deprecated public static final int SMS4 = 4; // 0x4
diff --git a/wifi/java/android/net/wifi/WifiConfiguration.java b/wifi/java/android/net/wifi/WifiConfiguration.java
index 656444e..02b7a42 100644
--- a/wifi/java/android/net/wifi/WifiConfiguration.java
+++ b/wifi/java/android/net/wifi/WifiConfiguration.java
@@ -301,9 +301,16 @@
*/
public static final int SMS4 = 4;
+ /**
+ * AES in Galois/Counter Mode with a 128-bit integrity key
+ */
+ public static final int GCMP_128 = 5;
+
+
public static final String varName = "pairwise";
- public static final String[] strings = { "NONE", "TKIP", "CCMP", "GCMP_256", "SMS4" };
+ public static final String[] strings = { "NONE", "TKIP", "CCMP", "GCMP_256", "SMS4",
+ "GCMP_128" };
}
/**
@@ -345,13 +352,17 @@
* SMS4 cipher for WAPI
*/
public static final int SMS4 = 6;
+ /**
+ * AES in Galois/Counter Mode with a 128-bit integrity key
+ */
+ public static final int GCMP_128 = 7;
public static final String varName = "group";
public static final String[] strings =
{ /* deprecated */ "WEP40", /* deprecated */ "WEP104",
"TKIP", "CCMP", "GTK_NOT_USED", "GCMP_256",
- "SMS4" };
+ "SMS4", "GCMP_128" };
}
/**
@@ -498,8 +509,10 @@
allowedProtocols.set(WifiConfiguration.Protocol.RSN);
allowedKeyManagement.set(WifiConfiguration.KeyMgmt.SAE);
allowedPairwiseCiphers.set(WifiConfiguration.PairwiseCipher.CCMP);
+ allowedPairwiseCiphers.set(WifiConfiguration.PairwiseCipher.GCMP_128);
allowedPairwiseCiphers.set(WifiConfiguration.PairwiseCipher.GCMP_256);
allowedGroupCiphers.set(WifiConfiguration.GroupCipher.CCMP);
+ allowedGroupCiphers.set(WifiConfiguration.GroupCipher.GCMP_128);
allowedGroupCiphers.set(WifiConfiguration.GroupCipher.GCMP_256);
requirePmf = true;
break;
@@ -508,7 +521,9 @@
allowedKeyManagement.set(WifiConfiguration.KeyMgmt.WPA_EAP);
allowedKeyManagement.set(WifiConfiguration.KeyMgmt.IEEE8021X);
allowedKeyManagement.set(WifiConfiguration.KeyMgmt.SUITE_B_192);
+ allowedPairwiseCiphers.set(WifiConfiguration.PairwiseCipher.GCMP_128);
allowedPairwiseCiphers.set(WifiConfiguration.PairwiseCipher.GCMP_256);
+ allowedGroupCiphers.set(WifiConfiguration.GroupCipher.GCMP_128);
allowedGroupCiphers.set(WifiConfiguration.GroupCipher.GCMP_256);
allowedGroupManagementCiphers.set(WifiConfiguration.GroupMgmtCipher.BIP_GMAC_256);
// Note: allowedSuiteBCiphers bitset will be set by the service once the
@@ -519,8 +534,10 @@
allowedProtocols.set(WifiConfiguration.Protocol.RSN);
allowedKeyManagement.set(WifiConfiguration.KeyMgmt.OWE);
allowedPairwiseCiphers.set(WifiConfiguration.PairwiseCipher.CCMP);
+ allowedPairwiseCiphers.set(WifiConfiguration.PairwiseCipher.GCMP_128);
allowedPairwiseCiphers.set(WifiConfiguration.PairwiseCipher.GCMP_256);
allowedGroupCiphers.set(WifiConfiguration.GroupCipher.CCMP);
+ allowedGroupCiphers.set(WifiConfiguration.GroupCipher.GCMP_128);
allowedGroupCiphers.set(WifiConfiguration.GroupCipher.GCMP_256);
requirePmf = true;
break;