[go: up one dir, main page]

JP3545045B2 - Creating a pattern file for IC card access - Google Patents

Creating a pattern file for IC card access Download PDF

Info

Publication number
JP3545045B2
JP3545045B2 JP12822894A JP12822894A JP3545045B2 JP 3545045 B2 JP3545045 B2 JP 3545045B2 JP 12822894 A JP12822894 A JP 12822894A JP 12822894 A JP12822894 A JP 12822894A JP 3545045 B2 JP3545045 B2 JP 3545045B2
Authority
JP
Japan
Prior art keywords
command
card
pattern file
response
format
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.)
Expired - Lifetime
Application number
JP12822894A
Other languages
Japanese (ja)
Other versions
JPH07311820A (en
Inventor
宏 逢坂
恵美 早田
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Dai Nippon Printing Co Ltd
Original Assignee
Dai Nippon Printing Co Ltd
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 Dai Nippon Printing Co Ltd filed Critical Dai Nippon Printing Co Ltd
Priority to JP12822894A priority Critical patent/JP3545045B2/en
Publication of JPH07311820A publication Critical patent/JPH07311820A/en
Application granted granted Critical
Publication of JP3545045B2 publication Critical patent/JP3545045B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Images

Landscapes

  • Credit Cards Or The Like (AREA)

Description

【0001】
【産業上の利用分野】
本発明はICカードアクセス用パターンファイルの作成方法、特に、各ICカードに別個の個人情報を書き込む処理を行う場合に用いるパターンファイルを作成する方法に関する。
【0002】
【従来の技術】
磁気カードに代わる新しい情報記憶媒体として、ICカードが注目を集めている。特に、CPUを内蔵したICカードでは、内部に記憶された情報に関して高度のセキュリティが確保できるため、重要な情報を取り扱う分野においても広く利用されるものと期待されている。
【0003】
現在、一般的に普及しているICカードは、リーダライタ装置によってアクセスされる。特に、CPUを内蔵したICカードでは、インターフェイス回路を介して、リーダライタ装置とICカード内部のCPUとが信号伝送路で結合され、この信号伝送路を介して、両者の間での情報交換が行われる。この場合、リーダライタ装置からICカードへは、コマンドという形式で情報が伝達され、逆に、ICカードからリーダライタ装置へは、このコマンドに対するレスポンスという形式で情報が伝達される。ICカード内のCPUは、リーダライタ装置から与えられたコマンドに基いて、リセット、内蔵メモリへの書き込みや読出しなど、種々の処理を実行し、その実行結果をレスポンスという形式でリーダライタ装置側へ返すことになる。たとえば、リーダライタ装置側からリセットコマンドが与えられると、ICカード側のCPUはリセット処理を実行した後、このリセット処理の実行を示す所定のコードをレスポンスとしてリーダライタ装置側へと返すことになる。また、リーダライタ装置側から所定のデータとともにこれを所定のアドレスに書き込む命令がコマンドとして与えられると、ICカード側のCPUは、コマンドとして与えられたデータを内部メモリに書き込む処理を実行した後、正しく書き込まれたか、あるいは何らかのエラーが発生したか、を示す情報をレスポンスとしてリーダライタ装置側へと返すことになる。
【0004】
このように、リーダライタ装置とICカードとの間の情報交換は、リーダライタ装置側からICカード側へのコマンドの往信処理と、ICカード側からリーダライタ装置側へのレスポンスの返信処理と、を交互に繰り返し実行することにより行われている。リーダライタ装置側は、返信処理によりICカード側から返ってきたレスポンスに基いて、先に与えたコマンドが正しく実行されたか否かを判断することができる。このようなICカードに対するアクセス処理を円滑に行うため、通常は、リーダライタ装置側にパターンファイルが用意される。現在、一般的に利用されているパターンファイルは、コマンドと、このコマンドに応じて返信されるであろうと期待されるレスポンスの期待値と、を交互に並べたテーブルによって構成されている。すなわち、コマンド,レスポンスの期待値,コマンド,レスポンスの期待値,コマンド,…、というように、コマンドとレスポンスの期待値とを交互に配列したテーブルからなるパターンファイルを用意しておき、リーダライタ装置は、このパターンファイルの順序に従って、コマンドを送信し、これに応じて実際に返信されてきたレスポンスを、パターンファイル内のレスポンスの期待値と比較する処理を行うことになる。
【0005】
【発明が解決しようとする課題】
しかしながら、上述したパターンファイルを利用したアクセス方法では、多数のICカードに対するアクセスを行う場合に、パターンファイルを用意する作業に多大な労力が必要になる。たとえば、個人の会員番号、氏名、住所、電話番号、生年月日、などの個人情報を各ICカード内のメモリに書き込むことにより、1個人に1枚のICカードを発行する処理を行う場合、各個人ごとにパターンファイルを用意する必要がある。したがって、たとえば1000人分のICカードを発行する処理を行う場合には、このようなパターンファイルを1000人分用意する必要がある。また、用いるリーダライタ装置によっては、利用できるパターンファイルの書式が異なることがあり、このような書式の異なるパターンファイルを用意する作業は非常に能率が悪くなる。たとえば、リーダライタ装置Aにより前半の500人分の発行処理を行い、別なリーダライタ装置Bにより後半の500人分の発行処理を行う場合、前半の500人については書式Aによって記述されたパターンファイルを用意し、後半の500人については書式Bによって記述されたパターンファイルを用意しなければならない。
【0006】
そこで本発明は、各ICカードごとに異なる情報を記録するために用いるパターンファイルを、効率的に作成することができるパターンファイルの作成方法を提供することを目的とする。
【0007】
【課題を解決するための手段】
(1) 本発明の第1の態様は、CPUを内蔵したICカードと、このICカードをアクセスするためのリーダライタ装置と、の間に信号伝送路を形成し、この信号伝送路を介して、リーダライタ装置を制御するホストコンピュータからICカードへ所定のコマンドを往信し、ICカードからリーダライタ装置を介してホストコンピュータへコマンドに応じたレスポンスを返信する、という往信処理および返信処理を、コマンドおよび当該コマンドに応じて返信されるであろうと期待されるレスポンスの期待値を並べたパターンファイルに基いて実行することにより、ICカードに対するアクセスを行う場合に、アクセスに利用するパターンファイルを作成する方法において、
複数の個人情報をレコード単位で収容した個人情報ファイルを用意し、
部分的に個人情報ファイル内のデータを取り込む旨の取込指示を含んだコマンドおよびこれに対するレスポンスの期待値を、第1の書式で記述したひな形パターンファイルを用意し、
第1の書式を、リーダライタ装置が解読できる第2の書式に変換するための変換テーブルを用意し、
ひな形パターンファイルの所定部分に、取込指示に基いて、個人情報ファイル内の所定のデータを取り込むとともに、変換テーブルに基いて、第1の書式を第2の書式に変換することにより、第2の書式により記述された各個人ごとのパターンファイルを作成する処理をコンピュータに実行させるようにしたものである。
【0008】
(2) 本発明の第2の態様は、CPUを内蔵したICカードと、このICカードをアクセスするためのリーダライタ装置と、の間に信号伝送路を形成し、この信号伝送路を介して、リーダライタ装置を制御するホストコンピュータからICカードへ所定のコマンドを往信し、ICカードからリーダライタ装置を介して前記ホストコンピュータへコマンドに応じたレスポンスを返信する、という往信処理および返信処理を、コマンドおよび当該コマンドに応じて返信されるであろうと期待されるレスポンスの期待値を並べたパターンファイルに基いて実行することにより、ICカードに対するアクセスを行う場合に、アクセスに利用するパターンファイルを作成する方法において、
所定の規則に基づく演算によって、所定のデータを生成するデータ生成手段を用意し、
データ生成手段が生成した所定のデータを取り込む旨の取込指示を含んだコマンドおよびこれに対するレスポンスの期待値を、第1の書式で記述したひな形パターンファイルを用意し、
第1の書式を、リーダライタ装置が解読できる第2の書式に変換するための変換テーブルを用意し、
ひな形パターンファイルの所定部分に、取込指示に基いて、データ生成手段が生成した所定のデータを取り込むとともに、変換テーブルに基いて、第1の書式を第2の書式に変換することにより、第2の書式により記述された各個人ごとのパターンファイルを作成する処理をコンピュータに実行させるようにしたものである。
【0009】
(3) 本発明の第3の態様は、上述の第1または第2の態様に係るパターンファイルの作成方法において、
コマンドまたはレスポンスの期待値に、取込指示に基いて所定のデータを取り込んだ後、この取り込んだデータを含めたコマンドまたはレスポンスの期待値に対するエラーチェックコードを演算で求め、求めたエラーチェックコードをコマンドまたはレスポンスの期待値に付加するようにしたものである。
【0010】
【作 用】
個人の会員番号、氏名、住所、電話番号、生年月日、などの個人情報を各ICカードに書き込むことにより、1個人に1枚のICカードを発行するような処理を行う場合、個々のICカードの発行処理に用いるパターンファイルの内容は、それぞれ異なったものとなる。しかしながら、異なる部分は、個人の会員番号、氏名、住所、電話番号、生年月日、などの個人情報の部分だけであり、残りの部分はほとんどが共通したものとなる。本発明に係るパターンファイルの作成方法では、この共通した部分について、ひな形パターンファイルが用意される。このひな形パターンファイルでは、共通しない個々の個人情報の部分については、実際のデータの代わりに取込指示が記述されており、この取込指示が記述された部分については、後に、個人情報ファイル内の所定データが取り込まれることになる。すなわち、ひな形パターンファイルは、個々の個人情報を取り込むべき箇所に空白部分を設けたパターンファイルであり、この空白部分に、個人Aの個人情報を取り込めば、個人Aについてのパターンファイルが作成でき、個人Bの個人情報を取り込めば、個人Bについてのパターンファイルが作成できる。したがって、多数の個人用の異なるパターンファイルを効率的に作成することができる。
【0011】
また、本発明におけるひな形パターンファイルは、個々のリーダライタ装置に依存しない第1の書式で記述しておくことができ、この第1の書式のパターンファイルは、変換テーブルを利用して、個々のリーダライタ装置に適した第2の書式のパターンファイルに変換される。したがって、ひな形パターンファイルを作成する段階では、個々のリーダライタ装置を意識する必要はなく、能率的作業が可能になる。
【0012】
更に、連続番号として各個人に付与される会員番号のように、所定の規則に基づく演算によって自動的に発生できるデータについては、個人情報ファイルとして提供せずに、この所定の規則に基づいた演算によって自動生成する手段を用意しておけば、この手段によって生成したデータを取り込むことにより、異なる情報を記録するための個々のパターンファイルが効率的に作成できる。
【0013】
【実施例】
以下、本発明を図示する実施例に基いて説明する。まず、図1に示すブロック図に基いて、CPUを内蔵したICカードに対する従来の一般的なアクセス処理の手順を説明する。ここでは、2枚のICカード10,20を、リーダライタ装置30に同時に接続し、両ICカード10,20に対して適宜アクセスを行う場合を例にとって説明する。たとえば、多数の会員に対してそれぞれ会員証として1枚ずつICカードを発行するような場合、発行対象となるICカード10と、発行業務におけるキーカードとしての機能を果たすICカード20と、をリーダライタ装置30に接続し、発行業務を行うような形態を採ると、セキュリティを向上させることができる。すなわち、キーカードとしてのICカード20を用いない限り、発行業務を行うことができないので、ICカード20をきちんと管理しておけば、不正な方法で会員証(ICカード10)が発行されることを防ぐことができる。
【0014】
図1に示されているように、一般的なICカード10は、I/Oインターフェイス11と、CPU12と、ROM13と、RAM14と、EEPROM15と、を内蔵している。I/Oインターフェイス11は、リーダライタ装置30との間に形成された信号伝送路31を介して、外部と情報のやりとりを行う機能をもった装置である。信号伝送路31は、電気的な配線路として形成される場合もあるし、電磁的に結合された空間路として形成される場合もある。リーダライタ装置30から信号伝送路31を介してI/Oインターフェイス11に与えられた情報は、CPU12に伝送され、逆に、CPU12から外部へ伝送すべき情報は、I/Oインターフェイス11から信号伝送路31を介してリーダライタ装置30に与えられる。リーダライタ装置30には、ホストコンピュータ40が接続されており、リーダライタ装置30はこのホストコンピュータ40の制御に基き、ICカード10に対するアクセス処理を行うことになる。また、ICカード20もICカード10と全く同様に、I/Oインターフェイス21と、CPU22と、ROM23と、RAM24と、EEPROM25と、を備えており、信号伝送路32を介してリーダライタ装置30に接続されている。
【0015】
ICカード10内には、ROM13、RAM14、EEPROM15という3種類のメモリが用意されている。ROM13は、CPU12を動作させるための基本的なプログラムを格納したメモリであり、CPU12は、このROM13内のプログラムに基いて種々の演算処理を実行することになる。RAM14は、この演算処理におけるワークスペースとして利用されるメモリである。また、EEPROM15は、主として、このICカード10の本来の機能であるユーザデータの蓄積に用いられるメモリであり、リーダライタ装置30側から与えられたユーザデータは、CPU12によってこのEEPROM15に書き込まれる。また、リーダライタ装置30側から所定の読出し命令が与えられると、CPU12は、EEPROM15内のユーザデータを読出し、これをリーダライタ装置30側へと返信する。ICカード20内のROM23、RAM24、EEPROM25という3種類のメモリも、同様の用途に利用される。
【0016】
ICカード10,20とリーダライタ装置30との間での情報交換は、コマンドCとレスポンスRという形式で行われる。すなわち、リーダライタ装置30からICカード10,20へは、コマンドCという形式で情報が伝達され、逆に、ICカード10,20からリーダライタ装置30へは、このコマンドCに対するレスポンスRという形式で情報が伝達される。すなわち、両者間の情報交換は、リーダライタ装置30側からICカード10,20側へのコマンドCの往信処理と、ICカード10,20側からリーダライタ装置30側へのレスポンスRの返信処理と、を交互に繰り返し実行することにより行われている。
【0017】
このようなICカード10に対するアクセス処理を円滑に行うため、通常は、図2に示すようなパターンファイルFが用意される。このパターンファイルFは、コマンドCと、このコマンドCに応じて返信されるであろうと期待されるレスポンスR(ICカード側から返信される本来の「レスポンス」ではなく、あくまでも「レスポンスの期待値」であるが、以下の説明では便宜上、単に「レスポンス」と呼ぶ)と、を交互に並べたテーブルによって構成されている。図2の例では、コマンドC1,レスポンスR1,コマンドC2,レスポンスR2,コマンドC3,レスポンスR3…、というように、コマンドCとレスポンスRとが交互に配列されている。ここで、コマンドC1は、第1番目にICカード側に与えるべきコマンドであり、レスポンスR1は、このコマンドC1を往信として与えたときに、ICカード側から返信されるであろうと期待されるレスポンスである。同様に、コマンドC2は、第2番目にICカード側に与えるべきコマンドであり、レスポンスR2は、このコマンドC2を往信として与えたときに、ICカード側から返信されるであろうと期待されるレスポンスである。
【0018】
この図2に示すようなパターンファイルFを、ホストコンピュータ40において用意しておき、必要に応じてリーダライタ装置30に与えるようにすれば、リーダライタ装置30は、このパターンファイルFに基いて、ICカードに対する円滑なアクセスを行うことができる。すなわち、まず、リーダライタ装置30はコマンドC1をICカード側に送る往信処理を行う。ICカード10または20のいずれにコマンドC1を送ればよいかは、パターンファイルF内に記述された指示に従う。たとえば、ICカード10に対してコマンドC1を送ったとすると、ICカード10内のCPU12は、このコマンドC1を実行した後、所定のレスポンスをリーダライタ装置30に返す返信処理を行う。そこで、リーダライタ装置30は、この実際に返信されたレスポンスを、パターンファイルF内のレスポンスR1と比較照合し、問題がなければ、次のコマンドC2をICカード10に送る往信処理を行う。CPU12は、このコマンドC2を実行した後、所定のレスポンスをリーダライタ装置30に返す返信処理を行う。そこで、リーダライタ装置30は、この実際に返信されたレスポンスを、パターンファイルF内のレスポンスR2と比較照合し、問題がなければ、次のコマンドC3をICカード10に送る往信処理を行う。このように、リーダライタ装置30は、パターンファイルFに並べられたコマンド/レスポンスを順に用いて、円滑に往信および返信処理を行うことができる。なお、レスポンスの照合の結果、何らかの問題があれば、もう一度同じコマンドを送り直すなどの措置がとられることになる。
【0019】
以上のように、パターンファイルFを利用したアクセス方法は、リーダライタ装置30の負担を軽減することができ、能率的なアクセスをすることができるが、多数のICカードに対して異なる内容のアクセス処理を行うような場合には、用意すべきパターンファイルが多くなり、これらパターンファイルを用意する作業に多大な労力が必要になることは、既に述べたとおりである。たとえば、ICカードを会員証として発行するような例を考えてみる。この会員証には、会員の氏名、住所、電話番号、生年月日、などの個人情報を記録する必要があるものとする。この場合、ICカード10を会員証として発行するには、これらの個人情報をEEPROM15内に書き込む必要があり、会員の数だけパターンファイルを用意しておく必要がある。
【0020】
また、このパターンファイルを用意する段階でのもうひとつの問題点は、パターンファイルの書式が、用いるリーダライタ装置によって異なるという点である。一般に、ICカードに関しては、ISOの規格などによりある程度の標準化が図られており、ICカードに対して与えるコマンドCや、ICカードから返信されてくるレスポンスRとしては、所定の書式が定められている。しかしながら、リーダライタ装置は、種々のメーカにより種々のものが提供されており、全く同一のICカードに対するアクセスを行う場合であっても、リーダライタ装置Aを利用する場合に必要なパターンファイルの書式と、リーダライタ装置Bを利用する場合に必要なパターンファイルの書式と、は異なるのが一般的である。したがって、パターンファイルを用意する場合、ICカードのアクセスにどのリーダライタ装置を用いるか、という点を考慮する必要があり、所定の書式で記述しなければならない。
【0021】
ここでは、このパターンファイルの作成手順を、より具体的な例を挙げて説明してみる。たとえば、利用するリーダライタ装置が、図3に示すようなコマンドコードの書式を要求し、図4に示すようなレスポンスコードの書式を要求する場合を考える。図3に示すコマンドコードは、制御部▲1▼,▲2▼,▲3▼と、コマンド部と、BCCと、の3つの部分から構成されている。ここで、ICカード側に実際にコマンドCとして送信される部分は、コマンド部とBCC(エラーチェックコード)とにより構成される部分である。制御部▲1▼,▲2▼,▲3▼は、リーダライタ装置の内部処理のための情報を与える部分であり、ICカード側へは送信されない。ここに示す例では、コマンドコードを8種類に分け、それぞれの書式が表で示されている。すなわち、通常コマンド1,2,リセットコマンド1,2,パワーオンリセットコマンド1,2,組込コマンド1,2の8種類が用意されている。ここで、各コマンドの末尾の数字1,2は、アクセス対象となるICカードを特定する数字であり、数字1はICカード10がアクセス対象であることを示し、数字2はICカード20がアクセス対象であることを示している。
【0022】
通常コマンドは、ICカードに対する書き込みや読出しなどを行う一般的なコマンドであり、所定のコマンドコード列(書式は、ICカードの規格によって定められている)をBCCコードとともにICカード10またはICカード20に送信するためのものである。制御部▲1▼の「00」または「01」は、通常コマンド1(ICカード10が対象)または通常コマンド2(ICカード20が対象)のいずれかであるかを特定する部分である。また、制御部▲2▼は、用いられておらず(表では「φ」と示されており、この2バイトは無視される)、制御部▲3▼は、以下に続くコマンド部およびBCCの合計バイト数(コマンド長)を示すものである。
【0023】
リセットコマンドおよびパワーオンリセットコマンドは、ICカードに対してリセット信号を与えるためのコマンドであり、前者は、ICカードが既に立ち上がった状態においてCPUをリセットするコマンド、後者は、ICカードに対して電源やクロックの供給を行い立ち上げ動作を行うとともにCPUをリセットするコマンドである。制御部▲1▼は、リセットコマンドか、パワーオンリセットコマンドか、を特定する情報を与え、制御部▲2▼は、対象となるICカードがICカード10(0000)か、ICカード20(FFFF)か、を示すものである。なお、これらのコマンドは、通常のデータ伝送用の信号伝送路31,32を介して何らかのコードを送るのではなく、専用のリセットラインあるいは専用の電源ラインやクロックラインを介して、リセット信号あるいは電源供給やクロック供給を行うためのものなので、コマンド部には何らデータはない。したがって、コマンド長を示す制御部▲3▼は「00」となっている。
【0024】
組込コマンドは、上述した通常コマンドの特殊な形態であり、コマンドコード列内に、前回のレスポンスとして得られたレスポンスコード列内の所定部分のデータを組込んで、これをICカードに送信するためのものである。通常コマンドとの書式上の相違は、制御部▲1▼が、組込コマンドであることを示す「10」(ICカード10が対象)あるいは「11」(ICカード20が対象)になっている点と、制御部▲2▼に、組込開始位置と長さが指定されている点である。この組込コマンドについては、後に実例に即して説明を行う。
【0025】
一方、図4に示すレスポンスコードは、制御部▲1▼,▲2▼,▲3▼と、レスポンス部と、BCCと、の3つの部分から構成されている。ここで、ICカード側から実際にレスポンスRとして返信されると期待される部分は、レスポンス部とBCC(エラーチェックコード)とにより構成される部分である。すなわち、基本的には、ICカード側からレスポンスRとして実際に返信されてきたデータを、図4に示す「レスポンス部+BCC」の部分と比較照合することになる。制御部▲1▼,▲2▼,▲3▼は、リーダライタ装置の内部処理のための情報を与える部分である。ここに示す例では、レスポンスコードを3種類に分け、それぞれの書式が表で示されている。
【0026】
全チェックは、ICカード側から返信されてきたレスポンスRを全桁にわたって比較照合するものである。制御部▲1▼の「08」は、このレスポンスコードが「全チェック」のレスポンスコードであることを示す部分である。制御部▲2▼は、用いられておらず(表では「φ」と示されており、この2バイトは無視される)、制御部▲3▼は、以下に続くレスポンス部およびBCCの合計バイト数(レスポンス長)を示すものである。
【0027】
部分チェックは、ICカード側から返信されてきたレスポンスRの一部分の桁だけを比較照合するものである。制御部▲1▼の「0A」は、このレスポンスコードが「部分チェック」のレスポンスコードであることを示す部分である。制御部▲2▼は、チェック開始位置と長さを示しており、制御部▲3▼は、以下に続くレスポンス部およびBCCの合計バイト数(レスポンス長)を示すものである。たとえば、チェック開始位置が「03」、長さが「02」となっていれば、レスポンスコード列の先頭から3バイト目から2バイト分だけが比較照合の対象となり、他の部分は無視されることになる。
【0028】
部分記憶は、ICカード側から返信されてきたレスポンスRの一部分の桁を記憶する処理を行うものである。制御部▲1▼の「1C」は、このレスポンスコードが「部分記憶」のレスポンスコードであることを示す部分である。制御部▲2▼は、記憶開始位置と長さを示しており、制御部▲3▼は、以下に続くレスポンス部およびBCCの合計バイト数(レスポンス長)を示すものである。たとえば、記憶開始位置が「03」、長さが「02」となっていれば、レスポンスコード列の先頭から3バイト目から2バイト分のデータが記憶され、この記憶されたデータは、次の段階において、前述した組込コマンドによってコマンドコード列中に組込まれて利用されることになる。
【0029】
さて、いま、図3に示すようなコマンドコードの書式と、図4に示すようなレスポンスコードの書式と、を要求するリーダライタ装置30を用いて、何か具体的な作業を行う場合を考えてみる。たとえば、会員「山田」氏に、会員証としてICカード10を発行することにする。ここでは、単純なモデルとして、会員証となるICカード10のEEPROM15内に、「山田」なる姓と、所定の機密コードとを書き込むことにより、ICカード10を会員証として発行できるものとする。そして、セキュリティを確保する上で、この所定の機密コードは、正当な発行者が管理するICカード20のEEPROM25内に記録されており、このICカード20から何らかのデータを読み出すためには、所定の暗証を照合しなければならないものとしよう。
【0030】
このような会員証の発行処理を行うためには、たとえば、図5に示すような4つのコマンドC1〜C4を実行すればよい。まず、コマンドC1によって、ICカード10に「山田」なるデータを書き込む。次に、コマンドC2によって、ICカード20からの読出し準備を行う。これは具体的には、所定の暗証の照合を行う処理である。続くコマンドC3によって、ICカード20からの機密コードの読出しを行い、最後に、コマンドC4によって、コマンドC3で読出した機密コードをICカード10に書き込む。このような手順により、「山田」氏に対する会員証の発行処理が実行できる。
【0031】
この図5に示す処理を行うためには、図6に示すようなパターンファイルを用意し、これをホストコンピュータ40からリーダライタ装置30に与える必要がある。この図6のパターンファイルにおける左欄のC1〜C4は、図5に示す各コマンドC1〜C4との対応関係を示すために便宜的に付した符号である。また、R1〜R4なる符号が付された行は、それぞれC1〜C4なる符号が付された行のコマンドに対応するレスポンスを示す。この図6のパターンファイルは、図3に示したコマンドコードの書式および図4に示したレスポンスの書式に準じたコマンドおよびレスポンスを並べたものである。
【0032】
「コマンド部/レスポンス部+BCC」と記した欄のデータは、リーダライタ装置からICカードに実際に往信されるコマンド、あるいはICカードからリーダライタ装置に実際に返信されるレスポンスの部分である。なお、「山田」と記した部分には、実際には、これに対応する4バイトの漢字コード入ることになるが、図6では説明の便宜上、「山田」と記して示してある。この「コマンド部/レスポンス部+BCC」の部分は、ISOなどのICカードの規格に基いて書式が定められている部分であり、その全バイト数(コマンド長,レスポンス長)が、制御部▲3▼に示されている。また、この部分の第1バイト目は、送受信の対象を示している。すなわち、ここに示す例では、第1バイト目は、「01」,「10」,「67」,「76」の4とおりのうちのいずれかになっており、「01」はリーダライタ装置30からICカード10へ往信されるコマンド、「10」はICカード10からリーダライタ装置30へ返信されるレスポンス、「67」はリーダライタ装置30からICカード20へ往信されるコマンド、「76」はICカード20からリーダライタ装置30へ返信されるレスポンス、をそれぞれ意味している。第2バイト目以降は、個々のコマンドあるいはレスポンス固有のコードであり、最後の1バイトがBCCエラーチェックコードである。以下、各コマンドおよびレスポンスの内容を簡単に説明しておく。
【0033】
コマンドC1は、ICカード10に対する通常コマンドであり、用いていない制御部▲2▼には、任意のデータ「FF FF」が入っている。「コマンド部/レスポンス部+BCC」の第2〜3バイト目の「02 03」は、後続する「山田」なるデータの書き込みを指示する命令コードである。このコマンドC1に対応したレスポンスR1は、全チェックのレスポンスであり、用いていない制御部▲2▼には、やはり任意のデータ「FF FF」が入っている。この例では、「コマンド部/レスポンス部+BCC」に記述されている「10 02 00 00 03」なる5バイトのデータすべてが、ICカード10から返信されてきたレスポンスと比較照合される。すなわち、ICカード10内において、コマンドC1(「山田」の書き込み)が正常に実施されると、「10 02 00 00 03」なる所定のレスポンスが返信されることになっているので、レスポンスR1との比較照合の結果、一致を確認することにより、コマンドC1が正常に実行されたことを認識することができる。
【0034】
コマンドC2は、ICカード20に対する通常コマンドであり、用いていない制御部▲2▼には、任意のデータ「FF FF」が入っている。「コマンド部/レスポンス部+BCC」の第2〜3バイト目の「05 00」は、ICカード20からの読出し準備を指示する命令コードである。このコマンドC2に対応したレスポンスR2は、部分チェックのレスポンスであり、制御部▲2▼には、チェック開始位置「01」、長さ「01」なる情報が記述されている。したがって、この例では、「コマンド部/レスポンス部+BCC」に記述されている「76 FF 00 03」なる4バイトのデータのうち、第1バイト目から1バイト分だけが、ICカード20から返信されてきた実際のレスポンスと比較照合される。すなわち、先頭の1バイト分が「76」であるか否かだけが確認されることになる。
【0035】
コマンドC3は、ICカード20に対する通常コマンドであり、用いていない制御部▲2▼には、任意のデータ「FF FF」が入っている。「コマンド部/レスポンス部+BCC」の第2〜4バイト目の「01 02 03」は、ICカード20内の所定のアドレスからの読出しを指示する命令コードである。この命令を実行することにより、ICカード20内の機密コードが読み出され、リーダライタ装置20側へレスポンスとして返信されることになる。このコマンドC3に対応したレスポンスR3は、部分記憶のレスポンスとなっており、読み出された機密コードは、リーダライタ装置20側で一時的に記憶されることになる。すなわち、レスポンスR3の制御部▲2▼には、記憶開始位置「03」、長さ「02」なる情報が記述されている。この例では、「コマンド部/レスポンス部+BCC」には、「76 01 FF FF FF」なる5バイトのデータが記述されているが、第3バイト目と第4バイト目の「FF FF」および第5バイト目の「FF」は、いずれもダミーとしてのデータである。これは、ICカード20に対し
て、コマンドC3を与えると、「76 01 ?? ?? ??」という書式の5バイトのデータ(図に破線で囲った第3バイト目および第4バイト目の「????」には、読み出された機密コードが入り、第5バイト目の「??」には、この実際の機密コードを含めたBCCが入る)が返信されるように、ICカード20がISOなどの規格に基いて設計されており、レスポンスR3はこのICカード20からのレスポンスに対応したものになっているためである。結局、リーダライタ装置30は、コマンドC3に対する実際のレスポンスを受け取ると、その第3バイト目および第4バイト目のデータ(機密コード)を一時的に記憶することになる。
【0036】
コマンドC4は、ICカード10に対する組込コマンドであり、制御部▲2▼には、組込開始位置「02」、長さ「02」なる情報が記述されている。これは、「コマンド部/レスポンス部+BCC」の第2バイト目から2バイト分の部分に、先の部分記憶レスポンスで記憶したデータを組込んだ上、これを書き込みコマンドとしてICカード10に送信し、ICカード10内の所定アドレスに書き込みを行うことを指示する命令コードである。この例では、「コマンド部/レスポンス部+BCC」には、「01 FF FF FF」なる4バイトのデータが記述されているが、第2バイト目と第3バイト目の「FF FF」および第4バイト目の「FF」は、いずれもダミーとしてのデータであり、実際には、破線で囲った第2〜3バイト目には、直前のレスポンスで記憶されたデータが組込まれ、第4バイト目には、この組込みデータを含めたBCCが入ることになる。このコマンドC4に対応したレスポンスR4は、全チェックのレスポンスであり、用いていない制御部▲2▼には、任意のデータ「FF FF」が入っている。この例では、「コマンド部/レスポンス部+BCC」に記述されている「10 01 03 D1」なる4バイトのデータすべてが、ICカード10から返信されてきたレスポンスと比較照合される。すなわち、ICカード10内において、コマンドC4(機密データの書き込み)が正常に実施されると、「10 01 03 D1」なる所定のレスポンスが返信されることになっているので、レスポンスR4との比較照合の結果、一致を確認することにより、コマンドC4が正常に実行されたことを認識することができる。
【0037】
以上の説明から、図5に示すような仕事を、図3および図4に示すような書式を要求するリーダライタ装置30を用いて行う場合、図6に示すようなパターンファイルを用意する必要があることがわかる。ところで、図5に示す仕事は、「山田」という会員についての会員証を発行する処理であるが、実際には、数100人、数1000人という単位の会員に対して、同様の発行処理を行わねばならない。しかも、上述の例では、「山田」という会員の姓のみをICカードに書き込んでいるが、実際には、会員の氏名をはじめ、住所、電話番号、生年月日、といった種々の個人情報を書き込まねばならない。したがって、実際のパターンファイルはより複雑なものとなり、そのようなパターンファイルを数100人分、数1000人分という単位で作成する作業は、非常に労力を必要とするものになる。また、こうして労力を費やして作成したパターンファイルは、図3および図4に示す書式で記述されたものであるため、別な書式を要求するリーダライタ装置には適用することができない。
【0038】
本発明は、このような問題を解決するためのものであり、その要点は、図7に示すひな形パターンファイルと、図8に示すような個人情報ファイルと、を予め用意し、これらのファイルに基いて、個々のパターンファイルを効率的に生成できるようにしたものである。図8の個人情報ファイルは、複数の個人情報をレコード単位で収容したファイルであり、この例では、1レコードは、4バイトの「氏」フィールド、4バイトの「名」フィールド、50バイトの「住所」フィールドの3つのフィールドから構成されている。別言すれば、1個人の情報が1レコードとして用意されていることになる。
【0039】
一方、図7に示すひな形パターンファイルは、図6に示すパターンファイルと同様の処理内容をひな形としての書式で記述したものであり、左欄のC1,R1,…は、図6に示すパターンファイルの左欄に示したコマンドC1,レスポンスR1,…に対応したものである。図7に示すひな形パターンファイルの書式では、ICカードに実際に往信するデータ部分あるいはICカードから実際に返信されるデータ部分に相当する「コマンド部/レスポンス部+BCC」の部分が、第1区切子と第2区切子とで挟まれた形式をとる。この例では、第1区切子は、「&−S」または「%−N」のいずれかをとり、第2区切子は「&」または「%」のいずれかをとる。そして、「&−S」と「&」とで挟まれたデータはコマンド、「%−N」と「%」とで挟まれたデータはレスポンス、として取り扱われる。
【0040】
「コマンド部/レスポンス部+BCC」の部分については、図7のひな形パターンファイルと図6のパターンファイルとで、かなり共通しているが、ひな形パターンファイルは細かな点で特徴をもっている。以下、この特徴的な部分について説明を行う。
【0041】
まず、コマンドC1については、図6のパターンファイルにおける「山田」なるデータ部分が、図7のひな形パターンファイルでは、「DATA,1,4」なる記述となっている。ここで、「山田」なる記述が、固有のデータそのものであるのに対し、「DATA,1,4」なる記述は、図8に示す個人情報ファイル内の一部分を取り込む取込指示となっている。具体的には、「DATA,1,4」なる記述は、別に用意された個人情報ファイルの各レコードの先頭の1バイト目から4バイト分を、この位置に取り込むことを示す取込指示であり、図8に示す個人情報ファイルの1レコード目にこれを適用すれば、「DATA,1,4」なる記述の部分に、「山田」なる固有のデータが取り込まれることになる。
【0042】
また、この「DATA,1,4」なる記述に続く「BCC」なる記述は、「DATA,1,4」なる取込指示に基いて個人情報ファイル内のデータを取り込んだ後、この取り込んだデータを含めた全体のBCCエラーチェックコードを演算で求め、求めたエラーチェックコードをこの位置に付加することを指示するものである。結局、図7のひな形パターンファイルにおけるコマンドC1を、図8の個人情報ファイルの第1レコード目に適用した場合には、図6のパターンファイルのコマンドC1と全く同じ8バイトのコマンド部が得られることになる。それだけではなく、図8の個人情報ファイルの第2レコード目に適用した場合には、「山田」なるデータの代わりに「鈴木」なるデータを入れた別なコマンド部が得られることになり、更に、「鈴木」なるデータを取り込んだ場合のBCCエラーチェックコードが付加されることになる。
【0043】
このように、図6に示すパターンファイルが、リーダライタ装置30によってそのまま利用することができる固有のパターンファイルであるのに対し、図7に示すひな形パターンファイルは、このままではリーダライタ装置30で利用できる形態にはなっておらず、個人情報ファイルからのデータの取り込みを前提としたいわゆる「ひな形」としてのパターンファイルである。
【0044】
図7のひな形パターンファイルにおけるレスポンスR2には、「XX XX XX」なる記述が見られるが、これは「XX」と記述された位置の1バイトについては、チェックを行わないことを示すものである。また、ひな形パターンファイルにおけるレスポンスR3およびコマンドC4には、「YY YY」なる記述が見られる。これは、レスポンス中における「YY」なる1バイトは、この位置の1バイトのデータを部分記憶することを示すものであり、コマンド中における「YY」なる1バイトは、部分記憶していたデータをこのバイト位置に組み込むことを示すものである。この部分記憶および組込みの処理は、図6に破線で囲って示した2バイトのデータについての部分記憶および組込みの処理に相当するものである。
【0045】
結局、図7のひな形パターンファイルの書式と、図6のパターンファイルの書式と、の対応関係を記述した所定の変換テーブルを用意しておけば、図7のひな形パターンファイルと図8の個人情報ファイルとを合成して、図6に示すようなパターンファイルを得ることができる。たとえば、ひな形パターンファイルにおいて、区切子「&−S」と「&」とで挟まれたデータについては、図3に示す通常コマンド1,2あるいは組込コマンド1,2のいずれかに変換することになるが、次のような変換テーブルを用意しておけば、一義的な変換が可能である。
(1) データの第1バイト目が「01」で、かつ「YY」を含まない
→ 通常コマンド1
(2) データの第1バイト目が「01」で、かつ「YY」を含む
→ 組込コマンド1
(3) データの第1バイト目が「67」で、かつ「YY」を含まない
→ 通常コマンド2
(4) データの第1バイト目が「67」で、かつ「YY」を含む
→ 組込コマンド2
ここで、制御部▲1▼の値は、図3の書式に基いて各コマンドに対応したものを記述すればよく、制御部▲2▼の値は、通常コマンドなら、たとえば「FF」などの任意の値を記述し、組込コマンドなら、「YY」の位置に基いて所定の値を記述すればよい。また、制御部▲3▼は、コマンド部+BCCの全長の値を記述すればよい。更に、「DATA,…」なる取込指示が含まれていた場合には、前述したように、その部分に個人情報ファイルから所定のデータを取り込めばよい。
【0046】
図9は、本発明に係るICカードアクセス用パターンファイルの作成方法を実施するための構成を示すブロック図である。たとえば、図5に示すような仕事を、1000人分の会員について行う必要があれば、ひな形パターンファイル41として図7に示すようなものを予め用意し、個人情報ファイル42として図8に示すようなものを予め用意し、変換テーブル43として上述のような一義的な変換を行うためのテーブルを予め用意しておけば、ホストコンピュータ40は、これらの各ファイルおよびテーブルに基いて、図6に示すようなパターンファイルを1000人分自動的に作成することが可能になる。これら1000のパターンファイルは、リーダライタ装置30が直接取り扱うことができる書式で記述されているため、これらのパターンファイルを1つずつリーダライタ装置30に与えることにより、1000人分の会員証を順次発行する処理を行うことができる。
【0047】
なお、個人情報の中でも所定の規則に基づいて自動発生できるようなデータは、あえて個人情報ファイル42内に用意しておく必要はない。たとえば、1000人分の会員証を発行する場合に、上述の例で述べた会員の氏名と住所に加えて、会員番号をICカードに書き込むことを考えよう。この会員番号がNo.1〜No.1000のような連続番号として付与される場合、あるいは、何らかの規則的な番号として付与される場合は、ホストコンピュータ40内に、この所定の規則に基づいて会員番号を発生させるアルゴリズムを用意しておけば、個人情報ファイル42内に会員番号のデータを用意しておく必要はなくなる。ひな形パターンファイル41のコマンド部には、たとえば、「SERIAL」といった連続番号の取込指示を記述しておき、発生した個々の会員番号をこの取込指示に基づいて取り込むようにすればよい。もちろん、ホストコンピュータ40内では、このようにして発生した会員番号を取り込む処理が行われた後、各会員番号を含むデータについての正しいBCCエラーチェックコードが演算生成され、付加されることになる。
【0048】
また、会員個人の個人情報だけに限らず、会員証の発行年月日などの時間的な情報、発行者サイドで各会員証を管理するために用いる管理番号、発行作業を行った作業者を特定するための発行作業者コード、など、所定の規則に基づく演算によって自動的に生成できるデータであればどのようなデータであっても、上述の会員番号の例と同様に、ホストコンピュータ40内で生成して、これをひな形パターンファイルに取り込む処理が可能である。
【0049】
このように、本発明に係るパターンファイルの作成方法によれば、次の2つのメリットが得られる。第1のメリットは、ひな形パターンファイル内に取込指示を記述し、この取込指示によって、別個に用意した個人情報ファイル内のデータまたは所定の規則に基づいて生成した連続番号等の所定のデータを部分的に取り込んで個々のパターンファイルを作成することができるため、1000人分の会員証を発行する場合であっても、単一のひな形パターンファイルだけを記述する作業ですむという点である。そして、第2のメリットは、ひな形パターンファイルの記述は、特有の簡便な書式で行うことができ、個々のリーダライタ装置が要求する書式を考慮せずに行うことができるという点である。図7のひな形パターンファイルを図6のパターンファイルと比較すればわかるとおり、図6における制御部の複雑なデータ列は、図7では簡便な区切子や「XX」,「YY」といった記述で表現されており、ファイルを記述する労力は著しく低減できる。
【0050】
以上、本発明を図示する実施例に基いて説明したが、本発明はこの実施例に限定されるものではなく、この他にも種々の態様で実施可能である。特に、図3および図4に示した具体的な書式や、図7に示したひな形パターンファイルの書式は、説明の便宜上、非常に単純なモデルとしての書式を示したものであり、実際には、より複雑な書式が定義されるのが一般的である。もちろん、本発明の実施は、特定の書式に限定されるものではなく、どのような書式に対しても本発明は適用しうるものである。
【0051】
【発明の効果】
以上のとおり本発明に係るパターンファイルの作成方法によれば、ひな形パターンファイルと個人情報ファイルとに基いて、所定の書式のパターンファイルを作成するようにしたため、各ICカードごとに異なる個人情報を記録するために用いるパターンファイルを、効率的に作成することができるようになる。また、ひな形パターンファイルに、自動生成したデータを取り込んで、所定の書式のパターンファイルを作成するようにしたため、個々のパターンファイルを効率的に作成することができるようになる。
【図面の簡単な説明】
【図1】ICカードに対する一般的なアクセス処理の形態を示すブロック図である。
【図2】図1に示すアクセス処理で用いられるパターンファイルFの基本構成を示す図である。
【図3】特定のリーダライタ装置が要求するコマンドコードの書式の一例を示す図である。
【図4】特定のリーダライタ装置が要求するレスポンスコードの書式の一例を示す図である。
【図5】ICカードにより会員証を発行する仕事を行うためのコマンド内容の一例を示す図である。
【図6】図3および図4に示す書式により、図5に示す仕事を行うためのパターンファイルを記述した一例を示す図である。
【図7】本発明に係る方法に利用されるひな形パターンファイルの一例を示す図である。
【図8】本発明に係る方法に利用される個人情報ファイルの一例を示す図である。
【図9】本発明に係る方法を実施するための装置構成例を示すブロック図である。
【符号の説明】
10…ICカード
11…I/Oインターフェイス
12…CPU
13…ROM
14…RAM
15…EEPROM
20…ICカード
21…I/Oインターフェイス
22…CPU
23…ROM
24…RAM
25…EEPROM
30…リーダライタ装置
31,32…信号伝送路
40…ホストコンピュータ
41…ひな形パターンファイル
42…個人情報ファイル
43…変換テーブル
[0001]
[Industrial applications]
The present invention relates to a method of creating a pattern file for accessing an IC card, and more particularly to a method of creating a pattern file used when performing a process of writing individual personal information to each IC card.
[0002]
[Prior art]
As a new information storage medium replacing the magnetic card, an IC card has attracted attention. In particular, an IC card with a built-in CPU can secure a high degree of security for information stored therein, and is therefore expected to be widely used in fields handling important information.
[0003]
At present, IC cards that are widely used are accessed by a reader / writer device. In particular, in an IC card with a built-in CPU, the reader / writer device and the CPU in the IC card are connected via a signal transmission path via an interface circuit, and information exchange between the two can be performed via the signal transmission path. Done. In this case, information is transmitted from the reader / writer device to the IC card in the form of a command, and conversely, information is transmitted from the IC card to the reader / writer device in the form of a response to the command. The CPU in the IC card executes various processes such as resetting, writing and reading to and from the built-in memory based on a command given from the reader / writer device, and sends the execution result to the reader / writer device in the form of a response. Will return. For example, when a reset command is given from the reader / writer device side, the CPU on the IC card side executes a reset process, and then returns a predetermined code indicating the execution of the reset process to the reader / writer device side as a response. . Also, when a command to write the data to a predetermined address together with the predetermined data is given as a command from the reader / writer device, the CPU of the IC card executes a process of writing the data given as the command to the internal memory, Information indicating whether the data has been correctly written or whether any error has occurred is returned to the reader / writer device as a response.
[0004]
As described above, information exchange between the reader / writer device and the IC card includes a command transmission / reception process from the reader / writer device to the IC card side, a response return process from the IC card side to the reader / writer device side, Are performed alternately and repeatedly. The reader / writer device can determine whether or not the previously given command has been correctly executed based on the response returned from the IC card by the return process. In order to smoothly perform such access processing to the IC card, a pattern file is usually prepared on the reader / writer device side. Currently, the commonly used pattern files are a command and a response that is expected to be returned in response to this command. Expected value of And are alternately arranged. That is, command, response Expected value of , Command, response Expected value of , Command, ..., command and response Expected value of Is prepared in advance, and the reader / writer device transmits a command in accordance with the order of the pattern file, and responds to the response in response to the command in the pattern file. Response Expected value of Will be performed.
[0005]
[Problems to be solved by the invention]
However, in the above-described access method using a pattern file, when accessing a large number of IC cards, a great deal of labor is required for the operation of preparing the pattern file. For example, when processing of issuing one IC card to each individual by writing personal information such as a member number, name, address, telephone number, and date of birth of the individual in a memory in each IC card, It is necessary to prepare a pattern file for each individual. Therefore, for example, when performing a process of issuing IC cards for 1,000 people, it is necessary to prepare such a pattern file for 1,000 people. Further, the format of the pattern file that can be used may differ depending on the reader / writer device used, and the operation of preparing a pattern file having such a different format becomes extremely inefficient. For example, when the reader / writer device A performs issuance processing for the first half of 500 people and another reader / writer device B performs issuance processing for the latter half of 500 people, the pattern written in the form A is used for the first 500 people. A file must be prepared, and a pattern file described in Format B must be prepared for the latter 500 people.
[0006]
Therefore, an object of the present invention is to provide a method of creating a pattern file that can efficiently create a pattern file used to record different information for each IC card.
[0007]
[Means for Solving the Problems]
(1) According to a first aspect of the present invention, a signal transmission path is formed between an IC card having a built-in CPU and a reader / writer device for accessing the IC card. , Reader / writer device Host computer controlling From the IC card to the IC card, and from the IC card to the reader / writer device Through the host computer To send and receive a response in response to the command. Expected response value expected to be returned in response to the command In the method of creating a pattern file used for access when performing access to an IC card by executing the
Prepare a personal information file containing multiple pieces of personal information in record units,
A command including a capture instruction to partially capture the data in the personal information file and its response Expected value of Is prepared in a template pattern file in the first format,
Preparing a conversion table for converting the first format into a second format that can be interpreted by the reader / writer device;
The predetermined data in the personal information file is fetched into a predetermined portion of the template pattern file based on the fetch instruction, and the first format is converted into the second format based on the conversion table. Create a pattern file for each individual described in the format of 2. Let the computer execute the process It is like that.
[0008]
(2) According to a second aspect of the present invention, a signal transmission path is formed between an IC card having a built-in CPU and a reader / writer device for accessing the IC card. , Reader / writer device Host computer controlling From the IC card to the IC card, and from the IC card to the reader / writer device Through the host computer To send and receive a response in response to the command. Expected response value expected to be returned in response to the command In the method of creating a pattern file used for access when performing access to an IC card by executing the
By a calculation based on a predetermined rule, a data generating means for generating predetermined data is prepared,
A command including a capture instruction to capture predetermined data generated by the data generation means, and a response thereto Expected value of Is prepared in a template pattern file in the first format,
Preparing a conversion table for converting the first format into a second format that can be interpreted by the reader / writer device;
By taking in predetermined data generated by the data generating means based on a take-in instruction into a predetermined part of the template pattern file, and converting the first format into the second format based on the conversion table, Create a pattern file for each individual described in the second format Let the computer execute the process It is like that.
[0009]
(3) A third aspect of the present invention provides the pattern file creating method according to the first or second aspect described above,
Command or response Expected value of After receiving predetermined data based on the capture instruction, a command or response including the captured data Expected value of Calculates the error check code for the command and calculates the error check code as a command or response. Expected value of Is added.
[0010]
[Operation]
When processing such that one IC card is issued to one individual by writing personal information such as a member number, name, address, telephone number, date of birth, etc. of the individual on each IC card, the individual IC The contents of the pattern file used for the card issuing process are different from each other. However, the different part is only a part of personal information such as an individual's member number, name, address, telephone number, date of birth, and the like, and the rest is almost common. In the pattern file creating method according to the present invention, a template pattern file is prepared for the common part. In this template pattern file, a capture instruction is described in place of actual data for individual personal information that is not common, and a portion in which the capture instruction is described will be described later in the personal information file. The predetermined data in is read. That is, the template pattern file is a pattern file in which a blank portion is provided in a place where individual personal information is to be captured. If the personal information of the individual A is captured in the blank portion, a pattern file for the individual A can be created. By taking in the personal information of the individual B, a pattern file for the individual B can be created. Therefore, a large number of different pattern files for individuals can be efficiently created.
[0011]
Further, the template pattern file according to the present invention can be described in a first format that does not depend on each reader / writer device. The pattern file in the first format can be individually written using a conversion table. Is converted into a pattern file of the second format suitable for the reader / writer device of the first embodiment. Therefore, at the stage of creating the template pattern file, it is not necessary to pay attention to each reader / writer device, and efficient work can be performed.
[0012]
Further, data that can be automatically generated by a calculation based on a predetermined rule, such as a member number assigned to each individual as a serial number, is not provided as a personal information file, but is calculated based on the predetermined rule. If a means for automatically generating data is prepared, individual pattern files for recording different information can be efficiently created by taking in data generated by this means.
[0013]
【Example】
Hereinafter, the present invention will be described with reference to the illustrated embodiments. First, a conventional general access procedure for an IC card having a built-in CPU will be described with reference to the block diagram shown in FIG. Here, a case will be described as an example where two IC cards 10 and 20 are simultaneously connected to the reader / writer device 30 and both IC cards 10 and 20 are appropriately accessed. For example, in the case where one IC card is issued as a membership card to each of a large number of members, the IC card 10 to be issued and the IC card 20 which functions as a key card in the issuing operation are read by a reader. If a configuration is adopted in which connection to the writer device 30 and issuance work are performed, security can be improved. In other words, unless the IC card 20 is used as a key card, the issuing operation cannot be performed. Therefore, if the IC card 20 is properly managed, the membership card (IC card 10) is issued in an unauthorized manner. Can be prevented.
[0014]
As shown in FIG. 1, a general IC card 10 includes an I / O interface 11, a CPU 12, a ROM 13, a RAM 14, and an EEPROM 15. The I / O interface 11 is a device having a function of exchanging information with the outside via a signal transmission path 31 formed between the I / O interface 11 and the reader / writer device 30. The signal transmission path 31 may be formed as an electrical wiring path, or may be formed as an electromagnetically coupled space path. Information provided from the reader / writer device 30 to the I / O interface 11 via the signal transmission path 31 is transmitted to the CPU 12, and conversely, information to be transmitted from the CPU 12 to the outside is transmitted from the I / O interface 11 by signal transmission. It is provided to the reader / writer device 30 via the path 31. A host computer 40 is connected to the reader / writer device 30, and the reader / writer device 30 performs access processing to the IC card 10 based on the control of the host computer 40. The IC card 20 also includes an I / O interface 21, a CPU 22, a ROM 23, a RAM 24, and an EEPROM 25, just like the IC card 10, and is provided to the reader / writer device 30 via a signal transmission path 32. It is connected.
[0015]
In the IC card 10, three types of memories, a ROM 13, a RAM 14, and an EEPROM 15, are prepared. The ROM 13 is a memory in which a basic program for operating the CPU 12 is stored. The CPU 12 executes various arithmetic processes based on the program in the ROM 13. The RAM 14 is a memory used as a work space in the arithmetic processing. The EEPROM 15 is a memory mainly used for storing user data, which is an original function of the IC card 10, and user data supplied from the reader / writer device 30 is written into the EEPROM 15 by the CPU 12. Further, when a predetermined read command is given from the reader / writer device 30, the CPU 12 reads the user data in the EEPROM 15 and returns this to the reader / writer device 30. Three types of memories, namely, a ROM 23, a RAM 24, and an EEPROM 25, in the IC card 20 are also used for the same purpose.
[0016]
Information exchange between the IC cards 10 and 20 and the reader / writer device 30 is performed in the form of a command C and a response R. That is, information is transmitted from the reader / writer device 30 to the IC cards 10 and 20 in the form of a command C, and conversely, information is transmitted from the IC cards 10 and 20 to the reader / writer device 30 in the form of a response R to the command C. Information is transmitted. That is, the information exchange between the two includes the process of sending and receiving the command C from the reader / writer device 30 to the IC cards 10 and 20 and the process of returning the response R from the IC cards 10 and 20 to the reader / writer device 30. , Are executed alternately and repeatedly.
[0017]
In order to smoothly perform such access processing to the IC card 10, usually, a pattern file F as shown in FIG. 2 is prepared. The pattern file F includes a command C and a response R expected to be returned in response to the command C. (It is not the original “response” returned from the IC card, but the “expected response value”, but in the following description, it is simply called “response” for convenience.) And are alternately arranged. In the example of FIG. 2, commands C and responses R are arranged alternately, such as command C1, response R1, command C2, response R2, command C3, response R3, and so on. Here, the command C1 is the first command to be given to the IC card side, and the response R1 is a response expected to be returned from the IC card side when this command C1 is given as outgoing communication. It is. Similarly, the command C2 is a command to be given secondly to the IC card side, and the response R2 is a response expected to be returned from the IC card side when this command C2 is given as outgoing communication. It is.
[0018]
If a pattern file F as shown in FIG. 2 is prepared in the host computer 40 and given to the reader / writer device 30 as needed, the reader / writer device 30 Smooth access to the IC card can be performed. That is, first, the reader / writer device 30 performs a sending / receiving process of sending the command C1 to the IC card side. Whether the command C1 should be sent to the IC card 10 or 20 depends on the instruction described in the pattern file F. For example, if the command C1 is sent to the IC card 10, the CPU 12 in the IC card 10 executes the command C1, and then performs a return process of returning a predetermined response to the reader / writer device 30. Then, the reader / writer device 30 compares and compares the actually returned response with the response R1 in the pattern file F, and if there is no problem, performs a transmission process of sending the next command C2 to the IC card 10. After executing the command C2, the CPU 12 performs a return process of returning a predetermined response to the reader / writer device 30. Therefore, the reader / writer device 30 compares and compares the actually returned response with the response R2 in the pattern file F, and if there is no problem, performs a forwarding process of sending the next command C3 to the IC card 10. As described above, the reader / writer device 30 can smoothly perform the sending and receiving process and the reply process by using the commands / responses arranged in the pattern file F in order. If there is any problem as a result of the response collation, measures such as sending the same command again will be taken.
[0019]
As described above, the access method using the pattern file F can reduce the load on the reader / writer device 30 and provide efficient access. As described above, when processing is performed, the number of pattern files to be prepared increases, and the work of preparing these pattern files requires a great deal of labor. For example, consider an example in which an IC card is issued as a membership card. It is necessary to record personal information such as the name, address, telephone number, and date of birth of the member on this membership card. In this case, in order to issue the IC card 10 as a membership card, it is necessary to write such personal information in the EEPROM 15, and it is necessary to prepare a pattern file for the number of members.
[0020]
Another problem at the stage of preparing this pattern file is that the format of the pattern file differs depending on the reader / writer used. In general, IC cards are standardized to some extent according to ISO standards and the like. Commands C given to the IC card and responses R returned from the IC card have a predetermined format. I have. However, various types of reader / writer devices are provided by various manufacturers, and even when accessing the exact same IC card, the format of the pattern file required when using the reader / writer device A is required. In general, the format of the pattern file required when using the reader / writer device B is different. Therefore, when preparing a pattern file, it is necessary to consider which reader / writer device is used for accessing the IC card, and it must be described in a predetermined format.
[0021]
Here, the procedure for creating the pattern file will be described using a more specific example. For example, consider a case where a reader / writer device to use requests a command code format as shown in FIG. 3 and requests a response code format as shown in FIG. The command code shown in FIG. 3 is composed of three parts: control units (1), (2), and (3), a command unit, and a BCC. Here, the part actually transmitted as the command C to the IC card side is a part composed of a command part and a BCC (error check code). The control units (1), (2), and (3) are units for giving information for internal processing of the reader / writer device, and are not transmitted to the IC card side. In the example shown here, the command codes are divided into eight types, and the respective formats are shown in a table. That is, eight types of normal commands 1 and 2, reset commands 1 and 2, power-on reset commands 1 and 2, and built-in commands 1 and 2 are prepared. Here, the numbers 1 and 2 at the end of each command are numbers specifying the IC card to be accessed, the number 1 indicates that the IC card 10 is to be accessed, and the number 2 indicates that the IC card 20 is to be accessed. Indicates that it is a target.
[0022]
The normal command is a general command for writing or reading data to or from an IC card, and includes a predetermined command code string (the format is defined by the standard of the IC card) together with the BCC code. To send to. “00” or “01” of the control unit (1) is a part for specifying whether it is the normal command 1 (for the IC card 10) or the normal command 2 (for the IC card 20). Further, the control unit (2) is not used (indicated by “φ” in the table, and these 2 bytes are ignored), and the control unit (3) is controlled by the following command unit and BCC. It indicates the total number of bytes (command length).
[0023]
The reset command and the power-on reset command are commands for giving a reset signal to the IC card. The former is a command for resetting the CPU when the IC card has already been started, and the latter is a command for powering the IC card. And a command for supplying a clock and performing a start-up operation and resetting the CPU. The control unit (1) gives information for specifying a reset command or a power-on reset command, and the control unit (2) provides the IC card 10 (0000) or the IC card 20 (FFFF) as a target IC card. ). Note that these commands do not send any code through signal transmission paths 31 and 32 for normal data transmission, but use a dedicated reset line or a dedicated power line or clock line to output a reset signal or power supply. There is no data in the command part because it is for supply and clock supply. Therefore, the control unit (3) indicating the command length is "00".
[0024]
The embedded command is a special form of the above-described normal command, and incorporates, into the command code string, data of a predetermined portion in the response code string obtained as the previous response, and transmits this to the IC card. It is for. The difference in format from the normal command is that the control unit (1) is "10" (for the IC card 10) or "11" (for the IC card 20) indicating that it is an embedded command. A point and a point at which an assembling start position and a length are designated in the control unit (2). This embedded command will be described later with reference to an actual example.
[0025]
On the other hand, the response code shown in FIG. 4 is composed of three parts: a control unit (1), (2), (3), a response unit, and a BCC. Here, the part expected to be actually returned as a response R from the IC card side is a part composed of a response part and a BCC (error check code). That is, basically, the data actually returned as the response R from the IC card side is compared with the “response portion + BCC” portion shown in FIG. The control units (1), (2), and (3) are units for giving information for internal processing of the reader / writer device. In the example shown here, the response codes are divided into three types, and each format is shown in a table.
[0026]
The full check is to compare and match the response R returned from the IC card over all digits. “08” of the control unit (1) is a part indicating that this response code is a response code of “all check”. The control unit {circle around (2)} is not used (indicated by “φ” in the table, and these two bytes are ignored), and the control unit {circle around (3)} is a total byte of the response unit and the BCC following the following. It indicates the number (response length).
[0027]
The partial check is for comparing and collating only a part of the digits of the response R returned from the IC card. “0A” of the control unit (1) is a part indicating that this response code is a response code of “partial check”. The control unit (2) indicates the check start position and length, and the control unit (3) indicates the total number of bytes (response length) of the following response unit and BCC. For example, if the check start position is "03" and the length is "02", only the two bytes from the third byte from the beginning of the response code string are to be compared and compared, and the other parts are ignored. Will be.
[0028]
The partial storage is a process for storing a part of the digits of the response R returned from the IC card. “1C” of the control unit (1) is a part indicating that this response code is a response code of “partial storage”. The control unit (2) indicates the storage start position and length, and the control unit (3) indicates the total number of bytes (response length) of the following response unit and BCC. For example, if the storage start position is "03" and the length is "02", two bytes of data from the third byte from the beginning of the response code string are stored, and the stored data is At this stage, the embedded command is used by being incorporated in the command code string by the aforementioned embedded command.
[0029]
Now, consider a case where some specific work is performed using the reader / writer device 30 that requests a command code format as shown in FIG. 3 and a response code format as shown in FIG. Try. For example, an IC card 10 is issued as a membership card to the member “Yamada”. Here, as a simple model, it is assumed that the IC card 10 can be issued as a membership card by writing a surname “Yamada” and a predetermined confidential code in the EEPROM 15 of the IC card 10 serving as a membership card. In order to ensure security, the predetermined confidential code is recorded in the EEPROM 25 of the IC card 20 managed by a valid issuer. Let's say you have to verify your password.
[0030]
In order to perform such a membership card issuing process, for example, four commands C1 to C4 as shown in FIG. 5 may be executed. First, data “Yamada” is written to the IC card 10 by the command C1. Next, readout from the IC card 20 is prepared by the command C2. More specifically, this is a process for collating a predetermined password. The confidential code read from the IC card 20 is read by the following command C3, and finally, the confidential code read by the command C3 is written to the IC card 10 by the command C4. According to such a procedure, a process for issuing a membership card to Mr. “Yamada” can be executed.
[0031]
In order to perform the processing shown in FIG. 5, it is necessary to prepare a pattern file as shown in FIG. 6, and provide the pattern file from the host computer 40 to the reader / writer device 30. C1 to C4 in the left column in the pattern file of FIG. 6 are reference numerals assigned for convenience to indicate the correspondence with the commands C1 to C4 shown in FIG. Further, the lines to which the reference numerals R1 to R4 are attached indicate the responses corresponding to the commands in the lines to which the reference numerals C1 to C4 are attached. The pattern file of FIG. 6 is a list of commands and responses according to the command code format shown in FIG. 3 and the response format shown in FIG.
[0032]
The data in the column of “command part / response part + BCC” is a part of a command actually transmitted from the reader / writer device to the IC card or a part of a response actually returned from the IC card to the reader / writer device. In addition, the portion described as "Yamada" actually contains a 4-byte kanji code corresponding thereto, but is shown as "Yamada" in FIG. 6 for convenience of explanation. The “command part / response part + BCC” part is a part whose format is determined based on the standard of an IC card such as ISO, and the total number of bytes (command length and response length) is determined by the control unit {circle around (3)}. Shown in ▼. Also, the first byte of this part indicates an object to be transmitted / received. That is, in the example shown here, the first byte is one of four types of “01”, “10”, “67”, and “76”, and “01” is the reader / writer device 30. , A command transmitted from the IC card 10 to the reader / writer device 30, “67” is a command transmitted from the reader / writer device 30 to the IC card 20, and “76” is a command transmitted from the IC card 10 to the IC card 20. This means a response returned from the IC card 20 to the reader / writer device 30, respectively. The second and subsequent bytes are codes unique to each command or response, and the last byte is a BCC error check code. Hereinafter, the contents of each command and response will be briefly described.
[0033]
The command C1 is a normal command for the IC card 10, and the unused control unit (2) contains arbitrary data "FF FF". “02 03” in the second and third bytes of “command part / response part + BCC” is an instruction code instructing writing of the following data “Yamada”. The response R1 corresponding to the command C1 is a response of all checks, and the unused control section (2) also contains arbitrary data "FF FF". In this example, all 5-byte data “10 02 00 00 03” described in “command part / response part + BCC” are compared with the response returned from the IC card 10. That is, when the command C1 (writing of “Yamada”) is normally executed in the IC card 10, a predetermined response of “10 02 00 00 03” is to be returned. As a result of the comparison and collation, it is possible to recognize that the command C1 has been executed normally by confirming the match.
[0034]
The command C2 is a normal command for the IC card 20, and the unused control section {circle around (2)} contains arbitrary data “FF FF”. “0500” in the second and third bytes of “command part / response part + BCC” is an instruction code for instructing preparation for reading from the IC card 20. The response R2 corresponding to the command C2 is a response of the partial check, and the control unit (2) describes information such as a check start position "01" and a length "01". Therefore, in this example, of the 4-byte data “76 FF 00 03” described in the “command part / response part + BCC”, only one byte from the first byte is returned from the IC card 20. Is compared with the actual response. That is, it is confirmed only whether or not the first byte is “76”.
[0035]
The command C3 is a normal command for the IC card 20, and the unused control section {circle around (2)} contains arbitrary data “FF FF”. “01 02 03” in the second to fourth bytes of “command part / response part + BCC” is an instruction code for instructing reading from a predetermined address in the IC card 20. By executing this command, the secret code in the IC card 20 is read and returned as a response to the reader / writer device 20 side. The response R3 corresponding to the command C3 is a partial storage response, and the read secret code is temporarily stored in the reader / writer device 20. That is, the control unit (2) of the response R3 describes information such as a storage start position “03” and a length “02”. In this example, in the “command part / response part + BCC”, 5-byte data “76 01 FF FF FF” is described, but “FF FF” in the third byte and the fourth byte and “FF FF” in the fourth byte are described. The “FF” in the fifth byte is dummy data. This is for the IC card 20
When the command C3 is given, five bytes of data in the format of “76 01 ?? ?? ??” (in the third and fourth bytes enclosed by broken lines in the figure, “????” The IC card 20 conforms to a standard such as ISO so that the read confidential code is entered and the fifth byte "??" contains the BCC including the actual confidential code. This is because the response R3 corresponds to the response from the IC card 20. Eventually, upon receiving the actual response to the command C3, the reader / writer device 30 temporarily stores the data (confidential code) in the third and fourth bytes.
[0036]
The command C4 is a built-in command for the IC card 10, and the control unit (2) describes information such as a built-in start position "02" and a length "02". This is achieved by incorporating the data stored in the partial storage response into the two bytes from the second byte of the “command part / response part + BCC”, and transmitting this to the IC card 10 as a write command. , An instruction code for instructing writing to a predetermined address in the IC card 10. In this example, four bytes of data “01 FF FF FF” are described in “command part / response part + BCC”, but “FF FF” of the second byte and the third byte and fourth byte data are described. The “FF” in the byte is dummy data, and in fact, the data stored in the immediately preceding response is incorporated in the second and third bytes surrounded by a broken line, and the fourth byte is Contains a BCC including the embedded data. The response R4 corresponding to the command C4 is a response of all checks, and the unused control unit (2) contains arbitrary data "FF FF". In this example, all four-byte data “1001 03 D1” described in “command part / response part + BCC” are compared with the response returned from the IC card 10. That is, when the command C4 (write of confidential data) is normally executed in the IC card 10, a predetermined response “1001 03 D1” is to be returned. As a result of the comparison, by confirming the match, it can be recognized that the command C4 has been executed normally.
[0037]
From the above description, when the job shown in FIG. 5 is performed using the reader / writer device 30 that requests the format shown in FIGS. 3 and 4, it is necessary to prepare a pattern file as shown in FIG. You can see that there is. By the way, the job shown in FIG. 5 is a process for issuing a membership card for a member “Yamada”. Have to do it. Moreover, in the above example, only the last name of the member "Yamada" is written on the IC card. I have to. Therefore, the actual pattern file becomes more complicated, and the work of creating such a pattern file in units of several hundreds or several thousands requires a great deal of labor. Further, since the pattern file created by the effort is described in the format shown in FIGS. 3 and 4, it cannot be applied to a reader / writer device that requires another format.
[0038]
The present invention is to solve such a problem. The point is that a template pattern file shown in FIG. 7 and a personal information file as shown in FIG. 8 are prepared in advance, and these files are prepared. Based on the above, individual pattern files can be efficiently generated. The personal information file shown in FIG. 8 is a file containing a plurality of personal information in record units. In this example, one record has a 4-byte “name” field, a 4-byte “name” field, and a 50-byte “name” field. It consists of three fields, an "address" field. In other words, information of one individual is prepared as one record.
[0039]
On the other hand, the template pattern file shown in FIG. 7 describes the same processing contents as the pattern file shown in FIG. 6 in a template format, and C1, R1,. This corresponds to the command C1, the response R1,... Shown in the left column of the pattern file. In the format of the template pattern file shown in FIG. 7, the "command part / response part + BCC" part corresponding to the data part actually transmitted to the IC card or the data part actually returned from the IC card is included in the first section. Takes a form sandwiched between a facet and a second facet. In this example, the first delimiter takes either "&-S" or "% -N" and the second delimiter takes either "&" or "%". Data sandwiched between "&-S" and "&" is handled as a command, and data sandwiched between "% -N" and "%" is handled as a response.
[0040]
The “command part / response part + BCC” portion is quite common between the template pattern file of FIG. 7 and the pattern file of FIG. 6, but the template pattern file has features in small points. Hereinafter, this characteristic portion will be described.
[0041]
First, for the command C1, the data portion "Yamada" in the pattern file of FIG. 6 is described as "DATA, 1, 4" in the template pattern file of FIG. Here, the description “Yamada” is the unique data itself, whereas the description “DATA, 1, 4” is a capture instruction to capture a part of the personal information file shown in FIG. . Specifically, the description “DATA, 1, 4” is a capture instruction indicating that four bytes from the first byte of each record of the separately prepared personal information file are to be captured at this position. If this is applied to the first record of the personal information file shown in FIG. 8, the unique data "Yamada" will be taken into the description "DATA, 1, 4".
[0042]
The description “BCC” following the description “DATA, 1, 4” is obtained by capturing the data in the personal information file based on the capture instruction “DATA, 1, 4”, and then reading the captured data. The entire BCC error check code including is calculated, and the obtained error check code is added to this position. Eventually, when the command C1 in the template pattern file of FIG. 7 is applied to the first record of the personal information file of FIG. 8, an 8-byte command portion exactly the same as the command C1 of the pattern file of FIG. 6 is obtained. Will be done. In addition, when applied to the second record of the personal information file in FIG. 8, another command portion containing data "Suzuki" instead of data "Yamada" is obtained. , "Suzuki" is added, a BCC error check code is added.
[0043]
As described above, the pattern file shown in FIG. 6 is a unique pattern file that can be used as it is by the reader / writer device 30, whereas the template pattern file shown in FIG. The pattern file is not in a usable form, and is a so-called "model" on the premise of taking in data from a personal information file.
[0044]
The description “XX XX XX” is found in the response R2 in the template pattern file of FIG. 7, which indicates that the check is not performed for one byte at the position described as “XX”. is there. In addition, the description “YY YY” is seen in the response R3 and the command C4 in the template pattern file. This means that one byte “YY” in the response partially stores the one-byte data at this position, and one byte “YY” in the command stores the partially stored data. This indicates that it is incorporated in this byte position. The processing of partial storage and embedding corresponds to the processing of partial storage and embedding of 2-byte data indicated by a broken line in FIG.
[0045]
After all, if a predetermined conversion table that describes the correspondence between the format of the template pattern file in FIG. 7 and the format of the pattern file in FIG. 6 is prepared, the template pattern file in FIG. By combining the personal information file and the personal information file, a pattern file as shown in FIG. 6 can be obtained. For example, in the template pattern file, data sandwiched between delimiters "&-S" and "&" is converted into one of the normal commands 1 and 2 or the embedded commands 1 and 2 shown in FIG. In other words, if the following conversion table is prepared, a unique conversion is possible.
(1) The first byte of data is “01” and does not include “YY”
→ Normal command 1
(2) The first byte of data is “01” and includes “YY”
→ Embedded command 1
(3) The first byte of data is “67” and does not include “YY”
Normal command 2
(4) The first byte of data is “67” and includes “YY”
→ Embedded command 2
Here, the value of the control unit (1) may be a value corresponding to each command based on the format of FIG. 3, and the value of the control unit (2) may be, for example, "FF" for a normal command. An arbitrary value may be described, and for an embedded command, a predetermined value may be described based on the position of “YY”. Further, the control unit (3) may describe the value of the total length of the command unit + BCC. Further, when a capture instruction of “DATA,...” Is included, predetermined data may be captured from the personal information file in that portion, as described above.
[0046]
FIG. 9 is a block diagram showing a configuration for implementing the method of creating an IC card access pattern file according to the present invention. For example, if it is necessary to perform the work shown in FIG. 5 for members of 1,000 people, a template pattern file 41 shown in FIG. 7 is prepared in advance, and a personal information file 42 shown in FIG. If such a table is prepared in advance and a table for performing the above-described unambiguous conversion is prepared in advance as the conversion table 43, the host computer 40 can execute the processing shown in FIG. It is possible to automatically create a pattern file as shown in FIG. Since these 1000 pattern files are described in a format that can be directly handled by the reader / writer device 30, by giving each of these pattern files to the reader / writer device 30 one by one, the membership cards for 1,000 people are sequentially printed. Issue processing can be performed.
[0047]
It is not necessary to prepare data in the personal information file 42 that can be automatically generated based on a predetermined rule among the personal information. For example, when issuing a membership card for 1,000 people, consider writing a member number on an IC card in addition to the name and address of the member described in the above example. This member number is No. 1 to No. When a serial number such as 1000 or a regular number is assigned, an algorithm for generating a member number based on the predetermined rule should be prepared in the host computer 40. This eliminates the need to prepare member number data in the personal information file 42. In the command portion of the template pattern file 41, for example, an instruction to capture a serial number such as "SERIAL" may be described, and each generated member number may be captured based on the instruction. Of course, in the host computer 40, after the process of capturing the member numbers generated in this way is performed, a correct BCC error check code for data including each member number is generated and added.
[0048]
Not only personal information of individual members, but also time information such as the date of issuance of the membership card, the management number used to manage each membership card on the issuer side, and the worker who performed the issuance work Regardless of any data that can be automatically generated by an operation based on a predetermined rule, such as an issuer code for identification, the host computer 40 can perform the same operation as in the example of the member number described above. , And importing this into a template pattern file is possible.
[0049]
As described above, according to the pattern file creating method of the present invention, the following two advantages can be obtained. A first merit is that a capture instruction is described in a template pattern file, and the capture instruction allows a predetermined number of data such as a serial number generated based on data in a separately prepared personal information file or a predetermined rule. Since individual pattern files can be created by partially capturing data, even when issuing a membership card for 1,000 people, it is only necessary to write a single template pattern file. It is. The second merit is that the description of the template pattern file can be performed in a specific simple format, and can be performed without considering the format required by each reader / writer device. As can be seen by comparing the template pattern file of FIG. 7 with the pattern file of FIG. 6, the complicated data sequence of the control unit in FIG. 6 is represented by simple delimiters and descriptions such as “XX” and “YY” in FIG. And the effort to describe the file can be significantly reduced.
[0050]
As described above, the present invention has been described based on the illustrated embodiments. However, the present invention is not limited to these embodiments, and can be implemented in various other modes. In particular, the specific format shown in FIGS. 3 and 4 and the format of the template pattern file shown in FIG. 7 show a format as a very simple model for convenience of explanation. Is generally defined in a more complex format. Of course, the implementation of the present invention is not limited to a specific format, and the present invention can be applied to any format.
[0051]
【The invention's effect】
As described above, according to the pattern file creating method of the present invention, a pattern file having a predetermined format is created based on the template pattern file and the personal information file. The pattern file used to record the pattern can be efficiently created. In addition, since automatically generated data is taken into a template pattern file to create a pattern file in a predetermined format, individual pattern files can be efficiently created.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a form of general access processing for an IC card.
FIG. 2 is a diagram showing a basic configuration of a pattern file F used in the access processing shown in FIG.
FIG. 3 is a diagram illustrating an example of a format of a command code requested by a specific reader / writer device.
FIG. 4 is a diagram illustrating an example of a format of a response code requested by a specific reader / writer device.
FIG. 5 is a diagram showing an example of the contents of a command for performing a job of issuing a membership card using an IC card.
FIG. 6 is a diagram showing an example in which a pattern file for performing the work shown in FIG. 5 is described in the format shown in FIGS. 3 and 4.
FIG. 7 is a diagram showing an example of a template pattern file used in the method according to the present invention.
FIG. 8 is a diagram showing an example of a personal information file used in the method according to the present invention.
FIG. 9 is a block diagram showing an example of a device configuration for performing a method according to the present invention.
[Explanation of symbols]
10 ... IC card
11 I / O interface
12 ... CPU
13 ROM
14 ... RAM
15… EEPROM
20 ... IC card
21 ... I / O interface
22 ... CPU
23… ROM
24 ... RAM
25… EEPROM
30 ... Reader / writer device
31, 32 ... signal transmission path
40 ... Host computer
41 ... Stationery pattern file
42 ... Personal information file
43 ... Conversion table

Claims (3)

CPUを内蔵したICカードと、このICカードをアクセスするためのリーダライタ装置と、の間に信号伝送路を形成し、この信号伝送路を介して、前記リーダライタ装置を制御するホストコンピュータから前記ICカードへ所定のコマンドを往信し、前記ICカードから前記リーダライタ装置を介して前記ホストコンピュータへ前記コマンドに応じたレスポンスを返信する、という往信処理および返信処理を、コマンドおよび当該コマンドに応じて返信されるであろうと期待されるレスポンスの期待値を並べたパターンファイルに基いて実行することにより、ICカードに対するアクセスを行う場合に、アクセスに利用するパターンファイルを作成する方法であって、
複数の個人情報をレコード単位で収容した個人情報ファイルを用意し、
部分的に前記個人情報ファイル内のデータを取り込む旨の取込指示を含んだコマンドおよびこれに対するレスポンスの期待値を、第1の書式で記述したひな形パターンファイルを用意し、
前記第1の書式を、前記リーダライタ装置が解読できる第2の書式に変換するための変換テーブルを用意し、
前記ひな形パターンファイルの所定部分に、前記取込指示に基いて、前記個人情報ファイル内の所定のデータを取り込むとともに、前記変換テーブルに基いて、前記第1の書式を前記第2の書式に変換することにより、前記第2の書式により記述された各個人ごとのパターンファイルを作成する処理をコンピュータに実行させることを特徴とするICカードアクセス用パターンファイルの作成方法。
A signal transmission path is formed between an IC card having a built-in CPU and a reader / writer apparatus for accessing the IC card, and a host computer controlling the reader / writer apparatus transmits the signal transmission path via the signal transmission path. and Oshin a predetermined command to the IC card, from said IC card through the reader-writer device returns a response corresponding to the command to the host computer, the Oshin processing and return processing of, according to a command and the command A method of creating a pattern file used for access when performing access to an IC card by executing based on a pattern file in which expected values of responses expected to be returned are arranged,
Prepare a personal information file containing multiple pieces of personal information in record units,
Prepare a template pattern file in which a command including a capture instruction to partially capture data in the personal information file and an expected value of a response to the command are described in a first format,
Preparing a conversion table for converting the first format into a second format that can be decoded by the reader / writer device;
The predetermined data in the personal information file is fetched into a predetermined portion of the template pattern file based on the fetch instruction, and the first format is changed to the second format based on the conversion table. A method of creating a pattern file for accessing an IC card, comprising causing a computer to execute a process of creating a pattern file for each individual described in the second format by converting.
CPUを内蔵したICカードと、このICカードをアクセスするためのリーダライタ装置と、の間に信号伝送路を形成し、この信号伝送路を介して、前記リーダライタ装置を制御するホストコンピュータから前記ICカードへ所定のコマンドを往信し、前記ICカードから前記リーダライタ装置を介して前記ホストコンピュータへ前記コマンドに応じたレスポンスを返信する、という往信処理および返信処理を、コマンドおよび当該コマンドに応じて返信されるであろうと期待されるレスポンスの期待値を並べたパターンファイルに基いて実行することにより、ICカードに対するアクセスを行う場合に、アクセスに利用するパターンファイルを作成する方法であって、
所定の規則に基づく演算によって、所定のデータを生成するデータ生成手段を用意し、
前記データ生成手段が生成した所定のデータを取り込む旨の取込指示を含んだコマンドおよびこれに対するレスポンスの期待値を、第1の書式で記述したひな形パターンファイルを用意し、
前記第1の書式を、前記リーダライタ装置が解読できる第2の書式に変換するための変換テーブルを用意し、
前記ひな形パターンファイルの所定部分に、前記取込指示に基いて、前記データ生成手段が生成した所定のデータを取り込むとともに、前記変換テーブルに基いて、前記第1の書式を前記第2の書式に変換することにより、前記第2の書式により記述された各個人ごとのパターンファイルを作成する処理をコンピュータに実行させることを特徴とするICカードアクセス用パターンファイルの作成方法。
A signal transmission path is formed between an IC card having a built-in CPU and a reader / writer apparatus for accessing the IC card, and a host computer controlling the reader / writer apparatus transmits the signal transmission path via the signal transmission path. and Oshin a predetermined command to the IC card, from said IC card through the reader-writer device returns a response corresponding to the command to the host computer, the Oshin processing and return processing of, according to a command and the command A method of creating a pattern file used for access when performing access to an IC card by executing based on a pattern file in which expected values of responses expected to be returned are arranged,
By a calculation based on a predetermined rule, a data generating means for generating predetermined data is prepared,
Prepare a template pattern file in which a command including a capture instruction to capture predetermined data generated by the data generation means and an expected value of a response to the command are described in a first format,
Preparing a conversion table for converting the first format into a second format that can be decoded by the reader / writer device;
The predetermined data generated by the data generation means is fetched into a predetermined portion of the template pattern file based on the fetch instruction, and the first format is converted into the second format based on the conversion table. A method for creating a pattern file for accessing an IC card, characterized by causing a computer to execute a process of creating a pattern file for each individual described in the second format by converting the file into a pattern file.
請求項1または2に記載のパターンファイルの作成方法において、
コマンドまたはレスポンスの期待値に、取込指示に基いて所定のデータを取り込んだ後、この取り込んだデータを含めたコマンドまたはレスポンスの期待値に対するエラーチェックコードを演算で求め、求めたエラーチェックコードをコマンドまたはレスポンスの期待値に付加することを特徴とするICカードアクセス用パターンファイルの作成方法。
3. The method for creating a pattern file according to claim 1 or 2,
After capturing predetermined data in the expected value of the command or response based on the capture instruction, calculate an error check code for the expected value of the command or response including the captured data, and calculate the obtained error check code. A method of creating an IC card access pattern file, which is added to an expected value of a command or a response.
JP12822894A 1994-05-18 1994-05-18 Creating a pattern file for IC card access Expired - Lifetime JP3545045B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP12822894A JP3545045B2 (en) 1994-05-18 1994-05-18 Creating a pattern file for IC card access

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP12822894A JP3545045B2 (en) 1994-05-18 1994-05-18 Creating a pattern file for IC card access

Publications (2)

Publication Number Publication Date
JPH07311820A JPH07311820A (en) 1995-11-28
JP3545045B2 true JP3545045B2 (en) 2004-07-21

Family

ID=14979666

Family Applications (1)

Application Number Title Priority Date Filing Date
JP12822894A Expired - Lifetime JP3545045B2 (en) 1994-05-18 1994-05-18 Creating a pattern file for IC card access

Country Status (1)

Country Link
JP (1) JP3545045B2 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5889941A (en) 1996-04-15 1999-03-30 Ubiq Inc. System and apparatus for smart card personalization
JP4523196B2 (en) * 2001-04-27 2010-08-11 日本電信電話株式会社 Management server for exchanging data with IC card and method executed by management server
WO2006057049A1 (en) 2004-11-26 2006-06-01 Kabushiki Kaisha Toshiba Card and host device
JP2015215706A (en) * 2014-05-08 2015-12-03 株式会社東芝 Data processor for issuing ic card, ic card issuance device, ic card issuance system, data processing program for issuing ic card, and ic card issuance program

Also Published As

Publication number Publication date
JPH07311820A (en) 1995-11-28

Similar Documents

Publication Publication Date Title
US5293029A (en) System for mutually certifying an IC card and an IC card terminal
KR920007410B1 (en) Safe file system for a portable data carrier
JP3900536B2 (en) Smart IC card system
JP3568970B2 (en) IC card issuing device
JP2854636B2 (en) Apparatus and method for issuing portable medium
JPS63201748A (en) Portable electronic equipment
JP3480746B2 (en) Portable electronic devices
JP3545045B2 (en) Creating a pattern file for IC card access
JP3657315B2 (en) Portable information recording medium and access method thereof
JP3425177B2 (en) Data transmission system
JP3545627B2 (en) Portable electronic devices
JP3526287B2 (en) Portable electronic device and data writing method thereof
JP2011060136A (en) Portable electronic apparatus, and data management method in the same
JP3645587B2 (en) IC card access pattern file creation support device
JPH02187888A (en) Certification system
JPH09179949A (en) Portable information recording medium and its reader/ writer device
WO2003071473A1 (en) Ic card creation method and system thereof
JP3231466B2 (en) Information recording medium storing keys
JP2505003B2 (en) IC card with auxiliary memory
JP2577370B2 (en) Portable electronic devices
JP3576233B2 (en) Information storage medium issuance processing data creation device and creation method
JP2002123802A (en) Ic card authentication system, ic card, and ic card reader/ writer
JP3054119B2 (en) Portable electronic devices
JPH06119506A (en) Ic card
JP2001043323A (en) Ic card issuing system and ic card issuing method

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20031216

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20040113

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20040304

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20040406

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20040407

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090416

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090416

Year of fee payment: 5

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20100416

Year of fee payment: 6

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110416

Year of fee payment: 7

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110416

Year of fee payment: 7

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120416

Year of fee payment: 8

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130416

Year of fee payment: 9

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140416

Year of fee payment: 10

EXPY Cancellation because of completion of term