KR102565850B1 - A TEE-based decentralized oracle system and method of transferring external data in the oracle system - Google Patents

A TEE-based decentralized oracle system and method of transferring external data in the oracle system Download PDF

Info

Publication number
KR102565850B1
KR102565850B1 KR1020200102278A KR20200102278A KR102565850B1 KR 102565850 B1 KR102565850 B1 KR 102565850B1 KR 1020200102278 A KR1020200102278 A KR 1020200102278A KR 20200102278 A KR20200102278 A KR 20200102278A KR 102565850 B1 KR102565850 B1 KR 102565850B1
Authority
KR
South Korea
Prior art keywords
oracle
node
data
transaction
blockchain network
Prior art date
Application number
KR1020200102278A
Other languages
Korean (ko)
Other versions
KR20220021576A (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 KR1020200102278A priority Critical patent/KR102565850B1/en
Publication of KR20220021576A publication Critical patent/KR20220021576A/en
Application granted granted Critical
Publication of KR102565850B1 publication Critical patent/KR102565850B1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/23Updating
    • G06F16/2365Ensuring data consistency and integrity
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/16Error detection or correction of the data by redundancy in hardware
    • G06F11/18Error detection or correction of the data by redundancy in hardware using passive fault-masking of the redundant circuits
    • G06F11/183Error detection or correction of the data by redundancy in hardware using passive fault-masking of the redundant circuits by voting, the voting not being performed by the redundant components
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/18File system types
    • G06F16/182Distributed file systems
    • G06F16/1834Distributed file systems implemented based on peer-to-peer networks, e.g. gnutella
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/64Protecting data integrity, e.g. using checksums, certificates or signatures
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/12Applying verification of the received information
    • H04L63/123Applying verification of the received information received data contents, e.g. message integrity
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/104Peer-to-peer [P2P] networks
    • H04L67/1087Peer-to-peer [P2P] networks using cross-functional networking aspects
    • H04L67/1093Some peer nodes performing special functions

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Computing Systems (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Computer Hardware Design (AREA)
  • Software Systems (AREA)
  • Health & Medical Sciences (AREA)
  • Quality & Reliability (AREA)
  • General Health & Medical Sciences (AREA)
  • Bioethics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Computer And Data Communications (AREA)

Abstract

본 발명은 신뢰 실행 환경을 기반으로 한 탈중앙형 오라클 시스템에 관한 것이다. 상기 탈중앙형 오라클 시스템은, 복수 개의 오라클 노드들이 프라이빗 블록체인 네트워크로 구성되어 외부의 블록체인 네트워크로부터의 요청에 따라 외부 데이터 소스의 데이터를 제공한다. 상기 오라클 노드는, 외부의 블록체인 네트워크에 의해 요청된 트랜잭션을 신뢰 실행 환경(TEE)에서 수행하는 트랜잭션 처리 장치; PoET 합의 알고리즘에 따라 리더 오라클 노드를 무작위로 선출하는 합의 엔진 모듈; 리더 오라클 노드로 선출되면, 검증자로서 일정 주기마다 블록을 생성하고 블록체인에 연결하여 블록을 배포하도록 구성된 블록 매니지먼트 모듈; 를 구비하여, PoET 합의 알고리즘에 따라 오라클 노드들 중에서 선출된 리더 오라클 노드가 검증자 노드로서 동작할 수 있도록 구성된다. The present invention relates to a decentralized oracle system based on a trusted execution environment. In the decentralized oracle system, a plurality of oracle nodes are configured as a private blockchain network to provide data from an external data source according to a request from an external blockchain network. The oracle node may include a transaction processing device that performs a transaction requested by an external blockchain network in a trusted execution environment (TEE); A consensus engine module that randomly selects a leader oracle node according to the PoET consensus algorithm; If elected as a leader oracle node, a block management module configured to generate blocks at regular intervals as a validator and distribute blocks by connecting to a blockchain; It is configured so that a leader oracle node selected from among oracle nodes according to the PoET consensus algorithm can operate as a verifier node.

Description

신뢰 실행 환경을 기반으로 한 탈중앙형 오라클 시스템 및 상기 시스템에서의 외부 데이터 전달 방법{A TEE-based decentralized oracle system and method of transferring external data in the oracle system} A TEE-based decentralized oracle system and method of transferring external data in the oracle system}

본 발명은 블록체인 네트워크의 오라클 시스템에 관한 것으로서, 더욱 구체적으로는 데이터 무결성을 보장하고 데이터 조작이 불가능하며, 중앙화로 인한 단일 장애점 문제와 분산 오라클에서의 확장성과 성능 문제를 해결하기 위하여, 프라이빗 블록체인인 하이퍼레저를 이용하여 신뢰 실행 환경(Trusted Execution Environment; TEE)을 기반으로 하여 구성된 탈중앙형 오라클 시스템에 관한 것이다. The present invention relates to an oracle system of a blockchain network, and more specifically, to ensure data integrity, to prevent data manipulation, to solve the single point of failure problem due to centralization and the scalability and performance problem in distributed oracles, It is about a decentralized oracle system built on the basis of a Trusted Execution Environment (TEE) using hyperledger, a blockchain.

블록체인은 비트코인에서 처음으로 등장한 기술로서, 모든 네트워크 참가자가 원장을 소유하고 합의 알고리즘을 통해 거래를 검증함으로써, 제3자의 개입 없이도 무결성 및 신뢰성을 확보하는 동등 계층간 통신망(Peer-to-Peer Network, P2P) 기반 분산원장 기술이다. 블록체인은 네트워크에서 발생한 입력과 출력, 즉 트랜잭션(Transaction)들을 블록체인 네트워크의 모든 참여자가 저장하고, 저장한 트랜잭션 내용을 바탕으로, 발생한 트랜잭션의 실행(혹은 결과)에 대한 유효성을 검증함으로써 트랜잭션의 무결성(Integrity)을 보장하는 장점을 가진다. 이때, 트랜잭션은 다수의 트랜잭션을 블록(Block)에 담아 합의(Consensus) 과정을 거친다. 합의는 모든 참여자가 동일한 트랜잭션의 실행 결과를 공유하기 위해 어떤 블록(혹은 결과)으로 통일할지 채택하는 과정이다. Blockchain is a peer-to-peer communication network that secures integrity and reliability without third party intervention by all network participants owning the ledger and verifying transactions through a consensus algorithm. Network, P2P) based distributed ledger technology. The blockchain stores the inputs and outputs that occurred in the network, that is, transactions, by all participants in the blockchain network, and verifies the validity of the execution (or result) of the transaction based on the stored transaction contents, thereby verifying the validity of the transaction. It has the advantage of guaranteeing integrity. At this time, the transaction goes through a consensus process by putting multiple transactions into a block. Consensus is a process in which all participants adopt a unified block (or result) to share the execution result of the same transaction.

이러한 특성을 갖는 블록체인 기술은 이중 지불 문제를 해결하는 P2P 전자화폐 거래시스템인 비트코인의 기술로 개발되었지만, 최근에는 건강 관리, 사물인터넷 또는 의료데이터 관리와 같은 다양한 분야를 지원할 수 있는 혁신적인 기술로 등장하게 되었다. Blockchain technology with these characteristics was developed as the technology of Bitcoin, a P2P electronic money transaction system that solves the double payment problem, but recently it has been developed as an innovative technology that can support various fields such as health management, the Internet of Things, or medical data management. came to appear

한편, 블록체인기술에 스마트 컨트랙트가 도입되면서 블록체인의 응용분야가 더 다양해지게 되었다. 스마트 컨트랙트(Smart contract)는 블록체인 네트워크에서 실행되는 응용 프로그램의 실행 코드이며, 코드가 공개적으로 블록체인에 저장되고 코드의 실행이 참여자간의 합의를 통해 일관성과 무결성을 보장받게 된다. 따라서, 스마트 컨트랙트를 이용하여, 다양한 분야의 탈중앙 어플리케이션이 개발되고 있다. On the other hand, with the introduction of smart contracts to blockchain technology, the application fields of blockchain have become more diverse. A smart contract is the execution code of an application program running on a blockchain network. The code is stored openly on the blockchain, and the consistency and integrity of the code execution is guaranteed through consensus among participants. Therefore, decentralized applications in various fields are being developed using smart contracts.

한편, 블록체인의 스마트 컨트랙트는 일반 응용 프로그램과 달리 특수한 한계점이 존재한다. 모든 참여자가 트랜잭션의 실행과 검증에 참여하는 블록체인의 특징상, 어떤 참여자의 환경에서 실행해도 같은 입력에 같은 결과가 나오는 결정성(Deterministic)이 보장되어야 하나의 실행 결과로 합의가 가능하다. 실행 결과의 결정성을 위해 스마트 컨트랙트는 네트워크를 통해 외부 데이터에 접근이 불가능하고, 오직 원장(혹은 블록)에 저장된 데이터만 접근이 가능하다. On the other hand, blockchain smart contracts have special limitations unlike general applications. Due to the characteristics of blockchain, in which all participants participate in the execution and verification of transactions, an agreement can be reached with one execution result only when deterministicity is guaranteed, in which the same input gives the same result no matter which participant executes it in the environment. For determinism of execution results, smart contracts cannot access external data through the network, and only data stored in the ledger (or block) can be accessed.

이와 같이, 블록체인 외부 데이터(이하 외부 데이터)에 접근이 불가능한 한계점을 오라클 문제(Oracle problem)라고 하고, 이런 한계점을 극복하기 위해 외부 데이터를 블록체인에 제공하는 데이터 중개자 또는 미들웨어(middle-ware)를 오라클(Oracle)이라고 한다. 외부 데이터를 블록체인 내부로 가져오기 위하여 블록체인과 동일한 수준의 보안성이 보장되거나 데이터 제공자인 오라클을 신뢰할 수 있어야 한다. 따라서, 오라클은 데이터 중개자로서, 외부 출처로부터 받은 외부 데이터에 변조가 없다는 무결성(Integrity)을 증명해야 한다.In this way, the limitation of not being able to access data external to the blockchain (hereinafter referred to as external data) is called the Oracle problem, and to overcome this limitation, data brokers or middle-ware that provide external data to the blockchain is called Oracle. In order to bring external data into the block chain, the same level of security as the block chain must be guaranteed or the data provider oracle must be trusted. Therefore, an oracle, as a data intermediary, must prove integrity that external data received from external sources is not tampered with.

따라서, 블록체인 오라클 문제를 해결하기 위하여 Oraclize, Town-crier, Chainlink 등과 같은 다양한 오라클 프로토콜이 제안되었다. 그러나, 기존의 오라클 프로토콜에는 중앙 집중식 문제 또는 데이터를 가져오기 위한 보안 채널 및 사물 인터넷 데이터와 같이 시간에 따라 가치가 다른 시변(Time-variant) 데이터를 제공하는 데 한계가 있다. 또한, 이더리움과 같은 외부 데이터를 제공할 블록체인에서 일부 검증 과정이 불가능하며 과도한 연산을 요구하게 되는 문제점이 있다. Therefore, various oracle protocols such as Oraclize, Town-crier, and Chainlink have been proposed to solve the blockchain oracle problem. However, existing oracle protocols have limitations in providing time-variant data whose values vary over time, such as secure channels for centralized problems or data fetching and Internet of Things data. In addition, there is a problem in that some verification processes are impossible in a block chain that will provide external data such as Ethereum, and excessive computation is required.

한국등록특허공보 제 10-2023101호Korean Registered Patent Publication No. 10-2023101 한국공개특허공보 제 10-2018-0069856호Korean Patent Publication No. 10-2018-0069856 미국공개특허공보 US 2019/0095879US Published Patent Publication US 2019/0095879

전술한 문제점을 해결하기 위한 본 발명의 목적은 외부 데이터 소스로부터 외부 데이터를 가져오는 과정에서 데이터 무결성, 데이터 가용성 및 오라클의 응답시간을 보장할 수 있도록 하는 신뢰 실행 환경을 기반으로 한 탈중앙형 오라클 시스템을 제공하는 것이다. An object of the present invention to solve the above problems is a decentralized oracle based on a trusted execution environment that can guarantee data integrity, data availability and oracle response time in the process of importing external data from an external data source. to provide the system.

전술한 기술적 과제를 달성하기 위한 본 발명의 제1 특징에 따른 신뢰 실행 환경을 기반으로 한 탈중앙형 오라클 시스템은, 복수 개의 오라클 노드들이 프라이빗 블록체인 네트워크로 구성되어 외부의 블록체인 네트워크로부터의 요청에 따라 외부 데이터 소스의 데이터를 제공하는 것을 특징으로 하며, A decentralized oracle system based on a trusted execution environment according to the first feature of the present invention for achieving the above-described technical problem is composed of a plurality of oracle nodes as a private blockchain network and requests from an external blockchain network It is characterized by providing data from an external data source according to,

상기 오라클 노드는, 외부의 블록체인 네트워크에 의해 요청된 트랜잭션을 신뢰 실행 환경(TEE)에서 수행하는 트랜잭션 처리 장치; PoET(Proof-of-Elapsed-Time) 합의 알고리즘에 따라 상기 복수 개의 오라클 노드들 중 리더 오라클 노드를 무작위로 선출하는 합의 엔진 모듈; 리더 오라클 노드로 선출되면, 검증자로서 일정 주기마다 블록을 생성하고 블록체인에 연결하여 블록을 배포하도록 구성된 블록 매니지먼트 모듈; 를 구비하여, PoET 합의 알고리즘에 따라 오라클 노드들 중에서 선출된 리더 오라클 노드가 검증자 노드로서 동작할 수 있도록 구성된다. The oracle node may include a transaction processing device that performs a transaction requested by an external blockchain network in a trusted execution environment (TEE); a consensus engine module that randomly selects a leader oracle node from among the plurality of oracle nodes according to a proof-of-elapsed-time (PoET) consensus algorithm; If elected as a leader oracle node, a block management module configured to generate blocks at regular intervals as a validator and distribute blocks by connecting to a blockchain; It is configured so that a leader oracle node selected from among oracle nodes according to the PoET consensus algorithm can operate as a verifier node.

전술한 제1 특징에 따른 TEE를 기반으로 한 탈중앙형 오라클 시스템에 있어서, 상기 오라클 노드들은 프라이빗 블록체인 내트워크인 하이퍼레저를 이용하여 peer-to-peer(P2P) 블록체인 네트워크를 구성한 것이 바람직하다. In the decentralized oracle system based on the TEE according to the first feature described above, it is preferable that the oracle nodes configure a peer-to-peer (P2P) blockchain network using hyperledger, a private blockchain network. do.

전술한 제1 특징에 따른 TEE를 기반으로 한 탈중앙형 오라클 시스템에 있어서, 상기 PoET 합의 알고리즘은 각 오라클 노드들이 동일한 연산을 푸는 수행 시간만큼의 시드값을 기반으로 하여 리더 오라클 노드를 무작위로 선출하고, 무작위로 선출된 리더 오라클 노드가 블록을 생성하고 트랜잭션을 검증하는 것이 바람직하다. In the decentralized oracle system based on the TEE according to the first feature described above, the PoET consensus algorithm randomly selects a leader oracle node based on a seed value corresponding to the execution time for each oracle node to solve the same operation It is desirable for a randomly selected leader oracle node to generate blocks and verify transactions.

전술한 제1 특징에 따른 TEE를 기반으로 한 탈중앙형 오라클 시스템은, 외부의 블록체인 네트워크의 전달 스마트 컨트랙트를 모니터링하는 클라이언트를 더 구비하고, 상기 클라이언트는 블록체인 네트워크로부터 오라클 요청에 대한 트랜잭션을 발생시키는 것을 특징으로 하며, 상기 오라클 노드는 상기 클라이언트로부터 발생된 트랜잭션을 트랜잭션 처리 장치에서 수행하여 외부 데이터 소스로부터 데이터를 받아오는 것이 바람직하다. The decentralized oracle system based on the TEE according to the first feature described above further includes a client that monitors a delivery smart contract of an external blockchain network, and the client executes a transaction in response to an oracle request from the blockchain network. It is characterized in that the oracle node generates data from an external data source by performing the transaction generated by the client in a transaction processing device.

전술한 제1 특징에 따른 TEE를 기반으로 한 탈중앙형 오라클 시스템에 있어서, 상기 오라클 노드가 오라클 요청에 따른 트랜잭션을 수행하여 외부 데이터 소스로부터 데이터를 전달받으면, 리더 오라클 노드에게 트랜잭션 처리 장치에서 수행된 코드와 데이터가 포함된 리포트 데이터(Report Data)를 보내는 것을 특징으로 하며, In the decentralized oracle system based on the TEE according to the first feature described above, when the oracle node performs a transaction according to an oracle request and receives data from an external data source, the transaction processing device performs the transaction to the leader oracle node. It is characterized by sending report data containing code and data,

상기 리더 오라클 노드는 리포트 데이터를 신뢰 실행 환경에서 원격 증명을 수행하여 검증하고, 검증된 트랜잭션을 포함한 블록을 생성하여 자신의 블록체인에 연결하고, 생성된 블록을 P2P 블록체인 네트워크를 통해 전파하고, 블록체인 네트워크의 전달 스마트 컨트랙트에 트랜잭션을 발생시켜 상기 데이터를 블록체인 네트워크로 전송하는 것이 바람직하다. The leader oracle node verifies the report data by performing remote proof in a trusted execution environment, creates a block including the verified transaction, connects it to its own blockchain, propagates the generated block through the P2P blockchain network, Transmission of the blockchain network It is preferable to transmit the data to the blockchain network by generating a transaction in a smart contract.

본 발명의 제2 특징에 따른 탈중앙형 오라클 시스템에서의 외부 데이터 전달 방법은, 프라이빗 블록체인 네트워크를 구성한 복수 개의 오라클 노드들 및 오라클 노드에 연결된 클라이언트를 구비하여, 외부의 블록체인 네트워크로부터의 요청에 따라 외부 데이터 소스의 데이터를 제공하는 탈중앙형 오라클 시스템에서의 오라클 노드 및 클라이언트에 의해 수행되는 외부 데이터 전달 방법에 관한 것으로서, (a) 클라이언트가 전달 스마트 컨트랙트를 모니터링하여 오라클 요청에 대한 트랜잭션을 발생시키는 단계; (b) 오라클 노드가 클라이언트로부터 발생된 트랜잭션을 트랜잭션 처리 장치에서 수행하여 외부 데이터 소스로부터 데이터를 받아오는 단계; (c) 상기 오라클 노드가 트랜잭션 처리 장치에서 수행된 코드와 데이터가 포함된 리포트 데이터를 리더 오라클 노드에게 전송하는 단계;를 구비한다. A method for transmitting external data in a decentralized oracle system according to a second feature of the present invention includes a plurality of oracle nodes constituting a private blockchain network and a client connected to the oracle node, and a request from an external blockchain network. It relates to an external data transfer method performed by an oracle node and a client in a decentralized oracle system that provides data from an external data source according to (a) the client monitors the delivery smart contract and executes a transaction for the oracle request. generating step; (b) receiving data from an external data source by performing a transaction generated by an oracle node in a transaction processing device; (c) transmitting, by the oracle node, report data including codes and data executed by the transaction processing device to the leader oracle node;

전술한 제2 특징에 따른 TEE를 기반으로 한 탈중앙형 오라클 시스템에서의 외부 데이터 전달 방법에 있어서, 상기 리더 오라클 노드는 PoET 합의 알고리즘에 따라 상기 복수 개의 오라클 노드들 중에서 선출되는 것이 바람직하다. In the external data transmission method in a TEE-based decentralized oracle system according to the second feature described above, the leader oracle node is preferably selected from among the plurality of oracle nodes according to a PoET consensus algorithm.

전술한 제2 특징에 따른 TEE를 기반으로 한 탈중앙형 오라클 시스템에서의 외부 데이터 전달 방법은, (d) 오라클 노드로부터 리포트 데이터를 전달받은 상기 리더 오라클 노드는, 리포트 데이터를 신뢰 실행 환경에서 원격 증명을 수행하여 검증하고, 검증된 트랜잭션을 포함한 블록을 생성하여 자신의 블록체인에 연결하고, 생성된 블록을 P2P 블록체인 네트워크를 통해 전파하고, 블록체인 네트워크의 전달 스마트 컨트랙트에 트랜잭션을 발생시켜 상기 데이터를 블록체인 네트워크로 전송하는 단계;를 더 구비하는 것이 바람직하다. External data transmission method in a TEE-based decentralized oracle system according to the second feature described above, (d) the leader oracle node receiving the report data from the oracle node transmits the report data remotely in a trusted execution environment. Proof is performed and verified, a block including the verified transaction is created and connected to the own blockchain, the generated block is propagated through the P2P blockchain network, and a transaction is generated in the delivery smart contract of the blockchain network to It is preferable to further include; transmitting the data to the blockchain network.

본 발명에 따른 탈중앙형 오라클 시스템은 복수 개의 오라클 노드들을 프라이빗 블록체인 네트워크인 하이퍼레저를 이용하여 구성함으로써, 단일 오라클 서버의 중앙화로 인한 단일 장애점 문제와 분산 오라클에서의 확장성과 성능 문제를 해결할 수 있게 된다.The decentralized oracle system according to the present invention solves the single point of failure problem due to the centralization of a single oracle server and the scalability and performance problems in distributed oracles by configuring a plurality of oracle nodes using Hyperledger, a private blockchain network. be able to

또한, 본 발명에 따른 탈중앙형 오라클 시스템은 오라클 노드의 트랜잭션 처리장치를 신뢰 실행 환경인 Intel-SGX에서 실행되도록 하고, 외부 데이터 소스와 TLS 통신을 함으로써, 데이터 무결성을 보장하고, 외부 데이터를 가져오기 위한 TLS 통신을 각 오라클 노드의 Intel SGX Enclave 내부에서 수행하도록 하여 데이터 조작이 불가능하게 된다. In addition, the decentralized oracle system according to the present invention makes the transaction processing device of the oracle node run in Intel-SGX, a trusted execution environment, and ensures data integrity by performing TLS communication with an external data source and importing external data. Data manipulation is impossible by making TLS communication to be performed inside the Intel SGX Enclave of each Oracle node.

또한, 본 발명에 따른 탈중앙형 오라클 시스템은 합의 알고리즘으로 PoET(Proof-of-Elapsed-Time)을 사용하여 리더 오라클 노드를 선출하고, 리더 오라클 노드는 다른 오라클 노드들이 외부 데이터 소스에서 TLS 통신을 이용하여 데이터를 가져오는 절차를 합의 과정에서 Intel SGX Enclave의 기능 중 하나인 원격 증명을 통해 검증한다. 따라서, 본 발명에 따른 오라클 시스템은 오라클 응답시간을 최소화시킬 수 있게 된다. In addition, the decentralized oracle system according to the present invention uses PoET (Proof-of-Elapsed-Time) as a consensus algorithm to elect a leader oracle node, and the leader oracle node allows other oracle nodes to use TLS communication from an external data source. In the process of consensus, the process of importing data is verified through remote proof, one of the functions of Intel SGX Enclave. Therefore, the oracle system according to the present invention can minimize the oracle response time.

본 발명에 따른 탈중앙형 오라클 시스템은 하이퍼레저를 사용함으로써, 성능과 오라클 응답 시간에 대한 문제를 최소화하게 되며, 오라클 노드 수의 증가에 따라 성능이 저하되던 기존의 분산 오라클의 확장성 문제를 해결할 수 있게 된다. The decentralized oracle system according to the present invention uses Hyperledger, thereby minimizing the problem of performance and oracle response time, and solving the scalability problem of the existing distributed oracle, which deteriorated as the number of oracle nodes increased. be able to

또한, 본 발명에 따른 탈중앙형 오라클 시스템은 이더리움과 같은 데이터 요청 블록체인에서의 연산을 최소화하고, 데이터를 가져오는 과정 검증을 대신하게 된다. 또한, 본 발명에 따른 탈중앙형 오라클 시스템은 PoET 합의 알고리즘을 통해 데이터 어뷰징(Data Abusing)을 방지하여 오라클 응답시간을 보장하게 됨에 따라, 블록체인이 오라클에 데이터를 요청하고 데이터를 받는 사이의 시간인 오라클 응답 시간을 최소화함으로써, 시간에 따라 변하는 사물인터넷 데이터를 블록체인에 제공할 수 있게 된다. In addition, the decentralized oracle system according to the present invention minimizes the operation in the data request block chain such as Ethereum, and replaces the verification process of bringing data. In addition, as the decentralized oracle system according to the present invention guarantees oracle response time by preventing data abusing through the PoET consensus algorithm, the time between the block chain requesting data from the oracle and receiving the data By minimizing the in-oracle response time, it is possible to provide time-varying IoT data to the blockchain.

도 1은 본 발명의 바람직한 실시예에 따른 TEE를 기반으로 한 탈중앙형 오라클 시스템을 전체적으로 도시한 구성도이다.
도 2는 본 발명의 바람직한 실시예에 따른 신뢰 실행 환경을 기반으로 한 탈중앙형 오라클 시스템에 있어서, 합의 엔진 모듈에서 이루어지는 PoET 합의 과정을 도시한 모식도이다.
도 3은 본 발명의 바람직한 실시예에 따른 신뢰 실행 환경을 기반으로 한 탈중앙형 오라클 시스템에 있어서, 트랜잭션 처리장치(110)의 구조를 도시한 모식도이다.
도 4는 본 발명의 바람직한 실시예에 따른 탈중앙형 오라클 시스템에 있어서, 검증자의 원격 증명 과정을 설명하기 위하여 도시한 모식도이다.
도 5는 본 발명의 바람직한 실시예에 따른 탈중앙형 오라클 시스템에 있어서, 외부 데이터 전달을 위한 오라클 요청 및 응답 과정을 설명하기 위하여 도시한 모식도이다. 도 6은 본 발명의 바람직한 실시예에 따른 탈중앙형 오라클 시스템에 있어서, 오라클 요청 알고리즘에 대한 의사 코드이다.
도 7은 본 발명의 바람직한 실시예에 따른 탈중앙형 오라클 시스템에 있어서, 오라클 응답 알고리즘에 대한 의사 코드이다.
1 is a configuration diagram showing the overall configuration of a decentralized oracle system based on TEE according to a preferred embodiment of the present invention.
2 is a schematic diagram showing a PoET consensus process performed in a consensus engine module in a decentralized oracle system based on a trusted execution environment according to a preferred embodiment of the present invention.
3 is a schematic diagram showing the structure of a transaction processing device 110 in a decentralized oracle system based on a trusted execution environment according to a preferred embodiment of the present invention.
4 is a schematic diagram illustrating a remote verification process of a verifier in a decentralized oracle system according to a preferred embodiment of the present invention.
5 is a schematic diagram illustrating an oracle request and response process for transferring external data in a decentralized oracle system according to a preferred embodiment of the present invention. 6 is pseudo code for an oracle request algorithm in a decentralized oracle system according to a preferred embodiment of the present invention.
7 is pseudo code for an oracle response algorithm in a decentralized oracle system according to a preferred embodiment of the present invention.

아래에서는 첨부한 도면을 참고로 하여 본 발명의 실시예에 대하여 본 발명이 속하는 기술 분야에서 통상의 지식을 가진 자가 용이하게 실시할 수 있도록 상세히 설명한다. 그러나 본 발명은 여러 가지 상이한 형태로 구현될 수 있으며 여기에서 설명하는 실시예에 한정되지 않는다. 그리고 도면에서 본 발명을 명확하게 설명하기 위해서 설명과 관계없는 부분은 생략하였으며, 명세서 전체를 통하여 유사한 부분에 대해서는 유사한 도면 부호를 붙였다. 명세서 전체에서, 어떤 부분이 어떤 구성요소를 "포함"한다고 할 때, 이는 특별히 반대되는 기재가 없는 한 다른 구성요소를 제외하는 것이 아니라 다른 구성요소를 더 포함할 수 있는 것을 의미한다.Hereinafter, with reference to the accompanying drawings, embodiments of the present invention will be described in detail so that those skilled in the art can easily carry out the present invention. However, the present invention may be embodied in many different forms and is not limited to the embodiments described herein. And in order to clearly explain the present invention in the drawings, parts irrelevant to the description are omitted, and similar reference numerals are attached to similar parts throughout the specification. Throughout the specification, when a certain component is said to "include", it means that it may further include other components without excluding other components unless otherwise stated.

이하, 첨부된 도면을 참조하여 본 발명의 바람직한 실시예에 따른 신뢰 실행 환경(Trusted Execution Environment; TEE)을 기반으로 한 탈중앙형 오라클 시스템의 구성 및 동작을 구체적으로 설명한다. Hereinafter, the configuration and operation of a decentralized oracle system based on a Trusted Execution Environment (TEE) according to a preferred embodiment of the present invention will be described in detail with reference to the accompanying drawings.

먼저, 외부 소프트웨어로부터 고립된 환경에서 안전한 실행이 가능한 TEE는 여러 형태로 구현되어 각각 용어가 상이하다. 본 발명에서는 Intel Software Guard Extensions(SGX)를 기준으로 용어를 기술한다. 또한, 스마트 컨트랙트의 설명은 스마트 컨트랙트를 지원하는 블록체인 플랫폼 중 하나인 이더리움(Ethereum)의 스마트 컨트랙트를 기준으로 기술한다. First, TEE, which can be safely executed in an environment isolated from external software, is implemented in various forms and has different terms. In the present invention, terms are described based on Intel Software Guard Extensions (SGX). In addition, the description of the smart contract is based on the smart contract of Ethereum, one of the blockchain platforms that support smart contracts.

Enclave는 악의적인 개체로부터 응용 프로그램을 보호할 수 있는 독립적이고 안정성이 보장된 메모리 영역을 의미한다. Remote attestation은 Intel SGX의 고급 기능으로, Enclave가 안전한 환경에서 설정되었음을 원격 사용자에게 증명하는 프로세스다. Remote attestation을 통해 프로세스가 Enclave 내부에서 실행되었음과, 프로세스의 신원(Identity), 그리고 데이터와 코드의 무결성을 증명할 수 있다.Enclave means an independent and stable memory area that can protect applications from malicious objects. Remote attestation is an advanced feature of Intel SGX and is the process of proving to remote users that an enclave has been set up in a secure environment. Through remote attestation, it is possible to prove that the process was executed inside the enclave, the identity of the process, and the integrity of data and code.

이더리움의 스마트 컨트랙트는 고유의 주소를 갖는 응용 프로그램이며, 실행하고자 하는 스마트 컨트랙트의 주소, 함수, 그리고 인자(Argument)를 지정한 트랜잭션을 생성함으로써 실행시킬 수 있다. 소스코드와 응용 프로그램의 데이터는 원장(혹은 블록)에 저장되어 있으며, 데이터들은 오로지 트랜잭션을 통해 값을 변화시킬 수 있다.Ethereum's smart contract is an application program with a unique address, and can be executed by creating a transaction specifying the address, function, and argument of the smart contract to be executed. The source code and application data are stored in the ledger (or block), and the values of the data can only be changed through transactions.

도 1은 본 발명의 바람직한 실시예에 따른 TEE를 기반으로 한 탈중앙형 오라클 시스템을 전체적으로 도시한 구성도이다. 도 1을 참조하면, 본 발명에 따른 탈중앙형 오라클 시스템(1)은 신뢰 실행 환경(Trusted Execution Environment; 'TEE')을 기반으로 한 복수 개의 오라클 노드들(10)이 P2P(Peer to Peer) 네트워크를 형성하여 구성된 것을 특징으로 하며, 상기 탈중앙형 오라클 시스템(1)은 외부 데이터 소스(30)들로부터 외부 데이터를 수집하여 무결성의 외부 데이터를 블록체인 네트워크로 전달하는 것을 특징으로 한다. 특히, 본 발명에 따른 탈중앙형 오라클 시스템은 프라이빗 블록체인 네트워크인 하이퍼레저 소투스(Hyper-ledger Sawtooths)를 이용하여 복수 개의 오라클 노드들이 P2P 블록체인 네트워크를 구성하는 것이 바람직하다. 한편, 상기 탈중앙형 오라클 시스템(1)은 외부의 블록체인 네트워크를 모니터링하는 클라이언트(50)를 더 구비하는 것이 바람직하다. 1 is a configuration diagram showing the overall configuration of a decentralized oracle system based on TEE according to a preferred embodiment of the present invention. Referring to Figure 1, the decentralized oracle system 1 according to the present invention is a plurality of oracle nodes 10 based on a Trusted Execution Environment ('TEE'), P2P (Peer to Peer) It is characterized in that it is configured by forming a network, and the decentralized oracle system (1) is characterized in that it collects external data from external data sources (30) and transmits the external data of integrity to the blockchain network. In particular, in the decentralized oracle system according to the present invention, it is preferable that a plurality of oracle nodes configure a P2P blockchain network using a private blockchain network, Hyper-ledger Sawtooths. Meanwhile, the decentralized oracle system 1 preferably further includes a client 50 for monitoring an external blockchain network.

본 발명에 따른 탈중앙형 오라클 시스템을 구성하는 각 오라클 노드(10)는 검증자 노드이며, 검증자 노드는 합의 엔진 모듈(Consensus engine module;100), 트랜잭션 처리장치(Transaction Processor;110), 블록 매니지먼트 모듈(Block Management Module; 120) 및 P2P 네트워크 모듈(130)를 구비한다. 이하, 전술한 각 구성 요소들에 대하여 구체적으로 설명한다. Each oracle node 10 constituting the decentralized oracle system according to the present invention is a verifier node, and the verifier node includes a consensus engine module (100), a transaction processor (110), a block A management module (Block Management Module; 120) and a P2P network module (130) are provided. Hereinafter, each of the aforementioned components will be described in detail.

상기 합의 엔진 모듈(Consensus engine module;100)은, 블록 생성을 위한 합의 알고리즘이 구동되는 모듈이다. 도 2는 본 발명의 바람직한 실시예에 따른 신뢰 실행 환경을 기반으로 한 탈중앙형 오라클 시스템에 있어서, 합의 엔진 모듈에서 이루어지는 PoET 합의 과정을 도시한 모식도이다. The consensus engine module 100 is a module that drives a consensus algorithm for block generation. 2 is a schematic diagram showing a PoET consensus process performed in a consensus engine module in a decentralized oracle system based on a trusted execution environment according to a preferred embodiment of the present invention.

합의 알고리즘은 블록체인에 연결할 다음 블록을 누가 만들고 어떤 방법으로 결정할지에 대한 알고리즘이다. 종래의 일반적인 블록체인 네트워크는 합의 알고리즘으로 작업 증명(Proof-of-Work;'PoW') 방식을 주로 사용하며, PoW 방식은 모든 채굴 노드가 특정 해시값으로 이루어진 퍼즐을 풀고, 먼저 푼 노드가 블록을 생성하여 보상을 받게 된다. 하지만, 전술한 PoW 방식은 자원 낭비가 심하게 발생하게 되므로, 신뢰할 수 있는 네트워크 참여자만 참여하도록 구성된 프라이빗 블록체인 네트워크에서는 적합하지 않다. 따라서, 본 발명에 따른 탈중앙형 오라클 시스템은 프라이빗 블록체인 네트워크로 구성하고 PoET(Proof-of-Elapsed-Time) 합의 알고리즘을 사용하는 것이 바람직하다. A consensus algorithm is an algorithm that determines who makes and how the next block to be connected to the blockchain is decided. Conventional general blockchain networks mainly use the Proof-of-Work ('PoW') method as a consensus algorithm. Create and receive rewards. However, since the aforementioned PoW method causes severe resource waste, it is not suitable for private blockchain networks configured to allow only trusted network participants to participate. Therefore, it is preferable to configure the decentralized oracle system according to the present invention as a private blockchain network and use a PoET (Proof-of-Elapsed-Time) consensus algorithm.

도 2를 참조하면, PoET는 각 블록체인 노드에게 동일한 연산인, 일종의 퍼즐을 신뢰 실행 환경의 Enclave 메모리 영역내에서 풀게 하고, 수행 시간만큼의 시드(seed) 값을 주고, 시드값을 기반으로 하여 리더 노드를 랜덤하게 선출하며, 이렇게 선출된 리더 노드가 블록 생성과 트랜잭션의 검증을 맡도록 하는 합의 방법이다. 전술한 PoET 방식은 기존의 PoW 방식에 비하여 적은 연산을 사용하며, 합의에 참여하는 노드 수가 증가하더라도 상수 시간내에 합의에 도달하게 된다. 또한, 최근 퍼블릭 블록체인에서 주로 사용되고 있는 PBFT 합의는 합의에 참여하는 노드의 수가 20개 이상이 되면 합의 속도가 급격하게 감소하는데 비하여, PoET 방식은 노드 수가 증가하더라도 합의에 도달하는 시간이 빠르므로 확장성이 있는 합의 알고리즘이라 할 수 있다. Referring to FIG. 2, PoET allows each blockchain node to solve the same operation, a kind of puzzle, within the enclave memory area of the trusted execution environment, gives a seed value equal to the execution time, and based on the seed value It is a consensus method that randomly selects a leader node and allows the elected leader node to take charge of block generation and transaction verification. The aforementioned PoET method uses fewer calculations than the existing PoW method, and even if the number of nodes participating in the agreement increases, an agreement is reached within a constant time. In addition, while the PBFT consensus, which is mainly used in recent public blockchains, has a rapid decrease in the speed of consensus when the number of nodes participating in the consensus exceeds 20, the PoET method expands because the time to reach consensus is fast even if the number of nodes increases. It can be considered as a consensus algorithm.

도 3은 본 발명의 바람직한 실시예에 따른 신뢰 실행 환경을 기반으로 한 탈중앙형 오라클 시스템에 있어서, 트랜잭션 처리장치(110)의 구조를 도시한 모식도이다.3 is a schematic diagram showing the structure of a transaction processing device 110 in a decentralized oracle system based on a trusted execution environment according to a preferred embodiment of the present invention.

도 3을 참조하면, 상기 트랜잭션 처리장치(Transaction Processor;110)는 각 오라클 노드가 트랜잭션을 수행하는 공간을 의미하는 것으로서, 트랜잭션 처리장치가 외부 데이터 소스로부터 데이터를 가져오는 작업을 수행하게 된다. 오라클 요청은 클라이언트에 의해 소투스 체인의 트랜잭션으로 요청되고, 요청된 트랜잭션은 검증자 노드의 트랜잭션 처리장치에서 수행된다. 본 발명에 따른 탈중앙형 오라클 시스템에 있어서, 각 오라클 노드의 트랜잭션 처리장치에서 수행되는 트랜잭션은 신뢰 실행 환경의 Enclave 메모리 영내에서 수행된다. 트랜잭션의 입력은 요청된 오라클 데이터의 소스와 요청 시점의 블록 넘버이고, ecall을 통해 오라클 데이터 소스를 신뢰 실행 환경의 Enclave 내부로 보내면, Enclave 내에서 오라클 데이터 소스에 TLS Connection을 생성하고 데이터를 가져오게 된다. 이 후, Enclave 내에서 데이터를 가져오는 코드가 올바르게 수행된 결과물인 데이터와 수행된 코드의 바이트 코드를 저장한 Report 자료 구조를 ocall로 반환받게 된다. Referring to FIG. 3 , the transaction processor 110 refers to a space in which each oracle node performs a transaction, and the transaction processor 110 performs a task of bringing data from an external data source. The oracle request is requested by the client as a transaction on the Sawtooth chain, and the requested transaction is executed in the transaction processor of the verifier node. In the decentralized oracle system according to the present invention, transactions performed in the transaction processor of each oracle node are performed within the enclave memory area of the trusted execution environment. The input of the transaction is the source of the requested oracle data and the block number at the time of request, and when the oracle data source is sent to the enclave of the trusted execution environment through ecall, the enclave creates a TLS connection to the oracle data source and retrieves the data. do. After that, the report data structure that stores the data that is the result of correctly executing the code that retrieves data from within the enclave and the byte code of the executed code is returned to ocall.

한편, 본 발명에 따른 오라클 시스템을 구성하는 모든 오라클 노드는 잠재적으로 검증자가 될 자격이 있다. 따라서, 모든 오라클 노드는 검증자 기능을 갖는 블록 매니지먼트 모듈을 구비한다. 도 4는 본 발명의 바람직한 실시예에 따른 탈중앙형 오라클 시스템에 있어서, 검증자의 원격 증명 과정을 설명하기 위하여 도시한 모식도이다. 도 4를 참조하면, PoET 합의 알고리즘을 통해 선출된 리더 오라클 노드는 상기 블록 매니지먼트 모듈(Block Management Module; 120)을 통해, 다른 오라클 노드들이 수행한 트랜잭션을 자신의 트랜잭션 처리장치 내의 Enclave에서 원격 증명을 통해 검증하고, 해당 트랜잭션에 데이터 또는 코드 조작에 대한 문제가 없으면 블록에 포함시킨다. 이후 검증자는 일정 주기마다 블록을 생성하고 블록체인에 연결하여 블록을 배포하는 역할을 한다. Meanwhile, all oracle nodes constituting the oracle system according to the present invention are potentially eligible to become verifiers. Therefore, all oracle nodes have a block management module with a validator function. 4 is a schematic diagram illustrating a remote verification process of a verifier in a decentralized oracle system according to a preferred embodiment of the present invention. Referring to FIG. 4, the leader oracle node elected through the PoET consensus algorithm remotely proves transactions performed by other oracle nodes in the enclave in its own transaction processing device through the block management module (Block Management Module; 120). If there is no problem with data or code manipulation in the transaction, it is included in the block. Afterwards, the validator plays a role in generating blocks at regular intervals and distributing the blocks by connecting them to the blockchain.

한편, 오라클 시스템으로 외부 데이터를 요청하는 블록체인 네트워크의 전달 스마트 컨트랙트는 블록체인 네트워크과 오라클 시스템을 연결해 주는 역할을 하는 스마트 컨트랙트로서, 블록체인 네트워크를 구성하는 노드들에 배포된다. 블록체인 네트워크의 일례로는 이더리움 등이 포함된다. 외부 데이터를 요구하는 사용자 컨트랙트가 전달 스마트 컨트랙터에 데이터를 요청하면, 요청된 트랜잭션이 블록체인 네트워크의 블록에 담기게 된다. On the other hand, the delivery smart contract of the blockchain network requesting external data to the oracle system is a smart contract that serves to connect the blockchain network and the oracle system, and is distributed to the nodes constituting the blockchain network. An example of a blockchain network includes Ethereum and the like. When a user contract requesting external data requests data from the forwarding smart contract, the requested transaction is included in a block of the blockchain network.

한편, 오라클 시스템의 클라이언트(50)는 블록체인 네트워크의 블록을 모니터링하면서, 해당 데이터 요청에 대한 트랜잭션을 발생시키는 형태로 오라클 요청을 진행하게 된다. Meanwhile, the client 50 of the oracle system proceeds with the oracle request in the form of generating a transaction for the data request while monitoring the block of the blockchain network.

오라클 시스템의 리더 오라클 노드는 오라클 노드로부터 외부 데이터가 전달되면, 자신에 블록을 전파함과 동시에 해당 블록 넘버와 트랜잭션 해쉬, 그리고 외부 데이터를 포함시킨 이더리움 트랜잭션을 전달 스마트 컨트랙트에 발생시킨다. 이후, 전달 스마트 컨트랙트에서 콜백(Callback) 함수를 통해 사용자 컨트랙트에 데이터를 전달한다. When external data is transmitted from the oracle node, the leader oracle node of the oracle system propagates the block to itself and simultaneously generates an Ethereum transaction including the corresponding block number, transaction hash, and external data to the delivery smart contract. Then, the transfer smart contract transfers the data to the user contract through a callback function.

이하, 도 5 내지 도 7을 참조하여 본 발명의 바람직한 실시예에 따른 탈중앙형 오라클 시스템에 있어서의 외부 데이터 전달을 위한 오라클 요청 및 응답에 대한 동작 과정을 구체적으로 설명한다. Hereinafter, with reference to FIGS. 5 to 7, an operation process for an oracle request and response for external data transfer in a decentralized oracle system according to a preferred embodiment of the present invention will be described in detail.

오라클 요청은 블록체인 네트워크의 사용자 컨트랙트(200)로부터 외부 데이터에 대한 요청이 발생하고, 전달 스마트 컨트랙트(210)를 통해 오라클 시스템에 트랜잭션이 발생하여 오라클 노드(10)의 트랜잭션 처리장치가 외부 데이터 소스(30)로부터 외부 데이터를 가져오는 과정까지를 의미한다. 오라클 응답은 오라클 노드의 트랜잭션 처리장치가 가져온 데이터를 PoET 합의 과정을 통해 오라클 시스템의 블록에 커밋(commit)되고, 이를 전달 스마트 컨트랙트를 거쳐 이더리움의 사용자 컨트랙트에 전달하는 과정이다. The oracle request is a request for external data from the user contract 200 of the blockchain network, and a transaction occurs in the oracle system through the delivery smart contract 210, so that the transaction processing unit of the oracle node 10 is an external data source (30) to the process of importing external data. The oracle response is a process in which the data brought by the transaction processing unit of the oracle node is committed to the block of the oracle system through the PoET consensus process, and then transferred to the user contract of Ethereum through the delivery smart contract.

도 5는 본 발명의 바람직한 실시예에 따른 탈중앙형 오라클 시스템에 있어서, 외부 데이터 전달을 위한 오라클 요청 및 응답 과정을 설명하기 위하여 도시한 모식도이다. 도 6은 본 발명의 바람직한 실시예에 따른 탈중앙형 오라클 시스템에 있어서, 오라클 요청 알고리즘에 대한 의사 코드이다.5 is a schematic diagram illustrating an oracle request and response process for transferring external data in a decentralized oracle system according to a preferred embodiment of the present invention. 6 is pseudo code for an oracle request algorithm in a decentralized oracle system according to a preferred embodiment of the present invention.

도 5 및 도 6을 참조하여, 본 발명에 따른 탈중앙형 오라클 시스템에서의 오라클 요청 과정을 보다 구체적으로 설명한다. 오라클 요청 과정은 도 5의 과정 1부터 과정 5까지의 과정이다. 먼저, 블록체인 네트워크 상의 사용자 스마트 컨트랙트에서 전달 스마트 컨트랙트에게 오라클 요청을 보낸다(과정 1). 다음, 과정 1 이후, 블록체인 네트워크의 블록을 모니터링하던 오라클 시스템의 클라이언트가 오라클 요청이 발생하였음을 확인한다(과정 2). 다음, 클라이언트가 해당 오라클 요청에 대한 오라클 시스템의 트랜잭션을 발생시킨다(과정 3). 다음, 오라클 노드는 자신의 로컬 트랜잭션 처리장치에서 해당 트랜잭션을 수행한다(과정 4). 이때, 트랜잭션 처리장치의 비신뢰영역에서 신뢰 영역으로의 ocall이 발생한다. 다음, 오라클 노드가 신뢰 실행 환경의 Enclave 내에서 오라클 요청에 대한 TLS 통신을 연결하고 외부 데이터를 받아온다(과정 5). Referring to Figures 5 and 6, the oracle request process in the decentralized oracle system according to the present invention will be described in more detail. The oracle request process is from process 1 to process 5 in FIG. 5 . First, the user smart contract on the blockchain network sends an oracle request to the forwarding smart contract (Process 1). Next, after step 1, the client of the oracle system monitoring the block of the blockchain network confirms that an oracle request has occurred (step 2). Next, the client generates a transaction in the oracle system for the oracle request (process 3). Next, the oracle node executes the transaction in its local transaction processor (step 4). At this time, an ocall from the untrusted area of the transaction processing device to the trusted area occurs. Next, the oracle node connects TLS communication for the oracle request within the enclave of the trusted execution environment and receives external data (process 5).

다음, 도 5 및 도 7을 참조하여, 본 발명에 따른 탈중앙형 오라클 시스템에서의 오라클 응답 과정을 보다 구체적으로 설명한다. Next, referring to FIGS. 5 and 7, the oracle response process in the decentralized oracle system according to the present invention will be described in more detail.

도 7은 본 발명의 바람직한 실시예에 따른 탈중앙형 오라클 시스템에 있어서, 오라클 응답 알고리즘에 대한 의사 코드이다. 오라클 응답은 트랜잭션을 수행한 오라클 노드가 외부 데이터 소스로부터 데이터를 전달받은 이후 과정부터 최종적으로 블록체인 네트워크의 사용자 컨트랙트에 데이터가 전달되기 까지의 과정이다. 도 5의 과정 6 내지 과정 11이 오라클 응답 과정이다. 먼저, PoET 합의 알고리즘에 의해 선출된 리더 오라클 노드에게 트랜잭션 처리 장치에서 수행된 코드와 데이터가 포함된 report 데이터를 보내면, 리더 오라클 노드는 자신의 로컬 Enclave에서 원격 증명을 수행하여 데이터와 코드를 검증한다(과정 6). 다음, 과정 6 이후 검증된 트랜잭션을 포함한 블록을 생성하고(과정 7), 이를 자신의 로컬 상태 데이터베이스의 블록체인에 연결한다(과정 8). 다음, 생성된 블록을 P2P 네트워크를 통해 전파하여 블록생성 과정을 마친다(과정 9). 다음, 리더 오라클 노드가 외부 데이터를 이더리움 전달 스마트 컨트랙트에 트랜잭션을 발생시켜 전송하고(과정 10), 마지막으로 전달 스마트 컨트랜트가 외부 데이터를 요청한 사용자 컨트랙트에 데이터를 보내는 트랜잭션을 생성하여(과정 11) 오라클 응답을 종료한다. 7 is pseudo code for an oracle response algorithm in a decentralized oracle system according to a preferred embodiment of the present invention. The oracle response is the process from when the oracle node that performed the transaction received the data from the external data source to the final delivery of the data to the user contract of the blockchain network. Steps 6 to 11 of FIG. 5 are oracle response steps. First, when the leader oracle node elected by the PoET consensus algorithm sends report data containing the code and data performed in the transaction processing device, the leader oracle node verifies the data and code by performing remote proof in its local enclave. (Course 6). Next, it creates a block including the transaction verified after step 6 (step 7) and connects it to the block chain of its local state database (step 8). Next, the generated block is propagated through the P2P network to complete the block generation process (Step 9). Next, the leader oracle node generates and transmits the external data to the Ethereum transfer smart contract (Process 10), and finally, the transfer smart contract creates a transaction that sends data to the user contract that requested the external data (Process 11). ) terminate the oracle response.

이상에서 본 발명에 대하여 그 바람직한 실시예를 중심으로 설명하였으나, 이는 단지 예시일 뿐 본 발명을 한정하는 것이 아니며, 본 발명이 속하는 분야의 통상의 지식을 가진 자라면 본 발명의 본질적인 특성을 벗어나지 않는 범위에서 이상에 예시되지 않은 여러 가지의 변형과 응용이 가능함을 알 수 있을 것이다. 그리고, 이러한 변형과 응용에 관계된 차이점들은 첨부된 청구 범위에서 규정하는 본 발명의 범위에 포함되는 것으로 해석되어야 할 것이다. Although the present invention has been described above with reference to preferred embodiments, this is only an example and does not limit the present invention, and those skilled in the art to which the present invention belongs will not deviate from the essential characteristics of the present invention. It will be appreciated that various modifications and applications not exemplified above are possible within the range. And, differences related to these variations and applications should be construed as being included in the scope of the present invention defined in the appended claims.

1 : 탈중앙형 오라클 시스템
10 : 오라클 노드
20 : 외부 블록체인 네트워크
200 : 사용자 컨트랙트
210 : 전달 스마트 컨트랙트
50 : 클라이언트
30 : 외부 데이터 소스
100 : 합의 엔진 모듈(Consensus engine module)
110 : 트랜잭션 처리장치(Transaction Processor)
120 : 블록 매니지먼트 모듈(Block Management Module)
130 : P2P 네트워크 모듈
1: Decentralized Oracle System
10 : Oracle node
20: External blockchain network
200: user contract
210: delivery smart contract
50: client
30: external data source
100: Consensus engine module
110: Transaction Processor
120: Block Management Module
130: P2P network module

Claims (8)

복수 개의 오라클 노드들이 프라이빗 블록체인 네트워크로 구성되어 외부의 블록체인 네트워크로부터의 요청에 따라 외부 데이터 소스의 데이터를 제공하는 것을 특징으로 하며,
상기 오라클 노드는,
외부의 블록체인 네트워크에 의해 요청된 트랜잭션을 신뢰 실행 환경(TEE)에서 수행하는 트랜잭션 처리 장치;
PoET(Proof-of-Elapsed-Time) 합의 알고리즘에 따라 상기 복수 개의 오라클 노드들 중 리더 오라클 노드를 무작위로 선출하는 합의 엔진 모듈; 및
리더 오라클 노드로 선출되면, 검증자로서 일정 주기마다 블록을 생성하고 블록체인에 연결하여 블록을 배포하도록 구성된 블록 매니지먼트 모듈;
을 구비하여, 상기 오라클 노드가 오라클 요청에 따른 트랜잭션을 수행하여 외부 데이터 소스로부터 데이터를 전달받으면, 트랜잭션 처리 장치에서 수행된 코드와 상기 전달받은 데이터가 포함된 리포트 데이터(Report Data)를 리더 오라클 노드에게 전송하는 것을 특징으로 하며,
상기 합의 엔진 모듈에 의해 PoET 합의 알고리즘에 따라 오라클 노드들 중에서 선출된 리더 오라클 노드가 검증자 노드로서 동작할 수 있도록 구성된 것을 특징으로 하며,
상기 리더 오라클 노드는, 리포트 데이터에 포함된 코드와 데이터에 대하여 신뢰 실행 환경에서 원격 증명을 수행하여 검증하고, 검증된 트랜잭션을 포함한 블록을 생성하여 자신의 블록체인에 연결하고, 생성된 블록을 P2P 블록체인 네트워크를 통해 전파하고, 블록체인 네트워크의 전달 스마트 컨트랙트에 트랜잭션을 발생시켜 상기 검증된 데이터를 블록체인 네트워크로 전송하는 것을 특징으로 하는 탈중앙형 오라클 시스템.
It is characterized in that a plurality of oracle nodes are composed of a private blockchain network and provide data from an external data source according to a request from an external blockchain network,
The oracle node,
A transaction processing device that performs a transaction requested by an external blockchain network in a trusted execution environment (TEE);
a consensus engine module that randomly selects a leader oracle node from among the plurality of oracle nodes according to a proof-of-elapsed-time (PoET) consensus algorithm; and
If elected as a leader oracle node, a block management module configured to generate blocks at regular intervals as a validator and distribute blocks by connecting to a blockchain;
When the oracle node performs a transaction according to an oracle request and receives data from an external data source, the code executed by the transaction processing device and report data including the received data are transmitted to the leader oracle node. characterized in that it is transmitted to,
Characterized in that the leader oracle node selected from among oracle nodes according to the PoET consensus algorithm by the consensus engine module is configured to operate as a verifier node,
The leader oracle node verifies by performing remote proof on the code and data included in the report data in a trusted execution environment, creates a block including the verified transaction, connects it to its own blockchain, and P2P the generated block. A decentralized oracle system characterized by propagating through a blockchain network and transmitting the verified data to a blockchain network by generating a transaction in a delivery smart contract of the blockchain network.
제1항에 있어서,
상기 오라클 노드들은 프라이빗 블록체인 네트워크인 하이퍼레저를 이용하여 peer-to-peer(P2P) 블록체인 네트워크를 구성한 것을 특징으로 하는 탈중앙형 오라클 시스템.
According to claim 1,
The oracle nodes are decentralized oracle systems, characterized in that a peer-to-peer (P2P) blockchain network is configured using hyperledger, a private blockchain network.
제1항에 있어서,
상기 PoET 합의 알고리즘은 각 오라클 노드들이 동일한 연산을 푸는 수행 시간만큼의 시드값을 기반으로 하여 리더 오라클 노드를 무작위로 선출하고,
무작위로 선출된 리더 오라클 노드가 블록을 생성하고 트랜잭션을 검증하는 것을 특징으로 하는 탈중앙형 오라클 시스템.
According to claim 1,
The PoET consensus algorithm randomly selects a leader oracle node based on a seed value equal to the execution time of each oracle node solving the same operation,
A decentralized oracle system characterized by randomly elected leader oracle nodes generating blocks and validating transactions.
제1항에 있어서, 상기 탈중앙형 오라클 시스템은,
외부의 블록체인 네트워크의 전달 스마트 컨트랙트를 모니터링하는 클라이언트를 더 구비하고, 상기 클라이언트는 블록체인 네트워크로부터 오라클 요청에 대한 트랜잭션을 발생시키는 것을 특징으로 하며,
상기 오라클 노드는 상기 클라이언트로부터 발생된 트랜잭션을 트랜잭션 처리 장치에서 수행하여 외부 데이터 소스로부터 데이터를 받아오는 것을 특징으로 하는 탈중앙형 오라클 시스템.
The method of claim 1, wherein the decentralized oracle system,
Further comprising a client that monitors a delivery smart contract of an external blockchain network, wherein the client generates a transaction in response to an oracle request from the blockchain network,
The oracle node is a decentralized oracle system, characterized in that for receiving data from an external data source by performing a transaction generated from the client in a transaction processing device.
삭제delete 프라이빗 블록체인 네트워크를 구성한 복수 개의 오라클 노드들 및 오라클 노드에 연결된 클라이언트를 구비하여, 외부의 블록체인 네트워크로부터의 요청에 따라 외부 데이터 소스의 데이터를 제공하는 탈중앙형 오라클 시스템에서의 오라클 노드 및 클라이언트에 의해 수행되는 외부 데이터 전달 방법에 있어서,
(a) 클라이언트가 전달 스마트 컨트랙트를 모니터링하여 오라클 요청에 대한 트랜잭션을 발생시키는 단계;
(b) 오라클 노드가 클라이언트로부터 발생된 트랜잭션을 트랜잭션 처리 장치에서 수행하여 외부 데이터 소스로부터 데이터를 받아오는 단계;
(c) 상기 오라클 노드가 트랜잭션 처리 장치에서 수행된 코드와 상기 외부 데이터 소스로부터 받아온 데이터가 포함된 리포트 데이터를 리더 오라클 노드에게 전송하는 단계; 및
(d) 오라클 노드로부터 리포트 데이터를 전달받은 상기 리더 오라클 노드는, 상기 리포트 데이터에 포함된 코드와 데이터에 대하여 신뢰 실행 환경에서 원격 증명을 수행하여 검증하고, 검증된 트랜잭션을 포함한 블록을 생성하여 자신의 블록체인에 연결하고, 생성된 블록을 P2P 블록체인 네트워크를 통해 전파하고, 블록체인 네트워크의 전달 스마트 컨트랙트에 트랜잭션을 발생시켜 상기 검증된 데이터를 블록체인 네트워크로 전송하는 단계;
를 구비하는 것을 특징으로 하는 TEE를 이용한 탈중앙형 오라클 시스템에서의 외부 데이터 전달 방법.
Oracle nodes and clients in a decentralized oracle system that provides data from an external data source according to a request from an external blockchain network, including a plurality of oracle nodes constituting a private blockchain network and a client connected to the oracle node. In the external data transfer method performed by,
(a) the client generating a transaction for the oracle request by monitoring the forwarding smart contract;
(b) receiving data from an external data source by performing a transaction generated by an oracle node in a transaction processing device;
(c) transmitting, by the oracle node, report data including code executed by the transaction processing device and data received from the external data source to a leader oracle node; and
(d) The leader oracle node, which has received the report data from the oracle node, verifies the code and data included in the report data by remotely verifying them in a trusted execution environment, and generates a block including the verified transaction to itself. Connecting to the block chain of, propagating the generated block through the P2P block chain network, generating a transaction in the delivery smart contract of the block chain network and transmitting the verified data to the block chain network;
External data transmission method in a decentralized oracle system using TEE, characterized in that it comprises a.
제6항에 있어서, 상기 TEE를 이용한 탈중앙형 오라클 시스템에서의 외부 데이터 전달 방법에 있어서,
상기 리더 오라클 노드는 PoET 합의 알고리즘에 따라 상기 복수 개의 오라클 노드들 중에서 선출되는 것을 특징으로 하는 TEE를 이용한 탈중앙형 오라클 시스템에서의 외부 데이터 전달 방법.

The method of claim 6, wherein in the external data transmission method in the decentralized oracle system using the TEE,
The leader oracle node is an external data transfer method in a decentralized oracle system using TEE, characterized in that selected from among the plurality of oracle nodes according to the PoET consensus algorithm.

삭제delete
KR1020200102278A 2020-08-14 2020-08-14 A TEE-based decentralized oracle system and method of transferring external data in the oracle system KR102565850B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020200102278A KR102565850B1 (en) 2020-08-14 2020-08-14 A TEE-based decentralized oracle system and method of transferring external data in the oracle system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020200102278A KR102565850B1 (en) 2020-08-14 2020-08-14 A TEE-based decentralized oracle system and method of transferring external data in the oracle system

Publications (2)

Publication Number Publication Date
KR20220021576A KR20220021576A (en) 2022-02-22
KR102565850B1 true KR102565850B1 (en) 2023-08-09

Family

ID=80494149

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020200102278A KR102565850B1 (en) 2020-08-14 2020-08-14 A TEE-based decentralized oracle system and method of transferring external data in the oracle system

Country Status (1)

Country Link
KR (1) KR102565850B1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115118461A (en) * 2022-06-07 2022-09-27 讯飞智元信息科技有限公司 Data processing method and device, electronic equipment and storage medium

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10169591B2 (en) 2015-12-07 2019-01-01 Amazon Technologies, Inc. Chained security systems
US20190095879A1 (en) 2017-09-26 2019-03-28 Cornell University Blockchain payment channels with trusted execution environments
KR20200062889A (en) * 2018-11-27 2020-06-04 한국전자통신연구원 Method and Apparatus for performing block agreement in block chain system
KR102023101B1 (en) 2018-12-20 2019-11-04 주식회사 엔퍼 Apparatus for preventing forgery of original data and method thereof

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
A. Beniiche, A Study of Blockchain Oracles, arXiv:2004.07140v2(2020.07.14.)*
O. Dib et al., Consortium Blockchains: Overview, Applications and Challenges, International Journal on Advances in Telecommunications Vol.11(2018)*

Also Published As

Publication number Publication date
KR20220021576A (en) 2022-02-22

Similar Documents

Publication Publication Date Title
US11388152B2 (en) Manicoding for communication verification
US20230023857A1 (en) Data processing method and apparatus, intelligent device, and storage medium
TWI740423B (en) System and method for providing privacy and security protection in blockchain-based private transactions
TW202038221A (en) Retrieving public data for blockchain networks using trusted execution environments
CN110993044A (en) Lightweight dynamic autonomous cross-link interaction method for medical alliance link
US20230097738A1 (en) Data processing method and apparatus, device, and storage medium
JP6951649B2 (en) Block verification device, block verification method, and program
JP2024505692A (en) Data processing methods, devices and computer equipment based on blockchain networks
Ren et al. HCNCT: A cross-chain interaction scheme for the blockchain-based metaverse
CN114422146B (en) Method for anonymously sequencing main nodes of blockchain
KR102565850B1 (en) A TEE-based decentralized oracle system and method of transferring external data in the oracle system
KR20220045025A (en) Method and system for communication protocol of decentralized transaction
Kottursamy et al. A novel blockchain architecture with mutable block and immutable transactions for enhanced scalability
KR102518634B1 (en) Blockchain consensus system and method to improve transaction processing speed
CN116126480A (en) Cross-region block chain processing method and device for transaction, intelligent equipment, medium and product
CN115796861A (en) Cross-link transaction method, system, equipment and storage medium on block chain
KR20210150810A (en) Method providing transaction integrity and confidentiality in heterogeneous blockchain platforms
KR102534411B1 (en) Blockchain consensus system and method considering network scalability
KR102428950B1 (en) Method and system for off-chain payment
Tarmissi et al. A Literature Review of Bitcoin Network Infrastructure, Methodology, and Challenges
CN111162970B (en) Method and device for testing decentralized application server in block chain system
Marcer Albareda Fog-Applying blockchain to secure a distributed set of clusters
Rouzbahani et al. A Trust-Aware Task Allocation Method Based on Blockchain for The Internet of Things
El Abid et al. LighTx: A Lightweight Proof-of-Bandwidth Transactions Transfer System
Theuermann Institute of Applied Information Processing and Communications, Graz Technical University, 8010 Graz, Austria kevin. theuermann@ egiz. gv. at

Legal Events

Date Code Title Description
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right
GRNT Written decision to grant