19

Is there an API in CocoaTouch/iOS for detecting wireless networks? I want to write an app that saves a list of networks the phone can see at a given moment.

Andrew J. Brehm
  • 4,448
  • 8
  • 45
  • 70
  • 2
    possible duplicate of [On the iPhone, is it possible to find out which WIFI network we are connected to?](http://stackoverflow.com/questions/2637094/on-the-iphone-is-it-possible-to-find-out-which-wifi-network-we-are-connected-to) – Brad Larson Oct 20 '10 at 20:57
  • 3
    See also [Can the iPhone SDK obtain the Wi-Fi SSID currently connected to?](http://stackoverflow.com/questions/339089/can-the-iphone-sdk-obtain-the-wi-fi-ssid-currently-connected-to), [Current network being accessed](http://stackoverflow.com/questions/2643011/current-network-being-accessed), [how to enumerate all available Wifi networks at range?](http://stackoverflow.com/questions/3019336/how-to-enumerate-all-available-wifi-networks-at-range) – Brad Larson Oct 20 '10 at 20:58
  • Possible duplicate of [iPhone get a list of all SSIDs without private library](https://stackoverflow.com/questions/9684341/iphone-get-a-list-of-all-ssids-without-private-library) – Senseful Sep 24 '18 at 05:23

2 Answers2

4

As far as I know you can get the information about the current connected Wi-Fi using CNCopySupportedInterfaces and CNCopyCurrentNetworkInfo of CaptiveNetwork. You can refer to: How do I use CaptiveNetwork to get the current WiFi Hotspot Name for more information.

According to 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.

You could have a look at iphone-wireless project if you are interested in Apple80211. There exists a sample app "Stumber" which does exactly what you want. But you cannot use this in your app if you want to publish to App Store because as it uses private APIs

Community
  • 1
  • 1
Ali
  • 647
  • 2
  • 10
  • 28
0

Check out this https://github.com/mustafa96m/iOS-Wireless-Scanner-API Hopefully it helps

mustafa96m
  • 329
  • 3
  • 16
  • Well there is something called Cydia or the guy wants to build special application for himself .. :P @geekyaleks – mustafa96m Oct 06 '15 at 14:39