Is there a way to get wifi encryption type (like WSA, WSA2, WEP) programmatically on Android 6.0+ without using:
WifiManager wifi = (WifiManager) getSystemService(Context.WIFI_SERVICE);
List<ScanResult> networkList = wifi.getScanResults();
because I don't want to have to ask user for access to location.
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
which appears to be a requirement when scanning wifi networks.
I am hoping there is a way to get this without having to scan all wifi networks like in the android.net.wifi.WifiInfo class.