Subscriber Identity Module Update

A method and software agent on the host device derive a shared key to securely update SIMs in IoT devices over IP networks, addressing the lack of HTTP OTA support in legacy communication modules by encrypting and decrypting update messages, thus enhancing SIM update efficiency.

JP7541604B2Active Publication Date: 2024-08-28SORACOM INC
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
JP2023141069
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Priority Date
2018-07-02
Filing Date
2023-08-31
Publication Date
2024-08-28
Estimated Expiration
2039-07-01

AI Technical Summary

Technical Problem

Many manufacturers of SIM-enabled communication modules do not support HTTP OTA due to increased cost and effort, limiting the ability to update SIM cards in IoT devices over IP networks, as BIP support is often absent in these modules.

Method used

A method and software agent on the host device derive a shared key to securely channel OTA commands to SIMs, enabling HTTP OTA without requiring BIP support in the communication module, using a pre-shared key derived from authentication responses to encrypt and decrypt update messages.

Benefits of technology

Enables secure and efficient updating of SIMs in legacy communication modules over IP networks, reducing the need for SMS support and enhancing compatibility with IoT devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007541604000006
    Figure 0007541604000006
  • Figure 0007541604000001
    Figure 0007541604000001
  • Figure 0007541604000003
    Figure 0007541604000003
Patent Text Reader

Abstract

To provide a method for updating a SIM on a host device.SOLUTION: A method includes the steps of deriving a pre-shared key using a value received from a SIM update server, sending, to the SIM update server, an update request message encrypted before transmission using the pre-shared key, receiving an update response message containing update data and encrypted with the pre-shared key from the SIM update server, and decoding the update response message and sending the update data to the SIM on a host device.SELECTED DRAWING: Figure 2
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] The present disclosure relates to updating a subscriber identity module (SIM) on a host device. [Background technology]

[0002] Mobile operators are often faced with the challenge of updating SIM cards in the field to deploy modifications or new applications. The current standard for this is called Over-The-Air (OTA) and usually requires that the subscription plan supports Short Message Service (SMS). With the advent of 4G technology, a new form of OTA has emerged: HTTP OTA. This is described, for example, in "Global Platform Card Specification Version2,2 Amendment B Version 1.1", "ETSI TS 102 225 entitled Smart Cards; Secured packet structure for UICC based applications", and ETSI TS 102 226 entitled "Smart Cards; Remote APDU structure for UICC based applications".

[0003] Instead of using its predecessor technology, SMS OTA, HTTP OTA allows remote management commands to be communicated to the SIM card over an IP network.

[0004] The arrival of 4G technology has been accompanied by the emergence of autonomous connected devices known as the Internet-of-Things (loT). Nowadays, a large number of mobile loT devices are networked using SIM-enabled communication modules (e.g. HSDPA modems). Summary of the Invention [Problem to be solved by the invention]

[0005] The inventors have found that many manufacturers of SIM-enabled communication modules have chosen not to provide the necessary support for HTTP OTA through implementation of Bearer Independent Protocol (BIP) in their communication modules. This is for a variety of reasons, including increased costs and efforts for developing and testing communication modules. Meanwhile, support for HTTP OTA through BIP has been implemented fairly rapidly by SIM vendors in new UICC cards.

[0006] Currently, BIP support in communication modules is only available in some high-end phones and communication modules that can host SIM cards of type eUICC with MFF2 form factor. As a result, most communication modules that are connected with removable SIMs (mini-SIM, micro-SIM and nano-SIM) do not support HTTP OTA. Furthermore, in many deployments of IoT projects, the only available communication bearer is the IP network.

[0007] To address this lack of HTTP OTA support, embodiments of the present disclosure implement a software agent that can take over the HTTP portion and help securely channel OTA commands to a SIM hosted in a legacy communication module. [Means for solving the problem]

[0008] According to one aspect of the disclosure, there is provided a method of deriving a shared key for use in communicating with a network entity, the method being performed by an agent on a host device and including the steps of requesting a SIM identifier for a Subscriber Identity Module (SIM) on the host device from a communication module of the host device, receiving the SIM identifier from the communication module and deriving an agent identifier from the SIM identifier, transmitting the agent identifier and the SIM identifier over a network to the network entity, receiving a random value from the network entity over the network, providing the random value to the communication module to initiate a SIM authentication procedure and receiving in return an authentication response from the communication module, and deriving the shared key from the authentication response.

[0009] According to another aspect of the present disclosure, there is provided a method for updating a Subscriber Identity Module (SIM) on a host device, the method being performed by an agent on the host device and including the steps of deriving a pre-shared key, the steps including the steps of requesting a SIM identifier of a deferred SIM via a communication module of the host device, receiving the SIM identifier from the SIM via the communication module and deriving an agent identifier from the SIM identifier, transmitting the agent identifier and the SIM identifier to a SIM update server via a network, receiving a random value from the SIM update server via the network, providing the random value to the SIM via the communication module to initiate a SIM authentication procedure and receiving in return an authentication response from the SIM via the communication module. and deriving the pre-shared key from the authentication response; sending an update request message over the network to the SIM update server, the update request message including the agent identifier and encrypted with the pre-shared key prior to transmission; receiving an update response message from the SIM update server over the network, the update response message including update data and encrypted with the pre-shared key; and following decryption of the update response message using the derived pre-shared key, sending the update data to the communications module for relay to the SIM for execution to update the SIM.

[0010] The authentication response may include a signed response and a cryptographic key.

[0011] Deriving the pre-shared key from the authentication response may include deriving the pre-shared key using at least one of the signed response and the cryptographic key.

[0012] Deriving the pre-shared key from the authentication response may include deriving the pre-shared key using a random value.

[0013] Deriving the pre-shared key from the authentication response may include concatenating the encryption key with itself to generate a concatenation result, and applying a bitwise XOR operation on the concatenation result and the random value to derive the pre-shared key.

[0014] The update data may be encrypted with a symmetric encryption key stored in the SIM.

[0015] The update request message may include the SIM identifier.

[0016] The method may include receiving an execution result from the SIM via the communications module in response to sending the update data to the communications module, and sending a further update request message via the network to the SIM update server, the update request message conveying the execution result and being encrypted before transmission using the pre-shared key.

[0017] An AT (Attention) command can be used to at least one of the following: request a SIM identifier of the SIM from the host device's communication module, provide a random value to the communication module to initiate a SIM authentication procedure, and send the update data to the communication module.

[0018] The application programming interface provided by the communications module can be used for at least one of the following: requesting a SIM identifier of the SIM from the communications module of the host device, providing the random value to the communications module to initiate a SIM authentication procedure, and sending the update data to the communications module.

[0019] Deriving an agent identifier from the SIM identifier may include adding a prefix to the SIM identifier.

[0020] The derivation of a pre-shared key may be triggered based on any of the following: (i) detecting user input on the host device, (ii) receiving a session initiation message from the SIM update server over the network, and (iii) detecting the expiration of a predetermined time interval.

[0021] The SIM identifier may be any of the following: (i) an IMSI associated with the SIM, (ii) an ICCID associated with the SIM, and (iii) an MSISDN associated with the SIM.

[0022] According to another aspect of the present disclosure, a computer program product is provided, the computer program product comprising code embodied on a non-transitory computer readable medium and configured to perform the methods described herein when executed on a processor of a host device.

[0023] According to another aspect of the present disclosure, a device is provided having a processor, the processor is coupled to a communication module coupled to a SIM associated with the device and configured to request a SIM identifier for the SIM via the communication module, receive the SIM identifier from the SIM via the communication module, derive an agent identifier from the SIM identifier, transmit the agent identifier and the SIM identifier to a SIM update server via a network, receive a random value from the SIM update server via the network, provide the random value to the SIM via the communication module to initiate a SIM authentication procedure, receive in return an authentication response from the SIM via the communication module, derive a pre-shared key from the authentication response, transmit an update request message to the SIM update server via the network, receive an update response message from the SIM update server via the network, and following decryption of the update response message with the derived pre-shared key, transmit the data to the communication module for relay to the SIM for execution to update the SIM. The update request message includes the agent identifier and is encrypted prior to transmission using the pre-shared key. The update response message includes update data and is encrypted with the pre-shared key.

[0024] According to another aspect of the present disclosure, there is provided a device having a processor, coupled to a communications module coupled to a subscriber identity module (SIM) associated with the device, configured to request a SIM identifier of the SIM from the communications module, receive the SIM identifier from the communications module, derive an agent identifier from the SIM identifier, transmit the agent identifier and the SIM identifier over a network to a network entity, receive a random value from the network entity over the network, provide the random value to the communications module to initiate a SIM authentication procedure, and receive in return an authentication response from the communications module, and derive a shared key from the authentication response.

[0025] According to another aspect of the present disclosure, there is provided a method of updating a SIM on a host device, the method being performed by a SIM update server and comprising the steps of deriving a pre-shared key, the pre-shared key including receiving from an agent on a host device an agent identifier and a SIM identifier of the SIM sent from the host device over a network, generating a random value, providing the random value and the SIM identifier of the SIM to an authentication entity and receiving in return an authentication response from the authentication entity, deriving the pre-shared key from the authentication response, storing the pre-shared key in memory in association with the agent identifier, transmitting the random value to the agent over the network, receiving an update request message from the agent on the host device over the network, the update request message including the agent identifier and encrypted prior to transmission using the pre-shared key, and transmitting an update response message to the host device over the network following decryption of the update request message using the pre-shared key, the update response message including update data and encrypted with the pre-shared key.

[0026] According to another aspect of the present disclosure, there is provided a computer program product for updating a subscriber identity module (SIM) on a host device, the computer program product comprising code embodied on a non-transitory computer readable medium and configured to perform the methods described herein when executed on a processor of a network entity (a SIM updating server).

[0027] According to another disclosure of the present disclosure, there is provided a SIM update server for updating a SIM on a host device, the SIM update server comprising at least one processor configured to receive an agent identifier sent from an agent on a host device via a network, generate a random value, provide the random value and a SIM identifier of the SIM to an authentication entity, receive an authentication response from the authentication entity in return, derive a pre-shared key from the authentication response, store the pre-shared key in association with the agent identifier in a memory coupled to the SIM update server, receive an update request message from the agent on the host device via the network, and transmit an update response message to the host device via the network following decryption of the update request message using the pre-shared key. The update request message includes the agent identifier and is encrypted using the pre-shared key before transmission. The update response message includes update data and is encrypted using the pre-shared key.

[0028] The SIM update server may include multiple processors for updating the SIM on the host device, and the multiple processors may be distributed over multiple coupled elements (e.g., servers) in communication with each other (e.g., as in a cloud architecture) in a manner known to those skilled in the art.

[0029] The authentication response may include a signed response and a cryptographic key.

[0030] The processor may be configured to derive the pre-shared key from the authentication response using at least one of the signed response and the cryptographic key.

[0031] The processor may be configured to additionally use the random value to derive the pre-shared key.

[0032] The processor may be configured to derive the pre-shared key from the authentication response by concatenating the encryption key with itself to generate a concatenation result, and applying a bitwise XOR operation on the concatenation result and the random value to derive the pre-shared key.

[0033] The update data may be encrypted with a symmetric encryption key stored in the memory.

[0034] The update request message may include the SIM identifier.

[0035] Those skilled in the art will appreciate that processor control code for implementing the methods, devices and network entities described above may, for example, be executed on a general purpose computer, a mobile computing or communications device, on a digital signal processor (DSP) or across multiple processors. The code may be provided on a non-transitory physical data carrier such as a disk, CD-ROM or DVD-ROM, programmed memory such as non-volatile memory (e.g. flash), or read-only memory (firmware). Code (and / or data) for implementing embodiments of the invention may include source code (interpreted or compiled), object code or executable code in conventional programming languages ​​such as C, assembly code or hardware description languages. As those skilled in the art will appreciate, such code and / or data may be distributed among several coupled components in communication with each other.

[0036] Those skilled in the art will also understand that when reference is made to a server, this may be one or more servers. Similarly, some or all of the storage or processing functions may be provided in a cloud, which may be a public cloud or a private cloud. As used herein, "cloud" refers to a system that can dynamically provision and provide computing resources, such as CPU, memory, storage, network bandwidth, etc., as demand dictates over a network. Those skilled in the art will also understand that the server software may be implemented on a physical computer or computer system that is also running the client software.

[0037] These and other aspects will be apparent from the embodiments described hereinafter. The scope of the disclosure is not intended to be limited by this Summary, nor is it intended to be limited to implementations that necessarily solve any or all of the described disadvantages. [Brief description of the drawings]

[0038] [Figure 1] FIG. 1 illustrates a process flow of a known SIM update procedure. [Diagram 2] FIG. 1 is a block diagram of a system for updating a SIM according to embodiments described herein. [Diagram 3] 3 is a block diagram of a mobile station for use in the system of FIG. 2. [Figure 4] FIG. 3 is a block diagram of a SIM for use in the system of FIG. 2. [Diagram 5] FIG. 13 is a diagram illustrating a process flow of a procedure for deriving a pre-shared key. [Figure 6] FIG. 2 illustrates a process flow for a SIM update procedure according to embodiments described herein. [Figure 7] 11 is a diagram for explaining an update response message transmitted in the SIM update procedure. FIG. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0039] The following definitions / examples are used herein: · Second generation mobile communication technologies such as 2G GSM Third generation wireless mobile communication technologies such as 3G EDGE 4G (fourth generation) is the fourth generation of wireless mobile communication technology such as LTE. APDU Application protocol data unit. Defines the basic set of commands and responses that can be exchanged with a smart card via the ISO 7816 interface. API Application protocol data unit, which exposes the specific functionality provided by that interface. The Bearer Independent Protocol defined in BIP TS 102 223 allows a Card Application Toolkit application on the UICC to establish a data channel with the terminal. eUICC embedded UICC (embedded SIM, usually soldered onto a circuit board) EDGE Enhanced Data GSM Environment is a high-speed 3G wireless communication standard based on GSM (Global System for Mobile). GSM stands for Global System for Mobile communications, a 2G wireless communication standard. ·GPRS General packet radio service HSDPA High Speed ​​Downlink Packet Access is one of the two sub-protocols of HSPA (High Speed ​​Packet Access), a 3G mobile communication network protocol. HTTP OTA Hypertext Transfer protocol over-the-air. SIM card via IP service A protocol for transmitting management commands to ·IEEE Institute of Electrical and Electronic Engineers IMSI International Mobile Subscriber Identity is a unique identification number used to identify a user of a cellular network and associated with all cellular networks. For example, it is represented as IMSI: xxx yy 1234567890. Here, XXX: stands for MCC YY: indicates MNC Part of TCP / IP, a longer abbreviation for IP iUICC integrated UICC (i.e. software SIM) ·LTE Long Term Evolution. 4G wireless communication standard. MCC: Mobile Country Code MNC:Mobile Network Code MFF2 Machine-to-machine form factor 2 defines one of the many shapes a SIM card can take, this is one of the smallest embeddable versions. OTA Over-The-Air. This covers any method of sending updates to the SIM (e.g. SMS OTA, HTTP OTA, etc.). · SCP80 Secure Channel Protocol 80 is a standard for OTA over SMS defined by Global Platform. SCP81 Secure Channel Protocol 81 is a standard for OTA over IP networks defined by Global Platform, also known as HTTP OTA. Covers all variations of authentication tokens in all forms, including SIM UICC, eUICC, iUICC, SoftSIM etc. ·SMS Short Message Service, commonly known as "text message". SMS OTA Short Message Service over-the-air is a protocol for transferring management commands to the SIM card via SMS. · TCP / IP stands for Transmission Control Protocol / Internet Protocol. A set of networking protocols that allows two or more computers to communicate. UICC (universal integrated circuit card) A smart card used in mobile terminals in GSM and UMTS networks. Wi-Fi is a trademark of the wireless networking standard defined by IEEE 802.1 1x.

[0040] In standard HTTP OTA (see Figure 1), SCP81 is implemented at the SIM and device level. This requires BIP support in the host device (more specifically, in the host device's communication module). BIP support in the host device means that it supports several specific Card Application Toolkit commands and events, namely: OPEN CHANNEL, CHANNEL STATUS, CLOSE CHANNEL, SEND DATA, RECEIVE DATA, EVENT DATA AVAILABLE. This is described in ETSI TS 102 223, entitled "Smart Cards; Card Application Toolkit (CAT)".

[0041] FIG. 1 is a flow chart 100 of a prior art HTTP OTA message protocol.

[0042] In a typical HTTP OTA session, in response to the communication module receiving a binary SMS message from the OTA server (step 1), the communication module opens a TCP channel to the specified server address (IP address is specified in the OPEN CHANNEL command) in steps 2-6. The device forwards higher-level protocol messages (requests) received in turn from the SIM in the form of SEND DATA commands (step 7) towards the OTA server via the TCP channel (step 8). These higher-level messages are actually wrapped in HTTPS packets by the SIM. The OTA server processes the request and sends back a response message (step 9). The response message potentially contains RFM (Remote File Management) or RAM (Remote Application Management) commands to be executed by the SIM (steps 10-13). The SIM in turn sends the execution results to the communication module, which relays the execution results to the OTA server in the form of new requests (step 15) until the OTA server sends an empty response (step 16). In response to processing the empty response (steps 17-19), the SIM instructs the communication module to close the TCP channel (step 20). The communication module then communicates with the OTA server to close the TCP channel (steps 21-22) and notifies the SIM of the closure of the TCP channel (step 23).

[0043] Higher level messages exchanged over the TCP channel are wrapped in HTTP packets, which are themselves encapsulated in TLS protocol packets. The particular version of the TLS protocol used here is called TLS Pre-Shared Key (PSK), where a pre-shared secret key known by the OTA server and the SIM is used to encrypt / decrypt the communication packets.

[0044] Reference is now made to Figure 2, which illustrates a block diagram of a system 200 for updating a SIM in accordance with an embodiment described herein. The system comprises an IP network 114 having conventional network elements and includes a number of base stations 114a (only one shown for illustrative purposes) for communicating with a host device 102a. The host device 102a is a computing device capable of transmitting data to and receiving information from the network 114. The host device 102a may take the form of, for example, a laptop computer, a tablet computer, or a mobile phone (sometimes referred to as a "smartphone"). In the example of Figure 2, the host device 102a is shown as a mobile device (and thus referred to herein as a "mobile station"), but this is merely for illustrative purposes.

[0045] Each of the mobile stations 102a communicates with a network 114 via a wireless data communications link and has an associated SIM 102b. In the illustrated example, the network 114 is also coupled to the Internet 116.

[0046] The system 200 also includes a SIM update server 110 (alternatively referred to herein as a "network entity") for updating the SIMs. The SIM update server 110 is configured to send Over-the-Air (OTA) updates to the SIMs, and is therefore also referred to herein as an OTA server. As illustrated, it is shown as a separate element, but in practice it may be implemented as an additional software component running on an existing network device or server. As will be described in more detail below, the SIM update server 110 includes a processor 111 and a memory 112, which stores code for receiving update request messages from the host device and sending update data to the host device. The SIM update server 110 is coupled to a Home Location Register (HLR) 118, also referred to as a Home Subscriber Server (HSS). The term HLR is typically used when the mobile network 114 is a 2G or 3G network, and the term HSS is typically used when the mobile network 114 is a 4G LTE network.

[0047] The HLR / HSS 118 is a database used to store and manage information of all subscribers authorized to use the network 114. For each subscriber, the HLR stores subscriber information including the subscriber's International Mobile Subscriber Identity (IMSI), service subscription information, location information, service restrictions, etc. The HLR / HSS 118 comprises or is coupled to an Authentication Center (AuC) 119. The AuC 119 provides authentication for each subscriber. The AuC 119 comprises a database that stores, for each subscriber, a shared key Ki for authentication of the subscriber's SIM. The AuC 119 may store multiple shared keys, each associated with each IMSI (or other SIM identifier).

[0048] 2 shows an example system in which the network 114 is a mobile (cellular) communications network, but this is merely illustrative. For example, embodiments are also included in which the methods described herein are used to implement OTA updates whereby the host device is coupled to the Internet or IP network 116 via a WiFi link over a WiFi network. That is, in embodiments of the invention, OTA updates can be accomplished over any data connection (e.g., WiFi, LAN, etc.) even if SIM 102b is unable to authenticate on the cellular network (e.g., during a roaming attempt).

[0049] 3 is a block diagram of an exemplary mobile station 102a. The connections between the various components of the mobile station 102a shown in FIG. 3 are merely exemplary.

[0050] As shown in Fig. 3, the mobile station 102a comprises a SIM 102b. As a person skilled in the art will appreciate, "SIM" as used herein may include a SIM card, a so-called eSIM (a module that can be embedded in a device), a so-called soft SIM or virtual SIM (a software SIM that can be stored in a module of a device, such as the communication module 202, and optionally downloadable over the air), or a so-called secure element. The techniques described herein are also applicable to SIMs other than SIM cards. Thus, the SIM may be embodied in, for example, a Universal Integrated Circuit Card (UICC), eUICC, iUICC, etc.

[0051] The communication module 202 acts as an intermediary for communication between the SIM 102b and an agent 204 (described in more detail below). The communication module 202 is, for example, a modem, such as an HSPDA modem. In the embodiments described herein, the communication module 202 may not support Bearer Independent Protocol (BIP), but the agent 204 enables a type of HTTP OTA without requiring BIP support in the communication module, thus allowing SIM cards inside legacy communication modules (that do not support BIP) to securely exchange RFM and RAM messages over an IP network.

[0052] The communication module 202 may be external to the mobile station 102a in that it is a separate unit housed in a separate casing, but is connected or connectable to the processor 206 of the mobile station 102a by a wired or wireless connection (in addition to being removable from the mobile station 102a). For example, the communication module 202 may take the form of a dongle for plugging into the mobile station 102a. By way of example only, the communication module may take the form of a Huawei USB stick MS2131. Alternatively, the communication module 202 may take the form of an internal part of the mobile station 102a, e.g., a radio module within the mobile station 102a. For example, both the communication module 202 and the host processor 206 may be housed within the same casing of the mobile station 102a.

[0053] The mobile station 102a further comprises an agent 204 (update handler) configured to communicate with the communication module 202. The agent 204 is further configured to communicate with the OTA server 10 via the network 14. That is, the handling of HTTP over TLS is delegated to an agent 214 on the mobile station 102a.

[0054] The functionality of the agent 204 may be implemented in a code (software) stored in a memory (e.g. memory 208) including one or more storage media and ready to be executed on a processor 206 including one or more processing units. The code is configured to perform operations according to the embodiments described below when fetched from the memory 208 and executed on the processor 206. An implementation of the software agent 204 will typically consist of a code executed on an operating system (OS) of the mobile station 102a. The OS (e.g. Windows™, Mac OS™ and Linux™) executes on the processor 206. The agent 204 may be provided, for example, in the form of a command line tool capable of triggering a communication session. Alternatively, it is not excluded that some or all of the functionality of the agent 204 is implemented in a dedicated hardware circuit or a configurable hardware circuit such as an FPGA.

[0055] In one embodiment, the agent 204 is in the form of an agent application downloadable by the customer to their computing device. The agent application can then trigger a remote update where SMS OTA is not available or if the SMS payload requires too many concatenated SMS messages (thereby increasing the risk of failure). In one example scenario, if a user living in a remote location has a SIM that is not connected to the local mobile network, the user can be instructed to connect the communication module 202 to the computing device and download the agent application 204 to the computing device. According to functionality described in more detail below, the agent application 204 can then receive new SIM credentials as an update via a connection to the OTA server 110 over a WiFi Internet link, which can be used to reconfigure the SIM to connect to the local mobile network.

[0056] The agent 204 is configured to communicate with the OTA server 110 using a communication interface 210 of the mobile station 102a. The communication interface 210 may include a wireless transceiver to enable communication between the agent 204 and the network 114.

[0057] The mobile station 102a may further comprise a display 212, such as a screen, a touch screen, etc. The mobile station 102a may also comprise at least one input device 214, such as, for example, a keypad, a microphone, a camera, a touch screen, etc., for receiving user input from a user of the mobile station 102a, and / or at least one output device 214, such as, for example, a speaker.

[0058] 4 is a block diagram of an exemplary SIM card of SIM 102b. The SIM card comprises a processor 120 coupled to a working memory 122, a non-volatile data store 124 such as an EEPROM, and a permanent program memory 126 such as a ROM. The SIM card also has an interface 128 for receiving power and accepting commands from the communication module 202 and providing responses. The permanent program memory 126 may store network / device interface code, an operating system including, for example, Java Card, and typically, but not necessarily, a Sim Application Toolkit (STK). The non-volatile data store 124 typically stores user telephone directory information, configuration data, software patches, etc. The non-volatile data store 124 may store a shared key Ki and an IMSI associated with SIM 102b. The authentication key Ki is "shared" in the sense that it is stored by both SIM 102b and AuC 119. Typically, the shared key Ki is stored in a protected manner, whereas the IMSI is publicly accessible.

[0059] 5 and 6, further code for performing the SIM operations described below may be present in permanent program memory 126, but may alternatively be stored partially or entirely in non-volatile data store 124.

[0060] As mentioned above, although FIG. 4 shows SIM 102b as a SIM card, its functionality may be implemented as an eSIM or softSIM as well.

[0061] Reference is now made to Figure 5, which illustrates a process 500 for deriving a pre-shared key (PSK). A pre-shared key (PSK) is an encryption key, and process 500 is performed at the start of a communication session such that both the mobile station 102a and the OTA server 110 mutually derive a pre-shared key for use in encrypting communications between the mobile station 102a and the OTA server 110. That is, the agent 204 and the OTA server 110 share the mutually derived key (PSK).

[0062] In step 1, the agent 204 sends a request for an identifier of SIM 102b to the communication module 202. As shown in Figure 5, the requested SIM identifier may be the IMSI associated with SIM 102b, or it may be the ICCID, MSISDN, or any other identifier associated with SIM 102b as would be known to one skilled in the art.

[0063] Step 1 may be accomplished, for example, by the agent 204 sending an ATtention (AT) command to the serial interface of the communication module 202. An "AT command" is a known message format for serial communication with modems defined in 3GPP TS 07.007. For example, an "AT+CIMI" command can be used in step 1 to obtain the identifier of SIM 102b.

[0064] An alternative way in which step 1 can be accomplished is to use an API provided by the communications module 202 such that the agent 204 can send an API call to the communications module 202 to request the SIM identifier.

[0065] Step 1 may be triggered by a user of the mobile station 102a providing input via the input device 214 of the mobile station 102a (e.g., by making a selection in a graphical user interface displayed on the display 212). Alternatively or additionally, the MNO may trigger the communication session by sending a session initiation message from an OTA server to the mobile station 102a over the network 114. In this embodiment, the agent 204 should be programmed to support the necessary triggers, such as SMS processing or some form of network service. Alternatively or additionally, step 1 may be triggered based on the agent 204 detecting the expiration of a predetermined time interval (e.g., by monitoring an internal timer) such that the process 500 is executed periodically.

[0066] In response to receiving the request from the agent 204, the communications module 202 requests a SIM identifier from the SIM 102b in step 2. This may be performed by executing an application protocol data unit (ADPU) command.

[0067] In step 3, SIM 102b provides the requested SIM identifier to the communications module 202, which then returns the SIM identifier to the agent 204 in step 4.

[0068] In response to receiving the SIM identifier, the agent 204 is configured to generate an agent identifier from the SIM identifier. The agent identifier is a unique string that identifies the agent 204. In one example, the agent 204 derives the agent identifier by appending the prefix "agent" to the SIM identifier. It will be appreciated that this is merely an example to illustrate the concept and that alternative methods for deriving an agent identifier using the SIM identifier may be used.

[0069] In step 5, the agent 204 transmits the agent identifier and the SIM identifier to the OTA server 110 over the network 114. In step 5, the agent may trigger an API (e.g., a Web API) on the IP network 114 with the agent identifier as a parameter. The API is provided over a secure channel, e.g., HTTPS. The transmission of the agent identifier to the OTA server 110 in step 5 serves as a request for a challenge, as described in more detail below.

[0070] In response to receiving the agent identifier, in step 6 the OTA server generates a random value (RAND), also called a “challenge”, for example 128 bits in length, and sends the challenge (RAND) and the SIM identifier to the AuC 119.

[0071] The AuC119 retrieves the shared key Ki stored in association with the SIM identifier, generates a signed response (SRES) using a first authentication algorithm (e.g., an A3 encryption algorithm) with the shared key Ki and the challenge (RAND) as input, and generates an encryption key (Kc) using a second authentication algorithm (e.g., an A8 encryption algorithm) with the shared key Ki and the challenge (RAND) as input.

[0072] In step 7, the OTA server 110 receives the signed response (SRES) and the encryption key (Kc) from the HLR / HSS 118.

[0073] In step 8, the OTA server 110 uses the signed response (SRES) and / or the encryption key (Kc) to derive a pre-shared key (PSK), which may be 128 bits in length. Additionally, a challenge (RAND) may be additionally used to derive the pre-shared key (PSK). One example of a method for deriving the pre-shared key (PSK) is to concatenate the encryption key (Kc) with itself and apply a bitwise XOR operation to the result with the challenge (RAND) as follows: PSK=CONCATENATE (Kc, Kc) XOR RAND

[0074] It will be appreciated that this is merely an example to illustrate the concept and alternative methods for deriving a pre-shared key (PSK) may be used.

[0075] The pre-shared key (PSK) can be ephemeral, meaning that it is forgotten after a communication session between the mobile station 102a and the OTA server 110 is conducted with that key.

[0076] Once the OTA server 110 has derived the pre-shared key (PSK), it associates the pre-shared key (PSK) with the agent identifier received in step 5 and stores the associated pre-shared key (PSK) and agent identifier in internal memory of the OTA server 110 (it will be understood that the associated pre-shared key (PSK) and agent identifier may alternatively be stored in memory external to the OTA server 110). This allows the OTA server 110 to know to use that pre-shared key (PSK) to encrypt communications to the agent 204 on the mobile station 102a.

[0077] In step 9, the OTA server 110 transmits a challenge (RAND) over the network 14 to the agent 204 on the mobile station 102a.

[0078] In step 10, the agent 204 provides a random value to the communications module 202 to initiate a SIM authentication procedure, and in response receives an authentication response from the communications module 202 (in step 13), as described in more detail below.

[0079] In step 10, the agent 204 may send an AT command to the communication module 202. In particular, the challenge (RAND) may be used as a seed by the agent 204 to invoke a command (AUTHENTICATE command) on the SIM with this random value as a parameter. One way to invoke the AUTHENTICATE APDU at the SIM level is to use the AT+C SIM command and collect the response APDU from the AT+C SIM response to the AT command (step 13). An alternative way in which step 10 can be accomplished is to use an API provided by the communication module 202, where the agent 204 can send an API call to the communication module 202 to initiate the SIM authentication procedure.

[0080] During the SIM authentication procedure, the communication module 202 presents a challenge (RAND) to the SIM 102b in step 11, for example by executing the Authenticate APDU command received in step 10.

[0081] In step 12, the SIM 102b retrieves the shared key Ki from the non-volatile data store 124, and generates a signed response (SRES) using a first authentication algorithm (e.g., A3 encryption algorithm) with the shared key Ki and the challenge (RAND) as input, and an encryption key (Kc) using a second authentication algorithm (e.g., A8 encryption algorithm) with the shared key Ki and the challenge (RAND) as input. The SIM 102b provides the signed response (SRES) and the encryption key (Kc) to the communication module 202.

[0082] In step 13, the communications module 202 provides the signed response (SRES) and the encryption key (Kc) to the agent 204 in an authentication response.

[0083] In step 14, the agent 204 derives a pre-shared key (PSK) similar to step 8 (implemented by the OTA server).

[0084] Thus, at the end of the process 500, both the agent 204 and the OTA server 110 have derived a TLS encryption key (PSK) that is used to encrypt / decrypt communication packets sent between the agent 204 and the OTA server 110, as described in more detail below with reference to FIG.

[0085] FIG. 6 illustrates a process 600 for a SIM update procedure that is performed after the pre-shared key derivation procedure 500 is completed.

[0086] Prior to step 1, the agent 204 opens a TLS channel with the OTA server 110. The opening of the TLS channel is technically referred to as a "TLS handshake" and is described in RFC 4279. During the TLS handshake, a series of messages are exchanged between the agent 204 and the OTA server 110. These messages are known in the art and will not be described in detail herein. During the TLS handshake procedure, the agent 204 informs the OTA server 110 of the key (Pre-Shared Key (PSK)) that will be used to encrypt / decrypt communication packets sent between the agent 204 and the OTA server 110. Specifically, the agent 204 sends a message (e.g., a "Client Key Exchange" message) to the OTA server 110 that includes the agent identifier as the "PSK Identity". In response, the OTA server 110 queries its associated memory 112 using the agent identifier to retrieve the pre-shared key (PSK) stored in association with the agent identifier.

[0087] The host device 102a may include a TLS / PSK software module. The agent 204 may include the TLS / PSK software module (which is part of the functionality of the agent 204), or alternatively, the TLS / PSK software module may be a separate module from the agent 204 and may include program code stored in the memory 208 that performs certain tasks when executed by the processor 206.

[0088] The agent 204 provides the derived PSK to a TLS / PSK software module that is configured to derive a session key from the PSK that is used by the TLS / PSK software module of the agent 204 to encrypt data sent from the agent 204 to the OTA server 110 and to decrypt data sent from the OTA server 110 to the agent. The TLS / PSK module on the host device 102a is responsible for decrypting the HTTP message and passing it to the agent 204.

[0089] The operation of a TLS / PSK software module is known to those skilled in the art and is documented in RFC 4279 and RFC 2246. In general, the TLS / PSK software module derives a "pre-master secret" from the PSK (this is described in RFC 4279 - section 2). The pre-master secret is encrypted and exchanged in the TLS handshake. The "pre-master secret" is used to derive a "master secret" (this is described in RFC 2246 - section 8.1). The TLS / PSK software module passes the master key and other data from the handshake through a pseudorandom function (PRF) to generate session keys (this is described in RFC 2246 - sections 5 and 6.3).

[0090] The session keys include a "client write encryption key" (used by the TLS / PSK software module of the OTA server 110 to decrypt data) used by the TLS / PSK software module of the agent 204 to encrypt data sent from the agent 204 to the OTA server 110, and a "server write encryption key" (used by the TLS / PSK software module of the agent 204 to decrypt data) used by the TLS / PSK software module of the OTA server 110 to encrypt data sent from the OTA server 110 to the agent 204. It will be appreciated from the above that these session keys are derived from the PSK.

[0091] The OTA server 110 may also include a TLS / PSK software module configured to derive session keys in a manner similar to that of the agent 204 described above.

[0092] In step 1, the agent 204 sends an update request message over a TLS channel to the OTA server 110. The update request message includes the agent identifier (generated by the agent 204 in procedure 500) and may also include a SIM identifier associated with SIM 102b. The update request message is encrypted using a pre-shared key (PSK) derived during procedure 500. That is, the update request message is encrypted by the TLS / PSK software module of the agent 204 using a session key (client write encryption key) derived from the PSK.

[0093] As shown in Figure 6, the update request message may be sent as a first HTTP request including the agent identifier as a parameter (in compliance with the SCP81 protocol), i.e. messages exchanged over the TLS channel may be wrapped in HTTP packets that are themselves encapsulated in TLS protocol packets.

[0094] In response to receiving the update request message, the OTA server 110 decrypts the update request message using a pre-shared key (PSK), i.e., the TLS / PSK software module of the OTA server 110 decrypts the update request message using a session key (client write encryption key) derived from the PSK.

[0095] In step 2, the OTA server 110 sends an update response message over a TLS channel to the agent 204. The update response message is encrypted using a pre-shared key (PSK) before transmission, i.e., the update response message is encrypted by the TLS / PSK software module of the OTA server 110 using a session key (server write encryption key) derived from the PSK.

[0096] The update response message includes update data. The update data may be stored in the memory 112 and may be associated with the SIM 102b, i.e., pre-designated for delivery to the SIM 102b. The update data may include at least one envelope APDU. The at least one envelope APDU may include RFM and / or RAM commands to be executed by the SIM 102b. The at least one envelope APDU is encrypted by the OTA server 110 using a symmetric OTA key, thus forming a secure envelope APDU. The symmetric OTA key is installed in the SIM 102b at the time of manufacture and is also provisioned in the OTA server 110. The symmetric OTA key may correspond to an encryption key identifier (Klc) as specified in the standard ETSI TS 102 225.

[0097] Figure 7 illustrates an update response message 702. As shown in Figure 7, the update response message 702 is encrypted using a session key (server write encryption key) 704 derived from the PSK. The update response message 702 includes update data 706 that is encrypted by the OTA server 110 using a symmetric OTA key 708.

[0098] Returning to process 600 of Figure 6, upon receiving the update response message, the update response message is decrypted using the pre-shared key derived during procedure 500. That is, the TLS / PSK software module of agent 204 decrypts the update response message using a session key (server write encryption key) derived from the PSK.

[0099] In step 3, the agent 204 provides the encrypted update data to the communications module 202. In step 3, the agent 204 may send an AT command to the communications module 202 to provide the encrypted update data to the communications module 202. In particular, an AT+CSIM command may be used. An alternative way in which step 3 may be accomplished is by using an API provided by the communications module 202, where the agent 204 can send an API call to the communications module 202 to provide the communications module 202 with the encrypted update data.

[0100] In step 4, the communications module 204 provides the encrypted update data to SIM 102b.

[0101] In response to receiving the encrypted update data, the SIM 102b decrypts the encrypted update data using the symmetric OTA key 708 and executes the update data to update the SIM 102b in step 5. The update executed on the SIM 102b based on the received update data may include installing new data on the SIM 102b (e.g., installing a new application such as a Javacard applet), updating data previously installed on the SIM 102b, and / or modifying parameter values ​​stored on the SIM 102b.

[0102] In step 6, the execution result of the update data is sent from SIM 102b to communication module 202. In step 7, communication module 202 relays the execution result to agent 204.

[0103] In step 8, the agent 204 sends a further update request message to the OTA server 110 via the network 114, the update request message conveying the result of the execution of the update data. As described above, the update request message is encrypted with a pre-shared key (PSK) before being sent, i.e., the update request message is encrypted with a session key (client write encryption key) derived from the PSK.

[0104] In response to receiving a further update request message from the agent 204 , the OTA server 110 is configured to determine whether there is any update data to be sent to the agent 204 .

[0105] If there is more update data to send to the agent 204, the process 600 returns to step 2 (in the process 600) where a more update response message is sent to the agent 204 over the TLS channel.

[0106] Data gathering (e.g., reading SIM parameters) may be performed in process 600. In particular, the first update response message sent by the OTA server 110 in step 2 may include a read command that is relayed to SIM 102b for execution, and thus the further update request message returned to the OTA server 110 in step 8 may include the data read result (e.g., SIM parameter value). The data read result may be used by the OTA server 110 to determine the update data to be sent in the further update response message sent by the OTA server 110 to the agent 204 when process 600 loops back to step 2.

[0107] If there is no more update data to send to the agent 204, the process 600 proceeds to step 9 where a message indicating that there is no more update data is sent from the OTA server 110 to the agent 204. The message sent in step 9 may be an empty HTTP response (e.g., HTTP response code 200).

[0108] Upon receiving a message indicating that no more updates are available, the communications session may be terminated normally.

[0109] As can be seen from processes 500 and 600 described above, the agent 204 provides support for HTTP OTA mechanisms in legacy SIM-enabled communication modules (and even 2G modules) and provides HTTP OTA without requiring SMS support in the host device 102a.

[0110] The APDUs can potentially be inspected using a SIM communication logging device (tracer) inspecting the mobile station 102a. Therefore, to address this, as described above, the update data APDUs are wrapped in a secure envelope APDU in the same manner as the SMS OTA protocol (SCP80). The SMS OTA key is only known by the OTA server 110 and the SIM 102b, and therefore the RFM / RAM message is protected end-to-end to provide secure transmission of the update data to the SIM 102b. Furthermore, since the endpoint of the HTTPS tunnel is the agent 204 and not the SIM 102b, the APDUs are considered to be provided to the outside for execution and therefore would not execute successfully without a proper authentication system. The fact of being wrapped inside the secure envelope provides this necessary authentication.

[0111] The communication protocol with the OTA server 110 described above with reference to Figures 5 and 6 differs from the SCP81 protocol (described above) in that it delegates the processing of HTTP over TLS to a software agent 204 on the host device 102a and derives the TLS encryption key (PSK) using the SIM 102b as a secure element.

[0112] In the embodiments described herein, the host hardware (e.g., processing and / or memory resources) on the mobile station 102a is typically more resourceful as compared to SIM hardware, which can reduce the time it takes for an OTA update. For example, processing HTTPS messages is computationally intensive, and the hardware available on the host device provides for faster processing of these communications.

[0113] Aspects of the present disclosure will be described with reference to the following bullet points.

[0114] C1. A method for updating a SIM on a host device, the method being performed by an agent on the host device, comprising: deriving a pre-shared key, requesting a SIM identifier of the SIM from a communication module of the host device; receiving the SIM identifier from the communications module and deriving an agent identifier from the SIM identifier; transmitting said agent identifier and said SIM identifier over a network to a network entity; receiving a random value from the network entity over the network; providing said random value to said communication module to initiate a SIM authentication procedure and receiving in response thereto an authentication response from said communication module; deriving the pre-shared key from the authentication response; and sending an update request message over the network to the network entity, the update request message including the agent identifier and encrypted prior to transmission using the pre-shared key; receiving an update response message from the network entity via the network, the update response message including update data and encrypted with the pre-shared key; decrypting the update response message using the derived pre-shared key and sending the update data to the communications module for relay to the SIM for execution to update the SIM. Includes.

[0115] C2. The method of clause C1, wherein the authentication response includes a signed response and a cryptographic key.

[0116] C3. The method of clause C2, wherein deriving the pre-shared key from the authentication response includes deriving the pre-shared key using at least one of the signed response and the cryptographic key.

[0117] C4. The method of clause C3, wherein deriving the pre-shared key from the authentication response includes deriving the pre-shared key using the random value.

[0118] C5. The method of clause C4, wherein deriving the pre-shared key from the authentication response includes concatenating the encryption key with itself to generate a concatenation result, and applying a bitwise XOR operation to the concatenation result and the random value to derive the pre-shared key.

[0119] C6. The method of any preceding claim, wherein the update data is encrypted with a symmetric encryption key stored by the SIM.

[0120] C7 The method of any preceding claim, wherein the update request message includes the SIM identifier.

[0121] C8. The method of any preceding claim, further comprising, in response to transmitting the update data to the communications module: receiving an execution result from the SIM via the communication module; sending a further update request message to the network entity via the network, the update request message conveying the result of the execution and being encrypted prior to transmission using the pre-shared key; Further includes:

[0122] C9 A method according to any preceding claim, wherein the AT command: requesting a SIM identifier of the SIM from a communication module of the host device; providing said random value to said communication module to initiate a SIM authentication procedure; and transmitting the update data to the communication module; The present invention is used in at least one of the above.

[0123] C10 The method of any preceding claim, wherein the application programming interface provided by the communications module comprises: requesting a SIM identifier of the SIM from a communication module of the host device; providing said random value to said communication module to initiate a SIM authentication procedure; and transmitting the update data to the communication module; The present invention is used in at least one of the above.

[0124] C11 The method of any preceding claim, wherein deriving the agent identifier from the SIM identifier comprises adding a prefix to the SIM identifier.

[0125] C12 The method of any preceding clause, wherein the derivation of the pre-shared key is triggered based on one of: (i) detecting a user input on the host device; (ii) receiving a session initiation message from the network entity over the network; and (iii) detecting the expiration of a predetermined time interval.

[0126] C13 The method of any preceding claim, wherein the SIM identifier is one of: (i) an IMSI associated with the SIM; (ii) an ICCID associated with the SIM; and (iii) an MSISDN associated with the SIM.

[0127] C14 A method for updating a SIM on a host device, the method being performed by a network entity, comprising: deriving a pre-shared key, receiving from a host device an agent identifier and a SIM identifier of the SIM transmitted from the host device over a network; generating a random value; providing the random value and the identifier of the SIM to an authentication entity and receiving in response an authentication response from the authentication entity; deriving the pre-shared key from the authentication response; and storing in memory the pre-shared key in association with the agent identifier; receiving an update request message from the host device over the network, the update request message including the agent identifier and encrypted prior to transmission using the pre-shared key; sending an update response message to the host device over the network, the update response message including update data and encrypted with the pre-shared key; Includes.

[0128] C15 A computer program product for updating a SIM on a host device, comprising code embodied on a non-transitory computer readable medium, the code being configured to perform the method of any preceding claim when executed on a processor.

[0129] It is understood that the above embodiments are described by way of example only and that other variations or applications will be apparent to one of ordinary skill in the art given the disclosure herein.

Claims

1. 1. A device-implemented method, comprising: receiving a value over a network from a server; sending said value to a SIM on said device; receiving a first message from the SIM, the first message being generated using the value; deriving a pre-shared key using the first message; receiving a second message from the server over the network, the second message including update data and encrypted with the pre-shared key; decrypting the second message using the pre-shared key and providing the update data to the SIM; Includes.

2. 2. The method of claim 1 , transmitting said value to said SIM initiates a SIM authentication procedure; The first message is an authentication response received from the SIM in response to the SIM authentication procedure.

3. 3. The method according to claim 1 or 2, the first message includes a signed response and a cryptographic key; Deriving the pre-shared key includes deriving the pre-derived key using at least one of the signed response and the cryptographic key.

4. On your device, receiving a value over a network from a server; sending the value to a SIM on the device and receiving from the SIM a first message generated using the value; deriving a pre-shared key using the first message; receiving a second message from the server over the network, the second message including update data and encrypted with the pre-shared key; decrypting the second message using the pre-shared key and providing the update data to the SIM; A program for executing a method comprising the steps of:

5. A device, comprising: Receives values ​​from the server over the network, Sending the value to a SIM on the device and receiving a first message from the SIM generated using the value; Deriving a pre-shared key using the first message; receiving a second message from the server over the network, the second message including update data and encrypted with the pre-shared key; The pre-shared key is used to decrypt the second message and provide the update data to the SIM.

Citation Information

Patent Citations

  • Securing host card emulation credentials

    US20160104154A1

  • UICCs EMBEDDED IN TERMINALS OR REMOVABLE THEREFROM

    US20160379006A1

  • Profile download method and apparatus for use in wireless communication system

    US20170064552A1