通过私有API检索UDID [英] Retrieving UDID via private API
问题描述
我正在寻找一种在运行iOS 6+(仅企业部署-无应用商店限制)的设备上检索UDID的方法.
I'm looking for a way to retrieve the UDID on devices running iOS 6+ (Enterprise deployment only - no app store limitations).
调用(现在是私有的)方法uniqueIdentifier
返回以'FFFFFFF'开头的'vendorIdentifier'.不幸的是那不是我想要的.
Calling the (now private) method uniqueIdentifier
returns the 'vendorIdentifier' starting with 'FFFFFFF'. Unfortunately thats not what I want.
有什么想法吗?还有另一种私有方法吗?
Any ideas? Is there another private method or something?
谢谢.
推荐答案
I recommend you reading this article. To sum up:
- 以前不推荐使用的
uniqueIdentifier
现在在iOS 7+上的作用与vendorIdentifier
相同,因此即使对于企业应用程序也不再可用 - OpenUDID 不能在iOS 7+上的应用程序之间共享,并且现在可以更改.它仍然可用,但不再推荐.
-
vendorIdentifier
尚未更改,但不建议在Enterprise Apps中使用,因为在更新应用程序时它可能会更改. - 新的
advertisingIdentifier
API 是购买新应用程序的方式.对于所有应用程序都是相同的,并且不应经常更改,但是用户可以在设置页面中将其重置.
- The previously deprecated
uniqueIdentifier
now works likevendorIdentifier
on iOS 7+, so it's no longer usable even for Enterprise Apps - OpenUDID cannot be shared between Applications on iOS 7+ and now can change. It's still usable but no longer recommended.
- The
vendorIdentifier
hasn't changed, but it's not recommended for Enterprise Apps because it can change when updating the App. - The new
advertisingIdentifier
API is the way to go for new Apps. It's the same for all Apps and should not change frequently, but the user can reset it in the settings page.
网站 udid.io 获取真实的设备UDID,而不是经过混淆的UDID(如果您需要使用它)在您的应用程序之外.如果您需要从应用程序中获取UDID,请参阅上面的答案.
Website udid.io obtains the real Device UDID instead of the obfuscated one if you need it for anything outside your App. If you need the UDID from within the App, see my answer above.
这篇关于通过私有API检索UDID的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!