JP3688971B2 - Electronic equipment - Google Patents
Electronic equipment Download PDFInfo
- Publication number
- JP3688971B2 JP3688971B2 JP2000108100A JP2000108100A JP3688971B2 JP 3688971 B2 JP3688971 B2 JP 3688971B2 JP 2000108100 A JP2000108100 A JP 2000108100A JP 2000108100 A JP2000108100 A JP 2000108100A JP 3688971 B2 JP3688971 B2 JP 3688971B2
- Authority
- JP
- Japan
- Prior art keywords
- information
- output
- application
- command
- determination
- 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
Links
Images
Description
【0001】
【発明の属する技術分野】
本発明は、たとえば、書換え可能な不揮発性メモリおよびCPUなどの制御素子を有し、外部からのデータの入出力を行なう手段を備えたIC(集積回路)チップを内蔵した、いわゆるICカードと称される電子装置に関する。
【0002】
【従来の技術】
近年、新たな携帯可能なデータ記憶媒体として、書換え可能な不揮発性メモリおよびCPUなどの制御素子を有し、外部からのデータの入出力を行なう手段を備えたICチップを内蔵した、いわゆるICカードが開発されている。
【0003】
一般に、この種のICカードは、受信したコマンドに対するステータスワード(SW)を決められた処理を行なった結果として出力する。すなわち、外部から入力されるコマンドを受信すると、この受信したコマンドに対する処理を行ない、その処理結果としてステータスワードを外部へ出力する。たとえば、キー照合コマンドにおいて、照合不一致であった場合、「6300(照合不一致)」などのステータスワードを出力していた。
【0004】
【発明が解決しようとする課題】
しかしながら、上述した従来技術の場合、コマンドコードの規格で決まっているCLAバイトあるいはINSバイトをランダムにアタックしていくと、CLA=00、INS=20において、ステータスワードとして「6300」が出力され、キー照合コマンドが存在することがわかってしまい、セキュリティ性に劣るという大きな問題があった。
【0005】
特に、金融決済を行なうアプリケーションなど、高いセキュリティを必要とするアプリケーションにおいて問題となる。
【0006】
そこで、本発明は、コマンドのランダムアタックに対しても高いセキュリティが得られる電子装置を提供することを目的とする。
【0007】
【課題を解決するための手段】
本発明の電子装置は、複数のアプリケーションを登録でき、登録された各アプリケーションにおいて、外部から入力されたコマンドを受信すると、この受信したコマンドに対する処理を行ない、その処理結果を示す情報を外部へ出力する電子装置において、前記アプリケーションに応じて受信したコマンドに対する処理結果を示す第1の情報を出力するか、あるいは処理結果とは異なる内容を示す第2の情報を出力するかを判定するための判定情報を記憶している記憶手段と、受信したコマンドに対する処理を行なった際、前記記憶手段の記憶内容に基づいて前記第1の情報を出力するか、あるいは前記第2の情報を出力するかを判定する判定手段と、この判定手段の判定結果に基づき前記第1の情報あるいは前記第2の情報を選択的に出力する出力手段とを具備している。
【0008】
また、本発明の電子装置は、複数のアプリケーションを登録でき、登録された各アプリケーションにおいて、外部から入力されたコマンドを受信すると、この受信したコマンドに対する処理を行ない、その処理結果を示す情報を外部へ出力する電子装置において、前記アプリケーションに応じて受信したコマンドに対する処理結果を示す第1の情報を出力するか、あるいは処理結果とは異なる内容を示す第2の情報を出力するかを判定するための判定情報を記憶している記憶手段と、受信したコマンドに対する処理を行なった際、その処理が正常に終了しなかった場合、前記記憶手段の記憶内容に基づいて前記第1の情報を出力するか、あるいは前記第2の情報を出力するかを判定する判定手段と、この判定手段の判定結果に基づき前記第1の情報あるいは前記第2の情報を選択的に出力する出力手段とを具備している。
【0009】
また、本発明の電子装置は、複数のアプリケーションを登録でき、登録された各アプリケーションにおいて、外部から入力されたコマンドを受信すると、この受信したコマンドに対する処理を行ない、その処理結果を示す情報を外部へ出力する電子装置において、前記アプリケーションに応じて受信したコマンドに対する処理結果を示す第1の情報を出力するか、あるいは処理結果とは異なる内容を示す第2の情報を出力するかを判定するための判定情報を記憶している記憶手段と、受信したコマンドに対する処理を行なった際、その処理が正常に終了した場合、前記記憶手段の記憶内容に基づいて前記第1の情報を出力するか、あるいは前記第2の情報を出力するかを判定する判定手段と、この判定手段の判定結果に基づき前記第1の情報あるいは前記第2の情報を選択的に出力する出力手段とを具備している。
【0010】
また、本発明の電子装置は、複数のアプリケーションを登録でき、登録された各アプリケーションにおいて、外部から入力されたコマンドを受信すると、この受信したコマンドに対する処理を行ない、その処理結果を示す情報を外部へ出力する電子装置において、前記アプリケーションに応じて受信したコマンドに対する処理結果を示す第1の情報を出力するか、あるいは処理結果とは異なる内容を示す第2の情報を出力するかを記憶する記憶手段と、受信したコマンドに対する処理を行なった際、その処理が正常に終了しなかった場合、現在選択されているアプリケーションがあらかじめ設定された特定のアプリケーションであるか否かを判定する判定手段と、この判定手段により現在選択されているアプリケーションが特定のアプリケーションではないと判定された場合は前記記憶手段の記憶内容に基づいて前記第1の情報を外部へ出力し、前記判定手段により現在選択されているアプリケーションが特定のアプリケーションであると判定された場合は前記記憶手段の記憶内容に基づいて前記第2の情報を外部へ出力する出力手段とを具備している。
【0011】
また、本発明の電子装置は、外部から入力されるコマンドを受信すると、この受信したコマンドに対する処理を行ない、その処理結果を示す情報を外部へ出力する電子装置において、受信したコマンドに対する処理結果を示す第1の情報を出力するか、あるいは処理結果とは異なる内容を示す第2の情報を出力するかを判断するための判断情報を記憶している第1の記憶手段と、前記第1の情報を出力するかあるいは前記第2の情報を出力するかをコマンドごとに指定する指定情報を記憶している第2の記憶手段と、受信したコマンドに対する処理を行なった際、前記第2の記憶手段内の指定情報を参照することにより前記第1の情報を出力するかあるいは前記第2の情報を出力するかを判断する第1の判断手段と、この第1の判断手段により第2の情報を出力すると判断された場合、前記第1の記憶手段内の判断情報を参照することにより前記第1の情報を出力するかあるいは前記第2の情報を出力するかを判断する第2の判断手段と、前記第1の判断手段により第1の情報を出力すると判断された場合、あるいは前記第2の判断手段により第1の情報を出力すると判断された場合は前記第1の情報を外部へ出力し、前記第2の判断手段により第2の情報を出力すると判断された場合は前記第2の情報を外部へ出力する出力手段とを具備している。
【0012】
さらに、本発明の電子装置は、複数のアプリケーションを登録でき、登録された各アプリケーションにおいて、外部から入力されたコマンドを受信すると、この受信したコマンドに対する処理を行ない、その処理結果を示す情報を外部へ出力する電子装置において、選択されたアプリケーションが発行された状態になっているか否かを識別するための発行識別情報を記憶している第1の記憶手段と、現在選択されているアプリケーションの種類を示す種類識別情報を記憶している第2の記憶手段と、受信したコマンドに対する処理を行なった際、その処理が正常に終了しなかった場合、前記第2の記憶手段内の種類識別情報を参照することにより現在選択されているアプリケーションがあらかじめ設定された特定のアプリケーションであるか否かを判定する第1の判定手段と、この第1の判定手段により現在選択されているアプリケーションが特定のアプリケーションであると判定された場合、前記第1の記憶手段内の発行識別情報を参照することにより現在選択されている特定のアプリケーションが発行済みであるか否かを判定する第2の判定手段と、前記第1の判定手段により現在選択されているアプリケーションが特定のアプリケーションではないと判定された場合、あるいは前記第2の判定手段により現在選択されている特定のアプリケーションが発行済みでないと判定された場合は受信したコマンドに対する処理結果を示す第1の情報を出力し、前記第2の判定手段により現在選択されている特定のアプリケーションが発行済みであると判定された場合は処理結果とは異なる内容を示す第2の情報を出力する出力手段とを具備している。
【0015】
【発明の実施の形態】
以下、本発明の実施の形態について図面を参照して説明する。
【0016】
図1は、本発明の実施の形態に係る携帯可能電子装置としてのICカードを取扱う端末装置の構成例を示すものである。すなわち、この端末装置は、ICカード1をカードリーダ・ライタ2を介してCPUなどからなる制御部3と接続可能にするとともに、制御部3にキーボード4、CRTディスプレイ装置5、および、プリンタ6を接続して構成される。
【0017】
ICカード1は、複数のアプリケーションが登録可能であり、たとえば、図2に示すように、CPUなどの制御素子(制御部)11、メモリ(記憶手段)としてのデータメモリ12、ワーキングメモリ13、プログラムメモリ14、および、カードリーダ・ライタ2との電気的接触を得るためのコンタクト部15によって構成されていて、これらのうち、制御素子11、データメモリ12、ワーキングメモリ13、および、プログラムメモリ14は1つのICチップ(あるいは複数のICチップ)16で構成されている。そして、ICチップ16とコンタクト部15とが一体的にICモジュール化されて、ICカ―ド本体内に埋設されている。
【0018】
データメモリ12は、各種データの記憶に使用され、たとえば、EEPROMなどの書換え可能な不揮発性メモリで構成されている。
【0019】
ワーキングメモリ13は、制御素子11が処理を行なう際の処理データなどを一時的に保持するためのメモリであり、たとえば、RAMなどで構成される。
【0020】
プログラムメモリ14は、たとえば、マスクROMで構成されており、制御素子11の制御プログラムなどを記憶するものである。
【0021】
図3は、データメモリ12の一部分を示しており、状態設定フラグ21、キーデータ22、および、アプリケーション発行情報23がそれぞれ格納されている。状態設定フラグ21は、どちらのステータスワードを出力するか、すなわち、通常のステータスワード(処理内容を示す正規のステータスワード)を出力するか、あるいは、正規のステータスワードと異なる内容を示す特定のステータスワードを出力するかを識別するためのものであり、フラグ設定コマンドにより設定される。
【0022】
ここに、上記特定のステータスワードとは、該当コマンドをサポートしていないことを示す正規のステータスワードと異なる内容を示すステータスワードであり、たとえば、キー照合コマンドに対するステータスワードは、「6D00(INS未サポート)」という特定のステータスワードとして出力する。
【0023】
キーデータ22は、状態設定フラグ21を設定するフラグ設定コマンドのアクセス権を確立するために使用されるもので、照合キーデータあるいは認証キーデータが設定される。
【0024】
アプリケーション発行情報23は、アプリケーションが既に発行済みであることを示すもので、セキュリティが高いアプリケーションが発行されたとき発行済みに設定される。
【0025】
図4は、ワーキングメモリ13の一部分を示しており、アクセス条件フラグ31およびアプリケーション識別情報32がそれぞれ格納されている。アクセス条件フラグ31は、アクセス権が確立されたことを示すフラグであり、キーデータ22の照合あるいは認証の結果によって設定される。アプリケーション識別情報32は、現在、選択されているアプリケーションの種類を示すものである。
【0026】
図5は、プログラムメモリ14の一部分を示しており、通常のステータスワードを出力するかあるいは特定のステータスワードを出力するかをコマンドごとに指定することができるコマンドサーチテーブル41が格納されている。コマンドサーチテーブル41は、当該ICカードがサポートしているコマンドごとに、CLA、INS、アクセス条件情報、コマンドのフォーマット情報、どちらのステータスワードを出力するかを指定するSW情報などが登録されている。
【0027】
図6は、状態設定フラグ21を設定するフラグ設定コマンドのフォーマット例を示しており、コマンドヘッダ51およびフラグ情報52から構成されている。
【0028】
図7は、キー照合コマンドのフォーマット例を示しており、コマンドヘッダ61およびキー値62から構成されている。
【0029】
次に、特定のステータスワードを出力するコマンドの処理について、図8に示すフローチャートを参照して説明する。カードリーダ・ライタ2から送られるコマンドを受信すると、ステップS1に進む。ステップS1では、受信したコマンドがコマンドサーチテーブル41に登録されているかどうかチェックする。
【0030】
このチェックの結果、コマンドサーチテーブル41に登録されている場合、ステップS2に進む。ステップS2では、アクセス条件フラグ31を参照することにより、アクセス権が確立されているかどうかチェックする。このチェックの結果、アクセス権が確立されている場合、ステップS3に進む。ステップS3では、コマンドサーチテーブル41内のフォーマット情報を参照することにより、受信したコマンドが適切なフォーマットになっているかどうかチェックする。
【0031】
このチェックの結果、適切なフォーマットになっている場合、ステップS4に進む。ステップS4では、受信したコマンドに対する処理を行なう。次に、ステップS5では、ステップS4の処理が正常に終了したかどうかチェックする。このチェックの結果、処理が正常に終了した場合、ステップS6に進む。ステップS6では、正常終了ステータスワードをカードリーダ・ライタ2へ出力し、コマンド待ち状態になる。
【0032】
ステップS1にてコマンドサーチテーブル41に登録されていない場合、ステップS2にてアクセス権が確立されていない場合、ステップS3にて適切なフォーマットになっていない場合、あるいは、ステップS5にて処理が正常に終了していない場合、ステップS7に進む。ステップS7では、コマンドサーチテーブル41内のSW情報を参照することにより、特定のステータスワードを出力するのか、通常のステータスワードを出力するのかをチェックする。すなわち、受信したコマンドがあらかじめ定められた特定のコマンド(たとえば、キー照合コマンドなど)であるかどうかチェックするものである。
【0033】
このチェックの結果、特定のステータスワードを出力する場合(受信したコマンドが特定のコマンドである場合)、ステップS8に進む。ステップS8では、状態設定フラグ21を参照することにより、状態設定フラグ21が特定のステータスワードを出力するよう設定されているか、通常のステータスワードを出力するよう設定されているかをチェックする。このチェックの結果、状態設定フラグ21が特定のステータスワードを出力するよう設定されている場合、ステップS9に進む。ステップS9では、特定のステータスワード(特定エラーステータス)をカードリーダ・ライタ2へ出力し、コマンド待ち状態になる。
【0034】
ステップS7にて通常のステータスワードを出力する場合(受信したコマンドが特定のコマンドでない場合)、あるいは、ステップS8にて状態設定フラグ21が通常のステータスワードを出力するよう設定されている場合、ステップS10に進む。ステップS10では、通常のステータスワード(通常エラーステータス)を出力し、コマンド待ち状態になる。
【0035】
このように、受信したコマンドに対する処理を行なった上、その処理が正常に終了しなかった場合、コマンドサーチテーブル41を参照することにより、特定のステータスワードを出力するのか通常のステータスワードを出力するのかをチェックし、特定のステータスワードを出力する場合、状態設定フラグ21が特定のステータスワードを出力するよう設定されているか通常のステータスワードを出力するよう設定されているかをチェックし、状態設定フラグ21が特定のステータスワードを出力するよう設定されている場合、特定のステータスワードを出力する。上記チェックで、通常のステータスワードを出力する場合、あるいは、状態設定フラグ21が通常のステータスワードを出力するよう設定されている場合、通常のステータスワードを出力するものである。
【0036】
次に、処理が正常に終了したときにも特定のステータスワードを出力するコマンドの処理について、図9に示すフローチャートを参照して説明する。なお、図8と同一のステップには同一の符号を付して説明を省略し、異なる部分についてだけ説明する。
【0037】
ステップS5において、処理が正常に終了した場合、ステップS11に進む。ステップS11では、コマンドサーチテーブル41内のSW情報を参照することにより、特定のステータスワードを出力するのか、通常のステータスワードを出力するのかをチェックする。すなわち、受信したコマンドがあらかじめ定められた特定のコマンド(たとえば、キー照合コマンドなど)であるかどうかチェックするものである。
【0038】
このチェックの結果、特定のステータスワードを出力する場合(受信したコマンドが特定のコマンドである場合)、ステップS12に進む。ステップS12では、状態設定フラグ21を参照することにより、状態設定フラグ21が特定のステータスワードを出力するよう設定されているか、通常のステータスワードを出力するよう設定されているかをチェックする。このチェックの結果、状態設定フラグ21が特定のステータスワードを出力するよう設定されている場合、ステップS13に進む。ステップS13では、特定のステータスワード(特定エラーステータス)をカードリーダ・ライタ2へ出力し、コマンド待ち状態になる。
【0039】
ステップS11にて通常のステータスワードを出力する場合(受信したコマンドが特定のコマンドでない場合)、あるいは、ステップS12にて状態設定フラグ21が通常のステータスワードを出力するよう設定されている場合、ステップS6に進む。ステップS6では、正常終了ステータスワードをカードリーダ・ライタ2へ出力し、コマンド待ち状態になる。
【0040】
このように、処理が正常に終了した場合にも、処理が正常に終了しなかった場合と同様な処理を行なうものである。
【0041】
次に、特定のアプリケーションで特定のステータスワードを出力するコマンドの処理について、図10に示すフローチャートを参照して説明する。なお、図8と同一のステップには同一の符号を付して説明を省略し、異なる部分についてだけ説明する。
【0042】
ステップS1にてコマンドサーチテーブル41に登録されていない場合、ステップS2にてアクセス権が確立されていない場合、ステップS3にて適切なフォーマットになっていない場合、あるいは、ステップS5にて処理が正常に終了していない場合、ステップS14に進む。ステップS14では、アプリケーション識別情報32を参照することにより、現在選択されているアプリケーションがあらかじめ定められた特定のアプリケーション(たとえば、高いセキュリティを必要とするアプリケーション)であるかどうかチェックする。
【0043】
このチェックの結果、特定のアプリケーションが選択されている場合、ステップS15に進む。ステップS15では、アプリケーション発行情報23を参照することにより、発行済み状態に設定されているかをチェックする。このチェックの結果、アプリケーション発行情報23が発行済み状態に設定されている場合、ステップS9に進む。ステップS9では、特定のステータスワードを出力し、コマンド待ち状態になる。
【0044】
ステップS14にて特定のアプリケーションが選択されていない場合、あるいは、ステップS15にてアプリケーション発行情報23が発行済み状態に設定されていない場合、ステップS10に進む。ステップS10では、通常のステータスワードを出力し、コマンド待ち状態になる。
【0045】
このように、受信したコマンドに対する処理を行なった上、その処理が正常に終了しなかった場合、アプリケーション識別情報32を参照することにより、特定のアプリケーションが選択されているかどうかチェックし、特定のアプリケーションが選択されている場合、アプリケーション発行情報23を参照することにより、発行済み状態に設定されているかどうかチェックし、発行済み状態に設定されている場合、特定のステータスワードを出力する。上記チェックで、特定のアプリケーションが選択されていない場合、あるいは、アプリケーション発行情報23が発行済み状態に設定されていない場合、通常のステータスワードを出力するものである。
【0046】
次に、特定のアプリケーションで処理が正常に終了したときにも特定のステータスワードを出力するコマンドの処理について、図11に示すフローチャートを参照して説明する。なお、図10と同一のステップには同一の符号を付して説明を省略し、異なる部分についてだけ説明する。
【0047】
ステップS5において、処理が正常に終了した場合、ステップS16に進む。ステップS16では、アプリケーション識別情報32を参照することにより、現在選択されているアプリケーションがあらかじめ定められた特定のアプリケーション(たとえば、高いセキュリティを必要とするアプリケーション)であるかどうかチェックする。
【0048】
このチェックの結果、特定のアプリケーションが選択されている場合、ステップS17に進む。ステップS17では、アプリケーション発行情報23を参照することにより、発行済み状態に設定されているかをチェックする。このチェックの結果、アプリケーション発行情報23が発行済み状態に設定されている場合、ステップS18に進む。ステップS18では、特定のステータスワード(特定エラーステータス)をカードリーダ・ライタ2へ出力し、コマンド待ち状態になる。
【0049】
ステップS16にて特定のアプリケーションが選択されていない場合、あるいは、ステップS17にてアプリケーション発行情報23が発行済み状態に設定されていない場合、ステップS6に進む。ステップS6では、正常終了ステータスワードを出力し、コマンド待ち状態になる。
【0050】
このように、特定のアプリケーションで処理が正常に終了した場合にも、処理が正常に終了しなかった場合と同様な処理を行なうものである。
【0051】
【発明の効果】
以上詳述したように本発明によれば、受信したコマンドに対する処理を行なった際、処理内容を示す正規のステータスワードを出力するかあるいはその正規のステータスワードと異なる内容を示す特定のステータスワードを出力するかを識別し、この識別結果に基づき正規のステータスワードあるいは特定のステータスワードを選択的に出力することにより、コマンドのランダムアタックに対しても高いセキュリティが得られる電子装置を提供できる。
【図面の簡単な説明】
【図1】本発明の実施の形態に係る携帯可能電子装置としてのICカードを取扱う端末装置の構成を示すブロック図。
【図2】ICカードの構成を概略的に示すブロック図。
【図3】データメモリの一部分を示す模式図。
【図4】ワーキングメモリの一部分を示す模式図。
【図5】プログラムメモリの一部分を示す模式図。
【図6】フラグ設定コマンドのフォーマットを示す模式図。
【図7】キー照合コマンドのフォーマットを示す模式図。
【図8】特定のステータスワードを出力するコマンドの処理について説明するフローチャート。
【図9】処理が正常に終了したときにも特定のステータスワードを出力するコマンドの処理について説明するフローチャート。
【図10】特定のアプリケーションで特定のステータスワードを出力するコマンドの処理について説明するフローチャート。
【図11】特定のアプリケーションで処理が正常に終了したときにも特定のステータスワードを出力するコマンドの処理について説明するフローチャート。
【符号の説明】
1……ICカード(携帯可能電子装置)
2……カードリーダ・ライタ(外部装置)
11……制御素子
12……データメモリ
13……ワーキングメモリ
14……プログラムメモリ
15……コンタクト部
21……状態設定フラグ
22……キーデータ
23……アプリケーション発行情報
31……アクセス条件フラグ
32……アプリケーション識別情報
41……コマンドサーチテーブル(記憶手段)[0001]
BACKGROUND OF THE INVENTION
The present invention is referred to as a so-called IC card that has a control element such as a rewritable nonvolatile memory and a CPU and has an IC (integrated circuit) chip provided with means for inputting / outputting data from the outside. The electronic device to be used .
[0002]
[Prior art]
In recent years, as a new portable data storage medium, a so-called IC card having a built-in IC chip having a rewritable nonvolatile memory and a control element such as a CPU and having means for inputting and outputting data from the outside. Has been developed.
[0003]
In general, this type of IC card outputs a status word (SW) for a received command as a result of a predetermined process. That is, when a command input from the outside is received, the received command is processed, and a status word is output to the outside as the processing result. For example, in the key collation command, if the collation does not match, a status word such as “6300 (collation mismatch)” is output.
[0004]
[Problems to be solved by the invention]
However, in the case of the above-described prior art, when a CLA byte or INS byte determined by the command code standard is randomly attacked, “6300” is output as a status word at CLA = 00 and INS = 20, It was found that there was a key matching command, and there was a big problem that it was inferior in security.
[0005]
This is particularly a problem in applications that require high security, such as applications that make financial settlements.
[0006]
SUMMARY An advantage of some aspects of the invention is that it provides an electronic device that can obtain high security against a random attack of a command.
[0007]
[Means for Solving the Problems]
The electronic device of the present invention can register a plurality of applications. When each registered application receives a command input from the outside, the electronic device performs processing on the received command and outputs information indicating the processing result to the outside. A determination for determining whether to output first information indicating a processing result for a command received according to the application or to output second information indicating a content different from the processing result Whether to output the first information or the second information based on the storage contents of the storage means when processing the received command and the storage means storing the information A determination means for determining and selectively outputting the first information or the second information based on the determination result of the determination means And and an output means that.
[0008]
The electronic device of the present invention can register a plurality of applications. When each registered application receives a command input from the outside, the electronic device performs processing on the received command and sends information indicating the processing result to the outside. In order to determine whether to output first information indicating a processing result for a command received according to the application or to output second information indicating a content different from the processing result a storage means for storing determination information of, when performing processing for the received command, if the processing is not completed normally, and outputs the first information based on the stored contents of said memory means Or a determination means for determining whether to output the second information, and the first information based on a determination result of the determination means. Information or are provided with an output means for selectively outputting the second information.
[0009]
The electronic device of the present invention can register a plurality of applications. When each registered application receives a command input from the outside, the electronic device performs processing on the received command and sends information indicating the processing result to the outside. In order to determine whether to output first information indicating a processing result for a command received according to the application or to output second information indicating a content different from the processing result a storage means for storing determination information of, when performing processing for the received command, if the process was successful, whether to output the first information based on the stored contents of the storage means, Alternatively, a determination unit that determines whether to output the second information, and the first information based on a determination result of the determination unit Rui is and an output means for outputting the second information selectively.
[0010]
The electronic device of the present invention can register a plurality of applications. When each registered application receives a command input from the outside, the electronic device performs processing on the received command and sends information indicating the processing result to the outside. A memory for storing whether to output first information indicating a processing result for a command received according to the application or to output second information indicating a content different from the processing result A means for determining whether or not the currently selected application is a specific application set in advance when the process for the received command is not normally completed when the process is performed; The application currently selected by this determination means is a specific application. If it is determined that it is not an application, the first information is output to the outside based on the stored contents of the storage means, and the determination means determines that the currently selected application is a specific application In some cases, the information processing apparatus includes output means for outputting the second information to the outside based on the stored contents of the storage means.
[0011]
In addition, when the electronic device of the present invention receives a command input from the outside, the electronic device performs processing on the received command and outputs the processing result for the received command in the electronic device that outputs information indicating the processing result to the outside. First storage means for storing determination information for determining whether to output first information to be displayed or to output second information having a content different from the processing result; and Second storage means for storing designation information for designating whether to output information or the second information for each command; and when the received command is processed, the second storage A first judging means for judging whether to output the first information or the second information by referring to the designation information in the means, and the first judging means. When it is determined that the second information is output, the first information is output by referring to the determination information in the first storage means to determine whether to output the first information or the second information. When the first information is output by the second determination means and the first determination means, or when the first information is determined to be output by the second determination means, the first information is output. Is output to the outside, and when it is determined that the second information is output by the second determining means, the second information is output to the outside.
[0012]
Furthermore, the electronic device of the present invention can register a plurality of applications. When each registered application receives a command input from the outside, the electronic device performs processing on the received command and sends information indicating the processing result to the outside. In the electronic device to output to, the first storage means for storing issuance identification information for identifying whether or not the selected application has been issued, and the type of the currently selected application When the processing for the received command and the second storage means for storing the type identification information indicating, and the processing did not end normally, the type identification information in the second storage means is Whether the application currently selected by browsing is a specific application set in advance When it is determined by the first determination means that the application currently selected by the first determination means is a specific application, the issue identification information in the first storage means is referred to. Accordingly, it is determined by the second determination means for determining whether or not the specific application currently selected has been issued, and the application currently selected by the first determination means is not a specific application. Or when the second determination means determines that the currently selected specific application has not been issued, the first information indicating the processing result for the received command is output, and the second determination If it is determined by the means that the specific application currently selected has been issued, the processing result will differ. And and an output means for outputting the second information indicating that content.
[0015]
DETAILED DESCRIPTION OF THE INVENTION
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
[0016]
FIG. 1 shows a configuration example of a terminal device that handles an IC card as a portable electronic device according to an embodiment of the present invention. That is, this terminal device enables the
[0017]
The
[0018]
The
[0019]
The working
[0020]
The
[0021]
FIG. 3 shows a part of the
[0022]
Here, the specific status word is a status word indicating contents different from a regular status word indicating that the corresponding command is not supported. For example, the status word for the key collation command is “6D00 (INS not yet). Support) ”as a specific status word.
[0023]
The
[0024]
The
[0025]
FIG. 4 shows a part of the working
[0026]
FIG. 5 shows a part of the
[0027]
FIG. 6 shows a format example of a flag setting command for setting the
[0028]
FIG. 7 shows a format example of the key collation command, which is composed of a
[0029]
Next, processing of a command for outputting a specific status word will be described with reference to the flowchart shown in FIG. When a command sent from the card reader /
[0030]
As a result of this check, if it is registered in the command search table 41, the process proceeds to step S2. In step S2, it is checked whether the access right is established by referring to the
[0031]
If it is determined that the format is appropriate, the process proceeds to step S4. In step S4, the received command is processed. Next, in step S5, it is checked whether or not the process of step S4 has been completed normally. As a result of this check, if the processing is completed normally, the process proceeds to step S6. In step S6, a normal completion status word is output to the card reader /
[0032]
If it is not registered in the command search table 41 in step S1, the access right is not established in step S2, the format is not appropriate in step S3, or the process is normal in step S5. If not, the process proceeds to step S7. In step S7, by referring to the SW information in the command search table 41, it is checked whether to output a specific status word or a normal status word. That is, it is checked whether the received command is a predetermined specific command (for example, a key collation command).
[0033]
As a result of this check, when a specific status word is output (when the received command is a specific command), the process proceeds to step S8. In step S8, by referring to the
[0034]
When a normal status word is output in step S7 (when the received command is not a specific command), or when the
[0035]
As described above, when the received command is processed and the process is not completed normally, the command search table 41 is referred to output a specific status word or a normal status word. When a specific status word is output, it is checked whether the
[0036]
Next, processing of a command that outputs a specific status word even when the processing ends normally will be described with reference to a flowchart shown in FIG. Note that the same steps as those in FIG. 8 are denoted by the same reference numerals, description thereof is omitted, and only different portions will be described.
[0037]
If the process ends normally in step S5, the process proceeds to step S11. In step S11, by referring to the SW information in the command search table 41, it is checked whether to output a specific status word or a normal status word. That is, it is checked whether the received command is a predetermined specific command (for example, a key collation command).
[0038]
If a specific status word is output as a result of this check (if the received command is a specific command), the process proceeds to step S12. In step S12, by referring to the
[0039]
When a normal status word is output in step S11 (when the received command is not a specific command), or when the
[0040]
As described above, even when the process ends normally, the same process as that when the process does not end normally is performed.
[0041]
Next, processing of a command for outputting a specific status word by a specific application will be described with reference to a flowchart shown in FIG. Note that the same steps as those in FIG. 8 are denoted by the same reference numerals, description thereof is omitted, and only different portions will be described.
[0042]
If it is not registered in the command search table 41 in step S1, the access right is not established in step S2, the format is not appropriate in step S3, or the process is normal in step S5. If not, the process proceeds to step S14. In step S14, it is checked whether or not the currently selected application is a predetermined specific application (for example, an application requiring high security) by referring to the
[0043]
As a result of the check, if a specific application is selected, the process proceeds to step S15. In step S15, by referring to the
[0044]
If a specific application is not selected in step S14, or if the
[0045]
As described above, when the process for the received command is performed and the process does not end normally, it is checked whether or not a specific application is selected by referring to the
[0046]
Next, processing of a command that outputs a specific status word even when processing is normally completed in a specific application will be described with reference to a flowchart shown in FIG. Note that the same steps as those in FIG. 10 are denoted by the same reference numerals, description thereof is omitted, and only different portions will be described.
[0047]
If the process ends normally in step S5, the process proceeds to step S16. In step S16, it is checked whether or not the currently selected application is a predetermined specific application (for example, an application requiring high security) by referring to the
[0048]
As a result of the check, if a specific application is selected, the process proceeds to step S17. In step S17, by referring to the
[0049]
If a specific application is not selected in step S16, or if the
[0050]
As described above, even when the process is normally completed in a specific application, the same process as that when the process is not normally completed is performed.
[0051]
【The invention's effect】
As described above in detail, according to the present invention, when processing for a received command is performed, a normal status word indicating the processing content is output or a specific status word indicating content different from the normal status word is output. By discriminating whether to output and selectively outputting a regular status word or a specific status word based on the identification result, an electronic device can be provided that can obtain high security against a random attack of a command.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a configuration of a terminal device that handles an IC card as a portable electronic device according to an embodiment of the present invention.
FIG. 2 is a block diagram schematically showing the configuration of an IC card.
FIG. 3 is a schematic diagram showing a part of a data memory.
FIG. 4 is a schematic diagram showing a part of a working memory.
FIG. 5 is a schematic diagram showing a part of a program memory.
FIG. 6 is a schematic diagram showing a format of a flag setting command.
FIG. 7 is a schematic diagram showing a format of a key collation command.
FIG. 8 is a flowchart for explaining processing of a command for outputting a specific status word.
FIG. 9 is a flowchart for explaining processing of a command that outputs a specific status word even when the processing ends normally.
FIG. 10 is a flowchart for explaining processing of a command for outputting a specific status word in a specific application.
FIG. 11 is a flowchart illustrating processing of a command that outputs a specific status word even when processing is normally completed in a specific application.
[Explanation of symbols]
1 ... IC card (portable electronic device)
2 …… Card reader / writer (external device)
DESCRIPTION OF
Claims (7)
前記アプリケーションに応じて受信したコマンドに対する処理結果を示す第1の情報を出力するか、あるいは処理結果とは異なる内容を示す第2の情報を出力するかを判定するための判定情報を記憶している記憶手段と、
受信したコマンドに対する処理を行なった際、前記記憶手段の記憶内容に基づいて前記第1の情報を出力するか、あるいは前記第2の情報を出力するかを判定する判定手段と、
この判定手段の判定結果に基づき前記第1の情報あるいは前記第2の情報を選択的に出力する出力手段と、
を具備したことを特徴とする電子装置。In an electronic device that can register a plurality of applications and receives a command input from the outside in each registered application, performs processing for the received command, and outputs information indicating the processing result to the outside.
Storing determination information for determining whether to output first information indicating a processing result for a command received according to the application or to output second information indicating a content different from the processing result; Storage means
A determination unit that determines whether to output the first information or the second information based on the storage content of the storage unit when processing the received command;
Output means for selectively outputting the first information or the second information based on the determination result of the determination means;
An electronic device comprising:
前記アプリケーションに応じて受信したコマンドに対する処理結果を示す第1の情報を出力するか、あるいは処理結果とは異なる内容を示す第2の情報を出力するかを判定するための判定情報を記憶している記憶手段と、
受信したコマンドに対する処理を行なった際、その処理が正常に終了しなかった場合、前記記憶手段の記憶内容に基づいて前記第1の情報を出力するか、あるいは前記第2の情報を出力するかを判定する判定手段と、
この判定手段の判定結果に基づき前記第1の情報あるいは前記第2の情報を選択的に出力する出力手段と、
を具備したことを特徴とする電子装置。In an electronic device that can register a plurality of applications and receives a command input from the outside in each registered application, performs processing for the received command, and outputs information indicating the processing result to the outside.
Storing determination information for determining whether to output first information indicating a processing result for a command received according to the application or to output second information indicating a content different from the processing result; Storage means
When performing a process for the received command, or if the processing is not completed normally, or not to output the first information based on the stored contents of the storage unit, or outputs the second information Determining means for determining
Output means for selectively outputting the first information or the second information based on the determination result of the determination means;
An electronic device comprising:
前記アプリケーションに応じて受信したコマンドに対する処理結果を示す第1の情報を出力するか、あるいは処理結果とは異なる内容を示す第2の情報を出力するかを判定するための判定情報を記憶している記憶手段と、
受信したコマンドに対する処理を行なった際、その処理が正常に終了した場合、前記記憶手段の記憶内容に基づいて前記第1の情報を出力するか、あるいは前記第2の情報を出力するかを判定する判定手段と、
この判定手段の判定結果に基づき前記第1の情報あるいは前記第2の情報を選択的に出力する出力手段と、
を具備したことを特徴とする電子装置。In an electronic device that can register a plurality of applications and receives a command input from the outside in each registered application, performs processing for the received command, and outputs information indicating the processing result to the outside.
Storing determination information for determining whether to output first information indicating a processing result for a command received according to the application or to output second information indicating a content different from the processing result; Storage means
When processing for the received command is performed, if the processing ends normally, it is determined whether to output the first information or the second information based on the storage contents of the storage means Determination means to perform,
Output means for selectively outputting the first information or the second information based on the determination result of the determination means;
An electronic device comprising:
前記アプリケーションに応じて受信したコマンドに対する処理結果を示す第1の情報を出力するか、あるいは処理結果とは異なる内容を示す第2の情報を出力するかを記憶する記憶手段と、
受信したコマンドに対する処理を行なった際、その処理が正常に終了しなかった場合、現在選択されているアプリケーションがあらかじめ設定された特定のアプリケーションであるか否かを判定する判定手段と、
この判定手段により現在選択されているアプリケーションが特定のアプリケーションではないと判定された場合は前記記憶手段の記憶内容に基づいて前記第1の情報を外部へ出力し、前記判定手段により現在選択されているアプリケーションが特定のアプリケーションであると判定された場合は前記記憶手段の記憶内容に基づいて前記第2の情報を外部へ出力する出力手段と、
を具備したことを特徴とする電子装置。In an electronic device that can register a plurality of applications and receives a command input from the outside in each registered application, performs processing for the received command, and outputs information indicating the processing result to the outside.
Storage means for storing whether to output first information indicating a processing result for a command received according to the application, or to output second information indicating a content different from the processing result;
A determination means for determining whether or not the currently selected application is a specific application set in advance when the process for the received command is not normally completed when the process is performed;
If it is determined by the determination means that the currently selected application is not a specific application, the first information is output to the outside based on the stored contents of the storage means, and the currently selected application is selected by the determination means. An output unit that outputs the second information to the outside based on the storage content of the storage unit when it is determined that the application is a specific application;
An electronic device comprising:
受信したコマンドに対する処理結果を示す第1の情報を出力するか、あるいは処理結果とは異なる内容を示す第2の情報を出力するかを判断するための判断情報を記憶している第1の記憶手段と、
前記第1の情報を出力するかあるいは前記第2の情報を出力するかをコマンドごとに指定する指定情報を記憶している第2の記憶手段と、
受信したコマンドに対する処理を行なった際、前記第2の記憶手段内の指定情報を参照することにより前記第1の情報を出力するかあるいは前記第2の情報を出力するかを判断する第1の判断手段と、
この第1の判断手段により第2の情報を出力すると判断された場合、前記第1の記憶手段内の判断情報を参照することにより前記第1の情報を出力するかあるいは前記第2の情報を出力するかを判断する第2の判断手段と、
前記第1の判断手段により第1の情報を出力すると判断された場合、あるいは前記第2の判断手段により第1の情報を出力すると判断された場合は前記第1の情報を外部へ出力し、前記第2の判断手段により第2の情報を出力すると判断された場合は前記第2の情報を外部へ出力する出力手段と、
を具備したことを特徴とする電子装置。When receiving an externally input command, the electronic device performs processing for the received command and outputs information indicating the processing result to the outside.
A first memory storing determination information for determining whether to output first information indicating a processing result for a received command or to output second information indicating a content different from the processing result Means,
Second storage means for storing designation information for designating for each command whether to output the first information or the second information;
When processing for the received command is performed, a first determination is made as to whether to output the first information or the second information by referring to the designation information in the second storage means Judgment means,
When it is determined by the first determination means that the second information is output, the first information is output by referring to the determination information in the first storage means, or the second information is Second judging means for judging whether to output;
When it is determined that the first information is output by the first determining means, or when it is determined that the first information is output by the second determining means, the first information is output to the outside. An output means for outputting the second information to the outside when it is determined by the second determination means to output the second information;
An electronic device comprising:
選択されたアプリケーションが発行された状態になっているか否かを識別するための発行識別情報を記憶している第1の記憶手段と、
現在選択されているアプリケーションの種類を示す種類識別情報を記憶している第2の記憶手段と、
受信したコマンドに対する処理を行なった際、その処理が正常に終了しなかった場合、前記第2の記憶手段内の種類識別情報を参照することにより現在選択されているアプリケーションがあらかじめ設定された特定のアプリケーションであるか否かを判定する第1の判定手段と、
この第1の判定手段により現在選択されているアプリケーションが特定のアプリケーションであると判定された場合、前記第1の記憶手段内の発行識別情報を参照することにより現在選択されている特定のアプリケーションが発行済みであるか否かを判定する第2の判定手段と、
前記第1の判定手段により現在選択されているアプリケーションが特定のアプリケーションではないと判定された場合、あるいは前記第2の判定手段により現在選択されている特定のアプリケーションが発行済みでないと判定された場合は受信したコマンドに対する処理結果を示す第1の情報を出力し、前記第2の判定手段により現在選択されている特定のアプリケーションが発行済みであると判定された場合は処理結果とは異なる内容を示す第2の情報を出力する出力手段と、
を具備したことを特徴とする電子装置。In an electronic device that can register a plurality of applications and receives a command input from the outside in each registered application, performs processing for the received command, and outputs information indicating the processing result to the outside.
First storage means for storing issue identification information for identifying whether or not the selected application has been issued;
A second storage means for storing type identification information indicating the type of the currently selected application;
When the process for the received command is not completed normally, the application currently selected by referring to the type identification information in the second storage means is set to a specific information set in advance. First determination means for determining whether or not the application;
When the first determination unit determines that the currently selected application is a specific application, the specific application currently selected by referring to the issue identification information in the first storage unit is determined. A second determination means for determining whether or not it has been issued;
When it is determined by the first determination means that the currently selected application is not a specific application, or when the specific application currently selected by the second determination means has not been issued Outputs the first information indicating the processing result for the received command, and if the second determining means determines that the specific application currently selected has been issued, the contents differ from the processing result. Output means for outputting second information to be shown;
An electronic device comprising:
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2000108100A JP3688971B2 (en) | 2000-04-10 | 2000-04-10 | Electronic equipment |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2000108100A JP3688971B2 (en) | 2000-04-10 | 2000-04-10 | Electronic equipment |
Related Child Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2003374865A Division JP4542766B2 (en) | 2003-11-04 | 2003-11-04 | Portable electronic device |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JP2001291084A JP2001291084A (en) | 2001-10-19 |
| JP3688971B2 true JP3688971B2 (en) | 2005-08-31 |
Family
ID=18621003
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2000108100A Expired - Lifetime JP3688971B2 (en) | 2000-04-10 | 2000-04-10 | Electronic equipment |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP3688971B2 (en) |
Families Citing this family (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP4546124B2 (en) * | 2004-03-19 | 2010-09-15 | 東芝テック株式会社 | Information tag response control method |
| JP6182940B2 (en) * | 2013-04-04 | 2017-08-23 | 大日本印刷株式会社 | IC card, status word output method, and status word output processing program |
-
2000
- 2000-04-10 JP JP2000108100A patent/JP3688971B2/en not_active Expired - Lifetime
Also Published As
| Publication number | Publication date |
|---|---|
| JP2001291084A (en) | 2001-10-19 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| KR910002256B1 (en) | Portable electronics | |
| US5285200A (en) | Portable electronic device and a method for processing data therefore | |
| JP2025097584A (en) | Electronic information storage medium, ic chip, ic card, element data storage method, and program | |
| US6286757B1 (en) | Portable electronic apparatus | |
| JP3688971B2 (en) | Electronic equipment | |
| JP4891587B2 (en) | Portable electronic device, IC card and IC module | |
| KR100350972B1 (en) | Computer system and method possessing the function of storing an ID in its ROM | |
| JP4542766B2 (en) | Portable electronic device | |
| JP2677589B2 (en) | Portable electronic device and IC chip | |
| JPH11282991A (en) | IC card | |
| JP2005182128A (en) | Portable information storage medium and program thereof | |
| JP3251579B2 (en) | Portable electronic devices | |
| JP2930258B2 (en) | Portable electronic devices | |
| JP2004259176A (en) | IC card | |
| JP2537200B2 (en) | Portable electronic devices | |
| JPH05100961A (en) | Data storage system | |
| JP2001202487A (en) | Portable electronic device and key matching method | |
| JPH02173869A (en) | Personal authentication system using ic card | |
| JP2003331236A (en) | Portable electronic devices | |
| JP2005301657A (en) | IC card storing a plurality of command tables in rewritable memory and command execution method | |
| JP3048550B2 (en) | IC chip for IC card | |
| JP2598056B2 (en) | Portable electronic devices | |
| JP2005190454A (en) | Device for providing memory card content and method of content security | |
| JP2537198B2 (en) | Portable electronic devices | |
| JPH01177183A (en) | Portable electronic device |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A02 | Decision of refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A02 Effective date: 20040810 |
|
| A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20040909 |
|
| A911 | Transfer to examiner for re-examination before appeal (zenchi) |
Free format text: JAPANESE INTERMEDIATE CODE: A911 Effective date: 20041015 |
|
| 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: 20050607 |
|
| A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20050609 |
|
| R151 | Written notification of patent or utility model registration |
Ref document number: 3688971 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R151 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20090617 Year of fee payment: 4 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20090617 Year of fee payment: 4 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20100617 Year of fee payment: 5 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20100617 Year of fee payment: 5 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20110617 Year of fee payment: 6 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20120617 Year of fee payment: 7 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20120617 Year of fee payment: 7 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20130617 Year of fee payment: 8 |
|
| S111 | Request for change of ownership or part of ownership |
Free format text: JAPANESE INTERMEDIATE CODE: R313111 |
|
| S111 | Request for change of ownership or part of ownership |
Free format text: JAPANESE INTERMEDIATE CODE: R313114 |
|
| R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |
|
| EXPY | Cancellation because of completion of term |