CN115334088B - Domain name system data synchronization method, device and system based on blockchain - Google Patents

Domain name system data synchronization method, device and system based on blockchain Download PDF

Info

Publication number
CN115334088B
CN115334088B CN202210974355.5A CN202210974355A CN115334088B CN 115334088 B CN115334088 B CN 115334088B CN 202210974355 A CN202210974355 A CN 202210974355A CN 115334088 B CN115334088 B CN 115334088B
Authority
CN
China
Prior art keywords
domain name
node
block
resolution server
name resolution
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202210974355.5A
Other languages
Chinese (zh)
Other versions
CN115334088A (en
Inventor
程筱彪
徐雷
张曼君
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China United Network Communications Group Co Ltd
Original Assignee
China United Network Communications Group Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China United Network Communications Group Co Ltd filed Critical China United Network Communications Group Co Ltd
Priority to CN202210974355.5A priority Critical patent/CN115334088B/en
Publication of CN115334088A publication Critical patent/CN115334088A/en
Application granted granted Critical
Publication of CN115334088B publication Critical patent/CN115334088B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/02Details
    • H04L12/16Arrangements for providing special services to substations
    • H04L12/18Arrangements for providing special services to substations for broadcast or conference, e.g. multicast
    • H04L12/1854Arrangements for providing special services to substations for broadcast or conference, e.g. multicast with non-centralised forwarding system, e.g. chaincast
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/14Network analysis or design
    • H04L41/142Network analysis or design using statistical or mathematical methods
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/12Applying verification of the received information
    • H04L63/123Applying verification of the received information received data contents, e.g. message integrity
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1095Replication or mirroring of data, e.g. scheduling or transport for data synchronisation between network nodes

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Algebra (AREA)
  • General Physics & Mathematics (AREA)
  • Mathematical Analysis (AREA)
  • Mathematical Optimization (AREA)
  • Mathematical Physics (AREA)
  • Probability & Statistics with Applications (AREA)
  • Pure & Applied Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention provides a domain name system data synchronization method, device and system based on a blockchain, and belongs to the technical field of networks. The method comprises the following steps: determining service nodes of the current period according to the reliability scores of the domain name resolution server nodes and a roulette algorithm; the service node gathers domain name update data of all root domain name resolution server nodes in the previous period to generate a first block, and broadcasts the first block to the whole network so that a verification node verifies the first block; and determining whether the whole network needs to synchronously update domain name update data corresponding to the first block according to the verification result. The method can solve the problem that the Internet cannot normally operate due to the fact that a root domain name server fails in the current domain name resolution system, and is used for constructing a decentralised domain name resolution system.

Description

Domain name system data synchronization method, device and system based on blockchain
Technical Field
The present invention relates to the field of network technologies, and in particular, to a domain name system data synchronization method, device and system based on blockchain.
Background
The domain name system (domain name system, DNS) serves as a key internet infrastructure, providing domain name to IP (Internet Protocol ) address resolution services for a large number of internet applications. The root domain name server is responsible for resolving the root zone and providing an index list of a Top Level Domain (TLD) server, and belongs to a centralized domain name resolution system, in which when the root domain name server fails, the internet cannot normally operate.
Disclosure of Invention
The invention aims to solve the technical problems of the prior art, and provides a domain name system data synchronization method, device and system based on a blockchain, which are used for at least solving the problem that the Internet cannot normally operate due to the fact that a root domain name server fails in the related art.
In a first aspect, the present invention provides a blockchain-based domain name system data synchronization method, a blockchain network including a plurality of root domain name resolution server nodes, the method comprising: determining service nodes of the current period according to the reliability scores of the domain name resolution server nodes and a roulette algorithm; the service node gathers domain name update data of all root domain name resolution server nodes in the previous period to generate a first block, and broadcasts the first block to the whole network so that a verification node verifies the first block; and determining whether the whole network needs to synchronously update domain name update data corresponding to the first block according to the verification result.
Preferably, the determining the service node of the current period according to the reliability score of each domain name resolution server node and the roulette algorithm specifically includes: obtaining the reliability score of each domain name resolution server node in the current period; calculating the cumulative probability of each root domain name resolution server node according to the reliability score of each root domain name resolution server node:
wherein Q is i For the cumulative probability of the i-th root domain name resolution server node, i=1, 2, …, N is the total number of root domain name resolution server nodes, P j For the probability of the jth root domain name resolution server node, P satisfies:
wherein r is i Reliable scoring for the ith root domain name resolution server node of the current period, r j For the jth root domain of the current periodReliability scoring of the name resolution server node; at [0,1]Randomly generates a number R in response to R<Q 1 Determining the service node of the current period as the 1 st root domain name resolution server node, responding to Q k-1 <R<Q k And determining the service node in the current period as a kth root domain name resolution server node.
Preferably, the obtaining the reliability score of each root domain name resolution server node in the current period specifically includes: after creating the blockchain network, setting the same reliability scoring initial value for all the root domain name resolution server nodes; and in response to the verification result of the first block generated by the service node in the previous period being normal, adjusting the reliability scores of the service node and the verification node in the previous period according to the following formula:
wherein r is the reliable score of the current period, r' is the reliable score of the previous period, w L Is of low threshold value, w H Is a high threshold; or, in response to the first block verification result generated by the service node in the previous period being abnormal or the verification result generated by the verification node in the previous period being wrong, correspondingly adjusting the reliability score of the service node or the verification node in the previous period according to the following formula: r=r' -w L
Preferably, after the service node gathers domain name update data of all root domain name resolution server nodes in the previous period to generate a first block and broadcasts the first block to the whole network, and before determining whether the whole network needs to synchronously update domain name update data corresponding to the first block according to the verification result, the domain name system data synchronization method based on the block chain further comprises: randomly selecting m nodes from other nodes except the service node in the blockchain network as verification nodes to verify a first block, wherein m=n is a first proportion, and the first proportion is more than 0 and less than 1; and after the first block verification result is that the information is correct, each verification node broadcasts a normal vote with a self signature, or after the first block verification result is that the information is tampered, each verification node broadcasts an abnormal vote with a self signature, after any verification node receives the normal vote number which is larger than the product of m and the second proportion, the normal vote, the self signature, the first block and the reliable scores of all nodes in the current period are summarized into the second block, so that the first block verification result is normal and broadcast to the whole network, or after any verification node receives the abnormal vote number which is larger than the product of m and the second proportion, the abnormal vote, the self signature, the first block in the previous period and the reliable scores of all nodes in the current period are summarized into the second block, so that the first block verification result is abnormal and broadcast to the whole network.
Preferably, the determining whether the whole network needs to synchronously update the domain name update data corresponding to the first block according to the verification result specifically includes: and determining that the domain name updating data corresponding to the first block is required to be synchronously updated in the current period by the whole network in response to the verification result being normal, or determining that the domain name updating data corresponding to the first block is not required to be synchronously updated in the current period by the whole network in response to the verification result being abnormal.
Preferably, after the service node gathers domain name update data of all root domain name resolution server nodes in the previous period to generate a first block and broadcasts the first block to the whole network, and before determining whether the whole network needs to synchronously update domain name update data corresponding to the first block according to the verification result, the domain name system data synchronization method based on the block chain further comprises: and when the service node generates a plurality of first blocks in the current period, broadcasting the plurality of first blocks to the whole network, and selecting a first block corresponding to the minimum hash value from the plurality of first blocks by the verification node for verification.
In a second aspect, the present invention further provides a blockchain-based domain name system data synchronization device, where a blockchain network includes a plurality of root domain name resolution server nodes, and the device includes a determining module, a broadcasting module, and a synchronization updating module.
And the determining module is used for determining the service node of the current period according to the reliability score of each domain name resolution server node and the roulette algorithm. And the broadcasting module is connected with the determining module and is used for collecting domain name updating data of all root domain name resolution server nodes in the previous period by the service node obtained by the determining module to generate a first block, and broadcasting the first block to the whole network so as to enable the verification node to verify the first block. And the synchronous updating module is connected with the broadcasting module and used for determining whether the whole network needs to synchronously update the domain name updating data corresponding to the first block according to the verification result.
Preferably, the determining module includes an acquiring unit, a calculating unit, and a determining unit.
And the obtaining unit is used for obtaining the reliability scores of the domain name resolution server nodes in the current period.
The computing unit is connected with the acquiring unit and is used for computing the cumulative probability of each domain name resolution server node according to the reliability scores of the domain name resolution server nodes:
wherein Q is i For the cumulative probability of the i-th root domain name resolution server node, i=1, 2, …, N is the total number of root domain name resolution server nodes, P j For the probability of the jth root domain name resolution server node, P satisfies:
wherein r is i Reliable scoring for the ith root domain name resolution server node of the current period, r j And (5) reliably scoring the jth root domain name resolution server node of the current period.
A determining unit connected with the calculating unit for determining the position of the first object in [0,1 ]]Randomly generates a number R in response to R<Q 1 Determining the service node of the current period as the 1 st root domain name resolution server node, responding to Q k-1 <R<Q k And (3) determiningThe service node in the current period is defined as the kth root domain name resolution server node.
Preferably, the acquisition unit comprises a setting component and an adjustment component.
And the setting component is used for setting the same reliability scoring initial value for all the root domain name resolution server nodes after the blockchain network is created.
The adjustment component is connected with the setting component and is used for adjusting the reliability scores of the service nodes and the verification nodes of the previous period according to the following formula in response to the verification result of the first block generated by the service nodes of the previous period being normal:
wherein r is the reliable score of the current period, r' is the reliable score of the previous period, w K Is of low threshold value, w H For a high threshold value of the value,
and the reliability score of the service node or the verification node of the previous period is correspondingly adjusted according to the following formula, wherein the reliability score is used for responding to the abnormal first block verification result generated by the service node of the previous period or the false verification result generated by the verification node of the previous period:
r=r′-w L
in a third aspect, the present invention also provides a blockchain-based domain name system data synchronization system comprising a memory having a computer program stored therein and a processor configured to run the computer program to implement the blockchain-based domain name system data synchronization method of the first aspect.
The invention provides a domain name system data synchronization method, a device and a system based on a blockchain, which are used for synchronously updating a alliance chain by a root domain name resolution server of each region based on the data of the blockchain forming a domain name system, wherein the alliance chain is used for determining service nodes in the current period based on the reliability score and a roulette algorithm of each root domain name resolution server node, issuing all domain name updating data generated in the previous period by the determined service nodes, verifying the data issued by the service nodes by a verification node, and synchronously updating the domain name updating data generated in the previous period by the whole network after verification is passed. Because the domain name resolution system based on the blockchain is established, the problem that the normal operation of the Internet is affected due to the failure of a root domain name server in the existing centralized domain name resolution system can be solved. And the domain name resolution system based on the blockchain can prevent information tampering, and has higher security. Further, the reliability of the service node determined by combining the reliability score of each domain name resolution server node and the roulette algorithm is higher, so that the reliability of a domain name resolution system based on a blockchain is improved.
Drawings
FIG. 1 is a flow chart of a domain name system data synchronization method based on blockchain in embodiment 1 of the present invention;
FIG. 2 is a schematic diagram of a domain name system data synchronization device based on blockchain according to embodiment 2 of the present invention;
fig. 3 is a schematic structural diagram of a domain name system data synchronization system based on blockchain in embodiment 3 of the present invention.
Detailed Description
In order to make the technical scheme of the present invention better understood by those skilled in the art, the following detailed description of the embodiments of the present invention will be given with reference to the accompanying drawings.
It is to be understood that the specific embodiments and figures described herein are merely illustrative of the invention, and are not limiting of the invention.
It is to be understood that the various embodiments of the invention and the features of the embodiments may be combined with each other without conflict.
It is to be understood that only the portions relevant to the present invention are shown in the drawings for convenience of description, and the portions irrelevant to the present invention are not shown in the drawings.
It should be understood that each unit and module in the embodiments of the present invention may correspond to only one physical structure, may be formed by a plurality of physical structures, or may be integrated into one physical structure.
It will be appreciated that, without conflict, the functions and steps noted in the flowcharts and block diagrams of the present invention may occur out of the order noted in the figures.
It is to be understood that the flowcharts and block diagrams of the present invention illustrate the architecture, functionality, and operation of possible implementations of systems, apparatuses, devices, methods according to various embodiments of the present invention. Where each block in the flowchart or block diagrams may represent a unit, module, segment, code, or the like, which comprises executable instructions for implementing the specified functions. Moreover, each block or combination of blocks in the block diagrams and flowchart illustrations can be implemented by hardware-based systems that perform the specified functions, or by combinations of hardware and computer instructions.
It should be understood that the units and modules related in the embodiments of the present invention may be implemented by software, or may be implemented by hardware, for example, the units and modules may be located in a processor.
Example 1:
the embodiment provides a domain name system data synchronization method based on a blockchain, wherein the blockchain network comprises a plurality of root domain name resolution server nodes, namely, independent root domain name resolution servers respectively established in all regions of the country form a alliance chain, and each node in the alliance chain corresponds to one root domain name resolution server. As shown in fig. 1, the method includes:
step 101, determining service nodes in the current period according to the reliability scores of the domain name resolution server nodes and the roulette algorithm.
In this embodiment, the reliability score is used to evaluate the reliability of the root domain name resolution server node, and the higher the reliability score, the higher the reliability of the root domain name resolution server node. The roulette algorithm is used for randomly selecting service nodes, and the probability of selecting the service nodes with high probability is high. The higher the reliability of both in combination with the determined service node, thereby improving the reliability of the blockchain-based domain name resolution system. In addition, the domain name resolution system established based on the blockchain can prevent data falsification, and has safety and traceability.
Optionally, step 101: the service node of the current period is determined according to the reliability score of each domain name resolution server node and the roulette algorithm, and the method specifically comprises the following steps of 1011-1013:
step 1011, obtaining the reliability score of each root domain name resolution server node in the current period.
In this embodiment, a service node needs to be determined in each period to collect and issue all domain name update data in the previous period, so that the reliability scores of all root domain name resolution server nodes need to be obtained in each period to determine the service node in the current period.
Step 1012, calculating the cumulative probability of each root domain name resolution server node according to the reliability score of each root domain name resolution server node:
wherein Q is i For the cumulative probability of the ith root dns server node, i=1, 2, …, N is the total number of root dns server nodes, for example, N has a value of 20, which illustrates that the blockchain network in this embodiment includes 20 root dns server nodes. P (P) j For the probability of the jth root domain name resolution server node, P satisfies:
wherein r is i Reliable scoring for the ith root domain name resolution server node of the current period, r j And (5) reliably scoring the jth root domain name resolution server node of the current period.
Step 1013, at [0,1]Randomly generates a number R in response to R<Q 1 Determining the service node of the current period as the 1 st root domain name resolution server node, responding to Q k-1 <R<Q k Determining the service node of the current period as the kth rootDomain name resolution server node.
In order to avoid the situation that the root domain name resolution server node with high reliability is continuously and circularly selected as the service node, so that the service node with the block chain network being centralized is enabled to continuously process the service, and the situation that the block chain network still cannot operate due to the fact that the service node breaks down is avoided, the service node is selected by adopting the roulette algorithm in combination with the reliability score, and the roulette algorithm is a random selection algorithm, so that the embodiment ensures the probability that all the root domain name resolution server nodes are selected as the service node, ensures the fairness of the service node being selected, and further improves the reliability of the whole network.
Optionally, step 1011: the method for obtaining the reliability score of each domain name resolution server node in the current period specifically comprises the following steps: after creating the blockchain network, setting the same reliability scoring initial value for all the root domain name resolution server nodes; and in response to the verification result of the first block generated by the service node in the previous period being normal, adjusting the reliability scores of the service node and the verification node in the previous period according to the following formula:
wherein r is the reliable score of the current period, r' is the reliable score of the previous period, w L Is of low threshold value, w H Is a high threshold; or, in response to the first block verification result generated by the service node in the previous period being abnormal or the verification result generated by the verification node in the previous period being wrong, correspondingly adjusting the reliability score of the service node or the verification node in the previous period according to the following formula: r=r' -w L
In this embodiment, when the domain name update data of the previous period is successfully issued, a reliability score is added to the service node and the verification node of the previous period in the present period, the reliability score increases faster (for example, the increasing amplitude is 1, of course, the amplitude can be set to l, and l is a positive number greater than 1) in the early stage of data synchronization, so as to pull the reliability score gap of each domain name resolution server node, and when the reliability score exceeds the low threshold and does not reach the high threshold, the reliability score increasing speed is slowed down (for example, the increasing amplitude is 1/N or other positive number smaller than 1), and when the reliability score exceeds the high threshold, the reliability score of the node is not increased but remains unchanged; if the domain name updating data of the previous period is not successfully issued (if the verification result of the first block issued by the service node is abnormal, or if the verification result fed back by the verification node is selected to be wrong, that is, the verification result of the verification node is inconsistent with the verification results of most other verification nodes), the service node or the verification node of the previous period is judged to have abnormal behavior, and then the reliability score is greatly reduced (if the reduced amplitude is a low threshold, the amplitude can be set to be other positive numbers larger than 1) for the service node or the verification node of the previous period in the current period. It should be noted that, the reliability score initial value, the low threshold value, and the high threshold value are all positive numbers, and the value can be set according to the user requirement. Preferably, after the data is synchronously run for a period of time and the reliability scores of the individual root domain name resolution server nodes are separated by a gap, the low threshold value can be set as an average value of the reliability scores of all the root domain name resolution server nodes, and the high threshold value can be set as the sum of the reliability scores of all the root domain name resolution server nodes multiplied by a second proportion, wherein the second proportion is m/N, and m is the number of verification nodes. The above method for adjusting the reliability score of the root domain name resolution server node can avoid the condition of being trapped in the centralized node to process the service, for example, in the conventional blockchain technology, once the node selected according to the first-round period reputation value sequence is a normal node, the reputation value of the node is continuously increased and continuously selected, thus the reputation value of the node newly added into the blockchain is very low, the probability of being selected is never avoided, the network is the centralized node to process the service, and once the centralized node fails, the reliability of the whole network is reduced. The reliability scoring method of the adjustment node in the embodiment makes the scoring difference between the newly added node and the old node smaller, and determines the service node based on a random roulette algorithm, so that all root domain name resolution server nodes in the blockchain have fair reliability scoring, have probability of being determined as the service node, realize the service processing of the decentralization node, and improve the reliability of the network. Further, the higher the reliability of the roulette algorithm, the higher the probability that the root domain name resolution server node is determined to be a service node, thereby further improving the reliability of the network.
Step 102, the service node gathers domain name update data of all root domain name resolution server nodes in the previous period to generate a first block, and broadcasts the first block to the whole network, so that the verification node verifies the first block.
And step 103, determining whether the whole network needs to synchronously update domain name update data corresponding to the first block according to the verification result.
Optionally, after step 102, and before step 103, the blockchain-based domain name system data synchronization method further includes: randomly selecting m different nodes from other nodes of the blockchain network except the service node determined in the step 101 as verification nodes to verify a first block, wherein m=n is a first proportion, and the first proportion is greater than 0 and less than 1, and if the first proportion takes a value of 1/10; and after the first block verification result is that the information is correct, each verification node broadcasts a normal vote with a self signature, or after the first block verification result is that the information is tampered, each verification node broadcasts an abnormal vote with a self signature, after any verification node receives a normal vote number which is larger than the product of m and a second proportion, the normal vote, the self signature, the first block and the reliable scores of all nodes in the current period are summarized into a second block, so that the first block verification result is normal and broadcast to the whole network, or after any verification node receives an abnormal vote number which is larger than the product of m and the second proportion, the abnormal vote, the self signature and the first block in the previous period and the reliable scores of all nodes in the current period are summarized into a second block, so that the first block verification result is abnormal and broadcast to the whole network, wherein the second proportion is larger than 0.5 and smaller than 1.
In this embodiment, m verification nodes are selected as verification nodes, instead of all other nodes except the service node, so that transmission traffic in the blockchain network can be reduced, and network resources can be saved. After each verification node verifies the correctness of the first block information, the verification node broadcasts the normal voting with the self signature, otherwise, if the verification node receives the tampered first block information, the verification node broadcasts the abnormal voting with the self signature. After a certain verification node receives the normal votes exceeding 2/3 of the number of the verification nodes, summarizing the final normal votes, own signature, a first block issued by a service node in the current period and reliable scoring information in the current period to one block to broadcast as a second block (namely a final block) in the current period, wherein the verification result of the first block in the current period is normal, so that the whole network updates domain name data in the current period; after a certain verification node receives abnormal votes exceeding 2/3 of the number of the verification nodes, the final abnormal votes, own signature, the first block of the previous period and reliable scoring information of the period are summarized to one block for broadcasting, and the verification result of the first block of the period is indicated to be abnormal, so that the whole network does not update domain name data. The first block issued by the service node is identified to be normal or not through a plurality of verification nodes, so that the safety of the whole block chain network is improved.
Optionally, step 103 specifically includes: and determining that the domain name updating data corresponding to the first block is required to be synchronously updated in the current period by the whole network in response to the verification result being normal, or determining that the domain name updating data corresponding to the first block is not required to be synchronously updated in the current period by the whole network in response to the verification result being abnormal.
Optionally, according to the descending order of the reliability scores of the nodes, determining a plurality of verification nodes from the rest of the root domain name resolution server nodes except the service nodes which are ranked at the front for common identification verification, wherein the verification nodes are high-reliability nodes, so that the reliability of the blockchain network is further improved.
Optionally, after the service node gathers domain name update data of all root domain name resolution server nodes in the previous period to generate a first block, and broadcasts the first block to the whole network, and before the whole network determines whether to synchronously update domain name update data corresponding to the first block according to the verification result, the data synchronization method further includes: and when the service node generates a plurality of first blocks in the current period, broadcasting the plurality of first blocks to the whole network, and selecting a first block corresponding to the minimum hash value from the plurality of first blocks by the verification node for verification.
In this embodiment, the determined service node may update the domain name update data again after issuing a first block due to the problems of error summary calculation, insufficient information collection, etc., and rebroadcast a new first block, that is, a plurality of first blocks may be generated in a certain period, and since the smaller hash value represents the later broadcasting time of the block, the information contained in the block is the latest information, and the first block corresponding to the minimum hash value is selected for verification.
According to the domain name system data synchronization method based on the blockchain, the root domain name resolution servers of all areas form the data synchronization updating alliance chains of the domain name system based on the blockchain, and the alliance chains are higher in reliability according to the service nodes determined by combining the reliability scores of the root domain name resolution server nodes and the roulette algorithm, so that the reliability of a domain name resolution system based on the blockchain is improved, and the situation that the Internet cannot normally operate due to the fact that the root domain name servers are out of order is avoided. And secondly, a domain name resolution system established based on the blockchain can prevent data tampering, and has safety and traceability. The first block issued by the service node is identified to be normal or not through a plurality of verification nodes, so that the safety of the whole block chain network is further improved. In addition, the reliability scoring method of the adjustment node in the embodiment makes the scoring difference between the newly added node and the old node smaller, and determines the service node based on a random roulette algorithm, so that all root domain name resolution server nodes in the blockchain have fair reliability scores, have probability of being determined as the service node, and realize the service processing of the decentralised node, thereby improving the reliability of the network.
Example 2:
as shown in fig. 2, the present embodiment provides a blockchain-based domain name system data synchronization apparatus, where a blockchain network includes a plurality of root domain name resolution server nodes, and the apparatus includes a determining module 21, a broadcasting module 22, and a synchronization updating module 23.
The determining module 21 is configured to determine the service node in the current period according to the reliability score of each root domain name resolution server node and the roulette algorithm.
The broadcasting module 22 is connected to the determining module 21, and is configured to aggregate domain name update data of all root domain name resolution server nodes in a previous period by the service node obtained by the determining module 21 to generate a first block, and broadcast the first block to the whole network, so that the verification node verifies the first block.
And the synchronous updating module 23 is connected with the broadcasting module 22 and is used for determining whether the whole network needs to synchronously update the domain name updating data corresponding to the first block according to the verification result.
Optionally, the determining module includes an acquiring unit, a calculating unit, and a determining unit.
And the obtaining unit is used for obtaining the reliability scores of the domain name resolution server nodes in the current period.
The computing unit is connected with the acquiring unit and is used for computing the cumulative probability of each domain name resolution server node according to the reliability scores of the domain name resolution server nodes:
wherein Q is i For the cumulative probability of the i-th root domain name resolution server node, i=1, 2, …, N is the total number of root domain name resolution server nodes, P j For the probability of the jth root domain name resolution server node, P satisfies:
wherein r is i Reliable scoring for the ith root domain name resolution server node of the current period, r j And (5) reliably scoring the jth root domain name resolution server node of the current period.
Determination unit and calculation sheetMeta-connection for use in [0,1 ]]Randomly generates a number R in response to R<Q 1 Determining the service node of the current period as the 1 st root domain name resolution server node, responding to Q k-1 <R<Q k And determining the service node in the current period as a kth root domain name resolution server node.
Optionally, the acquisition unit includes a setting component and an adjustment component.
And the setting component is used for setting the same reliability scoring initial value for all the root domain name resolution server nodes after the blockchain network is created.
The adjustment component is connected with the setting component and is used for adjusting the reliability scores of the service nodes and the verification nodes of the previous period according to the following formula in response to the verification result of the first block generated by the service nodes of the previous period being normal:
wherein r is the reliable score of the current period, r' is the reliable score of the previous period, w L Is of low threshold value, w H And the reliability score of the service node or the verification node of the previous period is correspondingly adjusted according to the following formula, wherein the high threshold is used for responding to the abnormal first block verification result generated by the service node of the previous period or the false verification result generated by the verification node of the previous period: r=r' -w L
Optionally, the blockchain-based domain name system data synchronization device further includes a selection module.
The selection module is respectively connected with the determination module, the broadcasting module and the synchronous updating module, and is used for randomly selecting m nodes from other nodes except the service node in the blockchain network as verification nodes, wherein m=N is a first proportion, the first proportion is larger than 0 and smaller than 1, each verification node is used for broadcasting normal votes with self signatures after the verification result of the first block is information correct, or broadcasting abnormal votes with self signatures after the verification result of the first block is information falsified, and summarizing the normal votes, the self signatures, the first block and the reliable scores of the nodes in the current period into a second block after the verification node receives the normal votes which are larger than the sum of m and the second proportion, so as to obtain the normal and broadcast to the whole network, or summarizing the abnormal, the self signatures, the first block of the previous period and the reliable scores of the nodes in the current period into the whole network after the verification node receives the abnormal votes which are larger than the sum of the m and the second proportion.
Optionally, the synchronous update module includes a first update unit and a second update unit.
And the first updating unit is used for determining that the whole network needs to synchronously update the domain name updating data corresponding to the first block in the current period in response to the verification result being normal.
And the second updating unit is used for determining that the whole network does not need to synchronously update the domain name updating data corresponding to the first block in the current period in response to the abnormal verification result.
Optionally, the selection module further comprises a selection unit. And the selecting unit is used for generating a plurality of first blocks in the current period by the service node, broadcasting the plurality of first blocks to the whole network, and selecting the first block corresponding to the minimum hash value from the plurality of first blocks by the verification node for verification.
Example 3:
as shown in fig. 3, the present embodiment provides a blockchain-based domain name system data synchronization system, which includes a memory 31 and a processor 32, wherein the memory 31 stores a computer program, and the processor 32 is configured to execute the computer program to implement the blockchain-based domain name system data synchronization method as described in embodiment 1.
In the blockchain-based domain name system data synchronization device provided in embodiment 2, in the blockchain-based domain name system data synchronization system provided in embodiment 3, the root domain name resolution server in each area forms the data synchronization update alliance chain of the domain name system based on the blockchain, and the alliance chain is higher in reliability according to the service node determined by combining the reliability score of the root domain name resolution server node and the roulette algorithm, so that the reliability of the blockchain-based domain name resolution system is improved, and the situation that the internet cannot normally operate due to the occurrence of faults of the root domain name resolution server is avoided. And secondly, a domain name resolution system established based on the blockchain can prevent data tampering, and has safety and traceability. The first block issued by the service node is identified to be normal or not through a plurality of verification nodes, so that the safety of the whole block chain network is further improved. In addition, the reliability scoring method of the adjustment node in the embodiment makes the scoring difference between the newly added node and the old node smaller, and determines the service node based on a random roulette algorithm, so that all root domain name resolution server nodes in the blockchain have fair reliability scores, have probability of being determined as the service node, and realize the service processing of the decentralised node, thereby improving the reliability of the network.
It is to be understood that the above embodiments are merely illustrative of the application of the principles of the present invention, but not in limitation thereof. Various modifications and improvements may be made by those skilled in the art without departing from the spirit and substance of the invention, and are also considered to be within the scope of the invention.

Claims (8)

1. A blockchain-based domain name system data synchronization method, wherein a blockchain network includes a plurality of root domain name resolution server nodes, the method comprising:
determining service nodes of the current period according to the reliability scores of the domain name resolution server nodes and a roulette algorithm;
the service node gathers domain name update data of all root domain name resolution server nodes in the previous period to generate a first block, and broadcasts the first block to the whole network so that a verification node verifies the first block;
determining whether the whole network needs to synchronously update domain name update data corresponding to the first block according to the verification result;
the service node of the current period is determined according to the reliability score of each domain name resolution server node and a roulette algorithm, and the method specifically comprises the following steps:
obtaining the reliability score of each domain name resolution server node in the current period;
calculating the cumulative probability of each root domain name resolution server node according to the reliability score of each root domain name resolution server node:
wherein Q is i For the cumulative probability of the i-th root domain name resolution server node, i=1, 2, …, N is the total number of root domain name resolution server nodes, P j For the probability of the jth root domain name resolution server node, P satisfies:
wherein r is i Reliable scoring for the ith root domain name resolution server node of the current period, r j Reliability scoring of the jth root domain name resolution server node of the current period;
at [0,1]Randomly generates a number R in response to R<Q 1 Determining the service node of the current period as the 1 st root domain name resolution server node, responding to Q k-1 <R<Q k And determining the service node in the current period as a kth root domain name resolution server node.
2. The blockchain-based domain name system data synchronization method according to claim 1, wherein the obtaining the reliability score of each root domain name resolution server node in the current period specifically comprises:
after creating the blockchain network, setting the same reliability scoring initial value for all the root domain name resolution server nodes;
and in response to the verification result of the first block generated by the service node in the previous period being normal, adjusting the reliability scores of the service node and the verification node in the previous period according to the following formula:
wherein r is the reliable score of the current period, r' is the reliable score of the previous period, w L Is of low threshold value, w H Is a high threshold;
or, in response to the first block verification result generated by the service node in the previous period being abnormal or the verification result generated by the verification node in the previous period being wrong, correspondingly adjusting the reliability score of the service node or the verification node in the previous period according to the following formula:
r=r′-w L
3. the blockchain-based domain name system data synchronization method of claim 1, wherein after the service node aggregates domain name update data of all root domain name resolution server nodes of a previous cycle to generate a first block and broadcasts the first block to the whole network, and before the determining whether the whole network needs to synchronously update domain name update data corresponding to the first block according to the verification result, further comprising:
randomly selecting m nodes from other nodes except the service node in the blockchain network as verification nodes to verify a first block, wherein m=n is a first proportion, and the first proportion is more than 0 and less than 1;
each verification node broadcasts a normal vote with its own signature in response to the first block verification result being that the information is correct, or broadcasts an abnormal vote with its own signature in response to the first block verification result being that the information is tampered,
and after any verification node receives the abnormal vote number which is greater than the product of m and the second proportion, the abnormal vote, the self signature, the first block of the previous period and the reliable scores of the nodes of the current period are summarized as the second block, so that the verification result of the first block is normal and broadcasted to the whole network.
4. The blockchain-based domain name system data synchronization method according to claim 1, wherein the determining whether the whole network needs to synchronously update the domain name update data corresponding to the first block according to the verification result specifically includes:
responding to the verification result as normal, determining that the whole network needs to synchronously update the domain name updating data corresponding to the first block in the current period,
or, in response to the verification result being abnormal, determining that the whole network does not need to synchronously update the domain name updating data corresponding to the first block in the current period.
5. The blockchain-based domain name system data synchronization method of claim 1, wherein after the service node aggregates domain name update data of all root domain name resolution server nodes of a previous cycle to generate a first block and broadcasts the first block to the whole network, and before the determining whether the whole network needs to synchronously update domain name update data corresponding to the first block according to the verification result, further comprising:
and when the service node generates a plurality of first blocks in the current period, broadcasting the plurality of first blocks to the whole network, and selecting a first block corresponding to the minimum hash value from the plurality of first blocks by the verification node for verification.
6. A domain name system data synchronization device based on a blockchain is characterized in that the blockchain network comprises a plurality of root domain name resolution server nodes, the device comprises a determination module, a broadcasting module and a synchronization updating module,
a determining module for determining the service node of the current period according to the reliability score of each domain name resolution server node and the roulette algorithm,
the broadcasting module is connected with the determining module and is used for collecting the domain name updating data of all the root domain name resolution server nodes in the previous period by the service node obtained by the determining module to generate a first block, broadcasting the first block to the whole network so as to enable the verification node to verify the first block,
the synchronous updating module is connected with the broadcasting module and used for determining whether the whole network needs to synchronously update domain name updating data corresponding to the first block according to the verification result;
the determining module comprises an acquiring unit, a calculating unit and a determining unit,
an obtaining unit, configured to obtain a reliability score of each root domain name resolution server node in the current period,
the computing unit is connected with the acquiring unit and is used for computing the cumulative probability of each domain name resolution server node according to the reliability scores of the domain name resolution server nodes:
wherein Q is i For the cumulative probability of the i-th root domain name resolution server node, i=1, 2, …, N is the total number of root domain name resolution server nodes, P j For the probability of the jth root domain name resolution server node, P satisfies:
wherein r is i Reliable scoring for the ith root domain name resolution server node of the current period, r j Reliability scores for the jth root domain name resolution server node for the current period,
a determining unit connected with the calculating unit forAt [0,1]Randomly generates a number R in response to R<Q 1 Determining the service node of the current period as the 1 st root domain name resolution server node, responding to Q k-1 <R<Q k And determining the service node in the current period as a kth root domain name resolution server node.
7. The blockchain-based domain name system data synchronization device of claim 6, wherein the acquisition unit includes a setup component and an adjustment component,
a setting component for setting the same reliability score initial value for all root domain name resolution server nodes after creating the blockchain network,
the adjustment component is connected with the setting component and is used for adjusting the reliability scores of the service nodes and the verification nodes of the previous period according to the following formula in response to the verification result of the first block generated by the service nodes of the previous period being normal:
wherein r is the reliable score of the current period, r' is the reliable score of the previous period, w L Is of low threshold value, w H For a high threshold value of the value,
and the reliability score of the service node or the verification node of the previous period is correspondingly adjusted according to the following formula, wherein the reliability score is used for responding to the abnormal first block verification result generated by the service node of the previous period or the false verification result generated by the verification node of the previous period:
r=r′-w L
8. a blockchain-based domain name system data synchronization system comprising a memory and a processor, the memory having a computer program stored therein, the processor being configured to run the computer program to implement the blockchain-based domain name system data synchronization method of any of claims 1-5.
CN202210974355.5A 2022-08-15 2022-08-15 Domain name system data synchronization method, device and system based on blockchain Active CN115334088B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210974355.5A CN115334088B (en) 2022-08-15 2022-08-15 Domain name system data synchronization method, device and system based on blockchain

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210974355.5A CN115334088B (en) 2022-08-15 2022-08-15 Domain name system data synchronization method, device and system based on blockchain

Publications (2)

Publication Number Publication Date
CN115334088A CN115334088A (en) 2022-11-11
CN115334088B true CN115334088B (en) 2024-02-27

Family

ID=83924028

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210974355.5A Active CN115334088B (en) 2022-08-15 2022-08-15 Domain name system data synchronization method, device and system based on blockchain

Country Status (1)

Country Link
CN (1) CN115334088B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108616613A (en) * 2018-04-13 2018-10-02 北京信息科技大学 A kind of decentralization root domain name service method and system based on block chain
CN108833603A (en) * 2018-05-28 2018-11-16 北京奇虎科技有限公司 A kind of method, server and system for realizing domain name mapping based on block chain
CN112468525A (en) * 2019-09-06 2021-03-09 傲为信息技术(江苏)有限公司 Domain name management system based on block chain
CN112527689A (en) * 2021-02-09 2021-03-19 腾讯科技(深圳)有限公司 Application testing method and device and storage medium

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109756589B (en) * 2019-02-20 2020-11-13 中国互联网络信息中心 Domain name information maintenance system based on block chain multi-party co-treatment

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108616613A (en) * 2018-04-13 2018-10-02 北京信息科技大学 A kind of decentralization root domain name service method and system based on block chain
CN108833603A (en) * 2018-05-28 2018-11-16 北京奇虎科技有限公司 A kind of method, server and system for realizing domain name mapping based on block chain
CN112468525A (en) * 2019-09-06 2021-03-09 傲为信息技术(江苏)有限公司 Domain name management system based on block chain
CN112527689A (en) * 2021-02-09 2021-03-19 腾讯科技(深圳)有限公司 Application testing method and device and storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
基于智能合约分布式多维数据的服务推荐系统;张海洋;《硕士电子期刊》;20211215;全文 *

Also Published As

Publication number Publication date
CN115334088A (en) 2022-11-11

Similar Documents

Publication Publication Date Title
CN112039964B (en) Node reputation consensus method based on block chain
CN110784346B (en) Reputation value-based PBFT consensus system and method
CN109543075B (en) Block generation method and system
CN109756589B (en) Domain name information maintenance system based on block chain multi-party co-treatment
CN107220130B (en) Method, device and system for realizing information consensus at nodes of block chain
US11930113B2 (en) Blockchain hybrid consensus-based system for maintaining domain name information
CN110796547A (en) Improved practical Byzantine fault-tolerant system based on alliance block chain
CN109542888B (en) Data modification and synchronization method, device, equipment and storage medium of block chain
CN111343208B (en) Block chain-based data detection method and device and computer-readable storage medium
CN111935207A (en) Block chain system consensus method based on improved C4.5 algorithm
CN111654395B (en) Voting information processing method, device, equipment and storage medium
Dini A secure and available electronic voting service for a large-scale distributed system
CN115225639B (en) Changing method and device for consensus trusted cluster, computer equipment and medium
CN111464631B (en) Service consensus method and device in alliance block chain
CN111931220A (en) Consensus processing method, device, medium and electronic equipment for block chain network
CN112395113A (en) Practical Byzantine fault-tolerant consensus method and device and readable storage medium
CN115334088B (en) Domain name system data synchronization method, device and system based on blockchain
CN112202647A (en) Test method, device and test equipment in block chain network
CN109995888B (en) Data updating method and network node of block chain Domain Name System (DNS) system
CN115189871A (en) Byzantine fault-tolerant consensus algorithm based on verifiable random function and threshold signature
CN114584326A (en) Block chain data processing method and device, electronic equipment and storage medium
CN112465516B (en) Block chain network-based device management method, related device and storage medium
CN112258184B (en) Method, apparatus, electronic device and readable storage medium for freezing blockchain network
KR102315226B1 (en) Block chain system based on consensus algorithm of proof-of-rule and method thereof
CN106027523A (en) Data collection method of distributed data system and distributed data system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant