CN107239469B - Routing information query method and device - Google Patents

Routing information query method and device Download PDF

Info

Publication number
CN107239469B
CN107239469B CN201610188218.3A CN201610188218A CN107239469B CN 107239469 B CN107239469 B CN 107239469B CN 201610188218 A CN201610188218 A CN 201610188218A CN 107239469 B CN107239469 B CN 107239469B
Authority
CN
China
Prior art keywords
aid
routing table
routing
routing information
global
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201610188218.3A
Other languages
Chinese (zh)
Other versions
CN107239469A (en
Inventor
陈剑锋
张庆立
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
ZTE Corp
Original Assignee
ZTE Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by ZTE Corp filed Critical ZTE Corp
Priority to CN201610188218.3A priority Critical patent/CN107239469B/en
Priority to PCT/CN2016/088377 priority patent/WO2017166470A1/en
Publication of CN107239469A publication Critical patent/CN107239469A/en
Application granted granted Critical
Publication of CN107239469B publication Critical patent/CN107239469B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/23Updating

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention provides a method and a device for inquiring routing information. Wherein, the method comprises the following steps: updating a part of local AID routing tables in a Near Field Communication Controller (NFCC) according to an AID routing table of a global in-card application identifier in a terminal where the NFCC is located to obtain an updated local AID routing table, wherein the updated local AID routing table comprises updated AID and routing information which have corresponding relations; receiving a route query request, wherein the route query request at least carries a first AID; and inquiring first routing information corresponding to the first AID in the updated local AID routing table. The invention solves the problem that the required routing information can not be inquired due to the fact that the AID routing table of the NFCC is easy to be full, and realizes that the required routing information can be inquired in time in the application interaction process.

Description

Routing information query method and device
Technical Field
The present invention relates to the field of communications, and in particular, to a method and an apparatus for querying routing information.
Background
In an application scenario of Near Field Communication (NFC), a mobile phone is used as a card simulation to interact with a card reader. In the ISO14443 protocol specification, a Card reader is generally called a Proximity Coupling Device (PCD) and a mobile phone is called a Proximity Integrated Circuit Card (PICC). For example, in a card-swiping transaction of a bank card, the POS machine is a PCD, and the bank card is called a PICC, and correspondingly, if the mobile phone is simulated as a bank card, the mobile phone is the PICC.
The PCD establishes an interactive process by selecting an application in the PICC through an application identification (SELECT AID) command in a selection card defined by the ISO7816 specification in the interactive process with the PICC. In an application scenario in which a mobile phone is used as a Card simulation, an application in the Card may exist in various application environments such as a Universal Integrated Circuit Card (UICC), a Search Engine based E-commerce (E-commerce based on Search Engine, eSE) or a Host-based Card simulation (HCE). When the PCD initiates application interaction, an NFC Controller (NFC Controller, NFCC for short) at a mobile phone end first receives SELECT AID command, the NFCC searches for an application environment corresponding to an AID by querying an AID routing table, forwards the command to an application in a corresponding application environment after finding the corresponding application environment (for example, UICC), and sends a response message to the corresponding application, so that an interaction process is established. The most main index of an AID routing table item queried by the NFCC is the AID, the AID is an in-card application identifier, and the length (5-16 bytes) and the format of the AID are specified in the ISO7816 specification.
However, in the current technology for querying an AID route by an NFCC, due to the limitation of the size of the nonvolatile memory of the NFCC and the increase of applications, an AID route table may be filled, so that a new application cannot register a new AID route entry, and thus the application cannot be used.
The current technical specification does not provide the implementation specification for how to solve the full AID route condition in the NFCC. In the current implementation, when the NFCC routing table entry is full, the AID cannot be continuously added, in this case, the command can be routed to the default Application environment only through the set default route, and the default Application environment may be configured before shipment or may be configured through an Application Programming Interface (API) during running.
Therefore, since the non-volatile memory space (NVRAM) of the NFCC is usually small, and the number of NFC applications is increasing rapidly, when NFCC NVRAM can store routing information reaching its maximum allowable capacity, the AID of the newly added application cannot continue to add routing information, so that the application can only be routed to the default application environment during application interaction, and if the corresponding default application environment does not have the application, the interaction will fail, and the related functions cannot be used.
Aiming at the problem that the AID routing table of NFCC in the related technology is easy to be full, so that the required routing information cannot be inquired, an effective solution is not provided at present.
Disclosure of Invention
The invention provides a method and a device for inquiring routing information, which are used for at least solving the problem that the required routing information cannot be inquired due to the fact that an AID routing table of an NFCC is full easily in the related technology.
According to an aspect of the present invention, there is provided a routing information query method, including: updating a partial local AID routing table in an NFCC according to a global AID routing table in a terminal where the NFCC is located to obtain an updated local AID routing table, wherein the updated local AID routing table comprises updated AIDs and routing information which have corresponding relations; receiving a route query request, wherein the route query request at least carries a first AID; and inquiring first routing information corresponding to the first AID in the updated local AID routing table.
Optionally, the local AID routing table includes: a first AID routing table and a second AID routing table, wherein the second AID routing table is set as the partial local AID routing table updated according to the global AID routing table, the first AID routing table is set as the local AID routing table of the remaining part not updated in the local AID routing table, and updating the local AID routing table in the NFCC according to the global AID routing table in the terminal where the NFCC is located includes: updating at least part of AIDs and routing information in the global AID routing table with corresponding relations into the second AID routing table.
Optionally, the updating, to the second AID routing table, at least part of AIDs and routing information in the global AID routing table, which have a correspondence relationship, includes: and updating AIDs and routing information which correspond to at least part of the usage scenes and have a corresponding relationship in the global AID routing table to the second AID routing table according to the usage scenes of the local AID routing table.
Optionally, the updating the local AID routing table in the NFCC according to the global AID routing table in the terminal where the NFCC is located includes: acquiring a second AID of an application to be installed and second routing information corresponding to the second AID; updating the global AID routing table according to the second AID and the second routing information which have a corresponding relationship; updating the corresponding relation between the second AID and the second routing information updated in the global AID routing table to the second AID routing table.
Optionally, the updating, in the second AID routing table, the updated correspondence between the second AID and the second routing information in the global AID routing table includes: judging whether the second AID routing table is full; and under the condition that the second AID routing table is not full, updating the corresponding relation between the updated second AID and the second routing information into the second AID routing table.
Optionally, after querying the updated local AID routing table for the first routing information corresponding to the first AID, the method further includes: if the first routing information corresponding to the first AID is not queried in the updated local AID routing table, querying the global AID routing table for the first routing information corresponding to the first AID.
Optionally, after querying the global AID routing table for the first routing information corresponding to the first AID, the method further includes: if the first routing information corresponding to the first AID is inquired in the global AID routing table, updating the inquired first AID and the first routing information with the corresponding relation to the local AID routing table.
Optionally, after querying the global AID routing table for the first routing information corresponding to the first AID, the method further includes: if the first routing information corresponding to the first AID is not inquired in the global AID routing table, acquiring preset routing information.
Optionally, querying the first routing information corresponding to the first AID in the updated local AID routing table includes: querying a first AID routing table of the updated local AID routing tables for the first routing information corresponding to the first AID; if the first routing information corresponding to the first AID is not queried in the second AID routing table, querying the first routing information corresponding to the first AID in the second AID routing table of the updated local AID routing table.
According to another aspect of the present invention, there is also provided a routing information query apparatus, including: an updating module, configured to update a local AID routing table in an NFCC according to a global AID routing table in a terminal where the NFCC is located, to obtain an updated local AID routing table, where the updated local AID routing table includes updated AIDs and routing information that have a corresponding relationship; a receiving module, configured to receive a route query request, where the route query request carries at least a first AID; a first query module, configured to query, in the updated local AID routing table, first routing information corresponding to the first AID.
According to the method and the device, a part of local AID routing tables in the near field communication controller NFCC are updated according to the global in-card application identifier AID routing table in the terminal where the NFCC is located to obtain the updated local AID routing tables, wherein the updated local AID routing tables comprise the updated AID and routing information which have corresponding relations; receiving a route query request, wherein the route query request at least carries a first AID; the method includes the steps of inquiring first routing information corresponding to a first AID in an updated local AID routing table, updating the local AID routing table in the NFCC according to a global AID routing table in a terminal, enabling the local AID routing table to store needed routing information, and inquiring the first routing information corresponding to the first AID in the local AID routing table according to the first AID carried in a received routing inquiry request.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the invention and together with the description serve to explain the invention without limiting the invention. In the drawings:
fig. 1 is a flowchart of a routing information query method according to an embodiment of the present invention;
fig. 2 is a block diagram of an AID routing table according to an embodiment of the present invention;
fig. 3 is a flow diagram of AID routing table updating in accordance with an alternative embodiment of the present invention;
FIG. 4 is a flow diagram of a method of routing information query according to an alternative embodiment of the present invention;
fig. 5 is a flow diagram of AID route initialization according to an alternative embodiment of the invention;
fig. 6 is a block diagram of the configuration of a routing information querying device according to an embodiment of the present invention;
fig. 7 is a block diagram one of an alternative structure of a routing information query device according to an embodiment of the present invention;
FIG. 8 is a block diagram of an alternative configuration of a routing information query device according to an embodiment of the present invention;
fig. 9 is a block diagram of an alternative configuration of a routing information query device according to an embodiment of the present invention;
fig. 10 is a block diagram of an alternative configuration of a routing information query device according to an embodiment of the present invention.
Detailed Description
The invention will be described in detail hereinafter with reference to the accompanying drawings in conjunction with embodiments. It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order.
Example 1
In this embodiment, a method for querying routing information is provided, and fig. 1 is a flowchart of a method for querying routing information according to an embodiment of the present invention, as shown in fig. 1, the flowchart includes the following steps:
step S102, updating a partial local AID routing table in the NFCC according to a global AID routing table in a terminal where the NFCC is located to obtain an updated local AID routing table, wherein the updated local AID routing table comprises updated AIDs and routing information which have corresponding relations;
step S104, receiving a route query request, wherein the route query request at least carries a first AID;
step S106, first routing information corresponding to the first AID is inquired in the updated local AID routing table.
Optionally, in this embodiment, an application scenario of the routing information query method includes, but is not limited to, applying to a process of interacting between a PICC and a card reader (PCD) in an NFC technology, where the scenario of interacting between the PICC and the PCD may include, but is not limited to, a process of interacting with the card reader as a card simulation by a terminal (e.g., a mobile phone).
In the application scenario, a part of local AID routing tables in the NFCC are updated according to a global AID routing table in the terminal, so that required routing information is stored in the local AID routing tables, and therefore, after a routing query request at least carrying a first AID is received, first routing information corresponding to the first AID can be queried in the local AID routing tables according to the received first AID. The local AID routing table is dynamically updatable, so that routing information meeting conditions can be stored in the local AID routing table at any time according to different application conditions, and thus, when the local AID routing table is filled, the routing information in the global AID routing table can be updated to the local AID routing table according to needs. Therefore, by adopting the steps, the problem that the required routing information cannot be inquired due to the fact that the AID routing table of the NFCC is easily insufficient in full storage space is solved, and therefore the stored routing information is updated in real time in the AID routing table of the NFCC, the required routing information can be inquired in time in the application interaction process, and normal interaction of the application is further guaranteed.
In this embodiment, the update of the local AID routing table may be real-time, or may be timed, or may be random, or may be triggered by the received information. For example: if the update of the local AID routing table is triggered by the received routing query request, at least part of routing information corresponding to the scene in the global AID routing table can be updated to the local AID routing table according to the application scene of the first AID carried in the routing query request after the routing query request is received, so that the success rate of querying the first routing information corresponding to the first AID is improved, the problem that the required routing information cannot be queried due to the fact that the AID routing table of the NFCC is full easily is solved, and the required routing information can be queried in time in the application interaction process.
Optionally, in this embodiment, after receiving the route query request, the required route information may be first searched in the local AID routing table, and if the required route information is not found, at least a part of the route information corresponding to the first AID carried in the route query request is updated to the local AID routing table according to the application scenario of the first AID in the route query request, and then is queried in the updated local AID routing table.
In this embodiment, the local AID routing table in the NFCC may be divided into two parts, one part is used to store fixed AIDs and routing information having a corresponding relationship, and the other part may be updated according to the global AID routing table in the terminal. Optionally, in this embodiment, the AID and the routing information, which are part of frequent applications and have a corresponding relationship, may be, but are not limited to, fixedly stored in the local AID routing table. Therefore, the AID to be inquired can be quickly acquired from the routing table entries fixedly stored in the local AID routing table, and the aim of improving the inquiry efficiency is fulfilled. For example, AIDs whose number of uses exceeds a predetermined threshold value and routing information having a correspondence relationship therewith are fixedly stored in the local AID routing table.
Optionally, in this embodiment, but not limited to, a part of the routing table entry may be updated in the global AID routing table to the local AID routing table as needed. That is, the partial routing table entries in the local AID routing table may be dynamically updated in real time according to the routing table entries in the global AID routing table. Therefore, the problem that a local AID routing table is easily filled in the related technology, so that a new routing table entry cannot be acquired is solved, and the required routing information is stored in the AID routing table of the NFCC, and meanwhile, the query efficiency of the routing information is improved.
Optionally, the local AID routing table may include: a first AID routing table and a second AID routing table, wherein the second AID routing table is set as the partial local AID routing table updated according to the global AID routing table, and the first AID routing table is set as the local AID routing table of the rest of the local AID routing tables that are not updated in the local AID routing table, then in the above step S102, AIDs and routing information in which at least part of the global AID routing table has a correspondence relationship may be updated into the second AID routing table.
In addition, in this embodiment, the AIDs and the routing information having a correspondence relationship, which are at least partially corresponding to the usage scenario, in the global AID routing table may be updated into the second AID routing table according to the usage scenario of the local AID routing table. In this embodiment, the method for using the scene update may include at least one of the following: and updating the AID routing table entry under one use scene in the global AID routing table into a second AID routing table, and updating the AID routing table entries under a plurality of use scenes in the global AID routing table into the second AID routing table. The usage scenario of the local AID routing table may include, but is not limited to: UICC, eSE, HCE, etc.
In the following examples and optional embodiments, the terminal takes the host as an example, the first AID routing table takes a static AID routing table as an example, the second AID routing table takes a dynamic AID routing table as an example, and the preset routing information takes a default route as an example.
The present embodiment will be described below with reference to specific examples.
The query method of the NFCC routing information in this example can solve the problem that the NFCC fails to interact with the application due to the fact that the NVRAM space is small and the number of NFC applications is increasing, and the routing information is stored without space.
In this example, the local AID routing table stored in the AID routing storage area of the NFCC is divided into two blocks, where one block stores a fixed part of routing information, referred to as a static AID routing table, whose function is the same as that of the original NFCCAID routing table, and the other part is referred to as a dynamic AID routing table, where the part of stored routing information is from a part of global routing information stored by a host to which the NFCC belongs, and the part of routing information is dynamic and can be continuously updated according to a change in a usage scenario. Since the storage space of the host is very large, almost any number of AID routing entries can be stored. In addition, in this example, by combining the global AID routing table and the dynamic AID routing table, both the AID routing query efficiency and the problem of failure in AID routing query can be solved.
Fig. 2 is a block diagram of an AID routing table according to an embodiment of the present invention, and as shown in fig. 2, the AID routing table in the NFCC is divided into a static AID routing table and a dynamic AID routing table, and a global AID routing table for storing routing information of all applications is established in the host. Routing information of AID is stored in a global AID routing table of a Host (Host) and a static AID routing table and a dynamic AID routing table of the NFCC, and the dynamic AID routing table caches partial table entries of the global AID routing table.
When a new application is installed, the acquired AID of the new application and the routing information corresponding to the AID of the new application may be added to the global AID routing table, and then the AID of the new application and the routing information corresponding to the AID of the new application are updated to the second AID routing table according to the updated global AID routing table. Through the steps, the global AID routing table can store all applied AIDs and routing information thereof due to the fact that the storage space in the terminal is large, and then the second AID routing table is updated through the table entries in the global AID routing table according to needs, so that the problem that the required routing information cannot be inquired due to the fact that the AID routing table of the NFCC is full easily is solved, and the required routing information can be inquired in time in the application interaction process.
Optionally, in the step S102, a second AID of the application to be installed and second routing information corresponding to the second AID may be acquired, the global AID routing table is updated according to the second AID and the second routing information having a corresponding relationship, and the second AID and the second routing information updated in the global AID routing table are updated into the second AID routing table.
When the updated correspondence between the second AID and the second routing information in the global AID routing table is updated to the second AID routing table, it may be determined whether the second AID routing table is full, and when the second AID routing table is not full, the updated correspondence between the second AID and the second routing information is updated to the second AID routing table.
Fig. 3 is a flowchart of updating an AID routing table according to an alternative embodiment of the present invention, as shown in fig. 3, in an alternative embodiment, an installed new application may be equivalent to the above application to be installed, and the process of updating the AID routing table when installing the new application may include the following steps:
in step S302, when a new NFC application is installed, the global AID routing table is updated first.
Step S304, judging that the dynamic AID routing table is not full.
Step S306, insert the second routing information related to the second AID corresponding to the new application into the dynamic AID routing table.
In this embodiment, if the required routing information is not queried in the local AID routing table, the query may be continued in the global AID routing table in the terminal. Through the steps, all the applied AIDs and the routing information with the corresponding relation are stored in the global AID routing table, so that the success rate of routing information query is improved.
Optionally, all the applied AIDs and routing information having a correspondence relationship may be stored in a global AID routing table established in the terminal where the NFCC is located, and after step S106, if the routing information indicated by the route query request is not queried in the local AID routing table, the global AID routing table may be queried for the first routing information corresponding to the required first AID. If first routing information corresponding to the first AID is inquired in the global AID routing table, updating the inquired first AID with the corresponding relation and the first routing information into a local AID routing table; and if the first routing information corresponding to the first AID is not inquired in the global AID routing table, acquiring the preset routing information.
Through the steps, if the required routing information is inquired in the global AID routing table, the inquired routing information is updated to the local AID routing table, and the routing information can be directly found in the local AID routing table when being inquired next time, so that the inquiry efficiency of the routing information is improved without searching the global AID routing table; if the required routing information is not inquired in the global AID routing table, providing default routing information for the AID, so that the interactive operation can be continued, and the success rate of application interaction is improved.
The condition that the first routing information corresponding to the first AID is not queried in the global AID routing table may mean that the first routing information corresponding to the first AID is not received in the global AID routing table, or that the first routing information corresponding to the first AID returned from the global AID routing table is not received in a predetermined time.
Optionally, in the step S102, first routing information corresponding to the first AID may be firstly searched in a first AID routing table of the updated local AID routing table, and if the first routing information corresponding to the first AID is not searched in the second AID routing table, the first routing information corresponding to the first AID may be further searched in a second AID routing table of the updated local AID routing table. Through the steps, the query sequence for querying the routing information in the local AID routing table is set, and because AIDs and routing information of common applications are fixedly stored in the first AID routing table, the query in the first AID routing table is easy and successful, and the query success rate of the routing information is improved.
In addition, in an optional embodiment, when application interaction occurs between the PCD and the PICC, the NFCC first queries the static AID routing table, and if routing information corresponding to the AID is queried by the static AID routing table, the query is ended, and the application interaction flow is continued. And if the routing information corresponding to the AID is not inquired, inquiring a dynamic AID routing table, and if the routing information corresponding to the AID is inquired by the dynamic AID routing table, finishing the inquiry and continuing to apply the interactive flow. And if the routing information corresponding to the AID is not inquired by the dynamic AID routing table, the NFCC inquires a global AID routing table from the Host end, and if the routing information table entry corresponding to the AID exists in the global AID routing table, the corresponding table entry is updated to the dynamic AID routing table, the inquiry result is returned, and the interactive process is continuously applied. And if the global AID routing table does not inquire the routing information, the NFCC continues to apply the interactive flow according to the configured default AID routing.
When an interaction process between the PCD and the PICC occurs, the NFCC queries a corresponding AID route according to the applied AID. Fig. 4 is a flowchart of a routing information query method according to an alternative embodiment of the present invention, as shown in fig. 4, the flowchart includes the following steps:
step S402, the NFCC receives a routing query request (e.g. Select AID message);
step S404, the NFCC inquires a static AID routing table;
step S406, if the first routing information related to the first AID is queried, performing step S420;
step S408, if the query fails, continuing to query the dynamic AID routing table;
step S410, if the first routing information related to the first AID is queried, perform step S420;
step S412, if the query fails, notifying the Host to continue AID query;
step S414, the Host inquires a global AID routing table and judges whether the needed AID routing information exists;
step S416, if the first routing information related to the first AID is queried, updating the dynamic AID routing table, and continuing to execute step S420;
step S418, if the query fails, the NFCC executes a policy corresponding to the default route, and continues the relevant processing;
and step S420, finishing the query, and continuing the interactive processing according to the query result.
In another alternative embodiment, a method of application interaction is provided, which may include the steps of:
step one, initializing a global AID routing table and a static AID routing table of an NFCC in the starting process of a system.
And step two, when the system installs a new NFC application, updating the AID and the related information of the new application to a global AID routing table.
Step three, when the application interaction occurs, firstly inquiring the static AID routing table, when the inquiry fails, inquiring the dynamic AID routing table, if the inquiry fails, informing the host computer to continuously inquire the global AID routing table
And step four, if the query is successful, selecting a corresponding application environment according to the relevant information of the routing table, and carrying out subsequent interactive processing. And if the query fails, selecting the relevant application environment and performing subsequent interactive processing according to the default route.
In another optional embodiment, during the system startup, the global AID routing table, the static AID routing table, and the dynamic AID routing table may be initialized. Fig. 5 is a flowchart of AID route initialization according to an alternative embodiment of the present invention, as shown in fig. 5, the flowchart includes the following steps:
step S502, starting the system;
step S504, initializing a global AID routing table according to the application condition of system installation;
step S506, initializing the static AID routing table and the dynamic AID routing table.
And when the space of the static AID routing table is full, partial routing information in the global AID routing table is stored in the dynamic AID routing table.
It should be noted that, the updating of the AID routing table in the embodiment of the present invention may include, but is not limited to, at least one of the following forms:
the first form: adding a routing table entry to be updated into an AID routing table;
the second form: after the original routing table is emptied, adding a routing table item to be updated into the AID routing table;
the third form: deleting part of routing table entries in the original routing table according to a preset rule, and adding the routing table entries to be updated into the AID routing table.
Through the above description of the embodiments, those skilled in the art can clearly understand that the method according to the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but the former is a better implementation mode in many cases. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which is stored in a storage medium (such as ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal device (such as a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.
Example 2
In this embodiment, a routing information query device is further provided, and the device is used to implement the foregoing embodiments and preferred embodiments, and the description of the device that has been already made is omitted. As used below, the term "module" may be a combination of software and/or hardware that implements a predetermined function. Although the means described in the embodiments below are preferably implemented in software, an implementation in hardware, or a combination of software and hardware is also possible and contemplated.
Fig. 6 is a block diagram of a routing information query apparatus according to an embodiment of the present invention, as shown in fig. 6, the apparatus including:
1) a first updating module 62, configured to update a partial local AID routing table in the NFCC according to a global AID routing table in a terminal where the NFCC is located, to obtain an updated local AID routing table, where the updated local AID routing table includes updated AIDs and routing information that have a corresponding relationship;
2) a receiving module 64, coupled to the first updating module 62, configured to receive a route query request, where the route query request carries at least a first AID;
3) a first querying module 66, coupled to the receiving module 64, configured to query the updated local AID routing table for first routing information corresponding to the first AID.
Optionally, in this embodiment, an application scenario of the routing information query apparatus includes, but is not limited to, applying to a process of interacting between a PICC and a card reader (PCD) in an NFC technology, where the process of interacting between the PICC and the PCD may include, but is not limited to, a process of interacting with the card reader as a card simulation by a terminal (e.g., a mobile phone).
In the above application scenario, the first updating module 62 updates a part of the local AID routing table in the NFCC according to the global AID routing table in the terminal, so that the local AID routing table stores the required routing information, and thus after the receiving module 64 receives the routing query request at least carrying the first AID, the first querying module 66 may query the local AID routing table for the first routing information corresponding to the first AID according to the received first AID. The local AID routing table is dynamically updatable, so that routing information meeting conditions can be stored in the local AID routing table at any time according to different application conditions, and thus, when the local AID routing table is filled, the routing information in the global AID routing table can be updated to the local AID routing table according to needs. Therefore, by adopting the device, the problem that the required routing information cannot be inquired due to the fact that the AID routing table of the NFCC is easily insufficient in full storage space is solved, and therefore the stored routing information is updated in real time in the AID routing table of the NFCC, the required routing information can be inquired in time in the application interaction process, and normal interaction of applications is further guaranteed.
In this embodiment, the updating of the local AID routing table by the first updating module 62 may be real-time, may also be timed, or may be random, or may also be triggered by the received information. For example: if the update of the local AID routing table by the first update module 62 is triggered by the received routing query request, then, after the receiving module 64 receives the routing query request, the first update module 62 updates, according to the application scenario of the first AID carried in the routing query request, the routing information corresponding to the scenario in the global AID routing table to the local AID routing table, so that the success rate of querying the first routing information corresponding to the first AID is improved, the problem that the required routing information cannot be queried due to the easy fullness of the AID routing table of the NFCC is solved, and the required routing information can be queried in time in the application interaction process.
Optionally, in this embodiment, after the receiving module 64 receives the routing query request, the first querying module 66 may first search for the required routing information in the local AID routing table, if the required routing information is not found, the first updating module 62 updates at least part of the routing information corresponding to the scene in the global AID routing table to the local AID routing table according to the application scene of the first AID carried in the routing query request, and the first querying module 66 queries the local AID routing table updated this time.
In this embodiment, the local AID routing table in the NFCC may be divided into two parts, one part is used to store fixed AIDs and routing information having a corresponding relationship, and the other part may be updated according to the global AID routing table in the terminal. Optionally, in this embodiment, the AID and the routing information, which are part of frequent applications and have a corresponding relationship, may be, but are not limited to, fixedly stored in the local AID routing table. Therefore, the AID to be inquired can be quickly acquired from the routing table entries fixedly stored in the local AID routing table, and the aim of improving the inquiry efficiency is fulfilled. For example, AIDs whose number of uses exceeds a predetermined threshold value and routing information having a correspondence relationship therewith are fixedly stored in the local AID routing table.
Optionally, in this embodiment, but not limited to, a part of the routing table entry may be updated in the global AID routing table to the local AID routing table as needed. That is, the partial routing table entries in the local AID routing table may be dynamically updated in real time according to the routing table entries in the global AID routing table. Therefore, the problem that a local AID routing table is easily filled in the related technology to cause that a new routing table item cannot be acquired is solved, and the required routing information is stored in the AID routing table of the NFCC, and meanwhile, the query efficiency of the routing information is improved
Optionally, the local AID routing table includes: a first AID routing table and a second AID routing table, wherein the second AID routing table is set as the partial local AID routing table updated according to a global AID routing table, the first AID routing table is set as the local AID routing table of the remaining part not updated in the local AID routing table, and the first updating module 62 is configured to: and updating at least part of AIDs and routing information which have the corresponding relation in the global AID routing table into a second AID routing table.
In addition, in this embodiment, the first updating module 62 may further update the AID and the routing information, which have a corresponding relationship and correspond to at least part of the usage scenario, in the global AID routing table into the second AID routing table according to the usage scenario of the local AID routing table. In this embodiment, the method for using the scene update may include at least one of the following: and updating the AID routing table entry under one use scene in the global AID routing table into a second AID routing table, and updating the AID routing table entries under a plurality of use scenes in the global AID routing table into the second AID routing table. The usage scenario of the local AID routing table may include, but is not limited to: UICC, eSE, HCE, etc.
Fig. 7 is a block diagram of an alternative structure of the routing information query device according to the embodiment of the present invention, as shown in fig. 7, optionally, the first updating module 62 includes:
1) the acquiring unit 72 acquires a second AID of the application to be installed and second routing information corresponding to the second AID;
2) a first updating unit 74, coupled to the obtaining unit 72, for updating the global AID routing table according to the second AID and the second routing information having the corresponding relationship;
3) and a second updating unit 76, coupled to the first updating unit 74, for updating the corresponding relationship between the second AID updated in the global AID routing table and the second routing information into the second AID routing table.
When a new application is installed, the first updating unit 74 may add the AID of the new application and the routing information corresponding to the AID of the new application acquired by the acquiring unit 72 to the global AID routing table, and the second updating unit 76 updates the AID of the new application and the routing information corresponding to the AID of the new application to the second AID routing table according to the updated global AID routing table. By the AID of the device, the global AID routing table can store all applied AIDs and routing information of all the applied AIDs due to the fact that the storage space in the terminal is large, and the second AID routing table is updated by using the entries in the global AID routing table as required, so that the problem that the required routing information cannot be inquired due to the fact that the AID routing table of the NFCC is full easily is solved, and the required routing information can be inquired in time in the application interaction process.
Optionally, the second updating unit 76 is configured to: judging whether the second AID routing table is full; and under the condition that the second AID routing table is not full, updating the corresponding relation between the updated second AID and the second routing information into the second AID routing table.
Fig. 8 is a block diagram of an optional structure of a routing information query apparatus according to an embodiment of the present invention, as shown in fig. 8, optionally, the apparatus further includes:
a second querying module 82, coupled to the first querying module 66, configured to query the global AID routing table for the first routing information corresponding to the first AID if the updated local AID routing table does not query the first routing information corresponding to the first AID.
Fig. 9 is a block diagram of an optional structure of a routing information query apparatus according to an embodiment of the present invention, as shown in fig. 9, optionally, the apparatus further includes:
a second updating module 92, coupled to the second querying module 82, configured to update the queried first AID and the first routing information, which have a corresponding relationship, into the local AID routing table if the first routing information corresponding to the first AID is queried in the global AID routing table.
Fig. 10 is a block diagram of an optional structure of a routing information query apparatus according to an embodiment of the present invention, as shown in fig. 10, optionally, the apparatus further includes:
the obtaining module 102 is coupled to the second querying module 82, and if the first routing information corresponding to the first AID is not queried in the global AID routing table, obtains the preset routing information.
Through the above steps, if the second querying module 82 queries the required routing information in the global AID routing table, the second updating module 92 updates the queried routing information to the local AID routing table, and the next time the routing information is queried, the routing information can be directly found in the local AID routing table, and the global AID routing table does not need to be searched, so that the query efficiency of the routing information is improved; if the second querying module 82 does not query the required routing information in the global AID routing table, the obtaining module 102 provides a default routing information for the AID, so that the interactive operation can be continued, and the success rate of the application interaction is improved.
The second querying module 82 may query that the global AID routing table does not query the first routing information corresponding to the first AID, that the global AID routing table does not have the first routing information corresponding to the first AID, that the first routing information corresponding to the first AID returned from the global AID routing table is not received, or that the first routing information corresponding to the first AID returned from the global AID routing table is not received within a predetermined time.
Optionally, the first query module 66 is configured to: inquiring first routing information corresponding to a first AID in a first AID routing table of the updated local AID routing table; and if the first routing information corresponding to the first AID is not inquired in the second AID routing table, inquiring the first routing information corresponding to the first AID in the second AID routing table of the updated local AID routing table.
Through the above steps, the first query module 66 is configured with a query sequence for querying the routing information in the local AID routing table, and since the first AID routing table fixedly stores AIDs and routing information thereof that are commonly used, the query in the first AID routing table is easier and successful, thereby also improving the success rate of querying the routing information.
It should be noted that, the updating of the AID routing table in the embodiment of the present invention may include, but is not limited to, at least one of the following forms:
the first form: adding a routing table entry to be updated into an AID routing table;
the second form: after the original routing table is emptied, adding a routing table item to be updated into the AID routing table;
the third form: deleting part of routing table entries in the original routing table according to a preset rule, and adding the routing table entries to be updated into the AID routing table.
It should be noted that, the above modules may be implemented by software or hardware, and for the latter, the following may be implemented, but not limited to: the modules are all positioned in the same processor; alternatively, the modules are respectively located in a plurality of processors.
Example 3
The embodiment of the invention also provides a storage medium. In the present embodiment, the storage medium described above may be configured to store program code for performing the steps of:
step S1, updating a partial local AID routing table in the NFCC according to a global AID routing table in a terminal where the NFCC is located, to obtain an updated local AID routing table, where the updated local AID routing table includes updated AIDs and routing information that have a corresponding relationship;
step S2, receiving a route query request, wherein the route query request at least carries a first AID;
step S3, the updated local AID routing table is queried for first routing information corresponding to the first AID.
Optionally, in this embodiment, the storage medium may include, but is not limited to: various media capable of storing program codes, such as a usb disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic disk, or an optical disk.
It will be apparent to those skilled in the art that the modules or steps of the present invention described above may be implemented by a general purpose computing device, they may be centralized on a single computing device or distributed across a network of multiple computing devices, and alternatively, they may be implemented by program code executable by a computing device, such that they may be stored in a storage device and executed by a computing device, and in some cases, the steps shown or described may be performed in an order different than that described herein, or they may be separately fabricated into individual integrated circuit modules, or multiple ones of them may be fabricated into a single integrated circuit module. Thus, the present invention is not limited to any specific combination of hardware and software.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (10)

1. A method for querying routing information is characterized by comprising the following steps:
updating a part of local AID routing tables in a near field wireless communication controller (NFCC) according to an AID routing table of a global in-card application identifier in a terminal where the NFCC is located to obtain an updated local AID routing table, wherein the updated local AID routing table comprises updated AID and routing information which have corresponding relations;
receiving a route query request, wherein the route query request at least carries a first AID;
and inquiring first routing information corresponding to the first AID in the updated local AID routing table.
2. The method of claim 1, wherein the local AID routing table comprises: a first AID routing table set as the partial local AID routing table updated according to the global AID routing table and a second AID routing table set as the local AID routing tables of the remaining portions not updated in the local AID routing table,
wherein updating the local AID routing table in the NFCC according to the global AID routing table in the terminal where the NFCC is located includes: updating at least part of AIDs and routing information in the global AID routing table with corresponding relations into the second AID routing table.
3. The method of claim 2, wherein updating at least some AIDs and routing information in the global AID routing table that have a correspondence relationship comprises:
and updating AIDs and routing information which correspond to at least part of the usage scenes and have a corresponding relationship in the global AID routing table to the second AID routing table according to the usage scenes of the local AID routing table.
4. The method according to claim 2, wherein updating the local AID routing table in the NFCC according to the global AID routing table in the terminal where the NFCC is located comprises:
acquiring a second AID of an application to be installed and second routing information corresponding to the second AID;
updating the global AID routing table according to the second AID and the second routing information which have a corresponding relationship;
updating the corresponding relation between the second AID and the second routing information updated in the global AID routing table to the second AID routing table.
5. The method of claim 4, wherein updating the updated correspondence between the second AID and the second routing information in the global AID routing table into the second AID routing table comprises:
judging whether the second AID routing table is full;
and under the condition that the second AID routing table is not full, updating the corresponding relation between the updated second AID and the second routing information into the second AID routing table.
6. The method of claim 1, wherein after querying the updated local AID routing table for the first routing information corresponding to the first AID, the method further comprises:
if the first routing information corresponding to the first AID is not queried in the updated local AID routing table, querying the global AID routing table for the first routing information corresponding to the first AID.
7. The method of claim 6, wherein after querying the global AID routing table for the first routing information corresponding to the first AID, the method further comprises:
if the first routing information corresponding to the first AID is inquired in the global AID routing table, updating the inquired first AID and the first routing information with the corresponding relation to the local AID routing table.
8. The method of claim 6, wherein after querying the global AID routing table for the first routing information corresponding to the first AID, the method further comprises:
if the first routing information corresponding to the first AID is not inquired in the global AID routing table, acquiring preset routing information.
9. The method of any of claims 2 to 5, wherein querying the updated local AID routing table for the first routing information corresponding to the first AID comprises:
querying a first AID routing table of the updated local AID routing tables for the first routing information corresponding to the first AID;
if the first routing information corresponding to the first AID is not queried in the second AID routing table, querying the first routing information corresponding to the first AID in the second AID routing table of the updated local AID routing table.
10. A routing information query apparatus, comprising:
a first updating module, configured to update a part of a local AID routing table in a near field wireless communication controller NFCC according to an application identifier AID routing table in a global card in a terminal where the NFCC is located, to obtain an updated local AID routing table, where the updated local AID routing table includes an updated AID and routing information that have a corresponding relationship;
a receiving module, configured to receive a route query request, where the route query request carries at least a first AID;
a first query module, configured to query, in the updated local AID routing table, first routing information corresponding to the first AID.
CN201610188218.3A 2016-03-29 2016-03-29 Routing information query method and device Active CN107239469B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201610188218.3A CN107239469B (en) 2016-03-29 2016-03-29 Routing information query method and device
PCT/CN2016/088377 WO2017166470A1 (en) 2016-03-29 2016-07-04 Routing information query method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610188218.3A CN107239469B (en) 2016-03-29 2016-03-29 Routing information query method and device

Publications (2)

Publication Number Publication Date
CN107239469A CN107239469A (en) 2017-10-10
CN107239469B true CN107239469B (en) 2022-01-28

Family

ID=59962533

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610188218.3A Active CN107239469B (en) 2016-03-29 2016-03-29 Routing information query method and device

Country Status (2)

Country Link
CN (1) CN107239469B (en)
WO (1) WO2017166470A1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114501581A (en) * 2022-01-18 2022-05-13 无锡融卡科技有限公司 Processing method and device for reducing DH frequent operation NFCC

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3735471B2 (en) * 1998-10-05 2006-01-18 株式会社日立製作所 Packet relay device and LSI
CA2696854C (en) * 2007-09-27 2016-07-12 Inside Contactless Method and device for managing application data in an nfc system in response to the sending or receiving of data without contact
CN102088407B (en) * 2010-12-29 2012-05-30 清华大学 Mobility managing system and method for integrated identifier network as well as routing method
CN103065107B (en) * 2011-10-21 2015-12-02 中国移动通信集团公司 A kind of noncontact swipe the card application implementation method and device
CN103310537B (en) * 2012-03-16 2016-01-20 中国移动通信集团公司 A kind of many application identifications access method, smart card and POS
EP2680617A1 (en) * 2012-06-28 2014-01-01 ST-Ericsson SA Emulation of multiple devices in an NFCdevice
FR3018972B1 (en) * 2014-03-18 2016-04-15 Proton World Int Nv SECURE NFC ROUTING
KR20160012574A (en) * 2014-07-24 2016-02-03 삼성전자주식회사 Electronic apparatus and payment method thereof
CN205091790U (en) * 2014-09-24 2016-03-16 意法半导体公司 Security module

Also Published As

Publication number Publication date
CN107239469A (en) 2017-10-10
WO2017166470A1 (en) 2017-10-05

Similar Documents

Publication Publication Date Title
US10097476B2 (en) Method and apparatus for controlling home network access using phone numbers, and system thereof
US9894469B2 (en) NFC device with multiple secure elements
CN105760199A (en) Method and equipment for loading application resource
JP6923582B2 (en) Information processing equipment, information processing methods, and programs
WO2020093976A1 (en) Resource change method and device, apparatus, and storage medium
CN111431818B (en) Cross-domain request flow distribution method and device, storage medium and computer equipment
US8510423B2 (en) Install system and install method
CN107239469B (en) Routing information query method and device
CN108228842B (en) Docker mirror image library file storage method, terminal, device and storage medium
CN110139326B (en) Method, device and terminal equipment for automatically switching network modes in private network system
US10122417B2 (en) Communicating via near field communications
US20200296573A1 (en) Electronic device and method for managing an ic card with multiple sim profiles
CN110780944B (en) Method and device for starting application permission and machine-readable storage medium
CN109842482B (en) Information synchronization method, system and terminal equipment
CN106664637B (en) Routing information configuration method and device
CN103514052A (en) Multi-application mutually-accessing method and smart card
CN109522014B (en) Algorithm processing method based on new product development, electronic device and readable storage medium
US20150282121A1 (en) Local resource sharing method of machine to machine component and apparatus thereof
KR20160134419A (en) Method for changing the subscriber identification information of terminal using smart card including multiple subscriber identification information, terminal and computer program thereof
CN109922470B (en) Recommendation method, terminal and server
CN106462845A (en) Contactless front-end configuration method and terminal
CN104853308A (en) Information sharing method and mobile communication terminal
WO2021062945A1 (en) Method and device for expanding applications of embedded universal integrated circuit card
JP6260344B2 (en) Identifier determining apparatus, identifier determining method, and identifier determining program
JP2015228160A (en) Storage medium device and application execution method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant