CN109993261B - Smart card, application realization method and device and computer readable storage medium - Google Patents

Smart card, application realization method and device and computer readable storage medium Download PDF

Info

Publication number
CN109993261B
CN109993261B CN201810048862.XA CN201810048862A CN109993261B CN 109993261 B CN109993261 B CN 109993261B CN 201810048862 A CN201810048862 A CN 201810048862A CN 109993261 B CN109993261 B CN 109993261B
Authority
CN
China
Prior art keywords
application
virtual machine
smart card
adopting
program
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
CN201810048862.XA
Other languages
Chinese (zh)
Other versions
CN109993261A (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.)
Nationz Technologies Inc
Original Assignee
Nationz Technologies Inc
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 Nationz Technologies Inc filed Critical Nationz Technologies Inc
Publication of CN109993261A publication Critical patent/CN109993261A/en
Application granted granted Critical
Publication of CN109993261B publication Critical patent/CN109993261B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06KGRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
    • G06K19/00Record carriers for use with machines and with at least a part designed to carry digital markings
    • G06K19/06Record carriers for use with machines and with at least a part designed to carry digital markings characterised by the kind of the digital marking, e.g. shape, nature, code
    • G06K19/067Record carriers with conductive marks, printed circuits or semiconductor circuit elements, e.g. credit or identity cards also with resonating or responding marks without active components
    • G06K19/07Record carriers with conductive marks, printed circuits or semiconductor circuit elements, e.g. credit or identity cards also with resonating or responding marks without active components with integrated circuit chips
    • G06K19/077Constructional details, e.g. mounting of circuits in the carrier
    • G06K19/07749Constructional details, e.g. mounting of circuits in the carrier the record carrier being capable of non-contact communication, e.g. constructional details of the antenna of a non-contact smart card
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45562Creating, deleting, cloning virtual machine instances
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The invention provides a smart card, an application realization method, a device and a computer readable storage medium, wherein during working, a virtual machine is constructed by adopting a native method, then a target application is called by the virtual machine, an outer layer program of the target application is analyzed, a core program of the target application is processed by adopting the native method, and a processing result is returned to a JAVA application layer, namely the core program is processed by adopting the native method, so that the execution efficiency can be accelerated, and the problem of lower efficiency when the existing JAVA smart card executes the application program by adopting the JAVA virtual machine is solved.

Description

Smart card, application realization method and device and computer readable storage medium
Technical Field
The present invention relates to the field of smart card applications, and in particular, to a smart card, an application implementation method, an application implementation device, and a computer readable storage medium.
Background
Along with the development of the internet and mobile communication technology, JAVA smart cards are widely used in industry to support multiple applications, have good security characteristics, face the mainstream object programming environment, and can dynamically download application programs on line.
The JAVA intelligent card is based on a JAVA virtual machine, so that development of an intelligent card application program is separated from a intelligent card hardware system, application program development is simplified, and program reusability is improved. However, when the JAVA virtual machine executes the application program, the application program needs to be parsed into byte codes, then the byte codes are compiled, and the operations such as compiling are performed, and the byte codes are converted into codes which can be directly executed by the JAVA virtual machine, and the JAVA virtual machine can execute the application program, so that the efficiency of the JAVA smart card is low due to the execution mode.
Disclosure of Invention
The invention provides a smart card, an application realization method, an application realization device and a computer readable storage medium, which are used for solving the problem that the efficiency is lower when the existing JAVA smart card executes an application program by a JAVA virtual machine.
In order to solve the technical problems, the invention adopts the following technical scheme:
a smart card application implementation method, comprising:
constructing a virtual machine by adopting a native (computer term, one of local algorithms) method;
acquiring an application calling requirement, determining a target application corresponding to the application calling requirement, calling the target application through a virtual machine, realizing a core program of the target application by adopting a native method, and realizing an outer program by adopting a JAVA mechanism;
the virtual machine analyzes the outer layer program of the target application, adopts a native method to process the core program of the target application, and returns the processing result to the JAVA application layer.
Further, obtaining the application call requirement includes:
displaying an application selection interface;
receiving a selection operation of a user on an application selection interface;
and taking the selection object of the selection operation as a target application corresponding to the application calling requirement to generate the application calling requirement.
Further, obtaining the application call requirement includes:
detecting real-time operation parameters of the smart card;
determining effective application corresponding to the real-time operation parameters;
and generating the application call requirement by using the effective application as a target application corresponding to the application call requirement.
Further, constructing the virtual machine by adopting the native method comprises the following steps: and C programming language is adopted as a native method to construct a virtual machine.
Further, the method further comprises the following steps:
acquiring an application adjustment requirement, determining an application to be adjusted corresponding to the application adjustment requirement, and forwarding the application to the virtual machine;
the virtual machine adopts a byte code patch mode to adjust an outer layer program and a core program of the application to be adjusted.
A smart card application-implementing device, comprising:
the creation module is used for constructing a virtual machine by adopting a native method;
the calling module is used for acquiring application calling requirements, determining target applications corresponding to the application calling requirements, calling the target applications through the virtual machine, enabling core programs of the target applications to be realized by adopting a native method, and enabling outer programs to be realized by adopting a JAVA mechanism;
and the execution module is used for analyzing the outer layer program of the target application through the virtual machine, processing the core program of the target application by adopting the native method, and returning the processing result to the JAVA application layer.
Further, the creation module is used for constructing a virtual machine by adopting a C programming language as a native method.
Further, the system also comprises an adjustment module, which is used for acquiring the application adjustment requirement, determining the application to be adjusted corresponding to the application adjustment requirement, and forwarding the application to the virtual machine; the virtual machine is also used for adjusting an outer layer program and a core program of the application to be adjusted by adopting a byte code patch mode.
A smart card, comprising: a processor, a memory, and a communication bus, wherein,
the communication bus is used for realizing connection communication between the processor and the memory;
the processor is configured to execute one or more programs stored in the memory to implement the steps of the smart card application implementation method provided by the present invention.
A computer readable storage medium storing one or more programs executable by one or more processors to implement the steps of the smart card application implementation method provided by the present invention.
Advantageous effects
The invention provides a smart card, an application realization method, a device and a computer readable storage medium, wherein in the invention, a core program of a target application is realized by adopting a native method, an outer layer program is realized by adopting a JAVA mechanism, so that the smart card can be compatible with a JAVA smart card.
Drawings
FIG. 1 is a flowchart of a smart card application implementation method according to a first embodiment of the present invention;
fig. 2 is a schematic structural diagram of a smart card application implementation device according to a second embodiment of the present invention;
fig. 3 is a schematic structural diagram of a smart card according to a third embodiment of the present invention;
FIG. 4 is a timing chart of the smart card according to the third embodiment of the present invention;
fig. 5 is a schematic structural diagram of a smart card according to a fourth embodiment of the present invention;
FIG. 6 is a timing chart of the smart card according to a fourth embodiment of the present invention;
fig. 7 is a schematic diagram illustrating execution of an application program according to an embodiment of the present invention.
Detailed Description
In the invention, the outer layer program is realized by byte codes, so that the application program is a common JAVA program for a JAVA intelligent card, and the core program is realized by using a local simple active method, such as a C programming language mode, thereby having higher execution efficiency.
The invention is suitable for all intelligent cards or electronic equipment provided with the intelligent cards, including PC, mobile phone, PAD, radio frequency card and the like.
The invention will be described in further detail below with reference to the drawings by means of specific embodiments.
Embodiment one:
fig. 1 is a flowchart of a smart card application implementation method provided in a first embodiment of the present invention, please refer to fig. 1, and the smart card application implementation method provided in the present embodiment includes the following steps:
s101: and constructing a virtual machine by adopting a native method.
Preferably, the virtual machine is built by adopting a C programming language as a native method.
S102: the method comprises the steps of obtaining application calling requirements, determining target applications corresponding to the application calling requirements, calling the target applications through a virtual machine, enabling core programs of the target applications to be realized by adopting a native method, and enabling outer programs to be realized by adopting a JAVA mechanism.
The method for acquiring the application calling requirements is different for different intelligent card application scenes, for example, the method can select which application to start for the scenes of the intelligent card arranged in the terminal such as the mobile phone, and the method can call according to the state of the intelligent card for the scenes of independent use of the intelligent card, such as the intelligent card corresponding to the card reader, the composite pass card and the like.
Specifically, for a scenario in which a smart card is used in cooperation with a terminal, the method includes: displaying an application selection interface; receiving a selection operation of a user on an application selection interface; and taking the selection object of the selection operation as a target application corresponding to the application calling requirement to generate the application calling requirement. For example, after the user opens the card tool kit, the application supported by the smart card is displayed in an interface mode for the user to select, and the user clicks on the application selection interface to perform selection operations, such as clicking the card-swiping application, so that the card-swiping application is the target application.
Aiming at the scene of independent use of the intelligent card, the method comprises the following steps: detecting real-time operation parameters of the smart card; determining effective application corresponding to the real-time operation parameters; and generating the application call requirement by using the effective application as a target application corresponding to the application call requirement. For example, when the smart card in the sleep state is activated by the magnetic signal, the card-swiping application will be automatically invoked, when the smart card in the active state is not read by the card reader for a long time, the sleep application will be automatically invoked, and for such a scenario, the real-time operation parameters include whether activated or not, or whether not it is not read for a long time after activation, etc., when the real-time operation parameters are activated, the corresponding effective application is the card-swiping application, and when the real-time operation parameters are not read for a long time after activation, the corresponding effective application is the sleep application, which will be described in detail in embodiment three. For example, after the smart card such as the composite pass card is started, the smart card includes two states of acquiring path information and providing path information, when the smart card is in a magnetic field, the path information stored in the security chip is provided to the external card reader, when the smart card is not in the magnetic field, the path information sent from the outside is received through the microwave radio frequency module and written into the security chip, for this scenario, the real-time operation parameters include whether the smart card is in the magnetic field or not, when the real-time operation parameters are in the magnetic field, the corresponding effective application is an application for providing the path information, and when the real-time operation parameters are not in the magnetic field, the corresponding effective application is an application for acquiring the path information, which will be described in detail in embodiment four.
S103: the virtual machine analyzes the outer layer program of the target application, adopts a native method to process the core program of the target application, and returns the processing result to the JAVA application layer.
In this embodiment, the virtual machine analyzes the outer layer program of the target application by using a conventional JAVA mechanism such as a bytecode manner, so as to obtain a core program of the target application, and calls a local simple native method for the core program, for example, a program process based on a C programming language, so as to improve the execution efficiency of the core program.
Specifically, as shown in fig. 7, the virtual machine parses application programs such as a card swiping payment application into byte codes such as LOAD byte codes, IF byte codes, save byte codes, STORE byte codes and the like in a byte code manner, wherein the LOAD byte codes, the IF byte codes and the STORE byte codes correspond to outer programs of the application programs, the save byte codes correspond to core programs of the application programs, at this time, the virtual machine parses outer programs (LOAD byte codes, IF byte codes and STORE byte codes) of a target application, processes the core programs (save byte codes) of the target application by adopting a NATIVE method, and returns a processing result to a JAVA application layer. .
In some embodiments, the kernel program for processing the target application by adopting the native method in the step includes: the virtual machine calls the corresponding relation between a preset program and local simple native interfaces, and each local simple native interface is respectively associated with one native module; searching a local simple native interface corresponding to the core program according to the corresponding relation; and processing the core program through a native module (namely a native simple native method) corresponding to the native simple native interface.
The correspondence is shown in table 1 below:
kernel program native interface native module
Opening up a storage space native interface 1 native Module 1
Accumulating data native interface 2 native Module 2
Algorithm 1 native interface 3 native module 3
…… native interface 4 native Module 4
TABLE 1
In table 1, the functions of the native modules are all implemented by the native C programming language, and the C programming languages corresponding to the native modules are stored in the chip ROM in a hard mask manner, so long as applications related to the functions of the native modules can be directly called, and thus, the basic file system is stored in the chip ROM in a hard mask manner, so that the method can be applied to any other application requiring storing a file structure.
To address this problem, in some embodiments, the method shown in fig. 1 further includes, after step S103: acquiring an application adjustment requirement, determining an application to be adjusted corresponding to the application adjustment requirement, and forwarding the application to the virtual machine; and the virtual machine adopts a hard patch address mapping mechanism and other byte code patch modes to adjust the outer layer program and the core program of the application to be adjusted. Aiming at different application requirements, the embodiment can realize fine adjustment of the bottom code through a byte code patching mechanism, support a hard patch address mapping mechanism, maximally support 8 address mapping patches, and more conveniently carry out code level fine adjustment aiming at more applications.
The embodiment provides a smart card application implementation method, when in work, a virtual machine is built by adopting a native method, then a target application is called through the virtual machine, an outer layer program of the target application is analyzed, a core program of the target application is processed by adopting the native method, and a processing result is returned to a JAVA application layer, namely the method adopts a local simple native method to process the core program, so that the execution efficiency can be accelerated, and the problem that the efficiency is lower when the existing JAVA smart card executes the application program through the JAVA virtual machine is solved.
Embodiment two:
fig. 2 is a schematic structural diagram of a smart card application implementation apparatus provided in a second embodiment of the present invention, please refer to fig. 2, and the smart card application implementation apparatus 2 provided in this embodiment includes:
a creation module 21, configured to construct a virtual machine by adopting a native method;
the calling module 22 is configured to obtain an application calling requirement, determine a target application corresponding to the application calling requirement, call the target application through the virtual machine, implement a kernel program of the target application by adopting a native method, and implement an outer layer program by adopting a JAVA mechanism;
and the execution module 23 is configured to parse the external layer program of the target application through the virtual machine, process the core program of the target application by adopting the native method, and return the processing result to the JAVA application layer.
In some embodiments, the calling module 22 is configured to display an application selection interface, and receive a selection operation of a user on the application selection interface; and taking the selection object of the selection operation as a target application corresponding to the application calling requirement to generate the application calling requirement.
In some embodiments, the calling module 22 is configured to detect real-time operating parameters of the smart card; determining effective application corresponding to the real-time operation parameters; and generating the application call requirement by using the effective application as a target application corresponding to the application call requirement.
In some embodiments, the creation module 21 is configured to build a virtual machine using a C programming language as the active method.
In some embodiments, as shown in fig. 2, the smart card application implementation apparatus 2 further includes an adjustment module 24, configured to obtain an application adjustment requirement, determine an application to be adjusted corresponding to the application adjustment requirement, and forward the application to the virtual machine; the virtual machine is also used for adjusting an outer layer program and a core program of the application to be adjusted by adopting a byte code patch mode.
In the smart card according to the third and fourth embodiments, the security chip is electrically connected to the magnetic induction coil, so that when the magnetic induction coil enters the magnetic field to generate current, the security chip is charged, that is, the power control pin of the security chip outputs a specific potential, that is, the first potential referred to herein, typically, the first potential is a high potential, such as a high level of 1.5V, and in other cases, the high potential may be 3.3V to 5V, and the potential change of the power control pin is synchronous with the entering of the magnetic field by the magnetic induction coil.
Embodiment III:
the present embodiment is described taking a payment card such as a bank card as an example.
Fig. 3 is a schematic structural diagram of a smart card according to a third embodiment of the present invention, referring to fig. 3, the smart card provided in this embodiment includes: the safety chip and the communication coil (such as a magnetic induction coil) are internally provided with a radio frequency module, the safety chip is electrically connected with the communication coil, and the safety chip stores safety data such as user account information and the like.
As shown in fig. 4, after the smart card approaches the card reader and is activated by the magnetic signal, the smart card performs secure data interaction with the card reader to complete payment, and after the smart card is far away from the card reader, the smart card performs a sleep state, which is a complete card swiping payment process. The outer layer program of the card swiping payment application related in the embodiment is realized by a virtual machine in a byte code mode, and the core program is realized by a native simple native mode such as a C programming language through a native module.
Specifically, as shown in fig. 4:
at time t0, the smart card is close to the card reader, but does not enter the effective range of the card searching signal sent by the card reader through the magnetic signal, at the moment, the magnetic induction coil does not sense the magnetic signal, the smart card sleeps, the corresponding target application is sleep application, and the core program of the application is simple and is directly realized by the virtual machine through a byte code mode.
At time t1, the smart card approaches the card reader and enters the effective range of the card seeking signal sent by the card reader through the magnetic signal, at this time, the magnetic induction coil senses the magnetic signal, the smart card is activated, the corresponding target application is the card swiping application, the virtual machine analyzes an outer layer program of the card swiping payment application in a byte code mode, acquires core programs such as a payment algorithm and a security algorithm of the card swiping payment application, sends the core programs to the corresponding native module for processing, and the native module processes the core programs in a local simple native mode such as a C programming language, activates the radio frequency module, and outputs processing results such as a card swiping payment result through the radio frequency module and the radio frequency antenna to finish the card swiping payment.
At time t2, the smart card is far away from the card reader and leaves the effective range of the card searching signal sent by the card reader through the magnetic signal, at the moment, the magnetic induction coil cannot sense the magnetic signal, the smart card enters dormancy, the corresponding target application is dormancy application, the virtual machine adopts a byte code mode to realize dormancy application, and the radio frequency module is controlled to be dormant.
Embodiment four:
the present embodiment will be described by taking a composite access card such as a high-speed toll card as an example.
Fig. 5 is a schematic structural diagram of a smart card according to a fourth embodiment of the present invention, referring to fig. 5, the smart card provided in this embodiment includes: the main controller 51, the national density chip 52, the microwave chip 53, the magnetic induction coil, the microwave antenna and the like, wherein the main controller 51 is respectively connected with a power control pin of the national density chip 52 and the microwave chip 53, the national density chip 52 is electrically connected with the magnetic induction coil, the microwave chip 53 is electrically connected with the microwave antenna, and the national density chip 52 stores safety data such as path information and the like.
All vehicle information is stored in a national cipher chip of the composite pass card, and the national cipher chip is required to be provided with an intelligent card operating system and create national standard files conforming to traffic department, so that in practical application, the composite pass card is divided into 3 modes such as an entrance mode, a road mode, an exit mode and the like. As shown in fig. 6, when a vehicle is driven into a high-speed entrance, the history path information in the card is cleared by using a lane card reader in an entrance mode in an entrance lane, the current entrance information is written into a composite pass card, the composite pass card is switched to an on-road mode, and road sign information starts to be received. In the on-road mode, the identification antenna can broadcast a wake-up signal in real time, when a vehicle carrying the composite pass card runs to the signal coverage area of the identification antenna, the vehicle is waken up, 433MHz/5.8GHz path identification flow is started, and after the two-way authentication is passed, the composite pass card stores path information. When the vehicle runs to the exit lane, in the exit mode, the lane card reader and the lane RSU antenna read the path information in the composite pass card, upload the path information to the network charge settlement management center system, and then finish the pass fee splitting work based on the path analysis result by the latter.
In the entrance mode and the exit mode, when the composite pass card approaches an entrance/exit lane card reader, the internal state secret chip of the card automatically detects a magnetic field, at the moment, a power supply monitoring pin signal is automatically pulled up, the main controller knows that the composite pass card needs to be subjected to non-communication through the pulled up power supply monitoring pin, and at the moment, the 7816 communication clock of the microwave chip is disconnected; when the power monitor pin signal is detected to be low, the microwave chip 7816 communication is resumed, and the magnetic field is removed. The application for providing path information, the application for clearing path information, and the application for acquiring path information according to the present embodiment are all implemented in the manner shown in fig. 7.
Specifically, as shown in fig. 6:
at time t0 to time t1, the user obtains the composite pass card and places the composite pass card on the entrance card reader, at this time, the composite pass card enters the effective range of the card seeking signal sent by the card reader through the magnetic signal, at this time, the magnetic induction coil senses the magnetic signal, the electric potential of the power control pin of the national cipher chip 52 becomes high electric potential 1 in real time, the main controller 51 activates the national cipher chip 52, the corresponding target application is the application of clearing path information, the virtual machine analyzes the outer layer program of the application of clearing path information in a byte code mode, obtains core programs such as a storage space, a safe storage algorithm and the like, sends the core programs to the corresponding active module for processing, the active module opens up a storage space in the national cipher chip 52 in a local simple active mode such as a C programming language and the like, activates the microwave module 53, and starts the encryption algorithm to complete the data processing in the entrance mode.
At time t1 to time t2, the composite pass card enters the expressway, is far away from the card reader, and leaves the effective range of the card seeking signal sent by the card reader through the magnetic signal, at the moment, the magnetic induction coil cannot sense the magnetic signal, the potential of the power control pin of the national security chip 52 becomes low potential 0 in real time, the main controller 51 controls the intelligent card to switch to the on-road mode, the corresponding target application is to acquire path information application, the virtual machine analyzes an outer layer program of the path information acquisition application in a byte code mode, acquires core programs such as a path information recording algorithm, a secure storage algorithm and the like, sends the core programs to the corresponding native module for processing, and the native module stores the path information in a storage space corresponding to the national security chip after secure encryption is carried out on the path information, and performs data processing such as path signal acquisition and storage.
At time t2 to time t3, the user arrives at a high-speed exit, the composite pass card is placed on an exit card reader, at this time, the composite pass card enters the effective range of a card searching signal sent by the card reader through a magnetic signal, at this time, the magnetic induction coil senses the magnetic signal, the electric potential of a power control pin of the national cipher chip 52 becomes high electric potential 1 in real time, the main controller 51 activates the national cipher chip 52, the corresponding target application is to provide path information application, the virtual machine analyzes an outer layer program for clearing the path information application in a byte code mode, core programs such as a security decryption algorithm, a data reading algorithm and the like are obtained, the core programs are sent to the corresponding native module for processing, the native module adopts a local simple native mode such as a C programming language and the like for processing the core programs, and in the storage space of the national cipher chip 52, after the decryption algorithm is started, the decrypted path information is sent to the exit card reader through the magnetic induction coil, and the data processing in an exit mode is completed.
According to the embodiment, the potential signal is automatically detected through hardware, the corresponding level is output through the control pin, the main controller is informed of whether the current smart card enters the magnetic field or not, and no additional processing is needed by software.
In some embodiments, the smart card provided by the present invention includes: a processor, a memory, and a communication bus, wherein,
the communication bus is used for realizing connection communication between the processor and the memory;
the processor is configured to execute one or more programs stored in the memory to implement the steps of the methods provided by any of the embodiments above.
The present invention also provides a computer-readable storage medium storing one or more programs that are executed to implement the steps of the methods provided by all embodiments of the present invention.
As can be seen from the implementation of the above embodiments, the present invention has the following advantages:
the invention provides a smart card, an application realization method, a device and a computer readable storage medium, wherein in the invention, a core program of a target application is realized by adopting a native method, an outer layer program is realized by adopting a JAVA mechanism, so that the smart card can be compatible with a JAVA smart card.
The foregoing is a further detailed description of the invention in connection with specific embodiments, and it is not intended that the invention be limited to such description. It will be apparent to those skilled in the art that several simple deductions or substitutions may be made without departing from the spirit of the invention, and these should be considered to be within the scope of the invention.

Claims (8)

1. A method for implementing a smart card application, comprising:
constructing a virtual machine by adopting a native method;
acquiring an application calling requirement, determining a target application corresponding to the application calling requirement, calling the target application through the virtual machine, wherein a core program of the target application is realized by adopting a native method, and an outer program is realized by adopting a JAVA mechanism;
the virtual machine analyzes an outer layer program of the target application, adopts a native method to process a core program of the target application, and returns a processing result to a JAVA application layer;
acquiring an application adjustment requirement, determining an application to be adjusted corresponding to the application adjustment requirement, and forwarding the application to the virtual machine;
and the virtual machine adopts a byte code patch mode to adjust the outer layer program and the core program of the application to be adjusted.
2. The smart card application implementation method of claim 1, wherein the obtaining the application call requirement includes:
displaying an application selection interface;
receiving a selection operation of a user on the application selection interface;
and taking the selection object of the selection operation as a target application corresponding to the application calling requirement to generate the application calling requirement.
3. The smart card application implementation method of claim 1, wherein the obtaining the application call requirement includes:
detecting real-time operation parameters of the smart card;
determining effective application corresponding to the real-time operation parameter;
and generating the application calling requirement by taking the effective application as a target application corresponding to the application calling requirement.
4. The smart card application implementation method of claim 1, wherein said constructing a virtual machine using a native method comprises: and constructing the virtual machine by adopting a C programming language as the native method.
5. A smart card application implementation apparatus, comprising:
the creation module is used for constructing a virtual machine by adopting a native method;
the calling module is used for acquiring application calling requirements, determining target applications corresponding to the application calling requirements, calling the target applications through the virtual machine, wherein a core program of the target applications is realized by adopting a native method, and an outer layer program is realized by adopting a JAVA mechanism;
the execution module is used for analyzing the outer layer program of the target application through the virtual machine, processing the core program of the target application by adopting a native method, and returning a processing result to the JAVA application layer;
the adjusting module is used for acquiring application adjusting requirements, determining an application to be adjusted corresponding to the application adjusting requirements and forwarding the application to the virtual machine; the virtual machine is also used for adjusting the outer layer program and the core program of the application to be adjusted by adopting a byte code patch mode.
6. The smart card application-implementing apparatus of claim 5, wherein the creation module is configured to build the virtual machine using a C programming language as the native method.
7. A smart card, comprising: a processor, a memory, and a communication bus, wherein,
the communication bus is used for realizing connection communication between the processor and the memory;
the processor is configured to execute one or more programs stored in the memory to implement the steps of the smart card application-implementing method according to any one of claims 1 to 4.
8. A computer readable storage medium storing one or more programs executable by one or more processors to implement the steps of the smart card application implementation method of any one of claims 1 to 4.
CN201810048862.XA 2017-12-29 2018-01-18 Smart card, application realization method and device and computer readable storage medium Active CN109993261B (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN2017114899774 2017-12-29
CN201711489977 2017-12-29

Publications (2)

Publication Number Publication Date
CN109993261A CN109993261A (en) 2019-07-09
CN109993261B true CN109993261B (en) 2023-06-16

Family

ID=67128653

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810048862.XA Active CN109993261B (en) 2017-12-29 2018-01-18 Smart card, application realization method and device and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN109993261B (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101231597A (en) * 2008-02-01 2008-07-30 东信和平智能卡股份有限公司 Method for execution of JAVA program instruction in smart card

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8607224B2 (en) * 2009-05-28 2013-12-10 Yahoo! Inc. System for packaging native program extensions together with virtual machine applications
US8978023B2 (en) * 2011-12-29 2015-03-10 Oracle International Corporation Canonical mechanism for securely assembling features into a mobile application
CN103530171A (en) * 2013-10-25 2014-01-22 大唐微电子技术有限公司 Smart card virtual machine and implementation method thereof
CN105005497A (en) * 2014-04-18 2015-10-28 中钞信用卡产业发展有限公司 Method and apparatus for calling local function in Java card virtual machine

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101231597A (en) * 2008-02-01 2008-07-30 东信和平智能卡股份有限公司 Method for execution of JAVA program instruction in smart card

Also Published As

Publication number Publication date
CN109993261A (en) 2019-07-09

Similar Documents

Publication Publication Date Title
US7364083B2 (en) IC card with built-in coprocessor for auxiliary arithmetic, and control method thereof
KR20170133478A (en) Cards and application programs
CN103839313A (en) Access control system
CN105488555A (en) Managing power and timing in a smart card device
RU2005131017A (en) MOBILE TERMINAL DEVICE, METHOD FOR MOBILE TERMINAL, MOBILE TERMINAL PROGRAM, SERVER DEVICE, METHOD FOR PROVIDING SERVER DEVICE AND PROVIDING SERVER PROGRAM
US20120149357A1 (en) Remote control method and system for smart card
US9729205B2 (en) Battery management scheme for NFC
KR20150085821A (en) Nfc device comprising configurable notification means
KR20130142864A (en) Method for issuing mobile credit card in portable terminal using credit card and credit card for the same
CN111581994A (en) Near Field Communication (NFC) communication method and device and electronic equipment
CN103365397A (en) Information processing apparatus and control method
CN110191054B (en) Route processing method and device, storage medium and electronic equipment
CN101853351A (en) Automatically the method and apparatus of the selection application that can realize by equipment
CN110414651A (en) Debug the method and device of smart card
CN109993261B (en) Smart card, application realization method and device and computer readable storage medium
KR101122470B1 (en) System and method for distinguishing electronic money of muiti type, apparatus applied to the same
CN111164912A (en) Wireless signal noise reduction
KR20190051724A (en) Device and method for controlling transactions of nfc reader with external electronic device
CN205230211U (en) Intelligence POS terminal
EP1272974B1 (en) Data carrier having a chip including means for the controllable voltage supply to a further component of the data carrier
CN108564721B (en) Charging method, server and intelligent device
CN109426324B (en) Power-on control method, AP chip and mobile terminal
CN206249399U (en) Intelligent data acquisition is analyzed and wages generate system
EP3751437A1 (en) Information processing device, information processing method, and program
CN205540909U (en) Intelligence POS machine security module

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