JP5670849B2 - Pseudorandom number generation device and pseudorandom number generation method - Google Patents
Pseudorandom number generation device and pseudorandom number generation method Download PDFInfo
- Publication number
- JP5670849B2 JP5670849B2 JP2011203947A JP2011203947A JP5670849B2 JP 5670849 B2 JP5670849 B2 JP 5670849B2 JP 2011203947 A JP2011203947 A JP 2011203947A JP 2011203947 A JP2011203947 A JP 2011203947A JP 5670849 B2 JP5670849 B2 JP 5670849B2
- Authority
- JP
- Japan
- Prior art keywords
- random number
- pseudo
- number generation
- initial value
- pseudo 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.)
- Expired - Fee Related
Links
- 238000000034 method Methods 0.000 title claims description 10
- 238000006243 chemical reaction Methods 0.000 claims description 7
- 230000001131 transforming effect Effects 0.000 claims 2
- 238000010586 diagram Methods 0.000 description 5
- 238000005259 measurement Methods 0.000 description 3
- 230000000694 effects Effects 0.000 description 2
- 230000000630 rising effect Effects 0.000 description 1
Images
Description
本発明は、擬似乱数を生成する擬似乱数生成装置に関する。 The present invention relates to a pseudo-random number generator that generates pseudo-random numbers.
擬似乱数は、暗号や認証などに利用されている。擬似乱数は、例えば線形フィードバックシフトレジスタ(LFSR: Linear Feedback Shift Register)により生成される。LFSRは、直列に接続された複数のレジスタを有している。そして、その複数のレジスタのうち所定の出力が、排他的論理和回路(EXOR回路)を介して先頭のレジスタにフィードバックされる。初期値が設定された後、LFSRは、所定のシフトクロックに基づいて動作する。その結果、LFSRは、初期値に依存するパターンの擬似乱数列を所定の周期で繰り返し出力する。このようなLFSRは、フィードバック経路にEXOR回路を設けることにより、長周期の乱数列を得ることを可能としている。 Pseudo random numbers are used for encryption and authentication. The pseudo random number is generated by, for example, a linear feedback shift register (LFSR). The LFSR has a plurality of registers connected in series. A predetermined output among the plurality of registers is fed back to the first register via an exclusive OR circuit (EXOR circuit). After the initial value is set, the LFSR operates based on a predetermined shift clock. As a result, the LFSR repeatedly outputs a pseudo random number sequence having a pattern depending on the initial value at a predetermined cycle. Such an LFSR makes it possible to obtain a long-period random number sequence by providing an EXOR circuit in the feedback path.
ただし、LFSRによる擬似乱数の生成論理は、出力パターンから数学的に容易に解析可能である。従って、LFSRを利用した擬似乱数生成回路では、生成される擬似乱数の乱数性を高めるための工夫が必要となる。例えば、初期値を変更可能にしたり、複数段のLFSRをカスケード接続したりすることが一般的である。あるいは、非線形フィードバックシフトレジスタ(NLFSR: Non-Linear Feedback Shift Register)を用いることや、初期値をランダム化することも考えられる。 However, the pseudo-random number generation logic by LFSR can be easily analyzed mathematically from the output pattern. Therefore, in the pseudo random number generation circuit using LFSR, a device for increasing the randomness of the generated pseudo random number is required. For example, it is common that the initial value can be changed or a plurality of LFSRs are cascade-connected. Alternatively, it is possible to use a non-linear feedback shift register (NLFSR) or to randomize the initial value.
特許文献1には、LFSRを応用して非線形化することにより擬似乱数を生成する擬似乱数生成装置が記載されている。また特許文献2および特許文献3には、ランダムな初期値を利用した擬似乱数生成装置が記載されている。
特許文献1に記載された擬似乱数生成装置は、複数のカウンタを用いて初期値の生成を行っている。ここで、カウンタの出力値は、オーバーフローすることにより0に戻る。つまり、カウンタの出力値には周期性がある。このため、カウンタを用いて初期値を生成すると、一定の周期で同一の初期値が生成される可能性がある。したがって、このような擬似乱数生成装置では、初期値の周期を長くしてその予測可能性を低減することが求められる。しかしながら、このような擬似乱数生成装置の構成では、初期値の周期を長くするには、カウンタサイズの増加が必要である。カウンタサイズの増加は、回路規模および消費電力の増大を招く。また、このような擬似乱数生成装置では、カウンタにクロックが供給されない等の要因によりカウンタ動作が停止すると、初期値が固定値となる。このような場合、初期値の予測可能性が高くなってしまうという問題もある。
The pseudorandom number generator described in
また、特許文献2に記載された擬似乱数生成装置は、ランダムな初期値として、電子機器の電源投入後からの経過時間に基づく値を演算している。しかしながら、この擬似乱数生成装置は、経過時間の測定にカウンタを使用している。このような経過時間そのものはランダムな値であっても、その測定にカウンタを用いると、測定値の範囲は、カウンタサイズに依存する上限値までとなってしまう。したがって、このような擬似乱数生成装置においても、測定値の上限値を大きくして初期値の予測可能性を低減することが求められる。しかしながら、特許文献1に記載のものと同様、このような擬似乱数生成装置の構成では、測定値の上限値を大きくするには、カウンタサイズの増加が必要である。カウンタサイズの増加は、回路規模および消費電力の増大を招く。また、この擬似乱数生成装置においても、電子機器の電源投入後からの経過時間を計測する機能が外因により停止すると初期値が固定値となる。このような場合、初期値の予測可能性が高くなってしまうという問題もある。
Moreover, the pseudorandom number generation device described in Patent Document 2 calculates a value based on an elapsed time after power-on of the electronic device as a random initial value. However, this pseudo-random number generator uses a counter for measuring elapsed time. Even if such elapsed time itself is a random value, when a counter is used for the measurement, the range of the measured value is up to an upper limit value depending on the counter size. Therefore, even in such a pseudorandom number generator, it is required to increase the upper limit value of the measurement value and reduce the predictability of the initial value. However, like the one described in
本発明は、上述の課題を解決するためになされたもので、回路規模を増大させることなく、擬似乱数生成において用いられる初期値の乱数性を高めて擬似乱数の乱数性を向上させる擬似乱数生成装置を提供することを目的とする。 The present invention has been made in order to solve the above-described problems, and improves the randomness of pseudorandom numbers by increasing the randomness of initial values used in pseudorandom number generation without increasing the circuit scale. An object is to provide an apparatus.
本発明の擬似乱数生成装置は、初期値を用いて擬似乱数を生成する擬似乱数生成部と、外部から入力される外部データおよび前記擬似乱数生成部から出力される擬似乱数を論理演算して得られる値を、前記初期値として前記擬似乱数生成部に対して出力する初期値制御部と、を備える。 The pseudorandom number generator of the present invention is obtained by performing a logical operation on a pseudorandom number generator that generates a pseudorandom number using an initial value, external data input from the outside, and a pseudorandom number output from the pseudorandom number generator. And an initial value control unit that outputs the obtained value as the initial value to the pseudo-random number generation unit.
また、本発明の擬似乱数生成方法は、初期値を用いて擬似乱数を生成する擬似乱数生成方法であって、生成した擬似乱数をフィードバックデータとして、該擬似乱数および外部から入力される外部データを論理演算して得られる値を初期値として次の擬似乱数を生成する。 The pseudo-random number generation method of the present invention is a pseudo-random number generation method that generates a pseudo-random number using an initial value. The generated pseudo-random number is used as feedback data, and the pseudo-random number and external data input from the outside are The next pseudorandom number is generated with the value obtained by the logical operation as the initial value.
回路規模を増大させることなく、擬似乱数生成処理において用いられる初期値の乱数性を高めることにより擬似乱数の乱数性を向上させる擬似乱数生成装置を提供することができる。 It is possible to provide a pseudo-random number generator that improves the randomness of a pseudo-random number by increasing the randomness of an initial value used in the pseudo-random number generation process without increasing the circuit scale.
以下、本発明の実施の形態について、図面を参照して詳細に説明する。 Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings.
(第1の実施の形態)
本発明の第1の実施の形態としての擬似乱数生成装置1の構成を図1に示す。図1において、擬似乱数生成装置1は、初期値制御部11と、擬似乱数生成部12とを備える。
(First embodiment)
FIG. 1 shows a configuration of a pseudo random
初期値制御部11には、擬似乱数生成部12からのフィードバックデータ、および、外部データが入力される。この外部データは、デジタルデータである。また、外部データは、固定値でないものが望ましい。例えば、外部データは、擬似乱数生成装置1を搭載する電子機器に内蔵されているデジタル時計機能から取得される時刻データであってもよい。また、外部データは、ランダムなアナログデータがデジタル変換されたデータであってもよい。例えば、外部データは、擬似乱数生成装置1を搭載する電子機器の外部に接続されたアナログデータ測定機器(例えば、湿度計・震度計・光度計・風速計・騒音計など)から取得されるアナログデータがデジタル変換されたものであってもよい。
The initial value controller 11 receives the feedback data from the
また、初期値制御部11は、フィードバックデータおよび外部データを論理演算して得られる値(論理演算値)を、擬似乱数生成部12に出力する。例えば、初期値制御部11は、フィードバックデータおよび外部データの排他的論理和を擬似乱数生成部12に出力してもよい。
Further, the initial value control unit 11 outputs a value (logical operation value) obtained by performing a logical operation on the feedback data and the external data to the pseudo random
擬似乱数生成部12は、初期値制御部11から出力される値を初期値とする擬似乱数生成処理を実行し、擬似乱数を生成する。擬似乱数生成部12には、初期値を用いて擬似乱数を生成する公知の技術を適用可能である。例えば、擬似乱数生成部12は、初期値を用いて自回路の出力値を非線形変換することにより次の出力値とする非線形フィードバックレジスタによって構成されてもよい。
The pseudo random
以上のように構成される擬似乱数生成装置1の動作について説明する。
The operation of the
まず、初期値制御部11に、外部データおよび擬似乱数生成部12からのフィードバックデータが入力される。なお、初期値制御部11には、電源投入直後は、擬似乱数生成部12からのフィードバックデータとして乱数性の低いデータが入力される。しかしながら、下記に述べるように一旦動作した後は、初期値制御部11には、フィードバックデータとして乱数性の高い擬似乱数が入力されるようになる。
First, external data and feedback data from the
次に、初期値制御部11は、入力された外部データおよびフィードバックデータの論理演算値(例えば排他的論理和)を、擬似乱数生成部12に出力する。
Next, the initial value control unit 11 outputs a logical operation value (for example, exclusive OR) of the input external data and feedback data to the pseudo-random
次に、擬似乱数生成部12は、初期値制御部11から入力された値を初期値として擬似乱数生成処理を行い、擬似乱数を生成する。
Next, the pseudo random
生成された擬似乱数は、フィードバックデータとして初期値制御部11に入力されるとともに、擬似乱数生成装置1の出力値として出力される。
The generated pseudo-random number is input as feedback data to the initial value control unit 11 and output as an output value of the pseudo-random
以上で、擬似乱数生成装置1の動作の説明を終了する。
Above, description of operation | movement of the pseudorandom
次に、本発明の実施の形態の効果について述べる。 Next, effects of the embodiment of the present invention will be described.
本発明の第1の実施の形態としての擬似乱数生成装置は、回路規模を増大させることなく、擬似乱数生成において用いられる初期値の乱数性を高めて擬似乱数の乱数性を向上させることができる。 The pseudo random number generation device as the first exemplary embodiment of the present invention can improve the randomness of the pseudo random number by increasing the randomness of the initial value used in the pseudo random number generation without increasing the circuit scale. .
その理由は、初期値制御部が、外部データおよび擬似乱数生成部からのフィードバックデータの論理演算値を、擬似乱数生成処理で用いられる初期値として擬似乱数生成部に出力するからである。これにより、本実施の形態としての擬似乱数生成装置は、外部データに周期性が存在したとしても、外部データおよび擬似乱数生成回路からのフィードバックデータの論理演算値を初期値とすることにより、初期値の周期性を乱すことができる。また、本実施の形態としての擬似乱数生成装置は、擬似乱数生成処理の初期値として擬似乱数生成部からのフィードバックデータのみを用いる場合と比べて、フィードバックデータおよび外部データの論理演算値を初期値とすることにより、擬似乱数の乱数性を上げることになる。また、本実施の形態としての擬似乱数生成装置は、外因により外部データが固定値となった場合でも、外部データおよび擬似乱数生成回路からのフィードバックデータの論理演算値を初期値とするため、固定値を初期値として用いることがない。その結果、本実施の形態としての擬似乱数生成装置は、出力される擬似乱数の解析をより困難にすることができる。しかも、このような乱数性の高い初期値を生成する本実施の形態の初期値制御部は、膨大なビット数のカウンタを有した初期値生成回路や、そのカウンタが同じ値とならないようにクロックを生成する回路を不要とし、論理演算回路のみを用いて実現可能である。これにより、本実施の形態としての擬似乱数生成装置は、初期値の乱数性向上のために回路規模および消費電力を増加させることがない。 This is because the initial value control unit outputs the logical operation value of the external data and the feedback data from the pseudo random number generation unit to the pseudo random number generation unit as the initial value used in the pseudo random number generation process. As a result, the pseudo-random number generation device according to the present embodiment is configured so that the initial value is the logical operation value of the feedback data from the external data and the pseudo-random number generation circuit even if the external data has periodicity. The periodicity of the value can be disturbed. In addition, the pseudo random number generation device according to the present embodiment uses the logical operation values of the feedback data and the external data as initial values as compared with the case where only the feedback data from the pseudo random number generation unit is used as the initial value of the pseudo random number generation process. By doing so, the randomness of the pseudo-random number is increased. In addition, the pseudo-random number generation device as the present embodiment uses the logical operation value of the feedback data from the external data and the pseudo-random number generation circuit as the initial value even when the external data becomes a fixed value due to an external factor. The value is not used as an initial value. As a result, the pseudo random number generation device according to the present embodiment can make it more difficult to analyze the output pseudo random numbers. In addition, the initial value control unit of the present embodiment that generates such an initial value with high randomness is an initial value generation circuit having a counter with an enormous number of bits and a clock so that the counter does not have the same value. This can be realized using only a logic operation circuit. Thereby, the pseudo-random number generation device as the present embodiment does not increase the circuit scale and power consumption in order to improve the randomness of the initial value.
(第2の実施の形態)
次に、本発明の第2の実施の形態について図面を参照して詳細に説明する。まず、本発明の第2の実施の形態としての擬似乱数生成装置2の構成を図2に示す。
(Second Embodiment)
Next, a second embodiment of the present invention will be described in detail with reference to the drawings. First, FIG. 2 shows a configuration of a pseudo random number generation device 2 as a second embodiment of the present invention.
図2において、擬似乱数生成装置2は、初期値制御部21と、擬似乱数生成部22と、擬似乱数制御部23とを備える。また、擬似乱数生成部22は、擬似乱数生成回路24a〜24d(以降、総称して擬似乱数生成回路24ともいう)を有する。なお、図2には、4つの擬似乱数生成回路24を示したが、本発明の擬似乱数生成部が有する擬似乱数生成回路の数を限定するものではない。
In FIG. 2, the pseudo random number generation device 2 includes an initial
初期値制御部21には、外部データDDおよび擬似乱数DOa〜DOdが入力される。この擬似乱数DOa〜DOdは、擬似乱数生成回路24a〜24dからの各出力値(フィードバックデータ)である。初期値制御部21の回路構成例を図3に示す。図3において、初期値制御部21は、EXOR回路201〜204を有する。初期値制御部21は、これらの回路を用いて、外部データDDおよび擬似乱数DOa〜DOdに基づく信号DIを出力する。
External data DD and pseudorandom numbers DOa to DOd are input to the initial
擬似乱数生成回路24は、初期値DIを用いて擬似乱数生成処理を行い、生成した擬似乱数DOを出力する回路である。図2に示したように、これらの擬似乱数生成回路24は、直列に接続される。すなわち、擬似乱数生成回路24aには、初期値制御部21からの出力値DIが、初期値DIaとして入力される。また、擬似乱数生成回路24bには、擬似乱数生成回路24aから出力される擬似乱数DOaが、擬似乱数生成の初期値DIbとして入力される。また、擬似乱数生成回路24cには、擬似乱数生成回路24bから出力される擬似乱数DObが、擬似乱数生成の初期値DIcとして入力される。また、擬似乱数生成回路24dには、擬似乱数生成回路24cから出力される擬似乱数DOcが、擬似乱数生成の初期値DIdとして入力される。
The pseudo random
各擬似乱数生成回路24から出力される擬似乱数DOa〜DOdは、前述のように、初期値制御部21に入力される。
The pseudo random numbers DOa to DOd output from each pseudo random
また、擬似乱数生成回路24は、非線形フィードバックシフトレジスタ(NLFSR)と同等の機能を有するものである。このような擬似乱数生成回路24の回路構成例を図4に示す。図4において、擬似乱数生成回路24は、シフトレジスタ205と、非線形変換部206とを備える。
The pseudo random
シフトレジスタ205は、N個のフリップフロップ207から構成される。Nは2以上の整数であり、たとえば16である。シフトレジスタ205には、Nビットのデータがパラレルに入力される。また、シフトレジスタ205からは、Nビットのデータがパラレルに出力される。この出力データが、DO(擬似乱数)となる。また、クロック信号CLKは、N個の各フリップフロップ207に供給される。シフトレジスタ205は、クロック信号CLKに基づいて動作する。つまり、シフトレジスタ205は、クロック信号CLKに同期して入力データの値を取り込む。そして、シフトレジスタ205は、次のクロック信号CLKの立ち上がりエッジまで、取り込んだ値を保持して出力している。すなわち、シフトレジスタ205のデータ値は、クロック信号CLKに同期して更新される。
The
非線形変換部206は、排他的論理和を演算するEXOR回路208、210と、論理積を演算するAND回路209と、置換回路211とを有する。非線形変換部206は、これらの回路を用いて、シフトレジスタ205からの出力データを、初期値DIを用いて非線形変換し、シフトレジスタ205に入力する。非線形変換されたデータは、次のクロック信号CLKに同期してシフトレジスタ205に取り込まれることになる。具体的には、非線形変換部206は、シフトレジスタ205からの出力データおよび初期値DIの排他的論理和と、シフトレジスタ205からの出力データおよび初期値DIの論理積とを演算し、ビットの入れ替え行うことにより、非線形化を実現している。
The
擬似乱数制御部23は、擬似乱数生成回路24a〜24dから出力される各擬似乱数DOa〜DOdの中から1つを選択して出力する。このような擬似乱数制御部23の回路構成例を図5に示す。擬似乱数制御部23は、EXOR回路212〜217と、セレクタ218とを有する。擬似乱数制御部23は、これらの回路を用いて、擬似乱数DOa〜DOdに基づく選択信号を生成し、選択信号に基づいて擬似乱数DOa〜DOdの1つを選択する。ここで、選択信号は、擬似乱数生成回路24の個数分の異なる値をとりうる信号である。本実施形態では、擬似乱数生成回路24の個数は4なので、選択信号は2ビットの信号である。
The pseudo random
以上のように構成された擬似乱数生成装置2の動作について、図3〜図5を参照して説明する。 The operation of the pseudorandom number generator 2 configured as described above will be described with reference to FIGS.
まず、図3の初期値制御部21に、外部データDDと、擬似乱数制御回路24a〜24dからのフィードバックデータDOa〜DOdが入力される。前述のように、外部データDDは、擬似乱数生成装置2の外部から入力されるデジタルデータである。前述のように、外部データDDは、固定値でないことが望ましい。ここでは、外部データDDは、擬似乱数生成装置2を搭載する電子機器に内蔵されているデジタル計時装置から取得された時刻データであるものとする。なお、外部データDDは、時刻データに限らない。
First, the external data DD and the feedback data DOa to DOd from the pseudo random number control circuits 24a to 24d are input to the initial
なお、初期値制御部21には、電源投入直後には、擬似乱数制御回路24a〜24dからのフィードバックデータDOa〜DOdとしてシフトレジスタ205の初期値が入力される。そして、下記に述べるような動作を数回繰り返した後、初期値制御部21には、フィードバックデータDOa〜DOdとして擬似乱数が入力されるようになる。
The initial
次に、初期値制御部21において、EXOR回路201は、信号DOaおよびDObの排他的論理和をとる。EXOR回路202は、信号DOcおよび信号DOdの排他的論理和をとる。EXOR回路203は、EXOR回路201およびEXOR回路202の各出力の排他的論理和をとる。EXOR回路204は、外部データDDおよびEXOR回路203の各出力の排他的論理和をとる。EXOR回路204の出力DIが、擬似乱数生成回路24aに出力される。
Next, in the initial
次に、図4の擬似乱数生成回路24aにおいて、EXOR回路208は、初期値DIaと、シフトレジスタ205から出力される擬似乱数DOaとの排他的論理和をとり、信号aとして出力する。AND回路209は、初期値DIaと、シフトレジスタ205から出力される擬似乱数DOaとの論理積をとり、信号bとして出力する。EXOR回路210は、信号bの各ビットの排他的論理和をとり、1ビットの信号cとして出力する。置換回路211は、信号aのうち最上位を除くN−1ビットを、上位N−1ビットとし、信号cを最下位ビットとする置換データを出力する。この置換データは、シフトレジスタ205にパラレルに入力される。シフトレジスタ205は、入力される置換データを、クロックCLKに同期して取り込む。取り込まれたNビットのデータは、擬似乱数DOaとして出力される。
Next, in the pseudo random number generation circuit 24a of FIG. 4, the
また、擬似乱数生成回路24bには、擬似乱数生成回路24aによって生成された擬似乱数DOaが初期値DIbとして入力されている。そして、擬似乱数生成回路24bは、擬似乱数生成回路24aと同様に動作することにより、擬似乱数DObを出力する。
Further, the pseudo random
また、擬似乱数生成回路24cには、擬似乱数生成回路24bによって生成された擬似乱数DObが初期値DIcとして入力されている。そして、擬似乱数生成回路24cは、擬似乱数生成回路24aと同様に動作することにより、擬似乱数DOcを出力する。
Further, the pseudo random
また、擬似乱数生成回路24dには、擬似乱数生成回路24cによって生成された擬似乱数DOcが初期値DIdとして入力されている。そして、擬似乱数生成回路24dは、擬似乱数生成回路24aと同様に動作することにより、擬似乱数DOdを出力する。
The pseudo random
ここで、擬似乱数生成回路24b〜24dによって生成された各擬似乱数の乱数周期は前段の擬似乱数生成回路によって生成された各擬似乱数の乱数周期の2乗となる。したがって、擬似乱数生成回路24a〜24dは、異なる周期の擬似乱数を出力することになる。また、擬似乱数生成回路24a〜24dによって生成される擬似乱数DOa〜DOdは、同じクロック信号CLKに同期して値が更新されるため、同じ値となる可能性は極めて低い。
Here, the random number period of each pseudo random number generated by the pseudo random
次に、擬似乱数生成回路24a〜24dから出力される擬似乱数DOa〜DOdは、擬似乱数制御部23に入力される。
Next, the pseudo random numbers DOa to DOd output from the pseudo random number generation circuits 24 a to 24 d are input to the pseudo random
図5の擬似乱数制御部23において、EXOR回路212は、擬似乱数DOdの各ビットの排他的論理和をとった1ビットの信号eを出力する。同様に、EXOR回路213〜215は、擬似乱数DOc〜DOaの各ビットの排他的論理和をとった1ビットの信号f〜hを出力する。そして、EXOR回路216は、信号eおよび信号fの排他的論理和をとった信号iを出力する。また、EXOR回路217は、信号gおよび信号hの排他的論理和をとった信号jを出力する。
In the pseudo random
次に、セレクタ218は、信号iおよび信号jのとりうる4通りの値を選択信号とみなして、擬似乱数DOa〜DObのいずれかを選択して出力する。例えば、信号iおよびj値がともに0の場合、擬似乱数DOaを選択出力し、信号iが0および信号jが1の場合、擬似乱数DObを選択出力するようにしてもよい。このように、乱数強度の異なる各擬似乱数DOa〜DOdによって生成される選択信号は、ランダム性を有する。すなわち、擬似乱数制御部23は、ランダムな選択信号に基づいて、擬似乱数DOa〜DOdのいずれか1つを選択し、出力する。
Next, the selector 218 regards four possible values of the signal i and the signal j as selection signals and selects and outputs one of the pseudo random numbers DOa to DOb. For example, when both the signal i and j values are 0, the pseudo random number DOa may be selectively output. When the signal i is 0 and the signal j is 1, the pseudo random number DOb may be selectively output. Thus, the selection signals generated by the pseudo random numbers DOa to DOd having different random number strengths have randomness. That is, the pseudo random
以上で、擬似乱数生成装置2の動作の説明を終了する。 Above, description of operation | movement of the pseudorandom number generation apparatus 2 is complete | finished.
次に、本発明の第2の実施の形態の効果について述べる。 Next, the effect of the second exemplary embodiment of the present invention will be described.
本発明の第2の実施の形態としての擬似乱数生成装置は、回路規模を増大させることなく、擬似乱数生成において用いられる初期値の乱数性をさらに高めることができ、その結果、擬似乱数の乱数性をさらに向上させることができる。 The pseudo random number generation device as the second exemplary embodiment of the present invention can further increase the randomness of the initial value used in the pseudo random number generation without increasing the circuit scale. The property can be further improved.
その理由は、複数の擬似乱数生成回路を直列に接続することによって擬似乱数生成部を構成し、1段目の擬似乱数生成回路は、乱数生成の初期値として、各擬似乱数生成回路からの出力値および外部データの排他的論理和をとった値を用いるからである。そして、2段目以降の擬似乱数生成回路は、前段の擬似乱数生成回路からの出力値を乱数生成の初期値として用いるからである。これにより、各擬似乱数生成回路からの出力値の乱数周期は、前段の2乗となる。また、各擬似乱数生成回路からの出力値は、同一のクロックに同期して値が更新されるため、同じ値となる可能性は極めて低い。このように、乱数周期が異なる複数の擬似乱数および外部データの排他的論理和を、1段目の乱数生成回路の初期値として生成することにより、本実施の形態の乱数生成装置は、乱数生成における初期値の乱数性をさらに高めることになる。さらに、擬似乱数制御部は、各擬似乱数生成回路からの出力値に基づき選択信号を生成する。このような選択信号は、前述のように乱数周期の異なる複数の擬似乱数に基づいて生成されるため、乱数性の高いものとなる。したがって、本実施の形態の乱数生成装置は、そのような乱数性の高い選択信号に基づいて、各擬似乱数生成回路からの出力値のいずれかを自装置から出力する。その結果、本実施の形態の乱数生成装置が生成する擬似乱数はより乱数性の高いものとなる。 The reason is that a pseudo-random number generator is configured by connecting a plurality of pseudo-random number generators in series. This is because a value obtained by exclusive OR of the value and external data is used. This is because the pseudo random number generation circuit in the second and subsequent stages uses the output value from the pseudo random number generation circuit in the previous stage as an initial value for random number generation. Thereby, the random number cycle of the output value from each pseudo-random number generation circuit becomes the square of the previous stage. Further, since the output values from the respective pseudo-random number generation circuits are updated in synchronization with the same clock, the possibility of being the same value is extremely low. In this way, by generating an exclusive OR of a plurality of pseudo-random numbers having different random number periods and external data as an initial value of the first-stage random number generation circuit, the random number generation device of the present embodiment can generate random numbers. This will further enhance the randomness of the initial value at. Furthermore, the pseudo random number control unit generates a selection signal based on the output value from each pseudo random number generation circuit. Since such a selection signal is generated based on a plurality of pseudo random numbers having different random number cycles as described above, the selection signal has high randomness. Therefore, the random number generation device according to the present embodiment outputs one of the output values from each pseudo-random number generation circuit based on such a highly random selection signal. As a result, the pseudo-random number generated by the random number generation device according to the present embodiment has higher randomness.
また、本実施の形態の乱数生成装置は、外部データDDと、各擬似乱数生成回路からのフィードバックデータとの排他的論理和を1段目の擬似乱数生成回路の初期値とするので、外部データDDが固定値であっても、初期値を固定値とすることがない。このため、本実施の形態の乱数生成装置は、外因により外部データDDが固定値となった場合でも、初期値の予測可能性を低減させない。その結果、本実施の形態の乱数生成装置は、生成する擬似乱数の乱数性の高さを維持可能となる。 In addition, the random number generation device according to the present embodiment uses the exclusive OR of the external data DD and the feedback data from each pseudo random number generation circuit as the initial value of the first stage pseudo random number generation circuit. Even if DD is a fixed value, the initial value is not set to a fixed value. For this reason, the random number generation device according to the present embodiment does not reduce the predictability of the initial value even when the external data DD becomes a fixed value due to an external factor. As a result, the random number generation device according to the present embodiment can maintain the high randomness of the pseudo random number to be generated.
そして、本実施の形態としての乱数生成装置は、上述のような乱数性の高い初期値を生成する初期値制御部を、排他的論理和回路の組み合わせで実現している。したがって、本実施の形態としての乱数生成装置は、初期値の乱数性向上のために回路規模を増大させることがない。 The random number generation device according to the present embodiment realizes an initial value control unit that generates an initial value with high randomness as described above by a combination of exclusive OR circuits. Therefore, the random number generation device according to the present embodiment does not increase the circuit scale in order to improve the randomness of the initial value.
なお、本発明の実施の形態において、擬似乱数生成部が4つの擬似乱数生成回路を備えるものとして説明したが、本発明の擬似乱数生成部が備える擬似乱数生成回路の数を限定するものではない。擬似乱数生成部がM(Mは2以上の整数)個の直列に接続された擬似乱数生成回路を備える場合、本実施の形態の初期値制御部は、M個の擬似乱数生成回路からの各出力値および外部データの排他的論理和を2つずつとっていくことにより初期値DIを生成すればよい。あるいは、初期値制御部は、M個の擬似乱数生成回路からの各出力値および外部データを論理演算することにより初期値DIを生成するのであれば、その他の論理回路の組み合わせにより実現されてもよい。 In the embodiment of the present invention, the pseudo random number generation unit is described as including four pseudo random number generation circuits, but the number of pseudo random number generation circuits included in the pseudo random number generation unit of the present invention is not limited. . When the pseudo random number generation unit includes M (M is an integer equal to or greater than 2) pseudo random number generation circuits connected in series, the initial value control unit according to the present embodiment includes each of the M pseudo random number generation circuits. The initial value DI may be generated by taking two exclusive ORs of the output value and the external data. Alternatively, the initial value control unit may be realized by a combination of other logic circuits as long as the initial value DI is generated by performing a logical operation on each output value and external data from the M pseudorandom number generation circuits. Good.
また、擬似乱数生成部がM個の直列に接続された擬似乱数生成回路を備える場合、本実施の形態の擬似乱数制御部は、M個の擬似乱数生成回路からの各出力値の各ビットの排他的論理和をとってそれぞれ1ビットの信号をM個生成すればよい。そして、本実施の形態の擬似乱数制御部は、生成したM個の信号に基づいて、M通りの値をとりうるmビットの選択信号を生成すればよい。あるいは、擬似乱数制御部は、M個の擬似乱数生成回路からの各出力値に基づいてM通りの値をとりうるmビットの選択信号を生成するのであれば、その他の構成であってもよい。 Further, when the pseudo random number generation unit includes M pseudo random number generation circuits connected in series, the pseudo random number control unit according to the present embodiment is configured to output each bit of each output value from the M pseudo random number generation circuits. What is necessary is just to generate M 1-bit signals by taking exclusive OR. Then, the pseudo random number control unit of the present embodiment may generate an m-bit selection signal that can take M values based on the generated M signals. Alternatively, the pseudo-random number control unit may have other configurations as long as it generates an m-bit selection signal that can take M values based on the output values from the M pseudo-random number generation circuits. .
また、上述した各実施の形態は、適宜組み合わせて実施されることが可能である。 Moreover, each embodiment mentioned above can be implemented in combination as appropriate.
また、本発明は、上述した各実施の形態に限定されず、様々な態様で実施されることが可能である。 The present invention is not limited to the above-described embodiments, and can be implemented in various modes.
1、2 擬似乱数生成装置
11、21 初期値制御部
12、22 擬似乱数生成部
23 擬似乱数制御部
24、24a〜24d 擬似乱数生成回路
201〜204、208、210、212〜217 EXOR回路
205 シフトレジスタ
206 非線形変換部
207 フリップフロップ
209 AND回路
211 置換回路
218 セレクタ
DESCRIPTION OF
Claims (4)
前記複数の擬似乱数生成回路から出力される擬似乱数のいずれか1つを選択して自装置の出力値とする擬似乱数制御部と、 A pseudo-random number control unit that selects any one of the pseudo-random numbers output from the plurality of pseudo-random number generation circuits as an output value of the own device;
前記複数の擬似乱数生成回路のそれぞれから出力される擬似乱数および外部から入力される外部データを論理演算して得られる値を、前記複数の擬似乱数生成回路のうち1段目の擬似乱数生成回路に対して自身の出力値を非線形変換するための次の前記初期値として出力する初期値制御部と、 A value obtained by performing a logical operation on a pseudo-random number output from each of the plurality of pseudo-random number generation circuits and external data input from the outside is used as a first-stage pseudo-random number generation circuit among the plurality of pseudo-random number generation circuits. An initial value control unit that outputs the output value as a next initial value for nonlinear conversion of the output value of itself,
を備えた擬似乱数生成装置。 A pseudo-random number generation device comprising:
第i(iは1以上の整数)の擬似乱数生成回路によって生成される擬似乱数を初期値として、第(i+1)の擬似乱数生成回路によって擬似乱数を生成し、 Using the pseudorandom number generated by the i-th (i is an integer of 1 or more) pseudorandom number generator as an initial value, the (i + 1) th pseudorandom number generator generates a pseudorandom number,
前記n個の擬似乱数生成回路により生成されるn個の擬似乱数のうち1つを選択して出力し、 Selecting and outputting one of the n pseudo-random numbers generated by the n pseudo-random number generation circuits;
前記n個の擬似乱数生成回路により生成されるn個の擬似乱数および外部から入力される外部データを論理演算して得られる値を、前記第1の擬似乱数生成回路において自身の出力値を非線形変換するための次の前記初期値として用いる擬似乱数生成方法。 A value obtained by performing a logical operation on n pseudo-random numbers generated by the n pseudo-random number generation circuits and external data input from the outside, and an output value of the first pseudo-random number generation circuit in a non-linear manner A pseudo-random number generation method used as the next initial value for conversion.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2011203947A JP5670849B2 (en) | 2011-09-19 | 2011-09-19 | Pseudorandom number generation device and pseudorandom number generation method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2011203947A JP5670849B2 (en) | 2011-09-19 | 2011-09-19 | Pseudorandom number generation device and pseudorandom number generation method |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2013064898A JP2013064898A (en) | 2013-04-11 |
JP5670849B2 true JP5670849B2 (en) | 2015-02-18 |
Family
ID=48188455
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2011203947A Expired - Fee Related JP5670849B2 (en) | 2011-09-19 | 2011-09-19 | Pseudorandom number generation device and pseudorandom number generation method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP5670849B2 (en) |
Families Citing this family (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP6203532B2 (en) * | 2013-05-13 | 2017-09-27 | 株式会社メガチップス | Semiconductor memory device and data processing system |
JP6194136B2 (en) * | 2015-02-19 | 2017-09-06 | 三菱電機株式会社 | Pseudorandom number generation device and pseudorandom number generation program |
JP2017005682A (en) * | 2016-02-16 | 2017-01-05 | 国立大学法人京都大学 | Data processing apparatus, data transmission method, computer program, and data server |
JP6678958B2 (en) * | 2016-12-08 | 2020-04-15 | 東芝情報システム株式会社 | Pseudo-random number generation device and pseudo-random number generation program |
JP6697618B2 (en) * | 2019-06-11 | 2020-05-20 | キオクシア株式会社 | Randomizer and semiconductor memory device |
US11188306B1 (en) * | 2020-08-18 | 2021-11-30 | Nuvoton Technology Corporation | Distributed random-number generator |
Family Cites Families (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH0736672A (en) * | 1993-07-20 | 1995-02-07 | Canon Inc | Random-number generator, communication system using the same and method therefor |
JP2002215030A (en) * | 2001-01-17 | 2002-07-31 | Advanced Mobile Telecommunications Security Technology Research Lab Co Ltd | Random number generation method |
JP3732188B2 (en) * | 2003-03-31 | 2006-01-05 | Necマイクロシステム株式会社 | Pseudo random number generator |
JP2004349992A (en) * | 2003-05-22 | 2004-12-09 | Hitachi Ltd | Data processing device with key generation function for encryption |
JP5119417B2 (en) * | 2008-04-17 | 2013-01-16 | ルネサスエレクトロニクス株式会社 | Pseudo random number generator |
JP5415020B2 (en) * | 2008-05-27 | 2014-02-12 | Kddi株式会社 | Stream cipher encryption apparatus, decryption apparatus, MAC generation apparatus, stream cipher encryption method, decryption method, MAC generation method, and program |
JP5171420B2 (en) * | 2008-06-18 | 2013-03-27 | ルネサスエレクトロニクス株式会社 | Pseudo random number generator |
-
2011
- 2011-09-19 JP JP2011203947A patent/JP5670849B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2013064898A (en) | 2013-04-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Garcia-Bosque et al. | Chaos-based bitwise dynamical pseudorandom number generator on FPGA | |
JP5670849B2 (en) | Pseudorandom number generation device and pseudorandom number generation method | |
Panda et al. | Modified dual-CLCG method and its VLSI architecture for pseudorandom bit generation | |
CN103098018B (en) | Bit sequence generator | |
JP2011071995A5 (en) | Counter circuit | |
US20180101361A1 (en) | Secured pseudo-random number generator | |
JP2004234153A (en) | Seed generation circuit, random number generation circuit, semiconductor integrated circuit, ic card and information terminal device | |
KR20140110142A (en) | Random number generator | |
US20130191427A1 (en) | Pseudo-noise generator | |
JP5341690B2 (en) | Physical random number generator | |
Gupta et al. | Coupled variable‐input LCG and clock divider‐based large period pseudo‐random bit generator on FPGA | |
JP2016126517A (en) | Device and method for generating random numbers | |
JP2010002959A (en) | Pseudo-random number generating device | |
Pareschi et al. | Simple and effective post-processing stage for random stream generated by a chaos-based RNG | |
JP4148807B2 (en) | Random number generator and information processing apparatus | |
JP2016126518A (en) | Device and method for generating random numbers | |
Singh et al. | FPGA Implementation of Chaos based Pseudo Random Number Generator | |
Hussain et al. | Design of Secured Lightweight PRNG Circuit using LFSR for Portable IoT Devices | |
Ergün et al. | An ADC based random number generator from a discrete time chaotic map | |
Rajagopalan et al. | Design of boolean chaotic oscillator using CMOS technology for true random number generation | |
JP5854003B2 (en) | Digitally controlled oscillator and variable frequency oscillator | |
Fischer et al. | True random number generators in configurable logic devices | |
CN107911208B (en) | Chaotic sequence generation method and generator | |
JP4451841B2 (en) | Random number generation apparatus and random number generation method | |
Kotě et al. | Improved structure of true random number generator with direct amplification of analog noise |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20130315 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20140213 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20140225 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20140418 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20140924 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20141107 |
|
TRDD | Decision of grant or rejection written | ||
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20141125 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20141218 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 5670849 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
S111 | Request for change of ownership or part of ownership |
Free format text: JAPANESE INTERMEDIATE CODE: R313111 |
|
R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |
|
LAPS | Cancellation because of no payment of annual fees |