tags: SIM card lock IMSI
SIM card lock
Android is a new way to explore, and God can skip it directly.
Original works, please indicate the source! ! ! !
(The content is relatively low-level, I don’t believe that someone will reprint it, hahaha..., manual funny!)
Write the IMSI value of the required SIM card as follows, you can have another card, and query the IMSI value yourself.
Public final static String IMSI = "46000";//Mobile Card
Public final static String IMSI1 = "46002";//Mobile Card
Public final static String IMSI2 = "46001";//Unicom Card
Public final static String IMSI3 = "46003";//Telecom card
Put the following piece of code in the onclick, you can achieve the click effect by satisfying these kinds of cards by clicking
TelephonyManager telManager = (TelephonyManager) getSystemService(Context.TELEPHONY_SERVICE);
/** Get the IMSI code of the SIM card
* SIM card unique identifier: IMSI: International Mobile Subscriber Identification Number (IMSI) is a sign that distinguishes mobile users.
* Stored in the SIM card, can be used to distinguish valid information from mobile users. IMSI consists of MCC, MNC, and MSIN, where MCC is the mobile country number and consists of 3 digits.
* Uniquely identify the country to which the mobile customer belongs, China is 460; MNC is the network id, consisting of 2 digits.
* It is used to identify the mobile network to which the mobile customer belongs. China Mobile is 00, China Unicom is 01, China Telecom is 03, and MSIN is the mobile customer identification code, which is composed of 11 digits of equal length.
* Uniquely identify mobile customers in the domestic GSM mobile communication network. So to distinguish between mobile or Unicom, just get the MNC field in the SIM card.
*/
if (ActivityCompat.checkSelfPermission(this, Manifest.permission.READ_PHONE_STATE) != PackageManager.PERMISSION_GRANTED) {
/ / User may turn off the required permissions
return;
}
else{
String imsi = telManager.getSubscriberId();
boolean phoneCard = (imsi!=null&&(imsi.substring(0,5).equals(this.IMSI)
|| imsi.substring(0,5).equals(this.IMSI1)
|| imsi.substring(0,5).equals(this.IMSI2)
|| imsi.substring(0,6).equals(this.IMSI3)
|| imsi.substring(0,6).equals(this.IMSI4)
|| imsi.substring(0,6).equals(this.IMSI5) )
);
//substring(0,5) Starting from the first one, taking five digits, (0,6) taking 6 digits
1, the main program: 3, file permissions configuration: <uses-permission android: name = "android.permission.READ_PHONE_STATE"> </ uses-permission>...
table of Contents Article Directory table of Contents SIM card USIM card pySim and ADM key SIM card SIM card, Subscriber Identity Module (SIM) is a smart card mainly used to store user identification ...
An APDU can be a command or a response to a command. The general format of the command APDU: CLA INS P1 P2 P2 Data P3 Data The general format for responding to APDUs: Data, SW1, SW1, SW2 The meaning o...
An APDU can be a command or a response to a command. The general format of the command APDU: CLA INS P1 P2 P3 Data The general format of the response APDU: Data SW1 SW2 The meaning of each byte is as ...
First of all, please make sure that you have set up EPC and ENB, and they can be connected (if the MME is connected, there will be a related display, and the ENB side will also display mme is associat...
//SIM card initialization...
6,SIMcard The main content of the SIM card includes the change of the status of the SIM card information. Among them, the state change is mainly reported from the Modem to the RIL daemon and finally r...
http://acm.csu.edu.cn:20080/csuoj/problemset/problem?pid=2027 Give full play to your English reading level, probably the three major operators. Only one operator can be used. You call and surf the Int...
Sim card operator obtains 1. Description SIM (Subscriber Identification Module): Subscriber identification module, the card is mainly used as the unique identity of the user. When the status of the SI...
// Get the TelephonyManager instance object final TelephonyManager tm = (TelephonyManager) getActivity().getSystemService(Context.TELEPHONY_SERVICE); // Get the number of SIM cards final int num...