Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to access a SIM card programmatically?

Tags:

Just any old GSM compatible SIM card (bonus for 3G USIM).

I presume I need some hardware? Can anyone recommend something cheap for hobbyist, and something more professional?

I presume that there will be full docs of an API with the h/w, so maybe this should be tagged "no-programming-related"? Sorry, if so.

Any good URLs or books (I am conversant with the 3GPP standards).

I'm not (black hat) hacking, don't worry, just not pleased with the likes of SIM Card Secretary, Data Doctor Recovery, etc, so would like to code my own, but might turn it commercial, or offer SIM card programming services (data recover from damaged card, etc) as a sideline.


Update: while I am primarily interested just reading my SMS for backup, it might be a bonus if someone knows of a cheap SIM card writer (so that I can back up all or part of the SIM and restore it later)

like image 363
Mawg says reinstate Monica Avatar asked May 08 '10 00:05

Mawg says reinstate Monica


People also ask

Can you remotely access a SIM card?

SIM cards can be accessed remotely over the Internet and can even be switched between mobile devices without the need to dispatch another SIM card.

How do I access information on my SIM card?

On an Android, you can go to Settings > About Phone to see your SIM's status and info like your phone number, roaming info and more.

What information can be extracted from a SIM card?

SIM cards can contain crucial information, for example, messages having login IDs and passwords related to one's bank accounts and social networking sites. SIM cards may also contain personal and professional messages, important contact information, call logs, etc. Deleted messages can also be recovered from SIM cards.

Can you view a SIM card on a computer?

Yes, you can read the information on your SIM card. There are USB SIM card readers and software available for purchase – the Dekart SIM Card reader is one example. Once you have purchased a SIM card reader, simply place your SIM card inside, and insert the reader into a spare USB drive on your computer.


1 Answers

You can do that with any PC/SC smart card reader (and writer, as others pointed out) and a program that can read and parse the data for you.

  • Talking to a card is done via APDU commands (defined in ISO-7816)
  • The command set used by SIM (2G) and USIM (3G) cards is different, so you have to keep that in mind
  • The structure and format of the file system of a SIM card is defined in GSM 11.11 (for 2G) and ETSI TS 131.102 (for 3G) - all this documentation is public and available free of charge
  • The SMS are kept in a file called EF SMS, its name is 0x6F3C, its structure is defined in section 10.5.3 of GSM 11.11

Direct answers to your questions:

  • Here's where to buy a SIM reader, click on 'photos' to see pics of the device and screenshots of the software
  • SIM Manager is the program that does everything you want (including reading SMS, restoring SMS, it can even attempt to recover deleted SMS - if they're still physically on the card)
  • A SIM card SDK is available too. It is a DLL you can load and apply in your program. This thing does all the hard work for you, all you need is to create a GUI on top of it

I am one of the people from the team that created SIM Manager and the aforementioned SDK.

like image 124
ralien Avatar answered Dec 22 '22 08:12

ralien