Supercharge Your Innovation With Domain-Expert AI Agents!

Java code patching method of Java card

A patch and code technology, applied in the Java code patch field of Java cards, can solve problems such as the inability to guarantee the operating efficiency of Java cards, the large space of Java cards, and the large memory of applications, so as to reduce table lookup operations and meet time-sensitive applications needs, small memory effect

Active Publication Date: 2015-05-27
东港股份有限公司
View PDF6 Cites 2 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] However, with changes in user needs and diversification of services, after the Java Card product is put into use, it is likely to have defects or require an upgrade of the function. If the Java code solidified in the Java Card ROM or EEPROM cannot be upgraded and maintained , the user needs to replace the Java card, which affects the life of the user. If the Java card used for patching and upgrading has a large space, the Java card cannot be guaranteed when processing some time-sensitive applications (such as fast payment). operation efficiency
[0004] In the existing Java card patch method, if the original program is found to have defects, generally by deleting the original program, downloading and installing a new application program, this method will cause the loss of customer data, and due to the large memory of the application program itself , requires less modification, and takes longer if the entire application is re-downloaded

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Java code patching method of Java card
  • Java code patching method of Java card
  • Java code patching method of Java card

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0049] A kind of Java code patch method of Java card, comprises the following steps:

[0050] (1) In the Java card chip, an area is allocated in EEPROM in advance as a patch management table for Java code. When patching different packages, an area is dynamically allocated from EEPROM as a patch information table for Java code. If each If the number of patches in the package exceeds 10, a multi-level patch information table is required;

[0051] The Java code patch consists of a patch management table, a patch information table, and a patch code;

[0052] The size of the patch management table is the number of Java packages solidified into the ROM area × 3 bytes, in which the 3 bytes of data are the offset address of the patch number of 1 byte and the patch information table of 2 bytes; patch management The structure of the table is shown in Table 1.

[0053] Table 1 Structure of patch management table

[0054]

[0055] The size of each level of patch information table is...

Embodiment 2

[0064] The method for patching the Java package stored in the ROM comprises the following steps:

[0065] ①Locate the card to the patch management table, access the static array variable of the patch management table, increase the number of patch methods, and check whether there is a patch information table. If it does not exist, additional space needs to be allocated to store the patch information table;

[0066] ② Add a new patch method information in the patch information table, including three parts: the absolute address of the method, the offset address of the abnormal information of the corrected method, and the offset address of the method body of the corrected method;

[0067] ③If the patch information in the patch information table is full, you need to apply for new space from EEPROM, build the next level of patch information table, and write the offset address of the new table at the end of the existing patch information table, and then go to the second step Continue...

Embodiment 3

[0072] The method for patching the Java package stored in the EEPROM comprises the following steps:

[0073] ①The card locates the method body of the original method, and updates the first byte to 0;

[0074] ② Allocate space from EEPROM to store the patch code, and write the offset address of the patch code into the 2nd and 3rd bytes of the method body of the original method.

[0075] like image 3 The Java package patching mechanism for the EEPROM area shown.

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a Java code patching method of a Java card. Two different processing methods are provided for Java codes stored in an ROM (Read Only Memory) region of the Java card and Java codes stored in an EEPROM (Electrically Erasable Programmable Read-Only Memory) region of the Java card; as for the Java codes in the ROM region, only a patch management table is allocated in advance, a multilevel patch information table method is adopted, space is not needed to be allocated to the patch information table in advance, and the patch information table is dynamically allocated during patching, so that the pre-allocated space can be greatly reduced; as for the Java codes in the EEPROM region, extra space is not needed for management, modification is performed on the address of an original method, and the operation of looking up the table is reduced, so that the implementation speed of the method is further improved. According to the Java code patching method, a user can patch the Java codes in the Java card without replacing the Java card, and the purpose of upgrading functions or repairing defects is achieved; after patching is performed, the operating efficiency of the Java card can be ensured, the demands of clients for time-sensitive application are met, client data losses caused by application program updating can be avoided, and the method has the advantage of short time required for repairing.

Description

technical field [0001] The invention relates to the field of Java smart cards, in particular to a Java code patch method for a Java card. Background technique [0002] With the overall development of financial electronics, in order to meet the needs of users for one card with multiple functions, Java cards supporting multiple applications have been more and more widely used. As a smart card, the Java card's storage system is mainly composed of read-write memory (RAM), read-only memory (ROM) and erasable programming memory (EEPROM), among which RAM is used to store intermediate data and result data in the operation process , ROM is used to store the operating system of the smart card, and EEPROM is the main memory of the smart card, which is used to store the personal information of the cardholder and the information and application data of the issuing unit. [0003] However, with changes in user needs and diversification of services, after the Java Card product is put into...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06F9/445
Inventor 刘哲理隋传波
Owner 东港股份有限公司
Features
  • R&D
  • Intellectual Property
  • Life Sciences
  • Materials
  • Tech Scout
Why Patsnap Eureka
  • Unparalleled Data Quality
  • Higher Quality Content
  • 60% Fewer Hallucinations
Social media
Patsnap Eureka Blog
Learn More