iPhone get a list of all SSIDs without private library iPhone get a list of all SSIDs without private library ios ios

iPhone get a list of all SSIDs without private library

Without the use of private library (Apple80211) you can only get the SSID of the network your device is currently connected to.

Since iOS 9, you can use NEHotspotHelper to get a list of SSIDs. But you have to get the com.apple.developer.networking.HotspotHelper entitlement from Apple by sending a request.

Check https://developer.apple.com/documentation/networkextension/nehotspothelper for more infomation.

Some new APIs have been released as part of the Network Extension in iOS 9 and iOS 11. While neither allows you to scan for networks while your app is running, they both allow you to do related tasks. E.g. you can scan for networks while the Settings Wi-Fi page is running using Hotspot Helper, and you can make it easier for a user to join a network using either of these.

Here's a comparison of the two frameworks.

Hotspot Helper

  • NEHotspotHelper (introduced in iOS 9, WWDC 2015).
  • Requires special permission from Apple.
  • Requires the com.apple.developer.networking.HotspotHelper entitlement.
  • For step-by-step instructions to get this working, see this answer.
  • Allows you to participate in the discovery/authentication to a Wi-Fi network via the Wi-Fi screen in the Settings app. You register to be notified when networks are being scanned (e.g. when the user launches Wi-Fi in the Settings app), and you can automatically pre-fill the password and display an annotation near the network name. The user still needs to tap on the network name to connect, but it won't prompt for a password if you pre-filled it.

    enter image description here

Hotspot Configuration

  • NEHotspotConfigurationManager (introduced in iOS 11, WWDC 2017).
  • Does not require special permission from Apple.
  • Requires the com.apple.developer.networking.HotspotConfiguration entitlement.
  • Allows you to initiate a connection to a Wi-Fi network. You give it a list of SSIDs/Passwords that should be connected to while your app is running. It will present a dialog asking the user if they want to connect to the network.

    enter image description here