A Scheme of Intelligent Traffic Light System Based on Distributed Security Architecture of Blockchain Technology

In recent years, under the background that the rapid development of traffic volume makes the current traffic lights far from meeting the urban traffic demand, intelligent traffic lights based on the centralized architecture began to appear. However, in the traffic network with complex structure and private data flow, there are many malicious attacks against the centralized architecture, such as Sybil and ghost car attacks, which undoubtedly brings great security risks to the traditional intelligent traffic lights. Blockchain technology is a popular security framework nowadays. Based on its outstanding characteristics in the distributed architecture and the development of Edge Intelligence (EI) technology, this paper proposes a distributed security architecture scheme based on blockchain technology for the existing intelligent traffic light system. At the same time, based on the model cutting technology proposed by EI, the smart contract is improved to achieve redundant cutting of ledger data in the process of block consensus, which greatly reduces the pressure of blockchain ledger data transmission. In the end of this paper, the superiority of this scheme compared with the traditional intelligent traffic light scheme in communication cost and time cost is demonstrated by simulation experiment.


I. INTRODUCTION
With the rapid development of social economy and technology, traffic congestion has become a major problem in the field of transportation. At the same time, the rapid development of traffic volume makes the current traffic lights far from meeting the demand of urban traffic, which also increases the traffic pressure in a disguised way, and makes the traffic predicament fall into a vicious circle. In order to maintain the road traffic and improve the urban traffic efficiency, it is urgent to analyze the existing traffic system conditions, use intelligent algorithm to update the traffic light timing scheme in real time, thus giving birth to the concept of intelligent traffic lights. In the complex and changeable traffic network, The associate editor coordinating the review of this manuscript and approving it for publication was Honghao Gao . intelligent traffic lights can connect with other intelligent traffic lights in the scope to a regional server for networking. Through image recognition algorithm, edge detection algorithm and machine learning algorithm, the collected traffic image data can be processed cooperatively [1]. Based on the data of traffic flow and people flow at each intersection, a standardized model is established, and a large number of existing traffic data are used to test the model, finally the optimal traffic light timing scheme is generated. However, the centralized network architecture of traditional intelligent traffic lights is vulnerable to malicious attacks from Internet of Vehicles (IoV), such as Sybil attacks and ghost car attacks. If an intelligent traffic light node in the network is maliciously attacked, the rest of the intelligent traffic light nodes in the network area will be threatened and affected, and even the whole traffic light network will be paralyzed, resulting in serious traffic congestion and traffic accidents. Therefore, in order to improve the safety and feasibility of intelligent traffic lights and maintain a good intelligent traffic ecology, this paper introduces the block chain technology with the characteristics of decentralization [2], distributed ledger and consensus mechanism. With the aid of edge intelligence technology, a distributed security framework is established for the intelligent traffic light system, aiming to maintain the data authenticity and behavior security of the intelligent traffic light system through the distributed architecture.

II. LITERATURE REVIEW
At present, many scholars at home and abroad have carried out quite in-depth research in the field of intelligent traffic lights, and there are still some security schemes combining blockchain technology. In this section, we will outline the progress of intelligent traffic lights research and some solutions based on blockchain technology, focusing on their advantages and disadvantages.
When the concept of intelligent traffic is still in its infancy, Maram et al. proposed an Intelligent Traffic Light Control algorithm (ITLC) [3], which can make the intelligent traffic lights of each road intersection coordinate with each other and maintain the effective scheduling of road traffic. Li et al. later proposed a new control system based on real-time traffic flow [4], which can intelligently set the duration of traffic lights by sensing the number of vehicles through the sensor network. In the same year, with the rise of artificial intelligence technology, Zaid et al. [5] developed an automatic algorithm to control the time of traffic lights based on artificial intelligence technology and images on traffic lights, which can significantly increase the reliability and stability of intelligent traffic lights; according to Jin's team [6], a group based framework algorithm with adaptive learning ability can change the adaptive learning ability according to the traffic demand in real time and play a greater role in coordination; in the following year, Jin's team proposed a multi-level stage control scheme based on collective learning [7], emphasizing the use of reinforcement learning algorithm to train the system model, so as to improve the traffic performance. After that, intelligent transportation began to introduce the concept of Fog Computing (FC) [8]. Wu et al. [9] proposed an intelligent traffic light control system based on fog computing, which can calculate and share the traffic flow status of the intersection through the fog computing platform. Compared with the scheme of Maram et al., it has made great progress. At the same time, Liu's team realizes safe intelligent traffic light control based on Fog Computing [10], which opens up the safety field of intelligent traffic lights, and can also be more friendly to compatible atomization equipment. Dorin [11] believes that some optimization tools can be used to update intelligent traffic lights. Vilarinho et al. innovatively focused on pedestrians, put forward a traffic light control strategy based on people at Isolated Intersections [12], adding people flow to the model, which can make the intelligent traffic light model more in line with the actual situation. In the latest research, Yousef et al. put forward a new reconfigurable history based traffic management algorithm [13], which optimizes performance indicators such as AQL and AWT through a robust heuristic method. The traffic network is dynamic and complex, and the perception of intelligent traffic lights to vehicles needs sufficient accuracy. Gao's team proposed a neural collaborative filtering QoS prediction scheme based on context awareness [14], and proved that the scheme can effectively improve the accuracy of the perception system. At the same time, when considering the type processing of exchange information, Gao's team also proposed a method of type processing of multimedia resources based on transformation [15], which can ensure the consistency of the collected traffic data in the exchange process and improve the reliability of decision-making. The team also made an in-depth discussion on the path planning of the intelligent transportation system, integrating the probability model test technology [16], Yin et al. further proposed a group travel planning scheme in the temporary mobile social network [17], which solved the existing path planning problems of the intelligent transportation system. Yin et al. proposed that service recommendation service quality prediction based on deep feature learning can be used in edge computing environment [18], thus promoting a cost driven service mix [19] in uncertain environment, so as to realize low coupling among entities of intelligent traffic light system. When collecting the information of traffic flow and people flow, it is necessary to improve the existing image recognition algorithm to obtain more accurate data information. Yu's team proposed a multi-mode converter for multi view visual representation of image caption display [20] and a layered depth selection feature prediction scheme for fine-grained image recognition [21], which can be used in combination. Experiments show that the accuracy of recognition can be improved effectively. For the position recognition errors in the image recognition process, Yu's team proposed a space pyramid enhanced netvlad position recognition algorithm based on weighted triple loss [22], which solved this problem well. With distributed architecture, it is bound to use edge computing technology to exchange and feedback data in time. Wang et al. proposed a CPCS trust evaluation crowdsourcing mechanism based on intelligent mobile edge computing [23] and an edge based sensor cloud differential privacy computing scheme [24], which improved the computing power of edge devices and could better coordinate the operation of intelligent traffic light system. In addition, we need to pay attention to the privacy of data in edge computing. In view of this, Wu et al. proposed a risk prevention method based on micro state prediction for part of information social network [25] and a security protection and recovery strategy based on incentive mechanism for big data in social network [26], which effectively improved the security in edge computing field. In addition, Wang et al. also proposed a mobile edge computing based industrial sensor cloud big data cleaning [27], which promotes the accuracy of decision-making formed by edge computing. Generally speaking, with the efforts of the above scholars, the intelligent VOLUME 8, 2020 traffic lights have been improved in function and performance, but at the same time, the security as a data carrier is ignored, which is also easy to be broken by malicious attacks, resulting in serious consequences. The security technology provided by blockchain technology can solve this problem well. Thakre et al. [28] proposed a novel secure publishing model based on blockchain technology, which is used to regulate and encourage academic publishing. Helo and Hao [29] developed a technical framework of bogistics monitoring system by using blockchain technology, and skillfully used the immutable distributed ledger to complete the information security work of supply chain. Longo et al. [30] also added the blockchain to the cooperation and trust of the supply chain, designed and developed a software connector based on the blockchain to connect the Ethereum blockchain with the enterprise information system, so as to share information with partners of different visibility levels. Yu's team research has given the realization of an online fair contract exchange protocol without a trusted third party, based on blockchain technology and certainty. At the same time, it has changed the one-way trust relationship of the current transaction type blockchain technology, and established a multi-directional trust relationship among the participating nodes of the blockchain through additional protocols [31]. In order to solve the security of centralized management of large-scale IoT devices, Xu's team proposed a scalable management framework for lightweight IoT devices based on blockchain technology [32], which improved transaction throughput, shortened transaction delay and reduced communication costs. There are also many scholars who have developed many security algorithms according to the characteristics of blockchain. Wei's team has proposed a forward security SSE scheme based on blockchain [33], which is proved to be four times faster than the latest forward private SSE scheme through experiments. Phan's team proposed an incremental hash function [34] based on the block link through the research of the blockchain ledger, which can calculate the hash value of the update message faster, but there will be some conflicts with the original hash function. Sachin's team [35] is able to achieve more efficient and effective goals and reflect sustainability in SC practice by studying blockchain technology. Ren et al. [36] proposed a sequential aggregate signature scheme (DVSSA) with designated verifier combined with blockchain technology to ensure that the user's health data can only be seen by the designated person, protect the privacy of WBAN users, and also compress the size of blockchain storage space. In addition, Ren's team also built a blockchain based identity and certificate management mechanism [37], which can provide a strong data security guarantee for the industrial Internet of things. In addition, it also proposed a mechanism that combines blockchain and regeneration coding [38], to improve the security and reliability of data stored under edge computing. Wang et al. proposed several intelligent data collection scheme [39]- [41] based on data fusion and a multi-source transmission scheme [42], which can better serve edge computing. The team also proposed a low complexity adaptive unloading scheme [43] based on Hungarian algorithm, which can effectively reduce the unloading delay of edge servers. He et al. proposed a light intelligent algorithm for edge computing [44]. Whether it is applied to solve practical problems or to develop more secure algorithms, the status of blockchain technology can not be shaken. In the development process of intelligent transportation and blockchain technology, we have summed up many experiences and lessons and integrated them into this paper.
The main contribution of this paper is to propose an improved security solution in the field of intelligent traffic lights, put forward a distributed intelligent traffic light architecture based on the decentralized characteristics of blockchain technology, and improve and innovate the existing intelligent contract by using the redundant cutting technology proposed by edge intelligence, effectively reducing the communication load in the consensus process in the block network.

A. OVERVIEW OF BLOCKCHAIN TECHNOLOGY
Blockchain is a kind of chained data structure which combines data blocks in chronological order in a way of sequential connection, and it is a distributed ledger that can not be tampered and forged guaranteed by cryptography [45].
In the intelligent traffic light architecture environment, which highly relies on the information of other nodes and maintains high frequency data exchange, new requirements are also put forward for the authenticity and privacy of data information: in order to prevent the real-time data of each intersection from being tampered with or used maliciously, the four core technologies of blockchain technology for the trust and security of transaction information can be adopted.

1) DECENTRALIZED ARCHITECTURE
In blockchain technology, decentralization means that in a system with many nodes, each node has a high degree of autonomy. Each node can choose to connect freely with each other to form a new connection unit. Any node may become a periodic center, but it does not have the mandatory central control and intervention function. The impact between nodes will form a non-linear causal relationship through the network. This open, flat and equal system architecture is called decentralized architecture.

2) DISTRIBUTED LEDGER
As the basis of blockchain to ensure the information security of account books, the most important implementation process of distributed account books is to make multiple nodes distributed in different places jointly complete the transaction bookkeeping, and the complete transaction account books will be dynamically stored in each node participating in the transaction. Therefore, all nodes can supervise and testify the legitimacy of transactions. Different from the traditional distributed storage, the uniqueness of the blockchain distributed storage is mainly reflected in two aspects. First, each node of the blockchain stores complete data according to the block chain structure, while the traditional distributed storage generally stores data in multiple parts according to certain rules. Second, each node of blockchain is independent and equal in status, and the storage consistency is guaranteed by consensus mechanism, while the traditional distributed storage generally synchronizes data from the central node to other backup nodes. There is no single node that can record the account data separately, thus avoiding the possibility of single bookkeeper being controlled or being bribed to record false account. Because there are enough accounting nodes, in theory, unless all nodes are destroyed, accounts will not be lost, thus ensuring the security of account data [45].

3) SMART CONTRACT TECHNOLOGY
Ethereum's smart contract is a blockchain based digital asset control program. In a narrow sense, smart contract is a set of program codes involving relevant logic and algorithms, which can program the complex relationship among people, legal agreements and networks. In a broad sense, smart contract is a kind of computer protocol. Once deployed, self execution and self verification can be achieved. At present, it has been applied in distributed computing, Internet of things and other fields.

4) CONSENSUS MECHANISM
The consensus mechanism exists in the consensus layer of the blockchain infrastructure model. It takes Proof of Work (PoW) and Proof of Stake (PoS) as the consensus basis, and then uses Byzantine and Rayleigh wave consensus algorithms as auxiliary consensus methods to complete the consensus work of adding accounting nodes in the block and confirming the validity of transaction records. Taking PoW as an example, only when a block accounting node controls more than 51% of the accounting nodes in the block, can a record be forged without considering the huge number of nodes in the whole blockchain and the loss of their own rights and interests. As more and more nodes are added to the blockchain, the possibility of successful forgery approaches zero. This can effectively prevent information from being tampered with illegally or used by malicious nodes.
The consensus mechanism has two basic characteristics of ''The minority is subordinate to the majority'' and ''Everyone is equal'' [45]. The principle of ''The minority is subordinate to the majority'' does not necessarily refer to the number of block accounting nodes, but also refers to the computing power of nodes, the number of equity of nodes or the comparable characteristics of some other nodes. ''Everyone is equal'' emphasizes that when the block accounting nodes meet the conditions of participating in consensus, all the block accounting nodes have the priority to put forward consensus voting. If the consensus of other nodes is obtained, the consensus result may become the final consensus result.

B. OVERVIEW OF EDGE INTELLIGENCE
Edge Intelligence (EI) refers to terminal intelligence, which is an open platform integrating network, computing, storage and application core capabilities, and provides edge intelligence services to meet the key needs of industry digitalization in agile connection, real-time business, data optimization, application intelligence, security and privacy protection [46]. It can deploy intelligent attributes on edge devices, make terminal intelligence closer to users, and provide intelligent services to users in a faster and more accurate way.
In the intelligent traffic light system, there are cameras, remote data centers and other terminal equipment. As the edge terminal equipment node, it is difficult to meet the huge data computing needs in the process of algorithm training, such as machine learning, in computing capacity and information storage capacity. The edge cloud collaboration, model cutting and redundant data reduction in the edge intelligence scheme can solve these problems well.

IV. SYSTEM MODEL A. SYSTEM ARCHITECTURED
In order to make the system framework have higher safety factor, the loose coupling principle is adopted in this paper. It is composed of three main entities: Municipal Administration, Traffic Administration and Intelligent Traffic Lights, among which Intelligent Traffic Lights entity includes edge terminal equipment such as camera and data sub center. In this VOLUME 8, 2020 paper, under the background of intelligent traffic light system using blockchain structure and Edge Intelligence technology, the feasibility of an intelligent traffic light system with data privacy and malicious attack resistance is studied. In order to facilitate the elaboration of the system framework and principle, MA, TA and ITL will be used to refer to Municipal Administration, Traffic Administration and Intelligent Traffic Lights.
The framework adopts the principle of loose coupling in order to reflect that the main entities need to complete data exchange in a low degree of dependence, and at the same time guarantee the realization of system functions in a form similar to ''separation of three powers'': MA has the power to establish, add and abolish ITL nodes, but it can not obtain sensitive data including pedestrian characteristics and vehicle characteristics collected by terminal equipment. This is to prevent abuse or corruption within MA, resulting in a threat to ledger information. In addition to obtaining all ITL collection data and decision-making results, TA also has the authority to temporarily control and interveneITL, which is only granted when individual ITL nodes fail or cities hold large-scale events and processions. At the same time, as a limitation, TA will not be able to add or remove ITL nodes. As an ITL node, in addition to the authority of collecting and processing data and decision-making scheme, it can also act as a member node in the blockchain to make consensus decision on the new ITL node added by MA. After obtaining the Proof of Work or Proof of Stake of the new node, it can decide whether it is allowed to join through consensus mechanism. This kind of mutual cooperation and checks and balances architecture can improve the safety of the intelligent traffic light framework to a greater extent. The specific system framework is shown in the Figure 3.
V. OUR SCHEME Based on the system framework described in the previous section, this paper will propose a distributed security scheme based on blockchain technology in the following, and make a detailed description of the flow of the scheme. At the same  time, in order to avoid the huge overhead load caused by the introduction of blockchain mechanism, we will use edge intelligence technology to improve the smart contract used by the system, complete the appropriate redundant cutting of the block, reduce the communication cost of the scheme on the premise of ensuring security, so that it can be better compatible with the original intelligent traffic light system architecture.

A. DECENTRALIZED DISTRIBUTED ARCHITECTURE BASED ON BLOCKCHAIN
Different from the traditional intelligent traffic light system in which the data is uploaded to the central server for processing, the intelligent traffic light architecture in this scheme adopts the decentralization scheme in the characteristics of blockchain, and the data collection, processing and transmission will be completed by each independent intelligent traffic light node, without relying on the server to participate in decision-making. At the same time, under the coordination and supervision of MA and TA, the safety of this way will be more solid. The advantage of the distributed scheme is to avoid the threat of being vulnerable to malicious attacks in the centralized scheme: in the centralized scheme, if there is a camouflaged traffic light node or ghost car attack, it is easy to upload the wrong information to the server, and then make the server processing decision confusion, and ultimately lead to the paralysis of the entire traffic system. The decentralized distributed architecture is shown in Figure 4.
In the distributed architecture based on blockchain, all blocks made up of nodes will maintain a common ledger, and the hash value of each block jointly proves the authenticity of the ledger. When one ITL makes a decision, it needs to obtain the unique bookkeeping right in the blockchain to add new data records, and generate new blocks through hash processing, broadcast and wait for the consensus of other nodes. The public ledger can only be added after the consensus is verified. This mode effectively prevents the whole intelligent traffic light system from being paralyzed due to malicious attacks on individual ITL nodes in the system. If some ITL nodes in the system suffer from multi-point attack at the same time, as long as the number of necrotic nodes is less than half of the number of block nodes, under the supervision of MA and TA, it can be intervened to some extent, for example, restart the node system or temporarily cancel the nodes. These methods can be adjusted quickly before the dead nodes affect the existing traffic conditions, which is also the necessity of MA and TA in this framework.

B. SPECIFIC IMPLEMENTATION PROCESS OF SAFETY SCHEME 1) INSTALLATION OF ITL NODE
ITL node has storage and computing functions, and it needs high security when it is put into use. Therefore, MA and TA are required to supervise its process when installing and establishing ITL node in this scheme, so as to prevent the creation ITL node from being maliciously attacked.
The new ITL node must be constructed and added by MA under the supervision of TA. The completed ITL node will receive a small amount of PoW from TA to assist it to add blocks in the subsequent process. Currently, it is only used as the creation node, not formally added to the block.
At this stage, TA will select global parameters for all ITL nodes in the system. On the newly installed ITL node, the public key (K pub−TA ), ITL's own key (K priv−ITL ) and digital certificate with TA key signature are stored. Other installed ITL nodes will also obtain the public key (K pub−ITL ) of the new ITL node from TA. TA stores the public key (K pub−ITL ) of the new ITL node and its own private key (K priv−TA ).

2) REGISTRATION OF ITL NODES
In the registration phase, all new ITL nodes must be registered in TA. After confirming the construction process specification and registering the TA under the premise that the exchange information is normal, the TA will assign the unique ID to the new ITL node. At this time, the information stored by each ITL node is the unique identification ID, the public key of TA (K pub−TA ) and the digital certificate with TA key signature.

3) AUTHENTICATION PROCESS OF ITL NODE
• Broadcasting The formation of block depends on hash function, which can transform the original information such as time, operation data and records stored in entity into a short summary information. Any slight change of the original information will make the hash value transformed by the hash function totally different, and also make it unable to reverse.
In the above-mentioned ITL node that completes the installation and registration process, the original information stored with the current timestamp needs to be converted into a hash value through the hash function: After the conversion is successful, the ITL node uses its own key (K priv−ITL ) to encrypt the hash value H 1 to form a message and broadcast the rest of the installed ITL nodes: • Consensus and verification After receiving the request message broadcast by the new ITL node, the rest of the installed ITL nodes enter the consensus and verification stage. The main task of this stage is to use the consensus mechanism to complete the consensus and verification of new ITL nodes. At the same time, at this stage, TA and MA are unable to impose unfair intervention on their block.
In the consensus process, the installed ITL node needs to decrypt the request information using the public key (K pub−ITL ) of the new ITL node to obtain the initial hash value H 1 : In ITL system, the number of ITL nodes in each block is limited, usually between 16 and 36, which also avoids the disadvantage of higher network communication complexity of Byzantine Fault Tolerance algorithm (PBFT) and achieves better consensus results. The key process of consensus includes three stages: pre prepare, prepare and confirm.  b) Whether the current view number is v; c) Whether the current ITL node implementing the consensus has never accepted message H 1 with sequence number m but different from its digest d in view v; d) Whether the sequence number m of the Message pre−p is between the upper and lower limit h and H of the watermark, so as to prevent a failed ITL node from using a large sequence number to consume the sequence number space.
After each ITL node participating in the consensus completes the above confirmation, it will enter the preparation stage. At this stage, the ITL node needs to confirm: a) Whether the signature of the Message pre−p and the Message prep is correct; b) Whether the view number v is consistent; c) Whether the message sequence number meets the waterline limit.
When the confirmation is passed, Message prep is written to the message log.
The flag of completion of the preparation stage is: the ITL node will record (H 1 , v, m, ID) in its message log, where H 1 is the request content, the number m of the Message pre−p in view v, as well as n-1 Message prep received from different ITL nodes consistent with the Message pre−p .
The preparation stage and the preparation stage ensure that all normal nodes agree on the request sequence number in the same view. When all the above conditions are met, the ITL node writes the confirmation message to the message log. It needs to be added that all received messages of a request are written to the log, which is allowed to exist in memory.
Define the conditions to confirm the completion of committed (H 1 , v, m) as true: The conditions for local confirmation to complete committed-local (H 1 , v, m, ID) are as follows: The confirmation stage guarantees the following invariants: This invariant and view change protocol ensure that all normal ITL nodes agree on the sequence number of local acknowledgment requests, even if the acknowledgment of these requests in each node is in a different view. Furthermore, this invariant ensures that any normal ITL node can finally confirm at least (n−1)/2+1 request nodes, and reduces the risk of malicious nodes disturbing the consensus results to a greater extent.
Each ITL node executes H 1 request after the committed-local (H 1 , v, m, ID) is true, and the consensus state of ITL can reflect that all requests with number less than m are executed in order, which ensures that all normal ITL nodes execute all received requests in the same order, and ensures the correctness and order of consensus algorithm. After the consensus and verification operations are completed, each ITL node will send a reply to the requested ITL node. In this process, the ITL node will discard the reply with a smaller time stamp than the one with a reply, so as to ensure that the reply will only be executed once.
So far, the consensus and verification phase has been basically completed and will enter the decision-making phase.
• Policy decision The ITL nodes participating in the consensus will sign in a round according to the results of the consensus and verification process. If the number of signatures is greater than or equal to 51%, the newly created ITL nodes will be allowed to join the block, otherwise, they will not pass, and the request record will be discarded. The decision results will be returned to the new ITL node, and the consensus will be fed back to the TA.      When the authority of data collection, processing and transmission is distributed to each independent ITL node, it needs to be used as an edge terminal device to complete data calculation, processing, storage and other operations, that is, Edge Intelligence, in order to achieve the purpose of decentralization. At the same time, ITL as a bookkeeping node, its consensus election process for new nodes and decision-making operations for data need to be recorded in the blockchain ledger, and circulated in the blockchain in the form of public ledger. Each independent node needs to store the copy of the circulation account book, which is a huge test for the communication cost of the whole network, which also requires the blockchain to introduce the mechanism of smart contract to maintain the stability of the network.

20: end if ---------------------------------------------
In this paper, based on the consideration of security and the performance of the system, we will combine the model cutting scheme proposed in the Edge Intelligent technology to change the algorithm, so as to form a redundant cutting technology for information, and add it to the existing smart contract. The advantage of this improvement is to solve the problem of high redundancy of account information in the consensus process, which leads to the soaring communication cost. The improved smart contract framework is shown in Figure 6:

1) INITIALIZATION
The smart contract includes necessary consensus modules, such as Byzantine algorithm [45], Ripple consensus algorithm, data management module, user management module, contract management module, legal text and parameters.
Redundancy cutting technology is often used in the field of edge intelligence. Its purpose is to cut the training model adaptively without affecting the data accuracy and data conclusion, so as to reduce the pressure of communication load. In the traffic light network with large amount of data, each independent ITL node needs to store the copy of the circulation account book, which will cause great pressure on the data storage of the node. Therefore, in the design of the smart contract, a redundant cutting process is added to the logic module of the smart contract. Initialization is the first step in the redundant cutting process. In the initialization stage, it is necessary to select global parameters for ITL nodes, zero the original information in the block, retain the initial hash value of each ITL node's account book, and clear the blacklist set by MA and TA.

2) BLOCK NODE WEIGHT CALCULATION AND REDUNDANT CUTTING
In Section V, this paper introduces the whole process of adding new ITL nodes into blocks in detail. In the consensus and verification stage, the main scheme of this paper is the current mainstream pbft algorithm. Unfortunately, in the process of PBFT algorithm consensus, it is necessary to repeatedly verify the pre prepared message, prepared message and confirmed message. This verification process will also require more communication resources in the process of consensus promotion.
Based on this dilemma, the second step of redundant cutting process needs to calculate the weight of the information generated by the consensus process in the block. The ITL nodes participating in the consensus in the block are analyzed by weight. Each ITL node has different contribution to the improvement of traffic environment in the area after entering the block, and its PoW and regional reputation are naturally different. We call this part of the value involved in the calculation as reputation product score, from low to high score as At the same time of consensus mechanism in reality, each ITL node must maintain its current working state continuously, which leads to the loss of computing power of nodes, which is also different, which affects the decline of ''loyalty'' of normal ITL nodes participating in consensus process, although the decline of loyalty is inevitable. We record the ''loyalty'' lost due to maintaining the existing working state as µ, the original ''loyalty'' of ITL node as x, then the ''loyalty'' of a single node is finally recognized as λ = x − µ, and the total ''loyalty'' of this block is: By integrating the reputation score and ''loyalty'' of each node, the weight of each ITL node is finally calculated as follows. It should be noted that σ ∈ (0, 1) in the formula is the standard deviation of the node reliability recognized by TA: After completing the weight calculation of ITL nodes, for ITL nodes with high weight, when other ITL nodes receive the pre-preparation message and preparation message from this node, they can directly skip the verification stage, and the default content is the authenticity of their views. At the same time, if the pre-preparation message and the preparation message broadcast by the ITL node with high weight are verified by one of the ITL nodes participating in the consensus, and there are still some ITL nodes that have not yet processed the received broadcast (the message is in the processing queue), then the verified ITL node can send broadcast to the other ITL nodes participating in the consensus. Other ITL nodes traverse their own processing queue after receiving the broadcast. If there is a message whose serial number is verified by broadcast, the redundant message will be cut.

3) IMPACT ASSESSMENT
The redundant cutting process is to selectively cut the pre preparation stage and preparation stage in the consensus process, and give a few ITL nodes with high trust the privilege of broadcasting messages from being repeatedly checked. However, in order to ensure that the final consensus results will not be affected by information cutting, we do not carry out this cutting process in the confirmation stage of PBFT algorithm. In this stage, each participating ITL node is treated equally, and the whole process of broadcasting, receiving and processing must be completed. Therefore, the results of information cutting in the first two stages will receive a complete verification evaluation in the confirmation stage. If the evaluation result is not ideal, even if it does not cause the fundamental error of the consensus result, it will be required to carry out the consensus process again, and punish the ITL node that bears the main weight in the last two stages, and TAwill reduce the credibility of this node.

VI. EXPERIMENT ANALYSIS
In this paper, we use the simulation platform of VISSIM-Excel VBA-MATLAB [48] to simulate the security solution proposed in this paper. VISSIM is a general-purpose traffic simulation modeling software [49], whose simulation time interval is 0.1 seconds, which can simulate various traffic conditions in reality, so it can comprehensively and effectively evaluate various traffic schemes [50], [51]. In order to verify the feasibility of the scheme, the experiment will use the traditional intelligent traffic light scheme to compare with the scheme in this paper, and finally analyze the simulation results.

A. SIMULATION ENVIRONMENT B. SIMULATION ANALYSIS 1) COMMUNICATION COST ANALYSIS
Based on the characteristics of intelligent traffic lights, the setting of intersection parameters built in VISSIM in this paper is shown in Table 3, and all indicators of communication are taken into account. As the measurement of the traffic road condition mainly depends on the throughput of the intersection, and the simulation block is large in the process of the experiment, the analysis of the group arrival rate during the operation will produce large errors. Therefore, we finally choose the throughput of intersections and packet loss rate of runtime packets as the analysis indicators of this section. At the same time, all the experiments below will be compared with the traditional intelligent traffic lights proposed in [47].
In order to make the experimental results more close to the performance of intelligent traffic lights, the following experiments will respectively simulate the changes of throughput and packet loss rate of intelligent traffic lights when they operate normally in peak hours, which is to avoid the measurement and analysis data when the traffic is scarce, that is, when the intelligent traffic lights do not play the real performance, which will cause a certain degree of error to the correct results of the experiment.  As shown in Figure 6, abscissa represents the duration of intelligent traffic light peak operation, in seconds(s), and ordinate represents real-time intersection throughput, in kbps. It can be clearly seen that before the peak operation duration of the traditional intelligent traffic light scheme reaches 400s, the real-time traffic throughput gradually increases while tends to be flat, which is better than the scheme in this paper. However, with the duration exceeding 400s, due to the advantages of ITL block distribution in this scheme, the ledger information transmission has adapted to the real environment, and because of the existence of redundant cutting technology, the system can complete the decision-making task of larger throughput, which makes the real-time intersection throughput of this scheme surpass the traditional scheme. At the same time, it can maintain a certain degree of upward trend. However, the throughput of the traditional scheme can only be kept below 200kbps, and there is a upper limit of throughput.
As shown in Figure 8, abscissa represents the duration of peak operation of intelligent traffic lights, in seconds(s), and ordinate represents the packet loss rate in × 10 −4 % of account books in blockchain. It can be seen from the figure that before the peak operation time of intelligent traffic lights reaches 600s in the traditional scheme, the overall curve shows an upward trend. However, in the second half of the curve, due to the adaptive influence of the system environment, it slightly fell back, and finally kept close to the level of 5×10 −4 %. The account packet loss rate caused by the scheme in this paper tends to be stable after the peak operation time is about 350s. In addition to the help of the  system's own adaptive ability to the environment, it is more because the improved smart contract in the scheme in this paper is gradually playing a role, making the packet loss rate finally fall below 4×10 −4 %.
At the same time of maintaining the peak operation of intelligent traffic lights, this paper also carried out repeated simulation experiments for the same indicators of the nodes of intelligent traffic lights.
As shown in Figure 9, the abscissa represents the number of nodes of intelligent traffic lights, and the ordinate represents the real-time intersection throughput, in kbps. It can be seen from the figure that with the increase of the number of intelligent traffic light nodes, the traditional scheme will reach a peak when the number of nodes is about 10. It is estimated that the throughput can reach 191kbps, but it will gradually fall back to around 120kbps later. The rising trend of the scheme in this paper will stop when the number of nodes reaches about 8, and then the redundant cutting technology starts to play a role. It optimizes the account book transmission process to make the throughput climb to about 145kbps stably, and when the number of nodes reaches 56, it will reverse the traditional scheme in throughput.
Similarly, as shown in Figure 10, the abscissa represents the number of nodes of the intelligent traffic light, and the ordinate represents the packet loss rate of the account book in the blockchain, with the unit of × 10 −4 %. It can be seen from the figure that with the increase of the number of intelligent traffic light nodes, the rate curve of account packet loss in the blockchain shows a steady upward trend, both in the traditional scheme and in this scheme. When the number of  intelligent traffic light nodes reaches 46, the account packet loss rate of this scheme gradually starts to play the powerful adaptive ability of block distribution, and the rising speed of packet loss rate slows down, and finally stays at about 3.2×10 −4 %. In the traditional scheme, the packet loss rate of account book keeps increasing at a linear speed, and breaks through 5×10 −4 % before the end of simulation.

2) TIME COST ANALYSIS
In addition to analyzing the scheme architecture from the perspective of communication cost, it also needs to further analyze its feasibility from the perspective of time cost. Further simulation experiments are also carried out according to the parameter list in Table 3. In terms of time cost index, the reduction of system delay is often a necessary condition for a new scheme to be proposed. In the huge intelligent traffic light network, a system delay is needed to identify the feasibility of the scheme, so this paper selects the system delay in the analysis of time cost.
In Figure 11, the abscissa represents the number of nodes of the intelligent traffic light, and the ordinate represents the overall delay of the intelligent traffic light system, with the unit of × 10 −2 s. It can be seen from the figure that the delay curves of the two schemes increase slowly with the increase of the number of nodes of the intelligent traffic lights, and the difference is that when the number of nodes exceeds 16, the delay growth rate of the scheme in this paper has been greatly reduced. Even when the number of nodes reaches 90, the curve shows a downward trend. This is because with the increase of nodes in this scheme, the execution of smart contracts between nodes will become ''simplified'' because of the existence of information cutting. This ''simplification'' is through the adaptive stage of the system, rather than the formal simplification of the smart contract itself. This shows the superiority of the scheme in the control system delay.

C. SUMMARY OF SIMULATION EXPERIMENT RESULTS
According to the simulation experiment analysis in Section VI, it can be seen that this scheme has considerable advantages over the traditional intelligent traffic light scheme in terms of communication cost and time cost, especially in terms of real-time intersection throughput, account packet loss rate, system delay and other indicators. At the same time, this advantage will be more obvious when the traffic network becomes larger because of the characteristics of blockchain's own distributed architecture. The feasibility and effectiveness of the scheme are verified by simulation.

VII. CONCLUSION
Based on the in-depth discussion, analysis and verification of the security field of intelligent traffic lights, this paper proposes an intelligent traffic lights system under the distributed security architecture based on blockchain technology, which can prevent malicious attacks against some nodes from invading and resulting in the collapse of the whole system. In this scheme, the redundant cutting technology proposed by Edge Intelligence is also used to improve and innovate the existing smart contract, and through the simulation and comparative experiment of this scheme, it is proved that this scheme can effectively reduce the huge communication load and time cost caused by information transmission in the consensus process of intelligent traffic light block network. Intelligent traffic light system is an important component to realize intelligent traffic in the future. In view of the research of its combination with blockchain technology, we will continue to carry out a series of research work. PENGJIE ZENG is currently pursuing the bachelor's degree from the Hunan University of Science and Technology. His research field is the application of blockchain in the Internet of Things, cyberspace security, privacy protection, and large data processing and analysis. He received the Second Prize at the National College Students Innovative Electronic Design Competition and the Third Prize at the School-Level Financial Management Data Analysis Competition. He is currently in charge of leading the Technical Team to complete the development of a smart agriculture project and an intelligent traffic light project.