This paper was converted on www.awesomepapers.org from LaTeX by an anonymous user.
Want to know more? Visit the Converter page.

RC-chain: Reputation-based Crowdsourcing Blockchain for
Vehicular Networks

Lijun Sun [email protected] Qian Yang [email protected] Xiao Chen [email protected] Zhenxiang Chen [email protected] College of Information Science and Technology, Qingdao University of Science & Technology, Qingdao 266061, China Shandong Provincial Key Laboratory of Network Based Intelligent Computing, University of Jinan 250022, China School of Informatics, University of Edinburgh, Edinburgh, EH8 9AB, UK
Abstract

As the commercial use of 5G technologies has grown more prevalent, smart vehicles have become an efficient platform for delivering a wide array of services directly to customers. The vehicular crowdsourcing service (VCS), for example, can provide immediate and timely feedback to the user regarding real-time transportation information. However, different sources can generate spurious information towards a specific service request in the pursuit of profit. Distinguishing trusted information from numerous sources is the key to a reliable VCS platform. This paper proposes a solution to this problem called “RC-chain”, a reputation-based crowdsourcing framework built on a blockchain platform (Hyperledger Fabric). We first establish the blockchain-based platform to support the management of crowdsourcing trading and user-reputation evaluating activities. A reputation model, the Trust Propagation & Feedback Similarity (TPFS), then calculates the reputation values of participants and reveals any malicious behavior accordingly. Finally, queueing theory is used to evaluate the blockchain-based platform and optimize the system performance. The proposed framework was deployed on the IBM Hyperledger Fabric platform to observe its real-world running time, effectiveness, and overall performance.

keywords:
Crowdsourcing , Reputation Management , Vehicular Networks , Blockchain , Hyperledger Fabric , Queueing Theory.
journal: Nuclear Physics B

1 Introduction

Enhanced wireless communication (e.g., 5G) technologies expand the scope of vehicular network services, such as the vehicular crowdsourcing service (VCS), which leverages smart device-equipped vehicles to support the sharing and trading of information among vehicles (Wu et al., 2013). In the VCS scenario, behaving as either service consumers or providers, vehicle-nodes cooperatively collect and share data of common interest (e.g., road conditions of a given destination, parking space availability). A specific request may be considered a payable mission that is assigned to a group of service providers via crowdsourcing platform (Howe, 2006). Once the mission is completed by the service providers, an optimal solution is selected by the service consumer via information sharing: the selected service provider is compensated for completing the trade. Service providers can also proactively share traffic jam warnings, or recommend restaurants along a certain route. The VCS when functioning optimally, gives users a safe, convenient and comfortable driving experience.

In addition to these advantages, the VCS is markedly advantaged by security threats. Researchers have introduced blockchain technology into vehicular networks in effort to exploit decentralization, immutability, transparency, and traceability characteristics (Huang et al., 2020). However, the entrance of a host of vehicle-nodes to the permissionless public blockchain exacerbates security and privacy risks, not to mention the high costs and high latency caused by the mining process of miners. By contrast, the consortium blockchain has strict permissioned standards for vehicle-nodes, which to a certain extent guarantees the legality of disseminated information (Kang et al., 2018). However, the consortium-based VCS will face challenges when encountering the following scenarios.

  • 1.

    Scenario 1: All nodes that are permitted to join the consortium blockchain are legal, but this does not mean that their behavior is always regulated. Free-riding, spoofing, and repudiation behaviors, for example, may happen occasionally. What is the best approach to eliminating selfish or malicious behaviors of vehicles? In other words: how does one engineer a trusted platform that allows users to trade information without worrying about cheating or attacks?

  • 2.

    Scenario 2: When a VCS mission is released, many vehicles make requests indicating whether or not they can provide services. How does one distinguish the most valuable information from the numerous information sources?

  • 3.

    Scenario 3: The “reputation value” concept was introduced to solve the above problems as a basis for selecting the best service providers (Yang et al., 2019; Kang et al., 2018). The reputation value can be calculated through mutual ratings between vehicles based on the assumption that all vehicles provide honest ratings for others. However, the value loses its meaning when malicious ratings or false reporting occur. So, how can these untruthful rating behaviors be eliminated?

  • 4.

    The limited resources of traditional centralized crowdsourcing platform are also taxed as the quantity of vehicle-nodes increase, coupled with the rapid growth of dissemination information. Large-scale user groups pose challenges in building an efficient VCS platform.

This paper proposes a reputation-based crowdsourcing blockchain framework, the RC-chain, which was designed to address these problems. The RC-chain implements crowdsourcing management on a blockchain platform, the IBM Hyperledger Fabric (Whitepaper, 2018), which is transparent, irreversible and decentralized. Each iteration of crowdsourced information-trading is recorded as a transaction of the blockchain based on a group of agreed-upon criterion specified in the smart contract (i.e., the chaincode in Fabric), which prevents adversarial user behaviors and guarantees a secure trading environment. A reputation model is also established with the RC-chain through smart contract to improve the crowdsourcing service quality. The reputation model is used to evaluate the trust-degree of VCS users, both service consumers and providers, based on their activities - including the quality of mission completion with service providers and the payment-operations of service consumers. This quantified reputation value can help consumers decide the potential providers and also can help providers choose their missions. The reputation value of the service vehicle is updated and recorded in the chain each time a crowdsourcing service is completed. When there is a problem with the reputation of a certain vehicle, it is marked with a “warning”.

We integrated our designed information-trading and reputation-evaluating components, to implement RC-chain atop the IBM Hyperledger Fabric, which combines the transaction process and a three-stage consensus. We used queueing theory to optimize configuration and performance of the Fabric-based RC-chain. Numerical analysis and practical experiments were conducted to test the feasibility, efficiency, and overall performance of the proposed framework. The primary contributions of this work can be summarized as follows.

  • 1.

    A novel blockchain-based VCS platform is proposed for enhanced trust, the Hyperledger Fabric-based RC-chain. Each trading record is designed as a RC-chain transaction by specifying all trading rules in transparent smart contract.

  • 2.

    A novel reputation model is designed and aggregated with the RC-chain to improve crowdsourcing service quality. The model prevents adversarial or irresponsible behaviors in handling crowdsourced missions by degrading the reputation of any malicious service consumers or providers. Additionally, a Trust Propagation & Feedback Similarity (TPFS) model identifies malicious service providers by analyzing their mission-based reputation figures: this helps consumers find an optimal service provider to receive high-quality service.

  • 3.

    Queueing theory is applied to generate an efficient configuration scheme that enhances RC-chain platform performance. We conducted a series of experiments on key performance indicators such as transaction confirmation time and transaction throughput to further assess the proposed framework’s effectiveness.

To the best of our knowledge, the RC-chain is the first solution to combine blockchain-based crowdsourcing management with reputation evaluation and queueing-based optimization approaches. Our analysis, as discussed in detail below, indicates that the framework allows for secure management and major performance improvement in VCS scenarios.

Below, Section 2 discusses previous work related to this study. Section 3 describes the VCS scenarios, roles and deployment relevant to RC-chain. Section 4 introduces the transaction process and consensus mechanism. An optimized reputation management model for calculating the reputation value of participants is given in Section 5. We modeled the RC-chain using queueing theory and evaluated its performance as discussed in Section 6. The results of the experiment and our interpretation of them are presented in Section 7. Section  8 gives concluding remarks.

2 Related work

Trust is an important research topic in the vehicular network field. To solve the challenge of the trust problem, many studies have been carried out. Existing trust models can be divided into three categories based on their respective evaluation objects: entity-centric trust models that focus on vehicle credibility, data-centric trust models that focus on received messages’ credibility, and combined trust models for evaluating both entities and data (Lu et al., 2018). Existing trust management methods are mainly centralized (Chen and Wang, 2017; Tian et al., 2020), or distributed (Haddadou et al., 2014; Zhang et al., 2016).

Many previous researchers have explored trust management schemes for Internet of Vehicles (IoV). Chen and Wang (Chen and Wang, 2017), for example, used cloud computing technology to build a three-tier trust model to ensure the reliability and security of reputation values. Vcash was introduced as a reputation framework for identifying denial of traffic service (Tian et al., 2020); it relies on a central server, however, resulting in centralization problems. Vcash also assumes that the Road Side Units (RSUs) are trustable, which actually may provide false messages owing to being attacked (Zhang, 2011). Raya et al. (2006) conducted a comprehensive analysis of attack problems. Cloud servers have high communication costs and usually cannot satisfy delay requirements, so it is difficult to guarantee the quality of service (Greenberg et al., 2009).

An alternative approach is the distributed aggregate privacy-preserving authentication (DAPPA) design (Zhang et al., 2016). Its necessary generation of one-time private key and aggregate signatures results in latency issues and affects system performance (Lu et al., 2019). Haddadou et al. (2014) developed the distributed trust model DTM2 to detect and eliminate malicious nodes, but could not ensure the safety of the reputation system itself. Other researchers have utilized the behavior-based trust management mechanism (Mármol and Pérez, 2012; Wex et al., 2008) to establish entity-centric models, which guarantees the accuracy of the reputation value, but does not secure the reliability of updated reputation values during storage. At present, there are several major challenges for electronic data storage. Unilateral deposit schemes are costly, allow data to be easily lost or tampered with, and are difficult to trace.

Table 1
Comparison of the RC-chain with the existing schemes
Reference Permission Distribution Incorrect Recommendations Feedback Similarity
(Kang et al., 2018) ×\times ×\times
(Yang et al., 2019) ×\times ×\times ×\times
(Jabbar et al., 2020) ×\times ×\times ×\times
(Tian et al., 2020) ×\times ×\times ×\times ×\times
(Xiao et al., 2020) ×\times ×\times
RC-chain(This paper)

Blockchain technology has attracted extensive attention from researchers for its qualities of decentralization, autonomy, traceability and non-tampering modification. It has emerged a viable solution to store and update reputation values. Yang et al. (2019) established a decentralized trust management system for vehicle networks based on blockchain technology. It adopts a consensus algorithm that combines Proof of Work (PoW) and Proof of Stake (PoS), where RSUs with larger stakes are more likely to be elected as a block producer. However, the miner hash value calculation process requires excessive computing power; few individuals are paid while most are simply wasting their resources (Wang et al., 2018). This is not desirable for vehicles with limited resources. Additionally, the consensus mechanism is collaboratively implemented by participants with conflicting interests. In a city or local area, RSUs is usually deployed and maintained by one or two network service providers, which creates potential security risks (e.g., 51% attack) (Chen et al., in press). The PoS scheme is also susceptible to “rich getting richer” problems (Zheng et al., 2017).

Li et al. (2018) proposed an incentive network based on privacy protection. CreditCoin, which uses a Byzantine fault-tolerance (BFT) consensus algorithm to encourage vehicles to publish messages. Awais Hassan et al. (2019) established security and trust in a decentralized vehicular environment without RSUs, by focusing on blockchain-based message distribution through short-range communication protocol. Their technique was also shown to ensure fast, secure transmission and accurate recording of the data. Jabbar et al. (2020) built the Decentralized IoT Solution for Vehicles communication (DISV) by adapting blockchain technology for real-time application (RTA).

The above approaches involve unresolved issue in terms of public blockchain schemes (Yang et al., 2019; Li et al., 2018; Singh and Kim, 2017). Insensitivity to delay requirements is a problem, for example, because the public chain has no access permission requirements - any node can participate in the consensus process (Zheng et al., 2017), resulting in block generation too slow for certain real-time reply services in vehicular networks. Privacy issues also merit concern. Data transmitted and stored publicly, does not comply with the requirements involving commercial secrets (Ali et al., 2018). General vulnerability to attacks is a noteworthy problem as well - driven by self-interest, malicious nodes can easily join the public blockchain network without permission. A consortium blockchain may be able to resolve these issues. Kang et al. (2017), for example, built a peer-to-peer (P2P) power trading system that requires no third party based on consortium blockchain technology.

Additionally, Zou et al. (2019) proposed the consensus protocol Proof-of-Trust (PoT) using a blockchain for crowdsourcing service. PoT consensus is a hybrid blockchain architecture that integrates a consortium blockchain in an open public service network. They focused on improving the consensus protocol without designing new transaction processes or crowdsourcing scenarios, such as IoV. Xiao et al. (2020) proposed a network computing framework Quick Fake News Detection (QcFND) to quickly detect fake news in IoV. QcFND used a data-centric, instead of entity-centric, trust management scheme based on Bayesian networks.

Kang et al. (2018) used edge computing and consortium blockchain for secure P2P data sharing. A reputation-based data sharing scheme with three-weight subjective logic (TWSL) was developed to select reliable data sources. However, using a PoW consensus scheme can waste resources and create “double spending” problems. The TWSL can be further improved in identifying untruthful ratings, as was one of our main goals in conducting this study. Relatively few blockchain researchers have explored theoretical modeling of the system, though, Memon et al. (2019) built a queueing theory-based model to evaluate ideal transactions statistics in Bitcoin and Ethereum. We summarize the most related works in Table 1.

Similarly, we applied the consortium blockchain to a vehicular network crowdsourcing service in this study. We utilized the fog computing paradigm to improve quality of service (QoS), and developed the RC-chain framework to meet the trust challenge. A detailed description of our framework is given below.

Refer to caption
Fig. 1: Regional consortium of VCS with RC-chain.

3 Framework description

We built the proposed RC-chain based on consortium blockchain and fog computing technology to support a trusted environment and high QoS for VCS. We added “organization” and “crowdsourcing” to the traditional vehicular network to fully utilize the infrastructure and resources.

3.1 Scenario overview

The scenario consists of the following entities: Certificate Authority (CA), organizations, blockchain, vehicles, RSUs, and fog servers (Fig. 1). Various organizations can form a regional consortium based on RC-chain. We divide the crowdsourcing services into two types here, the question and answer (Q&A) service and the data-sharing service.

The Q&A service involves a provider answering to questions proposed by the service consumer. For instance, consider a map company that needs traffic condition information for a certain road at a specific time, a weather bureau that needs to collect the precise air quality status of a park, or a traffic police authority that needs to know in real-time where traffic accidents have occurred. As potential service consumers, the vehicles within these organizations ask questions, then nearby vehicles including taxis, buses, and passenger cars can compete as service providers to answer the questions.

The data-sharing service refers to vehicles actively sharing data among various organizations. For example, a taxi service provider publishes collected data which can be utilized by other organizations (e.g., a traffic police authority) to analyze and plan holiday route changes. The weather bureau shares weather predictions which can be shared by the taxi company with their passengers. More details about this type of transaction process are introduced in Section 4.1.

RC-chain has a three-layer network architecture composed of a user stratum, fog stratum, and cloud stratum. The user stratum includes on-vehicle sensors and terminal devices which upload the collected data to the fog nodes, that is, the RSUs distributed along the road and organization-owned fog servers. As the number of transactions continues to increase, the fog nodes can upload early accounts to the cloud stratum after a certain period. Organizations can rent cloud services from suppliers based on their own needs to conduct big data analysis and large-capacity storage as necessary.

3.2 Roles of assignment

The roles and functionalities of entities are as follows.

Certificate Authority: The CA issues certificates and often held by the audit and management department. Unlike the traditional P2P trading of public blockchains, nodes without identity certificates are not permitted to participate in the transaction. Each user obtains a legal identity, then is given an initial reputation value that is constantly updated based on its service behavior (Section 5). The vehicle’s subsequent behavior after joining the consortium is reflected through the transaction records in the ledger (Lu et al., 2018).

Organizations: An organization is a collection of multiple members who generally share the same root certificate. An organization can be as large as a multi-national corporation or as small as an individual, e.g., traffic police authority, taxi company, map company, or weather bureau as shown in Fig. 1. A collection of organizations with common interest, joining to a network only by authorization, form a consortium. Nodes in the organization, such as vehicles, are the transaction objects.

Refer to caption
Fig. 2: Transaction process.

Blockchain: The Hyperledger Fabric platform of the consortium blockchain is an important component of RC-chain, which consists of three main components: peers with the ledger, orderers, and clients. Peers may be endorsing peers, committing peers, or leading peers. Each organization has its peers with copies of the ledger of their consortium network. The ledger is composed of the transactions logs of the blockchain structure and the world state, the database of the ledger, which describes the state of the ledger at a given point in time. The transactions logs record all transactions that produce the current value of the world state regardless of legality. Orderers are responsible for ordering transactions and packaging them into blocks. The client is operated by users. Every organization may contain a different number of peers, orderers, and clients. As shown in Fig. 1, the map company with two peers and one orderer initiates transactions through client A1. The peers and orderers work together to complete the consensus process; endorsing peers, orderers, and committing peers can all run independently for enhanced efficiency (Section 4.2).

Vehicles: Each vehicle belongs to one organization as a user capable of playing different roles (requester, server, idler) according to their own VCS needs. The client is deployed on vehicles. Vehicles are equipped with advanced communication devices such as On-Board Units (OBUs) which can collect data through sensors, execute simple calculation and storage operations, and communicate with nearby RSUs (Lasla et al., 2018).

RSUs: A certain number of RSUs are distributed in each area. RSUs act fog nodes that collect transaction requests and update reputation values. Orderers are deployed on RSUs to order services. The RSUs executes these processes according to agreed-upon rules specified in the smart contract, and upload the process to the ledger to be supervised by other nodes.

Fog servers: By leveraging the rich computing and storage resources of fog servers close to the edge of the network, peers deployed on fog servers within various organizations can effectively minimize latency. Transaction information is stored in the distributed ledger of the fog server for the purposes of consistency and transparency.

4 RC-chain design

In this section, the specific transaction process integrated on the RC-chain is elaborated, and it works with the three-stage consensus to achieve platform-level and service-level security.

4.1 Transaction process

All transactions are performed via chaincode. A vehicle broadcasts the request for Q&A service as shown in Fig. 2. The request proposal and following main process need verifications of three-stage consensus to proceed. Then they are recorded in the ledger as evidence of transactions. Any vehicle willing to answer the question can send a service request to the nearest RSU, which selects the server according to TPFS model. After the service is finished, the requester evaluates the service, then the reputation value of the corresponding server is updated. The data-sharing service only requires the server to upload the shared data index. The requester selects the data of interest according to the index, then establishes communication with the server to obtain integral data, other processes are similar to the Q&A service.

Step 1: All participants joining in the consortium should be authenticated in the CA by binding their registration information (e.g., vehicle license plate). CA issues public keys, private keys, transaction certificates, and identity certificates to legal entities via an elliptic curve digital signature algorithm and asymmetric cryptography. The initial reputation value of entities is generally 0.5.

Step 2: The requester broadcasts the request to the other vehicles and nearest RSU (the “leading” RSU), which communicates with other (“following”) RSUs in the same area to keep in sync. The following RSU passes the request to vehicles in its vicinity. The requester sends the request transaction proposal to endorsing peers in the fog servers of organizations to execute consensus. Endorsing peers are chosen by the endorsement policy in chaincode, which defines organizations that need to endorse the proposal to be accepted by the ledger. This is the literal definition of “consensus” – every organization involved must endorse a proposed ledger before it can be accepted by any peer of any organization. Vehicles must reach consensus before a transaction proposal can be completed. After the proposal passes the three stages of endorsement (Step 2.1), ordering (Step 2.2), and commitment (Step 2.3), it is considered to be a legal transaction and the ledger can be updated accordingly (Section 4.2).

Step 3: The service-intentioned vehicle submits a service-request to the nearest RSU.

Step 4: The leading RSU and following RSUs select one service candidate based on the TPFS model (Section 5). The following RSUs send the service candidates to the leading RSU, who selects the final server at random. The final server sends a service proposal with the RSU’s signature to the ledger.

Step 5: The requester establishes communication with the server, then the server sends the service-process proposal to the ledger as a proof of transaction.

Step 6: After the service is completed, the requester gives the leading RSU feedback (e.g., rating, timeliness report) about the server.

Step 7: The RSUs update the reputation value of the servers according to the TPFS model and send a reputation-update proposal to the ledger. In this way, the reputation value can be traced through the transaction records of the block.

4.2 Three-stage consensus

In the blockchain, “consensus” is an agreement on the order and status of multiple transactions generated within a certain period. The transaction is packaged into blocks according to certain rules to ensure that the ledger owned by the distributed nodes retains a stable state. It is possible that not all nodes run in an ideal state however, so a current consensus algorithm of the blockchain system is very challenging to establish. For example, this probabilistic consensus algorithm PoW causes not only a waste of resources but also “double spending” problems possibly. The PoS is susceptible to collusion attacks by malicious nodes. The Practical Byzantine Fault Tolerance (PBFT) cannot prevent sybil attacks, that is, where malicious users exploit multiple IDs to participate in erroneous consensus behavior. The pursuit of security can cause problems such as long delays and poor scalability.

Fortunately, the consensus of the Hyperledger Fabric is not susceptible to double spending. The three-stage consensus can effectively ensure security. It is the consensus of the whole process based on staged consensus, that is, the failure of any stage will lead to failure in the end. The separation between endorsement and ordering lends performance and scalability advantages, while the use of fog computing technology accelerates the processing time.

The transaction proposal discussed in Section  4.1 can only be written into the ledger after the endorsement, ordering, and commitment steps (2.1-2.3 in Fig. 2) of consensus are all complete. As shown in Fig. 3, there are two types of nodes participating in the consensus process. Peers are mainly used for endorsement and commitment and are divided into endorsing peers, leading peers, and committing peers categories while orderers are used for ordering.

Refer to caption
Fig. 3: Three-stage consensus.

Endorsement stage: The vehicles exploit the client to send the transaction proposal to the designated endorsing peers on fog servers of related organizations. The endorsing peers comprise a small portion of the total peers and are dynamically designated by the endorsement policy. Compared to situations wherein all nodes participate in the endorsement process, this markedly improves efficiency. Upon receiving a transaction proposal, the endorsing peers simulate execution of the transaction process per the chaincode, and record results, but the status of the ledger is not yet updated, The endorsing peers of various organizations then return the transaction proposal response with signatures to the client.

Ordering stage: After receiving sufficient endorsement, the client sends the endorsed transaction proposal to the orderers on RSUs. An orderer does not read the transaction content, but only orders the received transactions using the Kafka algorithm in real time, then packs them into blocks and sends them to the leading peer.

Commitment stage: The most basic function of peers is commitment. The leading peer in each organization synchronizes the received block to other committing peers. The committing peers verify the validity of transactions in the block, including the transaction structure, signature integrity, whether it is repeated, and whether the read and write collection versions match. (This step may contain a double spending transaction, which is considered invalid.) After verification, the transaction is written to the updated ledger.

The three-stage consensus performs well in fault tolerance. In the endorsement stage, the clients learn the current transaction status through feedback from the endorsing peers. The Kafka algorithm in the ordering stage supports Crash Fault-Tolerance (CFT), the downtime of a few orderers does not affect the generation of blocks. If a committing peer fails to synchronize a block due to communication failures, etc., it can pull the block from other committing peers to maintain ledger consistency. If transactions (e.g., the update of reputation value) can not be completed due to the consensus failure or network breakdown, they are not updated in the ledger, but recorded in the transactions logs for audit.

Due to the mobility of the vehicle, the client may have diconnection problem. In the endorsement stage, if client does not receive sufficient endorsement signatures, there are two possible cases:

Case 1. The client did not send the transaction proposal to sufficient endorsing peers for endorsement.

Case 2. Execution timeout of endorsement peers and no response.

For the Case 1 the client can propose the transaction again. Though Case 2 rarely occurs, we take it into account. The risk of disconnection can be reduced by setting in the endorsement policy. For instance, 1) increase the number of endorsing peers; 2) allow for passing the verification with fewer signatures; 3) select more backup nodes in client’s vicinity, etc. Even though they are all disconnected, repeat the submission.

The three-stage consensus process thus achieves BFT.

5 Reputation model

Our optimized reputation model is introduced in this section. Many researchers have established reputation value management models. For users who have joined the consortium, it is necessary to improve QoS in order to identify their possible selfish behavior, further help to choose higher-quality services. In addition, reputation can also be used as an incentive to encourage participants to take part in the interaction through reputation-based methods. Those users who contribute more reliable services will get more service opportunities and rewards. Kang et al. (2018) took interaction frequency, event timeliness, trajectory similarity, and recommended opinions into account. Subjective logic is utilized to formulate the individual reputation evaluation based on occurring interactions, which is a framework for probabilistic information fusion operated on subjective beliefs about the world. Based on the TWSL (Kang et al., 2018), we improved the recommended opinions factor as the so-called trust propagation (TP). Inspired by (Liu et al., 2016), we applied feedback similarity (FS) for the reputation model. As mentioned in Section 4, the TPFS model (which encompasses both TP and FS factors) is integrated into the chaincode to update the reputation values. We analyzed the TPFS model and compared it against the TWSL model as discussed in detail below.

5.1 Trust propagation

When the number of vehicles is very sparse in the vehicular network, most have not established interactions and thus it is difficult to find a suitable vehicle to send an inquiry request. The recommendations of other vehicles can be considered here, namely, TP. If ii has a reputation value to jj and jj has a reputation value to ff, then ii can calculate the reputation value to ff through jj. TWSL synthesizes the general opinions of all vehicles on ff, but does not consider any situation wherein vehicles with lower reputation values make incorrect recommendations. Here, we do take this into consideration to distinguish between reliable and unreliable opinions.

We set two thresholds Tl,Th{T}_{l},{T_{h}} for the reputation value, and deem the recommendation of neighbors with reputation values lower than Tl{T}_{l} to be unreliable while those of vehicles with recommendation values higher than Th{T}_{h} are reliable. We define the recommended confidence of vehicle ii to jj as:

Cij=(0,Rij<Tl0.8,Tl<Rij<Th1,Rij>Th{{{C}}_{i\to j}}{{=}}\left(\begin{array}[]{l}0,\qquad{{{R}}_{i\to j}}<{T_{l}}\\ 0.8,\quad{{{T}}_{l}}<{R_{i\to j}}<{T_{h}}\\ 1,\qquad{{{R}}_{i\to j}}>{T_{h}}\end{array}\right. (1)

where Rij{{R}}_{i\to j} is the reputation value of neighbor vehicle ii to vehicle jj.

The recommendation of vehicle jj can be divided into positive and negative opinions. For a positive opinion, the reputation value Rjf{R_{j\to f}} of neighbor vehicle jj to vehicle ff is greater than reputation threshold Tl{T}_{l}. For a negative opinion, the reputation value is Rjf{R_{j\to f}} less than the reputation threshold Tl{T}_{l}. The number of positive and negative recommendations is aa and bb respectively. The weighted aggregation of positive opinions is:

Pif=j=1aCijRijRjfa{P_{i\to f}}=\frac{{\sum\limits_{j=1}^{a}{{C_{i\to j}}\cdot}{R_{i\to j}}\cdot{R_{j\to f}}}}{a} (2)

and the weighted aggregation of negative opinions is:

Nif=j=1bCijRijRjfb{N_{i\to f}}=\frac{{\sum\limits_{j=1}^{b}{{C_{i\to j}}\cdot}{R_{i\to j}}\cdot{R_{j\to f}}}}{b} (3)

Based on the number of positive opinions and negative opinions, we can separately find their weights to find an indirect reputation value. The weights of positive and negative opinions are defined by Eq. (4) and Eq. (5), respectively.

c=aa+bc=\frac{a}{{a+b}} (4)
d=ba+bd=\frac{b}{{a+b}} (5)

The indirect reputation value of vehicle ii to vehicle ff is:

Rinif=cPifdNif{{Ri}}{{{n}}_{i\to f}}={c}\cdot{P_{i\to f}}-d\cdot{N_{i\to f}} (6)

5.2 Feedback similarity

The TWSL model assumes that all vehicles provide honest ratings of other vehicles, but this assumption makes it difficult to identify malicious vehicles. Since a malicious vehicle may not only send fake messages but may also create malicious, inaccurate ratings. “Pretending-type” (P-type) malicious vehicles may send real messages before beginning to emit fake messages. Two honest (or malicious) vehicles are likely to be given similar ratings by the same group of vehicles that have interacted with them, but this is unlikely to be the case for an honest vehicle versus a malicious vehicle.

Here, we use the same group of vehicles Com(i,j)Com(i,j) (e.g., vehicle qq) to indicate that have interacted with both vehicles ii and jj, and calculate the feedback similarity of vehicle ii and vehicle jj, thereby distinguishing P-type malicious vehicles from others. If the similarity of the feedback ratings of vehicle ii and vehicle jj is high, then vehicle jj has a high reputation value to vehicle ii. The feedback formula of the overall rating of vehicle ii to qq is as follows (and is also applicable to the feedback of vehicle jj to qq):

F(i,q)=f1αf2βα+βF(i,q)=\frac{{{f_{1}}\cdot\alpha-{f_{2}}\cdot\beta}}{{\alpha+\beta}} (7)

where α,β\alpha,\beta are the number of positive ratings and negative ratings and their weights are f1,f2{f_{1}},{f_{2}} respectively, as shown in Eq. (8) and Eq. (9).

f1=αα+β{f_{1}}=\frac{\alpha}{{\alpha+\beta}} (8)
f2=βα+β{f_{2}}=\frac{\beta}{{\alpha+\beta}} (9)

We used the Weighted Euclidean Distance (WED) method to calculate the feedback similarity of vehicles. We determined a dispersion value based on the historical rating feedback of vehicle ii and vehicle jj; smaller dispersion indicates greater similarity. The similarity of vehicle ii and vehicle jj based on feedback is defined as (Liu et al., 2016):

simf(i,j)=\displaystyle simf(i,j)= (10)
1qCom(i,j)Q(i,j,q)(F(i,q)F(j,q))2\displaystyle 1-\sqrt{\sum\nolimits_{q\in Com(i,j)}{Q(i,j,q)\cdot{{(F(i,q)-F(j,q))}^{2}}}}

where Q(i,j,q)Q(i,j,q) represents the normalized weight of the influence of vehicle qq on the similarity, and its standard deviation is Q(i,j,q)Q^{\prime}(i,j,q). The equations above were provided by (Liu et al., 2016).

WED can be used to assign different weights to amplify the different ratings of vehicles ii and jj for the same group of participants. We utilized the exponential function of feedback similarity to define the local reputation confidence rij{r_{i\to j}} (Eq. (11)), thereby preventing P-type vehicles accumulate deliberately high reputation values from certain honest vehicles. If there is no common interactive vehicle, the local reputation value weight is θ\theta \in [0, 1].

rij=𝑒(11/simf(i,j)){r_{i\to j}}=\mathop{e}\nolimits^{(1-1/simf(i,j))} (11)

When the feedback similarity of the vehicle is high, rij{r_{i\to j}} is also high (and vice versa).

5.3 Final reputation value

The final reputation value Rfinif{{Rfi}}{{{n}}_{i\to f}} can be divided into the following situations:

  1. 1.

    Vehicle ii and vehicle ff have never interacted and have no recommendations. The initial local reputation value from ii to ff is γ\gamma \in [0, 1] and the final reputation value is:

    Rfinif=rifγ{{Rfi}}{{{n}}_{i\to f}}={{{r}}_{i\to f}}\cdot\gamma (12)
  2. 2.

    Vehicle ii and vehicle ff have not established interactions before, but neighbor vehicles jj has a recommendation to ff. The local reputation value is η\eta \in [0, 1] and the final reputation value of ii to ff is:

    Rfinif=rifη+(1rif)Rinif{{Rfi}}{{{n}}_{i\to f}}={{{r}}_{i\to f}}\cdot\eta+{(1-}{{{r}}_{i\to f}})\cdot Ri{n_{i\to f}} (13)

    where RinifRi{n_{i\to f}} is given by Eq. (2), Eq. (3) and
    Eq. (6).

  3. 3.

    Vehicle ii has established interaction with vehicle ff, but no neighboring vehicle has a recommendation to ff. The final reputation value of ii to ff is:

    Rfinif=rifRif{{Rfi}}{{{n}}_{i\to f}}={{{r}}_{i\to f}}\cdot{R_{i\to f}} (14)
  4. 4.

    Vehicle ii has established interaction with vehicle ff, and the neighboring vehicle has a recommendation to ff and the final reputation value of ii to ff is:

    Rfinif=rifRif+(1rif)RinifRfi{n_{i\to f}}={r_{i\to f}}\cdot{R_{i\to f}}+(1-{r_{i\to f}})\cdot Ri{n_{i\to f}} (15)
Refer to caption
(a) Reputation management.
Refer to caption
(b) Fair server selection.
Fig. 4: Fairness mechanism of TPFS.

It is worth mentioning that in the process of updating the reputation value based on the chaincode, and the reputation value can be traced through the transaction records of the block. In addition, if the reputation value of a server is lower than the suggested service threshold TkT_{k}, it is marked to remind the requester to proceed with caution. If a server’s reputation value is lower than the allowable threshold TmT_{m}, its identity certificate is revoked – the consortium removes it and does not permit it again in the future. A flowchart of reputation management processes is given in Fig. 4(a). We also divided the intentioned servers into two groups, one new and one old, based on the historical number of trading threshold TnT_{n} to enhance the fairness of the server selection process. This provides service opportunities for vehicles newly joining the consortium.

RSU generates a random number RR to compare with the value of QQ\in [0, 1], which is a threshold specified by chaincode. Fig. 4(b) shows the detailed flowchart of the server selection. There may also be all intentioned servers whose reputation value is relatively low. In this case, servers are selected randomly. (Of course, this is rare.)

5.4 TPFS model evaluation

We conducted a series of experiments through Matlab to evaluate the performance of TPFS and to compare it against TWSL. Parameters in the experiment included γ\gamma=0.2, η\eta=0.2, and θ\theta=0.7 (Section 5.3).

Firstly, we analyzed the changes in reputation values over time based on different models as vehicles interact. Most services in the IoV have timeliness requirements. We considered segmented interactions in different situations to determine whether the reputation value can be updated in time. Kang et al. (2018) set the reputation value update time to 1 minute in their work; similarly, we assumed in this experiment that vehicle ii and vehicle jj interact once per minute for a total of 100 interactions with 100 minutes. Vehicle jj sends real messages in [0, 50] minutes and sends fake messages in [51, 80] minutes. Negative ratings have a greater impact on vehicle reputation than positive ratings, so the reputation declines rapidly in the latter half of this process. In [81, 100] minutes, vehicle ii and vehicle jj do not interact.

Refer to caption
Fig. 5: Reputation changes of vehicles over time.

At this time, the impact of previous ratings on vehicle reputation value gradually decreases while the influence of neighbor vehicle recommendation gradually increases. Fig. 5 shows the change in the reputation value of the vehicle ii to jj over time. Because TP considers recommendations from malicious vehicles, the reputation value it obtains is lower than that obtained by TWSL.

Refer to caption
Fig. 6: Relationship between percentage of truthful neighbor vehicles and the vehicle reputation value.

We also analyzed the impact of trusted neighbor recommendations on reputation. We set a total of 30 neighboring vehicles. In the case of no interaction between vehicle ii and vehicle jj, the reputation value of vehicle ii to vehicle jj originates entirely from “trust propagation”, that is, the recommendations of other neighbor vehicles. Fig. 6 shows the relationship between the percentage of truthful neighbor vehicles to all neighbor vehicles and the reputation of vehicle ii to jj. The reputation value of vehicle ii to vehicle jj, obtained by TP, is lower when there are fewer trusted vehicles providing recommendations. This is because TWSL ignores the fact that malicious vehicles may lead to malicious recommendations. TP first evaluates the credibility of the recommended vehicle and can reject any unreliable recommendation provided by a malicious vehicle.

Refer to caption
Fig. 7: Reputation value distribution of all vehicles with
P-type.

It is also important to consider that malicious vehicles may have unstable behavior. For the next experiment, we set 15 distributed vehicles as servers randomly. As shown in Fig. 7, No. 1 is a malicious vehicle that sends numerous real messages to confuse vehicle ii. It attempts to conduct malicious attacks after gaining a high reputation value. After 100 interactions, we obtained the reputation value of 15 vehicles as shown in Fig. 7. The reputation values calculated based on TWSL and TP are higher than those obtained by TPFS, because TPFS reduces its reputation value by identifying the malicious vehicle.

6 Performance evaluation

We next attempted to optimize the proposed RC-chain configuration, by applying queueing theory to quantitatively evaluate the impact of transaction arrival rate and batch size (i. e., maximum number of transactions in a block) on transaction confirmation time.

6.1 Queue model of RC-chain

We designed a queueing system with three different service stages, that express the three-stage consensus process and the building of a new block. By analyzing the queueing model, we obtained three key performance measures: 1) the average number of transactions in system; 2) the average transaction confirmation time, and 3) the average transaction throughput.

The notations used in this section, which are related to the RC-chain consensus mechanism (Section  4), are summarized in Table 2. A diagram of the model is given in Fig. 8.

Refer to caption
Fig. 8: Queueing network model.

We constructed a three-node open queueing network (Hayes and Babu, 2004). The endorsement stage is node 0, the ordering stage is node 1, and the commitment stage is node 2. Assuming that the transaction arrival from clients is a Poisson process, the arrival rate can be denoted as λ0\lambda_{0} and the external arrival to each node is represented by the vector 𝝀\boldsymbol{\lambda} = [λ0\lambda_{0}, 0, 0].

Table 2
Notaions
Symbols Meanings
qjiq_{ji}
-probability of a transaction being
routed from node jj to node ii
λi\lambda_{i} -arrival rate of transactions to node ii
Λi\Lambda_{i} -total transactions arrival rate to node ii
μi\mu_{i} -service rate of transactions to node ii
RiR_{i} -service intensity of node ii
P(ki)P(k_{i})
-probability that there are kik_{i}
transactions in node ii
P(k0,k1,k2)P(k_{0},k_{1},k_{2})
-state probability that there
are k0k_{0}, k1k_{1}, k2k_{2} transactions in
node 0, 1, 2, respectively
N¯i\bar{N}_{i}
-average number of transactions
in node ii
D¯i\bar{D}_{{i}}
-average delay of a transaction
through node ii
D¯\bar{D}
-average transaction confirmation time
HH
-average transaction throughout
MM
-batch size (i. e., maximum number of
transactions in a block)

In RC-chain, the transactions that do not meet the endorsement policy or fail the verification are not be updated to the ledger. Such invalid transactions are considered to be leaving the queueing network. The probability that a transaction is routed from node jj to node ii is given by qjiq_{ji}. The probabilistic routing matrix is:

Q=[0q010001000]Q=\begin{bmatrix}0&q_{01}&0\\ 0&0&1\\ 0&0&0\end{bmatrix} (16)

The total traffic into each node of the the network is:

Λi=λi+j=02qjiΛji=0,1,2{\Lambda_{i}}={\lambda_{i}}+\sum\limits_{j=0}^{2}{{q_{ji}}}\cdot{\Lambda_{j}}\quad i=0,1,2 (17)

As per the probabilistic routing matrix QQ and the external arrival 𝝀\boldsymbol{\lambda},

Λ0=λ0Λ1=Λ2=q01λ0\begin{split}{\Lambda_{0}}&={\lambda_{0}}\\ {\Lambda_{1}}&={\Lambda_{2}}={q_{01}}\cdot{\lambda_{0}}\end{split} (18)

Assuming that each node in queueing network has unlimited storage space, and the transaction service time in each node is exponentially distributed with average rate μi\mu_{i}, ii = 0, 1, 2.

At any consensus stage in the RC-chain, multiple servers serve the same transaction independently and simultaneously. For example, in the endorsement stage, multiple endorsing peers simultaneously validate the same transaction proposals. Therefore, we assume that there is one server at each node in the queueing network.

In Hyperledger Fabric, there are two conditions for orderers to perform block packaging: the number of transactions waiting packaged reaches the batch size, or these transaction waiting time reaches maximum elapsed duration (i.e., batch timeout). When either condition is met, the orderers immediately package the transactions into blocks. Here, we take the first condition as the model setting and let MM denote the batch size. Because the transaction arrival rate to the ordering stage is Λ1=q01λ0\Lambda_{1}=q_{01}\cdot\lambda_{0}, the average arrival time interval for a transaction is 1/Λ11/\Lambda_{1}. For MM transactions, the time to wait for packaging after the transaction arrives is (0, M/Λ1M/\Lambda_{1}). The service rate of the orderers is given by

μ1=2Λ1/M{\mu_{1}}=2{\Lambda_{1}}/M (19)

where the service rate of the committing peer is assumed to be equal to that of the endorsing peers.

Let Q1Q1, Q2Q2, and Q3Q3 denote the queue length in node 0, 1, and 2 in the steady state, respectively. At this point, the model is identical to the 3-node open Jackson network. The state of the system is defined by the number of transactions in each of the nodes: k0k_{0}, k1k_{1}, k2k_{2}. By strictly applying the derivation given by (Hayes and Babu, 2004), we have

P(Q0=k0,Q1=k1,Q2=k2)=\displaystyle P(Q_{0}={k_{0}},Q_{1}={k_{1}},Q_{2}={k_{2}})= (20)
P(k0,k1,k2)=i=02(1Ri)Riki\displaystyle P({k_{0}},{k_{1}},{k_{2}})=\prod\limits_{i=0}^{2}{(1-{R_{i}}){R_{i}}^{{k_{i}}}}

where

Ri=Λi/μi{R_{{i}}}={\Lambda_{i}}/{\mu_{i}} (21)

represents the service intensity of each node. The steady state condition of the system is Ri/Si=Ri<1{R_{{i}}}/{S_{i}}={R_{i}}<1

According to Eq. (18) and Eq. (21),

R0=λ0/μ0R1=q01λ0/μ1R2=q01λ0/μ2\begin{split}{R_{0}}&={{{\lambda_{0}}}\mathord{\left/{\vphantom{{{\lambda_{0}}}{{\mu_{0}}}}}\right.\kern-1.2pt}{{\mu_{0}}}}\\ {R_{1}}&={{{q_{01}}\cdot{\lambda_{0}}}\mathord{\left/{\vphantom{{{q_{01}}\cdot{\lambda_{0}}}{{\mu_{1}}}}}\right.\kern-1.2pt}{{\mu_{1}}}}\\ {R_{2}}&={{{q_{01}}\cdot{\lambda_{0}}}\mathord{\left/{\vphantom{{{q_{01}}\cdot{\lambda_{0}}}{{\mu_{2}}}}}\right.\kern-1.2pt}{{\mu_{2}}}}\end{split} (22)

According to Law of Total Probability, the state equation of each node is:

P(Q0)=P(k0)=k2=0k1=0P(k0,k1,k2)=(1R0)R0k0P(Q_{0})=P({k_{0}})=\sum\limits_{{k_{2}}=0}^{\infty}{\sum\limits_{{k_{1}}=0}^{\infty}{P({k_{0}},{k_{1}},{k_{2}})}}=(1-{R_{0}}){R_{0}}^{{k_{0}}} (23)
P(Q1)=P(k1)=k2=0k0=0P(k0,k1,k2)=(1R1)R1k1P(Q_{1})=P({k_{1}})=\sum\limits_{{k_{2}}=0}^{\infty}{\sum\limits_{{k_{0}}=0}^{\infty}{P({k_{0}},{k_{1}},{k_{2}})}}=(1-{R_{1}}){R_{1}}^{{k_{1}}} (24)
P(Q2)=P(k2)=k1=0k0=0P(k0,k1,k2)=(1R2)R2k2P(Q_{2})=P({k_{2}})=\sum\limits_{{k_{1}}=0}^{\infty}\\ {\sum\limits_{{k_{0}}=0}^{\infty}{P({k_{0}},{k_{1}},{k_{2}})=(1-{R_{2}}){R_{2}}^{{k_{2}}}}} (25)

This system satisfies Jackson’s theorem. The average number of transactions in each node is:

N¯i=ki=0kiP(ki)=Ri(1Ri)i=0,1,2{\bar{N}_{i}}=\sum\limits_{{k_{i}}=0}^{\infty}{{k_{i}}P({k_{i}})}=\frac{{{R_{i}}}}{{(1-{R_{i}})}}\quad{i}=0,1,2 (26)

The average number of transactions in system is:

N¯=k0,k1,k2=0(k0+k1+k2)P(k0,k1,k2)=\displaystyle\bar{N}=\sum\limits_{{k_{0}},{k_{1}},{k_{2}}=0}^{\infty}{({k_{0}}+{k_{1}}+{k_{2}})}P({k_{0}},{k_{1}},{k_{2}})= (27)
R0(1R0)+R1(1R1)+R2(1R2)\displaystyle\frac{{{R_{0}}}}{{(1-{R_{0}})}}+\frac{{{R_{1}}}}{{(1-{R_{1}})}}+\frac{{{R_{2}}}}{{(1-{R_{2}})}}

As per Little’s theorem, the average delay of a transaction through node ii is:

D¯i=N¯iΛi=Ri(1Ri)Λi{\bar{D}_{{i}}}=\frac{{{{{{\bar{N}}}}_{{i}}}}}{{{{\Lambda}_{{i}}}}}=\frac{{{R_{{i}}}}}{{(1-{R_{i}})\cdot{\Lambda_{i}}}} (28)

Let D¯\bar{D} denote the average transaction confirmation time, the time interval from the arrival time point of a transaction to its departure. Be noted that the transaction confirmation time here is calculated from the arrival endorsement stage of the transaction, and the time from the client to the endorsement peers is ignored for simplicity of analysis. Then,

D¯=i=02D¯i\bar{D}=\sum\limits_{{{i}}=0}^{2}{{{\bar{D}}_{i}}} (29)

The average transaction throughput HH is defined as the rate at which verified transactions are committed by the blockchain across the entire network, that is, the number of transactions that are updated in the ledger per unit time. HH is given by

H=N¯2q23D¯=R2q23(1R2)D¯H=\frac{{{{\bar{N}}_{2}}\cdot{q_{23}}}}{{\bar{D}}}=\frac{{{R_{2}}\cdot{q_{23}}}}{{(1-{R_{2}})\cdot\bar{D}}} (30)

6.2 Numerical analysis

Transaction confirmation time is a key factor for evaluation blockchain-based VCS platform, and the trust information dissemination in vehicular network is time-sensitive. Therefore, we discuss the time performance in transaction confirmation.

Through the numerical calculation on Matlab, we analyze with average transaction confirmation time and average transaction delay at orderer of RC-chain. The results show that the performance of RC-chain based Hyperledger Fabric occupies a clear advantage.

We take some common parameters: transaction arrival rate λ0\lambda_{0}\in [10, 110], batch size MM=10, 50, 100, q01q_{01}=0.9, q23q_{23}=0.95. The service rate of both the endorsing peers and the committing peers are 150.

Refer to caption
Fig. 9: The average delay of transaction at orderers.
Refer to caption
Fig. 10: The average transaction confirmation time.

It should be noted that the ordering stage has a great impact on the efficiency of block generation. Fig. 9 shows the relationship between average transaction delay at orderer and the transaction arrival rate. It can be seen, as the transaction arrival rate increases, the average delay of the transaction at orderer gradually increases. When the arrival rate increases to 40, the value converge smoothly. The change of average transaction confirmation time with arrival rate has the same trend, as shown in Fig. 10. In addition, the smaller the batch size, that is, the higher the service rate of orderers, the shorter the average transaction delay at orderer, and so does the average transaction confirmation time. Take Fig. 10 as an example, when MM is 100, the average delay is about 500 microseconds higher than MM is 10, and about 108 microseconds higher than MM is 50, which provides an effective basis for the next experiment deployment.

7 Experiment results

We next analyzed the safety and trust goals that are achievable by RC-chain. We constructed a VCS network, wrote smart contract, and implemented RC-chain using the configuration determined by the above model parameters. The running results were compared with the theoretical results of the queueing model and an existing similar scheme.

Table 3
Transaction confirmation time comparison
block No. 1 2 3 4 5 6 7 8 9 10
arrival rate(Tx/sec) 37.29 34.09 32.91 37.95 37.20 36.12 37.66 37.33 39.39 36.95
theoretical value(sec) 0.299 0.296 0.256 0.299 0.298 0.297 0.299 0.299 0.300 0.298
actual value(sec) 0.303 0.306 0.312 0.302 0.315 0.309 0.305 0.304 0.303 0.311
deviation(sec) 0.004 0.010 0.056 0.003 0.017 0.012 0.006 0.005 0.003 0.013
Refer to caption
Fig. 11: RC-chain implementation.

7.1 Safe and trust gaols

The RC-chain design combined with the consortium blockchain Hyperledger Fabric platform can achieve the following security goals.

Distributed solution: RC-chain is a distributed VCS solution. It does not rely on a unified manager during the transaction process. It is difficult for an attacker to target all nodes in the network, which enhances its fairness and security while reducing the possibility of the entire network being threatened by a single point attack.

Permissioned identity: The CA utilizes an elliptic curve digital signature algorithm to generate keys and certificates for the entity. The identity information is bound to its registration information and the physical address of the device, which uniquely identify this entity. Entities with malicious historical behavior have a low reputation value and cannot forge identities to join the network.

Privacy protection: The channel mechanism provides transaction privacy and confidentiality for a specific subset of network members. All data on the channel, including transactions, members, and channel information, is invisible to members outside the channel, which preserves privacy.

Reliable reputation value management–TPFS model: The legal identity represents the historical behavior of the entity. Its reputation value is updated timely based on current behavior. By degrading the reputation value of those service participants with untruthful behavior, adversarial or irresponsible behavior can be prevented.

Transparent transaction process: Participants, be they requesters, servers, or the RSU, upload the main steps of the transaction to the ledger. Nodes with copies of the ledger in the same channel can review and supervise others. If the node is malicious, it is easy to be found and held accountable. An entity with malicious behavior risks being forced out of the network due to a dropped reputation value. Thus, RC-chain can effectively prevent malicious behavior.

Three-stage consensus to achieve BFT: The transaction can only move into the subsequent consensus stage after sufficient endorsement signatures have been gathered in the endorsement stage. Illegal transactions cannot secure this sufficient quantity of endorsement signatures, thereby reducing attacks on the network. CFT is achieved via the second-stage Kafka-based ordering service. The final step is the verification process, which eliminates any double spending phenomenon and reviews transactions again. RC-chain implements BFT via this three-stage consensus.

7.2 RC-chain implementation

By using the Hyperledger Fabric running on Linux, we conducted another RC-chain experiment based on the results obtained from the above queueing theory model. We deployed RC-chain on a machine with Intel(R) Core(TM) i5-6300HQ CPU @ 2.30GHz and 6GB RAM running Ubuntu 18.04.4 LTS. The VCS network we built for this purpose contains three organizations, each one consisting of two peers and one orderer. The chaincode was written in GO language with the main functions of user registration, information query, data index acquisition, broadcast message, reputation value update, and server selection. According to the conclusion presented in Section 6.2, we set batch size MM to 10, with 3 clients submitting transactions randomly in parallel at an average arrival rate of 40. As shown in Fig. 11, we randomly selected trading within 52 minutes and observed it through Hyperledger Explorer. A total of 99784 transactions and 9983 blocks were generated during this period with an average throughput of 32 Tx/s. The throughput reached a maximum of 50 Tx/s and the system was operating in a stable state.

We randomly selected 10 consecutive blocks, calculated and analyzed the actual transaction confirmation time in Hyperledger Fabric, and compared it with the theoretical transaction confirmation time obtained by the queueing model. The results are shown in Table 3. Because the queueing model does not consider propagation delay or other certain factors, the theoretical value is smaller than the actual value on average; however, the average deviation is between them is small enough to consider our scheme realistic and feasible.

We also compared the transaction confirmation time with the framework QcFND in IoV-based Fabric (Xiao et al., 2020). We selected 30 blocks. Similar to the QcFND scheme, we selected five committing peers and calculated the average transaction confirmation time on five nodes with a batch size of 10 and batch timeout of 2s, with negligible time from clients to the endorsing peers. The average transaction confirmation time of 30 blocks was 0.312s in this case and the average transaction confirmation time of 52 minutes period was 0.315s, so we were able to consider the partial representing approximately the whole. As shown in Fig. 12, the average transaction time of the QcFND scheme was 2.194s and the average transaction time of RC-chain was 0.315s in this test; the transaction confirmation time of each of the 30 blocks is also shown in the figure.

Refer to caption
Fig. 12: Transaction confirmation time of RC-chain and
 QcFND.

As mentioned in Section  4.2, the public blockchain restricts the transaction throughput due to its consensus mechanism (and other factors), which makes the transaction confirmation time longer. The block generation time for Bitcoin is 600s and the throughput is (1048576/500)/600 \approx 3.5 Tx/s. The average block time of Ethereum is 14.096s and the throughput is 71.428/14.096 \approx 6.6 Tx/s, the number of their miners are 2200 and 100 respectively (Memon et al., 2019). Most IoV services require low latency, and the throughput of RC-chain with 6 endorsing peers is 32 Tx/s – in other words, our results suggest that the RC-chain based consortium blockchain has distinct advantages compared other public blockchain schemes.

8 Conclusion

This paper proposed a novel RC-chain designed for constructing reliable VCS platform. We find that RC-chain efficiently leverages the resources of vehicular networks, provides transactions security, and enhances QoS over existing schemes. RC-chain has no third-party credit intermediaries; it realizes intelligent automatic transactions and stores trusted distributed ledgers according to predetermined rules based on smart contract. More importantly, RC-chain implements interconnection between organizations with shared interests, and achieves the transmission and accumulation of trust among VCS participants.

We conducted a comprehensive set of experiments to find that RC-chain can be effectively applied, allows for swift transaction processing, and increases the throughput with lower execution cost compared to other schemes while satisfying trust constraints. Our numerical analysis also shows that the optimized TPFS model has favorable reputation updating effects over TWSL.

Acknowledgments

This research was supported by Opening Fund of Shandong Provincial Key Laboratory of Network based Intelligent Computing, National Natural Science Foundation of China under Grants No. 61802217, Natural Science Foundation of Shandong Province under Grants No. ZR201910280170, Project of Independent Cultivated Innovation Team of Jinan City under Grant No. 2018GXRC002, Project of Shandong Province Higher Educational Youth Innovation Science and Technology Program under Grant No. 2019KJN028.

References

  • Ali et al. (2018) Ali, M.S., Vecchio, M., Pincheira, M., Dolui, K., Antonelli, F., Rehmani, M.H., 2018. Applications of blockchains in the internet of things: A comprehensive survey. IEEE Communications Surveys & Tutorials 21, 1676–1717. Doi:\colorblue 10.1109/COMST.2018.2886932.
  • Awais Hassan et al. (2019) Awais Hassan, M., Habiba, U., Ghani, U., Shoaib, M., 2019. A secure message-passing framework for inter-vehicular communication using blockchain. International Journal of Distributed Sensor Networks 15. Doi:\colorblue 10.1177/1550147719829677.
  • Chen et al. (in press) Chen, X., Ding, J., Lu, Z., in press. A decentralized trust management system for intelligent transportation environments. Transactions on Intelligent Transportation Systems Doi:\colorblue 10.1109/TITS.2020.3013279.
  • Chen and Wang (2017) Chen, X., Wang, L., 2017. A cloud-based trust management framework for vehicular social networks. IEEE Access 5, 2967–2980. Doi:\colorblue 10.1109/ACCESS.2017.2670024.
  • Greenberg et al. (2009) Greenberg, A., Hamilton, J., Maltz, D.A., Patel, P., 2009. The cost of a cloud: Research problems in data center networks. Doi:\colorblue 10.1145/1496091.1496103.
  • Haddadou et al. (2014) Haddadou, N., Rachedi, A., Ghamri-Doudane, Y., 2014. A job market signaling scheme for incentive and trust management in vehicular ad hoc networks. IEEE transactions on vehicular technology 64, 3657–3674. Doi:\colorblue 10.1109/TVT.2014.2360883.
  • Hayes and Babu (2004) Hayes, J.F., Babu, T.V.G., 2004. Modeling and Analysis of Telecommunications Networks. John Wiley & Sons.
  • Howe (2006) Howe, J., 2006. The rise of crowdsourcing. Wired magazine 14, 1–4.
  • Huang et al. (2020) Huang, X., Ye, D., Yu, R., Shu, L., 2020. Securing parked vehicle assisted fog computing with blockchain and optimal smart contract design. CAA Journal of Automatica Sinica 7, 426–441. Doi:\colorblue 10.1109/JAS.2020.1003039.
  • Jabbar et al. (2020) Jabbar, R., Kharbeche, M., Al-Khalifa, K., Krichen, M., Barkaoui, K., 2020. Blockchain for the internet of vehicles: a decentralized iot solution for vehicles communication using ethereum. Sensors 20, 3928. Doi:\colorblue 10.3390/s20143928.
  • Kang et al. (2017) Kang, J., Yu, R., Huang, X., Maharjan, S., Zhang, Y., Hossain, E., 2017. Enabling localized peer-to-peer electricity trading among plug-in hybrid electric vehicles using consortium blockchains. IEEE Transactions on Industrial Informatics 13, 3154–3164. Doi:\colorblue 10.1109/TII.2017.2709784.
  • Kang et al. (2018) Kang, J., Yu, R., Huang, X., Wu, M., Maharjan, S., Xie, S., Zhang, Y., 2018. Blockchain for secure and efficient data sharing in vehicular edge computing and networks. IEEE Internet of Things Journal 6, 4660–4670. Doi:\colorblue 10.1109/JIOT.2018.2875542.
  • Lasla et al. (2018) Lasla, N., Younis, M., Znaidi, W., Arbia, D.B., 2018. Efficient distributed admission and revocation using blockchain for cooperative its, in: 2018 9th IFIP international conference on new technologies, mobility and security (NTMS), IEEE. pp. 1–5. Doi:\colorblue 10.1109/NTMS.2018.8328734.
  • Li et al. (2018) Li, L., Liu, J., Cheng, L., Qiu, S., Wang, W., Zhang, X., Zhang, Z., 2018. Creditcoin: A privacy-preserving blockchain-based incentive announcement network for communications of smart vehicles. IEEE Transactions on Intelligent Transportation Systems 19, 2204–2220. Doi:\colorblue 10.1109/TITS.2017.2777990.
  • Liu et al. (2016) Liu, L., Loper, M., Ozkaya, Y., Yasar, A., Yigitoglu, E., 2016. Machine to machine trust in the iot era, in: TRUST@AAMAS, CEUR-WS.org. pp. 18–29.
  • Lu et al. (2018) Lu, Z., Liu, W., Wang, Q., Qu, G., Liu, Z., 2018. A privacy-preserving trust model based on blockchain for vanets. IEEE Access 6, 45655–45664. Doi:\colorblue 10.1109/ACCESS.2018.2864189.
  • Lu et al. (2019) Lu, Z., Qu, G., Liu, Z., 2019. A survey on recent advances in vehicular network security, trust, and privacy. IEEE Transactions on Intelligent Transportation Systems 20, 760–776. Doi:\colorblue 10.1109/TITS.2018.2818888.
  • Mármol and Pérez (2012) Mármol, F.G., Pérez, G.M., 2012. Trip, a trust and reputation infrastructure-based proposal for vehicular ad hoc networks. Journal of network and computer applications 35, 934–941. Doi:\colorblue 10.1016/j.jnca.2011.03.028.
  • Memon et al. (2019) Memon, R.A., Li, J.P., Ahmed, J., 2019. Simulation model for blockchain systems using queuing theory. Electronics 8, 234. Doi:\colorblue 10.3390/electronics8020234.
  • Raya et al. (2006) Raya, M., Papadimitratos, P., Hubaux, J.P., 2006. Securing vehicular communications. IEEE wireless communications 13, 8–15. Doi:\colorblue 10.1109/WC-M.2006.250352.
  • Singh and Kim (2017) Singh, M., Kim, S., 2017. Blockchain based intelligent vehicle data sharing framework. arXiv e-prints .
  • Tian et al. (2020) Tian, Z., Gao, X., Su, S., Qiu, J., 2020. Vcash: A novel reputation framework for identifying denial of traffic service in internet of connected vehicles. IEEE Internet of Things Journal Doi:\colorblue 10.1109/JIOT.2019.2951620.
  • Wang et al. (2018) Wang, W., Hoang, D.T., Xiong, Z., Niyato, D., Wang, P., Hu, P., Wen, Y., 2018. A survey on consensus mechanisms and mining management in blockchain networks. arXiv e-prints , 1–33.
  • Wex et al. (2008) Wex, P., Breuer, J., Held, A., Leinmuller, T., Delgrossi, L., 2008. Trust issues for vehicular ad hoc networks, in: VTC Spring 2008-IEEE Vehicular Technology Conference, IEEE. pp. 2800–2804. Doi:\colorblue 10.1109/VETECS.2008.611.
  • Whitepaper (2018) Whitepaper, 2018. Hyperledger blockchain performance metrics .
  • Wu et al. (2013) Wu, D., Zhang, Y., Bao, L., Regan, A.C., 2013. Location-based crowdsourcing for vehicular communication in hybrid networks. IEEE transactions on intelligent transportation systems 14, 837–846. Doi:\colorblue 10.1109/TITS.2013.2243437.
  • Xiao et al. (2020) Xiao, Y., Liu, Y., Li, T., 2020. Edge computing and blockchain for quick fake news detection in iov. Sensors 20, 4360. Doi:\colorblue 10.3390/s20164360.
  • Yang et al. (2019) Yang, Z., Yang, K., Lei, L., Zheng, K., Leung, V.C., 2019. Blockchain-based decentralized trust management in vehicular networks. IEEE Internet of Things Journal 6, 1495–1505. Doi:\colorblue 10.1109/VETECS.2008.611.
  • Zhang (2011) Zhang, J., 2011. A survey on trust management for vanets, in: 2011 IEEE International Conference on Advanced Information Networking and Applications, IEEE. pp. 105–112. Doi:\colorblue 10.1109/AINA.2011.86.
  • Zhang et al. (2016) Zhang, L., Wu, Q., Domingo-Ferrer, J., Qin, B., Hu, C., 2016. Distributed aggregate privacy-preserving authentication in vanets. IEEE Transactions on Intelligent Transportation Systems 18, 516–526. Doi:\colorblue 10.1109/TITS.2016.2579162.
  • Zheng et al. (2017) Zheng, Z., Xie, S., Dai, H., Chen, X., Wang, H., 2017. An overview of blockchain technology: Architecture, consensus, and future trends, in: 2017 IEEE international congress on big data (BigData congress), IEEE. pp. 557–564. Doi:\colorblue 10.1109/BigDataCongress.2017.85.
  • Zou et al. (2019) Zou, J., Ye, B., Qu, L., Wang, Y., Orgun, M.A., Li, L., 2019. A proof-of-trust consensus protocol for enhancing accountability in crowdsourcing services. IEEE Transactions on Services Computing 12, 429–445. Doi:\colorblue 10.1109/TSC.2018.2823705.