Trust-driven blockchain consensus method for internet of vehicles

By using distributed key generation and a trust-driven dynamic PoW consensus method, the single-point trust problem and insufficient consensus mechanism of the vehicle-to-everything (V2X) system are solved, achieving decentralized management and dynamic adjustment, improving the system's security, efficiency and fairness, and meeting the high concurrency and low latency requirements of V2X.

CN122293318APending Publication Date: 2026-06-26ANHUI UNIV

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
ANHUI UNIV
Filing Date
2026-03-31
Publication Date
2026-06-26

AI Technical Summary

Technical Problem

In existing technologies, vehicle-to-everything (V2X) systems suffer from single-point trust issues in traditional multi-TA authentication mechanisms and security vulnerabilities in centralized key management. Traditional Proof-of-Work (PoW) consensus mechanisms are ill-suited to the highly dynamic environment of V2X systems and lack effective trust assessment and dynamic adjustment mechanisms, resulting in insufficient system security, efficiency, and fairness.

Method used

A distributed key generation protocol is adopted to achieve decentralized management of the master key. An incentive contract is designed by combining a dynamic trust evaluation mechanism based on Beta distribution and a principal-agent game model. A trust-driven dynamic PoW consensus method is constructed. The consensus difficulty is adjusted by the trust value, thereby achieving two-layer dynamic control of the global security state of the system and the reputation level of individual nodes.

Benefits of technology

It completely eliminates the single point of trust problem, improves the robustness and security of the system, optimizes consensus efficiency and fairness, reduces authentication latency and computing costs, and meets the application requirements of high concurrency and low latency in the Internet of Vehicles.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122293318A_ABST
    Figure CN122293318A_ABST
Patent Text Reader

Abstract

This invention belongs to the field of vehicle-to-everything (V2X) secure communication and blockchain consensus technology, specifically disclosing a trust-driven V2X blockchain consensus method. This method achieves decentralized management of the master key through a distributed key generation protocol, eliminating the traditional Root-TA single-point trust problem. Combining a dynamic trust evaluation mechanism based on Beta distribution with incentive contract design based on a delegate-agent game model, it constructs a trust-driven dynamic PoW consensus mechanism, achieving two-layer dynamic control of global security state and individual reputation level. This invention significantly improves the decentralization, consensus fairness, and operational efficiency of V2X systems while ensuring security and privacy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the fields of vehicle-to-everything (V2X) secure communication and blockchain consensus technology, specifically to a trust-driven V2X blockchain consensus method, which aims to achieve secure, efficient and controllable distributed collaborative consensus in a dynamic network environment. Background Technology

[0002] With the rapid development of Intelligent Transportation Systems (ITS), Vehicle-to-Everything (VANETs) networks are gradually becoming a crucial supporting technology for realizing vehicle-road cooperation, autonomous driving, and intelligent traffic management. VANETs enable low-latency communication between vehicles (V2V) and between vehicles and roadside units (V2I), allowing for real-time sharing of critical data such as traffic status information, vehicle trajectories, and road events, thereby improving overall traffic efficiency and safety. However, because their communication relies on open wireless channels, data is highly vulnerable to eavesdropping, tampering, replay attacks, and denial-of-service (DoS) attacks during transmission. These problems are particularly prominent in real-world scenarios and directly impact the reliability and availability of the system.

[0003] In practical engineering applications, the security risks of vehicle-to-everything (V2X) networks are particularly significant in typical high real-time scenarios:

[0004] Scenario 1: In a highway platooning scenario, multiple vehicles form a tight formation using a cooperative control algorithm, with a distance between vehicles typically maintained between 5 and 10 meters. The communication cycle needs to be controlled within 20–50 ms for real-time exchange of information such as position, speed, acceleration, and braking status. In this scenario, the system has extremely high requirements for the real-time performance and integrity of communication. If an attacker launches a replay attack or tampers with data, such as resending historical braking commands or modifying acceleration parameters, it will directly disrupt the stability of the platooning control. Experimental and simulation results show that when the delay of critical control information exceeds 150–200 ms, the vehicle control system will be unable to respond to the behavior of the vehicle in front in a timely manner, and the emergency braking distance will increase by approximately 30%–50%. If the attack lasts for 1–2 seconds, the overall stability of the platoon will completely fail, and the probability of a rear-end collision will increase by approximately 70%–80%. Furthermore, at high speeds (above 100 km / h), any erroneous decision can be amplified into a chain collision within one second, posing a significant threat to traffic safety.

[0005] Scenario 2: In a traffic-free intersection with coordinated traffic flow, vehicles rely on the CK (Roadside Unit) for unified scheduling and right-of-way allocation. Before entering the intersection, each vehicle broadcasts its predicted trajectory information in real time (including estimated arrival time, direction of travel, speed curve, etc.). The CK performs conflict detection and priority allocation based on global information. During peak hours, a single intersection needs to process tens to hundreds of vehicle requests per second, and the real-time requirement for the authentication mechanism is typically less than 50–100ms. Once a denial-of-service attack or authentication congestion occurs, such as an attacker continuously injecting forged request data (e.g., 100–300 requests per second), the CK's processing resources will be quickly exhausted, leading to a significant increase in the queuing delay for legitimate vehicle requests. Experimental data shows that when the authentication delay exceeds 100ms, the overall traffic efficiency of the intersection will decrease by about 40%; when the delay exceeds 300ms, the probability of vehicle scheduling failure increases significantly, and may even cause local traffic congestion or "deadlock." In addition, malicious nodes may also obtain priority right-of-way by forging identities, thereby undermining traffic fairness and system credibility.

[0006] To ensure communication security in the aforementioned scenarios, authentication and key negotiation mechanisms have become the core foundation of vehicle-to-everything (V2X) systems. However, traditional multi-TA (Trusted Authority) authentication and key negotiation (AKA) schemes typically rely on a single Root TA to centrally generate and distribute the system's master private key. This centralized architecture suffers from a significant single point of failure and security vulnerabilities: once the Root TA is attacked or malfunctions, the overall system security will be compromised. For example, in extreme cases, if the Root TA private key is leaked, attackers can forge any vehicle identity, thereby monitoring and manipulating all network communications, leading to the exposure of the privacy information of hundreds of thousands or even millions of vehicles; if the Root TA service is unavailable, all vehicles will be unable to complete registration and authentication, resulting in a large-scale interruption of V2X services. Furthermore, centralized key management also incurs high communication and storage overhead, making it difficult to meet the application requirements of low latency and high concurrency.

[0007] On the other hand, in the sharded architecture of the Internet of Vehicles (IoV) incorporating blockchain technology, each shard operates its consensus protocol independently, with CK nodes undertaking block generation and accounting tasks. In this context, the intra-shard consensus mechanism becomes crucial for ensuring system security and performance. However, the traditional Proof-of-Work (PoW) mechanism has significant shortcomings in the IoV environment: firstly, its difficulty adjustment cycle is typically long (e.g., 2016 blocks in classic blockchain systems), making it difficult to respond promptly to the frequently changing network computing power and node states in IoV; secondly, its incentive mechanism is relatively simple, relying solely on computing power competition and lacking constraints on the quality of node behavior. In environments with high-speed vehicle movement and frequent network topology changes, node online rates and computing power fluctuate significantly, leading to unstable block generation times and system throughput fluctuations exceeding 30%, even exhibiting phenomena of excessively fast or slow block generation within short periods. Furthermore, the traditional PoW mechanism does not consider differences in node reputation, allowing malicious or low-quality nodes to still participate in the competition, increasing system security risks.

[0008] In summary, the existing technologies have the following shortcomings: (1) Traditional multi-TA authentication mechanisms rely on the root-TA to centrally distribute the system master private key, which has single-point trust problems and insufficient system robustness; (2) Traditional PoW consensus mechanisms are difficult to adapt to the highly dynamic environment of the Internet of Vehicles, and have problems such as lagging difficulty adjustment, crude incentive mechanisms and lack of constraints on node behavior; (3) There is a lack of effective trust assessment and dynamic adjustment mechanisms, which makes it impossible to continuously supervise and optimize the behavior of CK nodes.

[0009] Therefore, there is an urgent need to propose a new consensus method that integrates distributed key management, trust assessment and dynamic incentive adjustment in order to comprehensively improve the overall performance of vehicle-to-everything (V2X) systems in terms of security, efficiency and fairness. Summary of the Invention

[0010] Purpose of the Invention: The purpose of this invention is to address the shortcomings of existing technologies by providing a trust-driven consensus method for vehicle-to-everything (V2X) blockchains. By introducing a distributed key generation protocol, decentralized management of the system's master key is achieved, fundamentally eliminating the single point of trust and single point of failure issues in the traditional Root-TA architecture. This enhances the overall security and robustness of the system. A dynamic trust evaluation mechanism based on Beta distribution is integrated to continuously quantify and update the behavior of CK nodes. Furthermore, an incentive contract is designed using a delegation-agent game model, closely linking node rewards to the quality of their behavior and their trust level. Through these mechanisms, a trust-driven dynamic PoW consensus method is constructed, enabling two-layer dynamic control of the system's global security state and the reputation level of individual nodes. This ensures security while improving consensus efficiency and system fairness.

[0011] Technical solution: The present invention provides a trust-driven blockchain consensus method for connected vehicles, comprising the following steps:

[0012] Step 1: System initialization phase;

[0013] First, cryptographic parameter initialization: choose a secure elliptic curve. Where p is a large prime number, For elliptic curve parameters, in elliptic curve We select a generator P, construct a cyclic group G of order q (a large prime number), and simultaneously select a set of cryptographically secure hash functions (P). ), and set the system security threshold t and the number of collaborative key generation nodes N;

[0014] Then, the CK node is used as a collaborative key generation node to jointly generate the system master private key share through the Distributed Key Generation Protocol (DKG). It compares the master key with the system's public key to achieve decentralized management of the master key. This indicates the node index for generating the collaboration key;

[0015] Subsequently, the consortium blockchain network is initialized, and global parameters are recorded in the genesis block. The system master public key PK generated by the DKG protocol, where N represents the total number of nodes;

[0016] Step 2: CK node registration and trust initialization phase;

[0017] CK nodes submit registration requests to the blockchain system. After verifying their identity, the system registers their blockchain address in the smart contract, forming a whitelist of collaborative nodes. At the same time, a dynamic trust assessment mechanism based on Beta distribution is introduced to initialize the trust value of each CK node. , Indicates the CK node index;

[0018] Step 3: Vehicle registration, authentication, and key negotiation phase;

[0019] Vehicle node selection real identity identifier The system sends a registration request to the CK node, where i represents the vehicle node index. The CK node verifies the vehicle's identity using a threshold signature mechanism and records the vehicle's public key via a smart contract. Based on registration status, decentralized identity management is achieved;

[0020] The vehicle node initiates an authentication request to the Edge Access Unit (EAU), and the CK node uses its private key share. Calculate local signature share The aggregation generates a global signature to complete two-way authentication, where j represents the EAU node index. Simultaneously, a session key is generated based on the pseudo-random function PRF and elliptic curve cryptography ECC. ;

[0021] ;

[0022] Step 4: Trust-driven dynamic PoW consensus phase;

[0023] Design an incentive contract based on a principal-agent game model. Calculate the optimal excitation intensity parameters By embedding trust states and incentive parameters into a difficulty adjustment function, a trust-driven dynamic PoW consensus mechanism is constructed, with a global base difficulty. Individual difficulty This enables dual-layer dynamic control of both overall security status and individual reputation levels.

[0024] Step 5: Dynamic update phase of trust value;

[0025] The vehicle node provides feedback and evaluation on the behavior of the CK node. Based on the dynamic trust evaluation mechanism, the system uses a Bayesian update algorithm combined with a time forgetting factor g and a penalty factor λ to dynamically adjust the trust value of the CK node. ,in Indicates the first The node at the th The trust value is set for each time slice, enabling dynamic updating of the trust value and suppression of malicious behavior.

[0026] Furthermore, the specific method of the Distributed Key Generation Protocol (DKG) in step 1 is as follows:

[0027] The system first initializes the parameters and selects a safe elliptic curve. , Where p is a large prime number, Let P be the curve parameter; select generators P from the curve E to construct a cyclic group of order q, which is a large prime number. ;

[0028] At the same time, a series of secure cryptographic hash functions were selected. And set the system security threshold t and the number of collaborative key generation nodes N to satisfy... This means that at least t nodes are needed to recover or participate in signing, so that the system can tolerate at most t-1 nodes being damaged or ineffective.

[0029] Each collaborative key generation node C Randomly generate a polynomial of order t-1: ;

[0030] Where the coefficient from Randomly selected from the middle, and the constant term As the node's share contribution to the system's master private key x;

[0031] Subsequently, the nodes calculate the public commitment vector corresponding to the polynomial coefficients:

[0032] ;

[0033] ;

[0034] in It is a secret contribution The commitment, where P is a generator on an elliptic curve, means that other CK nodes will verify the credibility of the broadcasting CK node based on this information and broadcast the commitment vector to all other nodes in the network.

[0035] Next, each A node is directed at other nodes in the network. Calculate the secret share: Substituting the node index k into the polynomial yields the corresponding share, which is then used with the node. public key Encrypt and generate ciphertext. The encrypted share is then securely sent to the corresponding node; once each node receives the encrypted share, it uses its own private key. Decryption And combined with the commitment vector broadcast by the sender Verify the correctness of the shares, that is, verify the following equation. The verification process is performed to determine whether the share is valid. If it fails, the verification is considered unsuccessful, and the corresponding node will broadcast a complaint message to the network to indicate that the sender may have engaged in malicious behavior. After all shares have been verified, each honest node will sum the valid shares from all honest nodes to obtain its final private key share. , This private key share constitutes a part of the system's master private key x. No single node can independently recover the complete private key. Only when no less than t nodes cooperate can the reconstruction of the master private key be completed.

[0036] Finally, the system master public key can be obtained by summing the first elements of all public commitment vectors. : ;

[0037] in The master private key is always distributed among the nodes in a distributed manner and is never held by any single entity, thus achieving decentralized management of the master key.

[0038] Furthermore, the specific implementation method of the dynamic trust evaluation mechanism based on Beta distribution is as follows:

[0039] First, targeting each CK node Set initial trust value This indicates a neutral state; a trust threshold T'=0.3 is set, and when the trust value of a CK node falls below this threshold, the system classifies it as a malicious node; a baseline trust level is set. , a reference benchmark used for dynamic difficulty adjustment;

[0040] Then, to characterize the uncertainty and probabilistic features of node behavior, a Beta distribution probability model is introduced:

[0041] Let random variable This represents the probability that a certain CK will exhibit positive behavior during the consensus process. The value range of is [0,1], and the probability density function of the Beta distribution is:

[0042]

[0043] in For shape parameters, For scale parameters, The Gamma function is used; the expected value of the Beta distribution is... The variance is ;

[0044] Subsequently, during actual operation, the system dynamically updates the distribution parameters based on the historical behavior feedback of the nodes. When s positive feedbacks and f negative feedbacks are received cumulatively within the statistical window, the system updates the Beta distribution parameters: Based on the expected value of the Beta distribution, the formula for calculating the basic trust value is: ;

[0045] To enhance the system's sensitivity to recent behavior, a time forgetting mechanism is introduced by setting a time forgetting factor. In time slice When recalculating trust values, only the most recent ones are considered. Feedback within each time slot is weighted and summarized, among which This represents the length of the sliding time window, and its value is determined based on the system's trade-off between stability and real-time performance.

[0046] The weighted success feedback statistics are as follows: ;

[0047] The weighted failure feedback statistics are as follows: ;

[0048] in, Indicates time slice Feedback in the current time slice The decay weight is below;

[0049] Building upon this, in order to achieve the "slow rise and rapid fall" characteristic of trust value and enhance the system's sensitivity to malicious behavior, a penalty factor is introduced. The final trust value calculation formula is: ,

[0050] in As a penalty item, This represents the weighted number of negative feedbacks.

[0051] Finally, the system determines malicious nodes based on the calculated dynamic trust value: when the trust value of the CK node... At that time, among them This indicates that the k-th CK node is in the... If a node's trust value is determined within a given time slice, it is identified as a malicious node, its operation is suspended, and it is prohibited from participating in subsequent data sharing and consensus processes. The private key share of a malicious node will be revoked, and its blockchain address will be removed from the whitelist of smart contracts.

[0052] The specific implementation methods for vehicle registration, authentication, and key negotiation in further step 3 are as follows:

[0053] First, vehicle nodes Choose Real Identity Send a registration request message to the CK node. ,in For the vehicle's public key, For vehicles to sign their registration information;

[0054] After receiving the registration request, the CK node performs threshold signature verification based on the distributed key system. Using private key shares Calculate the local signature share: After collecting local signature shares from at least t CK nodes, a global signature is generated through Lagrange interpolation aggregation. :

[0055] ,in These are the Lagrange interpolation coefficients;

[0056] And verify the formula as follows: If the information is valid, the verification is successful, indicating that the vehicle registration information is legal and valid.

[0057] After registration is complete, the vehicle initiates an authentication request; vehicle node Choose random ,calculate: Generate a fake identity: , where ⊕ represents the bitwise XOR operation. Use the system's master public key; retrieve the current timestamp. ; Calculation of certification labels: ,in For the vehicle's private key; package the message Send to EAU;

[0058] After receiving the vehicle authentication request, EAU first verifies the inequality. Whether it holds true is used to verify the freshness of time. For the current time, For the allowed time difference;

[0059] After the time freshness verification is passed, EAU selects random. ,calculate: ,in This is the private key for EAU. As the identifier for EAU, The current timestamp; packaged message Broadcast to the blockchain network;

[0060] After receiving the authentication message, the CK node performs joint verification, first checking the timestamp freshness: ; Query the registration status of EAU via smart contract; Query the registration status of vehicle via smart contract (according to...) (Query); using private key shares Calculate the local signature share: Aggregate to generate a global signature: Verify EAU identity: ; Calculate the vehicle's true identity: , where x is the system master private key; after verifying the vehicle identity, auxiliary verification parameters are generated using a pseudo-random function to enhance protocol security;

[0061] Finally, based on the completed authentication, the EAU and the vehicle respectively calculate the Lagrange interpolation constant term to generate the same session key;

[0062] The formula for calculating the session key is: , where k is the temporary key calculated by Lagrange interpolation. express x-coordinate, For the random number of node CK, The output is a pseudo-random function. The timestamp of the CK node;

[0063] This session key enables encrypted communication between the vehicle and the EAU, achieving two-way authentication and secure communication.

[0064] Furthermore, during the system's authentication and key negotiation process, a privacy-preserving identity management mechanism is introduced to ensure traceability while maintaining communication anonymity.

[0065] First, during normal communication, the vehicle node uses a pseudo-identity identifier. Hiding one's true identity, among which This serves as the vehicle's true identification identifier. The random number chosen for the vehicle The system master public key is denoted by ⊕, which represents a bitwise XOR operation. For cryptographic hash functions;

[0066] because The identity is randomly selected, so different authentication sessions use different pseudo-identities, thus achieving the unlinkability of vehicle identity.

[0067] Based on this, to address abnormal behavior and security incidents, the system is designed with an identity recovery mechanism: when a violation or attack is detected, the CK node can restore the vehicle's true identity using the following formula: , where x is the system master private key (which requires at least t CK nodes to jointly compute). These are random points submitted by the vehicle during the certification process; due to ,therefore This allows for the restoration of one's true identity and the realization of a controlled identity disclosure.

[0068] Furthermore, to enable post-event auditing and accountability, the system records the hash value of the vehicle's true identity through smart contracts. To support a conditional traceability mechanism, when a vehicle is identified as a malicious node, the system can query the corresponding identity information on the blockchain based on the hash value and add it to the blacklist, thereby restricting its subsequent participation in network activities. This mechanism achieves an effective balance between privacy protection and system security without directly exposing the plaintext identity.

[0069] Furthermore, the specific implementation of the incentive contract design for the principal-agent game model in step 4 is as follows:

[0070] After completing the system trust assessment mechanism, a game theory-based incentive mechanism model is further introduced to coordinate the interest relationship between the system and the CK node.

[0071] First, a delegation-agent model is constructed in the vehicle-to-everything (V2X) blockchain consensus system: the delegator is the system (or a set of vehicle nodes), and the agent is the CK node. The delegator expects the CK to provide high-quality consensus services, while the CK node aims to maximize its profits. Due to information asymmetry, the delegator cannot directly observe the effort level of the CK node, but can only observe its output. Indirect judgments can be made based on factors such as block generation speed and transaction processing efficiency.

[0072] Based on this, the linear incentive contract is designed as follows: ,in: It is a fixed income (guaranteed minimum income) and is unrelated to output; The incentive intensity parameter represents the additional benefit that CK gains for each additional unit of output. The output variable represents CK's work performance; The trust coupling parameter represents the degree to which the trust value affects the returns. The trust value of CK is calculated by the Beta distribution dynamic trust evaluation mechanism;

[0073] Furthermore, the utility function of the CK node is defined as follows: Where s is the benefit, a is the effort level, and b is the effort cost coefficient. For effort cost;

[0074] The goal of the CK node is to select the optimal effort level a* to maximize its utility function;

[0075] By analyzing the utility function with respect to effort level Taking the derivative and setting it equal to zero yields the optimal effort level: This formula shows that the optimal effort level of node CK is related to the incentive intensity. It is directly proportional to the cost coefficient b;

[0076] Based on this, further considering the risk aversion characteristics of the client, we introduce... The utility function, which optimizes the incentive mechanism, can be expressed as follows: Then, by taking the derivative of the deterministic equivalent payoff with respect to β and setting it equal to 0, the optimal incentive intensity parameters are obtained: ; ρ is the client's risk aversion coefficient; For output variance; The variance of the confidence value; The covariance between output and trust value;

[0077] The economic implications can be further analyzed from the above expression for optimal incentive intensity: as the risk aversion coefficient ρ increases, A decrease indicates that the client is more conservative, resulting in less incentive for CK; when the output variance... When increasing, A decrease indicates that when output uncertainty increases, the principal will reduce the incentive intensity; when the correlation between output and trust value increases (i.e., ... (increase) The increase indicates that the client can better monitor CK's performance by observing the trust value.

[0078] After deriving the optimal incentive strength parameters, the system further combines the incentive mechanism with consensus difficulty adjustment to achieve a dynamic balance between security and participation enthusiasm.

[0079] First, based on the optimal excitation intensity parameters The global base difficulty is calculated using the following expression: ,in The initial difficulty of the system is preset by the system based on computing power and security requirements. When β* is large, it indicates a high overall incentive level and a lower global difficulty, encouraging CK nodes to actively participate in consensus; when β* is small, it indicates a low overall incentive level and a higher global difficulty, reducing system risk.

[0080] Based on the overall difficulty determination, the system further implements an individualized difficulty adjustment mechanism for different CK nodes: the individual difficulty of each node is dynamically determined by its trust value, and the calculation formula is as follows: ,in As a baseline level of trust, for In time slice Trust value. When When, it means The level of trust is higher than the benchmark, and the individual difficulty is higher. That is, the CK achieves a lower solution complexity for the proof of work; when When, it means Their trust level is below the benchmark, and their individual difficulty This means that the CK achieves a high work-proof solution complexity. Therefore, the system forms a two-layer dynamic control mechanism: the first layer is the global-level safety state adjustment, which adjusts the global basic difficulty through the optimal incentive intensity β*. The first layer reflects the overall security status and incentive level of the system; the second layer controls individual reputation levels through trust values. Adjusting individual difficulty This enables refined incentives and constraints on the behavior of individual CK nodes.

[0081] To ensure the timeliness and adaptability of this mechanism, the system sets a uniform difficulty adjustment cycle. Every At time intervals, the system recalculates the optimal excitation intensity β* and the confidence value of each CK node. And update the global base difficulty accordingly. and individual difficulty .

[0082] Beneficial effects: Compared with the prior art, the present invention has the following advantages:

[0083] (1) Fully decentralized security architecture: This invention realizes the distributed generation and management of the system master key through the Distributed Key Generation (DKG) protocol, which completely eliminates the traditional root-TA single point of trust problem. The system master key does not depend on a single central node, and any single point attack or node failure cannot destroy the security and availability of the entire system, fundamentally improving the robustness and reliability of the system.

[0084] (2) Trust-driven fair consensus mechanism: Based on the Beta distribution, the dynamic trust evaluation mechanism can accurately quantify and evaluate the behavior of CK nodes, and combine the principal-agent game model to design incentive contracts to calculate the optimal incentive strength parameters. The trust-driven dynamic PoW difficulty adjustment mechanism enables the system to adaptively adjust the solution complexity of proof of work according to the global running state and individual reputation differences, optimizing system efficiency while ensuring security, and balancing fairness and incentive effects.

[0085] (3) Efficient identity management and verification: Smart contracts are used to manage vehicle identity, public key, reputation, revocation and logs to achieve decentralized identity registration and verification. The threshold signature mechanism ensures the security of the authentication process and significantly reduces authentication latency and on-chain load, meeting the performance requirements of latency-sensitive vehicle networking applications.

[0086] (4) Conditional privacy protection mechanism: During the threshold authentication and session key negotiation process, the vehicle communicates anonymously through pseudo-identity and conditional privacy mechanism. Under normal operation, the vehicle identity remains anonymous to protect user privacy; when violations or attacks occur, the vehicle's true identity can be tracked and restored through smart contracts, achieving a dynamic balance between privacy protection and system security.

[0087] (5) Lightweight computational overhead and real-time advantages: The algorithm design of this invention fully considers the computational resource limitations of the edge nodes of the vehicle network. Verified by actual test data, the computational overhead of the core trust evaluation algorithm (based on Beta distribution) is only 0.0035 ms, and the dynamic difficulty adjustment algorithm is only 0.0002 ms, both at the microsecond level. The total time for the complete vehicle authentication and key negotiation process is controlled within 1.1 ms, and the total overhead for a single round of the entire scheme is approximately 2.28 ms. Compared with traditional consensus mechanisms that require high-intensity computing power competition, this invention significantly reduces the computational cost of legitimate nodes through a trust-driven difficulty adjustment mechanism, effectively meeting the stringent application requirements of high concurrency and low latency (typically requiring a communication cycle of 20-50ms) in the vehicle network. Attached Figure Description

[0088] Figure 1 This is a schematic diagram of the overall architecture of the present invention;

[0089] Figure 2 This is a graph showing the dynamic change of trust value under different time conditions of forgetting factor g and penalty factor λ according to the present invention;

[0090] Figure 3 This is a comparison chart of the evolution of trust values ​​under different factors in the example;

[0091] Figure 4 This is a comparison chart showing the changes in trust values ​​between normal and malicious nodes under malicious behavior triggering conditions, as illustrated in the example.

[0092] Figure 5 The following is a graph showing the relationship between node trust value and individual consensus difficulty in an example.

[0093] Figure 6 This is a performance comparison chart between the method of this invention and the traditional PoW consensus mechanism in terms of throughput (TPS), latency, and computational overhead. Detailed Implementation

[0094] The technical solution of the present invention will be described in detail below, but the scope of protection of the present invention is not limited to the embodiments described.

[0095] like Figure 1 and Figure 2 The trust-driven vehicle networking blockchain consensus method of the present invention includes the following steps:

[0096] Step 1: System initialization phase;

[0097] First, cryptographic parameter initialization: choose a secure elliptic curve. Where p is a large prime number, For elliptic curve parameters, in elliptic curve We select a generator P, construct a cyclic group G of order q (a large prime number), and simultaneously select a set of cryptographically secure hash functions (P). ), and set the system security threshold t and the number of collaborative key generation nodes N;

[0098] Then, the CK node is used as a collaborative key generation node to jointly generate the system master private key share through the Distributed Key Generation Protocol (DKG). It compares the master key with the system's public key to achieve decentralized management of the master key. This indicates the node index for generating the collaboration key;

[0099] Subsequently, the consortium blockchain network is initialized, and global parameters are recorded in the genesis block. The system master public key PK generated by the DKG protocol, where N represents the total number of nodes;

[0100] Step 2: CK node registration and trust initialization phase;

[0101] CK nodes submit registration requests to the blockchain system. After verifying their identity, the system registers their blockchain address in the smart contract, forming a whitelist of collaborative nodes. At the same time, a dynamic trust assessment mechanism based on Beta distribution is introduced to initialize the trust value of each CK node. , Indicates the CK node index;

[0102] Step 3: Vehicle registration, authentication, and key negotiation phase;

[0103] Vehicle node selection real identity identifier The system sends a registration request to the CK node, where i represents the vehicle node index. The CK node verifies the vehicle's identity using a threshold signature mechanism and records the vehicle's public key via a smart contract. Based on registration status, decentralized identity management is achieved;

[0104] The vehicle node initiates an authentication request to the Edge Access Unit (EAU), and the CK node uses its private key share. Calculate local signature share The aggregation generates a global signature to complete two-way authentication, where j represents the EAU node index. Simultaneously, a session key is generated based on the pseudo-random function PRF and elliptic curve cryptography ECC. ;

[0105] ;

[0106] Step 4: Trust-driven dynamic PoW consensus phase;

[0107] Design an incentive contract based on a principal-agent game model. Calculate the optimal excitation intensity parameters By embedding trust states and incentive parameters into a difficulty adjustment function, a trust-driven dynamic PoW consensus mechanism is constructed, with a global base difficulty. Individual difficulty This enables dual-layer dynamic control of both overall security status and individual reputation levels.

[0108] Step 5: Dynamic update phase of trust value;

[0109] The vehicle node provides feedback and evaluation on the behavior of the CK node. Based on the dynamic trust evaluation mechanism, the system uses a Bayesian update algorithm combined with a time forgetting factor g and a penalty factor λ to dynamically adjust the trust value of the CK node. ,in Indicates the first The node at the th The trust value is set for each time slice, enabling dynamic updating of the trust value and suppression of malicious behavior.

[0110] The overall architecture of the vehicle-to-everything (V2X) blockchain consensus system constructed in this invention is as follows: Figure 1 As shown, the architecture comprises three layers: the cloud layer, the edge layer, and the vehicle layer. The cloud layer is responsible for global control and blockchain network maintenance; the edge layer consists of multiple roadside units (CKs), which act as collaborative key generation nodes (CK nodes) to handle consensus and key management tasks; the vehicle layer consists of a massive number of vehicle nodes that interact with the edge layer via V2X communication. Under this architecture, all CK nodes jointly generate the system master private key share and the system master public key through the Distributed Key Generation (DKG) protocol. The system selects a safe elliptic curve. Where p is a 256-bit prime number, a generator P is selected from curve E to generate a cyclic group G of order q. A series of secure cryptographic hash functions are selected, including those used to map group elements to finite fields, those used for pseudo-identity generation, and those used for authentication tag generation. The system jointly determines a security threshold t=3 and a total number of nodes N=5, tolerating a maximum of 2 nodes being corrupted or malfunctioning, thus achieving decentralized management of the master key and eliminating the risk of single point of failure.

[0111] CK nodes submit registration requests to the blockchain system. After verifying their identity, the system registers their blockchain address in the smart contract, forming a whitelist of collaborating nodes. Simultaneously, a dynamic trust assessment mechanism based on Beta distribution initializes the trust value of each CK node to 0.5, with a trust value threshold... =0.3 is used to identify malicious nodes, and the baseline trust level is used for dynamic difficulty adjustment. The dynamic update mechanism of the trust value is one of the core innovations of this invention, and its evolutionary characteristics are as follows: Figure 2 As shown. Figure 2The experiment demonstrates the dynamic changes in trust value under different forgetting and penalty factors. The experimental scenario was set as follows: the first 30 time slots saw nodes perform well and receive positive feedback; the last 20 time slots saw nodes exhibiting abnormal behavior. Experimental data shows that when the forgetting factor g=0.5, the system forgets historical behavior quickly and can rapidly respond to the latest state of the node; when a larger penalty factor λ is set, the trust value exhibits a significant "slow rise, fast fall" characteristic. For example, after receiving 30 consecutive positive feedbacks, the trust value only slowly rises from 0.5 to around 0.85; however, after encountering one negative feedback in the 31st time slot, the trust value immediately plummets to below 0.4. This mechanism effectively inhibits speculative behavior by nodes; that is, nodes need to work honestly for a long time to accumulate a high trust value, while a single malicious act can negate long-term efforts. To more intuitively illustrate the impact of the forgetting factor on the evolution of trust value, we plotted a comparison chart of trust value evolution under different factors (…). Figure 3 (Comparison of trust value evolution under different factors). This figure clearly shows that the larger the factor value, the slower the trust value increases and the more obvious the decay in the later stage. Figure 3 As shown, when the factor is 0.2, the trust value increases rapidly and stabilizes at a high level; however, when the factor increases to 2.0, the trust value not only increases slowly but also shows a significant downward trend after reaching its peak. This comparison provides an intuitive basis for the system to select an appropriate forgetting factor according to actual needs, further verifying the flexibility and effectiveness of the trust evaluation mechanism of this invention. Subsequently, the vehicle node selects a real identity identifier and sends a registration request to the CK node. The CK node verifies the vehicle identity through a threshold signature mechanism, each using its private key share to calculate a local signature share, aggregating to generate a global signature to complete identity verification, and recording the vehicle's public key and registration status through a smart contract to achieve decentralized identity management.

[0112] The vehicle node initiates an authentication request to the Edge Access Unit (EAU), which forwards the authentication message to the blockchain network. The CK node utilizes its private key share. Calculate local signature share The global signature is aggregated to complete two-way authentication. Simultaneously, a session key is generated based on the pseudo-random function PRF and elliptic curve cryptography ECC. This ensures the confidentiality and integrity of subsequent communications.

[0113] This invention also designs a trust-driven dynamic PoW consensus mechanism, which aims to adjust the consensus difficulty through trust value to ensure system fairness and security. Figure 4 This demonstrates a comparison of trust value changes between normal and malicious nodes under malicious behavior triggering conditions. Node A is set as an honest node, and node B is a potentially malicious node that initiates malicious behavior (such as broadcasting false messages) in the 30th time slot. Figure 4As shown, in the initial stage, the trust values ​​of both nodes show a similar slow upward trend starting from 0.5. However, when node B triggers malicious behavior in the 30th time slot, its trust value curve drops sharply under the effect of the penalty mechanism, quickly falling below the malicious judgment threshold T'=0.3, and continues to decline in the subsequent time period until it is isolated by the system. In contrast, node A's trust value maintains a stable upward trend due to continuous positive feedback and converges to the high trust range. This significant curve differentiation feature intuitively proves that the trust evaluation mechanism proposed in this invention has extremely high sensitivity and discriminative power, and can effectively identify dynamic malicious behavior in the network, preventing malicious nodes from disrupting the consensus process through "long-term disguise and sudden attack".

[0114] Furthermore, Figure 5 The curve illustrating the relationship between node trust value and individual consensus difficulty is shown. The dynamic difficulty adjustment function established in this invention results in a negative correlation between the solution complexity of proof-of-work and the trust value. Figure 5 It is evident that when a node's trust value is high (e.g., >0.8), the complexity of solving its proof-of-work task is significantly reduced, meaning it is easier for it to obtain the right to record transactions. Conversely, when the trust value is low, the complexity of solving the proof-of-work task increases sharply. This mechanism incentivizes nodes to maintain a good behavioral record in order to obtain higher rewards. An incentive contract is designed based on a delegation-agent model, and the optimal incentive strength parameters are calculated. A dynamic difficulty adjustment mechanism enables two-layer dynamic control of global base difficulty, individual difficulty, global security state, and individual reputation level. Figure 5 This study intuitively reveals the quantitative relationship of trust-driven dynamic difficulty adjustment. Using "node trust value" as the horizontal axis and "computational difficulty" as the vertical axis, it clearly depicts the inverse relationship between the two. Specific data analysis is as follows: Figure 5 The "baseline trust value T0" marked in the text is a key reference point, at which the individual difficulty of a node is set to the global base difficulty. When the node trust value is at a high level (e.g., in the range of 0.8 to 1.0), the curve shows a gentle downward trend, indicating that the solution complexity of the proof of work for high-reputation nodes is significantly reduced. For example, the difficulty of a node with a trust value of 0.9 may only be about 50% of the baseline difficulty.

[0115] When node trust values ​​drop to low levels (e.g., in the range of 0.0 to 0.4), the curve becomes unusually steep, indicating that the solution complexity for proof-of-work with low-reputation nodes increases dramatically, potentially reaching more than five times the baseline difficulty. The curve slopes steepest near the baseline trust value T0, indicating that changes in trust values ​​are most sensitive to difficulty variations in this region.

[0116] To further verify the advantages of the trust-driven dynamic PoW consensus mechanism proposed in this invention in terms of computational overhead, this embodiment is based on an open-source cryptography library ( Performance metrics and comparative experiments were conducted on the core algorithm. The experiment first tested the trust value calculation process based on the Beta distribution (including time-forgetting weighting and penalty factor calculation) with 1000 iterations. The results showed that the average time for a single trust value calculation was only 0.0035 seconds. The throughput reached approximately 285,000 times per second, verifying that the trust assessment algorithm is extremely lightweight and will not burden the system's real-time performance even with frequent calls in high-concurrency scenarios in the Internet of Vehicles (IoV). Subsequently, to quantify the improvement in consensus efficiency brought about by "trust-driven" approaches, the experiment compared and analyzed the computational costs of nodes with different trust levels. The experiment set a baseline difficulty of 0 for the first 8 bits of the hash value and adjusted the solution complexity of individual proof-of-work for low-trust nodes (T<0.3) and high-trust nodes (T>0.8): the difficulty for low-trust nodes was increased to 0 for the first 12 bits of the hash value, with an average of approximately 4,096 hash attempts and an average time of 12.50 seconds. This effectively suppresses computational attacks from malicious or low-reputation nodes; the difficulty of high-trust nodes is reduced to 0 for the first four bits, with an average of only 16 hash attempts and an average processing time of approximately 0.05 seconds. .

[0117] Experimental results show that the computational efficiency of high-trust nodes is approximately 256 times higher than that of low-trust nodes. This significant performance difference demonstrates that the present invention, through a two-layer dynamic control mechanism, significantly reduces the computational energy consumption of honest nodes while ensuring system security, achieving an incentive effect of "good money driving out bad," and fully meeting the engineering application requirements of resource-constrained and high real-time demands of vehicle-to-everything (V2X) edge nodes. In summary, Figure 5 The dynamic difficulty adjustment curve shown directly links the individual reputation (trust value) of a node to its accounting cost (the solution complexity of proof-of-work), constructing a powerful economic incentive and punishment mechanism. This not only effectively suppresses speculative behavior of nodes but also guides nodes to actively maintain good behavior records. Ultimately, it achieves two-layer dynamic control of the global network security status and individual reputation level, ensuring the efficiency and fairness of the consensus mechanism.

[0118] When vehicle nodes provide feedback and evaluation of the behavior of CK nodes, the system dynamically adjusts the trust value of CK nodes based on a Bayesian update mechanism with a Beta distribution. To verify the actual performance of this invention, a simulation comparison experiment was conducted between the method of this invention and the traditional PoW consensus mechanism. The results are as follows: Figure 6 As shown. Figure 6This chart compares the performance of the method of this invention with that of the traditional PoW consensus mechanism in terms of throughput (TPS), latency, and computational overhead. Figure 6 The data shows that, in terms of throughput, the traditional PoW mechanism, due to its static difficulty adjustment and the existence of invalid computing power competition, results in an average throughput of only 50 TPS. In contrast, the method of this invention, benefiting from a trust-driven dynamic difficulty adjustment mechanism, can rationally allocate accounting rights based on node reputation, effectively reducing the waiting time for block confirmation and increasing the average throughput to approximately 80 TPS, an increase of 60%. Regarding latency, traditional PoW suffers from an average latency of approximately 80ms due to its lengthy consensus process, making it difficult to meet the high real-time requirements of connected vehicle services. This invention, through a decentralized authentication architecture, optimizes the interaction process, significantly reducing the average latency to around 60ms, which is more suitable for communication requirements in high-speed vehicle scenarios. In terms of energy consumption, traditional PoW nodes, regardless of their trust level, require high-intensity hash collision calculations, resulting in huge computational overhead. This invention, by linking the trust value to the complexity of solving the proof-of-work problem, enables high-trust nodes to complete consensus at a lower computational cost, significantly reducing the overall energy consumption of the system.

[0119] Experimental data fully demonstrates that this invention achieves comprehensive optimization of system throughput, response speed, and resource utilization while ensuring security. To further verify the resource overhead and execution efficiency of this invention in a real computing environment, this embodiment conducted CPU time cost tests on the core cryptographic operations at each stage of the scheme. The test environment was a standard edge computing node configuration, and the calculations were performed using a Python cryptographic simulation library. The results show that: a single SHA-256 hash operation takes approximately 0.0024 milliseconds, a single ECC elliptic curve multiplication operation takes approximately 0.3451 milliseconds, the complete execution of the Distributed Key Generation (DKG) protocol takes approximately 0.5537 milliseconds, the entire process of threshold signature generation and aggregation takes approximately 0.7558 milliseconds, and the dynamic calculation of trust values ​​based on the Beta distribution takes an extremely low time of only 0.0035 milliseconds. Regarding the overall process overhead, the system initialization phase (including the DKG protocol) takes an average of approximately 0.55 milliseconds, and the vehicle registration and authentication phase (including threshold signature verification) takes an average of... The average time taken for authentication and key negotiation phases is approximately 1.10 milliseconds, the time taken for a single round of trust-driven PoW consensus is approximately 0.24 milliseconds, and the time taken for dynamic update of trust value is approximately 0.0035 milliseconds. Therefore, the total overhead of a single run of the complete solution of this invention is approximately 2.28 milliseconds. The computational overhead of the trust value calculation and difficulty adjustment algorithm, which are the core consensus logic, is only in the microsecond range, having almost no impact on the system's real-time performance. Compared to the traditional PoW mechanism, which relies on a large number of invalid hash collision calculations, this invention effectively reduces the computational difficulty of high-reputation nodes through a trust-driven dynamic difficulty adjustment strategy, thereby significantly reducing redundant computation. These test results verify that this invention possesses lightweight and low-latency engineering implementation capabilities while ensuring security and fairness, making it suitable for deployment in edge computing nodes in the highly dynamic environment of the Internet of Vehicles, achieving real-time and efficient blockchain consensus.

[0120] In summary, this invention effectively solves the security and efficiency bottlenecks in vehicle-to-everything (V2X) blockchain systems through the deep integration of distributed architecture and trust mechanisms, achieving synergistic optimization of decentralized management, dynamic trust assessment, and consensus incentives. During system operation, the trust assessment mechanism monitors node status in real time. When the trust value of a CK node falls below a preset threshold due to malicious behavior or prolonged inactivity, the system will initiate a trust assessment. When the value is 0.3, the system immediately triggers the penalty logic in the smart contract, automatically identifying it as a malicious node, suspending its running permissions in a timely manner, and prohibiting it from participating in subsequent data sharing and consensus processes. This establishes a real-time defense mechanism against malicious behavior while ensuring the openness of the system.

[0121] As described above, although the invention has been shown and described with reference to specific preferred embodiments, it should not be construed as limiting the invention itself. Various changes in form and detail may be made without departing from the spirit and scope of the invention as defined in the appended claims.

Claims

1. A trust-driven blockchain consensus method for connected vehicles, characterized in that: Includes the following steps: Step 1: System initialization phase; First, cryptographic parameter initialization: choose a secure elliptic curve. Where p is a large prime number, For elliptic curve parameters, in elliptic curve We select a generator P, construct a cyclic group G of order q (a large prime number), and simultaneously select a set of cryptographically secure hash functions (P). ), and set the system security threshold t and the number of collaborative key generation nodes N; Then, the CK node is used as a collaborative key generation node to jointly generate the system master private key share through the Distributed Key Generation Protocol (DKG). It compares the master key with the system's public key to achieve decentralized management of the master key. This indicates the node index for generating the collaboration key; Subsequently, the consortium blockchain network is initialized, and global parameters are recorded in the genesis block. The system master public key PK generated by the DKG protocol, where N represents the total number of nodes; Step 2: CK node registration and trust initialization phase; CK nodes submit registration requests to the blockchain system. After verifying their identity, the system registers their blockchain address in the smart contract, forming a whitelist of collaborative nodes. At the same time, a dynamic trust assessment mechanism based on Beta distribution is introduced to initialize the trust value of each CK node. , Indicates the CK node index; Step 3: Vehicle registration, authentication, and key negotiation phase; Vehicle node selection real identity identifier The system sends a registration request to the CK node, where i represents the vehicle node index. The CK node verifies the vehicle's identity using a threshold signature mechanism and records the vehicle's public key via a smart contract. Based on registration status, decentralized identity management is achieved; The vehicle node initiates an authentication request to the Edge Access Unit (EAU), and the CK node uses its private key share. Calculate local signature share The aggregation generates a global signature to complete two-way authentication, where j represents the EAU node index. Simultaneously, a session key is generated based on the pseudo-random function PRF and elliptic curve cryptography ECC. ; ; Step 4: Trust-driven dynamic PoW consensus phase; Design an incentive contract based on a principal-agent game model. Calculate the optimal excitation intensity parameters By embedding trust states and incentive parameters into a difficulty adjustment function, a trust-driven dynamic PoW consensus mechanism is constructed, with a global base difficulty. Individual difficulty This enables dual-layer dynamic control of both overall security status and individual reputation levels. Step 5: Dynamic update phase of trust value; The vehicle node provides feedback and evaluation on the behavior of the CK node. Based on the dynamic trust evaluation mechanism, the system uses a Bayesian update algorithm combined with a time forgetting factor g and a penalty factor λ to dynamically adjust the trust value of the CK node. ,in Indicates the first The node at the th The trust value is set for each time slice, enabling dynamic updating of the trust value and suppression of malicious behavior.

2. The trust-driven vehicle-to-everything (V2X) blockchain consensus method according to claim 1, characterized in that: The specific method of the Distributed Key Generation Protocol (DKG) in step 1 is as follows: The system selects elliptic curves. , Where p is a large prime number, Let P be the curve parameter; select generators P from the curve E to construct a cyclic group of order q, which is a large prime number. ; At the same time, a series of secure cryptographic hash functions were selected. And set the system security threshold t and the number of collaborative key generation nodes N to satisfy... ; Each collaborative key generation node C Randomly generate a polynomial of order t-1: ; Where the coefficient from Randomly selected from the middle, and the constant term As the node's share contribution to the system's master private key x; Subsequently, the nodes calculate the public commitment vector corresponding to the polynomial coefficients: ; ; in It is a secret contribution The commitment, P is a generator on the elliptic curve; Next, each A node is directed at other nodes in the network. Calculate the secret share: Substituting the node index k into the polynomial yields the corresponding share, which is then used with the node. public key Encrypt and generate ciphertext. The encrypted share is then securely sent to the corresponding node; once each node receives the encrypted share, it uses its own private key. Decryption And combined with the commitment vector broadcast by the sender Verify the correctness of the shares, that is, verify the following equation. The verification process is performed to determine whether the share is valid. If it fails, the verification is considered unsuccessful, and the corresponding node will broadcast a complaint message to the network to indicate that the sender may have engaged in malicious behavior. After all shares have been verified, each honest node will sum the valid shares from all honest nodes to obtain its final private key share. , This private key share constitutes a part of the system's master private key x. No single node can independently recover the complete private key. Only when no less than t nodes cooperate can the reconstruction of the master private key be completed. Finally, the system master public key can be obtained by summing the first elements of all public commitment vectors. : ; in This is the system's master private key.

3. The trust-driven vehicle networking blockchain consensus method according to claim 1, characterized in that: The specific implementation method of the dynamic trust evaluation mechanism based on Beta distribution is as follows: First, targeting each CK node Set initial trust value This indicates a neutral state; a trust threshold T'=0.3 is set, and when the trust value of a CK node falls below this threshold, the system classifies it as a malicious node; a baseline trust level is set. , a reference benchmark used for dynamic difficulty adjustment; Then, to characterize the uncertainty and probabilistic features of node behavior, a Beta distribution probability model is introduced: Let random variable This represents the probability that a certain CK will exhibit positive behavior during the consensus process. The value range of is [0,1], and the probability density function of the Beta distribution is: ; in For shape parameters, For scale parameters, The Gamma function is used; the expected value of the Beta distribution is... The variance is ; Subsequently, the distribution parameters are dynamically updated based on the historical behavior feedback of the nodes. When s positive feedbacks and f negative feedbacks are received cumulatively within the statistical window, the system updates the Beta distribution parameters: Based on the expected value of the Beta distribution, the formula for calculating the basic trust value is: ; Introducing a time forgetting mechanism by setting a time forgetting factor In time slice When recalculating trust values, only the most recent ones are considered. Feedback within each time slot is weighted and summarized, among which This represents the length of the sliding time window, and its value is determined based on the system's trade-off between stability and real-time performance. The weighted success feedback statistics are as follows: ; The weighted failure feedback statistics are as follows: ; in, Indicates time slice Feedback in the current time slice The decay weight is below; Introducing a penalty factor The final trust value calculation formula is: , in As a penalty item, This represents the weighted number of negative feedbacks. Finally, the system determines malicious nodes based on the calculated dynamic trust value: when the trust value of the CK node... At that time, among them This indicates that the k-th CK node is in the... If a node's trust value is determined within a given time slice, it is identified as a malicious node, its operation is suspended, and it is prohibited from participating in subsequent data sharing and consensus processes. The private key share of a malicious node will be revoked, and its blockchain address will be removed from the whitelist of smart contracts.

4. The trust-driven vehicle networking blockchain consensus method according to claim 1, characterized in that: The specific implementation methods for vehicle registration, authentication, and key negotiation in step 3 are as follows: First, vehicle nodes Choose Real Identity Send a registration request message to the CK node. ,in For the vehicle's public key, For vehicles to sign their registration information; After receiving the registration request, the CK node performs threshold signature verification based on the distributed key system. Using private key shares Calculate the local signature share: After collecting local signature shares from at least t CK nodes, a global signature is generated through Lagrange interpolation aggregation. : ,in These are the Lagrange interpolation coefficients; And verify the formula as follows: If the information is valid, the verification is successful, indicating that the vehicle registration information is legal and valid. After registration is completed, the vehicle initiates an authentication request; Vehicle node Choose random ,calculate: Generate a fake identity: , where ⊕ represents the bitwise XOR operation. Use the system's master public key; retrieve the current timestamp. ; Calculation of certification labels: ,in For the vehicle's private key; package the message Send to EAU; After receiving the vehicle authentication request, EAU first verifies the inequality. Whether it holds true is used to verify the freshness of time. For the current time, For the allowed time difference; After the time freshness verification is passed, EAU selects random. ,calculate: ,in This is the private key for EAU. As the identifier for EAU, The current timestamp; packaged message Broadcast to the blockchain network; After receiving the authentication message, the CK node performs joint verification, first checking the timestamp freshness: ; Query the registration status of EAU via smart contract; query the registration status of vehicle via smart contract; utilize private key shares. Calculate the local signature share: Aggregate to generate a global signature: Verify EAU identity: ; Calculate the vehicle's true identity: , where x is the system master private key; Finally, based on the completed authentication, the EAU and the vehicle respectively calculate the Lagrange interpolation constant term to generate the same session key; The formula for calculating the session key is: , where k is the temporary key calculated by Lagrange interpolation. express x-coordinate, For the random number of node CK, The output is a pseudo-random function. The timestamp of the CK node; This session key enables encrypted communication between the vehicle and the EAU, achieving two-way authentication and secure communication.

5. The trust-driven vehicle-to-everything (V2X) blockchain consensus method according to claim 1, characterized in that: The authentication and key negotiation phase in step 3 also employs a conditional privacy protection mechanism, the specific implementation process of which is as follows: First, vehicle nodes use pseudo-identity identifiers during normal communication. Hiding one's true identity, among which This serves as the vehicle's true identification identifier. The random number chosen for the vehicle The system master public key is denoted by ⊕, which represents a bitwise XOR operation. For cryptographic hash functions; because The identity is randomly selected, so different authentication sessions use different pseudo-identities, thus achieving the unlinkability of vehicle identity. To address abnormal behavior and security incidents, an identity recovery mechanism is designed: when a violation or attack is detected, the CK node can restore the vehicle's true identity using the following formula: Where x is the system master private key, These are random points submitted by the vehicle during the certification process; due to ,therefore ; Record the hash value of the vehicle's true identity through smart contracts. To support a conditional traceability mechanism, when a vehicle is identified as a malicious node, the system can query the corresponding identity information on the blockchain based on the hash value and add it to the blacklist.

6. The trust-driven vehicle networking blockchain consensus method according to claim 1, characterized in that: The specific implementation of the incentive contract design for the principal-agent game model in step 4 is as follows: First, a delegation-agent model is constructed in the vehicle-to-everything (V2X) blockchain consensus system. The delegation entity represents the system, and the agent is the CK node. The delegation entity expects CK to provide high-quality consensus services, while the CK node aims to maximize its profits. Due to information asymmetry, the delegation entity cannot directly observe the effort level of the CK node; it can only observe its output. Make an indirect judgment; The linear incentive contract is designed as follows: ,in: For fixed income; The incentive intensity parameter represents the additional benefit that CK gains for each additional unit of output. The output variable represents CK's work performance; The trust coupling parameter represents the degree to which the trust value affects the returns. The trust value of CK is calculated by the Beta distribution dynamic trust evaluation mechanism; The utility function for node CK is defined as follows: Where s is the benefit, a is the effort level, and b is the effort cost coefficient. For effort cost; The goal of the CK node is to select the optimal effort level a* to maximize its utility function; By analyzing the utility function with respect to effort level Taking the derivative and setting it equal to zero, we obtain the optimal effort level: ; Introduction The utility function takes into account the risk aversion of the principal and optimizes the incentive mechanism. The principal's deterministic equivalent benefit is expressed as: Then, by taking the derivative of the deterministic equivalent payoff with respect to β and setting it equal to 0, the optimal incentive intensity parameters are obtained: ; ρ is the client's risk aversion coefficient; For output variance; The variance of the confidence value; The covariance between output and trust value.

7. The trust-driven vehicle-to-everything (V2X) blockchain consensus method according to claim 1, characterized in that: The specific implementation method of the trust-driven dynamic PoW consensus mechanism in step 4 is as follows: First, based on the optimal excitation intensity parameters The global base difficulty is calculated using the following expression: ,in β* represents the initial difficulty of the system. When β* is large, it indicates that the overall incentive level of the system is high and the global difficulty is reduced, in order to encourage CK nodes to actively participate in consensus. When β* is small, it indicates that the overall incentive level of the system is low and the global difficulty is increased, in order to reduce system risk. An individualized difficulty adjustment mechanism is implemented for different CK nodes: the individual difficulty of each node is dynamically determined by its trust value, and the calculation formula is as follows: ; in As a baseline level of trust, for In time slice Trust value; when When, it means The level of trust is higher than the benchmark, and the individual difficulty is higher. That is, the CK achieves a lower work-proof solution complexity; when When, it means Their trust level is below the benchmark, and their individual difficulty That is, the CK achieves a higher work-proof solution complexity; Set a uniform difficulty adjustment cycle Every At time intervals, the system recalculates the optimal excitation intensity β* and the confidence value of each CK node. And update the global base difficulty accordingly. and individual difficulty .