WO2014173298A1 - Procédé de gestion d'une application sur carte - Google Patents

Procédé de gestion d'une application sur carte Download PDF

Info

Publication number
WO2014173298A1
WO2014173298A1 PCT/CN2014/076030 CN2014076030W WO2014173298A1 WO 2014173298 A1 WO2014173298 A1 WO 2014173298A1 CN 2014076030 W CN2014076030 W CN 2014076030W WO 2014173298 A1 WO2014173298 A1 WO 2014173298A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
command
card
data block
application
Prior art date
Application number
PCT/CN2014/076030
Other languages
English (en)
Chinese (zh)
Inventor
陆舟
于华章
Original Assignee
飞天诚信科技股份有限公司
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
Priority claimed from CN201310146939.4A external-priority patent/CN103218560B/zh
Priority claimed from CN201310399702.7A external-priority patent/CN103473093B/zh
Application filed by 飞天诚信科技股份有限公司 filed Critical 飞天诚信科技股份有限公司
Priority to US14/786,213 priority Critical patent/US10324781B2/en
Publication of WO2014173298A1 publication Critical patent/WO2014173298A1/fr

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/079Root cause analysis, i.e. error or fault diagnosis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/50Monitoring users, programs or devices to maintain the integrity of platforms, e.g. of processors, firmware or operating systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/0706Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment
    • G06F11/0736Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation the processing taking place on a specific hardware platform or in a specific software environment in functional embedded systems, i.e. in a data processing system designed as a combination of hardware and software dedicated to performing a certain function
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/0751Error or fault detection not based on redundancy
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/0766Error or fault reporting or storing
    • G06F11/0772Means for error signaling, e.g. using interrupts, exception flags, dedicated error registers
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/70Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer
    • G06F21/71Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information
    • G06F21/74Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information operating in dual or compartmented mode, i.e. at least one secure mode
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/70Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer
    • G06F21/71Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information
    • G06F21/77Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information in smart cards

Definitions

  • the invention belongs to the field of smart cards, and in particular relates to a method for managing applications on a card. Background technique
  • the card issuer does not manage all the card contents, especially the card is not issued.
  • the card content of the party therefore, requires a mechanism for the third party to manage the card content by pre-authentication, such as loading, installing, extradition and deletion.
  • the object of the present invention is to overcome the deficiencies of the prior art and to provide a method of managing applications on a card.
  • a method of managing applications on a card the basic implementation process is as follows:
  • Step A Check the card status. If it is the first preset state or the second preset state, step B: Check whether the received data conforms to the preset format. If the first preset format is met, perform step C. The second preset format performs step D. If the third preset format is met, step E is performed. If the fourth preset format is met, step F is performed. If the fifth preset format is met, step G is performed. The preset format is executed in step H. If the seventh preset format is met, step I is performed. If the preset format is not met, the data error status code is generated and returned to the operating environment, and the process ends.
  • Step C Continue to receive the data sent by the operating environment to obtain a complete first command, parse the first command, obtain a load file identifier and a load file associated security domain identifier, create a load file structure, and parse the obtained load file identifier and The load file associated domain identifier is populated into the created load file structure. If successful, the generated success status code and return result are sent to the running environment, and the process ends. If the operation is unsuccessful, it is generated and returned according to the failure reason. The corresponding status code is given to the operating environment, and ends;
  • Step D Continue to receive the data sent by the operating environment to obtain a complete second command, parse the second command, obtain a load file data block, obtain component data according to the load file data block, and store, and fill the storage address to the load In the file structure, if successful, generate and return the success status code and return result to the running environment, and end. If the operation is unsuccessful, generate and return the corresponding status code to the running environment according to the failure reason, and end;
  • Step E Continue to receive the data sent by the operating environment to obtain a complete third command, parse the third command, and obtain an executable load file identifier, an executable module identifier, an application identifier, and an application permission, and the executable load file obtained according to the parsing
  • the identifier searches for the load file structure, searches for an executable module corresponding to the parsed executable module identifier in the storage space corresponding to the storage address in the found load file structure, and creates an application of the found executable module, and uses the parsing
  • the obtained application identifier identifies the created application, and gives the created application the right specified by the parsed application permission, and sets the created application.
  • the associated security domain is an associated security domain of the executable load file corresponding to the parsed executable load file identifier. If successful, the success status code is generated and returned, and the result is returned to the running environment. If it is unsuccessful, it generates and returns the corresponding status code to the running environment according to the failure reason, and ends;
  • Step F Continue to receive the data sent by the operating environment to obtain a complete fourth command, parse the fourth command, obtain an application identifier and an application permission, and find an application corresponding to the parsed application identifier in the card, and update the found application.
  • the state of the application is a selectable state, and the permission of the newly-applied application is the permission specified by the parsed application permission. If the operation succeeds, the success status code is generated and returned, and the returned result is sent to the running environment, and ends. If the operation is unsuccessful, the corresponding status code is generated and returned to the running environment according to the failure reason, and the process ends.
  • Step G Continue to receive the data sent by the operating environment to obtain a complete fifth command, parse the fifth command, obtain the security domain identifier and the application identifier, and find the application and the parsing corresponding to the parsed application identifier in the card.
  • the security domain identifies the corresponding application, and updates the associated security domain of the found application to the application corresponding to the parsed security domain identifier. If successful, generates and returns the success status code and returns the result to the running. Environment, end, if the operation is unsuccessful, generate and return the corresponding status code to the running environment according to the failure reason, and end;
  • Step H Continue to receive the data sent by the operating environment to obtain a complete sixth command, parse the sixth command, obtain an application identifier, search for an application corresponding to the parsed application identifier in the card, and set the found application as an individual.
  • Application if successful, generate and return the success status code and return the result to the running environment, and end, if the operation is unsuccessful, generate and return the corresponding status code to the running environment according to the failure reason, and end;
  • Step I Continue to receive the data sent by the operating environment to obtain a complete seventh command, parse the seventh command, obtain a data domain identifier, and search for an application corresponding to the parsed data domain identifier and an executable loading file in the card. Delete the found application and executable load file, if successful, generate and return the success status code and return the result to Run environment, end, if the operation is unsuccessful, generate and return the corresponding status code to the running environment according to the failure reason, and end.
  • the preparing the loading application according to the first command specifically includes:
  • Step C1 determining whether the first data block of the first command is legal, and if it is legal, checking whether there is an executable file corresponding to the first data block in the card, if the condition is not satisfied, ⁇ Fails, otherwise step C2 is performed; if it is not legal, the data is incorrect and the operation fails;
  • Step C2 determining whether the second data block of the first command meets a preset requirement, and if the first preset requirement is met, setting an associated security domain of the loading file corresponding to the first data block to the card
  • the content management module performs step C4; if the second preset requirement is met, step C3 is performed; if the preset requirement is not met, the data is incorrect, and the operation fails; step C3: checking whether there is a second data block in the card Corresponding application, if not, the processing condition is not satisfied, and the operation fails; if yes, it is checked whether the application corresponding to the second data block has security domain authority, and if there is security domain authority, the setting is The associated security domain of the load file corresponding to the first data block is an application corresponding to the second data block, and step C4 is performed; if the security domain authority is not available, the processing condition is not satisfied, and the operation fails;
  • Step C4 determining whether the third data block of the first command is legal, if yes, storing the corresponding data in the third data block, and performing step C5; otherwise, the data is incorrect, and the operation fails;
  • Step C5 processing the fourth data block of the first command, performing step C6;
  • Step C6 determining whether the fifth data block of the first command is legal, if yes, creating a load file structure, and according to the A data block and the second data block fill the load file structure, initialize the global block number in the card, and succeed; otherwise, the data is incorrect and the operation fails.
  • the loading the application according to the second command specifically includes:
  • Step D1 determining whether the fourth byte of the second command is equal to the global block number in the card, if yes, executing step D2; otherwise, the data is incorrect, and the operation fails;
  • Step D2 Check whether the second command includes the data verification mode block information, and if yes, verify the data verification mode fast information, if the verification is passed, execute step D3, if the verification fails, the data error occurs, and the operation fails.
  • step D3 acquiring component data according to the load file data block in the second command and storing, filling the storage address into the load file structure, and updating the global block number in the card If the current value is incremented by 1, it is determined whether the load file data block is the last load file data block of the load file, and if yes, step D4 is performed, otherwise the operation is successful;
  • Step D4 determining whether the hash value of the load file data block in the card has a value, and if there is a value, performing a hash calculation on the whole of the load file data block stored in the card, and determining whether the calculation result is equal to the loading.
  • File data block hash value if it is equal, then execute step D5, if it is not equal, the data is wrong, and the operation fails; if there is no value, step D5 is performed;
  • Step D5 Store and submit the executable load file structure, and succeed.
  • the installing the application according to the third command specifically includes:
  • Step E1 determining whether the first data block of the third command is legal. If it is legal, checking whether there is a loading file structure corresponding to the first data block in the card, if yes, performing step E2, otherwise If the condition is not satisfied, the operation fails; if it is not legal, the data is wrong and the operation fails;
  • Step E2 determining whether the second data block of the third command is legal, and if it is legal, checking whether a storage space corresponding to the storage address in the loading file structure has a corresponding corresponding to the second data block. Execute the module, if yes, go to step E3. Otherwise, the processing condition is not satisfied, and the operation fails. If it is not legal, the data is wrong and the operation fails.
  • Step E3 determining whether the third data block of the third command is legal. If it is legal, checking whether there is an application corresponding to the third data block in the card, if yes, executing step E4, otherwise the processing condition is not Satisfaction, failure; if not legal, the data is wrong, the failure fails;
  • Step E4 determining whether the fourth data block of the third command is legal, and if it is legal, determining whether the application corresponding to the third data block has a default selection permission, Step E5 is performed, otherwise step E6 is performed; if it is not legal, the data is incorrect, and the operation fails; Step E5: determining whether the third byte of the third command is equal to the preset value, if the preset value is the data error, ⁇ If it is not the default value, it is judged whether the card content management module has the default selection authority, if yes, step E7 is performed; otherwise, the processing condition is not satisfied, and the operation fails;
  • Step E6 determining whether the third data block of the third command meets a preset condition, and processing the fifth data block of the third command if the first preset condition or the second preset condition is met, and performing the step E7, if the preset conditions are not met, the conditions are not satisfied, and the operation fails;
  • Step E7 determining whether the sixth data block of the third command is legal, if yes, registering the application according to the third command, performing step E8, otherwise the data is incorrect, and failing; step E8: determining the third command Whether the third byte of the third byte is equal to the preset value, and the state of the application corresponding to the third data block of the third command is set to be installed, and the operation is successful; otherwise, the third command is set The status of the application corresponding to the third data block is selectable, and step E9 is performed;
  • Step E9 determining whether an application corresponding to the third data block of the third command has a default selection permission, and setting an application corresponding to the third data block of the third command as a default application, Be successful, otherwise it will succeed.
  • the setting the application state according to the fourth command specifically includes:
  • Step F1 determining whether the first data block and the second data block of the fourth command are both legal, if yes, step F2 is performed, otherwise the data is incorrect, and the operation fails;
  • Step F2 determining whether the third data block of the fourth command is legal, if not, the data is incorrect, and the operation fails; if it is legal, checking whether there is an application corresponding to the third data block in the card, if If there is no condition, the condition is not satisfied, and the operation fails; if yes, it is judged whether the state of the application corresponding to the third data block is installed, and if it is not installed, the condition is not satisfied, and the operation fails; Step F3 is performed for installation;
  • Step F3 determining whether the fourth data block of the fourth command is legal, if yes, executing step F4; otherwise, the data is incorrect, and the operation fails;
  • Step F4 determining whether the fifth data block of the fourth command is legal, if yes, executing step F5; otherwise, the data is incorrect, and the operation fails;
  • Step F5 determining whether the sixth data block of the fourth command is legal, if yes, setting the state of the application corresponding to the third data block to be selectable, performing step F6, otherwise the data error fails;
  • Step F6 determining whether the application corresponding to the third data block has a default selection permission, if not, the operation is successful; if yes, determining whether the card content management module has a default selection permission, The application corresponding to the third data block is the default application, and the operation is successful. Otherwise, the processing condition is not satisfied, and the operation fails.
  • the updating the associated security domain of the application according to the fifth command specifically includes: Step G1: determining whether the first data block of the fifth command is legal, if not, the data is incorrect, and the operation fails; if it is legal, the card is checked. Whether there is an application corresponding to the first data block, if not, the processing condition is not satisfied, and the operation fails; if yes, it is determined whether the application corresponding to the first data block is the card.
  • the content management module if yes, the processing condition is not satisfied, and the operation fails; if not, step G2 is performed; step G2: determining whether the second data block of the fifth command is legal, if not, the data is incorrect, and the operation fails. If it is legal, it is determined whether the state of the application corresponding to the first data block is an installation, if not, the processing condition is not satisfied, and the operation fails; if it is installed, step G3 is performed;
  • Step G3 determining whether the third data block of the fifth command is legal. If it is not legal, the data is incorrect, and the operation fails; if it is legal, it is checked whether there is an application corresponding to the third data block in the card, if If there is no condition, the condition is not satisfied, and the operation fails; if yes, step G4 is performed;
  • Step G4 determining whether the application corresponding to the first data block has security domain authority, if not, the processing condition is not satisfied, and the failure occurs; if yes, determining that the first data block corresponds to Whether the state of the application is locked, if it is locked, the processing condition is not satisfied, and the operation fails; if it is not locked, it is determined whether the state of the application corresponding to the first data block is personalized, if it is personalized Then perform step G5, if not personalized If the conditions are not satisfied, the operation fails;
  • Step G5 determining whether the fourth data block and the fifth data block of the fifth command are both legal, if yes, executing step G6; otherwise, the data is incorrect, and the operation fails;
  • Step G6 determining whether the sixth data block of the fifth command is legal, if not, the data is incorrect, and the operation fails; if it is legal, determining whether the application corresponding to the third data block has security domain rights, If the condition is not satisfied, the failure is successful; if not, the associated security domain of the application corresponding to the third data block is set to be the application corresponding to the first data block, success.
  • the personalization application according to the sixth command specifically includes:
  • Step HI determining whether the first data block and the second data block of the sixth command are both legal, if yes, step H2 is performed, otherwise the data is incorrect, and the operation fails;
  • Step H2 determining whether the third data block of the sixth command is legal, if not, the data is incorrect, and the operation fails; if it is legal, checking whether there is an application corresponding to the third data block in the card, if If the condition is not satisfied, the operation fails; if yes, it is determined whether the associated security domain of the application corresponding to the third data block is the card content management module, if yes, step H3 is performed, otherwise, If the conditions are not met, the operation fails;
  • Step H3 determining whether the fourth data block, the fifth data block, and the sixth data block of the sixth command are both legal, and setting an application corresponding to the third data block to be a personalized application Otherwise, the conditions are not met and the operation fails.
  • the deleting the application and the executable loading file according to the seventh command specifically includes: Step II: determining whether the first data block of the seventh command is legal, if yes, executing step 12; otherwise, the data is incorrect, and the operation fails;
  • Step 12 Determine whether the second data block of the seventh command is legal. If it is not legal, the data is incorrect, and the operation fails. If it is legal, check whether there is an application corresponding to the second data block in the card. Then perform step 13, otherwise perform step 14;
  • Step 13 Determine whether the fourth byte of the seventh command is equal to the preset value, if yes, go to step 14, otherwise go to step 15;
  • Step 14 Check whether there is an executable load file corresponding to the second data block in the card. If not, the processing condition is not satisfied, and the operation fails; if yes, the fourth command of the seventh command is determined. Whether the byte is equal to a preset value, if equal to deleting the application and the executable load file corresponding to the second data block, if successful, if not equal to deleting the corresponding corresponding to the second data block The executable load file can be successfully executed;
  • Step 15 Check whether the application corresponding to the second data block is an associated security domain of another application or other executable load file, if the processing condition is not satisfied, the operation fails; otherwise, step 16;
  • Step 16 determining whether the application corresponding to the second data block is the card content management module, if the processing condition is not satisfied, the operation fails, otherwise deleting the corresponding data block corresponding to the second data block Application, success.
  • a method for implementing management of card data is as follows:
  • the first card data management module After the first card data management module receives the application protocol data unit APDU data sent by the operating environment, it uses itself as the current first card data management module, and performs the following steps:
  • Step A Examining the instruction code of the APDU data, if the instruction code is a valid value 0xE8, performing step D, if the instruction code is a valid value 0xE6, performing step B, if the instruction code is a valid value 0xE4 Perform step I;
  • Step B Check the first parameter of the APDU data, if the first parameter is 0x02, perform step C, if the first parameter is 0x04 or OxOC, perform step E, if the first parameter is 0x08 Step F is performed, if the first parameter is 0x10, step G is performed, and if the first parameter is 0x20, step H is performed;
  • Step C Collecting the data field part of the preloading command, obtaining the entire content of the preloading command, checking whether the card satisfies the preloading condition according to the content of the preloading command, and then creating a new executable loading file structure and setting corresponding data, and executing Step J, otherwise directly perform step J;
  • Step D collecting the data field part of the load command, obtaining the entire content of the load command, checking whether the card satisfies the loading condition according to the content of the load command, and storing the Load the corresponding content of the command, perform step J, otherwise directly execute step J;
  • Step E Collecting the data field part of the installation command, obtaining the entire content of the installation command, checking whether the card satisfies the installation condition according to the content of the installation command, creating an application and setting the corresponding state, performing step J, otherwise directly performing step J ;
  • Step F Collecting the data field part of the selectable command, obtaining all the contents of the selectable command, checking whether the card satisfies the selectable condition according to the content of the selectable command, and setting the state of the corresponding application to be selectable, and performing step J Otherwise, step J is directly executed; step G, collecting the data domain part of the extradition command, obtaining the entire content of the extradition command, checking whether the card satisfies the extradition condition according to the content of the extradition command, and resetting the security domain associated with the corresponding application, Perform step J, otherwise directly perform step J;
  • Step H Collecting the data field part of the personalized command, obtaining the entire content of the personalized command, checking whether the card satisfies the personalized condition according to the content of the personalized command, and then sending the corresponding data to the corresponding application, and performing step J, Otherwise, step J is directly executed;
  • Step I The data field portion of the delete command is received, and the entire content of the delete command is obtained. According to the content of the delete command, it is checked whether the card meets the deletion condition, and the card specified in the delete command is deleted. Corresponding data, perform step J, otherwise directly perform step J;
  • Step J Generate and return corresponding return data and/or corresponding status code to the running environment.
  • the beneficial effects of the method of the present invention are: providing a method for managing applications on a card, which can implement loading, installing, updating, personalizing, and deleting applications on the card; and simultaneously providing convenience for data management on the smart card, specifically embodied in Two aspects:
  • the card issuer may not care about applications that are not related to itself;
  • FIG. 1 is a flow chart of a method for managing an application on a card according to Embodiment 1 of the present invention
  • FIG. 2 is a flow chart of a specific method for preparing a loading application according to Embodiment 2 of the present invention
  • FIG. 3 is a flowchart of a specific method for loading an application according to Embodiment 3 of the present invention
  • FIG. 4 is a flowchart of a specific method for installing an application according to Embodiment 4 of the present invention
  • FIG. 6 is a flowchart of a specific method for updating an associated security domain of an application according to Embodiment 6 of the present invention.
  • Embodiment 7 is a flow chart of a specific method for a personalized application according to Embodiment 7 of the present invention.
  • FIG. 8 is a flowchart of a specific method for deleting an application and executing an executable file according to Embodiment 8 of the present invention.
  • FIG. 9 is a flowchart of a method for implementing management card data according to the present invention.
  • FIG. 10 is a specific flowchart of steps 1001 to 1028;
  • FIG. 11 is a specific flowchart of steps 1101 to 1129;
  • Figure 12 is a specific flow chart of steps 1201 to 1235;
  • Figure 13 is a specific flow chart of steps 1301 to 1324;
  • Figure 14 is a specific flow chart of steps 1401 to 1428;
  • Figure 15 is a specific flow chart of steps 1501 to 1517;
  • Figure 16 is a detailed flow chart of steps 1601 through 1625. detailed description
  • a first embodiment of the present invention provides a method for managing an application on a card.
  • the method specifically includes: after the card content management module receives the data sent by the RE (Runtime Environment) device, performing the following steps.
  • the card content management module is a special application in the card:
  • Step 101 Check the card status. If it is the first preset state or the second preset state, generate and return the card state does not support the status code to the RE, and end; otherwise, perform step 102; specifically, in this embodiment, A preset state is TERMINATED and the second preset state is CARD_LOCKED.
  • Step 102 Check whether the received data conforms to the preset format. If the first preset format is met, step 103 is performed; if the second preset format is met, step 104 is performed; if the third preset format is met, step 105 is performed; If the fourth preset format is met, step 106 is performed; if the fifth preset format is met, step 107 is performed; if the sixth preset format is met, step 108 is performed; if the seventh preset format is met, step 109 is performed; Comply with the default format to generate and return a data error status code to the RE, ending;
  • step 102 specifically includes:
  • Step B1 Check whether the length of the received data is five bytes. If yes, execute step B2. Otherwise, the received data does not conform to the preset format, generate and return a data error status code to the operating environment, and end;
  • Step B2 Check whether the first byte of the received data is 0x80 or 0x84, if yes, execute step B3, otherwise the received data does not conform to the preset format, generate and return a data error status code to the operating environment, and end;
  • Step B3 Check the second byte of the received data. If it is 0xE6, go to step B4. If it is 0xE8, go to step B5. If it is 0xE4, go to step B6. Otherwise, the received data does not match the preset format. Generate and return a data error status code to the runtime environment, End;
  • Step B4 Check the third to fifth bytes of the received data. If the third byte and the fourth byte are 0x02 and 0x00, respectively, and the fifth byte is not less than OxOA, the received data conforms to the first pre- Formatting, performing step 103; if the third byte is 0x04 or 0x0C, the fourth byte is 0x00, and the fifth byte is not less than 0x18, the received data conforms to the third preset format, and step 105 is performed; The byte and the fourth byte are 0x08 and 0x00 respectively, and the fifth byte is not less than OxOC, and the received data conforms to the fourth preset format, and step 106 is performed; if the third byte and the fourth byte are 0x10 and respectively 0x00 and the fifth byte is not less than 0x10, the received data conforms to the fifth preset format, and step 107 is performed; if the third byte and the fourth byte are 0x20 and
  • Step B5 Check whether the third byte of the received data is 0x00 or 0x80, if the received data conforms to the second preset format, perform step 104, otherwise the received data does not conform to the preset format, and generates Return the data error status code to the running environment, and end;
  • Step B6 Check whether the third byte of the received data is 0x00, if the received data conforms to the seventh preset format, go to step 109, otherwise receive the received data. The data does not conform to the preset format, generates and returns a data error status code to the running environment, and ends.
  • Step 103 Continue to receive the data sent by the RE to obtain complete APDU data, and prepare to load the application according to the APDU data.
  • the APDU data in step 103 is a for_Load command
  • the loading of the application according to the APDU data includes: parsing the for_Load command, obtaining the loading file identifier and the associated file security domain identifier, creating a loading file structure, and populating the parsed loading file identifier and the loading file association domain identifier into the created In the load file structure, if the above operation succeeds, the success status code and the return result are generated and returned to the running environment, and if the above operation is unsuccessful, the corresponding status code is generated and returned to the running environment according to the failure reason. End. Step 104: Continue to receive data sent by the RE to obtain complete APDU data, and load an application according to the APDU data.
  • the APDU data in the step 104 is a Load command; loading the application according to the APDU data specifically includes: parsing a Load command, obtaining a load file data block, and acquiring component data according to the load file data block. And storing, filling the storage address into the loading file structure, if the above succeeds, generating and returning the success status code and returning the result to the running environment, ending, if the above operation is unsuccessful, generating according to the failure reason And return the corresponding status code to the operating environment, and finish.
  • Step 105 Continue to receive data sent by the RE to obtain complete APDU data, and install an application according to the APDU data.
  • the APDU data in step 105 is a for_Install command
  • the installation of the application according to the APDU data specifically includes: parsing the for_Install command, obtaining an executable load file identifier, an executable module identifier, an application identifier, and an application permission, and searching for the load file structure according to the parsed executable load file identifier, and finding the An executable module corresponding to the executable module identifier obtained by parsing the parsed executable module in the storage space corresponding to the storage address in the file structure, creating an application of the found executable module, and creating the application by using the parsed application identifier identifier, and Giving the created application the right specified by the parsed application permission, and setting the associated security domain of the created application to the associated security domain of the executable load file corresponding to the parsed executable load file identifier, if the above operation If successful, the success status code and the return result are generated and returned to the running environment. If the above operation is unsuccessful, the corresponding status code is generated and returned to the running environment according to the failure reason, and the process ends.
  • Step 106 Continue to receive data sent by the RE to obtain complete APDU data, and set an application state according to the APDU data.
  • the APDU data in step 106 is a for_Makeselectable command
  • Setting the application state according to the APDU data specifically includes:
  • the for_Makeselectable command obtains the application identifier and the application permission, searches for an application corresponding to the parsed application identifier in the card, updates the status of the found application to a selectable state, and updates the searched application's permission to the parsed application.
  • the permission specified by the permission if the above operation succeeds, generates and returns the success status code and returns the result to the running environment, and ends. If the above operation is unsuccessful, the corresponding status code is generated and returned to the running environment according to the failure reason. , End.
  • Step 107 Continue to receive data sent by the RE to obtain complete APDU data, and update an associated security domain of the application according to the APDU data.
  • the associated security domain of the application provides a service such as a key for the application
  • the APDU data in step 107 is a for_Extradition command
  • Updating the associated security domain of the application according to the APDU data specifically includes: parsing the for_Extradition command, obtaining the security domain identifier and the application identifier, and searching for the application corresponding to the parsed application identifier in the card and corresponding to the parsed security domain identifier
  • the application updates the associated security domain of the application corresponding to the parsed application identifier to an application corresponding to the parsed security domain identifier, and if the above succeeds, generates and returns a success status code and Return the result to the running environment, and end. If the above operation is unsuccessful, generate and return the corresponding status code to the running environment according to the failure reason, and the process ends.
  • Step 108 Continue to receive data sent by the RE to obtain complete APDU data, and personalize the application according to the APDU data.
  • the APDU data in step 108 is a for-Personalized command
  • the personalization application according to the APDU data specifically includes: parsing the for_Personalized command, obtaining an application identifier, searching for an application corresponding to the parsed application identifier in the card, and setting the found application as a personalized application, if the above operation succeeds Generate and return the success status code and return the result to the running environment, and end. If the above operation is unsuccessful, generate and return the corresponding status code to the running environment according to the failure reason, and the process ends.
  • Step 109 Continue to receive the data sent by the RE to obtain complete APDU data, and delete the application and the executable loading file according to the APD U data.
  • the APDU data in the step 109 is a Delete command.
  • the deleting the application and the executable loading file according to the APDU data specifically includes: parsing a Delete command, obtaining a data domain identifier, and searching and parsing in the card.
  • the data field identifies the corresponding application and the executable load file, deletes the found application and the executable load file, and if the above operation succeeds, generates and returns the success status code and returns the result to the running environment, ending, if If the operation is unsuccessful, the corresponding status code is generated and returned to the running environment according to the failure reason, and the process ends.
  • the return result is 0x00
  • the failure reason includes: the processing condition is not satisfied and the data error occurs, and when the failure reason is that the processing condition is not satisfied, the generation and return condition does not satisfy the status code.
  • RE a data error status code is generated and returned to the RE when the cause of the failure is a data error.
  • the second embodiment of the present invention provides a specific method for preparing an application for loading an application in a method for managing a card provided in the first embodiment.
  • the APDU data in this embodiment is the complete APDU data obtained in step 103, and the data field portion thereof may be It is considered to be composed of a plurality of data blocks, each of which is an LV structure, that is, a structure of data length + data; see FIG. 2, the method specifically includes:
  • Step 201 Determine whether the first data block of the APDU data is legal, if yes, execute step 202, otherwise the data is incorrect, and the operation fails;
  • the first data block is specifically: loading file identifier length + loading file identifier;
  • Determining whether the first data block of the APDU data is legal or not includes: determining whether the length of the load file identifier in the first data block of the APDU data is within a preset range, and checking the first of the APDU data Each byte of the load file identifier in the data block, if both are 0x00, the first data block is invalid, if not all 0x00, then the first The data block is legal, otherwise the first data block is illegal;
  • the preset range is 0x05-0x10.
  • Step 202 Check whether there is an executable file corresponding to the loaded file identifier in the card, if the processing condition is not satisfied, the operation fails, otherwise step 203 is performed;
  • Step 203 Check whether the second data block of the APDU data meets the preset requirement. If the first preset requirement is met, step 204 is performed. If the second preset requirement is met, step 205 is performed, if the preset requirement is not met. The data is wrong, and the failure is made;
  • the second data block is specifically: a file association security domain identifier length + a load file association security domain identifier;
  • Checking whether the second data block of the APDU data meets the preset requirement specifically includes: determining whether the length of the load file associated security domain identifier in the second data block of the APDU data is 0x00, and the APDU data is The second data block satisfies the first preset requirement, and otherwise checks each byte of the load file associated security domain identifier in the second data block of the APDU data, and if both are 0x00, the APDU data is second. The data block does not meet the preset requirement, and if not all 0x00, the second data block of the APDU data satisfies the second preset requirement;
  • Step 204 Set the associated security domain of the load file to the card content management module, and perform step 208;
  • the load file is a load file corresponding to the load file identifier in the first data block of the APDU data.
  • Step 205 Check whether there is an application corresponding to the security domain identifier associated with the loaded file in the card, and then execute step 206, otherwise the processing condition is not satisfied, and the operation fails;
  • Step 206 Check whether the application corresponding to the security domain identifier associated with the load file has the security domain authority. If yes, execute step 207. Otherwise, the processing condition is not satisfied, and the operation fails. Specifically, it is determined whether the security is determined by the application permission attribute. Domain permission, the application permission attribute is a byte of data, from the high position to the status, b8 b7 b6 b5 b4 b3 b2 bl, check whether the application corresponding to the security domain identifier associated with the load file has security domain permissions, specifically for checking and loading files. The permission attribute of the application corresponding to the associated security domain identifier B8, if it is 1, the application corresponding to the security domain identifier associated with the load file has the security domain authority. If not 1, the application corresponding to the security domain identifier associated with the load file does not have the security domain authority.
  • Domain permission the application permission attribute is a byte of data, from the high position to the status, b8 b7 b6 b5
  • Step 207 Set an associated security domain of the loaded file to be an application corresponding to the security domain identifier associated with the loaded file.
  • Step 208 Determine whether the third data block of the APDU data is legal. If yes, go to step 209. Otherwise, the data is incorrect and fails.
  • the third data block is specifically: loading a file data block hash value length + loading a file data block hash value;
  • Determining whether the third data block of the APDU data is legal or not includes: determining whether the length of the load file data block hash value in the third data block of the APDU data is 0x00, and the third of the APDU data is The data block is invalid, otherwise the third data block of the APDU data is legal.
  • Step 209 Store a load file data block hash value
  • Step 210 Process a fourth data block of the APDU data.
  • the fourth data block is specifically: a loading parameter field length + a loading parameter field
  • the loading parameter field is 1 TLV structure data block (Tn, Ln, Vn)
  • the Vn is composed of 3 TLV structures.
  • the data block (Tn ', Ln ', Vn ') is composed.
  • step 210 specifically includes:
  • Step 210-1 Determine whether the length of the loading parameter field is 0x00, if yes, go to step 211, otherwise go to step 210-2;
  • Step 210-2 It is judged whether Tn is 0xEF, if yes, step 210-3 is performed, otherwise the data is incorrect, and the operation fails;
  • Step 210-3 Obtain a TLV structure data block of the Vn, and determine whether the Tn' of the TLV structure data block is legal. If yes, execute step 210-4. Otherwise, the data is incorrect, and the operation fails.
  • Step 210-5 Check Tn ' of the TLV structure data block, if it is 0xC6, according to the The Vn of the TLV structure data block acquires and stores the non-volatile code space quota, and performs step 210-6. If it is 0xC7, the volatile data space quota is acquired and stored according to the Vn' of the TLV structure data block, and step 210 is performed. -6, if 0xC8, according to the Vn ' of the TLV structure data block to obtain and store the non-volatile data space limit, step 210-6;
  • Step 210-6 determining whether there is still an unprocessed TLV structure data block, if yes, returning to step 210-3, otherwise performing step 210-7;
  • Step 210-7 Determine whether the non-volatile storage space and the volatile storage space in the card can meet the above quota. If yes, execute step 211. Otherwise, the processing condition is not satisfied, and the operation fails.
  • Step 211 Determine whether the fifth data block of the APDU data is legal. If yes, execute step 212. Otherwise, the data is incorrect and fails.
  • the fifth data block is specifically: loading the token length + loading the token; determining whether the fifth data block of the APDU data is legal or not specifically includes: determining the fifth data block of the APDU data Whether the length of the loaded token is 0x00, the fifth data block of the APDU data is legal, otherwise the data block of the APDU data is invalid.
  • Step 212 Create a load file structure, fill the load file identifier and the load file association security domain identifier into the created load file structure, and initialize the global block number in the card, and succeed.
  • the third embodiment of the present invention provides a specific method for loading an application in a method for managing an application on a card provided in the first embodiment.
  • the method specifically includes:
  • Step 301 Determine whether the fourth byte of the APDU data is equal to the global block number in the card, if yes, go to step 302. Otherwise, the data is incorrect and fails.
  • Step 302 Check whether the APDU data includes DAP (Data Authentication Pattern) block information, if yes, go to step 303, otherwise go to step 304;
  • Step 303 Verify the DAP block information, if the verification is passed, execute step 304, otherwise the data is incorrect, and the operation fails;
  • DAP Data Authentication Pattern
  • Step 304 Acquire component data according to the load file data block in the APDU data, store the storage address, and fill the storage address into the load file structure.
  • the loading file is divided into a plurality of loading file data blocks outside the card, and each time a loading file data block is encapsulated into an APDU data and sent to the card, and the RE sends the APDU data received by the card to the card content management module.
  • the card content management module processes the load file data block in each APDU data in units of components, and the components include: a Header component, a Directory component, an Applet component, an Import component, and the like.
  • Step 305 Update the global block number in the card
  • the global block number in the update card is specifically the global block number in the update card plus its current value plus one.
  • Step 306 Determine whether the load file data block is the last load file data block of the load file, if yes, execute step 307, otherwise the operation is successful;
  • determining whether the load file data block is the last load file data block of the load file specifically includes: determining whether the value of the third byte of the APDU data is 0x80, and the loading file data is The block is the last loaded file data block of the loaded file, otherwise the loaded file data block is not the last loaded file data block of the loaded file, and the loaded file has other data blocks.
  • Step 307 Determine whether the load file data block hash value in the card has a value, if yes, go to step 308, otherwise go to step 310;
  • Step 308 Hash all the loaded file data blocks stored in the card as a whole;
  • Step 309 Determine whether the calculation result is equal to the hash value of the load file data block stored in the card, if yes, execute step 310, otherwise the data is incorrect, and the operation fails;
  • Step 310 Store and submit the executable load file structure, and succeed.
  • the submitting is specifically writing data from the cache to the permanent storage area.
  • the fourth embodiment of the present invention provides a specific method for installing an application in a method for managing an application on a card provided in the first embodiment.
  • the data field portion of the APDU data in this embodiment may be regarded as being composed of multiple data blocks.
  • Each data block is an LV structure, that is, a structure of data length + data; see FIG. 4, the method specifically includes:
  • Step 401 Determine whether the first data block of the APDU data is legal, if yes, execute step 402, otherwise the data is incorrect, and the operation fails;
  • the first data block is specifically: an executable load file identifier length + an executable load file identifier;
  • Determining whether the first data block of the APDU data is legal or not includes: determining whether the length of the executable load file identifier in the first data block of the APDU data is within a preset range, and determining the length of the APDU data One data block is legal, otherwise the first data block of the APDU data is invalid;
  • the preset range is: 0x05-0x10.
  • Step 402 Check whether there is a loading file structure corresponding to the executable loading file identifier in the card. If yes, execute step 403. Otherwise, the processing condition is not satisfied, and the operation fails.
  • Step 403 Determine the second data of the APDU data. If the block is legal, if yes, go to step 404. Otherwise, the data is incorrect and the operation fails.
  • the second data block is specifically: an executable module identifier length + an executable module identifier
  • Determining whether the second data block of the APDU data is legal or not includes: determining whether the length of the executable module identifier in the second data block of the APD U data is within a preset range, and determining the length of the APDU data Two data blocks are legal, otherwise the second data block of the APDU data is invalid;
  • the preset range is 0x05-0x10.
  • Step 404 Check whether there is an executable module corresponding to the executable module identifier in the storage space corresponding to the storage address in the load file structure. If yes, execute step 405. Otherwise, the processing condition is not satisfied, and the operation fails; Step 405: Determine whether the third data block of the APDU data is legal. If yes, execute step 406. Otherwise, the data is incorrect and fails.
  • the third data block is specifically: an application identifier length + an application identifier; determining whether the third data block of the APDU data is legal or not specifically includes: determining an application in the third data block of the APDU data Whether the length of the identifier is within a preset range, and then checking each byte of the application identifier in the third data block of the APDU data, if all are 0x00, the third data block of the APDU data is invalid. If not all 0x00, the third data block of the APDU data is legal, otherwise the third data block of the APDU data is invalid;
  • the preset range is 0x05-0x10.
  • Step 406 Check whether there is an application corresponding to the application identifier in the card, if yes, execute step 407; otherwise, the processing condition is not satisfied, and the operation fails;
  • Step 407 Determine whether the fourth data block of the APDU data is legal. If yes, go to step 408. Otherwise, the data is incorrect and fails.
  • Step 408 Determine whether the currently installed application has the default selection authority, if yes, go to step 409, otherwise go to step 411;
  • the application that is installed in this time is specifically an application corresponding to the application identifier in the third data block; determining whether the currently installed application has the default selection authority specifically includes: determining the fourth of the APDU data. Whether the application permission in the data block is 0x04, the application installed this time has the default selection permission, otherwise the application installed this time does not have the default selection permission.
  • Step 409 Determine whether the third byte of the APDU data is a preset value, if the data is wrong, the operation fails; otherwise, step 410 is performed; In this embodiment, the preset value is 0x04.
  • Step 410 Determine whether the card content management module has a default selection permission, if yes, execute step 413; otherwise, the processing condition is not satisfied, and the operation fails;
  • the card content management module determines whether the card content management module has a default selection authority by using the permission attribute of the card content management module, and the permission attribute of the card content management module is one byte of data, and the order from the high position to the status is b8 b7 b6 b5 b4 b3 b2 bl ;
  • Determining whether the card content management module has the default selection authority specifically includes: determining whether the b3 of the license attribute of the card content management module is 1, and the card content management module has the default selection authority; otherwise, the card content management module does not have the default selection authority.
  • Step 411 Determine whether the application permission meets the preset condition. If the first preset condition or the second preset condition is met, step 412 is performed. If the preset condition is not met, the processing condition is not satisfied, and the operation fails;
  • determining whether the application permission meets the preset condition specifically includes: checking the application permission, if the application permission is from the lower end, the first bit, the sixth bit, and the seventh bit are both 0, the eighth bit If the application permission is equal to the first preset condition; if the first bit, the sixth bit, and the seventh bit of the application permission are not all 0 from the lower end, the application permission satisfies the second preset condition, otherwise the application is applied. The permission does not meet the preset conditions;
  • Step 412 Process the installation parameter field in the fifth data block of the APDU data, and perform step 413;
  • the fifth data block is specifically: an installation parameter field length + an installation parameter field, where the installation parameter field is composed of data of one or more TLV structure data blocks (Tn, Ln, Vn).
  • the Vn is composed of 0 or a plurality of TLV structure data blocks (Tn ', Ln ', Vn ').
  • the step 412 specifically includes:
  • Step 412-1 Determine whether the length of the installation parameter field is 0x00, if yes, go to step 413, otherwise go to step 412-2;
  • Step 412-2 Obtain a TLV structure data block of the installation parameter field, and check Tn of the TLV structure data block. If it is 0xC9, go to step 412-3. If it is OxEF, go to step 412-4. Otherwise, the data is incorrect. Failure to do so; Step 412-3: storing the Vn of the TLV structure data block, performing step 412-9;
  • Step 412-4 Obtain a TLV structure data block of Vn of the TLV structure data block, and determine whether Tn ' is legal. If yes, execute step 412-5. Otherwise, the data is incorrect, and the operation fails. Step 412-5: Determine Ln ' If it is 0x02, if yes, go to step 412-6. Otherwise, the data is wrong and the operation fails.
  • Step 412-6 Check Tn ', if 0xC7, obtain and store the volatile data space quota according to Vn ', perform step 412-7, if 0xC8, obtain and store the non-volatile data space quota according to Vn ', Perform step 412-7;
  • Step 412-7 determining whether there is an unprocessed TLV structure data block in the TLV structure data block, if yes, returning to step 412-4, otherwise performing step 412-8;
  • Step 412-8 Determine whether the non-volatile storage space and the volatile storage space in the card can meet the above quota, if yes, execute step 412-9; otherwise, the processing condition is not satisfied, and the operation fails;
  • Step 412-9 Determine whether there is an unprocessed TLV structure data block in the installation parameter field, if yes, go back to step 412-2, otherwise go to step 413.
  • Step 413 Determine whether the sixth data block of the APDU data is legal, if yes, execute step 414; otherwise, the data is incorrect, and the operation fails;
  • the sixth data block is specifically the installation token length + the installation token; determining whether the sixth data block of the APDU data is legal or not specifically includes: determining the sixth data block of the APDU data If the length of the installation token is 0x00, the sixth data block of the APDU data is legal, otherwise the sixth data block of the APDU data is invalid.
  • Step 414 Register an application according to the application identifier in the data field of the APDU data.
  • step 414 is specifically: creating and storing an instance of an executable module corresponding to the executable module identifier in the APDU data.
  • the instance is uniquely associated with the application identifier in the APDU data, and the state of the instance is set to an initial value, the permission of the instance is set according to the application permission in the APDU data, and the associated security domain of the instance is set to The executable load file identifier in the APDU data corresponds to the Execute the associated security domain of the loaded file.
  • Step 415 Determine whether the third byte of the APD U data is equal to the preset value, if yes, go to step 419; otherwise, go to step 416;
  • the preset value is 0x04.
  • Step 416 Set the state of the installed application to SELECTABLE (optional);
  • the step 416 is specifically: setting the state attribute of the installed application to 0x07.
  • Step 417 Determine whether the installed application has the default selection authority, and then execute step 418, otherwise the operation succeeds;
  • Step 418 Set the application to be installed as the default application, and succeed;
  • Step 419 Set the state of the installed application to INSTALLED (installation), and succeed.
  • the step 419 is specifically: setting the state attribute of the installed application to 0x03.
  • the fifth embodiment of the present invention provides a specific method for setting an application state in a method for managing an application on a card provided in the first embodiment.
  • the data domain portion of the APDU data in this embodiment may be regarded as being composed of multiple data blocks.
  • Each data block is an LV structure, that is, a structure of data length + data; see FIG. 5, the method specifically includes:
  • Step 501 Determine whether the first data block and the second data block of the APDU data are both legal. If yes, go to step 502. Otherwise, the data is incorrect and fails.
  • determining whether the first data block of the APDU data is legal or not includes: determining whether the first data block of the APDU data is 0x00, and the first data block of the APDU data is legal. Otherwise, the first data block of the APDU data is invalid;
  • Determining whether the second data block of the APDU data is legal or not includes: Whether the second data block of the APDU data is 0x00, if the second data block of the APDU data is legal, otherwise the second data block of the APDU data is invalid.
  • Step 502 Determine whether the third data block of the APDU data is legal. If yes, go to step 503. Otherwise, the data is incorrect and fails.
  • the third data block is specifically: an application identifier length + an application identifier; determining whether the third data block of the APDU data is legal or not specifically includes: determining an application in the third data block of the APDU data Whether the length of the identifier is within a preset range, and the third data block of the APDU data is legal, otherwise the third data block of the APDU data is invalid;
  • the preset range is 0x05-0x10.
  • Step 503 Check whether there is an application corresponding to the application identifier in the card, if yes, execute step 504; otherwise, the processing condition is not satisfied, and the operation fails;
  • Step 504 Determine whether the status of the application corresponding to the application identifier is INSTALLED, if yes, execute step 505, otherwise, the processing condition is not satisfied, and the operation fails;
  • Step 505 Determine whether the fourth data block of the APDU data is legal. If yes, go to step 506. Otherwise, the data is incorrect and the operation fails.
  • the fourth data block is specifically the application permission length + the application authority; determining whether the fourth data block of the APDU data is legal or not includes: determining the application permission in the fourth data block of the APDU data If the length is 0x01, then the fourth data block of the APDU data is legal, otherwise the fourth data block of the APDU data is invalid.
  • Step 506 Determine whether the fifth data block of the APDU data is legal. If yes, go to step 507. Otherwise, the data is incorrect and fails.
  • the fifth data block is specifically a parameter domain length + a parameter field.
  • the determining whether the fifth data block of the APDU data is legal or not includes: determining a parameter domain in the fifth data block of the APDU data. Whether the length is 0x00, yes, then
  • Step 507 Determine whether the sixth data block of the APDU data is legal, if yes, execute step 508; otherwise, the data is incorrect, and the operation fails;
  • the sixth data block is specifically: a selectable token length + a selectable token
  • Determining whether the sixth data block of the APDU data is legal or not includes: determining whether the selectable token length in the sixth data block of the APDU data is 0x00, and the sixth data block of the APDU data is Legal, otherwise the sixth data block of the APDU data is invalid.
  • Step 508 Set the status of the application corresponding to the application identifier to SELECTABLE
  • step 508 specifically sets the state attribute of the application corresponding to the application identifier to 0x07.
  • Step 509 Determine whether the application corresponding to the application identifier has a default selection permission, if yes, execute step 510, otherwise the operation succeeds;
  • Step 510 Determine whether the card content management module has a default selection permission, if yes, execute step 511, otherwise the processing condition is not satisfied, and the operation fails;
  • the card content management module determines whether the card content management module has a default selection authority by using the permission attribute of the card content management module, and the permission attribute of the card content management module is one byte of data, and the order from the high position to the status is b8 b7 b6 b5 b4 b3 b2 bl ;
  • Determining whether the card content management module has the default selection authority specifically includes: determining whether the b3 of the license attribute of the card content management module is 1, and the card content management module has the default selection authority; otherwise, the card content management module does not have the default selection authority.
  • Step 511 The application corresponding to the application identifier is set as the default application, and the operation is successful.
  • the sixth embodiment of the present invention provides a specific method for updating an associated security domain of an application in a method for managing applications on a card provided in the first embodiment.
  • the data domain portion of the APDU data in this embodiment may be regarded as multiple data. Composed of blocks, each block is one LV structure, that is, data length + data structure; Referring to FIG. 6, the method specifically includes: Step 601: Determine whether the first data block of the APDU data is legal, if yes, execute step 602, otherwise the data error occurs. failure;
  • the first data block is specifically: a security domain identifier length + a security domain identifier
  • Determining whether the first data block of the APDU data is legal or not includes: determining whether the length of the security domain identifier in the first data block of the APDU data is within a preset range, and the first of the APDU data is The data block is legal, otherwise the first data block of the APDU data is invalid;
  • the preset range is 0x05-0x10.
  • Step 602 Check whether there is an application corresponding to the security domain identifier in the card, and then execute step 603. Otherwise, the processing condition is not satisfied, and the operation fails;
  • Step 603 Determine whether the application corresponding to the security domain identifier is a card content management module, if the processing condition is not satisfied, the operation fails, otherwise step 604 is performed;
  • Step 604 Determine whether the second data block of the APDU data is legal. If yes, go to step 605. Otherwise, the data is incorrect and the operation fails.
  • determining whether the second data block of the APDU data is legal or not includes: determining whether the second data block of the APDU data is 0x00, and the second data block of the APDU data is legal. Otherwise, the second data block of the APDU data is invalid.
  • Step 605 Determine whether the status of the application corresponding to the security domain identifier is INSTALLED, if yes, execute step 606, otherwise the processing condition is not satisfied, and the operation fails;
  • Step 606 Determine whether the third data block of the APDU data is legal. If yes, go to step 607. Otherwise, the data is incorrect and the operation fails.
  • the third data block is specifically: an application identifier length + an application identifier; determining whether the third data block of the APDU data is legal or not specifically includes: determining an application in the third data block of the APDU data Whether the identifier length is within a preset range, and the third data block of the APDU data is legal, otherwise the APDU data is Three data blocks are illegal;
  • the preset range is 0x05-0x10.
  • Step 607 Check whether there is an application corresponding to the application identifier in the card, if yes, execute step 608; otherwise, the processing condition is not satisfied, and the operation fails;
  • Step 608 Determine whether the application corresponding to the security domain identifier has security domain authority, if yes, execute step 609; otherwise, the processing condition is not satisfied, and the operation fails;
  • the step 608 specifically includes: determining whether the highest bit of the privilege attribute of the application corresponding to the security domain identifier is 1, and the application corresponding to the security domain identifier has the security domain privilege; otherwise, the application corresponding to the security domain identifier Does not have security domain permissions.
  • Step 609 Determine whether the status of the application corresponding to the security domain identifier is LOCKED. If the condition is not satisfied, the operation fails. Otherwise, step 610 is performed. Step 610: Determine the status of the application corresponding to the security domain identifier. If it is PERSONALIZED (personalized), if yes, go to step 611. Otherwise, the processing condition is not satisfied, and the operation fails.
  • PERSONALIZED personalized
  • Step 611 Determine whether the fourth data block and the fifth data block of the APDU data are both legal. If yes, go to step 612. Otherwise, the data is incorrect and fails.
  • determining whether the fourth data block of the APDU data is legal or not includes: determining whether the fourth data block of the APDU data is 0x00, and the fourth data block of the APDU data is legal. Otherwise, the fourth data block of the APDU data is invalid;
  • Determining whether the fifth data block of the APDU data is legal or not includes: determining whether the fifth data block of the APDU data is 0x00, and then the fifth data block of the APDU data is legal, otherwise the APDU data The fifth data block is illegal.
  • Step 612 Determine whether the sixth data block of the APDU data is legal. If yes, go to step 613. Otherwise, the data is incorrect and fails.
  • the sixth data block is specifically: an extradition token length + an extrapolation token; determining whether the sixth data block of the APDU data is legal or not specifically includes: determining a sixth data block of the APDU data Whether the length of the extradition token is 0x00, is the The sixth data block of the APDU data is legal, otherwise the sixth data block of the APDU data is invalid.
  • Step 613 Determine whether the application corresponding to the application identifier has the security domain authority, if the processing condition is not satisfied, the operation fails; otherwise, step 614 is performed;
  • the step 613 specifically includes: determining whether the highest bit of the permission attribute of the application corresponding to the application identifier is 1 or not, and the application corresponding to the application identifier has the security domain authority; otherwise, the application corresponding to the application identifier is not secure. Domain permissions.
  • Step 614 Set the associated security domain of the application corresponding to the application identifier to be the application corresponding to the security domain identifier, and succeed.
  • Example 7
  • the seventh embodiment of the present invention provides a specific method for managing a personalized application in a method for managing a card provided in the first embodiment.
  • the data field portion of the APDU data in this embodiment may be regarded as being composed of multiple data blocks.
  • Each data block is an LV structure, that is, a data length + a structure of data; see FIG. 7, the method specifically includes:
  • Step 701 Determine whether the first data block and the second data block of the APDU data are both legal. If yes, go to step 702. Otherwise, the data is incorrect and fails.
  • determining whether the first data block of the APDU data is legal or not includes: determining whether the first data block of the APDU data is 0x00, and the first data block of the APDU data is legal. Otherwise, the first data block of the APDU data is invalid;
  • Determining whether the second data block of the APDU data is legal or not includes: determining whether the second data block of the APDU data is 0x00, and then the second data block of the APDU data is legal, otherwise the APDU data The second data block is illegal.
  • Step 702 Determine whether the third data block of the APDU data is legal. If yes, go to step 703. Otherwise, the data is incorrect and fails.
  • the third data block is specifically an application identifier length + an application identifier; determining whether the third data block of the APDU data is legal or not includes: Whether the application identifier length in the third data block of the APDU data is within a preset range, and the third data block of the APDU data is legal, otherwise the third data block of the APDU data is invalid;
  • the preset range is 0x05-0x10.
  • Step 703 Check whether there is an application corresponding to the application identifier in the card, and if yes, execute step 704. Otherwise, the processing condition is not satisfied, and the operation fails;
  • Step 704 Determine whether the associated security domain of the application corresponding to the application identifier is a card content management module. If yes, execute step 705. Otherwise, the processing condition is not satisfied, and the operation fails.
  • Step 705 Determine the fourth of the APDU data. Whether the data block, the fifth data block, and the sixth data block are both legal, if yes, step 706 is performed; otherwise, the data is incorrect, and the operation fails;
  • determining whether the fourth data block of the APDU data is legal or not includes: determining whether the fourth data block of the APDU data is 0x00, and the fourth data block of the APDU data is legal. Otherwise, the fourth data block of the APDU data is invalid;
  • Determining whether the fifth data block of the APDU data is legal or not includes: determining whether the fifth data block of the APDU data is 0x00, and then the fifth data block of the APDU data is legal, otherwise the APDU data The fifth data block is illegal;
  • Determining whether the sixth data block of the APDU data is legal or not includes: determining whether the sixth data block of the APDU data is 0x00, and the sixth data block of the APDU data is legal, otherwise the APDU data is The sixth data block is illegal.
  • Step 706 Set the state of the application corresponding to the application identifier to PERSONLIZED, and succeed.
  • the eighth embodiment of the present invention provides a specific method for deleting an application and an executable load file in the method for managing an application on a card provided in the first embodiment.
  • the data field portion of the APDU data in this embodiment may be regarded as multiple Composed of data blocks, each data block is one The LV structure, that is, the data length + the structure of the data;
  • the method specifically includes: Step 801: Determine whether the first data block of the APDU data is legal, if yes, execute step 802, otherwise the data is incorrect, Failed;
  • determining whether the first data block of the APDU data is legal or not includes: determining whether the first data block of the APDU data is 0x4f,
  • the first data block of the APDU data is legal, otherwise the first data block of the APDU data is invalid.
  • Step 802 Determine whether the second data block of the APDU data is legal. If yes, go to step 803. Otherwise, the data is incorrect.
  • the preset range is: 0x05-0x10.
  • Step 803 Check whether there is an application corresponding to the data domain identifier in the card, if yes, go to step 804, otherwise go to step 805;
  • Step 804 Determine whether the fourth byte of the APD U data is equal to the preset value, if yes, go to step 805, otherwise go to step 809;
  • the preset value is 0x80.
  • Step 805 Check whether there is an executable loading file corresponding to the data domain identifier in the card. If yes, go to step 806. Otherwise, the processing condition is not satisfied, and the operation fails.
  • Step 806 Determine whether the fourth byte of the APDU data is equal to a preset value, if yes, go to step 807, otherwise go to step 808;
  • the preset value is 0x80.
  • Step 807 Deleting an application corresponding to the data domain identifier and an executable loading file corresponding to the data domain identifier, and succeeding;
  • Step 808 deleting the executable loading file corresponding to the data domain identifier, and succeeding;
  • Step 809 Check whether the application corresponding to the data domain identifier is an associated security domain of another application or other executable load file, if the processing condition is not satisfied, the operation fails; otherwise, step 810 is performed;
  • Step 810 Determine whether the application corresponding to the data domain identifier is a card content management module, if the processing condition is not satisfied, the operation fails; otherwise, step 811 is performed;
  • Step 811 The application corresponding to the data domain identifier is deleted, and the operation succeeds.
  • the smart card is simply referred to as a card.
  • a method for implementing management card data is provided by the embodiment of the present invention.
  • the method specifically includes: when the first card data management module receives the APDU (Application Protocol Data Unit) data sent by the operating environment, As the current first card data management module, perform the following steps:
  • APDU Application Protocol Data Unit
  • Step 901 Check the INS (instruction code) of the APDU data, if it is 0xE8, execute step 1101 to step 1129; if it is 0xE6, execute step 902; if it is 0xE4, execute step 1601 to step 1625; if it is other valid values
  • the APDU data is another valid command that is not content management, and performs corresponding operations according to the APDU data; otherwise, the APDU data is an invalid command, and generates and returns a corresponding status code;
  • the other valid values include: 0xA4, 0x78, 0x7 A, 0x82, 0x50, 0xE2, 0xF0, 0xD8, 0xF2, OxCA;
  • Step 902 Check the PI (first parameter) of the APDU data, if it is 0x02, perform step 1001 to step 1028; if it is 0x04 or OxOC, perform step 1201 to step 1235; if it is 0x08, perform step 1301 to step 1324. If it is 0x10, step 1401 to step 1428 is performed; if it is 0x20, step 1501 to step 1517 is performed; otherwise, the APDU data is an invalid command, and a corresponding status code is generated and returned;
  • the first card data management module is a special application in the card, and is a representative of the application provider on the card;
  • steps 1001 to 1028 are specifically as follows: Step 1001: Determine whether the APDU data is a command header of a legal preload command, if yes, go to step 1002, otherwise go to step 1027;
  • the APDU data is a legal preload command.
  • Command header 0x80 or 0x84
  • P2 second parameter
  • Lc data field length
  • Step 1002 Determine whether the current state of the card is TERMINATED or CARD_LOCKED. If yes, go to step 1027. Otherwise, go to step 1003. Specifically, determine the status of the card by its status attribute.
  • the status attribute of the card is one word.
  • the data of the section, from high to low, is 138137136135134133132131, and the status of the card includes preparation OP_READY, initialization INITIALIZED, safety SECURED, lock CARD_LOCKED and termination TERMINATED, see the following table:
  • step 1001 and step 1002 may be reversed: first, it is determined whether the current state of the card is termination or card locking, and if yes, step 1027 is performed; otherwise, it is determined whether the APDU data is a legal preload command command header, Then step 1003 is performed, otherwise step 1027 is performed;
  • Step 1003 Receive the data field part of the preload command to obtain a complete preload command;
  • Step 1004 Determine whether the current state of the first card data management module is PERSONALIZED, if yes, go to step 1005, otherwise go to step 1027;
  • the first card data management module determines the status of the current first card data management module by using the status attribute of the current first card data management module, and the status attribute of the first card data management module is one byte of data, from high to low.
  • the status of the first card data management module includes INSTALLED installed, SELECTABLE selectable, personalized PERSONALIZED and lock LOCKED, see the following table:
  • Step 1005 Determine whether the current first card data management module has proxy authority, if yes, go to step 1006, otherwise go to step 1027;
  • the first card data management module determines whether the current first card data management module has proxy authority by using the permission attribute of the current first card data management module, and the permission attribute of the first card data management module is one byte data, from a high position
  • the lower order is b8b7b6b5b4b3b2bl, and when both b8 and b6 are 1, the first card data management module has proxy authority;
  • Step 1006 Determine whether the card meets the security condition, if yes, go to step 1007, otherwise go to step 1027;
  • the first card data management module determines whether the card satisfies the security condition by checking the security flag of the card. If the security flag is set, the card satisfies the security condition, and if the security flag is not set, the card does not satisfy the security condition.
  • the security flag is set when the card correctly executes the legal command with the INS byte value of 0x50 and the legal command with the INS byte value of 0x82.
  • Step 1007 Check the security level of the card, if it is the first level, go to step 1010, if it is the second level, go to step 1008, if it is the third level, go to step 1009;
  • the preloading command is the plaintext of the message data
  • the preloading command is the message data plaintext and the message authentication code (Message) Combination of Authentication Code (MAC)
  • MAC message authentication code
  • Step 1008 Determine, according to the message data plaintext and MAC (message authentication code) in the preloading command, whether the preloading command is complete, if yes, go to step 1010, otherwise go to step 1027;
  • MAC message authentication code
  • the determining, according to the message data plaintext and the message authentication code in the preloading command, whether the preloading command is complete or not includes: decrypting the message authentication code by using the agreed session key to obtain a decryption result, and according to the agreement
  • the hash function calculates the plaintext of the message data to obtain a calculation result, and determines whether the decryption result is the same as the calculation result, and the preloading command is complete, otherwise the preloading command is incomplete;
  • Step 1009 Determine whether the preloading command is complete according to the message data ciphertext and the MAC in the preloading command, if yes, execute step 1010, otherwise perform step 1027; wherein the message according to the preloading command is performed.
  • the data ciphertext and the message authentication code determine whether the preloading command is complete or not, including: decrypting the message data ciphertext to obtain the message data plaintext, decrypting the message authentication code by using the agreed session key, and obtaining the decrypted result, and simultaneously dispersing according to the agreement
  • the column function calculates the plaintext of the message data to obtain a calculation result, and determines whether the decryption result is the same as the calculation result, and the preloading command is complete, otherwise the preloading command is incomplete;
  • Step 1010 Determine whether the length of the load file identifier in the preload command is within the preset range, if yes, go to step 1011, otherwise go to step 1027;
  • Step 1011 Determine whether the load file identifier in the preload command is legal, if yes, go to step 1012, otherwise go to step 1027;
  • the loading file identifier is invalid when each byte thereof is 0x00, otherwise legal;
  • Step 1012 Check whether the loading file corresponding to the loading file identifier already exists in the card. If yes, go to step 1027. Otherwise, go to step 1013.
  • Step 1013 Determine whether the length of the security domain identifier in the preload command is within a preset range. If yes, go to step 1014. Otherwise, go to step 1027.
  • the preset range is 0x05-0x10;
  • Step 1014 Determine whether the security domain identifier in the preload command is legal. If yes, go to step 1015. Otherwise, go to step 1027.
  • the security domain identifier is invalid when each byte is 0x00, otherwise it is legal;
  • Step 1015 Check whether there is an application corresponding to the security domain identifier in the preloading command in the card, if yes, go to step 1016; otherwise, go to step 1027;
  • Step 1016 Determine whether the application corresponding to the security domain identifier in the preloading command has the security domain authority. If yes, go to step 1017. Otherwise, go to step 1027.
  • the privilege attribute of the application determines whether it has the security domain privilege, and the privilege attribute of the application is one byte of data, and the order from the high to the low is b8 b7 b6 b5 b4 b3 b2 bl, and when b8 is 1, the application is safe.
  • Step 1017 Determine whether the application corresponding to the security domain identifier in the preloading command is the current first card data management module, if yes, go to step 1019, otherwise go to step 1018;
  • Step 1018 Determine whether the status of the application corresponding to the security domain identifier in the preload command is PERSONALIZED. If yes, go to step 1019. Otherwise, go to step 1027.
  • Step 1019 Set an associated security domain of the load file corresponding to the load file identifier in the preload command to be an application corresponding to the security domain identifier in the preload command.
  • Step 1020 Determine whether the length of the load file data block hash value in the preload command is a preset value, if yes, go to step 1021; otherwise, go to step 1027;
  • the preset value is 0x14;
  • Step 1021 Store a load file data block hash value in the preload command and set a hash value verification flag.
  • Step 1022 Process a loading parameter field in the preloading command.
  • the loading parameter field is a TLV structure, that is, a data consisting of multiple labels + length + value format, and different operations are performed according to different labels, and detailed descriptions are not performed herein;
  • Step 1023 Determine whether the length of the load token in the preload command is 0x80, if yes, go to step 1024, otherwise go to step 1027;
  • Step 1024 Send data required for calculating the loading token to the second card data management module, and receive a calculation result returned by the second card data management module, and determine whether the calculation result is the same as the loading token in the preloading command. , if yes, go to step 1025, otherwise go to step 1027;
  • the second card data management module is also a special application in the card; specifically, sending P1, P2, length of valid data, loading file identifier length, loading file identifier, and security domain identifier in the preloading command Length, security domain ID, load file data block hash length, load file data block hash value, load parameter field length, and load parameter field to the second card data management module, regarding the card issuer verifying the process of loading the token, No detailed description is given here;
  • Step 1025 Newly load the file structure, and initialize the global block number.
  • the initialization global block number is 0, and the newly created loading file structure includes: creating an object of an executable loading file structure in the cache, setting each attribute value of the object to a default value, and the attribute value of the object
  • the storage address of each load file data block in the cache and the attributes of the executable load file, and the attributes of the executable load file, such as the executable load file association security domain identifier, are not specifically described herein;
  • Step 1026 Set the return data to 0x00, and perform step 1027.
  • Step 1027 Generate a corresponding status code.
  • the corresponding status code includes a status code that identifies a success and a status code that identifies an error, where different error types correspond to different status codes;
  • Step 1028 Return the set return data and/or the generated status code.
  • steps 1101 to 1129 are as follows:
  • Step 1101 Determine whether the APDU data is a command header of a legal load command, if yes, go to step 1102, otherwise go to step 1128;
  • the APDU data is legal;
  • Step 1102 Determine whether the current state of the card is TERMANATED or CARD_LOCKED, if yes, go to step 1128, otherwise go to step 1103;
  • Step 1103 The data field part of the load command is received, and a complete load command is obtained.
  • Step 1105 Determine whether the current first card data management module has proxy authority, if yes, go to step 1106, otherwise go to step 1128;
  • Step 1106 Determine whether the card meets the security condition, if yes, go to step 1107, otherwise, go to step 1128;
  • Step 1107 Check the security level of the card. If it is the first level, go to step 1110. If it is the second level, go to step 1108. If it is the third level, go to step 1109.
  • the loading command is a plaintext of the message data
  • the security level of the card is the second level
  • the loading command is a combination of the message data plaintext and the message authentication code.
  • the security level of the card is the third level, and the loading command is a combination of the message data ciphertext and the message authentication code;
  • Step 1108 Determine whether the loading command is complete according to the plaintext and MAC of the message data in the loading command, if yes, execute step 1110; otherwise, perform step 1128;
  • the determining, according to the message data in the loading command, the plaintext and the MAC Whether the loading command is complete or not includes: decrypting the MAC by using the agreed session key to obtain a decryption result, and calculating the plaintext of the message data according to the agreed hash function to obtain a calculation result, and determining whether the decryption result and the calculation result are The same, the load command is complete, otherwise the load command is incomplete;
  • Step 1109 Determine whether the loading command is complete according to the message data ciphertext and the MAC in the loading command, if yes, execute step 1110; otherwise, perform step 1128;
  • the determining whether the loading command is complete according to the message data ciphertext and the MAC in the loading command includes: decrypting the message data ciphertext to obtain the message data plaintext, and decrypting the MAC by using the agreed session key to obtain the decryption
  • the calculation result is obtained by calculating the plaintext of the message data according to the agreed hash function, and determining whether the decryption result and the calculation result are the same, if the loading command is complete, otherwise the loading command is incomplete;
  • Step 1110 Determine whether P2 in the load command is equal to the global block number, if yes, go to step 1111, otherwise go to step 1128;
  • Step 1111 Determine whether the global block number is 0, if yes, go to step 1112, otherwise go to step 1113;
  • Step 1112 The DAP (Data Authentication Pattern) block information in the load command is verified, if the verification is passed, step 1113 is performed, and if the verification fails, step 1128 is performed;
  • the load file is divided into a plurality of load file data blocks outside the card, and each load command includes a load file data block.
  • each load command includes a load file data block.
  • the loading command further includes DAP block information, where the DAP block information includes a load file data block signature value, and the first card data management module calculates the key pair DAP block information according to the application provider DAP stored by the current first card data management module. The loaded file data block signature value is verified;
  • Step 1113 Determine whether there is a hash value verification flag in the card, if yes, save the load file data block in the load command, perform step 1114, otherwise directly execute step 1114;
  • Step 1114 Determine whether there is any uncommitted storage component in the executable load file structure, if yes, go to step 1118, otherwise go to step 1115;
  • the application processes the loaded load file data block in units of components to obtain an executable load file structure, where the components include: a Header component, a Directory component, an Applet component, an Import component, and the like;
  • Step 1115 Check whether the component number and component size are included in the load command, if yes, go to step 1116, otherwise go to step 1128;
  • Step 1116 Read the component number, determine whether the component number is legal, if yes, go to step 1117, otherwise go to step 1128;
  • Step 1117 According to the component size Distribute the corresponding size of space;
  • Step 1118 Start processing the load file data block in the load command;
  • Step 1119 Determine whether the current component is processed, if yes, go to step 320, otherwise, go to step 1121;
  • the determining whether the current component is processed is to determine whether a size of data that has been processed in the current component is equal to a size of the current component;
  • Step 1120 Submit the processing result of the current component, and perform step 1121;
  • Step 1121 Determine whether there is still unprocessed load file data block data, if yes, go back to step 1115, otherwise go to step 1122;
  • Step 1122 The global block number is incremented, and it is determined whether P1 of the load command is 0x80, if yes, step 1123 is performed, otherwise step 1127 is performed;
  • the global block number is incremented by one
  • Step 1123 Determine whether there is a hash value verification flag in the card, if yes, go to step 1124; otherwise, go to step 1125;
  • Step 1124 Perform a hash calculation on the stored file data block, and determine whether the calculation result is equal to the load file data block hash value. If yes, go to step 1125. Otherwise, go to step 1128.
  • Step 1125 Submit the storage executable file structure;
  • Step 1126 Send the data required for calculating the receipt to the second card data management module, receive the receipt returned by the second card data management module, and set the return data to the Receipt, perform step 1128;
  • the length of the load file identifier corresponding to the load file data block in the load command, the load file identifier, the length of the security domain identifier, and the security domain identifier are sent to the card provider module.
  • Step 1127 Set the return data to 0x00, and perform step 1128;
  • Step 1128 Generate a corresponding status code.
  • the corresponding status code includes a status code that identifies a success and a status code that identifies an error, where different error types correspond to different status codes;
  • Step 1129 Return the set return data and/or the generated status code; preferably, referring to FIG. 12, steps 1201 to 1235 are as follows:
  • Step 1201 Determine whether the APD U data is a command header of a legal installation command, if yes, go to step 1202, otherwise go to step 1234;
  • the APDU data is a command header of a legal installation command
  • Step 1202 Determine whether the current state of the card is TERMANATED or CARD_LOCKED, if yes, go to step 1234, otherwise go to step 1203;
  • Step 1203 Receive the data field part of the installation command to obtain a complete installation command;
  • Step 1204 Determine whether the current state of the first card data management module is PERSONALIED, if yes, go to step 1205, otherwise go to step 1234;
  • Step 1205 Determine whether the current first card data management module has proxy authority, if yes, go to step 1206, otherwise go to step 1234;
  • Step 1206 Determine whether the card meets the security condition, if yes, go to step 1207, otherwise go to step 1234;
  • Step 1207 Check the security level of the card. If it is the first level, perform step 1210. If the level is the second level, the step 1208 is performed. If the level is the third level, the step 1209 is performed. Specifically, if the security level of the card is the first level, the installation command is the clear text of the message data, and if the security level of the card is the first level The second level, the installation command is a combination of the message data plaintext and the message authentication code. If the security level of the card is the third level, the installation command is a combination of the message data ciphertext and the message authentication code;
  • Step 1208 Determine whether the installation command is complete according to the plaintext and the MAC address of the message in the installation command. If yes, go to step 1210. Otherwise, execute step 1234.
  • the message is based on the message data in the installation command. Determining whether the installation command is complete or not includes: decrypting the MAC by using the agreed session key to obtain a decryption result, and calculating the plaintext of the message data according to the agreed hash function to obtain a calculation result, determining the decryption result and the calculating Whether the result is the same, if the installation command is complete, otherwise the installation command is incomplete;
  • Step 1209 Determine whether the installation command is complete according to the message data ciphertext and the MAC in the installation command, if yes, execute step 1210, otherwise perform step 1234; wherein, according to the message data ciphertext in the installation command And the MAC determining whether the installation command is complete includes: decrypting the message data ciphertext to obtain the message data plaintext, decrypting the MAC by using the agreed session key to obtain a decryption result, and calculating the plaintext of the message data according to the agreed hash function. Obtaining a calculation result, determining whether the decryption result and the calculation result are the same, if the installation command is complete, otherwise the installation command is incomplete;
  • Step 1210 Determine whether the length of the executable load file identifier in the installation command is within a preset range, if yes, go to step 1211, otherwise go to step 1234;
  • the preset range is 0x05-0x10; the corresponding identifier of the executable load file is identified, if yes, step 1212 is performed; otherwise, step 1234 is performed;
  • Step 1212 Determine whether the security domain associated with the executable load file corresponding to the executable load file identifier in the installation command is the current first card data management module, and Go to step 1213, otherwise go to step 1234;
  • Step 1213 Determine whether the executable module identifier length in the installation command is within the preset range, if yes, go to step 1214, otherwise go to step 1234;
  • the preset range is 0x05-0x10; the corresponding executable module is identified, if yes, step 1215 is performed, otherwise step 1234 is performed;
  • Step 1215 Determine whether the application identifier length in the installation command is within a preset range, if yes, go to step 1216, otherwise go to step 1234;
  • the preset range is 0x05-0x10;
  • Step 1216 Determine whether the application identifier in the installation command is legal, if yes, go to step 1217, otherwise go to step 1234;
  • the application identifier is invalid when each byte thereof is 0x00, otherwise the method is legal;
  • Step 1217 Determine whether there is an application corresponding to the application identifier in the installation command in the card, if yes, go to step 1234, otherwise go to step 1218;
  • Step 1218 Determine whether the application permission length in the installation command is 0x01, if yes, go to step 1219, otherwise go to step 1234;
  • Step 1219 Determine whether the application permission in the installation command is 0x04, if yes, execute step 1220, otherwise perform step 1222;
  • Step 1220 Determine whether P1 of the installation command is 0x04, if yes, go to step 1234, otherwise go to step 1221.
  • Step 1221 Determine whether the second card data management module has a default selection authority, if yes, go to step 1222, otherwise go to step 1234;
  • the permission attribute of the second card data management module determines whether it has a default selection authority, and the permission attribute of the second card data management module is one byte of data, which is 138 137 136 135 134 134 133 132 131 from high to low.
  • the permission attribute of the second card data management module is one byte of data, which is 138 137 136 135 134 134 133 132 131 from high to low.
  • the second card data management module has a default selection authority
  • Step 1222 determining that the lower end of the application permission of the installation command starts from the first bit, Whether the 6th bit and the 7th bit are both 0, if yes, go to step 1223, otherwise go to step 1224;
  • Step 1223 Determine whether the highest bit of the application permission of the installation command is 1, and then execute step 1224, otherwise step 1234;
  • Step 1224 Process the installation parameter field in the installation command.
  • Step 1225 Determine whether the length of the installation token in the installation command is 0x80, if yes, go to step 1226, otherwise go to step 1234;
  • Step 1226 Send the data required for calculating the installation token to the second card data management module, and receive the calculation result returned by the second card data management module, and determine whether the calculation result and the installation token in the installation command are the same. If yes, go to step 1227, otherwise go to step 1234;
  • the P1, P2, the length of the valid data, the length of the executable load file identifier, the executable load file identifier, the executable module identifier length, the executable module identifier, the application identifier length, the application identifier, and the application are sent.
  • Step 1227 Register the application according to the data in the data field of the installation command;
  • Step 1228 Determine whether P1 in the installation command is 0x04, if yes, go to step 1232, otherwise go to step 1229;
  • Step 1229 Set the state of the application corresponding to the application identifier in the installation command to SELECTABLE (optional);
  • step 1229 is to set a value of a status attribute of an application corresponding to the application identifier in the installation command to 0x07;
  • Step 1230 Determine whether the application permission in the installation command is 0x04, if yes, execute step 1231, otherwise perform step 1233;
  • Step 1231 Set the application corresponding to the application identifier in the installation command as the default application, and perform step 1233.
  • Step 1232 Set the state of the application corresponding to the application identifier in the installation command to INSTALLED (installation), and perform step 1233; Specifically, the step 1232 includes: setting a value of a state attribute of an application corresponding to the application identifier in the obtained command to 0x03;
  • Step 1233 Send the data required for calculating the receipt to the second card data management module, receive the receipt returned by the second card data management module, set the return data to the receipt, and perform step 1234;
  • Step 1234 Generate a corresponding status code.
  • the corresponding status code includes a status code that identifies a success and a status code that identifies an error, where different error types correspond to different status codes;
  • Step 1235 Return the set return data and/or the generated status code; preferably, see Figure 13, step 1301 to step 1324 are as follows:
  • Step 1301 Determine whether the APDU data is a command header of a legal selectable command, if yes, execute step 1302, otherwise perform step 1323;
  • the APDU data is a command header of a legal selectable command
  • Step 1302 Determine whether the current state of the card is TERMANATED or CARD_LOCKED, if yes, go to step 1323, otherwise go to step 1303;
  • Step 1303 Receive a data field portion of the selectable command to obtain a complete selectable command.
  • Step 1304 Determine whether the current state of the first card data management module is PERSONALIZED (personalized), if yes, execute step 1305, otherwise perform step 1323;
  • Step 1305 Determine whether the current first card data management module has proxy authority, if yes, go to step 1306, otherwise go to step 1323;
  • Step 1306 Determine whether the card meets the security condition, if yes, go to step 1307, otherwise, go to step 1323;
  • Step 1307 Check the security level of the card. If it is the first level, perform step 1310. If the level is the second level, the step 1308 is performed. If the level is the third level, the step 1309 is performed. Specifically, if the security level of the card is the first level, the selectable command is the plaintext of the message data, if the security level of the card is The second level, the selectable command is a combination of the message data plaintext and the message authentication code. If the security level of the card is the third level, the selectable command is a combination of the message data ciphertext and the message authentication code;
  • Step 1308 Determine whether the selectable command is complete according to the message data plaintext and MAC in the selectable command, if yes, execute step 1310, otherwise perform step 1323; wherein, according to the message data in the selectable command Whether the plaintext and the MAC determine whether the selectable command is complete or not includes: decrypting the MAC by using the agreed session key to obtain a decrypted result, and calculating the plaintext of the message data according to the agreed hash function to obtain a calculation result, and determining the decrypted result. Whether the result of the calculation is the same, if the selectable command is complete, otherwise the selectable command is incomplete
  • Step 1309 Determine whether the selectable command is complete according to the message data ciphertext and MAC in the selectable command, if yes, execute step 1310, otherwise perform step 1323; wherein, according to the message in the selectable command The data ciphertext and the MAC determine whether the selectable command is complete or not, including: decrypting the message data ciphertext to obtain the message data plaintext, decrypting the MAC by using the agreed session key to obtain a decryption result, and simultaneously using the hash function according to the agreed hash function The data is calculated in plain text to obtain a calculation result, and it is judged whether the decryption result and the calculation result are the same, and the selectable command is complete, otherwise the selectable command is incomplete;
  • Step 1310 Determine whether the first two bytes of data in the data field of the selectable command are all 0x00, if yes, execute step 1311; otherwise, perform step 1323;
  • Step 1311 Determine whether the application identifier length in the selectable command is within a preset range, if yes, execute step 1312; otherwise, perform step 1323;
  • the preset range is 0x05-0x10;
  • Step 1312 Determine whether there is an application corresponding to the application identifier in the selectable command in the card, if yes, go to step 1313, otherwise go to step 1323;
  • Step 1313 Determine the status of the application corresponding to the application identifier in the selectable command. If it is INSTALLED (installation), if yes, go to step 1314, otherwise go to step 1323; Step 1314: Determine whether the application permission length in the selectable command is 0x00, if yes, go to step 1315, otherwise go to step 1323;
  • Step 1315 Determine whether a byte data after the application permission in the selectable command is 0x00, if yes, go to step 1316; otherwise, go to step 1323; if yes, go to step 1317; otherwise, go to step 1323;
  • Step 1317 Send data required for calculating the installation token to the second card data management module, and receive a calculation result returned by the second card data management module, and determine whether the calculation result is the same as the installation token in the selectable command. If yes, go to step 1318, otherwise go to step 1323;
  • the P1, P2, the valid data length, the executable load file identifier length, the 0x00, the 0x00, the application identifier length, the application identifier, the application permission length, the application permission, and the 0x00 for the second card data management of the selectable command are sent.
  • Step 1318 Set the state of the application corresponding to the application identifier in the selectable command to SELECTABLE (optional);
  • step 1318 is specifically: setting a value of a status attribute of an application corresponding to the application identifier in the selectable command to 0x07;
  • Step 1319 Determine whether P1 in the selectable command is 0x04, if yes, execute step 1320, otherwise perform step 1322;
  • Step 1320 Determine whether the second card data management module has a default selection authority, if yes, go to step 1321. Otherwise, go to step 1323;
  • Step 1321 Set the application corresponding to the application identifier in the selectable command to be the default application, and perform step 1322;
  • Step 1322 Set the return data to 0x00, and perform step 1323;
  • Step 1323 Generate a corresponding status code.
  • the corresponding status code includes a status code that identifies a success and a status code that identifies an error, where different error types correspond to different status codes;
  • Step 1324 Return the set return data and/or the generated status code; preferably, referring to FIG. 14, steps 1401 to 1428 are as follows:
  • Step 1401 Determine whether the APDU data is a command header of a legal extradition command, if yes, execute step 1402; otherwise, execute step 1427;
  • the APDU data is a command header of a legal extradition command
  • Step 1402 Determine whether the current state of the card is TERMANATED or CARD_LOCKED, if yes, go to step 1427; otherwise, go to step 1403;
  • Step 1403 Receive the data domain part of the extradition command to obtain a complete extradition command;
  • Step 1404 Determine whether the current state of the first card data management module is PERSONALIZED, if yes, go to step 1405; otherwise, go to step 1427;
  • Step 1405 Determine whether the current first card data management module has proxy authority, if yes, go to step 1406, otherwise go to step 1427;
  • Step 1406 Determine whether the card meets the security condition, if yes, go to step 1407, otherwise, go to step 1427;
  • Step 1407 Check the security level of the card. If it is the first level, go to step 1410. If it is the second level, go to step 1408. If it is the third level, go to step 1409.
  • the extradition command is a plaintext of the message data
  • the extradition command is a combination of the message data plaintext and the message authentication code.
  • the security level of the card is the third level, and the extradition command is a combination of the message data ciphertext and the message authentication code;
  • Step 1408 Determine, according to the plaintext and MAC of the message data in the extradition command, whether the extradition command is complete, if yes, execute step 1410; otherwise, perform step 1427;
  • the determining, according to the plaintext and the MAC of the message data in the extradition command, whether the extradition command is complete includes: decrypting the MAC by using the agreed session key to obtain a decryption result, and simultaneously using the hash function according to the agreed hash function
  • the plain text is calculated to obtain a calculation result, and it is judged whether the decrypted result and the calculation result are the same.
  • the extradition order is complete, otherwise the extradition order is incomplete;
  • Step 1409 Determine, according to the message data ciphertext and the MAC in the extradition command, whether the extradition command is complete, if yes, go to step 1410; otherwise, go to step 1427;
  • the determining, according to the message data ciphertext and the MAC in the extradition command, whether the extradition command is complete includes: decrypting the message data ciphertext to obtain the message data plaintext, and decrypting the MAC by using the agreed session key to obtain the decryption
  • the calculation result is obtained by calculating the plaintext of the message data according to the agreed hash function, and determining whether the decryption result and the calculation result are the same, and the extradition command is complete, otherwise the extradition command is incomplete; , yes, go to step 1411, otherwise go to step 1427;
  • the preset range is 0x05-0x10; for the application, step 1412 is performed, otherwise step 1427 is performed;
  • Step 1412 Determine whether the application corresponding to the security domain identifier in the extradition command is the current card provider module, if yes, go to step 1427; otherwise, go to step 1413;
  • Step 1413 Determine whether a byte data after the security domain identifier in the extrapolation command is 0x00, if yes, execute step 1414; otherwise, execute step 1427;
  • Step 1414 Determine whether the status of the application corresponding to the security domain identifier in the extradition command is INSTALLED. If yes, go to step 1415. Otherwise, go to step 1427. Step 1415: Determine whether the application identifier length in the extradition command is Within the preset range, yes, step 1416 is performed, otherwise step 1427 is performed;
  • the preset range is 0x05-0x10;
  • Step 1416 Determine whether there is an application corresponding to the application identifier in the extradition command in the card, if yes, go to step 1417; otherwise, go to step 1427;
  • Step 1417 It is determined whether the security domain associated with the application corresponding to the application identifier in the extradition command is the current first card data management module, if yes, step 1418 is performed; otherwise, step 1427 is performed; Step 1418: Determine whether the application corresponding to the security domain identifier in the extradition command has security domain authority, if yes, go to step 1419, otherwise go to step 1427;
  • Step 1419 Determine whether the status of the application corresponding to the security domain identifier in the extradition command is LOCKED. If yes, go to step 1427. Otherwise, go to step 1420.
  • Step 1420 Determine the security domain identifier in the extradition command. Whether the status of the application is PERSONALIZED (personalized), if yes, execute step 1421; otherwise, execute step 1427;
  • Step 1421 Determine whether the two bytes of data after the application identifier in the extradition command are all 0x00, if yes, go to step 1422, otherwise go to step 1427;
  • Step 1422 Determine whether the length of the extradition token in the extradition command is 0x80, if yes, go to step 1423, otherwise go to step 1427;
  • Step 1423 Send the data required for calculating the extradition token to the second card data management module, and receive the calculation result returned by the second card data management module, and determine whether the calculation result is the same as the extradition token in the extradition command. If yes, go to step 1424, otherwise go to step 1427;
  • the P1, P2, the valid data length, the security domain identifier length, the security domain identifier, the 0x00, the application identifier length, the application identifier, 0x00, and 0x00 of the extrapolation command are sent to the second card data management module;
  • Step 1424 It is determined whether the application corresponding to the application identifier in the extradition command has the security domain authority, if yes, step 1427 is performed; otherwise, step 1425 is performed;
  • Step 1425 Will be stated! The security domain associated with the application identifier corresponding to the application identifier in the transition command is modified to be the application corresponding to the security domain identifier in the extradition command;
  • Step 1426 Send the data required for calculating the receipt to the second card data management module, receive the receipt returned by the second card data management module, set the return data to the receipt, and perform step 1427;
  • the length of the application identifier, the application identifier, the length of the original security domain identifier, the original security domain identifier, the length of the new security domain identifier, and the new security domain identifier are sent to the second card data management module, where , the original security domain identifier is this reference
  • the security domain identifier of the security domain associated with the application before the extradition; the new security domain identifier identifies the security domain identity of the security domain to be associated after the extradition application for the extradition application;
  • Step 1427 Generate a corresponding status code
  • the corresponding status code includes a status code that identifies a success and a status code that identifies an error, where different error types correspond to different status codes;
  • Step 1428 Return the set return data and/or the generated status code; preferably, see Figure 15, step 1501 to step 1517 are as follows:
  • Step 1501 Determine whether the APDU data is a command header of a legal personalized command, if yes, go to step 1502, otherwise go to step 1516;
  • the APDU data is a command header of a legal personalized command
  • Step 1502 Determine whether the current state of the card is TERMANATED or CARD_LOCKED, if yes, go to step 1516; otherwise, go to step 1503;
  • Step 1503 Receive the data field part of the personalized command to obtain a complete personalization command;
  • Step 1504 Determine whether the current state of the first card data management module is PERSONALIZED (personalized), if yes, go to step 1505, otherwise go to step 1516;
  • Step 1505 Determine whether the card meets the security condition, if yes, go to step 1506, otherwise go to step 1516;
  • Step 1506 Check the security level of the card. If it is the first level, go to step 1509. If it is the second level, go to step 1507. If it is the third level, go to step 1508.
  • the personalized command is a plaintext of the message data
  • the personalized command is a combination of the message data plaintext and the message authentication code.
  • the security level of the card is the third level, the personalized command is a combination of the message data ciphertext and the message authentication code;
  • Step 1507 Determine whether the personalized command is complete according to the plaintext and MAC of the message data in the personalized command. If yes, go to step 1509. Otherwise, go to step 1516.
  • the message data according to the personalized command is executed.
  • Clear text and MAC judgment Whether the personalization command is complete or not includes: decrypting the MAC by using the agreed session key to obtain a decryption result, and calculating the plaintext of the message data according to the agreed hash function to obtain a calculation result, and determining the decryption result and the calculation Whether the result is the same, if the personalized command is complete, otherwise the personalized command is incomplete;
  • Step 1508 Determine whether the personalized command is complete according to the message data ciphertext and the MAC in the personalized command, if yes, go to step 1509, otherwise go to step 1516; wherein, according to the message in the personalized command
  • the data ciphertext and the MAC determine whether the personalized command is complete or not, including: decrypting the message data ciphertext to obtain the message data plaintext, decrypting the MAC by using the agreed session key to obtain a decryption result, and simultaneously using the hash function according to the agreed hash function.
  • the data is calculated in plain text to obtain a calculation result, and it is judged whether the decryption result and the calculation result are the same, and the personalized command is complete, otherwise the personalized command is incomplete;
  • Step 1509 Determine whether the first two bytes of the data field of the personalized command are 0x00, if yes, go to step 1510, otherwise go to step 1516;
  • Step 1510 Determine whether the application identifier length in the personalized command is within a preset range, if yes, go to step 1511, otherwise go to step 1516;
  • the preset range is 0x05-0x10;
  • Step 1511 Determine whether there is an application corresponding to the application identifier in the personalized command in the card, if yes, go to step 1512, otherwise go to step 1516;
  • Step 1512 Determine whether the security domain associated with the application corresponding to the application identifier in the personalized command is the current first card data management module, if yes, go to step 1513, otherwise go to step 1516;
  • Step 1513 Determine whether the last three bytes of data of the personalized command are 0x00, if yes, go to step 1514, otherwise go to step 1516;
  • Step 1514 Set the state of the application corresponding to the application identifier in the personalized command to personalization (PERSONLIZED);
  • Step 1515 Set the return data to 0x00;
  • Step 1516 Generate a corresponding status code.
  • the corresponding status code includes a status code that identifies a success and a status code that identifies an error, where different error types correspond to different status codes;
  • Step 1517 Return the set return data and/or the generated status code; preferably, see Figure 16, step 1601 to step 1625 are as follows:
  • Step 1601 Determine whether the APDU data is a command header of a legal delete command, if yes, go to step 1602, otherwise go to step 1624;
  • the APD U data is a command header of a legal delete command
  • Step 1602 Determine whether the current state of the card is TERMANATED or CARD_LOCKED, if yes, go to step 1624, otherwise go to step 1603;
  • Step 1603 The data field part of the delete command is received, and a complete delete command is obtained.
  • Step 1605 Determine whether the current first card data management module has proxy authority, if yes, go to step 1606, otherwise go to step 1624;
  • Step 1606 Determine whether the card meets the security condition, if yes, go to step 1607, otherwise go to step 1624;
  • Step 1607 Check the security level of the card, if it is the first level, step 1610 is performed, if it is the second level, step 1608 is performed, and if it is the third level, step 1609 is performed;
  • the deletion command is a plaintext of the message data
  • the deletion command is a combination of the message data plaintext and the message authentication code.
  • the security level of the card is the third level, and the deletion command is a combination of the message data ciphertext and the message authentication code;
  • Step 1608 Determine, according to the plaintext and MAC of the message data in the delete command, whether the delete command is complete, if yes, go to step 1610, otherwise go to step 1624;
  • the determining, according to the plaintext and the MAC of the message data in the deletion command, whether the deletion command is complete or not includes: solving the MAC by using the agreed session key The decryption result is obtained, and the calculation result is obtained by calculating the plaintext of the message data according to the agreed hash function, and determining whether the decryption result and the calculation result are the same, if the deletion command is complete, otherwise the deletion command is incomplete. ;
  • Step 1609 Determine whether the deletion command is complete according to the message data ciphertext and the MAC in the deletion command. If yes, go to step 1610. Otherwise, execute step 1624.
  • the MAC determining whether the deletion command is complete includes: decrypting the message data ciphertext to obtain the message data plaintext, decrypting the MAC by using the agreed session key to obtain a decryption result, and calculating the plaintext of the message data according to the agreed hash function. Obtaining a calculation result, determining whether the decryption result and the calculation result are the same, if the deletion command is complete, otherwise the deletion command is incomplete;
  • Step 1610 It is determined whether the first byte data in the data field of the delete command is 0x4f, if yes, step 1611 is performed, otherwise step 1624 is performed;
  • Step 1611 Determine whether the length of the data field identifier in the delete command is within a preset range, if yes, go to step 1612, otherwise go to step 1624;
  • the preset range is 0x05-0x10;
  • Step 1612 Determine whether there is an application corresponding to the data field identifier in the delete command in the card, if yes, go to step 1613, otherwise go to step 1614;
  • Step 1613 Determine whether P2 in the delete command is 0x80, if yes, go to step 1614, otherwise go to step 1619;
  • Step 1614 Determine whether there is an executable file corresponding to the data field identifier in the delete command in the card, if yes, go to step 1615, otherwise go to step 1624;
  • Step 1615 Determine whether the security domain associated with the executable file corresponding to the data domain identifier in the delete command is the current first card data management module, if yes, go to step 1616; otherwise, go to step 1624;
  • Step 1616 It is determined whether P2 in the delete command is 0x80, if yes, step 1617 is performed; otherwise, step 1618 is performed;
  • Step 1617 Delete the executable file corresponding to the data domain identifier in the delete command. And all the applications corresponding to the executable file, go to step 1623; Step 1618: Delete the executable file corresponding to the data domain identifier in the delete command, and perform step 1623;
  • Step 1619 Determine whether the application corresponding to the data domain identifier in the delete command is a security domain associated with another application or other executable file, if yes, go to step 1624, otherwise go to step 1620;
  • Step 1620 Determine whether the application corresponding to the data domain identifier in the delete command is the current first card data management module, if yes, go to step 1624, otherwise go to step 1621;
  • Step 1621 Determine the data domain identifier in the delete command. Whether the security domain associated with the corresponding application is the current first card data management module, if yes, go to step 1622, otherwise go to step 1624;
  • Step 1622 Delete an application corresponding to the data domain identifier in the delete command.
  • Step 1623 Send data required for calculating the receipt to the second card data management module, and receive the receipt returned by the second card data management module, and set Returning the data to the receipt, performing step 1624;
  • Step 1624 Generate a corresponding status code.
  • the corresponding status code includes a status code that identifies a success and a status code that identifies an error, where different error types correspond to different status codes;
  • Step 1625 Return the set return data and/or the generated status code.

Abstract

La présente invention appartient au domaine des cartes intelligentes, et concerne un procédé de gestion d'une application sur carte. Le procédé comporte les étapes suivantes: après avoir reçu des données envoyées par un environnement d'exécution (RE), un module de gestion de contenu de carte vérifie l'état de la carte; lorsque l'état de la carte n'est pas un premier état prédéfini ou un deuxième état prédéfini, les données reçues sont vérifiées; et lorsque les données reçues satisfont un format prédéfini, la réception des données envoyées par l'environnement d'exécution continue pour obtenir une commande complète, et une commande correspondante est exécutée pour mettre en œuvre une association d'applications sur une carte. L'avantage de la présente invention réside dans la mise en place d'un procédé de gestion d'une application sur carte, permettant de mettre en œuvre le chargement, l'installation, la mise à jour, la personnalisation et la suppression d'une application sur la carte.
PCT/CN2014/076030 2013-04-25 2014-04-23 Procédé de gestion d'une application sur carte WO2014173298A1 (fr)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US14/786,213 US10324781B2 (en) 2013-04-25 2014-04-23 Method for managing application on card

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
CN201310146939.4 2013-04-25
CN201310146939.4A CN103218560B (zh) 2013-04-25 2013-04-25 一种管理卡片数据的实现方法
CN201310399702.7 2013-09-05
CN201310399702.7A CN103473093B (zh) 2013-09-05 2013-09-05 一种管理卡片上应用的方法

Publications (1)

Publication Number Publication Date
WO2014173298A1 true WO2014173298A1 (fr) 2014-10-30

Family

ID=51791060

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2014/076030 WO2014173298A1 (fr) 2013-04-25 2014-04-23 Procédé de gestion d'une application sur carte

Country Status (2)

Country Link
US (1) US10324781B2 (fr)
WO (1) WO2014173298A1 (fr)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103544037B (zh) 2013-10-29 2016-08-17 飞天诚信科技股份有限公司 一种支持OpenSC的软硬件驱动的实现方法
US11138076B2 (en) * 2017-06-30 2021-10-05 Redis Ltd. Methods, systems, and media for controlling append-only file rewrites

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101042736A (zh) * 2006-03-24 2007-09-26 中国银联股份有限公司 一种智能卡及智能卡中存取对象的方法
US7340748B2 (en) * 2000-12-21 2008-03-04 Gemplus Automatic client proxy configuration for portable services
CN102801705A (zh) * 2012-06-25 2012-11-28 飞天诚信科技股份有限公司 一种java卡上安全域的实现方法
CN103218560A (zh) * 2013-04-25 2013-07-24 飞天诚信科技股份有限公司 一种管理卡片数据的实现方法
CN103473093A (zh) * 2013-09-05 2013-12-25 飞天诚信科技股份有限公司 一种管理卡片上应用的方法

Family Cites Families (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0917119A3 (fr) * 1997-11-12 2001-01-10 Citicorp Development Center, Inc. Portemonnaie électronique réparti basé sur un reseau
US6824045B2 (en) * 2000-04-20 2004-11-30 Canon Kabushiki Kaisha Method and system for using multiple smartcards in a reader
US6816882B1 (en) * 2000-05-31 2004-11-09 International Business Machines Corporation System and method for automatically negotiating license agreements and installing arbitrary user-specified applications on application service providers
US7113883B1 (en) * 2001-08-24 2006-09-26 Vi Technology, Inc. Test configuration and data management system and associated method for enterprise test operations
EP1454306A2 (fr) * 2001-12-07 2004-09-08 Ecebs Limited Systeme de carte intelligente
US9959544B2 (en) * 2003-05-22 2018-05-01 International Business Machines Corporation Updating an application on a smart card and displaying an advertisement
US20040236680A1 (en) * 2003-05-22 2004-11-25 International Business Machines Corporation Method and apparatus for displaying embedded chip states and embedded chip end-user application states
US7272776B2 (en) * 2003-12-30 2007-09-18 Sap Aktiengesellschaft Master data quality
US8355042B2 (en) * 2008-10-16 2013-01-15 Spatial Cam Llc Controller in a camera for creating a panoramic image
US8819286B2 (en) * 2010-10-19 2014-08-26 Hewlett-Packard Development Company, L.P. Methods, systems, and apparatus for processing messaging data sets using structured data sets
US8803666B2 (en) * 2012-07-10 2014-08-12 Honeywell International Inc. Universal access device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7340748B2 (en) * 2000-12-21 2008-03-04 Gemplus Automatic client proxy configuration for portable services
CN101042736A (zh) * 2006-03-24 2007-09-26 中国银联股份有限公司 一种智能卡及智能卡中存取对象的方法
CN102801705A (zh) * 2012-06-25 2012-11-28 飞天诚信科技股份有限公司 一种java卡上安全域的实现方法
CN103218560A (zh) * 2013-04-25 2013-07-24 飞天诚信科技股份有限公司 一种管理卡片数据的实现方法
CN103473093A (zh) * 2013-09-05 2013-12-25 飞天诚信科技股份有限公司 一种管理卡片上应用的方法

Also Published As

Publication number Publication date
US10324781B2 (en) 2019-06-18
US20160085609A1 (en) 2016-03-24

Similar Documents

Publication Publication Date Title
JP7372434B2 (ja) スクリプトに基づくブロックチェーン相互作用
US9398025B2 (en) Method for generating and check-controlling network identity indentification code in network electronic identification card
CN110912707B (zh) 基于区块链的数字证书处理方法、装置、设备及存储介质
CN112671720B (zh) 一种云平台资源访问控制的令牌构造方法、装置及设备
KR20240023688A (ko) 블록체인 기반의 암호화폐를 위한 토큰을 검증하는 컴퓨터로 구현된 방법 및 시스템
TW201732666A (zh) 使用分散式雜湊表與區塊鏈來保護電腦軟體之方法與系統
US20070136574A1 (en) Apparatus and method for managing plurality of certificates
CN110989994A (zh) 基于区块链的代码版本管理方法、装置、终端及存储介质
WO2015156786A1 (fr) Signatures de document pouvant être rédigé
WO2009157133A1 (fr) Dispositif de traitement d’informations, procédé de traitement d’informations et programme informatique et circuit intégré pour leur réalisation
WO2009132529A1 (fr) Procédé et dispositif pour valider des données de formulaire web
US10621335B2 (en) Method and device for verifying security of application
US20200349556A1 (en) Methods and devices for managing access to account in blockchain system
CN111612456A (zh) 过期数字证书管控方法、系统、装置及存储介质
KR20230044262A (ko) 블록체인 토큰들
US20050154899A1 (en) Mobile software authentication and validation
CN110213290A (zh) 数据获取方法、api网关以及存储介质
CN103152724B (zh) 一种硬件锁sim卡的方法及系统
CN104158797A (zh) 口令和标识型密码相集成的用户登录鉴别实施方法
CN106487505B (zh) 密钥管理、获取方法及相关装置和系统
WO2014173298A1 (fr) Procédé de gestion d'une application sur carte
CN103218560B (zh) 一种管理卡片数据的实现方法
CN111241492A (zh) 一种产品多租户安全授信方法、系统及电子设备
CN103473093B (zh) 一种管理卡片上应用的方法
CN105677693A (zh) 一种访问数据库的方法及装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 14788882

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 14786213

Country of ref document: US

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 14788882

Country of ref document: EP

Kind code of ref document: A1