KR101136972B1 - method for evaluating Elliptic Curve Cryptosystem - Google Patents

method for evaluating Elliptic Curve Cryptosystem Download PDF

Info

Publication number
KR101136972B1
KR101136972B1 KR1020090048259A KR20090048259A KR101136972B1 KR 101136972 B1 KR101136972 B1 KR 101136972B1 KR 1020090048259 A KR1020090048259 A KR 1020090048259A KR 20090048259 A KR20090048259 A KR 20090048259A KR 101136972 B1 KR101136972 B1 KR 101136972B1
Authority
KR
South Korea
Prior art keywords
value
elliptic curve
multiplication
finite field
register
Prior art date
Application number
KR1020090048259A
Other languages
Korean (ko)
Other versions
KR20100067590A (en
Inventor
최용제
최두호
정교일
Original Assignee
한국전자통신연구원
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 한국전자통신연구원 filed Critical 한국전자통신연구원
Publication of KR20100067590A publication Critical patent/KR20100067590A/en
Application granted granted Critical
Publication of KR101136972B1 publication Critical patent/KR101136972B1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F7/00Methods or arrangements for processing data by operating upon the order or content of the data handled
    • G06F7/60Methods or arrangements for performing computations using a digital non-denominational number representation, i.e. number representation without radix; Computing devices using combinations of denominational and non-denominational quantity representations, e.g. using difunction pulse trains, STEELE computers, phase computers
    • G06F7/72Methods or arrangements for performing computations using a digital non-denominational number representation, i.e. number representation without radix; Computing devices using combinations of denominational and non-denominational quantity representations, e.g. using difunction pulse trains, STEELE computers, phase computers using residue arithmetic
    • G06F7/724Finite field arithmetic
    • G06F7/725Finite field arithmetic over elliptic curves
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F5/00Methods or arrangements for data conversion without changing the order or content of the data handled
    • G06F5/01Methods or arrangements for data conversion without changing the order or content of the data handled for shifting, e.g. justifying, scaling, normalising
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F7/00Methods or arrangements for processing data by operating upon the order or content of the data handled
    • G06F7/38Methods or arrangements for performing computations using exclusively denominational number representation, e.g. using binary, ternary, decimal representation
    • G06F7/48Methods or arrangements for performing computations using exclusively denominational number representation, e.g. using binary, ternary, decimal representation using non-contact-making devices, e.g. tube, solid state device; using unspecified devices
    • G06F7/52Multiplying; Dividing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F7/00Methods or arrangements for processing data by operating upon the order or content of the data handled
    • G06F7/60Methods or arrangements for performing computations using a digital non-denominational number representation, i.e. number representation without radix; Computing devices using combinations of denominational and non-denominational quantity representations, e.g. using difunction pulse trains, STEELE computers, phase computers
    • G06F7/72Methods or arrangements for performing computations using a digital non-denominational number representation, i.e. number representation without radix; Computing devices using combinations of denominational and non-denominational quantity representations, e.g. using difunction pulse trains, STEELE computers, phase computers using residue arithmetic
    • G06F7/724Finite field arithmetic
    • G06F7/726Inversion; Reciprocal calculation; Division of elements of a finite field

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Computational Mathematics (AREA)
  • Mathematical Analysis (AREA)
  • Mathematical Optimization (AREA)
  • Pure & Applied Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Complex Calculations (AREA)

Abstract

타원곡선 암호화를 위한 유한체 중 GF(P) 상의 소수 유한체의 곱셈 및 역승산 연산 방법이 제공된다. 본 발명의 실시예에 의한 유한체 곱셈 방법은 피승수와 승수를 일정 크기의 비트 단위로 구분하여 곱하는 단계와, 상기 곱셈 결과를 미리 저장된 이전 단계의 유한체 연산 결과와 더하는 단계 및 상기 덧셈 결과를 리덕션하는 단계를 포함한다.A method for multiplying and inverse multiplication of prime finite bodies on GF (P) among finite bodies for elliptic curve encryption is provided. In the finite field multiplication method according to an embodiment of the present invention, multiplying a multiplier and a multiplier by a predetermined bit unit, adding the multiplication result to a prestored finite field operation result, and reducing the addition result. It includes a step.

타원곡선, 유한체, GF(P), 곱셈, 역승산 Elliptic Curve, Finite Field, GF (P), Multiplication, Inverse Multiplication

Description

타원곡선 암호 연산 방법{method for evaluating Elliptic Curve Cryptosystem}Method for evaluating Elliptic Curve Cryptosystem

본 발명의 실시예는 타원곡선 암호화를 위한 유한체 중 GF(P) 상의 소수 유한체의 곱셈 및 역승산 연산 방법에 관한 것이다.Embodiments of the present invention relate to a multiplication and inverse multiplication method of prime finite bodies on GF (P) among finite bodies for elliptic curve encryption.

본 발명은 지식경제부 및 정보통신연구진흥원의 IT성장동력기술개발의 일환으로 수행한 연구로부터 도출된 것이다[과제관리번호: 2005-S-088-04, 과제명: 안전한 RFID/USN을 위한 정보보호 기술 개발].The present invention is derived from the research conducted as part of the IT growth engine technology development of the Ministry of Knowledge Economy and the Ministry of Information and Telecommunication Research and Development. [Task Management Number: 2005-S-088-04, Title: Information Protection for Secure RFID / USN] Technology development].

1980년대 중반 Victor Miller와 Neal Kobliz에 의해 제안된 타원곡선 암호 시스템(Elliptic Curve Cryptosystem; ECC)은 RSA나 ElGamal과 같은 다른 암호 시스템에 비해 현저히 작은 키를 사용하면서(약 1/6 정도) 동일한 안전도를 가진다. 작은 키를 사용한다는 것은 계산 시간, 전력 소모 그리고 저장 공간의 감소를 의미한다. The Elliptic Curve Cryptosystem (ECC), proposed by Victor Miller and Neal Kobliz in the mid-1980s, uses the same level of security (approximately one-sixth) while using significantly smaller keys than other cryptographic systems such as RSA and ElGamal. Have Using a smaller key means less computation time, less power, and less storage space.

타원곡선 암호 시스템으로 GF(p)의 소수(prime) 유한체 타원곡선 암호 시스템과 GF(2m)의 이진 유한체 타원곡선 암호 시스템이 주로 사용된다. 이러한 두 타원 곡선 암호 시스템은 사용되는 비트 길이에 따른 안전성은 동일하지만, 각 암호 시스템에서 사용되는 유한체 연산의 특성이 서로 다르며 유한체의 종류에 따라 각기 다른 형태로 구현된다.As the elliptic curve encryption system, the prime finite field elliptic curve encryption system of GF (p) and the binary finite field elliptic curve encryption system of GF (2 m ) are mainly used. These two elliptic curve cryptosystems have the same security depending on the bit length used, but the characteristics of the finite field operations used in each cryptosystem are different and are implemented in different forms depending on the type of finite field.

즉, GF(2n) 이진 유한체를 사용하는 타원곡선 암호 시스템은 연산의 특성상 하드웨어로의 구현이 더 용이한 반면, GF(P) 소수 유한체를 사용하는 타원곡선 암호 시스템은 소프트웨어로의 구현이 더 용이하다. 특히 GF(p) 타원곡선 암호 시스템은 자원 제약형 장치의 MCU(Micro Controller Unit)에 소프트웨어 형태로 구현되는 것이 고려되고 있다.In other words, an elliptic curve cryptosystem using GF (2 n ) binary finite bodies is easier to implement in hardware, while an elliptic curve cryptosystem using GF (P) fractional finite bodies is implemented in software. This is easier. In particular, the GF (p) elliptic curve cryptographic system is considered to be implemented in software form in the microcontroller unit (MCU) of the resource constrained device.

GF(p) 타원곡선 암호 시스템의 구현을 소프트웨어 형태로 예정하는 것은, 이를 하드웨어로 구현할 경우 소수 유한체의 곱셈 연산 및 역승산 연산 과정에서 발생하는 캐리(carry)의 처리를 위해 불가피하게 유한체 연산 장치의 구현 면적이 커지는 문제점이 있기 때문이다.The implementation of the GF (p) elliptic curve cryptographic system in software form is inevitably finite field computation for the handling of carry in the process of multiplication and inverse multiplication of prime finite field. This is because there is a problem that the implementation area of the device becomes large.

본 발명의 실시예가 해결하고자 하는 과제는 소수 유한체의 곱셈 연산 및 역승산 연산을 단순화하고 각각의 연산에서 발생하는 캐리의 처리를 단순화하는 타원곡선 암호화 방법 장치를 제공하는 것이다.An object of the present invention is to provide an elliptic curve encryption method apparatus that simplifies the multiplication and inverse multiplication operations of prime finite bodies and simplifies the processing of the carry occurring in each operation.

위와 같은 과제를 해결하기 위한 본 발명의 일 양태는 타원곡선 암호 연산을 위한 유한체 곱셈 방법에 관한 것으로서, 피승수와 승수를 일정 크기의 비트 단위로 구분하여 곱하는 단계와, 상기 곱셈 결과를 미리 저장된 이전 단계의 유한체 연산 결과와 더하는 단계 및 상기 덧셈 결과를 리덕션하는 단계를 포함한다. One aspect of the present invention for solving the above problems relates to a finite field multiplication method for the operation of the elliptic curve cryptography, multiplying the multiplicand multiplied by a predetermined size bit unit, and previously stored the multiplication result Adding to the finite field result of the step and reducing the addition result.

여기서, 상기 곱셈 단계는 상기 피승수의 일 비트 단위에 대해 상기 승수의 최하위 비트 단위부터 상위 비트 단위의 순서로 부분 곱셈을 수행하되, 상기 부분 곱셈은 상기 피승수의 최상위 비트 단위에서 하위 비트 단위의 순서로 수행된다.Here, the multiplying step may perform partial multiplication of the least significant bit unit of the multiplier in the order of the upper bit unit with respect to one bit unit of the multiplicand, wherein the partial multiplication is performed in the order of the most significant bit unit of the multiplier in the lower bit unit. Is performed.

또한, 상기 덧셈 단계는 상기 곱셈 결과의 상위 비트 단위와 상기 이전 단계의 유한체 연산 결과의 미리 정해진 비트 단위를 더하는 단계 및 상기 곱셈 결과의 하위 비트 단위와 상기 이전 단계의 유한체 연산 결과의 미리 정해진 비트 단위를 더하는 단계를 포함한다.The addition may include adding an upper bit unit of the multiplication result and a predetermined bit unit of the finite field operation result of the previous step, and a predetermined bit unit of the multiplication result and the finite field operation result of the previous step. Adding bit units.

그리고, 상기 리덕션 단계는 상기 유한체 연산 결과의 최상위 비트 단위를 임시 저장하는 단계와, 상기 유한체 연산 결과의 최상위 비트 단위를 한 비트 우측으로 쉬프트하는 단계 및 상기 임시 저장된 값과 상기 쉬프트된 값을 더하는 단계 를 포함한다.The reduction may include temporarily storing the most significant bit unit of the finite field operation result, shifting the most significant bit unit of the finite field operation result one bit to the right, and storing the temporarily stored value and the shifted value. Adding step.

본 발명의 다른 일 양태는 타원곡선 암호 연산 장치의 유한체 역승산 방법에 관한 것으로서, 중간값 및 최종값을 초기화하는 제1단계와, 피역승수를 1/2하는 제2-1단계와, 상기 중간값이 짝수이면 상기 중간값을 1/2하는 제2-2단계와, 상기 중간값이 짝수가 아니면 상기 중간값과 소수의 합을 1/2한 값을 상기 중간값으로 하는 제2-3단계를 피역승수가 짝수인 동안 반복하는 제2단계와, 최종값을 1/2하는 제3-1단계와, 상기 최종값이 짝수이면 상기 최종값을 1/2하는 제3-2단계와, 상기 최종값이 짝수가 아니면 상기 최종값과 상기 소수의 합을 1/2한 값을 상기 최종값으로 하는 제3-3단계를 상기 소수가 짝수인 동안 반복하는 제3단계와, 상기 피역승수가 상기 소수 이상이면, 상기 피역승수에서 상기 소수를 뺀 값을 피역승수로 하고 상기 중간값에서 상기 최종값을 뺀 값을 상기 중간값으로 하는 제4-1단계와, 그렇지 않으면 상기 소수에서 상기 피역승수를 뺀 값을 소수로 하고 상기 최종값에서 상기 중간값을 뺀 값을 상기 최종값으로 하는 제4-2단계 및 상기 최종값을 상기 소수로 모듈러 연산한 결과값을 출력하는 제5단계를 포함하며, 상기 제2단계 내지 제5단계는 상기 피역승수가 0이 아닌 동안 반복된다.Another aspect of the present invention relates to a finite-body inverse multiplication method of an elliptic curve cryptographic apparatus, comprising: a first step of initializing an intermediate value and a final value; If the median value is even, steps 2-2 of halving the median value; and if the median value is not even, step 2-2 of the median and the sum of the decimals halved; A second step of repeating the steps while the multiplicand is even, a third step of halving the final value, a third step of halving the final value if the final value is even, and A third step of repeating the third to third steps, wherein the final value is a value obtained by halving the sum of the final value and the prime number, if the final value is not even; If the fractional number is greater than or equal to, the multiplier subtracted from the multiplier is the multiplicand and the final value is obtained from the intermediate value. Step 4-1, wherein the value is the intermediate value; otherwise Step 4-2, where the decimal value is obtained by subtracting the multiplier by the decimal number and the final value is obtained by subtracting the intermediate value from the final value. And a fifth step of outputting a result of performing the modular operation on the final value by the decimal number, wherein the second to fifth steps are repeated while the dead multiplier is not zero.

본 발명의 실시예에 의하면 소수 유한체의 연산을 단순화함으로써 암호화 처리 장치의 구현 면적을 최소화하면서 연산 성능을 높일 수 있다.According to the embodiment of the present invention, the operation performance of the encryption processing apparatus can be minimized by simplifying the operation of the decimal finite field.

아래에서는 첨부한 도면을 참고로 하여 본 발명의 실시예에 대하여 본 발명 이 속하는 기술 분야에서 통상의 지식을 가진 자가 용이하게 실시할 수 있도록 상세히 설명한다. 그러나 본 발명은 여러 가지 상이한 형태로 구현될 수 있으며 여기에서 설명하는 실시예에 한정되지 않는다. 그리고 도면에서 본 발명을 명확하게 설명하기 위해서 설명과 관계없는 부분은 생략하였으며, 명세서 전체를 통하여 유사한 부분에 대해서는 유사한 도면 부호를 붙였다.Hereinafter, exemplary embodiments of the present invention will be described in detail with reference to the accompanying drawings so that those skilled in the art may easily implement the present invention. The present invention may, however, be embodied in many different forms and should not be construed as limited to the embodiments set forth herein. In the drawings, parts irrelevant to the description are omitted in order to clearly describe the present invention, and like reference numerals designate like parts throughout the specification.

명세서 전체에서, 어떤 부분이 다른 부분과 "연결"되어 있다고 할 때, 이는 "직접적으로 연결"되어 있는 경우뿐 아니라, 그 중간에 다른 소자를 사이에 두고 "전기적으로 연결"되어 있는 경우도 포함한다.Throughout the specification, when a part is referred to as being "connected" to another part, it includes not only "directly connected" but also "electrically connected" with another part in between .

명세서 전체에서, 어떤 부분이 어떤 구성요소를 "포함"한다고 할 때, 이는 특별히 반대되는 기재가 없는 한 다른 구성요소를 제외하는 것이 아니라 다른 구성요소를 더 포함할 수 있는 것을 의미한다.Throughout the specification, when a part is said to "include" a certain component, it means that it can further include other components, without excluding other components unless specifically stated otherwise.

본 발명의 실시예는 타원곡선 암호화를 위한 유한체 중 GF(P) 상의 소수(prime) 유한체에 관한 연산 방법 및 이를 위한 연산 장치에 관한 것이다. An embodiment of the present invention relates to a calculation method for a prime finite field on GF (P) among finite bodies for elliptic curve encryption, and a computing device therefor.

유한체 곱셈 연산과 역승산 연산은 GF(P) 상의 유한체를 이용한 타원곡선 암호화 연산의 주요 부분을 차지한다. 따라서, 이하에서는 첨부된 도면을 참고로 유한체 곱셈 연산과 역승산 연산을 순차적으로 상세히 설명한다.Finite field multiplication and inverse multiplication are the major part of the elliptic curve encryption using the finite field on GF (P). Therefore, hereinafter, the finite field multiplication operation and the inverse multiplication operation will be described in detail with reference to the accompanying drawings.

GFGF (P) 유한체 곱셈 연산(P) finite field multiplication

도 1은 본 발명의 일 실시예에 의한 유한체 곱셈 연산 장치의 구성을 간략하게 도시한 블럭도이다.FIG. 1 is a block diagram schematically illustrating a configuration of a finite field multiplication apparatus according to an embodiment of the present invention.

본 실시예에 의한 유한체 연산 장치는 피승수를 저장하기 위한 A 레지스 터(110)와, 승수를 저장하기 위한 B 레지스터(120)와, 곱셈기(130)와, 2개의 덧셈기(141, 142)와, 2개의 캐리 레지스터(151, 152)와, 연산 결과값을 저장하기 위한 C 레지스터(160)와, 본 실시예의 유한체 연산 장치가 곱셈 연산을 수행하도록 상기 구성요소들을 제어하기 위한 제어기(도면에 미도시)를 포함한다.The finite field arithmetic apparatus according to the present embodiment includes an A register 110 for storing a multiplier, a B register 120 for storing a multiplier, a multiplier 130, two adders 141, 142, 2 carry registers 151 and 152, a C register 160 for storing the result of the operation, and a controller for controlling the components so that the finite field operation apparatus of the present embodiment performs a multiplication operation (as shown in the drawing). Not shown).

도 1은 특히 160 비트의 유한체를 대상으로 곱셈을 수행하는 연산 장치의 예를 도시한다. 즉, 도 1의 연산 장치는 160 비트의 유한체 전체를 한 번에 연산하는 것이 아니라 이를 32 비트 단위로 구분하여 연산한다. 이를 위해 160 비트의 레지스터들(110, 120, 160)과 32 비트의 곱셈기(130) 및 32 비트의 덧셈기(141, 142)가 사용된다. 그리고 각 레지스터(110, 120, 160)에서 32 비트의 단위 비트를 선택하기 위한 다중화기들(181~184)이 본 실시예의 연산 장치에 추가로 포함될 수 있다. 여기서, 상기 32 비트의 연산 단위를 '단위 비트'라 부르기로 한다.1 shows an example of an arithmetic device that performs multiplication on a 160 bit finite field in particular. That is, the computing device of FIG. 1 does not compute the entire finite field of 160 bits at once, but divides them into 32 bit units. For this purpose, 160 bits of registers 110, 120, 160, 32 bits of multiplier 130, and 32 bits of adders 141, 142 are used. In addition, multiplexers 181 to 184 for selecting 32-bit unit bits in each register 110, 120, and 160 may be further included in the computing device of the present embodiment. Here, the 32-bit operation unit will be referred to as 'unit bit'.

이하, 유한체 곱셈 연산 과정을 도 1을 참고로 상세히 설명하면 다음과 같다.Hereinafter, the finite field multiplication operation will be described in detail with reference to FIG. 1.

본 발명의 실시예에 따른 유한체 곱셈 연산은, A 레지스터(110)의 32 비트 단위 비트들을 B 레지스터(120)의 32 비트 단위 비트들과 곱하는 단계와, 곱셈 결과를 다시 32 비트로 구분하여 C 레지스터(160)의 미리 지정된 단위 비트들과 합산하는 단계와, 합산 결과를 160 비트로 맞추기 위해 리덕션하는 단계를 반복하는 구조로 이루어진다.In the finite field multiplication operation according to an embodiment of the present invention, the 32-bit unit bits of the A register 110 are multiplied by the 32-bit unit bits of the B register 120, and the multiplication result is divided into 32 bits and the C register. Summing up with the predetermined unit bits of 160 and reducing to adjust the summing result to 160 bits.

상기 곱셈 단계에 있어서 단위 비트들의 연산 규칙은 다음과 같다. 도 2는 본 발명의 실시예에 따른 유한체 곱셈 연산의 단위 비트들 간의 연산 순서를 나타 낸 개념도이다.The operation rule of the unit bits in the multiplication step is as follows. 2 is a conceptual diagram illustrating an operation order between unit bits of a finite field multiplication operation according to an exemplary embodiment of the present invention.

도 2에서 보듯, A 레지스터(110)의 최상위 단위 비트(A0)와 B 레지스터(120)의 각 단위 비트(B4 ~ B0)를 최하위로부터 상위 방향 순으로 연산하고, A 레지스터(110)의 다음 순위 단위 비트(A1)와 B 레지스터(120)의 각 단위 비트(B4 ~ B0)를 다시 최하위로부터 상위 방향 순으로 연산한다. 이와 같은 과정은 A 레지스터(110)의 다음 순위 단위 비트들(A2 ~ A5)에 대하여 반복적으로 수행된다.As shown in FIG. 2, the most significant unit bit A0 of the A register 110 and each of the unit bits B4 to B0 of the B register 120 are calculated in order from the lowest to the highest, and the next rank of the A register 110 is calculated. The unit bits A1 and the respective unit bits B4 to B0 of the B register 120 are again calculated from the lowest to the highest directions. This process is repeatedly performed on the next rank unit bits A2 to A5 of the A register 110.

다시 도 1을 참고하여 A 레지스터(110)의 A0 단위 비트와 B 레지스터(120)의 각 단위 비트(B4 ~ B0)를 연산하는 과정을 구체적으로 살펴본다.Referring back to FIG. 1, a process of calculating the A0 unit bits of the A register 110 and the respective unit bits B4 to B0 of the B register 120 will be described in detail.

제어기는 다중화기(115, 125)를 제어하여 A 레지스터(110)의 A0 단위 비트를 선택하고, B 레지스터(120)의 B4 단위 비트를 선택하여 곱셈기(130)로 전송한다.The controller controls the multiplexers 115 and 125 to select the A0 unit bits of the A register 110 and the B4 unit bits of the B register 120 to transmit to the multiplier 130.

곱셈기(130)의 연산 결과값은 32 비트로 나뉘어 Mul_h, Mul_l로 출력된다. 그리고, Mul_h는 C 레지스터(160)의 C4 단위 비트와 덧셈기(141)에서 더해지고, Mul_l는 C 레지스터(160)의 C5 단위 비트와 덧셈기(142)에서 더해져서 각각 C 레지스터(160)의 C4 및 C5에 다시 저장된다. 이 과정에서 덧셈기(141)로는 MUL_h와 C_h(C4)가 입력되고, 덧셈기(142)로는 MUL_l와 C_l(C5)이 입력된다. 그리고, 덧셈기(142)의 캐리값(CL)은 덧셈기(141)에 캐리로 입력된다.The operation result of the multiplier 130 is divided into 32 bits and output as Mul_h and Mul_l. Mul_h is added in the C4 unit bit of the C register 160 and the adder 141, and Mul_l is added in the C5 unit bit of the C register 160 and the adder 142, respectively, and C4 and C4 of the C register 160 are added. It is stored back in C5. In this process, MUL_h and C_h (C4) are input to the adder 141 and MUL_l and C_l (C5) are input to the adder 142. The carry value CL of the adder 142 is input to the adder 141 as a carry.

초기에는 C 레지스터(160) 값이 '0'이기 때문에 결과적으로 곱셈기(130)의 출력은 C 레지스터(160)의 C4와 C5에 그대로 저장된다. 이후 A0와 B3의 곱셈 결과는 덧셈기(141, 142)에서 각각 C3와 C4의 저장값과 더해져서 다시 C 레지스터(160)의 C3와 C4에 저장된다. 이러한 과정을 B0까지 반복하면 결국 C 레지스터(160)에는 A0 * B의 연산 결과가 저장된다.Initially, since the value of C register 160 is '0', the output of multiplier 130 is stored in C4 and C5 of C register 160 as it is. Then, the multiplication result of A0 and B3 is added to the stored values of C3 and C4 in the adders 141 and 142, respectively, and stored in C3 and C4 of the C register 160 again. If this process is repeated up to B0, the result of operation A0 * B is eventually stored in the C register 160.

제어기는 A0 * B 의 연산이 종료되면 C 레지스터에 저장된 값에 대하여 리덕션 연산을 수행한다. 도 3은 리덕션 연산의 원리를 간략하게 도시한 개념도이다.When the operation of A0 * B is completed, the controller performs reduction operation on the value stored in the C register. 3 is a conceptual diagram briefly illustrating the principle of reduction operation.

도 3에서 보듯, 리덕션 연산은 어떠한 연산 결과로 160 비트를 초과해버린 값을 160 비트 내의 유한체 값으로 변환하는 과정으로서, 대상 값을 유한체 최소 다항식인 p(x)로 나눈 나머지 값을 구하는 연산이다.As shown in FIG. 3, a reduction operation is a process of converting a value exceeding 160 bits into a finite field value within 160 bits as a result of a certain operation, and obtaining a residual value obtained by dividing a target value by p (x), which is a finite minimum polynomial. Operation.

다시 도 1로 돌아가 리덕션 연산을 설명하면, 제어기는 특별한 다항식(예를 들면 유한체 최소 다항식)을 선택하여 그에 따라 리덕션 연산을 수행할 수 있는데, 일례로 C0와 C0의 쉬프트된 값들(C0[31:1], C0[0])을 합산하는 방법으로 리덕션을 수행할 수 있다. 이와 같은 리덕션 연산은 C0와 덧셈기들의 캐리값들이 '0'이 될 때까지 반복하여 수행된다.Returning to FIG. 1 and explaining the reduction operation, the controller can select a special polynomial (e.g., a finite minimum polynomial) and perform the reduction operation accordingly, for example the shifted values of C0 and C0 (C0 [31). Reduction can be performed by summing: 1] and C0 [0]). This reduction operation is repeatedly performed until the carry values of C0 and the adders become '0'.

상기 리덕션 연산을 위해 본 발명의 실시예에 의한 연산 장치는 C0의 저장값을 임시 저장하기 위한 레지스터(170)와, C0의 저장값을 쉬프트하기 위한 다중화기(171)를 더 포함할 수 있으며, 덧셈기(141)는 상기 임시 저장된 값과 상기 쉬프트된 값을 더하는 기능을 더 포함할 수 있다.The arithmetic unit according to the embodiment of the present invention for the reduction operation may further include a register 170 for temporarily storing the stored value of C0, and a multiplexer 171 for shifting the stored value of C0, The adder 141 may further include a function of adding the temporarily stored value and the shifted value.

이상의 곱셈 단계, 덧셈 단계 및 리덕션 단계는 A1 * B, A2 * B, A3 * B, A4 * B에 대하여도 동일하게 수행된다.The above multiplication step, addition step and reduction step are similarly performed for A1 * B, A2 * B, A3 * B and A4 * B.

GFGF (P) 유한체의 (P) finite 역승산Inverse odds

본 발명의 일 실시예에 의한 유한체 역승산 연산을 수행하기 위해 다음의 알고리즘 1이 이용될 수 있다.The following algorithm 1 may be used to perform a finite field inverse multiplication operation according to an embodiment of the present invention.

<알고리즘 1>Algorithm 1

INPUT(입력): Prime p, a ∈ [0, p-1]INPUT: Prime p, a ∈ [0, p-1]

OUTPUT(출력): a-1 mod pOUTPUT: a -1 mod p

1. u <- a, v <- p, A <- 0, C <- 0U <-a, v <-p, A <-0, C <-0

2. While u≠0 doWhile u ≠ 0 do

2.1 While u is even do:   2.1 While u is even do:

u <- u/2, If A is even then A <- A/2; else A <- (A+p)/2       u <-u / 2, If A is even then A <-A / 2; else A <-(A + p) / 2

2.2 While v is even do:   2.2 While v is even do:

v <- v/2, If C is even then C <- C/2; else C <- (C+p)/2       v <-v / 2, If C is even then C <-C / 2; else C <-(C + p) / 2

2.3 If u≥v then: u <- u-v, A <- A-C; else v <- v-u, C <- C-A   2.3 If u≥v then: u <-u-v, A <-A-C; else v <-v-u, C <-C-A

3. Return(C mod p)3.Return (C mod p)

알고리즘 1에서 보듯, 본 실시예에 의한 역승산 연산은 1/2 연산, 덧셈 연산 및 뺄셈 연산의 반복으로 이루어진다.As shown in Algorithm 1, the inverse multiplication operation according to the present embodiment consists of repetition of a half operation, an addition operation, and a subtraction operation.

알고리즘 1에 따라 유한체 역승산을 수행하는 연산 장치를 살펴보면 다음과 같다. 도 4는 본 발명의 일 실시예에 의한 유한체 역승산 장치의 구성을 간략하게 도시한 블럭도이다.The computing device that performs the finite field inverse multiplication according to Algorithm 1 is as follows. 4 is a block diagram briefly illustrating a configuration of a finite body multiplication apparatus according to an embodiment of the present invention.

본 실시예에 의한 유한체 연산 장치는 알고리즘 1에서 변수 u를 저장하기 위한 A 레지스터(210)와, 변수 v를 저장하기 위한 B 레지스터(220)와, 변수 C를 저장하기 위한 C 레지스터(230)와, 변수 A를 저장하기 위한 D 레지스터(240)와, 뺄셈 연산을 위한 2개의 다중화기(251, 252)와, 2개의 덧셈기(261, 262)와, 1/2 연산을 수행하기 위한 다중화기들(271~274)과, 본 실시예의 유한체 연산 장치가 알고리즘 1에 따라 동작하도록 상기 구성요소들을 제어하기 위한 제어기(도면에 미도시)를 포함한다.In the finite field calculation apparatus according to the present exemplary embodiment, the A register 210 for storing the variable u, the B register 220 for storing the variable v, and the C register 230 for storing the variable C in Algorithm 1 are described. D register 240 for storing variable A, two multiplexers 251 and 252 for subtraction operation, two adders 261 and 262, multiplexer for performing 1/2 operation 271 to 274, and a controller (not shown in the figure) for controlling the components so that the finite field apparatus of the present embodiment operates according to Algorithm 1.

도 4는 특히 160 비트의 유한체를 대상으로 역승산을 수행하는 연산 장치를 도시하며, 160 비트의 유한체 전체를 한 번에 연산하는 것이 아니라 이를 32 비트 단위로 구분하여 연산하기 위한 일례를 도시한다. 이를 위해 160 비트의 레지스터들(210, 220, 230, 240)과 32 비트의 덧셈기(261, 262)와 32 비트의 다중화기들(251~252, 271~274)가 사용된다. 그리고 각 레지스터(210, 220, 230, 240)에서 32 비트의 단위 비트를 선택하기 위한 다중화기들(281~285)이 본 실시예의 연산 장치에 추가로 포함될 수 있다.FIG. 4 illustrates an arithmetic unit that performs inverse multiplication on a 160-bit finite field, and illustrates an example for calculating the entire finite field of 160 bits at once instead of calculating them in 32-bit units. do. For this purpose, 160-bit registers 210, 220, 230, and 240, 32-bit adders 261 and 262, and 32-bit multiplexers 251 to 252 and 271 to 274 are used. In addition, multiplexers 281-285 for selecting 32-bit unit bits from each register 210, 220, 230, and 240 may be additionally included in the computing device of the present embodiment.

유한체 a의 역승산을 위해, 먼저 역승산수 a, 모듈러 상수 p가 각각 A 레지스터(210) 및 B 레지스터(220)에 저장되고, C 레지스터(230) 및 D 레지스터(240)에 초기값으로 각각 0과 1이 저장된다(S201).For inverse multiplication of the finite body a, first, the inverse multiplier a and the modular constant p are stored in the A register 210 and the B register 220, respectively, and initialized to the C register 230 and the D register 240 as initial values. 0 and 1 are stored respectively (S201).

제어기는 A 레지스터(210)의 저장값이 0이 아니고(S202) A 레지스터(210)가 짝수이면 u를 1/2한 값을 A 레지스터(210)에 저장한다(S203). 그리고 만약 A 레지스터(210)의 저장값이 짝수이면 해당 저장값을 1/2하여 다시 A 레지스터(210)에 저장하고(S204), 그렇지 않으면 A 레지스터(210)의 저장값과 p의 합산 결과를 1/2한 값을 A 레지스터(210)에 저장한다(S205).If the stored value of the A register 210 is not 0 (S202) and the A register 210 is an even number, the controller stores the value 1/2 of the u in the A register 210 (S203). If the stored value of the A register 210 is an even number, the corresponding stored value is 1/2 and stored in the A register 210 again (S204). Otherwise, the sum of the stored value of the A register 210 and p is calculated. The half value is stored in the A register 210 (S205).

또한, 제어기는 A 레지스터(210)의 저장값이 0이 아니고(S202) B 레지스 터(220)가 짝수이면 v를 1/2한 값을 B 레지스터(220)에 저장한다(S206). 그리고 만약 B 레지스터(220)의 저장값이 짝수이면 해당 저장값을 1/2하여 다시 C 레지스터(220)에 저장하고(S207), 그렇지 않으면 C 레지스터(230)의 저장값과 p의 합산 결과를 1/2한 값을 C 레지스터(230)에 저장한다(S208).In addition, if the stored value of the A register 210 is not 0 (S202) and the B register 220 is an even number, the controller stores a value of 1/2 of the value in the B register 220 (S206). If the stored value of the B register 220 is an even number, the stored value is half stored in the C register 220 (S207). Otherwise, the sum of the stored value of the C register 230 and p is calculated. The half value is stored in the C register 230 (S208).

이어서, 제어기는 A 레지스터(210)의 저장값이 0이 아니고(S202) A 레지스터(210)의 저장값이 B 레지스터(220)의 저장값보다 크거나 같으면, A 레지스터(210)의 저장값에서 B 레지스터(220)의 저장값을 뺀 값을 다시 A 레지스터(210)에 저장한다(S209).Subsequently, if the stored value of the A register 210 is not 0 (S202) and the stored value of the A register 210 is greater than or equal to the stored value of the B register 220, The value obtained by subtracting the stored value of the B register 220 is stored in the A register 210 again (S209).

만약, A 레지스터(210)의 저장값이 0이 아니고(S202) A 레지스터(210)의 저장값이 B 레지스터(220)의 저장값보다 작으면, 제어기는 B 레지스터(220)의 저장값에서 A 레지스터(210)의 저장값을 뺀 값을 B 레지스터(220)에 저장한다(S210).If the stored value of the A register 210 is not 0 (S202) and the stored value of the A register 210 is smaller than the stored value of the B register 220, the controller determines that the stored value of the B register 220 is A. The value obtained by subtracting the stored value of the register 210 is stored in the B register 220 (S210).

상기 S202 단계 내지 S210 단계는 A 레지스터(210)의 저장값이 0이 될 때까지 반복적으로 수행되며, 제어기는 A 레지스터(210)의 저장값이 0이 되면 C 레지스터(230)의 저장값을 p로 모듈러 연산한 값을 최종 결과값으로 출력한다.Steps S202 to S210 are repeatedly performed until the stored value of the A register 210 becomes 0, and the controller p stores the stored value of the C register 230 when the stored value of the A register 210 becomes 0. Outputs the result of the modular operation as the final result.

한편, 본 실시예의 역승산 연산에서 1/2 연산은 다중화기(271~274)를 이용하여 레지스터(210~240)를 단순 쉬프트시키는 방법으로 수행된다.Meanwhile, in the inverse multiplication operation of the present embodiment, the half operation is performed by a method of simply shifting the registers 210 to 240 using the multiplexers 271 to 274.

또한, 본 실시예의 역승산 연산에서 덧셈 및 뺄셈 연산은 각 레지스터(210~240)의 하위 32비트 단위 비트부터 수행된다.In addition, in the inverse multiplication operation of the present embodiment, the addition and subtraction operations are performed from the lower 32-bit unit bits of each register 210 to 240.

S205 단계의 합산 과정을 구체적으로 살펴보면 다음과 같다.Looking at the adding process of step S205 in detail.

제어기는 다중화기(285)를 이용하여 C 레지스터(230)의 C4 단위 비트를 선택 하고, 다중화기(282)를 이용하여 B 레지스터(220)의 B4 단위 비트를 선택한 후, 두 출력값을 덧셈기(262)로 보낸다. 덧셈기(262)에서의 합산 결과, 발생된 캐리는 캐리 레지스터(262-1)에 저장되어 다음 단계의 단위 비트들의 합산에 반영하고, 합산값은 다중화기(273)을 통해 1/2 연산된 후 다시 C 레지스터(230)에 저장된다. 이와 같은 과정은 C3~C0 및 B3~B0에 대하여 동일하게 반복된다.The controller selects the C4 unit bits of the C register 230 using the multiplexer 285, selects the B4 unit bits of the B register 220 using the multiplexer 282, and then adds the two output values 262. Send to). As a result of the summation in the adder 262, the generated carry is stored in the carry register 262-1 to reflect the sum of the unit bits of the next step, and the summation value is calculated 1/2 through the multiplexer 273. Again stored in the C register 230. This process is the same for C3 to C0 and B3 to B0.

S208 단계의 합산 과정을 구체적으로 살펴보면 다음과 같다.Looking at the addition process of step S208 in detail.

제어기는 다중화기(285)를 이용하여 D 레지스터(240)의 D4 단위 비트를 선택하고, 다중화기(282)를 이용하여 B 레지스터(220)의 B4 단위 비트를 선택한 후, 두 출력값을 덧셈기(262)로 보낸다. 덧셈기(262)에서의 합산 결과, 발생된 캐리는 캐리 레지스터(262-1)에 저장되어 다음 단계의 단위 비트들의 합산에 반영하고, 합산값은 다중화기(274)을 통해 1/2 연산된 후 다시 D 레지스터(240)에 저장된다. 이와 같은 과정은 D3~D0 및 B3~B0에 대하여 동일하게 반복된다.The controller selects the D4 unit bits of the D register 240 using the multiplexer 285, selects the B4 unit bits of the B register 220 using the multiplexer 282, and then adds the two output values 262. Send to). As a result of the summation in the adder 262, the generated carry is stored in the carry register 262-1 to reflect the sum of the unit bits of the next step, and the sum value is 1/2 calculated by the multiplexer 274. Again stored in the D register 240. This process is repeated for D3 to D0 and B3 to B0 in the same manner.

다음으로, S209 단계의 감산 과정을 구체적으로 살펴보면 다음과 같다.Next, the subtraction process of step S209 will be described in detail.

제어기는 A 레지스터(210)의 저장값이 0이 아니고 A 레지스터(210)의 저장값이 B 레지스터(220)의 저장값보다 크거나 같으면, 다중화기(281)를 이용하여 선택한 A 레지스터(210)의 A4 단위 비트를 덧셈기(261)로 보내고, 다중화기(232)를 이용하여 선택한 B 레지스터(220)의 B4 단위 비트를 다중화기(251)를 통해 NOT 연산한 후 덧셈기(261)로 보내어 뺄셈 연산을 수행한다. 이어서, 제어기는 다중화기(284)를 이용하여 선택한 C 레지스터(230)의 C4 단위 비트를 덧셈기(262)로 보내고, 다중화기(235)를 이용하여 선택한 D 레지스터(240)의 B4 단위 비트를 다중화 기(252)를 통해 NOT 연산한 후 덧셈기(262)로 보내어 뺄셈 연산을 수행한다.If the stored value of the A register 210 is not 0 and the stored value of the A register 210 is greater than or equal to the stored value of the B register 220, the controller selects the selected A register 210 using the multiplexer 281. Sends the A4 unit bits of the B4 unit bits of the selected B register 220 using the multiplexer 232 to the adder 261 and then sends the resultant to the adder 261. Do this. The controller then sends the C4 unit bits of the selected C register 230 to the adder 262 using the multiplexer 284 and multiplexes the B4 unit bits of the selected D register 240 using the multiplexer 235. A NOT operation is performed through the device 252 and then sent to the adder 262 to perform a subtraction operation.

S210 단계의 감산 과정도 S209 단계와 유사하게 수행된다.The subtraction process of step S210 is also performed similarly to step S209.

즉, 제어기는 A 레지스터(210)의 저장값이 0이 아니고 A 레지스터(210)의 저장값이 B 레지스터(220)의 저장값보다 작으면, 다중화기(281)를 이용하여 선택한 A 레지스터(210)의 A4 단위 비트를 다중화기(251)를 통해 NOT 연산한 후 덧셈기(261)로 보내고, 다중화기(232)를 이용하여 선택한 B 레지스터(220)의 B4 단위 비트를 덧셈기(261)로 보내어 뺄셈 연산을 수행한다. 이어서, 제어기는 다중화기(284)를 이용하여 선택한 C 레지스터(230)의 C4 단위 비트를 다중화기(252)를 통해 NOT 연산한 후 덧셈기(262)로 보내고, 다중화기(235)를 이용하여 선택한 D 레지스터(240)의 B4 단위 비트를 덧셈기(262)로 보내어 뺄셈 연산을 수행한다.That is, if the stored value of the A register 210 is not 0 and the stored value of the A register 210 is smaller than the stored value of the B register 220, the controller selects the A register 210 selected using the multiplexer 281. NOT operation through the multiplexer 251 to the A4 unit bit, and then to the adder 261. The B4 unit bit of the selected B register 220 is sent to the adder 261 using the multiplexer 232. Perform the operation. Subsequently, the controller performs a NOT operation on the multiplexer 284 and selects the C4 unit bits of the selected C register 230 through the multiplexer 252 to the adder 262, and then selects the multiplexer 235. The B4 unit bits of the D register 240 are sent to the adder 262 to perform a subtraction operation.

S209 및 S210의 뺄셈 연산에서 캐리 레지스터(261-1, 262-1)의 초기값은 1로 세팅(set)되며, 연산을 통해 발생한 캐리는 다시 캐리 레지스터(261-1, 262-1)에 저장되어 다음 단계의 비트 단위의 연산에 반영된다.In subtraction operations S209 and S210, the initial values of the carry registers 261-1 and 262-1 are set to 1, and the carry generated through the operation is stored in the carry registers 261-1 and 262-1 again. This is reflected in the next bitwise operation.

전술한, 덧셈 연산과 뺄셈 연산의 결과는 다시 p와의 비교 연산을 통해 조정될 수 있다. 즉, 제어기는 덧셈 연산과 뺄셈 연산의 결과와 p와의 비교 결과, 덧셈 또는 뺄셈 결과값이 p보다 큰 경우 해당 결과값에서 p를 다시 빼주는 연산을 수행하여 그 결과값이 유한체 내의 값이 되도록 한다. The result of the addition operation and the subtraction operation described above may be adjusted through a comparison operation with p. That is, the controller performs the operation of subtracting p from the result value if the result of the comparison between the result of the addition operation and the subtraction operation and p and the addition or subtraction result is larger than p so that the result becomes a value within the finite field. .

한편, 레지스터(210~240)의 저장값이 짝수인지를 판단하기 위해 해당 저장값의 최하위 비트 단위(또는 비트값)을 이용할 수 있다. 또한, 덧셈기(261, 262)의 캐리 출력값(CH, CL)은 연산 결과에 따른 캐리의 발생 유무를 판별하는 데 이용된 다. 또한, A 레지스터(210)의 저장값이 0인지를 판단하기 위해 32비트 단위의 각 단위 비트를 or 연산할 수 있으며, 만약 or 연산 결과가 0인 경우에는 최종 연산 결과값으로 C 레지스터(230)의 저장값을 출력한다.Meanwhile, in order to determine whether the stored values of the registers 210 to 240 are even, the least significant bit unit (or bit value) of the corresponding stored value may be used. In addition, the carry output values CH and CL of the adders 261 and 262 are used to determine whether or not a carry is generated according to the operation result. In addition, in order to determine whether the stored value of the A register 210 is 0, each unit bit of a 32-bit unit may be or operated. If the or operation result is 0, the C register 230 is a final operation result value. Output the stored value of.

도 5는 전술한 유한체 곱셈 연산과 유한체 역승산 연산은 동시에 수행하는 타원곡선 암호 연산 장치의 구성을 간략하게 도시한 블록도이다.FIG. 5 is a block diagram schematically illustrating a configuration of an elliptic curve cryptographic apparatus that simultaneously performs the aforementioned finite field multiplication and finite field multiplication operations.

유한체 곱셈 연산에 있어서, 본 실시예의 연산 장치에 포함된 복수의 레지스터들(310~330)은 도 1의 레지스터들(110, 120, 160)에 대응하고, 곱셈기(350)는 도 1의 곱셈기(130)에 대응하고, 두 개의 덧셈기(361, 362)는 도 1의 덧셈기(141, 142)에 대응하고, 두 개의 캐리 레지스터(361-1, 362-1)는 도 1의 캐리 레지스터(151, 152)에 대응하고, 임시 레지스터(370)는 도 1의 임시 레지스터(170)에 대응하고, 복수의 다중화기(381~384)는 도 1의 다중화기(181~184)에 대응한다.In the finite field multiplication operation, the plurality of registers 310 to 330 included in the computing device of the present embodiment correspond to the registers 110, 120, and 160 of FIG. 1, and the multiplier 350 is a multiplier of FIG. 1. Corresponding to 130, two adders 361 and 362 correspond to adders 141 and 142 in FIG. 1, and two carry registers 361 and 362-1 correspond to carry registers 151 in FIG. 152, the temporary register 370 corresponds to the temporary register 170 of FIG. 1, and the plurality of multiplexers 381 to 384 correspond to the multiplexers 181 to 184 of FIG. 1.

또한, 유한체 역승산 연산에 있어서, 본 실시예의 연산 장치에 포함된 복수의 레지스터들(310~340)은 도 4의 레지스터들(210~240)에 대응하고, 두 개의 덧셈기(361, 362)는 도 4의 덧셈기(261, 262)에 대응하고, 두 개의 캐리 레지스터(361-1, 362-1)는 도 4의 캐리 레지스터(261-1, 262-1)에 대응하고, 복수의 다중화기(381~384, 391~394, 3010~3020)는 도 4의 다중화기(281~284, 271~274, 251~252)에 대응한다.In addition, in the finite field multiplication operation, the plurality of registers 310 to 340 included in the computing device of the present embodiment correspond to the registers 210 to 240 of FIG. 4, and two adders 361 and 362. Corresponds to the adders 261 and 262 of FIG. 4, the two carry registers 361-1 and 362-1 correspond to the carry registers 261-1 and 262-1 of FIG. 4, and a plurality of multiplexers. 381 to 384, 391 to 394, and 3010 to 3020 correspond to the multiplexers 281 to 284, 271 to 274, and 251 to 252 of FIG. 4.

유한체 곱셈 연산 및 유한체 역승산 연산에 있어서, 상기 대응되는 구성에 의한 연산 과정은 각각 상기 도 1 및 상기 도 4과 동일하다.In the finite field multiplication operation and the finite field inverse multiplication operation, the calculation process by the corresponding configuration is the same as that of FIGS. 1 and 4, respectively.

이상의 설명에서는 연산 장치의 일례로 160 비트의 유한체를 32 비트의 연산 단위로 분리하여 곱셈 연산 및 역승산 연산을 수행하는 경우(case)에 대해 설명하였지만 반드시 이에 한정하는 것은 아니다. 다시 말해, 연산 단위는 16 비트, 32 비트, 48 비트, 64 비트 등 16 비트, 32 비트 또는 64 비트의 배수로 설정할 수 있으며, 그에 따라 유한체의 구성 비트 수는 상기 설정된 연산 단위의 배수로 결정될 수 있다.In the above description, a case of performing a multiplication operation and an inverse multiplication operation by separating a 160-bit finite field into 32-bit operation units as an example of an operation device is not limited thereto. In other words, the operation unit may be set to a multiple of 16 bits, 32 bits, or 64 bits, such as 16 bits, 32 bits, 48 bits, 64 bits, and so the number of configuration bits of the finite body may be determined as a multiple of the set operation unit. .

한편, 이상에서 설명한 본 발명의 실시예는 장치 또는 방법을 통해서만 구현이 되는 것은 아니며, 본 발명의 실시예의 구성에 대응하는 기능을 실현하는 프로그램 또는 그 프로그램이 기록된 기록 매체를 통해 구현될 수도 있다. Meanwhile, the embodiments of the present invention described above are not implemented only through an apparatus or a method, but may be implemented through a program for realizing a function corresponding to the configuration of the embodiments of the present invention or a recording medium on which the program is recorded. .

또한, 이상에서 본 발명의 실시예에 대하여 상세하게 설명하였지만 본 발명의 권리범위는 이에 한정되는 것은 아니고 다음의 청구범위에서 정의하고 있는 본 발명의 기본 개념을 이용한 당업자의 여러 가지 변형 및 개량 형태 또한 본 발명의 권리범위에 속한다.In addition, the embodiments of the present invention have been described in detail above, but the scope of the present invention is not limited thereto, and various modifications and improvements of those skilled in the art using the basic concepts of the present invention defined in the following claims are also provided. It belongs to the scope of the present invention.

도 1은 본 발명의 일 실시예에 의한 유한체 곱셈 연산 장치의 구성을 간략하게 도시한 블럭도이다.FIG. 1 is a block diagram schematically illustrating a configuration of a finite field multiplication apparatus according to an embodiment of the present invention.

도 2는 본 발명의 실시예에 따른 유한체 곱셈 연산의 단위 비트들 간의 연산 순서를 나타낸 개념도이다.2 is a conceptual diagram illustrating an operation order between unit bits of a finite field multiplication operation according to an exemplary embodiment of the present invention.

도 3은 리덕션 연산의 원리를 간략하게 도시한 개념도이다.3 is a conceptual diagram briefly illustrating the principle of reduction operation.

도 4는 본 발명의 일 실시예에 의한 유한체 역승산 장치의 구성을 간략하게 도시한 블럭도이다.4 is a block diagram briefly illustrating a configuration of a finite body multiplication apparatus according to an embodiment of the present invention.

도 5는 전술한 유한체 곱셈 연산과 유한체 역승산 연산은 동시에 수행하는 타원곡선 암호 연산 장치의 구성을 간략하게 도시한 블록도이다.FIG. 5 is a block diagram schematically illustrating a configuration of an elliptic curve cryptographic apparatus that simultaneously performs the aforementioned finite field multiplication and finite field multiplication operations.

Claims (6)

타원 곡선 암호 연산 장치가 타원곡선 암호 연산을 위한 유한체 곱셈을 수행하는 타원곡선 암호 연산 방법에 있어서,In the elliptic curve cryptography method, the elliptic curve cryptography device performs finite field multiplication for elliptic curve cryptography, 상기 타원 곡선 암호 연산 장치가 피승수와 승수를 일정 크기의 비트 단위로 구분하여 곱하는 단계;Dividing and multiplying the multiplicand and the multiplier by bit units of a predetermined size by the elliptic curve cryptographic computing device; 상기 타원 곡선 암호 연산 장치가 상기 곱셈 결과를 미리 저장된 이전 단계의 유한체 연산 결과와 더하는 단계; 및Adding, by the elliptic curve cryptographic calculation device, the multiplication result to a previously stored finite field calculation result; And 상기 타원 곡선 암호 연산 장치가 상기 덧셈 결과를 리덕션하는 단계Reducing the addition result by the elliptic curve cryptographic device 를 포함하는 타원곡선 암호 연산 방법.Elliptic curve encryption method comprising a. 제1항에 있어서, 상기 곱셈 단계는The method of claim 1, wherein the multiplication step 상기 피승수의 일 비트 단위에 대해 상기 승수의 최하위 비트 단위부터 상위 비트 단위의 순서로 부분 곱셈을 수행하되,Partial multiplication is performed for one bit unit of the multiplicant in order of least significant bit unit to upper bit unit of the multiplier, 상기 부분 곱셈은 상기 피승수의 최상위 비트 단위에서 하위 비트 단위의 순서로 수행되는 타원곡선 암호 연산 방법.And the partial multiplication is performed in the order of the most significant bit unit to the least significant bit unit of the multiplicand. 제1항에 있어서, 상기 덧셈 단계는The method of claim 1, wherein the adding step 상기 곱셈 결과의 상위 비트 단위와 상기 이전 단계의 유한체 연산 결과의 미리 정해진 비트 단위를 더하는 단계; 및Adding an upper bit unit of the multiplication result and a predetermined bit unit of the finite field operation result of the previous step; And 상기 곱셈 결과의 하위 비트 단위와 상기 이전 단계의 유한체 연산 결과의 미리 정해진 비트 단위를 더하는 단계를 포함하는 타원곡선 암호 연산 방법.And adding a lower bit unit of the multiplication result and a predetermined bit unit of the finite field operation result of the previous step. 제3항에 있어서, 상기 리덕션 단계는The method of claim 3, wherein the reduction step 상기 유한체 연산 결과의 최상위 비트 단위를 임시 저장하는 단계;Temporarily storing the most significant bit unit of the finite field calculation result; 상기 유한체 연산 결과의 최상위 비트 단위를 한 비트 우측으로 쉬프트하는 단계; 및Shifting the most significant bit unit of the result of the finite field operation one bit to the right; And 상기 임시 저장된 값과 상기 쉬프트된 값을 더하는 단계를 포함하는 타원곡선 암호 연산 방법.And adding the temporarily stored value and the shifted value. 타원곡선 암호 연산 장치가 유한체 역승산을 수행하는 타원 곡선 암호 연산 방법에 있어서,In the elliptic curve cryptography method, the elliptic curve cryptography device performs a finite field inverse multiplication, 상기 타원 곡선 암호 연산 장치가 상기 유한체 승산을 위한 중간값 및 최종값, 피역승수인 제1값, 소수인 제2값을 설정하고, 상기 중간값 및 상기 최종값을 초기화하는 제1단계;A first step of setting, by the elliptic curve cryptographic calculation device, an intermediate value and a final value for the finite field multiplication, a first value that is a multiplicand, and a second value that is a decimal number, and initializing the intermediate value and the final value; 상기 타원 곡선 암호 연산 장치가 상기 제1 값을 1/2하는 제2-1단계와, 상기 중간값이 짝수이면 상기 중간값을 1/2하는 제2-2단계와, 상기 중간값이 짝수가 아니면 상기 중간값과 상기 제2값의 합을 1/2한 값을 상기 중간값으로 하는 제2-3단계를, 상기 제1 값이 짝수인 동안 반복하는 제2단계;Step 2-1 in which the elliptic curve cryptography device halves the first value; step 2-2 in which the median is even; Or a second step of repeating steps 2 to 3, wherein the intermediate value is 1/2 of the sum of the intermediate value and the second value, while the first value is even; 상기 타원 곡선 암호 연산 장치가 상기 최종값을 1/2하는 제3-1단계와, 상기 최종값이 짝수이면 상기 최종값을 1/2하는 제3-2단계와, 상기 최종값이 짝수가 아니면 상기 최종값과 상기 제2값의 합을 1/2한 값을 상기 최종값으로 하는 제3-3단계를, 상기 제2값이 짝수인 동안 반복하는 제3단계;Step 3-1 in which the elliptic curve cryptography apparatus halves the final value; step 3-2 in which the final value is even; A third step of repeating steps 3-3, wherein the final value is half of the sum of the final value and the second value, while the second value is an even number; 상기 타원 곡선 암호 연산 장치가 상기 제1 값이 상기 제2 값 이상이면, 상기 제1 값에서 상기 제2 값을 뺀 값을 상기 제1 값으로 하고 상기 중간값에서 상기 최종값을 뺀 값을 상기 중간값으로 하는 제4-1단계와, 그렇지 않으면 상기 제2값에서 상기 제1 값을 뺀 값을 상기 제2값으로 하고, 상기 최종값에서 상기 중간값을 뺀 값을 상기 최종값으로 하는 제4-2단계; 및If the elliptic curve cryptographic device is the first value is greater than or equal to the second value, the value obtained by subtracting the second value from the first value is the first value and the value obtained by subtracting the final value from the median value is determined. A step 4-1 of setting the intermediate value to the second value; otherwise, the second value is obtained by subtracting the first value from the second value, and the final value is obtained by subtracting the final value from the final value. Step 4-2; And 상기 타원 곡선 암호 연산 장치가 상기 제2 단계, 제3 단계, 그리고 제4 단계를 수행한 다음에 최종적으로 구해진 상기 최종값을 상기 제2 값으로 모듈러 연산하고 그 결과값을 출력하는 제5단계A fifth step of performing the second step, the third step, and the fourth step by the elliptic curve cryptographic device, and then modularly calculating the finally obtained final value as the second value and outputting the result value. 를 포함하는 타원곡선 암호 연산 방법.Elliptic curve encryption method comprising a. 제5항에 있어서,The method of claim 5, 상기 제2단계 내지 제5단계는 상기 제1 값이 0이 아닌 동안 반복되는 타원곡선 암호 연산 방법.And the second to fifth steps are repeated while the first value is not zero.
KR1020090048259A 2008-12-11 2009-06-01 method for evaluating Elliptic Curve Cryptosystem KR101136972B1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
KR1020080126108 2008-12-11
KR20080126108 2008-12-11

Publications (2)

Publication Number Publication Date
KR20100067590A KR20100067590A (en) 2010-06-21
KR101136972B1 true KR101136972B1 (en) 2012-04-19

Family

ID=42366238

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020090048259A KR101136972B1 (en) 2008-12-11 2009-06-01 method for evaluating Elliptic Curve Cryptosystem

Country Status (1)

Country Link
KR (1) KR101136972B1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102241252B1 (en) * 2020-12-03 2021-04-15 국민대학교산학협력단 Method, apparatus and system for performing modular arithmetic

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101423947B1 (en) * 2011-08-31 2014-08-01 고려대학교 산학협력단 Modular multiplication and modular exponentiation using extended NIST prime
KR102272862B1 (en) * 2017-04-27 2021-07-05 한국전자통신연구원 Prime field divider and method thereof
KR102360837B1 (en) * 2021-03-29 2022-02-08 국민대학교산학협력단 Method, apparatus and system for operating point multiplication

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20040050742A (en) * 2002-12-09 2004-06-17 한국전자통신연구원 Apparatus for public key cryptography on the prime field
KR100480997B1 (en) 2002-12-21 2005-04-07 한국전자통신연구원 APPARATUS OF FIELD MULTIPLICATION OVER GF(p) AND GF(2^m)

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20040050742A (en) * 2002-12-09 2004-06-17 한국전자통신연구원 Apparatus for public key cryptography on the prime field
KR100480997B1 (en) 2002-12-21 2005-04-07 한국전자통신연구원 APPARATUS OF FIELD MULTIPLICATION OVER GF(p) AND GF(2^m)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102241252B1 (en) * 2020-12-03 2021-04-15 국민대학교산학협력단 Method, apparatus and system for performing modular arithmetic

Also Published As

Publication number Publication date
KR20100067590A (en) 2010-06-21

Similar Documents

Publication Publication Date Title
Javeed et al. High performance hardware support for elliptic curve cryptography over general prime field
Aysu et al. Low-cost and area-efficient FPGA implementations of lattice-based cryptography
Erdem et al. A general digit-serial architecture for montgomery modular multiplication
Javeed et al. Radix-4 and radix-8 booth encoded interleaved modular multipliers over general F p
Khan et al. High-speed FPGA implementation of full-word Montgomery multiplier for ECC applications
JP2004326112A (en) Multiple modulus selector, accumulator, montgomery multiplier, method of generating multiple modulus, method of producing partial product, accumulating method, method of performing montgomery multiplication, modulus selector, and booth recorder
Shah et al. A high‐speed RSD‐based flexible ECC processor for arbitrary curves over general prime field
Salman et al. A scalable ECC processor implementation for high-speed and lightweight with side-channel countermeasures
KR101136972B1 (en) method for evaluating Elliptic Curve Cryptosystem
KR101925868B1 (en) Modular arithmetic unit and secure system having the same
US7412474B2 (en) Montgomery modular multiplier using a compressor and multiplication method
Ozcan et al. A high performance full-word Barrett multiplier designed for FPGAs with DSP resources
KR102496446B1 (en) Word-parallel calculation method for modular arithmetic
Brumley et al. Conversion algorithms and implementations for Koblitz curve cryptography
Özcan et al. A fast digit based Montgomery multiplier designed for FPGAs with DSP resources
Jarvinen et al. Efficient circuitry for computing τ-adic non-adjacent form
Kadu et al. Hardware implementation of efficient elliptic curve scalar multiplication using vedic multiplier
KR100954583B1 (en) Serial apparatus and method for finite field multiplication using polynomial basis
KR20140089230A (en) Mutiplication method and modular multiplier using redundant form recoding
KR100480997B1 (en) APPARATUS OF FIELD MULTIPLICATION OVER GF(p) AND GF(2^m)
KR20060037941A (en) Apparatus for hybrid multiplier in gf(2^m) and method for multiplying
Kadu et al. A novel efficient hardware implementation of elliptic curve cryptography scalar multiplication using vedic multiplier
KR20070062901A (en) Apparatus and method for modular multiplication using chhinese remainder theorem and carry save adder
Huzaifa et al. Low latency Montgomery multiplier for cryptographic applications
Gutub et al. Efficient scalable hardware architecture for Montgomery inverse computation in GF (p)

Legal Events

Date Code Title Description
A201 Request for examination
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right
GRNT Written decision to grant
FPAY Annual fee payment

Payment date: 20160330

Year of fee payment: 5

FPAY Annual fee payment

Payment date: 20190430

Year of fee payment: 8