2

Is there a way to "virtualize" a SIM card?
Say I go to T-Mobile, and get a new phone line. I have a new number (say (123) 456-7890), and a new SIM card (new ICCID).

Is there a way to "virtualize" that SIM card's information so it can be used on a virtual android machine?

  • Perhaps you can extend the detail of what you are really trying to do with SIM card on the virtual machine? If it's to emulate something, then (I think) there's a way, but if it's to do telco-related thing (e.g. phone call), no, it's useless, since the host (or, your PC) doesn't have required hardware to do it. – Andrew T. Jun 7 '16 at 13:40
1

Just found this: Is it possible to virtually emulate a SIM card and make it work on a mobile phone?

Not impossible.

SIM card basically carries authentication information to make the required connection with the network. So, to be able to connect to a network in the name of SIM you don't have, you have to have the information which the SIM carries.

Once you have this, you have to tamper with the phone's hardware(and/or software) to get the information it is expected to collect from the SIM from somewhere else.

Since, the interface between the SIM and the phone is standardised for any given technology, it should not be impossible to mimic this, using a combination of hardware and software. But, such a system is readily available? I haven't heard of.

It seems it's possible if you're genius enough to understand and implement how the interfacing between phone and sim card is done, because on the basic level, a sim card is nothing but a storage device holding access codes and data (you may just virtually store this info and emulate/read it like there's a sim card).

But as far as I searched, no one has done it.. And also, as @Andrew commented, you need appropriate radio hardware to make telecommunication even if something like that hack is accomplished :)

  • I suspect that SIM cards contain some form of encryption which would be almost impossible to reverse engineer or to extract. A bit like hardware dongles. – Rolf Apr 28 '18 at 13:26
  • @Rolf Hardware dongles are tied with the software drivers that each dongle vendors provide, which handles the means of encrypted communication or access to the hardware. But I don't think that's the case with a SIM card; a SIM card can be manipulated by any phone, from the basic ones to Android. So, there can't be a standard way of encryption to comply between the interfacing. If it's possible to use a SIM card from a Nokia 1100 designed decades ago, it is possible to simulate the same communication provided the right hardware and understanding the interfacing of SIM cards. – Gokul NC Apr 28 '18 at 15:20
  • I think they use the same principle for providing security. I was not thinking about drivers. So basically there is like a private key on the SIM card. I don't know really. Very old dongles would implement authentication by means of a circuit that would act like a private key. You pass a value to the dongle and it would return another value and this operation can be authenticated but is very hard to reverse engineer, and the dongle is destroyed if you try to open it. So i'm thinking SIM cards implement something like that, or maybe they just store a private key. – Rolf Apr 28 '18 at 18:26
0

The SIM card is more complex than you think. Of course it is identified by an MSISDN, basically a unique number identifying the phone number internationally. BUT, there are 2 sides to the encryption, 1/2 Key is stored on the SIM card itself, and the other half is stored on the Network (The HLR - Home Location Register). The combination of those 2 enables the Operator to make sure you are allowed to use the network as per your contract with this operator. Only the right combination of those 2 1/2 keys (one of which is in possession of the operator only, enables the device using the SIM card to make phone calls etc... The second half is indeed stored in the SIM card, however there is no way to read it, and it does not even send it to the device, instead the Network generates a unique number say "N" and sends it to the device, itself forwards it to the SIM, which, using an algorithm generates a new number which is (if the SIM card is real), recognized by the network and lets the user "Use" the network. Because the number N resulting from the Network is combination of the Private Key + a randomly generated one, you cannot get anywhere. The actual key is indeed physically encoded on some chip on the SIM card itself, however there is no practical way to get to it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.