in order. It looks like you have most of the flow already tuned into your mind. I add a few specific things:
1. Registration
Users will need to explicitly read the SIM serial number, which is physically printed on the side of the SIM card and must tell you this serial number (in case you register users manually and offline) .. or users can register themselves online by entering this specific serial number SIM (if your registration process is connected to the network and controlled by the user). It will only be time recording.
I am not sure of any search for the serial number of the SIM card without removing the SIM card from the phone. You can study it more.
2. Authentication
Now, every time a user launches your application, you can read information related to the SIM card, such as the serial number of the SIM card, operator code, operator name, operator country code, etc. and transmit this information to your web server for authentication.
To get these details you need to use the functions getSimOperatorName() , getSimSerialNumbe() , getSimCountryIso() TelephonyManager .
Please note that since @rajesh has already commented that there is no IMEI. It is used to identify the device, not the SIM card, so it is not needed if you want authentication to be specific to the SIM card.
3. Verification
In addition to authentication, you will have to implement the logic to see the status of the SIM card (perhaps after each specific time interval or only at the time when your application is used).
You will need to use the getSimState() function for TelephonyManager to read the states:
SIM_STATE_NETWORK_LOCKED - Indicates that the SIM card is blocked by the network operator. (disconnection, when the user had to inform about SIM blocking after a lost SIM card event. SIM_STATE_ABSENT - indicates that there is no SIM card.
Accordingly, you can exit the application by displaying appropriate messages to the user.
This approach can be modified and used according to your requirements. Hope this helps you.