CN110457956B - Consensus supervision method and system for data supervision-oriented block chain network - Google Patents

Consensus supervision method and system for data supervision-oriented block chain network Download PDF

Info

Publication number
CN110457956B
CN110457956B CN201910758926.XA CN201910758926A CN110457956B CN 110457956 B CN110457956 B CN 110457956B CN 201910758926 A CN201910758926 A CN 201910758926A CN 110457956 B CN110457956 B CN 110457956B
Authority
CN
China
Prior art keywords
node
verified
data
written
block chain
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
CN201910758926.XA
Other languages
Chinese (zh)
Other versions
CN110457956A (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.)
Chongqing Huayi Kangdao Technology Co ltd
Original Assignee
Chongqing Huayi Kangdao Technology 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 Chongqing Huayi Kangdao Technology Co ltd filed Critical Chongqing Huayi Kangdao Technology Co ltd
Priority to CN201910758926.XA priority Critical patent/CN110457956B/en
Publication of CN110457956A publication Critical patent/CN110457956A/en
Application granted granted Critical
Publication of CN110457956B publication Critical patent/CN110457956B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/602Providing cryptographic facilities or services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/64Protecting data integrity, e.g. using checksums, certificates or signatures

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Health & Medical Sciences (AREA)
  • Bioethics (AREA)
  • General Health & Medical Sciences (AREA)
  • Computer Hardware Design (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention provides a consensus supervision method and a supervision system of a data supervision-oriented block chain network, wherein the supervision method comprises the following steps: s1, the block chain link point to be written transmits the data to be written and the first verification code of the block chain to be written to the node to be verified; s2, the node to be verified verifies whether the received data is the data to be written in the block chain to be written in; s3, the next-stage node to be verified verifies whether the received data is the data sent by the node to be verified; s4, the last stage of node to be verified verifies whether the received data is the data sent by the last stage of node to be verified; and S5, if the to-be-written block chain link point verifies that the received data is the data sent by the last-stage to-be-verified node, the to-be-written block chain link point writes the to-be-written data of the to-be-written block chain into the block chain. The invention can supervise the data written into the blockchain network, prevent the data before being written into the blockchain network from being distorted and ensure the integrity of the written data.

Description

Consensus supervision method and system for data supervision-oriented block chain network
Technical Field
The invention relates to the technical field of data supervision, in particular to a consensus supervision method and a supervision system of a data supervision-oriented block chain network.
Background
In the supervision system, there may be multiple supervision departments supervising the same business field, and the emphasis is different. There is a relatively fixed supervision structure among the supervision departments. As shown in fig. 2, the circle represents a regulatory body, and the arrow represents a higher jurisdiction subordinate. In the structure, each department only has 0 or 1 superior department and 0 or more subordinate departments, and only one department in the supervision structure has no superior department. As shown in fig. 3, when there is a plurality of departments without an upper department, one virtual node is added as their upper department. The blockchain network is a p2p network, and nodes in the network can be subordinate to corresponding departments.
Disclosure of Invention
The invention aims to at least solve the technical problems in the prior art, and particularly creatively provides a consensus supervision method and a supervision system for a data supervision-oriented blockchain network.
In order to achieve the above object, the present invention provides a consensus supervision method for a data-supervision-oriented blockchain network, comprising the following steps:
s1, the block chain link point to be written transmits the data to be written and the first verification code of the block chain to be written to the node to be verified;
s2, the node to be verified verifies whether the received data is data to be written in the block chain to be written:
if the node to be verified verifies that the received data is the data to be written in the block chain to be written in, the node to be verified transmits the received data and the second verification code to the next-stage node to be verified; step S3 is executed;
if the node to be verified verifies that the received data is not the data to be written in the block chain to be written in, the node to be verified receives the data sent by the next block chain node to be written in; returning to step S2;
s3, the next-level node to be verified verifies whether the received data is the data sent by the node to be verified:
if the next-stage node to be verified verifies that the received data is the data sent by the node to be verified, the next-stage node to be verified transmits the received data and the third verification code to the next-stage node to be verified; step S4 is executed;
if the next-stage node to be verified verifies that the received data is not the data sent by the node to be verified, the next-stage node to be verified receives the data sent by the next-stage node to be verified; returning to step S3;
s4, the last node to be verified verifies whether the received data is the data sent by the previous node to be verified:
if the last-stage node to be verified verifies that the received data is the data sent by the last-stage node to be verified, the last-stage node to be verified transmits the received data and the last verification code to the block chain node to be written; step S5 is executed;
if the last-stage node to be verified verifies that the received data is not the data sent by the previous-stage node to be verified, the last-stage node to be verified receives the data sent by the next previous-stage node to be verified; returning to step S4;
s5, the block chain node to be written verifies whether the received data is the data sent by the last stage node to be verified:
if the to-be-written block chain link point verifies that the received data is the data sent by the last-stage to-be-verified node, the to-be-written block chain link point writes the to-be-written data to be written into the block chain;
if the data received by the link point of the block to be written is verified to be not the data sent by the node to be verified at the last stage, the link point of the block to be written receives the data sent by the node to be verified at the last stage next time; return is made to step S5.
In a preferred embodiment of the present invention, in step S1, the method for calculating the first verification code includes the steps of:
s11, acquiring data to be written in the block chain to be written;
s12, performing first information digest algorithm calculation on the data to be written in the block chain to be written in to obtain a first hash value; and calculating a first hash value of the data to be written of the block chain to be written by using a first information summary algorithm, so that the processing efficiency is improved, and the user experience on the node of the block chain to be written is enhanced.
And S13, encrypting the first hash value by using the private key configured on the block chain node to be written in to obtain a first verification code.
In a preferred embodiment of the present invention, in step S2, the method for verifying, by the node to be verified, whether the received data is to-be-written data of a block chain to be written includes the following steps:
s21, acquiring data to be written and a first verification code of the block chain to be written;
s22, performing second information digest algorithm calculation on the data to be written in the block chain to be written in to obtain a verification first hash value;
s23, decoding the first verification code by using a public key corresponding to the private key and configured by the block chain node to be written in to obtain a decoded first hash value;
s24, determining whether the verification first hash value is the same as the decoded first hash value:
if the first hash value is verified to be the same as the decoded first hash value, the node to be verified verifies that the received data is data to be written in the block chain to be written;
and if the first hash value is verified to be different from the decoded first hash value, the node to be verified verifies that the received data is not the data to be written in the block chain to be written.
In a preferred embodiment of the present invention, in step S2, the method for calculating the second verification code includes the steps of:
s41, acquiring data received by the node to be verified and sent by the block chain node to be written, wherein the data received by the node to be verified and sent by the block chain node to be written are the data to be written and the first verification code;
s42, performing third information digest algorithm calculation on the data received by the node to be verified and sent by the node to be written into the block chain to obtain a second hash value;
and S43, encrypting the second hash value by using the private key configured on the node to be verified to obtain a second verification code.
In a preferred embodiment of the present invention, in step S3, the method for verifying whether the received data by the next node to be verified is the data sent by the node to be verified includes the following steps:
s31, acquiring data and a second verification code received by the node to be verified; the data received by the node to be verified are data to be written and a first verification code;
s32, performing fourth information digest algorithm calculation on the data received by the node to be verified to obtain a verified second hash value; and calculating a second hash value of the data received by the node to be verified by using a fourth information summary algorithm, so that the processing efficiency is improved, and the user experience on the node to be verified is enhanced.
S33, decoding the second verification code by using a public key which is configured by the node to be verified and corresponds to the private key, so as to obtain a decoded second hash value;
s34, determining whether the verification second hash value is the same as the decoded second hash value:
if the second hash value is verified to be the same as the decoded second hash value, the next-stage node to be verified verifies that the received data is the data sent by the node to be verified;
and if the second hash value is verified to be different from the decoded second hash value, the next-stage node to be verified verifies that the received data is not the data sent by the node to be verified.
In a preferred embodiment of the present invention, the method for calculating the third verification code includes the steps of:
s61, acquiring data sent by the next-stage node to be verified, wherein the data sent by the next-stage node to be verified is the data received by the node to be verified and the second verification code;
s62, performing fifth information digest algorithm calculation on the data sent by the node to be verified and received by the next-stage node to be verified to obtain a third hash value;
and S63, encrypting the third hash value by using the private key configured on the next-level node to be verified to obtain a third verification code.
In a preferred embodiment of the present invention, the method for determining a to-be-written blockchain node includes: and judging which node has the most data uploaded from which node in the latest configured period time period, and which node is the to-be-written block chain node, namely the out-block node.
The invention also provides a supervision system of the consensus supervision method of the data supervision-oriented blockchain network, which comprises a to-be-written blockchain node module, a to-be-verified node module, a next-stage to-be-verified node module, … … and a last-stage to-be-verified node module;
the to-be-written block chain node module is used for transmitting to-be-written data and a first verification code of the to-be-written block chain to the to-be-verified node module, and writing the to-be-written data of the to-be-written block chain into the block chain after verification is passed;
the node module to be verified is used for verifying whether the received data is the data to be written in the block chain to be written in, and transmitting the received data and the second verification code to the next node module to be verified after the verification is passed;
the next-stage node module to be verified is used for verifying whether the received data is the data sent by the node module to be verified or not, and transmitting the received data and a third verification code to the next-stage node module to be verified after the verification is passed;
and the last-stage node module to be verified is used for verifying whether the received data is the data sent by the last-stage node to be verified, and transmitting the received data and the last verification code to the block chain node module to be written in after the verification is passed.
In a preferred embodiment of the present invention, the method for calculating the first verification code includes the steps of:
s11, acquiring data to be written in the block chain to be written;
s12, performing first information digest algorithm calculation on the data to be written in the block chain to be written in to obtain a first hash value;
s13, encrypting the first hash value by using a private key configured on the block chain node to be written in to obtain a first verification code;
and/or the calculation method of the second verification code comprises the following steps:
s41, acquiring data received by the node to be verified and sent by the block chain node to be written, wherein the data received by the node to be verified and sent by the block chain node to be written are the data to be written and the first verification code;
s42, performing third information digest algorithm calculation on the data received by the node to be verified and sent by the node to be written into the block chain to obtain a second hash value;
s43, encrypting the second hash value by using the private key configured on the node to be verified to obtain a second verification code;
and/or the calculation method of the third verification code comprises the following steps:
s61, acquiring data sent by the next-stage node to be verified, wherein the data sent by the next-stage node to be verified is the data received by the node to be verified and the second verification code;
s62, performing fifth information digest algorithm calculation on the data sent by the node to be verified and received by the next-stage node to be verified to obtain a third hash value;
and S63, encrypting the third hash value by using the private key configured on the next-level node to be verified to obtain a third verification code.
In a preferred embodiment of the present invention, a method for verifying whether received data is to-be-written data of a to-be-written block chain by a to-be-verified node module includes the following steps:
s21, acquiring data to be written and a first verification code of the block chain to be written;
s22, performing second information digest algorithm calculation on the data to be written in the block chain to be written in to obtain a verification first hash value;
s23, decoding the first verification code by using a public key corresponding to the private key and configured by the block chain node to be written in to obtain a decoded first hash value;
s24, determining whether the verification first hash value is the same as the decoded first hash value:
if the first hash value is verified to be the same as the decoded first hash value, the node to be verified verifies that the received data is data to be written in the block chain to be written;
if the first hash value is verified to be different from the first hash value, the node to be verified verifies that the received data is not the data to be written in the block chain to be written in;
and/or the next-stage node module to be verified verifies whether the received data is the data sent by the node to be verified, and the verification method comprises the following steps:
s31, acquiring data and a second verification code received by the node to be verified; the data received by the node to be verified are data to be written and a first verification code;
s32, performing fourth information digest algorithm calculation on the data received by the node to be verified to obtain a verified second hash value;
s33, decoding the second verification code by using a public key which is configured by the node to be verified and corresponds to the private key, so as to obtain a decoded second hash value;
s34, determining whether the verification second hash value is the same as the decoded second hash value:
if the second hash value is verified to be the same as the decoded second hash value, the next-stage node to be verified verifies that the received data is the data sent by the node to be verified;
and if the second hash value is verified to be different from the decoded second hash value, the next-stage node to be verified verifies that the received data is not the data sent by the node to be verified.
In summary, by adopting the above technical solution, the present invention can supervise the data written into the blockchain network, prevent the data written into the blockchain network from being tampered, and ensure the integrity of the written data.
Additional aspects and advantages of the invention will be set forth in part in the description which follows and, in part, will be obvious from the description, or may be learned by practice of the invention.
Drawings
The above and/or additional aspects and advantages of the present invention will become apparent and readily appreciated from the following description of the embodiments, taken in conjunction with the accompanying drawings of which:
FIG. 1 is a schematic flow diagram of the present invention.
Fig. 2 is a schematic diagram of the regulatory structure of the present invention.
FIG. 3 is a schematic diagram of the policing architecture of the present invention adding virtual nodes.
Detailed Description
Reference will now be made in detail to embodiments of the present invention, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar elements or elements having the same or similar function throughout. The embodiments described below with reference to the accompanying drawings are illustrative only for the purpose of explaining the present invention, and are not to be construed as limiting the present invention.
The invention provides a consensus supervision method of a data supervision-oriented block chain network, which comprises the following steps as shown in figure 1:
s1, the block chain link point to be written transmits the data to be written and the first verification code of the block chain to be written to the node to be verified;
s2, the node to be verified verifies whether the received data is data to be written in the block chain to be written:
if the node to be verified verifies that the received data is the data to be written in the block chain to be written in, the node to be verified transmits the received data and the second verification code to the next-stage node to be verified; step S3 is executed;
if the node to be verified verifies that the received data is not the data to be written in the block chain to be written in, the node to be verified receives the data sent by the next block chain node to be written in; returning to step S2;
s3, the next-level node to be verified verifies whether the received data is the data sent by the node to be verified:
if the next-stage node to be verified verifies that the received data is the data sent by the node to be verified, the next-stage node to be verified transmits the received data and the third verification code to the next-stage node to be verified; step S4 is executed;
if the next-stage node to be verified verifies that the received data is not the data sent by the node to be verified, the next-stage node to be verified receives the data sent by the next-stage node to be verified; returning to step S3;
s4, the last node to be verified verifies whether the received data is the data sent by the previous node to be verified:
if the last-stage node to be verified verifies that the received data is the data sent by the last-stage node to be verified, the last-stage node to be verified transmits the received data and the last verification code to the block chain node to be written; step S5 is executed;
if the last-stage node to be verified verifies that the received data is not the data sent by the previous-stage node to be verified, the last-stage node to be verified receives the data sent by the next previous-stage node to be verified; returning to step S4;
s5, the block chain node to be written verifies whether the received data is the data sent by the last stage node to be verified:
if the to-be-written block chain link point verifies that the received data is the data sent by the last-stage to-be-verified node, the to-be-written block chain link point writes the to-be-written data to be written into the block chain;
if the data received by the link point of the block to be written is verified to be not the data sent by the node to be verified at the last stage, the link point of the block to be written receives the data sent by the node to be verified at the last stage next time; return is made to step S5.
In a preferred embodiment of the present invention, in step S1, the method for calculating the first verification code includes the steps of:
s11, acquiring data to be written in the block chain to be written;
s12, performing first information digest algorithm calculation on the data to be written in the block chain to be written in to obtain a first hash value;
and S13, encrypting the first hash value by using the private key configured on the block chain node to be written in to obtain a first verification code.
In a preferred embodiment of the present invention, in step S2, the method for verifying, by the node to be verified, whether the received data is to-be-written data of a block chain to be written includes the following steps:
s21, acquiring data to be written and a first verification code of the block chain to be written;
s22, performing second information digest algorithm calculation on the data to be written in the block chain to be written in to obtain a verification first hash value;
s23, decoding the first verification code by using a public key corresponding to the private key and configured by the block chain node to be written in to obtain a decoded first hash value;
s24, determining whether the verification first hash value is the same as the decoded first hash value:
if the first hash value is verified to be the same as the decoded first hash value, the node to be verified verifies that the received data is data to be written in the block chain to be written;
and if the first hash value is verified to be different from the decoded first hash value, the node to be verified verifies that the received data is not the data to be written in the block chain to be written.
In a preferred embodiment of the present invention, in step S2, the method for calculating the second verification code includes the steps of:
s41, acquiring data received by the node to be verified and sent by the block chain node to be written, wherein the data received by the node to be verified and sent by the block chain node to be written are the data to be written and the first verification code;
s42, performing third information digest algorithm calculation on the data received by the node to be verified and sent by the node to be written into the block chain to obtain a second hash value;
and S43, encrypting the second hash value by using the private key configured on the node to be verified to obtain a second verification code.
In a preferred embodiment of the present invention, in step S3, the method for verifying whether the received data by the next node to be verified is the data sent by the node to be verified includes the following steps:
s31, acquiring data and a second verification code received by the node to be verified; the data received by the node to be verified are data to be written and a first verification code;
s32, performing fourth information digest algorithm calculation on the data received by the node to be verified to obtain a verified second hash value;
s33, decoding the second verification code by using a public key which is configured by the node to be verified and corresponds to the private key, so as to obtain a decoded second hash value;
s34, determining whether the verification second hash value is the same as the decoded second hash value:
if the second hash value is verified to be the same as the decoded second hash value, the next-stage node to be verified verifies that the received data is the data sent by the node to be verified;
and if the second hash value is verified to be different from the decoded second hash value, the next-stage node to be verified verifies that the received data is not the data sent by the node to be verified.
In a preferred embodiment of the present invention, the method for calculating the third verification code includes the steps of:
s61, acquiring data sent by the next-stage node to be verified, wherein the data sent by the next-stage node to be verified is the data received by the node to be verified and the second verification code;
s62, performing fifth information digest algorithm calculation on the data sent by the node to be verified and received by the next-stage node to be verified to obtain a third hash value;
and S63, encrypting the third hash value by using the private key configured on the next-level node to be verified to obtain a third verification code.
In this embodiment, the third verification code … … and the last verification code are calculated in the same way as the first verification code or/and the second verification code, and the data verification method for the last node to be verified to verify whether the received data is sent by the previous node to be verified is the same as the data to be written by the node to be verified to verify whether the received data is written into the block chain or/and the data verification method for the next node to be verified to verify whether the received data is sent by the node to be verified.
In a preferred embodiment of the present invention, the method for determining a to-be-written blockchain node includes: and judging which node has the most data uploaded from which node in the latest configured period time period, and which node is the to-be-written block chain node, namely the out-block node.
The invention also provides a supervision system of the consensus supervision method of the data supervision-oriented blockchain network, which comprises a to-be-written blockchain node module, a to-be-verified node module, a next-stage to-be-verified node module, … … and a last-stage to-be-verified node module;
the to-be-written block chain node module is used for transmitting to-be-written data and a first verification code of the to-be-written block chain to the to-be-verified node module, and writing the to-be-written data of the to-be-written block chain into the block chain after verification is passed;
the node module to be verified is used for verifying whether the received data is the data to be written in the block chain to be written in, and transmitting the received data and the second verification code to the next node module to be verified after the verification is passed;
the next-stage node module to be verified is used for verifying whether the received data is the data sent by the node module to be verified or not, and transmitting the received data and a third verification code to the next-stage node module to be verified after the verification is passed;
and the last-stage node module to be verified is used for verifying whether the received data is the data sent by the last-stage node to be verified, and transmitting the received data and the last verification code to the block chain node module to be written in after the verification is passed.
In a preferred embodiment of the present invention, the method for calculating the first verification code includes the steps of:
s11, acquiring data to be written in the block chain to be written;
s12, performing first information digest algorithm calculation on the data to be written in the block chain to be written in to obtain a first hash value;
s13, encrypting the first hash value by using a private key configured on the block chain node to be written in to obtain a first verification code;
and/or the calculation method of the second verification code comprises the following steps:
s41, acquiring data received by the node to be verified and sent by the block chain node to be written, wherein the data received by the node to be verified and sent by the block chain node to be written are the data to be written and the first verification code;
s42, performing third information digest algorithm calculation on the data received by the node to be verified and sent by the node to be written into the block chain to obtain a second hash value;
s43, encrypting the second hash value by using the private key configured on the node to be verified to obtain a second verification code;
and/or the calculation method of the third verification code comprises the following steps:
s61, acquiring data sent by the next-stage node to be verified, wherein the data sent by the next-stage node to be verified is the data received by the node to be verified and the second verification code;
s62, performing fifth information digest algorithm calculation on the data sent by the node to be verified and received by the next-stage node to be verified to obtain a third hash value;
and S63, encrypting the third hash value by using the private key configured on the next-level node to be verified to obtain a third verification code.
In a preferred embodiment of the present invention, a method for verifying whether received data is to-be-written data of a to-be-written block chain by a to-be-verified node module includes the following steps:
s21, acquiring data to be written and a first verification code of the block chain to be written;
s22, performing second information digest algorithm calculation on the data to be written in the block chain to be written in to obtain a verification first hash value;
s23, decoding the first verification code by using a public key corresponding to the private key and configured by the block chain node to be written in to obtain a decoded first hash value;
s24, determining whether the verification first hash value is the same as the decoded first hash value:
if the first hash value is verified to be the same as the decoded first hash value, the node to be verified verifies that the received data is data to be written in the block chain to be written;
if the first hash value is verified to be different from the first hash value, the node to be verified verifies that the received data is not the data to be written in the block chain to be written in;
and/or the next-stage node module to be verified verifies whether the received data is the data sent by the node to be verified, and the verification method comprises the following steps:
s31, acquiring data and a second verification code received by the node to be verified; the data received by the node to be verified are data to be written and a first verification code;
s32, performing fourth information digest algorithm calculation on the data received by the node to be verified to obtain a verified second hash value;
s33, decoding the second verification code by using a public key which is configured by the node to be verified and corresponds to the private key, so as to obtain a decoded second hash value;
s34, determining whether the verification second hash value is the same as the decoded second hash value:
if the second hash value is verified to be the same as the decoded second hash value, the next-stage node to be verified verifies that the received data is the data sent by the node to be verified;
and if the second hash value is verified to be different from the decoded second hash value, the next-stage node to be verified verifies that the received data is not the data sent by the node to be verified. In a preferred embodiment of the present invention, the first to fifth message digest algorithms use one or any combination of SHA1, MD5, and SHA 256.
While embodiments of the invention have been shown and described, it will be understood by those of ordinary skill in the art that: various changes, modifications, substitutions and alterations can be made to the embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the claims and their equivalents.

Claims (13)

1. A consensus supervision method for a data supervision-oriented blockchain network is characterized by comprising the following steps:
s1, the block chain link point to be written transmits the data to be written and the first verification code of the block chain to be written to the node to be verified;
s2, the node to be verified verifies whether the received data is data to be written in the block chain to be written:
if the node to be verified verifies that the received data is the data to be written in the block chain to be written in, the node to be verified transmits the received data and the second verification code to the next-stage node to be verified; step S3 is executed;
if the node to be verified verifies that the received data is not the data to be written in the block chain to be written in, the node to be verified receives the data sent by the next block chain node to be written in; returning to step S2;
s3, the next-level node to be verified verifies whether the received data is the data sent by the node to be verified:
if the next-stage node to be verified verifies that the received data is the data sent by the node to be verified, the next-stage node to be verified transmits the received data and the third verification code to the next-stage node to be verified; step S4 is executed;
if the next-stage node to be verified verifies that the received data is not the data sent by the node to be verified, the next-stage node to be verified receives the data sent by the next-stage node to be verified; returning to step S3;
s4, the last node to be verified verifies whether the received data is the data sent by the previous node to be verified:
if the last-stage node to be verified verifies that the received data is the data sent by the last-stage node to be verified, the last-stage node to be verified transmits the received data and the last verification code to the block chain node to be written; step S5 is executed;
if the last-stage node to be verified verifies that the received data is not the data sent by the previous-stage node to be verified, the last-stage node to be verified receives the data sent by the next previous-stage node to be verified; returning to step S4;
s5, the block chain node to be written verifies whether the received data is the data sent by the last stage node to be verified:
if the to-be-written block chain link point verifies that the received data is the data sent by the last-stage to-be-verified node, the to-be-written block chain link point writes the to-be-written data to be written into the block chain;
if the data received by the link point of the block to be written is verified to be not the data sent by the node to be verified at the last stage, the link point of the block to be written receives the data sent by the node to be verified at the last stage next time; return is made to step S5.
2. The method for consensus supervision of a data-policing-oriented blockchain network according to claim 1, wherein in step S1, the method for calculating the first verification code comprises the steps of:
s11, acquiring data to be written in the block chain to be written;
s12, performing first information digest algorithm calculation on the data to be written in the block chain to be written in to obtain a first hash value;
and S13, encrypting the first hash value by using the private key configured on the block chain node to be written in to obtain a first verification code.
3. The consensus supervision method of a data-policing-oriented blockchain network according to claim 1, wherein in step S2, the method for verifying whether the received data is the data to be written into the blockchain by the node to be verified comprises the following steps:
s21, acquiring data to be written and a first verification code of the block chain to be written;
s22, performing second information digest algorithm calculation on the data to be written in the block chain to be written in to obtain a verification first hash value;
s23, decoding the first verification code by using a public key corresponding to the private key and configured by the block chain node to be written in to obtain a decoded first hash value;
s24, determining whether the verification first hash value is the same as the decoded first hash value:
if the first hash value is verified to be the same as the decoded first hash value, the node to be verified verifies that the received data is data to be written in the block chain to be written;
and if the first hash value is verified to be different from the decoded first hash value, the node to be verified verifies that the received data is not the data to be written in the block chain to be written.
4. The method for consensus supervision of a data-policing-oriented blockchain network according to claim 1, wherein in step S2, the method for calculating the second verification code comprises the steps of:
s41, acquiring data received by the node to be verified and sent by the block chain node to be written, wherein the data received by the node to be verified and sent by the block chain node to be written are the data to be written and the first verification code;
s42, performing third information digest algorithm calculation on the data received by the node to be verified and sent by the node to be written into the block chain to obtain a second hash value;
and S43, encrypting the second hash value by using the private key configured on the node to be verified to obtain a second verification code.
5. The method for consensus supervision of a data-policing-oriented blockchain network according to claim 1, wherein in step S3, the method for verifying the next node to be verified to verify whether the received data is the data sent by the node to be verified comprises the following steps:
s31, acquiring data and a second verification code received by the node to be verified; the data received by the node to be verified are data to be written and a first verification code;
s32, performing fourth information digest algorithm calculation on the data received by the node to be verified to obtain a verified second hash value;
s33, decoding the second verification code by using a public key which is configured by the node to be verified and corresponds to the private key, so as to obtain a decoded second hash value;
s34, determining whether the verification second hash value is the same as the decoded second hash value:
if the second hash value is verified to be the same as the decoded second hash value, the next-stage node to be verified verifies that the received data is the data sent by the node to be verified;
and if the second hash value is verified to be different from the decoded second hash value, the next-stage node to be verified verifies that the received data is not the data sent by the node to be verified.
6. The consensus supervision method of data-policing-oriented blockchain network according to claim 4, wherein in step S3, the calculation method of the third verification code comprises the following steps:
s61, acquiring data sent by the next-stage node to be verified, wherein the data sent by the next-stage node to be verified is the data received by the node to be verified and the second verification code;
s62, performing fifth information digest algorithm calculation on the data sent by the node to be verified and received by the next-stage node to be verified to obtain a third hash value;
and S63, encrypting the third hash value by using the private key configured on the next-level node to be verified to obtain a third verification code.
7. The consensus supervision method for data policing oriented blockchain network according to claim 1, characterized in that the method of determining the blockchain node to be written is: and judging which node has the most data uploaded from which node in the latest configured period time period, and which node is the to-be-written block chain node, namely the out-block node.
8. The supervision system of the consensus supervision method for the data supervision-oriented blockchain network according to any one of claims 1 to 7, comprising a to-be-written blockchain node module, a to-be-verified node module, a next-stage to-be-verified node module, … …, and a last-stage to-be-verified node module;
the to-be-written block chain node module is used for transmitting to-be-written data and a first verification code of the to-be-written block chain to the to-be-verified node module, and writing the to-be-written data of the to-be-written block chain into the block chain after verification is passed;
the node module to be verified is used for verifying whether the received data is the data to be written in the block chain to be written in, and transmitting the received data and the second verification code to the next node module to be verified after the verification is passed;
the next-stage node module to be verified is used for verifying whether the received data is the data sent by the node module to be verified or not, and transmitting the received data and a third verification code to the next-stage node module to be verified after the verification is passed;
and the last-stage node module to be verified is used for verifying whether the received data is the data sent by the last-stage node to be verified, and transmitting the received data and the last verification code to the block chain node module to be written in after the verification is passed.
9. The system of claim 8, wherein the method for calculating the first validation code comprises the following steps:
s11, acquiring data to be written in the block chain to be written;
s12, performing first information digest algorithm calculation on the data to be written in the block chain to be written in to obtain a first hash value;
and S13, encrypting the first hash value by using the private key configured on the block chain node to be written in to obtain a first verification code.
10. The system of claim 8, wherein the second validation code is calculated by a method comprising:
s41, acquiring data received by the node to be verified and sent by the block chain node to be written, wherein the data received by the node to be verified and sent by the block chain node to be written are the data to be written and the first verification code;
s42, performing third information digest algorithm calculation on the data received by the node to be verified and sent by the node to be written into the block chain to obtain a second hash value;
and S43, encrypting the second hash value by using the private key configured on the node to be verified to obtain a second verification code.
11. The system of claim 8, wherein the third verification code is calculated by the method comprising:
s61, acquiring data sent by the next-stage node to be verified, wherein the data sent by the next-stage node to be verified is the data received by the node to be verified and the second verification code;
s62, performing fifth information digest algorithm calculation on the data sent by the node to be verified and received by the next-stage node to be verified to obtain a third hash value;
and S63, encrypting the third hash value by using the private key configured on the next-level node to be verified to obtain a third verification code.
12. The supervision system of a consensus supervision method of a data-policing-oriented blockchain network according to claim 8, wherein the verification method of the node module to be verified verifying whether the received data is the data to be written into the blockchain comprises the following steps:
s21, acquiring data to be written and a first verification code of the block chain to be written;
s22, performing second information digest algorithm calculation on the data to be written in the block chain to be written in to obtain a verification first hash value;
s23, decoding the first verification code by using a public key corresponding to the private key and configured by the block chain node to be written in to obtain a decoded first hash value;
s24, determining whether the verification first hash value is the same as the decoded first hash value:
if the first hash value is verified to be the same as the decoded first hash value, the node to be verified verifies that the received data is data to be written in the block chain to be written;
and if the first hash value is verified to be different from the decoded first hash value, the node to be verified verifies that the received data is not the data to be written in the block chain to be written.
13. The system for supervising the consensus supervision method of the data-policing-oriented blockchain network according to claim 8, wherein the method for verifying whether the received data is the data sent by the node to be verified by the next node module to be verified comprises the following steps:
s31, acquiring data and a second verification code received by the node to be verified; the data received by the node to be verified are data to be written and a first verification code;
s32, performing fourth information digest algorithm calculation on the data received by the node to be verified to obtain a verified second hash value;
s33, decoding the second verification code by using a public key which is configured by the node to be verified and corresponds to the private key, so as to obtain a decoded second hash value;
s34, determining whether the verification second hash value is the same as the decoded second hash value:
if the second hash value is verified to be the same as the decoded second hash value, the next-stage node to be verified verifies that the received data is the data sent by the node to be verified;
and if the second hash value is verified to be different from the decoded second hash value, the next-stage node to be verified verifies that the received data is not the data sent by the node to be verified.
CN201910758926.XA 2019-08-16 2019-08-16 Consensus supervision method and system for data supervision-oriented block chain network Active CN110457956B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910758926.XA CN110457956B (en) 2019-08-16 2019-08-16 Consensus supervision method and system for data supervision-oriented block chain network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910758926.XA CN110457956B (en) 2019-08-16 2019-08-16 Consensus supervision method and system for data supervision-oriented block chain network

Publications (2)

Publication Number Publication Date
CN110457956A CN110457956A (en) 2019-11-15
CN110457956B true CN110457956B (en) 2021-05-28

Family

ID=68487189

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910758926.XA Active CN110457956B (en) 2019-08-16 2019-08-16 Consensus supervision method and system for data supervision-oriented block chain network

Country Status (1)

Country Link
CN (1) CN110457956B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113204755B (en) * 2021-04-20 2022-10-14 重庆工业职业技术学院 Data capture method for block chain big data security

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101901124A (en) * 2010-06-30 2010-12-01 上海华御信息技术有限公司 File printing control method and system
CN105809420A (en) * 2016-03-08 2016-07-27 杭州复杂美科技有限公司 Liquidation method of multi-layer block chain
CN106453636A (en) * 2016-11-22 2017-02-22 深圳银链科技有限公司 Credible block generation method and system
CN106506146A (en) * 2016-10-26 2017-03-15 北京瑞卓喜投科技发展有限公司 Based on the Transaction Information method of calibration of block chain technology, apparatus and system
CN107945017A (en) * 2017-11-16 2018-04-20 成都赤乌软件技术有限公司 A kind of combination chain bookkeeping methods based on multi-level verification
CN109961287A (en) * 2019-02-12 2019-07-02 众安信息技术服务有限公司 A kind of monitoring and managing method and supervisory systems of block chain

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102005158B1 (en) * 2017-11-29 2019-07-29 신한카드 주식회사 Apparatus of generating credit virtual currency and apparatus of managing credit virtual currency
CN108256353B (en) * 2018-01-11 2021-01-01 武汉斗鱼网络科技有限公司 Data integrity checking method and device and client

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101901124A (en) * 2010-06-30 2010-12-01 上海华御信息技术有限公司 File printing control method and system
CN105809420A (en) * 2016-03-08 2016-07-27 杭州复杂美科技有限公司 Liquidation method of multi-layer block chain
CN106506146A (en) * 2016-10-26 2017-03-15 北京瑞卓喜投科技发展有限公司 Based on the Transaction Information method of calibration of block chain technology, apparatus and system
CN106453636A (en) * 2016-11-22 2017-02-22 深圳银链科技有限公司 Credible block generation method and system
CN107945017A (en) * 2017-11-16 2018-04-20 成都赤乌软件技术有限公司 A kind of combination chain bookkeeping methods based on multi-level verification
CN109961287A (en) * 2019-02-12 2019-07-02 众安信息技术服务有限公司 A kind of monitoring and managing method and supervisory systems of block chain

Also Published As

Publication number Publication date
CN110457956A (en) 2019-11-15

Similar Documents

Publication Publication Date Title
Dai et al. A low storage room requirement framework for distributed ledger in blockchain
CN107426165B (en) Bidirectional secure cloud storage data integrity detection method supporting key updating
US10560270B2 (en) Optimal data storage configuration in a blockchain
US11451406B2 (en) Cross-chain messaging and message validation
US11080691B2 (en) Fork-tolerant consensus protocol
CN108900364B (en) Block chain network management method, block chain network management device, block chain network management medium and electronic equipment
CN112001502B (en) Federal learning training method and device for high-delay network environment robustness
CN111095218B (en) Method, system and device for storing shared block chain data based on error correction coding
KR102050007B1 (en) System and method for supporting external interface based on block chain
CN113505019B (en) Erasure code data and verification recovery method, device and equipment and readable medium
CN110851535B (en) Data processing method and device based on block chain, storage medium and terminal
EP3831012A1 (en) Bidirectional blockchain
CN113469371B (en) Federal learning method and apparatus
CN111478772A (en) Assembly line friendly signature and signature verification method, device and storage medium
JP2013232902A (en) Transmission system, method and program
CN112968883A (en) Block chain heterogeneous consensus method with high safety and terminal
CN110457956B (en) Consensus supervision method and system for data supervision-oriented block chain network
CN111865595B (en) Block chain consensus method and device
CN111161075B (en) Blockchain transaction data proving and supervising method, system and related equipment
CN114285578A (en) Method for digitally signing a message
Xu et al. Data tag replacement algorithm for data integrity verification in cloud storage
CN111385096A (en) Block chain network, signature processing method, terminal and storage medium
CN110618989B (en) Information processing method, information processing device and related products
CN102761520B (en) Method and system for processing authentication information
US20200153615A1 (en) Method for information verification in distributed systems

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