JP2008278416A - Apparatuses, methods, and programs for data encryption processing and data decryption processing, and integrated circuit - Google Patents

Apparatuses, methods, and programs for data encryption processing and data decryption processing, and integrated circuit Download PDF

Info

Publication number
JP2008278416A
JP2008278416A JP2007122443A JP2007122443A JP2008278416A JP 2008278416 A JP2008278416 A JP 2008278416A JP 2007122443 A JP2007122443 A JP 2007122443A JP 2007122443 A JP2007122443 A JP 2007122443A JP 2008278416 A JP2008278416 A JP 2008278416A
Authority
JP
Japan
Prior art keywords
data
error detection
encryption
ciphertext
detection data
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2007122443A
Other languages
Japanese (ja)
Inventor
Kaoru Yokota
薫 横田
Natsume Matsuzaki
なつめ 松崎
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP2007122443A priority Critical patent/JP2008278416A/en
Publication of JP2008278416A publication Critical patent/JP2008278416A/en
Pending legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To solve the problem that, in the prior art, when data for tampering detection are added, a data size is expanded. <P>SOLUTION: An encryption key is generated for encrypting data for tampering detection on the basis of data to detect tampering and a random number generated from a private key. The data for tampering detection created from ciphertext data are encrypted using the encryption key and sent. On a receiving side, the encryption key is generated on the basis of the data to detect tampering and the random number generated from the private key, and the received encrypted data for tampering detection are decrypted. The decrypted data for tampering detection are compared with data for tampering detection calculated from ciphertext, and presence/absence of data tampering or data error is detected. Thus, not only a data error on a communication path but also intensive data tampering of an object to detect tampering can be detected. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

本発明は、送信側でデータを改ざん検出可能な形式で暗号化して受信側に送信し、受信側で復号化してデータ改ざんの有無を検知することが可能な、データ暗号処理装置に関する。   The present invention relates to a data encryption processing apparatus capable of encrypting data in a format that can detect tampering on the transmission side and transmitting the encrypted data to the reception side and decrypting the data on the reception side to detect the presence or absence of data tampering.

近年、映画や音楽などのデジタルコンテンツを、ネットワークを介して配信したり、ある機器で受信あるいは蓄積しているデジタルコンテンツを、別の機器に転送して利用したりするケースが多くなってきた。このようなケースでは、配信したり転送したりするデジタルコンテンツデータの著作権を保護するために、送信側の機器あるいはサーバでコピー可能回数や利用条件などを記述したコピー制御情報を付加した上で、暗号化してネットワーク上や機器間の伝送チャネルを介して送付されるのが一般的である。送付された暗号化コンテンツデータを受信した機器は、コンテンツの復号化処理を行った上で、付加されているコピー制御情報に基づいて再生処理などのコンテンツ利用を行う。   In recent years, digital contents such as movies and music have been distributed over a network, and digital contents received or stored in one device have been transferred to another device for use. In such cases, in order to protect the copyright of the digital content data that is distributed or transferred, copy control information that describes the number of copies that can be made by the sending device or server, usage conditions, etc. is added. In general, it is encrypted and sent via a transmission channel on a network or between devices. The device that has received the transmitted encrypted content data performs content decryption processing and uses content such as reproduction processing based on the added copy control information.

また、近年、高速ネットワークの一般家庭への普及に伴い、デジタルストリームコンテンツをリアルタイムで受信、復号化、再生するようなストリーム配信サービスも普及している。他方で、コンテンツの高精細化、大容量化も進んでいるため、そのような高品質で大容量の暗号化コンテンツデータを、リアルタイムでストリーミング再生するためには、高速処理が可能な暗号方式が求められている。   In recent years, with the spread of high-speed networks to ordinary households, stream distribution services that receive, decode, and play back digital stream contents in real time have also become widespread. On the other hand, since the content is becoming higher in definition and larger in capacity, in order to stream such high-quality and large-capacity encrypted content data in real time, there is an encryption method capable of high-speed processing. It has been demanded.

ここで、コンテンツに付加するコピー制御情報は、コンテンツの利用条件を規定する情報であるため、何らかの暗号処理によって転送中の改ざんを阻止しなければならない。一般に、データを暗号化するだけでは、転送中のデータ改ざんを完全に阻止することはできない。例えば、データを所定のブロック単位で暗号化するブロック暗号方式では、暗号化データの一部分を改ざんしても、復号化データは、改ざんを行った部分を含む1ブロックだけが元の平文とは異なるだけに過ぎない。従って、先頭にコピー制御情報を付加したコンテンツデータの暗号化データに対してコピー制御情報部分を改ざんしても、コンテンツデータの先頭ブロックのデータが壊れるだけである。そのため、例えば、映像データの場合は、コピー制御情報は変えられてしまっているにもかかわらず、最初の数フレーム分に映像の乱れが有るだけで後は支障なく再生できてしまう恐れが有る。   Here, since the copy control information added to the content is information that defines the usage conditions of the content, it is necessary to prevent tampering during transfer by some kind of encryption processing. In general, it is not possible to completely prevent data tampering during transfer simply by encrypting data. For example, in a block encryption method that encrypts data in a predetermined block unit, even if a part of the encrypted data is tampered with, the decrypted data differs from the original plaintext only in one block that includes the tampered part. Only. Therefore, even if the copy control information portion is falsified with respect to the encrypted data of the content data with the copy control information added at the head, only the data in the head block of the content data is broken. Therefore, for example, in the case of video data, there is a possibility that even if the copy control information has been changed, there is a video disturbance in the first few frames, and the video data can be reproduced without any trouble later.

この問題は、暗号方式としてストリーム暗号方式を用いた場合には更に顕著となる。ストリーム暗号方式では、基本的にはデータを1ビット単位で暗号化している。従って、例えば暗号化コンテンツデータの先頭の8ビットがコピー制御情報であると分かっていて、その部分の暗号化コンテンツデータに改ざん(ビット反転)を行っても、復号化データは、改ざんを行ったコピー制御情報部分だけが元の平文データと違う値となり、それ以外の部分は全くもとの平文と同じとなる。即ち、コピー制御情報は改変されたにも関わらず、コンテンツの再生は何ら支障なく行えることになり、コンテンツの著作権は損なわれてしまう。ストリーム暗号方式は、ブロック暗号方式と比べて、より高速な暗号処理が可能であるため、コンテンツのストリーム配信などでの使用に有効であるが、上記のようなデータ改ざんに対する耐性の低さが特に問題となってくる。   This problem becomes more prominent when the stream encryption method is used as the encryption method. In the stream encryption method, data is basically encrypted in 1-bit units. Therefore, for example, even if the first 8 bits of the encrypted content data are known to be copy control information and the encrypted content data in that portion is altered (bit inversion), the decrypted data has been altered. Only the copy control information part has a value different from the original plaintext data, and the other parts are completely the same as the original plaintext. That is, although the copy control information has been altered, the content can be reproduced without any trouble, and the copyright of the content is lost. The stream encryption method is effective for use in content stream distribution and the like because it can perform higher-speed encryption processing than the block encryption method, but the low resistance to data alteration as described above is particularly low. It becomes a problem.

デジタルデータの改ざん防止方法としては、メッセージ改ざん検出子を用いた方式が一般的である。この方式では、送信側、受信側で予め共有された秘密データを元に、送信側で、データの改ざんを検出するためのデータ(メッセージ改ざん検出子)を作成する。そして、メッセージ改ざん検出子を伝送するデータに付加して受信側に送付する。受信側では、受信したデータから送信側と同じようにしてメッセージ改ざん検出子を作成し、伝送データに付加されていたものと一致するかどうかを確認する。一致すれば、伝送データは改ざんされていないと判断し、一致しない場合には改ざんがされていると判断する。   As a digital data alteration prevention method, a method using a message alteration detector is generally used. In this method, data for detecting data falsification (message falsification detector) is created on the transmission side based on secret data shared in advance on the transmission side and reception side. Then, the message alteration detector is added to the data to be transmitted and sent to the receiving side. On the receiving side, a message alteration detector is created from the received data in the same manner as on the transmitting side, and it is confirmed whether or not it matches the one added to the transmission data. If they match, it is determined that the transmission data has not been tampered with, and if they do not match, it is determined that tampering has occurred.

しかしながら、従来技術においては、伝送データにメッセージ改ざん検出子を付加する必要があるため、伝送データのデータサイズが増加する、という課題を有していた。これは、ストリーム配信あるいは転送されるコンテンツデータをリアルタイムで受信、復号化、再生するような場合には特に問題となる。例えば、コンテンツデータを、パケット単位で受信する場合、各パケットにメッセージ改ざん検出子を付加すると、1パケットあたりのデータサイズが増加する。このため、単位時間あたりの通信パケット数を同じにするためには、通信帯域を増加することが必要になってしまう。さらに、受信側端末でも単位時間あたりの処理パケット数を同じにするためには、端末の処理性能を高める必要がある。以上のように、通信コスト、端末コストとも増大することになる一方、受信端末側の処理負荷が増加し、リアルタイムでコンテンツ受信、再生に対応しきれずに、音とびや映像の途切れが生じてしまう恐れも増加する。   However, the prior art has a problem that the data size of the transmission data increases because it is necessary to add a message alteration detector to the transmission data. This is particularly problematic when content data to be streamed or transferred is received, decoded, and reproduced in real time. For example, when content data is received in units of packets, adding a message alteration detector to each packet increases the data size per packet. For this reason, in order to make the number of communication packets per unit time the same, it is necessary to increase the communication band. Furthermore, in order for the receiving terminal to have the same number of processing packets per unit time, it is necessary to improve the processing performance of the terminal. As described above, both the communication cost and the terminal cost will increase, but the processing load on the receiving terminal side will increase, and it will not be able to handle content reception and playback in real time, causing skipping and skipping of video Fear also increases.

本発明は、前記課題を解決するもので、高速処理が可能で、従来技術のようにデータ改ざん検出用のデータを付加することなく、転送されるデータの改ざんを阻止することが可能なデータ暗号処理装置を提供することを目的とする。   The present invention solves the above-mentioned problems, and is a data encryption that can perform high-speed processing and can prevent the tampering of transferred data without adding data for detecting data tampering as in the prior art. An object is to provide a processing apparatus.

前記従来の課題を解決するために、本発明のデータ暗号処理装置は、平文データを暗号化して暗号文データを生成し、前記平文データは、改ざん検出対象データを含み、前記データ暗号処理装置は、鍵データを用いて前記平文データを暗号化して暗号化データを生成するデータ暗号変換部と、前記暗号化データに対して誤り検出用データを生成する誤り検出用データ生成部と、前記改ざん検出対象データと前記鍵データに基づいて誤り検出用データ暗号鍵を生成する誤り検出用データ暗号鍵生成部と、前記誤り検出用データ暗号鍵を用いて前記誤り検出用データを暗号化して暗号化誤り検出用データを生成する誤り検出用データ暗号化部と、前記暗号化データと前記暗号化誤り検出用データを元に暗号文データを作成して出力する暗号文データ出力部とを備えることを特徴とする。   In order to solve the conventional problem, a data encryption processing device of the present invention generates plaintext data by encrypting plaintext data, and the plaintext data includes alteration detection target data, and the data encryption processing device includes: A data encryption conversion unit that encrypts the plaintext data using key data to generate encrypted data, an error detection data generation unit that generates error detection data for the encrypted data, and the falsification detection An error detection data encryption key generation unit that generates an error detection data encryption key based on the target data and the key data, and encrypts the error detection data by using the error detection data encryption key to encrypt an error. An error detection data encryption unit that generates detection data; and ciphertext data that is generated and output based on the encrypted data and the encryption error detection data. And an outputting portion.

本発明のデータ暗号処理装置によれば、誤り検出用データのチェックにより、データ改ざん検出も可能とすることで、従来技術のようにデータ改ざん検出用のデータを付加することなく、転送されるデータの改ざんを阻止することが可能になるという効果がある。
また、データ改ざん検出のための処理は、コンテンツデータの暗号化、復号化処理と並列化が可能であるため、データ改ざん検出の処理を追加することによる処理時間の増加をきわめて小さくすることが可能になるという効果もある。
According to the data encryption processing apparatus of the present invention, data tampering detection can be performed by checking error detection data, so that data transferred without adding data tampering detection as in the prior art is transmitted. This has the effect of making it possible to prevent tampering.
In addition, the processing for detecting data alteration can be performed in parallel with the encryption and decryption processing of content data, so the increase in processing time due to the addition of data alteration detection processing can be minimized. There is also an effect of becoming.

また、本発明のデータ改ざん検出方式では、データの高速暗号化・復号化が可能なストリーム暗号方式にも適用することで、ストリーム暗号方式の長所である高速暗号処理性能を損なうことなく、ストリーム暗号化方式の欠点であったデータ改ざんへの耐性の低さを補い、かつ、改ざん検出用の付加データが不要という、特に顕著な効果を奏する。   In addition, the data alteration detection method of the present invention is applied to a stream encryption method capable of high-speed encryption / decryption of data, so that stream encryption can be performed without impairing high-speed encryption processing performance, which is an advantage of the stream encryption method. This has a particularly remarkable effect of compensating for the low resistance to data alteration, which has been a drawback of the conversion method, and not requiring additional data for detecting alteration.

(実施の形態)
以下、本発明の実施の形態について、図面を参照しながら説明する。
(データ送受信システムの構成)
図1は、本発明の実施の形態におけるデータ送受信システムの構成を示したブロック図である。本システムは、データ受信装置2と認証及び鍵共有を行ったうえでストリームデータを暗号化して送信するデータ送信装置1と、データ送信装置1と認証及び鍵共有を行ったうえで暗号化ストリームデータを受信、復号化して再生または蓄積するデータ受信装置2とからなる。データ送信装置1の例としては、デジタルテレビ放送やIP放送などの放送波を受信してテレビで視聴可能な信号に変換するセットトップボックスや、メディアに蓄積されたコンテンツデータを読み出してデコードするDVD(Digital Versatile Disk)プレーヤー、DVDレコーダー、BD(Blu−ray Disk)プレーヤー、BDレコーダなどである。データ受信装置2の例としては、変換もしくはデコードされたコンテンツデータを受信して表示もしくは蓄積する、テレビ、PCモニター、DVDレコーダ、BDレコーダなどである。
(Embodiment)
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
(Data transmission system configuration)
FIG. 1 is a block diagram showing a configuration of a data transmission / reception system according to an embodiment of the present invention. This system performs authentication and key sharing with the data receiving device 2 and then encrypts and transmits the stream data, and encrypts stream data after performing authentication and key sharing with the data transmitting device 1. And a data receiving device 2 that reproduces or stores the data by decoding and decoding. Examples of the data transmission device 1 include a set-top box that receives broadcast waves such as digital television broadcasts and IP broadcasts and converts them into signals that can be viewed on a television, or a DVD that reads and decodes content data stored in media. (Digital Versatile Disk) player, DVD recorder, BD (Blu-ray Disk) player, BD recorder, and the like. Examples of the data receiving apparatus 2 include a television, a PC monitor, a DVD recorder, and a BD recorder that receive and display or store the converted or decoded content data.

データ送信装置1は、データ暗号化処理を行うデータ暗号化部10と、データ受信装置2と相互認証及び鍵共有を行う認証鍵共有処理部11と、送信するデータストリームの生成を行うデータストリーム生成部12からなる。また、データ受信装置2は、データ復号化処理を行うデータ復号化部20と、データ送信装置1と相互認証及び鍵共有を行う認証鍵共有処理部21と、受信して復号化したデータストリームの再生を行うデータストリーム再生部22からなる。   The data transmission device 1 includes a data encryption unit 10 that performs data encryption processing, an authentication key sharing processing unit 11 that performs mutual authentication and key sharing with the data reception device 2, and a data stream generation that generates a data stream to be transmitted. Part 12. In addition, the data reception device 2 includes a data decryption unit 20 that performs data decryption processing, an authentication key sharing processing unit 21 that performs mutual authentication and key sharing with the data transmission device 1, and a received and decrypted data stream. It comprises a data stream playback unit 22 that performs playback.

本データ送受信システムにおいて、データ送信装置1がデータ受信装置2にストリームデータを送付するための動作は以下の通りである。
(1)相互認証及び鍵共有
データ送信装置1とデータ受信装置2の間で相互に認証を行う。データ送信装置1の認証鍵共有処理部11とデータ受信装置2の認証鍵共有処理部21には、それぞれ認証のための認証鍵が保管されており、認証鍵共有処理部11と21は、それぞれ保有している認証鍵を用いて、相互に認証しあった上で鍵共有を行う。なお、相互認証と鍵共有の方式は、公知であるためその詳細は説明しない。相互認証と鍵共有の方式としては、共通鍵暗号方式を用いた方法や、公開鍵暗号方式を用いた方法など各種あるが、互いに相手の機器の正当性が認証でき、両者の間で秘密の鍵データが共有できればどのような方式であっても良い。このようにして、認証鍵共有処理部11と21は、128ビットの秘密の鍵データKを共有する。また、両者は、前記鍵データとは別に128ビットの初期ベクタIVを共有する。初期ベクタIVは、必ずしも秘密裏に共有する必要はないので、相互に認証の後、どちらかがランダムに生成して平文のまま相手に送付しても良いし、前記鍵データKで暗号化して送付しても良い。
In this data transmission / reception system, the operation for the data transmission apparatus 1 to send stream data to the data reception apparatus 2 is as follows.
(1) Mutual authentication and key sharing The data transmission device 1 and the data reception device 2 perform mutual authentication. The authentication key sharing processing unit 11 of the data transmitting device 1 and the authentication key sharing processing unit 21 of the data receiving device 2 store authentication keys for authentication, respectively, and the authentication key sharing processing units 11 and 21 respectively Using the authentication key that you have, perform mutual key authentication. Note that the mutual authentication and key sharing methods are well known and will not be described in detail. There are various mutual authentication and key sharing methods, such as a method using a common key encryption method and a method using a public key encryption method. Any method may be used as long as key data can be shared. In this way, the authentication key sharing processing units 11 and 21 share the 128-bit secret key data K. Both share a 128-bit initial vector IV separately from the key data. Since the initial vector IV does not necessarily have to be secretly shared, either one may be randomly generated after mutual authentication and sent to the other party in plain text, or encrypted with the key data K You may send it.

(2)ストリームデータの暗号化及び送信
データ送信装置1は、ストリームデータを生成して暗号化した上でデータ受信装置2に送信する。まず、ストリームデータ生成部12で平文ストリームデータを生成する。平文ストリームの例としては、受信した放送波や、DVDなどのメディアから読み取った映像・音楽コンテンツデータを、受信装置側で再生可能な形式に変換したデータなどである。図2は、平文ストリームデータの構成の一例を示したものである。平文ストリームデータは、複数のパケットデータ50、51、・・・、52からなり、各パケットデータ(図2ではパケットデータ51を例にして図示している)は、ヘッダデータ510と、メインデータ511とからなる。本実施例では、各パケットのデータサイズは、2048バイトとし、パケットデータは、2バイトのヘッダデータと2046バイトのメインデータからなるものとする。また、ヘッダデータ2バイトは、コピー制御情報であるものとする。コピー制御情報は、ストリームデータを生成する際に、その元となるオリジナルのコンテンツデータに予め設定されているコピー制御規則に基づいて決定してストリームデータを構成する各パケットデータのヘッダデータ部分に設定する。次に、データ暗号化部10は、認証鍵共有処理部11から入力される初期ベクタIVと鍵Kとを用いて、前記の平文ストリームデータに対して暗号化処理を行い、暗号文ストリームデータを生成する。平文ストリームデータの暗号化処理の詳細については、後で説明する。そして、データ送信装置1は、暗号文ストリームデータをデータ受信装置2に送付する。なお、データ送信装置1は、全てのストリームデータの暗号化が完了してから暗号文ストリームデータをデータ受信装置2に送付しても良いし、暗号化処理を行ったストリームデータを、その都度リアルタイムでデータ受信装置2に送付しても良い。
(2) Encryption and transmission of stream data The data transmission apparatus 1 generates and encrypts stream data and transmits the stream data to the data reception apparatus 2. First, the stream data generation unit 12 generates plaintext stream data. Examples of the plaintext stream include received broadcast waves and data obtained by converting video / music content data read from a medium such as a DVD into a format that can be reproduced on the receiving device side. FIG. 2 shows an example of the structure of plaintext stream data. The plaintext stream data is composed of a plurality of packet data 50, 51,..., 52. Each packet data (illustrated by taking the packet data 51 as an example in FIG. 2) includes header data 510 and main data 511. It consists of. In this embodiment, the data size of each packet is 2048 bytes, and the packet data is composed of 2 bytes of header data and 2046 bytes of main data. Also, it is assumed that the header data 2 bytes is copy control information. The copy control information is determined based on a copy control rule set in advance in the original original content data when the stream data is generated, and set in the header data portion of each packet data constituting the stream data. To do. Next, the data encryption unit 10 performs an encryption process on the plaintext stream data using the initial vector IV and the key K input from the authentication key sharing processing unit 11, and converts the encrypted text stream data into the encrypted text stream data. Generate. Details of the plaintext stream data encryption processing will be described later. Then, the data transmission device 1 sends the ciphertext stream data to the data reception device 2. The data transmitting device 1 may send the ciphertext stream data to the data receiving device 2 after the encryption of all the stream data is completed, or the stream data subjected to the encryption process is sent in real time each time. May be sent to the data receiving device 2.

(3)暗号化ストリームデータの復号化及び再生
データ受信装置2は、データ送信装置1から受信した暗号化ストリームデータを、(1)の処理で共有した鍵Kと初期ベクタIVに基づいて復号化を行って復号文ストリームデータを生成し、再生する。データ復号化部20は、認証鍵共有処理部21から入力される初期ベクタIVと鍵Kとを用いて、受信した暗号化ストリームデータに対して復号化処理を行い、復号文ストリームデータを生成する。暗号文ストリームデータの復号化処理の詳細については、後で説明する。前記復号化処理が正しく行われると、復号文ストリームデータは、データ送信装置1のデータストリーム生成部12が生成した平文ストリームデータと一致する。次に、データストリーム再生部22は、復号文ストリームのパケットデータに含まれるヘッダデータ2バイトのコピー制御情報に基づいて、復号文ストリームを再生する。なお、データ受信装置2は、暗号文ストリームデータを全て受信し終わってから復号化処理とストリームデータの再生処理を開始しても良いし、データ送信装置1から受信した暗号文ストリームデータをリアルタイムで復号化と再生の処理をしても良い。
(3) Decryption and reproduction of encrypted stream data The data receiving device 2 decrypts the encrypted stream data received from the data transmitting device 1 based on the key K and the initial vector IV shared in the processing of (1). To generate decrypted text stream data and reproduce it. The data decryption unit 20 performs decryption processing on the received encrypted stream data using the initial vector IV and the key K input from the authentication key sharing processing unit 21, and generates decrypted text stream data. . Details of the decryption processing of the ciphertext stream data will be described later. When the decryption process is correctly performed, the decrypted text stream data matches the plain text stream data generated by the data stream generating unit 12 of the data transmitting apparatus 1. Next, the data stream reproduction unit 22 reproduces the decrypted text stream based on the copy control information of 2 bytes of header data included in the packet data of the decrypted text stream. The data receiving apparatus 2 may start the decryption process and the stream data reproduction process after receiving all the ciphertext stream data, or the ciphertext stream data received from the data transmitting apparatus 1 in real time. Decoding and playback processing may be performed.

次に、データ暗号化部10の処理について説明する。
(データ暗号化部10の処理詳細)
データ暗号化部10は、平文ストリームデータに対して、先頭から1パケットずつ暗号化処理を行い、最終パケットの暗号処理が完了するまで暗号化処理を繰り返し行う。こうして平文ストリームデータの全パケットに対して暗号化処理を行った結果を暗号文ストリームデータとして出力する。以下では、データ暗号化部10が、1パケットの平文パケットデータを暗号化して、1パケットの暗号化パケットデータを生成する処理について説明する。
Next, processing of the data encryption unit 10 will be described.
(Details of processing of the data encryption unit 10)
The data encryption unit 10 performs encryption processing on the plaintext stream data one packet at a time from the beginning, and repeatedly performs the encryption processing until the encryption processing of the final packet is completed. In this way, the result of performing the encryption processing on all the packets of plaintext stream data is output as ciphertext stream data. Hereinafter, a process in which the data encryption unit 10 encrypts one packet of plaintext packet data to generate one packet of encrypted packet data will be described.

図3は、データ暗号化部10の詳細な構成の一例を示したブロック図である。データ暗号化部10は、初期ベクタIVとこれまでの暗号化処理済みパケット数に基づいて変形初期ベクタを生成する初期ベクタ更新部100と、鍵Kと変形初期ベクタとを用いて乱数データを生成する乱数生成部101と、乱数と平文パケットデータとの排他的論理和演算を行う排他的論理和部102と、暗号化パケットデータからデータ誤り検出用のCRC(Cyclic Redundancy Check)データを生成するCRC計算部103と、CRCデータを暗号化するためのCRC暗号鍵を生成するCRC暗号鍵生成部104と、CRC暗号鍵とCRCデータとの排他的論理和演算を行って暗号化CRCデータを生成する排他的論理和部105からなる。以下、データ暗号化部10の処理について説明する。   FIG. 3 is a block diagram illustrating an example of a detailed configuration of the data encryption unit 10. The data encryption unit 10 generates random data using the initial vector IV and the initial vector update unit 100 that generates a modified initial vector based on the number of packets that have been encrypted so far, and the key K and the modified initial vector. A random number generation unit 101 for performing the exclusive OR operation for performing an exclusive OR operation between the random number and the plaintext packet data, and a CRC for generating CRC (Cyclic Redundancy Check) data from the encrypted packet data. The calculation unit 103, the CRC encryption key generation unit 104 that generates a CRC encryption key for encrypting the CRC data, and the exclusive OR operation of the CRC encryption key and the CRC data are performed to generate the encrypted CRC data. It consists of an exclusive OR unit 105. Hereinafter, processing of the data encryption unit 10 will be described.

初期ベクタ更新部100は、平文ストリームデータの何パケットまで暗号化をしたかを示すカウンタ値を128ビットの数値データNとして保持している。平文ストリームデータの暗号化処理開始時には、N=0(128ビット)であり、1パケットの暗号化処理を完了するたびに、1ずつ加算される。初期ベクタ更新部100は、上記の128ビットデータNと認証鍵共有処理部11から入力される初期ベクタIVとの排他的論理和演算を行い、変形初期ベクタ128ビットを生成する。そして、変形初期ベクタを乱数生成部101に入力する。Nは、1パケット暗号処理を行うたびに変化する値であり、初期ベクタIVは固定的な値であるので、変形初期ベクタは、各パケットの暗号処理ごとに必ず異なる値となる。   The initial vector update unit 100 holds, as 128-bit numerical data N, a counter value indicating how many packets of plaintext stream data have been encrypted. At the start of the plaintext stream data encryption process, N = 0 (128 bits), and every time one packet encryption process is completed, 1 is added. The initial vector update unit 100 performs an exclusive OR operation between the 128-bit data N and the initial vector IV input from the authentication key sharing processing unit 11 to generate a modified initial vector 128 bits. Then, the modified initial vector is input to the random number generation unit 101. N is a value that changes every time one packet encryption process is performed, and the initial vector IV is a fixed value. Therefore, the modified initial vector always has a different value for each packet encryption process.

乱数生成部101は、鍵Kと変形初期ベクタを用いて乱数生成処理を行う。ここで、乱数生成処理の方式としては、株式会社日立製作所「擬似乱数生成器MUGI仕様書Ver.1.2(2001年12月18日)http://www.sdl.hitachi.co.jp/crypto/mugi/mugi_spj.pdf」(右記URLより入手可能 http://www.sdl.hitachi.co.jp/crypto/mugi/mugi_spj.pdf)の乱数生成方式を用いるものとする。この乱数生成方式では、秘密の鍵K128ビットと、変形初期ベクタ128ビットを入力として、64ビット単位で任意の個数の乱数を生成することができる。乱数生成部101は、鍵Kと変形初期ベクタを元に、64ビット×34個の乱数を生成するが、1番目、2番目に生成する乱数は、それぞれ後述する乱数A、Bとして、CRC暗号鍵生成部104に入力し、3番目以降に生成する32個の乱数は、後述する乱数R[0]、R[1]、R[2]、・・・、R[31]として、排他的論理和部102に入力する。   The random number generation unit 101 performs random number generation processing using the key K and the modified initial vector. Here, as a random number generation processing method, Hitachi, Ltd. “Pseudorandom number generator MUGI specification Ver. 1.2 (December 18, 2001) http://www.sdl.hitachi.co.jp/ It is assumed that the random number generation method of “crypto / mugi / mugi_spj.pdf” (available from the URL on the right is http://www.sdl.hitachi.co.jp/crypto/mugi/mugi_spj.pdf). In this random number generation method, an arbitrary number of random numbers can be generated in units of 64 bits with the secret key K128 bits and the modified initial vector 128 bits as inputs. The random number generation unit 101 generates 64 bits × 34 random numbers based on the key K and the modified initial vector. The first and second random numbers are generated as CRCs, which will be described later as random numbers A and B, respectively. The 32 random numbers that are input to the key generation unit 104 and generated after the third are exclusive as random numbers R [0], R [1], R [2],. Input to the logical sum unit 102.

CRC暗号鍵生成部104は、平文パケットデータの先頭64ビットデータP[0]と、乱数生成部101から入力された乱数A、Bとを用いて以下の計算を行い、CRC暗号鍵KCを求める。
KC=T‖T
T=(P[0](+)A)×B
ここで、α‖βは、データαとデータβを上位からα、βの順で連結したデータを示し、(+)は、ビットごとの排他的論理和演算を表す。また、×は、既約多項式x^(64)+x^4+x^3+x+1による有限体GF(2^64)上の乗算を表す。α^βは、αのβ乗を意味する。
The CRC encryption key generation unit 104 performs the following calculation using the first 64-bit data P [0] of the plaintext packet data and the random numbers A and B input from the random number generation unit 101 to obtain the CRC encryption key KC. .
KC = T‖T
T = (P [0] (+) A) × B
Here, α‖β represents data obtained by concatenating data α and data β from the top in the order of α and β, and (+) represents an exclusive OR operation for each bit. Further, x represents multiplication on the finite field GF (2 ^ 64) by the irreducible polynomial x ^ (64) + x ^ 4 + x ^ 3 + x + 1. α ^ β means α to the power of β.

排他的論理和部102には、平文パケットデータが先頭から64ビット単位で、P[0]、P[1]、・・・、P[31]としてこの順序で入力される。排他的論理和部102は、乱数生成部101から入力される乱数R[0]、R[1]、R[2]、・・・、R[31]を用いて、上記平文パケットデータに対して、64ビット単位で以下の排他的論理和演算を行い、C[0]、C[1]、・・・、C[31]を算出し、これらを先頭からこの順序で連結したものを、暗号化データとする。   To the exclusive OR unit 102, plain text packet data is input in this order as P [0], P [1],..., P [31] in 64-bit units from the beginning. The exclusive OR unit 102 uses the random numbers R [0], R [1], R [2],..., R [31] input from the random number generation unit 101 to the plaintext packet data. Then, the following exclusive OR operation is performed in units of 64 bits to calculate C [0], C [1],..., C [31], and these are concatenated in this order from the top, Encrypted data.

C[i]=P[i](+)R[i] (i=0、1、・・・、31)
CRC計算部103は、排他的論理和部102から出力される暗号化データに対してCRCデータを計算する。CRCデータの計算方法は公知であるためここでは省略する。また、本発明において、CRCデータのサイズは特に限定されないが、本実施例では、64ビットとし、CRC多項式は、X^(64)+X^4+X^3+X+1とする。即ち、CRC計算部103は、暗号化データに対して64ビットのCRCデータCDを計算し、排他的論理和部105に入力する。
C [i] = P [i] (+) R [i] (i = 0, 1,..., 31)
The CRC calculation unit 103 calculates CRC data for the encrypted data output from the exclusive OR unit 102. Since the calculation method of CRC data is well known, it is omitted here. In the present invention, the size of the CRC data is not particularly limited, but in this embodiment, it is 64 bits, and the CRC polynomial is X ^ (64) + X ^ 4 + X ^ 3 + X + 1. That is, the CRC calculation unit 103 calculates a 64-bit CRC data CD for the encrypted data, and inputs the CRC data CD to the exclusive OR unit 105.

排他的論理和部105は、CRC暗号鍵生成部104から入力されるCRC暗号鍵KCとCRC計算部103から入力されるCRCデータCDとの排他的論理和演算を行い、暗号化CRCデータED(64ビット)を算出する。そして、EDを、前記暗号化データに付加する。
上記のようにして生成される、暗号化CRCデータ付き暗号化データを、暗号化パケットデータ(2112ビット)としてデータ送信装置1から出力する。データ送信装置1は、上記の1パケットデータ単位の暗号化処理を、平文ストリームデータに含まれる全パケットデータに対して行って、暗号文ストリームデータを生成する。ここで、CRCデータは、伝送路上の誤りを検出するために元々パケットデータに付加されているデータであり、データの改ざんチェックを行う・行わないに関わらず付加されている。従って、本方式において、改ざん検出を行うことにより、暗号化パケットデータのデータサイズは増加しない。
The exclusive OR unit 105 performs an exclusive OR operation between the CRC encryption key KC input from the CRC encryption key generation unit 104 and the CRC data CD input from the CRC calculation unit 103 to obtain the encrypted CRC data ED ( 64 bits). Then, ED is added to the encrypted data.
The encrypted data with encrypted CRC data generated as described above is output from the data transmitting apparatus 1 as encrypted packet data (2112 bits). The data transmitting apparatus 1 performs the above-described encryption processing in units of one packet data on all packet data included in the plaintext stream data to generate ciphertext stream data. Here, CRC data is data originally added to packet data in order to detect an error on the transmission path, and is added regardless of whether or not data tampering is checked. Therefore, in this method, the data size of the encrypted packet data does not increase by detecting falsification.

次に、データ復号化部20の処理について説明する。
(データ復号化部20の処理詳細)
データ復号化部20は、暗号文ストリームデータを、先頭から1パケットずつ復号化処理を行い、最終パケットの復号化処理が完了するまで復号化処理を繰り返し行う。以下では、データ復号化部20が、1パケットの暗号文パケットデータを復号化して、1パケットの復号化パケットデータを生成する処理を説明する。
Next, processing of the data decoding unit 20 will be described.
(Details of processing of the data decoding unit 20)
The data decryption unit 20 decrypts the ciphertext stream data one packet at a time from the beginning, and repeats the decryption process until the decryption process of the final packet is completed. Hereinafter, a process in which the data decryption unit 20 decrypts one packet of ciphertext packet data to generate one packet of decrypted packet data will be described.

図4は、データ復号化部20の詳細な構成の一例を示したブロック図である。データ復号化部20は、初期ベクタIVとこれまでの復号化処理済みパケット数に基づいて変形初期ベクタを生成する初期ベクタ更新部200と、鍵Kと変形初期ベクタとを用いて乱数データを生成する乱数生成部201と、乱数と暗号化パケットデータとの排他的論理和演算を行う排他的論理和部202と、暗号化パケットデータからデータ誤り検出用のCRCデータを生成するCRC計算部203と、暗号化CRCデータを復号化するためのCRC暗号鍵を生成するCRC暗号鍵生成部204と、CRC暗号鍵と暗号化CRCデータとの排他的論理和演算を行って復号化CRCデータを生成する排他的論理和部205と、暗号化パケットデータから計算したCRCデータを暗号化CRCデータとCRC暗号鍵を使って算出した復号化CRCデータと比較して受信した暗号化パケットデータに改ざんあるいは誤りがあるかどうかを判断するCRCチェック部206とからなる。以下、データ復号化部20の処理について説明する。   FIG. 4 is a block diagram illustrating an example of a detailed configuration of the data decoding unit 20. The data decryption unit 20 generates random data using the initial vector IV and the initial vector update unit 200 that generates a modified initial vector based on the number of packets that have been decrypted so far, and the key K and the modified initial vector. A random number generation unit 201 that performs an exclusive OR operation between the random number and the encrypted packet data, a CRC calculation unit 203 that generates CRC data for data error detection from the encrypted packet data, A CRC encryption key generation unit 204 for generating a CRC encryption key for decrypting the encrypted CRC data, and performing an exclusive OR operation on the CRC encryption key and the encrypted CRC data to generate decrypted CRC data An exclusive OR unit 205, and a decrypted CR calculated from the CRC data calculated from the encrypted packet data using the encrypted CRC data and the CRC encryption key. Compared to the data consisting of the CRC check unit 206. which determines whether there is tampering or error in the encrypted packet data received. Hereinafter, processing of the data decoding unit 20 will be described.

暗号化パケットデータは、暗号化データと暗号化CRCデータとからなり、暗号化データは、排他的論理和部202とCRC計算部203に入力され、暗号化CRCデータは排他的論理和部205に入力される。
初期ベクタ更新部200は、暗号文ストリームデータの何パケット分を復号化したかを128ビットの数値データNとして保持している。暗号文ストリームデータの復号化処理開始時には、N=0(128ビット)であり、1パケットの復号化処理を行うたびに、1ずつ加算される。初期ベクタ更新部200は、上記のようにして保持している128ビットデータNと認証鍵共有処理部21から入力される初期ベクタIVとの排他的論理和演算を行い、変形初期ベクタ(128ビット)を生成する。そして、変形初期ベクタを乱数生成部201に入力する。Nは、1パケット復号化処理を行うたびに変化する値であり、初期ベクタIVは固定的な値であるので、変形初期ベクタは、各パケットの復号化処理ごとに必ず異なる値となる。
The encrypted packet data consists of encrypted data and encrypted CRC data. The encrypted data is input to the exclusive OR unit 202 and the CRC calculation unit 203, and the encrypted CRC data is input to the exclusive OR unit 205. Entered.
The initial vector update unit 200 holds, as 128-bit numerical data N, how many packets of the ciphertext stream data have been decrypted. At the start of the decryption processing of the ciphertext stream data, N = 0 (128 bits), and every time one packet decryption processing is performed, 1 is added. The initial vector update unit 200 performs an exclusive OR operation between the 128-bit data N held as described above and the initial vector IV input from the authentication key sharing processing unit 21 to obtain a modified initial vector (128 bits). ) Is generated. Then, the modified initial vector is input to the random number generation unit 201. N is a value that changes every time one-packet decoding process is performed, and the initial vector IV is a fixed value. Therefore, the modified initial vector always has a different value for each packet decoding process.

乱数生成部201は、鍵Kと変形初期ベクタを用いて乱数生成処理を行う。乱数生成処理は、データ暗号化部10の乱数生成部101と同じ処理を用いるものとする。乱数生成部201は、鍵Kと変形初期ベクタを元に、64ビット×34個の乱数を生成するが、1番目、2番目に生成する乱数は、それぞれ後述する乱数A、Bとして、CRC暗号鍵生成部204に入力し、3番目以降に生成する32個の乱数は、後述する乱数R[0]、R[1]、R[2]、・・・、R[31]として、排他的論理和部202に入力する。   The random number generation unit 201 performs random number generation processing using the key K and the modified initial vector. The random number generation process uses the same process as the random number generation unit 101 of the data encryption unit 10. The random number generation unit 201 generates 64 bits × 34 random numbers based on the key K and the modified initial vector, and the first and second random numbers are generated as CRCs ciphers as random numbers A and B, which will be described later, respectively. The 32 random numbers input to the key generation unit 204 and generated after the third are exclusive as random numbers R [0], R [1], R [2],. Input to the logical sum unit 202.

排他的論理和部202には、暗号化データが先頭から64ビット単位で、C[0]、C[1]、・・・、C[31]として順乱入力される。排他的論理和部202は、乱数生成部201から入力される乱数R[0]、R[1]、R[2]、・・・、R[31]を用いて、上記暗号化パケットデータに対して、64ビット単位で以下の排他的論理和演算を行い、復号化したデータD[0]、D[1]、・・・、D[31]を算出し、これらを先頭からこの順序で連結したものを、復号化パケットデータ(2048ビット)とする。このとき、D[0]については、下記の計算により算出すると同時にCRC暗号鍵生成部204にも入力する。   To the exclusive OR unit 202, the encrypted data is randomly input as C [0], C [1],..., C [31] in 64-bit units from the beginning. The exclusive OR unit 202 uses the random numbers R [0], R [1], R [2],..., R [31] input from the random number generation unit 201 to generate the encrypted packet data. On the other hand, the following exclusive OR operation is performed in units of 64 bits to calculate decoded data D [0], D [1],..., D [31], and these are processed in this order from the top. The concatenated data is decoded packet data (2048 bits). At this time, D [0] is calculated by the following calculation and input to the CRC encryption key generation unit 204 at the same time.

D[i]=C[i](+)R[i] (i=0、1、・・・、31)
CRC暗号鍵生成部204は、排他的論理和部202が、上記の処理でC[0]の処理が終わって、D[0]が生成され入力されると、D[0]に対して、乱数生成部101から入力された乱数A、Bとを用いて以下の計算を行い、CRC暗号鍵KCを求める。
KC=T‖T
T=(X[0](+)A)×B
ここで、α‖βは、データαとデータβを上位からα、βの順で連結したデータを示し、(+)は、ビットごとの排他的論理和演算を表す。また、×は、既約多項式x^(64)+x^4+x^3+x+1による有限体GF(2^64)上の乗算を表す。α^βは、αのβ乗を意味する。
D [i] = C [i] (+) R [i] (i = 0, 1,..., 31)
The CRC encryption key generation unit 204, when the exclusive OR unit 202 finishes the process of C [0] in the above process and generates and inputs D [0], The following calculation is performed using the random numbers A and B input from the random number generation unit 101 to obtain the CRC encryption key KC.
KC = T‖T
T = (X [0] (+) A) × B
Here, α‖β represents data obtained by concatenating data α and data β from the top in the order of α and β, and (+) represents an exclusive OR operation for each bit. Further, x represents multiplication on the finite field GF (2 ^ 64) by the irreducible polynomial x ^ (64) + x ^ 4 + x ^ 3 + x + 1. α ^ β means α to the power of β.

CRC計算部203は、暗号化データに対してCRCデータを計算する。CRC計算部203は、データ暗号化部10のCRC計算部103と同じ計算方法により、暗号化データ(2048ビット)に対して64ビットのCRCデータCDを計算し、排他的論理和部205に入力する。
排他的論理和部205は、CRC暗号鍵生成部204から入力されるCRC暗号鍵KCと暗号化パケットデータに含まれている暗号化CRCデータEDとの排他的論理和演算を行い、復号化CRCデータDD(64ビット)を算出して、CRCチェック部206に入力する。
The CRC calculation unit 203 calculates CRC data for the encrypted data. The CRC calculation unit 203 calculates a 64-bit CRC data CD for the encrypted data (2048 bits) by the same calculation method as the CRC calculation unit 103 of the data encryption unit 10 and inputs it to the exclusive OR unit 205. To do.
The exclusive OR unit 205 performs an exclusive OR operation between the CRC encryption key KC input from the CRC encryption key generation unit 204 and the encrypted CRC data ED included in the encrypted packet data, and performs decryption CRC Data DD (64 bits) is calculated and input to the CRC check unit 206.

CRCチェック部206は、CRC計算部203から入力されるCRCデータと排他的論理和部205から入力される復号化CRCデータとの比較を行い、両者が一致するかどうかを判断する。両者が一致する場合には、受信した暗号化パケットデータには、誤りや改ざんが存在しないとして、復号化パケットデータ(2048ビット)をデータ復号化部20から出力する。両者が一致しなかった場合には、受信した暗号化パケットデータに、誤りもしくは改ざんが生じているとして、復号化パケットデータを破棄する。即ち、両者が一致しなかった場合には、データ復号化部20は、暗号化パケットデータの入力に対して、復号化パケットデータを出力しない。   The CRC check unit 206 compares the CRC data input from the CRC calculation unit 203 with the decoded CRC data input from the exclusive OR unit 205 and determines whether or not they match. If they match, the decrypted packet data (2048 bits) is output from the data decrypting unit 20 assuming that the received encrypted packet data does not contain any errors or tampering. If they do not match, the decrypted packet data is discarded, assuming that the received encrypted packet data contains an error or falsification. That is, when the two do not match, the data decryption unit 20 does not output the decrypted packet data in response to the input of the encrypted packet data.

パケットデータの先頭2バイト(ヘッダデータ)はコピー制御情報であり、本方式では、このデータの改ざんを検出することが可能である。以下、その理由について説明する。データ暗号化部10では、先頭64ビット(うち16ビットがコピー制御情報)と乱数生成部101が生成する乱数に基づいてCRC暗号鍵を生成している。また、データ復号化部20では、復号化パケットデータの先頭64ビット(うち16ビットがコピー制御情報)と乱数生成部201が生成する乱数に基づいてCRC暗号鍵を生成している。ここで、乱数生成部101と201は、同じ鍵と変形初期ベクタを用いて乱数生成を行っているので、CRC暗号鍵の生成に用いる乱数は同じである。従って、復号化パケットデータの先頭64ビットが、平文パケットデータの先頭64ビットが同じであれば、同じCRC暗号鍵を生成することになる。従って、先頭64ビットが改ざんされず、かつ、伝送路上で暗号化パケットデータに誤り(ビットの反転)が生じない限り、CRCチェック部206の判定はOKとなって、データ復号化部20から復号化パケットデータが出力される。一方、伝送路上で、ヘッダ部分のコピー制御情報が改ざんされた場合には、データ暗号化時とは違うCRC暗号鍵が生成されるので、違う復号化CRCデータが計算される。従って、たとえ伝送路上で暗号化パケットデータに誤りが生じていなくても、CRCチェック部206の判定はNGとなって、データ復号化部20から復号化パケットデータは出力されない。また、コピー制御情報の改ざんを行おうとする攻撃者は、秘密の鍵Kを知らないため、CRC暗号鍵生成に用いる乱数A、Bの値を知りえない。従って、コピー制御情報の改ざんを行ったうえで、その改ざんされた暗号化パケットに対するCRCデータを計算することはできても、それに対応するCRC暗号鍵を計算することができないので、上記改ざんされた暗号化パケットデータに対する暗号化CRCデータを計算することはできない。以上のことにより、本方式では、コピー制御情報を伝送路上で改ざんされた場合には、データ復号化側でそれを検出して、復号化データを出力しないようにすることが可能である。   The first two bytes (header data) of the packet data are copy control information, and in this method, alteration of this data can be detected. The reason will be described below. The data encryption unit 10 generates a CRC encryption key based on the first 64 bits (of which 16 bits are copy control information) and the random number generated by the random number generation unit 101. Further, the data decryption unit 20 generates a CRC encryption key based on the first 64 bits of the decrypted packet data (16 bits are copy control information) and the random number generated by the random number generation unit 201. Here, since the random number generation units 101 and 201 perform random number generation using the same key and modified initial vector, the random numbers used for generating the CRC encryption key are the same. Therefore, if the first 64 bits of the decrypted packet data are the same as the first 64 bits of the plaintext packet data, the same CRC encryption key is generated. Therefore, unless the first 64 bits are falsified and there is no error (bit inversion) in the encrypted packet data on the transmission path, the CRC check unit 206 determines OK and decrypts from the data decryption unit 20. Packet data is output. On the other hand, when the copy control information in the header portion is falsified on the transmission path, a different CRC encryption key from that at the time of data encryption is generated, so that different decrypted CRC data is calculated. Therefore, even if there is no error in the encrypted packet data on the transmission path, the CRC check unit 206 determines NG and the decrypted packet data is not output from the data decryption unit 20. Further, since an attacker who tries to falsify the copy control information does not know the secret key K, he cannot know the values of the random numbers A and B used for CRC encryption key generation. Therefore, after the copy control information has been tampered with, CRC data for the tampered encrypted packet can be calculated, but the corresponding CRC encryption key cannot be calculated. The encrypted CRC data for the encrypted packet data cannot be calculated. As described above, in this method, when the copy control information is falsified on the transmission path, it is possible to detect it on the data decoding side and not output the decoded data.

また、改ざん検出は、通信誤り検出用に元々付加されているCRCデータの替わりに付加した同サイズのデータに基づいて行うため、改ざん検出用データを追加することによるデータ量の増加はない。更に、データ暗号化部10の処理をハードウェアで実現する場合、「排他的論理和部102の処理を行ってCRC計算部103の処理を行う」部分の処理(平文パケットデータの暗号化に関わる処理)と、「CRC暗号鍵生成部104の処理を行って排他的論理和演算部105の処理を行う」部分の処理(改ざん検出のための処理)とは、並列化することが可能であるから、改ざん検出を行うことにより、データ暗号化処理に更に時間がかかることにはならない。同様に、データ復号化部20をハードウェアで実現する場合にも、「排他的論理和部202の処理」と「CRC計算部203の処理」(いずれも平文パケットデータの暗号化に関わる処理)と、「CRC暗号鍵生成部204の処理を行って排他的論理和演算部205の処理を行う」部分の処理(改ざん検出のための処理)とは、並列化することが可能であるから、改ざん検出を行うことにより、データ復号化処理に更に時間がかかることにはならない。   Further, since the alteration detection is performed based on the same size data added instead of the CRC data originally added for communication error detection, there is no increase in the data amount due to the addition of the alteration detection data. Further, when the processing of the data encryption unit 10 is realized by hardware, the processing of the part “perform processing of the exclusive OR unit 102 and processing of the CRC calculation unit 103” (related to encryption of plaintext packet data) Processing) and the processing (processing for tampering detection) of the portion “processing the CRC encryption key generation unit 104 and processing the exclusive OR operation unit 105” can be performed in parallel. Thus, by detecting falsification, the data encryption process does not take much longer. Similarly, when the data decryption unit 20 is realized by hardware, “processing of the exclusive OR unit 202” and “processing of the CRC calculation unit 203” (both processing related to encryption of plaintext packet data). Since the processing (processing for tampering detection) of the portion “processing the CRC encryption key generation unit 204 and processing the exclusive OR operation unit 205” (processing for falsification detection) can be performed in parallel, By performing falsification detection, the data decoding process does not take much longer.

(実施の形態の変形例)
本発明の実施の形態における変形例を説明する。
図5は、本発明の実施の形態の変形例におけるデータ送受信システムの構成を示したブロック図である。構成及び、各部の役割は、図1を用いて説明したデータ送受信システムの構成と同一であるから詳細は省略する。本変形例においては、上記の実施の形態と比べてデータ暗号化部30とデータ復号化部40の処理だけが異なっているので、以下その相違点を中心に説明を行う。
(Modification of the embodiment)
A modification in the embodiment of the present invention will be described.
FIG. 5 is a block diagram showing a configuration of a data transmission / reception system in a modification of the embodiment of the present invention. The configuration and the role of each unit are the same as the configuration of the data transmission / reception system described with reference to FIG. In the present modification, only the processes of the data encryption unit 30 and the data decryption unit 40 are different from those of the above-described embodiment. Therefore, the following description will be focused on the differences.

(データ暗号化部30の処理詳細)
図6は、データ暗号化部30の構成を示すブロック図である。データ暗号化部30が、データ暗号化部10と異なる点は、CRC暗号鍵生成部304の処理だけである。即ち、データ暗号化部10では、CRC暗号鍵生成部104は、平文パケットデータの先頭64ビットを元にCRC暗号鍵を生成していたが、データ暗号化部30では、CRC暗号鍵生成部304は、上記データの代わりに暗号化パケットデータの先頭64ビットを元にCRC暗号鍵を生成している。そのために、CRC暗号鍵生成部304は、排他的論理和部302が、平文パケットデータの先頭64ビットデータと乱数生成部301から入力される乱数データとの排他的論理和演算を行って、64ビットの暗号化データを生成した後に、CRC暗号鍵生成処理を行う必要がある。それ以外の処理詳細は、データ暗号化部10と全く同じであるから説明は省略する。
(Details of processing of the data encryption unit 30)
FIG. 6 is a block diagram illustrating a configuration of the data encryption unit 30. The data encryption unit 30 is different from the data encryption unit 10 only in the processing of the CRC encryption key generation unit 304. That is, in the data encryption unit 10, the CRC encryption key generation unit 104 generates a CRC encryption key based on the first 64 bits of the plaintext packet data, but in the data encryption unit 30, the CRC encryption key generation unit 304 Generates a CRC encryption key based on the first 64 bits of the encrypted packet data instead of the above data. For this purpose, in the CRC encryption key generation unit 304, the exclusive OR unit 302 performs an exclusive OR operation on the first 64-bit data of the plaintext packet data and the random number data input from the random number generation unit 301. It is necessary to perform CRC encryption key generation processing after generating bit-encrypted data. Since the other processing details are exactly the same as those of the data encryption unit 10, a description thereof will be omitted.

(データ復号化部40の処理詳細)
図7は、データ復号化部40の構成を示すブロック図である。データ復号化部40が、データ復号化部20と異なる点は、CRC暗号鍵生成部404の処理だけである。即ち、データ復号化部20では、CRC暗号鍵生成部204は、復号化パケットデータの先頭64ビットを元にCRC暗号鍵を生成していたが、データ復号化部40では、CRC暗号鍵生成部404は、上記データの代わりに暗号化パケットデータの先頭64ビットを元にCRC暗号鍵を生成している。データ復号化部20の場合は、排他的論理和部202が、暗号化パケットデータの先頭64ビットデータと乱数生成部201から入力される乱数データとの排他的論理和演算を行って64ビットの復号化データを生成した後に、そのデータを用いてCRC暗号鍵生成処理を行う必要があった。しかし、本変形例のデータ復号化部40では、排他的論理和部302の処理を待たずに、データ復号化部40に入力された暗号化パケットデータの先頭64ビットからCRC暗号鍵生成処理を開始できる。このように、本変形例では、CRC暗号鍵生成処理が、より早いタイミングで開始できるため、データ復号化に関する処理と、データ改ざん検出に関する処理との並列化がより効率よく行うことができるので、暗号化パケットデータに対する復号化処理がより高速に行うことが可能となる。
(Details of processing of the data decoding unit 40)
FIG. 7 is a block diagram showing a configuration of the data decoding unit 40. The data decryption unit 40 is different from the data decryption unit 20 only in the processing of the CRC encryption key generation unit 404. That is, in the data decryption unit 20, the CRC encryption key generation unit 204 generates a CRC encryption key based on the first 64 bits of the decrypted packet data, but in the data decryption unit 40, the CRC encryption key generation unit 404 generates a CRC encryption key based on the first 64 bits of the encrypted packet data instead of the above data. In the case of the data decryption unit 20, the exclusive OR unit 202 performs an exclusive OR operation on the first 64-bit data of the encrypted packet data and the random number data input from the random number generation unit 201, thereby performing 64-bit After generating the decrypted data, it is necessary to perform a CRC encryption key generation process using the data. However, in the data decryption unit 40 of this modification, the CRC encryption key generation processing is performed from the first 64 bits of the encrypted packet data input to the data decryption unit 40 without waiting for the processing of the exclusive OR unit 302. You can start. In this way, in this modification, since the CRC encryption key generation process can be started at an earlier timing, parallelization of the process related to data decryption and the process related to data alteration detection can be performed more efficiently. It is possible to perform the decryption process on the encrypted packet data at a higher speed.

(その他の変形例)
なお、本発明は、上記の実施の形態に限定されないのはもちろんである。以下のような場合も本発明に含まれる。
(1)各データ、フィールドのデータサイズはあくまでも一例であって、他のデータサイズであってもよい。
(Other variations)
Needless to say, the present invention is not limited to the above-described embodiment. The following cases are also included in the present invention.
(1) The data size of each data and field is merely an example, and other data sizes may be used.

(2)乱数生成部で用いる乱数生成方式は、あるソースとなるデータ(実施の形態では、鍵、変形初期ベクタに対応)を元にして乱数列が生成され、かつ、ソースとなるデータが同じであれば、常に同じ乱数系列が出力される方式であれば、何でも良い。他の乱数生成方式の例としては、PANAMAや、ハッシュ関数、ブロック暗号を用いた方式などがある。   (2) The random number generation method used in the random number generation unit is that a random number sequence is generated based on a certain source data (corresponding to a key and a modified initial vector in the embodiment), and the source data is the same. As long as the same random number sequence is always output, any method may be used. Examples of other random number generation methods include a method using PANAMA, a hash function, and a block cipher.

(3)本実施の形態では、CRCデータを用いて誤り有無の判定を行っていたが、誤り訂正を行う、もしくは、誤り訂正と誤り検出を行うようにしてもよい。誤り訂正を行う場合には、改ざん検出対象データが改ざんされると、CRC暗号鍵のデータは大幅に変わる(本来計算されるべきCRC暗号鍵と多数のビットが異なる)ので、復号化CRCデータは、誤り訂正能力の限界を超えたビットが変わってしまう。したがって、正しく誤り訂正がされなくなるので、パケットデータは壊れてしまい、コンテンツは正しく再生されない。そのため、改ざん検出対象データの改ざんを防止することができる。また、誤り訂正と誤り検出を行う場合には、上記と同じ理由で誤り訂正能力の限界以上の誤りが検出されたとしてパケットデータは破棄されてしまうのでコンテンツの再生は行えなくなる。したがって、改ざん検出対象データに対する改ざんを防止できる。   (3) In the present embodiment, the presence or absence of an error is determined using CRC data. However, error correction may be performed, or error correction and error detection may be performed. When performing error correction, if the falsification detection target data is falsified, the CRC encryption key data changes significantly (the CRC encryption key to be originally calculated differs in a number of bits), so the decrypted CRC data is Bits that exceed the limit of error correction capability will change. Therefore, since error correction is not performed correctly, the packet data is broken and the content is not reproduced correctly. Therefore, it is possible to prevent falsification of the falsification detection target data. Further, when error correction and error detection are performed, packet data is discarded even if an error exceeding the limit of error correction capability is detected for the same reason as described above, so that the content cannot be reproduced. Therefore, it is possible to prevent falsification of the falsification detection target data.

(4)本実施の形態では、改ざん検出対象であるコピー制御情報(16ビット)を含んだ64ビットデータからCRC暗号鍵を生成しているが、これは、コピー制御だけを取り出して、それに48ビットの固定値を結合した64ビットデータであっても良い。このとき、48ビットの固定値は、なんらかの方法(たとえば、予めシステム固定値として決めておくなど)で、データ暗号化部とデータ復号化部の間で共有化しておく必要がある。このようにしておくと、CRCデータを誤り検出ではなく、誤り訂正目的で用いる場合には以下のようなメリットがある。実施の形態においては、CRC暗号鍵の生成に用いるパケットデータの先頭64ビットのうち、コピー制御情報(16ビット)を除く48ビットの1ビットにエラーが生じてビット反転されてしまった場合でも、CRC暗号鍵が全く異なった値として計算されてしまう。したがって、その結果として復号化されるCRCデータは、全く異なった値となってしまう。そのため、1ビットのエラーが生じただけあるにも関わらず、CRCの誤り訂正能力の限界を超えた誤りが生じたことと同じことになり、誤り訂正エラーとなってパケットデータは壊れてしまう。つまり、データ改ざん検出対象部分以外でビット反転が生じ、それが、CRCの誤り訂正能力の範囲内であっても、誤り訂正エラーとなる恐れがあった。しかし、この変形例では、改ざん検出を行いたいデータのみからCRC暗号鍵を生成するため、上記のように、改ざん検出対象以外の部分でビット反転が起きても、それがCRCの誤り訂正能力の範囲内であれば、正しく誤り訂正することが可能となる。また上記に限らず、CRC鍵を生成する際にパケットデータから取り出すデータは、少なくとも改ざん検出を行いたい部分が含まれていれば、どのような取り出し方をしても良い。   (4) In the present embodiment, a CRC encryption key is generated from 64-bit data including copy control information (16 bits) that is a target for falsification detection. It may be 64-bit data obtained by combining fixed values of bits. At this time, the 48-bit fixed value needs to be shared between the data encryption unit and the data decryption unit by some method (for example, determined in advance as a system fixed value). In this way, there are the following merits when CRC data is used not for error detection but for error correction. In the embodiment, even if an error occurs in one bit of 48 bits excluding copy control information (16 bits) out of the first 64 bits of packet data used for generating a CRC encryption key, the bit is inverted. The CRC encryption key is calculated as a completely different value. Therefore, the CRC data that is decoded as a result has a completely different value. Therefore, even though a 1-bit error has occurred, this is the same as an error that exceeds the limit of the error correction capability of the CRC, resulting in an error correction error and packet data being corrupted. That is, bit inversion occurs in a portion other than the data alteration detection target portion, and even if it is within the range of the error correction capability of the CRC, an error correction error may occur. However, in this modified example, since the CRC encryption key is generated only from the data to be detected for falsification, as described above, even if bit inversion occurs in a portion other than the falsification detection target, this is the CRC error correction capability. If it is within the range, it becomes possible to correct the error correctly. Further, the present invention is not limited to the above, and any data can be extracted from the data extracted from the packet data when generating the CRC key as long as at least a portion for which alteration detection is desired is included.

(5)CRC暗号鍵生成部の処理は、実施の形態の方式でなくてもよい。例えば、入力乱数を鍵として入力されるパケットデータを暗号化あるいは復号化する暗号処理(例えば、AES暗号や、DES暗号など)を用いても良い。あるいは、前記データを結合したデータにハッシュ関数処理(例えば、SHA−1、MD5、SHA−256など)を行うような処理であっても良い。あるいは、データ暗号化部とデータ復号化部で秘密に共有化された秘密の変換アルゴリズムであってもよい。   (5) The processing of the CRC encryption key generation unit may not be the method of the embodiment. For example, encryption processing (for example, AES encryption or DES encryption) that encrypts or decrypts packet data that is input using an input random number as a key may be used. Alternatively, it may be a process of performing hash function processing (for example, SHA-1, MD5, SHA-256, etc.) on the data obtained by combining the data. Alternatively, it may be a secret conversion algorithm that is secretly shared between the data encryption unit and the data decryption unit.

(6)CRC暗号鍵とCRCデータとから暗号化CRCデータを計算する処理としては、排他的論理和演算以外であっても良い。例えば、CRC暗号鍵とCRCデータとの算術加算を行った結果を暗号化CRCデータとしても良い。このとき、暗号化CRCデータからCRC暗号鍵を引き算する処理によって復号化CRCデータを算出すればよい。なお、この他にもCRC暗号鍵とCRCデータとから暗号化CRCデータを得る変換と、暗号化CRCデータとCRC暗号鍵から復号化CRCデータを得る変換とが逆変換の関係にある限り、どのような変換を用いてもよい。   (6) The process for calculating the encrypted CRC data from the CRC encryption key and the CRC data may be other than the exclusive OR operation. For example, the result of arithmetic addition of a CRC encryption key and CRC data may be used as encrypted CRC data. At this time, the decrypted CRC data may be calculated by the process of subtracting the CRC encryption key from the encrypted CRC data. In addition to this, as long as the conversion for obtaining the encrypted CRC data from the CRC encryption key and the CRC data and the conversion for obtaining the decrypted CRC data from the encrypted CRC data and the CRC encryption key are in a reverse conversion relation, Such conversion may be used.

また、CRC暗号鍵を生成するために、乱数生成器の生成する乱数を用いているが、これは、データ改ざんを行う者が知りえない、もしくは、計算し得ないデータであれば何でもよい。例えば、乱数生成部に入力される鍵データであってもよい。
(7)本実施の形態では、パケットデータの暗号化・復号化処理としてストリーム暗号方式を用いているが、ブロック暗号方式を用いてもよい。この場合、図3のデータ暗号化部10において、乱数生成部101と排他的論理和部102が、ブロック暗号化処理部に置き換わる。このとき、ブロック暗号化処理部は、例えば鍵Kと変形初期ベクタを用いたAES暗号のCBC暗号化処理となる。また、CRC暗号鍵生成部104は、乱数生成部101から入力される乱数の代わりのデータとして鍵Kを用いればよい。
In addition, although a random number generated by a random number generator is used to generate a CRC encryption key, this may be any data that cannot be calculated or calculated by a person who alters the data. For example, it may be key data input to the random number generation unit.
(7) In this embodiment, the stream encryption method is used as the encryption / decryption processing of the packet data, but a block encryption method may be used. In this case, in the data encryption unit 10 of FIG. 3, the random number generation unit 101 and the exclusive OR unit 102 are replaced with a block encryption processing unit. At this time, the block encryption processing unit performs CES encryption processing of AES encryption using, for example, the key K and the modified initial vector. The CRC encryption key generation unit 104 may use the key K as data instead of the random number input from the random number generation unit 101.

(8)CRC計算部のCRC計算方法は、本実施例の方式以外の方式を用いても良い。このとき、CRC計算の方式によっては、CRCデータのサイズ(Nビット)とCRC暗号鍵のサイズ(Mビット)が一致しない場合も起こり得るが、CRCデータサイズの方がCRC暗号鍵のサイズよりも小さい場合(N<M)には、CRC暗号鍵のうちNビットだけを使って暗号化CRCデータを計算するようにすれば良い。CRC暗号鍵のサイズの方がCRCデータサイズよりも大きい場合(N>M)には、CRC暗号鍵データを所定個数だけ複製したものを連結してNビットデータとした上で、暗号化CRCデータを計算するようにすれば良い。   (8) As a CRC calculation method of the CRC calculation unit, a method other than the method of this embodiment may be used. At this time, depending on the CRC calculation method, the CRC data size (N bits) may not match the CRC encryption key size (M bits), but the CRC data size is larger than the CRC encryption key size. If it is small (N <M), the encrypted CRC data may be calculated using only N bits of the CRC encryption key. When the size of the CRC encryption key is larger than the CRC data size (N> M), the encrypted CRC data is obtained by concatenating a predetermined number of copies of the CRC encryption key data into N-bit data. Should be calculated.

(9)本実施の形態では、CRC暗号鍵の生成に、乱数生成部が生成する1番目、2番目の乱数データを用いているが、これは、3番目、4番目など、任意のタイミングで生成される乱数であってもよい。但し、どのタイミングで取り出した乱数を用いてCRC暗号鍵を生成するかの情報は、データ暗号化部、データ復号化部で共有化しておく必要がある。   (9) In the present embodiment, the first and second random number data generated by the random number generation unit is used to generate the CRC encryption key, but this may be performed at an arbitrary timing such as the third or fourth. It may be a random number that is generated. However, it is necessary for the data encryption unit and the data decryption unit to share information on the timing at which the CRC encryption key is generated using the random number extracted.

(10)上記の各装置は、具体的には、マイクロプロセッサ、ROM、RAM、ハードディスクユニット、ディスプレイユニット、キーボード、マウスなどから構成されるコンピュータシステムである。前記RAMまたはハードディスクユニットには、コンピュータプログラムが記憶されている。前記マイクロプロセッサが、前記コンピュータプログラムにしたがって動作することにより、各装置は、その機能を達成する。ここでコンピュータプログラムは、所定の機能を達成するために、コンピュータに対する指令を示す命令コードが複数個組み合わされて構成されたものである。   (10) Each of the above devices is specifically a computer system including a microprocessor, ROM, RAM, a hard disk unit, a display unit, a keyboard, a mouse, and the like. A computer program is stored in the RAM or hard disk unit. Each device achieves its functions by the microprocessor operating according to the computer program. Here, the computer program is configured by combining a plurality of instruction codes indicating instructions for the computer in order to achieve a predetermined function.

(11)上記の各装置を構成する構成要素の一部または全部は、1個のシステムLSI(Large Scale Integration:大規模集積回路)から構成されているとしてもよい。システムLSIは、複数の構成部を1個のチップ上に集積して製造された超多機能LSIであり、具体的には、マイクロプロセッサ、ROM、RAMなどを含んで構成されるコンピュータシステムである。前記RAMには、コンピュータプログラムが記憶されている。前記マイクロプロセッサが、前記コンピュータプログラムにしたがって動作することにより、システムLSIは、その機能を達成する。   (11) A part or all of the components constituting each of the above devices may be configured by one system LSI (Large Scale Integration). The system LSI is a super multifunctional LSI manufactured by integrating a plurality of components on one chip, and specifically, a computer system including a microprocessor, a ROM, a RAM, and the like. . A computer program is stored in the RAM. The system LSI achieves its functions by the microprocessor operating according to the computer program.

また、上記の各装置を構成する構成要素の各部は、個別に1チップ化されていても良いし、一部又は全てを含むように1チップ化されてもよい。
また、ここでは、システムLSIとしたが、集積度の違いにより、IC、LSI、スーパーLSI、ウルトラLSIと呼称されることもある。また、集積回路化の手法はLSIに限るものではなく、専用回路又は汎用プロセッサで実現してもよい。LSI製造後に、プログラムすることが可能なFPGA(Field Programmable Gate Array)や、LSI内部の回路セルの接続や設定を再構成可能なリコンフィギュラブル・プロセッサーを利用しても良い。
In addition, each part of the components constituting each of the above devices may be individually made into one chip, or may be made into one chip so as to include a part or all of them.
Although the system LSI is used here, it may be called IC, LSI, super LSI, or ultra LSI depending on the degree of integration. Further, the method of circuit integration is not limited to LSI's, and implementation using dedicated circuitry or general purpose processors is also possible. An FPGA (Field Programmable Gate Array) that can be programmed after manufacturing the LSI or a reconfigurable processor that can reconfigure the connection and setting of circuit cells inside the LSI may be used.

さらには、半導体技術の進歩又は派生する別技術によりLSIに置き換わる集積回路化の技術が登場すれば、当然、その技術を用いて機能ブロックの集積化を行ってもよい。バイオ技術の適用等が可能性としてありえる。
(12)上記の各装置を構成する構成要素の一部または全部は、各装置に脱着可能なICカードまたは単体のモジュールから構成されているとしてもよい。前記ICカードまたは前記モジュールは、マイクロプロセッサ、ROM、RAMなどから構成されるコンピュータシステムである。前記ICカードまたは前記モジュールは、上記の超多機能LSIを含むとしてもよい。マイクロプロセッサが、コンピュータプログラムにしたがって動作することにより、前記ICカードまたは前記モジュールは、その機能を達成する。このICカードまたはこのモジュールは、耐タンパ性を有するとしてもよい。
Further, if integrated circuit technology comes out to replace LSI's as a result of the advancement of semiconductor technology or a derivative other technology, it is naturally also possible to carry out function block integration using this technology. Biotechnology can be applied.
(12) A part or all of the components constituting each of the above devices may be configured as an IC card that can be attached to and detached from each device or a single module. The IC card or the module is a computer system including a microprocessor, a ROM, a RAM, and the like. The IC card or the module may include the super multifunctional LSI described above. The IC card or the module achieves its function by the microprocessor operating according to the computer program. This IC card or this module may have tamper resistance.

(13)本発明は、上記に示す方法であるとしてもよい。また、これらの方法をコンピュータにより実現するコンピュータプログラムであるとしてもよいし、前記コンピュータプログラムからなるデジタル信号であるとしてもよい。
また、本発明は、前記コンピュータプログラムまたは前記デジタル信号をコンピュータ読み取り可能な記録媒体、例えば、フレキシブルディスク、ハードディスク、CD−ROM、MO、DVD、DVD−ROM、DVD−RAM、BD(Blu−ray Disc)、半導体メモリなどに記録したものとしてもよい。また、これらの記録媒体に記録されている前記デジタル信号であるとしてもよい。
(13) The present invention may be the method described above. Further, the present invention may be a computer program that realizes these methods by a computer, or may be a digital signal composed of the computer program.
The present invention also provides a computer-readable recording medium such as a flexible disk, hard disk, CD-ROM, MO, DVD, DVD-ROM, DVD-RAM, BD (Blu-ray Disc). ), Recorded in a semiconductor memory or the like. The digital signal may be recorded on these recording media.

また、本発明は、前記コンピュータプログラムまたは前記デジタル信号を、電気通信回線、無線または有線通信回線、インターネットを代表とするネットワーク、データ放送等を経由して伝送するものとしてもよい。
また、本発明は、マイクロプロセッサとメモリを備えたコンピュータシステムであって、前記メモリは、上記コンピュータプログラムを記憶しており、前記マイクロプロセッサは、前記コンピュータプログラムにしたがって動作するとしてもよい。
In the present invention, the computer program or the digital signal may be transmitted via an electric communication line, a wireless or wired communication line, a network represented by the Internet, a data broadcast, or the like.
The present invention may be a computer system including a microprocessor and a memory, wherein the memory stores the computer program, and the microprocessor operates according to the computer program.

また、前記プログラムまたは前記デジタル信号を前記記録媒体に記録して移送することにより、または前記プログラムまたは前記デジタル信号を前記ネットワーク等を経由して移送することにより、独立した他のコンピュータシステムにより実施するとしてもよい。
(14)上記実施の形態及び上記変形例をそれぞれ組み合わせるとしてもよい。
In addition, the program or the digital signal is recorded on the recording medium and transferred, or the program or the digital signal is transferred via the network or the like, and executed by another independent computer system. It is good.
(14) The above embodiment and the above modifications may be combined.

本発明にかかるデータ暗号処理装置は、高速な暗号処理を実現しながら、かつ、改ざん検出用のデータを付加することなく、伝送中のコンテンツに含まれるコピー制御情報の改ざんを検出可能であるという特徴を有するので、映像・音楽コンテンツのストリーミング配信システムなどのような、高速伝送、高速処理、でかつ、データ改ざん防止の実現が求められるシステムで使用するためのデータ暗号処理装置の実現に有用である。   The data encryption processing device according to the present invention can detect falsification of copy control information included in the content being transmitted while realizing high-speed encryption processing and without adding data for falsification detection. Because it has features, it is useful for realizing data encryption processing devices for use in systems that require high-speed transmission, high-speed processing, and prevention of data tampering, such as streaming distribution systems for video and music content. is there.

本発明の実施の形態に係るデータ送受信システムの構成を示すブロック図The block diagram which shows the structure of the data transmission / reception system which concerns on embodiment of this invention 本発明の実施の形態に係る平文ストリームデータの構成を示すブロック図The block diagram which shows the structure of the plaintext stream data which concerns on embodiment of this invention 本発明の実施の形態に係るデータ暗号化部10の構成を示すブロック図The block diagram which shows the structure of the data encryption part 10 which concerns on embodiment of this invention. 本発明の実施の形態に係るデータ復号化部20の構成を示すブロック図The block diagram which shows the structure of the data decoding part 20 which concerns on embodiment of this invention. 本発明の実施の形態の変形例に係るデータ送受信システムの構成を示すブロック図The block diagram which shows the structure of the data transmission / reception system which concerns on the modification of embodiment of this invention. 本発明の実施の形態の変形例に係るデータ暗号化部30の構成を示すブロック図The block diagram which shows the structure of the data encryption part 30 which concerns on the modification of embodiment of this invention. 本発明の実施の形態の変形例に係るデータ復号化部40の構成を示すブロック図The block diagram which shows the structure of the data decoding part 40 which concerns on the modification of embodiment of this invention.

符号の説明Explanation of symbols

1 データ送信装置
2 データ受信装置
10 データ暗号化部
11 認証鍵共有処理部
12 ストリームデータ生成部
20 データ復号化部
21 認証鍵共有処理部
22 ストリームデータ再生部
100 初期ベクタ更新部
101 乱数生成部
102 排他的論理和部
103 CRC計算部
104 CRC暗号鍵生成部
105 排他的論理和部
200 初期ベクタ更新部
201 乱数生成部
202 排他的論理和部
203 CRC計算部
204 CRC暗号鍵生成部
205 排他的論理和部
206 CRCチェック部
DESCRIPTION OF SYMBOLS 1 Data transmitter 2 Data receiver 10 Data encryption part 11 Authentication key sharing process part 12 Stream data generation part 20 Data decryption part 21 Authentication key share processing part 22 Stream data reproduction | regeneration part 100 Initial vector update part 101 Random number generation part 102 Exclusive OR section 103 CRC calculation section 104 CRC encryption key generation section 105 Exclusive OR section 200 Initial vector update section 201 Random number generation section 202 Exclusive OR section 203 CRC calculation section 204 CRC encryption key generation section 205 Exclusive logic Japanese part 206 CRC check part

Claims (8)

平文データを暗号化して暗号文データを生成するデータ暗号処理装置であって、前記平文データは、改ざん検出対象データを含み、
前記データ暗号処理装置は、
鍵データを用いて前記平文データを暗号化して暗号化データを生成するデータ暗号変換部と、
前記暗号化データに対して誤り検出用データを生成する誤り検出用データ生成部と、
前記改ざん検出対象データと前記鍵データに基づいて誤り検出用データ暗号鍵を生成する誤り検出用データ暗号鍵生成部と、
前記誤り検出用データ暗号鍵を用いて前記誤り検出用データを暗号化して暗号化誤り検出用データを生成する誤り検出用データ暗号化部と、
前記暗号化データと前記暗号化誤り検出用データを元に暗号文データを作成して出力する暗号文データ出力部と
を備えることを特徴とするデータ暗号処理装置。
A data encryption processing device that encrypts plaintext data to generate ciphertext data, wherein the plaintext data includes alteration detection target data,
The data encryption processing device includes:
A data encryption conversion unit that encrypts the plaintext data using key data to generate encrypted data;
An error detection data generator for generating error detection data for the encrypted data;
An error detection data encryption key generation unit that generates an error detection data encryption key based on the falsification detection target data and the key data;
An error detection data encryption unit that encrypts the error detection data using the error detection data encryption key to generate encrypted error detection data;
A data cipher processing apparatus comprising: a ciphertext data output unit that creates ciphertext data based on the encrypted data and the encryption error detection data and outputs the ciphertext data.
平文データを暗号化して暗号文データを生成するデータ暗号処理方法であって、前記平文データは、改ざん検出対象データを含み、
前記データ暗号処理方法は、
鍵データを用いて前記平文データを暗号化して暗号化データを生成するデータ暗号変換ステップと、
前記暗号化データに対して誤り検出用データを生成する誤り検出用データ生成ステップと、
前記改ざん検出対象データと前記鍵データに基づいて誤り検出用データ暗号鍵を生成する誤り検出用データ暗号鍵生成ステップと、
前記誤り検出用データ暗号鍵を用いて前記誤り検出用データを暗号化して暗号化誤り検出用データを生成する誤り検出用データ暗号化ステップと、
前記暗号化データと前記暗号化誤り検出用データを元に暗号文データを作成して出力する暗号文データ出力ステップと
を含むことを特徴とするデータ暗号処理方法。
A data encryption processing method for generating plaintext data by encrypting plaintext data, wherein the plaintext data includes alteration detection target data,
The data encryption processing method includes:
A data encryption conversion step for generating encrypted data by encrypting the plaintext data using key data;
An error detection data generation step for generating error detection data for the encrypted data;
An error detection data encryption key generation step for generating an error detection data encryption key based on the falsification detection target data and the key data;
An error detection data encryption step for encrypting the error detection data using the error detection data encryption key to generate encrypted error detection data;
And a ciphertext data output step of generating and outputting ciphertext data based on the encrypted data and the encryption error detection data.
平文データを暗号化して暗号文データを生成するデータ暗号処理プログラムであって、前記平文データは、改ざん検出対象データを含み、
前記データ暗号処理プログラムは、
鍵データを用いて前記平文データを暗号化して暗号化データを生成するデータ暗号変換ステップと、
前記暗号化データに対して誤り検出用データを生成する誤り検出用データ生成ステップと、
前記改ざん検出対象データと前記鍵データに基づいて誤り検出用データ暗号鍵を生成する誤り検出用データ暗号鍵生成ステップと、
前記誤り検出用データ暗号鍵を用いて前記誤り検出用データを暗号化して暗号化誤り検出用データを生成する誤り検出用データ暗号化ステップと、
前記暗号化データと前記暗号化誤り検出用データを元に暗号文データを作成して出力する暗号文データ出力ステップと
を含むことを特徴とするデータ暗号処理プログラム。
A data encryption processing program for encrypting plaintext data to generate ciphertext data, wherein the plaintext data includes alteration detection target data,
The data encryption processing program is:
A data encryption conversion step for generating encrypted data by encrypting the plaintext data using key data;
An error detection data generation step for generating error detection data for the encrypted data;
An error detection data encryption key generation step for generating an error detection data encryption key based on the falsification detection target data and the key data;
An error detection data encryption step for encrypting the error detection data using the error detection data encryption key to generate encrypted error detection data;
A data encryption processing program comprising: a ciphertext data output step of generating and outputting ciphertext data based on the encrypted data and the encryption error detection data.
平文データを暗号化して暗号文データを生成する集積回路であって、前記平文データは、改ざん検出対象データを含み、
前記集積回路は、
鍵データを用いて前記平文データを暗号化して暗号化データを生成するデータ暗号変換部と、
前記暗号化データに対して誤り検出用データを生成する誤り検出用データ生成部と、
前記改ざん検出対象データと前記鍵データに基づいて誤り検出用データ暗号鍵を生成する誤り検出用データ暗号鍵生成部と、
前記誤り検出用データ暗号鍵を用いて前記誤り検出用データを暗号化して暗号化誤り検出用データを生成する誤り検出用データ暗号化部と、
前記暗号化データと前記暗号化誤り検出用データを元に暗号文データを作成して出力する暗号文データ出力部と
を備えることを特徴とする集積回路。
An integrated circuit that encrypts plaintext data to generate ciphertext data, the plaintext data including falsification detection target data,
The integrated circuit comprises:
A data encryption conversion unit that encrypts the plaintext data using key data to generate encrypted data;
An error detection data generator for generating error detection data for the encrypted data;
An error detection data encryption key generation unit that generates an error detection data encryption key based on the falsification detection target data and the key data;
An error detection data encryption unit that encrypts the error detection data using the error detection data encryption key to generate encrypted error detection data;
An integrated circuit comprising: a ciphertext data output unit that creates ciphertext data based on the encrypted data and the encryption error detection data and outputs the ciphertext data.
暗号文データを復号化して復号文データを生成するデータ復号処理装置であって、
前記暗号文データは、暗号化誤り検出用データを含み、
前記データ復号処理装置は、
鍵データを用いて前記暗号文データを復号化して復号化データを生成し、前記復号化データは改ざん検出対象データを含むデータ復号変換部と、
前記暗号文データに対して誤り検出用データを生成する誤り検出用データ生成部と、
前記改ざん検出対象データと前記鍵データに基づいて誤り検出用データ暗号鍵を生成する誤り検出用データ暗号鍵生成部と、
前記誤り検出用データ暗号鍵を用いて前記暗号化誤り検出用データを復号化して復号化誤り検出用データを生成する改ざん検出用データ復号化部と、
前記復号化誤り検出用データと前記誤り検出用データとに基づいて、前記暗号文データにおける誤りまたは改ざんの有無を判断する誤り検出用データ確認部と、
前記復号化データを元に復号文データを作成して出力する復号文データ出力部と
を備えることを特徴とするデータ復号処理装置。
A data decryption processing device for decrypting ciphertext data to generate decrypted text data,
The ciphertext data includes encryption error detection data,
The data decoding processing device includes:
Decrypting the ciphertext data using key data to generate decrypted data, and the decrypted data includes a data decryption conversion unit including falsification detection target data;
An error detection data generation unit for generating error detection data for the ciphertext data;
An error detection data encryption key generation unit that generates an error detection data encryption key based on the falsification detection target data and the key data;
A tampering detection data decryption unit that decrypts the encryption error detection data using the error detection data encryption key to generate decryption error detection data;
An error detection data confirmation unit that determines whether there is an error or falsification in the ciphertext data based on the decryption error detection data and the error detection data;
A data decryption processing apparatus comprising: a decrypted text data output unit that creates and outputs decrypted text data based on the decrypted data.
暗号文データを復号化して復号文データを生成するデータ復号処理方法であって、前記暗号文データは、暗号化誤り検出用データを含み、
前記データ復号処理方法は、
鍵データを用いて前記暗号文データを復号化して復号化データを生成し、前記復号化データは改ざん検出対象データを含むデータ復号変換ステップと、
前記暗号文データに対して誤り検出用データを生成する誤り検出用データ生成ステップと、
前記改ざん検出対象データと前記鍵データに基づいて誤り検出用データ暗号鍵を生成する誤り検出用データ暗号鍵生成ステップと、
前記誤り検出用データ暗号鍵を用いて前記暗号化誤り検出用データを復号化して復号化誤り検出用データを生成する改ざん検出用データ復号化ステップと、
前記復号化誤り検出用データと前記誤り検出用データとに基づいて、前記暗号文データにおける誤りまたは改ざんの有無を判断する誤り検出用データ確認ステップと、
前記復号化データを元に復号文データを作成して出力する復号文データ出力ステップと
を含むことを特徴とするデータ復号処理方法。
A data decryption method for decrypting ciphertext data to generate decrypted text data, wherein the ciphertext data includes encryption error detection data,
The data decoding processing method includes:
Decrypting the ciphertext data using key data to generate decrypted data, wherein the decrypted data includes a data decryption conversion step including alteration detection target data;
An error detection data generation step for generating error detection data for the ciphertext data;
An error detection data encryption key generation step for generating an error detection data encryption key based on the falsification detection target data and the key data;
A tampering detection data decryption step of decrypting the encryption error detection data using the error detection data encryption key to generate decryption error detection data;
An error detection data confirmation step for determining whether there is an error or falsification in the ciphertext data based on the decryption error detection data and the error detection data;
And a decrypted text data output step of generating decrypted text data based on the decrypted data and outputting the decrypted text data.
暗号文データを復号化して復号文データを生成するデータ復号処理プログラムであって、前記暗号文データは、暗号化誤り検出用データを含み、
前記データ復号処理プログラムは、
鍵データを用いて前記暗号文データを復号化して復号化データを生成し、前記復号化データは改ざん検出対象データを含むデータ復号変換ステップと、
前記暗号文データに対して誤り検出用データを生成する誤り検出用データ生成ステップと、
前記改ざん検出対象データと前記鍵データに基づいて誤り検出用データ暗号鍵を生成する誤り検出用データ暗号鍵生成ステップと、
前記誤り検出用データ暗号鍵を用いて前記暗号化誤り検出用データを復号化して復号化誤り検出用データを生成する改ざん検出用データ復号化ステップと、
前記復号化誤り検出用データと前記誤り検出用データとに基づいて、前記暗号文データにおける誤りまたは改ざんの有無を判断する誤り検出用データ確認ステップと、
前記復号化データを元に復号文データを作成して出力する復号文データ出力ステップと
を含むことを特徴とするデータ復号処理プログラム。
A data decryption processing program for decrypting ciphertext data to generate decrypted text data, wherein the ciphertext data includes encryption error detection data,
The data decryption program is
Decrypting the ciphertext data using key data to generate decrypted data, wherein the decrypted data includes a data decryption conversion step including alteration detection target data;
An error detection data generation step for generating error detection data for the ciphertext data;
An error detection data encryption key generation step for generating an error detection data encryption key based on the falsification detection target data and the key data;
A tampering detection data decryption step of decrypting the encryption error detection data using the error detection data encryption key to generate decryption error detection data;
An error detection data confirmation step for determining whether there is an error or falsification in the ciphertext data based on the decryption error detection data and the error detection data;
And a decrypted text data output step for generating and outputting decrypted text data based on the decrypted data.
暗号文データを復号化して復号文データを生成する集積回路であって、
前記暗号文データは、暗号化誤り検出用データを含み、
前記集積回路は、
鍵データを用いて前記暗号文データを復号化して復号化データを生成し、前記復号化データは改ざん検出対象データを含むデータ復号変換部と、
前記暗号文データに対して誤り検出用データを生成する誤り検出用データ生成部と、
前記改ざん検出対象データと前記鍵データに基づいて誤り検出用データ暗号鍵を生成する誤り検出用データ暗号鍵生成部と、
前記誤り検出用データ暗号鍵を用いて前記暗号化誤り検出用データを復号化して復号化誤り検出用データを生成する改ざん検出用データ復号化部と、
前記復号化誤り検出用データと前記誤り検出用データとに基づいて、前記暗号文データにおける誤りまたは改ざんの有無を判断する誤り検出用データ確認部と、
前記復号化データを元に復号文データを作成して出力する復号文データ出力部と
を備えることを特徴とする集積回路。
An integrated circuit that decrypts ciphertext data and generates decrypted text data,
The ciphertext data includes encryption error detection data,
The integrated circuit comprises:
Decrypting the ciphertext data using key data to generate decrypted data, and the decrypted data includes a data decryption conversion unit including falsification detection target data;
An error detection data generation unit for generating error detection data for the ciphertext data;
An error detection data encryption key generation unit that generates an error detection data encryption key based on the falsification detection target data and the key data;
A tampering detection data decryption unit that decrypts the encryption error detection data using the error detection data encryption key to generate decryption error detection data;
An error detection data confirmation unit that determines whether there is an error or falsification in the ciphertext data based on the decryption error detection data and the error detection data;
An integrated circuit comprising: a decrypted text data output unit that creates and outputs decrypted text data based on the decrypted data.
JP2007122443A 2007-05-07 2007-05-07 Apparatuses, methods, and programs for data encryption processing and data decryption processing, and integrated circuit Pending JP2008278416A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007122443A JP2008278416A (en) 2007-05-07 2007-05-07 Apparatuses, methods, and programs for data encryption processing and data decryption processing, and integrated circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007122443A JP2008278416A (en) 2007-05-07 2007-05-07 Apparatuses, methods, and programs for data encryption processing and data decryption processing, and integrated circuit

Publications (1)

Publication Number Publication Date
JP2008278416A true JP2008278416A (en) 2008-11-13

Family

ID=40055795

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007122443A Pending JP2008278416A (en) 2007-05-07 2007-05-07 Apparatuses, methods, and programs for data encryption processing and data decryption processing, and integrated circuit

Country Status (1)

Country Link
JP (1) JP2008278416A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011239117A (en) * 2010-05-10 2011-11-24 Mitsubishi Electric Corp Communication device, communication system, communication method and communication program
JP2013255010A (en) * 2012-06-05 2013-12-19 Toppan Printing Co Ltd Information processing device, information processing method, and information processing system
WO2018109906A1 (en) * 2016-12-15 2018-06-21 日本電気株式会社 Message authentication system, device, and message verification method
JP2019075733A (en) * 2017-10-18 2019-05-16 Necプラットフォームズ株式会社 Communication system, communication device, and method thereof
CN110321737A (en) * 2019-06-28 2019-10-11 兆讯恒达微电子技术(北京)有限公司 A kind of method of the anti-injection attack of data encryption standards coprocessor

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011239117A (en) * 2010-05-10 2011-11-24 Mitsubishi Electric Corp Communication device, communication system, communication method and communication program
JP2013255010A (en) * 2012-06-05 2013-12-19 Toppan Printing Co Ltd Information processing device, information processing method, and information processing system
WO2018109906A1 (en) * 2016-12-15 2018-06-21 日本電気株式会社 Message authentication system, device, and message verification method
US11336456B2 (en) 2016-12-15 2022-05-17 Nec Corporation Message authentication system, apparatus, and message verification method
JP2019075733A (en) * 2017-10-18 2019-05-16 Necプラットフォームズ株式会社 Communication system, communication device, and method thereof
CN110321737A (en) * 2019-06-28 2019-10-11 兆讯恒达微电子技术(北京)有限公司 A kind of method of the anti-injection attack of data encryption standards coprocessor
CN110321737B (en) * 2019-06-28 2020-12-11 兆讯恒达科技股份有限公司 Method for preventing injection type attack of data encryption standard coprocessor

Similar Documents

Publication Publication Date Title
JP3901909B2 (en) ENCRYPTION DEVICE AND RECORDING MEDIUM CONTAINING PROGRAM
JP3864675B2 (en) Common key encryption device
EP1081888B1 (en) Encryption method, encryption apparatus, decryption method, and decryption apparatus
JP4596256B2 (en) Transmission / reception system and method, transmission device and method, reception device and method, and program
US8972300B2 (en) Content distribution system
US20030212886A1 (en) Encryption/decryption system and encryption/decryption method
JP4650267B2 (en) Transmitting apparatus and method, receiving apparatus and method, data transmission system, and data transmission method
WO2004051920A1 (en) Key sharing system, shared key creation device, and shared key restoration device
KR101365603B1 (en) Method for conditional inserting authentication code and apparatus therefor, Method for conditional using data through authenticating and apparatus therefor
JP2001211442A (en) Contents information transmission method, contents information recording method, contents information transmitter, contents information recorder, transmission medium, and recording medium
WO2016067524A1 (en) Authenticated encryption apparatus, authenticated decryption apparatus, authenticated cryptography system, authenticated encryption method, and program
JP2004138933A (en) Digital image scrambling system, descrambling system, and program realizing the system
JP2008278416A (en) Apparatuses, methods, and programs for data encryption processing and data decryption processing, and integrated circuit
KR101059344B1 (en) Encrypted communication system
JP2011091494A (en) Data distribution device, data reception device, data distribution program and data reception program
KR100930036B1 (en) Duplicate stream password information in the next packet of encrypted frames
JP2007041756A (en) Information processor and method, program, and security chip
US20030174835A1 (en) Data encryption device, data decryption device, and data encryption/decryption device
WO2007043002A2 (en) Improved security system
JP5367023B2 (en) Information encryption method, information encryption apparatus, program, and recording medium
JP2009213083A (en) Image compression method and apparatus
JP2001211159A (en) Method and device for decipehring contents information
JP4752239B2 (en) Common key encryption method and apparatus
KR20060003328A (en) Improved cfm mode system
JP3864798B2 (en) Common key encryption decryption device