JP2006113747A - Portable electronic device - Google Patents

Portable electronic device Download PDF

Info

Publication number
JP2006113747A
JP2006113747A JP2004299260A JP2004299260A JP2006113747A JP 2006113747 A JP2006113747 A JP 2006113747A JP 2004299260 A JP2004299260 A JP 2004299260A JP 2004299260 A JP2004299260 A JP 2004299260A JP 2006113747 A JP2006113747 A JP 2006113747A
Authority
JP
Japan
Prior art keywords
application
addition
card
command
added
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2004299260A
Other languages
Japanese (ja)
Inventor
Norio Ishibashi
則夫 石橋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Toshiba Corp
Original Assignee
Toshiba Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Toshiba Corp filed Critical Toshiba Corp
Priority to JP2004299260A priority Critical patent/JP2006113747A/en
Publication of JP2006113747A publication Critical patent/JP2006113747A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Stored Programmes (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To inhibit re-addition of an application that cannot be re-added, by setting, during installation, re-addition inhibition information correspondingly to the name of the application program using a first installation command that declares the name of the application program. <P>SOLUTION: When the application that cannot be re-added is added to an IC card 1, a higher-level device 2 sends re-addition inhibition information to the IC card 1, along with a command to install or load the application. At the IC card 1, a check is made to see whether or not there is the re-addition inhibition information upon the command to install or load the application; if the re-addition inhibition information is included, the application is registered as the application that cannot be re-added. <P>COPYRIGHT: (C)2006,JPO&NCIPI

Description

本発明は、たとえば、データの書込みや書換え可能な不揮発性メモリおよびCPUなどの制御素子を有したICチップを内蔵し、外部から入力されるコマンドに対応した処理を実行してその処理結果を外部へ出力し、外部から入力されるアプリケーションを不揮発性メモリにロード(あるいは、インストール)し、このロードしたアプリケーションを実行することが可能なICカードなどの携帯可能電子装置に関する。   The present invention incorporates, for example, an IC chip having a control element such as a non-volatile memory capable of writing and rewriting data and a CPU, executes processing corresponding to an externally input command, and outputs the processing result to the outside The present invention relates to a portable electronic device such as an IC card that can load (or install) an application input from the outside into a non-volatile memory and execute the loaded application.

従来、携帯可能電子装置としては、たとえば、メモリやCPUなどの機能を有したICチップがプラスチック板などで構成される筐体内に埋設されているICカードがある。このようなICカードでは、不揮発性メモリに記憶されているアプリケーションプログラムに基づいて種々の制御を実現している。従来のICカードでは、アプリケーション(アプリケーションプログラム)がICカード(ICチップ)の製造メーカ独自の言語で作成されていることが多い。また、従来のICカードでは、アプリケーションが書き換え不可能なROMに記憶されることも多い。このため、ICカード(ICチップ)の製造メーカ以外が、アプリケーションを(一般言語で)作成したり、運用後にアプリケーションを追加したり削除したりすることが現実的に困難であるという問題がある。   Conventionally, as a portable electronic device, for example, there is an IC card in which an IC chip having functions such as a memory and a CPU is embedded in a casing made of a plastic plate or the like. In such an IC card, various controls are realized based on an application program stored in a nonvolatile memory. In conventional IC cards, applications (application programs) are often created in the language unique to the IC card (IC chip) manufacturer. In conventional IC cards, applications are often stored in a non-rewritable ROM. For this reason, there is a problem that it is practically difficult for anyone other than the manufacturer of the IC card (IC chip) to create an application (in a general language) or add or delete an application after operation.

そこで、これらの不都合を解決するために、いわゆるJavaカード(Javaは米サン・マイクロシステムズ社の登録商標)と称されるICカードが開発されている。上記Javaカードは、一般的なICカードのOS(オペレーティングシステム)の上にバーチャルマシン(Virtual Machine)をのせたICカードである。上記Javaカードの特徴は、Java言語でアプリケーション(以下、アプレットとも言う)を作成することが可能であることがあげられる。このため、Javaカードでは、カード発行者などの権限を持った人であれば、Javaカード内のアプリケーションを追加したり削除したりすることが容易に可能である。   Therefore, in order to solve these disadvantages, an IC card called a so-called Java card (Java is a registered trademark of Sun Microsystems, Inc.) has been developed. The Java card is an IC card in which a virtual machine (Virtual Machine) is placed on an OS (operating system) of a general IC card. A feature of the Java card is that it is possible to create an application (hereinafter also referred to as an applet) in the Java language. For this reason, with a Java card, any person with authority such as a card issuer can easily add or delete an application in the Java card.

たとえば、従来のJavaカードへのアプリケーションの追加は、2つのインストールコマンドとロードコマンドなどにより行われ、そのシーケンスは以下の通りである。   For example, an application is added to a conventional Java card by two installation commands and a load command, and the sequence is as follows.

れる。
まず、Javaカードには、上位装置からの第1のインストールコマンドにより追加するアプリケーションのプログラムの名前(Load File AID)が宣言される。
It is.
First, in the Java card, the name of the application program (Load File AID) to be added is declared by the first installation command from the host device.

上位装置がJavaカードに対してアプリケーションのプログラムの名前をICカードに宣言するコマンドである。これにより、Javaカードでは、追加するアプリケーションのプログラムの名前が設定される。 This is a command for the host device to declare the name of the application program to the IC card for the Java card. Thereby, in the Java card, the name of the program of the application to be added is set.

次に、Javaカードには、上位装置からのロードコマンドにより第1のインストールコマンドによって名前(Load File AID)が宣言されたアプリケーションのプログラム(追加するアプリケーションのプログラム)が転送される。このロードコマンドは、複数回実施され、アプリケーションのプログラム全体がJavaカードに転送される。これにより、Javaカードでは、追加するアプリケーションのプログラムが第1のインストールコマンドで宣言された名前で追加(作成)される。   Next, the application program (the application program to be added) whose name (Load File AID) is declared by the first installation command is transferred to the Java card by the load command from the host device. This load command is executed a plurality of times, and the entire application program is transferred to the Java card. Thereby, in the Java card, the application program to be added is added (created) with the name declared by the first installation command.

次に、Javaカードには、上位装置からアプリケーションのデータの名前(Application AID)が宣言される。これにより、Javaカードでは、上記ロードコマンドにてロードされたアプリケーションのデータの名前が追加(作成)される。
これらのコマンドによってJavaカードには、アプリケーションがインストールされるようになっている。
Next, the name of the application data (Application AID) is declared on the Java card from the host device. As a result, in the Java card, the name of the application data loaded by the load command is added (created).
With these commands, an application is installed on the Java card.

また、従来のJavaカードへのアプリケーションの削除は、削除コマンドなどにより行われる。Javaカードには、上位装置から削除したいアプリケーションのプログラムの名前(Load File AID)あるいはアプリケーションのデータの名前(Application AID)が宣言される。これにより、Javaカードでは、アプリケーションのプログラムの名前(Load File AID)あるいはアプリケーションのデータの名前(Application AID)で指定されるアプリケーションを削除する。   In addition, deletion of an application to a conventional Java card is performed by a deletion command or the like. In the Java card, the name of the application program (Load File AID) or the name of the application data (Application AID) to be deleted from the host device is declared. Thereby, in the Java card, the application specified by the name of the application program (Load File AID) or the name of the application data (Application AID) is deleted.

上記のようなJavaカードが広く普及した場合、カード発行者が発行した全てのJavaカード内のアプリケーションを完全に管理することは、とても困難であると考えられる。それは、膨大な数のアプリケーションが開発され、アプリケーションの追加あるいは削除の権限をカード発行者以外の機関に委譲された場合には任意にアプリケーションの追加あるいは削除が出来ることなどからである。すなわち、上記のような状況では、1つのJavaカードにつき使用回数を制限したいアプリケーション等に関しては問題が発生する場合がある。たとえば、使用回数を制限したいアプリケーションとしては、クーポン券や割引券として機能するアプリケーションなどがある。このようなアプリケーション自体は、従来のJavaカードであっても、使用回数を規定することは可能である(たとえば、特許文献1)。   When the Java cards as described above are widely spread, it is very difficult to completely manage all the applications in the Java cards issued by the card issuer. This is because a huge number of applications have been developed, and when the authority to add or delete applications is transferred to an organization other than the card issuer, applications can be added or deleted arbitrarily. That is, in the situation as described above, a problem may occur with respect to an application or the like for which it is desired to limit the number of uses for one Java card. For example, applications that limit the number of uses include applications that function as coupons or discount coupons. Even if such an application itself is a conventional Java card, the number of times of use can be defined (for example, Patent Document 1).

しかしながら、アプリケーションの追加あるいは削除が任意に可能な場合、そのアプリケーションを削除して再追加することによって使用回数が延長できる。つまり、アプリケーションの追加と削除とを繰り返すことによってアプリケーションの使用回数を無制限にすることが可能となってしまうという問題がある。特に、今後、Javaカードに対するアプリケーションの追加あるいは削除の権限がカード発行者以外に委譲されることが多くなると、Javaカードへのアプリケーションの再追加に歯止めをかけることが可能な技術が要望されている。
特開2003−196625号公報
However, when an application can be arbitrarily added or deleted, the number of uses can be extended by deleting and re-adding the application. That is, there is a problem that the number of times the application is used can be made unlimited by repeating addition and deletion of the application. In particular, when the authority to add or delete an application to a Java card is increasingly delegated to a person other than the card issuer in the future, there is a demand for a technique capable of stopping the re-addition of the application to the Java card. .
JP 2003-196625 A

この発明は、上記のような問題点を解決するものであり、特定のアプリケーションの追加を制限することができる携帯可能電子装置を提供することを目的とする。   The present invention solves the above-described problems, and an object thereof is to provide a portable electronic device that can limit the addition of a specific application.

この発明の携帯可能電子装置は、書き換え可能な不揮発性メモリにインストールされているアプリケーションを実行するものにおいて、外部装置からの前記不揮発性メモリへのアプリケーションの追加要求と当該アプリケーションの再追加が不可である旨の情報とを受信する受信手段と、この受信手段によりアプリケーションの追加要求と再追加が不可である旨の情報とを受信した場合、当該アプリケーションの再追加を不可とすることを示すデータを設定する設定手段と、前記受信手段により前記外部装置から受信したアプリケーションを前記不揮発性メモリにインストールする処理手段と有する。   The portable electronic device according to the present invention executes an application installed in a rewritable nonvolatile memory, and cannot add an application to the nonvolatile memory from an external device and cannot re-add the application. When receiving means for receiving information indicating that there is information and information indicating that an application addition request and re-addition cannot be performed by the receiving means, data indicating that re-addition of the application is not allowed Setting means for setting, and processing means for installing the application received from the external device by the receiving means in the nonvolatile memory.

この発明の携帯可能電子装置は、書き換え可能な不揮発性メモリにインストールされているアプリケーションを実行するものにおいて、外部装置からの前記不揮発性メモリにインストールされているアプリケーションの削除要求と当該アプリケーションの再追加が不可である旨の情報とを受信する受信手段と、この受信手段によりアプリケーションの削除要求と再追加不可を受信した場合、当該アプリケーションの再追加を不可とすることを示すデータを設定する設定手段と、前記受信手段により削除要求を受信したアプリケーションを前記不揮発性メモリから削除する処理手段とを有する。   The portable electronic device according to the present invention executes an application installed in a rewritable nonvolatile memory. In the portable electronic device according to the present invention, a request to delete the application installed in the nonvolatile memory from an external device and re-addition of the application. Receiving means for receiving information indicating that the application cannot be received, and setting means for setting data indicating that the application cannot be re-added when an application deletion request and re-addition impossible are received by the receiving means. And processing means for deleting the application that has received the deletion request by the receiving means from the non-volatile memory.

この発明の携帯可能電子装置は、書き換え可能な不揮発性メモリにインストールされているアプリケーションを実行するものにおいて、アプリケーションの追加を不可に設定する関数を含む関数群が登録されている登録手段と、この登録手段に登録されている関数群を用いて前記不揮発性メモリにインストールされているアプリケーションを実行する実行手段と、この実行手段により前記不揮発性メモリにインストールされているアプリケーションのうち再追加を不可とするアプリケーションを実行する際、前記登録手段に登録されているアプリケーションの追加を不可に設定する関数を用いて当該アプリケーションの再追加を不可とすることを示すデータを設定する設定手段とを有する。   The portable electronic device according to the present invention executes an application installed in a rewritable nonvolatile memory, and includes a registration unit in which a function group including a function that disables addition of an application is registered. Execution means for executing an application installed in the nonvolatile memory using a function group registered in the registration means, and re-addition of the applications installed in the nonvolatile memory by the execution means is impossible. And a setting unit that sets data indicating that re-addition of the application is prohibited by using a function that disables addition of the application registered in the registration unit.

この発明の携帯可能電子装置は、書き換え可能な不揮発性メモリにインストールされているアプリケーションを実行するものにおいて、追加を不可とするアプリケーションを示すデータが設定されている設定手段と、外部装置からの前記不揮発性メモリへのアプリケーションの追加要求を受信する受信手段と、この受信手段によりアプリケーションの追加要求を受信した場合、当該アプリケーションが前記設定手段により追加を不可とするアプリケーションとして設定されているか否かを判断する判断手段と、この判断手段により当該アプリケーションが追加を不可とするアプリケーションとして設定されていると判断した場合、当該アプリケーションの追加を不可とする第1の処理手段と、前記判断手段により当該アプリケーションが追加を不可とするアプリケーションとして設定されていないと判断した場合、前記受信手段により追加要求を受信したアプリケーションを前記不揮発性メモリにインストールする第2の処理手段とを有する。   The portable electronic device according to the present invention executes an application installed in a rewritable nonvolatile memory, and includes setting means in which data indicating an application that cannot be added is set; and the external device A receiving unit that receives a request for adding an application to the nonvolatile memory, and whether or not the application is set as an application that cannot be added by the setting unit when the receiving unit receives an application addition request. A determination means for determining; a first processing means for disallowing addition of the application when the determination means determines that the application is set as an application that cannot be added; and the application by the determination means Added If it is judged not to be set as an application to disable, and a second processing means for installing the application that has received the additional request by the receiving means in the nonvolatile memory.

この発明によれば、特定のアプリケーションの追加を制限することができる携帯可能電子装置を提供することを目的とする。   An object of the present invention is to provide a portable electronic device that can limit the addition of a specific application.

以下、この発明を実施するための最良の形態について図面を参照して説明する。
図1は、この実施の形態に係る携帯可能電子装置としてのICカード1のハードウエア構成を概略的に示すものである。以下に説明する実施の形態では、ICカード1がJavaカードであることを想定して説明する。
The best mode for carrying out the present invention will be described below with reference to the drawings.
FIG. 1 schematically shows a hardware configuration of an IC card 1 as a portable electronic device according to this embodiment. In the embodiment described below, description will be made assuming that the IC card 1 is a Java card.

このICカード1は、CPU(セントラル・プロセッシング・ユニット)11、ROM(リード・オンリ・メモリ)12、RAM(ランダム・アクセス・メモリ)13、通信ユニット(UART)14、不揮発性メモリ(NV(EEPROM))15、コプロセッサ(Co−Pro)16、およびタイマ17などを有している。   The IC card 1 includes a CPU (Central Processing Unit) 11, a ROM (Read Only Memory) 12, a RAM (Random Access Memory) 13, a communication unit (UART) 14, a non-volatile memory (NV (EEPROM) )) 15, a coprocessor (Co-Pro) 16, a timer 17, and the like.

上記CPU11は、全体的な管理や制御を司るものである。上記CPU11は、制御プログラム等に基づいて動作し、種々の処理を行う処理手段や判断手段として機能する。上記ROM12は、上記CPU11の制御用プログラムなどが格納される不揮発性メモリである。上記RAM13は、ワーキングメモリとして機能する揮発性のメモリである。上記通信ユニット14は、送受信手段として機能し、上位装置(カードリーダライタなど)2と通信を制御するものである。   The CPU 11 is responsible for overall management and control. The CPU 11 operates based on a control program or the like and functions as a processing unit or a determination unit that performs various processes. The ROM 12 is a non-volatile memory in which a control program for the CPU 11 is stored. The RAM 13 is a volatile memory that functions as a working memory. The communication unit 14 functions as transmission / reception means, and controls communication with the host device (such as a card reader / writer) 2.

上記不揮発性メモリ15は、各種データやアプリケーション(アプリケーションプログラム)を記憶する書き換え可能な不揮発性メモリである。また、上記不揮発性メモリ15には、データテーブル15aが設けられている。上記データテーブル15aは、設定手段として機能し、後述する再追加不許可情報を記憶する。上記コプロセッサ(Co−Pro)16は、暗号化あるいは復号化などの演算の補助を行うものである。上記タイマ17は、計時動作を行うものである。   The nonvolatile memory 15 is a rewritable nonvolatile memory that stores various data and applications (application programs). The nonvolatile memory 15 is provided with a data table 15a. The data table 15a functions as a setting unit and stores re-addition non-permission information described later. The coprocessor (Co-Pro) 16 assists operations such as encryption or decryption. The timer 17 performs a time measuring operation.

図2は、上述したハードウエア構成のICカード1がJavaカードとして使用される場合のICカード1内のソフトウエア構成を模式的に示すものである。
上記ICカード1のソフトウエア構成は、ハードウエア(H/W)層21、OS(オペレーティングシステム)層22、およびアプリケーション(アプレット)層23から構成される。上記アプリケーション層23が最上位に位置し、OS層22が上記H/W層21の上位に位置するように構成されている。
FIG. 2 schematically shows a software configuration in the IC card 1 when the above-described hardware configuration IC card 1 is used as a Java card.
The software configuration of the IC card 1 includes a hardware (H / W) layer 21, an OS (operating system) layer 22, and an application (applet) layer 23. The application layer 23 is positioned at the top, and the OS layer 22 is positioned above the H / W layer 21.

上記H/W層21は、上記通信ユニット14、不揮発性メモリ15、コプロセッサ16などのハードウエアからなるものである。上記(H/W)層21は、OS(オペレーティングシステム)層22のカードOS31により制御される。
上記OS層22は、バーチャルマシン(Virtual Machine)32、ISD.(Issuer Security Domain)33、およびAPI(APplication Interface)群34といったモジュールがカードOS31にのった状態となっている。
The H / W layer 21 is composed of hardware such as the communication unit 14, the nonvolatile memory 15, and the coprocessor 16. The (H / W) layer 21 is controlled by the card OS 31 of the OS (operating system) layer 22.
The OS layer 22 includes a virtual machine 32, ISD. Modules such as (Issor Security Domain) 33 and API (Application Interface) group 34 are on the card OS 31.

上記バーチャルマシン32は、Javaカード1を動作させるための環境設定などを示すモジュールである。上記ISD33は、上記アプリケーション層23の各アプリケーション(アプレット)を管理するモジュールである。上記API群34は、アプリケーションで使用される関数としてのAPIを示すモジュールであり、アプリケーションにより使用される各種の関数を登録する登録手段として機能する。
また、上記アプリケーション層23は、たとえば、複数のアプリケーション(アプリケーションA、アプリケーションB)を有する。上記アプリケーション層23の各アプリケーションは上記API34を使用して種々の処理を実現するものであり、各アプリケーションの実体は不揮発性メモリ15等に記憶される。
The virtual machine 32 is a module that indicates environment settings for operating the Java card 1. The ISD 33 is a module that manages each application (applet) in the application layer 23. The API group 34 is a module that indicates an API as a function used in an application, and functions as a registration unit that registers various functions used by the application.
The application layer 23 has, for example, a plurality of applications (application A, application B). Each application in the application layer 23 implements various processes using the API 34, and the substance of each application is stored in the nonvolatile memory 15 or the like.

次に、上記のように構成されるICカード1でのアプリケーションの追加、実行、削除の動作について説明する。   Next, operations for adding, executing, and deleting an application in the IC card 1 configured as described above will be described.

ICカード1では、特定のアプリケーションの再追加を不可とするため、再追加を不可とするための再追加不許可情報を登録し、その再追加不許可情報に基づいて特定のアプリケーションの再追加を不可するようになっている。すなわち、上記ICカード1では、再追加不許可情報を登録する処理と、上記再追加不許可情報に基づいてアプリケーションの追加を制御する処理とを行うようになっている。   In the IC card 1, re-addition non-permission information for prohibiting re-addition is registered in order to make it impossible to re-add a specific application, and re-addition of a specific application is performed based on the re-addition non-permission information. It is supposed to be impossible. That is, the IC card 1 performs a process for registering re-addition non-permission information and a process for controlling addition of an application based on the re-addition non-permission information.

上記再追加不許可情報を登録する処理では、たとえば、再追加を許可しないアプリケーションのプログラム名(Load File AID)あるいはアプリケーションのデータ名(Application AID)を再追加不許可情報として、不揮発性メモリ15のデータテーブル15aに登録する。このデータテーブル15aは、OS層22のカードOS31により管理される。   In the process of registering the re-addition non-permission information, for example, the program name (Load File AID) of the application that is not permitted to re-add or the data name (Application AID) of the application is used as the re-addition non-permission information. Register in the data table 15a. The data table 15a is managed by the card OS 31 of the OS layer 22.

なお、アプリケーションのプログラムの名前(Load File AID)とは、アプリケーションを実行するためのプログラムの名前を示すものであり、たとえば、プログラムコード(あるいはROMコード)を示す。また、アプリケーションのデータの名前(Application AID)とは、アプリケーションの自体の名前を示すものである。   Note that the application program name (Load File AID) indicates the name of the program for executing the application, for example, a program code (or ROM code). The application data name (Application AID) indicates the name of the application itself.

上記再追加不許可情報に基づいてアプリケーションの追加を制御する処理では、たとえば、アプリケーションを追加する際に、そのアプリケーションのプログラム名(Load File AID)あるいはアプリケーションのデータ名(Application AID)と上記データテーブル15aに登録されている再追加不許可情報と比較し、完全一致もしくは、部分一致した場合に、そのアプリケーションの追加を異常終了させる。   In the process of controlling the addition of an application based on the re-addition non-permission information, for example, when an application is added, the program name of the application (Load File AID) or the data name of the application (Application AID) and the data table Compared to the re-addition non-permission information registered in 15a, if the application completely matches or partially matches, the addition of the application is abnormally terminated.

次に、上記ICカード1に再追加不許可情報を登録する処理を具体例な動作例により説明する。
上記再追加不許可情報は、アプリケーションの追加(インストール)開始から当該アプリケーションを削除するまでの間に登録する必要がある。たとえば、アプリケーションを追加(インストール)する処理、アプリケーションを実行する処理、あるいは、アプリケーションを削除する処理において、上記再追加不許可情報を登録することが可能である。本実施の形態では、上記再追加不許可情報を登録する処理として、たとえば、図3〜図7に示すような5つのパターンについて説明するものとする。
Next, the process of registering the re-addition non-permission information in the IC card 1 will be described with a specific example of operation.
The re-addition non-permission information needs to be registered between the start of application addition (installation) and the deletion of the application. For example, the re-addition non-permission information can be registered in a process of adding (installing) an application, a process of executing an application, or a process of deleting an application. In the present embodiment, as a process for registering the re-addition non-permission information, for example, five patterns as shown in FIGS. 3 to 7 will be described.

まず、上記再追加不許可情報を登録する処理の例としての第1のパターンについて説明する。
図3は、上記再追加不許可情報を登録する処理の例としての第1のパターンを説明するためのフローチャートである。
図3に示す第1のパターンでは、アプリケーションのプログラム名(Load File AID)を宣言する第1のインストールコマンドにおいて、当該アプリケーションの再追加不許可情報をICカード1に登録する。
First, a first pattern as an example of a process for registering the re-addition non-permission information will be described.
FIG. 3 is a flowchart for explaining a first pattern as an example of a process for registering the re-addition non-permission information.
In the first pattern shown in FIG. 3, the re-addition non-permission information of the application is registered in the IC card 1 in the first install command for declaring the program name (Load File AID) of the application.

すなわち、再追加を不可とするアプリケーションをICカード1に追加する場合、上記上位装置2は、追加するアプリケーションのプログラム名(Load File AID)としてのプログラムコードを宣言する第1のインストールコマンドをICカード1へ送信する。この第1のインストールコマンドには、再追加不許可情報を含むものとする。つまり、上記上位装置2は、再追加を不可とするアプリケーションについては、当該アプリケーションの再追加不許可情報を含む第1のインストールコマンドをICカード1へ送信する。この場合、上記再追加不許可情報は、アプリケーションのプログラム名(Load File AID)に対応づけられている。   That is, when an application that cannot be re-added is added to the IC card 1, the upper device 2 sends a first installation command for declaring a program code as a program name (Load File AID) of the application to be added to the IC card. Send to 1. This first installation command includes re-addition non-permission information. That is, for the application that cannot be re-added, the higher-level device 2 transmits a first installation command including re-addition disapproval information of the application to the IC card 1. In this case, the re-addition non-permission information is associated with the application program name (Load File AID).

これに対してICカード1では、上記H/W層21のUART14により第1のインストールコマンドを受信し、受信した第1のインストールコマンドを上記OS層22のカードOS31へ与える(ステップS1)。上記第1のインストールコマンドを受信すると、上記カードOS31では、当該アプリケーションのプログラム名(Load File AID)を定義するとともに、当該第1のインストールコマンドに再追加不許可情報があるか否かを判断する(ステップS2)。   On the other hand, in the IC card 1, the first install command is received by the UART 14 of the H / W layer 21, and the received first install command is given to the card OS 31 of the OS layer 22 (step S1). When the first install command is received, the card OS 31 defines the program name (Load File AID) of the application and determines whether or not the re-addition non-permission information is included in the first install command. (Step S2).

この判断により受信した第1のインストールコマンドに再追加不許可情報があると判断した場合(ステップS2、あり)、上記カードOS31は、その再追加不許可情報を当該アプリケーションのプログラム名(Load File AID)に対応づけて登録する(ステップS3)。なお、上記再追加不許可情報は、ソフトウエア的にはカードOS31内に記憶されるが、ハードウエア的には上記不揮発性メモリ15内に記憶される。   When it is determined that the re-addition non-permission information is included in the first install command received by this determination (Yes in step S2), the card OS 31 uses the re-addition non-permission information as the program name (Load File AID) of the application. ) And register (step S3). The re-addition non-permission information is stored in the card OS 31 in terms of software, but is stored in the nonvolatile memory 15 in terms of hardware.

上記第1のインストールコマンドに応じたアプリケーションのプログラム名の定義および当該アプリケーションの再追加不許可情報を登録が完了すると、上記カードOS31は、当該第1のインストールコマンドに対する処理が正常に終了したことを示すステータスを上位装置2へ返す。   When the registration of the definition of the program name of the application corresponding to the first installation command and the re-addition non-permission information of the application is completed, the card OS 31 confirms that the processing for the first installation command has been completed normally. The status shown is returned to the host device 2.

上記第1のインストールコマンドが正常に終了した旨のステータスを受信した上位装置2では、当該アプリケーションのプログラムの実体(プログラムを構成するデータ)をロードするロードコマンドを当該ICカード1へ送信する。上記ロードコマンドは、当該アプリケーションのデータ量や上位装置とICカードとの通信能力等に応じて複数回実施される。このようなロードコマンドに対して、上記ICカード1では、上記上位装置2からのロードコマンドを受信するごとに、当該アプリケーションのプログラムを上記不揮発性メモリ15に記憶(ロード)し、その処理結果を上記上位装置2へ返す(ステップS4)。   The host device 2 that has received the status indicating that the first installation command has been normally completed transmits a load command for loading the actual program (data constituting the program) of the application to the IC card 1. The load command is executed a plurality of times according to the data amount of the application, the communication capability between the host device and the IC card, and the like. In response to such a load command, the IC card 1 stores (loads) the application program in the non-volatile memory 15 each time it receives a load command from the host device 2, and displays the processing result. Return to the host device 2 (step S4).

このような動作によってアプリケーションのプログラムのロードが完了すると、複数のロードコマンドによりロードされたアプリケーションのプログラムは、上記第1のインストールコマンドによって定義されたプログラム名の1つのアプリケーションとして上記アプリケーション層23に追加(作成)される(ステップS5)。これは、ハードウエア的には、上記アプリケーションが不揮発性メモリ15に記憶されたことを示す。   When loading of the application program is completed by such an operation, the application program loaded by the plurality of load commands is added to the application layer 23 as one application having the program name defined by the first installation command. (Created) (Step S5). This indicates that the application is stored in the nonvolatile memory 15 in terms of hardware.

このような複数のロードコマンドに対する処理が正常終了した旨を受信した上位装置2では、さらに、ロードしたアプリケーションのデータ名(Application AID)を宣言する第2のインストールコマンドをICカード1へ送信する。   The host device 2 that has received the notification that the processing for the plurality of load commands has been normally completed further transmits a second install command for declaring the data name (Application AID) of the loaded application to the IC card 1.

これに対してICカード1では、上記H/W層21のUART14により第2のインストールコマンドを受信し、受信した第2のインストールコマンドを上記OS層22のカードOS31へ与える(ステップS6)。当該ICカード1のカードOS31では、上記ステップS5で上記アプリケーション層23に追加された当該アプリケーションのデータを追加し、その名前(Application AID)を定義する(ステップS7)。
上記第2のインストールコマンドに応じたアプリケーションのデータ名の追加が完了すると、上記カードOS31は、当該第2のインストールコマンドに対する処理が正常に終了したことを示すステータスを上位装置2へ返す。
On the other hand, in the IC card 1, the second install command is received by the UART 14 of the H / W layer 21, and the received second install command is given to the card OS 31 of the OS layer 22 (step S6). In the card OS 31 of the IC card 1, the data of the application added to the application layer 23 in step S5 is added, and the name (Application AID) is defined (step S7).
When the addition of the data name of the application corresponding to the second installation command is completed, the card OS 31 returns a status indicating that the processing for the second installation command has been completed normally to the higher-level device 2.

上記のように、第1のパターンによれば、再追加不可とするアプリケーションをICカードに追加する上位装置では、アプリケーションのプログラムの名前(Load File AID)をICカードに宣言する第1のインストールコマンドにおいて再追加不許可情報をICカードに送信し、ICカードでは、第1のインストールコマンドに対して再追加不許可情報の有無を確認し、再追加不許可情報が含まれている場合には、そのアプリケーションのプログラム(名前はLoad File AID)を再追加不可とするアプリケーションとして登録するようにしたものである。   As described above, according to the first pattern, in a host device that adds an application that cannot be re-added to the IC card, the first installation command that declares the name of the application program (Load File AID) to the IC card. If the re-addition non-permission information is included in the IC card, the re-addition non-permission information is confirmed with respect to the first installation command. The application program (named “Load File AID”) is registered as an application that cannot be added again.

これにより、第1のパターンによれば、再追加を不可とするアプリケーションについては、インストール時に、当該アプリケーションのプログラム名を宣言する第1のインストールコマンドにて、当該アプリケーションのプログラム名に対応して再追加不許可情報を設定することができ、当該アプリケーションの再追加を不可とすることが可能となる。   Thus, according to the first pattern, for an application that cannot be re-added, the first install command that declares the program name of the application is re-corresponding to the program name of the application at the time of installation. Addition non-permission information can be set, and re-addition of the application can be disabled.

次に、上記再追加不許可情報を登録する処理の例としての第2のパターンについて説明する。
図4は、上記再追加不許可情報を登録する処理の例としての第2のパターンを説明するためのフローチャートである。
図4に示す第2のパターンでは、アプリケーションのプログラムを転送(ロード)するロードコマンドにおいて当該アプリケーションの再追加不許可情報をICカードに登録する。
Next, a second pattern as an example of processing for registering the re-addition non-permission information will be described.
FIG. 4 is a flowchart for explaining a second pattern as an example of a process for registering the re-addition non-permission information.
In the second pattern shown in FIG. 4, the re-addition non-permission information of the application is registered in the IC card in the load command for transferring (loading) the application program.

すなわち、再追加を不可とするアプリケーションをICカード1に追加する場合、上記上位装置2は、まず、追加するアプリケーションのプログラムの名前(Load File AID)としてロードするプログラムのコードを宣言する第1のインストールコマンドをICカード1へ送信する。   That is, when an application that cannot be re-added is added to the IC card 1, the upper device 2 first declares the code of the program to be loaded as the name of the program of the application to be added (Load File AID). An installation command is transmitted to the IC card 1.

これに対してICカード1では、上記H/W層21のUART14により第1のインストールコマンドを受信し、受信した第1のインストールコマンドを上記OS層22のカードOS31へ与える。上記カードOS31では、当該アプリケーションのプログラム名(Load File AID)を定義する(ステップS11)、このような上記第1のインストールコマンドに応じたアプリケーションのプログラム名の定義が完了すると、上記カードOS31は、当該第1のインストールコマンドに対する処理が正常に終了したことを示すステータスを上位装置2へ返す。   On the other hand, in the IC card 1, the first install command is received by the UART 14 of the H / W layer 21 and the received first install command is given to the card OS 31 of the OS layer 22. The card OS 31 defines a program name (Load File AID) of the application (step S11). When the definition of the program name of the application according to the first installation command is completed, the card OS 31 A status indicating that the processing for the first installation command has been completed normally is returned to the host device 2.

上記第1のインストールコマンドが正常に終了した旨のステータスを受信した上位装置2では、当該アプリケーションのプログラム(プログラムを構成するデータ)をロードするためのロードコマンドを当該ICカード1へ送信する。上記ロードコマンドは、当該アプリケーションのデータ量や上位装置とICカードとの通信能力等に応じて複数回実施される。   The host device 2 that has received the status indicating that the first install command has been normally completed transmits a load command for loading the application program (data constituting the program) to the IC card 1. The load command is executed a plurality of times according to the data amount of the application, the communication capability between the host device and the IC card, and the like.

また、これらのロードコマンドの何れか1つには、再追加不許可情報を含むものとする。つまり、上記上位装置2は、再追加を不可とするアプリケーションについては、当該アプリケーションの再追加不許可情報を含むロードコマンド(複数回ロードコマンドを実施する場合には何れか1つのロードコマンド)をICカード1へ送信する。また、ロードコマンドに含まれる再追加不許可情報は、アプリケーションのプログラム名(Load File AID)に対応づけられている。なお、上記再追加不許可情報は、複数のロードコマンドのうちどのロードコマンドに含めるようにしても良く、たとえば、最初のロードコマンドや最後のロードコマンドに含めるようにすれば良い。   In addition, any one of these load commands includes re-addition non-permission information. That is, for the application that cannot be re-added, the host device 2 sends a load command including re-addition disapproval information for the application (any one load command when executing a load command multiple times) to the IC. Send to card 1. Further, the re-addition non-permission information included in the load command is associated with the application program name (Load File AID). The re-addition non-permission information may be included in any load command among a plurality of load commands. For example, it may be included in the first load command or the last load command.

このような上位装置から受信したロードコマンドに再追加不許可情報が含まれていない場合(ステップS13、なし)、上記ICカード1では、上記上位装置2からのロードコマンドを受信するごとに、当該アプリケーションのプログラムを上記不揮発性メモリ15に記憶(ロード)し、その処理結果を上記上位装置2へ返す(ステップS12)。   When the re-addition non-permission information is not included in the load command received from such a host device (step S13, none), the IC card 1 receives the load command from the host device 2 every time the load command is received. The application program is stored (loaded) in the nonvolatile memory 15, and the processing result is returned to the host device 2 (step S12).

また、上位装置から受信したロードコマンドに再追加不許可情報が含まれていた場合(ステップS13、あり)、上記カードOS31は、受信したロードコマンドにより当該アプリケーションのプログラムを上記不揮発性メモリ15に記憶(ロード)するとともに、そのロードコマンドに含まれている再追加不許可情報を当該アプリケーションのプログラム名(Load File AID)に対応づけて登録する(ステップS14)。なお、上記再追加不許可情報は、ソフトウエア的にはカードOS31内に記憶されるが、ハードウエア的には上記不揮発性メモリ15内に記憶される。   If the load command received from the host device includes re-addition non-permission information (Yes in step S13), the card OS 31 stores the application program in the nonvolatile memory 15 by the received load command. (Reload) and register the re-addition non-permission information included in the load command in association with the program name (Load File AID) of the application (step S14). The re-addition non-permission information is stored in the card OS 31 in terms of software, but is stored in the nonvolatile memory 15 in terms of hardware.

上記のような複数のロードコマンドによるアプリケーションのプログラムのロードが完了すると、カードOS31は、複数のロードコマンドによりロードしたアプリケーションのプログラムは、上記第1のインストールコマンドによって定義されたプログラム名の1つのアプリケーションとして上記アプリケーション層23に追加(作成)する(ステップS15)。これは、ハードウエア的には、上記アプリケーションが不揮発性メモリ15に記憶されたことを示す。   When the loading of the application program by the plurality of load commands as described above is completed, the card OS 31 indicates that the application program loaded by the plurality of load commands is one application having the program name defined by the first installation command. Is added (created) to the application layer 23 (step S15). This indicates that the application is stored in the nonvolatile memory 15 in terms of hardware.

このような複数のロードコマンドに対する処理が正常終了した旨を受信した上位装置2では、さらに、ロードしたアプリケーションのデータ名(Application AID)を宣言する第2のインストールコマンドをICカード1へ送信する。
これに対してICカード1では、上記ステップS6およびS7と同様に、受信した第2のインストールコマンドに基づいて上記アプリケーション層23に追加された当該アプリケーションのデータを追加し(ステップS16)、名前(Application AID)を定義し(ステップS17)、当該第2のインストールコマンドに対する処理が正常に終了したことを示すステータスを上位装置2へ返す。
The host device 2 that has received the notification that the processing for the plurality of load commands has been normally completed further transmits a second install command for declaring the data name (Application AID) of the loaded application to the IC card 1.
On the other hand, the IC card 1 adds the data of the application added to the application layer 23 based on the received second installation command (step S16), as in steps S6 and S7. (Application AID) is defined (step S17), and a status indicating that the processing for the second installation command has been completed normally is returned to the host device 2.

上記のように、第2のパターンによれば、再追加不可とするアプリケーションをICカードに追加する上位装置では、アプリケーションのプログラムをロードするロードコマンドにおいて再追加不許可情報をICカードに送信し、ICカードでは、ロードコマンドに対して再追加不許可情報の有無を確認し、再追加不許可情報が含まれている場合には、そのアプリケーションのプログラム(名前はLoad File AID)を再追加不可とするアプリケーションとして登録するようにしたものである。   As described above, according to the second pattern, the host device that adds an application that cannot be re-added to the IC card transmits re-addition non-permission information to the IC card in the load command that loads the application program. The IC card confirms the presence / absence of re-addition non-permission information in response to the load command. If re-addition non-permission information is included, the application program (name is Load File AID) cannot be re-added. It is intended to be registered as an application to be used.

これにより、上述した第2のパターンによれば、再追加を不可とするアプリケーションについては、そのインストール時に、ロードコマンドにて、当該アプリケーションのプログラム名に対応して再追加不許可情報を設定することができ、当該アプリケーションの再追加を不可とすることが可能となる。   As a result, according to the second pattern described above, for an application that cannot be re-added, re-addition disapproval information is set corresponding to the program name of the application with the load command at the time of installation. And re-addition of the application can be disabled.

次に、上記再追加不許可情報を登録する処理の例としての第3のパターンについて説明する。
図5は、上記再追加不許可情報を登録する処理の例としての第3のパターンを説明するためのフローチャートである。
図5に示す第3のパターンでは、ロードされたアプリケーションのデータ名(Application AID)を宣言する第2のインストールコマンドにおいて、再追加不許可情報をICカード1に登録する。
Next, a third pattern as an example of processing for registering the re-addition non-permission information will be described.
FIG. 5 is a flowchart for explaining a third pattern as an example of a process for registering the re-addition non-permission information.
In the third pattern shown in FIG. 5, the re-addition non-permission information is registered in the IC card 1 in the second installation command for declaring the data name (Application AID) of the loaded application.

すなわち、再追加を不可とするアプリケーションをICカード1に追加する場合、上記上位装置2は、追加するアプリケーションのプログラム名(アプリケーションプログラムを構成するデータ)としてロードするデータのファイル名を宣言する第1のインストールコマンドをICカード1へ送信する。これに対してICカード1のカードOS31では、上記ステップS11と同様に、受信した第1のインストールコマンドに基づいて、当該アプリケーションのプログラム名(Load File AID)を定義し(ステップS21)、当該第1のインストールコマンドに対する処理が正常に終了したことを示すステータスを上位装置2へ返す。   That is, when an application that cannot be re-added is added to the IC card 1, the host device 2 declares a file name of data to be loaded as a program name of the application to be added (data constituting the application program). Is sent to the IC card 1. On the other hand, the card OS 31 of the IC card 1 defines the program name (Load File AID) of the application based on the received first install command (step S21), as in step S11. A status indicating that the processing for the install command of 1 is normally completed is returned to the higher-level device 2.

上記第1のインストールコマンドが正常に終了した旨のステータスを受信した上位装置2では、上記ステップS4と同様に、当該アプリケーションのプログラム(プログラムを構成するデータ)をロードする複数のロードコマンドを順次当該ICカード1へ送信する。このようなロードコマンドに対して、上記ICカード1では、上記上位装置2からのロードコマンドを受信するごとに、当該アプリケーションのプログラムを上記不揮発性メモリ15に記憶(ロード)し、その処理結果を上記上位装置2へ返す(ステップS22)。   In the host device 2 that has received the status indicating that the first installation command has been normally completed, a plurality of load commands for loading the application program (data constituting the program) are sequentially received in the same manner as in step S4. Send to IC card 1. In response to such a load command, the IC card 1 stores (loads) the application program in the non-volatile memory 15 each time it receives a load command from the host device 2, and displays the processing result. It returns to the higher order apparatus 2 (step S22).

複数のロードコマンドによりロードされたアプリケーションのプログラムは、上記第1のインストールコマンドによって定義されたプログラム名の1つのアプリケーションとして上記アプリケーション層23に追加(作成)される(ステップS23)。これは、ハードウエア的には、上記アプリケーションが不揮発性メモリ15に記憶されたことを示す。   An application program loaded by a plurality of load commands is added (created) to the application layer 23 as one application having a program name defined by the first installation command (step S23). This indicates that the application is stored in the nonvolatile memory 15 in terms of hardware.

このような複数のロードコマンドに対する処理が正常終了した旨をICカード1から受信した上位装置2では、さらに、ロードしたアプリケーションのデータ名(Application AID)を宣言する第2のインストールコマンドをICカード1へ送信する。この第2のインストールコマンドには、再追加不許可情報を含むものとする。つまり、上記上位装置2は、再追加を不可とするアプリケーションについては、当該アプリケーションの再追加不許可情報を含む第2のインストールコマンドをICカード1へ送信する。この場合、上記再追加不許可情報は、アプリケーションのデータ名(Application AID)に対応づけられている。   In the host device 2 that has received from the IC card 1 that processing for a plurality of load commands has been normally completed, a second install command for declaring the data name (Application AID) of the loaded application is further sent to the IC card 1. Send to. This second installation command includes re-addition non-permission information. That is, for the application that cannot be re-added, the higher-level device 2 transmits a second installation command including re-addition disapproval information of the application to the IC card 1. In this case, the re-addition non-permission information is associated with an application data name (Application AID).

これに対してICカード1では、上記H/W層21のUART14により第2のインストールコマンドを受信し、受信した第2のインストールコマンドを上記OS層22のカードOS31へ与える(ステップS24)。上記カードOS31では、当該アプリケーションのデータを追加して当該アプリケーションのデータ名(Application AID)を定義するとともに、当該第2のインストールコマンドに再追加不許可情報があるか否かを判断する(ステップS25)。   On the other hand, in the IC card 1, the second install command is received by the UART 14 of the H / W layer 21, and the received second install command is given to the card OS 31 of the OS layer 22 (step S24). The card OS 31 adds the data of the application to define the data name (Application AID) of the application and determines whether the second installation command has re-addition non-permission information (step S25). ).

この判断により受信した第1のインストールコマンドに再追加不許可情報があると判断した場合(ステップS25、あり)、上記カードOS31は、その再追加不許可情報を当該アプリケーションのデータ名(Application AID)に対応づけて登録する(ステップS26)。なお、上記再追加不許可情報は、ソフトウエア的にはカードOS31内に記憶されるが、ハードウエア的には上記不揮発性メモリ15内に記憶される。   When it is determined that the re-addition non-permission information is included in the first installation command received by this determination (Yes in step S25), the card OS 31 uses the re-addition non-permission information as the data name (Application AID) of the application. Is registered in association with (step S26). The re-addition non-permission information is stored in the card OS 31 in terms of software, but is stored in the nonvolatile memory 15 in terms of hardware.

上記第2のインストールコマンドに応じたアプリケーションのデータ(名前はApplication AID)の追加および当該アプリケーションの再追加不許可情報を登録が完了すると、上記カードOS31は、当該第2のインストールコマンドに対する処理が正常に終了したことを示すステータスを上位装置2へ返す。   When the addition of application data (name is Application AID) in accordance with the second install command and the registration of the re-addition disapproval information for the application are completed, the card OS 31 performs normal processing for the second install command. The status indicating completion is returned to the host device 2.

上記のように、第3のパターンによれば、再追加不可とするアプリケーションをICカードに追加する上位装置では、アプリケーションのデータの名前(Application AID)をICカードに宣言する第2のインストールコマンドにおいて再追加不許可情報をICカードに送信し、ICカードでは、第2のインストールコマンドに対して再追加不許可情報の有無を確認し、再追加不許可情報が含まれている場合には、そのアプリケーションのデータ(名前はApplication AID)を再追加不可とするアプリケーションとして登録するようにしたものである。   As described above, according to the third pattern, in the host device that adds an application that cannot be re-added to the IC card, in the second install command that declares the name of the application data (Application AID) to the IC card. The re-addition non-permission information is transmitted to the IC card, and the IC card confirms the presence / absence of the re-addition non-permission information with respect to the second installation command. Application data (name is Application AID) is registered as an application that cannot be added again.

これにより、第3のパターンによれば、再追加を不可とするアプリケーションについては、インストール時に、当該アプリケーションのデータ名を宣言する第2のインストールコマンドにて、当該アプリケーションのプログラム名に対応して再追加不許可情報を設定することができ、当該アプリケーションの再追加を不可とすることが可能となる。   Thus, according to the third pattern, for an application that cannot be re-added, the second install command that declares the data name of the application is re-corresponding to the program name of the application at the time of installation. Addition non-permission information can be set, and re-addition of the application can be disabled.

次に、上記再追加不許可情報を登録する処理の例としての第4のパターンについて説明する。
図6は、上記再追加不許可情報を登録する処理の例としての第4のパターンを説明するためのフローチャートである。
図6に示す第4のパターンでは、アプリケーションの実行中において、当該アプリケーション自身が再追加不許可情報をICカード1に登録する。
Next, a fourth pattern as an example of processing for registering the re-addition non-permission information will be described.
FIG. 6 is a flowchart for explaining a fourth pattern as an example of a process for registering the re-addition non-permission information.
In the fourth pattern shown in FIG. 6, the application itself registers re-addition non-permission information in the IC card 1 during execution of the application.

ここで、上記上位装置2が再追加不可とするアプリケーションの実行を要求するコマンドをICカード1へ送信したものとする。これに対してICカード1では、上位装置2からのアプリケーションの実行を要求するコマンドを受信し(ステップS31)、上記カードOS31によりアプリケーション層23の当該アプリケーションに対して実行の指示を行う。これにより、アプリケーション層23のアプリケーションが開始される(ステップS32)。   Here, it is assumed that the host device 2 transmits a command requesting execution of an application that cannot be added again to the IC card 1. On the other hand, the IC card 1 receives a command for requesting execution of the application from the host device 2 (step S31), and the card OS 31 instructs the application in the application layer 23 to execute. Thereby, the application of the application layer 23 is started (step S32).

上記アプリケーション層23のアプリケーションは、当該アプリケーションの再追加が不可である場合、再追加不許可情報の登録処理を行う。この再追加不許可情報の登録処理では、当該アプリケーションが上記OS層22のAPI群34に対して当該アプリケーション自身の再追加不許可情報の登録処理を行うためのAPI34aを呼び出す(ステップS33)。なお、API群34はアプリケーションで使用される関数などを示すAPIからなり、再追加不許可情報の登録処理を行うためのAPI34aは予め設定されているものとする。   When the application of the application layer 23 cannot be re-added, the application layer 23 performs registration processing of re-addition non-permission information. In the re-addition non-permission information registration process, the application calls the API 34a for performing the re-addition non-permission information registration process of the application itself to the API group 34 of the OS layer 22 (step S33). It is assumed that the API group 34 includes APIs indicating functions used in the application, and an API 34a for performing re-addition non-permission information registration processing is set in advance.

上記アプリケーションに呼び出されたAPI34aは、上記データテーブル15aに再追加不許可情報が登録されているアプリケーションのプログラム名(Load File AID)あるいはアプリケーションのデータ名(Application AID)を参照し、当該アプリケーションの再追加不許可情報が既に登録済みでないかを確認する。なお、当該アプリケーションの再追加不許可情報が登録済みであると判定した場合には上記ステップS36へ進み、当該アプリケーションを実行する(ステップS36)。   The API 34a called by the application refers to the program name (Load File AID) or the data name (Application AID) of the application in which the re-addition non-permission information is registered in the data table 15a. Check whether additional disapproval information has already been registered. If it is determined that the re-addition non-permission information of the application has been registered, the process proceeds to step S36 and the application is executed (step S36).

当該アプリケーションの再追加不許可情報が登録済みでないことを確認すると、上記API34aは、カードOS31に対して当該アプリケーションのプログラム名(Load File AID)あるいはアプリケーションのデータ名(Application AID)に対応づけて再追加不許可情報の登録の要求を行う。カードOS31では、API34aにより指定された当該アプリケーションのプログラム名(Load File AID)あるいはアプリケーションのデータ名(Application AID)の再追加不許可情報を上記データテーブル15aに登録する。   Upon confirming that the re-addition non-permission information of the application has not been registered, the API 34a re-associates the card OS 31 with the program name (Load File AID) of the application or the data name (Application AID) of the application. Request registration of additional non-permission information. In the card OS 31, re-addition disapproval information of the program name (Load File AID) or application data name (Application AID) designated by the API 34a is registered in the data table 15a.

この登録が正常に終了すると、カードOS31は、上記API34aを介して当該アプリケーションに再追加不許可情報の登録が正常終了した旨を通知する。この再追加不許可情報の登録が正常終了した旨の通知を受けると、当該アプリケーションは、当該アプリケーションの本体となる残りのプログラムを実行する(ステップS36)。   When this registration is completed normally, the card OS 31 notifies the application that the registration of the re-addition non-permission information has been completed normally via the API 34a. When receiving the notification that the registration of the re-addition non-permission information has been normally completed, the application executes the remaining program serving as the main body of the application (step S36).

上記のように、第4のパターンでは、ICカードにインストールされているアプリケーションが自身のアプリケーションのプログラム名(Load File AID)あるいはアプリケーションのデータ名(Application AID)を再追加不許可情報としてカードOSに登録するようにしたものである。   As described above, in the fourth pattern, the application installed in the IC card uses the program name (Load File AID) of the application itself or the data name (Application AID) of the application as re-addition non-permission information to the card OS. It is intended to be registered.

これにより、第4のパターンによれば、再追加を不可とするアプリケーションについては、そのアプリケーションの実行時に、自身のアプリケーションの再追加を不許可とするための、当該アプリケーションのプログラム名(Load File AID)あるいはアプリケーションのデータ名(Application AID)に対応づけた再追加不許可情報を設定することができ、当該アプリケーションの再追加を不可とすることが可能となる。   Thus, according to the fourth pattern, for an application that cannot be re-added, the program name of the application (Load File AID) for disallowing re-adding of its own application when the application is executed ) Or re-addition non-permission information associated with an application data name (Application AID), and re-addition of the application can be disabled.

また、上記第4のパターンによれば、アプリケーションのインストールや削除の過程では、再追加不許可情報を登録する処理が不要となり、上位装置から再追加不許可情報の登録を指示する必要がなくなる。つまり、アプリケーションの処理の1つとして再追加不許可情報の登録処理を行うことができるため、ICカード内での処理で再追加不許可情報を登録でき、上位装置からのアプリケーションの追加や削除は従来の手順で実行できる。さらに、この結果として、上位装置とICカードとからなるシステムとしての動作が従来と同様であっても上記のような動作が実施可能となる。   Further, according to the fourth pattern, the process of registering the re-addition non-permission information is not required in the process of application installation or deletion, and it is not necessary to instruct the registration of the re-addition non-permission information from the host device. In other words, since re-addition non-permission information registration processing can be performed as one of the application processes, re-addition non-permission information can be registered by processing within the IC card, and addition and deletion of applications from the host device It can be executed by a conventional procedure. Furthermore, as a result, the above operation can be performed even if the operation of the system composed of the host device and the IC card is the same as the conventional one.

なお、上記第4のパターンでは、アプリケーションが自身のアプリケーションの再追加を不可とするような再追加不許可情報を登録するものとしたが、任意のアプリケーションの追加を不可とするような追加不許可情報を登録するようにしても良い。すなわち、上記第4のパターンでは、アプリケーションが実行する処理として再追加不許可情報を登録するようにしているため、当該アプリケーション自身以外の任意のアプリケーションの追加(インストール)を不可とするような情報を登録することができる。この場合、たとえば、追加を不可とするアプリケーションは、処理を実行するアプリケーションにより呼び出されるAPI34aの引数定義により指定可能である。   In the fourth pattern, the re-addition non-permission information is registered so that the application cannot re-add its own application. However, the addition non-permission that prohibits addition of any application is prohibited. Information may be registered. That is, in the fourth pattern, since re-addition non-permission information is registered as processing executed by the application, information that makes it impossible to add (install) any application other than the application itself is displayed. You can register. In this case, for example, an application that cannot be added can be specified by an argument definition of the API 34a called by the application that executes the process.

次に、上記再追加不許可情報を登録する処理の例としての第5のパターンについて説明する。
図7は、上記再追加不許可情報を登録する処理の例としての第5のパターンを説明するためのフローチャートである。
図7に示す第5のパターンでは、アプリケーションを削除する削除コマンドにおいて、当該アプリケーションに対する再追加不許可情報をICカード1に登録する。
Next, a fifth pattern as an example of a process for registering the re-addition non-permission information will be described.
FIG. 7 is a flowchart for explaining a fifth pattern as an example of processing for registering the re-addition non-permission information.
In the fifth pattern shown in FIG. 7, re-addition non-permission information for the application is registered in the IC card 1 in the delete command for deleting the application.

すなわち、再追加を不可とするアプリケーションをICカード1から削除する場合、上記上位装置2は、削除するアプリケーションの名前(Application AID)を宣言する削除コマンドをICカード1へ送信する。この削除コマンドには、再追加不許可情報を含むものとする。つまり、上記上位装置2は、再追加を不可とするアプリケーションについては、当該アプリケーションの再追加不許可情報を含む削除コマンドをICカード1へ送信する。この場合、上記再追加不許可情報は、アプリケーションのプログラム名(Load File AID)あるいはアプリケーションのデータ名(Application AID)に対応づけられている。   That is, when an application that cannot be re-added is deleted from the IC card 1, the higher-level device 2 transmits a delete command that declares the name of the application to be deleted (Application AID) to the IC card 1. This deletion command includes re-addition non-permission information. That is, for the application that cannot be re-added, the host device 2 transmits a delete command including re-addition disapproval information of the application to the IC card 1. In this case, the re-addition non-permission information is associated with an application program name (Load File AID) or an application data name (Application AID).

これに対してICカード1では、上記H/W層21のUART14により削除コマンドを受信し、受信した削除コマンドを上記OS層22のカードOS31へ与える(ステップS41)。上記カードOS31では、削除コマンドを受信した際、当該削除コマンドに再追加不許可情報があるか否かを判断する(ステップS42)。   On the other hand, in the IC card 1, the delete command is received by the UART 14 of the H / W layer 21, and the received delete command is given to the card OS 31 of the OS layer 22 (step S41). When receiving the deletion command, the card OS 31 determines whether or not the deletion command includes re-addition non-permission information (step S42).

この判断により受信した削除コマンドに再追加不許可情報があると判断した場合(ステップS42、あり)、上記カードOS31は、その再追加不許可情報を当該アプリケーションのプログラム名(Load File AID)あるいはアプリケーションのデータ名(Application AID)に対応づけて登録する(ステップS43)。なお、上記再追加不許可情報は、ソフトウエア的にはカードOS31内に記憶されるが、ハードウエア的には上記不揮発性メモリ15内に記憶される。   When it is determined that the re-addition non-permission information is included in the delete command received by this determination (Yes in step S42), the card OS 31 uses the re-addition non-permission information as the program name (Load File AID) or application of the application. Are registered in association with the data name (Application AID) (step S43). The re-addition non-permission information is stored in the card OS 31 in terms of software, but is stored in the nonvolatile memory 15 in terms of hardware.

さらに、上記カードOS31は、受信した削除コマンドにより指定されるアプリケーション(名前はApplication AID)を不揮発性メモリ15上から削除する処理を行う。これにより、上記削除コマンドに応じた当該アプリケーションの再追加不許可情報の登録およびアプリケーションの削除が完了すると、上記カードOS31は、当該削除コマンドに対する処理が正常に終了したことを示すステータスを上位装置2へ返す。   Further, the card OS 31 performs a process of deleting the application (named Application AID) designated by the received delete command from the nonvolatile memory 15. As a result, when the registration of the re-addition non-permission information for the application and the deletion of the application in accordance with the deletion command are completed, the card OS 31 displays a status indicating that the processing for the deletion command has been completed normally. Return to.

上記のように、第5のパターンによれば、上位装置2では、再追加不可とするアプリケーションを削除する際、削除するアプリケーションのデータ名(Application AID)をICカードに宣言する削除コマンドに再追加不許可情報を付加してICカードへ送信し、ICカードでは、削除コマンドに対して再追加不許可情報の有無を確認し、再追加不許可情報が含まれている場合には、当該アプリケーションのプログラム名(Load File AID)あるいはアプリケーションのデータ名(Application AID)を再追加不可とするアプリケーションとして登録するようにしたものである。   As described above, according to the fifth pattern, when deleting the application that cannot be re-added, the host device 2 re-adds the data name (Application AID) of the application to be deleted to the delete command that declares to the IC card. The non-permission information is added and transmitted to the IC card. In the IC card, the presence / absence of re-addition non-permission information is confirmed in response to the delete command. A program name (Load File AID) or an application data name (Application AID) is registered as an application that cannot be added again.

これにより、第5のパターンによれば、再追加を不可とするアプリケーションについては、削除時に、当該アプリケーションの削除を要求する削除コマンドにて、当該アプリケーションのプログラム名(Load File AID)あるいはアプリケーションのデータ名(Application AID)に対応づけた再追加不許可情報を設定することができ、当該アプリケーションの再追加を不可とすることが可能となる。   As a result, according to the fifth pattern, for an application that cannot be re-added, the program name (Load File AID) or application data of the application is deleted by a deletion command that requests deletion of the application at the time of deletion. Re-addition non-permission information associated with a name (Application AID) can be set, and re-addition of the application can be disabled.

この場合、アプリケーションのインストールおよび実行の過程では、再追加不許可情報を登録する処理が不要となる。つまり、削除しないアプリケーションについては、アプリケーション自身の使用回数制限によって使用回数を制限でき、当該アプリケーションの再追加を制限するための上記のような再追加不許可情報を登録する必要がない。たとえば、ICカードの運用形態が簡単にアプリケーションの削除しないような形態であれば、インストール時に再追加不許可情報を登録するなどの無駄な処理が不要となる。   In this case, the process of registering the re-addition non-permission information is not required in the process of application installation and execution. That is, for applications that are not deleted, the number of uses can be limited by limiting the number of uses of the application itself, and there is no need to register re-addition non-permission information as described above for limiting re-addition of the application. For example, if the operation mode of the IC card is such that the application is not easily deleted, useless processing such as registration of re-addition non-permission information at the time of installation becomes unnecessary.

次に、上記ICカード1にアプリケーションの追加する際の具体例な動作例について説明する。
上記のような再追加不許可情報に基づいてアプリケーションの追加を制限する処理は、アプリケーションのインストール時に実行される。本実施の形態では、アプリケーションの追加を制限する処理の具体例として、たとえば、図8〜図10に示すような3つのパターンについて説明するものとする。
Next, a specific operation example when an application is added to the IC card 1 will be described.
The process for restricting the addition of an application based on the re-addition non-permission information as described above is executed when the application is installed. In the present embodiment, for example, three patterns as shown in FIGS. 8 to 10 will be described as specific examples of processing for restricting addition of applications.

まず、アプリケーションの追加を制限する処理の例としての第6のパターンについて説明する。
図8は、アプリケーションの追加を制限する処理の例としての第6のパターンを説明するためのフローチャートである。
図8に示す第6のパターンでは、アプリケーションのプログラム名(Load File AID)を宣言する第1のインストールコマンドを受信した際に、当該アプリケーションの追加の可否を判断するものである。
First, a sixth pattern as an example of processing for restricting addition of an application will be described.
FIG. 8 is a flowchart for explaining a sixth pattern as an example of processing for restricting addition of an application.
In the sixth pattern shown in FIG. 8, when the first install command for declaring the program name (Load File AID) of the application is received, it is determined whether or not the application can be added.

ここで、上位装置2から追加するアプリケーションのプログラム名(Load File AID)を宣言する第1のインストールコマンドがICカード1へ送信されたものとする。上位装置2から第1のインストールコマンドを受信すると(ステップS61)、ICカード1のカードOS31は、まず、当該第1のインストールコマンドにより指定されたアプリケーションのプログラム名(Load File AID)に基づいて上記データテーブル15aに登録されているアプリケーションのプログラム名(Load File AID)を検索する(ステップS62)。   Here, it is assumed that the first installation command for declaring the program name (Load File AID) of the application to be added is transmitted from the host device 2 to the IC card 1. When the first install command is received from the host device 2 (step S61), the card OS 31 of the IC card 1 firstly executes the above-mentioned based on the program name (Load File AID) of the application designated by the first install command. The program name (Load File AID) of the application registered in the data table 15a is searched (step S62).

この検索の結果に基づいて、上記カードOS31は、当該第1のインストールコマンドにより指定されたアプリケーションのプログラム名(Load File AID)と完全に一致するか、あるいは一部が一致するアプリケーションのプログラム名(Load File AID)が上記データテーブル15aに登録されているか否かを判断する(ステップS63)。   Based on the result of this search, the card OS 31 matches the program name (Load File AID) of the application specified by the first installation command completely or partially matches the program name of the application ( It is determined whether or not (Load File AID) is registered in the data table 15a (step S63).

ここで、一部一致とは、当該第1のインストールコマンドにより指定されたアプリケーションのプログラム名の一部とデータテーブル15aに登録されているアプリケーションのプログラム名の一部が一致することでプログラム名が同じアプリケーションであることが判断できる場合である。たとえば、当該第1のインストールコマンドにより指定されたアプリケーションのプログラム名の上位部分がデータテーブル15aに登録されているアプリケーションのプログラム名の上位部分と一意に一致すれば、両者が一致したと判断するようにするものである。   Here, “partial match” means that a part of the program name of the application specified by the first installation command and a part of the program name of the application registered in the data table 15a match each other. This is a case where it can be determined that the applications are the same. For example, if the upper part of the program name of the application specified by the first installation command uniquely matches the upper part of the program name of the application registered in the data table 15a, it is determined that the two match. It is to make.

上記判断により当該第1のインストールコマンドにより指定されたアプリケーションのプログラム名と完全一致あるいは一部一致するプログラム名がデータテーブル15aに登録されていると判断した場合(ステップS63、なし)、上記カードOS31は、当該アプリケーションのインストール処理を実行する。当該アプリケーションのインストール処理は、たとえば、上記第1のパターン、あるいは、上記第2のパターンにより実行される。   If it is determined by the above determination that a program name that completely or partially matches the program name of the application specified by the first install command is registered in the data table 15a (step S63, none), the card OS 31 Executes the installation process of the application. The application installation process is executed by, for example, the first pattern or the second pattern.

また、上記判断により当該第1のインストールコマンドにより指定されたアプリケーションのプログラム名と完全一致あるいは一部一致するプログラム名がデータテーブル15aに登録されていると判断した場合(ステップS63、あり)、上記カードOS31は、当該アプリケーションの追加(再追加)を不許可とし、当該第1のインストールコマンドに対する処理が異常終了したことを示すステータスを上位装置2へ通知する(ステップS64)。これにより、上記ICカード1には、当該アプリケーションを追加することが不許可となる。   If it is determined by the above determination that a program name that completely or partially matches the program name of the application specified by the first installation command is registered in the data table 15a (step S63, present), The card OS 31 disallows the addition (re-addition) of the application, and notifies the host device 2 of a status indicating that the process for the first installation command has ended abnormally (step S64). As a result, it is not permitted to add the application to the IC card 1.

上記のように、第6のパターンでは、上位装置から追加するアプリケーションのプログラム名を宣言する第1のインストールコマンドを受信した際に、当該アプリケーションのプログラム名が再追加不可のアプリケーションのプログラム名として登録されているか否かを判断し、この判断により当該アプリケーションのプログラム名が再追加不可のアプリケーションのプログラム名として登録されていると判断した場合、当該アプリケーションのインストールを不可とするものである。   As described above, in the sixth pattern, when the first install command for declaring the program name of the application to be added is received from the host apparatus, the program name of the application is registered as the program name of the application that cannot be added again. If it is determined that the program name of the application is registered as the program name of an application that cannot be added again, the installation of the application is disabled.

これにより、再追加不可のアプリケーションとして登録されているプログラム名と一致するプログラム名のアプリケーションについては、そのプログラム名を宣言するインストールコマンドを受信した際にインストールを不可することができる。また、アプリケーションのプログラム名は容易に変更することができないため、上記第6のパターンによれば、アプリケーションのデータ名(Application AID)を変更しても同じプログラムからなるアプリケーションの再追加を不可とすることが可能となる。   As a result, for an application having a program name that matches the program name registered as an application that cannot be added again, installation can be disabled when an installation command that declares the program name is received. Further, since the program name of the application cannot be easily changed, according to the sixth pattern, it is impossible to re-add an application composed of the same program even if the data name (Application AID) of the application is changed. It becomes possible.

次に、アプリケーションの追加を制限する処理の例としての第7のパターンについて説明する。
図9は、アプリケーションの追加を制限する処理の例としての第7のパターンを説明するためのフローチャートである。
図9に示す第7のパターンでは、アプリケーションのプログラム(名前はLoad File AID)をロードするロードコマンドを受信した際に、当該アプリケーションの追加の可否を判断するものである。
Next, a seventh pattern as an example of processing for restricting addition of applications will be described.
FIG. 9 is a flowchart for explaining a seventh pattern as an example of processing for restricting addition of an application.
In the seventh pattern shown in FIG. 9, when a load command for loading an application program (named Load File AID) is received, it is determined whether or not the application can be added.

ここで、上位装置2から追加するアプリケーションのプログラム名(Load File AID)を宣言する第1のインストールコマンドがICカード1へ送信されたものとする。上位装置2から第1のインストールコマンドを受信すると、ICカード1のカードOS31は、まず、当該第1のインストールコマンドにより指定されたアプリケーションのプログラム名(Load File AID)を設定し、その処理結果を上位装置2へ通知する。   Here, it is assumed that the first installation command for declaring the program name (Load File AID) of the application to be added is transmitted from the host device 2 to the IC card 1. When the first install command is received from the host device 2, the card OS 31 of the IC card 1 first sets the program name (Load File AID) of the application designated by the first install command, and the processing result is displayed. Notify the host device 2.

上記上位装置2では、第1のインストールコマンドに対する処理が正常終了した旨の通知を受けて、当該アプリケーションのプログラムをロードするロードコマンドを送信する。このロードコマンドは、当該アプリケーションのプログラムのデータ量やICカード1との通信能力に応じて複数回実施される。   In response to the notification that the processing for the first installation command has been completed normally, the host device 2 transmits a load command for loading the application program. This load command is executed a plurality of times according to the data amount of the program of the application and the communication capability with the IC card 1.

上位装置2からロードコマンドを受信すると、ICカード1のカードOS31は、受信したロードコマンドに従ってアプリケーションのプログラムをロードする処理を行う(ステップS72)。この際、上記カードOS31は、ロードするアプリケーションのプログラム名(Load File AID)に基づいて上記データテーブル15aに登録されているアプリケーションのプログラム名(Load File AID)を検索する(ステップS73)。   When the load command is received from the host device 2, the card OS 31 of the IC card 1 performs a process of loading the application program in accordance with the received load command (step S72). At this time, the card OS 31 searches for the program name (Load File AID) of the application registered in the data table 15a based on the program name (Load File AID) of the application to be loaded (Step S73).

なお、ロードコマンドが複数回実施される場合、上記カードOS31は、複数のロードコマンドのうち何れかのロードコマンドを受信した際に、検索処理を行う。たとえば、最初のロードコマンドを受信した際に、プログラム名に基づく検索を行うようにしても良いし、最終のロードコマンドを受信した際にプログラム名に基づく検索を行うようにしても良い。   When the load command is executed a plurality of times, the card OS 31 performs a search process when any one of the plurality of load commands is received. For example, a search based on the program name may be performed when the first load command is received, or a search based on the program name may be performed when the final load command is received.

この検索の結果に基づいて、上記カードOS31は、当該第1のインストールコマンドにより指定されたアプリケーションのプログラム名(Load File AID)と完全に一致するか、あるいは一部が一致するアプリケーションのプログラム名(Load File AID)が上記データテーブル15aに登録されているか否かを判断する(ステップS74)。   Based on the result of this search, the card OS 31 matches the program name (Load File AID) of the application specified by the first installation command completely or partially matches the program name of the application ( It is determined whether or not (Load File AID) is registered in the data table 15a (step S74).

上記判断により当該第1のインストールコマンドにより指定されたアプリケーションのプログラム名と完全一致あるいは一部一致するプログラム名がデータテーブル15aに登録されていると判断した場合(ステップS64、なし)、上記カードOS31は、当該アプリケーションのインストール処理を実行する。このアプリケーションのインストール処理は、たとえば、上記第2のパターンにより実行されるようにすれば良い。   When it is determined by the above determination that a program name that completely or partially matches the program name of the application specified by the first install command is registered in the data table 15a (step S64, none), the card OS 31 Executes the installation process of the application. The application installation process may be executed by the second pattern, for example.

また、上記判断により当該第1のインストールコマンドにより指定されたアプリケーションのプログラム名と完全一致あるいは一部一致するプログラム名がデータテーブル15aに登録されていると判断した場合(ステップS74、あり)、上記カードOS31は、当該アプリケーションの追加(再追加)を不許可とし、当該ロードコマンドに対する処理が異常終了したことを示すステータスを上位装置2へ通知する(ステップS75)。これにより、上記ICカード1には、当該アプリケーションを追加することが不許可となる。   If it is determined by the above determination that a program name that completely or partially matches the program name of the application specified by the first installation command is registered in the data table 15a (step S74, yes), The card OS 31 disallows the addition (re-addition) of the application, and notifies the host device 2 of a status indicating that the process for the load command has been terminated abnormally (step S75). As a result, it is not permitted to add the application to the IC card 1.

上記のように、第7のパターンでは、上位装置から追加するアプリケーションのプログラムをロードするロードコマンドを受信した際に、当該アプリケーションのプログラム名が再追加不可のアプリケーションのプログラム名として登録されているか否かを判断し、この判断により当該アプリケーションのプログラム名が再追加不可のアプリケーションのプログラム名として登録されていると判断した場合、当該アプリケーションのインストールを不可とするものである。   As described above, in the seventh pattern, when the load command for loading the application program to be added is received from the higher-level device, the program name of the application is registered as the program name of the application that cannot be added again. If it is determined that the program name of the application is registered as the program name of an application that cannot be added again, installation of the application is disabled.

これにより、再追加不可のアプリケーションとして登録されているプログラム名と一致するプログラム名のアプリケーションについては、そのプログラムをロードするインストールコマンドを受信した際にインストールを不可することができる。また、アプリケーションのプログラム名は容易に変更することができないため、上記第6のパターンと同様に、第7のパターンによれば、アプリケーションのデータ名(Application AID)を変更しても同じプログラムからなるアプリケーションの再追加を不可とすることが可能となる。   As a result, an application having a program name that matches the program name registered as a non-re-addable application can be prohibited from being installed when an installation command for loading the program is received. Further, since the program name of the application cannot be easily changed, according to the seventh pattern, the same program is formed even if the data name (Application AID) of the application is changed according to the seventh pattern. It becomes possible to make it impossible to add the application again.

次に、アプリケーションの追加を制限する処理の例としての第8のパターンについて説明する。
図10は、アプリケーションの追加を制限する処理の例としての第8のパターンを説明するためのフローチャートである。
図10に示す第8のパターンでは、アプリケーションのデータ名(Application AID)を宣言する第2のインストールコマンドを受信した際に、当該アプリケーションの追加の可否を判断するものである。
Next, an eighth pattern will be described as an example of processing for restricting addition of an application.
FIG. 10 is a flowchart for explaining an eighth pattern as an example of processing for restricting addition of an application.
In the eighth pattern shown in FIG. 10, when a second install command for declaring a data name (Application AID) of an application is received, it is determined whether or not the application can be added.

ここで、上位装置2から追加するアプリケーションのプログラム名(Load File AID)を宣言する第1のインストールコマンドがICカード1へ送信されたものとする。上位装置2から第1のインストールコマンドを受信すると、ICカード1のカードOS31は、当該第1のインストールコマンドにより指定されたアプリケーションのプログラム名(Load File AID)を設定し、その処理結果を上位装置2へ通知する(ステップS81)。   Here, it is assumed that the first installation command for declaring the program name (Load File AID) of the application to be added is transmitted from the host device 2 to the IC card 1. When the first install command is received from the host device 2, the card OS 31 of the IC card 1 sets the program name (Load File AID) of the application designated by the first install command, and the processing result is sent to the host device. 2 is notified (step S81).

上記上位装置2では、第1のインストールコマンドに対する処理が正常終了した旨の通知を受けて、当該アプリケーションのプログラムをロードするロードコマンドを送信する。このロードコマンドは、当該アプリケーションのプログラムのデータ量やICカード1との通信能力に応じて複数回実施される。上位装置2からロードコマンドを受信するごとに、ICカード1のカードOS31は、受信したロードコマンドに従ってアプリケーションのプログラムをロードする処理を行う(ステップS82)。複数のロードコマンドによってロードされたアプリケーションのプログラムは、上記第1のインストールコマンドによって定義されたプログラム名の1つのアプリケーションとして上記アプリケーション層23に追加(作成)される(ステップS83)。   In response to the notification that the processing for the first installation command has been completed normally, the host device 2 transmits a load command for loading the application program. This load command is executed a plurality of times according to the data amount of the program of the application and the communication capability with the IC card 1. Each time a load command is received from the host device 2, the card OS 31 of the IC card 1 performs a process of loading an application program in accordance with the received load command (step S82). An application program loaded by a plurality of load commands is added (created) to the application layer 23 as one application having a program name defined by the first installation command (step S83).

上記のような複数のロードコマンドに対する処理が正常終了した旨を受信した上位装置2では、さらに、ロードしたアプリケーションのデータ名(Application AID)を宣言する第2のインストールコマンドをICカード1へ送信する。
上記上位装置2から第2のインストールコマンドを受信すると(ステップS84)、ICカード1のカードOS31は、当該第2のインストールコマンドにより指定されたアプリケーションのデータ名(Application AID)に基づいて上記データテーブル15aに登録されているアプリケーションのデータ名(Application AID)を検索する(ステップS85)。
The host device 2 that has received the notification that the processing for the plurality of load commands has been normally completed further transmits a second install command for declaring the data name (Application AID) of the loaded application to the IC card 1. .
When the second installation command is received from the host device 2 (step S84), the card OS 31 of the IC card 1 uses the data table (Application AID) specified by the second installation command to execute the data table. The data name (Application AID) of the application registered in 15a is searched (step S85).

この検索の結果に基づいて、上記カードOS31は、当該第2のインストールコマンドにより指定されたアプリケーションのデータ名(Application AID)と完全に一致するか、あるいは一部が一致するアプリケーションのデータ名(Application AID)が上記データテーブル15aに登録されているか否かを判断する(ステップS86)。   Based on the result of this search, the card OS 31 determines whether the data name (Application AID) of the application specified by the second installation command completely matches or partly matches the data name (Application) of the application. It is determined whether or not (AID) is registered in the data table 15a (step S86).

上記判断により当該第2のインストールコマンドにより指定されたアプリケーションのデータ名と完全一致あるいは一部一致するデータ名のアプリケーションがデータテーブル15aに登録されていると判断した場合(ステップS86、なし)、上記カードOS31は、当該アプリケーションのインストール処理を実行する。このアプリケーションのインストール処理は、たとえば、上記第3のパターンにより実行されるようにすれば良い。   When it is determined by the above determination that an application having a data name that completely or partially matches the data name of the application specified by the second installation command is registered in the data table 15a (No in step S86), The card OS 31 executes installation processing for the application. The application installation process may be executed by the third pattern, for example.

また、上記判断により当該第2のインストールコマンドにより指定されたアプリケーションのデータ名と完全一致あるいは一部一致するデータ名のアプリケーションがデータテーブル15aに登録されていると判断した場合(ステップS86、あり)、上記カードOS31は、当該アプリケーションの追加(再追加)を不許可とし、当該第2のインストールコマンドに対する処理が異常終了したことを示すステータスを上位装置2へ通知する(ステップS87)。これにより、上記ICカード1には、当該アプリケーションを追加することが不許可となる。   If it is determined by the above determination that an application having a data name that completely or partially matches the data name of the application specified by the second installation command is registered in the data table 15a (Yes in step S86). The card OS 31 disallows the addition (re-addition) of the application, and notifies the host device 2 of a status indicating that the process for the second installation command has ended abnormally (step S87). As a result, it is not permitted to add the application to the IC card 1.

上記のように、第8のパターンでは、上位装置から追加するアプリケーションのデータ名を宣言する第2のインストールコマンドを受信した際に、当該アプリケーションのデータ名が再追加不可のアプリケーションのデータ名として登録されているか否かを判断し、この判断により当該アプリケーションのデータ名が再追加不可のアプリケーションのデータ名として登録されていると判断した場合、当該アプリケーションのインストールを不可とするものである。   As described above, in the eighth pattern, when the second install command for declaring the data name of the application to be added is received from the host device, the data name of the application is registered as the data name of the application that cannot be added again. If it is determined that the data name of the application is registered as the data name of an application that cannot be added again, the application cannot be installed.

これにより、再追加不可のアプリケーションとして登録されているデータ名と一致するデータ名のアプリケーションについては、そのアプリケーションのデータ名を宣言する第2のインストールコマンドを受信した際にインストールを不可することができる。また、アプリケーションのデータ名は容易に変更することができないため、第8のパターンによれば、アプリケーションのデータ名によりインストールが不可か否かを判断するため、上記データテーブル15aにはアプリケーションのデータ名(Application AID)を登録しておけば良い。さらに、第8のパターンでは、同一のプログラム名からなる他のアプリケーションの追加を不可としないようにすることも可能となる。   As a result, for an application having a data name that matches the data name registered as a non-re-addable application, the installation can be disabled when the second installation command for declaring the data name of the application is received. . Since the data name of the application cannot be easily changed, according to the eighth pattern, the data name of the application is stored in the data table 15a in order to determine whether or not installation is possible based on the data name of the application. (Application AID) may be registered. Furthermore, in the eighth pattern, it is possible not to prohibit addition of other applications having the same program name.

なお、上記第6のパターン、上記第7のパターンおよび第8のパターンは、予め登録されているアプリケーションであるか否かに基づいてアプリケーションが追加可能か否かを判断するものである。このため、アプリケーションの再追加の場合に限らず、予め追加を不可とするアプリケーションを登録しておくことにより、特定のアプリケーションの追加(インストール)を不可するようにすることも可能である。   Note that the sixth pattern, the seventh pattern, and the eighth pattern determine whether or not an application can be added based on whether or not the application is registered in advance. For this reason, not only in the case of re-adding an application, it is also possible to make it impossible to add (install) a specific application by registering an application that cannot be added in advance.

また、上記第1のインストールコマンドを受信した際にアプリケーションのプログラム名に基づいてアプリケーションの追加の可否を判断する第6のパターンについては、再追加許可情報としてアプリケーションのプログラム名を設定する上記第1、第2、第4、あるいは第5のパターンと組み合わせて実施することが可能である。   For the sixth pattern for determining whether or not an application can be added based on the program name of the application when the first installation command is received, the program name of the application is set as re-addition permission information. It can be implemented in combination with the second, fourth or fifth pattern.

また、上記ロードコマンドを受信した際にアプリケーションのプログラム名に基づいてアプリケーションの追加の可否を判断する第7のパターンについては、再追加許可情報としてアプリケーションのプログラム名を設定する上記第2、第4、あるいは第5のパターンと組み合わせて実施することが可能である。   As for the seventh pattern for determining whether or not an application can be added based on the program name of the application when the load command is received, the second and fourth of setting the program name of the application as re-addition permission information. Or in combination with the fifth pattern.

また、上記第2のインストールコマンドを受信した際にアプリケーションのデータ名に基づいてアプリケーションの追加の可否を判断する第8のパターンについては、再追加許可情報としてアプリケーションのデータ名を設定する上記第3、第4、あるいは第5のパターンと組み合わせて実施することが可能である。   For the eighth pattern in which whether or not an application can be added is determined based on the data name of the application when the second installation command is received, the data name of the application is set as re-addition permission information. , 4th or 5th pattern can be used in combination.

本発明の実施の形態に係る携帯可能電子装置としてのICカード1のハードウエア構成を概略的に示す図。1 is a diagram schematically showing a hardware configuration of an IC card 1 as a portable electronic device according to an embodiment of the present invention. ICカードがJavaカードとして使用される場合のICカード内のソフトウエア構成を模式的に示す図。The figure which shows typically the software structure in an IC card in case an IC card is used as a Java card. 再追加不許可情報を登録する処理の例としての第1のパターンを説明するためのフローチャート。The flowchart for demonstrating the 1st pattern as an example of the process which registers re-addition nonpermission information. 再追加不許可情報を登録する処理の例としての第2のパターンを説明するためのフローチャート。The flowchart for demonstrating the 2nd pattern as an example of the process which registers re-addition nonpermission information. 再追加不許可情報を登録する処理の例としての第3のパターンを説明するためのフローチャート。The flowchart for demonstrating the 3rd pattern as an example of the process which registers re-addition prohibition information. 再追加不許可情報を登録する処理の例としての第4のパターンを説明するためのフローチャート。The flowchart for demonstrating the 4th pattern as an example of the process which registers re-addition nonpermission information. 再追加不許可情報を登録する処理の例としての第5のパターンを説明するためのフローチャート。The flowchart for demonstrating the 5th pattern as an example of the process which registers re-addition nonpermission information. アプリケーションの追加を制限する処理の例としての第6のパターンを説明するためのフローチャート。The flowchart for demonstrating the 6th pattern as an example of the process which restrict | limits the addition of an application. アプリケーションの追加を制限する処理の例としての第7のパターンを説明するためのフローチャート。The flowchart for demonstrating the 7th pattern as an example of the process which restrict | limits the addition of an application. アプリケーションの追加を制限する処理の例としての第8のパターンを説明するためのフローチャート。The flowchart for demonstrating the 8th pattern as an example of the process which restrict | limits the addition of an application.

符号の説明Explanation of symbols

1…ICカード(携帯可能電子装置)、2…上位装置、11…CPU、12…ROM、13…RAM、14…通信ユニット(UART)、15…不揮発性メモリ、15a…データテーブル、21…ハードウエア層、22…OS層、23…アプリケーション層、31…カードOS、32…バーチャルマシン、33…ISD、34…API群、34a…API   DESCRIPTION OF SYMBOLS 1 ... IC card (portable electronic device), 2 ... Host device, 11 ... CPU, 12 ... ROM, 13 ... RAM, 14 ... Communication unit (UART), 15 ... Non-volatile memory, 15a ... Data table, 21 ... Hardware Wear layer, 22 ... OS layer, 23 ... Application layer, 31 ... Card OS, 32 ... Virtual machine, 33 ... ISD, 34 ... API group, 34a ... API

Claims (6)

書き換え可能な不揮発性メモリにインストールされているアプリケーションを実行する携帯可能電子装置において、
外部装置からの前記不揮発性メモリへのアプリケーションの追加要求と当該アプリケーションの再追加が不可である旨の情報とを受信する受信手段と、
この受信手段によりアプリケーションの追加要求と再追加が不可である旨の情報とを受信した場合、当該アプリケーションの再追加を不可とすることを示すデータを設定する設定手段と、
前記受信手段により前記外部装置から受信したアプリケーションを前記不揮発性メモリにインストールする処理手段と、
を具備することを特徴とする携帯可能電子装置。
In a portable electronic device that executes an application installed in a rewritable non-volatile memory,
Receiving means for receiving an application addition request from the external device to the nonvolatile memory and information indicating that the application cannot be added again;
A setting means for setting data indicating that re-addition of the application is not allowed when receiving an application addition request and information indicating that re-addition is impossible by the receiving means;
Processing means for installing the application received from the external device by the receiving means into the nonvolatile memory;
A portable electronic device comprising:
前記受信手段により受信するアプリケーションの再追加が不可である旨の情報は、当該アプリケーションのプログラム名を指定するコマンド、当該アプリケーションのデータ名を指定するコマンド、あるいは、当該アプリケーションのプログラムをロードするコマンドに付加されている情報である、ことを特徴とする前記請求項1に記載の携帯可能電子装置。 Information indicating that re-addition of an application received by the receiving means is impossible is a command for specifying the program name of the application, a command for specifying the data name of the application, or a command for loading the program of the application. The portable electronic device according to claim 1, wherein the portable electronic device is added information. 書き換え可能な不揮発性メモリにインストールされているアプリケーションを実行する携帯可能電子装置において、
外部装置からの前記不揮発性メモリにインストールされているアプリケーションの削除要求と当該アプリケーションの再追加が不可である旨の情報とを受信する受信手段と、
この受信手段によりアプリケーションの削除要求と再追加が不可である旨の情報を受信した場合、当該アプリケーションの再追加を不可とすることを示すデータを設定する設定手段と、
前記受信手段により削除要求を受信したアプリケーションを前記不揮発性メモリから削除する処理手段と、
を具備することを特徴とする携帯可能電子装置。
In a portable electronic device that executes an application installed in a rewritable non-volatile memory,
Receiving means for receiving a request to delete an application installed in the nonvolatile memory from an external device and information indicating that the application cannot be re-added;
A setting means for setting data indicating that re-addition of the application is disabled when receiving information indicating that the application deletion request and re-addition are impossible by the receiving means;
Processing means for deleting the application that has received the deletion request by the receiving means from the nonvolatile memory;
A portable electronic device comprising:
書き換え可能な不揮発性メモリにインストールされているアプリケーションを実行する携帯可能電子装置において、
アプリケーションの追加を不可に設定する関数を含む関数群が登録されている登録手段と、
この登録手段に登録されている関数群を用いて前記不揮発性メモリにインストールされているアプリケーションを実行する実行手段と、
この実行手段により前記不揮発性メモリにインストールされているアプリケーションのうち再追加を不可とするアプリケーションを実行する際、前記登録手段に登録されているアプリケーションの追加を不可に設定する関数を用いて当該アプリケーションの再追加を不可とすることを示すデータを設定する設定手段と、
を具備することを特徴とする携帯可能電子装置。
In a portable electronic device that executes an application installed in a rewritable non-volatile memory,
A registration means in which a function group including a function for disabling addition of an application is registered;
Execution means for executing an application installed in the non-volatile memory using a function group registered in the registration means;
When executing an application that cannot be re-added among the applications installed in the non-volatile memory by the execution unit, the application is registered using a function for setting the addition of the application registered in the registration unit to be disabled. A setting means for setting data indicating that re-addition of the URL cannot be re-added,
A portable electronic device comprising:
書き換え可能な不揮発性メモリにインストールされているアプリケーションを実行する携帯可能電子装置において、
追加を不可とするアプリケーションを示すデータが設定されている設定手段と、
外部装置からの前記不揮発性メモリへのアプリケーションの追加要求を受信する受信手段と、
この受信手段によりアプリケーションの追加要求を受信した場合、当該アプリケーションが前記設定手段により追加を不可とするアプリケーションとして設定されているか否かを判断する判断手段と、
この判断手段により当該アプリケーションが追加を不可とするアプリケーションとして設定されていると判断した場合、当該アプリケーションの追加を不可とする第1の処理手段と、
前記判断手段により当該アプリケーションが追加を不可とするアプリケーションとして設定されていないと判断した場合、前記受信手段により追加要求を受信したアプリケーションを前記不揮発性メモリにインストールする第2の処理手段と、
を具備することを特徴とする携帯可能電子装置。
In a portable electronic device that executes an application installed in a rewritable non-volatile memory,
A setting means in which data indicating an application that cannot be added is set;
Receiving means for receiving an application addition request to the nonvolatile memory from an external device;
A determination unit that determines whether or not the application is set as an application that cannot be added by the setting unit when an application addition request is received by the receiving unit;
A first processing unit that disables addition of the application when the determination unit determines that the application is set as an application that cannot be added;
A second processing unit that installs the application that has received the addition request by the receiving unit in the non-volatile memory when the determining unit determines that the application is not set as an application that cannot be added;
A portable electronic device comprising:
前記判断手段は、当該アプリケーションのプログラム名の指定、当該アプリケーションのデータ名の指定、あるいは、当該アプリケーションのプログラムのロードを行う際に、当該アプリケーションが前記設定手段により追加を不可とするアプリケーションとして設定されているか否かを判断する、ことを特徴とする前記請求項5に記載の携帯可能電子装置。 The determination unit is set as an application that cannot be added by the setting unit when the program name of the application is specified, the data name of the application is specified, or the program of the application is loaded. The portable electronic device according to claim 5, wherein it is determined whether or not it is present.
JP2004299260A 2004-10-13 2004-10-13 Portable electronic device Pending JP2006113747A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004299260A JP2006113747A (en) 2004-10-13 2004-10-13 Portable electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004299260A JP2006113747A (en) 2004-10-13 2004-10-13 Portable electronic device

Publications (1)

Publication Number Publication Date
JP2006113747A true JP2006113747A (en) 2006-04-27

Family

ID=36382228

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004299260A Pending JP2006113747A (en) 2004-10-13 2004-10-13 Portable electronic device

Country Status (1)

Country Link
JP (1) JP2006113747A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008269077A (en) * 2007-04-17 2008-11-06 Toshiba Corp Portable electronic device and ic card
US20120022973A1 (en) * 2010-06-02 2012-01-26 Oleg Makhotin Trusted internal interface
WO2013042682A1 (en) * 2011-09-21 2013-03-28 株式会社 東芝 Ic card, portable electronic device, and ic card control method
JP2014052824A (en) * 2012-09-06 2014-03-20 Dainippon Printing Co Ltd Ic card system and ic card
JP2015158855A (en) * 2014-02-25 2015-09-03 大日本印刷株式会社 Identifier determination device, identifier determination method and identifier determination program
JP2019046211A (en) * 2017-09-04 2019-03-22 大日本印刷株式会社 Electronic information storage medium, ic card, update method by electronic information storage medium, and update program

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008269077A (en) * 2007-04-17 2008-11-06 Toshiba Corp Portable electronic device and ic card
US9846873B2 (en) 2010-06-02 2017-12-19 Visa International Service Association Trusted internal interface
US8321345B2 (en) * 2010-06-02 2012-11-27 Visa International Service Association Trusted internal interface
US20130046588A1 (en) * 2010-06-02 2013-02-21 Oleg Makhotin Trusted internal interface
US9092769B2 (en) 2010-06-02 2015-07-28 Visa International Service Association Trusted internal interface
US20120022973A1 (en) * 2010-06-02 2012-01-26 Oleg Makhotin Trusted internal interface
US10685343B2 (en) 2010-06-02 2020-06-16 Visa International Service Association Trusted internal interface
WO2013042682A1 (en) * 2011-09-21 2013-03-28 株式会社 東芝 Ic card, portable electronic device, and ic card control method
JP2013069057A (en) * 2011-09-21 2013-04-18 Toshiba Corp Ic card, portable electronic device and ic card control method
JP2014052824A (en) * 2012-09-06 2014-03-20 Dainippon Printing Co Ltd Ic card system and ic card
JP2015158855A (en) * 2014-02-25 2015-09-03 大日本印刷株式会社 Identifier determination device, identifier determination method and identifier determination program
JP2019046211A (en) * 2017-09-04 2019-03-22 大日本印刷株式会社 Electronic information storage medium, ic card, update method by electronic information storage medium, and update program
JP7009844B2 (en) 2017-09-04 2022-01-26 大日本印刷株式会社 Update method and update program using electronic information storage medium, IC card, electronic information storage medium

Similar Documents

Publication Publication Date Title
US20060086785A1 (en) Portable electronic apparatus and method of updating application in portable electronic apparatus
JP5061908B2 (en) Program execution control method and apparatus, and execution control program
JP6013061B2 (en) Information processing apparatus and control method
KR100318150B1 (en) Single chip microcomputer internally including a flash memory
JP2006252477A (en) Access control device and access control method
CN100507797C (en) Techniques for implementing security on a small footprint device using a context barrier
CN1316360C (en) Techniques for permitting access across a context barrier on a small footprint device using run time environment privileges
CN100353324C (en) Techniques for permitting access across a context barrier in a small footprint device using shared object interfaces
JP2003198718A (en) Communication terminal, method for limiting use of contents, and method for limiting execution of program
JP2006113747A (en) Portable electronic device
JP2017504112A (en) Updatable IC wireless device
JP5057829B2 (en) Portable electronic device and IC card
WO2013031115A1 (en) Mobile terminal, authentication method, authentication program and authentication system
KR100838671B1 (en) Portable information processor having password code checking function
JP2010146410A (en) Portable electronic device
JP2009075797A (en) Portable electronic equipment
JP6065791B2 (en) Control program and information processing terminal
JP7202543B2 (en) eUICC and eUICC provisioning methods
CN104573566A (en) Method for setting system working mode of mobile data terminal
JP2006338311A (en) Computer system for processing device loaded with multiple applications, device and computer program
JP4618224B2 (en) Object-oriented vehicle control system
JP2003016410A (en) Ic card
JP2011039825A (en) Firmware updating method and firmware updating device
JP5242091B2 (en) Portable electronic device, IC card, and portable electronic device control method
JP5229855B2 (en) Memory system and computer system