There are now 4 ways of getting HWID:
Every Android should provide applicationID or MAC address identifiers. Neither Android serial number nor IMEI is accessible since Android 8.X OS. So basically, two licensing mechanisms are currently fully supported on Android generally:
- ApplicationID-based licenses:
- Bound to Android applicationID parameter of APK. (each different APK needs unique license)
- Unlimited to number of devices (one license file for N devices)
- Disabled to generate via CRM till license generator is updated.
- Bounded to specific MAC address of device's network interface. (each device needs unique license )
- Unlimited to number of APKs (one license file of device can be used for N different applications)
The licensing mechanisms are not equal in a business plane- the conditions are a subject of a business agreement.
1. ApplicationID based HWID - returned by IEngine_GetHardwareId function in all Innovatrics' latest SDKs or by License manager desktop utility using command license_manager -c "<aplicationId>"
2. Serial number based HWID - returned by IEngine_GetHardwareId function in old versions of Innovatrics' SDKs (e.g. IDKit SDK v5.3.1, IFace SDK v3.2.2, ANSI&ISO SDK v2.1.0, Segmentation SDK v1.8.0 or older).
3. IMEI based HWID - returned by IEngine_GetHardwareId function if no serial number is found. You can also find the IMEI of your device in Settings->About phone->Status or by entering a special code *#06# using the device's keypad according to http://www.phonearena.com/news/How-to-find-a-phones-IMEI-number_id62867. Please note that you have to add letter 'M' before the IMEI number and then add it to CRM license generator. For example if the IMEI=123456789012345 then the Hardware ID=M123456789012345. You also have to add following permission to application's manifest file in order to use IMEI as Hardware ID:
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
- ANSI&ISO SDK - IEngine_GetHwid in C++, method getHardwareId() in Java
- Segmentation SDK - ISegLib_GetHwid in C++, method getHardwareId() in Java
- IFace SDK - IFACE_Get_HardwareId
In case you have decided to use MAC-based license, you also need to make sure the following permissions are in your project's manifest:
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />