[go: up one dir, main page]

JPH09311627A - Method and device for generating cipher key of cipher based on circulating computation - Google Patents

Method and device for generating cipher key of cipher based on circulating computation

Info

Publication number
JPH09311627A
JPH09311627A JP8150077A JP15007796A JPH09311627A JP H09311627 A JPH09311627 A JP H09311627A JP 8150077 A JP8150077 A JP 8150077A JP 15007796 A JP15007796 A JP 15007796A JP H09311627 A JPH09311627 A JP H09311627A
Authority
JP
Japan
Prior art keywords
random number
encryption
simultaneous
bits
random
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.)
Granted
Application number
JP8150077A
Other languages
Japanese (ja)
Other versions
JP3013777B2 (en
Inventor
Michio Shimada
道雄 島田
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.)
NEC Corp
Original Assignee
NEC Corp
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 NEC Corp filed Critical NEC Corp
Priority to JP8150077A priority Critical patent/JP3013777B2/en
Publication of JPH09311627A publication Critical patent/JPH09311627A/en
Application granted granted Critical
Publication of JP3013777B2 publication Critical patent/JP3013777B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Abstract

PROBLEM TO BE SOLVED: To simplify generation of a cipher key to be used for enciphering and deciphering cipher based on circulating computations, by using a binary series generated at random. SOLUTION: A random number having a length of e(1)+...+e(k) bits generated at random by a random number generating means 102 is inputted into a binary digit string dividing means 131, and the input random number is divided into k random numbers of e(1),..., e(k) bits respectively. An addition means 132 adds 1 to the k random numbers respectively, and further a simultaneous congruence expression solution finding means 133 solves simultaneous congruence expressions relating to x, x=aj (mod pj ), j=1,..., k, where k random numbers are designated as a1 ,..., ak . A found solution is supplied to a cipher device 105 as a cipher key A for the cipher device based on a circulating computation. The cipher device 105 thereby secures remarkable simplification of ciphering and deciphering caused by the cipher key A.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【発明の属する技術分野】本発明は循環演算にもとづく
暗号の暗号鍵生成方法及び装置に関し、特に通信システ
ムや計算機システムにおいて採用され、許可されていな
い者が不正に情報を取得することなどを防止するために
情報を暗号文に変換する暗号化と、暗号文から元の情報
を復元する復号化において用いる、循環演算にもとづく
暗号の暗号鍵生成方法及び装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a method and apparatus for generating an encryption key for encryption based on circular operation, and is particularly adopted in a communication system or computer system to prevent unauthorized persons from illegally acquiring information. In order to do so, the present invention relates to a method and apparatus for generating a cryptographic key based on cyclic operation, which is used in encryption for converting information into ciphertext and decryption for restoring original information from ciphertext.

【0002】[0002]

【従来の技術】従来のこの種の暗号化方法及び装置で
は、しばしば線形変換(アフィン変換とも呼ばれる)Y
=AX+B(mod P)を組み合わせて暗号化が行わ
れていた。ここでいう線形変換とは、変換対象の整数X
に整数Aを乗算し、その乗算結果AXに整数Bを加算
し、その加算結果AX+BをPで割った時の余り(剰余
と呼ぶ)を暗号文Yとするものである。これを前述した
Y=AX+B(mod P)で表現している。
2. Description of the Related Art In a conventional encryption method and apparatus of this type, a linear transformation (also called an affine transformation) Y is often used.
= AX + B (mod P) was combined to perform encryption. The linear conversion here is the integer X to be converted.
Is multiplied by an integer A, an integer B is added to the multiplication result AX, and the remainder (called a remainder) when the addition result AX + B is divided by P is a ciphertext Y. This is represented by Y = AX + B (mod P) described above.

【0003】このような線形変換暗号においては、A,
B及びPは予め決められた整数で、一般にAとBが暗号
鍵とされ、Pがアルファベットの数とされる。特にA=
1とし、Bを暗号鍵とし、Pをアルファベットの数とし
たものはシーザー暗号と呼ばれる。また、特にAを暗号
鍵とし、B=0とし、Pをアルファベットの数としたも
のは積暗号と呼ばれる。
In such a linear conversion cipher, A,
B and P are predetermined integers, generally A and B are encryption keys, and P is an alphabet number. Especially A =
It is called a Caesar cipher that sets 1, the encryption key is B, and the alphabet is P. In addition, a cryptographic key of which A is B, B = 0, and P is the number of alphabets is called a product cipher.

【0004】なお、通常の計算機においては、8ビット
整数が1文字として扱われることが多いため、A,X及
びBはそれぞれ8ビット整数で、従ってP=256 とな
る。このため、演算結果AX+Bの下位8ビットがAX
+B(mod P)と等しくなる。即ち、割り算をしな
くとも、上位のビットを無視するだけで剰余が計算でき
る。
In an ordinary computer, since an 8-bit integer is often treated as one character, each of A, X and B is an 8-bit integer, so P = 256. Therefore, the lower 8 bits of the operation result AX + B are AX
It becomes equal to + B (mod P). That is, the remainder can be calculated by ignoring the upper bits without dividing.

【0005】また、多重剰余暗号と呼ばれる暗号化方法
においてはA,Bを予め決められた整数とし、Pを暗号
鍵とした線形変換を組み合わせることで非線形の暗号化
が行われる。なお、シーザー暗号、積暗号及び線形変換
暗号については、例えば松井甲子雄著「コンピュータに
よる暗号解読入門」(森北出版、1990年)の第39ページ
から第55ページにわたって詳しい解説がある。また、多
重剰余暗号については、例えば特開平6−75525号
公報などに詳述されている。
In addition, in an encryption method called multiple remainder encryption, nonlinear encryption is performed by combining linear transformations in which A and B are predetermined integers and P is an encryption key. In addition, about Caesar cipher, product cipher, and linear conversion cipher, for example, from Kojio Matsui "Introduction to Cryptanalysis by Computer" (Morikita Publishing Co., Ltd., 1990), there are detailed explanations on pages 39 to 55. Further, the multiple residue cipher is described in detail, for example, in Japanese Patent Laid-Open No. 6-75525.

【0006】なお、以下の記述では、Xを平文と呼びY
を暗号文とも呼ぶ。さらに、以下の記述では、x=Y
mod Zは、YをZで割って得られる剰余をXに代入
することを意味し、X=Y/Zは、YをZで割って得ら
れる商をXに代入することを意味し、X=Y(mod
Z)は、XをZで割って得られる剰余と、YをZで割っ
て得られる剰余が等しいことを意味するものとする。
又、X=Y(mod Z)は合同式と呼ばれる。
In the following description, X is called plaintext and Y
Is also called ciphertext. Furthermore, in the following description, x = Y
mod Z means substituting the remainder obtained by dividing Y by Z into X, and X = Y / Z means substituting the quotient obtained by dividing Y by Z into X, = Y (mod
Z) shall mean that the remainder obtained by dividing X by Z and the remainder obtained by dividing Y by Z are equal.
Further, X = Y (mod Z) is called a congruential expression.

【0007】しかしながら、このような線形変換によっ
て得られる暗号は、簡単に解読できるという問題があっ
た。その理由は、暗号鍵を知らない第三者であっても、
入出力の組が幾つか入手できれば、それらにもとづいて
線形方程式をたて、たてた線形方程式を解くことによっ
て暗号鍵が推定できるからである。
However, the cipher obtained by such linear conversion has a problem that it can be easily deciphered. The reason is that even a third party who does not know the encryption key
This is because, if some input / output pairs are available, a cryptographic key can be estimated by constructing a linear equation based on them and solving the linear equation.

【0008】また、多重剰余暗号には、計算量が大きい
という問題がある。その理由は、線形変換暗号において
は、通常は法Pとして2のべき乗になるような値が選ば
れるので割り算が不要だったが、多重剰余暗号において
は法Pとして素数が選ばれるので、割り算が必要となる
ことによる。
Further, the multi-residue cipher has a problem that the amount of calculation is large. The reason is that in the linear conversion cipher, a value that is a power of 2 is usually selected as the modulus P, so that division is not necessary, but in the multiple residue cipher, a prime number is selected as the modulus P, so division is performed. It depends on what you need.

【0009】そこで、従来は割り算が不要な非線形変換
として、循環演算にもとづく暗号方法及び復号化方法が
用いられている。この暗号化方法は、nビットの平文X
に対してY=AXとし、Yがnビットの整数になるま
で、Y=(Yの下位nビット)+(Yの上位nビット)
という操作を繰り返し、Yがnビットの整数になった
らYを暗号文として出力する暗号化方法である。
Therefore, conventionally, an encryption method and a decryption method based on a cyclic operation have been used as a non-linear conversion that does not require division. This encryption method uses n-bit plaintext X
And Y = AX, and Y = (lower n bits of Y) + (n higher bits of Y) until Y becomes an n-bit integer.
This is an encryption method in which Y is output as a ciphertext when Y becomes an n-bit integer.

【0010】この場合、Y=(Yの下位nビット)+
(Yの上位nビット) という操作は、1回の暗号化に
ついて、たかだか2回しか繰り返されないので高速処理
が可能となる。なお、循環演算にもとづく暗号方法によ
って生成された暗号文から元の情報を復号化するために
は、Aとして2n −1とは互いに素な整数を用いなけれ
ばならないことが知られている。
In this case, Y = (lower n bits of Y) +
Since the operation (upper n bits of Y) is repeated at most twice for one encryption, high speed processing is possible. It is known that in order to decrypt the original information from the ciphertext generated by the cryptographic method based on the circular operation, an integer that is relatively prime to 2 n -1 must be used as A.

【0011】[0011]

【発明が解決しようとする課題】上述した従来の循環演
算にもとづく暗号化方法及び復号化方法の問題点は、ラ
ンダムに生成された2値系列を暗号鍵として使うことが
できず、Aの値として、2n −1と素な整数を総当り的
に生成して使う必要があり、暗号鍵を生成するのに膨大
な計算量を必要とし、しかも2値系列を発生する安価な
乱数発生器は利用できないという問題点があった。
The problem with the above-described conventional encryption and decryption methods based on cyclic operations is that the randomly generated binary sequence cannot be used as an encryption key, and the value of A is , It is necessary to exhaustively generate and use an integer prime to 2 n -1, which requires a huge amount of calculation to generate an encryption key, and is an inexpensive random number generator that generates a binary sequence. There was a problem that was not available.

【0012】本発明の目的は上述した問題点を解決し、
ランダムに生成された2値系列から2n −1とは互いに
素なAの値を生成する循環演算にもとづく暗号の暗号鍵
生成方法及び装置を提供することにある。
An object of the present invention is to solve the above-mentioned problems,
An object of the present invention is to provide an encryption key generation method and device for encryption based on a cyclic operation for generating a value of A that is relatively prime to 2 n −1 from a randomly generated binary sequence.

【0013】[0013]

【課題を解決するための手段】本発明は、上記の目的を
達成するために次の手段構成を有する。本発明の循環演
算にもとづく暗号の暗号鍵生成方法は、予め決められた
整数nに対して2n −1=p12 ……pk に素因数分
解でき、且つpj の長さをe(j)ビットとした場合
に、長さe(1)+……+e(k)ビットの乱数をそれ
ぞれe(1),……,e(k)ビットのk個の乱数に分
割したうえ前記k個に分割された乱数のそれぞれに1を
加算し、前記k個に分割された乱数をa1 ,……,ak
としてxに関する連立合同式x=aj(mod pj),j
=1,……,kを解いて求めた鍵を暗号鍵として少なく
とも1個生成する特徴を有する。
The present invention has the following means in order to achieve the above object. According to the method for generating a cryptographic key based on the cyclic operation of the present invention, a predetermined integer n can be factored into 2 n −1 = p 1 p 2 ... P k , and the length of p j is e. (J) bits, a random number of length e (1) + ... + e (k) bits is divided into k random numbers of e (1) ,. 1 is added to each of the k divided random numbers, and the k divided random numbers are a 1 , ..., A k
As a simultaneous congruence equation x = a j (mod p j ), j
= 1, ..., K is characterized in that at least one key obtained by solving k is generated as an encryption key.

【0014】また、循環演算にもとづく暗号の暗号鍵生
成装置に関する本発明の第1の構成は、外部から暗号化
処理を指定する制御信号を入力して送出する入力手段
と、2値系列をランダムに生成し長さe(1)+……+
e(k)ビットの乱数を送出する乱数発生手段と、所定
の容量の記憶媒体から成る記憶手段と、予め決められた
整数nに対して2n −1=p12 ……pk に素因数分
解でき、且つpj の長さをe(j)ビットとした場合
に、前記乱数発生手段の送出する前記乱数をそれぞれ長
さe(1),……,e(k)ビットのk個の乱数に分解
しk個に分割された乱数を前記記憶手段に記憶させるビ
ット列分割手段と、前記記憶手段に記憶したk個の乱数
のそれぞれに1を加算する加算手段と、前記記憶手段に
記憶したk個の乱数をa1 ,……,ak としてxに関す
る連立合同式x=aj(mod pj),j=1,……,k
を解く連立合同式求解手段とを備え、前記制御信号入力
手段に制御信号が入力されると、前記乱数発生手段から
提供されるe(1)+……+e(k)ビットの乱数に対
して、前記ビット列分割手段と加算手段と連立合同式求
解手段とによる処理を逐次的に実行して、前記連立合同
式求解手段によって得られた解を暗号鍵として少なくと
も1個を暗号装置に供給するものとした構成を有する。
Further, the first configuration of the present invention relating to the encryption key generation apparatus for encryption based on the cyclic operation has the input means for inputting and transmitting the control signal for designating the encryption processing from the outside, and the random binary sequence. To generate length e (1) + …… +
a random number generating means for sending the e (k) of bit random number, a storage means comprising a storage medium of a given capacity, the 2 n -1 = p 1 p 2 ...... p k for integer n to a predetermined When the prime factorization is possible and the length of p j is e (j) bits, the random numbers transmitted by the random number generating means are k pieces each having a length e (1), ..., E (k) bits. Bit string dividing means for storing the random number divided into k random numbers in the storage means, addition means for adding 1 to each of the k random numbers stored in the storage means, and the storage means The k random numbers are a 1 , ..., A k , and the simultaneous congruence equation x = a j (mod p j ), j = 1 ,.
When a control signal is input to the control signal inputting means, a simultaneous congruential solution solving means for solving e (1) + ... + e (k) -bit random numbers is provided. Processing for sequentially performing the processing by the bit string dividing means, the adding means, and the simultaneous congruence equation solving means, and supplying at least one of the solutions obtained by the simultaneous congruence equation solving means as an encryption key to an encryption device. It has the configuration.

【0015】また、循環演算にもとづく暗号の暗号鍵生
成装置に関する本発明の第2の構成は、前記第1の構成
において、前記ビット列分割手段と、前記加算手段と、
前記連立合同求解手段とを一体化してデータ処理手段と
なし、このデータ処理手段が前記制御入力手段の制御信
号入力にもとづいて逐次に処理を実行するものとした構
成を有する。
A second structure of the present invention relating to a cryptographic key generation device based on a cyclic operation is the same as the first structure except that the bit string dividing means, the adding means, and
The simultaneous joint solution solving means is integrated to form a data processing means, and the data processing means sequentially executes the processing based on the control signal input from the control input means.

【0016】[0016]

【発明の実施の形態】循環演算にもとづく暗号化方法で
は、nビットの平文Xに対して、Y=AX(Aは暗号
鍵)とし、Yがnビットの整数となるまでY=(Yの下
位nビット)+(Yの上位nビット) の操作を繰り返
し実行し、Yがnビットの整数になった段階でYを暗号
文として出力している。
BEST MODE FOR CARRYING OUT THE INVENTION In an encryption method based on a circular operation, Y = AX (A is an encryption key) for an n-bit plaintext X, and Y = (Y The operation of (lower n bits) + (upper n bits of Y) is repeatedly executed, and when Y becomes an integer of n bits, Y is output as a ciphertext.

【0017】しかしながら、上述した暗号化方法では暗
号鍵Aのとるべき値として2n −1と互いに素なる整数
を総当り的に生成し利用する条件があり、この条件が壁
となって暗号鍵Aをランダムに簡易に生成することが困
難であった。
However, in the above-described encryption method, there is a condition that an integer that is relatively prime to 2 n -1 is exhaustively generated and used as a value that the encryption key A should take. It was difficult to randomly generate A easily.

【0018】本発明では、2n −1が2n −1=p1
2 ……pm と素因数分解できたとすると、公知の中国人
の剰余の定理によれば、xに関する連立合同式x=a
j(mod pj),j=1,……,m の解と(a1 ,a
2 ,……,am)とは1対1に対応し、又、xがpの倍数
であればx=0(mod p)であり、従って、0<a
j <pj ,j=1,……,mである整数の組(a1 ,a
2 ,……,am)をランダムに決めて前述した連立合同式
を求解すれば、その解として2n −1と素な整数が得ら
れることを暗号鍵生成方法の基本的特徴としている。
In the present invention, 2 n -1 is 2 n -1 = p 1 p
2 ...... If p m can be factored, the known Chinese remainder theorem states that the simultaneous congruence equation x = a for x
The solution of j (mod p j ), j = 1, ..., M and (a 1 , a
, 2 , ..., A m ) corresponds to one to one, and if x is a multiple of p, then x = 0 (mod p), so 0 <a
A set of integers (a 1 , a where j <p j , j = 1, ..., M)
(2 , ..., Am ) is randomly determined to solve the above-mentioned simultaneous congruence equation, and the fundamental feature of the encryption key generation method is that an integer that is a prime number of 2 n −1 is obtained as the solution.

【0019】このような暗号鍵生成方法を具体化するた
めの構成として、図1に示すように制御信号を入出力す
る制御信号入力手段101 と、長さe(1)+……+e
(k)ビットの乱数を出力する乱数発生手段102 と、乱
数発生手段102 の出力する乱数に対して、前述した暗号
鍵生成処理を逐次施すビット列分割手段131 、加算手段
132 及び連立合同式求解手段133 を一体化構成として含
むデータ処理手段103 と、処理実行のエリアを提供する
記憶手段104 とを備え、制御信号入力手段101 が外部か
ら制御信号を受けるとデータ処理手段によって暗号鍵が
生成され、暗号化と復号化とを行う暗号装置105 に提供
されることを発明の実施の形態としている。
As a configuration for embodying such an encryption key generating method, as shown in FIG. 1, a control signal input means 101 for inputting / outputting a control signal and a length e (1) + ... + e.
(K) Random number generating means 102 for outputting a random number, bit string dividing means 131 for sequentially performing the above-mentioned encryption key generating process on the random number output by the random number generating means 102, and adding means
Data processing means 103 including 132 and simultaneous congruent equation solving means 133 as an integrated configuration, and storage means 104 for providing a processing execution area, and data processing means when control signal input means 101 receives a control signal from the outside An embodiment of the invention is that an encryption key is generated by and is provided to an encryption device 105 that performs encryption and decryption.

【0020】[0020]

【実施例】次に、本発明について図面を参照して説明す
る。図1は、本発明の一実施例の構成を示すブロック図
である。図1に示す実施例は、図示しない上位装置から
受ける暗号鍵設定指令としての制御信号を入出力する制
御信号入力手段101 と、所望の暗号鍵生成に必要な母体
データとしての乱数を送出する乱数発生手段102 と、乱
数発生手段102 の送出する乱数に対して暗号鍵生成のた
めのデータ処理を施すデータ処理手段103 と、データ処
理手段103 によるデータ処理に必要な実行エリアを提供
する記憶手段104 とを備える。
Next, the present invention will be described with reference to the drawings. FIG. 1 is a block diagram showing the configuration of an embodiment of the present invention. In the embodiment shown in FIG. 1, a control signal input means 101 for inputting and outputting a control signal as an encryption key setting command received from a higher-level device (not shown), and a random number for transmitting a random number as mother data necessary for generating a desired encryption key. Generating means 102, data processing means 103 for performing data processing for generating a cryptographic key on the random numbers sent by the random number generating means 102, and storage means 104 for providing an execution area necessary for data processing by the data processing means 103. With.

【0021】また、データ処理手段103 は、乱数発生手
段102 の送出する乱数に対するビット列分割処理を施す
ビット列分割手段131 と、ビット列分割処理を施された
分割乱数に所定の整数を加算する加算手段132 と、加算
手段132 の出力に対して連立合同式を利用する求解処理
を施して、その解を暗号鍵として出力する連立合同式求
解手段133 とを備える。なお、図1には暗号鍵の提供を
受けて循環演算にもとづく暗号化及び復号化を行う暗号
装置105 を併記して示す。
The data processing means 103 includes a bit string dividing means 131 for performing a bit string dividing process on the random number sent from the random number generating means 102, and an adding means 132 for adding a predetermined integer to the divided random number subjected to the bit string dividing process. And a simultaneous congruence equation solving means 133 which performs solution finding processing using the simultaneous agreement equation on the output of the adding means 132 and outputs the solution as an encryption key. It is to be noted that FIG. 1 also shows a cryptographic device 105 for performing encryption and decryption based on a circular operation upon receiving the provision of the cryptographic key.

【0022】次に、図1の実施例の説明に先立ち、本発
明の循環演算にもとづく暗号鍵生成方法の内容について
説明する。予め定められた整数nに対して、2n −1=
12 ……pk という具合に2n −1が素因数分解で
きたとする。ところで、中国人の剰余定理により、xに
関する次の数式1で示す連立合同式の解と(a1 ,a
2 ,……,ak)は1対1に対応する。
Prior to the description of the embodiment shown in FIG. 1, the contents of the encryption key generation method based on the circular operation of the present invention will be described. For a predetermined integer n, 2 n −1 =
p 1 p 2 ...... p k 2 n -1 and so that is assumed to be disassembled prime factors. By the way, according to the Chinese Remainder Theorem, the solution of the simultaneous congruence equation and the equation (a 1 , a
2 , ..., A k ) correspond one-to-one.

【0023】[0023]

【数1】 [Equation 1]

【0024】また連立合同式の解xが2n −1と素でな
ければ、あるj=1,2,……,kに対してxがpj
倍数となり、x=0(mod pj)となる。それ故に、
すべてのj=1,2,……,kに対して、0<aj <p
j であれば、上の連立合同式の解は2n −1と素であ
る。
If the solution x of the simultaneous congruential equation is not prime to 2 n -1, then x becomes a multiple of p j for some j = 1, 2, ..., K, and x = 0 (mod p j ). Therefore,
0 <a j <p for all j = 1, 2, ..., K
If j , then the solution of the system of congruences above is prime to 2 n -1.

【0025】以上のことは即ち、2n −1と互いに素な
Aの値は、区間0<A<2n −1の上にわたって不連続
に存在しているのにもかかわらず、それらを上の連立合
同式のパラメータに変換すると、変換結果(a1 ,a
2 ,……,ak)が、連続領域0<a1 <p1 ,0<a2
<p2 ,……,0<am <pk に存在するという興味深
い事実を示している。なお、以上の説明において、連続
とは整数としての連続性を意味するものとする。
The above description is to say, the value of disjoint A and 2 n -1, in spite of the interval 0 <exist discontinuously over the the A <2 n -1, on their When converted to the parameters of the simultaneous congruence equation of, the conversion result (a 1 , a
2 , ..., a k ) is a continuous region 0 <a 1 <p 1 , 0 <a 2
<P 2, ......, 0 <shows an interesting fact that there in a m <p k. In the above description, continuity means continuity as an integer.

【0026】このような背景から、本発明の循環演算に
もとづく暗号鍵生成方法では、まず、2e(j)<pj であ
るようなe(j)に対して長さe(j)ビットの2値系
列をランダムに生成し、それに1を加算したものをaj
の値とする。なお、e(j)=0の場合には、aj =1
とする。そのようにすれば、0<aj <pj という条件
を満足するaj が得られる。そして、そのようにして生
成された(a1 ,a2,……,ak)に対して上の連立合同
式の解を求め、その解をAの値とする。以上のようにす
れば、ランダムに生成された長さe(1)+e(2)+
……+e(k)ビットの2値系列から、2n −1と互い
に素なAの値を生成できることを基本的な特徴としてい
る。
From such a background, in the encryption key generating method based on the circular operation of the present invention, first, for e (j) such that 2 e (j) <p j , the length is e (j) bits. Is generated at random, and one obtained by adding 1 is added to a j
Value. When e (j) = 0, a j = 1
And By doing so, 0 <a j <p j a j which satisfies the condition that is obtained. Then, the solution of the above simultaneous congruential equation is obtained for (a 1 , a 2 , ..., Ak ) thus generated, and the solution is set as the value of A. By doing so, the randomly generated length e (1) + e (2) +
The basic feature is that it is possible to generate a value of A that is relatively prime to 2 n −1 from a binary sequence of + e (k) bits.

【0027】再び、図1に戻って実施例の説明を続行す
る。図1において、制御信号入力手段101 は、暗号鍵を
設定することを指示する制御信号が外部から入力される
と、データ処理手段103 に制御信号を供給する。乱数発
生手段102 は、長さe(1)+……+e(k)ビットの
乱数を生成してデータ処理手段103 に生成した乱数1021
を供給する。データ処理手段103 は、制御信号入力手段
101 から制御信号1011を受け取ると、乱数発生手段102
から長さe(1)+……+e(k)ビットの乱数1021を
入力する。
Returning to FIG. 1 again, the description of the embodiment will be continued. In FIG. 1, the control signal input means 101 supplies a control signal to the data processing means 103 when a control signal instructing to set an encryption key is input from the outside. The random number generating means 102 generates a random number of length e (1) + ... + e (k) bits and generates the random number 1021 in the data processing means 103.
Supply. The data processing means 103 is a control signal input means.
Upon receiving the control signal 1011 from 101, the random number generating means 102
, A random number 1021 of length e (1) + ... + e (k) bits is input.

【0028】データ処理手段103 においては、次のよう
な処理が行われる。即ち、ビット列分割手段131 は、乱
数発生手段102 から得た長さe(1)+……+(k)ビ
ットの乱数1021を、それぞれe(1),……,e(k)
ビットのk個の乱数に分割し、k個に分割された乱数を
記憶手段104 に記憶する。加算手段132 は、記憶手段10
4 に記憶されているk個の乱数のそれぞれに1を加算す
る。
The data processing means 103 performs the following processing. That is, the bit string dividing means 131 uses the random numbers 1021 of length e (1) + ... + (k) bits obtained from the random number generating means 102 as e (1), ..., E (k), respectively.
The random number is divided into k random numbers of bits, and the k random numbers are stored in the storage means 104. The adding means 132 is the storage means 10
Add 1 to each of the k random numbers stored in 4.

【0029】連立合同式求解手段133 は、記憶手段104
に記憶されているk個の乱数をa1 ,……,ak とし、
xに関する連立合同式x=aj(mod pj),j=1,
……,kと解き、求められた鍵を、暗号鍵A1031として
暗号装置105 に供給する。
The simultaneous congruential equation solving means 133 includes a storage means 104.
Let k 1 , the random numbers stored in, be a 1 ,.
Simultaneous congruential expression x = a j (mod p j ), j = 1, for x
.., k, and the obtained key is supplied to the encryption device 105 as the encryption key A1031.

【0030】暗号装置105 は、暗号鍵A1031にもとづい
て、入力端子151 から入力された情報1511に対して循環
演算にもとづく暗号化を施して、得られた暗号文1521を
出力端子152 から出力し、一方、暗号鍵Aにもとづい
て、入力端子154 から入力された暗号文1541に対して循
環演算にもとづく復号化を施して、復元された情報を出
力端子153 から復号情報1531として出力する。なお、以
上において、n,k及びe(j),pj ,j=1,…
…,kは、前述した説明で述べた整数である。
The cryptographic device 105 performs encryption based on the circular operation on the information 1511 input from the input terminal 151 based on the cryptographic key A1031 and outputs the obtained ciphertext 1521 from the output terminal 152. On the other hand, based on the encryption key A, the ciphertext 1541 input from the input terminal 154 is decrypted based on the cyclic operation, and the restored information is output from the output terminal 153 as the decryption information 1531. In the above, n, k and e (j), p j , j = 1, ...
..., k are the integers described in the above description.

【0031】図2は、図1のデータ処理手段103 による
第1の暗号鍵生成動作を説明するフローチャートであ
る。以下、図2のフローチャートを併せ参照しつつ、図
1の実施例の動作をさらに説明する。データ処理手段10
3 は乱数発生手段102 から、長さe(1)+……+e
(k)ビットの乱数を得る(ステップ201 )。ビット列
分割手段131 は、乱数発生手段102 の出力する長さe
(1)+……+e(m)ビットの乱数をそれぞれe
(1),……,e(k)ビットのk個の乱数に分割し、
k個に分割された乱数は記憶手段104 に記憶する(ステ
ップ202 )。
FIG. 2 is a flow chart for explaining the first encryption key generating operation by the data processing means 103 of FIG. The operation of the embodiment of FIG. 1 will be further described below with reference to the flowchart of FIG. Data processing means 10
3 is the length e (1) + ... + e from the random number generation means 102.
A (k) -bit random number is obtained (step 201). The bit string dividing means 131 has a length e output from the random number generating means 102.
(1) + ... + e (m) -bit random numbers e
(1), ..., E (k) bits are divided into k random numbers,
The random number divided into k pieces is stored in the storage means 104 (step 202).

【0032】加算手段132 は、記憶手段104 に記憶され
ているk個の乱数のそれぞれに1を加算する(ステップ
203 )。連立合同式求解手段133 は、記憶手段104 に記
憶されているk個の乱数をa1 ,……,ak とし、xに
関する連立合同式x=aj(mod pj),j=1,…
…,kを解く(ステップ204 )。このようにして、求め
られた解が、暗号鍵Aとして暗号装置105 に供給される
(ステップ205)。
The adding means 132 adds 1 to each of the k random numbers stored in the storage means 104 (step
203). The simultaneous congruence solving means 133 sets the k random numbers stored in the storage 104 to a 1 , ..., A k, and the simultaneous congruence equation x = a j (mod p j ), j = 1 regarding x. …
..., k is solved (step 204). In this way, the obtained solution is supplied to the encryption device 105 as the encryption key A (step 205).

【0033】なお、上述した実施例では、暗号装置105
が、循環演算にもとづく暗号化を1ブロックの情報に対
して1回しか施していないので、1個の暗号鍵しか必要
としていない場合を例としたが、例えば、循環演算にも
とづく暗号化を1ブロック情報に対して異なる暗号鍵で
m回繰り返して施すような場合には、m個の暗号鍵を必
要とする。そのような場合には、データ処理手段103 に
よる第2の暗号鍵生成動作を説明するフローチャートを
示す図3の処理フローに従って図1のデータ処理手段10
3 を動作させればよい。
In the above embodiment, the encryption device 105
However, since the encryption based on the cyclic operation is performed only once for one block of information, the case where only one encryption key is required is taken as an example. For example, the encryption based on the cyclic operation is 1 When the block information is repeatedly applied m times with different encryption keys, m encryption keys are required. In such a case, the data processing means 10 of FIG. 1 is followed according to the processing flow of FIG. 3 showing a flowchart for explaining the second encryption key generating operation by the data processing means 103.
3 should work.

【0034】すなわち、まず、変数CをC=0とし(ス
テップ301 )、次に図2のステップ201 〜205 を含む暗
号鍵生成のための処理を実行し(ステップ200 )、次に
C=C+1とし(ステップ302 )、次にもしC=mなら
ば処理を終了し、さもなくばステップ200 に制御を移す
判断を行う(ステップ303 )。こうして、ランダムに生
成される2値系列から、循環演算にもとづく暗号化及び
復号化に用いる暗号鍵の生成が著しく簡素化できる。
That is, first, the variable C is set to C = 0 (step 301), the process for generating the encryption key including the steps 201 to 205 of FIG. 2 is executed (step 200), and then C = C + 1. (Step 302), if C = m, then the processing is terminated, and if not, it is judged to shift the control to step 200 (step 303). Thus, the generation of the encryption key used for encryption and decryption based on the cyclic operation can be significantly simplified from the randomly generated binary sequence.

【0035】[0035]

【発明の効果】以上説明したように本発明は、ランダム
に生成された2値系列から、2n −1とは互いに素なる
値を有するAを連立合同式の解として求めて暗号鍵とす
る簡素な方法と装置とを実施することにより、次の第1
及び第2の効果を有する。第1の効果は、循環演算にも
とづく暗号化及び復号化を行う暗号装置の暗号鍵を高速
に生成できるということである。なぜなら、従来は、2
n −1と互いに素な整数を総当りで生成するしかなかっ
たので、暗号鍵を生成するのに膨大な計算量が必要だっ
たが、本発明によって、ほぼ連立合同式を解くのに要す
る計算量だけで暗号鍵が生成できるようになったからで
ある。
As described above, according to the present invention, A having a value that is relatively prime to 2 n -1 is obtained as a solution of the simultaneous congruential equation from a randomly generated binary sequence, and is used as an encryption key. By implementing a simple method and device,
And has a second effect. The first effect is that an encryption key for an encryption device that performs encryption and decryption based on a circular operation can be generated at high speed. Because 2
Since there was no choice but to generate an integer that is relatively prime to n −1 by brute force, a huge amount of calculation was required to generate the encryption key. However, according to the present invention, the calculation required to solve almost simultaneous simultaneous congruences This is because the encryption key can be generated only by the amount.

【0036】第2の効果は、暗号鍵生成装置を低コスト
に実現できるということである。なぜなら、従来は、循
環演算にもとづく暗号装置に必要とする暗号鍵を高速に
生成するには、2n −1と互いに素な整数を生成する乱
数発生装置が必要だったが、本発明によって、2値系列
を発生する乱数発生手段が使えるようになったからであ
る。2値系列を発生する乱数発生手段で高速なものを低
コストに実現できるようになったからである。
The second effect is that the encryption key generating device can be realized at low cost. This is because conventionally, in order to generate an encryption key required for a cryptographic device based on a circular operation at high speed, a random number generator that generates an integer that is relatively prime to 2 n -1 was required. This is because the random number generating means for generating a binary sequence can be used. This is because a high-speed random number generating means for generating a binary sequence can be realized at low cost.

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

【図1】本発明の一実施例の構成を示すブロック図であ
る。
FIG. 1 is a block diagram showing the configuration of an embodiment of the present invention.

【図2】図1の第1の暗号鍵生成動作を説明するフロー
チャートである。
FIG. 2 is a flowchart illustrating a first encryption key generation operation of FIG.

【図3】図1の第2の暗号鍵生成動作を説明するフロー
チャートである。
FIG. 3 is a flowchart illustrating a second encryption key generation operation of FIG.

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

101 制御信号入力手段 102 乱数発生手段 103 データ処理手段 104 記憶手段 105 暗号装置 131 ビット列分割手段 132 加算手段 133 連立合同式求解手段 101 Control signal input means 102 Random number generation means 103 Data processing means 104 Storage means 105 Cryptographic apparatus 131 Bit string division means 132 Addition means 133 Simultaneous congruence solving means

Claims (3)

【特許請求の範囲】[Claims] 【請求項1】 予め決められた整数nに対して2n −1
=p12 ……pkに素因数分解でき、且つpj の長さ
をe(j)ビットとした場合に、長さe(1)+……+
e(k)ビットの乱数をそれぞれe(1),……,e
(k)ビットのk個の乱数に分割したうえ前記k個に分
割された乱数のそれぞれに1を加算し、前記k個に分割
された乱数をa1 ,……,ak としてxに関する連立合
同式x=aj(mod pj),j=1,……,kを解いて
求めた鍵を暗号鍵として少なくとも1個生成することを
特徴とする循環演算にもとづく暗号の暗号鍵生成方法。
1. 2 n -1 for a predetermined integer n
= P 1 p 2 ...... can be factored into p k , and if the length of p j is e (j) bits, the length e (1) + ... +
The e (k) -bit random numbers are e (1), ..., e, respectively.
(K) to each random number is divided into the k number after divided into k random bits plus 1, a 1 divided random number to said k pieces, ..., simultaneous with respect to x as a k A method for generating an encryption key for encryption based on a cyclic operation, characterized in that at least one key obtained by solving the congruence formula x = a j (mod p j ), j = 1, ..., K is generated as an encryption key. .
【請求項2】 外部から暗号化処理を指定する制御信号
を入力して送出する入力手段と、2値系列をランダムに
生成し長さe(1)+……+e(k)ビットの乱数を送
出する乱数発生手段と、所定の容量の記憶媒体から成る
記憶手段と、予め決められた整数nに対して2n −1=
12 ……pk に素因数分解でき、且つpj の長さを
e(j)ビットとした場合に、前記乱数発生手段の送出
する前記乱数をそれぞれ長さe(1),……,e(k)
ビットのk個の乱数に分解しk個に分割された乱数を前
記記憶手段に記憶させるビット列分割手段と、前記記憶
手段に記憶したk個の乱数のそれぞれに1を加算する加
算手段と、前記記憶手段に記憶したk個の乱数をa1
……,ak としてxに関する連立合同式x=aj(mod
j),j=1,……,kを解く連立合同式求解手段と
を備え、前記制御信号入力手段に制御信号が入力される
と、前記乱数発生手段から提供されるe(1)+……+
e(k)ビットの乱数に対して、前記ビット列分割手段
と加算手段と連立合同式求解手段とによる処理を逐次的
に実行して、前記連立合同式求解手段によって得られた
解を暗号鍵として少なくとも1個を暗号装置に供給する
ことを特徴とする循環演算にもとづく暗号の暗号鍵生成
装置。
2. An input means for inputting and transmitting a control signal for designating an encryption process from the outside, and a random number sequence having a length of e (1) + ... + e (k) bits and randomly generating a binary sequence. 2 n −1 = for a predetermined integer n, a random number generating means for sending, a storage means composed of a storage medium of a predetermined capacity,
p 1 p 2 ...... can be factorized into p k , and when the length of p j is e (j) bits, the random numbers transmitted by the random number generating means are respectively lengths e (1) ,. , E (k)
A bit string dividing means for decomposing into k random numbers of bits and storing the k divided random numbers in the storage means; addition means for adding 1 to each of the k random numbers stored in the storage means; The k random numbers stored in the storage means are a 1 ,
..., ak simultaneous simultaneous congruence equation x = a j (mod
p j ), j = 1, ..., K and simultaneous congruential equation solving means, and when a control signal is input to the control signal input means, e (1) + provided from the random number generating means is provided. …… +
For the random number of e (k) bits, the processes by the bit string dividing means, the adding means, and the simultaneous congruence solving means are sequentially executed, and the solution obtained by the simultaneous congruence solving means is used as an encryption key. An encryption key generation device for encryption based on cyclic operation, characterized in that at least one key is supplied to the encryption device.
【請求項3】 前記ビット列分割手段と、前記加算手段
と、前記連立合同求解手段とを一体化してデータ処理手
段となし、このデータ処理手段が前記制御入力手段の制
御信号入力にもとづいて逐次に処理を実行するものとし
たことを特徴とする請求項2記載の暗号鍵生成装置。
3. The bit string dividing means, the adding means, and the simultaneous congruent solution means are integrated to form a data processing means, and the data processing means is sequentially operated based on a control signal input from the control input means. The encryption key generating device according to claim 2, wherein the process is executed.
JP8150077A 1996-05-21 1996-05-21 Cryptographic key generator based on cyclic operation Expired - Lifetime JP3013777B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP8150077A JP3013777B2 (en) 1996-05-21 1996-05-21 Cryptographic key generator based on cyclic operation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP8150077A JP3013777B2 (en) 1996-05-21 1996-05-21 Cryptographic key generator based on cyclic operation

Publications (2)

Publication Number Publication Date
JPH09311627A true JPH09311627A (en) 1997-12-02
JP3013777B2 JP3013777B2 (en) 2000-02-28

Family

ID=15489021

Family Applications (1)

Application Number Title Priority Date Filing Date
JP8150077A Expired - Lifetime JP3013777B2 (en) 1996-05-21 1996-05-21 Cryptographic key generator based on cyclic operation

Country Status (1)

Country Link
JP (1) JP3013777B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019021386A1 (en) * 2017-07-26 2019-01-31 日本電気株式会社 Random number calculation device, random number calculation method, encryption device, and recording medium having random number calculation program recorded thereon

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019021386A1 (en) * 2017-07-26 2019-01-31 日本電気株式会社 Random number calculation device, random number calculation method, encryption device, and recording medium having random number calculation program recorded thereon
US11579845B2 (en) 2017-07-26 2023-02-14 Nec Corporation Random number generation device, random number generation method, encryption device, and non-transitory recording medium

Also Published As

Publication number Publication date
JP3013777B2 (en) 2000-02-28

Similar Documents

Publication Publication Date Title
US7079651B2 (en) Cryptographic method and apparatus for non-linearly merging a data block and a key
KR100435052B1 (en) Encryption device
US7224795B2 (en) Variable-length key cryptosystem
JP4127472B2 (en) Data conversion apparatus, data conversion method and program for data conversion apparatus, and computer-readable recording medium
JPH11136229A (en) Method and system for generating encryption key
JP3180836B2 (en) Cryptographic communication device
RU2124814C1 (en) Method for encoding of digital data
US6463150B1 (en) Encryption device for information in binary code
EP1583278B1 (en) Stream Cipher Design with Revolving Buffers
CN113098675A (en) Binary data encryption system and method based on polynomial complete homomorphism
CN100393026C (en) Binary data block encryption conversion method
JPH10240500A (en) Random number generation device and method, encryption device and method, decryption device and method, and stream encryption system
US6301361B1 (en) Encoding and decoding information using randomization with an alphabet of high dimensionality
RU2188513C2 (en) Method for cryptographic conversion of l-bit digital-data input blocks into l-bit output blocks
JPH10173646A (en) Encryption assisting method, decryption assisting method, and apparatus using those methods
JP2000209195A (en) Cipher communication system
JP2725610B2 (en) Secret key encryption method and apparatus
CN117834119A (en) Encryption processing device, encryption processing method and storage medium
RU2103828C1 (en) Method for block data encryption
JP4857230B2 (en) Pseudorandom number generator and encryption processing device using the same
KR100564599B1 (en) Inverse calculation circuit, inverse calculation method, and storage medium encoded with computer-readable computer program code
JP3013777B2 (en) Cryptographic key generator based on cyclic operation
KR100350207B1 (en) Method for cryptographic conversion of l-bit input blocks of digital data into l-bit output blocks
JPH0736673A (en) Random number generator, communication system using the same, and method thereof
JP3013774B2 (en) Cryptographic device based on cyclic operation