WO2011036747A1 - 演算装置 - Google Patents
演算装置 Download PDFInfo
- Publication number
- WO2011036747A1 WO2011036747A1 PCT/JP2009/066538 JP2009066538W WO2011036747A1 WO 2011036747 A1 WO2011036747 A1 WO 2011036747A1 JP 2009066538 W JP2009066538 W JP 2009066538W WO 2011036747 A1 WO2011036747 A1 WO 2011036747A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- value
- rows
- matrix
- unit
- input
- 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.)
- Ceased
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/002—Countermeasures against attacks on cryptographic mechanisms
- H04L9/003—Countermeasures against attacks on cryptographic mechanisms for power analysis, e.g. differential power analysis [DPA] or simple power analysis [SPA]
Definitions
- the present invention relates to an arithmetic device.
- Power Analysis which estimates the secret key used in the cryptographic circuit by observing the power consumption during the operation of the cryptographic circuit.
- the attacker predicts the key used in the encryption circuit based on the plaintext (input to the encryption device) and the ciphertext (output of the encryption device) and calculates the corresponding intermediate data. Thereafter, statistical processing of the predicted intermediate data and the power consumption of the encryption circuit is performed to determine whether or not the key prediction is correct.
- a method using a single power consumption waveform is called simple power analysis (Simple Power Analysis), and a method using a plurality of power consumption waveforms corresponding to a plurality of plaintexts is called differential power analysis (Differential Power Analysis). to be called.
- the random mask method using a random number (random mask) generated inside the encryption circuit is an effective measure.
- the random mask method makes the analysis difficult by disturbing the intermediate data and the power consumption by the random mask and eliminating the relation between the intermediate data and the power consumption predicted by the attacker.
- non-linear arithmetic processing is used in the processing in order to increase security.
- AES an 8-bit input / output nonlinear operation called SubByte is used.
- the AES SubByte is an inverse element calculation of a finite field GF (hereinafter simply referred to as GF) (in the original definition, an inverse element calculation of GF (2 ⁇ 8).
- GF finite field GF
- the present invention has been made in view of the above, and an object of the present invention is to provide an arithmetic device capable of improving safety against power analysis.
- the present invention includes an input unit that receives an input value, and L (L is an integer of 1 or more) predetermined M rows and N columns (M and N are L) corresponding to the input value among the row vectors included in the matrix in which the sum of the numbers of elements included in each row of the matrix is equal to each other between the rows
- a calculation unit that calculates an output value that is a linear sum of L values corresponding to an inner product of each of the N row vectors and a first column vector of N rows predetermined for each of the L matrices; and the output And an output unit for outputting a value.
- the arithmetic device uses a matrix having redundancy in the column direction as compared with the matrix used in the method of Coron et al., So that the number of elements in each row of the matrix is the same.
- arithmetic device that performs inverse element calculation (nonlinear calculation) of GF (2 ⁇ 2) that is safe for power analysis will be described.
- the method of the present embodiment can also be applied to inverse element calculation in other finite fields such as GF (2 ⁇ 4) and data reference in a general input / output table.
- R 2 is a 1-bit random mask
- R 3 and R 4 are 2-bit random masks.
- i ⁇ Z ⁇ and i ⁇ R 1 represent inner product calculation between vectors.
- 1 and ⁇ 1 of the matrix component (matrix element value) of 4 rows and 4 columns in the matrix calculation of equation (1) are respectively ( ⁇ 1) ⁇ ⁇ R 2 + i ⁇ Z ⁇ This corresponds to +1 and ⁇ 1 of + i ⁇ R 1 ⁇ .
- ⁇ when the matrix component is 1, the value of F ⁇ (i) is added to the calculation result so far (initial value is 2 ⁇ 2R 3 + R 4 ) regardless of the values of the random masks R 1 and R 2 Is done.
- the matrix component is ⁇ 1
- the value of F ⁇ (i) is subtracted from the calculation result so far, regardless of the values of the random masks R 1 and R 2 .
- redundancy is provided in the column direction of the matrix so that the number of elements in each row of the matrix becomes equal.
- the number of additions and subtractions in the non-linear operation using the row vector corresponding to the row can be made uniform for all rows of the matrix.
- the column vector is represented by a general solution including variables s and t.
- the above matrix is an example, and any matrix can be used as long as it is a matrix of M rows and N columns (M and N are integers of 4 or more, M ⁇ N) in which the number of elements in each row is the same.
- 2 ⁇ 2 in equation (5) may be 2 ⁇ k and the range of i may be 0 to N-1.
- This method makes the number of 1's and -1's in each row of the matrix uniform, so that it is safe for power analysis focusing on the type of operation. Note that it is possible to further increase the tolerance to power analysis by randomly changing the order of the subscript i of ⁇ to randomize the calculation order.
- FIG. 1 is a block diagram illustrating an example of a functional configuration of the arithmetic device 100 according to the first embodiment.
- the arithmetic device 100 includes an input / output unit 101, a variable storage unit 102, an intermediate result storage unit 103, a generation unit 104, a determination unit 105, and a calculation unit 106.
- the input / output unit 101 includes an input unit 101a and an output unit 101b.
- the input unit 101a receives an input value of an inverse element calculation (nonlinear calculation).
- the output unit 101b outputs an output value that is a result calculated with respect to the input value.
- variable storage unit 102 stores column vectors used for nonlinear calculations and various data necessary for control.
- the intermediate result storage unit 103 stores an intermediate result output in the course of nonlinear calculation.
- variable storage unit 102 and the intermediate result storage unit 103 can be configured by any commonly used storage medium such as an HDD (Hard Disk Drive), an optical disk, a memory card, and a RAM (Random Access Memory). .
- HDD Hard Disk Drive
- optical disk an optical disk
- memory card an optical disk
- RAM Random Access Memory
- the generation unit 104 generates a random number used in non-linear calculation.
- the determination unit 105 determines whether to perform addition or subtraction in a predetermined calculation in the nonlinear calculation according to the input value and the random number value.
- the arithmetic unit 106 performs an inverse operation corresponding to the above equation (4) by performing a bit operation, a logical operation, an arithmetic operation, and the like, and calculates an output value (inverse element) corresponding to the input value. Details of the inverse element calculation by the calculation unit 106 will be described later.
- FIG. 2 is a flowchart showing the overall flow of the arithmetic processing in the first embodiment.
- the input unit 101a receives Z to (2 bits) and R 1 (2 bits) as input values (step S101). Thereafter, the generation unit 104 generates random numbers R 2 (1 bit), R 3 (2 bits), and R 4 (2 bits) (step S102). Next, the calculation unit 106 calculates 2 ⁇ 2R 3 + R 4 and stores it in the intermediate result storage unit 103 (step S103).
- i 0, 1,..., 5 corresponding to each column of the matrix (or each row of the column vector) (steps S104 to S106).
- the order of i at this time may be any of ascending order, descending order, and random.
- the determination unit 105 takes i, Z ⁇ , R 1 , R 2 as inputs, and ( ⁇ 1) ⁇ ⁇ G ⁇ (i, Z ⁇ , R 1 , R 2 ) ⁇ becomes +1 or becomes ⁇ 1. It is determined whether or not (step S104).
- step S104 the calculation unit 106 adds F ⁇ (i) stored in the variable storage unit 102 and 2 ⁇ 2 to the intermediate result stored in the intermediate result storage unit 103. Add as a modulo (step S105).
- step S105 F ⁇ (i) stored in the variable storage unit 102 is subtracted from the intermediate result stored in the intermediate result storage unit 103 using 2 ⁇ 2 as a modulus.
- step S107 determines whether or not all the columns (i) have been processed. If not (step S107: NO), the next unprocessed column (i) is determined. The process is repeated (step S104).
- step S107 When calculation has been performed for all i (step S107: YES), the operation unit 106 truncates the lower 2 bits of the previous operation results stored in the intermediate result storage unit 103 (step S108). Then, the output unit 101b is the output value C is the result obtained, and R 2, and outputs the R 3 (step S109).
- the matrix and the column vector are determined in advance. That is, it is assumed that the function G used by the determination unit 105 in order to realize an operation corresponding to a matrix is predetermined.
- the column vectors are stored in the variable storage unit 102.
- the matrix and column vector expressions may be changed each time a nonlinear operation is calculated. That is, for each calculation, the function G used by the determination unit 105 can be changed, and a column vector corresponding to the new function G can be stored in the variable storage unit 102 to perform nonlinear calculation.
- FIG. 3 is a block diagram illustrating an example of a hardware configuration in which the functional configuration of FIG. 1 is implemented by hardware.
- the arithmetic device 100 includes an input unit 101a, generation units 104a, 104b, and 104c, a left shift unit 111, an addition unit 112, addition / subtraction units 113a to 113f, a right shift unit 114, And an output unit 101b.
- the generation units 104a, 104b, and 104c correspond to the generation unit 104 in FIG.
- a part of the functions of the left shift unit 111, the addition unit 112, the addition / subtraction units 113a to 113f, and the right shift unit 114 correspond to the calculation unit 106 in FIG.
- a part of the functions of the addition / subtraction units 113a to 113f corresponds to the determination unit 105 in FIG.
- F ⁇ (i) input to the addition / subtraction units 113a to 113f is stored in the variable storage unit 102 which is omitted in FIG.
- the input unit 101a accepts an input value of inverse element calculation (nonlinear calculation).
- the generation units 104a to 104c generate random numbers used in nonlinear calculations.
- the generation units 104a to 104c may be realized by the same device.
- the left shift unit 111 shifts input data to the left by 2 bits.
- the adder 112 adds the two input values modulo 2 ⁇ 2.
- the addition / subtraction units 113a to 113f perform addition or subtraction at 2 ⁇ 2 based on the input.
- the number of addition / subtraction units 113 is not limited to this, and an arbitrary number can be taken according to the number of columns of the matrix.
- the right shift unit 114 right-shifts the input value by 2 bits.
- the output unit 101b outputs data including an output value that is a result calculated for the input value.
- FIG. 4 is a flowchart showing the overall flow of arithmetic processing in the case of the hardware configuration of FIG.
- the input unit 101a accepts Z to (2 bits) and R 1 (2 bits) as input values (step S201). Thereafter, the generation units 104a, 104b, and 104c generate random numbers R 2 (1 bit), R 3 (2 bits), and R 4 (2 bits), respectively (step S202). Next, the left shift unit 111 shifts R 3 by 2 bits to the left, and the addition unit 112 calculates 2 ⁇ 2R 3 + R 4 by adding R4 and 2 ⁇ 2 modulo (step S203).
- i 0, 1,..., 5 corresponding to each column of the matrix (or each row of the column vector) (steps S204 to S206).
- the order of i at this time may be any of ascending order, descending order, and random.
- the addition / subtraction unit 113a receives i, Z ⁇ , R 1 , R 2 as inputs, and ( ⁇ 1) ⁇ ⁇ G ⁇ (i, Z ⁇ , R 1 , R 2 ) ⁇ becomes +1 or becomes ⁇ 1. It is determined whether or not (step S204). In the case of +1 (step S204: YES), the addition / subtraction unit 113a adds F ⁇ (i) to the calculation result so far, using 2 ⁇ 2 as a modulus (step S205). In the case of ⁇ 1 (step S204: NO), the addition / subtraction unit 113a subtracts F ⁇ (i) from 2 ⁇ 2 modulo the previous calculation result (step S206).
- step S207 NO
- step S207 NO
- step S207 NO
- step S207 NO
- step S207 NO
- step S207 NO
- step S207 it is described that it is determined in step S207 whether or not the process of the last addition / subtraction unit has been completed, but it is not actually necessary to execute such a determination process.
- step S207 When the processing by the adder / subtractor 113f is completed (step S207: YES), the right shift unit 114 truncates the lower 2 bits (step S208). Then, the output unit 101b is the output value C is the result obtained, and R 2, and outputs the R 3 (step S209).
- the arithmetic device by adjusting the number of elements included in each row of the matrix expressing the transformation of space, for example, the number of executions of each of addition and subtraction executed by non-linear calculation can be reduced. , Constant for all input values. For this reason, even if attention is paid to the feature of the operation processed according to the element, it is impossible to specify the input given to the non-linear operation circuit. Therefore, safety against power analysis can be improved. Further, since the data being calculated is disturbed using a random mask, a safer calculation device for power analysis can be realized.
- the number of elements in each row of the matrix is made uniform by adding columns in the column direction of the matrix.
- the arithmetic device according to the second embodiment compresses the column direction of the matrix so that the number of elements in each row of the matrix becomes uniform. At this time, a correction term (column vector) for appropriately performing the calculation is required.
- FIG. 5 is a block diagram illustrating an example of a functional configuration of the arithmetic device 200 according to the second embodiment.
- the arithmetic device 200 includes an input / output unit 101, a variable storage unit 202, an intermediate result storage unit 103, a generation unit 104, a determination unit 105, and a calculation unit 206.
- the information stored in the variable storage unit 202 and the function of the calculation unit 206 are different from those in the first embodiment. Since other configurations and functions are the same as those in FIG. 1 which is a block diagram showing the functional configuration of the arithmetic device 100 according to the first embodiment, the same reference numerals are given and description thereof is omitted here.
- the variable storage unit 202 stores column vectors used for non-linear calculations and various data necessary for control, as with the variable storage unit 102 of the first embodiment.
- the variable storage unit 202 is different from the variable storage unit 102 of the first embodiment in that, for example, a column vector format for obtaining an inner product with a matrix and a column vector serving as the correction term described above are further stored.
- the calculation unit 206 executes an inverse element calculation corresponding to an expression different from the above expression (4), and calculates an output value (inverse element) corresponding to the input value, so that the calculation unit 106 of the first embodiment. And different.
- the computing unit 206 performs an inverse element calculation of GF (2 ⁇ 2) by the following equation (8) expressed using a matrix in which the number of 1's and -1's in each row is 1, for example.
- the above matrix is an example, and any matrix can be used as long as the number of elements in each row is the same as that of M rows and N columns (M and N are integers of 2 or more, M> N).
- H ⁇ (Z ⁇ , R 1 ) can be calculated by ( ⁇ 1) ⁇ ⁇ R 2 ⁇ H (Z ⁇ (+) R 1 ).
- H ⁇ (Z ⁇ , R 1 ) itself is executed in the first embodiment, the third embodiment described later, and the fourth embodiment. Is also possible. Similarly to the first embodiment, it is possible to further increase the tolerance to power analysis by randomly changing the order of the subscript i of ⁇ and randomizing the calculation order.
- the number of 1's and -1's in each row of the matrix is made uniform by compressing the column direction. For this reason, it becomes safe with respect to the power analysis which paid its attention to the kind of calculation.
- the row direction of the matrix is compressed so that the number of elements in each row of the matrix is uniform.
- the output range for the input value is narrowed, a plurality of output values are assigned to each row, and necessary elements (output values) corresponding to the input values are extracted after the calculation.
- FIG. 6 is a block diagram illustrating an example of a functional configuration of the arithmetic device 300 according to the third embodiment.
- the arithmetic device 300 includes an input / output unit 101, a variable storage unit 302, an intermediate result storage unit 103, a generation unit 104, a determination unit 105, and a calculation unit 306.
- the information stored in the variable storage unit 302 and the function of the calculation unit 306 are different from those in the first embodiment. Since other configurations and functions are the same as those in FIG. 1 which is a block diagram showing the functional configuration of the arithmetic device 100 according to the first embodiment, the same reference numerals are given and description thereof is omitted here.
- the variable storage unit 302 stores column vectors used for non-linear calculations and various data necessary for control, as with the variable storage unit 102 of the first embodiment.
- the variable storage unit 302 differs from the variable storage unit 102 of the first embodiment in, for example, the format of a column vector for obtaining an inner product with a matrix.
- the calculation unit 306 performs an inverse element calculation corresponding to an expression different from the above expression (4), and calculates an output value (inverse element) corresponding to the input value, so that the calculation unit 106 according to the first embodiment. And different.
- the calculation unit 306 performs an inverse element calculation of GF (2 ⁇ 2) by the following equation (11) expressed using a matrix in which the number of 1's and -1's in each row is 2.
- the column vector is represented by a general solution including variables s and t.
- the above matrix is an example, and any matrix can be used as long as the number of elements in each row is the same as that of M rows and N columns (M and N are integers of 2 or more, M ⁇ N).
- F ( ⁇ Z, Z (+) 1 ⁇ ) (+) R 5 be C.
- the lower 2 bits of C are output as F (Z) (+) (R 5,1 R 5,0 ).
- the upper 2 bits of C are output as F (Z) (+) (R 5,3 R 5,2 ). In this way, a necessary output value corresponding to the input value can be extracted from the calculation result including a plurality of output values.
- the third embodiment is different from the first embodiment in that the upper 2 bits or the lower 2 bits are extracted from the result C obtained by the calculation according to the input value and used as the output value. Different. Since the flow of other arithmetic processing is the same as that of FIG. 2 showing the arithmetic processing of the first embodiment, description thereof is omitted.
- the number of 1's and -1's in each row of the matrix is made uniform by compressing the row direction. For this reason, it becomes safe with respect to the power analysis which paid its attention to the kind of calculation.
- FIG. 7 is a block diagram illustrating an example of a functional configuration of the arithmetic device 400 according to the fourth embodiment.
- the arithmetic device 400 includes an input / output unit 101, a variable storage unit 402, an intermediate result storage unit 103, a generation unit 104, a determination unit 105, and a calculation unit 406.
- the information stored in the variable storage unit 402 and the function of the calculation unit 406 are different from those in the first embodiment. Since other configurations and functions are the same as those in FIG. 1 which is a block diagram showing the functional configuration of the arithmetic device 100 according to the first embodiment, the same reference numerals are given and description thereof is omitted here.
- the variable storage unit 402 stores column vectors used for nonlinear calculations and various data necessary for control, as with the variable storage unit 102 of the first embodiment.
- the variable storage unit 302 is different from the variable storage unit 102 of the first embodiment in that, for example, a plurality of column vectors used for a plurality of matrix calculations are stored.
- the calculation unit 406 performs an inverse element calculation corresponding to an expression different from the above expression (4), and calculates an output value (inverse element) corresponding to the input value, so that the calculation unit 106 of the first embodiment. And different.
- the inverse element calculation by the calculation unit 406 is generally based on matrix calculation described by the following equation (14).
- A, B,... Are L (L is an integer of 1 or more) M rows and N columns (M, N are integers of 2 or more), a, b,.
- a predetermined constant value (scalar value), x, y,... represents a column vector of N rows determined in advance for each of L matrices.
- the calculation unit 406 includes, among the row vectors included in the L matrices, each of the L row vectors of the row corresponding to the input value, and N rows of columns that are predetermined for each of the L matrices.
- a linear sum of L values corresponding to the inner product with the vector is calculated.
- a matrix of 4 rows and 4 columns can be used as it is in addition to the matrix of the format described in each embodiment described above.
- equation (15) the sum of the number of 1s and the sum of the numbers of ⁇ 1 in each row of the two matrices is 4, respectively.
- FIG. 8 is an explanatory diagram of a hardware configuration example of the arithmetic devices according to the first to fourth embodiments.
- the arithmetic devices according to the first to fourth embodiments communicate with a control device such as a CPU (Central Processing Unit) 51 and a storage device such as a ROM (Read Only Memory) 52 and a RAM 53 by connecting to a network.
- a control device such as a CPU (Central Processing Unit) 51 and a storage device such as a ROM (Read Only Memory) 52 and a RAM 53 by connecting to a network.
- a communication I / F 54 to be performed and a bus 61 for connecting each unit are provided.
- Arithmetic programs executed by the arithmetic devices according to the first to fourth embodiments are provided by being incorporated in advance in the ROM 52 or the like.
- Arithmetic programs executed by the arithmetic devices are files in an installable format or executable format, such as a CD-ROM (Compact Disk Read Only Memory), a flexible disk (FD), You may comprise so that it may be provided as a computer program product recorded on computer-readable recording media, such as CD-R (Compact Disk Recordable) and DVD (Digital Versatile Disk).
- CD-ROM Compact Disk Read Only Memory
- FD flexible disk
- the arithmetic program executed by the arithmetic device according to the first to fourth embodiments is stored on a computer connected to a network such as the Internet and is provided by being downloaded via the network. May be.
- the arithmetic program executed by the arithmetic devices according to the first to fourth embodiments may be provided or distributed via a network such as the Internet.
- the arithmetic program executed by the arithmetic devices according to the first to fourth embodiments can cause the computer to function as each unit (input / output unit, generation unit, determination unit, arithmetic unit) of the above-described arithmetic device.
- the CPU 51 can read out an arithmetic program from a computer-readable storage medium onto a main storage device and execute it.
- the present invention is not limited to the above-described embodiment as it is, and can be embodied by modifying the constituent elements without departing from the scope of the invention in the implementation stage.
- various inventions can be formed by appropriately combining a plurality of constituent elements disclosed in the above embodiments. For example, some components may be deleted from all the components shown in the embodiment. Furthermore, constituent elements over different embodiments may be appropriately combined.
Landscapes
- Engineering & Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Complex Calculations (AREA)
Abstract
電力解析に対する安全性を向上させる。入力値を受付ける入力部101aと、L個(Lは1以上の整数)の予め定められたM行N列(M、Nは2以上の整数)の行列であって、行列の各行に含まれる要素それぞれの個数の和が、各行間で相互に等しい行列に含まれる行ベクトルのうち、入力値に対応するL個の行ベクトルそれぞれと、L個の行列ごとに予め定められたN行の第1列ベクトルとの内積に相当する値を算出し、算出した値に基づいて入力値に対する出力値を演算する演算部106と、出力値を出力する出力部101bとを備える。
Description
本発明は、演算装置に関する。
AES(Advanced Encryption Standard)に代表される秘密鍵ブロック暗号は、通信内容の秘匿などを目的として広範に用いられている。
近年、暗号回路の動作時の消費電力を観測することで、暗号回路内部で用いられている秘密鍵を推測する電力解析(Power Analysis)とよばれる攻撃手法が脅威となっている。電力解析では、攻撃者は平文(暗号装置への入力)と暗号文(暗号装置の出力)に基づき、暗号回路内部で用いられている鍵を予測して対応する中間データを計算する。その後、予測した中間データと暗号回路の消費電力との統計処理を行い、鍵の予測が正しいか否かを判定する。統計処理において、単一の消費電力波形を用いる手法は単純電力解析(Simple Power Analysis)とよばれ、複数の平文に対応する複数の消費電力波形を用いる手法は差分電力解析(Differential Power Analysis)とよばれる。
電力解析に対しては、暗号回路内部で発生させた乱数(ランダムマスク)を利用する、ランダムマスク法が有効な対策である。ランダムマスク法は、ランダムマスクで中間データと消費電力を撹乱し、攻撃者が予測する中間データと消費電力の関連を消すことで、解析を困難とする。
一方、秘密鍵ブロック暗号は、安全性を高めるために、処理の内部に非線形演算処理が用いられる。例えば、AESではSubByteとよばれる、8ビット入出力の非線形演算が用いられる。AESのSubByteは、有限体GF(以下、単にGFという)の逆元計算(元の定義ではGF(2^8)の逆元計算だが、回路規模を削減する目的で合成体を用いる場合にはGF(2^4)やGF(2^2)の逆元計算)とアフィン変換で計算される。SubByteは、それ自体を8ビットの入出力テーブルとして実装されるほか、有限体の逆元計算の部分をテーブルとして実装されることもある。
非線形演算では、本来の演算の入出力と整合するように、ランダムマスクによるデータの撹乱(マスク処理)とデータの補正(アンマスク処理)を行うことが困難であり、電力解析対策を施すには、特別な処理が必要となる。Coronらは、フーリエ変換を利用して、非線形演算を行う空間とは異なる空間のテーブルを用意し、後にアンマスク処理が容易に行えるようなランダムマスク法を提案している(例えば非特許文献1参照)。
Jean-Sebastien Coron、Christophe Giraud、Emmanuel Prouff、Matthieu Rivain、"Attack and Improvement of a Secure S-box Caluculation Based on the Fourier Transform",Cryptographic Hardware and Embedded Systems,CHES 2008,pp.1-14,Lecture Notes in Computer Science 5154,Springer-Verlag
しかしながら、Coronらの対策を用いる場合には、空間の変換を表現する行列で、各行が含む要素それぞれの個数が偏る。そのため、要素に応じて処理される演算の特徴に着目することにより、ランダムマスクの影響にかかわらず、非線形演算回路に特定の入力が与えられたか否かを判別できる可能性がある。このため、非線形演算回路に与えられた特定の入力および対応する平文から、秘密鍵を特定できるという問題が生じうる。
本発明は、上記に鑑みてなされたものであって、電力解析に対する安全性を向上させることができる演算装置を提供することを目的とする。
上述した課題を解決し、目的を達成するために、本発明は、入力値を受付ける入力部と、L個(Lは1以上の整数)の予め定められたM行N列(M、Nは2以上の整数)の行列であって、前記行列の各行に含まれる要素それぞれの個数の和が、各行間で相互に等しい前記行列に含まれる行ベクトルのうち、前記入力値に対応するL個の行ベクトルそれぞれと、L個の前記行列ごとに予め定められたN行の第1列ベクトルとの内積に相当するL個の値の線形和である出力値を演算する演算部と、前記出力値を出力する出力部と、を備えることを特徴とする。
本発明によれば、電力解析に対する安全性を向上させることができるという効果を奏する。
以下に添付図面を参照して、この発明にかかる演算装置の好適な実施の形態を詳細に説明する。
(第1の実施の形態)
第1の実施の形態にかかる演算装置は、Coronらの方法で用いる行列と比較して、列方向に冗長度を持たせた行列を用いることにより、行列の各行の要素それぞれの個数が同一となるようにする。なお、以下では、電力解析に対して安全となる、GF(2^2)の逆元計算(非線形演算)を行う演算装置を例に説明する。本実施の形態の方法は、GF(2^4)などの他の有限体での逆元計算や、一般の入出力テーブルでのデータ参照にも適用できる。
第1の実施の形態にかかる演算装置は、Coronらの方法で用いる行列と比較して、列方向に冗長度を持たせた行列を用いることにより、行列の各行の要素それぞれの個数が同一となるようにする。なお、以下では、電力解析に対して安全となる、GF(2^2)の逆元計算(非線形演算)を行う演算装置を例に説明する。本実施の形態の方法は、GF(2^4)などの他の有限体での逆元計算や、一般の入出力テーブルでのデータ参照にも適用できる。
最初に、Coronらの方法による問題点の詳細について説明する。
GF(2^2)の定義多項式x^2+x+1の根をαとするとき、0、1、2=α、3=α+1の逆元はそれぞれ0^{-1}=0、1^{-1}=1、2^{-1}=3、3^{-1}=2となる。フーリエ変換を用いるGF(2^2)の逆元計算は、以下の(1)式の行列計算に基づいて実行される。
例えば、2^{-1}を計算する場合には、入力値2に対して、第3行の行ベクトル(1 1 -1 -1)と列ベクトル(6 0 -4 -2)^Tの内積計算を行い、2^2で除した3を出力する。
Coronらの方法では、2ビットのランダムマスクR1が処理されたZ~=Z(+)R1が与えられたとき((+)は排他的論理和を表す)、Zを露呈することなくF(Z)を以下の(3)式で表される手順で計算する。
R2は1ビットのランダムマスク、R3とR4は2ビットのランダムマスクである。i・Z~とi・R1は、ベクトル同士の内積計算を表す。
このとき、(1)式の行列計算の4行4列の行列成分(行列の要素の値)の1と-1は、それぞれ(3)式の(-1)^{R2+i・Z~+i・R1}の+1と-1に対応している。Σの計算として、行列成分が1のときにはランダムマスクR1とR2の値に拠らずF^(i)の値がそれまでの計算結果(初期値は2^2R3+R4)に加算される。また、行列成分が-1のときにはランダムマスクR1とR2の値に拠らずF^(i)の値がそれまでの計算結果から減算される。
Coronらの方法では、4行4列の行列の第1行がすべて1であり、入力値が0の場合に限り、加算が4回実行される。行列のその他の行はすべて+1と-1を2個ずつ含むため、入力値が0ではないときには、加算と減算が2回ずつ実行される。したがって、演算に着目し、加算が4回実行される平文を探すことができれば、平文に基づいて非線形演算の入力値を0とする秘密鍵を特定することができる。例えば、加算と減算とに要する消費電力に着目すると、消費電力の違いから加算が4回の平文を探すことが可能である。
そこで、第1の実施の形態では、上述のように行列の列方向に冗長度をもたせて行列の各行の要素それぞれの個数が等しくなるようにする。これにより、行列のすべての行に対して、当該行に対応する行ベクトルを用いた非線形演算内での加算および減算の個数を均一化することができる。
このとき、列ベクトルは変数sとtを含む一般解で表される。例えばs=2、t=4とした列ベクトル(3 3 -1 1 2 4)^Tを用いることができる。なお、上記行列は一例であり、各行の要素それぞれの個数が同一であるM行N列(M、Nは4以上の整数、M<N)の行列であればあらゆる行列を用いることができる。
行列計算を以下の(5)式で表すとき、G(i,Z)は、i=(i2 i1 i0)(ビット表現)とZ(2ビット)とから、G(i,Z)=((Z==0)&i2)|((i2(+)1)&(i1 i0)・Z)などにより計算する。
なお、GF(2^k)の逆元計算の場合は、(5)式の2^2を2^k、iの範囲を0~N-1とすればよい。
ここで、G~(i,Z~,R1,R2)は、Z~=(z~1 z~2)(ビット表現)とR1=(R1,1 R1,0)(ビット表現)とした場合、G~(i,Z~,R1,R2)=R2(+)((i2(+)1)&((i1 i0)・Z~(+)(i1 i0)・R1))(+)(i2&(Z~==R1))で計算される。
このような方法により、行列の各行の1と-1の個数が均一化されるため、演算の種類に着目した電力解析に対して安全となる。なお、Σの添え字iの順番をランダムに変更して演算順序もランダム化することにより、電力解析に対する耐性をさらに高めることも可能である。
次に、第1の実施の形態にかかる演算装置の構成例について説明する。図1は、第1の実施の形態にかかる演算装置100の機能構成の一例を示すブロック図である。図1に示すように、演算装置100は、入出力部101と、変数記憶部102と、中間結果記憶部103と、生成部104と、判定部105と、演算部106とを備えている。
入出力部101は、入力部101aと、出力部101bとを備えている。入力部101aは、逆元演算(非線形演算)の入力値を受付ける。出力部101bは、入力値に対して演算された結果である出力値の出力を行う。
変数記憶部102は、非線形演算に用いる列ベクトルや制御に必要な各種データを記憶する。中間結果記憶部103は、非線形演算の過程で出力される中間結果を記憶する。
なお、変数記憶部102および中間結果記憶部103は、HDD(Hard Disk Drive)、光ディスク、メモリカード、RAM(Random Access Memory)などの一般的に利用されているあらゆる記憶媒体により構成することができる。
生成部104は、非線形演算で利用する乱数を生成する。判定部105は、入力値と乱数の値に応じて、非線形演算内の所定の演算で加算または減算のいずれを行うかを判定する。演算部106は、ビット演算、論理演算、および四則演算などを行うことにより、上記(4)式に相当する逆元演算を実行し、入力値に対応する出力値(逆元)を演算する。演算部106による逆元演算の詳細については後述する。
次に、このように構成された第1の実施の形態にかかる演算装置100による演算処理について図2を用いて説明する。図2は、第1の実施の形態における演算処理の全体の流れを示すフローチャートである。
まず、入力部101aが、Z~(2ビット)とR1(2ビット)とを入力値として受け付ける(ステップS101)。その後、生成部104が、乱数R2(1ビット)、R3(2ビット)、およびR4(2ビット)を生成する(ステップS102)。次に、演算部106が、2^2R3+R4を計算し、中間結果記憶部103に記憶する(ステップS103)。
次に、上記行列の各列(または上記列ベクトルの各行)に対応するi=0,1,・・・,5について、以下の処理が実行される(ステップS104~ステップS106)。なお、このときのiの順番は昇順、降順、ランダムのいずれでもよい。
まず、判定部105が、i、Z~、R1、R2を入力として、(-1)^{G~(i、Z~、R1、R2)}が+1になるか-1になるかを判定する(ステップS104)。
+1の場合には(ステップS104:YES)、演算部106が、変数記憶部102に記憶されているF^(i)を、中間結果記憶部103に記憶されている中間結果に2^2を法として加算する(ステップS105)。-1の場合には(ステップS104:NO)、変数記憶部102に記憶されているF^(i)を、中間結果記憶部103に記憶されている中間結果から2^2を法として減算する(ステップS106)。
次に、判定部105が、すべての列(i)を処理したか否かを判定し(ステップS107)、処理していない場合(ステップS107:NO)、次の未処理の列(i)について処理を繰り返す(ステップS104)。
すべてのiについて計算を行ったら(ステップS107:YES)、演算部106が、中間結果記憶部103に記憶されているこれまでの演算結果の下位2ビットを切り捨てる(ステップS108)。次に、出力部101bが、得られた結果である出力値Cと、R2と、R3とを出力する(ステップS109)。
上述の方法では、行列と列ベクトルは予め定められているものとしている。すなわち、行列に相当する演算を実現するために判定部105が用いる関数Gは予め定められているものとしている。また、列ベクトルは変数記憶部102に記憶されているものとしている。これに対し、非線形演算を計算するたびに、行列および列ベクトルの表現を変更するように構成してもよい。すなわち演算ごとに、判定部105が用いる関数Gを変更するとともに、新たな関数Gに応じた列ベクトルを変数記憶部102に記憶して、非線形演算を行うことも可能である。
次に、図1のような機能構成をハードウェアにより実装する場合の構成例について図3を用いて説明する。図3は、図1の機能構成をハードウェア実装したハードウェア構成の一例を示すブロック図である。
図3に示すように、演算装置100は、入力部101aと、生成部104a、104b、104cと、左シフト部111と、加算部112と、加減算部113a~113fと、右シフト部114と、出力部101bとを備えている。
生成部104a、104b、104cは、図1の生成部104に相当する。左シフト部111、加算部112、加減算部113a~113fの機能の一部、および、右シフト部114が、図1の演算部106に相当する。加減算部113a~113fの機能の一部が、図1の判定部105に相当する。なお、加減算部113a~113fに入力されるF^(i)は、図3では省略されている変数記憶部102に記憶されている。
入力部101aは、逆元演算(非線形演算)の入力値を受付ける。生成部104a~104cは、非線形演算で利用する乱数を生成する。生成部104a~104cは同一の装置により実現されてもよい。左シフト部111は、入力されたデータを2ビット左シフトする。加算部112は、入力された2つの値を2^2を法として加算する。加減算部113a~113fは、入力に基づいて、2^2での加算または減算を行う。なお、図3では、上記(4)式の行列の列数(=6)に対応して6個の加減算部113a~113fを備える例が示されている。加減算部113の個数はこれに限られず、行列の列数に応じて任意の個数を取りうる。右シフト部114は、入力された値を2ビット右シフトする。出力部101bは、入力値に対して演算された結果である出力値を含むデータを出力する。
次に、図3のようなハードウェア構成の場合の演算処理について説明する。図4は、図3のハードウェア構成の場合の演算処理の全体の流れを示すフローチャートである。
まず、入力部101aが、Z~(2ビット)とR1(2ビット)を入力値として受け付ける(ステップS201)。その後、生成部104a、104b、および104cが、それぞれ乱数R2(1ビット)、R3(2ビット)、R4(2ビット)を生成する(ステップS202)。次に、左シフト部111がR3を2ビット左シフトし、加算部112がR4と2^2を法として加算することにより、2^2R3+R4を計算する(ステップS203)。
次に、上記行列の各列(または上記列ベクトルの各行)に対応するi=0,1,・・・,5について、以下の処理が実行される(ステップS204~ステップS206)。なお、このときのiの順番は昇順、降順、ランダムのいずれでもよい。
まず、加減算部113aが、i、Z~、R1、R2を入力として、(-1)^{G~(i、Z~、R1、R2)}が+1になるか-1になるかを判定する(ステップS204)。+1の場合には(ステップS204:YES)、加減算部113aは、F^(i)を、それまでの計算結果に2^2を法として加算する(ステップS205)。-1の場合には(ステップS204:NO)、加減算部113aは、F^(i)を、それまでの計算結果に2^2を法として減算する(ステップS206)。
次に、ステップS204~ステップS206までの処理が、加減算部113b~加減算部113fにより順次実行される。すなわち、最後に処理を実行する加減算部113bの処理が終了していない場合には(ステップS207:NO)、次の加減算部にそれまでの計算結果が入力され、処理が繰り返される(ステップS204)。なお、図4では、説明の便宜上、ステップS207で最後の加減算部の処理が終了したかが判定されることが記載されているが、実際にはこのような判定処理が実行される必要はない。加減算部113fによる処理が終了すると(ステップS207:YES)、右シフト部114が、下位2ビットを切り捨てる(ステップS208)。次に、出力部101bが、得られた結果である出力値Cと、R2と、R3とを出力する(ステップS209)。
このように、第1の実施の形態にかかる演算装置では、空間の変換を表現する行列の各行が含む要素の数を揃えることにより、例えば非線形演算により実行される加算および減算それぞれの実行回数が、すべての入力値に対して一定となる。このため、要素に応じて処理される演算の特徴に着目したとしても、非線形演算回路に与えられた入力を特定することを不可能とする。したがって、電力解析に対する安全性を向上させることができる。また、ランダムマスクを利用して演算中のデータを撹乱するため、電力解析に対してより安全な演算装置を実現できる。
(第2の実施の形態)
第1の実施の形態では、行列の列方向に列を追加することにより行列の各行の要素それぞれの個数が均一となるようにしていた。第2の実施の形態にかかる演算装置は、行列の列方向を圧縮し、行列の各行の要素それぞれの個数が均一となるようにする。このとき、演算を適切に行うための補正項(列ベクトル)が必要となる。
第1の実施の形態では、行列の列方向に列を追加することにより行列の各行の要素それぞれの個数が均一となるようにしていた。第2の実施の形態にかかる演算装置は、行列の列方向を圧縮し、行列の各行の要素それぞれの個数が均一となるようにする。このとき、演算を適切に行うための補正項(列ベクトル)が必要となる。
図5は、第2の実施の形態にかかる演算装置200の機能構成の一例を示すブロック図である。図5に示すように、演算装置200は、入出力部101と、変数記憶部202と、中間結果記憶部103と、生成部104と、判定部105と、演算部206とを備えている。
第2の実施の形態では、変数記憶部202に記憶する情報、および、演算部206の機能が第1の実施の形態と異なっている。その他の構成および機能は、第1の実施の形態にかかる演算装置100の機能構成を表すブロック図である図1と同様であるので、同一符号を付し、ここでの説明は省略する。
変数記憶部202は、第1の実施の形態の変数記憶部102と同様に、非線形演算に用いる列ベクトルや制御に必要な各種データを記憶する。変数記憶部202は、例えば、行列との内積を求める列ベクトルの形式、および、上述の補正項となる列ベクトルをさらに記憶する点が、第1の実施の形態の変数記憶部102と異なる。
演算部206は、上記(4)式と異なる式に相当する逆元演算を実行し、入力値に対応する出力値(逆元)を演算する点が、第1の実施の形態の演算部106と異なる。演算部206は、例えば、各行の1と-1の個数がそれぞれ1である行列を用いて表される以下の(8)式によりGF(2^2)の逆元計算を行う。
なお、上記行列は一例であり、各行の要素それぞれの個数が同一であるM行N列(M、Nは2以上の整数、M>N)の行列であればあらゆる行列を用いることができる。
行列計算を、以下の(9)式で表すとき、G(i,Z)は、i(1ビット)とZ=(z1 z0)(ビット表現)とから、G(i,Z)=i(+)1(+)z0などにより計算する。H(Z)は、補正項の列ベクトル(1 0 4 1)^Tを表す。
ここで、G~(i,Z~,R1,R2)は、Z~=(z~1 z~2)(ビット表現)とR1=(R1,1R1,0)(ビット表現)とした場合、G~(i,Z~,R1,R2)=R2(+)i(+)1(+)z~0(+)R1,0で計算される。H~(Z~,R1)は、(-1)^{R2}H(Z~(+)R1)で計算することができる。
なお、電力解析耐性を高めるために、H~(Z~,R1)の演算自体を、第1の実施の形態、後述する第3の実施の形態および第4の実施の形態で実行することも可能である。また、第1の実施の形態と同様に、Σの添え字iの順番をランダムに変更し、演算順序もランダム化することにより、電力解析に対する耐性をさらに高めることも可能である。
第2の実施の形態による演算処理の全体の流れは第1の実施の形態の演算処理を表す図2と同様であるため、説明を省略する。なお、上記(8)式を用いる場合、第2の実施の形態の演算処理は、行列の列数に応じた繰り返し処理(ステップS104~ステップS107)の回数が第1の実施の形態と異なるのみである。すなわち、第1の実施の形態では、行列の列数(=6)に対応して6回処理を繰り返したのに対し、第2の実施の形態では、(8)式の行列の列数(=2)に対応して2回だけ処理を繰り返す点が異なる。
このように、第2の実施の形態にかかる演算装置では、列方向を圧縮することにより行列の各行の1と-1の個数を均一化する。このため、演算の種類に着目した電力解析に対して安全となる。
(第3の実施の形態)
第3の実施の形態では、行列の行方向を圧縮し、行列の各行の要素それぞれの個数が均一となるようにする。このとき、入力値に対する出力範囲が狭まるため、各行に複数の出力値を割り当てて、計算後に入力値に対応する必要な要素(出力値)を取り出す。
第3の実施の形態では、行列の行方向を圧縮し、行列の各行の要素それぞれの個数が均一となるようにする。このとき、入力値に対する出力範囲が狭まるため、各行に複数の出力値を割り当てて、計算後に入力値に対応する必要な要素(出力値)を取り出す。
図6は、第3の実施の形態にかかる演算装置300の機能構成の一例を示すブロック図である。図6に示すように、演算装置300は、入出力部101と、変数記憶部302と、中間結果記憶部103と、生成部104と、判定部105と、演算部306とを備えている。
第3の実施の形態では、変数記憶部302に記憶する情報、および、演算部306の機能が第1の実施の形態と異なっている。その他の構成および機能は、第1の実施の形態にかかる演算装置100の機能構成を表すブロック図である図1と同様であるので、同一符号を付し、ここでの説明は省略する。
変数記憶部302は、第1の実施の形態の変数記憶部102と同様に、非線形演算に用いる列ベクトルや制御に必要な各種データを記憶する。変数記憶部302は、例えば、行列との内積を求める列ベクトルの形式が、第1の実施の形態の変数記憶部102と異なる。
演算部306は、上記(4)式と異なる式に相当する逆元演算を実行し、入力値に対応する出力値(逆元)を演算する点が、第1の実施の形態の演算部106と異なる。演算部306は、例えば、各行の1と-1の個数がそれぞれ2である行列を用いて表される以下の(11)式によりGF(2^2)の逆元計算を行う。
このとき、列ベクトルは変数sとtを含む一般解で表される。例えばs=3、t=4とした列ベクトル(33 4 3 30)^Tを用いることができる。なお、上記行列は一例であり、各行の要素それぞれの個数が同一であるM行N列(M、Nは2以上の整数、M<N)の行列であればあらゆる行列を用いることができる。
なお、F({Z,Z(+)1})は、複数の入力値が1つの行に対応することを表している({}を集合を表わす意味で用いる)。例えば、Z=0の場合、0と1との排他的論理和(0(+)1)が1であるため、F(Z,Z(+)1)は、F({0,1})を意味する。これは、例えば逆元演算の結果であるベクトルの1行目に対応する。そして、例えば、Z=1の場合、1と1との排他的論理和(1(+)1)が0であるため、F({Z,Z(+)1})は、F({1,0})=F({0,1})を意味する。この場合も、逆元演算の結果であるベクトルの1行目に対応するものとしている。すなわち、2つの入力値であるZ=0,1が、演算結果のベクトルの1行目に対応している。
ここで、G~(i,Z~,R1,R2)は、Z~=(z~1 z~0)(ビット表現)とR1=(R1,1 R1,0)(ビット表現)とした場合、G~(i,Z~,R1,R2)=R2(+)i・(1 z~1)(+)i・(0 R1,1)で計算される。
(-1)^{R2}F({Z,Z(+)1})+R3を計算した後、算術的に加算されているランダムマスクR2とR3を、排他的論理和により演算されるランダムマスクR5=(R5,3 R5,2 R5,1 R5,0)(4ビット)に置き換える(例えば、Louis Goubin、“A Sound Method for Switching between Boolean and Arithmetic Masking”,Cryptographic Hardware and Embedded Systems,CHES 2001,pp.3-15,Lecture Notes in Computer Science 2162,Springer-Verlagを参照)。
まず、F({Z,Z(+)1})(+)R5をCとおく。z~0(+)R1,0が1のときには、Cの下位2ビットをF(Z)(+)(R5,1 R5,0)として出力する。z~0(+)R1,0が0のときには、Cの上位2ビットをF(Z)(+)(R5,3 R5,2)として出力する。このようにして、複数の出力値を含む計算結果から、入力値に対応する必要な出力値を取り出すことができる。
このように、第3の実施の形態では、演算により得られた結果Cから、入力値に応じて上位2ビットまたは下位2ビットを取り出して出力値とする点が、第1の実施の形態と異なる。その他の演算処理の流れは第1の実施の形態の演算処理を表す図2と同様であるため、説明を省略する。
以上のように、第3の実施の形態にかかる演算装置では、行方向を圧縮することにより行列の各行の1と-1の個数を均一化する。このため、演算の種類に着目した電力解析に対して安全となる。
(第4の実施の形態)
第1~第3の実施の形態では、1つの行列を用いた非線形演算について説明した。第4の実施の形態では、複数の行列計算を組み合わせることにより、演算の数を均一とする。
第1~第3の実施の形態では、1つの行列を用いた非線形演算について説明した。第4の実施の形態では、複数の行列計算を組み合わせることにより、演算の数を均一とする。
図7は、第4の実施の形態にかかる演算装置400の機能構成の一例を示すブロック図である。図7に示すように、演算装置400は、入出力部101と、変数記憶部402と、中間結果記憶部103と、生成部104と、判定部105と、演算部406とを備えている。
第4の実施の形態では、変数記憶部402に記憶する情報、および、演算部406の機能が第1の実施の形態と異なっている。その他の構成および機能は、第1の実施の形態にかかる演算装置100の機能構成を表すブロック図である図1と同様であるので、同一符号を付し、ここでの説明は省略する。
変数記憶部402は、第1の実施の形態の変数記憶部102と同様に、非線形演算に用いる列ベクトルや制御に必要な各種データを記憶する。変数記憶部302は、例えば、複数の行列計算に用いる複数の列ベクトルを保存する点が、第1の実施の形態の変数記憶部102と異なる。
演算部406は、上記(4)式と異なる式に相当する逆元演算を実行し、入力値に対応する出力値(逆元)を演算する点が、第1の実施の形態の演算部106と異なる。演算部406による逆元演算は、一般には、以下の(14)式で記述される行列計算に基づく。
A、B、・・・はL個(Lは1以上の整数)のM行N列(M、Nは2以上の整数)の行列、a、b、・・・はL個の行列ごとに予め定められた定数値(スカラー値)、x、y、・・・はL個の行列ごとに予め定められたN行の列ベクトルを表す。このように、演算部406は、L個の行列に含まれる行ベクトルのうち、入力値に対応する行のL個の行ベクトルそれぞれと、L個の行列ごとに予め定められたN行の列ベクトルとの内積に相当するL個の値の線形和を演算する。A、B、・・・は、上述した各実施の形態で説明する形式の行列に加え、4行4列の行列をそのまま用いることも可能である。
例えば、1ビットのデータsと、4行4列の2つの行列とを用いて、以下の(15)式のように逆元演算を実行することができる。(15)式では、2つの行列の各行の1の個数の和、および-1の個数の和は、それぞれ4個となる。
(a/2^2)Ax、(b/2^2)By、・・・のような上記(14)式の各項の計算を、Coronらの方法または上記各実施の形態の方法で計算することにより、電力解析に対して安全性をもたせつつ、暗号回路の非線形演算を実行できる。
なお、上記行列は一例であり、L個の行列の各行の要素それぞれの個数の和が同一となるM行N列の行列であればあらゆる行列を用いることができる。
次に、第1~第4の実施の形態にかかる演算装置の機能構成をソフトウェアにより実装する場合の、演算装置のハードウェア構成例について図8を用いて説明する。図8は、第1~第4の実施の形態にかかる演算装置のハードウェア構成例を示す説明図である。
第1~第4の実施の形態にかかる演算装置は、CPU(Central Processing Unit)51などの制御装置と、ROM(Read Only Memory)52やRAM53などの記憶装置と、ネットワークに接続して通信を行う通信I/F54と、各部を接続するバス61を備えている。
第1~第4の実施の形態にかかる演算装置で実行される演算プログラムは、ROM52等に予め組み込まれて提供される。
第1~第4の実施の形態にかかる演算装置で実行される演算プログラムは、インストール可能な形式又は実行可能な形式のファイルでCD-ROM(Compact Disk Read Only Memory)、フレキシブルディスク(FD)、CD-R(Compact Disk Recordable)、DVD(Digital Versatile Disk)等のコンピュータで読み取り可能な記録媒体に記録されたコンピュータプログラムプロダクトとして提供されるように構成してもよい。
さらに、第1~第4の実施の形態にかかる演算装置で実行される演算プログラムを、インターネット等のネットワークに接続されたコンピュータ上に格納し、ネットワーク経由でダウンロードさせることにより提供するように構成してもよい。また、第1~第4の実施の形態にかかる演算装置で実行される演算プログラムをインターネット等のネットワーク経由で提供または配布するように構成してもよい。
第1~第4の実施の形態にかかる演算装置で実行される演算プログラムは、コンピュータを上述した演算装置の各部(入出力部、生成部、判定部、演算部)として機能させうる。このコンピュータは、CPU51がコンピュータ読取可能な記憶媒体から演算プログラムを主記憶装置上に読み出して実行することができる。
なお、本発明は、上記実施の形態そのままに限定されるものではなく、実施段階ではその要旨を逸脱しない範囲で構成要素を変形して具体化することができる。また、上記実施の形態に開示されている複数の構成要素の適宜な組み合わせにより、種々の発明を形成することができる。例えば、実施の形態に示される全構成要素からいくつかの構成要素を削除してもよい。さらに、異なる実施の形態にわたる構成要素を適宜組み合わせても良い。
51 CPU
52 ROM
53 RAM
54 通信I/F
61 バス
100、200、300、400 演算装置
101 入出力部
101a 入力部
101b 出力部
102、202、302、402 変数記憶部
103 中間結果記憶部
104 生成部
105 判定部
106、206、306、406 演算部
52 ROM
53 RAM
54 通信I/F
61 バス
100、200、300、400 演算装置
101 入出力部
101a 入力部
101b 出力部
102、202、302、402 変数記憶部
103 中間結果記憶部
104 生成部
105 判定部
106、206、306、406 演算部
Claims (6)
- 入力値を受付ける入力部と、
L個(Lは1以上の整数)の予め定められたM行N列(M、Nは2以上の整数)の行列であって、前記行列の各行に含まれる要素それぞれの個数の和が、各行間で相互に等しい前記行列に含まれる行ベクトルのうち、前記入力値に対応するL個の行ベクトルそれぞれと、L個の前記行列ごとに予め定められたN行の第1列ベクトルとの内積に相当するL個の値の線形和である出力値を演算する演算部と、
前記出力値を出力する出力部と、
を備えることを特徴とする演算装置。 - 前記演算部は、1個のM<Nを満たすM行N列の前記行列に含まれる行ベクトルのうち、前記入力値に対応する行ベクトルとN行の前記第1列ベクトルとの内積に相当する前記出力値を演算すること、
を特徴とする請求項1に記載の演算装置。 - 前記演算部は、1個のM>Nを満たすM行N列の前記行列に含まれる行ベクトルのうち、前記入力値に対応する行ベクトルとN行の前記第1列ベクトルとの内積に相当する前記出力値を演算すること、
を特徴とする請求項1に記載の演算装置。 - 前記演算部は、1個のM>Nを満たすM行N列の前記行列に含まれる行ベクトルのうち、前記入力値に対応する行ベクトルとN行の前記第1列ベクトルとの内積に相当する値値に、予め定められたN行の第2列ベクトルの要素のうち、前記入力値に対応する要素の値を加算した前記出力値を演算すること、
を特徴とする請求項1に記載の演算装置。 - 前記演算部は、1個のM<Nを満たすM行N列の前記行列に含まれる行ベクトルのうち、前記入力値に対応する行ベクトルとN行の前記第1列ベクトルとの内積に相当する前記出力値を演算し、
前記出力部は、前記出力値を表すビット列のうち、前記入力値に対応する一部のビット列で表される前記出力値を出力すること、
を特徴とする請求項1に記載の演算装置。 - 前記演算部は、L個のM行N列の前記行列に含まれる行ベクトルのうち、前記入力値に対応するL個の行ベクトルそれぞれと前記第1列ベクトルとの内積に相当する値を算出し、算出した値にL個の前記行列ごとに予め定められた定数値を乗じて算出されるL個の値の線形和である前記出力値を演算すること、
を特徴とする請求項1に記載の演算装置。
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
PCT/JP2009/066538 WO2011036747A1 (ja) | 2009-09-24 | 2009-09-24 | 演算装置 |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
PCT/JP2009/066538 WO2011036747A1 (ja) | 2009-09-24 | 2009-09-24 | 演算装置 |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2011036747A1 true WO2011036747A1 (ja) | 2011-03-31 |
Family
ID=43795518
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/JP2009/066538 Ceased WO2011036747A1 (ja) | 2009-09-24 | 2009-09-24 | 演算装置 |
Country Status (1)
Country | Link |
---|---|
WO (1) | WO2011036747A1 (ja) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104426653A (zh) * | 2013-08-30 | 2015-03-18 | 上海复旦微电子集团股份有限公司 | 一种数据处理方法和装置 |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH052898A (ja) * | 1991-06-24 | 1993-01-08 | Mitsubishi Electric Corp | 半導体記憶装置 |
JP2006018747A (ja) * | 2004-07-05 | 2006-01-19 | Casio Comput Co Ltd | 行列表示制御装置及びプログラム |
WO2008146482A1 (ja) * | 2007-05-30 | 2008-12-04 | Panasonic Corporation | 暗号化装置、復号化装置、暗号化方法及び集積回路 |
-
2009
- 2009-09-24 WO PCT/JP2009/066538 patent/WO2011036747A1/ja not_active Ceased
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH052898A (ja) * | 1991-06-24 | 1993-01-08 | Mitsubishi Electric Corp | 半導体記憶装置 |
JP2006018747A (ja) * | 2004-07-05 | 2006-01-19 | Casio Comput Co Ltd | 行列表示制御装置及びプログラム |
WO2008146482A1 (ja) * | 2007-05-30 | 2008-12-04 | Panasonic Corporation | 暗号化装置、復号化装置、暗号化方法及び集積回路 |
Non-Patent Citations (1)
Title |
---|
JEAN-SEBASTIEN CORON ET AL.: "Attack and Improvement of a Secure S-Box Calculation Based on the Fourier Transform", CHES2008, 2008, pages 1 - 14, XP047029781, Retrieved from the Internet <URL:http://www.jscoron.fr/publications/fourier.pdf> [retrieved on 20091029] * |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104426653A (zh) * | 2013-08-30 | 2015-03-18 | 上海复旦微电子集团股份有限公司 | 一种数据处理方法和装置 |
CN104426653B (zh) * | 2013-08-30 | 2017-12-15 | 上海复旦微电子集团股份有限公司 | 一种数据处理方法和装置 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP5242560B2 (ja) | 暗号化装置、復号化装置、暗号化方法及び集積回路 | |
US20070140478A1 (en) | Encryption apparatus and encryption method | |
JP5229315B2 (ja) | 共通鍵暗号機能を搭載した暗号化装置及び組込装置 | |
JP5711681B2 (ja) | 暗号処理装置 | |
RU2449482C2 (ru) | Устройство обработки шифрования, способ обработки шифрования и компьютерная программа | |
JP2000066585A (ja) | 暗号化・復号装置、暗号化・復号方法、およびそのプログラム記憶媒体 | |
US8199909B2 (en) | Method and device for carrying out a cryptographic calculation | |
CA2717622A1 (en) | White-box implementation | |
JP4837058B2 (ja) | 演算装置及びプログラム | |
WO2010067827A1 (ja) | 暗号処理装置及び演算方法 | |
KR20110014630A (ko) | 지수 불명료화 | |
JP6916770B2 (ja) | 秘匿計算装置、秘匿計算方法及び秘匿計算プログラム | |
JP2020064461A (ja) | 変換装置、変換方法、変換プログラム及び難読プログラム | |
US8538017B2 (en) | Encryption device | |
KR20100079060A (ko) | 마스킹이 적용된 seed를 이용한 암호화 방법 | |
Schamberger et al. | Practical evaluation of masking for ntruencrypt on arm cortex-m4 | |
RU2188513C2 (ru) | Способ криптографического преобразования l-битовых входных блоков цифровых данных в l-битовые выходные блоки | |
JP2022038811A (ja) | 暗号処理装置、暗号処理方法およびプログラム | |
WO2011036747A1 (ja) | 演算装置 | |
JP5500277B2 (ja) | 共通鍵暗号機能を搭載した暗号化装置及び組込装置 | |
Alarcón-Narváez et al. | Towards a symmetric crypto algorithm: The HAJ | |
JP5354914B2 (ja) | 暗号処理装置及び復号処理装置及びプログラム | |
JP6876423B2 (ja) | ストリーム暗号における内部状態の初期化装置、方法及びプログラム | |
JP2006201641A (ja) | 非線形演算装置及び暗号処理装置及び非線形演算方法及び非線形演算プログラム | |
JP6371197B2 (ja) | 暗号処理装置 |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 09849778 Country of ref document: EP Kind code of ref document: A1 |
|
NENP | Non-entry into the national phase |
Ref country code: DE |
|
122 | Ep: pct application non-entry in european phase |
Ref document number: 09849778 Country of ref document: EP Kind code of ref document: A1 |
|
NENP | Non-entry into the national phase |
Ref country code: JP |