As the 5G era arrives,the Internet of Things enters a new stage,and the amount of IoT data grows rapidly.In recent years,with the rise of blockchain technology,resear-chers have found that due to its unique decentralization and immutability,blockchain technology is suitable for product traceability and verification,identity authentication and management,contract management,and other aspects of the IoT.However,IoT devices typically have limited computing and storage capabilities and cannot support the large amount of computing power required for blockchain mining.Moreover,due to the large number of devices in the IoT,the blockchain’s processing of transactions may be delayed,resulting in slow transaction confirmation speeds and low transaction throughput.Traditional blockchain is difficult to accommodate massive amounts of data,which poses a challenge to its scalability,Existing improvements based on blockchain,such as off-chain payments,protocol upgrades,and sharding,all have performance bottlenecks and limitations in the face of rapid growth in data.Currently,some researchers have proposed to replace the underlying chain-like structure of the blockchain with a Directed Acyclic Graph(DAG)structure,which has certain advantages in terms of performance.However,there are new challenges in implementing consensus algorithms and ensuring security.Existing research solutions are mostly theoretical designs that do not adequately consider security and practical implementation.This paper proposes and implements a high-throughput distributed ledger based on a directed acyclic graph(DAG).In this study,we improve the scalability of DAG-based distributed ledgers by designing a consensus algorithm suitable for them,and ensure the decentralization and security of the ledger by using trusted execution environments(TEEs)and encryption algorithms.Our experiments show that the throughput of the DAG-based distributed ledger is significantly higher than that of traditional blockchain,and has certain advantages over existing designs of DAG-based distributed ledgers.The main contributions and research results of this paper are as follows:1.A distributed ledger technology based on DAG is proposed,and its underlying structure is a parallel chain based on self-reference.Each node needs to maintain a DAG ledger locally and each block contains two reference hashes,namely self-parent hash and proof hash.The self-parent hash is implemented by referencing the last block of the parallel chain of the number to which the node belongs,while the proof hash is calculated by the block hash to obtain the number of the parallel chain to be referenced.This structure can effectively increase the concurrency between nodes,reduce the confirmation time of transactions,and increase the randomness of references.The experimental results show that the throughput of DAGbased distributed ledgers is significantly improved compared with that of traditional blockchain,which effectively improves the scalability and concurrency of distributed ledgers.2.A TEE-based signature and verification technology is proposed to improve the security of DAG ledger by providing a secure execution environment for data and code execution.TEE provides an execution space that is isolated from the common environment,so that its data and code have higher security performance and privacy.The experimental results show that using TEE to participate in the construction of DAG distributed ledgers will not affect the performance of the ledgers,and our method is more efficient than other blockchain ledgers using TEE.3.A consensus algorithm for DAG distributed ledger combined with TEE is proposed.By analyzing and studying the existing consensus algorithms,we can find that most of the consensus algorithms are only applicable to blockchain,and the research on DAG distributed ledgers still needs to be developed.The consensus algorithm proposed in this paper can effectively improve the efficiency of block consensus among nodes,and can quickly realize the release and confirmation of blocks,thereby realizing the confirmation of transactions.The experimental results show that,compared with other consensus algorithms that need to delay confirmation of transactions,the consensus algorithm proposed in this paper can effectively improve the throughput of DAG ledger and the speed of transaction confirmation.4.Design and implement a high-throughput distributed ledger system based on DAG.The system realizes the six-layer structure design of application layer,incentive layer,consensus layer,network layer,data layer and storage layer,and each layer is divided into multiple modules.This system can implement many functions such as the joining and exiting of nodes,setting the permissions of organizations and nodes,the publishing and querying of blocks,the consistency consensus among nodes,etc.It can effectively analyze and experiment the scalability,security,resource consumption and decentralization of distributed ledgers through the system. |