14

I am interfacing with a GSM modem module through the standard GSM AT command interface. Right now the access point names (APN), user names, and passwords for each known carrier are hard coded in my software. I am wondering if this information is provided by the carrier on the SIM card. Is this the case?

I am willing to try to directly access the file structure of the sim card with "+CRSM" or "+CSIM", but would like to know if the APN information is even there before I start. If so, is there a link that describes SIM file structure that contains this information? Many thanks.

1
  • 1
    did you get any solution to get the apn based on simcard?
    – dmSherazi
    Jun 2, 2016 at 15:04

3 Answers 3

17

SIM cards have many Elementary Files (EF). Ref 3GPP TS 31.102 & ETSI TS 102.221 which are freely available.

One such EF is EF-ACL which is "APN Control List" which can contain the APN names which the Operator wants the Device to use.

Note that EF-ACL can control the Device to use a particular APN, however, it CANNOT provide the APN. The APN should be present in Device's database (eg. apn-conf.xml in Android Phones) or the Device can ask the network to provide an APN (network-provided-APN) Ref. Sec 5.3.14 in 3GPP TS 31.102

The EF-ACL service needs to be "available" in EF-UST and "enabled" in EF-EST for the Device to use it. If it is available & enabled, then the contents can be read using the following AT Command:

at+crsm=176,28503,0,0,255

Here, I have assumed length of the EF-ACL to be 255 Bytes. However, it could be different in different SIMs.

2
  • How to Enable these services EF-ACL and EF-UST
    – dmSherazi
    Jun 2, 2016 at 15:04
  • 1
    It's /system/etc/apns-conf.xml. The s with apn. Jun 30, 2020 at 18:53
0

I made some research on this wiki and this link

but nothing seems to indicate this information is available in the SIM card. My guess is this information is stored in the device memory(mobile or modem).

maybe you could use sim explorer to a better investigation of the SIM file system.

0

An APN node structure consists of network id,mcc and mnc which are available in sim card hence the device would indirectly get the apn from the sim card .

1
  • 1
    Can you point out which EF with APN data? I don't think your answer is correct.
    – Kislingk
    Nov 10, 2020 at 20:54

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.