From iOS 7.0.2 the MAC address is: 02:00:00:00:00:00.
How can I read real one in iOS?
Is this unvailable from 7.0.2, or not?
How do it?
This is a privacy change, so there's no way to get at the underlying MAC address. https://developer.apple.com/news/?id=8222013a
If your apps use the MAC address to identify an iOS device, the system will return the same static value for all devices running iOS 7. Please update your apps to use the identifierForVendor property of UIDevice. If you need an identifier for advertising purposes, use the advertisingIdentifier property of ASIdentifierManager.
Related
I thought this could be best place to clarify my doubts and my concern - we about to release our app and it displays MAC address of all connected devices to a router and someone told me apple does not allow to display MAC address and hence app will get rejected.
But there are so many ios apps on itunes which does display MAC address and how did there app got approved if apple does not allow it.
Please guide me on this.
Thanks,
From iOS 7 or later, the MAC address of an iOS device always returns value 02:00:00:00:00:00. If you need to identify the device, use the identifierForVendor property of UIDevice instead.([[UIDevice currentDevice] uniqueIdentifier]).
I'm searching for a good way to identify a device on iOS with my cordova application. I'm using device.uuid but it's not a good identifier because after a new installation or update it creates a new uuid. I thought about hashing the mac address of the device but it seems to me like there is no way getting the mac address of a device on iOS.
So how can I identify a device on iOS?
Is there a way to get the real Wi-Fi MAC address of the IOS device using Swift language?
Code snippet much appreciated!
Thanks.
When you request the Device MAC address in iOS 7 and above you will always get the same response: 02:00:00:00:00:00, this has been made by Apple for privacy concerns.
In iOS 7 and later, if you ask for the MAC address of an iOS device, the system returns the value 02:00:00:00:00:00. If you need to identify the device, use the identifierForVendor property of UIDevice instead. (Apps that need an identifier for their own advertising purposes should consider using the advertisingIdentifier property of ASIdentifierManager instead.)
Apple recommends to switch to UDID instead if you need to uniquely identify an iOS device. In Swift you can use this:
UIDevice.currentDevice().identifierForVendor
if you want a string instead use:
UIDevice.currentDevice().identifierForVendor.UUIDString
Here's a nice reading about UDID
This is no longer possible since iOS 7, due to privacy risks Apple does not allow developers to access any device specific identifiers.
You can not get mac address because of some security concerns. you may use UUID instead to identify device uniquely.
for swift 4.2
UIDevice().identifierForVendor?.uuidString ?? ""
for objective c
[[[UIDevice currentDevice] identifierForVendor] UUIDString]
For iOS 15 do this:
UIDevice.current.identifierForVendor?.uuidString
Our app is using device WiFiMAC address to uniquely identify a device. As per the
Apple doumentation we shall start using identifierForVendor property of UIDevice but my app is strongly dependent on WiFi MAC address. At run time, app users look into device settings and fetch the WiFi Mac address and manually put them in some tool to enable some feature on server side. Has anyone retrieved the device WiFi MAC address with iOS 7?
This was intentionally removed from the SDK in iOS 7. You can no longer retrieve the MAC address. Techcrunch has one of several stories on it, and it was confirmed at WWDC.
Use libimobiledevice and from command line run:
./ideviceinfo -k WiFiAddress
I want to ask that whether objective C can obtain a unique device ID of the Device. "uniqueIdentifier" is deprecated in iOS7 and I try to use "identifierForVendor" but it gives me a different ID after the app is re-installed. I want to find a stable device ID after the app is re-install, and even the iOS is changed. In the early version of iOS, we can use MAC address to achieve such goal. But now, in iOS7, the MAC address is no longer available. How can i find a stable device ID of the iOS device in iOS7?
Maybe using Keychain to store the "identifierForVendor" value is a good approach. But will it still be the same after the whole iOS is re-installed?
iOS does not allow you to identify a device universally anymore. That is the basic idea behind removing access to UDID and Mac address.
You need to change the design of your application to adapt to these new circumstances.
in my case i used keyChain to save first generated UUID then i used it as unique device id it still persistent even if after uninstalling the app