JP3788886B2 - IC card and IC card using device - Google Patents
IC card and IC card using device Download PDFInfo
- Publication number
- JP3788886B2 JP3788886B2 JP16090399A JP16090399A JP3788886B2 JP 3788886 B2 JP3788886 B2 JP 3788886B2 JP 16090399 A JP16090399 A JP 16090399A JP 16090399 A JP16090399 A JP 16090399A JP 3788886 B2 JP3788886 B2 JP 3788886B2
- Authority
- JP
- Japan
- Prior art keywords
- card
- parameter
- management
- program
- encryption
- 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 - Fee Related
Links
Images
Description
【0001】
【発明の属する技術分野】
本発明は、異なる種類のICカードにおいてもプログラムの高い再利用性を実現し得るICカード及びICカード利用装置に関する。
【0002】
【従来の技術】
近年、金融、流通、通信及び医療等といった様々な分野に関し、データや手続を記憶可能なICチップを搭載し、固有の機能を実行するICカードの開発が進められている。
【0003】
この種のICカードは、ベンダ毎に異なるカードOSにより、内部のプログラムを動作させている。このため、同じ機能のプログラムであっても、他の種類(他の仕様)のICカードに実装するには、新規にプログラムを作成し直す必要がある。
【0004】
なお、ICカードの種類とは、ICカードの仕様を意味しており、例えば同じRSA方式のアルゴリズムでもベンダ毎に異なり、同じベンダでも実装する機能の組合せ毎に異なり、また、同じベンダの同じRSA方式のアルゴリズムでもICカードのバージョン毎に異なっている。
【0005】
一方、最近、Javaカード(Javaは、米サン・マイクロシステムズ社の商標)の出現により、カードOSが共通化されている。このJavaカードでは、共通のカードOSにより、原則的にはICカード内のプログラム(アプレット)が他の種類のICカードにも実装可能となっている。
【0006】
【発明が解決しようとする課題】
しかしながら、以上のようなICカードでは、共通のカードOSの場合、内部のプログラムは、原則的には他の種類のICカードに実装可能であるものの、実際にはICカードの種類毎にカスタマイズされる必要がある。
【0007】
例えば、各種類のICカード間では、種類毎に使用可能なメモリ量が異なるので、同じ機能の鍵管理プログラムを実装する場合であっても、カード内に入る鍵の個数などに違いが生じる。
【0008】
また、同じ暗号/署名機能のプログラムでも、例えば、DES(Data Encryption Standard)方式のみ実装する場合と、DES方式及びトリプルDES方式の両者を実装する場合とでは、サポートするアルゴリズムに違いがある。よって、各種類のICカードは、鍵の個数やサポートするアルゴリズムの違いに応じてプログラムのカスタマイズが必要である。
とは言え、共通のカードOSの出現により、プログラム自体はどのICカードにも実装可能なので、カスタマイズは最小限に済ませたい。まとめると、ICカードの分野では、ある種類用のプログラムをカスタマイズして他の種類用のプログラムを作成する場合、カスタマイズ前のプログラムを可能な限り再利用したいという要請がある。
本発明は上記実情を考慮してなされたもので、異なる種類のICカードにおいてもプログラムの高い再利用性を実現し得るICカード及びICカード利用装置を提供することを目的とする。
【0009】
【課題を解決するための手段】
請求項1に対応する発明は、カード発行用のICカード利用装置により発行されたICカードであって、カード発行の際に個別パラメータの種類及び個数を示す管理パラメータが設定されたパラメータ管理手段と、カード発行の際に前記管理パラメータに基づいて個別に設定可能な個別パラメータ及びこの個別パラメータを用いて動作が記述されたアルゴリズムからなるプログラムを有し、個別パラメータの指示を含むプログラム実行要求を受けたとき、この指示された個別パラメータに基づいて、前記プログラムを実行するプログラム実行手段を備えており、前記プログラム実行手段としては、前記個別パラメータが設定される前に、この個別パラメータの管理パラメータに基づいて、当該個別パラメータの記憶に必要なICカードのメモリ量を算出するメモリ量算出手段と、前記メモリ量算出手段の算出結果に基づいてメモリ領域を確保した後、前記ICカード利用装置から入力される個別パラメータを前記メモリ領域に保持するパラメータ設定手段とを備えており、前記メモリ量算出手段としては、前記管理パラメータが示す「種類」毎に、当該「種類」に対応するバイト長と、当該「種類」に対応する「個数」とを乗算し、得られた各々の乗算結果及び定数αを互いに加算することにより、前記メモリ量を算出するICカードである。
【0010】
また、請求項2に対応する発明は、請求項1に対応するICカードにおいて、前記管理パラメータの読出要求が入力されると、前記パラメータ管理手段内の管理パラメータを読出すパラメータ読出手段を備えたICカードである。
【0011】
さらに、請求項3に対応する発明は、請求項2に対応するICカードを利用して処理を実行するICカード利用装置において、前記パラメータ読出手段から読出された管理パラメータに基づいて、前記ICカードへのアクセスを行なうカードアクセス手段を備えたICカード利用装置である。
【0012】
さらに、請求項4に対応する発明は、請求項2に対応するICカードを発行するカード発行用のICカード利用装置において、前記ICカードを発行する際に、前記プログラム実行手段、前記パラメータ管理手段及び前記パラメータ読出手段の各プログラムを当該発行する前のICカードに書き込む手段と、前記書き込まれたプログラム実行手段の起動の後、前記発行する前のICカードに個別パラメータを入力する手段とを備えたICカード利用装置である。
また、請求項5に対応する発明は、カード発行の際に個別に設定可能な個別パラメータ及びこの個別パラメータを用いて動作が記述されたアルゴリズムからなるプログラムを有し、個別パラメータの指示を含むプログラム実行要求を受けたとき、この指示された個別パラメータに基づいて、前記プログラムを実行するプログラム実行手段を備えたICカードを利用して処理を実行するICカード利用装置であって、前記個別パラメータを設定する前に、この個別パラメータの種類及び個数を示す管理パラメータに基づいて、当該個別パラメータの記憶に必要なICカードのメモリ量を算出するメモリ量算出手段と、前記メモリ量算出手段の算出結果を表示し、カード発行者に確認を促す手段と、前記確認により前記管理パラメータが確定すると、この管理パラメータを前記プログラム内のパラメータ管理手段に設定する手段と、このパラメータ管理手段内の管理パラメータに基づいて前記メモリ量を算出してこの算出結果に基づいてメモリ領域をICカード内に確保した後に前記ICカード利用装置から入力される個別パラメータを前記メモリ領域に保持可能な前記プログラムに関し、このプログラムを前記ICカードにインストールする手段と、前記インストールされたプログラムにより前記メモリ領域がICカード内に確保された後、前記個別パラメータを前記ICカードに入力するパラメータ設定手段とを備えており、前記メモリ量算出手段としては、前記管理パラメータが示す「種類」毎に、当該「種類」に対応するバイト長と、当該「種類」に対応する「個数」とを乗算し、得られた各々の乗算結果及び定数αを互いに加算することにより、前記メモリ量を算出するICカード利用装置である。
請求項6に対応する発明は、請求項5に記載のICカード利用装置において、前記ICカードとしては、前記管理パラメータの読出要求が入力されると、前記パラメータ管理手段内の管理パラメータを読出すパラメータ読出手段を備えたICカード利用装置である。
請求項7に対応する発明は、請求項6に記載のICカード利用装置において、前記パラメータ読出手段から読出された管理パラメータに基づいて、前記ICカードへのアクセスを行なうカードアクセス手段を備えたICカード利用装置である。
【0014】
(作用)
従って、請求項1,5に対応する発明は以上のような手段を講じたことにより、プログラム実行手段が、個別に設定可能な個別パラメータ及びこの個別パラメータを用いて動作が記述されたアルゴリズムからなるプログラムを有し、個別パラメータの指示を含むプログラム実行要求を受けたとき、この指示された個別パラメータに基づいて、プログラムを実行する。
【0015】
これにより、ある種類のICカードのプログラムを異なる種類のICカードにカスタマイズする際に、アルゴリズムを変更せずに、個別パラメータを変更することにより、カスタマイズを実行できる。すなわち、カスタマイズの際に、プログラムのうち、アルゴリズムの部分を再利用できる。よって、異なる仕様のICカードにおいてもプログラムの高い再利用性を実現させることができる。
また、請求項1,5に対応する発明は、プログラム実行手段におけるメモリ量算出手段が、個別パラメータが設定される前に、この個別パラメータの種類及び個数を示す管理パラメータに基づいて、当該個別パラメータの記憶に必要なICカードのメモリ量を算出し、プログラム実行手段におけるパラメータ設定手段が、メモリ量算出手段の算出結果に基づいてメモリ領域を確保した後、ICカード利用装置から入力される個別パラメータをメモリ領域に保持するので、前述した作用に加え、カスタマイズの際に、必要なメモリ量を検討する作業の効率を向上させることができる。
【0016】
また、請求項2,6に対応する発明は、パラメータ読出手段が、管理パラメータの読出要求が入力されると、パラメータ管理手段内の管理パラメータを読出すので、請求項1,5に対応する作用に加え、管理パラメータの内容により、外部からカード本体の機能の詳細(鍵管理機能なら鍵の個数など)を容易に知ることができる。
【0017】
さらに、請求項3,7に対応する発明は、カードアクセス手段が、パラメータ読出手段から読出された管理パラメータに基づいて、ICカードへのアクセスを行なうので、請求項2,6に対応する作用に加え、ICカードにて(管理パラメータの示す)サポートされた機能に対する要求のときのみICカードにアクセスすることにより、無駄なアクセスを無くすことができる。
【0018】
また、請求項4に対応する発明は、カード発行用のICカード利用装置が、ICカードを発行する際に、プログラム実行手段、パラメータ管理手段及びパラメータ読出手段の各プログラムを当該発行する前のICカードに書き込み、このプログラム実行手段の起動の後、発行する前のICカードに個別パラメータを入力するので、請求項2に対応するICカードを発行することができる。
【0019】
【発明の実施の形態】
以下、本発明の各実施形態について図面を参照しながら説明する。
(第1の実施形態)
図1は本発明の第1の実施形態に係るICカード及びICカード利用装置の構成を示すブロック図である。このICカード10は、パラメータ管理部11、プログラム実行部12及びパラメータ読出部13を備えている。
【0020】
ここで、パラメータ管理部11は、プログラム実行部12内の個別パラメータの属性を管理するための管理パラメータが設定されたものであり、その管理パラメータをプログラム実行部12及びパラメータ読出部13により読出可能となっている。なお、管理パラメータは、カード外に読出不可の個別パラメータとは異なり、カード外に読出可能な管理用の属性データである。例えば個別パラメータが暗号鍵自体のとき、管理パラメータは、暗号鍵の種類及びその個数(個別パラメータの属性)が適用可能となっている。
【0021】
プログラム実行部12は、カード利用の際に、ICカード利用装置20からの入力内容に基づいて、パラメータ管理部11を参照して入力内容とプログラムの整合とを確認した後、プログラムを実行してその実行結果をICカード利用装置20に送出する機能をもっている。
【0022】
具体的には、プログラム実行部12は、ある個別パラメータの指示を含むプログラム実行要求を受けたとき、パラメータ管理部11内の管理パラメータに基づいて、プログラム実行要求の適否を判定し、適と判定したとき、指示された個別パラメータに基づいて、プログラムを実行し、実行結果をICカード利用装置20に返送する機能をもっている。
【0023】
なお、実行されるプログラムは、ICカード10の種類とは無関係のアルゴリズムの部分と、アルゴリズム中で使用される個別パラメータの部分とから構成され、個別パラメータの変更により、アルゴリズム部分を変更せずに、他の種類のICカード20に転用可能なものである。
【0024】
パラメータ読出部13は、ICカード利用装置20からの要求に基づいて、パラメータ管理部11内の管理パラメータを読出してICカード利用装置20に送出する機能をもっている。
【0025】
一方、ICカード利用装置20は、図示しないアプリケーションソフトウェア部、カードアクセス部21及びカードR/W(リーダライタ)部22を備えている。
【0026】
ここで、カードアクセス部21は、アプリケーションソフトウェア部の処理の実行に応じ、カードアクセス要求を受けたとき、ICカードのパラメータ読出部13を介してパラメータ管理部11内の管理パラメータを読出す機能と、図2に示すように、この管理パラメータに基づいて、カードアクセス要求の内容がICカード10にて実行可能か否かを判定する機能と、実行可能なときにはカードR/W部22を介してICカード10にアクセスする機能と、実行不可能なときにはエラー通知をアプリケーションソフトウェア部に返送して処理を終了する機能とをもっている。
【0027】
なお、カードアクセス要求は、ICカード10へのアクセスを伴う全ての要求を包含する概念であり、ここでは、個別パラメータの指定を含むプログラム実行要求が該当する。
【0028】
カードR/W部22は、カードアクセス部21により制御され、ICカード10に対して情報を読出/書込可能な装置であり、具体的には周知のICカードリーダライタである。
【0029】
次に、以上のように構成されたICカード及びICカード利用装置の動作を説明する。
(カード発行時)
まず、カード発行の際に、カード発行者により、管理パラメータが指定される。この管理パラメータは、カード発行用の図示しないICカード利用装置により、パラメータ管理部11に記述される。また、これらパラメータ管理部11、プログラム実行部12及びパラメータ読出部13の各プログラムは、ICカード利用装置により、ICカード20に書き込まれる。
【0030】
その後、起動されたプログラム実行部12は、パラメータ管理部11内の管理パラメータ(例、鍵の種類と個数)に基づいて、個別パラメータ(例、鍵)の保持に要するメモリ量を算出し、算出結果に基づいてメモリ領域を確保する。続いて、プログラム実行部12は、ICカード利用装置から入力される個別パラメータをこのメモリ領域に保持する。また、利用者ID等の登録の後、ICカード10が発行される。
【0031】
(カード利用時)
次に、このICカードを利用する際の動作を図1を用いて述べる。
カード利用の際には、ICカード利用装置20においては、カードアクセス部21が、アプリケーションソフトウェア部の処理の実行に応じ、個別パラメータの指定(例、鍵の種類とその種類中の何番目か)を含むプログラム実行要求を受けたとき、ICカード10のパラメータ読出部13を介してパラメータ管理部11内の管理パラメータを読出す。
【0032】
続いて、カードアクセス部21は、図2に示したように、この管理パラメータに基づいて、プログラム実行要求の内容がICカード10にて実行可能か否か(個別パラメータの指定が管理パラメータに適合するか否か)を判定する。
【0033】
この判定の結果、実行不可能なときにはエラー通知をアプリケーションソフトウェア部に返送して処理を終了するが、ここでは実行可能であるので、カードR/W部22を介してICカード10にアクセスする。
【0034】
ICカード10においては、このプログラム実行要求を受けると、パラメータ管理部11内の管理パラメータに基づいて、プログラム実行要求の適否を判定し、適と判定したとき、指示された個別パラメータに基づいて、プログラムを実行すると共に、実行結果をICカード利用装置20に送出する。
【0035】
この実行結果は、カードR/W部22及びカードアクセス部21を介してアプリケーションソフトウェア部(図示せず)に送出される。これにより、アプリケーションソフトウェア部は、ICカード10の機能を利用して処理を実行することができる。
【0036】
上述したように本実施形態によれば、プログラム実行部12が、個別に設定可能な個別パラメータ及びこの個別パラメータを用いて動作が記述されたアルゴリズムからなるプログラムを有し、個別パラメータの指示を含むプログラム実行要求を受けたとき、この指示された個別パラメータに基づいて、プログラムを実行する。
【0037】
これにより、ある種類のICカードのプログラムを異なる種類のICカードにカスタマイズする際に、アルゴリズムを変更せずに、個別パラメータを変更することにより、カスタマイズを実行できる。すなわち、カスタマイズの際に、プログラムのうちのアルゴリズムの部分を再利用できるので、最小限の変更作業により、プログラムをカスタマイズできる。よって、異なる仕様のICカードにおいてもプログラムの高い再利用性を実現させることができる。
【0038】
また、プログラム実行部12が、個別パラメータが設定されるとき、この個別パラメータの属性に基づいて、当該個別パラメータの記憶に必要なメモリ量を算出し、この算出結果に基づいて、個別パラメータを設定させるので、カスタマイズの際に、必要なメモリ量を検討する作業の効率を向上させることができる。
【0039】
さらに、個別パラメータの属性を管理するための管理パラメータが設定されたパラメータ管理部11を設け、パラメータ読出部13が、管理パラメータの読出要求が入力されると、パラメータ管理部11内の管理パラメータを読出すので、管理パラメータの内容により、外部からカード本体の機能の詳細(鍵管理機能なら鍵の個数など)を容易に知ることができる。
【0040】
また、カードアクセス部21が、パラメータ読出部13から読出された管理パラメータに基づいて、ICカード10へのアクセスを行なうので、アプリケーションソフトウェア部からの要求がICカード10内にサポートされた機能に対応するときのみ、ICカード10にアクセスすることにより、無駄なアクセスを無くすことができる。
【0041】
(第2の実施形態)
図3及び図4は本発明の第2の実施形態に係るICカード及びICカード利用装置の構成を示すブロック図であり、同一要素には同一数字を付して重複した説明を省略する。
【0042】
なお、本実施形態は、第1の実施形態と同様の作用効果をより詳細に述べるものである。
具体的には、カード発行者用のICカード利用装置30Aは、カード発行用アプリケーション31A、カード暗号化機能モジュール32、R/Wドライバ部33及びカードR/W部34を備えている。
【0043】
また、カード利用者用のICカード利用装置30Bは、前述した構成において、カード発行用アプリケーション31Aに代えて、ファイル暗号化用アプリケーション31Bを備えている。
【0044】
ここで、カード発行用アプリケーション31Aは、カード発行者にカード発行のためのユーザインタフェースを提供し、発行者の要求に応じてカード暗号化機能モジュール32を利用してカード発行手続を実現するものであって、Javaアプリケーションとして実装されている。
【0045】
具体的には、カード発行用アプリケーション31Aは、カード発行用の処理を実行するための上位アプリケーションであり、カード発行者の要求に応じ、暗号化機能モジュール32の夫々のJavaメソッド(Javaは米サン・マイクロシステムズ社の商標)を呼出すように、Javaメソッド毎に対応するカードアクセス要求(以下、カード命令という)をカード暗号化機能モジュール32に与える機能をもっている。
【0046】
なお、カード発行用アプリケーション31Aが呼出すJavaメソッドとしては、例えば「鍵の選択」、「鍵のインポート」、「パーソナライズ」の順序の各メソッドがあり、図5〜図8に示すように、夫々「鍵の選択」、「鍵のインポート」、「パーソナライズ」の各カード命令のカード暗号化機能モジュール32への入力により呼び出され、戻り値のカード発行用アプリケーション31Aへの出力により終了する。
【0047】
また同様に、ファイル暗号化アプリケーション31Bは、利用者にファイル暗号化のためのユーザインタフェースを提供し、利用者の要求に応じて、カード暗号化機能モジュール32を利用してファイル暗号化機能を実現するものであって、Javaアプリケーションとして実装されている。
【0048】
具体的には、ファイル暗号化アプリケーション31Bは、ファイル暗号化用の処理を実行するための上位アプリケーションであり、利用者の要求に応じ、暗号化機能モジュール32の夫々のJavaメソッドを呼び出すように、このJavaメソッド毎に、対応するカード命令をカード暗号化機能モジュール32に与える機能と、カード暗号化機能モジュール32から機能実行結果(戻り値)を受けると、所定の処理(例、機能実行結果の保存等)を実行する機能とをもっている。
【0049】
なお、ファイル暗号化アプリケーション31Bが呼出すJavaメソッドとしては、例えば「鍵の選択」と、その後の「暗号化」又は「復号」との各メソッドがあり、図5、図8及び図9に示すように、夫々「鍵の選択」、「暗号化」、「復号」の各カード命令のカード暗号化機能モジュール32への入力により呼び出され、戻り値のファイル暗号化アプリケーション31Bへの出力により終了する。
【0050】
カード暗号化機能モジュール32は、ICカード40内の鍵を利用したデータ暗号化機能を提供するモジュールであり、ICカード40へのコマンド送信を隠蔽し、上位アプリケーションへ直感的なインタフェースを提供するものであって、Javaクラスライブラリとして実装されている。
【0051】
具体的には、カード暗号化機能モジュール32は、これら上位のアプリケーション31A,31Bから受けるカード命令を解釈し、「鍵の選択」、「鍵のインポート」、「パーソナライズ」、「暗号化」、「復号」という5種類のJavaメソッドのいずれかに移行し、図10〜図14に示すように、対応するコマンドをR/Wドライバ部33及びカードR/W部34を介してICカード40に送出する機能と、この送出に応じてICカード40から受けた機能実行結果(応答)を上位のアプリケーション31A,31Bに送出し、Javaメソッドから復帰する機能とをもっている。
【0052】
なお、カード暗号化機能モジュール32は、カード命令「オプションリスト取得」に対応するJavaメソッドに関しては、ICカード40への接続を開始したとき、図15に示すように、最初に自動的にオプションリスト取得コマンドをR/Wドライバ部33及びカードR/W部34を介してICカード40に送出する機能をもっている。
【0053】
R/Wドライバ部33は、カード暗号化機能モジュール32に制御され、カードR/W部34を駆動する周知のICカードリーダライタドライバである。例えば、R/Wドライバ部33は、PC/SC用の各カードR/Wドライバを一括管理するソフトウェア(例、PC/SCリソースマネージャ)と各カードR/Wドライバとの組合せとしてもよい。なお、PC/SCは、Microsoft Windows (Windows は、米マイクロソフト社の商標)上でICカードにアクセスするための仕組みである。
【0054】
カードR/W部34は、前述同様に、R/Wドライバ部33に制御され、ICカード40内の情報を読出/書込可能な周知のICカードリーダライタであり、例えばFY-1300 (FY-1300 は、(株)東芝の製品の型番)が使用可能となっている。
【0055】
一方、ICカード40としては、共通のカードOS41、受信バッファ42、送信バッファ43、暗号化カードアプレット44、DES暗号装置45及びトリプルDES暗号装置46を備えており、具体的にはJavaカードOSの載ったICカード(Javaカード)であればよく、例えばJMAGIC(JMAGICは、(株)東芝の商標)が使用可能となっている。
【0056】
カードOS41は、複数のカードアプレットを個別に実行可能なものであり、具体的にはJavaカードOSであって、ここでは、暗号化カードアプレット44を制御する機能と、ICカード利用装置30A,30Bから受けたデータを受信バッファ42に記憶させる機能と、送信バッファ43内のデータをICカード利用装置30A,30Bに送信する機能とをもっている。
【0057】
暗号化カードアプレット44は、JavaカードOS上で動作するアプリケーションソフトウェアであり、ソースコードがJava言語で記述可能であり、ここでは、パラメータ管理クラス47と、暗号化/鍵管理アプレットの機能をもった暗号化/鍵管理アプレットクラス48とから構成される。
【0058】
パラメータ管理クラス47は、図16にソースコードを示すように、カード40に実装される鍵の種類と個数(管理パラメータ)を保持するものである。なお、この管理パラメータの一覧は、本明細書中「オプションリスト」と呼ばれる。
【0059】
暗号化/鍵管理アプレットクラス48は、利用者IDメモリ48a、パーソナライズ状態メモリ48b及び鍵メモリ48cと、この鍵メモリ48c内の鍵(個別パラメータ)を用いて動作が記述されたメソッド(アルゴリズム)からなるプログラムであり、鍵の指示を含むプログラム実行要求を受けたとき、この指示された鍵に基づいて、図示しないCPUに実行されることにより、送信バッファ43及び受信バッファ41を介してカード外との通信処理を行うものである。
【0060】
具体的には、暗号化/鍵管理アプレットクラス48は、図17に示す如き、アプレットインストール時の初期化処理機能と、ICカード利用装置30A,30Bから受信バッファ42に受けた「鍵の選択」コマンド、「鍵のインポート」コマンド、「パーソナライズ」コマンド、「オプションリスト取得」コマンド、「暗号化」コマンド又は「復号」コマンドに個別に応じて図18〜図23に示す如き処理を実行し、実行結果を送信バッファ43に書込むコマンド処理機能とをもっている。
【0061】
DES暗号装置45は、暗号化カードアプレット44により制御され、暗号化カードアプレット44により与えられたデータに対し、DES方式による暗号化処理又は復号処理を実行し、実行結果を暗号化カードアプレット44に送出するものである。
【0062】
トリプルDES暗号装置46は、暗号化カードアプレット44により制御され、暗号化カードアプレット44により与えられたデータに対し、トリプルDES方式による暗号化処理又は復号処理を実行し、実行結果を暗号化カードアプレット44に送出するものである。
【0063】
次に、以上のように構成されたICカード利用装置及びICカードの動作をカード発行時及びカード利用時に分けて説明する。
【0064】
(カード発行時)
カード発行の際には、カード発行者により、図1に示すICカード利用装置30Aが使用され、暗号化カードアプレット44が個別のICカード用にカスタマイズされた後、ICカード40にインストールされる。ここでは、DESとトリプルDESとの夫々の鍵の個数がカスタマイズされる場合を例に挙げて説明する。
【0065】
いま、ICカード利用装置30Aにおいては、カード発行用アプリケーション31Aが起動され、カスタマイズ対象の暗号化カードアプレット44が選択済であるとする。
【0066】
このカード発行用アプリケーション31Aは、その実行中、カード発行者の操作により、搭載される鍵の種類とその個数とが指定されると、この指定内容による必要なメモリ量M[byte]を次の(1)式で算出し、適宜表示させてカード発行者に確認を促す。
【0067】
M=8D+16T+α …(1)
但し、D:DES鍵の個数、T:トリプルDES鍵の個数、α:定数である。
この必要なメモリ量の算出はカード発行用アプリケーション31A以外の部分で行っても良い。
【0068】
指定内容が確定されると、カード発行用アプリケーションの実行により、図16に示す如き、パラメータ管理クラスの定数(numOfDesKey 及びnumOfDes3Key)の値(各種類の鍵の個数)を変更する。
これにより、暗号化アプレットのカスタマイズが完了する。
【0069】
次に、ICカード利用装置30Aは、カード発行者の操作に基づき、暗号化カードアプレット44をICカード40にインストールする。このインストールの際には、各カード毎の専用インストール手順が使用され、図17に示すように、暗号化カードアプレット44により、アプレットインストール時の初期化処理が実行される。
【0070】
すなわち、暗号化カードアプレット44内の暗号化/鍵管理アプレットクラス48は、その実行中、利用者IDの保存領域(利用者IDメモリ48a)を確保し(ST1)、パーソナライズ状態を保存するフラグを宣言してパーソナライズ常態メモリ48bを確保し、フラグを「パーソナライズ前」状態に初期化する(ST2)。
【0071】
続いて、鍵の保存に必要なメモリ量を前述の(1)式により算出し、このメモリ量に相当する保存領域(鍵メモリ48cの一部)を確保する(ST3)。
次に、鍵の種類、鍵メモリ48c上のオフセット値(鍵オフセット(先頭アドレス))を保存するための領域を確保し(ST4)、アプレットインストール時の初期化処理を終了する。
【0072】
次に、カード発行用アプリケーション31Aは、カード発行者の操作により、鍵をICカードにインポートするためのインポート処理を実行し、カード暗号化機能モジュールの「鍵の選択」メソッド及び「鍵のインポート」メソッドを呼出すように、「鍵の選択」及び「鍵のインポート」の各カード命令を順次、カード暗号化機能モジュールに送出する。
【0073】
カード暗号化機能モジュール32は、「鍵の選択」のカード命令を受けると、「鍵の選択」コマンドをICカード40向けに送出する。次に、カード暗号化機能モジュール32は、「鍵のインポート」カード命令を受けると、「鍵のインポート」コマンドをICカード40向けに送出する。これら「鍵の選択」コマンド及び「鍵のインポート」コマンドは、R/Wドライバ部33及びカードR/W部34を介してICカード40の受信バッファ42に保存される。
【0074】
ICカード40の暗号化カードアプレット44は、受信バッファ42内の「鍵の選択」コマンドに基づき、図18に示すように、パラメータ管理クラス47の定数(numOfDesKey 及びnumOfDes3Key)を参照しつつ、指定された種類と何番目の鍵かを示す鍵番号とが利用可能か否かを判定し(ST11)、利用不可能なときには処理を終了するが、利用可能なときには、指定内容に基づいて、対応する鍵メモリ48cのオフセットを算出して保存する(ST12)。
【0075】
例えば、DES方式の1番の鍵の場合、DESの鍵の先頭のオフセット(先頭アドレス)が得られる。また、DESの3番の鍵の場合、先頭のオフセット+DES鍵の所定バイト長×3(番目の鍵)として、鍵オフセットが算出される。なお、鍵の所定バイト長は、DES鍵は8バイトであり、トリプルDES鍵は16バイトである。
【0076】
また、ステップST12の後、暗号化/鍵管理アプレットクラス48は、指定された鍵の種類を保存する(ST13)。
【0077】
次に、暗号化カードアプレット44は、受信バッファ42内の「鍵のインポート」コマンドに基づき、図19に示すように、パーソナライズ状態メモリ48bのフラグを参照してパーソナライズ前か否(後)かを判定し(ST21)、否のときには処理を終了するが、パーソナライズ前のときには、受信バッファ42内のデータを鍵の種類に対応するバイト長分だけ、鍵メモリ48c内の鍵オフセットからの領域にコピーする(ST22)。
【0078】
なお、鍵のインポート処理は、指定された鍵の種類とその個数に対応した回数だけ、「鍵の選択」及び「鍵のインポート」の各メソッドが繰り返し呼び出されて実行される。
【0079】
次に、カード発行用アプリケーション31Aは、カード発行者の操作により、利用者IDを用いてICカード40をパーソナライズ(個人化)するためのパーソナライズ処理を実行し、カード暗号化機能モジュール32の「パーソナライズ」メソッドを呼出すように、「パーソナライズ」のカード命令をカード暗号化機能モジュール32に送出する。
【0080】
カード暗号化機能モジュール32は、「パーソナライズ」のカード命令を受けると、「パーソナライズ」コマンドをICカード40向けに送出する。「パーソナライズ」コマンドは、R/Wドライバ部33及びカードR/W部34を介してICカード40の受信バッファ43に保存される。
【0081】
ICカード40の暗号化カードアプレット33は、受信バッファ43内の「パーソナライズ」コマンドに基づき、図20に示すように、受信バッファ43内のデータを8バイト分だけ利用者IDメモリ48aにコピーし(ST31)、パーソナライズ状態メモリ48bのフラグを“パーソナライズ後”に設定する(ST32)。
【0082】
ここでは、利用者IDにより、ICカード40がパーソナライズされると共に、“パーソナライズ後”のパーソナライズ状態フラグにより、以後の鍵のインポートが不可となる。
【0083】
これにより、ICカード40のパーソナライズ処理が完了し、ICカード40の発行が完了する。発行されたICカード40は、手渡し又は郵送等により、利用者に配布される。
(カード利用時)
カードを利用する際には、利用者により、図2に示すICカード利用装置30Bが使用され、ファイルが暗号化又は復号される。その際、暗号化/復号のための鍵は選択可能となっている。
【0084】
いま、ICカード利用装置30Bにおいては、ファイル暗号化アプリケーション31Bが起動されており、利用者のICカード40がカードR/W部34に保持されたとする。このICカード40への接続を開始したとき、カード暗号化機能モジュール32は、最初に自動的に「オプションリスト取得」コマンドをICカード40向けに送出する。
【0085】
ICカード40の暗号化/鍵管理アプレットクラス48は、受信バッファ43内の「オプションリスト取得」コマンドに基づき、図21に示すように、オプションリスト取得メソッドを呼び出してパラメータ管理クラス47の定数(DES鍵の個数、トリプルDES鍵の個数)の一覧をオプションリストとして送信バッファ43に保存し(ST41)、オプションリスト取得メソッドから復帰する。
【0086】
送信バッファ43内のオプションリストは、カードOS41により、ICカード利用装置30Bに送出され、カードR/W部34及びR/Wドライバ部33を介してカード暗号化機能モジュール32に送出される。
【0087】
次に、前述同様に鍵が選択される。ファイル暗号化アプリケーション31Bは、利用者の操作により、指定された鍵の種類及び番号に基づいて、鍵の選択処理を実行し、「鍵の選択」メソッドを呼出すための「鍵の選択」のカード命令をカード暗号化機能モジュール32に送出する。
【0088】
カード暗号化機能モジュールは、「鍵の選択」のカード命令を受けると、カード命令中に指定された鍵がICカード40内で使用か否かをオプションリストにより判定し、使用可能なときのみ、前述同様に、「鍵の選択」コマンドをICカード40向けに送出する。
【0089】
ICカード40の暗号化/鍵管理アプレットクラス48は、受信バッファ42内の「鍵の選択」コマンドに基づき、前述した図18に示すように、パラメータ管理クラス47の定数を確認し(ST11)、指定内容に基づいて、対応する鍵メモリ48cのオフセットを保存し(ST12)、鍵の種類を保存する(ST13)。
【0090】
次に、ファイル暗号化アプリケーション31Bは、利用者の操作により、データmを暗号化するための暗号化処理を実行し、カード暗号化機能モジュール32の「暗号化」メソッドを呼出すように、「暗号化」のカード命令をカード暗号化機能モジュール32に送出する。
【0091】
カード暗号化機能モジュール32は、「暗号化」のカード命令を受けると、「暗号化」コマンドをICカード40向けに送出する。
【0092】
ICカード40の暗号化/鍵管理アプレットクラス48は、受信バッファ42内の「暗号化」コマンドに基づき、図22に示すように、保存された鍵の種類に従ってDES暗号装置45又はトリプルDES暗号装置46を選択する(ST51)。
【0093】
また、暗号化/鍵管理アプレットクラス48は、選択した例えばDES暗号装置45を暗号化用に初期化すると共に、引数として、鍵メモリ48c内の鍵オフセットをDES暗号装置45に与える(ST52)。これにより、DES暗号装置45は、鍵メモリ48c内の鍵を使用した暗号処理を実行可能となる。
【0094】
また、暗号化/鍵管理アプレットクラス48は、受信バッファ42内のデータmをDES暗号装置45に与え、しかる後、DES暗号装置45による暗号化結果を送信バッファ43に記憶させ(ST53)、処理を終了する。
この暗号化結果は、カードOS41によりICカード利用装置30Bに送出され、カードR/W部34及びドライバR/W部33を介してカード暗号化機能モジュール32に与えられ、カード暗号化機能モジュール32からファイル暗号化アプリケーション31Bに出力される。
【0095】
これにより、暗号化処理が完了する。
次に、復号処理について説明する。なお、DES暗号装置45において、暗号化と復号とは、基本的には同じ変換処理である。
このため、ICカード利用装置30Bにおける復号処理は、上述した暗号化処理において、暗号化対象のデータmに代えて、復号対象のデータcを用い、「暗号化」メソッドに代えて、「復号」メソッドを用い、「暗号化」のカード命令及び「暗号化」のコマンドに代えて、「復号」のカード命令及び「復号」のコマンドが使用されたものと同じである。また、鍵の指定内容は、暗号化処理のときと同じである(例示したDESが共通鍵方式なので)。
【0096】
すなわち、ICカード利用装置30B及びICカード40では、利用者の復号要求により、前述した暗号化処理と同様に、図18及び図23に示すように、データcに対する復号処理が実行される。
【0097】
上述したように本実施形態によれば、第1の実施形態の効果に加え、以下のような効果を得ることができる。
【0098】
例えば、上位のアプリケーション31A,31BがJavaのメソッドを呼出すだけでICカード40にアクセスできるので、アクセスの容易性を向上させることができる。
【0099】
また前述同様に、ICカード40のプログラムをカスタマイズする際に、暗号化/鍵管理アプレットクラス48を全く変更せずに済むので、プログラムの高い再利用性を実現できる。
【0100】
さらに、パラメータ管理クラス47の定数の変更がオプションリストに反映されるので、カード発行者及びICカード利用装置30Aは、オプションリストのフォーマットを知る必要がなく、容易にカスタマイズを行なうことができる。また、パラメータ管理クラス47の定数を変更する際に、必要なメモリ量がすぐ算出されるので、明確な指針の下でプログラムを変更することができる。
【0101】
これらに加え、カード暗号化機能モジュール32が使用するコマンドのみをサポートするように暗号化/鍵管理アプレットクラス48を作成することにより、他のコマンドに対応するプログラムの分だけ、ICカード40のメモリ量やプログラム開発量をより低減させることができる。
【0102】
また、このように必要なコマンドのみをサポートする構成により、ICカード40とICカード利用装置30A,30Bとからなるシステム全体としての構成を容易にし、保守性を向上させることができる。
【0103】
なお、本発明はその要旨を逸脱しない範囲で種々変形して実施できる。
【0104】
【発明の効果】
以上説明したように本発明によれば、異なる種類のICカードにおいてもプログラムの高い再利用性を実現できるICカード及びICカード利用装置を提供できる。
【図面の簡単な説明】
【図1】本発明の第1の実施形態に係るICカード及びICカード利用装置の構成を示すブロック図
【図2】同実施形態におけるカードアクセス部の機能を説明するための模式図
【図3】本発明の第2の実施形態に係るICカード及びICカード利用装置の構成を示すブロック図
【図4】同実施形態におけるICカード及びICカード利用装置の構成を示すブロック図
【図5】同実施形態におけるカード命令とその戻り値を説明するための模式図
【図6】同実施形態におけるカード命令とその戻り値を説明するための模式図
【図7】同実施形態におけるカード命令とその戻り値を説明するための模式図
【図8】同実施形態におけるカード命令とその戻り値を説明するための模式図
【図9】同実施形態におけるカード命令とその戻り値を説明するための模式図
【図10】同実施形態におけるカード命令とその戻り値を説明するための模式図
【図11】同実施形態におけるコマンドとその応答を説明するための模式図
【図12】同実施形態におけるコマンドとその応答を説明するための模式図
【図13】同実施形態におけるコマンドとその応答を説明するための模式図
【図14】同実施形態におけるコマンドとその応答を説明するための模式図
【図15】同実施形態におけるコマンドとその応答を説明するための模式図
【図16】同実施形態におけるパラメータ管理クラスを説明するための模式図
【図17】同実施形態におけるアプレットインストール時の初期化処理を説明するためのフローチャート
【図18】同実施形態における鍵の選択処理を説明するためのフローチャート
【図19】同実施形態における鍵のインポート処理を説明するためのフローチャート
【図20】同実施形態におけるパーソナライズ処理を説明するためのフローチャート
【図21】同実施形態におけるオプションリスト取得処理を説明するためのフローチャート
【図22】同実施形態における暗号化処理を説明するためのフローチャート
【図23】同実施形態における復号処理を説明するためのフローチャート
【符号の説明】
10,40…ICカード
11…パラメータ管理部
12…プログラム実行部
13…パラメータ読出部
20,30A,30B…ICカード利用装置
21…カードアクセス部
22,34…カードR/W部
31A…カード発行用アプリケーション
31B…ファイル暗号化用アプリケーション
32…カード暗号化機能モジュール
33…R/Wドライバ部
41…共通のカードOS
42…受信バッファ
43…送信バッファ
44…暗号化カードアプレット
45…DES暗号装置
46…トリプルDES暗号装置
47…パラメータ管理クラス
48…暗号化/鍵管理アプレットクラス
48a…利用者IDメモリ
48b…パーソナライズ状態メモリ
48c…鍵メモリ[0001]
BACKGROUND OF THE INVENTION
The present invention relates to an IC card and an IC card utilization device that can realize high reusability of a program even in different types of IC cards.
[0002]
[Prior art]
In recent years, in various fields such as finance, distribution, communication, and medical care, development of an IC card that is equipped with an IC chip capable of storing data and procedures and that executes a unique function has been advanced.
[0003]
In this type of IC card, an internal program is operated by a different card OS for each vendor. For this reason, even if a program has the same function, it is necessary to recreate a new program in order to mount it on an IC card of another type (other specifications).
[0004]
The type of IC card means the specification of the IC card. For example, the same RSA algorithm is different for each vendor, the same vendor is different for each combination of functions, and the same RSA of the same vendor is used. The algorithm of the method is different for each IC card version.
[0005]
On the other hand, recently, with the advent of Java cards (Java is a trademark of Sun Microsystems, Inc.), card OSs have become common. In this Java card, a program (applet) in the IC card can be mounted on other types of IC cards in principle by a common card OS.
[0006]
[Problems to be solved by the invention]
However, in the case of the IC card as described above, in the case of a common card OS, the internal program can be mounted on other types of IC cards in principle, but is actually customized for each type of IC card. It is necessary to
[0007]
For example, the amount of memory that can be used for each type of IC card differs between the types of IC cards, so that even when a key management program having the same function is installed, the number of keys entering the card differs.
[0008]
Even in the same encryption / signature function program, for example, there is a difference in the supported algorithm between the case where only the DES (Data Encryption Standard) method is implemented and the case where both the DES method and the triple DES method are implemented. Therefore, each type of IC card needs to be customized according to the number of keys and the difference in supported algorithms.
However, with the advent of a common card OS, the program itself can be installed on any IC card, so we want to minimize customization. In summary, in the field of IC cards, when a program for one type is customized and a program for another type is created, there is a demand for reusing the program before customization as much as possible.
The present invention has been made in view of the above circumstances, and an object of the present invention is to provide an IC card and an IC card utilization device that can realize high reusability of programs even in different types of IC cards.
[0009]
[Means for Solving the Problems]
The invention corresponding to claim 1 is an IC card issued by an IC card using device for issuing a card,Parameter management means in which management parameters indicating the type and number of individual parameters are set when issuing a card;When issuing a cardBased on the management parametersA program comprising an individual parameter that can be set individually and an algorithm that describes the operation using the individual parameter. When a program execution request including an instruction for the individual parameter is received, the program is based on the designated individual parameter. And a program execution means for executing the program, wherein the individual parameter is set as the program execution means.before, For this individual parameterManagement parametersA memory amount calculating means for calculating the memory amount of the IC card necessary for storing the individual parameter, and a memory area is secured based on the calculation result of the memory amount calculating means.AfterAnd parameter setting means for holding individual parameters input from the IC card using device in the memory area.The memory amount calculation means is obtained by multiplying the “type” indicated by the management parameter by the byte length corresponding to the “type” and the “number” corresponding to the “type”. The memory amount is calculated by adding the multiplication results and the constant α to each other.IC card.
[0010]
An invention corresponding to claim 2 is an IC card corresponding to claim 1.,When the management parameter read request is input, the IC card includes parameter reading means for reading the management parameter in the parameter management means.
[0011]
Further, the invention corresponding to claim 3 is an IC card utilization apparatus for executing processing using the IC card corresponding to claim 2, and based on the management parameter read from the parameter reading means, the IC card This is an IC card utilization device provided with card access means for accessing the card.
[0012]
Furthermore, the invention corresponding to claim 4 is the card issuing IC card utilization apparatus for issuing the IC card corresponding to claim 2, and when issuing the IC card, the program execution means, the parameter management means And means for writing each program of the parameter reading means to the IC card before issuance, and means for inputting individual parameters to the IC card before issuance after activation of the written program execution means. IC card using device.
The invention corresponding to claim 5 has a program comprising an individual parameter that can be individually set at the time of card issuance and an algorithm in which an operation is described using the individual parameter, and includes an instruction for the individual parameter. When receiving an execution request, an IC card using device that executes processing using an IC card provided with program execution means for executing the program based on the instructed individual parameter, the individual parameterTheSettingYouRubefore, This individual parameterParameters indicating the type and number of itemsMemory amount calculation means for calculating the memory amount of the IC card necessary for storing the individual parameter based on the calculation result, and the calculation result of the memory amount calculation meansAnd a means for prompting the card issuer to confirm, a means for setting the management parameter in the parameter management means in the program when the management parameter is confirmed by the confirmation, and a management parameter in the parameter management means. The memory amount is calculated based on the calculation result, and the memory area is secured in the IC card based on the calculation result, and then the individual parameter input from the IC card using device can be stored in the memory area. After the memory area is secured in the IC card by the installed program and the installed program.Individual parametersIC cardIninputParameter setting meansThe memory amount calculation means is obtained by multiplying the “type” indicated by the management parameter by the byte length corresponding to the “type” and the “number” corresponding to the “type”. The memory amount is calculated by adding the multiplication results and the constant α to each other.IC card using device.
The invention corresponding to claim 6 is the IC card utilization apparatus according to claim 5, wherein the IC card is,When the management parameter read request is input, the IC card utilization apparatus includes parameter reading means for reading the management parameter in the parameter management means.
According to a seventh aspect of the present invention, there is provided an IC card utilization apparatus according to the sixth aspect, wherein the IC card use device comprises card access means for accessing the IC card based on the management parameter read from the parameter reading means. It is a card using device.
[0014]
(Function)
Accordingly, claim 1, 5In the invention corresponding to the above, the program execution means has a program comprising an individual parameter that can be set individually and an algorithm in which an operation is described using the individual parameter. When the program execution request including the instruction is received, the program is executed based on the instructed individual parameter.
[0015]
Thereby, when customizing a program of a certain type of IC card to a different type of IC card, the customization can be executed by changing the individual parameters without changing the algorithm. That is, when customizing, the algorithm part of the program can be reused. Therefore, high reusability of the program can be realized even with IC cards having different specifications.
In the invention corresponding to claims 1 and 5, the memory amount calculation means in the program execution means is set with individual parameters.before,The type and number of these individual parametersManagement parameter indicatingThe memory capacity of the IC card necessary for storing the individual parameter is calculated based on the parameter, and the parameter setting means in the program execution means secures a memory area based on the calculation result of the memory quantity calculation means.AfterSince the individual parameters input from the IC card using device are held in the memory area, in addition to the above-described operation, the efficiency of the work for examining the necessary memory amount can be improved during customization.
[0016]
Further, the invention corresponding to claims 2 and 6 is,When the parameter reading means receives a management parameter read request, the parameter reading means reads the management parameter in the parameter management means. Thus, in addition to the operation corresponding to claims 1 and 5, the card body from the outside according to the contents of the management parameter. The details of the function (such as the number of keys for the key management function) can be easily found.
[0017]
Furthermore, claim 3, 7The card access means accesses the IC card based on the management parameter read from the parameter reading means., 6In addition to the action corresponding to the above, unnecessary access can be eliminated by accessing the IC card only when there is a request for a function supported by the IC card (indicated by the management parameter).
[0018]
Claims4The corresponding invention isWhen an IC card using device for issuing a card issues an IC card, each program of the program execution means, parameter management means, and parameter reading means is written in the IC card before issuance, and the program execution means is activated. Thereafter, since the individual parameters are input to the IC card before issuance, the IC card corresponding to claim 2 can be issued.
[0019]
DETAILED DESCRIPTION OF THE INVENTION
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
(First embodiment)
FIG. 1 is a block diagram showing a configuration of an IC card and an IC card using apparatus according to the first embodiment of the present invention. The
[0020]
Here, the
[0021]
When using the card, the
[0022]
Specifically, when the
[0023]
The executed program is composed of an algorithm part unrelated to the type of the
[0024]
The
[0025]
On the other hand, the IC
[0026]
Here, the
[0027]
Note that the card access request is a concept including all requests accompanying access to the
[0028]
The card R /
[0029]
Next, operations of the IC card and the IC card using apparatus configured as described above will be described.
(When issuing a card)
First, when issuing a card, management parameters are specified by the card issuer. This management parameter is described in the
[0030]
Thereafter, the activated
[0031]
(When using a card)
Next, the operation when using this IC card will be described with reference to FIG.
When using the card, in the IC
[0032]
Subsequently, as shown in FIG. 2, the
[0033]
If the result of this determination is that execution is impossible, an error notification is returned to the application software unit and the processing is terminated. However, since it can be executed here, the
[0034]
In the
[0035]
The execution result is sent to an application software unit (not shown) via the card R /
[0036]
As described above, according to the present embodiment, the
[0037]
Thereby, when customizing a program of a certain type of IC card to a different type of IC card, the customization can be executed by changing the individual parameters without changing the algorithm. In other words, since the algorithm portion of the program can be reused during customization, the program can be customized with a minimum of change work. Therefore, high reusability of the program can be realized even with IC cards having different specifications.
[0038]
Further, when an individual parameter is set, the
[0039]
Further, a
[0040]
Further, since the
[0041]
(Second Embodiment)
3 and 4 are block diagrams showing the configuration of an IC card and an IC card using device according to the second embodiment of the present invention. The same elements are denoted by the same reference numerals and redundant description is omitted.
[0042]
In addition, this embodiment describes the effect similar to 1st Embodiment in detail.
Specifically, the card issuer IC card utilization device 30A includes a
[0043]
Further, the IC
[0044]
Here, the
[0045]
Specifically, the
[0046]
Note that the Java methods called by the
[0047]
Similarly, the
[0048]
Specifically, the
[0049]
As the Java method called by the
[0050]
The card
[0051]
Specifically, the card
[0052]
Note that the card
[0053]
The R /
[0054]
As described above, the card R /
[0055]
On the other hand, the
[0056]
The
[0057]
The
[0058]
The
[0059]
The encryption / key
[0060]
Specifically, the encryption / key
[0061]
The
[0062]
The triple
[0063]
Next, the operation of the IC card using apparatus and the IC card configured as described above will be described separately when the card is issued and when the card is used.
[0064]
(When issuing a card)
When issuing a card, the card issuer uses the IC card utilization device 30A shown in FIG. 1, and the
[0065]
Now, in the IC card utilization apparatus 30A, it is assumed that the
[0066]
When the
[0067]
M = 8D + 16T + α (1)
However, D: Number of DES keys, T: Number of triple DES keys, α: Constant.
The calculation of the necessary memory amount may be performed in a portion other than the
[0068]
When the specified contents are confirmed, the values (number of keys of each type) of the parameter management class constants (numOfDesKey and numOfDes3Key) are changed as shown in FIG. 16 by executing the card issuing application.
This completes customization of the encrypted applet.
[0069]
Next, the IC card utilization device 30A installs the
[0070]
That is, the encryption / key
[0071]
Subsequently, the memory amount necessary for storing the key is calculated by the above-described equation (1), and a storage area (a part of the key memory 48c) corresponding to the memory amount is secured (ST3).
Next, an area for storing the key type and the offset value (key offset (start address)) on the key memory 48c is secured (ST4), and the initialization process at the time of installing the applet is terminated.
[0072]
Next, the
[0073]
When the card
[0074]
The
[0075]
For example, in the case of the first key of the DES method, the head offset (head address) of the DES key is obtained. In the case of the DES No. 3 key, the key offset is calculated as the first offset + the predetermined byte length of the DES key × 3 (the first key). The predetermined byte length of the key is 8 bytes for the DES key and 16 bytes for the triple DES key.
[0076]
Further, after step ST12, the encryption / key
[0077]
Next, as shown in FIG. 19, the
[0078]
The key import process is executed by repeatedly calling the “key selection” and “key import” methods for the number of times corresponding to the designated key type and the number of keys.
[0079]
Next, the
[0080]
Upon receiving the “personalize” card command, the card
[0081]
Based on the “personalize” command in the
[0082]
Here, the
[0083]
Thereby, the personalization process of the
(When using a card)
When using the card, the IC
[0084]
Now, in the IC
[0085]
The encryption / key
[0086]
The option list in the
[0087]
Next, a key is selected as described above. The
[0088]
When the card encryption function module receives the card instruction of “select key”, it determines whether or not the key specified in the card instruction is used in the
[0089]
The encryption / key
[0090]
Next, the
[0091]
Upon receiving the “encryption” card command, the card
[0092]
The encryption / key
[0093]
Also, the encryption / key
[0094]
Also, the encryption / key
This encryption result is sent to the IC
[0095]
Thereby, the encryption process is completed.
Next, the decoding process will be described. In the
Therefore, the decryption process in the IC
[0096]
That is, in the IC
[0097]
As described above, according to the present embodiment, the following effects can be obtained in addition to the effects of the first embodiment.
[0098]
For example, since the upper-
[0099]
Further, as described above, when the program of the
[0100]
Further, since the change of the constant of the
[0101]
In addition to these, by creating the encryption / key
[0102]
In addition, with the configuration that supports only necessary commands in this manner, the configuration of the entire system including the
[0103]
The present invention can be implemented with various modifications without departing from the scope of the invention.
[0104]
【The invention's effect】
As described above, according to the present invention, it is possible to provide an IC card and an IC card utilization apparatus that can realize high reusability of programs even in different types of IC cards.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a configuration of an IC card and an IC card using apparatus according to a first embodiment of the present invention.
FIG. 2 is a schematic diagram for explaining a function of a card access unit in the embodiment;
FIG. 3 is a block diagram showing a configuration of an IC card and an IC card using apparatus according to a second embodiment of the present invention.
FIG. 4 is a block diagram showing a configuration of an IC card and an IC card using apparatus according to the embodiment.
FIG. 5 is a schematic diagram for explaining a card command and its return value in the embodiment;
FIG. 6 is a schematic diagram for explaining a card instruction and its return value in the embodiment;
FIG. 7 is a schematic diagram for explaining a card instruction and its return value in the embodiment;
FIG. 8 is a schematic diagram for explaining a card instruction and its return value in the embodiment;
FIG. 9 is a schematic diagram for explaining a card command and its return value in the embodiment;
FIG. 10 is a schematic diagram for explaining a card instruction and its return value in the embodiment;
FIG. 11 is a schematic diagram for explaining commands and responses in the embodiment;
FIG. 12 is a schematic diagram for explaining commands and responses in the embodiment;
FIG. 13 is a schematic diagram for explaining commands and responses in the embodiment;
FIG. 14 is a schematic diagram for explaining a command and its response in the embodiment;
FIG. 15 is a schematic diagram for explaining a command and its response in the embodiment;
FIG. 16 is a schematic diagram for explaining a parameter management class in the embodiment;
FIG. 17 is a flowchart for explaining initialization processing when an applet is installed in the embodiment;
FIG. 18 is a flowchart for explaining key selection processing in the embodiment;
FIG. 19 is a flowchart for explaining key import processing according to the embodiment;
FIG. 20 is a flowchart for explaining personalization processing in the embodiment;
FIG. 21 is a flowchart for explaining option list acquisition processing in the embodiment;
FIG. 22 is a flowchart for explaining encryption processing in the embodiment;
FIG. 23 is a flowchart for explaining decoding processing in the embodiment;
[Explanation of symbols]
10, 40 ... IC card
11 ... Parameter management section
12 ... Program execution part
13 ... Parameter reading section
20, 30A, 30B ... IC card utilization device
21 ... Card access section
22, 34 ... Card R / W section
31A ... Card issuing application
31B ... Application for file encryption
32 ... Card encryption function module
33 ... R / W driver section
41 ... Common card OS
42 ... Receive buffer
43 ... Transmission buffer
44 ... Encryption card applet
45 ... DES encryption device
46 ... Triple DES encryption device
47 ... Parameter management class
48 ... Encryption / key management applet class
48a ... User ID memory
48b ... Personalized state memory
48c ... Key memory
Claims (7)
カード発行の際に個別パラメータの種類及び個数を示す管理パラメータが設定されたパラメータ管理手段と、カード発行の際に前記管理パラメータに基づいて個別に設定可能な個別パラメータ及びこの個別パラメータを用いて動作が記述されたアルゴリズムからなるプログラムを有し、個別パラメータの指示を含むプログラム実行要求を受けたとき、この指示された個別パラメータに基づいて、前記プログラムを実行するプログラム実行手段を備えており、
前記プログラム実行手段は、
前記個別パラメータが設定される前に、この個別パラメータの管理パラメータに基づいて、当該個別パラメータの記憶に必要なICカードのメモリ量を算出するメモリ量算出手段と、
前記メモリ量算出手段の算出結果に基づいてメモリ領域を確保した後、前記ICカード利用装置から入力される個別パラメータを前記メモリ領域に保持するパラメータ設定手段と
を備えており、
前記メモリ量算出手段は、前記管理パラメータが示す「種類」毎に、当該「種類」に対応するバイト長と、当該「種類」に対応する「個数」とを乗算し、得られた各々の乗算結果及び定数αを互いに加算することにより、前記メモリ量を算出することを特徴とするICカード。An IC card issued by an IC card using device for issuing cards,
Parameter management means in which management parameters indicating the type and number of individual parameters are set at the time of card issuance, individual parameters that can be individually set based on the management parameters at the time of card issuance, and operation using these individual parameters And a program execution means for executing the program based on the instructed individual parameter when a program execution request including an instruction for the individual parameter is received.
The program execution means includes
Before setting the individual parameters, based on the management parameters of the individual parameters, a memory amount calculating means for calculating the memory amount of the IC card necessary for storing the individual parameters;
Parameter setting means for holding individual parameters input from the IC card using device in the memory area after securing the memory area based on the calculation result of the memory amount calculating means ;
For each “type” indicated by the management parameter, the memory amount calculation unit multiplies the byte length corresponding to the “type” by the “number” corresponding to the “type”, and obtains each multiplication obtained. An IC card , wherein the memory amount is calculated by adding a result and a constant α to each other .
前記管理パラメータの読出要求が入力されると、前記パラメータ管理手段内の管理パラメータを読出すパラメータ読出手段を備えたことを特徴とするICカード。In the IC card according to claim 1 ,
An IC card comprising parameter reading means for reading a management parameter in the parameter management means when a management parameter read request is inputted.
前記パラメータ読出手段から読出された管理パラメータに基づいて、前記ICカードへのアクセスを行なうカードアクセス手段を備えたことを特徴とするICカード利用装置。In the IC card utilization apparatus for executing processing using the IC card according to claim 2,
An IC card utilization apparatus comprising card access means for accessing the IC card based on management parameters read from the parameter reading means.
前記ICカードを発行する際に、前記プログラム実行手段、前記パラメータ管理手段及び前記パラメータ読出手段の各プログラムを当該発行する前のICカードに書き込む手段と、
前記書き込まれたプログラム実行手段の起動の後、前記発行する前のICカードに個別パラメータを入力する手段と
を備えたことを特徴とするICカード利用装置。In the IC card utilization apparatus for card issuance which issues the IC card according to claim 2,
Means for writing each program of the program execution means, the parameter management means and the parameter reading means to the IC card before issuance when issuing the IC card;
An IC card utilization device comprising: means for inputting individual parameters to the IC card before issuance after the written program execution means is activated.
前記個別パラメータを設定する前に、この個別パラメータの種類及び個数を示す管理パラメータに基づいて、当該個別パラメータの記憶に必要なICカードのメモリ量を算出するメモリ量算出手段と、
前記メモリ量算出手段の算出結果を表示し、カード発行者に確認を促す手段と、
前記確認により前記管理パラメータが確定すると、この管理パラメータを前記プログラム内のパラメータ管理手段に設定する手段と、
このパラメータ管理手段内の管理パラメータに基づいて前記メモリ量を算出してこの算 出結果に基づいてメモリ領域をICカード内に確保した後に前記ICカード利用装置から入力される個別パラメータを前記メモリ領域に保持可能な前記プログラムに関し、このプログラムを前記ICカードにインストールする手段と、
前記インストールされたプログラムにより前記メモリ領域がICカード内に確保された後、前記個別パラメータを前記ICカードに入力するパラメータ設定手段と
を備えており、
前記メモリ量算出手段は、前記管理パラメータが示す「種類」毎に、当該「種類」に対応するバイト長と、当該「種類」に対応する「個数」とを乗算し、得られた各々の乗算結果及び定数αを互いに加算することにより、前記メモリ量を算出することを特徴とするICカード利用装置。There is a program consisting of an individual parameter that can be set individually when issuing a card and an algorithm that describes the operation using this individual parameter. An IC card utilization device that executes processing using an IC card provided with program execution means for executing the program based on individual parameters,
Before you set the individual parameters, and this shows the type and number of the individual parameters based on the control parameters, the memory amount calculating means for calculating an amount of memory IC card required for storage of the individual parameters,
Means for displaying the calculation result of the memory amount calculating means and prompting the card issuer to confirm;
Means for setting the management parameter in the parameter management means in the program when the management parameter is confirmed by the confirmation;
The memory areas individual parameters input from the IC card utilization device after securing a memory area in the IC card on the basis to calculate the amount of memory on the basis of management parameters in this parameter in the management unit in the calculation out results Means for installing the program on the IC card;
After the memory area is secured in the IC card by the installed program, and a parameter setting means for inputting a pre-Symbol individual parameters in the IC card,
For each “type” indicated by the management parameter, the memory amount calculation unit multiplies the byte length corresponding to the “type” by the “number” corresponding to the “type”, and obtains each multiplication obtained. An IC card utilization apparatus , wherein the memory amount is calculated by adding a result and a constant α to each other .
前記ICカードは、
前記管理パラメータの読出要求が入力されると、前記パラメータ管理手段内の管理パラメータを読出すパラメータ読出手段を備えたことを特徴とするICカード利用装置。In the IC card utilization apparatus according to claim 5,
The IC card,
An IC card utilization apparatus comprising parameter reading means for reading a management parameter in the parameter management means when a management parameter read request is input.
前記パラメータ読出手段から読出された管理パラメータに基づいて、前記ICカードへのアクセスを行なうカードアクセス手段を備えたことを特徴とするICカード利用装置。In the IC card utilization apparatus according to claim 6,
An IC card utilization apparatus comprising card access means for accessing the IC card based on the management parameter read from the parameter reading means.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP16090399A JP3788886B2 (en) | 1999-06-08 | 1999-06-08 | IC card and IC card using device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP16090399A JP3788886B2 (en) | 1999-06-08 | 1999-06-08 | IC card and IC card using device |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2000348146A JP2000348146A (en) | 2000-12-15 |
JP3788886B2 true JP3788886B2 (en) | 2006-06-21 |
Family
ID=15724845
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP16090399A Expired - Fee Related JP3788886B2 (en) | 1999-06-08 | 1999-06-08 | IC card and IC card using device |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP3788886B2 (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP5795921B2 (en) | 2011-09-21 | 2015-10-14 | 株式会社東芝 | IC card, portable electronic device, and IC card control method |
-
1999
- 1999-06-08 JP JP16090399A patent/JP3788886B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2000348146A (en) | 2000-12-15 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4348190B2 (en) | Smart card system | |
US7797527B2 (en) | Computing device deployment using mass storage device | |
JP4308551B2 (en) | Memory card and host device | |
EP1084549B1 (en) | Method of controlling usage of software components | |
US5835760A (en) | Method and arrangement for providing BIOS to a host computer | |
TW318227B (en) | ||
US20060253620A1 (en) | Data structure of flash memory having system area with variable size in which data can be updated, USB memory device having the flash memory, and method of controlling the system area | |
US20030069999A1 (en) | Method for providing a single preloaded software image with an ability to support multiple hardware configurations and multiple types of computer systems | |
US20040230801A1 (en) | Data processing device and method and program of same | |
JP4742469B2 (en) | IC card, IC card processing apparatus and processing method using a plurality of OSs | |
US8006009B2 (en) | Methods and device for implementing multifunction peripheral devices with a single standard peripheral device driver | |
JP2003141460A (en) | Communication method, data processing device, and program | |
WO2022165771A1 (en) | Virtual electronic card management method and system, security chip, terminal, and storage medium | |
CN107798256B (en) | Smart card based on cryptographic algorithm separation storage and design method | |
JP3788886B2 (en) | IC card and IC card using device | |
JP4236830B2 (en) | Storage device with upload function | |
JP2004054502A (en) | Information terminal device, program for purchasing additional function, and method for adding program function | |
JP2004112510A (en) | Data processing apparatus, program thereof, and apparatus thereof | |
JP4765174B2 (en) | Application execution apparatus, communication system, and application execution method | |
JP4670158B2 (en) | Data processing method and semiconductor circuit | |
JP4881742B2 (en) | Method of writing data and application to identification media | |
JP4207409B2 (en) | Data processing apparatus and method | |
JP2004220328A (en) | Ap addition/ap personalization method, execution device therefor and processing program therefor | |
JPH07296124A (en) | Ic card applying device | |
JP2006236376A (en) | Ic card usage device, ic card, and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20050316 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20050322 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20050523 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20050802 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20050929 |
|
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: 20060322 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20060324 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20090407 Year of fee payment: 3 |
|
S111 | Request for change of ownership or part of ownership |
Free format text: JAPANESE INTERMEDIATE CODE: R313111 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20090407 Year of fee payment: 3 |
|
R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20090407 Year of fee payment: 3 |
|
S111 | Request for change of ownership or part of ownership |
Free format text: JAPANESE INTERMEDIATE CODE: R313114 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20090407 Year of fee payment: 3 |
|
R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20090407 Year of fee payment: 3 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20090407 Year of fee payment: 3 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20100407 Year of fee payment: 4 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20100407 Year of fee payment: 4 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20100407 Year of fee payment: 4 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20100407 Year of fee payment: 4 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20110407 Year of fee payment: 5 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20130407 Year of fee payment: 7 |
|
LAPS | Cancellation because of no payment of annual fees |