Analysis system and method for DPoS blockchain network security situation awareness
By generating adversarial networks and TOPSIS evaluation algorithms, the security situation of the DPoS blockchain network is quantified, and the network instability caused by node manipulation and geographical distribution concentration is solved, and the security situation awareness and management efficiency of the blockchain network is improved. .
Patent Information
- Application Number
- CN202211435668.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-11-16
- Publication Date
- 2025-01-07
- Estimated Expiration
- 2042-11-16
AI Technical Summary
There is a tendency in the DPoS blockchain network to centralize the election manipulation, difficulty in eliminating malicious nodes in a timely manner, and centralized node geographical distribution, and the lack of effective security situation awareness and evaluation mechanisms, resulting in network instability.
Generative adversarial network (WGAN-GP) is used for time series prediction and data filling, combined with improved TOPSIS evaluation algorithm with weights, quantify producer node stability and overall network security situation, and present results through visual system to achieve multiple results. View linkage explores the causes of abnormalities.
It realizes timely discovery and analysis of abnormal nodes in the blockchain network, reduces the difficulty of users to understand complex information, improves network management efficiency and data mining capabilities, and ensures network stability and security.
Smart Images

Figure CN115941291B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of blockchain, and in particular relates to an analysis system and method for DPoS blockchain network security situation awareness. Background Art
[0002] As an emerging technical framework, blockchain technology integrates peer-to-peer networks, asymmetric encryption, Merkle trees, consensus mechanisms, smart contracts and other technologies. In recent years, as the application of blockchain technology has gradually involved many traditional and emerging industries such as finance, energy, Internet of Things, government administration, healthcare, and transportation, blockchain technology has begun to become the focus of researchers. The DPoS consensus mechanism is considered suitable for large-scale application scenarios due to its high transaction throughput, low block latency and energy consumption, and has attracted a large number of decentralized application developers and users to participate. At the same time, users' demand for blockchain network security and stability monitoring is also growing. In the DPoS consensus mechanism, dedicated producer nodes are responsible for verifying and packaging transactions. The number of producer nodes in the network is fixed, and all coin holders in the network exchange votes for voting. Nodes that meet the corresponding standards can participate in the election. Only nodes with higher votes can obtain the right to package blocks, and the remaining nodes become standby nodes, only synchronizing on-chain data. However, blockchain networks based on DPoS will have the following risks:
[0003] (1) Block producer nodes and users with higher vote counts jointly manipulate election activities to harm the interests of ordinary users.
[0004] (2) The elected nodes are not necessarily all honest nodes. When an erroneous or malicious node appears, we can only hope that it will be eliminated in the next round of elections. Inactive voting will result in the malicious node not being removed in time.
[0005] (3) Currently, there is no mechanism for evaluating nodes, which makes it easy to select unqualified producer nodes and affect the stability of the overall network.
[0006] (4) The geographical distribution of nodes is too concentrated, and the inevitable centralization tendency threatens the integrity of blockchain data.
[0007] For the contributors to the construction of blockchain networks and related researchers, security situation awareness of blockchain networks is an effective way to test the above risks. Data visualization tools can effectively support the decision-making of professionals by using multiple visual channels to increase the amount of information transmitted while reducing the burden of information reduction, which brings convenience to decision-making.
[0008] With the widespread application of blockchain technology, many blockchain technology enthusiasts and related researchers have developed various blockchain visualization tools in recent years. One tool in the prior art is a series of visualization views designed for ordinary users using visual metaphors to help users understand the operating mechanism of the blockchain network and attract potential users to participate in the ecological construction of the blockchain network.
[0009] In general, current research on blockchain visualization focuses on account addresses, transaction data, etc., with only statistical presentation of data, lack of in-depth mining and exploration, and less attention paid to the overall security situation and evolution of blockchain networks. There are also relatively few visualization studies on blockchain networks with the later-emerging DPoS consensus mechanism. Summary of the invention
[0010] In view of the above-mentioned deficiencies in the prior art, the present invention provides an analysis system and method for DPoS blockchain network security situation awareness, which solves the problem of overall network instability caused by the inconvenient blockchain network security situation awareness and the inability to timely eliminate hidden dangers.
[0011] In order to achieve the above-mentioned invention object, the technical solution adopted by the present invention is: an analysis method for DPoS blockchain network security situation awareness, comprising the following steps:
[0012] S1. Obtain relevant feature data;
[0013] S2. quantifying the blockchain network value based on the community token value of the relevant feature data;
[0014] S3. Using the historical data of the blockchain network value as real samples, training an improved variant of the generative adversarial network, WGAN-GP, to obtain a WGAN-GP deep learning model;
[0015] S4. Use the WGAN-GP deep learning model to perform time series prediction, fill in missing values in the relevant feature data, and obtain complete data;
[0016] S5. quantifying the evaluation object using an improved TOPSIS evaluation algorithm with weights according to the complete data;
[0017] S6. Present the results of the producer node stability, the overall network security situation and the valid information in the relevant feature data using a visualization system.
[0018] The beneficial effects of the present invention are as follows: the quantitative method of the overall network security situation of the present invention can timely and effectively discover abnormal nodes that appear in the network during the evolution process, and explore the causes of abnormalities through the multi-view linkage of the interactive system, and use visual views rather than tables to present information, which not only makes it easier for ordinary users to get started and understand the relevant information of the blockchain network, but also makes it easier for researchers to obtain data analysis and mining results, timely detect defects in the blockchain network, provide support for improvement work, and help blockchain network managers verify whether the additional mechanism is effective. For time series prediction, the WGAN-GP deep learning model can generate samples faster because it does not need to generate different data in the sampling sequence, and only uses back propagation, without using the Markov decision chain. The WGAN-GP deep learning model can still make predictions with high accuracy in the face of sudden situations.
[0019] Furthermore, the method for acquiring relevant feature data in step S1 comprises the following steps:
[0020] S101, replaying the transaction in the blockchain network to obtain the original data of the transaction information, and extracting the producer node feature data from the original data;
[0021] S102, obtaining relevant network characteristic information on the Internet, and extracting network characteristic data from the network characteristic information;
[0022] S103: Asynchronously process the producer node feature data and the network feature data, and obtain relevant feature data after structuring.
[0023] The beneficial effects of the above further scheme are: obtaining the original data of transaction information from the blockchain network, and extracting relevant network feature information from the Internet, and obtaining relevant feature data after processing the original data and network feature information, so as to prepare for the subsequent quantification of the producer nodes and the overall security situation of the network.
[0024] Further, the WGAN-GP deep learning model in step S3 includes a generator and a discriminator;
[0025] The generator is used to synthesize virtual samples;
[0026] The discriminator is used to distinguish between real samples and virtual samples.
[0027] The beneficial effect of the above further scheme is: using the generator to synthesize virtual samples similar to real samples, and using the discriminator to identify the virtual samples, through continuous training, so that the virtual samples synthesized by the generator are as close to the real samples as possible, and finally the discriminator cannot identify the virtual samples, so that the virtual samples synthesized by the generator can directly replace the missing relevant feature data, preparing for the analysis and processing of the relevant feature data.
[0028] Furthermore, the generator includes a first gated recurrent unit GRU, a second gated recurrent unit GRU, a third gated recurrent unit GRU, a first fully connected layer, and a second fully connected layer; the number of neurons of the first gated recurrent unit GRU, the second gated recurrent unit GRU, and the third gated recurrent unit GRU are 1024, 512, and 256, respectively;
[0029] The discriminator includes a first convolutional layer, a second convolutional layer, a third convolutional layer, a third fully connected layer, a fourth fully connected layer and a fifth fully connected layer; the number of neurons in the first convolutional layer, the second convolutional layer and the third convolutional layer are 32, 64 and 128 respectively; the number of neurons in the third fully connected layer, the fourth fully connected layer and the fifth fully connected layer are 220, 220 and 1 respectively.
[0030] The beneficial effects of the above further scheme are: the generator using the three-layer gated recurrent unit GRU has better performance, the generator and the discriminator compete with each other, and the WGAN-GP deep learning model with good performance is trained to prepare for subsequent time series prediction.
[0031] Furthermore, the objective function of the WGAN-GP deep learning model is:
[0032]
[0033]
[0034] ε~U[0,1]
[0035] Among them, L is the objective function of the WGAN-GP deep learning model, λ is the penalty gradient coefficient, and P g is the distribution of fake samples generated by the generator, P r is the real sample distribution, is the random interpolation sampling distribution, is the false sample sample generated by the generator, x is the real sample sample, For x and Random interpolation sampling on the connection line, ε is a constant, is the expectation of false samples, is the identification result of the discriminator for the false sample, is the expectation of the real sample, D(x) is the identification result of the discriminator on the real sample, is the sample expectation of random interpolation sampling, The norm of the discriminator's identification results for randomly interpolated samples.
[0036] The beneficial effects of the above further scheme are as follows: the improved variant of the generative adversarial network WGAN-GP solves the problem of gradient being 0 during training. In addition, the improved variant of the generative adversarial network WGAN-GP also adds gradient penalty, which greatly enhances the training stability of the improved variant of the generative adversarial network WGAN-GP. For time series prediction, the WGAN-GP deep learning model can generate samples faster because it does not need to generate different data in the sampling sequence and only uses back propagation without using Markov decision chains. The WGAN-GP deep learning model can still make predictions with high accuracy in the face of sudden situations.
[0037] Furthermore, the quantification method of the evaluation object in step S5 includes the following steps:
[0038] S501. Obtain a feature matrix of the evaluation object according to the complete data:
[0039]
[0040] Among them, X is the feature matrix of the evaluation object, x nm is the value of the mth evaluation index of the nth evaluation object, n is the total number of evaluation objects, and m is the total number of evaluation indicators;
[0041] S502, performing positive processing on the negative evaluation index in the feature matrix to obtain positive data:
[0042]
[0043] i∈[1,n]
[0044] j∈[1,m]
[0045] Among them, max{·} is the maximum value function, min{·} is the minimum value function, and x ij is the value of the jth evaluation index of the i-th evaluation object, where i = 1, 2, ..., n, j = 1, 2, ...m;
[0046] S503, performing standardization processing on the positive data to obtain standardized data:
[0047]
[0048] Among them, z ijis the standardized data of the jth evaluation index of the i-th evaluation object;
[0049] S504, obtaining a standardized feature matrix according to the standardized data;
[0050] S505. Calculate the information entropy of each evaluation index according to the standardized feature matrix:
[0051]
[0052] Among them, E j is the information entropy of the jth evaluation index;
[0053] S506. Calculate the weight of each evaluation index according to the information entropy:
[0054]
[0055] Among them, w j is the weight of the jth evaluation index;
[0056] S507: According to the standardized data matrix, define the maximum value and the minimum value in the evaluation object:
[0057] Z + =(max{z 11 ,z 21 ,…,z n1},max{z 12 ,z 22 ,…,z n2},…,max{z 1m ,z 2m ,…,z nm})
[0058] Z - =(min{z 11 ,z 21 ,…,z n1},min{z 12 ,z 22 ,…,z n2},…,min{z 1m ,z 2m ,…,z nm})
[0059] Among them, Z + is the maximum value of the evaluation object, Z - is the minimum value of the evaluation object, z nm is the standardized data matrix of the mth evaluation index of the nth evaluation object;
[0060] S508: Calculate the distance between each evaluation object and the maximum value and the minimum value according to the maximum value, the minimum value and the weight of each evaluation index in the evaluation object:
[0061]
[0062]
[0063] in, is the distance between the i-th evaluation object and the maximum value, is the distance between the i-th evaluation object and the minimum value, is the maximum value of the jth evaluation index, is the minimum value of the jth evaluation index;
[0064] S509: Calculate the score of each producer node according to the distance between each evaluation object and the maximum value and the minimum value:
[0065]
[0066] Among them, S i is the score of the i-th evaluation object;
[0067] S5010, obtaining an evaluation ranking of the evaluation object according to the score of each evaluation object;
[0068] S5011, determining whether the evaluation object is a producer node, if so, proceeding to step S5011, otherwise, completing the quantification of the evaluation object;
[0069] S5012. Compare the differences between the evaluation ranking and the vote ranking of each producer node to obtain the stability of the producer node, and complete the quantification of the stability of the producer node:
[0070] T i =Rank s -Rank v
[0071] Among them, T i is the stability of the i-th producer node, Rank s Rank is the evaluation ranking of the producer node. v The vote ranking of the producer node.
[0072] The beneficial effects of the above further scheme are: the smaller the information entropy value of the evaluation index, the greater the degree of dispersion of the evaluation index, and the greater the influence of the evaluation index on the comprehensive evaluation (i.e., weight). Therefore, the weight of each evaluation index is calculated using the tool of information entropy, thereby avoiding the influence of subjective factors in the evaluation process; the score of the evaluation object is calculated based on the distance between the evaluation object and the maximum value, and the quantification of the evaluation object is completed. If it is a producer node, it is also necessary to compare the evaluation ranking with the vote ranking to quantify the stability of the producer node, thereby avoiding the subjectivity of the data, not requiring an objective function, not requiring testing, and well characterizing the comprehensive impact of multiple evaluation indicators.
[0073] The present invention provides an analysis system for DPoS blockchain network security situation awareness, including:
[0074] A first processing module, used for acquiring relevant feature data;
[0075] A second processing module, configured to quantify the blockchain network value according to the community token value of the relevant feature data;
[0076] A third processing module is used to train an improved variant of the generative adversarial network WGAN-GP using the historical data of the blockchain network value as real samples to obtain a WGAN-GP deep learning model;
[0077] A fourth processing module is used to use the WGAN-GP deep learning model to perform time series prediction, fill in missing values in the relevant feature data, and obtain complete data;
[0078] A fifth processing module, configured to quantify the stability of the producer node and the overall security situation of the network by using an improved TOPSIS evaluation algorithm with weights according to the complete data;
[0079] The sixth processing module is used to present the producer node stability, the overall network security situation and the valid information in the relevant feature data, and realize multi-view linkage.
[0080] The beneficial effects of the present invention are as follows: the modules interact to form a complete data transmission chain, and finally the effective information is displayed. The causes of the anomalies are explored through multi-view linkage, and information is presented in a visual view rather than a table. This not only makes it easier for ordinary users to get started and understand the relevant information of the blockchain network, but also makes it easier for researchers to obtain data analysis and mining results, timely detect defects in the blockchain network, provide support for improvement work, and help blockchain network managers verify whether the additional mechanism is effective. BRIEF DESCRIPTION OF THE DRAWINGS
[0081] Figure 1This is a flow chart of the analysis method for DPoS blockchain network security situation awareness in the present invention.
[0082] Figure 2 This is a flow chart of the method for obtaining relevant feature data in the present invention.
[0083] Figure 3 This is a data storage structure diagram of the relevant characteristic data in the present invention.
[0084] Figure 4 This is a framework diagram of the improved variant WGAN-GP of the generative adversarial network in the present invention.
[0085] Figure 5 The figure is a flow chart of the quantification method of the evaluation object in the present invention.
[0086] Figure 6 This is a structural diagram of the analysis system for DPoS blockchain network security situation awareness in the present invention.
[0087] Figure 7 This is a system architecture diagram of the analysis system for DPoS blockchain network security situation awareness in the present invention.
[0088] Figure 8 This is a system overview of the analysis system for DPoS blockchain network security situation awareness in the present invention. DETAILED DESCRIPTION
[0089] The specific implementation modes of the present invention are described below so that those skilled in the art can understand the present invention. However, it should be clear that the present invention is not limited to the scope of the specific implementation modes. For those of ordinary skill in the art, as long as various changes are within the spirit and scope of the present invention as defined and determined by the attached claims, these changes are obvious, and all inventions and creations utilizing the concept of the present invention are protected.
[0090] Example 1
[0091] like Figure 1 As shown, in one embodiment of the present invention, the present invention provides an analysis method for DPoS blockchain network security situation awareness, comprising the following steps:
[0092] S1. Obtain relevant feature data;
[0093] like Figure 2 As shown, the method for obtaining relevant feature data in step S1 includes the following steps:
[0094] S101, replaying the transaction in the blockchain network to obtain the original data of the transaction information, and extracting the producer node feature data from the original data;
[0095] S102: Obtain relevant network characteristic information on the Internet, and extract network characteristic data from the network characteristic information
[0096] S103: Asynchronously process the producer node feature data and the network feature data, and obtain relevant feature data after structuring.
[0097] In this embodiment, transactions are replayed in the blockchain network to obtain the original data of transaction information and related network feature information is obtained on the Internet and stored in a memory buffer. At the same time, the original data is asynchronously processed in the memory buffer to eliminate redundant information and serialized and stored in a storage device.
[0098] In this embodiment, the relevant feature data required by the present invention is extracted from the acquired data, and the feature items of the producer node are selected to reflect the status of the node from three aspects: node characteristics, performance, and benefits. The node characteristics include three characteristics: node name, node vote ranking, and node geographical location. The performance aspect includes four characteristics: block production quantity, packaged transaction volume, CPU consumption, and network resource consumption. The benefit aspect includes two characteristics: node account balance and node daily income. The network feature data selects the number of new users per day, the number of contract calls, external information reports, Google trends, and token unit price. The required feature data is structured to obtain relevant feature data, and the relevant feature data is stored in a MySQL database for subsequent query use. The data storage structure is as follows: Figure 3 shown.
[0099] S2. quantifying the blockchain network value based on the community token value of the relevant feature data;
[0100] In this embodiment, the value of the community token can represent the degree of attention paid by participating users to the blockchain network, so the value of the community token is used to quantify the value of the blockchain network.
[0101] S3, using the historical data of the blockchain network value as real samples to train an improved variant of the generative adversarial network WGAN-GP, and obtain a WGAN-GP deep learning model;
[0102] The WGAN-GP deep learning model in step S3 includes a generator and a discriminator;
[0103] The generator is used to synthesize virtual samples;
[0104] The discriminator is used to distinguish between real samples and virtual samples.
[0105] The generator includes a first gated recurrent unit GRU, a second gated recurrent unit GRU, a third gated recurrent unit GRU, a first fully connected layer and a second fully connected layer; the number of neurons of the first gated recurrent unit GRU, the second gated recurrent unit GRU and the third gated recurrent unit GRU are 1024, 512 and 256 respectively;
[0106] The discriminator includes a first convolutional layer, a second convolutional layer, a third convolutional layer, a third fully connected layer, a fourth fully connected layer and a fifth fully connected layer; the number of neurons in the first convolutional layer, the second convolutional layer and the third convolutional layer are 32, 64 and 128 respectively; the number of neurons in the third fully connected layer, the fourth fully connected layer and the fifth fully connected layer are 220, 220 and 1 respectively.
[0107] The objective function of the WGAN-GP deep learning model is:
[0108]
[0109]
[0110] ε~U[0,1]
[0111] Among them, L is the objective function of the WGAN-GP deep learning model, λ is the penalty gradient coefficient, and P g is the distribution of fake samples generated by the generator, P r is the real sample distribution, is the random interpolation sampling distribution, is the false sample sample generated by the generator, x is the real sample sample, For x and Random interpolation sampling on the connection line, ε is a constant, is the expectation of false samples, is the identification result of the discriminator for the false sample, is the expectation of the real sample, D(x) is the identification result of the discriminator on the real sample, is the sample expectation of random interpolation sampling, The norm of the discriminator's identification results for randomly interpolated samples.
[0112] In this embodiment, the model is trained by obtaining historical data of the blockchain network value. To ensure the training effect of the model, the present invention completes the model selection and hyperparameter adjustment in the experimental stage, and finally selects the improved variant WGAN-GP of the generative adversarial network. The framework of the improved variant WGAN-GP of the generative adversarial network selected in the experiment is as follows: Figure 4As shown in the figure, the community token value is used to represent the blockchain network value, which is the final predicted output value. The gated recurrent unit (GRU) is selected as the generator, and 7 feature variables are used to predict the future value of the token, namely the daily opening price, closing price, highest price, lowest price, EOSIO Google Trends, the number of new users in the network per day, and the total number of contract calls per day. In this article, the historical data of the first 30 days is used to predict the value of the next day. In order to build a generator with good performance, the model uses three layers of GRU, with the number of neurons being 1024, 512, and 256 respectively, and then two fully connected layers (Dense) are added. The number of neurons in the last layer is the same as the number of variables to be output. The discriminator in this model uses a convolutional neural network to distinguish whether the input data is real or fictitious. The input data of the discriminator will come from the original real data and the generated data of the generator. The discriminator contains three convolutional layers (Conv1d) with 32, 64 and 128 neurons respectively. The activation function uses LeakyReLU. Finally, three fully connected layers (Dense) are added with 220, 220 and 1 neurons respectively.
[0113] S4. Use the WGAN-GP deep learning model to perform time series prediction, fill in missing values in the relevant feature data, and obtain complete data;
[0114] In this embodiment, the WGAN-GP deep learning model is selected to fill in the missing values in the original data. The main purpose of this step is to obtain the complete trend of the network value evolution in the selected time period, to ensure that the normal analysis process will not be interrupted due to missing data items in the subsequent analysis method establishment and visualization system presentation, and the view presentation will not be abnormal.
[0115] S5. quantifying the evaluation object using an improved TOPSIS evaluation algorithm with weights according to the complete data;
[0116] like Figure 5 As shown, the quantification method of the evaluation object in step S5 includes the following steps:
[0117] S501. Obtain a feature matrix of the evaluation object according to the complete data:
[0118]
[0119] Among them, X is the feature matrix of the evaluation object, x nm is the value of the mth evaluation index of the nth evaluation object, n is the total number of evaluation objects, and m is the total number of evaluation indicators;
[0120] S502, performing positive processing on the negative evaluation index in the feature matrix to obtain positive data:
[0121]
[0122] i∈[1,n]
[0123] j∈[1,m]
[0124] Among them, max{·} is the maximum value function, min{·} is the minimum value function, and x ij is the value of the jth evaluation index of the i-th evaluation object, where i = 1, 2, ..., n, j = 1, 2, ...m;
[0125] S503, performing standardization processing on the positive data to obtain standardized data:
[0126]
[0127] Among them, z ij is the standardized data of the jth evaluation index of the i-th evaluation object;
[0128] S504, obtaining a standardized feature matrix according to the standardized data;
[0129] S505. Calculate the information entropy of each evaluation index according to the standardized feature matrix:
[0130]
[0131] Among them, E j is the information entropy of the jth evaluation index;
[0132] S506. Calculate the weight of each evaluation index according to the information entropy:
[0133]
[0134] Among them, w j is the weight of the jth evaluation index;
[0135] S507: According to the standardized data matrix, define the maximum value and the minimum value in the evaluation object:
[0136] Z + =(max{z 11 ,z 21 ,…,z n1},max{z 12 ,z 22 ,…,z n2},…,max{z 1m ,z 2m ,…,z nm})
[0137] Z- =(min{z 11 ,z 21 ,…,z n1},min{z 12 ,z 22 ,…,z n2},…,min{z 1m ,z 2m ,…,z nm})
[0138] Among them, Z + is the maximum value of the evaluation object, Z - is the minimum value of the evaluation object, z nm is the standardized data matrix of the mth evaluation index of the nth evaluation object;
[0139] S508: Calculate the distance between each evaluation object and the maximum value and the minimum value according to the maximum value, the minimum value and the weight of each evaluation index in the evaluation object:
[0140]
[0141]
[0142] in, is the distance between the i-th evaluation object and the maximum value, is the distance between the i-th evaluation object and the minimum value, is the maximum value of the jth evaluation index, is the minimum value of the jth evaluation index;
[0143] S509: Calculate the score of each producer node according to the distance between each evaluation object and the maximum value and the minimum value:
[0144]
[0145] Among them, S i is the score of the i-th evaluation object;
[0146] S5010, obtaining an evaluation ranking of the evaluation object according to the score of each evaluation object;
[0147] S5011, determining whether the evaluation object is a producer node, if so, proceeding to step S5011, otherwise, completing the quantification of the evaluation object;
[0148] S5012. Compare the differences between the evaluation ranking and the vote ranking of each producer node to obtain the stability of the producer node, and complete the quantification of the stability of the producer node:
[0149] Ti =Rank s -Rank v
[0150] Among them, T i is the stability of the i-th producer node, Rank s Rank is the evaluation ranking of the producer node. v The vote ranking of the producer node.
[0151] In this embodiment, in order to avoid the influence of subjective factors on the evaluation, the entropy weight method is used to calculate the feature weights of each evaluation object. The evaluation objects in the present invention include all producer nodes in the same period and the overall security situation of the network in different periods. The feature items of the producer nodes include node name, node vote ranking, node balance, node income status, block production quantity, packaged transaction volume, CPU consumption and network resource consumption. The feature items of the overall network security situation include the stability of a single node, the network value after filling processing and the degree of network decentralization. All producer nodes are sorted using the improved TOPSIS evaluation algorithm with weights, and then the producer nodes are sorted according to the number of votes of each node in the original data. The stability of the producer nodes is quantified by analyzing the difference between the evaluation ranking and the vote ranking of the producer nodes. The overall network security situation quantification method also first uses the entropy weight method to calculate the weights of each feature, and then uses the TOPSIS evaluation algorithm to sort the overall network security situation in the selected time series; the entropy weight method only considers the data level and is an objective weighting method based on the principle that the smaller the degree of variation of the indicator, the less information it reflects, and the corresponding weight should be lower.
[0152] S6. Present the results of the producer node stability, the overall network security situation and the valid information in the relevant feature data using a visualization system.
[0153] In this embodiment, the producer node stability and the overall network security situation obtained through the processing flow of steps S1-S5 are combined with the valid information extracted from the complete data, wherein the valid information includes the geographical location distribution of nodes, voting enthusiasm, ballot source information, network value evolution and external information reporting data, and the results are presented using a visualization system.
[0154] Example 2
[0155] like Figure 6 As shown, the present invention provides an analysis system for DPoS blockchain network security situation awareness, including:
[0156] A first processing module, used for acquiring relevant feature data;
[0157] A second processing module, configured to quantify the blockchain network value according to the community token value of the relevant feature data;
[0158] A third processing module is used to train an improved variant of the generative adversarial network WGAN-GP using the historical data of the blockchain network value as real samples to obtain a WGAN-GP deep learning model;
[0159] A fourth processing module is used to use the WGAN-GP deep learning model to perform time series prediction, fill in missing values in the relevant feature data, and obtain complete data;
[0160] A fifth processing module, configured to quantify the stability of the producer node and the overall security situation of the network by using an improved TOPSIS evaluation algorithm with weights according to the complete data;
[0161] The sixth processing module is used to present the producer node stability, the overall network security situation and the valid information in the relevant feature data, and realize multi-view linkage.
[0162] In this embodiment, the system architecture diagram is as follows: Figure 7 As shown, the system overview is as follows Figure 8 As shown in the figure, the node geographical distribution evolution view ( Figure 8 (A)) and network value evolution view ( Figure 8 (B)), Network stability evolution view ( Figure 8 (C)), node stability evolution view ( Figure 8 (D)), single node stability evolution view ( Figure 8 (E1)), Added vote source view ( Figure 8 (E2)) and the control panel ( Figure 8 (F)). Through the control panel ( Figure 8 (F)) Select the time period to be observed and the producer node list version number, node geographical distribution evolution view ( Figure 8 (A)) and network value evolution view ( Figure 8 (B)), Network stability evolution view ( Figure 8 (C)) can present the overall situation of the network. Selecting a specific version number can observe the source of new votes in that version. Through the node stability evolution view ( Figure 8 (D) Select the node of interest to jump to the single node stability evolution view ( Figure 8 (E1)) for observation. It supports observing the security situation of the entire blockchain network from the perspective of geographical distribution evolution, external environment changes, node stability and network stability, and can explore the causes of abnormal phenomena in more depth. The following introduces the design ideas of each view:
[0163] Node Geographic Distribution Evolution View ( Figure 8 (A)) is used to present the evolution of the geographical distribution of producer nodes. This embodiment uses a view similar to a strip chart and filled with bars to present the geographical distribution of nodes in the network. The time is used as the horizontal axis of the view, and the occupied range of the vertical axis is used to encode different regions. The proportion on the vertical axis represents the proportion of all nodes in the region in the entire network at that time. From top to bottom, the nodes in each region are ranked according to the total number of votes obtained. The density of the bar distribution in the view is used to encode the frequency of version updates of the producer node list.
[0164] Network Value Evolution View( Figure 8 (B)) is used to display the trend of token prices and external information at the same time. This view is similar to the node geographical distribution evolution view ( Figure 8 (A)) Shared horizontal axis, the background shows the value of blockchain network. The collected relevant information data is arranged in the form of scattered points according to the release time. The size of the scattered points indicates the popularity of the information. Clicking on the scattered points can jump to the specific information report page.
[0165] Network stability evolution view ( Figure 8 (C) is used to present the evolution of the overall stability of the blockchain network. The relative changes in the stability of the blockchain network within the selected version range are presented in the form of a line graph, with the version of the producer node list changed as the horizontal axis.
[0166] Node stability evolution view ( Figure 8 (D) is used to present the evolution of the stability of producer nodes in various versions. The horizontal axis of the view uses the version number of the producer node list, and the vertical axis is arranged from top to bottom according to the number of votes obtained by the producer node. Circular nodes are used to represent the current stability of the producer node. The same node is connected by straight lines in different versions. If the current producer node loses in the next round of elections, the straight line extends directly to the horizontal axis; if a candidate node loses in the previous round of elections but is successfully elected in this round, the straight line extends directly from the horizontal axis to the node. This way, it is indicated that these two types of nodes are more worthy of attention.
[0167] Single node stability evolution view ( Figure 8 (E1)) is used to present the stability evolution of a single producer node within the selected version range. The view is further designed based on the line graph. The horizontal axis is the version number and the vertical axis represents the gap between the two rankings. If the node fails to be successfully elected as a producer node in some versions, there is no need to draw a line in this range.
[0168] Added a new vote source view ( Figure 8(E2)) is used to represent the source of new votes for the single-selected producer node in the current version during the previous round of elections. The view is presented in a network diagram, where the nodes are composed of two types of nodes, namely producer nodes and voters. Voters are divided into two categories, including ordinary users (User) and proxies (Proxy). The thickness of the line between nodes is used to encode the number of votes.
Claims
1. An analysis method for DPoS blockchain network security situation awareness, characterized in that: The following steps are involved: S1. Obtain relevant feature data; S2. quantifying the blockchain network value based on the community token value of the relevant feature data; S3. Using the historical data of the blockchain network value as real samples, training an improved variant of the generative adversarial network, WGAN-GP, to obtain a WGAN-GP deep learning model; S4. Use the WGAN-GP deep learning model to perform time series prediction, fill in missing values in the relevant feature data, and obtain complete data; S5. According to the complete data, the evaluation object is quantified using an improved TOPSIS evaluation algorithm with weights; the quantification method of the evaluation object in step S5 comprises the following steps: S501. Obtain a feature matrix of the evaluation object according to the complete data: Among them, X is the feature matrix of the evaluation object, x nm is the value of the mth evaluation index of the nth evaluation object, n is the total number of evaluation objects, and m is the total number of evaluation indicators; S502, performing positive processing on the negative evaluation index in the feature matrix to obtain positive data: i∈[1,n] j∈[1,m] Among them, max{·} is the maximum value function, min{·} is the minimum value function, and x ij is the value of the jth evaluation index of the i-th evaluation object, where i = 1, 2, ..., n, j = 1, 2, ...m; S503, performing standardization processing on the positive data to obtain standardized data: Among them, z ij is the standardized data of the jth evaluation index of the i-th evaluation object; S504, obtaining a standardized feature matrix according to the standardized data; S505. Calculate the information entropy of each evaluation index according to the standardized feature matrix: Among them, E j is the information entropy of the jth evaluation index; S506. Calculate the weight of each evaluation index according to the information entropy: Among them, w j is the weight of the jth evaluation index; S507, define the maximum and minimum values in the evaluation object: WITH + =(max{z 11 ,With 21 ,…,With n1 },max{from 12 ,With 22 ,…,With n2 },…,max{from 1m ,With 2m ,…,With nm }) WITH - =(min{z 11 ,With 21 ,…,With n1 },min{z 12 ,With 22 ,…,With n2 },…,min{z 1m ,With 2m ,…,With nm }) Among them, Z + is the maximum value of the evaluation object, Z - is the minimum value of the evaluation object, z nm is the standardized data of the mth evaluation index of the nth evaluation object; S508: Calculate the distance between each evaluation object and the maximum value and the minimum value according to the maximum value, the minimum value and the weight of each evaluation index in the evaluation object: in, is the distance between the i-th evaluation object and the maximum value, is the distance between the i-th evaluation object and the minimum value, is the maximum value of the jth evaluation index, is the minimum value of the jth evaluation index; S509: Calculate the score of each producer node according to the distance between each evaluation object and the maximum value and the minimum value: Among them, S i is the score of the i-th evaluation object; S5010, obtaining an evaluation ranking of the evaluation object according to the score of each evaluation object; S5011, determining whether the evaluation object is a producer node, if so, proceeding to step S5011, otherwise, completing the quantification of the evaluation object; S5012. Compare the differences between the evaluation ranking and the vote ranking of each producer node to obtain the stability of the producer node, and complete the quantification of the stability of the producer node: T i =Rank s -Rank v Among them, T i is the stability of the i-th producer node, Rank s Rank is the evaluation ranking of the producer node. v The vote ranking of the producer node; S6. Present the results of the producer node stability, the overall network security situation and the valid information in the relevant feature data using a visualization system.
2. The analysis method for DPoS blockchain network security situation awareness according to claim 1 is characterized in that: The method for obtaining relevant feature data in step S1 comprises the following steps: S101, replaying the transaction in the blockchain network to obtain the original data of the transaction information, and extracting the producer node feature data from the original data; S102, obtaining relevant network characteristic information on the Internet, and extracting network characteristic data from the network characteristic information; S103: Asynchronously process the producer node feature data and the network feature data, and obtain relevant feature data after structuring.
3. The analysis method for DPoS blockchain network security situation awareness according to claim 1 is characterized in that: The WGAN-GP deep learning model in step S3 includes a generator and a discriminator; The generator is used to synthesize virtual samples; The discriminator is used to distinguish between real samples and virtual samples.
4. The analysis method for DPoS blockchain network security situation awareness according to claim 3 is characterized in that: The generator includes a first gated recurrent unit GRU, a second gated recurrent unit GRU, a third gated recurrent unit GRU, a first fully connected layer and a second fully connected layer; the number of neurons of the first gated recurrent unit GRU, the second gated recurrent unit GRU and the third gated recurrent unit GRU are 1024, 512 and 256 respectively; The discriminator includes a first convolutional layer, a second convolutional layer, a third convolutional layer, a third fully connected layer, a fourth fully connected layer and a fifth fully connected layer; the number of neurons in the first convolutional layer, the second convolutional layer and the third convolutional layer are 32, 64 and 128 respectively; the number of neurons in the third fully connected layer, the fourth fully connected layer and the fifth fully connected layer are 220, 220 and 1 respectively.
5. The analysis method for DPoS blockchain network security situation awareness according to claim 4 is characterized in that: The objective function of the WGAN-GP deep learning model is: ε~U[0,1] Among them, L is the objective function of the WGAN-GP deep learning model, λ is the penalty gradient coefficient, and P g is the distribution of fake samples generated by the generator, P r is the real sample distribution, is the random interpolation sampling distribution, is the false sample sample generated by the generator, x is the real sample sample, For x and Random interpolation sampling on the connection line, ε is a constant, is the expectation of false samples, is the identification result of the discriminator for the false sample, is the expectation of the real sample, D(x) is the identification result of the discriminator on the real sample, is the sample expectation of random interpolation sampling, The norm of the discriminator's identification results for randomly interpolated samples.
6. The analysis system of the analysis method for DPoS blockchain network security situation awareness according to any one of claims 1 to 5 is characterized in that: include: A first processing module, used for acquiring relevant feature data; A second processing module, configured to quantify the blockchain network value according to the community token value of the relevant feature data; A third processing module is used to train an improved variant of the generative adversarial network WGAN-GP using the historical data of the blockchain network value as real samples to obtain a WGAN-GP deep learning model; A fourth processing module is used to use the WGAN-GP deep learning model to perform time series prediction, fill in missing values in the relevant feature data, and obtain complete data; A fifth processing module, configured to quantify the stability of the producer node and the overall security situation of the network by using an improved TOPSIS evaluation algorithm with weights according to the complete data; The sixth processing module is used to present the producer node stability, the overall network security situation and the valid information in the relevant feature data, and realize multi-view linkage.
Citation Information
Patent Citations
Security risk assessment method for block chain
CN110309657A
Method and system for grading advantages and disadvantages of blockchain projects
CN112070373A