JP2002229444A - Block encryption and decryption circuit - Google Patents

Block encryption and decryption circuit

Info

Publication number
JP2002229444A
JP2002229444A JP2001030496A JP2001030496A JP2002229444A JP 2002229444 A JP2002229444 A JP 2002229444A JP 2001030496 A JP2001030496 A JP 2001030496A JP 2001030496 A JP2001030496 A JP 2001030496A JP 2002229444 A JP2002229444 A JP 2002229444A
Authority
JP
Japan
Prior art keywords
data
circuit
bit
register
block
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
JP2001030496A
Other languages
Japanese (ja)
Inventor
Hiroshi Ichise
浩 市瀬
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.)
Toyo Communication Equipment Co Ltd
Original Assignee
Toyo Communication Equipment 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 Toyo Communication Equipment Co Ltd filed Critical Toyo Communication Equipment Co Ltd
Priority to JP2001030496A priority Critical patent/JP2002229444A/en
Publication of JP2002229444A publication Critical patent/JP2002229444A/en
Pending legal-status Critical Current

Links

Abstract

PROBLEM TO BE SOLVED: To solve the problem of an easy tendency to cryptoanalysis of the 8-bit data at the top of ciphertext data heretofore in a cipher feeback mode (cipher CFB mode) of a block encryption (decryption) circuit using a common key. SOLUTION: The 8-bit data at the top of the plaintext (ciphertext) data is encrypted (decrypted) by the first encryption (decryption) circuit and the succeeding data of the 8-bit at the top is encrypted (decrypted) by the second encryption (decryption) circuit. Part of the encrypted (plaintext) data formed by the first encryption (decryption) circuit is set as the initial value of the second encryption (decryption) circuit.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明は、共通鍵を用いたブ
ロック暗号技術に関する。
[0001] The present invention relates to a block cipher technique using a common key.

【0002】[0002]

【従来の技術】従来から暗号技術は軍事機密や営業秘密
等を始め個人のプライバシ−情報等に至るまで様々な情
報を保護しセキュリティを確保する重要な基盤技術とし
て社会に貢献してきた。近年、インターネット等の情報
インフラがグローバルな規模で整備され本格的な高度情
報化社会を迎えるに至り、暗号技術はこれを支える重要
技術としてますます世間の注目を集めていると共に、様
々な暗号技術が研究、開発されていることは周知のこと
である。
2. Description of the Related Art Conventionally, encryption technology has been contributing to society as an important basic technology for protecting various types of information, such as military confidentiality and trade secrets, as well as personal privacy information, and ensuring security. In recent years, the information infrastructure such as the Internet has been developed on a global scale and has entered a full-fledged advanced information society. It is well known that is being researched and developed.

【0003】暗号技術は大別すると共通鍵方式と公開鍵
方式とに分類される。中でも共通鍵方式は暗号化と復号
に共通の鍵を用いるものであって、鍵の管理や秘密裏に
鍵を共有しなければならないという問題を抱えていもの
の、高速に暗号化または復号できるという利点を有して
いるため、その応用分野は広い。また、共通鍵方式の中
でもブロック暗号方式と呼ばれるものが商用暗号の主流
として広く採用されている。ブロック暗号は平文を一定
な長さの文字列(ブロック)に分割し、これらを同じ共
通鍵で暗号化する暗号である。
[0003] Cryptographic techniques are broadly classified into a common key scheme and a public key scheme. Among them, the common key method uses a common key for encryption and decryption, and has the problem of having to manage the key and sharing the key secretly, but has the advantage of being able to encrypt or decrypt at high speed. Therefore, its application field is wide. Further, among the common key systems, a system called a block cipher system is widely adopted as a mainstream of commercial encryption. The block cipher is a cipher that divides a plaintext into character strings (blocks) of a fixed length and encrypts them with the same common key.

【0004】図3はJIS X 5053に規定されて
いる、従来のブロック暗号化回路及び復号回路を示した
ものであり、暗号フィードバックモード(暗号CFBモ
ード)方式と呼ばれているものである。図3に示すブロ
ック暗号化回路及び復号回路は、所定の入力手段から入
力された平文データ列を取り込み8ビット毎抽出して平
文データを出力する入力バッファ1と、前記入力バッフ
ァ1から8ビット毎供給された平文データを暗号化し8
ビット毎に暗号文データを出力する暗号化回路2と、前
記暗号化回路2が出力する暗号文データを順次格納及び
保持し暗号文データ列として出力する出力バッファ3
と、前記出力バッファ3が出力する暗号文データ列を取
り込み8ビット毎抽出して暗号文データを出力する入力
バッファ4と、前記入力バッファ4から8ビット毎供給
された暗号文データを復号し8ビット毎に平文データを
出力する復号回路5と、前記復号回路5が出力する平文
データを順次格納し平文データ列として出力する出力バ
ッファ6とを備えている。
FIG. 3 shows a conventional block encryption circuit and a conventional decryption circuit defined in JIS X 5053, which is called an encryption feedback mode (encryption CFB mode). The block encryption circuit and the decryption circuit shown in FIG. 3 take in an input buffer 1 which takes in a plaintext data string input from a predetermined input means, extracts every 8 bits, and outputs plaintext data, and outputs every 8 bits from the input buffer 1. Encrypts the supplied plaintext data to 8
An encryption circuit 2 for outputting ciphertext data for each bit, and an output buffer 3 for sequentially storing and holding the ciphertext data output by the encryption circuit 2 and outputting the same as a ciphertext data string
And an input buffer 4 for taking in the ciphertext data string output from the output buffer 3 and extracting the ciphertext data every 8 bits and outputting the ciphertext data, and decrypting the ciphertext data supplied from the input buffer 4 every 8 bits. A decoding circuit 5 that outputs plaintext data for each bit, and an output buffer 6 that sequentially stores the plaintext data output by the decoding circuit 5 and outputs it as a plaintext data string.

【0005】また、前記暗号化回路2は所定ビット長の
共通鍵データを保持する鍵データレジスタ7と、前記鍵
データレジスタ7から供給される共通鍵データを基に後
述するフィードバックされた64ビットデータを暗号化
し64ビットのブロック暗号を生成するブロック暗号化
回路8と、前記ブロック暗号化回路8の出力する64ビ
ットブロック暗号を保持するレジスタ9と、前記レジス
タ9の保持した64ビットブロック暗号の上位8ビット
を抽出し保持するレジスタ10と、入力バッファ1から
転送された8ビットの平文データを保持するレジスタ1
1と、前記レジスタ11の保持する8ビットの平文デー
タとレジスタ10の保持する8ビットのブロック暗号と
を各ビット毎に排他的論理和演算を行い8ビットの暗号
文データを生成出力する排他的論理和回路12と、前記
排他的論理和回路12からの8ビットの暗号文データを
保持し出力バッファ3に供給するレジスタ13と、前記
レジスタ13から供給された8ビット暗号文データを格
納すると共に該格納した8ビット暗号文データを順次上
位方向へシフトさせながら72ビットの暗号文データを
保持するシフトレジスタ14(フィードバックバッフ
ァ)と、前記シフトレジスタ14の保持した72ビット
の暗号文データの上位64ビットを保持するレジスタ1
5とを備え、前記レジスタ15の保持した64ビットデ
ータは前記ブロック暗号化回路8にフィードバックデー
タとして供給されている。
The encryption circuit 2 has a key data register 7 for holding common key data having a predetermined bit length, and a 64-bit data fed back based on the common key data supplied from the key data register 7. A block encryption circuit 8 for generating a 64-bit block cipher by encrypting the data, a register 9 for holding the 64-bit block cipher output from the block encryption circuit 8, and a higher-order 64-bit block cipher held by the register 9. A register 10 for extracting and holding 8 bits, and a register 1 for holding 8 bits of plaintext data transferred from the input buffer 1
An exclusive OR operation is performed by performing an exclusive OR operation for each bit on the 8-bit plaintext data held by the register 11 and the 8-bit block cipher held by the register 10 to generate and output 8-bit ciphertext data. An OR circuit 12, a register 13 for holding the 8-bit ciphertext data from the exclusive OR circuit 12 and supplying the same to the output buffer 3, and storing the 8-bit ciphertext data supplied from the register 13; A shift register 14 (feedback buffer) that holds the 72-bit ciphertext data while sequentially shifting the stored 8-bit ciphertext data upward, and the upper 64 bits of the 72-bit ciphertext data held by the shift register 14. Register 1 that holds bits
The 64-bit data held in the register 15 is supplied to the block encryption circuit 8 as feedback data.

【0006】更に、前記復号回路5は所定ビット長の共
通鍵データを格納する鍵データレジスタ16と、前記鍵
データレジスタ16から供給される共通鍵データを基に
後述する64ビット暗号データを復号し64ビットのブ
ロック復号データを生成するブロック復号回路17と、
前記ブロック復号回路17の出力する64ビットブロッ
ク復号データを保持するレジスタ18と、前記レジスタ
18の保持する64ビットブロック復号データの上位8
ビットを抽出し保持するレジスタ19と、前記入力バッ
ファ4から転送された8ビットの暗号文データを保持す
るレジスタ20と、前記レジスタ20の保持する8ビッ
トの暗号文データとレジスタ19の保持する8ビットブ
ロック復号データとを各ビット毎に排他的論理和演算を
行い8ビットの平文データを復号出力する排他的論理和
回路21と、前記排他的論理和回路21から供給された
平文データを保持し前記出力バッファ6に供給するレジ
スタ22と、前記レジスタ20から供給された8ビット
暗号文データを格納すると共に該格納した8ビット暗号
文データを順次上位方向へシフトさせながら72ビット
の暗号文データを保持するシフトレジスタ23と、前記
シフトレジスタ23の保持した72ビットの暗号文デー
タの上位64ビットを保持するレジスタ24とを備え、
前記レジスタ24の保持した64ビット暗号データは前
記ブロック復号回路17に供給されている。
Further, the decryption circuit 5 decrypts 64-bit encrypted data, which will be described later, based on a key data register 16 for storing common key data having a predetermined bit length and the common key data supplied from the key data register 16. A block decoding circuit 17 for generating 64-bit block decoded data;
A register 18 for holding the 64-bit block decoded data output from the block decoding circuit 17;
A register 19 for extracting and holding bits; a register 20 for holding 8-bit ciphertext data transferred from the input buffer 4; and a 8-bit ciphertext data held by the register 20 and 8 held by the register 19. An exclusive OR circuit 21 that performs an exclusive OR operation on the bit block decoded data for each bit to decode and output 8-bit plaintext data, and holds the plaintext data supplied from the exclusive OR circuit 21. A register 22 for supplying to the output buffer 6, storing the 8-bit ciphertext data supplied from the register 20, and shifting the stored 8-bit ciphertext data upward in order to convert the 72-bit ciphertext data. The shift register 23 held therein and the upper 64 bits of the 72-bit ciphertext data held by the shift register 23. And a register 24 for holding,
The 64-bit encrypted data held by the register 24 is supplied to the block decryption circuit 17.

【0007】図3に示した従来の暗号化/復号回路は以
下のように動作する。まず、暗号化回路2の動作につい
て説明する。暗号化回路2が起動すると、シフトレジス
タ14の上位64ビットは所定の初期値に設定される。
次に、前記シフトレジスタ14に初期設定した上位64
ビットをレジスタ15に転送する。ブロック暗号回路8
は前記レジスタ15に保持した64ビットデータを鍵デ
ータレジスタ7から供給される所定ビット長の鍵データ
で暗号化し64ビットのブロック暗号を生成しレジスタ
9に転送する。そして、レジスタ10で前記レジスタ9
に保持した64ビットのブロック暗号の上位8ビットを
抽出し保持する。
The conventional encryption / decryption circuit shown in FIG. 3 operates as follows. First, the operation of the encryption circuit 2 will be described. When the encryption circuit 2 starts, the upper 64 bits of the shift register 14 are set to a predetermined initial value.
Next, the upper 64 data initially set in the shift register 14 are stored.
Transfer the bits to register 15. Block encryption circuit 8
Encrypts the 64-bit data held in the register 15 with key data of a predetermined bit length supplied from the key data register 7 to generate a 64-bit block cipher and transfer it to the register 9. Then, the register 9 stores the
And extracts and holds the upper 8 bits of the 64-bit block cipher held.

【0008】一方、図3に図示されない入力手段から入
力バッファ1へ平文データを8ビット入力する。そし
て、入力バッファ1はこれをレジスタ11に8ビット転
送すると共に削除する。そこで、排他的論理和回路12
はレジスタ11に転送された8ビットの平文データとレ
ジスタ10に保持した8ビットのブロック暗号とをそれ
ぞれ各ビット毎排他的論理和演算を実行し8ビットの暗
号文データを生成出力する。これをレジスタ13に保持
すると共に出力バッファ3へ転送する。出力バッファ3
は前記8ビットの暗号文データを出力手段に供給後これ
を削除する。
On the other hand, 8 bits of plaintext data are input to the input buffer 1 from input means not shown in FIG. Then, the input buffer 1 transfers this to the register 11 by 8 bits and deletes it. Therefore, the exclusive OR circuit 12
Performs an exclusive OR operation on each of the 8-bit plaintext data transferred to the register 11 and the 8-bit block cipher held in the register 10 to generate 8-bit ciphertext data. This is held in the register 13 and transferred to the output buffer 3. Output buffer 3
Supplies the 8-bit ciphertext data to the output means and deletes it.

【0009】次に、レジスタ13は前記8ビット暗号文
データをシフトレジスタ14の下位8ビットへ転送す
る。そして、シフトレジスタ14は転送された8ビット
暗号文データを上位方向へ8ビット分シフトさせる。こ
こで、シフトレジスタ14の上位64ビットは上位方向
へ8ビット分シフトした結果、初期値から変化し新たな
値となっている。これをレジスタ15に保持し、ブロッ
ク暗号化回路8でブロック暗号化しレジスタ9で保持し
上位8ビットをレジスタ10に保持する。そして、入力
手段から入力バッファ1へ新たに平文データを8ビット
分入力しレジスタ11に転送すると、同様にレジスタ1
0とレジスタ11の8ビットデータを排他的論理和回路
12で演算し新たに8ビットの暗号文データを生成出力
する。
Next, the register 13 transfers the 8-bit ciphertext data to the lower 8 bits of the shift register 14. Then, the shift register 14 shifts the transferred 8-bit ciphertext data upward by 8 bits. Here, as a result of shifting the upper 64 bits of the shift register 14 by 8 bits in the upper direction, the upper register 64 changes from the initial value to a new value. This is held in a register 15, block-encrypted by a block encryption circuit 8, held in a register 9, and the upper 8 bits are held in a register 10. When new 8-bit plaintext data is input from the input means to the input buffer 1 and transferred to the register 11, similarly,
The exclusive OR circuit 12 operates on 0 and the 8-bit data of the register 11 to generate and output 8-bit ciphertext data.

【0010】レジスタ13は排他的論理回路12から供
給された8ビット暗号文データを再び出力バッファ3に
転送すると共に、シフトレジスタ2に転送する。出力バ
ッファ3は前記8ビット暗号文データを出力手段へ再度
出力しこれを削除する。また、シフトレジスタ14は転
送された8ビット暗号文データを再び上位方向へ8ビッ
ト分シフトさせる。以上説明した動作を順次繰り返して
いくと、入力手段から入力された平文データは順次8ビ
ット毎暗号化され、出力バッファ3からは8ビット毎暗
号文データが出力手段へ供給されるようになる。
The register 13 transfers the 8-bit ciphertext data supplied from the exclusive logic circuit 12 to the output buffer 3 again and to the shift register 2. The output buffer 3 outputs the 8-bit ciphertext data again to the output means and deletes it. The shift register 14 shifts the transferred 8-bit ciphertext data upward by 8 bits again. By sequentially repeating the above-described operations, the plaintext data input from the input unit is sequentially encrypted every 8 bits, and the output buffer 3 supplies the 8-bit encrypted data to the output unit.

【0011】次に、復号回路5の動作について説明す
る。復号回路5が起動すると、シフトレジスタ23の上
位64ビットは所定の初期値に設定される。ここで、前
記初期値はシフトレジスタ23に設定した初期値と同じ
値である。そこで、シフトレジスタ23に初期設定した
上位64ビットをレジスタ24に転送する。そして、ブ
ロック復号回路17は前記レジスタ24に保持した64
ビットデータを鍵データレジスタ16から供給される所
定ビット長の鍵データで復号し64ビットのブロック復
号データを出力する。なお、鍵データレジスタ16に保
持した鍵データは鍵データレジスタ7に保持した鍵デー
タと全く同じものであり、ブロック復号回路17はブロ
ック暗号化回路8と同じ動作を行うものである。
Next, the operation of the decoding circuit 5 will be described. When the decoding circuit 5 starts, the upper 64 bits of the shift register 23 are set to a predetermined initial value. Here, the initial value is the same value as the initial value set in the shift register 23. Therefore, the upper 64 bits initially set in the shift register 23 are transferred to the register 24. Then, the block decoding circuit 17 stores the 64
The bit data is decrypted with key data of a predetermined bit length supplied from the key data register 16 to output 64-bit block decrypted data. The key data held in the key data register 16 is exactly the same as the key data held in the key data register 7, and the block decryption circuit 17 performs the same operation as the block encryption circuit 8.

【0012】一方、暗号化回路2で生成した暗号文デー
タを入力手段を介して入力バッファ4に供給する。そし
て、入力バッファ4はこれをレジスタ20に8ビット転
送後削除する。そこで、排他的論理和回路21はレジス
タ20に転送された8ビットの暗号文データとレジスタ
19に保持した8ビットのブロック復号データとをそれ
ぞれ各ビット毎排他的論理和演算を実行し8ビットの平
文データを生成出力する。これをレジスタ22に保持す
ると共に出力バッファ6へ転送する。出力バッファ6は
前記8ビットの平文データを別途出力手段に供給後削除
する。
On the other hand, the ciphertext data generated by the encryption circuit 2 is supplied to the input buffer 4 via the input means. Then, the input buffer 4 deletes the data after transferring it to the register 20 by 8 bits. Therefore, the exclusive OR circuit 21 performs an exclusive OR operation for each bit of the 8-bit ciphertext data transferred to the register 20 and the 8-bit block decrypted data held in the register 19, and performs an 8-bit operation. Generate and output plaintext data. This is held in the register 22 and transferred to the output buffer 6. The output buffer 6 deletes the 8-bit plaintext data after supplying it to the output means separately.

【0013】次に、レジスタ20は前記8ビット暗号文
データをシフトレジスタ23の下位8ビットへ転送す
る。そして、シフトレジスタ23は転送された8ビット
暗号文データを上位方向へ8ビット分シフトさせる。こ
こで、シフトレジスタ23の上位64ビットは上位方向
へ8ビット分シフトした結果、上位64ビットは更に変
化し新たな値となっている。これをレジスタ24に保持
し、ブロック復号回路17でブロック復号し、レジスタ
18で保持し上位8ビットをレジスタ19に保持する。
そして、入力手段から入力バッファ1へ新たに暗号文デ
ータを8ビット入力しレジスタ20に転送すると、同様
にレジスタ19とレジスタ20の8ビットデータを排他
的論理和回路21で演算し新たに8ビットの平文データ
を生成出力する。
Next, the register 20 transfers the 8-bit ciphertext data to the lower 8 bits of the shift register 23. Then, the shift register 23 shifts the transferred 8-bit ciphertext data upward by 8 bits. Here, as a result of shifting the upper 64 bits of the shift register 23 by 8 bits in the upper direction, the upper 64 bits are further changed to a new value. This is held in the register 24, block-decoded by the block decoding circuit 17, held in the register 18, and held in the register 19 in the upper 8 bits.
Then, when 8-bit ciphertext data is newly input from the input means to the input buffer 1 and transferred to the register 20, the 8-bit data of the register 19 and the register 20 is similarly operated by the exclusive OR circuit 21 to newly generate 8 bits. Generate and output plaintext data.

【0014】レジスタ22は排他的論理回路21から供
給された8ビット平文データを再び出力バッファ22に
供給し出力バッファ6は前記8ビット暗号文データを出
力手段へ再度出力し削除する。またシフトレジスタ23
はレジスタ20から転送された8ビット暗号文データを
上位方向へ8ビット分シフトさせる。以上説明した動作
を順次繰り返していくと、入力手段から入力された暗号
文データは順次8ビット毎復号され、出力バッファ6か
らは8ビット毎平文データが出力手段へ供給されるよう
になる。
The register 22 supplies the 8-bit plaintext data supplied from the exclusive logic circuit 21 to the output buffer 22 again, and the output buffer 6 outputs the 8-bit ciphertext data to the output means again and deletes it. The shift register 23
Shifts the 8-bit ciphertext data transferred from the register 20 upward by 8 bits. When the above-described operations are sequentially repeated, the ciphertext data input from the input unit is sequentially decoded every 8 bits, and the output buffer 6 supplies the 8-bit plaintext data to the output unit.

【0015】[0015]

【発明が解決しようとする課題】しかしながら、従来の
暗号化、復号回路には以下のような問題点があった。す
なわち、暗号化、復号回路の起動時、シフトレジスタ1
4の上位64ビットは予め所定の初期値に設定されてし
まっている。よって、これをレジスタ15に保持しブロ
ック暗号化回路8で暗号化するので起動直後の最初の6
4ビット出力データはある決まった値しか出力されな
い。ゆえに、レジスタ10に保持される最初の8ビット
データもある決まった値(以下、レジスタ10初期保持
値と言う)となり、前記レジスタ10初期保持値とレジ
スタ11(入力バッファ1)に保持した平文の先頭8ビ
ットデータとを排他的論理和回路12で演算したものが
先頭の8ビット暗号文データとして得られることにな
る。従って、暗号化、復号回路の起動直後、入力バッフ
ァ1に保持した先頭の8ビットデータと出力バッファ1
3に出力される先頭の8ビットデータとを取得すれば、
レジスタ10初期保持値の内容を簡単な論理演算によっ
て求めることができてしまう。この結果、暗号化回路の
起動直後、暗号文データ列の先頭の8ビットは求めたレ
ジスタ10初期保持値を使って簡単に復号できてしまう
といった問題点が生じる。
However, the conventional encryption / decryption circuit has the following problems. That is, when the encryption / decryption circuit is activated, the shift register 1
The upper 64 bits of 4 are preset to a predetermined initial value. Therefore, this is stored in the register 15 and encrypted by the block encryption circuit 8, so that the first 6
As for the 4-bit output data, only a certain fixed value is output. Therefore, the first 8-bit data held in the register 10 also has a certain value (hereinafter, referred to as the register 10 initial holding value), and the register 10 initial holding value and the plaintext held in the register 11 (input buffer 1) are stored. The result obtained by calculating the leading 8-bit data by the exclusive OR circuit 12 is obtained as the leading 8-bit ciphertext data. Therefore, immediately after the start of the encryption / decryption circuit, the first 8-bit data held in the input buffer 1 and the output buffer 1
By acquiring the leading 8-bit data output to 3,
The contents of the initial holding value of the register 10 can be obtained by a simple logical operation. As a result, there arises a problem that immediately after the activation of the encryption circuit, the first 8 bits of the ciphertext data string can be easily decrypted using the obtained initial holding value of the register 10.

【0016】この問題点を回避するため、入力手段から
入力する平文データ列の先頭に8ビットのプリアンブル
データを付加し、先頭の8ビットが解読されても問題な
いようにするとか、または64ビットのデータを別途手
段で暗号化して、これを外部からシフトレジスタ14、
23の初期値としてダウンロードするか、或いは鍵デー
タレジスタ7、16に保持した鍵データを不定期に更新
するようにして、暗号化した時刻によって前記レジスタ
10初期保持値が異なるようにするといった方法も採ら
れている。
In order to avoid this problem, preamble data of 8 bits is added to the head of the plaintext data string input from the input means so that there is no problem even if the head 8 bits are decoded, or 64 bits are used. Is encrypted by a separate means, and this is externally transferred to the shift register 14,
Alternatively, the key data held in the key data registers 7 and 16 may be updated at random, or the key data held in the key data registers 7 and 16 may be updated irregularly so that the initial held value of the register 10 differs depending on the time of encryption. Has been adopted.

【0017】しかしながら、プリアンブルを付加する方
法は不要なデータが先頭に付与されてデータサイズが変
わってしまうことや、64ビットのデータを暗号化し初
期値とする方法も、64ビットデータの保管方法の問題
が発生することや暗号化回路自体が相当複雑化してしま
うといった問題がある。また、暗号鍵を更新する方法に
ついても、更新する度に鍵データを外部からダウンロー
ドしなければならず、更新する鍵データの保管方法等の
問題も別途発生してしまうので有効な方法とは言えな
い。
However, the method of adding a preamble is such that unnecessary data is added to the head to change the data size, the method of encrypting 64-bit data and setting it to an initial value is also a method of storing 64-bit data. There is a problem that a problem occurs and the encryption circuit itself becomes considerably complicated. In addition, the method of updating the encryption key is also an effective method because the key data must be downloaded from the outside each time the update is performed, and another problem such as a method of storing the updated key data occurs separately. Absent.

【0018】本発明は、上記問題を解決するためになさ
れたものであって、暗号文データの先頭8ビットを解読
できないようにできる、暗号強度の高い暗号フィードバ
ックモードのブロック暗号化、復号回路を提供すること
を目的とする。
SUMMARY OF THE INVENTION The present invention has been made to solve the above-mentioned problem. The present invention provides a block encryption / decryption circuit in a cryptographic feedback mode having a high cryptographic strength, which can prevent the first 8 bits of ciphertext data from being decrypted. The purpose is to provide.

【0019】[0019]

【課題を解決しようとする手段】上記目的を解決するた
めに、本発明に係わるブロック暗号化、復号回路の請求
項1記載の発明は、平文データ列から順次所定ビット毎
抽出して暗号化し、所定ビット毎暗号文データ列を生成
し出力する共通鍵方式ブロック暗号化回路の暗号フィー
ドバックモード(暗号CFBモード)において、第1の
暗号化回路と第2の暗号化回路と入力切替手段と出力切
替手段とを備えた暗号化回路であって、前記平文データ
列の先頭の所定ビットを前記入力切替手段で選択して前
記第1の暗号化回路で暗号化するとともに、該平文デー
タ列の先頭の所定ビットに続くビット列を該入力切替手
段で選択して前記第2の暗号化回路で暗号化し、前記第
1の暗号化回路で得られた暗号文データ及び前記第2の
暗号化回路で得られた暗号文データとをそれぞれ前記出
力切替手段で選択し出力したものであって、前記第1の
暗号化回路は共通鍵データを生成する第1の鍵データレ
ジスタと、前記共通鍵データを基に所定ビット長のブロ
ック暗号を生成する第1のブロック暗号化回路と、前記
第1のブロック暗号から抽出した上位所定ビットと該平
文データ列から抽出した所定ビットとを排他的論理和演
算処理し暗号文データを生成出力する第1の排他的論理
回路と、前記第1の排他的論理回路から供給される暗号
文データを所定ビット毎順次上位へシフトさせながら格
納及び保持するとともに該保持した暗号文データを前記
第1のブロック暗号化回路にフィードバック供給する第
1のシフトレジスタ(フィードバックバッファ)とを有
し、前記第2の暗号化回路は共通鍵データを生成する第
2の鍵データレジスタと、前記第2の共通鍵データを基
に所定ビット長のブロック暗号を生成する第2のブロッ
ク暗号化回路と、前記ブロック暗号から抽出した上位所
定ビットと該平文データ列から抽出した所定ビットとを
排他的論理和演算処理し暗号文データを生成出力する第
2の排他的論理和回路と、前記第2の排他的論理和回路
から供給される暗号文データを順次上位へシフトさせな
がら格納及び保持するとともに該保持した暗号文データ
を前記第2のブロック暗号化回路にフィードバック供給
する第2のシフトレジスタ(フィードバックバッファ)
とを有し、前記第1の暗号化回路で暗号文データを生成
する過程において前記第1のシフトレジスタに保持した
暗号文データを前記第2の暗号化回路に転送し、これを
該第2のシフトレジスタの初期値として設定したもので
ある。
In order to solve the above-mentioned object, a block encryption / decryption circuit according to the present invention is characterized in that a predetermined bit is sequentially extracted from a plaintext data string and encrypted. A first encryption circuit, a second encryption circuit, an input switching unit, and an output switch in an encryption feedback mode (encryption CFB mode) of a common key block encryption circuit that generates and outputs a ciphertext data sequence for each predetermined bit. Means for selecting a predetermined bit at the head of the plaintext data string by the input switching means and encrypting the selected bit at the first encryption circuit; A bit string following a predetermined bit is selected by the input switching means and encrypted by the second encryption circuit, and the ciphertext data obtained by the first encryption circuit and the ciphertext data obtained by the second encryption circuit are obtained. And the ciphertext data selected and output by the output switching means, wherein the first encryption circuit includes a first key data register for generating common key data, and a first key data register based on the common key data. A first block encryption circuit for generating a block cipher having a predetermined bit length, and performing an exclusive OR operation on an upper predetermined bit extracted from the first block cipher and a predetermined bit extracted from the plaintext data string to perform encryption; A first exclusive logic circuit for generating and outputting text data, and storing and holding the ciphertext data supplied from the first exclusive logic circuit while sequentially shifting the ciphertext data by a predetermined bit to a higher order; A first shift register (feedback buffer) for feeding data back to the first block encryption circuit, wherein the second encryption circuit uses a common key A second key data register for generating a data, a second block encryption circuit for generating a block cipher of a predetermined bit length based on the second common key data, and upper predetermined bits extracted from the block cipher. A second exclusive-OR circuit for performing exclusive-OR operation on the data and a predetermined bit extracted from the plaintext data string to generate and output ciphertext data; and a cipher supplied from the second exclusive-OR circuit. A second shift register (feedback buffer) for storing and holding the sentence data while sequentially shifting the sentence data upward, and for feeding back the held ciphertext data to the second block encryption circuit;
Transferring the ciphertext data held in the first shift register to the second encryption circuit in the process of generating the ciphertext data in the first encryption circuit, Are set as the initial values of the shift register.

【0020】本発明に係わるブロック暗号化、復号回路
の請求項2記載の発明は、請求項1記載の暗号化回路に
よって得られた暗号文データ列を所定ビット毎復号する
復号回路であって、前記復号回路は第1の復号回路と第
2の復回路と入力切替手段と出力切替手段とを備え、前
記暗号文データ列の先頭の所定ビットを前記入力切替手
段で選択して前記第1の復号回路で復号するとともに、
該暗号文データ列の先頭の所定ビットに続くビット列を
該入力切替手段で選択して前記第2の復号回路で復号
し、前記第1の復号回路で得られた平文データ及び前記
第2の復号回路で得られた平文データとを前記出力切替
手段で選択し出力したものであって、前記第1の復号回
路は共通鍵データを生成する請求項1記載の第1の鍵デ
ータレジスタと、前記共通鍵データを基に所定ビット長
のブロック暗号を復号する第1のブロック復号回路と、
前記第1のブロック復号回路から復号した復号データの
上位所定ビットと該暗号文データ列から抽出した所定ビ
ットとを排他的論理和演算処理し平文データを生成出力
する第1の排他的論理回路と、前記暗号文データ列を所
定ビット毎順次上位へシフトさせながら格納及び保持す
るとともにに該保持した暗号文データを前記第1のブロ
ック復号回路に供給する第1のシフトレジスタとを有
し、前記第2の復号回路は共通鍵データを生成する請求
項1記載の第2の鍵データレジスタと、前記第2の共通
鍵データを基に所定ビット長のブロック暗号を復号する
第2のブロック復号回路と、前記ブロック復号回路から
復号した復号データの上位所定ビットと該暗号文データ
列から抽出した所定ビットとを排他的論理和演算処理し
平文データを生成出力する第2の排他的論理回路と、前
記暗号文データ列を所定ビット毎順次上位へシフトさせ
ながら格納及び保持するとともに該保持した暗号文デー
タを前記第2のブロック復号回路に供給する第2のシフ
トレジスタとを有し、前記第1の復号回路で平文データ
を生成する過程において前記第1のシフトレジスタに保
持される暗号文データを前記第2の復号回路に転送し、
これを該第2のシフトレジスタの初期値として設定した
ものである。
According to a second aspect of the present invention, there is provided a decryption circuit for decrypting a ciphertext data sequence obtained by the encryption circuit according to the first aspect of the present invention for each predetermined bit, The decryption circuit includes a first decryption circuit, a second decryption circuit, an input switching unit, and an output switching unit. The first predetermined bit of the ciphertext data string is selected by the input switching unit, and the first switching is performed. While decoding by the decoding circuit,
A bit string following a predetermined bit at the head of the ciphertext data string is selected by the input switching means and decrypted by the second decryption circuit, and the plaintext data obtained by the first decryption circuit and the second decryption are obtained. 2. The first key data register according to claim 1, wherein the plaintext data obtained by the circuit is selected and output by the output switching means, and wherein the first decryption circuit generates common key data. A first block decryption circuit for decrypting a block cipher having a predetermined bit length based on the common key data;
A first exclusive logic circuit for performing an exclusive OR operation on upper predetermined bits of the decrypted data decrypted from the first block decryption circuit and predetermined bits extracted from the ciphertext data string to generate and output plaintext data; A first shift register that stores and holds the ciphertext data sequence while shifting the ciphertext data sequence upward by a predetermined bit sequentially and supplies the held ciphertext data to the first block decryption circuit; 2. The second key data register according to claim 1, wherein the second decryption circuit generates common key data, and a second block decryption circuit that decrypts a block cipher having a predetermined bit length based on the second common key data. And exclusive OR operation of upper predetermined bits of the decrypted data decrypted from the block decryption circuit and predetermined bits extracted from the ciphertext data string to generate plaintext data. A second exclusive logic circuit for storing and holding the ciphertext data sequence while sequentially shifting the ciphertext data sequence upward by a predetermined bit, and supplying the held ciphertext data to the second block decryption circuit. A shift register, and transferring the ciphertext data held in the first shift register to the second decryption circuit in a process of generating plaintext data in the first decryption circuit;
This is set as the initial value of the second shift register.

【0021】本発明に係わるブロック暗号化、復号回路
の請求項3記載の発明は、請求項1記載のブロック暗号
化回路において、前記第2のブロック暗号化回路で前記
第1のブロック暗号回路を併用したものである。本発明
に係わるブロック暗号化、復号回路の請求項4記載の発
明は、請求項2記載のブロック復号回路において、前記
第2のブロック復号回路で前記第1のブロック復号回路
を併用したものである。
According to a third aspect of the block encryption / decryption circuit according to the present invention, in the block encryption circuit according to the first aspect, the first block encryption circuit is replaced by the second block encryption circuit. It was used in combination. According to a fourth aspect of the block encryption / decryption circuit according to the present invention, in the block decryption circuit according to the second aspect, the second block decryption circuit is used in combination with the first block decryption circuit. .

【0022】[0022]

【発明の実施の形態】以下図示した実施の形態例に基づ
いて本発明を詳細に説明する。図1及び図2は本発明に
係わるブロック暗号化、復号回路の実施の形態例のブロ
ック図を示したものであって、図1は暗号化回路、図2
は復号回路のブロック図を示したものである。図1に示
したブロック暗号回路は、所定の入力手段から入力され
た平文のデータ列を取り込み8ビット毎抽出して平文デ
ータを出力する入力バッファ1と、入力端子と第1の出
力端子と第2の出力端子を有し前記入力バッファ1から
供給された平文データを選択出力する入力切換手段25
と、前記入力切換手段25の第1の出力端子から選択供
給された平文データの先頭8ビットを1ビットずつ取り
込み保持するシフトレジスタ26と、前記シフトレジス
タ26が保持する平文データの先頭8ビットを1ビット
ずつ暗号化する第1の暗号化回路27と、前記入力切換
手段25の第2の出力端子から供給された平文データの
先頭8ビットの後続データを8ビットずつ暗号化処理す
る第2の暗号化回路28と、前記第1の暗号化回路27
が出力する暗号文データを1ビットずつ格納し8ビット
の暗号文データを保持するシフトレジスタ29と、前記
シフトレジスタ29の保持する8ビット暗号文データと
前記第2の暗号化回路28の出力する8ビットの暗号文
データとを選択して出力する出力切換手段30と、前記
出力切換手段30から供給された暗号文データを保持す
る出力バッファ3と、前記出力切換手段28及び入力切
換手段25の切換動作を制御する制御部31とを備えて
いる。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS The present invention will be described below in detail based on illustrated embodiments. 1 and 2 show block diagrams of an embodiment of a block encryption / decryption circuit according to the present invention. FIG. 1 shows an encryption circuit, and FIG.
Shows a block diagram of a decoding circuit. The block cipher circuit shown in FIG. 1 includes an input buffer 1 which takes in a plaintext data sequence input from a predetermined input means, extracts every 8 bits, and outputs plaintext data, an input terminal, a first output terminal, and a first output terminal. Input switching means 25 having two output terminals for selectively outputting the plaintext data supplied from the input buffer 1
A shift register 26 which takes in and holds the first 8 bits of the plaintext data selectively supplied from the first output terminal of the input switching means 25 one bit at a time, and a first 8 bits of the plaintext data held by the shift register 26. A first encryption circuit 27 for encrypting one bit at a time, and a second encryption circuit for encrypting the subsequent eight bits of the first eight bits of the plaintext data supplied from the second output terminal of the input switching means 25 at a time. An encryption circuit 28 and the first encryption circuit 27;
The shift register 29 stores the ciphertext data output by the first bit by one bit and holds the 8-bit ciphertext data, and outputs the 8-bit ciphertext data held by the shift register 29 and the second encryption circuit 28. An output switching unit 30 for selecting and outputting 8-bit ciphertext data, an output buffer 3 for holding the ciphertext data supplied from the output switching unit 30, an output switching unit 28 and an input switching unit 25. A control unit 31 for controlling the switching operation.

【0023】また、第1の暗号化回路27は所定ビット
長の共通鍵データを保持する鍵データレジスタ32と、
前記鍵データレジスタ32から供給される共通鍵データ
を基に後述するフィードバックされた64ビットデータ
を暗号化し64ビットのブロック暗号を生成するブロッ
ク暗号化回路33と、前記ブロック暗号化回路33の出
力する64ビットブロック暗号を保持するレジスタ34
と、前記レジスタ34の保持した64ビットブロック暗
号の上位1ビットを抽出し保持するレジスタ35と、シ
フトレジスタ26から1ビットずつ供給された平文デー
タを保持するレジスタ36と、前記レジスタ36の保持
する1ビットの平文データとレジスタ35の保持する1
ビットのブロック暗号データとを排他的論理和演算を行
い1ビットの暗号文データを出力する排他的論理和回路
37と、前記排他的論理和回路37が出力する1ビット
の暗号文データを保持しシフトレジスタ29に供給する
レジスタ38と、前記レジスタ38が出力した1ビット
暗号文データを格納すると共に格納した1ビット暗号文
データを順次上位方向へシフトさせながら65ビットの
暗号文データを保持するシフトレジスタ39(フィード
バックバッファ)と、前記シフトレジスタ39の保持し
た65ビットの暗号文データの上位64ビットを保持す
るレジスタ40とを備え、前記レジスタ40の保持した
64ビットデータは前記ブロック暗号化回路33にフィ
ードバックデータとして供給されている。
The first encryption circuit 27 includes a key data register 32 for holding common key data having a predetermined bit length,
Based on the common key data supplied from the key data register 32, a block encryption circuit 33 for encrypting 64-bit data fed back, which will be described later, to generate a 64-bit block cipher, and outputs the block encryption circuit 33. Register 34 for holding 64-bit block cipher
A register 35 for extracting and holding the upper 1 bit of the 64-bit block cipher held by the register 34; a register 36 for holding plaintext data supplied bit by bit from the shift register 26; 1-bit plaintext data and 1 held by the register 35
An exclusive OR circuit 37 that performs an exclusive OR operation on the bit block cipher data and outputs 1-bit ciphertext data, and holds the 1-bit ciphertext data output by the exclusive OR circuit 37. A register 38 to be supplied to the shift register 29, and a shift for storing the 1-bit ciphertext data output from the register 38 and holding the 65-bit ciphertext data while sequentially shifting the stored 1-bit ciphertext data upward. A register 39 (feedback buffer); and a register 40 for storing upper 64 bits of the 65-bit ciphertext data held by the shift register 39. The 64-bit data held by the register 40 is stored in the block encryption circuit 33. As feedback data.

【0024】更に、第2の暗号化回路28は所定ビット
長の共通鍵データを格納する鍵データレジスタ41と、
前記鍵データレジスタ41から供給される共通鍵データ
を基に後述するフィードバックされた64ビットデータ
を暗号化し64ビットのブロック暗号を発生するブロッ
ク暗号化回路42と、前記ブロック暗号化回路42の出
力する64ビットブロック暗号を保持するレジスタ43
と、前記レジスタ43の保持した64ビットブロック暗
号の上位8ビットを抽出し保持するレジスタ44と、入
力切換手段25から供給された8ビットの平文データを
保持するレジスタ45と、前記レジスタ45の保持する
8ビットの平文データとレジスタ44の保持する8ビッ
トのブロック暗号データとを排他的論理和演算を行い8
ビットの暗号文データを出力する排他的論理和回路46
と、前記排他的論理和回路46が出力する8ビットの暗
号文データを保持し出力切換手段30に供給するレジス
タ47と、前記レジスタ47が出力した8ビット暗号文
データを格納すると共に該格納した8ビット暗号文デー
タを順次上位方向へシフトさせながら72ビットの暗号
文データを保持するシフトレジスタ48(フィードバッ
クバッファ)と、前記シフトレジスタ48の保持した7
2ビットの暗号文データの上位64ビットを保持するレ
ジスタ49とを備え、前記レジスタ49の保持した64
ビットデータは前記ブロック暗号化回路42にフィード
バックデータとして供給されている。
Further, the second encryption circuit 28 has a key data register 41 for storing common key data having a predetermined bit length,
Based on the common key data supplied from the key data register 41, a block encryption circuit 42 for encrypting feedback 64-bit data, which will be described later, to generate a 64-bit block cipher, and outputs the block encryption circuit 42. Register 43 for holding 64-bit block cipher
A register 44 for extracting and holding the upper 8 bits of the 64-bit block cipher held by the register 43; a register 45 for holding the 8-bit plaintext data supplied from the input switching means 25; The exclusive-OR operation is performed on the 8-bit plaintext data to be performed and the 8-bit block cipher data held by the register 44 to obtain
Exclusive OR circuit 46 for outputting bit ciphertext data
And a register 47 for holding the 8-bit ciphertext data output from the exclusive OR circuit 46 and supplying it to the output switching means 30; and storing and storing the 8-bit ciphertext data output from the register 47. A shift register 48 (feedback buffer) for holding the 72-bit ciphertext data while sequentially shifting the 8-bit ciphertext data in the upper direction;
A register 49 for holding upper 64 bits of the 2-bit ciphertext data;
The bit data is supplied to the block encryption circuit 42 as feedback data.

【0025】なお、シフトレジスタ39が保持する上位
64ビットデータは制御部31を介してシフトレジスタ
48の上位64ビットに転送されるようになっていると
共に、制御部31はシフトレジスタ26のデータ転送タ
イミング及び入力切換手段25と出力切換手段30の切
換タイミングを制御している。
The upper 64 bits of data held by the shift register 39 are transferred to the upper 64 bits of the shift register 48 via the control section 31. The timing and the switching timing of the input switching means 25 and the output switching means 30 are controlled.

【0026】一方、図2に示したブロック復号回路は、
所定の入力手段から入力された暗号文データ列を取り込
み8ビット毎抽出して暗号文データを出力する入力バッ
ファ1と、入力端子と第1の出力端子と第2の出力端子
とを有し前記入力バッファ1から供給された暗号文デー
タを選択出力する入力切換手段50と、前記入力切換手
段50の第1の出力端子から選択供給された先頭8ビッ
トの暗号文データを保持するシフトレジスタ51と、前
記シフトレジスタ51が保持する先頭8ビットの暗号文
データを1ビットずつ復号する第1の復号回路52と、
前記入力切換手段51の第2の出力端子から供給された
先頭8ビットの暗号文データの後続データを8ビットず
つ復号処理する第2の復号回路53と、前記第1の復号
回路52が出力する平文データを1ビットずつ格納し8
ビットの平文データを保持するシフトレジスタ54と、
前記シフトレジスタ54の保持する8ビット平文データ
と前記第2の復号回路53の出力する8ビットの平文デ
ータとを選択して出力する出力切換手段55と、前記出
力切換手段55から供給された平文データを保持する出
力バッファ6と、前記出力切換手段55及び入力切換手
段50の切換動作を制御する制御部56とを備えてい
る。
On the other hand, the block decoding circuit shown in FIG.
An input buffer 1 for taking in a ciphertext data string input from a predetermined input means, extracting the ciphertext data every 8 bits, and outputting ciphertext data, and having an input terminal, a first output terminal, and a second output terminal. An input switching means 50 for selectively outputting the ciphertext data supplied from the input buffer 1; a shift register 51 for holding the leading 8-bit ciphertext data selectively supplied from the first output terminal of the input switching means 50; A first decryption circuit 52 that decrypts the leading 8-bit ciphertext data held by the shift register 51 bit by bit;
A second decryption circuit 53 for decrypting the subsequent data of the 8-bit ciphertext data supplied from the second output terminal of the input switching means 51 in 8-bit units, and the first decryption circuit 52 outputs. Stores plaintext data one bit at a time
A shift register 54 holding bit plaintext data;
Output switching means 55 for selecting and outputting 8-bit plaintext data held by the shift register 54 and 8-bit plaintext data output by the second decoding circuit 53, and plaintext supplied from the output switching means 55 An output buffer 6 for holding data and a control unit 56 for controlling the switching operation of the output switching means 55 and the input switching means 50 are provided.

【0027】また、第1の復号回路52は所定ビット長
の共通鍵データを格納する鍵データレジスタ57と、前
記鍵データレジスタ57から供給される共通鍵データを
基に後述する64ビットデータを復号し64ビットの復
号データを生成するブロック復号回路58と、前記ブロ
ック復号回路58の出力する64ビット復号データを保
持するレジスタ59と、前記レジスタ59の保持した6
4ビット復号データの上位1ビットを抽出し保持するレ
ジスタ60と、シフトレジスタ51から1ビットずつ供
給された暗号文データを保持するレジスタ61と、前記
レジスタ61の保持する1ビットの暗号文データと前記
レジスタ60の保持する1ビットの復号データとを排他
的論理和演算を行い1ビットの平文データを出力する排
他的論理和回路62と、前記排他的論理和回路62が出
力する1ビットの平文データを保持しシフトレジスタ5
4に供給するレジスタ63と、前記レジスタ61が保持
した1ビット暗号文データを格納すると共に格納した1
ビット暗号文データを順次上位方向へシフトさせながら
65ビットの平文データを保持するシフトレジスタ64
と、前記シフトレジスタ64の保持した65ビットの暗
号文データの上位64ビットを保持するレジスタ65と
を備え、前記レジスタ65の保持した64ビットデータ
は前記ブロック復号回路58に供給されている。
The first decryption circuit 52 decrypts 64-bit data described later on the basis of the key data register 57 for storing common key data of a predetermined bit length and the common key data supplied from the key data register 57. A block decoding circuit 58 for generating 64-bit decoded data, a register 59 for holding the 64-bit decoded data output from the block decoding circuit 58,
A register 60 for extracting and holding the upper one bit of the 4-bit decrypted data, a register 61 for holding the ciphertext data supplied bit by bit from the shift register 51, and a 1-bit ciphertext data held by the register 61 An exclusive-OR circuit 62 for performing an exclusive-OR operation on the 1-bit decoded data held by the register 60 and outputting 1-bit plaintext data; and a 1-bit plaintext output by the exclusive-OR circuit 62 Shift register 5 for holding data
4 for storing the 1-bit ciphertext data held by the register 61,
A shift register 64 for holding 65-bit plaintext data while sequentially shifting the bit ciphertext data upward.
And a register 65 for holding the upper 64 bits of the 65-bit ciphertext data held by the shift register 64. The 64-bit data held by the register 65 is supplied to the block decryption circuit 58.

【0028】更に、第2の復号回路53は所定ビット長
の共通鍵データを格納する鍵データレジスタ66と、前
記鍵データレジスタ66から供給される共通鍵データを
基に後述する64ビットデータを復号し64ビットの復
号データを発生するブロック復号回路67と、前記ブロ
ック復号回路67の出力する64ビット復号データを保
持するレジスタ68と、前記レジスタ68の保持した6
4ビット復号データの上位8ビットを抽出し保持するレ
ジスタ69と、入力切換手段50から供給された8ビッ
トの暗号文データを保持するレジスタ70と、前記レジ
スタ70の保持する8ビットの暗号文データとレジスタ
69の保持する8ビットの復号データとを排他的論理和
演算を行い8ビットの平文データを出力する排他的論理
和回路71と、前記排他的論理和回路71が出力する8
ビットの平文データを保持し出力切換手段55に供給す
るレジスタ72と、前記レジスタ70が保持した8ビッ
トの暗号文データを格納すると共に格納した8ビットを
順次上位方向へシフトさせながら72ビットの暗号文デ
ータを保持するシフトレジスタ73と、前記シフトレジ
スタ73の保持した72ビットの暗号文データの上位6
4ビットを保持するレジスタ74とを備え、前記レジス
タ74の保持した64ビットデータはブロック復号回路
67に供給されている。
Further, the second decryption circuit 53 decrypts 64-bit data described later based on the key data register 66 for storing common key data of a predetermined bit length and the common key data supplied from the key data register 66. A block decoding circuit 67 for generating 64-bit decoded data, a register 68 for holding 64-bit decoded data output from the block decoding circuit 67,
A register 69 for extracting and holding the upper 8 bits of the 4-bit decrypted data, a register 70 for holding the 8-bit ciphertext data supplied from the input switching means 50, and an 8-bit ciphertext data held by the register 70 And an exclusive OR circuit 71 for performing an exclusive OR operation on the 8-bit decoded data held in the register 69 and outputting 8-bit plaintext data, and 8 output from the exclusive OR circuit 71.
A register 72 for storing bit plaintext data and supplying it to the output switching means 55; and a 72-bit ciphertext for storing the 8-bit ciphertext data held by the register 70 and sequentially shifting the stored 8 bits upward. Shift register 73 for holding the sentence data, and the upper 6 bits of the 72-bit ciphertext data held by the shift register 73.
A register 74 for holding 4 bits, and the 64-bit data held by the register 74 is supplied to a block decoding circuit 67.

【0029】なお、シフトレジスタ64が保持する上位
64ビットデータは制御部56を介してシフトレジスタ
73の上位64ビットに転送されるようになっていると
共に、制御部56はシフトレジスタ51のデータ転送タ
イミング及び入力切換手段50と出力切換手段55の切
換タイミングを制御している。
The upper 64 bits of data held by the shift register 64 are transferred to the upper 64 bits of the shift register 73 via the controller 56, and the controller 56 transfers the data of the shift register 51 to the upper 64 bits. The timing and the switching timing of the input switching means 50 and the output switching means 55 are controlled.

【0030】ここで、鍵データレジスタ32と鍵データ
レジスタ57は全く同じ鍵データを有すると共に、鍵デ
ータレジスタ41と鍵データレジスタ66は全く同じ鍵
データを有する。更にブロック暗号化回路33とブロッ
ク復号回路58は全く同じ動作を行うとともに、ブロッ
ク暗号化回路42とブロック復号回路67は全く同じ動
作を行っている。
Here, the key data register 32 and the key data register 57 have exactly the same key data, and the key data register 41 and the key data register 66 have exactly the same key data. Further, the block encryption circuit 33 and the block decryption circuit 58 perform exactly the same operation, and the block encryption circuit 42 and the block decryption circuit 67 perform exactly the same operation.

【0031】以下図1及び図2に示した本発明に係わる
ブロック暗号化/復号回路の動作について説明する。ま
ず、図1の暗号化回路の動作について説明する。暗号化
回路が起動すると、第1の暗号化回路27においてシフ
トレジスタ39の上位64ビットは所定の初期値に設定
される。次に、前記シフトレジスタ39に初期設定した
上位64ビットをレジスタ40に転送する。ブロック暗
号化回路33は前記レジスタ40に保持した64ビット
データを鍵データレジスタ32から供給される所定ビッ
ト長の鍵データで暗号化し64ビットのブロック暗号を
出力しレジスタ34に転送する。そして、レジスタ34
は保持した64ビットのブロック暗号の上位8ビットを
レジスタ35に転送する。
The operation of the block encryption / decryption circuit according to the present invention shown in FIGS. 1 and 2 will be described below. First, the operation of the encryption circuit of FIG. 1 will be described. When the encryption circuit starts, the upper 64 bits of the shift register 39 in the first encryption circuit 27 are set to a predetermined initial value. Next, the upper 64 bits initially set in the shift register 39 are transferred to the register 40. The block encryption circuit 33 encrypts the 64-bit data held in the register 40 with key data having a predetermined bit length supplied from the key data register 32, outputs a 64-bit block cipher, and transfers the block cipher to the register. And the register 34
Transfers the upper 8 bits of the held 64-bit block cipher to the register 35.

【0032】一方、図1に図示されない入力手段から入
力バッファ1へ平文データの先頭8ビットを入力する。
そして、入力バッファ1は先頭の8ビットを入力切換手
段25に転送した後これを削除する。入力切換手段25
は転送された先頭8ビットの暗号文データを選択し第1
の出力端子へ出力すると共にシフトレジスタ26へ供給
する。更に、シフトレジスタ26は制御部31に従い保
持した8ビットの平文データの最下位1ビットをレジス
タ36に転送するとともに保持した8ビットを下位方向
へ1ビット分シフトさせる。そこで、排他的論理和回路
37はレジスタ36に保持した1ビットの平文データと
レジスタ35に保持した1ビットのブロック暗号とを排
他的論理和演算を実行し1ビットの暗号文データを生成
出力する。これをレジスタ38に保持すると共にシフト
レジスタ29の最上位ビットへ転送する。そしてシフト
レジスタ29はこれを下位方向へ1ビット分シフトさせ
て保持する。
On the other hand, the first 8 bits of the plaintext data are input to the input buffer 1 from input means not shown in FIG.
Then, the input buffer 1 deletes the first 8 bits after transferring them to the input switching means 25. Input switching means 25
Selects the transmitted 8-bit ciphertext data, and
And output to the shift register 26. Further, the shift register 26 transfers the least significant one bit of the 8-bit plaintext data held by the control unit 31 to the register 36 and shifts the held eight bits by one bit in the lower direction. The exclusive OR circuit 37 performs an exclusive OR operation on the 1-bit plaintext data held in the register 36 and the 1-bit block cipher held in the register 35 to generate and output 1-bit ciphertext data. . This is held in the register 38 and transferred to the most significant bit of the shift register 29. Then, the shift register 29 shifts this by one bit in the lower direction and holds it.

【0033】次に、レジスタ38の保持した1ビット暗
号文データをシフトレジスタ39の最下位ビットへ転送
する。そして、シフトレジスタ39はこれを上位方向へ
1ビシフトさせる。ここで、シフトレジスタ39の上位
64ビットは上位方向へ1ビット分シフトした結果、上
位64ビットは初期値から変化し新たな値となってい
る。これをレジスタ40に保持しブロック暗号化回路3
3に供給する。ブロック暗号化回路33はこれを鍵デー
タレジスタ32から供給された鍵データを基に暗号化し
64ビットのブロック暗号を生成する。そしてレジスタ
34に保持し上位1ビットをレジスタ35に保持する。
更に、シフトレジスタ26の最下位ビットから次の平文
データを1ビット分入力しレジスタ36に転送すると、
同様にレジスタ35とレジスタ36にそれぞれ保持した
1ビットデータを排他的論理和回路37で演算し次の1
ビットの暗号文データを生成出力する。
Next, the 1-bit ciphertext data held in the register 38 is transferred to the least significant bit of the shift register 39. Then, the shift register 39 shifts this one bit upward. Here, as a result of shifting the upper 64 bits of the shift register 39 by one bit in the upper direction, the upper 64 bits are changed from the initial value to a new value. This is held in the register 40 and the block encryption circuit 3
Supply 3 The block encryption circuit 33 encrypts this based on the key data supplied from the key data register 32 to generate a 64-bit block cipher. Then, it is held in the register 34 and the upper one bit is held in the register 35.
Further, when the next plaintext data for one bit is input from the least significant bit of the shift register 26 and transferred to the register 36,
Similarly, the exclusive OR circuit 37 operates the 1-bit data held in the registers 35 and 36, respectively, and
Generates and outputs bit ciphertext data.

【0034】レジスタ38は排他的論理回路37から供
給された1ビット暗号文データを再びシフトレジスタ2
9の最上位ビットに転送すると共に、シフトレジスタ3
9の最下位ビットに転送する。そして、シフトレジスタ
29はこれを下位方向へ1ビット分シフトさせて格納保
持すると共に、シフトレジスタ39は上位方向へ1ビッ
ト分シフトさせて格納保持する。ここまで、シフトレジ
スタ29には先頭2ビットの暗号文データが保持されて
いる。
The register 38 converts the 1-bit ciphertext data supplied from the exclusive logic circuit 37 into the shift register 2 again.
9 and the shift register 3
9 to the least significant bit. The shift register 29 shifts this by one bit in the lower direction and stores and holds it, and the shift register 39 shifts it by one bit in the upper direction and stores and holds it. Up to this point, the shift register 29 holds the ciphertext data of the first two bits.

【0035】以上説明した動作を順次繰り返していく
と、シフトレジスタ26から1ビットずつ供給された平
文データは1ビットずつ暗号化され、シフトレジスタ2
9には8ビットの暗号文データが格納、保持される。そ
して、これを出力切換手段30を介して出力バッファ3
に保持する。ここまで、平文データの先頭8ビットを順
次1ビットずつ暗号化する過程について説明した。
When the above-described operations are sequentially repeated, the plaintext data supplied bit by bit from the shift register 26 is encrypted bit by bit, and the shift register 2
Reference numeral 9 stores and holds 8-bit ciphertext data. Then, this is output to the output buffer 3 via the output switching means 30.
To hold. So far, the process of sequentially encrypting the first 8 bits of the plaintext data one bit at a time has been described.

【0036】次に、先頭8ビットの後続データを暗号化
する過程について説明する。まず、第1の暗号化回路2
7によって先頭8ビットの平文データの暗号化を完了し
出力バッファ3から先頭8ビットの暗号文データを出力
手段へ出力するとともに、出力バッファ3に保持したデ
ータを削除する。次に、レジスタ39に保持した上位6
4ビットのデータを制御部31を介してシフトレジスタ
48の上位64ビットへ転送し初期値とする。そして、
入力手段から後続の8ビット平文データを入力バッファ
1へ供給する。入力バッファ1はこれを入力切換手段2
5に供給した後削除する。入力切換手段25は供給され
た8ビット平文データを第2の出力端子からレジスタ4
5に転送する。
Next, a process of encrypting the subsequent data of the first 8 bits will be described. First, the first encryption circuit 2
7, the encryption of the head 8-bit plaintext data is completed, the head 8-bit ciphertext data is output from the output buffer 3 to the output means, and the data held in the output buffer 3 is deleted. Next, the upper 6
The 4-bit data is transferred to the upper 64 bits of the shift register 48 via the control unit 31 and set as an initial value. And
The input means supplies the subsequent 8-bit plaintext data to the input buffer 1. The input buffer 1 uses this as input switching means 2
5 and then deleted. The input switching means 25 transfers the supplied 8-bit plaintext data from the second output terminal to the register 4.
Transfer to 5.

【0037】一方、シフトレジスタ48に保持した上位
64ビットの初期値をレジスタ49で保持し、これをブ
ロック暗号化回路42へ入力して鍵データレジスタ41
の保持する鍵データを基に暗号化する。そして生成した
64ビットのブロック暗号をレジスタ43に保持し、上
位8ビットをレジスタ44で抽出し保持する。更に、排
他的論理和回路46で前記レジスタ44に保持した8ビ
ットのブロック暗号とレジスタ45に保持した8ビット
の平文データとを各ビット毎に排他的論理和演算処理し
8ビットの暗号文データをレジスタ47に出力する。
On the other hand, the initial value of the upper 64 bits held in the shift register 48 is held in the register 49, and this is input to the block encryption circuit 42 and is inputted to the key data register 41.
Is encrypted based on the key data held by. Then, the generated 64-bit block cipher is held in the register 43, and the upper 8 bits are extracted and held in the register 44. The exclusive-OR circuit 46 performs an exclusive-OR operation on the 8-bit block cipher held in the register 44 and the 8-bit plaintext data held in the register 45 for each bit, thereby obtaining 8-bit ciphertext data. Is output to the register 47.

【0038】レジスタ47は排他的論理和回路46から
供給された8ビットの暗号文データを出力切換手段30
に供給する。出力切換手段30は制御部31に従いこれ
を選択し出力バッファ3へ供給する。そして、出力バッ
ファ3は保持した8ビットの暗号文データを出力手段へ
供給し削除する。次に、レジスタ47は保持した8ビッ
トの暗号文データをシフトレジスタ48に転送する。シ
フトレジスタ47はこれを上位方向へ8ビットシフトさ
せながら格納し保持する。これをレジスタ49に保持
し、ブロック暗号化回路42でブロック暗号化する。更
にこれをレジスタ43で保持し上位8ビット分をレジス
タ44に保持する。
The register 47 outputs the 8-bit ciphertext data supplied from the exclusive OR circuit 46 to the output switching means 30.
To supply. The output switching means 30 selects this according to the control unit 31 and supplies it to the output buffer 3. Then, the output buffer 3 supplies the held 8-bit ciphertext data to the output unit and deletes it. Next, the register 47 transfers the held 8-bit ciphertext data to the shift register 48. The shift register 47 stores and holds this while shifting it by 8 bits in the upper direction. This is stored in the register 49 and the block encryption circuit 42 performs block encryption. This is held in the register 43, and the upper 8 bits are held in the register 44.

【0039】そして、入力手段から新たに8ビットの平
文データを入力バッファ1に供給し、これを入力切換手
段25の第2の出力端子からレジスタ45に転送する。
排他的論理和回路46はレジスタ45に新たに保持した
8ビット平文データとレジスタ44に新たに保持した8
ビットのブロック暗号を排他的論理和演算処理し8ビッ
トの暗号文データを出力しレジスタ47に供給する。レ
ジスタ47はこれを保持し出力切換回路30を介して出
力バッファ6に供給すると共にシフトレジスタ48に転
送する。出力バッファ3はこれを出力手段に出力した
後、保持したデータを削除する。
Then, new 8-bit plaintext data is supplied from the input means to the input buffer 1 and transferred to the register 45 from the second output terminal of the input switching means 25.
The exclusive OR circuit 46 stores the 8-bit plaintext data newly stored in the register 45 and the 8-bit plaintext data newly stored in the register 44.
The exclusive OR operation is performed on the bit block cipher, and 8-bit ciphertext data is output and supplied to the register 47. The register 47 holds this, supplies it to the output buffer 6 via the output switching circuit 30, and transfers it to the shift register 48. After outputting this to the output means, the output buffer 3 deletes the held data.

【0040】以上の処理を繰り返すと、第1の暗号化回
路27で暗号化された先頭8ビットに続き、第2の暗号
化回路28によって後続の平文データは8ビットずつ順
次暗号化され、出力バッファ3から出力手段へ暗号文デ
ータ列が出力される。
By repeating the above processing, the plaintext data following the first 8 bits encrypted by the first encryption circuit 27 and the subsequent plaintext data are sequentially encrypted by the second encryption circuit 28 in units of 8 bits. The ciphertext data string is output from the buffer 3 to the output means.

【0041】次に、図1にて生成した暗号文データを復
号する過程を説明する。復号する処理は暗号化する処理
と同様に、図2において入力手段から入力バッファ4へ
供給した先頭8ビットの暗号文データを入力切換手段5
0を介して第1の復号回路52に供給しこれを1ビット
ずつ復号する。更に前記先頭8ビットの暗号文データの
後続データを入力切換手段50を介して第2の復号回路
53へ供給しこれを8ビットずつ復号する。このよう
に、入力手段から入力された暗号文データは第1の復号
回路52と第2の復号回路53で処理されるので、出力
バッファ6から復号した平文データが出力手段へ供給さ
れる。なお、第1の復号回路52及び第2の復号回路5
3の動作については、レジスタ61、70からデータを
シフトレジスタ64、73にそれぞれ転送する点を除け
ば、第1の暗号化回路27及び第2の暗号化回路28と
全く同じものであり、詳細な説明は省略する。
Next, the process of decrypting the ciphertext data generated in FIG. 1 will be described. The decrypting process is similar to the encrypting process in that the leading 8-bit ciphertext data supplied from the input means to the input buffer 4 in FIG.
The signal is supplied to the first decoding circuit 52 via the "0" and is decoded bit by bit. Further, the succeeding data of the ciphertext data of the first 8 bits is supplied to the second decryption circuit 53 via the input switching means 50, and the second decryption circuit 53 decrypts the data by 8 bits. As described above, the ciphertext data input from the input means is processed by the first decryption circuit 52 and the second decryption circuit 53, and the decrypted plaintext data is supplied from the output buffer 6 to the output means. Note that the first decoding circuit 52 and the second decoding circuit 5
The operation 3 is exactly the same as the first encryption circuit 27 and the second encryption circuit 28 except that data is transferred from the registers 61 and 70 to the shift registers 64 and 73, respectively. Detailed description is omitted.

【0042】このように、平文データの先頭8ビットを
1ビットずつ第1の暗号化回路27で暗号化し、且つ第
1の暗号化回路27で生成した暗号文データを第2の暗
号化回路28のシフトレジスタ48の初期値の一部とし
て設定したことによって、第2の暗号化回路28で暗号
化される最初の8ビットデータは毎回異なったデータと
なるので、入力バッファ1と出力バッファ3の情報を入
手しても最初の8ビットを解読することが不可能とな
る。なお、第1の暗号化回路27においてシフトレジス
タ39の上位64ビットに初期値として固定値を設定し
ており、1ビットずつ暗号化しているので先頭8ビット
の暗号文データのうち最初の1ビットについては解読が
可能となってしまうが、後続の7ビット分については解
読不可能なため、従来先頭の8ビットが解読できてしま
った問題を解消するに充分な効果を得ることができる。
As described above, the first 8 bits of the plaintext data are encrypted one bit at a time by the first encryption circuit 27, and the encrypted data generated by the first encryption circuit 27 is encrypted by the second encryption circuit 28. Is set as a part of the initial value of the shift register 48, the first 8-bit data encrypted by the second encryption circuit 28 becomes different data every time. Obtaining information makes it impossible to decode the first 8 bits. In the first encryption circuit 27, a fixed value is set as an initial value in the upper 64 bits of the shift register 39, and encryption is performed one bit at a time. Can be decoded, but the subsequent 7 bits cannot be decoded, so that a sufficient effect can be obtained to solve the problem that the first 8 bits could be decoded conventionally.

【0043】以上説明したブロック暗号化、復号回路に
ついては、第1の暗号化回路27において1ビットずつ
平文データを暗号化し、且つ第1の復号回路52におい
ては1ビットずつ復号するとしたが、本発明にあっては
これに限らず。例えば、第1の暗号化回路27及び第1
の復号回路52において、2ビット或いは4ビットずつ
暗号化、復号してもよい。この場合は暗号化した先頭8
ビットのうち、最初の2ビット或いは4ビットが解読さ
れる可能性が高いので説明した実施例に比べ暗号強度が
下がるものの、先頭の8ビットについては2ビット或い
は4ビットずつ暗号化するので、処理時間を短縮化でき
るであろう。
In the block encryption / decryption circuit described above, the plaintext data is encrypted one bit at a time in the first encryption circuit 27, and the plaintext data is decrypted one bit at a time in the first decryption circuit 52. The invention is not limited to this. For example, the first encryption circuit 27 and the first
In the decryption circuit 52, encryption and decryption may be performed in units of 2 bits or 4 bits. In this case, the encrypted first 8
Of the bits, the first two bits or four bits are more likely to be decrypted, so the encryption strength is lower than in the embodiment described above. However, the leading eight bits are encrypted two or four bits at a time. You could save time.

【0044】更に、第2の暗号化回路28及び第2の復
号回路53においては8ビットずつ処理するとしたが、
本発明にあってはこれにかぎらず、処理するビット数を
更に増やすといったことも可能である。なお、入力手段
或いは出力手段とのインタフェースを考慮すると8ビッ
ト(1バイト)或いはその倍数毎に処理する方法がデー
タ処理上最も扱いやすくなるので実施例においては8ビ
ット毎の処理方法とした。
Further, in the second encryption circuit 28 and the second decryption circuit 53, 8 bits are processed at a time.
The present invention is not limited to this, and the number of bits to be processed can be further increased. In consideration of the interface with the input means or the output means, the method of processing every 8 bits (1 byte) or a multiple thereof is the easiest to handle in data processing.

【0045】また、いずれか一つの暗号化回路で第1の
暗号化回路及び第2の暗号化回路を共用するようにして
もよいであろう。例えば、第1の暗号化回路27におい
て、レジスタ39を72ビットのものに変更しても、同
様に先頭8ビットを暗号化することができる。従って、
第2の暗号化回路で、まず先頭の8ビットを1ビットず
つ暗号化し、後続のデータを8ビットずつ暗号化するよ
うにする。このとき、シフトレジスタ48のシフト量を
1ビットか8ビットのいずれでも設定できるようにして
おく。このようにすれば、第1の暗号化回路27のシフ
トレジスタ39から上位64ビットを第2の暗号化回路
28へ転送する必要もない。更に、入力切換手段25や
出力切換手段30等の周辺回路は不要となり、回路規模
を相当コンパクト化できることは言うまでもない。な
お、復号回路についても同様に第1の復号回路52と第
2の復号回路53とをいずれか一つの復号回路で共用す
ることが可能である。
Further, the first encryption circuit and the second encryption circuit may be shared by any one of the encryption circuits. For example, even if the register 39 is changed to a 72-bit register in the first encryption circuit 27, the first 8 bits can be encrypted in the same manner. Therefore,
In the second encryption circuit, first, the first 8 bits are encrypted one bit at a time, and the subsequent data are encrypted eight bits at a time. At this time, the shift amount of the shift register 48 is set so that it can be set to either 1 bit or 8 bits. This eliminates the need to transfer the upper 64 bits from the shift register 39 of the first encryption circuit 27 to the second encryption circuit 28. Further, it goes without saying that peripheral circuits such as the input switching means 25 and the output switching means 30 are not required, and the circuit scale can be considerably reduced. Similarly, the first decoding circuit 52 and the second decoding circuit 53 can be shared by any one decoding circuit.

【0046】[0046]

【発明の効果】本発明は以上説明したように、共通鍵を
用いたブロック暗号化回路の暗号フィードバックモード
(暗号CFBモード)において、第1の暗号化回路によ
って平文データの先頭8ビットを暗号化し、第2の暗号
化回路によって該先頭の8ビットの後続データを暗号化
すると共に、前記第1の暗号化回路にて生成した暗号化
データの一部を第2の暗号化回路の初期値として設定し
たので、従来平文データの先頭の8ビットデータが解読
されやすい問題点を解決し、暗号強度の強い共通鍵方式
のブロック暗号化、復号回路を提供する上で著効を奏
す。
As described above, according to the present invention, the first eight bits of the plaintext data are encrypted by the first encryption circuit in the encryption feedback mode (encryption CFB mode) of the block encryption circuit using the common key. And the second encryption circuit encrypts the leading 8-bit subsequent data, and sets a part of the encrypted data generated by the first encryption circuit as an initial value of the second encryption circuit. The setting makes it possible to solve the problem that the leading 8-bit data of the plaintext data is easily deciphered, and to provide a block encryption / decryption circuit using a common key system having a high encryption strength.

【0047】[0047]

【図面の簡単な説明】[Brief description of the drawings]

【図1】本発明に係わるブロック暗号化回路の実施の形
態例を示すブロック図。
FIG. 1 is a block diagram showing an embodiment of a block encryption circuit according to the present invention.

【図2】本発明に係わるブロック復号回路の実施の形態
例を示すブロック図。
FIG. 2 is a block diagram showing an embodiment of a block decoding circuit according to the present invention.

【図3】従来のブロック暗号化、復号回路の実施の形態
例を示すブロック図。
FIG. 3 is a block diagram showing an embodiment of a conventional block encryption / decryption circuit.

【符号の説明】[Explanation of symbols]

1、4・・・入力バッファ 2・・・暗号化回路 3、6・・・出力バッファ 5・・・復号回路 7、16、32、41、57、66・・・鍵データレジス
タ 8、33、42・・・ブロック暗号化回路 9、10、11、13、15、18、19、20、2
2、24、34、35、36、38、40、43、4
4、45、47、49、59、60、61、63、6
5、68、69、70、72、74・・・レジスタ 12、21、37、46、62、71・・・排他的論理和
回路 14、23、26、29、39、48、64、73・・・
シフトレジスタ 17、58、67・・・ブロック復号回路 25、50・・・入力切換手段 27・・・第1の暗号化回路 28・・・第2の暗号化回路 30、55・・・出力切換手段 31、56・・・制御部 52・・・第1の復号回路 53・・・第2の復号回路
1, 4 ... input buffer 2 ... encryption circuit 3, 6 ... output buffer 5 ... decryption circuit 7, 16, 32, 41, 57, 66 ... key data register 8, 33, 42 ... Block encryption circuit 9, 10, 11, 13, 15, 18, 19, 20, 2
2, 24, 34, 35, 36, 38, 40, 43, 4
4, 45, 47, 49, 59, 60, 61, 63, 6
5, 68, 69, 70, 72, 74 ... registers 12, 21, 37, 46, 62, 71 ... exclusive OR circuits 14, 23, 26, 29, 39, 48, 64, 73・ ・
Shift register 17, 58, 67 ... block decryption circuit 25, 50 ... input switching means 27 ... first encryption circuit 28 ... second encryption circuit 30, 55 ... output switching Means 31, 56 Control unit 52 First decoding circuit 53 Second decoding circuit

Claims (4)

【特許請求の範囲】[Claims] 【請求項1】平文データ列から順次所定ビット毎抽出し
て暗号化し、所定ビット毎暗号文データ列を生成し出力
する共通鍵方式ブロック暗号化回路の暗号フィードバッ
クモード(暗号CFBモード)において、 第1の暗号化回路と第2の暗号化回路と入力切替手段と
出力切替手段とを備えた暗号化回路であって、前記平文
データ列の先頭の所定ビットを前記入力切替手段で選択
して前記第1の暗号化回路で暗号化するとともに、該平
文データ列の先頭の所定ビットに続くビット列を該入力
切替手段で選択して前記第2の暗号化回路で暗号化し、
前記第1の暗号化回路で得られた暗号文データ及び前記
第2の暗号化回路で得られた暗号文データとをそれぞれ
前記出力切替手段で選択し出力したものであって、 前記第1の暗号化回路は共通鍵データを生成する第1の
鍵データレジスタと、前記共通鍵データを基に所定ビッ
ト長のブロック暗号を生成する第1のブロック暗号化回
路と、前記第1のブロック暗号から抽出した上位所定ビ
ットと該平文データ列から抽出した所定ビットとを排他
的論理和演算処理し暗号文データを生成出力する第1の
排他的論理回路と、前記第1の排他的論理回路から供給
される暗号文データを所定ビット毎順次上位へシフトさ
せながら格納及び保持するとともに該保持した暗号文デ
ータを前記第1のブロック暗号化回路にフィードバック
供給する第1のシフトレジスタ(フィードバックバッフ
ァ)とを有し、 前記第2の暗号化回路は共通鍵データを生成する第2の
鍵データレジスタと、前記第2の共通鍵データを基に所
定ビット長のブロック暗号を生成する第2のブロック暗
号化回路と、前記ブロック暗号から抽出した上位所定ビ
ットと該平文データ列から抽出した所定ビットとを排他
的論理和演算処理し暗号文データを生成出力する第2の
排他的論理和回路と、前記第2の排他的論理和回路から
供給される暗号文データを順次上位へシフトさせながら
格納及び保持するとともに該保持した暗号文データを前
記第2のブロック暗号化回路にフィードバック供給する
第2のシフトレジスタ(フィードバックバッファ)とを
有し、 前記第1の暗号化回路で暗号文データを生成する過程に
おいて前記第1のシフトレジスタに保持した暗号文デー
タを前記第2の暗号化回路に転送し、これを該第2のシ
フトレジスタの初期値として設定したことを特徴とする
ブロック暗号化、復号回路。
In a cryptographic feedback mode (encryption CFB mode) of a common key type block encryption circuit for sequentially extracting and encrypting a predetermined bit from a plaintext data string and generating and outputting a ciphertext data string for each predetermined bit. A first encryption circuit, a second encryption circuit, an input switching unit, and an output switching unit, wherein the input switching unit selects a predetermined bit at the head of the plaintext data string, and While encrypting by the first encryption circuit, a bit string following a predetermined bit at the head of the plaintext data string is selected by the input switching means and encrypted by the second encryption circuit,
The ciphertext data obtained by the first encryption circuit and the ciphertext data obtained by the second encryption circuit are selected and output by the output switching means, respectively, An encryption circuit configured to generate a first key data register that generates common key data, a first block encryption circuit that generates a block cipher having a predetermined bit length based on the common key data, and A first exclusive logic circuit for performing an exclusive OR operation on the extracted upper predetermined bits and the predetermined bits extracted from the plaintext data string to generate and output ciphertext data; and a first exclusive logic circuit. The first cipher data is stored and held while sequentially shifting the cipher text data to be shifted upward by a predetermined bit, and the held cipher text data is fed back to the first block encryption circuit. A second key data register for generating common key data; and a block cipher having a predetermined bit length based on the second common key data. A second block encryption circuit that performs an exclusive OR operation on upper predetermined bits extracted from the block cipher and predetermined bits extracted from the plaintext data string to generate and output ciphertext data An OR circuit and storing and holding the ciphertext data supplied from the second exclusive OR circuit while sequentially shifting the ciphertext data upward, and feeding back the held ciphertext data to the second block encryption circuit. And a second shift register (feedback buffer) for supplying ciphertext data in the first encrypting circuit. Transfer the encrypted data held in the shift register to said second encryption circuit, block encryption, characterized in that it has been set as the initial value of the shift register of the second, decoding circuit.
【請求項2】請求項1記載の暗号化回路によって得られ
た暗号文データ列を所定ビット毎復号する復号回路であ
って、前記復号回路は第1の復号回路と第2の復回路と
入力切替手段と出力切替手段とを備え、前記暗号文デー
タ列の先頭の所定ビットを前記入力切替手段で選択して
前記第1の復号回路で復号するとともに、該暗号文デー
タ列の先頭の所定ビットに続くビット列を該入力切替手
段で選択して前記第2の復号回路で復号し、前記第1の
復号回路で得られた平文データ及び前記第2の復号回路
で得られた平文データとを前記出力切替手段で選択し出
力したものであって、 前記第1の復号回路は共通鍵データを生成する請求項1
記載の第1の鍵データレジスタと、前記共通鍵データを
基に所定ビット長のブロック暗号を復号する第1のブロ
ック復号回路と、前記第1のブロック復号回路から復号
した復号データの上位所定ビットと該暗号文データ列か
ら抽出した所定ビットとを排他的論理和演算処理し平文
データを生成出力する第1の排他的論理回路と、前記暗
号文データ列を所定ビット毎順次上位へシフトさせなが
ら格納及び保持するとともにに該保持した暗号文データ
を前記第1のブロック復号回路に供給する第1のシフト
レジスタとを有し、 前記第2の復号回路は共通鍵データを生成する請求項1
記載の第2の鍵データレジスタと、前記第2の共通鍵デ
ータを基に所定ビット長のブロック暗号を復号する第2
のブロック復号回路と、前記ブロック復号回路から復号
した復号データの上位所定ビットと該暗号文データ列か
ら抽出した所定ビットとを排他的論理和演算処理し平文
データを生成出力する第2の排他的論理回路と、前記暗
号文データ列を所定ビット毎順次上位へシフトさせなが
ら格納及び保持するとともに該保持した暗号文データを
前記第2のブロック復号回路に供給する第2のシフトレ
ジスタとを有し、 前記第1の復号回路で平文データを生成する過程におい
て前記第1のシフトレジスタに保持される暗号文データ
を前記第2の復号回路に転送し、これを該第2のシフト
レジスタの初期値として設定したことを特徴とするブロ
ック暗号化、復号回路。
2. A decryption circuit for decrypting a ciphertext data sequence obtained by the encryption circuit according to claim 1 for each predetermined bit, wherein said decryption circuit has a first decryption circuit, a second decryption circuit, and an input. Switching means and output switching means, wherein the input switching means selects a predetermined bit at the head of the ciphertext data string, decrypts the selected bit at the first decryption circuit, and sets a predetermined bit at the head of the ciphertext data string. Is selected by the input switching means and decoded by the second decoding circuit, and the plaintext data obtained by the first decoding circuit and the plaintext data obtained by the second decoding circuit are The first decryption circuit is selected and output by an output switching unit, and the first decryption circuit generates common key data.
A first key data register, a first block decryption circuit for decrypting a block cipher having a predetermined bit length based on the common key data, and upper predetermined bits of decrypted data decrypted from the first block decryption circuit And a first exclusive logical circuit for generating and outputting plaintext data by performing an exclusive OR operation on the predetermined bits extracted from the ciphertext data sequence and a predetermined exclusive bit. And a first shift register that stores and holds the ciphertext data and supplies the held ciphertext data to the first block decryption circuit, wherein the second decryption circuit generates common key data.
And a second key data register for decrypting a block cipher having a predetermined bit length based on the second common key data.
And a second exclusive OR operation for performing an exclusive OR operation on upper predetermined bits of the decrypted data decrypted from the block decryption circuit and predetermined bits extracted from the ciphertext data string to generate and output plaintext data A logic circuit, and a second shift register that stores and holds the ciphertext data sequence while shifting the ciphertext data sequence upward by a predetermined bit sequentially and supplies the held ciphertext data to the second block decryption circuit. Transferring the ciphertext data held in the first shift register to the second decryption circuit in the process of generating the plaintext data by the first decryption circuit, and transferring the encrypted data to the initial value of the second shift register; A block encryption / decryption circuit characterized by being set as:
【請求項3】前記請求項1記載のブロック暗号化回路に
おいて、前記第1のブロック暗号化回路で前記第2のブ
ロック暗号回路を併用したことを特徴とする請求項1記
載のブロック暗号化、復号回路。
3. The block encryption circuit according to claim 1, wherein said second block encryption circuit is used in combination with said first block encryption circuit. Decoding circuit.
【請求項4】前記請求項2記載のブロック復号回路にお
いて、前記第1のブロック復号回路で前記第2のブロッ
ク復号回路を併用したことを特徴とする請求項2記載の
ブロック暗号化、復号回路。
4. The block encryption / decryption circuit according to claim 2, wherein said second block decryption circuit is used in combination with said first block decryption circuit. .
JP2001030496A 2001-02-07 2001-02-07 Block encryption and decryption circuit Pending JP2002229444A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2001030496A JP2002229444A (en) 2001-02-07 2001-02-07 Block encryption and decryption circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2001030496A JP2002229444A (en) 2001-02-07 2001-02-07 Block encryption and decryption circuit

Publications (1)

Publication Number Publication Date
JP2002229444A true JP2002229444A (en) 2002-08-14

Family

ID=18894707

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2001030496A Pending JP2002229444A (en) 2001-02-07 2001-02-07 Block encryption and decryption circuit

Country Status (1)

Country Link
JP (1) JP2002229444A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005278009A (en) * 2004-03-26 2005-10-06 Mitsubishi Electric Corp Encryption authentication packet communication device, encryption authentication packet communication method, and program which makes computer execute encryption authentication packet communication method
JP2007311928A (en) * 2006-05-16 2007-11-29 Sony Corp Transmission method, transmission system, transmission method, transmitter, receiving method, and receiver
US8253859B2 (en) 2006-05-16 2012-08-28 Sony Corporation Transmission system, transmission apparatus, and transmission method for transmitting video data
US11838402B2 (en) 2019-03-13 2023-12-05 The Research Foundation For The State University Of New York Ultra low power core for lightweight encryption

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005278009A (en) * 2004-03-26 2005-10-06 Mitsubishi Electric Corp Encryption authentication packet communication device, encryption authentication packet communication method, and program which makes computer execute encryption authentication packet communication method
JP2007311928A (en) * 2006-05-16 2007-11-29 Sony Corp Transmission method, transmission system, transmission method, transmitter, receiving method, and receiver
US8253859B2 (en) 2006-05-16 2012-08-28 Sony Corporation Transmission system, transmission apparatus, and transmission method for transmitting video data
US8817182B2 (en) 2006-05-16 2014-08-26 Sony Corporation Transmission system, transmission apparatus, and transmission method for transmitting video data
US8854543B2 (en) 2006-05-16 2014-10-07 Sony Corporation Transmission system, transmission apparatus, and transmission method for transmitting video data
US8982278B2 (en) 2006-05-16 2015-03-17 Sony Corporation Transmission system, transmission apparatus, and transmission method for transmitting video data
US8982279B2 (en) 2006-05-16 2015-03-17 Sony Corporation Transmission system, transmission apparatus, and transmission method for transmitting video data
US9065963B2 (en) 2006-05-16 2015-06-23 Sony Corporation Transmission system, transmission apparatus, and transmission method for transmitting video data
US9544535B2 (en) 2006-05-16 2017-01-10 Sony Corporation Transmission system, transmission apparatus, and transmission method for transmitting video data
US11838402B2 (en) 2019-03-13 2023-12-05 The Research Foundation For The State University Of New York Ultra low power core for lightweight encryption

Similar Documents

Publication Publication Date Title
EP0802653B1 (en) Multi-cycle non-parallel data encryption engine
US5671284A (en) Data encryptor having a scalable clock
JP2010140026A (en) Method and device for encryption chained mode
JP2005505069A (en) Memory encryption
US8594321B2 (en) Apparatus and method for operating a symmetric cipher engine in cipher-block chaining mode
US7925009B2 (en) Hybrid data encryption
JP2001086110A (en) Packet communication system for encrypted information
GB2398213A (en) Encryption using the KASUMI algorithm
JPH0380645A (en) Enciphering method and deciphering method
JP3769804B2 (en) Decoding method and electronic device
US7257229B1 (en) Apparatus and method for key scheduling
JP2008035305A (en) Encryption method and data concealing method
US20040223609A1 (en) Data encryption method
GB2426673A (en) Forming a ciphertext sequence using a plurality of initialisation values
JP2002229444A (en) Block encryption and decryption circuit
KR20060110383A (en) Multi-mode ciphering apparatus for network security processor
JP2001177518A (en) Enciphering method, and decoding method and device
JP2000224158A (en) Ciphering communication system
JP4287397B2 (en) Ciphertext generation apparatus, ciphertext decryption apparatus, ciphertext generation program, and ciphertext decryption program
WO2022096141A1 (en) Method for processing encrypted data
JP4117095B2 (en) Encryption method
JP2007500376A (en) Method and apparatus for low memory hardware implementation of key expansion function
JP2002290391A (en) Session key generating system in common key encryption system and encryption device/decoder
JP4708914B2 (en) Decryption method
JPH10303883A (en) Enciphering method