Obsolete
Status Update
Comments
s....@gmail.com <s....@gmail.com> #2
Bug already reported during the preview but badly triaged as a dupe of a UI crash. (Related to the UI part of Wifi configuration)
https://code.google.com/p/android-developer-preview/issues/detail?id=509
s....@gmail.com <s....@gmail.com> #3
Looks like it's still broken in 5.0.1/LRX22C.
sa...@google.com <sa...@google.com> #4
Thank you for your feedback. We assure you that we are doing our best to address the issue reported, however our product team has shifted work priority that doesn't include this issue. For now, we will be closing the issue as won't fix obsolete. If this issue currently still exists, we request that you log a new issue along with latest bug report here https://goo.gl/TbMiIO .
Description
The code below, allow Free Mobile's users (20815 operator) to connect to Free Mobile hotspots, using Free Mobile EAPSIM network (SSID = "FreeWifi_secure") in France.
This code works on Motorola Nexus 6 (LRX210), LG G3 (v20d-EUR-XX LRX21R.A1417119896) but not on Nexus 5 (LRX210) "Authentification error".
-> logcat -b radio on nexus 5 is attached.
WifiManager wifiManag = (WifiManager)context.getSystemService(Context.WIFI_SERVICE);
TelephonyManager mTelephonyMgr = (TelephonyManager) context.getSystemService(Context.TELEPHONY_SERVICE);
String userName = "1" + mTelephonyMgr.getSubscriberId() + "@
String ssid = "FreeWifi_secure";
WifiConfiguration selectedConfig = new WifiConfiguration();
selectedConfig.SSID = "\"FreeWifi_secure\"";
selectedConfig.priority = 0;
selectedConfig.hiddenSSID = false;
selectedConfig.allowedKeyManagement.clear();
selectedConfig.allowedKeyManagement.set(KeyMgmt.IEEE8021X);
selectedConfig.allowedKeyManagement.set(KeyMgmt.WPA_EAP);
selectedConfig.allowedGroupCiphers.clear();
selectedConfig.allowedGroupCiphers.set(GroupCipher.CCMP);
selectedConfig.allowedGroupCiphers.set(GroupCipher.TKIP);
selectedConfig.allowedPairwiseCiphers.clear();
selectedConfig.allowedPairwiseCiphers.set(PairwiseCipher.CCMP);
selectedConfig.allowedPairwiseCiphers.set(PairwiseCipher.TKIP);
selectedConfig.allowedProtocols.clear();
selectedConfig.allowedProtocols.set(Protocol.RSN);
selectedConfig.allowedProtocols.set(Protocol.WPA);
try
{
WifiEnterpriseConfig enterpriseConfig = new WifiEnterpriseConfig();
enterpriseConfig.setIdentity(userName);
enterpriseConfig.setEapMethod(WifiEnterpriseConfig.Eap.SIM);
wifiConfig.enterpriseConfig = enterpriseConfig;
}
catch (Exception e)
{
logger.e("Could not configure WifiEnterpriseConfig" + e.getMessage());
}
int res = wifiManag.addNetwork(selectedConfig);
wifiManag.saveConfiguration();
wifiManag.enableNetwork(res, false);