Get IMEI and serial number from SIM on iOS programatically
Apple does not allow the use of private framework / api. Also, getting the users IMEI number will cause Apple to reject the app.
How to get IMEI from IOS device using C#
Some device identifiers are now impossible to be obtained from public APIs of iOS:
IMSI - International Mobile Subscriber Identity (SIM card number)
IMEI - International Mobile Equipment Identity (Device ID)
UDID - Unique Device Identifier for Apple iDevices
MAC address - Media Access Control Address (Network address)
Take a look here:
http://studyswift.blogspot.gr/2015/12/asidentifiermanager-get-idfv-vendor.html
If you could use any of the provided IDs the code is in Swift but if you use C# / Xamarin it won't be difficult to convert.
Hope this helps
How to check user's device in iOS SDK
You will have to keep UUID into keychain since keychain data persist after uninstallation of the app
iOS manages keychain information as sensitive information. you can use
SwiftKeychainWrapper library to easily access your keychain.
what apple doc says on SIM change: https://developer.apple.com/documentation/coretelephony/cttelephonynetworkinfo
CodingExample:
let uuid = UIDevice.current.identifierForVendor?.uuidString
KeychainWrapper.standard.set(uuid, forKey: "appUUID")
And whenever you want to get appUUID just fetch from keychain:
let uuid = KeychainWrapper.standard.string(forKey: "appUUID")
Note: You can also check if your UUID is changed after reinstallation
of the app and update it into a keychain.
Related Topics
Iso8601Dateformatter Doesn't Parse Iso Date String
Xcode Logging: "Metal API Validation Enabled"
Default Value of Maxconcurrentoperationcount for Nsoperationqueue
Swift 2.2 #Selector in Protocol Extension Compiler Error
Dequeuereusablecellwithidentifier Never Returns Nil
Contact Address Book Crash on iOS 10 Beta
Could an iOS Application Read/Access Sms Text
How to Delete an App Which Is Waiting for Upload
Stuck on Using Mkpinannotationview() Within Swift and Mapkit
Cannot Show Modal Viewcontroller in iOS7
Firebase Dynamic Link Always Goes to App Store Url Even If the App Is Installed
iOS Are Methods Called by Delegates and Observers Executed on the Main Thread
How to Truncate Decimals to X Places in Swift
Google Maps Url Scheme Not Working on iOS 9
Alamofire 5: Value of Type 'Result<Data, Aferror>' Has No Member 'Value'