Last active
December 17, 2015 04:08
-
-
Save KyleLeneau/5548089 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import <SystemConfiguration/CaptiveNetwork.h> | |
- (id)checkNetworkSSID { | |
NSArray *ifs = (__bridge_transfer id)CNCopySupportedInterfaces(); | |
NSLog(@"Supported interfaces: %@", ifs); | |
id info = nil; | |
for (NSString *ifnam in ifs) { | |
info = (__bridge_transfer id)CNCopyCurrentNetworkInfo((__bridge CFStringRef)ifnam); | |
NSLog(@"%@ => %@", ifnam, info); | |
if (info && [info count]) { break; } | |
} | |
return info; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment