I use NEHotspotNetwork.fetchCurrentWithCompletionHandle, but it gives me Nil for both SSID and BSSID
#import "FPPHotspotNetworkInfoProvider.h"
#import <NetworkExtension/NetworkExtension.h>
@implementation FPPHotspotNetworkInfoProvider
- (void)fetchNetworkInfoWithCompletionHandler:
(void (^)(FPPNetworkInfo *network))completionHandler
API_AVAILABLE(ios(14)) {
[NEHotspotNetwork fetchCurrentWithCompletionHandler:^(
NEHotspotNetwork *network) {
dispatch_async(dispatch_get_main_queue(), ^{
if (network) {
completionHandler([[FPPNetworkInfo alloc] initWithSSID:network.SSID
BSSID:network.BSSID]);
return;
}
completionHandler(nil);
});
}];
}
@end
Do I need approval from Apple for this? If so, could you please provide guidance on how to obtain it?
Thank you.