如何以编程方式获取iPhone的IMEI号码?

Har*_*han 2 iphone ios

我使用以下代码来获取objective-c中iPhone的IMEI号码:

NSString *imei = [[NetworkController sharedInstance] IMEI];
Run Code Online (Sandbox Code Playgroud)

但我收到此错误,使用未声明的标识符 "NetworkController"我已导入AFNetworking.h但我无法解决此错误.任何人都可以帮我解决这个问题吗?

Nih*_*ika 7

You can get the UDID, but can not get the IMEI.Apple does not allow this.
Run Code Online (Sandbox Code Playgroud)