KR101693591B1 - Lightweight cryptographic apparatus using hardware and software co-design - Google Patents

Lightweight cryptographic apparatus using hardware and software co-design Download PDF

Info

Publication number
KR101693591B1
KR101693591B1 KR1020150084003A KR20150084003A KR101693591B1 KR 101693591 B1 KR101693591 B1 KR 101693591B1 KR 1020150084003 A KR1020150084003 A KR 1020150084003A KR 20150084003 A KR20150084003 A KR 20150084003A KR 101693591 B1 KR101693591 B1 KR 101693591B1
Authority
KR
South Korea
Prior art keywords
hardware
microprocessor
gezel
lightweight
instruction
Prior art date
Application number
KR1020150084003A
Other languages
Korean (ko)
Other versions
KR20160147361A (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 고려대학교 산학협력단
Priority to KR1020150084003A priority Critical patent/KR101693591B1/en
Publication of KR20160147361A publication Critical patent/KR20160147361A/en
Application granted granted Critical
Publication of KR101693591B1 publication Critical patent/KR101693591B1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/14Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols using a plurality of keys or algorithms
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/06Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols the encryption apparatus using shift registers or memories for block-wise or stream coding, e.g. DES systems or RC4; Hash functions; Pseudorandom sequence generators
    • H04L9/0618Block ciphers, i.e. encrypting groups of characters of a plain text message using fixed encryption transformation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/06Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols the encryption apparatus using shift registers or memories for block-wise or stream coding, e.g. DES systems or RC4; Hash functions; Pseudorandom sequence generators
    • H04L9/0618Block ciphers, i.e. encrypting groups of characters of a plain text message using fixed encryption transformation
    • H04L9/0637Modes of operation, e.g. cipher block chaining [CBC], electronic codebook [ECB] or Galois/counter mode [GCM]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L2209/00Additional information or applications relating to cryptographic mechanisms or cryptographic arrangements for secret or secure communication H04L9/00
    • H04L2209/80Wireless
    • H04L2209/805Lightweight hardware, e.g. radio-frequency identification [RFID] or sensor

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Storage Device Security (AREA)

Abstract

본 발명은 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 관한 것으로, 블록 암호 운용 방식에 따르는 마이크로프로세서 및 상기 마이크로프로세서와 연결되어 통신하는 GEZEL 하드웨어 코-프로세서(H/W co-processor)를 포함하며, 상기 GEZEL 하드웨어 코-프로세서는 GEZEL IP(intellectual property) 블록 및 데이터패스(datapath)를 이용한 유한상태기계(Finite state machine with datapath, FSMD) 방식으로 동작시키는 하나 이상의 하드웨어 IP를 포함하여 구성된다.
상기와 같이 구성된 본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 의하면, 데이터패스를 이용한 유한상태기계(FSMD) 방식의 GEZEL을 이용하여 블록암호 및 경량암호 알고리즘의 하드웨어와 소프트웨어를 최적화하여 통합 설계함으로써, 경쟁효과(race condition)로부터 자유로워서 신호 타이밍 캐치가 쉽고, 교착 상태에 빠질 우려가 없으며, 하드웨어와 소프트웨어 상호간의 인터페이스를 최적화하여 전체적인 레이턴시(latency)를 감소시키고, 속도를 향상시킨다.
The present invention relates to a lightweight encryption device capable of integrated design of hardware and software, and includes a microprocessor according to a block cipher operation method and a GEZEL hardware co-processor communicating with the microprocessor, , The GEZEL hardware co-processor comprises one or more hardware IPs operating in a finite state machine with datapath (FSMD) scheme using GEZEL intellectual property (IP) blocks and datapath.
According to the lightweight cryptographic apparatus capable of integrally designing the hardware and software according to the present invention, the hardware and software of the block cipher and the lightweight cryptographic algorithm are optimized by using the GEZEL of the finite state machine (FSMD) By integrated design, it is free from race condition, so signal timing catch is easy, there is no possibility of falling into deadlock, and the interface between hardware and software is optimized to reduce overall latency and improve speed.

Description

하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치{LIGHTWEIGHT CRYPTOGRAPHIC APPARATUS USING HARDWARE AND SOFTWARE CO-DESIGN}BACKGROUND OF THE INVENTION 1. Field of the Invention [0001] The present invention relates to a light-

본 발명은 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 관한 것으로, 더욱 상세하게는 데이터패스를 이용한 유한상태기계(FSMD) 방식의 GEZEL을 이용하여 블록암호 및 경량암호 알고리즘의 하드웨어와 소프트웨어 통합 설계하는 경량암호 장치에 관한 것이다.The present invention relates to a lightweight encryption apparatus capable of integrating hardware and software, and more particularly, to an integrated design of hardware and software of a block cipher and a lightweight encryption algorithm using GEZEL of a finite state machine (FSMD) To a lightweight encryption apparatus.

암호 시스템은 크게 공개키 암호 시스템과 암/복호화에 동일한 키를 사용하는 대칭키 암호 시스템으로 분류된다. RFID나 USN 같은 저전력/경량화 환경에서는 안전성을 보장하면서도 효율적인 암호 알고리즘을 필요로 한다. 이러한 환경에서 평문을 블록단위로 암호화를 수행하는 대칭키 경량 암호가 많이 사용된다. 그리고, 경량 암호는 단독으로 사용되기보다는 다양한 길이를 가진 메시지를 암호화하기 위해 다양한 운용 모드와 함께 사용된다.The cryptosystem is largely classified into a public key cryptosystem and a symmetric key cryptosystem using the same key for encryption / decryption. In low-power / light-weight environments such as RFID and USN, efficient encryption algorithms are required while ensuring safety. In this environment, a symmetric key lightweight cipher that performs encryption on a plaintext block basis is often used. And, lightweight cryptography is used with various operating modes to encrypt messages of various lengths rather than being used alone.

암호 시스템을 설계할 때 하드웨어와 소프트웨어 각각의 모듈로 따로 설계하기 보다는 각 설계 방법의 이점들을 최대한 살릴 수 있는 하드웨어/소프트웨어 통합 설계 기법이 많이 적용되어 사용되고 있다. 다만, 하드웨어/소프트웨어의 언어적 특징이 상당히 다른 면이 있고, 최적화 방법도 상이하기 때문에 각각의 장점을 활용하여 효과적으로 설계하기 어려운 문제점이 있다.When designing a cryptographic system, a hardware / software integrated design technique that can maximize the advantages of each design method is applied rather than designing each module as hardware and software. However, there is a problem that the linguistic characteristics of the hardware / software are quite different, and the optimization method is also different.

Patrick R. Schaumont, "A Practical Introduction to Hardware/Software Codesign," Springer, Dec. 2012.Patrick R. Schaumont, "A Practical Introduction to Hardware / Software Codesign," Springer, Dec. 2012.

본 발명이 해결하고자 하는 기술적 과제는 블록암호 및 경량암호 알고리즘의 하드웨어와 소프트웨어를 통합적으로 설계한 최적화 기법이 존재하지 않았으며, 그로 인해 통합 설계 과정에서 나타날 수 있는 데드락(deadlock), 레이턴시(latency) 및 경쟁 효과(race condition) 발생의 문제점을 극복하기 위한 것으로서, 데이터패스를 이용한 유한상태기계(FSMD) 방식의 GEZEL을 이용하여 블록암호 및 경량암호 알고리즘의 하드웨어와 소프트웨어를 통합 설계하는 경량암호 장치를 제공하는 데에 그 목적이 있다.SUMMARY OF THE INVENTION The present invention has been made in an effort to solve the above problems, and it is an object of the present invention to provide an encryption method and a lightweight encryption algorithm, And a lightweight cryptographic device that combines hardware and software of a block cipher and a lightweight cipher algorithm using GEZEL of a finite state machine (FSMD) method using a data path. The purpose is to provide.

상기 목적을 달성하기 위해 본 발명은 블록 암호 운용 방식에 따르는 마이크로프로세서 및 상기 마이크로프로세서와 연결되어 통신하는 GEZEL 하드웨어 코-프로세서(H/W co-processor)를 포함하며, 상기 GEZEL 하드웨어 코-프로세서는 GEZEL IP(intellectual property) 블록 및 데이터패스(datapath)를 이용한 유한상태기계(Finite state machine with datapath, FSMD) 방식으로 동작시키는 하나 이상의 하드웨어 IP를 포함하여 구성되고, 상기 마이크로프로세서는 하드웨어와 소프트웨어의 통합 설계 시 각 대칭키 암호의 알고리즘 중 키 스케줄 부분을 소프트웨어에서 구현하여 미리 각 라운드키 값을 계산하고, 상기 계산된 라운드키를 하드웨어로 보내어 상기 하드웨어에서 키 스케줄 연산 처리 과정을 생략시킴으로써 속도를 증대시키며, 상기 마이크로프로세서가 한 사이클에 두 명령을 상기 하드웨어로 전송하면, 상기 하드웨어는 상기 두 명령을 순차적 또는 병렬적으로 수행하되, 상기 마이크로프로세서는 상기 하드웨어로부터 첫 명령전송에 대응하는 하나의 완료명령을 받은 후 다음 사이클에 두 명령을 다시 상기 하드웨어로 보내는 통신을 통해, 첫 연산 사이클 이후 소프트웨어 연산 시 하드웨어의 동작 대기 시간을 줄이고, 소프트웨어와 하드웨어가 암호화 연산 수행 중에도 메시지를 송수신하는 인터페이스를 구현한다.In order to accomplish the above object, the present invention includes a microprocessor according to a block cipher operating method and a GEZEL hardware co-processor communicating with the microprocessor, wherein the GEZEL hardware co- And one or more hardware IPs operating in a finite state machine with datapath (FSMD) scheme using GEZEL intellectual property (IP) blocks and datapaths, the microprocessor comprising hardware and software integration The key schedule part of the algorithm of each symmetric key cryptosystem at the time of design is implemented in software to calculate each round key value in advance and sends the calculated round key to the hardware to increase the speed by omitting the key schedule calculation process in the hardware , ≪ / RTI > the microprocessor has two The hardware executes the two instructions sequentially or in parallel, and the microprocessor receives one completion command corresponding to the first command transmission from the hardware, Through the communication sent to the hardware, the hardware operation wait time is reduced in the software operation after the first arithmetic cycle, and the interface that sends and receives the message is performed while the software and hardware perform the encryption operation.

본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 있어서, 상기 마이크로프로세서는 전자 코드북(ECB), 암호 블록 체인(CBC), 카운터(CTR), 암호 피드백(CFB), 및 출력 피드백(OFB) 중 어느 하나의 방식을 선택하여 블록 암호를 운용하는 것을 특징으로 한다.A lightweight cryptographic apparatus capable of integrally designing hardware and software according to the present invention, the microprocessor comprising an electronic codebook (ECB), a cipher block chain (CBC), a counter (CTR), a cryptographic feedback (CFB) And the block cipher is operated by selecting one of the methods.

본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 있어서, 상기 하나 이상의 하드웨어 IP는 경량암호 HIGHT 기법의 하드웨어 IP, 경량암호 PRESENT 기법의 하드웨어 IP, 및 경량암호 PRINTcipher 기법의 하드웨어 IP를 포함하는 것을 특징으로 한다.A lightweight encryption device capable of integrating hardware and software according to the present invention, the at least one hardware IP including hardware IP of a lightweight encryption HIGHT scheme, hardware IP of a lightweight encryption PRESENT scheme, and hardware IP of a lightweight encryption PRINTcipher scheme .

본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 있어서, 상기 경량암호 HIGHT 기법의 하드웨어 IP는 상기 경량암호 HIGHT 기법의 각 데이터패스를 유한상태기계로 정의하여 제어하는 HIGHT 제어기와, 상기 경량암호 HIGT 기법의 암호 알고리즘을 수행하는 HIGHT_round_dp 데이터패스와, 키 스케줄(key schedule)을 수행하는 KEY expand 데이터패스와, 룩-업 테이블(look-up table) 형태로 내부 함수의 출력 값을 갖는 F0 및 F1 데이터패스 및 라운드의 서브키(subkey) 조합에 사용되는 델타(delta)값을 저장하는 delta 데이터패스를 포함하는 것을 특징으로 한다.The hardware IP of the lightweight cryptographic HIGHT technique includes a HIGHT controller for defining and controlling each data path of the lightweight cryptographic HIGHT technique as a finite state machine, and HIGHT_round_dp datapath that performs an encryption algorithm of a cipher HIGT techniques, the key schedule (key schedule) to perform kEY expand data path, look to-up table (look-up table) F 0 with an output of the internal function in the form And a delta data path for storing a delta value used for a combination of F 1 data paths and round subkeys.

본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 있어서, 상기 HIGHT 제어기는 서브키를 16개 사용하는 4라운드 수행 후 키스케줄을 수행하되 4라운드 수행시 레지스터의 위치를 변경하는 리타이밍(retiming)을 적용하여 크리티컬 패스(critical path)의 지연(delay)을 감소시키는 것을 특징으로 한다.In the lightweight encryption apparatus capable of designing the integrated hardware and software according to the present invention, the HIGHT controller performs a key schedule after performing 4 rounds using 16 subkeys, and performs a retiming retiming is applied to reduce the delay of a critical path.

본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 있어서, 상기 경량암호 PRESENT 기법의 하드웨어 IP는 상기 경량암호 PRESENT 기법의 각 데이터패스를 유한상태기계로 정의하여 제어하는 PRESENT 제어기와, 상기 경량암호 PRESENT 기법의 암호 알고리즘을 수행하는 RESENT_round_dp 데이터패스와, 룩-업 테이블(look-up table) 형태로 입출력을 처리하는 복수 개의 S-box 데이터패스 및 키 스케줄 시 사용하는 Key-box 데이터패스를 포함하는 것을 특징으로 한다.The hardware IP of the lightweight encryption PRESENT scheme includes a PRESENT controller for defining and controlling each data path of the lightweight encryption PRESENT scheme as a finite state machine, A RESENT_round_dp data path for performing the encryption algorithm of the encryption PRESENT scheme, a plurality of S-box data paths for processing input and output in the form of a look-up table, and a key-box data path for use in key scheduling .

본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 있어서, 상기 PRESENT 제어기는 입력과 출력이 필요한 S-box를 상기 룩-업 테이블을 이용하여 하나의 데이터패스로 처리하되 S-box Layer의 입력값들을 레지스터로 선언함으로써 상기 PRESENT_round_dp 데이터패스와 상기 S-box 데이터패스 간에 발생할 수 있는 지연을 감소시켰으며, 하나의 사이클마다 S-box Layer, Permutation Layer, 및 다음 라운드의 AddRoundKey를 수행하는 것을 특징으로 한다.The PRESENT controller processes an S-box requiring input and output as one data path using the look-up table, and controls the S-box layer of the S-box layer By delimiting input values into registers, it is possible to reduce the delay that may occur between the PRESENT_round_dp data path and the S-box data path, and to perform an S-box layer, a Permutation Layer, and an AddRoundKey of the next round for each cycle .

본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 있어서, 상기 경량암호 PRINTcipher 기법의 하드웨어 IP는 상기 경량암호 PRINTcipher 기법의 각 데이터패스를 유한상태기계로 정의하여 제어하는 PRINTcipher 제어기와, 상기 경량암호 PRINTcipher 기법의 암호 알고리즘을 수행하는 PRINTcipher_round_dp 데이터패스 및 Permutation과 S-box Substitution을 수행하는 복수 개의 SP-box 데이터패스를 포함하는 것을 특징으로 한다.The hardware IP of the lightweight cryptographic PRINT cipher technique includes a PRINT cipher controller for defining and controlling each data path of the lightweight cryptographic PRINT cipher technique as a finite state machine, A PRINTcipher_round_dp data path for performing a cryptographic algorithm of the cryptographic PRINT cipher technique, and a plurality of SP-box datapaths for performing permutation and S-box substitution.

본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 있어서, 상기 PRINTcipher 제어기는 PRINTcipher 기법에 따른 Permutation과 S-box Substitution의 전처리 부분을 미리 하나의 테이블로 설정하여 연산량을 감소시키며, 반복 수행되는 라운드 연산의 루프(loop) 로직을 재구성하여 하나의 루프마다 데이터의 읽기 및 쓰기 횟수를 증가시켜 수행 사이클(cycle)을 감소시키는 언폴딩(unfolding)을 적용하는 것을 특징으로 한다.In the lightweight encryption apparatus capable of designing the hardware and software integrated according to the present invention, the PRINT cipher controller reduces the amount of computation by setting the preprocessing portion of permutation and S-box substitution according to the PRINT cipher technique in advance as one table, The loop logic of the round operation is reconfigured to increase the number of times of reading and writing data for each loop to apply unfolding to reduce a cycle.

본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 있어서, 상기 마이크로프로세서는 상기 GEZEL 하드웨어 코-프로세서 입출력 장치와 통신 시, 메모리 맵 입출력(memory mapped I/O)방식 또는 포트 맵 입출력(port mapped I/O)방식을 이용하여 연결되는 것을 특징으로 한다.A lightweight cryptographic apparatus capable of integrating hardware and software according to the present invention, the microprocessor comprising: a memory mapped I / O system or a port map input / output (port) system in communication with the GEZEL hardware co- mapped I / O).

본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 있어서, 상기 마이크로프로세서는 상기 GEZEL 하드웨어 코-프로세서와 통신 시, 암호화와 메시지 송수신이 동시에 병렬로 수행하는 핸드쉐이크 (handshake) 프로토콜을 이용하여 메시지를 송수신하는 것을 특징으로 한다.In the lightweight encryption apparatus capable of integrating hardware and software according to the present invention, the microprocessor uses a handshake protocol in which encryption and message transmission / reception are simultaneously performed in parallel with the GEZEL hardware co- And transmits and receives a message.

본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 있어서, 상기 마이크로프로세서는 상기 핸드쉐이크 프로토콜을 이용한 통신을 위해, 상기 마이크로프로세서가 상기 GEZEL 하드웨어 코-프로세서로 제1명령과 제2명령을 전송하고, 상기 GEZEL 하드웨어 코-프로세서는 상기 제1명령과 상기 제2명령을 수신하여 동작을 순차적 또는 한번에 병렬적으로 수행하고, 상기 GEZEL 하드웨어 코-프로세서가 수신한 상기 제1명령과 상기 제2명령 중 먼저 완료된 동작의 제1완료 시그널을 상기 마이크로프로세서로 전송하며, 상기 제1완료 시그널을 수신한 상기 마이크로프로세서가 제3명령과 제4명령을 생성하여 버퍼에 저장하고, 상기 GEZEL 하드웨어 코-프로세서가 수신한 상기 제1명령과 상기 제2명령 중 나중에 완료된 동작의 제2완료 시그널을 상기 마이크로프로세서로 전송하며, 상기 제2완료 시그널을 수신한 상기 마이크로프로세서가 상기 버퍼에 저장된 상기 제3명령과 상기 제4명령을 상기 GEZEL 하드웨어 코-프로세서로 전송하는 과정을 반복 수행한다.In a lightweight cryptographic apparatus capable of designing an integrated hardware and software according to the present invention, the microprocessor is configured to transmit a first command and a second command to the GEZEL hardware co-processor for communication using the handshake protocol Wherein the GEZEL hardware co-processor receives the first instruction and the second instruction to perform operations sequentially or in parallel at a time, and wherein the first instruction received by the GEZEL hardware co- The microprocessor receiving the first completion signal generates a third instruction and a fourth instruction and stores the third instruction and the fourth instruction in a buffer, and the GEZEL hardware co- And a second completion signal of a later completed operation of the first instruction and the second instruction received by the processor And the microprocessor that has received the second completion signal repeatedly transmits the third instruction and the fourth instruction stored in the buffer to the GEZEL hardware co-processor.

상기와 같이 구성된 본 발명에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 의하면, 데이터패스를 이용한 유한상태기계(FSMD) 방식의 GEZEL을 이용하여 블록암호 및 경량암호 알고리즘의 하드웨어와 소프트웨어를 최적화하여 통합 설계함으로써, 경쟁효과(race condition)로부터 자유로워서 신호 타이밍 캐치가 쉽고, 교착 상태에 빠질 우려가 없다.According to the lightweight cryptographic apparatus capable of integrally designing the hardware and software according to the present invention, the hardware and software of the block cipher and the lightweight cryptographic algorithm are optimized by using the GEZEL of the finite state machine (FSMD) By integrally designing, it is free from race condition, and signal timing catch is easy, and there is no possibility of falling into deadlock state.

또한, 하드웨어와 소프트웨어 상호간의 인터페이스를 최적화하여 전체적인 레이턴시(latency)를 감소시키고, 속도를 향상시키는 효과가 있다.In addition, the interface between the hardware and the software is optimized to reduce the overall latency and improve the speed.

도 1은 본 발명의 일 실시 예에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치의 구조를 나타내는 블록도이다.
도 2는 본 발명의 일 실시예에 따른 HIGHT 유한상태기계(FSM)의 전체 흐름을 도시한 도면이다.
도 3은 본 발명의 일 실시예에 따른 PRESENT 유한상태기계(FSM)의 전체 흐름을 도시한 도면이다.
도 4는 본 발명의 일 실시예에 따른 PRINTcipher 유한상태기계(FSM)의 전체 흐름을 도시한 도면이다.
도 5는 본 발명의 일 실시예에 따른 핸드쉐이크 프로토콜을 이용한 통신 방법을 나타내는 순서도이다.
1 is a block diagram illustrating a structure of a lightweight encryption apparatus capable of designing an integrated hardware and software according to an embodiment of the present invention.
2 is a diagram illustrating an overall flow of a HIGHT finite state machine (FSM) according to an embodiment of the present invention.
3 is a diagram illustrating an overall flow of a PRESENT finite state machine (FSM) according to one embodiment of the present invention.
FIG. 4 is a diagram illustrating the entire flow of a PRINTcipher finite state machine (FSM) according to one embodiment of the present invention.
5 is a flowchart illustrating a communication method using a handshake protocol according to an embodiment of the present invention.

본 발명은 다양한 변형 및 여러 가지 실시 예를 가질 수 있는바, 특정 실시 예들을 도면에 예시하고 상세한 설명에 보다 상세하게 설명하고자 한다. 본 발명을 설명함에 있어서 관련된 공지 기술에 대한 구체적인 설명이 본 발명의 요지를 흐릴 수 있다고 판단되는 경우 그 상세한 설명을 생략한다.The present invention may have various modifications and various embodiments, and specific embodiments are illustrated in the drawings and described in detail in the detailed description. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS Hereinafter, the present invention will be described in detail with reference to the accompanying drawings.

먼저 본 발명에서 하드웨어와 소프트웨어 통합 설계를 위한 GEZEL에 대해서 설명한다. GEZEL은 소프트웨어와 하드웨어 통합설계가 용이하도록 개발된 언어이자 설계 플랫폼이다. 또한 GEZEL의 문법은 직관적이라서 소프트웨어 설계에 익숙한 설계자들이 하드웨어를 쉽게 설계할 수 있다.First, GEZEL for hardware and software integrated design will be described in the present invention. GEZEL is a language and design platform developed to facilitate software and hardware integration design. GEZEL's syntax is intuitive so designers familiar with software design can easily design hardware.

사이클 기반의 하드웨어 기술 언어인 GEZEL은 데이터패스를 이용한 유한상태기계(Finite State Machine with Datapath, FSMD) 방식으로 되어있다. 다른 하드웨어 설계언어는 유한상태기계(Finite State Machine, FSM)기반인데 반해 데이터패스가 결합된 유한상태기계를 구성하기 때문에 하드웨어 구현 최적화 이론을 적용하기 쉽다.GEZEL, a cycle-based hardware description language, is based on Finite State Machine with Datapath (FSMD). The hardware implementation optimization theory is easy to apply because other hardware design languages are based on finite state machines (FSM), while finite state machines are combined with datapaths.

특히, GEZEL은 하드웨어 단독 설계뿐만 아니라 하드웨어와 소프트웨어의 통합 설계에도 적합하도록 개발되었다. 통합 설계에 있어서 GEZEL은 ARM, 8051 마이크로프로세서의 IP 코어 블록을 지원하기 때문에 별도의 컴파일 없이도 GEZEL에서 지원하는 IP 블록 코드를 삽입하는 것만으로도 ARM, 8051 마이크로프로세서들과 통신이 가능하다.In particular, GEZEL has been developed not only for hardware-only design, but also for integrated design of hardware and software. In the integrated design, GEZEL supports the IP core block of the ARM, 8051 microprocessor so that it can communicate with the ARM, 8051 microprocessors simply by inserting the IP block code supported by GEZEL without any additional compilation.

이하, 본 발명의 일 실시예를 첨부된 도면을 참조하여 GEZEL을 이용한 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치에 대해서 상세히 설명하기로 한다.DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS Hereinafter, an embodiment of the present invention will be described in detail with reference to the accompanying drawings.

도 1은 본 발명의 일 실시예에 따른 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치의 구조를 나타내는 블록도이다. 도 1을 참조하면 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치는 마이크로프로세서(100)와 GEZEL 하드웨어 코-프로세서(200)를 포함하여 구성된다.1 is a block diagram illustrating a structure of a lightweight encryption apparatus capable of designing an integrated hardware and software according to an embodiment of the present invention. Referring to FIG. 1, a lightweight encryption apparatus capable of hardware and software integrated design includes a microprocessor 100 and a GEZEL hardware co-processor 200.

마이크로프로세서(100)는 전자 코드북(Electronic Code Book, ECB) 운용모드(110), 암호 블록 체인(Cipher Block Chaining, CBC) 운용모드(120), 카운터(Counter, CTR) 운용모드(130), 암호 피드백(Cipher FeedBack, CFB) 운용모드(140) 및 출력 피드백(Output FeedBack, OFB) 운용모드(150)의 5개의 운용모드를 통해 하드웨어/소프트웨어의 통합설계를 구축한다. The microprocessor 100 includes an electronic code book (ECB) operating mode 110, a Cipher Block Chaining (CBC) operating mode 120, a counter (CTR) operating mode 130, The integrated design of hardware / software is built up through five operating modes: Cipher FeedBack (CFB) operating mode 140 and Output FeedBack (OFB) operating mode 150.

전자 코드북 운용모드(110)는 운용 방식 중 가장 간단한 구조를 가지며, 암호화하려는 메시지를 여러 블록으로 나누어 각각 암호화하는 방식으로 되어있다.The electronic codebook operating mode 110 has the simplest structure of the operation method, and is a method of encrypting a message to be encrypted by dividing it into a plurality of blocks.

암호 블록 체인 운용모드(120)는 각 블록이 암호화되기 전에 이전 블록의 암호화 결과와 익스쿨루시브 오아(exclusive or, XOR) 로직으로 결합되며, 첫 블록의 경우에는 초기화 벡터가 사용된다. 상기 초기화 벡터가 같은 경우 출력 결과가 항상 같기 때문에, 매 암호화마다 다른 초기화 벡터를 사용해야 한다.The cipher block chain operation mode 120 is coupled to the encryption result of the previous block with exclusive or XOR logic before each block is encrypted. In the case of the first block, the initialization vector is used. Since the output result is always the same if the initialization vectors are the same, a different initialization vector should be used for each encryption.

카운터 운용모드(130)는 블록 암호를 스트림 암호로 바꾸는 구조를 가진다. 카운터 운용모드(130)는 각 블록마다 현재 블록이 몇 번째인지 값을 얻어, 그 숫자와 난스(nonce)를 결합하여 블록 암호의 입력으로 사용한다. 각 블록 암호에서 연속적인 난수를 얻은 다음 암호화하려는 문자열과 XOR 로직으로 결합한다. 카운터 운용모드(130)는 각 블록의 암호화 및 복호화가 이전 블록에 의존하지 않으므로 병렬적으로 동작하는 것이 가능하다. 또한, 암호화된 문자열에서 원하는 부분만 복호화하는 것도 가능하다.The counter operation mode 130 has a structure for changing the block cipher to a stream cipher. The counter operation mode 130 obtains the value of the current block for each block, combines the number and the nonce, and uses it as an input of the block cipher. Obtain consecutive random numbers from each block cipher and then combine them with the string to be encrypted with XOR logic. The counter operation mode 130 is capable of operating in parallel since the encryption and decryption of each block does not depend on the previous block. It is also possible to decrypt only a desired portion of the encrypted string.

암호 피드백 운용모드(140)는 블록 암호를 자기 동기 스트림 암호로 변환한다. 암호 피드백 운용모드(140)의 동작 방식은 전자 코드북 운용모드(110)와 유사하며, 특히 암호 해제 방식은 전자 코드북 운용모드(110) 암호화의 역순과 매우 유사하다.The cipher feedback operating mode 140 converts the block cipher to a self-synchronizing stream cipher. The operation mode of the cipher feedback operation mode 140 is similar to the electronic codebook operation mode 110, and in particular, the decryption mode is very similar to the reverse order of the electronic codebook operation mode 110 encryption.

출력 피드백 운용모드(150)는 블록 암호를 동기식 스트림 암호로 변환한다. XOR 명령의 대칭 때문에 암호화와 암호 해체 방식은 완전히 동일하다.The output feedback operating mode 150 converts the block cipher into a synchronous stream cipher. Because of the symmetry of the XOR instruction, the encryption and decryption methods are exactly the same.

마이크로프로세서(100)는 상기의 5가지 운용모드를 이용함으로 사용 플랫폼과 상황에 맞추어 운용모드와 암호를 선택할 수 있는 유연성을 제공한다. 또한, 마스터키가 하드웨어에 저장된 것이 아닌 소프트웨어로부터 입력받는 것임으로 추후 키가 유출되었을 경우 쉽게 수정 및 업데이트가 가능하다는 안전성 측면에서의 유연성을 갖는다.The microprocessor 100 provides the flexibility to select the operating mode and the password according to the usage platform and situation by using the above five operation modes. In addition, since the master key is input from software, which is not stored in hardware, it has flexibility in terms of safety in that it can be easily corrected and updated when a key is leaked later.

설계 측면에서도 하드웨어와 소프트웨어의 통합 설계 시 각 대칭키 암호의 알고리즘 중 키 스케줄 부분을 소프트웨어에서 구현하여 미리 각 라운드키 값을 사전 계산하고, 계산된 라운드키를 하드웨어로 보내는 방식으로도 구현할 수 있다. 그에 따라 하드웨어에서는 키 스케줄 연산 처리과정이 삭제됨으로 면적이 감소하고 속도 증대 효과를 기대할 수 있다.In terms of design, it is also possible to implement the key schedule part of the algorithm of each symmetric key cryptosystem in software and to precompute each round key value in advance and send the calculated round key to the hardware. As a result, the key schedule computation process is deleted in the hardware, so that the area decreases and the speed increase effect can be expected.

다음으로 GEZEL 하드웨어 코-프로세서(200)는 GEZEL IP 블록(210), 데이터 로더(220), HIGHT 하드웨어 IP(230), PRESENT 하드웨어 IP(240), PRINTcipher 하드웨어 IP(250)를 포함한다.Next, the GEZEL hardware co-processor 200 includes a GEZEL IP block 210, a data loader 220, a HIGHT hardware IP 230, a PRESENT hardware IP 240, and a PRINT cipher hardware IP 250.

GEZEL IP 블록(210)은 GEZEL을 이용하여 설계한 하드웨어와 소프트웨어 간의 통신이 쉽게 이루어질 수 있도록 GEZEL에서 제공하는 통신을 위한 IP 블록으로, 본 발명에서는 마이크로프로세서(100)와 GEZEL 하드웨어 코-프로세서(200) 간의 통신이 가능하도록 연결해주는 IP 블록을 의미한다.The GEZEL IP block 210 is an IP block for communication provided by the GEZEL so that communication between the hardware and the software designed using the GEZEL can be easily performed. In the present invention, the microprocessor 100 and the GEZEL hardware co- ) In order to allow communication between them.

데이터 로더(220)는 GEZEL 하드웨어 코-프로세서(200) 내부의 메모리로 구성되어 있으며, 마이크로프로세서(100)의 명령어 또는 데이터를 받아 데이터 로더(200)에 미리 저장하여 GEZEL 하드웨어 코-프로세서(200)에서 빠른 연산이 이루어지도록 한다. 여기서 하드웨어와 소프트웨어 통합 설계시 레이턴시(latency)에 가장 많은 영향을 미치는 부분이 소프트웨어와 하드웨어 간의 데이터를 읽고 쓰는데 있다는 것을 감안한다면, 데이터 로더(220)는 하드웨어에서 중요한 역할을 한다.The data loader 220 is constituted by a memory inside the GEZEL hardware co-processor 200. The data loader 220 receives commands or data of the microprocessor 100 and stores the commands or data in advance in the data loader 200, So that a fast operation can be performed. Here, the data loader 220 plays an important role in the hardware, considering that the most influential part of latency in the hardware and software integrated design is the read / write data between the software and the hardware.

HIGHT 하드웨어 IP(230)는 HIGHT 알고리즘을 이용한 하드웨어 IP로 HIGHT 제어기(231) 및 HIGHT 데이터 패스(232)를 포함하여 구성된다.The HIGHT hardware IP 230 includes a HIGHT controller 231 and a HIGHT datapath 232 as a hardware IP using the HIGHT algorithm.

HIGHT 제어기(231)는 각 데이터패스를 유한상태기계로 정의하여 상기 각 데이터패스들을 이용한 연산 기능을 수행한다.The HIGHT controller 231 defines each data path as a finite state machine and performs an arithmetic function using each of the data paths.

HIGHT 데이터 패스(232)는 HIGHT 암호 알고리즘 전체를 수행하는 HIGHT_round-dp 데이터패스와, 키 스케줄을 수행하는 KEY expand 데이터패스, 룩-업 테이블(look-up table) 형태로 내부 함수와의 출력 값을 갖고 F0, F1 데이터패스 및 라운드의 서브키(subkey) 조합에서 사용되는 델타(delta)값을 저장하는 delta 데이터패스의 총 5개의 데이터패스로 구성된다.The HIGHT data path 232 includes a HIGHT_round-dp data path for performing the entire HIGHT encryption algorithm, a KEY expand data path for performing a key schedule, and a look-up table, And a delta data path storing a delta value used in a combination of F 0 , F 1 data paths and round subkeys.

상기와 같은 구성으로 HIGHT 제어기(231)는 서브키를 16개 사용하고 난 이후에 입력된 비밀키의 상위 64비트와 하위 64비트가 각각 8비트씩 순환 왼쪽 시프트를 하는 것에 착안하여 최적화를 수행하였다. 즉, 서브키를 16개 사용하는 4라운드 수행 후 키 스케줄을 수행할 수 있게 구현하고, 4라운드 수행 시 발생하는 크리티컬 패스(critical path)의 증가문제를 해결하기 위하여 리타이밍(retiming) 기법을 적용하여 크리티컬 패스의 지연을 감소시킨다.In the above configuration, the HIGHT controller 231 performs optimization by considering the fact that the upper 64 bits and the lower 64 bits of the secret key inputted after using the 16 sub keys perform a cyclic left shift by 8 bits, respectively . That is, a key schedule can be performed after 4 rounds using 16 sub keys, and a retiming technique is applied to solve the problem of an increase in a critical path occurring in 4 rounds. Thereby reducing the delay of the critical path.

여기서 HIGHT 제어기(231)의 최적화 방법은 도 2를 참조하여 설명한다. 도 2는 본 발명의 일 실시예에 따른 HIGHT 유한상태기계(FSM)의 전체 흐름을 도시한 도면으로 총 8개의 상태로 구성된다.Here, an optimization method of the HIGHT controller 231 will be described with reference to FIG. FIG. 2 is a view showing the entire flow of a HIGHT finite state machine (FSM) according to an embodiment of the present invention, and is composed of a total of 8 states.

먼저 Check start(310) 상태에서 통신 모듈과 소프트웨어의 통신이 연결되었는지 확인하여, 연결이 되지 않았다면 암호화를 시작하지 않는다. 정상적으로 연결이 되고 상기 통신 모듈로부터 평문과 키를 입력받았다면 다음 상태로 넘어간다.First, in the check start (310) state, it is checked whether communication between the communication module and the software is connected. If the connection is not established, the encryption is not started. If the connection is normally established and the plaintext and key are input from the communication module, the process proceeds to the next state.

다음으로 INIT(320) 상태에서는 외부 통신 모듈로부터 평문과 키를 입력받은 후 HIGHT 내부 레지스터에 저장한다. 그리고 HIGHT 암호화를 수행하는 동안 사용될 레지스터를 초기화하는 상태를 의미한다.Next, INIT (320) receives the plaintext and key from the external communication module and stores it in HIGHT internal register. And a state in which a register to be used during HIGHT encryption is initialized.

다음으로 Pre round(330) 상태에서는 라운드 시작 전에 입력 받은 평문에 대해서 화이트닝키를 삽입하는 과정을 수행한다.Next, in the pre-round (330) state, a whitening key is inserted into the plain text inputted before the beginning of the round.

다음으로 Sub_Key(340) 상태에서는 HIGHT의 라운트키로부터 2랄운드에 사용될 8개의 서브키를 생성한다. delta 데이터패스의 출력값과 현재 키를 조합하여 서브키를 생성한다.Next, in Sub_Key (340) state, 8 sub keys are generated from the round key of HIGHT to be used in the second round. The sub key is generated by combining the output value of the delta data path and the current key.

다음으로 Round(350) 수행 상태에서는 앞서 생성된 8개의 서브키를 이용하여 2라운드를 수행하고 그 값을 레지스터에 저장한다. 이때 HIGHT는 마지막 라운드가 기존 라운드와 다르기 때문에 마지막 라운드는 32라운드 알고리즘을 수행하고 최종 화이트닝키를 삽입한 값을 출력한다. 이 상태에서는 키 스케줄을 시작하기 전에 3라운드 중 처음 2라운드만 수행했을 때는 다시 서브키를 생성하는 Sub_Key(340) 상태로 회귀되고, 4라운드가 모두 수행되었으면 키 스케줄을 수행하는 상태로 이행된다.Next, in the state of performing the round (350), 2 rounds are performed using the 8 generated subkeys, and the values are stored in the register. At this time, since the last round is different from the existing round, the final round performs a 32 round algorithm and outputs the value obtained by inserting the final whitening key. In this state, if the first two rounds of the third round are performed before starting the key schedule, the sub key is returned to the sub key (340) state in which the sub key is generated. If all four rounds have been performed, the key schedule is executed.

다음으로 Delta Change(360) 상태에서는 라운드의 서브키 조합에 사용되는 델타 데이터패스의 입력값인 delta_constant를 갱신한 후 레지스터에 저장한다.Next, in the Delta Change (360) state, delta_constant, which is an input value of the delta data path used for the sub key combination of the round, is updated and stored in the register.

다음으로 Key schedule(370) 상태에서는 키를 갱신하는 키 스케줄을 수행하는 상태로, 현재 키의 상위 64비트와 하위 64비트 각각 8비트씩 좌측 순환 이동(left shift rotation)시킨 값을 키 레지스터에 저장한다.Next, in the state of Key Schedule (370), left shift rotation of the upper 64 bits and the lower 64 bits of the current key is performed in the key register do.

마지막으로 FINISH(380) 상태에서는 최종 라운드까지 수행된 암호문을 외부 통신 모듈로 전송한다. 그리고 HIGHT의 시작 상태를 알려주는 레지스터를 다시 초기화시킨다.Finally, in the FINISH (380) state, the ciphertext performed until the last round is transmitted to the external communication module. Then, reinitialize the register that indicates the start state of HIGHT.

이상과 같이 HIGHT 하드웨어 IP(230)의 구성을 확인하였으며, 다음으로 PRESENT 하드웨어 IP(240)에 대해서 설명한다.The configuration of the HIGHT hardware IP 230 is confirmed as described above. Next, the PRESENT hardware IP 240 will be described.

PRESENT 하드웨어 IP(240)는 PRESENT 알고리즘을 이용한 하드웨어 IP로 PRESENT 제어기(241) 및 PRESENT 데이터 패스(242)를 포함하여 구성된다.The PRESENT hardware IP 240 includes a PRESENT controller 241 and a PRESENT data path 242 as a hardware IP using a PRESENT algorithm.

PRESENT 제어기(241)는 각 데이터패스를 유한상태기계로 정의하여 상기 각 데이터패스들을 이용한 연산을 수행한다.PRESENT controller 241 defines each data path as a finite state machine and performs operations using the respective data paths.

PRESENT 데이터 패스(242)는 PRESENT 암호 알고리즘을 전체를 수행하는 PRESENT_round_dp 데이터패스와, 룩-업 테이블의 형태로 S-box 0~3 입/출력을 처리하는 4개의 S-box 데이터패스 및 키 스케줄시 사용하는 Key-box 데이터패스로 총 6개의 데이터패스로 구성되며, PRESENT 암호 알고리즘의 라운드 함수는 AddRoundKey, S-box Layer 및 Permutation Layer의 세가지 과정을 포함한다.The PRESENT data path 242 includes a PRESENT_round_dp data path for performing the entire PRESENT cipher algorithm, four S-box data paths for processing input / output of S-boxes 0 to 3 in the form of a look-up table, The PRESENT cryptographic algorithm round function consists of three steps: AddRoundKey, S-box Layer, and Permutation Layer.

상기와 같은 구성으로 PRESENT 제어기(241)는 S-box Layer의 입력과 출력이 필요한 모듈인 룩-업 테이블을 하나의 데이터패스로 구현하였기 때문에 S-box Layer의 입력값들을 레지스터로 선언하여 PRESENT_round_dp 데이터패스와 S-box 데이터패스 간에 발생할 수 있는 지연을 최소화하였다. 따라서 한 사이클마다 S-box Layer, Permutation Layer 및 다음 라운드의 AddRoundKey 를 수행한다. 그 이유는 레지스터에 할당된 값은 다음 라운드에 사용할 수 있으므로 S-box 입력을 중심으로 사이클을 나누는 것이 효율적이기 때문이다. 그리고 레지스터를 8비트 단위로 분할한 이후에 비밀키와 XOR를 수행함으로 64비트 단위 XOR를 수행할 때보다 효율적이다. 또한 소프트웨어인 마이크로프로세서(100)상에서 구현된 키 스케줄링에 의해 전처리된 라운드 키값들을 전송받아서 사용하므로 하드웨어의 효율을 증가시킬 수 있다.Since the PRESENT controller 241 implements the look-up table, which is a module requiring input and output of the S-box layer, as one data path, the PRESENT controller 241 declares the input values of the S-box layer as a register and outputs PRESENT_round_dp data Minimizing the delay between the path and the S-box datapath. Therefore, the S-box layer, the Permutation Layer, and the AddRoundKey of the next round are performed every cycle. This is because the value assigned to the register can be used in the next round, so it is efficient to divide the cycle around the S-box input. Also, since the register is divided into 8 bit units and XOR is performed with the secret key, it is more efficient than performing 64 bit unit XOR. Also, since round key values pre-processed by the key scheduling implemented on the microprocessor 100, which is software, are received and used, the hardware efficiency can be increased.

여기서 PRESENT 제어기(241)의 최적화 방법은 도 3을 참조하여 설명한다. 도 3은 본 발명의 일 실시예에 따른 PRESENT 유한상태기계(FSM)의 전체 흐름을 도시한 도면으로 총 6개의 상태로 구성된다.Here, an optimization method of the PRESENT controller 241 will be described with reference to FIG. FIG. 3 is a view showing the entire flow of a PRESENT finite state machine (FSM) according to one embodiment of the present invention, and is composed of a total of six states.

먼저 Check start(410) 상태에서 통신 모듈과 소프트웨어의 통신이 연결되었는지 확인하여, 연결이 되지 않았다면 암호화를 시작하지 않는다. 정상적으로 연결이 되고 통신 모듈로부터 평문과 키값을 입력받았다면 다음 상태로 넘어간다.First, in Check start (410) state, check whether communication between communication module and software is connected. If connection is not established, encryption is not started. If the connection is normally established and the plaintext and the key value are input from the communication module, the procedure proceeds to the next state.

다음으로 INIT(420) 상태에서는 외부 통신 모듈로부터 평문과 키값을 입력 받은 후 PRESENT_round_dp 내부 레지스터에 저장한다. 그리고 암호화를 수행하는 동안 사용될 레지스터를 초기화하는 상태이다. 본 발명의 실시예들은 라운드 수행 알고리즘이 첫 라운드 AddRoundKey 과정을 수행하지 않도록 구성되어 있으므로 초기 레지스터에 미리 AddRoundKey를 수행하여 저장하는 것이 바람직하다.Next, in the INIT (420) state, the plaintext and the key value are input from the external communication module and stored in the PRESENT_round_dp internal register. And initialize the register to be used during encryption. Embodiments of the present invention are preferably configured such that the round-execution algorithm does not perform the first round AddRoundKey process, so it is preferable to perform the AddRoundKey in the initial register beforehand to store the result.

다음으로 Round(430) 상태에서는 PRESENT의 라운드 함수를 수행하는 상태이다. 라운드 수행 알고리즘은 S-box Layer, Permutation Layer 및 다음 라운드의 AddRoundKey를 수행한 이후에 8비트 레지스터 8개에 나누어 저장한다. 이 상태를 최종라운드까지 수행한다.Next, in the round (430) state, the PRESENT round function is performed. The rounding algorithm is performed by storing the S-box layer, the Permutation Layer, and the AddRoundKey of the next round, and then dividing the result into eight 8-bit registers. This state is performed until the final round.

다음으로 Key schedule(440) 상태에서는 소프트웨어로부터 받은 각 라운드키값을 갱신하고 라운드 상수인 ctr을 증가시킨다. 이때 키는 키값을 저장하는 레지스터에 저장된다.Next, in the Key schedule (440) state, each round key value received from the software is updated and the round constant ctr is increased. At this time, the key is stored in a register storing the key value.

다음으로 S-box(450) 상태에는 Present 암호 알고리즘의 S-box 구성에 맞는 대치(substitution) 연산을 수행한다.Next, in the state of the S-box 450, a substitution operation suitable for the S-box configuration of the Present encryption algorithm is performed.

마지막으로 Finish(460) 상태에서는 최종 라운드까지 수행 시 암호문을 외부 통신 모듈로 전송한다. 그리고 PRESENT의 시작상태를 알려주는 레지스터를 초기화 시킨다.Finally, in the Finish (460) state, the ciphertext is transmitted to the external communication module when the final round is performed. Initialize the register that indicates the start state of PRESENT.

이상과 같이 PRESENT 하드웨어 IP(240)의 구성을 확인하였으며, 다음으로 PRINTcipher 하드웨어 IP(250)에 대해서 설명한다.The configuration of the PRESENT hardware IP 240 is confirmed as described above. Next, the PRINTcipher hardware IP 250 will be described.

PRINTcipher 하드웨어 IP(250)는 PRINTcipher 알고리즘을 이용한 하드웨어 IP로 PRINTcipher 제어기(251) 및 PRINTcipher 데이터 패스(252)를 포함하여 구성된다.The PRINTcipher hardware IP 250 includes a PRINTcipher controller 251 and a PRINTcipher data path 252 as a hardware IP using the PRINTcipher algorithm.

PRINTcipher 제어기(251)는 각 데이터패스를 유한상태기계로 정의하여 상기 각 데이터패스들을 이용한 연산을 수행한다.The PRINTcipher controller 251 defines each data path as a finite state machine and performs operations using the respective data paths.

PRINTcipher 데이터 패스(252)는 PRINTcipher 암호 알고리즘을 전체를 수행하는 PRINTcipher_round_dp 데이터패스와, 룩-업 테이블의 형태로 3비트 단위로 Permutation과 S-box Substritution을 수행하는 4개의 SP-box 데이터패스로 구성된다.The PRINTcipher data path 252 is composed of a PRINTcipher_round_dp data path for performing the entire PRINTcipher encryption algorithm and four SP-box data paths for performing permutation and S-box substration in 3-bit units in the form of a look-up table .

상기와 같은 구성으로 PRINTcipher 제어기(251)는 라운드 함수가 한 사이클 당 2라운드를 수행하게 언폴딩(unfolding) 기법을 적용하여 총 사이클을 감소시켰다. 여기서 언폴딩은 프로그램의 루프 로직을 풀어서 한 번에 여러 연산을 수행하는 방법으로, 이때 공간의 소비가 있으므로 속도적 측면과 공간의 효율을 고려해야 한다.In the above configuration, the PRINT cipher controller 251 reduces the total cycle by applying an unfolding technique so that the round function performs two rounds per cycle. Unfolding is a method of loosening the loop logic of a program and performing multiple operations at a time. In this case, since there is space consumption, the speed aspect and space efficiency should be considered.

또한 PRINTcipher 제어기(251)는 암호화 과정 중 Permutation과 S-box Substitution을 따로 처리하지 않고 하나의 테이블로 미리 설정하여 연산량을 감소시킨다. 따라서 PRINTcipher의 기존 구조인 Key XOR - Permutation - S-box Substitution을 Key XOR - SP-box 구조로 구성하였고 라운드 연산을 수행 시 SP-box 이전에 레지스터를 두어 현재 라운드의 SP-box, 다음 라운드의 Key XOR를 하나의 프로세스로 구성한다. 그리고 상기 프로세스를 한 사이클 당 두 번 수행하게 구성한다. 이로 인해 총 수행 사이클이 감소되는 효과를 얻을 수 있다.Also, the PRINT cipher controller 251 does not process permutation and S-box substitution separately in the encryption process, and reduces the amount of computation by presetting the table as a single table. Therefore, Key XOR - Permutation - S - box Substitution, which is an existing structure of PRINTcipher, is composed by Key XOR - SP - box structure. When round operation is performed, register is placed before SP - box to make SP - box of current round, Key Configure XOR as one process. And to perform the process twice per cycle. Thus, the total execution cycle is reduced.

나아가, SP-box 데이터패스 입력값을 3비트 레지스터 16개로 선언하고, Key XOR 과정을 SP-box 데이터패스 내부에서 수행하도록 구성한다. 그에 따라 48비트의 Key XOR 과정보다 3비트 단위로 나누어져 Key XOR 과정을 수행하여 속도 측면에서의 효율성이 있다.Further, the SP-box data path input value is declared as 16-bit 3-bit registers, and the key XOR process is performed in the SP-box data path. Accordingly, the key XOR process is divided into three bits rather than the 48-bit Key XOR process, thereby achieving efficiency in terms of speed.

여기서 PRINTcipher 제어기(251)의 최적화 방법은 도 4를 참조하여 설명한다. 도 4는 본 발명의 일 실시예에 따른 PRINTcipher 유한상태기계(FSM)의 전체 흐름을 도시한 도면으로 총 5개의 상태로 구성된다.Here, an optimization method of the PRINT cipher controller 251 will be described with reference to Fig. FIG. 4 is a diagram showing the entire flow of a PRINTcipher finite state machine (FSM) according to an embodiment of the present invention, and is composed of five states in total.

먼저, Check start(510) 상태에서 다른 암호화 동일하게 통신 모듈과 소프트웨어의 통신이 연결되었는지 확인하여 연결이 되지 않았다면 암호화를 시작하지 않는다. 정상적으로 연결이 되고 통신 모듈로부터 평문과 키값을 입력 받았다면 다음 상태로 넘어간다.First, in the check start (510) state, it is checked whether communication of the communication module and the software is connected in the same manner as other encryption. If the connection is not established, encryption is not started. If the connection is normally established and the plaintext and the key value are input from the communication module, the procedure proceeds to the next state.

다음으로 INIT(520) 상태에서는 외부 통신 모듈로부터 평문과 키값을 입력 받은 후 PRINTcipher_round_dp 내부 레지스터에 저장한다. 그리고 본 실시예에서는 PRINTcipher의 라운드 수행 알고리즘이 첫 라운드 Key XOR 과정을 수행하지 않도록 구성되어 있으므로 초기 레지스터에 저장할 때 미리 Key XOR를 수행하여 저장한다.Next, in the INIT state (520), the plaintext and the key value are input from the external communication module and stored in the PRINTcipher_round_dp internal register. In this embodiment, the rounding algorithm of the PRINT cipher is configured not to perform the first Round Key XOR process, so the Key Round XOR is performed before storing in the initial register.

다음으로 2R-Round(530) 상태에서는 PRINTcipher의 2라운드 함수를 수행한다. Permutation - S-box Substitution 과정을 미리 테이블로 설정한 3비트 SP-box 데이터패스를 설계하고 SP-box 데이터패스 내부에서 Key XOR를 수행한다.Next, in the 2R-Round (530) state, the PRINTcipher 2 round function is performed. Permutation - Design a 3-bit SP-box datapath with S-box substitution process in advance and perform Key XOR in the SP-box datapath.

PRINTcipher_round_dp에서는 SP-box 데이터패스의 출력값을 입력받고 상기 과정을 한 사이클 당 두번 수행하여 한 사이클에 두 개의 라운드가 수행된다.In PRINTcipher_round_dp, the output value of the SP-box data path is received and the above process is performed twice per cycle, and two rounds are performed in one cycle.

다음으로 SP-box(540) 상태에서는 PRINTcipher의 특성을 나타내는 대치 및 치환(Substitution and Permutation) 연산을 수행한다.Next, in the SP-box 540, a substitution and permutation operation indicating the characteristics of the PRINT cipher is performed.

마지막으로 Finish(550) 상태에서는 암호문을 외부 통신 모듈로 전송한다. 그리고 PRINTcipher의 시작 상태를 알려주는 레지스터를 초기화시킨다.Finally, in the Finish (550) state, the ciphertext is transmitted to the external communication module. Then initialize the register to indicate the start state of PRINTcipher.

이상으로 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치의 마이크로프로세서(100)와 GEZEL 하드웨어 코-프로세서(200)의 구성을 확인하였다. 다음으로 마이크로프로세서(100)와 GEZEL 하드웨어 코-프로세서(200) 간의 통신방법에 대해서 설명한다.The configuration of the microprocessor 100 and the GEZEL hardware co-processor 200 of the lightweight cryptographic apparatus capable of integrating hardware and software has been confirmed. Next, a communication method between the microprocessor 100 and the GEZEL hardware co-processor 200 will be described.

GEZEL을 이용한 통합설계에서 마이크로프로세서(100)가 하드웨어 입출력 장치와 통신 시 사용하는 방식은 메모리 맵 입출력(memory mapped I/O) 방식과 포트 맵 입출력(port mapped I/O) 방식이 있다. 메모리 맵 입출력 방식은 통신 시 입출력과 메모리의 주소 공간을 분리하지 않는 방식이고, 포트 맵 입출력 방식은 입출력 회로와 메모리 주소 공간을 분리하는 방식이다. 입출력 회로가 메모리에 비해 속도가 느린 경우 이 두 공간을 분리하면 속도와 공간의 효율성이 있다. 본 발명의 실시예에서는 IP 블록을 연결 시 포트 맵 입출력 방식을 사용하여 속도와 공간의 효율성을 향상시켰으며, 이는 본 발명의 통신 방법을 포트 맵 입출력 방식으로 한정하는 것은 아니다.In the integrated design using GEZEL, the microprocessor 100 uses a memory mapped I / O scheme and a port mapped I / O scheme in communication with hardware input / output devices. The memory map input / output method does not separate input / output and memory address space in communication, and port map input / output method separates input / output circuit and memory address space. If the I / O circuitry is slower than the memory, there is speed and space efficiency when these two spaces are separated. In the embodiment of the present invention, the efficiency of speed and space is improved by using the port map input / output method when connecting the IP blocks. This does not limit the communication method of the present invention to the port map input / output method.

하드웨어와 소프트웨어 간의 통신 시 신뢰성을 높이기 위해 마이크로프로세서(100)와 GEZEL 하드웨어 코-프로세서(200) 간에 개선된 핸드쉐이크(handshake) 프로토콜을 사용한다. 서로 통신이 확립되면 완료가 되었다는 완료 시그널(done signal)을 보내어 데이터를 주고 받을 수 있는 상태가 되었는지 확인한다. 도 5를 참조하여 개선된 핸드쉐이크 프로토콜을 이용한 통신 방법에 대해서 구체적으로 설명한다.Processor 200 uses an improved handshake protocol between the microprocessor 100 and the GEZEL hardware co-processor 200 to increase reliability in communication between hardware and software. Once the communication is established, a done signal indicating that the communication has been completed is sent to check whether data can be exchanged. A communication method using the improved handshake protocol will be described in detail with reference to FIG.

도 5는 본 발명의 일 실시예에 따른 핸드쉐이크 프로토콜을 이용한 통신 방법을 나타내는 순서도이다. 5 is a flowchart illustrating a communication method using a handshake protocol according to an embodiment of the present invention.

먼저 마이크로프로세서(100)가 GEZEL 하드웨어 코-프로세서(200)로 제1명령과 제2명령을 전송하고, GEZEL 하드웨어 코-프로세서(200)는 제1명령과 제2명령을 수신하여 동작을 순차적 또는 한번에 병렬적으로 수행한다(S10).First, the microprocessor 100 sends a first instruction and a second instruction to the GEZEL hardware co-processor 200, and the GEZEL hardware co-processor 200 receives the first instruction and the second instruction, Are performed in parallel at once (S10).

다음으로 GEZEL 하드웨어 코-프로세서(200)가 수신한 제1명령과 제2명령 중 먼저 완료된 동작의 제1완료 시그널을 마이크로프로세서(100)로 전송한다(S20). 제1완료 시그널을 수신한 마이크로프로세서(100)는 제3명령과 제4명령을 생성하여 버퍼에 저장한다(S30).Next, the first complete signal of the first command received by the GEZEL hardware co-processor 200 and the first completed signal of the second command are transmitted to the microprocessor 100 (S20). The microprocessor 100 receiving the first completion signal generates a third instruction and a fourth instruction and stores the third instruction and the fourth instruction in the buffer (S30).

다음으로 GEZEL 하드웨어 코-프로세서(200)가 수신한 제1명령과 제2명령 중 나중에 완료된 동작의 제2완료 시그널을 마이크로프로세서(100)로 다시 전송한다(S40). 제2완료 시그널을 수신한 마이크로프로세서(100)는 버퍼에 저장된 제3명령과 제4명령을 GEZEL 하드웨어 코-프로세서(200)로 전송한다(S50).Next, the GEZEL hardware co-processor 200 transmits the first command received and the second completed signal of the second command to the microprocessor 100 (S40). The microprocessor 100 receiving the second completion signal transmits the third command and the fourth command stored in the buffer to the GEZEL hardware co-processor 200 (S50).

이상으로 핸드쉐이크 프로토콜을 이용한 통신 방법을 확인하였다. 상기 단계를 반복적으로 수행하여 통신을 수행하며, 이를 통해 GEZEL 하드웨어 코-프로세서(200)에서 암호화 수행 중에도 마이크로프로세서(100)와 메시지를 주고 받을 수 있다.Thus, the communication method using the handshake protocol is confirmed. The GEZEL hardware co-processor 200 can exchange messages with the microprocessor 100 during encryption by repeatedly performing the above steps to perform communication.

상기된 본 발명의 실시예들에 따르면, 본 발명은 경량암호가 사용될 수 있는 IoT 제품이나 RFID/USN 및 스마트카드 등에 탑재되어 효율적인 암호화 연산에 사용될 수 있으며, 기존에 탑재되어 있는 PRINTcipher 경량암호 기반의 전자 제품에 대체하여 탑재할 수 있고, 다양한 운용모드에 바로 적용할 수 있어 제품 및 플랫폼에 상관없이 적용할 수 있다는 장점을 갖는다.According to the embodiments of the present invention described above, the present invention can be applied to an efficient encryption operation by being mounted on an IoT product, a RFID / USN, a smart card, etc. in which a lightweight password can be used, and a PRINTcipher lightweight password- And can be applied to various operation modes, so that it can be applied regardless of products and platforms.

본 명세서에 기재된 본 발명의 실시 예와 도면에 도시된 구성은 본 발명의 가장 바람직한 실시 예에 관한 것이고, 발명의 기술적 사상을 모두 포괄하는 것은 아니므로, 출원시점에 있어서 이들을 대체할 수 있는 다양한 균등물과 변형 예들이 있을 수 있음을 이해하여야 한다. 따라서 본 발명은 상술한 실시 예에 한정되지 아니하며, 청구범위에서 청구하는 본 발명의 요지를 벗어남이 없이 당해 발명이 속하는 기술분야에서 통상의 지식을 가진 자라면 누구든지 다양한 변형실시가 가능한 것은 물론이고, 그와 같은 변경은 청구범위 기재의 권리범위 내에 있게 된다.The embodiments of the present invention described in the present specification and the configurations shown in the drawings relate to the most preferred embodiments of the present invention and are not intended to encompass all of the technical ideas of the present invention so that various equivalents It should be understood that water and variations may be present. Therefore, it is to be understood that the present invention is not limited to the above-described embodiments, and that various modifications may be made without departing from the spirit and scope of the invention as defined in the appended claims. , Such changes shall be within the scope of the claims set forth in the claims.

100: 마이크로프로세서 110: 전자 코드북(ECB) 운용모드
120: 암호 블록 체인(CBC) 운용모드 130: 카운터(CTR) 운용모드
140: 암호 피드백(CFB) 운용모드 150: 출력 피드백(OFB) 운용모드
200: GEZEL 하드웨어 코-프로세서 210: GEZEL IP 블록
220: 데이터 로더 230: HIGHT 하드웨어 IP
240: PRESENT 하드웨어 IP 250: PRINTcipher 하드웨어 IP
100: Microprocessor 110: Electronic codebook (ECB) operating mode
120: Cipher block chain (CBC) operation mode 130: Counter (CTR) operation mode
140: Password feedback (CFB) operation mode 150: Output feedback (OFB) operation mode
200: GEZEL hardware co-processor 210: GEZEL IP block
220: Data Loader 230: HIGHT Hardware IP
240: PRESENT hardware IP 250: PRINTcipher hardware IP

Claims (12)

블록 암호 운용 방식에 따르는 마이크로프로세서; 및
상기 마이크로프로세서와 연결되어 통신하는 GEZEL 하드웨어 코-프로세서(H/W co-processor);를 포함하며,
상기 GEZEL 하드웨어 코-프로세서는,
GEZEL IP(intellectual property) 블록; 및
데이터패스(datapath)를 이용한 유한상태기계(Finite state machine with datapath, FSMD) 방식으로 동작시키는 하나 이상의 하드웨어 IP;를 포함하고,
상기 마이크로프로세서는 하드웨어와 소프트웨어의 통합 설계 시 각 대칭키 암호의 알고리즘 중 키 스케줄 부분을 소프트웨어에서 구현하여 미리 각 라운드키 값을 계산하고, 상기 계산된 라운드키를 하드웨어로 보내어 상기 하드웨어에서 키 스케줄 연산 처리 과정을 생략시킴으로써 속도를 증대시키며,
상기 마이크로프로세서가 한 사이클에 두 명령을 상기 하드웨어로 전송하면, 상기 하드웨어는 상기 두 명령을 순차적 또는 병렬적으로 수행하되, 상기 마이크로프로세서는 상기 하드웨어로부터 첫 명령전송에 대응하는 하나의 완료명령을 받은 후 다음 사이클에 두 명령을 다시 상기 하드웨어로 보내는 통신을 통해, 첫 연산 사이클 이후 소프트웨어 연산 시 하드웨어의 동작 대기 시간을 줄이고, 소프트웨어와 하드웨어가 암호화 연산 수행 중에도 메시지를 송수신하는 인터페이스를 구현하는 것을 특징으로 하는 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치.
A microprocessor according to a block cipher operation scheme; And
And a GEZEL hardware co-processor communicatively coupled to the microprocessor,
The GEZEL hardware co-
GEZEL intellectual property (IP) block; And
One or more hardware IPs operating in a finite state machine with datapath (FSMD) scheme using a datapath,
In the integrated design of the hardware and the software, the microprocessor calculates the round key value in advance by implementing the key schedule part of the symmetric key cryptographic algorithm in software, and sends the calculated round key to the hardware, By speeding up the process by omitting the process,
The microprocessor performs two instructions sequentially or in parallel when the microprocessor sends two instructions to the hardware in one cycle, the microprocessor receives a single completion instruction corresponding to the first instruction transmission from the hardware And an interface for transmitting and receiving a message during software and hardware operations during a cryptographic operation is implemented by reducing the waiting time of hardware operation during software operation after the first arithmetic cycle through communication for sending two commands back to the hardware in the next cycle A lightweight encryption device capable of integrated design of hardware and software.
제 1항에 있어서,
상기 마이크로프로세서는,
전자 코드북(ECB), 암호 블록 체인(CBC), 카운터(CTR), 암호 피드백(CFB), 및 출력 피드백(OFB) 중 어느 하나의 방식을 선택하여 블록 암호를 운용하는 것을 특징으로 하는 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치.
The method according to claim 1,
The microprocessor,
Characterized in that a block cipher is operated by selecting one of ECB, ECB, CBC, CTR, CFB, and OFB. Lightweight encryption device with integrated design.
제 1항에 있어서,
상기 하나 이상의 하드웨어 IP는,
경량암호 HIGHT 기법의 하드웨어 IP, 경량암호 PRESENT 기법의 하드웨어 IP, 및 경량암호 PRINTcipher 기법의 하드웨어 IP를 포함하는 것을 특징으로 하는 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치.
The method according to claim 1,
The one or more hardware IPs
A hardware IP of a lightweight encryption HIGHT technique, a hardware IP of a lightweight encryption PRESENT technique, and a hardware IP of a lightweight encryption PRINT cipher technique.
제 3항에 있어서,
상기 경량암호 HIGHT 기법의 하드웨어 IP는,
상기 경량암호 HIGHT 기법의 각 데이터패스를 유한상태기계로 정의하여 제어하는 HIGHT 제어기;
상기 경량암호 HIGHT 기법의 암호 알고리즘을 수행하는 HIGHT_round_dp 데이터패스;
키 스케줄(key schedule)을 수행하는 KEY expand 데이터패스;
룩-업 테이블(look-up table) 형태로 내부 함수의 출력 값을 갖는 F0 및 F1 데이터패스; 및
라운드의 서브키(subkey) 조합에 사용되는 델타(delta)값을 저장하는 delta 데이터패스;를 포함하는 것을 특징으로 하는 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치.
The method of claim 3,
The hardware IP of the lightweight cryptographic HIGHT technique,
A HIGHT controller for defining and controlling each data path of the lightweight cryptographic HIGHT technique as a finite state machine;
A HIGHT_round_dp data path for performing a cryptographic algorithm of the lightweight cryptographic HIGHT technique;
A KEY expand data path that performs a key schedule;
F 0 and F 1 data paths having output values of the inner function in the form of a look-up table; And
And a delta data path for storing a delta value used for a combination of subkeys of the round.
제 4항에 있어서,
상기 HIGHT 제어기는,
서브키를 16개 사용하는 4라운드 수행 후 키스케줄을 수행하되,
4라운드 수행시 레지스터의 위치를 변경하는 리타이밍(retiming)을 적용하여 크리티컬 패스(critical path)의 지연(delay)을 감소시키는 것을 특징으로 하는 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치.
5. The method of claim 4,
The HIGHT controller comprises:
After performing 4 rounds using 16 subkeys, perform key schedule,
Wherein a delay of a critical path is reduced by applying retiming for changing a position of a register in a round of 4 rounds.
제 3항에 있어서,
상기 경량암호 PRESENT 기법의 하드웨어 IP는,
상기 경량암호 PRESENT 기법의 각 데이터패스를 유한상태기계로 정의하여 제어하는 PRESENT 제어기;
상기 경량암호 PRESENT 기법의 암호 알고리즘을 수행하는 PRESENT_round_dp 데이터패스;
룩-업 테이블(look-up table) 형태로 입출력을 처리하는 복수 개의 S-box 데이터패스; 및
키 스케줄 시 사용하는 Key-box 데이터패스;를 포함하는 것을 특징으로 하는 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치.
The method of claim 3,
The hardware IP of the lightweight encryption PRESENT technique,
A PRESENT controller for defining and controlling each data path of the lightweight PRESENT technique as a finite state machine;
A PRESENT_round_dp data path for performing the encryption algorithm of the lightweight encryption PRESENT scheme;
A plurality of S-box data paths for processing input and output in the form of a look-up table; And
And a key-box data path for use in key scheduling.
제 6항에 있어서,
상기 PRESENT 제어기는,
입력과 출력이 필요한 S-box를 상기 룩-업 테이블을 이용하여 하나의 데이터패스로 처리하되 S-box Layer의 입력값들을 레지스터로 선언함으로써 상기 PRESENT_round_dp 데이터패스와 상기 S-box 데이터패스 간에 발생할 수 있는 지연을 감소시켰으며,
하나의 사이클마다 S-box Layer, Permutation Layer, 및 다음 라운드의 AddRoundKey를 수행하는 것을 특징으로 하는 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치.
The method according to claim 6,
Wherein the PRESENT controller comprises:
By using the look-up table to process an S-box requiring input and output as one data path and declaring the input values of the S-box layer as a register, it can be generated between the PRESENT_round_dp data path and the S- The delay is reduced,
Wherein the S-box layer, the Permutation Layer, and the AddRoundKey of the next round are performed for each cycle.
제 3항에 있어서,
상기 경량암호 PRINTcipher 기법의 하드웨어 IP는,
상기 경량암호 PRINTcipher 기법의 각 데이터패스를 유한상태기계로 정의하여 제어하는 PRINTcipher 제어기;
상기 경량암호 PRINTcipher 기법의 암호 알고리즘을 수행하는 PRINTcipher_round_dp 데이터패스; 및
Permutation과 S-box Substitution을 수행하는 복수 개의 SP-box 데이터패스;를 포함하는 것을 특징으로 하는 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치.
The method of claim 3,
The hardware IP of the lightweight cryptographic PRINT cipher technique,
A PRINT cipher controller for defining and controlling each data path of the lightweight cryptographic PRINT cipher technique as a finite state machine;
A PRINTcipher_round_dp data path that performs the encryption algorithm of the lightweight cryptographic PRINT cipher technique; And
And a plurality of SP-box data paths for performing permutation and S-box substitution.
제 8항에 있어서,
상기 PRINTcipher 제어기는,
PRINTcipher 기법에 따른 Permutation과 S-box Substitution의 전처리 부분을 미리 하나의 테이블로 설정하여 연산량을 감소시키며,
반복 수행되는 라운드 연산의 루프(loop) 로직을 재구성하여 하나의 루프마다 데이터의 읽기 및 쓰기 횟수를 증가시켜 수행 사이클(cycle)을 감소시키는 언폴딩(unfolding)을 적용하는 것을 특징으로 하는 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치.
9. The method of claim 8,
The PRINT cipher controller includes:
The pre-processing part of permutation and S-box substitution according to PRINTcipher method is set in advance as one table,
Wherein the loop logic of the round operation to be repeatedly performed is reconfigured to apply unfolding to reduce a cycle by increasing the number of times of reading and writing data in each loop. Lightweight encryption device with integrated design.
제 1항에 있어서,
상기 마이크로프로세서는,
상기 GEZEL 하드웨어 코-프로세서 입출력 장치와 통신 시, 메모리 맵 입출력(memory mapped I/O)방식 또는 포트 맵 입출력(port mapped I/O)방식을 이용하여 연결되는 것을 특징으로 하는 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치.
The method according to claim 1,
The microprocessor,
The integrated hardware and software design is connected to the GEZEL hardware co-processor I / O device using a memory mapped I / O scheme or a port mapped I / O scheme. Possible lightweight encryption device.
제 1항에 있어서,
상기 마이크로프로세서는,
상기 GEZEL 하드웨어 코-프로세서와 통신 시, 암호화와 메시지 송수신이 동시에 병렬로 수행하는 핸드쉐이크 (handshake) 프로토콜을 이용하여 메시지를 송수신하는 것을 특징으로 하는 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치.
The method according to claim 1,
The microprocessor,
Wherein a message is transmitted and received using a handshake protocol in which encryption and message transmission and reception are simultaneously performed in parallel with each other in communication with the GEZEL hardware co-processor.
제 11항에 있어서,
상기 마이크로프로세서는 상기 핸드쉐이크 프로토콜을 이용한 통신을 위해,
상기 마이크로프로세서가 상기 GEZEL 하드웨어 코-프로세서로 제1명령과 제2명령을 전송하고, 상기 GEZEL 하드웨어 코-프로세서는 상기 제1명령과 상기 제2명령을 수신하여 동작을 순차적 또는 한번에 병렬적으로 수행하고,
상기 GEZEL 하드웨어 코-프로세서가 수신한 상기 제1명령과 상기 제2명령 중 먼저 완료된 동작의 제1완료 시그널을 상기 마이크로프로세서로 전송하며,
상기 제1완료 시그널을 수신한 상기 마이크로프로세서가 제3명령과 제4명령을 생성하여 버퍼에 저장하고,
상기 GEZEL 하드웨어 코-프로세서가 수신한 상기 제1명령과 상기 제2명령 중 나중에 완료된 동작의 제2완료 시그널을 상기 마이크로프로세서로 전송하며,
상기 제2완료 시그널을 수신한 상기 마이크로프로세서가 상기 버퍼에 저장된 상기 제3명령과 상기 제4명령을 상기 GEZEL 하드웨어 코-프로세서로 전송하는 과정을 반복 수행하는 것을 특징으로 하는 하드웨어와 소프트웨어 통합 설계가 가능한 경량암호 장치.
12. The method of claim 11,
Wherein the microprocessor, for communication using the handshake protocol,
Wherein the microprocessor transmits a first instruction and a second instruction to the GEZEL hardware co-processor, the GEZEL hardware co-processor receives the first instruction and the second instruction and performs an operation sequentially or at a time in parallel and,
Wherein the first and second instructions received by the GEZEL hardware co-processor and the first completed signal of the first completed operation are transmitted to the microprocessor,
The microprocessor receiving the first completion signal generates a third instruction and a fourth instruction and stores the third instruction and the fourth instruction in a buffer,
The first instruction received by the GEZEL hardware co-processor and the second completed signal of a later completed operation of the second instruction to the microprocessor,
And the microprocessor that has received the second completion signal repeatedly transmits the third instruction and the fourth instruction stored in the buffer to the GEZEL hardware co-processor. Possible lightweight encryption device.
KR1020150084003A 2015-06-15 2015-06-15 Lightweight cryptographic apparatus using hardware and software co-design KR101693591B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020150084003A KR101693591B1 (en) 2015-06-15 2015-06-15 Lightweight cryptographic apparatus using hardware and software co-design

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020150084003A KR101693591B1 (en) 2015-06-15 2015-06-15 Lightweight cryptographic apparatus using hardware and software co-design

Publications (2)

Publication Number Publication Date
KR20160147361A KR20160147361A (en) 2016-12-23
KR101693591B1 true KR101693591B1 (en) 2017-01-17

Family

ID=57736103

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020150084003A KR101693591B1 (en) 2015-06-15 2015-06-15 Lightweight cryptographic apparatus using hardware and software co-design

Country Status (1)

Country Link
KR (1) KR101693591B1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107508666A (en) * 2017-08-31 2017-12-22 华南理工大学 It is a kind of based on RSA and SHA 512 low-cost digital sign SOPC design methods

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100418575B1 (en) * 2002-04-03 2004-02-14 주식회사 하이닉스반도체 Apparatus for encryption of Data Encryption Standard of Cipher Block Chaining mode

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
Herwin Chan, Accelerating Applications Through Cross-layer Co-design, ProQuest, 2007(2007. 공개)*
Lars Knudsen 외 3인, "PRINTcipher:A Block Cipher for IC-Printing", Cryptographic Hardware and Embedded Systems 2010(2010.08.20. 공개)*
김동규 외 5인, 경량 암호 알고리즘(HIGHT)의 하드웨어적 구현 방안 연구, KISA 최종연구보고서(2011.11. 공개)*

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107508666A (en) * 2017-08-31 2017-12-22 华南理工大学 It is a kind of based on RSA and SHA 512 low-cost digital sign SOPC design methods

Also Published As

Publication number Publication date
KR20160147361A (en) 2016-12-23

Similar Documents

Publication Publication Date Title
US11615716B2 (en) Lightweight cryptographic engine
JP4890976B2 (en) Cryptographic processing device
US7606365B2 (en) Encryption/decryption system and key scheduler with variable key length
US8515059B2 (en) Cryptographic processor with dynamic update of encryption state
US20110255689A1 (en) Multiple-mode cryptographic module usable with memory controllers
US20080019524A1 (en) Apparatus and method for low power aes cryptographic circuit for embedded system
CN111722831B (en) Encryption system and implementation method thereof
JP2010245881A (en) Cipher processor
KR101658397B1 (en) Lightweight cryptographic apparatus using PRESENT
US6873707B1 (en) Hardware-based encryption/decryption employing cycle stealing
JPH10333569A (en) Cipher processor, ic card and cipher processing method
KR101693591B1 (en) Lightweight cryptographic apparatus using hardware and software co-design
KR100949538B1 (en) Apparatus and method for improving rate encryption and decryption using aes rijndael algorithm
EP3889764A1 (en) Parallel generation of a random matrix
CN105721139B (en) A kind of the AES encipher-decipher method and circuit of the FPGA suitable for limited I/O resource
Rashidi et al. FPGA based a new low power and self-timed AES 128-bit encryption algorithm for encryption audio signal
KR101655862B1 (en) Lightweight cryptographic apparatus using PRINTcipher
KR101664799B1 (en) Lightweight cryptographic apparatus using HIGHT
KR100667189B1 (en) Apparatus for aes encryption in mobile device and method thereby
Hasamnis et al. implementation of AES as a custom hardware using NIOS II processor
Daoud et al. High-level synthesis optimization of aes-128/192/256 encryption algorithms
Panato et al. An IP of an Advanced Encryption Standard for Altera/spl trade/devices
Yao et al. A dynamic reconfigurable design of multiple cryptographic algorithms based on FPGA
CN106788968A (en) It is applied to the implementation method of the security coprocessor of WIA-PA agreements
KR102319459B1 (en) Method and system for communication based on hash-based message authentication code

Legal Events

Date Code Title Description
E701 Decision to grant or registration of patent right
GRNT Written decision to grant
FPAY Annual fee payment

Payment date: 20200102

Year of fee payment: 4