JP2008299416A - Portable electronic device, file access method in portable electronic device, and ic card - Google Patents

Portable electronic device, file access method in portable electronic device, and ic card Download PDF

Info

Publication number
JP2008299416A
JP2008299416A JP2007142201A JP2007142201A JP2008299416A JP 2008299416 A JP2008299416 A JP 2008299416A JP 2007142201 A JP2007142201 A JP 2007142201A JP 2007142201 A JP2007142201 A JP 2007142201A JP 2008299416 A JP2008299416 A JP 2008299416A
Authority
JP
Japan
Prior art keywords
data
file
condition
identifier
command
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
JP2007142201A
Other languages
Japanese (ja)
Inventor
Kazuhiro Ishibe
一洋 石部
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 JP2007142201A priority Critical patent/JP2008299416A/en
Priority to SG200801948-1A priority patent/SG146551A1/en
Priority to FR0851649A priority patent/FR2914449B1/en
Priority to US12/049,820 priority patent/US7775423B2/en
Publication of JP2008299416A publication Critical patent/JP2008299416A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Storage Device Security (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a portable electronic device controlling access in more detail than when setting an access condition for each conventional file by setting the access condition for each data object. <P>SOLUTION: This IC card has a non-volatile memory holding data, the memory has at least one file set thereto, and the file stores a plurality of data objects. The IC card accesses the file by interpreting and executing a command inputted from the outside. In the IC card, the condition for executing the command inputted from the outside is set in each of the plurality of data objects, and each data object in the file is accessed by executing the command inputted from the outside based on the set condition. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

本発明は、たとえば、データを保持する不揮発性メモリを有し、このメモリには少なくとも1つのファイルが設定され、このファイルには複数のデータオブジェクトが格納されていて、外部から入力されるコマンド(命令)を解釈して実行することで、前記ファイルに対しアクセスするICカードなどの携帯可能電子装置、および携帯可能電子装置におけるファイルアクセス方法、およびICカードに関する。   The present invention has, for example, a non-volatile memory for holding data, and at least one file is set in the memory, and a plurality of data objects are stored in the file, and a command ( The present invention relates to a portable electronic device such as an IC card that accesses the file by interpreting and executing the command, a file access method in the portable electronic device, and an IC card.

この種のICカードにあっては、その内部の不揮発性メモリに保持するデータについて、デディケイトファイル(DF:Dedicated File)やエレメンタリファイル(EF:Elementary File)など、ファイルを単位としたファイル管理を行なう方法が一般的である(たとえば、特許文献1参照)。   In this type of IC card, file management in units of files, such as a dedicated file (DF) and an elementary file (EF), for data stored in a nonvolatile memory inside the IC card. Is generally performed (see, for example, Patent Document 1).

また、不揮発性メモリ内のファイルに格納するデータは、当該データの種別を示す識別子(Tag)と、当該データの長さを示す長さ情報(Length)と、当該データそのものを示すデータ部(Value)とを連結して構成されるデータ列(TLV構造のデータ列)、いわゆるデータオブジェクト構造になっているものもある。   The data stored in the file in the nonvolatile memory includes an identifier (Tag) indicating the type of the data, length information (Length) indicating the length of the data, and a data portion (Value) indicating the data itself. ) Are concatenated with each other (a data string having a TLV structure), that is, a so-called data object structure.

このようなデータオブジェクトをファイルに格納するICカードにおいては、ファイル単位にアクセス条件を設定し、この設定されたアクセス条件に基づき、コマンド(命令)によるアクセス制御を行なっている(たとえば、特許文献2、特許文献3参照)。
特許第2695857号公報 特開平8−263353号公報 特開平11−65938号公報
In an IC card that stores such a data object in a file, an access condition is set for each file, and access control by a command (instruction) is performed based on the set access condition (for example, Patent Document 2). And Patent Document 3).
Japanese Patent No. 2695857 JP-A-8-263353 JP 11-65938 A

しかし、最近、1つのファイルに複数のデータオブジェクトが格納されている場合があり、その場合、従来のアクセス制御方式では、アクセス制御はファイル単位で行なうため、データオブジェクトごとのアクセス制御を行なうことはできないという問題がある。   However, recently, there are cases where a plurality of data objects are stored in one file. In such a case, in the conventional access control method, access control is performed on a file basis, so that access control for each data object is not possible. There is a problem that you can not.

そこで、本発明は、データオブジェクトごとにアクセス条件を設定することにより、従来のファイル単位にアクセス条件を設定した場合よりも細かなアクセス制御を行なうことが可能となる携帯可能電子装置、携帯可能電子装置におけるファイルアクセス方法およびICカードを提供することを目的とする。   Therefore, the present invention provides a portable electronic device and a portable electronic device that can perform finer access control than the conventional case where an access condition is set for each file by setting an access condition for each data object. It is an object to provide a file access method and an IC card in an apparatus.

本発明の携帯可能電子装置は、メモリを有し、このメモリには少なくとも1つのファイルが設定され、このファイルには当該データの種別を示す識別子と当該データの長さを示す長さ情報と当該データそのものを示すデータ部とを連結して構成されるデータオブジェクトが複数格納されていて、外部から入力される命令を解釈して実行することで、前記ファイルに対しアクセスする携帯可能電子装置において、外部から入力される命令を実行するための条件を、前記複数のデータオブジェクトの各識別子にそれぞれ対応させて設定する条件設定手段と、外部から入力される命令を受信すると、当該命令により指定される識別子に基づき前記条件設定手段の設定内容を参照することにより、当該識別子に対応する識別子を持つ条件を検索する検索手段と、この検索手段により検索された条件に基づき、前記受信した命令を実行することにより、前記ファイルに対しデータオブジェクト単位にアクセスするアクセス制御手段とを具備している。   The portable electronic device of the present invention has a memory, and at least one file is set in the memory. The file indicates an identifier indicating the type of the data, length information indicating the length of the data, and the In a portable electronic device that accesses the file by interpreting and executing a command input from the outside, in which a plurality of data objects configured by connecting a data portion indicating data itself are stored, Condition setting means for setting a condition for executing a command input from the outside corresponding to each identifier of the plurality of data objects, and when a command input from the outside is received, specified by the command By referring to the setting contents of the condition setting means based on the identifier, a search for searching for a condition having an identifier corresponding to the identifier is performed. Based on means and, conditions retrieved by the retrieval means, by executing the instruction thus received, and an access control means for accessing the data object units to said file.

本発明の携帯可能電子装置におけるファイルアクセス方法は、メモリを有し、このメモリには少なくとも1つのファイルが設定され、このファイルには当該データの種別を示す識別子と当該データの長さを示す長さ情報と当該データそのものを示すデータ部とを連結して構成されるデータオブジェクトが複数格納されていて、外部から入力される命令を解釈して実行することで、前記ファイルに対しアクセスする携帯可能電子装置におけるファイルアクセス方法であって、外部から入力される命令を実行するための条件を、前記複数のデータオブジェクトの各識別子にそれぞれ対応させて設定しておき、外部から入力される命令を受信すると、当該命令により指定される識別子に基づき前記条件の設定内容を参照することにより、当該識別子に対応する識別子を持つ条件を検索し、この検索された条件に基づき、前記受信した命令を実行することにより、前記ファイルに対しデータオブジェクト単位にアクセスすることを特徴とする。   The file access method in the portable electronic device according to the present invention has a memory, and at least one file is set in the memory. The file indicates an identifier indicating the type of the data and a length indicating the length of the data. A plurality of data objects configured by connecting information and a data part indicating the data itself are stored, and the file can be accessed by interpreting and executing an externally input command. A method for accessing a file in an electronic device, wherein a condition for executing a command input from the outside is set in correspondence with each identifier of the plurality of data objects, and a command input from the outside is received. Then, by referring to the setting contents of the condition based on the identifier specified by the instruction, the identifier Search criteria with the corresponding identifier, on the basis of the search conditions, by executing the instruction thus received, characterized in that access to the data object units to said file.

本発明のICカードは、メモリを有し、このメモリには少なくとも1つのファイルが設定され、このファイルには当該データの種別を示す識別子と当該データの長さを示す長さ情報と当該データそのものを示すデータ部とを連結して構成されるデータオブジェクトが複数格納されていて、外部から入力される命令を解釈して実行することで、前記ファイルに対しアクセスするICカードにおいて、外部から入力される命令を実行するための条件を、前記複数のデータオブジェクトの各識別子にそれぞれ対応させて設定する条件設定手段と、外部から入力される命令を受信すると、当該命令により指定される識別子に基づき前記条件設定手段の設定内容を参照することにより、当該識別子に対応する識別子を持つ条件を検索する検索手段と、この検索手段により検索された条件に基づき、前記受信した命令を実行することにより、前記ファイルに対しデータオブジェクト単位にアクセスするアクセス制御手段とを有したICモジュールと、このICモジュールを収納したICカード本体とを具備している。   The IC card of the present invention has a memory, and at least one file is set in the memory. The file indicates an identifier indicating the type of the data, length information indicating the length of the data, and the data itself. A plurality of data objects configured by linking the data portion indicating the file are stored, and an IC card that accesses the file by interpreting and executing a command input from the outside is input from the outside. A condition setting means for setting a condition for executing the instruction to be associated with each identifier of the plurality of data objects, and when receiving an instruction input from the outside, based on the identifier specified by the instruction By referring to the setting contents of the condition setting means, search means for searching for a condition having an identifier corresponding to the identifier, and this An IC module having an access control means for accessing the file in units of data objects by executing the received command based on the condition searched by the search means, and an IC card main body containing the IC module It is equipped with.

本発明によれば、データオブジェクトごとにアクセス条件を設定することにより、従来のファイル単位にアクセス条件を設定した場合よりも細かなアクセス制御を行なうことが可能となる携帯可能電子装置、携帯可能電子装置におけるファイルアクセス方法およびICカードを提供できる。   According to the present invention, by setting an access condition for each data object, a portable electronic device and a portable electronic device that can perform finer access control than when a conventional access condition is set for each file. A file access method and an IC card in the apparatus can be provided.

以下、本発明の実施の形態について図面を参照して説明する。
図1は、本発明に係る携帯可能電子装置としてのICカードを取扱うICカードシステムの構成例を示すものである。このICカードシステムは、ICカード101を外部装置としてのカードリーダ・ライタ102を介して端末装置103と接続可能にするとともに、端末装置103にキーボード104、CRT表示部105、プリンタ106を接続して構成される。
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
FIG. 1 shows a configuration example of an IC card system that handles an IC card as a portable electronic device according to the present invention. In this IC card system, an IC card 101 can be connected to a terminal device 103 via a card reader / writer 102 as an external device, and a keyboard 104, a CRT display unit 105, and a printer 106 are connected to the terminal device 103. Composed.

ICカード101は、カードリーダ・ライタ102からの電源供給により動作可能な状態となり、カードリーダ・ライタ102から供給されるコマンドに応じて種々の処理を実行する。カードリーダ・ライタ102は、ICカード101に対し動作電源を供給するとともに種々の処理を要求するコマンドを供給する。   The IC card 101 becomes operable by supplying power from the card reader / writer 102, and executes various processes in accordance with commands supplied from the card reader / writer 102. The card reader / writer 102 supplies operating power to the IC card 101 and commands for requesting various processes.

ここに、カードリーダ・ライタ102からICカード101に供給されるコマンドの内容は、たとえば、データオブジェクトのアクセスであり、データオブジェクトに対するデータの読出し、書込み、削除、データオブジェクトの追加のうち少なくともいずれか1つである。   Here, the content of the command supplied from the card reader / writer 102 to the IC card 101 is, for example, access to a data object, and at least one of reading, writing, deleting, and adding a data object to / from the data object. One.

端末装置103は、たとえば、パーソナルコンピュータなどにより構成されていて、図示しないメモリに記憶されている各種制御プログラムを実行することにより、各種の処理を実行するとともに、カードリーダ・ライタ102を介してICカード101との間でデータの入出力を行なう。   The terminal device 103 is constituted by, for example, a personal computer, and executes various processes by executing various control programs stored in a memory (not shown), and also performs an IC via the card reader / writer 102. Data is input to and output from the card 101.

図2は、ICカード101の構成を示すもので、制御素子としてのCPU201、記憶内容が書換え可能な記憶手段(メモリ)としてのデータメモリ202、ワーキングメモリ203、プログラムメモリ204、および、カードリーダ・ライタ102との通信を行なうための通信部205によって構成されている。そして、これらのうち、破線内の部分(CPU201、データメモリ202、ワーキングメモリ203、プログラムメモリ204)は1つ(あるいは複数)のICチップ206で構成され、さらに、このICチップ206と通信部205とが一体的にICモジュール化されて、ICカード本体101a内に埋設されている。   FIG. 2 shows the configuration of the IC card 101. The CPU 201 is a control element, the data memory 202 is a storage means (memory) whose contents can be rewritten, the working memory 203, the program memory 204, and the card reader The communication unit 205 is configured to communicate with the writer 102. Of these, the portion within the broken line (CPU 201, data memory 202, working memory 203, program memory 204) is composed of one (or a plurality) of IC chips 206, and further this IC chip 206 and communication unit 205. Are integrated into an IC module and embedded in the IC card main body 101a.

CPU201は、各種の判定処理や判断処理およびメモリへの書込みや読出しなどの各種のデータ処理を行なう制御部である。   The CPU 201 is a control unit that performs various determination processes, determination processes, and various data processes such as writing to and reading from a memory.

データメモリ202は、たとえば、EEPROM(エレクトリカリ・イレーザブル・アンド・プログラマブル・リード・オンリ・メモリ)などの消去(書換え)可能な不揮発性メモリで構成されていて、各種アプリケーションデータなどの各種データがファイル構造で記憶される。   The data memory 202 is composed of an erasable (rewritable) non-volatile memory such as an EEPROM (Electrical Eraseable and Programmable Read Only Memory), and various data such as various application data are files. Stored in structure.

ワーキングメモリ203は、CPU201が処理を行なう際の処理データを一時的に保持するための作業用のメモリであり、たとえば、RAM(ランダム・アクセス・メモリ)などの揮発性メモリで構成されている。   The working memory 203 is a working memory for temporarily storing processing data when the CPU 201 performs processing. For example, the working memory 203 includes a volatile memory such as a RAM (Random Access Memory).

プログラムメモリ204は、たとえば、マスクROM(リード・オンリ・メモリ)などの書換え不可能な固定メモリで構成されており、CPU201の制御プログラムなどを記憶している。   The program memory 204 is configured by a non-rewritable fixed memory such as a mask ROM (read only memory), for example, and stores a control program of the CPU 201 and the like.

通信部205は、ICカード101が非接触式(無線式)ICカードの場合にはアンテナ部として構成され、カードリーダ・ライタ102から送信された変調波を非接触で受信したり外部へ変調波を発信したりするようになっている。また、この通信部205で受信した変調波から内部回路に供給するための電源やクロックを生成するようになっている。また、接触式ICカードの場合にはコンタクト部として構成され、カードリーダ・ライタ102に設けられたICカード端子部(図示しない)と接触することにより電源やクロックを得るようになっている。   The communication unit 205 is configured as an antenna unit when the IC card 101 is a non-contact (wireless) IC card, and receives the modulated wave transmitted from the card reader / writer 102 in a non-contact manner or transmits the modulated wave to the outside. Or to send. Further, a power supply and a clock for supplying to the internal circuit are generated from the modulated wave received by the communication unit 205. In the case of a contact type IC card, it is configured as a contact portion, and a power source and a clock are obtained by contacting with an IC card terminal portion (not shown) provided in the card reader / writer 102.

図3は、データメモリ102の内部構造例を示すものである。この例では、1つのファイルに2つのデータオブジェクトが格納されている場合を示している。
データメモリ102内には、たとえば、照合キーを格納する照合キーEFを定義する照合キーEF定義情報301、認証キーを格納する認証キーEFを定義する認証キーEF定義情報302、認証子生成鍵を格納する認証子生成鍵EFを定義する認証子生成鍵EF定義情報303、データ暗号化鍵を格納するデータ暗号化鍵EFを定義するデータ暗号化鍵EF定義情報304が格納されているとともに、データ暗号化鍵EF定義情報304で定義されるデータ暗号化鍵EF305、認証子生成鍵EF定義情報303で定義される認証子生成鍵EF306、認証キーEF定義情報302で定義される認証キーEF307、照合キーEF定義情報301で定義される照合キーEF308、データオブジェクトに対するタグ(Tag)リストテーブル309、タグリストテーブル309に対するデータオブジェクト(2)310、データオブジェクト(1)311が格納されている。
FIG. 3 shows an example of the internal structure of the data memory 102. In this example, two data objects are stored in one file.
In the data memory 102, for example, verification key EF definition information 301 for defining a verification key EF for storing a verification key, authentication key EF definition information 302 for defining an authentication key EF for storing an authentication key, and an authenticator generation key are stored. Stored is an authenticator generation key EF definition information 303 that defines an authenticator generation key EF to be stored, a data encryption key EF definition information 304 that defines a data encryption key EF that stores a data encryption key, and data Data encryption key EF305 defined by encryption key EF definition information 304, authenticator generation key EF306 defined by authenticator generation key EF definition information 303, authentication key EF307 defined by authentication key EF definition information 302, verification Matching key EF308 defined in key EF definition information 301, tag list table for data object 309, the data object (2) for the tag list table 309 310, the data object (1) 311 is stored.

データオブジェクト(2)310、データオブジェクト(1)311は、前述したように、当該データの種別を示す識別子(Tag)と、当該データの長さを示す長さ情報(Length)と、当該データそのものを示すデータ部(Value)とを連結して構成されるデータ列(TLV構造のデータ列)である。   As described above, the data object (2) 310 and the data object (1) 311 include the identifier (Tag) indicating the type of the data, the length information (Length) indicating the length of the data, and the data itself. Is a data string (a data string having a TLV structure) configured by linking a data part (Value) indicating the above.

図4は、ワーキングメモリ203の内部構造例を示すものである。ワーキングメモリ203は、照合キーの照合状態を格納する領域203aおよび認証キーや認証子の認証状態を格納する領域203bを有している。   FIG. 4 shows an example of the internal structure of the working memory 203. The working memory 203 has an area 203a for storing the verification state of the verification key and an area 203b for storing the authentication status of the authentication key and the authenticator.

図5は、タグリストテーブル309の詳細を示している。この例では、1つのフアイルに2つのデータオブジェクトが格納されている場合を示している。
タグリストテーブル309は、401は、タグ(Tag)テーブルの1つ当たりの長さを示すテーブル長さ情報401、当該タグリストテーブル309内のタグテーブルの数を示すタグテーブル数情報402、1つ目のデータオブジェクト(第3図のデータオブジェクト(1)311)のタグテーブル403、2つ目のデータオブジェクト(第3図のデータオブジェクト(2)310)のタグテーブル404を有して構成される。
FIG. 5 shows details of the tag list table 309. In this example, two data objects are stored in one file.
In the tag list table 309, 401 is table length information 401 indicating the length of one tag (Tag) table, tag table number information 402 indicating the number of tag tables in the tag list table 309, and one. A tag table 403 of the second data object (data object (2) 310 in FIG. 3) and a tag table 404 of the second data object (data object (1) 311 in FIG. 3) are configured. .

タグテーブル403,404は、データオブジェクトの識別子であるタグ(Tag)値501、データオブジェクトのデータ部(Value)の長さを示す長さ情報502、データオブジェクトの詳細制御情報(Location Data)503、データオブジェクトを格納しているファイルの識別情報であるファイルID(DID)504、対象タグ(データオブジェクト)のアクセス条件505を有して構成される。   The tag tables 403 and 404 include a tag value 501 which is an identifier of the data object, length information 502 indicating the length of the data part (Value) of the data object, detailed control information (Location Data) 503 of the data object, A file ID (DID) 504 that is identification information of a file storing a data object and an access condition 505 for a target tag (data object) are configured.

ここで、データオブジェクトのアクセス条件505としては、たとえば、データ読出処理のアクセス条件、データ書込処理のアクセス条件、セキュアメッセージング処理のアクセス条件などが考えられる。   Here, as the access condition 505 for the data object, for example, an access condition for the data read process, an access condition for the data write process, an access condition for the secure messaging process, and the like can be considered.

データ読出処理のアクセス条件としては、読出しを禁止する読出禁止、照合キーの照合が成功したときに読出しを可能とする照合読出可能、認証キーの認証が成功したときに読出しを可能とする認証読出可能、照合キーの照合が成功あるいは認証キーの認証が成功したときに読出しを可能とする照合/認証読出可能、照合キーの照合が成功し、かつ、認証キーの認証が成功したときに読出しを可能とする照合・認証読出可能、自由に読出しを可能とする読出しフリーなどが考えられる。   As access conditions for data reading processing, reading prohibition prohibiting reading, verification reading that enables reading when verification of the verification key succeeds, and authentication reading that enables reading when authentication of the authentication key succeeds are possible. Yes, collation / authentication readout that enables reading when the verification of the verification key is successful or when the authentication of the authentication key is successful, and can be read when the verification of the verification key is successful and the authentication of the authentication key is successful Possible verification / authentication readout is possible, read-out is possible, and so on.

ここに、照合キーの照合とは、カードリーダ・ライタ102からの照合コマンドに付加された照合キーと照合キーEF308内の照合キーとを照合し、両照合キーが一致したとき照合成功とし、両照合キーが一致しなかったとき照合不成功とすることを意味しており、その照合結果はワーキングメモリ203の照合状態格納領域203aに格納される。この照合処理は、書込みや読出し等の実際の処理コマンドを実行する前に先立って行なわれる。   Here, collation of the collation key refers to collation of the collation key added to the collation command from the card reader / writer 102 with the collation key in the collation key EF308, and when both collation keys match, the collation is successful. This means that collation is unsuccessful when the collation keys do not match, and the collation result is stored in the collation state storage area 203a of the working memory 203. This collation processing is performed prior to execution of actual processing commands such as writing and reading.

また、認証キーの認証とは、カードリーダ・ライタ102からの認証コマンドに付加された暗号化された認証用データを認証キーEF307内の認証キーにより復号化し、正しく復号化されたとき認証成功とし、正しく復号化されなかったとき認証不成功とすることを意味しており、その認証結果はワーキングメモリ203の認証状態格納領域203bに格納される。この認証処理も、書込みや読出し等の実際の処理コマンドを実行する前に先立って行なわれる。   The authentication of the authentication key means that the encrypted authentication data added to the authentication command from the card reader / writer 102 is decrypted with the authentication key in the authentication key EF307, and the authentication is successful when correctly decrypted. This means that the authentication is unsuccessful when decryption is not successful, and the authentication result is stored in the authentication state storage area 203b of the working memory 203. This authentication process is also performed prior to executing an actual processing command such as writing or reading.

セキュアメッセージング処理のアクセス条件としては、セキュアメッセージング無し、認証子が必要、データ暗号化が必要、認証子およびデータ暗号化が必要などが考えられる。
ここに、認証子が必要とは、受信したコマンドの特定部(たとえば、ヘッダ部やデータ部等)のデータを認証子生成鍵EF306内の認証子生成鍵を用いて暗号化することで認証子を生成し、この生成した認証子と受信したコマンドに付加されている認証子とを照合し、両認証子が一致したとき認証成功とし、両認証子が一致しなかったとき認証不成功とすることを意味しており、その認証結果はワーキングメモリ203の認証状態格納領域203bに格納される。認証子の認証が成功したときにコマンド処理が行なわれる。
As access conditions for the secure messaging process, there may be no secure messaging, an authenticator is required, data encryption is required, an authenticator and data encryption is required, and the like.
Here, the fact that an authenticator is necessary means that the data of a specific part (for example, a header part or a data part) of the received command is encrypted by using the authenticator generation key in the authenticator generation key EF306. The generated authenticator is compared with the authenticator attached to the received command. If both authenticators match, authentication is successful, and if both authenticators do not match, authentication fails. The authentication result is stored in the authentication state storage area 203b of the working memory 203. Command processing is performed when authentication of the authenticator is successful.

また、データ暗号化が必要とは、データ暗号化鍵EF305内のデータ暗号化鍵を用いてデータを復号化(暗号化)してからコマンド処理を行なうことを意味している。たとえば、データ書込コマンドの場合、当該コマンドに付加された書込みデータをデータ暗号化鍵EF305内のデータ暗号化鍵を用いて復号化してから、データメモリ102に対する書込み処理を行なう。また、たとえば、データ読出コマンドの場合、データメモリ102から当該コマンドで指定されたデータオブジェクトを読出し、この読出したデータオブジェクトをデータ暗号化鍵EF305内のデータ暗号化鍵を用いて暗号化してから、カードリーダ・ライタ102へ出力する。   The necessity of data encryption means that command processing is performed after the data is decrypted (encrypted) using the data encryption key in the data encryption key EF305. For example, in the case of a data write command, the write data added to the command is decrypted using the data encryption key in the data encryption key EF 305, and then the data memory 102 is written. Further, for example, in the case of a data read command, the data object specified by the command is read from the data memory 102, and the read data object is encrypted using the data encryption key in the data encryption key EF305. The data is output to the card reader / writer 102.

また、認証子およびデータ暗号化が必要とは、認証子およびデータ暗号化が必要であり、上記したように認証子の認証が成功し、かつ、データ部を復号化(暗号化)してからコマンド処理を行なうことを意味している。   In addition, the authentication code and data encryption are required. The authentication code and data encryption are necessary. As described above, the authentication of the authentication code is successful and the data part is decrypted (encrypted). This means that command processing is performed.

図6は、カードリーダ・ライタ102からICカード101へ送られるコマンドのフォーマット例を示している。この例は、たとえば、データオブジェクトを読出す際の読出コマンドを示していて、コマンドを識別する機能などを持つ分類部(CLA:class)701、命令部(INS:instruction)702、および、パラメータデータ(P1、P2)703,704から構成されている。
パラメータデータ(P1、P2)703,704には、たとえば、読出し対象となるデータオブジェクトを指定する当該データオブジェクトのタグ(Tag)値が格納される。
FIG. 6 shows a format example of a command sent from the card reader / writer 102 to the IC card 101. This example shows, for example, a read command for reading a data object, and includes a classification unit (CLA: class) 701, a command unit (INS: instruction) 702, and parameter data having a function for identifying the command. (P1, P2) 703 and 704.
The parameter data (P1, P2) 703, 704 stores, for example, a tag value of the data object that designates a data object to be read.

次に、このような構成において、カードリーダ・ライタ102からのコマンドに対するアクセス処理について図7に示すフローチャートを参照して説明する。この例は、たとえば、データオブジェクトを読出す読出コマンドに対する処理について説明する。   Next, an access process for a command from the card reader / writer 102 in such a configuration will be described with reference to a flowchart shown in FIG. In this example, for example, processing for a read command for reading a data object will be described.

CPU201は、カードリーダ・ライタ102から入力される読出コマンドを受信すると(ステップS1)、当該読出コマンドとしての正当性を確認すべく、コマンドフォーマットのチェックを行なう(ステップS2)。このフォーマットチェックでは、たとえば、当該読出コマンドの分類部701および命令部702が正規のコマンドを示すものかどうかを確認し、パラメータデータ703,704が機能外に設定されていないかを確認する。   When the CPU 201 receives a read command input from the card reader / writer 102 (step S1), the CPU 201 checks the command format to confirm the validity of the read command (step S2). In this format check, for example, it is confirmed whether or not the classification unit 701 and the instruction unit 702 of the read command indicate a regular command, and whether or not the parameter data 703 and 704 are set outside the function.

ステップS2におけるフォーマットチェックの結果、フォーマットに異常が発見された場合、CPU201は、フォーマットエラーを示すステータスワードを設定して、当該ステータスワードの出力処理を実行し(ステップS3)、当該処理を終了する。   As a result of the format check in step S2, if an abnormality is found in the format, the CPU 201 sets a status word indicating a format error, executes the status word output process (step S3), and ends the process. .

ステップS2におけるフォーマットチェックの結果、フォーマットに異常が発見されなかった場合、CPU201は、当該読出コマンドのパラメータデータ703,704に格納されたタグ値は正しいか否かをチェックし(ステップS4)、正しくない場合、処理エラーを示すステータスワードを設定して、当該ステータスワードの出力処理を実行し(ステップS3)、当該処理を終了する。   If no abnormality is found in the format as a result of the format check in step S2, the CPU 201 checks whether the tag values stored in the parameter data 703 and 704 of the read command are correct (step S4). If not, a status word indicating a processing error is set, the status word output process is executed (step S3), and the process ends.

ステップS4におけるチェックの結果、パラメータデータ703,704に格納されたタグ値が正しい場合、CPU201は、当該読出コマンドのパラメータデータ703,704に格納されたタグ値に基づき、図5のタグリストテーブル309を参照することにより、当該タグ値に対応する(同一の)タグ値(読出し対象となるデータオブジェクトのタグ値)501を持つタグテーブル403(404)を検索する(ステップS5)。   If the tag values stored in the parameter data 703 and 704 are correct as a result of the check in step S4, the CPU 201 determines that the tag list table 309 in FIG. 5 is based on the tag values stored in the parameter data 703 and 704 of the read command. , The tag table 403 (404) having the tag value (the tag value of the data object to be read) 501 corresponding to the tag value is searched (step S5).

ステップS5における検索の結果、読出し対象となるデータオブジェクトのタグ値501を持つタグテーブル403(404)が存在しない場合、CPU201は、処理エラーを示すステータスワードを設定して、当該ステータスワードの出力処理を実行し(ステップS3)、当該処理を終了する。   If the tag table 403 (404) having the tag value 501 of the data object to be read does not exist as a result of the search in step S5, the CPU 201 sets a status word indicating a processing error and outputs the status word. Is executed (step S3), and the process ends.

ステップS5における検索の結果、読出し対象となるデータオブジェクトのタグ値501を持つタグテーブル403(404)が存在する場合、CPU201は、当該タグテーブル403(404)内のファイルID(DID)504と同一のファイルIDを持つファイル(読出し対象となるファイル)をデータメモリ102から検索する(ステップS6)。   If the tag table 403 (404) having the tag value 501 of the data object to be read exists as a result of the search in step S5, the CPU 201 is the same as the file ID (DID) 504 in the tag table 403 (404). A file having the file ID (file to be read) is searched from the data memory 102 (step S6).

ステップS6における検索の結果、読出し対象となるファイルが存在しない場合、CPU201は、処理エラーを示すステータスワードを設定して、当該ステータスワードの出力処理を実行し(ステップS3)、当該処理を終了する。   If the file to be read does not exist as a result of the search in step S6, the CPU 201 sets a status word indicating a processing error, executes the status word output process (step S3), and ends the process. .

ステップS6における検索の結果、読出し対象となるファイルが存在する場合、CPU201は、ステップS5で検索されたタグテーブル403(404)内のアクセス条件505および図4の照合状態、認証状態を参照することによって、当該読出コマンド処理が対象となっているデータオブジェクトに対して許容できるか否かを判定する(ステップS7)。   If there is a file to be read as a result of the search in step S6, the CPU 201 refers to the access condition 505 in the tag table 403 (404) searched in step S5 and the collation state and authentication state in FIG. Thus, it is determined whether or not the data object for which the read command processing is targeted is acceptable (step S7).

ステップS7おける判定の結果、対象データオブジェクトに対して処理が許容されない場合、CPU201は、処理エラーを示すステータスワードを設定して、当該ステータスワードの出力処理を実行し(ステップS3)、当該処理を終了する。   If the result of determination in step S7 is that processing is not allowed for the target data object, the CPU 201 sets a status word indicating a processing error, executes output processing of the status word (step S3), and executes the processing. finish.

ステップS7おける判定の結果、対象データオブジェクトに対して処理が許容される場合、CPU201は、当該データオブジェクトに対して読出処理を実行し(ステップS8、その後、当該処理が正常に終了すると、正常終了を示すステータスワードを設定して、当該ステータスワードの出力処理を実行し(ステップS9)、当該処理を終了する。   As a result of the determination in step S7, if the process is permitted for the target data object, the CPU 201 executes the read process for the data object (step S8, and if the process ends normally, the process ends normally. Is set, a status word output process is executed (step S9), and the process ends.

ステップS8において、読出処理が正常に終了せず、読出異常が生じた場合、CPU201は、処理エラーを示すステータスワードを設定して、当該ステータスワードの出力処理を実行し(ステップS3)、当該処理を終了する。   In step S8, when the reading process does not end normally and a reading abnormality occurs, the CPU 201 sets a status word indicating a processing error, executes the output process of the status word (step S3), and the processing Exit.

以上説明したように、上記実施の形態によれば、データを保持する不揮発性メモリを有し、このメモリには少なくとも1つのファイルが設定され、このファイルには複数のデータオブジェクトが格納されていて、外部から入力されるコマンドを解釈して実行することで、前記ファイルに対しアクセスするICカードにおいて、外部から入力されるコマンドを実行するための条件を複数のデータオブジェクトごとに設定しておき、この設定された条件に基づき、外部から入力されるコマンドを実行することによりファイルに対しデータオブジェクト単位にアクセスすることにより、従来のファイル単位にアクセス条件を設定した場合よりも細かなアクセス制御を行なうことが可能となる。   As described above, according to the above-described embodiment, the nonvolatile memory that holds data is provided, at least one file is set in the memory, and a plurality of data objects are stored in the file. In the IC card that accesses the file by interpreting and executing the command input from the outside, a condition for executing the command input from the outside is set for each of the plurality of data objects, Based on this set condition, by executing an externally input command, the file is accessed in the data object unit, thereby performing finer access control than when the access condition is set in the conventional file unit. It becomes possible.

なお、前記実施の形態では、携帯可能電子装置としてICカードに適用した場合について説明したが、本発明はこれに限定されるものではなく、たとえば、PDAと称される携帯端末装置や携帯電話機などであっても適用でき、また、形状もカード型に限らず、冊子型、ブロック形あるいはタグ型などであってもよい。   In the above-described embodiment, the case where the present invention is applied to an IC card as a portable electronic device has been described. However, the present invention is not limited to this, and for example, a portable terminal device called PDA, a cellular phone, etc. However, the shape is not limited to the card type, but may be a booklet type, a block type, or a tag type.

本発明に係る携帯可能電子装置としてのICカードを取扱うICカードシステムの構成例を示すブロック図。The block diagram which shows the structural example of the IC card system which handles the IC card as a portable electronic device concerning the present invention. ICカードの構成を概略的に示すブロック図。1 is a block diagram schematically showing the configuration of an IC card. データメモリの内部構造例を示す模式図。The schematic diagram which shows the internal structure example of a data memory. ワーキングメモリの内部構造例を示す模式図。The schematic diagram which shows the example of an internal structure of a working memory. タグリストテーブルの詳細を示す構成図。The block diagram which shows the detail of a tag list table. ICカードへ送られる読出コマンドのフォーマット例を示す模式図。The schematic diagram which shows the example of a format of the read command sent to an IC card. 読出コマンドに対するアクセス処理について説明するフローチャート。The flowchart explaining the access process with respect to a read command.

符号の説明Explanation of symbols

101…ICカード(携帯可能電子装置)、101a…ICカード本体、102…カードリーダ・ライタ、103…端末装置、104…キーボード、105…CRT表示部、106…プリンタ、201…CPU(制御素子)、202…データメモリ(記憶手段)、203…ワーキングメモリ、204…プログラムメモリ、205…通信部、206…ICチップ、309…タグリストテーブル、403,404…タグテーブル、501…タグ値、505…アクセス条件。   DESCRIPTION OF SYMBOLS 101 ... IC card (portable electronic device), 101a ... IC card main body, 102 ... Card reader / writer, 103 ... Terminal device, 104 ... Keyboard, 105 ... CRT display part, 106 ... Printer, 201 ... CPU (control element) 202 ... Data memory (storage means) 203 ... Working memory 204 ... Program memory 205 ... Communication unit 206 ... IC chip 309 ... Tag list table 403,404 ... Tag table 501 ... Tag value 505 ... Access conditions.

Claims (7)

メモリを有し、このメモリには少なくとも1つのファイルが設定され、このファイルには当該データの種別を示す識別子と当該データの長さを示す長さ情報と当該データそのものを示すデータ部とを連結して構成されるデータオブジェクトが複数格納されていて、外部から入力される命令を解釈して実行することで、前記ファイルに対しアクセスする携帯可能電子装置において、
外部から入力される命令を実行するための条件を、前記複数のデータオブジェクトの各識別子にそれぞれ対応させて設定する条件設定手段と、
外部から入力される命令を受信すると、当該命令により指定される識別子に基づき前記条件設定手段の設定内容を参照することにより、当該識別子に対応する識別子を持つ条件を検索する検索手段と、
この検索手段により検索された条件に基づき、前記受信した命令を実行することにより、前記ファイルに対しデータオブジェクト単位にアクセスするアクセス制御手段と、
を具備したことを特徴とする携帯可能電子装置。
The memory has at least one file, and an identifier indicating the type of the data, length information indicating the length of the data, and a data portion indicating the data itself are connected to the file. In a portable electronic device that accesses the file by interpreting and executing a command input from the outside, a plurality of data objects configured as described above are stored,
Condition setting means for setting a condition for executing an instruction input from the outside in correspondence with each identifier of the plurality of data objects;
When receiving an instruction input from the outside, referring to the setting content of the condition setting means based on the identifier specified by the instruction, search means for searching for a condition having an identifier corresponding to the identifier;
Access control means for accessing the file in units of data objects by executing the received command based on the conditions searched by the search means;
A portable electronic device comprising:
前記命令の内容は、データオブジェクトのアクセスであり、データオブジェクトに対するデータの読出し、書込み、削除、データオブジェクトの追加のうち少なくともいずれか1つであることを特徴とする請求項1記載の携帯可能電子装置。   2. The portable electronic device according to claim 1, wherein the content of the instruction is an access to a data object, and is at least one of reading, writing, deleting, and adding a data object to the data object. apparatus. 前記条件設定手段が設定するた条件とは、当該条件に沿ってデータオブジェクトのアクセス可否を判断する命令の実行前に実行された特定の命令の実行結果、あるいは、データオブジェクトをアクセスする命令自身の形式等であることを特徴とする請求項1または請求項2記載の携帯可能電子装置。   The condition set by the condition setting means is an execution result of a specific instruction executed before execution of an instruction that determines whether or not a data object is accessible according to the condition, or an instruction itself that accesses a data object. The portable electronic device according to claim 1, wherein the portable electronic device is in a format or the like. 前記特定の命令の実行結果とは、照合命令に基づく照合キーの照合結果、あるいは、認証命令に基づく認証キーによる認証結果等であることを特徴とする請求項3記載の携帯可能電子装置。   4. The portable electronic device according to claim 3, wherein the execution result of the specific command is a verification result of a verification key based on a verification command, an authentication result based on an authentication key based on an authentication command, or the like. 前記命令自身の形式とは、セキュアメッセージング処理の有無等であることを特徴とする請求項3記載の携帯可能電子装置。   4. The portable electronic device according to claim 3, wherein the format of the command itself is presence / absence of secure messaging processing. メモリを有し、このメモリには少なくとも1つのファイルが設定され、このファイルには当該データの種別を示す識別子と当該データの長さを示す長さ情報と当該データそのものを示すデータ部とを連結して構成されるデータオブジェクトが複数格納されていて、外部から入力される命令を解釈して実行することで、前記ファイルに対しアクセスする携帯可能電子装置におけるファイルアクセス方法であって、
外部から入力される命令を実行するための条件を、前記複数のデータオブジェクトの各識別子にそれぞれ対応させて設定しておき、外部から入力される命令を受信すると、当該命令により指定される識別子に基づき前記条件の設定内容を参照することにより、当該識別子に対応する識別子を持つ条件を検索し、この検索された条件に基づき、前記受信した命令を実行することにより、前記ファイルに対しデータオブジェクト単位にアクセスすることを特徴とする携帯可能電子装置におけるファイルアクセス方法。
The memory has at least one file, and an identifier indicating the type of the data, length information indicating the length of the data, and a data portion indicating the data itself are connected to the file. A file access method in a portable electronic device that accesses the file by interpreting and executing a command input from the outside, wherein a plurality of data objects configured are stored;
Conditions for executing an instruction input from the outside are set in correspondence with each identifier of the plurality of data objects, and when an instruction input from the outside is received, the identifier specified by the instruction is set. By referring to the setting contents of the condition based on this, a condition having an identifier corresponding to the identifier is searched, and based on the searched condition, the received command is executed, so that a data object unit is obtained for the file. A method for accessing a file in a portable electronic device, characterized in that:
メモリを有し、このメモリには少なくとも1つのファイルが設定され、このファイルには当該データの種別を示す識別子と当該データの長さを示す長さ情報と当該データそのものを示すデータ部とを連結して構成されるデータオブジェクトが複数格納されていて、外部から入力される命令を解釈して実行することで、前記ファイルに対しアクセスするICカードにおいて、
外部から入力される命令を実行するための条件を、前記複数のデータオブジェクトの各識別子にそれぞれ対応させて設定する条件設定手段と、外部から入力される命令を受信すると、当該命令により指定される識別子に基づき前記条件設定手段の設定内容を参照することにより、当該識別子に対応する識別子を持つ条件を検索する検索手段と、この検索手段により検索された条件に基づき、前記受信した命令を実行することにより、前記ファイルに対しデータオブジェクト単位にアクセスするアクセス制御手段とを有したICモジュールと、
このICモジュールを収納したICカード本体と、
を具備したことを特徴とするICカード。
The memory has at least one file, and an identifier indicating the type of the data, length information indicating the length of the data, and a data portion indicating the data itself are connected to the file. In an IC card that accesses the file by interpreting and executing a command input from the outside, a plurality of data objects configured as described above are stored,
Condition setting means for setting a condition for executing a command input from the outside corresponding to each identifier of the plurality of data objects, and when a command input from the outside is received, specified by the command By referring to the setting contents of the condition setting means based on the identifier, a search means for searching for a condition having an identifier corresponding to the identifier, and the received instruction is executed based on the condition searched by the search means An IC module having access control means for accessing the file in units of data objects;
An IC card body containing the IC module;
An IC card comprising:
JP2007142201A 2007-03-29 2007-05-29 Portable electronic device, file access method in portable electronic device, and ic card Pending JP2008299416A (en)

Priority Applications (4)

Application Number Priority Date Filing Date Title
JP2007142201A JP2008299416A (en) 2007-05-29 2007-05-29 Portable electronic device, file access method in portable electronic device, and ic card
SG200801948-1A SG146551A1 (en) 2007-03-29 2008-03-10 Portable electronic device and control method of portable electronic device
FR0851649A FR2914449B1 (en) 2007-03-29 2008-03-14 PORTABLE ELECTRONIC DEVICE AND METHOD FOR CONTROLLING A PORTABLE ELECTRONIC DEVICE.
US12/049,820 US7775423B2 (en) 2007-03-29 2008-03-17 Portable electronic device and control method of portable electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007142201A JP2008299416A (en) 2007-05-29 2007-05-29 Portable electronic device, file access method in portable electronic device, and ic card

Publications (1)

Publication Number Publication Date
JP2008299416A true JP2008299416A (en) 2008-12-11

Family

ID=40172921

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007142201A Pending JP2008299416A (en) 2007-03-29 2007-05-29 Portable electronic device, file access method in portable electronic device, and ic card

Country Status (1)

Country Link
JP (1) JP2008299416A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016076153A (en) * 2014-10-08 2016-05-12 株式会社東芝 Portable electronic device and method
JP2017174269A (en) * 2016-03-25 2017-09-28 凸版印刷株式会社 Ic card and method for reading data from ic card
JP2022148539A (en) * 2021-03-24 2022-10-06 大日本印刷株式会社 Secure element and method for managing access to data object

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2001243118A (en) * 2001-04-20 2001-09-07 Ntt Data Corp Ic card and personalizing device
JP2005275739A (en) * 2004-03-24 2005-10-06 Toppan Printing Co Ltd Information recording medium and program, and command execution control method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2001243118A (en) * 2001-04-20 2001-09-07 Ntt Data Corp Ic card and personalizing device
JP2005275739A (en) * 2004-03-24 2005-10-06 Toppan Printing Co Ltd Information recording medium and program, and command execution control method

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016076153A (en) * 2014-10-08 2016-05-12 株式会社東芝 Portable electronic device and method
JP2017174269A (en) * 2016-03-25 2017-09-28 凸版印刷株式会社 Ic card and method for reading data from ic card
JP2022148539A (en) * 2021-03-24 2022-10-06 大日本印刷株式会社 Secure element and method for managing access to data object
JP7363844B2 (en) 2021-03-24 2023-10-18 大日本印刷株式会社 How to manage access to secure elements and data objects

Similar Documents

Publication Publication Date Title
US7775423B2 (en) Portable electronic device and control method of portable electronic device
JP5843674B2 (en) IC card, portable electronic device, and control method of IC card
JP4891587B2 (en) Portable electronic device, IC card and IC module
JP2008243045A (en) Portable electronic apparatus and ic card
JP2008299416A (en) Portable electronic device, file access method in portable electronic device, and ic card
JP2014041552A (en) Ic card and portable electronic device
JP4950730B2 (en) Portable electronic device, file access method and IC card in portable electronic device
JP5301018B2 (en) Portable electronic device
JP2007115187A (en) Portable electronic device and ic card
JP2001167236A (en) Portable electronic device
JP2011171946A (en) Portable electronic device, method for controlling portable electronic device, and ic card
JP5306079B2 (en) IC card, IC card processing device, and IC card processing system
JP6499052B2 (en) IC card, IC module, and program
JP4836716B2 (en) Portable electronic device and IC card
US7346730B2 (en) Mobile electronic device
JP2009134545A (en) Portable electronic device and ic card
JP4533665B2 (en) Portable electronic device
JP4738249B2 (en) Portable electronic device, IC card and IC module
JP5085055B2 (en) IC card and IC module
JP2006172005A (en) Portable electronic instrument
JP5957347B2 (en) IC card and portable electronic device
JP2008047040A (en) Portable electronic device and ic card
JP5492172B2 (en) Portable electronic device, IC card and IC module
JP2009176034A (en) Portable electronic device and data management method
JP6039036B2 (en) IC card, portable electronic device, and control method of IC card

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20100316

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20120423

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20120508

RD04 Notification of resignation of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7424

Effective date: 20120529

A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20120911