KR20050102291A - Method and apparatus for protecting public key cryptosystems from side-channel attacks, and computer readable record medium stored thereof method - Google Patents

Method and apparatus for protecting public key cryptosystems from side-channel attacks, and computer readable record medium stored thereof method Download PDF

Info

Publication number
KR20050102291A
KR20050102291A KR1020040027570A KR20040027570A KR20050102291A KR 20050102291 A KR20050102291 A KR 20050102291A KR 1020040027570 A KR1020040027570 A KR 1020040027570A KR 20040027570 A KR20040027570 A KR 20040027570A KR 20050102291 A KR20050102291 A KR 20050102291A
Authority
KR
South Korea
Prior art keywords
calculating
mod
public key
temp
message
Prior art date
Application number
KR1020040027570A
Other languages
Korean (ko)
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 삼성전자주식회사
Priority to KR1020040027570A priority Critical patent/KR20050102291A/en
Publication of KR20050102291A publication Critical patent/KR20050102291A/en

Links

Classifications

    • EFIXED CONSTRUCTIONS
    • E02HYDRAULIC ENGINEERING; FOUNDATIONS; SOIL SHIFTING
    • E02BHYDRAULIC ENGINEERING
    • E02B3/00Engineering works in connection with control or use of streams, rivers, coasts, or other marine sites; Sealings or joints for engineering works in general
    • E02B3/04Structures or apparatus for, or methods of, protecting banks, coasts, or harbours
    • E02B3/12Revetment of banks, dams, watercourses, or the like, e.g. the sea-floor
    • E02B3/129Polyhedrons, tetrapods or similar bodies, whether or not threaded on strings
    • EFIXED CONSTRUCTIONS
    • E02HYDRAULIC ENGINEERING; FOUNDATIONS; SOIL SHIFTING
    • E02BHYDRAULIC ENGINEERING
    • E02B3/00Engineering works in connection with control or use of streams, rivers, coasts, or other marine sites; Sealings or joints for engineering works in general
    • E02B3/16Sealings or joints
    • EFIXED CONSTRUCTIONS
    • E02HYDRAULIC ENGINEERING; FOUNDATIONS; SOIL SHIFTING
    • E02DFOUNDATIONS; EXCAVATIONS; EMBANKMENTS; UNDERGROUND OR UNDERWATER STRUCTURES
    • E02D29/00Independent underground or underwater structures; Retaining walls
    • E02D29/02Retaining or protecting walls
    • E02D29/0208Gabions
    • EFIXED CONSTRUCTIONS
    • E02HYDRAULIC ENGINEERING; FOUNDATIONS; SOIL SHIFTING
    • E02DFOUNDATIONS; EXCAVATIONS; EMBANKMENTS; UNDERGROUND OR UNDERWATER STRUCTURES
    • E02D29/00Independent underground or underwater structures; Retaining walls
    • E02D29/02Retaining or protecting walls
    • E02D29/025Retaining or protecting walls made up of similar modular elements stacked without mortar

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Structural Engineering (AREA)
  • Environmental & Geological Engineering (AREA)
  • Ocean & Marine Engineering (AREA)
  • Mechanical Engineering (AREA)
  • Civil Engineering (AREA)
  • Chemical & Material Sciences (AREA)
  • Crystallography & Structural Chemistry (AREA)
  • Inorganic Chemistry (AREA)
  • Storage Device Security (AREA)

Abstract

두 소수(p, q)를 비밀키로, n=p*q를 만족하는 n을 공개키, phi(n)과 서로 소인 정수 e를 공개키로, ed=1 mod phi(n)을 만족시키는 d를 비밀키로 이용하는 CRT에 기초한 RSA 공개키 암호화 방식을 이용한 암호화 장치는 상기 두 소수(p, q), 상기 비밀키(d) 및 상기 공개키(e)로부터 dp=d mod (p-1), dq=d mod(q-1), ep=e mod (p-1), eq=e mod (q-1), pi= p-1 mod q, qi=q-1 mod p을 계산하는 제1연산수단; 메시지(M), 상기 두 소수(p, q), 및 상기 제1연산수단으로부터 출력되는 계산 값들에 기초하여 를 계산하는 제2연산수단; 상기 M, 상기 ep, 상기 eq, 상기 p, 및 상기 q에 기초하여 를 계산하는 제3연산수단; 상기 Tp와 상기 Tq를 배타 논리합(XOR)하고, 그 결과를 생성하는 제4연산수단; 상기 Sp, Sq, p, q, pi 및 qi를 수신하고, 이들에 기초하여 를 계산하는 제5연산수단; 및 상기 제5연산수단으로부터 출력된 S를 수신하고, 수신된 Sp가 (S mod p)와 일치하는지의 여부 및 상기 Sq가 (S mod q)와 일치하는지의 여부에 기초하여 상기 S를 상기 서명하고자 하는 메시지(M)에 대한 전자서명으로서 출력하는 디지털 서명 출력수단을 구비한다.With two prime numbers (p, q) as the secret key, n satisfying n = p * q is the public key, phi (n) and the prime integer e are public keys, and ed = 1 mod phi (n) An encryption apparatus using an RSA public key encryption method based on a CRT used as a secret key includes dp = d mod (p-1), dq from the two prime numbers (p, q), the secret key (d), and the public key (e). First operation to calculate = d mod (q-1), ep = e mod (p-1), eq = e mod (q-1), pi = p -1 mod q, qi = q -1 mod p Way; Based on the message M, the two prime numbers p, q and the calculated values output from the first computing means Wow Second operation means for calculating a; Based on the M, ep, eq, p, and q Third operation means for calculating a; Fourth operation means for performing an exclusive OR on the Tp and the Tq and generating a result; Receive the Sp, Sq, p, q, pi and qi and based on them Fifth calculation means for calculating a; And receiving S output from the fifth calculating means and signing the S based on whether the received Sp matches (S mod p) and whether Sq matches (S mod q). And digital signature output means for outputting as an electronic signature for the message M to be intended.

Description

부가채널 공격들로부터 공개키 암호 시스템을 보호하기 위한 방법과 장치, 및 상기 방법을 기록한 컴퓨터로 읽을 수 있는 기록매체{Method and apparatus for protecting public key cryptosystems from side-channel attacks, and computer readable record medium stored thereof method}Method and apparatus for protecting public key cryptosystems from side-channel attacks, and computer readable record medium stored method method}

본 발명은 암호화 장치와 암호화 방법에 관한 것으로, 보다 상세하게는 CRT(Chinese remainder theorem)에 기반을 둔 RSA(Rivest, Shamir and Adleman)공개키 암호화 방법과 장치, 및 상기 방법을 기록한 컴퓨터로 읽을 수 있는 기록매체에 관한 것으로, 더 상세하게는 CRT에 기반을 둔 RSA공개키 암호화 방법을 이용한 디지털 서명장치와 디지털 서명방법, 및 상기 방법을 기록한 컴퓨터로 읽을 수 있는 기록매체에 관한 것이다.The present invention relates to an encryption apparatus and an encryption method, and more particularly, to a method and apparatus for RSA (Rivest, Shamir and Adleman) public key based on Chinese remainder theorem (CRT), and a computer readable recording the method. More particularly, the present invention relates to a digital signature device and a digital signature method using an RSA public key encryption method based on a CRT, and to a computer readable recording medium recording the method.

정보화 사회의 도래와 함께 암호 알고리듬과 암호 프로토콜을 이용한 정보의 보호는 그 중요성을 더해가고 있다. 이러한 암호 알고리듬 중에서 RSA를 포함하는 공개키 암호 알고리듬은 AES를 포함하는 비밀키 암호 알고리듬의 단점인 키 분배 문제, 전자서명 문제 등을 해결하면서 인터넷이나 금융망 등과 같은 여러 가지 응용분야에 빠르게 적용되어 가고있다.With the advent of the information society, the protection of information using cryptographic algorithms and cryptographic protocols is increasing in importance. Among these cryptographic algorithms, public key cryptography algorithms including RSA are rapidly being applied to various applications such as the Internet and financial networks while solving key distribution problems and digital signature problems which are disadvantages of secret key cryptography algorithms including AES. have.

그 중 가장 먼저 제안된 공개키 암호화 방식인 RSA 알고리듬은 다음과 같은 과정으로 암호화/복호화, 전자서명의 생성/검증이 이루어진다.The RSA algorithm, which is the first proposed public key encryption method, is composed of encryption / decryption and digital signature generation / verification by the following process.

먼저, 암호화 통신을 원하는 제1사용자는 큰 두 소수(prime; p, q)를 생성하고 n=p*q를 계산한다. 또한 phi(n)=(p-1)*(q-1)과 서로 소(relatively prime)인 정수 e를 선택하고, ed=1 mod phi(n)을 만족시키는 d를 계산한 후, (n, e)를 공개키로 공개하고, (p, q, d)를 비밀키로 저장한다. First, a first user wanting encrypted communication generates two large primes (p, q) and calculates n = p * q. Also select phi (n) = (p-1) * (q-1) and a relatively prime integer e, calculate d that satisfies ed = 1 mod phi (n), and then (n e) is published as a public key and (p, q, d) is stored as a private key.

제1사용자에게 메시지(M)를 비밀리에 전송하고자 하는 제2사용자는 상기 제1사용자의 공개키(n, e)를 이용하여 수학식1과 같은 모듈라 지수승(modular exponentiation) 연산을 수행한 후, 그 결과 값(C)을 상기 제1사용자에게 전송한다.The second user who wants to secretly transmit the message (M) to the first user performs a modular exponentiation (Equation 1) using the public key (n, e) of the first user after The resultant value C is transmitted to the first user.

상기 결과 값(C)을 상기 제2사용자로부터 전송 받은 상기 제1사용자는 자신의 비밀키(d)를 이용하여 수학식 2와 같은 모듈라 지수승 연산을 통해 원래의 메시지(M)을 복구한다.The first user, having received the result value C from the second user, recovers the original message M through a modular exponential operation as shown in Equation 2 using its secret key d.

상기 메시지(M)에 전자서명을 하기를 원하는 제1사용자는 자신의 비밀키(d)를 이용하여 수학식 3과 같은 연산을 통해 상기 메시지(M)의 전자서명(S)를 생성하다.The first user who wants to digitally sign the message (M) generates an electronic signature (S) of the message (M) through an operation as shown in Equation (3) using his private key (d).

메시지(M)와 전자서명(S)을 수신하고, 상기 전자서명(S)이 제1사용자가 작성한 메시지(M)의 서명이라는 것을 검증하고 싶은 제2사용자는 제1사용자의 공개키(n, e)를 이용하여 수학식 4와 같은 연산을 수행한 후 나온 결과 값(M')이 메시지(M)와 같다는 것을 이용해서 전자서명(S)이 제1사용자가 작성한 메시지(M)의 서명이라는 것을 검증할 수 있다.A second user who receives the message M and the digital signature S, and wants to verify that the digital signature S is the signature of the message M created by the first user, has the public key n, e) the result of performing the operation as shown in Equation 4 using the result value (M ') is the same as the message (M), the digital signature (S) is a signature of the message (M) created by the first user Can be verified.

RSA 공개키 암호 시스템에서 공개키(n, e)로부터 비밀키(p, q, d)를 알아내는 문제는 n=p*q로부터 그 소인수 p, q를 알아내는 문제, 즉 n을 소인수 분해하는 문제와 같다.In the RSA public key cryptosystem, the problem of finding the secret key (p, q, d) from the public key (n, e) is to find its prime factor p, q from n = p * q, that is, the factorization of n It's like a problem.

따라서 현재의 컴퓨터 연산능력과 소인수 분해 알고리듬의 발전정도를 고려하면, 상기 RSA에서 사용되는 n의 크기는 적어도 1024비트 이상이 될 것이다.Therefore, considering the current computer computing power and the degree of development of the prime factorization algorithm, the size of n used in the RSA will be at least 1024 bits.

그러나 상기 RSA의 기본 연산인 모듈라 지수승 연산을 수행하기 위해서는 많은 계산량이 요구된다. 특히 스마트 카드와 같이 제한된 연산능력과 메모리를 가진 연산환경에서는 많은 문제점을 야기한다. 이러한 문제점을 보완하기 위해서 CRT에 기반한 모듈라 지수승 연산 방법이 RSA의 복호화 연산이나 전자 서명 생성 연산에 적용될 수 있으며 이 방법은 CRT를 사용하지 않는 방법에 비해서 약 4배 정도의 속도 향상을 가져올 수 있다.However, a large amount of computation is required to perform the modular exponential operation, which is the basic operation of the RSA. In particular, computing environments with limited computing power and memory, such as smart cards, cause many problems. To solve this problem, CRT-based modular exponential operation method can be applied to RSA decoding operation or digital signature generation operation, which can bring about 4 times faster than CRT method. .

그리나, CRT에 기반을 둔 RSA(CRT_RSA) 복호화 방법이나 전자서명 방법은 여러 가지 부가채널 공격(side-channel attacks)과 오류 공격(fault attacks)에 취약하다. 상기 부가채널 공격이란 암호연산을 수행하는 도중에 노출되는 부가정보를 이용해서 암호 시스템 내부의 비밀키 관련 정보를 추출하는 공격 방법으로, Kocher 등이 제안한 시간공격(timing attack)과 전력공격(power attack)등이 있다.However, the CRT-based RSA (CRT_RSA) decryption method or the digital signature method is vulnerable to various side-channel attacks and fault attacks. The additional channel attack is an attack method for extracting secret key related information inside the cryptographic system by using additional information exposed during cryptographic operation. The timing and power attack proposed by Kocher et al. Etc.

또한, 오류 공격(fault attack)이란 Boneh 등에 의해 제안된 공격방법으로 암호연산을 수행하는 장치에 일시적인 오류나 항구적인 오류(permanent fault)를 주입함으로써 생성되는 잘못된 계산결과를 분석하여 시스템 내부의 비밀키 관련 정보를 추출하는 방법이다.In addition, fault attack is an attack method proposed by Boneh et al., Which analyzes the incorrect calculation result generated by injecting temporary error or permanent fault into the device that performs cryptographic operation, and analyzes the secret key in the system. How to extract information.

먼저 RSA 암호시스템에 대한 시간공격은 지수승 알고리듬 내부에서 수행되는 제곱 연산과 곱셈 연산의 연산 수행 시간이 다를 수 있다는 점, 지수의 비트가 0인 경우와 1인 경우의 연산 수행 시간이 다를 수 있다는 점, 그리고 메시지에 따라서 지수승 연산 시간이 달라질 수 있다는 사실 등을 이용해서 비밀키나 비밀키의 Hamming weight (비밀키의 이진 전개에서 1의 개수) 등을 도출해내는 공격 방법이다. First, the time attack on the RSA cryptosystem is that the square and multiplication operations performed inside the exponential multiplication algorithm may have different execution times, and that the execution time may be different when the bits of the exponent are zero and one. It is an attack method that derives the secret key or Hamming weight (number of 1s from the binary expansion of the secret key) using the fact that the exponent operation time may vary depending on the point and the message.

이러한 시간 공격에 대해서 여러 가지 대응책(countermeasure)이 제안되었으며 대표적으로는 지수의 각 비트에 상관없이 연산 시간이 동일하도록 허위 연산(dummy operation)을 삽입하는 방법, 지수부분을 난수를 이용해서 마스킹을 하는 방법, 메시지를 난수를 이용해서 마스킹을 하는 방법 등이 있다. 본 발명은 허위 연산을 이용해서 시간 공격에 대한 대응책을 제공하며 그 적용 방식에 있어서 연산 시간을 최적화하는 방법을 사용한다.Several countermeasures have been proposed for this time attack, typically a method of inserting a dummy operation so that the operation time is the same regardless of each bit of the exponent, and masking the exponent part using random numbers. There are ways to mask messages using random numbers. The present invention provides a countermeasure against time attack by using a false calculation and uses a method of optimizing the calculation time in the application method.

다음으로 RSA 암호시스템에 대한 전력공격은 단순 전력 공격(simple power attack)과 차분 전력 공격 (differential power attack)이 있으며, 그 기본 원리는 암호화 장치가 소모하는 전력과 내부 레지스터의 상태는 서로 연관이 되어 있으며 따라서 이러한 전력을 분석함으로써 비밀키를 도출할 수 있다는 데에 있다. 이러한 전력 공격에 대해서 여러 가지 대응책이 제안되었으며 대표적으로는 지수부분을 난수를 이용해서 마스킹을 하는 방법, 메시지를 난수를 이용해서 마스킹을 하는 방법 등이 있다. 본 발명은 메시지를 난수를 이용해서 마스킹을 하는 방법을 허위 연산 삽입 방법과 함께 사용해서 전력 공격에 대한 대응책을 제공하며 그 적용 방식에 있어서 연산 시간을 최적화한다.Next, power attacks against RSA cryptosystems are simple power attacks and differential power attacks. The basic principle is that the power consumed by an encryption device and the state of internal registers are correlated. Therefore, the secret key can be derived by analyzing such power. Various countermeasures have been proposed for such a power attack, and there are representative methods of masking the exponential part using random numbers and masking a message using random numbers. The present invention provides a countermeasure against power attack by using a method of masking a message using a random number together with a false operation insertion method and optimizes operation time in the application method.

마지막으로 CRT-RSA 암호 시스템은 일반적인 RSA 암호시스템에 비해서 오류 공격에 특히 더 취약하다는 것이 알려져 있다. Boneh 와 Lenstra 등에 의해 처음으로 제안된 상기 CRT-RSA에 대한 오류 공격은 어떤 메시지에 대해 두 개의 소수 중 하나의 소수에 대한 서명연산과정에 오류를 주입해서 틀린 전자서명을 발생시킬 수 있으면, 다른 소수를 복구해 낼 수 있음을 이용한다. Finally, it is known that the CRT-RSA cryptosystem is particularly vulnerable to error attack compared to the normal RSA cryptosystem. The error attack on the CRT-RSA, first proposed by Boneh and Lenstra et al., Can inject an error in the signature operation of one of two prime numbers for a message and cause an invalid digital signature, Can be recovered.

상기 오류 공격은 오류의 발생 원인에 대한 제약을 두지 않으며 또한 매우 간단하게 CRT-RSA 암호 시스템을 공격할 수 있기 때문에 가장 강력한 공격 방법으로 알려져 있으며 따라서 여러 가지 대응책이 제안되었다. 그 중에서 대표적인 것은 서명 출력 전 확인 단계를 삽입하는 방법, Shamir가 제안한 방법 등이 있다. 먼저, 서명 출력 전 확인 단계를 삽입하는 방법이란, 전자 서명 생성시 출력될 서명(S)을 공개키(e)를 이용해 지수승 연산 (Se mod n)을 수행한 후 그 값이 메시지(M)와 동일한지를 검사하고, 만약 같으면 오류가 발생하지 않은 서명으로 간주해서 출력을 하고, 그렇지 않으면 서명 연산을 다시 수행하도록 하는 방법을 의미한다.The error attack is known as the most powerful attack method because it does not restrict the cause of the error and can attack the CRT-RSA cryptosystem very simply, and therefore, various countermeasures have been proposed. Typical examples include inserting the verification step before signature output and Shamir's method. First, a method of inserting a verification step before outputting a signature is to perform an exponential power operation (S e mod n) using a public key (e) on a signature (S) to be output when a digital signature is generated. ), And if they are the same, then the output is assumed to be an error-free signature, otherwise the signature operation is performed again.

그러나 이 방법은 그 수행 중에 조건 검사 명령을 수행하게 되며 이러한 조건 검사 명령은 또 다른 부가 채널 공격에 취약함이 알려져 있기 때문에 바람직하지 않다. Shamir가 미국 특허 제 5,991,415에서 제안한 방법은, 먼저 짧은 길이의 난수(r)을 생성한 후 다음 수학식과 같은 서명 생성 중간 결과값(Up, Uq)m를 생성한다.However, this method is not preferable because it performs a condition check command during its execution, which is known to be vulnerable to another additional channel attack. Shamir's method proposed in US Pat. No. 5,991,415 first generates a short length random number r, and then generates a signature generation intermediate result (Up, Uq) m as shown in the following equation.

이제 서명 검증 단계로 Up mod r 과 Uq mod r 를 생성한 후, 그 두 값이 같은 지를 검사하고, 만약 두 값이 다르면 오류가 발생한 서명이므로 서명 생성 연산을 다시 수행하고 두 값이 같으면 다음 수학식과 같이 Sp, Sq를 생성하고 CRT를 이용해서 서명 S를 생성하여 그 값을 출력한다.Now generate up mod r and Uq mod r as the signature verification step, and check if the two values are the same, and if the two values are different, perform the signature generation operation again because the signature is in error. Similarly, Sp and Sq are generated, and the signature S is generated using the CRT and the value is output.

그러나 이 방법은 다음과 같은 문제점들이 있다. 첫째, 이론적으로 감지할 수 없는 오류의 확률이 1/r만큼 존재한다. 즉, 오류가 발생을 하였지만 Up mod r = Uq mod r이 되어 오류를 감지할 수 없는 경우가 존재하고 그 확률은 1/r이 된다. 여기서 큰 r을 선택하게 되면 감지할 수 없는 오류의 확률을 줄일 수 있지만 그 만큼 커진 모듈러스(p*r, q*r)에 대한 모듈라 지수승 연산을 해야 하기 때문에 많은 연산 오버헤드(overhead)가 발생한다. 반대로 작은 r을 선택하면 연산 오버헤드는 줄일 수 있지만 감지할 수 없는 오류 발생 확률이 커지게 되므로 바람직하지 않다. However, this method has the following problems. First, there is 1 / r probability of error that cannot be theoretically detected. That is, there is a case where an error occurs but the error cannot be detected because Up mod r = Uq mod r, and the probability is 1 / r. Selecting a large r here will reduce the probability of undetectable errors, but it requires a lot of computational overhead because it requires a modulus exponentiation on the increased modulus (p * r, q * r). do. Conversely, choosing a smaller r can reduce computational overhead, but it is not desirable because it increases the probability of undetectable errors.

두 번째의 문제점은 상기 방법은 조건 검사 명령을 수행하게 되면서 또 다른 부가 채널 공격에 취약해 질 수 있다. 세 번째 문제점은 상기 방법의 모듈라 지수승 연산에서 사용되는 모듈러스(p*r, q*r)가 원래의 모듈러스(p,q)에서 확장이 된 형태이기 때문에 기존 시스템과의 호환성에 문제가 생길 수 있다. 본 발명은 CRT를 이용해서 서명을 생성하는 과정 중에 하나의 소수에 대해서 오류가 발생한 경우 그 오류가 다른 소수에 대한 결과값에도 영향을 미치도록 함으로써 상기 오류 공격을 불가능하게 한다.The second problem is that the method can be vulnerable to another additional channel attack while performing the condition check command. The third problem is that the modulus (p * r, q * r) used in the modulus exponential operation of the above method is an extension of the original modulus (p, q), which may cause compatibility with the existing system. have. In the present invention, when an error occurs for one prime number during the process of generating a signature using a CRT, the error attack is impossible by making the error affect the result value for the other prime number.

따라서 본 발명이 이루고자 하는 기술적인 과제는 부가채널 공격들로부터 공개키 암호시스템을 보호하기 위한 방법과 장치, 및 상기 방법을 기록한 컴퓨터로 읽을 수 있는 기록매체를 제공하는 것이다.Accordingly, a technical object of the present invention is to provide a method and apparatus for protecting a public key cryptographic system from side channel attacks, and a computer readable recording medium recording the method.

상기 기술적 과제를 달성하기 위한 두 소수(p, q)를 비밀키로, n=p*q를 만족하는 n을 공개키로, phi(n)와 서로 소인 정수 e를 공개키로, e*d=1 mod phi(n)을 만족시키는 d를 비밀키로 이용하는 CRT에 기초한 RSA 공개키 암호화 방식을 이용한 암호화 방법은 상기 두 소수(p, q), 상기 비밀키(d) 및 상기 공개키(e)로부터 을 계산하고 저장하는 단계; 서명하고자 하는 메시지(M), 상기 두 소수(p, q), 상기 dp, 및 dq에 기초하여 를 계산하는 단계; 를 계산하는 단계; 상기 Tp와 상기 Tq를 배타 논리합(XOR)하고 그 결과 값(T)를 생성하는 단계; 를 계산하는 단계; 및 상기 Sp가 (S mod p)와 일치하는지의 여부와 상기 Sq가 (S mod q)와 일치하는지의 여부에 기초하여 상기 S를 상기 서명하고자 하는 메시지(M)에 대한 전자서명으로서 출력하는 단계를 구비한다.In order to accomplish the above technical problem, two prime numbers (p, q) are used as a secret key, n satisfying n = p * q as a public key, phi (n) and a mutually prime integer e as a public key, and e * d = 1 mod The CRT-based RSA public key encryption method using d as a secret key satisfying phi (n) is obtained from the two prime numbers (p, q), the secret key (d) and the public key (e). Calculating and storing; Based on the message (M) to be signed, the two prime numbers (p, q), the dp, and dq Wow Calculating; Calculating; Exclusively ORing the Tp and the Tq and generating a resultant value T; Calculating; And outputting S as an electronic signature for the message M to be signed based on whether Sp matches (S mod p) and Sq matches (S mod q). It is provided.

상기 를 계산하는 단계는 난수(r)를 발생하는 단계; 를 계산하고 그 계산 값을 저장하는 단계; r-1 mod p, M*r-1 mod p, r-1 mod q, 및 M*r-1 mod q를 각각 계산하고, 계산된 각 값을 대응되는 레지스터(Temp_p[0], Temp_p[1]. Temp_q[0] 및 Temp_q[1])에 저장하는 단계; i를 n에서부터 0까지 1씩 감소시키면서 를 계산하고 그 계산된 값을 저장하는 단계; ki가 0인지 1이지의 여부와 mi가 0이지 1인지의 여부에 기초하여 를 계산하는 단계; 및 를 계산하고 상기 Sp와 상기 Sq를 출력하는 단계를 구비한다.remind Wow Computing the step of generating a random number (r); Calculating and storing the calculated value; Compute r -1 mod p, M * r -1 mod p, r -1 mod q, and M * r -1 mod q, respectively, and calculate each calculated value to the corresponding register (Temp_p [0], Temp_p [1). ] Temp_q [0] and Temp_q [1]); decreasing i from n to 0 by 1 Calculating and storing the calculated value; based on whether ki is 0 or 1 and whether mi is 0 or 1 Calculating; And Calculating and outputting the Sp and the Sq.

상기 ki는 dp를 이진전개 했을 때 i번째 계수이고, 상기 dp=kn*2n+…+ki*2i+…+k1*2+k0이고, 상기 mi는 dq를 이진전개 했을 때 i번째 계수이고, 상기 dq=mn*2n+…+mi*2i+…+m1*2+m0이다.Ki is the i th coefficient when dp is binary developed, and dp = kn * 2 n +. + ki * 2 i +… + k1 * 2 + k0, and mi is the i-th coefficient when dq is binary developed, and dq = mn * 2 n +. + mi * 2 i +… + m1 * 2 + m0.

상기 기술적 과제를 달성하기 위한 두 소수(p, q)를 비밀키로, n=p*q를 만족하는 n을 공개키로, phi(n)과 서로 소인 정수 e를 공개키로, ed=1 mod phi(n)을 만족시키는 d를 비밀키로 이용하는 CRT에 기초한 RSA 공개키 암호화 방식을 이용한 암호화 방법은 서명하고자 하는 메시지(M), 상기 두 소수(p, q), 상기 비밀키(d) 및 상기 공개키(e)로부터 을 계산하고 저장하는 단계; 를 계산하는 단계; 를 계산하는 단계; 상기 Tp와 상기 Tq를 배타 논리합(XOR)하고, 그 결과를 생성하는 단계; 를 계산하는 단계; 및 을 계산하고, 상기 S를 상기 서명하고자 하는 메시지 (M)에 대한 전자서명으로서 출력하는 단계를 구비한다.In order to achieve the above technical problem, two prime numbers (p, q) are used as a secret key, n satisfying n = p * q as a public key, phi (n) and a prime integer e which are mutually primed, and ed = 1 mod phi ( An encryption method using an RSA public key encryption method based on CRT using d as a secret key satisfying n) satisfies a message (M) to be signed, the two prime numbers (p and q), the secret key (d), and the public key. from (e) Calculating and storing; Wow Calculating; Calculating; Exclusive ORing the Tp and the Tq and generating a result; Calculating; And And outputting the S as an electronic signature for the message (M) to be signed.

상기 방법을 실행시키기 위한 컴퓨터로 읽을 수 있는 프로그램은 기록매체에 저장된다.A computer readable program for executing the method is stored on the recording medium.

상기 기술적 과제를 달성하기 위한 두 소수(p, q)를 비밀키로, n=p*q를 만족하는 n을 공개키, phi(n)과 서로 소인 정수 e를 공개키로, ed=1 mod phi(n)을 만족시키는 d를 비밀키로 이용하는 CRT에 기초한 RSA 공개키 암호화 방식을 이용한 암호화 장치는 상기 두 소수(p, q), 상기 비밀키(d) 및 상기 공개키(e)로부터 을 계산하는 제1연산수단; 메시지(M), 상기 두 소수(p, q), 및 상기 제1연산수단으로부터 출력되는 계산 값들에 기초하여 를 계산하는 제2연산수단; 상기 M, 상기 ep, 상기 eq, 상기 p, 및 상기 q에 기초하여 를 계산하는 제3연산수단; 상기 Tp와 상기 Tq를 배타 논리합(XOR)하고, 그 결과를 생성하는 제4연산수단; 상기 Sp, Sq, p, q, pi 및 qi를 수신하고, 이들에 기초하여 를 계산하는 제5연산수단; 및 상기 제5연산수단으로부터 출력된 S를 수신하고, 수신된 Sp가 (S mod p)와 일치하는지의 여부 및 상기 Sq가 (S mod q)와 일치하는지의 여부에 기초하여 상기 S를 상기 서명하고자 하는 메시지(M)에 대한 전자서명으로서 출력하는 디지털 서명 출력수단을 구비한다.In order to accomplish the above technical problem, two prime numbers (p, q) are used as a secret key, n satisfying n = p * q is a public key, phi (n) and a prime integer e are mutual keys, and ed = 1 mod phi ( An encryption apparatus using an RSA public key encryption scheme based on CRT using d as a secret key satisfying n) is obtained from the two prime numbers (p, q), the secret key (d), and the public key (e). First operating means for calculating a; Based on the message M, the two prime numbers p, q and the calculated values output from the first computing means Wow Second operation means for calculating a; Based on the M, ep, eq, p, and q Third operation means for calculating a; Fourth operation means for performing an exclusive OR on the Tp and the Tq and generating a result; Receive the Sp, Sq, p, q, pi and qi and based on them Fifth calculation means for calculating a; And receiving S output from the fifth calculating means and signing the S based on whether the received Sp matches (S mod p) and whether Sq matches (S mod q). And digital signature output means for outputting as an electronic signature for the message M to be intended.

상기 제2연산수단은 난수(r)을 발생하는 난수 발생수단; 및 을 생성하고, r-1 mod p, M*r-1 mod p, r-1 mod q, 및 M*r-1 mod q를 각각 계산하고, 계산된 각 값을 대응되는 레지스터(Temp_p[0], Temp_p[1]. Temp_q[0] 및 Temp_q[1])에 저장하고, 를 계산하고, ki의 값과 mi의 값에 기초하여 를 계산하고, 를 출력하는 Sp 및 Sq생성 수단을 구비한다.The second computing means comprises: random number generating means for generating a random number r; And And compute r −1 mod p, M * r −1 mod p, r −1 mod q, and M * r −1 mod q, respectively, and compute each computed value in the corresponding register (Temp_p [0]). , Temp_p [1], Temp_q [0] and Temp_q [1]), Is calculated, and based on the values of ki and mi And calculate Sp and Sq generating means for outputting.

상기 ki는 dp를 이진전개 했을 때 i번째 계수이고, 상기 dp=kn*2n+…+ki*2i+…+k1*2+k0이고, 상기 mi는 dq를 이진전개 했을 때 i번째 계수이고, 상기 dq=mn*2n+…+mi*2i+…+m1*2+m0이다.Ki is the i th coefficient when dp is binary developed, and dp = kn * 2 n +. + ki * 2 i +… + k1 * 2 + k0, and mi is the i-th coefficient when dq is binary developed, and dq = mn * 2 n +. + mi * 2 i +… + m1 * 2 + m0.

상기 기술적 과제를 달성하기 위한 두 소수(p, q)를 비밀키로, n=p*q를 만족하는 n을 공개키로, phi(n)과 서로 소인 정수 e를 공개키로, ed=1 mod phi(n)을 만족시키는 d를 비밀키로 이용하는 CRT에 기초한 RSA 공개키 암호화 방식을 이용한 암호화 장치는 상기 두 소수(p, q), 상기 비밀키(d) 및 상기 공개키(e)로부터 을 계산하는 제1연산수단;In order to achieve the above technical problem, two prime numbers (p, q) are used as a secret key, n satisfying n = p * q as a public key, phi (n) and a prime integer e which are mutually primed, and ed = 1 mod phi ( An encryption apparatus using an RSA public key encryption scheme based on CRT using d as a secret key satisfying n) is obtained from the two prime numbers (p, q), the secret key (d), and the public key (e). First operating means for calculating a;

서명하고자 하는 메시지(M), 상기 두 소수(p, q), 상기 dp 및 상기 dq에 기초하여 를 계산하는 제2연산수단; 상기 제2연산수단으로 부터 출력된 Sp와 Sq, 상기 M, ep, eq, p 및 q에 기초하여 를 계산하는 제3연산수단; 상기 제3연산수단으로부터 출력된 상기 Tp와 상기 Tq를 수신하고, 이들을 배타 논리합(XOR)하고, 그 결과(T)를 출력하는 제4연산수단; 상기 제4연산수단으로부터 출력된 값(T)과 p, q, pi, 및 qi에 기초하여 를 계산하는 제5연산수단; 및 상기 제2연산수단으로부터 출력된 값들(Sp와 Sq), 상기 제4연산수단으로부터 출력된 값(T), 상기 제5연산수단으로부터 출력된 값(D), 상기 p, q, pi 및 qi에 기초하여 를 계산하고, 계산된 S를 상기 서명하고자 하는 메시지(M)에 대한 전자서명으로서 출력하는 디지털 서명 출력수단을 구비한다.Based on the message (M) to be signed, the two prime numbers (p, q), the dp and the dq Wow Second operation means for calculating a; Based on Sp and Sq, M, ep, eq, p and q outputted from the second calculating means Third operation means for calculating a; Fourth computing means for receiving the Tp and the Tq outputted from the third computing means, exclusive-ORing them, and outputting the result T; Based on the value T output from the fourth calculating means and p, q, pi, and qi Fifth calculation means for calculating a; And values Sp and Sq output from the second calculation means, a value T output from the fourth calculation means, a value D output from the fifth calculation means, p, q, pi and qi. Based on And digital signature output means for outputting the calculated S as an electronic signature for the message M to be signed.

본 발명과 본 발명의 동작상의 이점 및 본 발명의 실시에 의하여 달성되는 목적을 충분히 이해하기 위해서는 본 발명의 바람직한 실시예를 예시하는 첨부 도면 및 첨부 도면에 기재된 내용을 참조하여야만 한다.In order to fully understand the present invention, the operational advantages of the present invention, and the objects achieved by the practice of the present invention, reference should be made to the accompanying drawings which illustrate preferred embodiments of the present invention and the contents described in the accompanying drawings.

이하, 첨부한 도면을 참조하여 본 발명의 바람직한 실시예를 설명함으로써, 본 발명을 상세히 설명한다. 각 도면에 제시된 동일한 참조부호는 동일한 부재를 나타낸다.Hereinafter, exemplary embodiments of the present invention will be described in detail with reference to the accompanying drawings. Like reference numerals in the drawings denote like elements.

도 1은 본 발명의 일 실시예에 따른 암호와 방법을 나타내는 흐름도를 나타낸다. 도 2는 본 발명에 따른 Sp와 Sq를 구하는 방법을 나타내는 흐름도를 나타낸다. 도 3은 본 발명의 일 실시예에 따른 암호화 장치의 블락도를 나타낸다. 도 4는 도 3에 도시된 제2연산수단의 상세한 블락도를 나타낸다.1 shows a flow diagram illustrating an encryption and a method in accordance with one embodiment of the present invention. 2 shows a flowchart illustrating a method for obtaining Sp and Sq according to the present invention. 3 is a block diagram of an encryption apparatus according to an embodiment of the present invention. FIG. 4 shows a detailed block diagram of the second computing means shown in FIG.

도 1 내지 도 4를 참조하여 공개키(n, e)와 비밀키(p, q, d)를 사용하여 RSA를 이용한 암호화 장치의 복호화 연산이나 전자서명 연산에 CRT에 기초한 모듈러 지수승 연산을 수행하는 과정을 설명하면 다음과 같다.Referring to FIGS. 1 to 4, a CRT-based modular exponential operation is performed on a decryption operation or an electronic signature operation of an encryption apparatus using an RSA using a public key (n, e) and a secret key (p, q, d). The process of doing this is as follows.

제1연산수단(210)은 두 소수(p, q), 비밀키(d), 및 공개키(e)를 수신하고 (110단계), 수학식 7과 같이 dp, dq, ep, eq, pi, 및 qi를 계산하고, 그 계산결과를 소정의 레지스터에 저장한다(120단계). The first computing means 210 receives two prime numbers (p, q), a secret key (d), and a public key (e) (step 110), and dp, dq, ep, eq, pi as shown in Equation (7). , And qi are calculated and the calculation result is stored in a predetermined register (step 120).

여기서 dp와 dq는 비밀키(d)를 (p-1)와 (q-1)로 각각 모듈러 연산한 결과를 나타내고, ep와 eq는 공개키(e)를 (p-1)과 (q-1)로 각각 모듈러 연산한 결과를 나타내고, pi는 p-1 을 q로 모듈러 연산한 결과를 나타내고, qi는 q-1를 p로 모듈러 연산한 결과를 나타낸다.Where dp and dq represent the result of modular operation of the secret key (d) with (p-1) and (q-1), respectively, and ep and eq represent the public key (e) with (p-1) and (q- 1) shows the result of each modular operation, pi shows the result of the modular operation p- 1 to q, and qi shows the result of the modular operation p- 1 to p.

제2연산수단(220)은 상기 제1연산수단(210)에 의하여 계산된 dp, dq, 비밀키 (p, q), 그리고 서명하고자 하는 메시지(M)를 수신하고(1301단계), 이들을 이용하여 Sp와 Sq를 계산한다. 상기 제2연산수단(220)은 를 계산한다. 여기서 곱셈연산은 모듈러스 p에 대한 모듈러 곱셈(multiplication modulo p)과 모듈러스 q에 대한 모듈러 곱셈을 의미한다.The second computing means 220 receives the dp, dq, secret keys (p, q), and the message M to be signed (step 1301) calculated by the first computing means 210 and uses them. Calculate Sp and Sq. The second operation means 220 Wow Calculate Here, the multiplication operation means modular multiplication of modulus p and modular multiplication of modulus q.

도 3과 도 4를 참조하여, 상기 제2연산수단(220)의 상세한 동작을 설명하면 다음과 같다. 난수 발생수단(221)은 난수(r)를 발생한다(1303단계).3 and 4, detailed operations of the second operation unit 220 will be described below. The random number generating means 221 generates a random number r (step 1303).

C1과 C2 발생수단(223)은 메시지(M)와 난수(r)에 대하여 곱셈연산을 수행하고, 그 결과로서 C1과 C2를 수학식 8과 같이 생성하고(1305단계), 생성된 C1과 C2를 소정의 각각 레지스터에 저장한다. 상기 C1과 C2 발생수단(223)은 시간공격에 대응하기 위하여 암호문에 난수(r)를 곱하는 마스킹 단계를 수행한다. The C1 and C2 generating means 223 performs a multiplication operation on the message M and the random number r, and as a result, generates C1 and C2 as shown in Equation 8 (step 1305), and generates the generated C1 and C2. Is stored in each predetermined register. The C1 and C2 generating means 223 performs a masking step of multiplying the ciphertext by a random number r in order to respond to a time attack.

그리고, C1과 C2 발생수단(223)은 소수(p)에 대한 난수(r)의 곱셈에 대한 역원 r-1 mod p를 수학식 9와 같이 계산하여 그 결과를 레지스터(Temp_p[0]; 미도시)에 저장하고, r-1과 메시지(M)를 곱하여 그 결과를 레지스터(Temp_p[1]; 미도시)에 저장한다(1307단계).The C1 and C2 generating means 223 calculates the inverse r -1 mod p for the multiplication of the random number r with respect to the decimal number p as shown in Equation (9) and registers the result of the register (Temp_p [0]; And multiply r −1 by the message M and store the result in a register Temp_p [1] (not shown) (step 1307).

그리고, C1과 C2 발생수단(223)은 소수(q)에 대한 난수(r)의 곱셈에 대한 역원 r-1 mod q를 수학식 10과 같이 계산하여 그 결과를 도시되지 않은 레지스터 (Temp_q[0])에 저장하고, r-1과 메시지(M)를 곱하여 그 결과를 도시되지 않은 레지스터(Temp_q[1])에 저장한다(1307단계).The C1 and C2 generating means 223 calculates the inverse r -1 mod q for the multiplication of the random number r with respect to the prime number q as shown in Equation 10, and the result is a register (Temp_q [0]). ], And multiplies r −1 by the message M to store the result in a register (Temp_q [1]) (not shown) (step 1307).

C1과 C2 발생수단(223)은 변수(i)를 n에서 0까지 감소시키면서 C1과 C2를 수학식 11을 통하여 계산하고, 그 결과를 소정의 레지스터에 저장한다. 단, 여기서 ki는 dp를 이진전개 했을 때 i번째 계수이다. The C1 and C2 generating means 223 calculates C1 and C2 through Equation 11 while decreasing the variable i from n to 0, and stores the result in a predetermined register. Where ki is the i-th coefficient when dp is binary developed.

여기서, dp=kn*2n+…+ki*2i+…+k1*2+k0이고, mi는 dq를 이진전개 했을 때 i번째 계수이다. 여기서 dq=mn*2n+…+mi*2i+…+m1*2+m0이다.Where dp = kn * 2 n +... + ki * 2 i +… + k1 * 2 + k0, and mi is the i-th coefficient when dq is binary developed. Where dq = mn * 2 n +... + mi * 2 i +… + m1 * 2 + m0.

상기 C1과 C2 발생수단(223)은 ki가 0이면 C1과 Temp_p[0]에 대하여 곱셈연산을 수행하고 그 결과를 소정의 레지스터에 저장하고, 만일, ki가 1이면 C1과 Temp_p[1]에 대하여 곱셈연산을 수행하고 그 결과를 소정의 레지스터(C2)에 저장한다(1309단계).The C1 and C2 generating means 223 performs a multiplication operation on C1 and Temp_p [0] when ki is 0, and stores the result in a predetermined register. The multiplication operation is performed on the result, and the result is stored in the predetermined register C2 (step 1309).

그리고 C1과 C2 발생수단(223)은 mi가 0이면 C2와 Temp_q[0]에 대하여 곱셈연산을 수행하고 그 결과를 소정의 레지스터(C2)에 저장하고, 만일, mi가 1이면 C2와 Temp_q[1]에 대하여 곱셈연산을 수행하고 그 결과를 소정의 레지스터에 저장한다(1309단계). 즉, 상기 C1과 C2 발생수단(223)은 수학식 12와 같은 연산을 수행한다.The C1 and C2 generating means 223 performs a multiplication operation on C2 and Temp_q [0] when mi is 0, and stores the result in a predetermined register C2. If mi is 1, C2 and Temp_q [ Multiplication is performed in step 1309 and the result is stored in a predetermined register (step 1309). That is, the C1 and C2 generating means 223 performs an operation as shown in Equation 12.

Sp와 Sq 생성수단(225)은 p, q, 상기 C1과 C2 발생수단(223)에 의하여 계산된 C1과 C2, Temp_p[ki]와 Temp_q[mi]를 수신하고, 이들을 곱하여 수학식 13과 같이 Sp와 Sq를 계산하고, 그 결과를 대응되는 레지스터(미 도시)에 저장하고(1311단계), Sp와 Sq를 제3연산수단(230)으로 출력한다(1313단계).Sp and Sq generating means 225 receives p, q, C1 and C2 calculated by the C1 and C2 generating means 223, Temp_p [ki] and Temp_q [mi], and multiplies them to obtain Equation (13). Sp and Sq are calculated, and the result is stored in a corresponding register (not shown) (step 1311), and Sp and Sq are output to the third calculating means 230 (step 1313).

즉, 제2연산수단(220)은 1307단계 내지 1313단계를 통하여 시간공격과 전력공격에 대비하기 위하여 1305단계에서 생성된 데이터에 더미연산을 포함한 CRT에 기반을 둔 모듈러 지수승 연산을 수행한다. That is, the second operation unit 220 performs a modular exponential operation based on the CRT including a dummy operation on the data generated in step 1305 to prepare for a time attack and a power attack through steps 1307 to 1313.

제3연산수단(230)은 메시지(M), ep, eq, p, 및 q를 이용하여 수학식 14와 같이 모듈러 지수승 연산과 모듈러 뺄셈연산을 수행하고, 그 결과로서 발생된 Tp와 Tq를 소정의 레지스터에 저장한다(140단계).The third calculation means 230 performs a modular exponential power operation and a modular subtraction operation using the message M, ep, eq, p, and q as shown in Equation 14, and generates the resulting Tp and Tq. Stored in a predetermined register (step 140).

제4연산수단(240)은 제3연산수단(230)으로부터 출력된 Tp와 Tq를 수신하고, 이들을 배타 논리합(XOR)하여 수학식 15를 통하여 T를 계산한다(150단계).The fourth calculating means 240 receives Tp and Tq output from the third calculating means 230, calculates T through Equation 15 by performing an exclusive OR (XOR) (step 150).

본 발명에 따른 암호화 장치의 제3연산수단(230)과 제4연산수단(240)는 1307단계 내지 1313단계를 통하여 생성된 데이터로부터 일시적인 오류를 검출하기 위한 오류검출 인자를 생성한다. The third operation means 230 and the fourth operation means 240 of the encryption apparatus according to the present invention generate an error detection factor for detecting a temporary error from the data generated in steps 1307 through 1313.

제5연산수단(250)은 T, Sp, Sq, p, q, n, pi 및 qi를 수신하고, 이들에 기초하여, 즉 모듈러스 n에 대하여 덧셈연산을 수행하여 전자서명(S)을 수학식 16과 같이 계산하고, 전자서명(S)을 소정의 레지스터에 저장한다(160단계).The fifth calculating means 250 receives T, Sp, Sq, p, q, n, pi and qi, and adds to the modulus n based on them, i. The calculation is performed as in step 16, and the electronic signature S is stored in a predetermined register (step 160).

제5연산수단(250)은 각 연산수단의 연산과정 중에 발생할 수 있는 장치(예컨대, 스마트 카드)내부의 영구적인 오류(permanent error)를 검출하고 그 결과를 출력한다.The fifth calculation means 250 detects a permanent error in the device (eg, a smart card) that may occur during the calculation of each calculation means and outputs a result.

디지털 서명 출력수단(260)은 제5연산수단(250)이 계산한 전자서명(S)과 Sq와 모듈러스 p에 대하여 합동인지의 여부를 검사한다(170단계). 즉, Sp=S mod p를 만족하는 경우, 상기 디지털 서명 출력수단(260)은 상기 전자서명(S)이 Sq와 모듈러스 p에 대하여 합동인지의 여부를 다시 한번 더 검사한다(180단계). The digital signature output means 260 checks whether the digital signature S calculated by the fifth computation means 250 and Sq and the modulus p are congruent (step 170). That is, when Sp = S mod p, the digital signature output means 260 checks again whether the digital signature S is congruent with respect to Sq and modulus p (step 180).

그 결과 Sq=S mod q가 만족되는 경우, 상기 디지털 서명 출력수단(260)은 전자서명(S)을 메시지(M)에 대한 전자서명으로서 출력한다. 즉, 상기 디지털 서명 출력수단(260)은 Sp=S mod p를 만족시키고 Sq=S mod q가 만족되는 경우에만, 상기 전자서명(S)을 메시지(M)에 대한 전자서명으로서 출력한다(190단계). 그 외의 경우는 상기 전자서명 생성 연산과정을 다시 수행한다.As a result, when Sq = S mod q is satisfied, the digital signature output means 260 outputs the digital signature S as the digital signature for the message M. That is, the digital signature output means 260 outputs the digital signature S as the digital signature for the message M only when Sp = S mod p is satisfied and Sq = S mod q is satisfied (190). step). Otherwise, the digital signature generation operation is performed again.

디지털 서명 출력수단(260)은 각 연산수단에서 생성된 데이터로부터 CRT를 이용하여 원하는 전자서명을 생성한다.The digital signature output means 260 generates a desired digital signature using the CRT from the data generated by each computing means.

도 5는 본 발명의 다른 실시예에 따른 암호와 방법을 나타내는 흐름도를 나타낸다. 도 6은 본 발명에 따른 Sp와 Sq를 구하는 방법을 나타내는 흐름도를 나타낸다. 도 7은 본 발명의 다른 실시예에 따른 암호화 장치의 블락도를 나타낸다.5 is a flowchart illustrating a cryptography and method according to another embodiment of the present invention. 6 shows a flowchart illustrating a method for obtaining Sp and Sq according to the present invention. 7 is a block diagram of an encryption apparatus according to another embodiment of the present invention.

도 4 내지 도 7을 참조하여 공개키(n, e)와 비밀키(p, q, d)를 사용하여 RSA를 이용한 암호화장치의 복호화 연산이나 전자서명 연산에 대하여 CRT에 기초한 모듈러 지수승 연산을 수행하는 과정을 설명하면 다음과 같다.Referring to FIGS. 4 to 7, the CRT-based modular exponential operation is performed on the decryption operation or the digital signature operation of the encryption apparatus using the RSA using the public key (n, e) and the secret key (p, q, d). The following describes the process to be performed.

제1연산수단(210)은 소수(p, q), 비밀키(d) 및 공개키(e)를 수신하고(310단계), 수학식 7과 같이 dp, dq, ep, eq, pi 및 qi를 계산하고, 그 계산결과를 소정의 레지스터에 저장한다(320단계).The first operation means 210 receives a prime number (p, q), a secret key (d) and a public key (e) (step 310), and dp, dq, ep, eq, pi and qi as shown in Equation (7). Is calculated and the calculation result is stored in a predetermined register (step 320).

제2연산수단(220)은 상기 제1연산수단(210)에의 의하여 계산된 dp, dq, 비밀키(p, q), 그리고 서명하고자 하는 메시지(M)를 수신하고(3301단계), 이들을 이용하여 Sp와 Sq를 계산한다. 여기서 곱셈연산은 모듈러스 p에 대한 모듈러 곱셈(multiplication modulo p)과 모듈러스 q에 대한 모듈러 곱셈을 의미한다.The second operation unit 220 receives the dp, dq, secret key (p, q), and the message M to be signed (step 3301) calculated by the first operation unit 210 and uses them. Calculate Sp and Sq. Here, the multiplication operation means modular multiplication of modulus p and modular multiplication of modulus q.

난수 발생수단(221)은 난수(r)를 발생한다(3303단계).The random number generating means 221 generates a random number r (step 3303).

C1과 C2 발생수단(223)은 수학식 8과 같이 메시지(M)와 난수(r)에 대하여 곱셈연산을 수행하고, 그 결과로서 C1과 C2를 발생한다(3305단계).The C1 and C2 generating means 223 performs a multiplication operation on the message M and the random number r as shown in Equation 8, and generates C1 and C2 as a result (step 3305).

C1과 C2 발생수단(223)은 소수(p)에 대한 난수(r)의 곱셈에 대한 역원 r-1 mod p를 수학식 9와 같이 계산하여 그 결과를 레지스터(Temp_p[0])에 저장하고, r-1과 메시지(M)를 곱하여 그 결과를 레지스터(Temp_p[1])에 저장한다(3307단계).The C1 and C2 generating means 223 calculates the inverse r -1 mod p for the multiplication of the random number r with respect to the decimal number p as shown in Equation 9, and stores the result in the register (Temp_p [0]). , r −1 is multiplied by the message M, and the result is stored in the register Temp_p [1] (step 3307).

그리고, C1과 C2 발생수단(223)은 소수(q)에 대한 난수(r)의 곱셈에 대한 역원 r-1 mod q를 수학식 10과 같이 계산하여 그 결과를 레지스터(Temp_q[0])에 저장하고, r-1과 M의 곱하여 그 결과를 레지스터(Temp_q[1])에 저장한다(3307단계).The C1 and C2 generating means 223 calculates the inverse r −1 mod q for the multiplication of the random number r with respect to the decimal number q as shown in Equation 10, and the result is stored in the register Temp_q [0]. And store the result in a register (Temp_q [1]) by multiplying r −1 by M (step 3307).

C1과 C2 발생수단(223)은 i를 n에서 0까지 감소시키면서 C1과 C2를 수학식 11과 같은 연산을 수행하고, 그 결과를 소정의 레지스터에 저장한다. 단, 여기서 ki는 dp를 이진전개 했을 때 i번째 계수이다.The C1 and C2 generating means 223 performs operations similar to Equation 11 while decreasing i from n to 0, and stores the result in a predetermined register. Where ki is the i-th coefficient when dp is binary developed.

여기서 dp=kn*2n+…+ki*2i+…+k1*2+k0이고, mi는 dq를 이진전개 했을 때 i번째 계수이다. 여기서 dq=mn*2n+…+mi*2i+…+m1*2+m0이다.Where dp = kn * 2 n +… + ki * 2 i +… + k1 * 2 + k0, and mi is the i-th coefficient when dq is binary developed. Where dq = mn * 2 n +... + mi * 2 i +… + m1 * 2 + m0.

상기 C1과 C2 발생수단(223)은 수학식 12와 같이 ki가 0이면 C1과 Temp_p[0]에 대하여 곱셈연산을 수행하여 그 결과를 소정의 레지스터에 저장하고, 만일, ki가 1이면 C1과 Temp_p[1]에 대하여 곱셈연산을 수행하여 그 결과를 소정의 레지스터에 저장한다(3309단계).The C1 and C2 generating means 223 performs a multiplication operation on C1 and Temp_p [0] when ki is 0 as shown in Equation 12, and stores the result in a predetermined register. A multiplication operation is performed on Temp_p [1], and the result is stored in a predetermined register (step 3309).

그리고 C1과 C2 발생수단(223)은 수학식 12와 같이 mi가 0이면 C2와 Temp_q[0]에 대하여 곱셈연산을 수행하여 그 결과를 소정의 레지스터에 저장하고, 만일, mi가 1이면 C2와 Temp_q[1]에 대하여 곱셈연산을 수행하여 그 결과를 소정의 레지스터에 저장한다(3309단계). 즉, 상기 C1과 C2 발생수단(223)은 다음과 같은 연산을 수행한다.The C1 and C2 generating means 223 performs a multiplication operation on C2 and Temp_q [0] when mi is 0, as shown in Equation 12, and stores the result in a predetermined register. A multiplication operation is performed on Temp_q [1], and the result is stored in a predetermined register (step 3309). That is, the C1 and C2 generating means 223 performs the following operation.

Sp와 Sq 생성수단(225)은 상기 C1과 C2 발생수단(223)에 의하여 계산된 C1과 C2, Temp_p[ki]와 Temp_q[mi]를 수신하고, 이들을 곱하여 수학식 13과 같이 Sp와 Sq를 계산하여 그 결과를 대응되는 레지스터에 저장하고(3311단계), Sp와 Sq를 제3연산수단(230)으로 출력한다(3313단계).Sp and Sq generating means 225 receives C1 and C2, Temp_p [ki] and Temp_q [mi] calculated by the C1 and C2 generating means 223, multiplies them to obtain Sp and Sq as shown in Equation (13). The calculation results are stored in a corresponding register (step 3311), and Sp and Sq are output to the third calculating means 230 (step 3313).

제3연산수단(230)은 메시지(M), ep, eq, p, 및 q를 이용하여 수학식 14와 같이 모듈러 지수승 연산과 모듈러 뺄셈연산을 수행하고, 그 결과로서 발생된 Tp와 Tq를 소정의 레지스터에 저장한다(340단계).The third calculation means 230 performs a modular exponential power operation and a modular subtraction operation using the message M, ep, eq, p, and q as shown in Equation 14, and generates the resulting Tp and Tq. Stored in a predetermined register (step 340).

제4연산수단(240)은 Tp와 Tq를 수신하고, 수학식 15와 같이 이들을 배타 논리합(XOR)하여 T를 계산한다(350단계).The fourth calculating means 240 receives Tp and Tq, and calculates T by performing an exclusive OR (XOR) on them, as shown in Equation 15 (step 350).

제5연산수단(250)은 T, p, q, pi 및 qi를 수신하고, 비밀키(q)와 T를 배타 논리합하여 얻어진 값과 qi에 대하여 정수뺄셈 연산을 수행한 후 그 결과 값을 모듈러스 p에 대하여 1만큼 모듈러 뺄셈 연산한 값 및 비밀키(p)와 T를 배타 논리합하여 얻어진 값과 pi에 대하여 정수뺄셈 연산을 수행한 후 그 결과 값을 모듈러스 q에 대하여 1만큼 모듈러 뺄셈 연산한 값을 정수 덧셈 연산하여 수학식 17와 같이 생성된 값을 소정의 레지스터에 저장한다(360단계).The fifth calculating means 250 receives T, p, q, pi, and qi, performs an integer subtraction operation on the value obtained by the exclusive OR of the secret key q and T, and qi, and modulates the result value. Modular subtraction operation for p, and the value obtained by exclusive OR of secret key (p) and T, and integer subtraction operation for pi, and then the result of modular subtraction operation of 1 for modulus q In operation 360, the integer addition operation is performed to store the generated value in a predetermined register.

디지털 서명 출력수단(420)은 S1, S2 및 S를 수학식 18과 같이 계산한 후(370단계), 그 결과를 전자서명 S로서 출력한다(380단계).The digital signature output means 420 calculates S1, S2, and S as shown in Equation 18 (step 370), and then outputs the result as the electronic signature S (step 380).

본 발명에 따른 암호화 장치와 암호화 방법은 컴퓨터 시스템에서 실행할 수 있는 프로그램으로 작성가능하다. 또한, 이러한 프로그램을 기록한 컴퓨터로 읽을 수 있는 기록 매체로부터 해당 프로그램을 읽어들여 범용 디지털 컴퓨터 시스템에서 실행될 수 있다. 이러한 기록 매체에는 마그네틱 저장 매체(예를 들면, 롬(ROM), 플로피디스크(floppy disc), 하드디스크 등), 광학적 판독 매체(예를 들면, 씨디롬(CD-ROM), 디브이디(DVD) 등) 및 캐리어 웨이브(예를 들면, 인터넷을 통한 전송)와 같은 매체가 포함된다.An encryption device and an encryption method according to the present invention can be written as a program that can be executed in a computer system. In addition, the program can be read from a computer readable recording medium having recorded such a program and executed in a general-purpose digital computer system. Such recording media include magnetic storage media (e.g., ROM, floppy disk, hard disk, etc.), optical reading media (e.g., CD-ROM, DVD, etc.) And media such as carrier waves (eg, transmission over the Internet).

본 발명은 도면에 도시된 일 실시 예를 참고로 설명되었으나 이는 예시적인 것에 불과하며, 본 기술 분야의 통상의 지식을 가진 자라면 이로부터 다양한 변형 및 균등한 타 실시예가 가능하다는 점을 이해할 것이다. 따라서, 본 발명의 진정한 기술적 보호 범위는 첨부된 등록청구범위의 기술적 사상에 의해 정해져야 할 것이다.Although the present invention has been described with reference to one embodiment shown in the drawings, this is merely exemplary, and those skilled in the art will understand that various modifications and equivalent other embodiments are possible therefrom. Therefore, the true technical protection scope of the present invention will be defined by the technical spirit of the appended claims.

상술한 바와 같이 본 발명에 따른 암호화 장치와 암호화 방법은 시간공격에 안전하게 구현될 수 있다.As described above, the encryption apparatus and the encryption method according to the present invention can be securely implemented in a time attack.

본 발명에 따른 암호화 장치와 암호화 방법은 전력공격에 안전하게 구현될 수 있다.The encryption apparatus and encryption method according to the present invention can be securely implemented in a power attack.

본 발명에 따른 암호화 장치와 암호화 방법은 일시적인 오류주입에 안전하게 구현될 수 있다.The encryption device and encryption method according to the present invention can be securely implemented for temporary error injection.

본 발명에 따른 암호화 장치와 암호화 방법은 영구적인 오류주입에 안전하게 구현될 수 있다. The encryption device and encryption method according to the present invention can be securely implemented for permanent error injection.

본 발명에 따른 암호화 장치와 암호화 방법은 연산수행 시간을 최소화할 수 있는 효과가 있다.The encryption device and the encryption method according to the present invention have the effect of minimizing the operation time.

본 발명의 상세한 설명에서 인용되는 도면을 보다 충분히 이해하기 위하여 각 도면의 상세한 설명이 제공된다.The detailed description of each drawing is provided in order to provide a thorough understanding of the drawings cited in the detailed description of the invention.

도 1은 본 발명의 일 실시예에 따른 암호와 방법을 나타내는 흐름도를 나타낸다.1 shows a flow diagram illustrating an encryption and a method in accordance with one embodiment of the present invention.

도 2는 본 발명에 따른 Sp와 Sq를 구하는 방법을 나타내는 흐름도를 나타낸다.2 shows a flowchart illustrating a method for obtaining Sp and Sq according to the present invention.

도 3은 본 발명의 일 실시예에 따른 암호화 장치의 블락도를 나타낸다.3 is a block diagram of an encryption apparatus according to an embodiment of the present invention.

도 4는 도 3에 도시된 제2연산수단의 상세한 블락도를 나타낸다.FIG. 4 shows a detailed block diagram of the second computing means shown in FIG.

도 5는 본 발명의 다른 실시예에 따른 암호와 방법을 나타내는 흐름도를 나타낸다.5 is a flowchart illustrating a cryptography and method according to another embodiment of the present invention.

도 6은 본 발명에 따른 Sp와 Sq를 구하는 방법을 나타내는 흐름도를 나타낸다.6 shows a flowchart illustrating a method for obtaining Sp and Sq according to the present invention.

도 7은 본 발명의 다른 실시예에 따른 암호화 장치의 블락도를 나타낸다.7 is a block diagram of an encryption apparatus according to another embodiment of the present invention.

Claims (11)

두 소수(p, q)를 비밀키로, n=p*q를 만족하는 n을 공개키로, phi(n)와 서로 소인 정수 e를 공개키로, e*d=1 mod phi(n)을 만족시키는 d를 비밀키로 이용하는 CRT에 기초한 RSA 공개키 암호화 방식을 이용한 암호화 방법에 있어서,Satisfies two primes (p, q) as a private key, n as a public key that satisfies n = p * q, phi (n) and a prime integer e as a public key, and satisfies e * d = 1 mod phi (n) An encryption method using an RSA public key encryption method based on a CRT using d as a secret key, 상기 두 소수(p, q), 상기 비밀키(d) 및 상기 공개키(e)로부터 을 계산하고 저장하는 단계;From the two prime numbers (p, q), the secret key (d) and the public key (e) Calculating and storing; 서명하고자 하는 메시지(M), 상기 두 소수(p, q), 상기 dp, 및 dq에 기초하여 를 계산하는 단계;Based on the message (M) to be signed, the two prime numbers (p, q), the dp, and dq Wow Calculating; 를 계산하는 단계; Calculating; 상기 Tp와 상기 Tq를 배타 논리합(XOR)하고 그 결과 값(T)를 생성하는 단계;Exclusively ORing the Tp and the Tq and generating a resultant value T; 를 계산하는 단계; 및 Calculating; And 상기 Sp가 (S mod p)와 일치하는지의 여부와 상기 Sq가 (S mod q)와 일치하는지의 여부에 기초하여 상기 S를 상기 서명하고자 하는 메시지(M)에 대한 전자서명으로서 출력하는 단계를 구비하는 것을 특징으로 하는 암호화방법. Outputting S as an electronic signature for the message M to be signed based on whether Sp matches (S mod p) and Sq matches (S mod q) Encryption method characterized in that it comprises. 제1항에 있어서, 상기 를 계산하는 단계는,The method of claim 1, wherein Wow The step of calculating 난수(r)를 발생하는 단계;Generating a random number r; 를 계산하고 그 계산 값을 저장하는 단계; Calculating and storing the calculated value; r-1 mod p, M*r-1 mod p, r-1 mod q, 및 M*r-1 mod q를 각각 계산하고, 계산된 각 값을 대응되는 레지스터(Temp_p[0], Temp_p[1]. Temp_q[0] 및 Temp_q[1])에 저장하는 단계;Compute r -1 mod p, M * r -1 mod p, r -1 mod q, and M * r -1 mod q, respectively, and calculate each calculated value to the corresponding register (Temp_p [0], Temp_p [1). ] Temp_q [0] and Temp_q [1]); i를 n에서부터 0까지 1씩 감소시키면서 를 계산하고 그 계산된 값을 저장하는 단계;decreasing i from n to 0 by 1 Calculating and storing the calculated value; ki가 0인지 1이지의 여부와 mi가 0이지 1인지의 여부에 기초하여 를 계산하는 단계; 및based on whether ki is 0 or 1 and whether mi is 0 or 1 Calculating; And 를 계산하고 상기 Sp와 상기 Sq를 출력하는 단계를 구비하는 것을 특징으로 하는 암호화 방법. And calculating Sp and outputting the Sp and the Sq. 제2항에 있어서, 상기 ki는 dp를 이진전개 했을 때 i번째 계수이고, 상기 dp=kn*2n+…+ki*2i+…+k1*2+k0이고, 상기 mi는 dq를 이진전개 했을 때 i번째 계수이고, 상기 dq=mn*2n+…+mi*2i+…+m1*2+m0인 것을 특징으로 하는 암호화 방법.3. The method of claim 2, wherein ki is the i-th coefficient when dp is binary developed, and dp = kn * 2 n +. + ki * 2 i +… + k1 * 2 + k0, and mi is the i-th coefficient when dq is binary developed, and dq = mn * 2 n +. + mi * 2 i +… Encryption method characterized in that + m1 * 2 + m0. 두 소수(p, q)를 비밀키로, n=p*q를 만족하는 n을 공개키로, phi(n)과 서로 소인 정수 e를 공개키로, ed=1 mod phi(n)을 만족시키는 d를 비밀키로 이용하는 CRT에 기초한 RSA 공개키 암호화 방식을 이용한 암호화 방법에 있어서,With two prime numbers (p, q) as the secret key, n satisfying n = p * q as the public key, phi (n) and mutually prime integer e as the public key, and d satisfying ed = 1 mod phi (n) In the encryption method using the RSA public key encryption method based on the CRT used as the secret key, 서명하고자 하는 메시지(M), 상기 두 소수(p, q), 상기 비밀키(d) 및 상기 공개키(e)로부터 을 계산하고 저장하는 단계;From the message (M) to be signed, the two prime numbers (p, q), the secret key (d) and the public key (e) Calculating and storing; 를 계산하는 단계; Wow Calculating; 를 계산하는 단계; Calculating; 상기 Tp와 상기 Tq를 배타 논리합(XOR)하고, 그 결과를 생성하는 단계;Exclusive ORing the Tp and the Tq and generating a result; 를 계산하는 단계; 및 Calculating; And 을 계산하고, 상기 S를 상기 서명하고자 하는 메시지 (M)에 대한 전자서명으로서 출력하는 단계를 구비하는 것을 특징으로 하는 암호화방법. And outputting the S as an electronic signature for the message (M) to be signed. 제4항에 있어서, 상기 를 계산하는 단계는,The method of claim 4, wherein Wow The step of calculating 난수(r)를 발생하는 단계;Generating a random number r; 를 계산하고 그 계산 값을 저장하는 단계; Calculating and storing the calculated value; r-1 mod p, M*r-1 mod p, r-1 mod q, 및 M*r-1 mod q를 각각 계산하고, 계산된 각 값을 대응되는 레지스터(Temp_p[0], Temp_p[1]. Temp_q[0] 및 Temp_q[1])에 저장하는 단계;Compute r -1 mod p, M * r -1 mod p, r -1 mod q, and M * r -1 mod q, respectively, and calculate each calculated value to the corresponding register (Temp_p [0], Temp_p [1). ] Temp_q [0] and Temp_q [1]); i를 n에서부터 0까지 1씩 감소시키면서 를 계산하고 그 계산된 값을 저장하는 단계;decreasing i from n to 0 by 1 Calculating and storing the calculated value; ki가 0인지 1이지의 여부와 mi가 0이지 1인지의 여부에 기초하여 를 계산하는 단계; 및based on whether ki is 0 or 1 and whether mi is 0 or 1 Calculating; And 를 계산하고 상기 Sp와 상기 Sq를 출력하는 단계를 구비하는 것을 특징으로 하는 암호화 방법. And calculating Sp and outputting the Sp and the Sq. 제5항에 있어서, 상기 ki는 dp를 이진전개 했을 때 i번째 계수이고, 상기 dp=kn*2n+…+ki*2i+…+k1*2+k0이고, 상기 mi는 dq를 이진전개 했을 때 i번째 계수이고, 상기 dq=mn*2n+…+mi*2i+…+m1*2+m0인 것을 특징으로 하는 암호화 방법.6. The method of claim 5, wherein ki is the i-th coefficient when dp is binary developed, and dp = kn * 2 n +. + ki * 2 i +… + k1 * 2 + k0, and mi is the i-th coefficient when dq is binary developed, and dq = mn * 2 n +. + mi * 2 i +… Encryption method characterized in that + m1 * 2 + m0. 컴퓨터에서 제1항 내지 제6항 중의 어느 하나의 항에 기재된 방법을 실행시키기 위한 프로그램을 기록한 컴퓨터로 읽을 수 있는 기록매체.A computer-readable recording medium having recorded thereon a program for executing the method according to any one of claims 1 to 6 on a computer. 두 소수(p, q)를 비밀키로, n=p*q를 만족하는 n을 공개키, phi(n)과 서로 소인 정수 e를 공개키로, ed=1 mod phi(n)을 만족시키는 d를 비밀키로 이용하는 CRT에 기초한 RSA 공개키 암호화 방식을 이용한 암호화 장치에 있어서,With two prime numbers (p, q) as the secret key, n satisfying n = p * q is the public key, phi (n) and the prime integer e are public keys, and ed = 1 mod phi (n) An encryption device using an RSA public key encryption method based on a CRT used as a secret key, 상기 두 소수(p, q), 상기 비밀키(d) 및 상기 공개키(e)로부터 을 계산하는 제1연산수단;From the two prime numbers (p, q), the secret key (d) and the public key (e) First operating means for calculating a; 메시지(M), 상기 두 소수(p, q), 및 상기 제1연산수단으로부터 출력되는 계산 값들에 기초하여 를 계산하는 제2연산수단;Based on the message M, the two prime numbers p, q and the calculated values output from the first computing means Wow Second operation means for calculating a; 상기 M, 상기 ep, 상기 eq, 상기 p, 및 상기 q에 기초하여 를 계산하는 제3연산수단;Based on the M, ep, eq, p, and q Third operation means for calculating a; 상기 Tp와 상기 Tq를 배타 논리합(XOR)하고, 그 결과를 생성하는 제4연산수단;Fourth operation means for performing an exclusive OR on the Tp and the Tq and generating a result; 상기 Sp, Sq, p, q, pi 및 qi를 수신하고, 이들에 기초하여 Receive the Sp, Sq, p, q, pi and qi and based on them 를 계산하는 제5연산수단; 및 Fifth calculation means for calculating a; And 상기 제5연산수단으로부터 출력된 S를 수신하고, 수신된 Sp가 (S mod p)와 일치하는지의 여부 및 상기 Sq가 (S mod q)와 일치하는지의 여부에 기초하여 상기 S를 상기 서명하고자 하는 메시지(M)에 대한 전자서명으로서 출력하는 디지털 서명 출력수단을 구비하는 것을 특징으로 하는 암호화 장치. To receive the S output from the fifth calculating means and to sign the S based on whether the received Sp matches (S mod p) and whether the Sq matches (S mod q) And digital signature output means for outputting as an electronic signature for a message (M). 제8항에 있어서, 상기 제2연산수단은,The method of claim 8, wherein the second operation means, 난수(r)을 발생하는 난수 발생수단; 및 Random number generating means for generating a random number (r); And 을 생성하고, r-1 mod p, M*r-1 mod p, r-1 mod q, 및 M*r-1 mod q를 각각 계산하고, 계산된 각 값을 대응되는 레지스터(Temp_p[0], Temp_p[1]. Temp_q[0] 및 Temp_q[1])에 저장하고, 를 계산하고, ki의 값과 mi의 값에 기초하여 를 계산하고, 를 출력하는 Sp 및 Sq생성 수단을 구비하는 것을 특징으로 하는 암호화 장치. And compute r −1 mod p, M * r −1 mod p, r −1 mod q, and M * r −1 mod q, respectively, and compute each computed value in the corresponding register (Temp_p [0]). , Temp_p [1], Temp_q [0] and Temp_q [1]), Is calculated, and based on the values of ki and mi And calculate And Sp generating means for outputting the Sq. 제9항에 있어서, 상기 ki는 dp를 이진전개 했을 때 i번째 계수이고, 상기 dp=kn*2n+…+ki*2i+…+k1*2+k0이고, 상기 mi는 dq를 이진전개 했을 때 i번째 계수이고, 상기 dq=mn*2n+…+mi*2i+…+m1*2+m0인 것을 특징으로 하는 암호화 장치.The method according to claim 9, wherein ki is the i-th coefficient when dp is binary developed, and dp = kn * 2 n +. + ki * 2 i +… + k1 * 2 + k0, and mi is the i-th coefficient when dq is binary developed, and dq = mn * 2 n +. + mi * 2 i +… Encryption device characterized in that + m1 * 2 + m0. 두 소수(p, q)를 비밀키로, n=p*q를 만족하는 n을 공개키로, phi(n)과 서로 소인 정수 e를 공개키로, ed=1 mod phi(n)을 만족시키는 d를 비밀키로 이용하는 CRT에 기초한 RSA 공개키 암호화 방식을 이용한 암호화 장치에 있어서,With two prime numbers (p, q) as the secret key, n satisfying n = p * q as the public key, phi (n) and mutually prime integer e as the public key, and d satisfying ed = 1 mod phi (n) An encryption device using an RSA public key encryption method based on a CRT used as a secret key, 상기 두 소수(p, q), 상기 비밀키(d) 및 상기 공개키(e)로부터 을 계산하는 제1연산수단;From the two prime numbers (p, q), the secret key (d) and the public key (e) First operating means for calculating a; 서명하고자 하는 메시지(M), 상기 두 소수(p, q), 상기 dp 및 상기 dq에 기초하여 를 계산하는 제2연산수단;Based on the message (M) to be signed, the two prime numbers (p, q), the dp and the dq Wow Second operation means for calculating a; 상기 제2연산수단으로 부터 출력된 Sp와 Sq, 상기 M, ep, eq, p 및 q에 기초하여 를 계산하는 제3연산수단;Based on Sp and Sq, M, ep, eq, p and q outputted from the second calculating means Third operation means for calculating a; 상기 제3연산수단으로부터 출력된 상기 Tp와 상기 Tq를 수신하고, 이들을 배타 논리합(XOR)하고, 그 결과(T)를 출력하는 제4연산수단;Fourth computing means for receiving the Tp and the Tq outputted from the third computing means, exclusive-ORing them, and outputting the result T; 상기 제4연산수단으로부터 출력된 값(T)과 p, q, pi, 및 qi에 기초하여 Based on the value T output from the fourth calculating means and p, q, pi, and qi 를 계산하는 제5연산수단; 및 Fifth calculation means for calculating a; And 상기 제2연산수단으로부터 출력된 값들(Sp와 Sq), 상기 제4연산수단으로부터 출력된 값(T), 상기 제5연산수단으로부터 출력된 값(D), 상기 p, q, pi 및 qi에 기초하여 를 계산하고, 계산된 S를 상기 서명하고자 하는 메시지(M)에 대한 전자서명으로서 출력하는 디지털 서명 출력수단을 구비하는 것을 특징으로 하는 암호화 장치.The values Sp and Sq output from the second computing means, the value T output from the fourth computing means, the value D output from the fifth computing means, p, q, pi and qi. Based on And digital signature output means for calculating a and outputting the calculated S as an electronic signature for the message M to be signed.
KR1020040027570A 2004-04-21 2004-04-21 Method and apparatus for protecting public key cryptosystems from side-channel attacks, and computer readable record medium stored thereof method KR20050102291A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020040027570A KR20050102291A (en) 2004-04-21 2004-04-21 Method and apparatus for protecting public key cryptosystems from side-channel attacks, and computer readable record medium stored thereof method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020040027570A KR20050102291A (en) 2004-04-21 2004-04-21 Method and apparatus for protecting public key cryptosystems from side-channel attacks, and computer readable record medium stored thereof method

Publications (1)

Publication Number Publication Date
KR20050102291A true KR20050102291A (en) 2005-10-26

Family

ID=37280517

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020040027570A KR20050102291A (en) 2004-04-21 2004-04-21 Method and apparatus for protecting public key cryptosystems from side-channel attacks, and computer readable record medium stored thereof method

Country Status (1)

Country Link
KR (1) KR20050102291A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8422671B2 (en) 2010-03-08 2013-04-16 Samsung Electronics Co., Ltd. Methods of encryption and decryption using operand ordering and encryption systems using the same
CN106464501A (en) * 2014-04-09 2017-02-22 有限公司Ictk Authentication apparatus and method
KR20220052207A (en) * 2020-10-20 2022-04-27 국민대학교산학협력단 Method and apparatus for side channel analysis for rsa encryption using artifical neural network

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8422671B2 (en) 2010-03-08 2013-04-16 Samsung Electronics Co., Ltd. Methods of encryption and decryption using operand ordering and encryption systems using the same
CN106464501A (en) * 2014-04-09 2017-02-22 有限公司Ictk Authentication apparatus and method
US10659232B2 (en) 2014-04-09 2020-05-19 Ictk Holdings Co., Ltd. Message authentication apparatus and method based on public-key cryptosystems
CN106464501B (en) * 2014-04-09 2020-09-25 Ictk控股有限公司 Authentication device and method
KR20220052207A (en) * 2020-10-20 2022-04-27 국민대학교산학협력단 Method and apparatus for side channel analysis for rsa encryption using artifical neural network

Similar Documents

Publication Publication Date Title
Boneh et al. On the importance of eliminating errors in cryptographic computations
Yen et al. RSA speedup with Chinese remainder theorem immune against hardware fault cryptanalysis
Sung-Ming et al. RSA speedup with residue number system immune against hardware fault cryptanalysis
US8850221B2 (en) Protection against side channel attacks with an integrity check
US7853013B2 (en) Cryptographic method and system for encrypting input data
Shoufan et al. A timing attack against Patterson algorithm in the McEliece PKC
US20060029224A1 (en) System and recording medium for securing data and methods thereof
US7912216B2 (en) Elliptic curve cryptosystem optimization using two phase key generation
EP3188001A1 (en) Modular multiplication device and method
JP2011530093A (en) Solutions to protect power-based encryption
US20040028221A1 (en) Cryptographic method and cryptographic device
JP2004304800A (en) Protection of side channel for prevention of attack in data processing device
US11824986B2 (en) Device and method for protecting execution of a cryptographic operation
US20040148325A1 (en) Information processing means
Fouque et al. Defeating countermeasures based on randomized BSD representations
EP1347596B1 (en) Digital signature methods and apparatus
Kim et al. A secure and practical CRT-based RSA to resist side channel attacks
US20060274894A1 (en) Method and apparatus for cryptography
US7496758B2 (en) Method and apparatus for protecting an exponentiation calculation by means of the chinese remainder theorem (CRT)
KR100953715B1 (en) Digital signature method, Digital signature apparatus using CRT-RSA modula exponentiation algorithm and Recording medium using by the same
JP2003255831A (en) Method and device for calculating elliptic curve scalar multiple
KR20050102291A (en) Method and apparatus for protecting public key cryptosystems from side-channel attacks, and computer readable record medium stored thereof method
KR100954844B1 (en) Method and Apparatus of digital signature using CRT-RSA modula exponentiation algorithm against fault attacks, and Recording medium using it
KR100953716B1 (en) Method and Apparatus of digital signature using bit arithmetic based on CRT-RSA and Recording medium using by the same
Yen et al. Permanent fault attack on the parameters of RSA with CRT

Legal Events

Date Code Title Description
WITN Withdrawal due to no request for examination