Blockchain smart-based trust management method and system for internet of vehicles

By employing a blockchain-based intelligent trust management method, and utilizing deep learning and federated learning algorithms to calculate vehicle-to-everything (V2X) trust values, the problems of identifying malicious internal nodes and consuming blockchain resources in V2X are solved, achieving efficient trust value evaluation and storage.

CN120730309BActive Publication Date: 2026-02-13SHANGRAO XIYANGTENG INFORMATION TECHNOLOGY CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510974713.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-07-15
Publication Date
2026-02-13
Estimated Expiration
2045-07-15

AI Technical Summary

Technical Problem

Existing vehicle-to-everything (V2X) trust management solutions struggle to effectively identify attacks from malicious internal nodes when faced with high mobility and dynamic network topologies. Furthermore, blockchain-based trust value storage solutions consume excessive resources, impacting efficiency.

Method used

A blockchain-based intelligent trust management method is adopted, which calculates direct trust values ​​through deep learning algorithms and generates final trust values ​​by combining dynamic weighting algorithms. The consensus mechanism of federated learning and machine learning is used for model training and parameter integration to achieve continuous learning and efficient storage of trust values.

Benefits of technology

It improves the accuracy and adaptability of trust value assessment, reduces the resource consumption of the consensus mechanism, and enhances the accuracy of identifying internal malicious nodes and the efficiency of block creation and publication.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120730309B_ABST
    Figure CN120730309B_ABST
Patent Text Reader

Abstract

The application provides a kind of based on blockchain intelligence's trust management method and system for Internet of Vehicles, the method comprises: obtaining direct trust value according to deep learning algorithm;Generate local trust value, aggregate all local trust values to calculate final trust value;According to final trust value, trust evaluation model is trained;Obtain the model training accuracy of trust evaluation model, calculate the evaluation value of each vehicle according to final trust value and model training accuracy, and divide all vehicles into check vehicle and FL client according to evaluation value;Obtain the test set accuracy calculated by check vehicle and the model training accuracy sent by FL client, and judge whether the absolute value of the difference between test set accuracy and model training accuracy is not greater than the first preset threshold;If not greater than, model parameters are packaged into block transaction, and model parameters are integrated into local trust evaluation model.The application can improve the accuracy of trust value evaluation and adaptability to environmental changes.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of vehicle trust management, and particularly relates to a vehicle networking trust management method and system based on blockchain intelligence. BACKGROUND

[0002] Vehicle networking combines wireless communication, sensors, artificial intelligence and other cutting-edge technologies with traditional automotive systems, and realizes low-latency and reliable data sharing between vehicles, road infrastructure, pedestrians and cloud servers through V2X (Vehicle-to-Everything) communication, which can effectively improve traffic safety and reduce traffic congestion. However, due to the high mobility, dynamic network topology and openness of vehicle networking, intelligent and networked vehicles are vulnerable to security and privacy threats, which can interfere with driving and endanger the safety of drivers and passengers.

[0003] Traditional key-based authentication schemes can resist attacks initiated by external malicious nodes that have not been authenticated and do not have legal certificate credentials, but cannot effectively identify attacks initiated by internal malicious nodes that have been authenticated and have legal certificate credentials, including maliciously publishing incorrect traffic messages and refusing to participate in message sharing.

[0004] Trust management is a solution to effectively identify internal attacks, and by calculating the trust values of each node in the network and the messages published by the nodes, nodes with trust values below a threshold are identified as malicious nodes, and the certificates of the malicious nodes are revoked. In recent years, machine learning and blockchain have been widely used in the evaluation and storage of vehicle trust values, but current trust value evaluation algorithms lack adaptability to dynamic environments and ignore environmental and algorithm update parameters. Moreover, after these algorithm models are deployed on terminal nodes, they cannot continuously learn and update from the vast amount of V2X communication messages. At the same time, the consensus phase before the publication of a block consumes a large amount of resources in the trust value storage scheme based on blockchain, affecting the efficiency of block creation and publication.

[0005] Blockchain intelligence is a technology that combines blockchain and machine learning algorithms, and uses the characteristics of decentralization, transparency, tamper resistance and encryption of blockchain to provide machine learning algorithms with secure and reliable data sources and storage capabilities. At the same time, the high-order analysis and processing capabilities of machine learning algorithms are used to realize lightweight consensus mechanisms and smart contracts for blockchain. However, existing trust management schemes based on both blockchain and machine learning only use machine learning algorithms to calculate the trust values of nodes or messages separately, and then use blockchain to store trust values and other necessary data, without using the advantages of these two technologies to compensate for the deficiencies of the other. SUMMARY

[0006] The application aims to provide a blockchain intelligent-based trust management method and system for vehicle networking, aiming to solve at least one problem in the background art.

[0007] In a first aspect, the application provides a blockchain intelligent-based trust management method for vehicle networking, comprising:

[0008] inputting vehicle parameters, event parameters, environment parameters and model update parameters into a deep learning algorithm to obtain direct trust values;

[0009] calculating indirect trust values from the direct trust values, aggregating the direct trust values and the indirect trust values through a dynamic weight algorithm to generate local trust values, and summarizing all the local trust values to calculate final trust values;

[0010] training a trust evaluation model according to the final trust values, and obtaining model parameters of the trust evaluation model after training;

[0011] obtaining the model training accuracy of the trust evaluation model, calculating the evaluation value of each vehicle according to the final trust values and the model training accuracy, and dividing all the vehicles into verification vehicles and FL clients according to the evaluation value;

[0012] obtaining the test set accuracy calculated by the verification vehicle and the model training accuracy sent by the FL client, and determining whether the absolute value of the difference between the test set accuracy and the model training accuracy is not greater than a first preset threshold;

[0013] If the absolute value of the difference between the test set accuracy and the model training accuracy is not greater than the first preset threshold, the model parameters are packaged into a block transaction, and the model parameters are integrated into the local trust evaluation model using a federated average algorithm.

[0014] Further, the step of inputting vehicle parameters, event parameters, environment parameters and model update parameters into a deep learning algorithm to obtain direct trust values comprises:

[0015] The deep learning algorithm comprises an input layer, two hidden layers and an output layer, and the calculation formula of each layer is as follows:

[0016] y L =a L (W L y L-1 +b L );

[0017] wherein y L and y L-1 represent the output of the Lth layer and the (L-1)th layer respectively, W L , b L , a L() are the weight, bias and activation function of the Lth layer, respectively;

[0018] The loss function of the deep learning algorithm is:

[0019]

[0020] Wherein, L(W, b) is the loss value of the loss function of the deep learning algorithm, N represents the size of the training set, represents the true label of the trust value of the ith training sample, represents the direct trust value of the ith record calculated by the deep learning algorithm.

[0021] Further, the step of calculating the indirect trust value according to the direct trust value, and aggregating the direct trust value and the indirect trust value through the dynamic weight algorithm to generate the local trust value, and collecting all the local trust values to calculate the final trust value comprises:

[0022] The indirect trust value is calculated according to the following formula:

[0023]

[0024] Wherein, M represents the number of vehicles broadcasting the direct trust value of the message sending vehicle around the message receiving vehicle, FT r is the final trust value of the rth message receiving vehicle, DT s,r is the direct trust value of the st information sending vehicle calculated by the rth information receiving vehicle, IDT s,r is the indirect trust value of the st information sending vehicle calculated by the rth information receiving vehicle;

[0025] The local trust value is calculated according to the following formula:

[0026] LT s,r = θ s,r DT s,r +(1-θ s,r )IDT s,r ;

[0027] Wherein, LT s,r is the local trust value of the st information sending vehicle calculated by the rth information receiving vehicle, θ s,r is the comprehensive weight;

[0028] The final trust value is calculated according to the following formula:

[0029]

[0030] Wherein, P represents the number of vehicles reporting the local trust value of the same message sending vehicle around a road side unit, FTs obtaining a final trust value of the s-th information sending vehicle.

[0031] Further, the step of obtaining the model training accuracy of the trust evaluation model, calculating an evaluation value of each vehicle according to the final trust value and the model training accuracy, and dividing all vehicles into a verification vehicle and a FL client according to the evaluation value comprises:

[0032] The evaluation value is calculated according to the following formula:

[0033] CS = w1FT + w2ACC + w3FRQ;

[0034] wherein, CS represents the evaluation value of the vehicle, FT represents the final trust value of the vehicle, ACC is the model training accuracy of the trust evaluation model, FQR is the update frequency, w1, w2 and w3 are all parameter weights;

[0035] All evaluation values are sorted, and the first preset proportion of vehicles with high ranking are selected as the verification vehicle according to the sorting result, and the remaining vehicles are selected as the FL client.

[0036] The FL client is used to train a local trust evaluation model.

[0037] Further, the step of judging whether the absolute value of the difference between the test set accuracy and the model training accuracy is not greater than a first preset threshold further comprises:

[0038] If greater than the first preset threshold, the model parameter is discarded.

[0039] Further, the expression of the federated average algorithm is:

[0040]

[0041] wherein, s l , s t are the local training set size of the vehicle and the overall training set size of the roadside unit respectively, W rsu , b rsu are the weight and bias of the trust evaluation model based on deep learning integrated by the roadside unit respectively, W veh , b veh are the weight and bias of the trust evaluation model based on deep learning trained by the vehicle respectively.

[0042] Further, the method further comprises:

[0043] When receiving the model parameter uploaded by the FL verifier after verification, the RSU integrates the model parameter into the local trust evaluation model of the RSU, and trains the model using the V2X messages and trust values collected by the RSU locally.

[0044] The comprehensive scores of the respective RSUs are calculated, and RSUs with the top second preset proportion of the comprehensive scores are selected to form a block publishing review committee, and an RSU with the highest comprehensive score creates a candidate block, the review committee includes a plurality of committee nodes, each committee node corresponds to an RSU;

[0045] The candidate block is sent to the review committee for verification, if the verification is passed, the committee node casts a yes vote, if the verification is not passed, the committee node casts a no vote;

[0046] If more than a third preset proportion of the yes votes, the candidate block is confirmed to be published, and all RSUs add the selected block into the block chain, if not more than the third preset proportion of the yes votes, the candidate block is discarded.

[0047] In a second aspect, the present application provides a vehicle networking trust management system based on blockchain intelligence, the system comprises:

[0048] A direct trust value acquisition module is configured to input vehicle parameters, event parameters, environment parameters and model update parameters into a deep learning algorithm to obtain a direct trust value;

[0049] An ultimate trust value acquisition module is configured to calculate an indirect trust value based on the direct trust value, aggregate the direct trust value and the indirect trust value through a dynamic weight algorithm to generate a local trust value, and aggregate all the local trust values to calculate an ultimate trust value;

[0050] A model parameter extraction module is configured to train a trust evaluation model based on the ultimate trust value, and obtain model parameters of the trust evaluation model after the training is completed;

[0051] A vehicle division module is configured to obtain model training accuracy of the trust evaluation model, calculate an evaluation value of each vehicle based on the ultimate trust value and the model training accuracy, and divide all the vehicles into a verification vehicle and a FL client based on the evaluation value;

[0052] A verification module is configured to obtain test set accuracy calculated by the verification vehicle and model training accuracy sent by the FL client, and determine whether an absolute value of a difference between the test set accuracy and the model training accuracy is not greater than a first preset threshold;

[0053] A model parameter integration module is configured to, if the absolute value of the difference is not greater than the first preset threshold, encapsulate the model parameters into a block transaction, and integrate the model parameters into a local trust evaluation model through a federated average algorithm.

[0054] In a third aspect, the present application provides a storage medium, which stores one or more programs, and the programs are executed by a processor to implement the blockchain intelligent-based trust management method for Internet of Vehicles described above.

[0055] In a fourth aspect, the present application provides an electronic device, which comprises a memory and a processor, wherein:

[0056] The memory is used to store a computer program;

[0057] The processor is used to execute the computer program stored on the memory to implement the blockchain intelligent-based trust management method for Internet of Vehicles described above.

[0058] Compared with the prior art, the present application has the following advantages:

[0059] 1. By applying blockchain intelligence in the trust management scheme, the decentralized, transparent, tamper-proof, and encrypted characteristics of the blockchain are utilized to effectively solve the storage problem of node trust values and model parameters, provide a reliable data source for the trust value evaluation algorithm based on deep learning, and at the same time avoid the leakage of local sensitive data during the continuous learning and dynamic upgrading of the algorithm model, ensuring the security and trustworthiness of the model sharing stage. On the other hand, the high-order computing power of machine learning is utilized to improve the accuracy of trust value calculation and reduce the resource consumption of the consensus mechanism, thereby improving the efficiency of block creation and publication.

[0060] 2. By using the deep learning algorithm to calculate the direct trust value of the node, the accuracy of trust value evaluation and the adaptability to environmental changes are improved by adding environmental indicators and algorithm model continuous updating effect indicators based on the conventional vehicle and event-related input parameters, thereby improving the recognition accuracy of internal malicious nodes.

[0061] 3. By applying blockchain-based federated learning in the trust value evaluation algorithm, vehicles and RSUs can utilize newly received V2X messages and trust scores during idle time to continuously learn and train the deep learning-based trust evaluation algorithm, thereby improving the dynamic characteristics of the algorithm.

[0062] 4. By using a consortium chain to store node final trust values, model parameters, and other information, and using a machine learning-based consensus mechanism, the training process and results of the trust evaluation model are used as the basis for evaluation workload. The higher the trust value of the node and the higher the accuracy and frequency of the new model contributed by the node, the more opportunities the node has to create and publish new blocks, thereby reducing the computational resource consumption of the node consensus process and improving the storage efficiency of node trust values and model parameters. BRIEF DESCRIPTION OF DRAWINGS

[0063] Figure 1An architecture diagram of a trust management scheme exemplified in an embodiment of the present application;

[0064] Figure 2 A flowchart of a blockchain intelligent-based trust management method for Internet of Vehicles proposed in an embodiment of the present application;

[0065] Figure 3 A deep learning algorithm schematic diagram exemplified in an embodiment of the present application;

[0066] Figure 4 A continuous learning schematic diagram of a trust evaluation algorithm exemplified in an embodiment of the present application;

[0067] Figure 5 A block structure schematic diagram exemplified in an embodiment of the present application;

[0068] Figure 6 A structure schematic diagram of a blockchain intelligent-based trust management system for Internet of Vehicles proposed in an embodiment of the present application.

[0069] The following specific embodiments will further illustrate the present application in combination with the above-mentioned drawings. DETAILED DESCRIPTION

[0070] In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be described clearly and completely below. Obviously, the described embodiments are only some of the embodiments of the present application, but not all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative work fall within the scope of protection of the present application. Unless otherwise defined, the technical terms or scientific terms used herein should be understood as the common meanings thereof by those of ordinary skill in the art to which the present application belongs. The words such as “comprise” and the like used herein mean that the elements or objects before the words cover the elements or objects listed after the words and their equivalents, and do not exclude other elements or objects.

[0071] The present application relates to a connected vehicle (CV), a roadside unit (RSU) and a trusted authority (TA), wherein:

[0072] (1)Intelligent networked vehicles are equipped with intelligent sensors and onboard communication units (OBU, Onboard unit), which support regular broadcast of V2X messages, including safety messages (BSM, Basic Safety Message) and traffic accident messages, through wireless vehicle network (such as 4G / 5G LTE or DSRC); vehicles receiving V2X messages first use deep learning algorithm (DL, Deep Learning) to calculate the direct trust value (DT, Direct Trust) of the message, and then broadcast the calculation result; surrounding vehicles use these direct trust values to calculate indirect trust values (Indirect Trust), and then integrate them into local trust values (LT, Local Trust) and send them to nearby RSUs; in addition, when the vehicle's computing resources are idle, use the recently received V2X messages and trust values to train the local deep learning algorithm, and share the training results with nearby other vehicles, including model parameters, model accuracy and local training set size; the vehicle with a higher comprehensive score is responsible for checking the model parameters shared by the vehicle, and if the verification is passed, it is uploaded to the nearby RSU.

[0073] (2)RSU broadcasts road condition messages and forwards received messages to all vehicles within its communication range; when receiving LT uploaded by nearby vehicles, RSU calculates the final trust value (FT, Final Trust) of the vehicle and broadcasts it; when receiving the trust evaluation model uploaded by nearby vehicles after verification, RSU integrates it into its own local model, and uses the V2X messages and trust values it has recently received to further train the model, and uses the training results to compete to create and publish blocks; all RSUs and TAs jointly maintain a blockchain (consortium chain) that stores the final trust values, model parameters and other related information of the nodes.

[0074] (3)TA is a fully trusted platform, all nodes need to register with TA and obtain valid certificates before joining the Internet of Vehicles, TA records the mapping relationship between the real identity and certificate of the node to prevent leakage of the node's privacy data; once the trust value of the node is lower than the set threshold, TA will determine it as a malicious node and revoke the node's certificate; TA as a read-only node, and all RSUs jointly maintain a blockchain.

[0075] In addition, as shown in Figure 1 , the trust management scheme architecture of the present application comprises in turn: trust storage layer, trust evaluation layer, trust sharing layer, trust application layer; in addition, it also contains two guarantee mechanisms: privacy protection mechanism and reward / punishment mechanism, wherein:

[0076] (1)The trust storage layer uses blockchain to store the final trust values, model parameters and other related information of the nodes, and uses a consensus mechanism based on machine learning.

[0077] (2)Trust evaluation layer includes trust algorithm definition, trust value calculation, trust value aggregation, trust value prediction and trust value update, this paper combines deep learning algorithm and traditional algorithm (sum, mean algorithm, etc.), and calculates the direct trust value, indirect trust value, local trust value and final trust value of the node in turn.

[0078] (3)Trust value propagation layer contains broadcast and query interface of trust value, and realizes sharing of trust value in the calculation process and after the calculation is completed.

[0079] (4)Trust value application layer mainly focuses on identification and processing of malicious nodes, including definition of trust threshold, label and certificate revocation management mechanism.

[0080] (5)Privacy protection mechanism is responsible for hiding the real ID of the node in the process of message sharing and data storage, preventing the analysis of the trajectory of the vehicle and other private data through the association of multiple V2X messages, and preventing the node from leaking sensitive information collected locally in the model sharing stage.

[0081] (6)Reward / punishment mechanism encourages nodes to actively participate in various activities in the Internet of Vehicles environment, including message sharing, continuous model training, block creation and release, etc.

[0082] As shown in Figure 1 , an embodiment of the present application proposes a blockchain intelligent-based trust management method for Internet of Vehicles, which comprises steps S101 to S106, wherein:

[0083] Step S101: input vehicle parameters, event parameters, environment parameters and model update parameters into a deep learning algorithm to obtain a direct trust value;

[0084] It should be noted that in this step, the vehicle parameters include the longitude of the vehicle, the latitude of the vehicle, the timestamp, the type of the vehicle, the speed of the vehicle, the acceleration, the direction of the vehicle, the sending vehicle trust value and the receiving vehicle trust value; the event parameters include the longitude of the event occurrence, the latitude of the event occurrence, the type of the event, such as collision, congestion, etc.; the environment parameters include the road condition, the traffic state, the weather, the emergency; the model update parameters include the model training accuracy, the size of the local training set and the model update frequency.

[0085] In addition, the direct trust value refers to the trust value of the rth message receiving vehicle V r The trust value of the s th message sending vehicle V s The calculated message. The direct trust value adopts a deep learning algorithm, i.e. a fully connected neural network (FCN), as shown in Figure 3As shown, it comprises an input layer, two hidden layers and an output layer, wherein the input layer comprises four types of feature values, which are extracted to V2X messages, surrounding environment and update records of algorithm model respectively; each hidden layer comprises 16 neurons; the output layer represents the direct trust value of the message sending vehicle, ranging from 0 to 1.

[0086] Specifically, in some embodiments, for the deep learning algorithm, the calculation formula of each layer is as follows:

[0087] y L =a L (W L y L-1 +b L );

[0088] wherein y L and y L-1 represent the output of the Lth layer and the (L-1)th layer respectively, W L , b L , a L () are the weight, bias and activation function of the Lth layer respectively, and the activation functions adopted by the input layer, hidden layer and output layer are ReLU, ReLU and Sigmoid respectively.

[0089] In addition, in some embodiments, the deep learning algorithm adopts gradient descent method to calculate W L , b L , wherein the loss function is calculated as follows:

[0090]

[0091] wherein L(W, b) is the loss value of the loss function of the deep learning algorithm, N represents the size of the training set, represents the true label of the trust value of the i-th training sample, represents the direct trust value of the i-th record calculated by the deep learning algorithm.

[0092] In addition, it should be pointed out that after the message receiving vehicle calculates the direct trust value of the message sending vehicle, it sends it to other nodes around in the form of broadcast.

[0093] Step S102: Calculate the indirect trust value according to the direct trust value, aggregate the direct trust value and the indirect trust value through a dynamic weight algorithm to generate a local trust value, and aggregate all the local trust values to calculate a final trust value;

[0094] It should be noted that the direct trust value is calculated using a deep learning algorithm, and in traditional technologies, the input parameters generally only consider vehicle and event related parameters, so the calculated trust value cannot adapt to changes in the environment (such as weather, whether it is a peak time to go to work or school, road conditions, etc.) and the contribution of continuous learning of the model (such as frequently contributing high-precision locally trained models, which are often more trustworthy). Based on this, the application adds environmental parameters and model update parameters to adapt to changes in the environment and the contribution of continuous learning of the model.

[0095] In addition, the indirect trust value is calculated according to the following formula:

[0096]

[0097] Where M represents the number of vehicles around the message receiving vehicle that broadcast the direct trust value of the message sending vehicle, FT r is the final trust value of the rth message receiving vehicle, DT s,r is the direct trust value of the st message sending vehicle calculated by the rth information receiving vehicle, IDT s,r is the indirect trust value of the st message sending vehicle calculated by the rth information receiving vehicle. That is, the calculation of the indirect trust value is to weight and sum all the direct trust values of the same message sending vehicle broadcast by the vehicles around the vehicle with the final trust value as the weight.

[0098] The local trust value is calculated according to the following formula:

[0099] LT s,r = θ s,r D s,r +(1-θ s,r )IDT s,r ;

[0100] Where LT s,r is the local trust value of the st message sending vehicle calculated by the rth information receiving vehicle, θ s,r is the comprehensive weight, which considers both the communication frequency and the interval distance between the message sending and receiving vehicles. When the two vehicles are close and communicate frequently, the direct trust value has a larger weight; otherwise, the indirect trust value has a larger weight. After calculating the local trust value, the message receiving vehicle uploads the trust value to the surrounding RSU.

[0101] The final trust value is calculated according to the following formula:

[0102]

[0103] Where P represents the number of vehicles around a roadside unit that report the local trust value of the same message sending vehicle, FT sLet be the final trust value of the vehicle that sent the s-th message. The final trust value is calculated by weighting the vehicle's final trust value and summing the local trust values ​​of all nearby vehicles that reported the same message.

[0104] Step S103: Train the trust assessment model based on the final trust value and obtain the model parameters of the trained trust assessment model;

[0105] It should be noted that, as Figure 4 As shown, the algorithm mainly uses recently collected V2X messages and final trust values ​​to train the local trust assessment algorithm. After completion, the model parameters (including weights and biases), the model's training accuracy, and the size of the local training set are broadcast externally.

[0106] Step S104: Obtain the model training accuracy of the trust evaluation model, calculate the evaluation value of each vehicle based on the final trust value and the model training accuracy, and divide all vehicles into verification vehicles and FL clients based on the evaluation value.

[0107] It should be noted that in the process of using a blockchain-based federated learning model to achieve continuous learning and knowledge sharing of the vehicle-local trust assessment model, firstly, a comprehensive score (evaluation value) is defined to periodically classify vehicles into FL clients and FL verifiers. The evaluation value is calculated according to the following formula:

[0108] CS = w1FT + w2ACC + w3FRW;

[0109] Where CS represents the vehicle's evaluation value, FT represents the vehicle's final trust value, ACC represents the model training accuracy of the trust evaluation model, FQR represents the update frequency, and w1, w2, and w3 are parameter weights that can be dynamically adjusted according to different scenarios.

[0110] Then, all the evaluation values ​​are sorted, and the top-ranked vehicles are selected as verification vehicles based on the sorting results. The remaining vehicles are used as FL clients, which are used to train the local trust evaluation model.

[0111] For example, the top 20% of vehicles in terms of overall score are selected as FL validators, responsible for verifying whether the accuracy of the trust value evaluation algorithm model trained by the FL client meets the requirements. The remaining vehicles act as FL clients, training their local models and uploading them to the FL validators. Note that the FL validators are only responsible for validating the models and do not participate in model training.

[0112] Furthermore, in some embodiments, the final trust value (FT) of the vehicle is compared. s and predefined trust threshold Thr mal When FTs < Thr mal , V s is marked as a malicious vehicle, the TA revokes the valid credentials of the node.

[0113] Step S105: Obtain the test set accuracy calculated by the verification vehicle and the model training accuracy sent by the FL client, and determine whether the absolute value of the difference between the test set accuracy and the model training accuracy is not greater than a first preset threshold value;

[0114] Step S106: If the absolute value of the difference between the test set accuracy and the model training accuracy is not greater than the first preset threshold value, the model parameters are encapsulated into a block transaction, and the federated averaging algorithm is used to integrate the model parameters into the local trust evaluation model.

[0115] It should be noted that, in order to enhance the generalization ability of the trust evaluation algorithm, the FL verifier vehicle uses the data collected in the recent period as a test set to verify whether the model shared by the FL client meets the accuracy requirement. Specifically, when the test set accuracy L r and the accuracy ACC sent by the FL client differ by a first preset threshold value δ1, i.e., |L r -ACC|≤δ1, the model parameters, the accuracy and the training set size received by the FL verifier are forwarded to the nearby RSU, i.e., the FL aggregator; otherwise, the model parameters are discarded.

[0116] The RSU encapsulates the received model parameters into a block transaction, and uses the federated averaging algorithm to integrate the model parameters into the local trust value evaluation algorithm model. Then, the RSU trains the model using the data collected by itself, and competes to publish a block through a proof-of-model training (PoMT) consensus algorithm. The federated averaging algorithm is as follows:

[0117]

[0118] where s l and s t are the local training set of the vehicle and the overall training set of the roadside unit, respectively, W rsu and b rsu are the weight and bias of the trust evaluation model based on deep learning integrated by the roadside unit, respectively, and W veh and b veh are the weight and bias of the trust evaluation model based on deep learning trained by the vehicle, respectively.

[0119] In some embodiments, all RSUs and TAs jointly maintain a consortium blockchain, which stores node trust values, trust evaluation model parameters, and other related data. The RSUs are responsible for writing blocks, and the TAs are only read-only nodes. Figure 5 As shown in FIG. 3, a block body contains two types of transaction information: trust values and trust evaluation model parameters. The trust value transaction contains the final trust value FL of a vehicle, the vehicle ID (Vid), and the RSU ID (Rid). The model parameter transaction contains the model parameters W, b, the model accuracy ACC, the local test set size s, the accuracy error ERR, the FL client ID (i.e., the vehicle ID, Vid), and the FL integrator ID (i.e., the RSU ID, Rid). Correspondingly, the block header also contains the hash values of the two MerkleRoots.

[0120] In some embodiments, when the RSU receives the already-verified model parameters uploaded by the FL verifier, the RSU integrates the model parameters into its local trust evaluation model and trains the model using the V2X messages and trust values collected by the RSU. The comprehensive scores of each RSU are calculated in the same way as the evaluation values, except that the model parameters in the RSUs are used in this calculation. Then, the RSUs with the top second preset proportion of comprehensive scores are selected to form a block publishing review committee, and the RSU with the highest comprehensive score creates a candidate block. The review committee includes multiple committee nodes, each of which corresponds to an RSU. The candidate block is sent to the review committee for verification. If the verification is passed, the committee nodes cast a yes vote, and if the verification is not passed, the committee nodes cast a no vote. If more than a third preset proportion of the votes are yes votes, the candidate block is confirmed to be published, and all RSUs add the selected block to the blockchain. If the third preset proportion of the votes is not exceeded, the candidate block is discarded.

[0121] Specifically, the consensus mechanism based on model training proof (PoMT) uses the comprehensive score CS (including model training accuracy ACC, update frequency FRQ, and vehicle final trust value FT) as the basis for selecting block publishing nodes. The specific workflow is as follows: after receiving the model parameters uploaded by the FL verifier, the RSU integrates the model parameters into its local model and trains the model using the V2X messages and trust values collected by the RSU. The comprehensive score CS of each RSU is calculated and arranged in descending order. A certain proportion (such as 20%, which can be dynamically adjusted as needed) of RSUs with higher scores form a block publishing review committee. The RSU with the highest score is allowed to create a candidate block and send it to the block review committee for verification. Each committee node first verifies the block signature and other basic information, and then uses the V2X messages and trust values collected by itself as a test set to verify the model parameters in the candidate block. If the accuracy difference is within the preset range, it means that the verification is passed, and the committee node casts a vote of approval; otherwise, it casts a vote of disapproval. If more than 2 / 3 of the committee nodes pass the verification, the block is allowed to be published, and all RSUs add the block to the blockchain; otherwise, the candidate block is discarded.

[0122] The current trust value storage scheme based on blockchain consumes a large amount of resources or lacks scalability, affecting the efficiency of block generation and publication. This embodiment uses blockchain to store the calculated trust values and model parameters after continuous learning. The structure of the block contains trust values and model parameters, and this part is designed for this scheme. In addition, a consensus mechanism based on model training proof (PoMT) is defined, which uses the comprehensive score CS (including model training accuracy ACC, update frequency FRQ, and vehicle final trust value FT) as the basis for selecting block publishing nodes. A block publishing review committee is also defined to verify the authenticity and reliability of the block before publishing.

[0123] In addition, the core idea of the consensus mechanism used in this paper is to combine the nodes participating in the Internet of Vehicles and trust management, and to add the concept of block publishing review committee for adaptation and optimization. The purpose of this embodiment is to replace the meaningless calculation resources consumed by hash operation in traditional consensus mechanism with continuous training of machine learning model to improve the accuracy of the model as proof of work to select suitable block publishing nodes. Without increasing additional resource consumption, the continuous learning and sharing of trust evaluation algorithm are realized.

[0124] 1. By applying blockchain intelligence in the trust management scheme, the storage problem of node trust value and model parameters is effectively solved by using the characteristics of decentralization, transparency, tamper resistance and encryption of blockchain, providing a reliable data source for trust value evaluation algorithm based on deep learning, while avoiding the leakage of local sensitive data in the process of continuous learning and dynamic upgrading of algorithm model, ensuring the security and trustworthiness of the model sharing stage. In turn, the high-order computing power of machine learning is used to improve the accuracy of trust value calculation, reduce the resource consumption of consensus mechanism, and improve the efficiency of block creation and publication.

[0125] 2. By using deep learning algorithm to calculate the direct trust value of nodes, on the basis of conventional vehicle and event related input parameters, environmental indicators and algorithm model continuous updating effect indicators are added, the accuracy of trust value evaluation and the adaptability to environmental changes are improved, and the identification accuracy of internal malicious nodes is improved.

[0126] 3. By applying blockchain-based federated learning in the trust value evaluation algorithm, vehicles and RSUs can use newly received V2X messages and trust scores during idle time to continuously learn and train the deep learning-based trust evaluation algorithm, improving the dynamic characteristics of the algorithm.

[0127] 4. By using alliance chain to store node final trust value, model parameters and other information, and using machine learning-based consensus mechanism, the training process and results of the trust evaluation model are used as the basis for evaluation workload. The higher the trust value of the node and the higher the accuracy and frequency of the new model contributed, the more opportunities the node has to create and publish new blocks, reducing the computational resource consumption of the node consensus process and improving the storage efficiency of the node trust value and model parameters.

[0128] As shown in Figure 6 , an embodiment of the present application proposes a blockchain intelligence-based Internet of Vehicles trust management system, which comprises:

[0129] A direct trust value acquisition module 10 is configured to input vehicle parameters, event parameters, environmental parameters and model update parameters into a deep learning algorithm to obtain a direct trust value.

[0130] A final trust value acquisition module 20 is configured to calculate an indirect trust value based on the direct trust value, aggregate the direct trust value and the indirect trust value through a dynamic weight algorithm to generate a local trust value, and aggregate all local trust values to calculate a final trust value.

[0131] A model parameter extraction module 30 is configured to train a trust evaluation model based on the final trust value and obtain model parameters of the trained trust evaluation model.

[0132] The vehicle division module 40 is configured to obtain the model training accuracy of the trust evaluation model, calculate the evaluation value of each vehicle according to the final trust value and the model training accuracy, and divide all vehicles into verification vehicles and FL clients according to the evaluation value.

[0133] The verification module 50 is configured to obtain the test set accuracy calculated by the verification vehicle and the model training accuracy sent by the FL client, and determine whether the absolute value of the difference between the test set accuracy and the model training accuracy is not greater than a first preset threshold.

[0134] The model parameter integration module 60 is configured to, if the absolute value of the difference between the test set accuracy and the model training accuracy is not greater than the first preset threshold, encapsulate the model parameters into a block transaction, and integrate the model parameters into the local trust evaluation model by using a federated average algorithm.

[0135] In another aspect, the application further provides a storage medium having one or more programs stored thereon, which, when executed by a processor, implement the above-mentioned blockchain intelligent-based trust management method for Internet of Vehicles.

[0136] In another aspect, the application further provides an electronic device including a memory and a processor, wherein the memory is configured to store a computer program, and the processor is configured to execute the computer program stored in the memory to implement the above-mentioned blockchain intelligent-based trust management method for Internet of Vehicles.

[0137] Those skilled in the art can understand that the logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a list of executable instructions for implementing logical functions, which can be specifically implemented in any computer readable medium for use by or in conjunction with an instruction execution system, device or apparatus, such as a computer-based system, a system including a processor or other system that can fetch and execute instructions from the instruction execution system, device or apparatus. For the purpose of the present specification, the "computer readable medium" can be any device that can contain, store, communicate, propagate or transport programs for use by or in conjunction with an instruction execution system, device or apparatus, or in conjunction with these instruction execution systems, devices or apparatus.

[0138] More specific examples (a non-exhaustive list) of the computer-readable medium include the following: an electrical connection (electronic) having one or more wires, a portable computer diskette (magnetic), a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), an optical fiber, and a portable compact disc read-only memory (CDROM). Additionally, the computer-readable medium can also be paper or another suitable medium upon which the program is printed, as the program can be electronically captured, for example, via an optical scanner, then compiled, interpreted, or otherwise processed, and stored in a computer memory in a form that is then suitable for use by the computer. The computer readable medium can also be a memory of a portable computing device, such as a floppy disk, a USB drive, a CD-ROM, a DVD, a Blu-Ray disk, a memory card, a ROM, a programmable ROM (EPROM), an erasable programmable ROM (EPROM), electronically erasable programmable ROM (EEPROM), a magnetic or optical disk, a tape, a cassette, or any other suitable memory of the like, for storing this computer program.

[0139] It should be understood that aspects of the application can be implemented in hardware, software, firmware or combinations thereof. In the embodiments described above, various steps or methods can be implemented, for example, in software or firmware that is stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, and in another embodiment, any of the following technologies, known in the art, or combinations thereof, can be used: discrete logic circuitry having logic gates for implementing logic functions upon data signals, application specific integrated circuits having appropriate combinational logic gates, programmable gate arrays (PGA), field programmable gate arrays (FPGA), and so forth.

[0140] While the embodiments of the application have been illustrated and described in detail, it will be clear to those skilled in the art that various modifications and changes can be made to the embodiments without departing from the scope and spirit of the application as set forth in the claims. It should be understood that the application as described in this specification can have other embodiments and be practiced or carried out in various ways.

Claims

1. A blockchain smart-based trust management method for Internet of Vehicles, characterized in that, The method comprises: inputting vehicle parameters, event parameters, environment parameters, model update parameters into a deep learning algorithm to obtain a direct trust value; calculating an indirect trust value from the direct trust value, and aggregating the direct trust value and the indirect trust value through a dynamic weight algorithm to generate a local trust value, and collecting all the local trust values to calculate a final trust value; training the trust evaluation model according to the final trust value, and obtaining model parameters of the trust evaluation model after the training is completed; obtaining model training accuracy of the trust evaluation model, calculating an evaluation value of each vehicle according to the final trust value and the model training accuracy, and dividing all the vehicles into a verification vehicle and an FL client according to the evaluation value; obtaining a test set accuracy calculated by the verification vehicle and a model training accuracy sent by the FL client, and judging whether an absolute value of a difference between the test set accuracy and the model training accuracy is not greater than a first preset threshold value; if not greater than the first preset threshold value, encapsulating the model parameters into a block transaction, and integrating the model parameters into the local trust evaluation model by using a federated average algorithm. 2.The blockchain smart-based trust management method for V2X according to claim 1, characterized in that, The step of inputting the vehicle parameters, the event parameters, the environment parameters, and the model update parameters into the deep learning algorithm to obtain the direct trust value comprises: The deep learning algorithm comprises an input layer, two hidden layers, and an output layer, and the calculation formula of each layer is as follows: y L = a L (W L y L-1 + b L ); where y L and y L-1 represent the output of the Lth layer and the (L-1)th layer, respectively, W L , b L , a L () are the weight, bias, and activation function of the Lth layer, respectively. The loss function of the deep learning algorithm is: Wherein, L(W, b) is the loss value of the loss function of the deep learning algorithm, N represents the size of the training set, represents the true label of the trust value of the i-th training sample, represents the direct trust value of the i-th record calculated by the deep learning algorithm. 3.The blockchain smart-based trust management method for V2X according to claim 2, characterized in that, The step of calculating the indirect trust value from the direct trust value, and aggregating the direct trust value and the indirect trust value through the dynamic weight algorithm to generate the local trust value, and collecting all the local trust values to calculate the final trust value comprises: The indirect trust value is calculated according to the following formula: where M represents the number of vehicles broadcasting the direct trust value of the message sending vehicle around the message receiving vehicle, FT r the final trust value for the rth message receiving vehicle, DT s,r the direct trust value of the sth message sending vehicle calculated by the rth message receiving vehicle, IDT s,r the indirect trust value of the sth message sending vehicle calculated by the rth message receiving vehicle; The local trust value is calculated according to the following formula: LT s,r = θ s,r DT s,r + (1 - θ s,r ) IDT s,r ; wherein LT s,r is the local trust value of the s-th information sending vehicle calculated by the r-th information receiving vehicle, θ s,r is the comprehensive weight; The final trust value is calculated according to the following formula: Wherein, P represents the number of vehicles reporting the local trust value of the same message sending vehicle around a roadside unit, FT s is the final trust value of the s-th information sending vehicle. 4.The blockchain smart-based trust management method for V2X according to claim 3, characterized in that, The step of obtaining the model training accuracy of the trust evaluation model, calculating the evaluation value of each vehicle according to the final trust value and the model training accuracy, and dividing all the vehicles into the verification vehicle and the FL client according to the evaluation value comprises: The evaluation value is calculated according to the following formula: CS = w1FT + w2ACC + w3FRQ; wherein CS represents the evaluation value of the vehicle, FT represents the final trust value of the vehicle, ACC is the model training accuracy of the trust evaluation model, FQR is the update frequency, and w1, w2, and w3 are parameter weights; all the evaluation values are sorted, and a first preset proportion of vehicles ranking at the top are selected as the verification vehicle according to the sorting result, and the remaining vehicles are selected as the FL client; The FL client is used to train the local trust evaluation model. 5.The blockchain smart-based trust management method for V2X according to claim 4, characterized in that, The step of judging whether the absolute value of the difference between the test set accuracy and the model training accuracy is not greater than the first preset threshold value further comprises: if greater than the first preset threshold value, the model parameters are discarded. 6.The blockchain smart-based trust management method for V2X according to claim 4, characterized in that, The expression of the federated average algorithm is: where s l , s t are the local training set size of the vehicle and the overall training set size of the road side unit, respectively, W rsu , b rsu are the weights and bias of the road side unit integrated deep learning based trust assessment model, respectively, W veh , b veh are the weights and bias of the vehicle trained deep learning based trust assessment model, respectively. 7.The blockchain smart-based trust management method for V2X according to claim 6, characterized in that, The method further comprises: When receiving the model parameters uploaded by the FL checker after verification, the RSU integrates the model parameters into the local trust evaluation model, and trains the model with the V2X messages and trust values collected by the RSU locally; The comprehensive scores of the RSUs are calculated, and RSUs with a comprehensive score in the top second preset proportion are selected to form a block publishing review committee, and an RSU with the highest comprehensive score creates a candidate block, the review committee includes multiple committee nodes, and each committee node corresponds to an RSU; The candidate block is sent to the review committee for verification, if the verification is passed, the committee node votes in favor, if the verification is not passed, the committee node votes against; If more than a third preset proportion of votes are in favor, the candidate block is confirmed to be published, and all RSUs add the selected block into the blockchain, if the third preset proportion of votes are not in favor, the candidate block is discarded. 8.A blockchain smart-based trust management system for Internet of Vehicles, characterized in that, The system comprises: A direct trust value acquisition module configured to input vehicle parameters, event parameters, environment parameters, and model update parameters into a deep learning algorithm to obtain a direct trust value; An ultimate trust value acquisition module configured to calculate an indirect trust value based on the direct trust value, aggregate the direct trust value and the indirect trust value through a dynamic weight algorithm to generate a local trust value, and aggregate all local trust values to calculate an ultimate trust value; A model parameter extraction module configured to train a trust evaluation model based on the ultimate trust value, and obtain model parameters of the trust evaluation model after training; A vehicle division module configured to obtain model training accuracy of the trust evaluation model, calculate an evaluation value of each vehicle based on the ultimate trust value and the model training accuracy, and divide all vehicles into verification vehicles and FL clients based on the evaluation value; A verification module configured to obtain test set accuracy calculated by the verification vehicles and model training accuracy sent by the FL clients, and determine whether an absolute value of a difference between the test set accuracy and the model training accuracy is not greater than a first preset threshold; A model parameter integration module configured to, if the absolute value of the difference is not greater than the first preset threshold, encapsulate the model parameters into a block transaction, and integrate the model parameters into a local trust evaluation model through a federated average algorithm.

9. A storage medium, characterized by The storage medium stores one or more programs, which are executed by the processor to implement the blockchain intelligent-based trust management method for Internet of Vehicles according to any one of claims 1-7. 10.An electronic device, comprising a memory and a processor, wherein: The memory is configured to store a computer program; The processor is configured to execute the computer program stored on the memory to implement the blockchain intelligent-based trust management method for Internet of Vehicles according to any one of claims 1-7. 10.An electronic device, comprising a memory and a processor, wherein: The memory is configured to store a computer program; The processor is configured to execute the computer program stored on the memory to implement the blockchain intelligent-based trust management method for Internet of Vehicles according to any one of claims 1-7.

Citation Information

Patent Citations

  • Collaborative model training method and device

    CN113537509A

  • Internet of vehicles federal learning method based on block chain

    CN118488075A