CN110781192A - Verification method, device and equipment of block chain data - Google Patents

Verification method, device and equipment of block chain data Download PDF

Info

Publication number
CN110781192A
CN110781192A CN201911044952.2A CN201911044952A CN110781192A CN 110781192 A CN110781192 A CN 110781192A CN 201911044952 A CN201911044952 A CN 201911044952A CN 110781192 A CN110781192 A CN 110781192A
Authority
CN
China
Prior art keywords
hash value
service data
block chain
verification information
user
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.)
Granted
Application number
CN201911044952.2A
Other languages
Chinese (zh)
Other versions
CN110781192B (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.)
Alipay Hangzhou Information Technology Co Ltd
Original Assignee
Alipay Hangzhou Information 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 Alipay Hangzhou Information Technology Co Ltd filed Critical Alipay Hangzhou Information Technology Co Ltd
Priority to CN201911044952.2A priority Critical patent/CN110781192B/en
Publication of CN110781192A publication Critical patent/CN110781192A/en
Application granted granted Critical
Publication of CN110781192B publication Critical patent/CN110781192B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/22Indexing; Data structures therefor; Storage structures
    • G06F16/2228Indexing structures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/242Query formulation

Abstract

An embodiment of the specification provides a verification method, a verification device and verification equipment of block chain data, wherein the method comprises the following steps: the terminal equipment of the first user acquires the service data to be verified from the first block chain, acquires the verification information of the service data from the second block chain, and verifies the acquired service data according to the acquired verification information. The first block chain is used for storing the service data of the user, and the second block chain is used for storing the verification information of the service data in the first block chain.

Description

Verification method, device and equipment of block chain data
Technical Field
The present disclosure relates to the field of blockchain technologies, and in particular, to a method, an apparatus, and a device for verifying blockchain data.
Background
A federation chain is one of a class of blockchains that is open to a particular organization or community. Currently, each node in the federation chain participates in consensus verification and maintains all data on the federation chain. However, in practical applications, some users often only want to verify their own service data or service data related to them. Thus, requiring each node to participate in consensus verification and save all data on the federation chain, for some users, is undoubtedly an increase in operations and a waste of resources.
Disclosure of Invention
One or more embodiments of the present specification provide a method for verifying blockchain data, which is applied to a terminal device of a first user. The verification method comprises the step of obtaining service data to be verified from a first block chain, wherein the first block chain is used for storing the service data of a user. And acquiring the verification information of the service data from a second block chain, wherein the second block chain is used for storing the verification information of the service data in the first block chain. And verifying the service data according to the verification information.
One or more embodiments of the present specification provide a method for verifying blockchain data, which is applied to a first blockchain node. The verification method comprises the step of receiving a service data query request sent by terminal equipment of a first user, wherein the service data query request comprises a first hash value. And inquiring related service data from a first block chain according to the first hash value, and sending the inquired service data to the terminal equipment so that the terminal equipment can verify the service data.
One or more embodiments of the present specification provide a method for verifying blockchain data, which is applied to a second blockchain node. The authentication method comprises the steps of receiving an authentication information inquiry request sent by terminal equipment of a first user, wherein the authentication information inquiry request comprises index information. And inquiring related verification information from the second block chain according to the index information, and sending the inquired verification information to the terminal equipment so that the terminal equipment verifies the service data to be verified according to the verification information.
One or more embodiments of the present specification provide an apparatus for verifying blockchain data, which is applied to a terminal device of a first user. The verification device comprises a first acquisition module, which acquires service data to be verified from a first block chain. The first block chain is used for storing service data of a user. The verification device further comprises a second obtaining module, which obtains the verification information of the service data from the second blockchain. The second block chain is used for storing the verification information of the service data in the first block chain. The verification device also comprises a verification module which verifies the service data according to the verification information.
One or more embodiments of the present specification provide an apparatus for verifying blockchain data, which is applied to a first blockchain node. The verification device comprises a receiving module, which receives a service data query request sent by a terminal device of a first user, wherein the service data query request comprises a first hash value. The verification device further comprises a query module which queries the associated service data from the first block chain according to the first hash value. The verification device also comprises a sending module which sends the inquired service data to the terminal equipment so as to ensure that the terminal equipment verifies the service data.
One or more embodiments of the present specification provide an apparatus for verifying blockchain data, which is applied to a second blockchain node. The authentication device comprises a receiving module, which receives an authentication information inquiry request sent by a terminal device of a first user, wherein the authentication information inquiry request comprises index information. The authentication device further comprises a query module which queries the associated authentication information from the second blockchain according to the index information. The verification device also comprises a sending module which sends the queried verification information to the terminal equipment so that the terminal equipment verifies the service data to be verified according to the verification information.
One or more embodiments of the present specification provide an apparatus for verifying blockchain data, including a processor. The verification device further comprises a memory arranged to store computer executable instructions. The computer executable instructions, when executed, cause the processor to obtain service data to be verified from a first blockchain, wherein the first blockchain is used for storing the service data of the user. And acquiring the verification information of the service data from a second block chain, wherein the second block chain is used for storing the verification information of the service data in the first block chain. And verifying the service data according to the verification information.
One or more embodiments of the present specification provide an apparatus for verifying blockchain data, including a processor. The verification device further comprises a memory arranged to store computer executable instructions. The computer executable instructions, when executed, cause the processor to receive a service data query request sent by a terminal device of a first user, wherein the service data query request comprises a first hash value. And inquiring related service data from a first block chain according to the first hash value, and sending the inquired service data to the terminal equipment so that the terminal equipment can verify the service data.
One or more embodiments of the present specification provide an apparatus for verifying blockchain data, including a processor. The verification device further comprises a memory arranged to store computer executable instructions. The computer-executable instructions, when executed, cause the processor to receive an authentication information query request sent by a terminal device of a first user, wherein the authentication information query request includes index information. And inquiring related verification information from the second block chain according to the index information, and sending the inquired verification information to the terminal equipment so that the terminal equipment verifies the service data to be verified according to the verification information.
One or more embodiments of the present specification provide a storage medium for storing computer-executable instructions. The computer-executable instructions, when executed, obtain service data to be verified from a first blockchain, where the first blockchain is used to store service data of a user. And acquiring the verification information of the service data from a second block chain, wherein the second block chain is used for storing the verification information of the service data in the first block chain. And verifying the service data according to the verification information.
One or more embodiments of the present specification provide a storage medium for storing computer-executable instructions. The computer-executable instructions, when executed, receive a service data query request sent by a terminal device of a first user, wherein the service data query request includes a first hash value. And inquiring related service data from a first block chain according to the first hash value, and sending the inquired service data to the terminal equipment so that the terminal equipment can verify the service data.
One or more embodiments of the present specification provide a storage medium for storing computer-executable instructions. The computer-executable instructions, when executed, receive an authentication information query request sent by a terminal device of a first user, wherein the authentication information query request includes index information. And inquiring related verification information from the second block chain according to the index information, and sending the inquired verification information to the terminal equipment so that the terminal equipment verifies the service data to be verified according to the verification information.
Drawings
In order to more clearly illustrate one or more embodiments or prior art solutions of the present specification, the drawings that are needed in the description of the embodiments or prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments described in the present specification, and that other drawings can be obtained by those skilled in the art without inventive exercise.
Fig. 1 is a schematic view of a scenario of a verification method of blockchain data according to one or more embodiments of the present disclosure;
fig. 2 is a first flowchart illustrating a method for verifying blockchain data according to one or more embodiments of the present disclosure;
fig. 3 is a second flowchart of a method for verifying blockchain data according to one or more embodiments of the present disclosure;
fig. 4 is a third flowchart illustrating a method for verifying blockchain data according to one or more embodiments of the present disclosure;
fig. 5 is a fourth flowchart illustrating a method for verifying blockchain data according to one or more embodiments of the present disclosure;
fig. 6 is a fifth flowchart illustrating a method for verifying blockchain data according to one or more embodiments of the present disclosure;
fig. 7 is a sixth flowchart illustrating a method for verifying blockchain data according to one or more embodiments of the present disclosure;
fig. 8 is a seventh flowchart illustrating a method for verifying blockchain data according to one or more embodiments of the present disclosure;
fig. 9 is an eighth flowchart illustrating a method for verifying blockchain data according to one or more embodiments of the present disclosure;
fig. 10 is a schematic diagram illustrating a first module of a device for verifying blockchain data according to one or more embodiments of the present disclosure;
fig. 11 is a schematic diagram illustrating a second module of a device for verifying blockchain data according to one or more embodiments of the present disclosure;
fig. 12 is a schematic diagram illustrating a third module of a device for verifying blockchain data according to one or more embodiments of the present disclosure;
fig. 13 is a schematic structural diagram of a device for verifying blockchain data according to one or more embodiments of the present disclosure.
Detailed Description
In order to make those skilled in the art better understand the technical solutions in one or more embodiments of the present disclosure, the technical solutions in one or more embodiments of the present disclosure will be clearly and completely described below with reference to the drawings in one or more embodiments of the present disclosure, and it is obvious that the described embodiments are only a part of the embodiments of the present disclosure, and not all embodiments. All other embodiments that can be derived by a person skilled in the art from one or more of the embodiments described herein without making any inventive step shall fall within the scope of protection of this document.
One or more embodiments of the present specification provide a method, an apparatus, and a device for verifying block chain data, where service data is stored in a first block chain in advance, and verification information of the service data is stored in a second block chain, so that when a first user needs to verify the service data, the service data to be verified is obtained from the first block chain through a terminal device of the first user, and the verification information of the service data is obtained from the second block chain, so that the service data can be verified according to the obtained verification information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
Fig. 1 is a schematic view of an application scenario of a verification method for blockchain data according to one or more embodiments of the present disclosure, as shown in fig. 1, the system includes: a terminal device of a first user, a first block chain node and a second block chain node; the terminal equipment of the first user can be a mobile phone, a tablet computer, a desktop computer, a portable notebook computer and the like; the first block chain node is a node in a first block chain, and the first block chain is used for storing service data of a user; the second block chain node is a node in a second block chain, and the second block chain is used for storing the verification information of the service data in the first block chain; the terminal equipment of the first user is in communication connection with the first block chain node and the second block chain node through a wireless network; further, the first blockchain and the second blockchain may be union chains or public chains.
Specifically, when the first user needs to verify the service data stored in the first blockchain, the first user may operate the terminal device thereof to send a data verification request to the terminal device; the terminal equipment of the first user responds to a data verification request of the first user, acquires service data to be verified from the first block chain, and acquires verification information of the service data to be verified from the second block chain; and verifying the service data to be verified by adopting the acquired verification information. The business data includes transaction data, enterprise operation data, user identity data, and the like. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
Based on the application scenario architecture, one or more embodiments of the present specification provide a method for verifying blockchain data; fig. 2 is a flowchart illustrating a method for verifying blockchain data according to one or more embodiments of the present disclosure, where the method in fig. 2 can be executed by a terminal device of a first user in fig. 1, and as shown in fig. 2, the method includes the following steps:
step S102, acquiring service data to be verified from a first block chain; the first block chain is used for storing service data of a user;
the service data to be verified may be service data of a first user or service data of a second user; the second user is a user other than the first user, and it should be understood that in a specific scenario, the user identity referred to by the first user and the user identity referred to by the second user in this specification may be replaced with each other.
Step S104, obtaining the verification information of the service data from the second block chain; the second block chain is used for storing the verification information of the service data in the first block chain;
after the verification information of the service data is that the first user or the second user stores the service data to be stored to the first block chain, the terminal device of the first user or the terminal device of the second user generates the verification information based on the service data to be stored.
And step S106, verifying the service data to be verified according to the acquired verification information.
In one or more embodiments of the present specification, a terminal device of a first user can, in response to a data verification request of the first user, obtain service data to be verified from a first blockchain, obtain verification information of the service data from a second blockchain, and verify the service data according to the obtained verification information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
When the first user needs to verify the service data of the first user, before the verification, the first user first stores the service data into the first block chain through the terminal device of the first user, specifically, as shown in fig. 3, before step S102, the method further includes:
step S100-2, sending a first data storage request to a first block chain node; the first data storage request comprises service data to be stored, so that the first block link node stores the service data and the first hash value in a first block chain in an associated manner;
step S100-4, receiving a first hash value sent by a first blockchain node.
The first hash value is a hash value calculated by the first block link point based on the service data and the additional data; specifically, the terminal device of the first user responds to the data storage operation of the first user and sends a first data storage request to the first block chain node according to the service data to be stored; when a first block link node receives a first data storage request, acquiring service data from the first data storage request, calculating the service data and additional data according to a second preset algorithm to obtain a first hash value, storing the service data and the first hash value in a first block chain in a correlation manner, and sending the first hash value to terminal equipment of a first user so that the terminal equipment of the first user inquires the service data according to the first hash value; the terminal equipment of the first user receives and stores the first hash value sent by the first blockchain node; in practical applications, the additional data may be set as needed, such as the receiving time of the first data storage request received by the first block node, the block identifier of the block storing the service data, and the like. The first user can effectively prevent the service data from being lost and the service data from being maliciously tampered and the like based on the characteristics of the block chain by storing the service data into the first block chain.
In order to enable a first user to verify the service data stored in the first block chain and enable other users to verify the service data of the first user, after the terminal device of the first user receives a first hash value sent by a first block chain node, the terminal device of the first user also determines verification information of the service data according to the service data to be stored (namely original service data) included in a first data storage request, and stores the verification information into a second block chain through a second block chain node of the second block chain; specifically, as shown in fig. 3, after step S100-4, the method further includes:
s100-6, calculating a second hash value of the service data to be stored according to a first preset algorithm;
step S100-8, sending a second data storage request to a second block chain node; the second data storage request comprises a first hash value and a second hash value, so that the second block chain node stores the first hash value, the second hash value and a third hash value in a second block chain in a correlation manner, and the third hash value is a hash value calculated by the second block chain node based on the first hash value and the second hash value;
and S100-10, receiving a third hash value sent by the second blockchain node.
Specifically, because the first block link point is maliciously controlled, or the service data stored in the first block chain is incorrect due to other factors, in order to enable a user to verify the integrity and accuracy of the service data stored in the first block chain in the subsequent process, when the terminal device of the first user receives a first hash value sent by a first block chain node, a second hash value of the service data to be stored included in the first data storage request is calculated according to a first preset algorithm, and a second data storage request is sent to a second block chain node according to the first hash value and the second hash value; when the second block link node receives a second data storage request, calculating the first hash value and the second hash value according to a third preset algorithm to obtain a third hash value, storing the first hash value, the second hash value and the third hash value into a second block chain in an associated manner, and sending the third hash value to the terminal equipment of the first user, so that the first user can inquire corresponding verification information according to the third hash value; and the terminal equipment of the first user receives and stores the third hash value sent by the second blockchain node.
Therefore, after the first user saves the service data to be stored to the first block chain, the second hash value is calculated based on the service data to be stored, the second hash value and the third hash value are saved to the second block chain, and the corresponding service data saved in the first block chain is verified based on the hash value saved in the second block chain subsequently.
In one or more embodiments of the present disclosure, in order to quickly and conveniently acquire service data when a first user wants to verify whether own service data stored in a first block link point is correct, the first user sends a service data query request to the first block link point through a terminal device of the first user, so that the first block link point quickly queries corresponding service data according to a first hash value in the service data query request; specifically, as shown in fig. 4, step S102 includes:
step S102-2, a service data query request is sent to a first block link point in a first block chain, wherein the service data query request comprises a first hash value, so that the first block link point queries related service data from the first block chain according to the first hash value;
as described above, the first hash value is a hash value calculated by the first block link point based on the service data and the additional data when the first user stores the service data to be stored to the first block chain through the first block link point in advance. Specifically, the terminal device of the first user responds to a data verification request of the first user and sends a service data query request to a first block link node in a first block chain according to a stored first hash value; when the first block link receives a service data query request, the service data stored in association is queried in the first block link according to a first hash value included in the service data query request, and the queried service data is sent to the terminal equipment of the first user.
And step S102-4, receiving the service data sent by the first block chain node.
Further, in order to verify the obtained service data, the terminal device further sends a verification information query request to a second block link point in the second block chain to obtain corresponding verification information, specifically, as shown in fig. 4, step S104 includes:
step S104-2, sending a verification information query request to a second block link point in a second block chain, wherein the verification information query request comprises index information of verification information to be queried, so that the second block link point queries related verification information from the second block chain according to the index information;
and step S104-4, receiving the verification information sent by the second blockchain node.
Specifically, the terminal device takes the stored first hash value and/or the stored third hash value as index information of the verification information to be queried, and sends a verification information query request to a second block link node in the second block chain according to the index information; when the second block link node receives the verification information query request, querying the hash value stored in a correlation manner from the second block link according to the index information included in the verification information query request, and sending the queried hash value serving as the verification information to the terminal equipment of the first user; and the terminal equipment of the first user receives the verification information sent by the second blockchain node.
When the service data to be verified and the verification information of the service data are obtained, the service data can be verified according to the verification information. Specifically, when the index information includes the third hash value, correspondingly, the verification information includes the first hash value and the second hash value; step S106 includes:
step S106-2, determining whether the first hash value included in the verification information is consistent with the first hash value stored in the terminal equipment;
step S106-4, calculating a fourth hash value of the acquired service data according to a first preset algorithm, and determining whether the calculated fourth hash value is consistent with a second hash value included in the verification information;
and step S106-6, if the data are consistent, the service data is determined to pass the verification.
The execution sequence of the step S106-2 and the step S106-4 can be interchanged; further, when it is determined that the first hash value included in the verification information is consistent with the first hash value stored in the terminal device, it may be determined that the obtained verification information is the verification information of the service data to be verified; when it is determined that the fourth hash value is consistent with the second hash value included in the verification information, it may be determined that the service data acquired from the first blockchain is correct, that is, the service data stored in the first blockchain is not tampered. Therefore, effective verification of the authenticity of the business data is achieved based on the first hash value and the second hash value.
Further, when the index information includes the first hash value, or the index information includes the first hash value and the third hash value, correspondingly, the verification information includes the second hash value, and step S106 includes:
step S106-8, calculating a fourth hash value of the acquired service data according to a first preset algorithm, determining whether the fourth hash value is consistent with a second hash value included in the verification information, and if so, determining that the service data passes the verification.
When it is determined that the fourth hash value is consistent with the second hash value included in the verification information, it may be determined that the service data acquired from the first blockchain is correct, that is, the service data stored in the first blockchain is not tampered. Therefore, based on the second hash value, effective verification of the authenticity of the business data is achieved.
In the above, the terminal device of the first user, in response to the data verification request of the first user, obtains the service data of the first user from the first blockchain based on the stored first hash value, obtains the verification information of the service data of the first user from the second blockchain based on the terminal device storing the first hash value and/or the third hash value, and verifies the obtained service data based on the obtained verification information. Therefore, for the first user, the terminal device does not need to be deployed as a node device to join the block chain, the terminal device of the first user does not need to participate in consensus verification in the block chain, and all data in the block chain are not needed to be stored in the terminal device of the first user, so that the verification requirement of the first user on the service data of the first user is met on the basis of reducing the operation of the terminal device of the first user and reducing resource consumption.
Further, the first user may also verify the service data of the second user based on the service data stored in the first blockchain and the verification information stored in the second blockchain. Correspondingly, as shown in fig. 5, step S102 includes:
step S102-6, acquiring service data to be verified and a first hash value associated with the service data from a first block chain; the first hash value is calculated on the basis of the service data and the additional data when the second user stores the service data to be stored to the first block chain in advance through the first block chain link point in the first block chain;
specifically, when the first block chain is a public chain, all users have authority to view data in the first block chain, so that the first user can directly obtain service data to be verified and a first hash value stored corresponding to the service data to be verified from the first block chain through the terminal device of the first user; when the first blockchain is a federation chain, the public range of the federation chain can be preset by members of the federation chain, for example, when a certain group is a member of the federation chain, whether a user in the group deploys a federation chain node or not can be set, the user has the authority to view data on the federation chain, and therefore when the first user is a user with the authority to view data, the service data on the first blockchain can be verified.
Correspondingly, as shown in fig. 5, step S104 includes:
step S104-6, the acquired first hash value is used as index information of the verification information to be inquired, and a verification information inquiry request is sent to a second block chain link point in a second block chain according to the index information, so that the second block chain link point inquires the associated verification information from the second block chain according to the index information;
and step S104-8, receiving the verification information sent by the second blockchain node.
The verification information comprises a second hash value obtained by calculating the service data to be stored by the terminal equipment of the second user according to a first preset algorithm in advance;
correspondingly, as shown in fig. 5, step S106 includes:
step S106-10, calculating a fourth hash value of the acquired service data according to a first preset algorithm, determining whether the fourth hash value is consistent with a second hash value included in the verification information, and if so, determining that the service data passes the verification.
Therefore, when the first user needs to verify the service data of the second user, the terminal equipment of the first user can directly acquire the service data of the second user and the corresponding first hash value from the first block chain, acquire corresponding verification information from the second block chain according to the first hash value, and verify the acquired service data of the second user according to the acquired verification information; therefore, for the first user, the terminal device does not need to be deployed as a node device to join the block chain, the terminal device of the first user does not need to participate in consensus verification, and all data in the block chain are not needed to be stored in the terminal device of the first user, so that the verification requirement of the first user on the service data of the second user is met on the basis of reducing the operation of the terminal device of the first user and reducing resource consumption.
It should be noted that, the first user may deploy its terminal device as a node in the second blockchain, and correspondingly, step S102 includes: acquiring verification information of service data from data stored in terminal equipment; even if the service data is verified by the terminal device of the first user only by storing the verification information and the index information in the form of the hash value, compared with the case of storing the full amount of service data, the amount of the stored data is greatly reduced, so that the requirement on the storage space is reduced, and the resource consumption is reduced.
In the present specification, the integrity of the service data can be verified by the above manner of storing the service data of the user by using the first blockchain and storing the verification information of the service data in the first blockchain by using the second blockchain; it can be considered that, by adopting the double-chain data storage manner, the scheme of the present specification may also be applied to a data verification manner such as validity of service data, and details are not described herein.
In one or more embodiments of the present description, by saving the service data in the first block chain in advance, and saving the verification information of the service data in the second block chain, the terminal device of the first user can respond to the data verification request of the first user, obtain the service data to be verified from the first block chain, obtain the verification information of the service data from the second block chain, and verify the service data according to the obtained verification information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data which the first user wants to verify, and therefore, the verification requirement of the first user on the service data is met on the basis that excessive resources of the first user are not occupied.
Corresponding to the verification method of the blockchain data described above, based on the same technical concept, one or more embodiments of the present specification further provide a verification method of blockchain data, which is applied to a first blockchain node; fig. 6 illustrates a method for verifying blockchain data applied to a first blockchain node according to one or more embodiments of the present disclosure, where the method includes the following steps:
step S202, receiving a service data query request sent by a terminal device of a first user, wherein the service data query request comprises a first hash value;
step S204, inquiring related service data from the first block chain according to the first hash value;
the first block chain is used for storing service data of a user.
Step S206, sending the queried service data to the terminal device, so that the terminal device verifies the service data.
When a first user sends a first data storage request to a first block chain node in advance through terminal equipment of the first user, storing the service data in the first block chain by a first block chain link point; specifically, as shown in fig. 7, in one or more embodiments of the present specification, before step S202, the method further includes:
step S200-2, receiving a first data storage request sent by the terminal equipment; the first data storage request comprises service data to be stored;
step S200-4, calculating a first hash value according to the service data and the additional data;
specifically, the service data and the additional data are calculated according to a second preset algorithm to obtain a first hash value; in practical application, the additional data may be set according to requirements, such as a receiving time of receiving the first data storage request, a block identifier of a block storing the service data, and the like.
Step S200-6, storing the first hash value and the business data into a first block chain in an associated manner;
and step S200-8, sending the first hash value to the terminal equipment so that the first user inquires the service data according to the first hash value.
In one or more embodiments of the present specification, when the first block link node receives a service data query request sent by a terminal device of a first user, service data is queried from the first block link based on a first hash value included in the service data query request and is sent to the terminal device of the first user, so that the terminal device of the first user verifies the service data. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
Corresponding to the verification method of the blockchain data described above, based on the same technical concept, one or more embodiments of the present specification further provide a verification method of blockchain data, which is applied to a second blockchain node; fig. 8 illustrates a method for verifying blockchain data applied to a second blockchain node according to one or more embodiments of the present disclosure, where the method includes the following steps:
step S302, receiving a verification information query request sent by a terminal device of a first user, wherein the verification information query request comprises index information;
step S304, inquiring the related verification information from the second block chain according to the index information;
the second block chain is used for storing the verification information of the service data in the first block chain.
Step S306, the inquired verification information is sent to the terminal device, so that the terminal device verifies the service data to be verified according to the verification information.
The verification information is stored in the second block chain by the second block chain link point when the first user sends a second data storage request to the second block chain node through the terminal equipment of the first user in advance; specifically, as shown in fig. 9, in one or more embodiments of this specification, before step S302, the method further includes:
step S300-2, receiving a second data storage request sent by the terminal equipment; the second data storage request comprises a first hash value and a second hash value, the first hash value is a hash value calculated by the first block chain node based on the service data and the additional data when the first user stores the service data to be stored to the first block chain in advance through the first block chain node in the first block chain, and the second hash value is a hash value calculated by the terminal device based on the service data to be stored;
step S300-4, calculating a third hash value according to the first hash value and the second hash value;
specifically, the first hash value and the second hash value are calculated according to a third preset algorithm to obtain a third hash value; the third preset algorithm can be set as required in practical application.
Step S300-6, the first hash value, the second hash value and the third hash value are stored in a second block chain in an associated mode;
and step S300-8, sending the third hash value to the terminal equipment.
By calculating the third hash value and sending the third hash value to the terminal device of the first user, on one hand, the user knows that the verification information is successfully stored, and on the other hand, when the first user needs to acquire the verification information, the corresponding verification information can be quickly and accurately acquired based on the third hash value.
Since the first hash value and the third hash value are stored in the terminal device of the first user, and the first hash value and the third hash value are also stored in the second block chain, in practical application, when the first user needs to verify the service data of the first user, the first hash value may be used as the index information of the verification information, the third hash value may be used as the index information of the verification information, or the first hash value and the third hash value may be used together as the index information of the verification information. Specifically, when the index information includes the third hash value, step S304 includes:
inquiring the associated first hash value and second hash value from the second block chain according to the third hash value to obtain verification information;
when the index information includes the first hash value, step S304 includes:
inquiring a related second hash value from a second block chain according to the first hash value to obtain verification information;
when the index information includes the first hash value and the third hash value, step S304 includes:
and inquiring the associated second hash value from the second block chain according to the first hash value and the third hash value to obtain verification information.
Therefore, when the first user needs to verify the service data of the first user, the terminal device can respond to the data verification request of the first user and send a verification information inquiry request to the second block link node according to the stored first hash value and/or the stored second hash value, and the second block link node can search the verification information of the service data of the first user according to the first hash value and/or the second hash value.
Further, when the first user needs to verify the service data of the second user, a verification information query request may be sent to the second block link point based on the first hash value obtained from the first block link to obtain corresponding verification information; the index information includes a first hash value, and the first hash value is a hash value calculated by a first block link point based on the service data and the additional data when the service data to be stored is stored in the first block link by a second user through the first block link point in the first block link in advance; correspondingly, step S304 includes:
inquiring a related second hash value from a second block chain according to the first hash value to obtain verification information; the second hash value is a hash value calculated by the terminal device of the second user based on the service data in the first block chain.
Specifically, when a second user sends a first data storage request to a first block chain node in a first block chain through terminal equipment of the second user, the first block chain node acquires service data from the first data storage request, calculates the acquired service data and additional data according to a second preset algorithm to obtain a first hash value, stores the first hash value and the service data in association with each other in the first block chain, and sends the first hash value to the terminal equipment of the second user; when receiving the first hash value, the terminal equipment of the second user calculates the service data to be stored included in the first data storage request according to a first preset algorithm to obtain a second hash value, and sends a second data storage request to the second block chain node according to the first hash value and the second hash value; when the second block chain node receives a second data storage request sent by the terminal equipment of a second user, calculating the first hash value and the second hash value according to a third preset algorithm to obtain a third hash value, and storing the first hash value, the second hash value and the third hash value into a second block chain in an associated manner; therefore, when the second block link point receives the verification information query request sent by the terminal device of the first user, the corresponding verification information can be queried based on the index information included in the verification information query request, namely the first hash value calculated by the first block link point based on the service data to be stored of the second user and the additional data, and the queried verification information is sent to the terminal device of the first user, so that the terminal device of the first user can verify the service data of the second user according to the verification information.
In one or more embodiments of the present specification, when the second block link node receives an authentication information query request sent by the terminal device of the first user, the second block link node queries associated authentication information from the second block link based on index information included in the authentication information query request and sends the associated authentication information to the terminal device of the first user, so that the terminal device of the first user authenticates data to be authenticated based on the authentication information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
Based on the same technical concept, corresponding to the verification method of the blockchain data described in fig. 2 to 5, one or more embodiments of the present disclosure further provide a verification apparatus of blockchain data, which is applied to a terminal device of a first user. Fig. 10 is a schematic block diagram of an apparatus for verifying blockchain data according to one or more embodiments of the present disclosure, the apparatus being configured to perform the method for verifying blockchain data described in fig. 2 to 5, as shown in fig. 10, the apparatus including:
a first obtaining module 401, configured to obtain service data to be verified from a first block chain; the first block chain is used for storing service data of a user;
a second obtaining module 402, configured to obtain verification information of the service data from a second blockchain; the second block chain is used for storing the verification information of the service data in the first block chain;
and a verification module 403, configured to verify the service data according to the verification information.
In one or more embodiments of the present specification, service data to be verified is obtained from a first blockchain, verification information of the service data is obtained from a second blockchain, and the service data is verified according to the obtained verification information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
Optionally, the first obtaining module 401 sends a service data query request to a first block link point in the first block chain, where the service data query request includes a first hash value, so that when the first block link point queries associated service data from the first block chain according to the first hash value, the first hash value is a hash value calculated by the first block link point based on the service data and additional data when the first user stores service data to be stored to the first block chain through the first block link point in advance; and the number of the first and second groups,
and receiving the service data sent by the first blockchain node.
Optionally, the apparatus further comprises: the device comprises a first sending module and a first receiving module;
the first sending module sends a first data storage request to a first blockchain node before the first obtaining module 401 obtains the service data to be verified from the first blockchain; wherein the first data storage request includes the service data to be stored, so that the first block link node stores the service data and the first hash value association into the first block chain;
the first receiving module receives the first hash value sent by the first blockchain node.
Optionally, the second obtaining module 402 sends a verification information query request to a second block link point in a second block chain, where the verification information query request includes index information of verification information to be queried, so that the second block link point queries, according to the index information, associated verification information from the second block chain; and the number of the first and second groups,
and receiving the verification information sent by the second blockchain node.
Optionally, the apparatus further comprises: the device comprises a calculation module, a second sending module and a second receiving module;
the calculation module is used for calculating a second hash value of the service data to be stored according to a first preset algorithm;
the second sending module sends a second data storage request to the second blockchain node; wherein the second data storage request includes the first hash value and the second hash value, such that the second chunk link node stores the first hash value, the second hash value, and a third hash value in association with the second chunk chain, the third hash value being a hash value calculated by the second chunk link node based on the first hash value and the second hash value;
the second receiving module receives the third hash value sent by the second blockchain node.
Optionally, the index information includes the third hash value, and the verification information includes the first hash value and the second hash value;
correspondingly, the verification module 403 determines whether the first hash value included in the verification information is consistent with the first hash value stored in the terminal device; and the number of the first and second groups,
calculating a fourth hash value of the acquired service data according to the preset algorithm, and determining whether the calculated fourth hash value is consistent with a second hash value included in the verification information;
and if the service data are consistent, determining that the service data pass the verification.
Optionally, the index information includes the first hash value, or the index information includes the first hash value and the third hash value; the verification information comprises the second hash value;
correspondingly, the verification module 403 calculates a fourth hash value of the acquired service data according to the preset algorithm, and determines whether the fourth hash value is consistent with the second hash value included in the verification information;
and if the service data are consistent, determining that the service data pass the verification.
Optionally, the first obtaining module 401 obtains, from a first blockchain, to-be-verified service data and a first hash value associated with the service data; the first hash value is a hash value calculated by a first block link point based on the service data and additional data when a second user stores the service data to the first block link through the first block link point in the first block link in advance;
correspondingly, the second obtaining module 402 uses the first hash value obtained by the first obtaining module 401 as index information of the verification information to be queried, and sends a verification information query request to a second block link point in a second block chain according to the index information, so that the second block link point queries associated verification information from the second block chain according to the index information;
and receiving the verification information sent by the second blockchain node.
Optionally, the verification information includes: the terminal equipment of the second user calculates a second hash value obtained by the service data stored in the first block chain in advance according to a first preset algorithm;
correspondingly, the verification module 403 calculates a fourth hash value of the acquired service data according to the preset algorithm, and determines whether the fourth hash value is consistent with the second hash value included in the verification information;
and if the service data are consistent, determining that the service data pass the verification.
In one or more embodiments of the present disclosure, a device for verifying blockchain data obtains service data to be verified from a first blockchain, obtains verification information of the service data from a second blockchain, and verifies the service data according to the obtained verification information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
It should be noted that, the embodiment of the verification apparatus for blockchain data in this specification and the embodiment of the verification method for blockchain data applied to the terminal device of the first user in this specification are based on the same inventive concept, and therefore, for specific implementation of this embodiment, reference may be made to the implementation of the verification method for blockchain data applied to the terminal device of the first user, and repeated details are not described again.
Based on the same technical concept, corresponding to the verification method of the blockchain data described in fig. 6 to 7, one or more embodiments of the present disclosure further provide a verification apparatus of blockchain data, which is applied to the first blockchain node. Fig. 11 is a schematic block diagram of an apparatus for verifying blockchain data according to one or more embodiments of the present disclosure, the apparatus being configured to perform the method for verifying blockchain data described in fig. 6 to 7, as shown in fig. 11, and the apparatus including:
a receiving module 501, configured to receive a service data query request sent by a terminal device of a first user, where the service data query request includes a first hash value;
a query module 502, configured to query the associated service data from the first block chain according to the first hash value;
a sending module 503, configured to send the queried service data to the terminal device, so that the terminal device verifies the service data.
Optionally, the apparatus further comprises: a calculation module and a storage module;
the receiving module 501, before receiving a service data query request sent by a terminal device of a first user, also receives a first data storage request sent by the terminal device; wherein the first data storage request comprises the service data to be stored;
the calculation module is used for calculating the first hash value according to the service data and the additional data;
the storage module is used for storing the first hash value and the business data into the first block chain in a correlation manner;
the sending module 503 is further configured to send the first hash value to the terminal device, so that the first user queries the service data according to the first hash value.
In the verification apparatus for blockchain data provided in one or more embodiments of the present specification, when receiving a service data query request sent by a terminal device of a first user, service data is queried from a first blockchain based on a first hash value included in the service data query request and sent to the terminal device of the first user, so that the terminal device of the first user verifies the service data. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
It should be noted that the embodiment of the verification apparatus for blockchain data in this specification and the embodiment of the verification method for blockchain data applied to the first blockchain node in this specification are based on the same inventive concept, and therefore, for specific implementation of this embodiment, reference may be made to the implementation of the verification method for blockchain data applied to the first blockchain node, and repeated details are not described again.
Based on the same technical concept, corresponding to the verification method of the blockchain data described in fig. 8 to 9, one or more embodiments of the present disclosure further provide a verification apparatus of blockchain data, which is applied to the second blockchain node. Fig. 12 is a schematic block diagram of an apparatus for verifying blockchain data according to one or more embodiments of the present disclosure, the apparatus being configured to perform the method for verifying blockchain data described in fig. 8 to 9, and as shown in fig. 12, the apparatus includes:
a receiving module 601, configured to receive an authentication information query request sent by a terminal device of a first user, where the authentication information query request includes index information;
a query module 602, configured to query the associated verification information from the second blockchain according to the index information;
a sending module 603, configured to send the queried verification information to the terminal device, so that the terminal device verifies the service data to be verified according to the verification information.
Optionally, the apparatus further comprises: a calculation module and a storage module;
the receiving module 601, before receiving the verification information query request sent by the terminal device of the first user, also receives a second data storage request sent by the terminal device; the second data storage request comprises a first hash value and a second hash value, the first hash value is a hash value calculated by the first block chain node based on the service data and additional data when the first user stores the service data to be stored to the first block chain in advance through the first block chain node in the first block chain, and the second hash value is a hash value calculated by the terminal device based on the service data to be stored;
the calculation module calculates a third hash value according to the first hash value and the second hash value;
the saving module is used for saving the first hash value, the second hash value and the third hash value into the second block chain in an associated manner;
the sending module 603 further sends the third hash value to the terminal device.
Optionally, the index information includes the third hash value, and the query module 602 queries, according to the third hash value, the associated first hash value and the associated second hash value from a second block chain to obtain verification information;
or the index information includes the first hash value, and the query module 602 queries the associated second hash value from a second block chain according to the first hash value to obtain verification information;
alternatively, the first and second electrodes may be,
the index information includes the first hash value and the third hash value, and the query module 602 queries the associated second hash value from the second block chain according to the first hash value and the third hash value to obtain the verification information.
Optionally, the index information includes a first hash value, where the first hash value is a hash value stored in a first block chain, and calculated based on the service data and additional data when a second user stores the service data to be stored in the first block chain in advance through a first block link point in the first block chain;
correspondingly, the query module 602 queries the associated second hash value from a second block chain according to the first hash value to obtain verification information; the second hash value is a hash value calculated by the terminal device of the second user based on the service data saved in the first block chain.
In the block chain data verification apparatus provided in one or more embodiments of the present specification, when receiving a verification information query request sent by a terminal device of a first user, related verification information is queried from a second block chain based on index information included in the verification information query request and sent to the terminal device of the first user, so that the terminal device of the first user verifies to-be-verified data based on the verification information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
It should be noted that the embodiment of the verification apparatus for blockchain data in this specification and the embodiment of the verification method for blockchain data applied to the second blockchain node in this specification are based on the same inventive concept, and therefore, for specific implementation of this embodiment, reference may be made to the implementation of the verification method for blockchain data applied to the second blockchain node, and repeated details are not described again.
Further, corresponding to the verification method of the blockchain data described above, based on the same technical concept, one or more embodiments of the present disclosure further provide a verification device of the blockchain data, where the verification device is configured to perform the verification method of the blockchain data, and fig. 13 is a schematic structural diagram of the verification device of the blockchain data provided in one or more embodiments of the present disclosure.
As shown in fig. 13, the verification device for blockchain data may have a relatively large difference due to different configurations or performances, and may include one or more processors 701 and a memory 702, where one or more stored applications or data may be stored in the memory 702. Memory 702 may be, among other things, transient storage or persistent storage. The application program stored in memory 702 may include one or more modules (not shown), each of which may include a series of computer-executable instructions in a validation device for blockchain data. Still further, the processor 701 may be configured to communicate with the memory 702 to execute a series of computer-executable instructions in the memory 702 on a verification device for blockchain data. The verification apparatus of blockchain data may also include one or more power supplies 703, one or more wired or wireless network interfaces 704, one or more input-output interfaces 705, one or more keyboards 706, and the like.
In one embodiment, the apparatus for validating blockchain data comprises a memory, and one or more programs, wherein the one or more programs are stored in the memory, and the one or more programs may comprise one or more modules, and each module may comprise a series of computer-executable instructions in the apparatus for validating blockchain data, and the one or more programs configured to be executed by the one or more processors comprise computer-executable instructions for:
acquiring service data to be verified from a first block chain; the first block chain is used for storing service data of a user;
acquiring verification information of the service data from a second block chain; the second block chain is used for storing the verification information of the service data in the first block chain;
and verifying the service data according to the verification information.
In one or more embodiments of the present specification, service data to be verified is obtained from a first blockchain, verification information of the service data is obtained from a second blockchain, and the service data is verified according to the obtained verification information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
Optionally, when executed, the obtaining service data to be verified from the first blockchain includes:
sending a service data query request to a first block link point in the first block chain, wherein the service data query request includes a first hash value, so that the first block link point queries related service data from the first block chain according to the first hash value, and the first hash value is a hash value calculated by the first block link point based on the service data and additional data when the first user stores the service data to be stored to the first block chain through the first block link point in advance;
and receiving the service data sent by the first blockchain node.
Optionally, when executed, before obtaining the service data to be verified from the first blockchain, the computer-executable instructions further include:
sending a first data storage request to the first blockchain node; wherein the first data storage request includes the service data to be stored, so that the first block link node stores the service data and the first hash value association into the first block chain;
and receiving the first hash value sent by the first blockchain node.
Optionally, when executed, the computer-executable instructions obtain the verification information of the service data from the second blockchain, including:
sending a verification information query request to a second block link point in a second block chain, wherein the verification information query request comprises index information of verification information to be queried, so that the second block link point queries related verification information from the second block chain according to the index information;
and receiving the verification information sent by the second blockchain node.
Optionally, when executed, the computer-executable instructions, before obtaining the verification information of the service data from the second blockchain, further include:
calculating a second hash value of the service data to be stored according to a first preset algorithm;
sending a second data storage request to the second blockchain node; wherein the second data storage request includes the first hash value and the second hash value, such that the second chunk link node stores the first hash value, the second hash value, and a third hash value in association with the second chunk chain, the third hash value being a hash value calculated by the second chunk link node based on the first hash value and the second hash value;
and receiving the third hash value sent by the second blockchain node.
Optionally, the computer executable instructions, when executed, the index information comprises the third hash value, the verification information comprises the first hash value and the second hash value;
the verifying the service data according to the verification information includes:
determining whether a first hash value included in the verification information is consistent with a first hash value stored by the terminal equipment; and the number of the first and second groups,
calculating a fourth hash value of the acquired service data according to the preset algorithm, and determining whether the calculated fourth hash value is consistent with a second hash value included in the verification information;
and if the service data are consistent, determining that the service data pass the verification.
Optionally, the computer-executable instructions, when executed, comprise the first hash value, or the index information comprises the first hash value and the third hash value; the verification information comprises the second hash value;
the verifying the service data according to the verification information includes:
calculating a fourth hash value of the acquired service data according to the preset algorithm, and determining whether the fourth hash value is consistent with the second hash value included in the verification information;
and if the service data are consistent, determining that the service data pass the verification.
Optionally, when executed, the obtaining service data to be verified from the first blockchain includes:
acquiring service data to be verified and a first hash value associated with the service data from a first block chain; the first hash value is a hash value calculated by a first block link point based on the service data and additional data when a second user stores the service data to the first block link through the first block link point in the first block link in advance;
the obtaining the verification information of the service data from the second blockchain includes:
taking the obtained first hash value as index information of verification information to be inquired, and sending a verification information inquiry request to a second block chain link point in a second block chain according to the index information so that the second block chain link point inquires associated verification information from the second block chain according to the index information;
and receiving the verification information sent by the second blockchain node.
Optionally, the computer executable instructions, when executed, further comprise: the terminal equipment of the second user calculates a second hash value obtained by the service data stored in the first block chain in advance according to a first preset algorithm;
the verifying the service data according to the verification information includes:
calculating a fourth hash value of the acquired service data according to the preset algorithm, and determining whether the fourth hash value is consistent with the second hash value included in the verification information;
and if the service data are consistent, determining that the service data pass the verification.
In the block chain data verification apparatus provided in one or more embodiments of the present specification, service data to be verified is obtained from a first block chain, verification information of the service data is obtained from a second block chain, and the service data is verified according to the obtained verification information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
In another embodiment, the apparatus for verifying blockchain data includes a memory, and one or more programs, wherein the one or more programs are stored in the memory, and the one or more programs may include one or more modules, and each module may include a series of computer-executable instructions for a public opinion querying device, and the one or more programs configured to be executed by the one or more processors include computer-executable instructions for:
receiving a service data query request sent by terminal equipment of a first user, wherein the service data query request comprises a first hash value;
inquiring related service data from a first block chain according to the first hash value;
and sending the inquired service data to the terminal equipment so that the terminal equipment verifies the service data.
Optionally, when executed, the computer-executable instructions, before receiving a service data query request sent by a terminal device of a first user, further include:
receiving a first data storage request sent by the terminal equipment; wherein the first data storage request comprises the service data to be stored;
calculating the first hash value according to the service data and the additional data;
storing the first hash value and the business data association into the first block chain; and the number of the first and second groups,
and sending the first hash value to the terminal equipment so that the first user queries the service data according to the first hash value.
In the verification device for blockchain data provided in one or more embodiments of the present specification, when receiving a service data query request sent by a terminal device of a first user, service data is queried from a first blockchain based on a first hash value included in the service data query request and sent to the terminal device of the first user, so that the terminal device of the first user verifies the service data. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
In another embodiment, the apparatus for verifying blockchain data includes a memory, and one or more programs, wherein the one or more programs are stored in the memory, and the one or more programs may include one or more modules, and each module may include a series of computer-executable instructions for a public opinion querying device, and the one or more programs configured to be executed by the one or more processors include computer-executable instructions for:
receiving a verification information query request sent by terminal equipment of a first user, wherein the verification information query request comprises index information;
inquiring related verification information from a second block chain according to the index information;
and sending the inquired verification information to the terminal equipment so that the terminal equipment verifies the service data to be verified according to the verification information.
Optionally, when executed, the computer-executable instructions, before receiving the authentication information query request sent by the terminal device of the first user, further include:
receiving a second data storage request sent by the terminal equipment; the second data storage request comprises a first hash value and a second hash value, the first hash value is a hash value calculated by the first block chain node based on the service data and additional data when the first user stores the service data to be stored to the first block chain in advance through the first block chain node in the first block chain, and the second hash value is a hash value calculated by the terminal device based on the service data to be stored;
calculating a third hash value according to the first hash value and the second hash value;
storing the first hash value, the second hash value, and the third hash value association into the second blockchain; and the number of the first and second groups,
and sending the third hash value to the terminal equipment.
Optionally, when executed, the index information includes the third hash value, and the querying the associated verification information from the second block chain according to the index information includes:
inquiring the related first hash value and the second hash value from a second block chain according to the third hash value to obtain verification information;
alternatively, the first and second electrodes may be,
the index information includes the first hash value, and the querying the associated verification information from the second block chain according to the index information includes:
inquiring the associated second hash value from a second block chain according to the first hash value to obtain verification information;
alternatively, the first and second electrodes may be,
the index information includes the first hash value and the third hash value, and the querying the associated verification information from the second block chain according to the index information includes:
and inquiring the associated second hash value from a second block chain according to the first hash value and the third hash value to obtain verification information.
Optionally, when the computer-executable instructions are executed, the index information includes a first hash value, where the first hash value is a hash value stored in a first block chain, and calculated by a second user based on the service data and additional data when the second user stores the service data to be stored in the first block chain in advance through a first block link point in the first block chain;
the querying the associated verification information from the second blockchain according to the index information includes:
inquiring the associated second hash value from a second block chain according to the first hash value to obtain verification information; the second hash value is a hash value calculated by the terminal device of the second user based on the service data saved in the first block chain.
In the verification device for blockchain data provided in one or more embodiments of the present specification, when receiving a verification information query request sent by a terminal device of a first user, related verification information is queried from a second blockchain based on index information included in the verification information query request and sent to the terminal device of the first user, so that the terminal device of the first user verifies to-be-verified data based on the verification information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
It should be noted that the embodiment of the verification apparatus for blockchain data in this specification and the embodiment of the verification method for blockchain data in this specification are based on the same inventive concept, and therefore, for specific implementation of this embodiment, reference may be made to implementation of the verification method for blockchain data described above, and repeated details are not repeated.
Further, based on the same technical concept, one or more embodiments of the present specification further provide a storage medium for storing computer-executable instructions, where in a specific embodiment, the storage medium may be a usb disk, an optical disk, a hard disk, and the like, and when the storage medium stores the computer-executable instructions, the following process can be implemented:
acquiring service data to be verified from a first block chain; the first block chain is used for storing service data of a user;
acquiring verification information of the service data from a second block chain; the second block chain is used for storing the verification information of the service data in the first block chain;
and verifying the service data according to the verification information.
In one or more embodiments of the present specification, service data to be verified is obtained from a first blockchain, verification information of the service data is obtained from a second blockchain, and the service data is verified according to the obtained verification information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
Optionally, the computer-executable instructions stored in the storage medium, when executed by the processor, obtain service data to be verified from the first blockchain, including:
sending a service data query request to a first block link point in the first block chain, wherein the service data query request includes a first hash value, so that the first block link point queries related service data from the first block chain according to the first hash value, and the first hash value is a hash value calculated by the first block link point based on the service data and additional data when the first user stores the service data to be stored to the first block chain through the first block link point in advance;
and receiving the service data sent by the first blockchain node.
Optionally, the storage medium stores computer-executable instructions, which when executed by the processor, further include, before the obtaining the service data to be verified from the first blockchain:
sending a first data storage request to the first blockchain node; wherein the first data storage request includes the service data to be stored, so that the first block link node stores the service data and the first hash value association into the first block chain;
and receiving the first hash value sent by the first blockchain node.
Optionally, the storage medium stores computer-executable instructions that, when executed by the processor, obtain the verification information of the service data from the second blockchain, including:
sending a verification information query request to a second block link point in a second block chain, wherein the verification information query request comprises index information of verification information to be queried, so that the second block link point queries related verification information from the second block chain according to the index information;
and receiving the verification information sent by the second blockchain node.
Optionally, the storage medium stores computer-executable instructions, which when executed by the processor, further include, before the obtaining the verification information of the service data from the second blockchain:
calculating a second hash value of the service data to be stored according to a first preset algorithm;
sending a second data storage request to the second blockchain node; wherein the second data storage request includes the first hash value and the second hash value, such that the second chunk link node stores the first hash value, the second hash value, and a third hash value in association with the second chunk chain, the third hash value being a hash value calculated by the second chunk link node based on the first hash value and the second hash value;
and receiving the third hash value sent by the second blockchain node.
Optionally, the storage medium stores computer-executable instructions that, when executed by the processor, the index information includes the third hash value, and the verification information includes the first hash value and the second hash value;
the verifying the service data according to the verification information includes:
determining whether a first hash value included in the verification information is consistent with a first hash value stored by the terminal equipment; and the number of the first and second groups,
calculating a fourth hash value of the acquired service data according to the preset algorithm, and determining whether the calculated fourth hash value is consistent with a second hash value included in the verification information;
and if the service data are consistent, determining that the service data pass the verification.
Optionally, the storage medium stores computer-executable instructions that, when executed by a processor, the index information includes the first hash value, or the index information includes the first hash value and the third hash value; the verification information comprises the second hash value;
the verifying the service data according to the verification information includes:
calculating a fourth hash value of the acquired service data according to the preset algorithm, and determining whether the fourth hash value is consistent with the second hash value included in the verification information;
and if the service data are consistent, determining that the service data pass the verification.
Optionally, the computer-executable instructions stored in the storage medium, when executed by the processor, obtain service data to be verified from the first blockchain, including:
acquiring service data to be verified and a first hash value associated with the service data from a first block chain; the first hash value is a hash value calculated by a first block link point based on the service data and additional data when a second user stores the service data to the first block link through the first block link point in the first block link in advance;
the obtaining the verification information of the service data from the second blockchain includes:
taking the obtained first hash value as index information of verification information to be inquired, and sending a verification information inquiry request to a second block chain link point in a second block chain according to the index information so that the second block chain link point inquires associated verification information from the second block chain according to the index information;
and receiving the verification information sent by the second blockchain node.
Optionally, the storage medium stores computer-executable instructions that, when executed by the processor, cause the authentication information to include: the terminal equipment of the second user calculates a second hash value obtained by the service data stored in the first block chain in advance according to a first preset algorithm;
the verifying the service data according to the verification information includes:
calculating a fourth hash value of the acquired service data according to the preset algorithm, and determining whether the fourth hash value is consistent with the second hash value included in the verification information;
and if the service data are consistent, determining that the service data pass the verification.
One or more embodiments of the present specification provide a storage medium storing computer-executable instructions that, when executed by a processor, perform authentication on service data by acquiring service data to be authenticated from a first blockchain and acquiring authentication information of the service data from a second blockchain, and authenticating the service data according to the acquired authentication information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
In another specific embodiment, the storage medium may be a usb disk, an optical disk, a hard disk, or the like, and the storage medium stores computer executable instructions that, when executed by the processor, implement the following process:
receiving a service data query request sent by terminal equipment of a first user, wherein the service data query request comprises a first hash value;
inquiring related service data from a first block chain according to the first hash value;
and sending the inquired service data to the terminal equipment so that the terminal equipment verifies the service data.
Optionally, the storage medium stores computer-executable instructions, which when executed by the processor, further include, before receiving a service data query request sent by a terminal device of a first user:
receiving a first data storage request sent by the terminal equipment; wherein the first data storage request comprises the service data to be stored;
calculating the first hash value according to the service data and the additional data;
storing the first hash value and the business data association into the first block chain; and the number of the first and second groups,
and sending the first hash value to the terminal equipment so that the first user queries the service data according to the first hash value.
One or more embodiments of the present specification provide a storage medium storing computer-executable instructions, which when executed by a processor, when receiving a service data query request sent by a terminal device of a first user, query service data from a first block chain based on a first hash value included in the service data query request and send the service data to the terminal device of the first user, so that the terminal device of the first user verifies the service data. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
In another specific embodiment, the storage medium may be a usb disk, an optical disk, a hard disk, or the like, and the storage medium stores computer executable instructions that, when executed by the processor, implement the following process:
receiving a verification information query request sent by terminal equipment of a first user, wherein the verification information query request comprises index information;
inquiring related verification information from a second block chain according to the index information;
and sending the inquired verification information to the terminal equipment so that the terminal equipment verifies the service data to be verified according to the verification information.
Optionally, the storage medium stores computer-executable instructions, which when executed by the processor, further include, before receiving the authentication information query request sent by the terminal device of the first user:
receiving a second data storage request sent by the terminal equipment; the second data storage request comprises a first hash value and a second hash value, the first hash value is a hash value calculated by the first block chain node based on the service data and additional data when the first user stores the service data to be stored to the first block chain in advance through the first block chain node in the first block chain, and the second hash value is a hash value calculated by the terminal device based on the service data to be stored;
calculating a third hash value according to the first hash value and the second hash value;
storing the first hash value, the second hash value, and the third hash value association into the second blockchain; and the number of the first and second groups,
and sending the third hash value to the terminal equipment so that the first user queries verification information according to the third hash value.
Optionally, the storage medium stores computer-executable instructions that, when executed by the processor, the index information including the third hash value, the querying the associated verification information from the second blockchain according to the index information, including:
inquiring the related first hash value and the second hash value from a second block chain according to the third hash value to obtain verification information;
alternatively, the first and second electrodes may be,
the index information includes the first hash value, and the querying the associated verification information from the second block chain according to the index information includes:
inquiring the associated second hash value from a second block chain according to the first hash value to obtain verification information;
alternatively, the first and second electrodes may be,
the index information includes the first hash value and the third hash value, and the querying the associated verification information from the second block chain according to the index information includes:
and inquiring the associated second hash value from a second block chain according to the first hash value and the third hash value to obtain verification information.
Optionally, when the computer-executable instructions stored in the storage medium are executed by a processor, the index information includes a first hash value, where the first hash value is a hash value stored in a first block chain, and calculated by a second user on the basis of the service data and additional data when the second user stores the service data to be stored in the first block chain in advance through a first block link point in the first block chain;
the querying the associated verification information from the second blockchain according to the index information includes:
inquiring the associated second hash value from a second block chain according to the first hash value to obtain verification information; the second hash value is a hash value calculated by the terminal device of the second user based on the service data saved in the first block chain.
When receiving an authentication information query request sent by a terminal device of a first user, the storage medium stores computer executable instructions which, when executed by a processor, query associated authentication information from a second blockchain based on index information included in the authentication information query request and send the query to the terminal device of the first user, so that the terminal device of the first user authenticates data to be authenticated based on the authentication information. Thus, for the first user, it does not need to deploy a node device to become a node in the blockchain, nor participate in consensus verification, and does not need to store all data in the blockchain; even in this way, the first user can still verify the service data in the first block chain, and therefore, the requirement of the first user on verification of the service data is met on the basis that excessive resources of the first user are not occupied.
It should be noted that the embodiment of the storage medium in this specification and the embodiment of the verification method of the blockchain data in this specification are based on the same inventive concept, and therefore, for specific implementation of this embodiment, reference may be made to the implementation of the verification method of the blockchain data described above, and repeated details are not repeated.
The foregoing description has been directed to specific embodiments of this disclosure. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.
In the 30 s of the 20 th century, improvements in a technology could clearly be distinguished between improvements in hardware (e.g., improvements in circuit structures such as diodes, transistors, switches, etc.) and improvements in software (improvements in process flow). However, as technology advances, many of today's process flow improvements have been seen as direct improvements in hardware circuit architecture. Designers almost always obtain the corresponding hardware circuit structure by programming an improved method flow into the hardware circuit. Thus, it cannot be said that an improvement in the process flow cannot be realized by hardware physical modules. For example, a Programmable Logic Device (PLD), such as a Field Programmable Gate Array (FPGA), is an integrated circuit whose Logic functions are determined by programming the Device by a user. A digital system is "integrated" on a PLD by the designer's own programming without requiring the chip manufacturer to design and fabricate application-specific integrated circuit chips. Furthermore, nowadays, instead of manually making an integrated Circuit chip, such Programming is often implemented by "logic compiler" software, which is similar to a software compiler used in program development and writing, but the original code before compiling is also written by a specific Programming Language, which is called Hardware Description Language (HDL), and HDL is not only one but many, such as abel (advanced Boolean Expression Language), ahdl (alternate Language Description Language), traffic, pl (core unified Programming Language), HDCal, JHDL (Java Hardware Description Language), langue, Lola, HDL, laspam, hardsradware (Hardware Description Language), vhjhd (Hardware Description Language), and vhigh-Language, which are currently used in most common. It will also be apparent to those skilled in the art that hardware circuitry that implements the logical method flows can be readily obtained by merely slightly programming the method flows into an integrated circuit using the hardware description languages described above.
The controller may be implemented in any suitable manner, for example, the controller may take the form of, for example, a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro) processor, logic gates, switches, an Application Specific Integrated Circuit (ASIC), a programmable logic controller, and an embedded microcontroller, examples of which include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320, the memory controller may also be implemented as part of the control logic for the memory. Those skilled in the art will also appreciate that, in addition to implementing the controller as pure computer readable program code, the same functionality can be implemented by logically programming method steps such that the controller is in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers, embedded microcontrollers and the like. Such a controller may thus be considered a hardware component, and the means included therein for performing the various functions may also be considered as a structure within the hardware component. Or even means for performing the functions may be regarded as being both a software module for performing the method and a structure within a hardware component.
The systems, devices, modules or units illustrated in the above embodiments may be implemented by a computer chip or an entity, or by a product with certain functions. One typical implementation device is a computer. In particular, the computer may be, for example, a personal computer, a laptop computer, a cellular telephone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.
For convenience of description, the above devices are described as being divided into various units by function, and are described separately. Of course, the functions of the units may be implemented in the same software and/or hardware or in multiple software and/or hardware when implementing the embodiments of the present description.
One skilled in the art will recognize that one or more embodiments of the present description may be provided as a method, system, or computer program product. Accordingly, one or more embodiments of the present description may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the description may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The description has been presented with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the description. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, a computer readable medium does not include a transitory computer readable medium such as a modulated data signal and a carrier wave.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
One or more embodiments of the present description may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. One or more embodiments of the specification may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the system embodiment, since it is substantially similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
The above description is only an example of this document and is not intended to limit this document. Various modifications and changes may occur to those skilled in the art from this document. Any modifications, equivalents, improvements, etc. which come within the spirit and principle of the disclosure are intended to be included within the scope of the claims of this document.

Claims (26)

1. A verification method of block chain data is applied to terminal equipment of a first user and comprises the following steps:
acquiring service data to be verified from a first block chain; the first block chain is used for storing service data of a user;
acquiring verification information of the service data from a second block chain; the second block chain is used for storing the verification information of the service data in the first block chain;
and verifying the service data according to the verification information.
2. The method of claim 1, wherein the obtaining the service data to be verified from the first blockchain comprises:
sending a service data query request to a first block link node in the first block chain; wherein the service data query request comprises a first hash value, so that the first block link point queries the associated service data from the first block chain according to the first hash value; the first hash value is a hash value calculated by the first block link point based on the service data and additional data when the first user stores the service data to be stored to the first block chain through the first block link point in advance;
and receiving the service data sent by the first blockchain node.
3. The method according to claim 2, before the obtaining the service data to be verified from the first blockchain, further comprising:
sending a first data storage request to the first blockchain node; wherein the first data storage request includes the service data to be stored, so that the first block link node stores the service data and the first hash value association into the first block chain;
and receiving the first hash value sent by the first blockchain node.
4. The method of claim 2, wherein the obtaining the verification information of the service data from the second blockchain comprises:
sending a verification information query request to a second block link point in a second block chain; the verification information query request comprises index information of verification information to be queried, so that the second block link point queries related verification information from the second block chain according to the index information;
and receiving the verification information sent by the second blockchain node.
5. The method of claim 4, before the obtaining the verification information of the service data from the second blockchain, further comprising:
calculating a second hash value of the service data to be stored according to a first preset algorithm;
sending a second data storage request to the second blockchain node; wherein the second data storage request includes the first hash value and the second hash value such that the second blockchain link saves the first hash value, the second hash value, and a third hash value association into the second blockchain; the third hash value is a hash value calculated by the second block link point based on the first hash value and the second hash value;
and receiving the third hash value sent by the second blockchain node.
6. The method of claim 5, the index information comprising the third hash value, the validation information comprising the first hash value and the second hash value;
the verifying the service data according to the verification information includes:
determining whether a first hash value included in the verification information is consistent with a first hash value stored by the terminal equipment; and the number of the first and second groups,
calculating a fourth hash value of the acquired service data according to the preset algorithm, and determining whether the calculated fourth hash value is consistent with a second hash value included in the verification information;
and if the service data are consistent, determining that the service data pass the verification.
7. The method of claim 5, the index information comprising the first hash value, or the index information comprising the first hash value and the third hash value; the verification information comprises the second hash value;
the verifying the service data according to the verification information includes:
calculating a fourth hash value of the acquired service data according to the preset algorithm, and determining whether the fourth hash value is consistent with the second hash value included in the verification information;
and if the service data are consistent, determining that the service data pass the verification.
8. The method of claim 1, wherein the obtaining the service data to be verified from the first blockchain comprises:
acquiring service data to be verified and a first hash value associated with the service data from a first block chain; the first hash value is a hash value calculated by a first block link point based on the service data and additional data when a second user stores the service data to the first block link through the first block link point in the first block link in advance;
the obtaining the verification information of the service data from the second blockchain includes:
taking the obtained first hash value as index information of verification information to be inquired, and sending a verification information inquiry request to a second block chain link point in a second block chain according to the index information so that the second block chain link point inquires associated verification information from the second block chain according to the index information;
and receiving the verification information sent by the second blockchain node.
9. The method of claim 8, the authentication information comprising: the terminal equipment of the second user calculates a second hash value obtained by the service data stored in the first block chain in advance according to a first preset algorithm;
the verifying the service data according to the verification information includes:
calculating a fourth hash value of the acquired service data according to the preset algorithm, and determining whether the fourth hash value is consistent with the second hash value included in the verification information;
and if the service data are consistent, determining that the service data pass the verification.
10. A verification method of block chain data is applied to a first block chain node and comprises the following steps:
receiving a service data query request sent by terminal equipment of a first user, wherein the service data query request comprises a first hash value;
inquiring related service data from a first block chain according to the first hash value;
and sending the inquired service data to the terminal equipment so that the terminal equipment verifies the service data.
11. The method of claim 10, before receiving the service data query request sent by the terminal device of the first user, further comprising:
receiving a first data storage request sent by the terminal equipment; wherein the first data storage request comprises the service data to be stored;
calculating the first hash value according to the service data and the additional data;
storing the first hash value and the business data association into the first block chain; and the number of the first and second groups,
and sending the first hash value to the terminal equipment so that the first user queries the service data according to the first hash value.
12. A verification method of block chain data is applied to a second block chain node and comprises the following steps:
receiving a verification information query request sent by terminal equipment of a first user, wherein the verification information query request comprises index information;
inquiring related verification information from a second block chain according to the index information;
and sending the inquired verification information to the terminal equipment so that the terminal equipment verifies the service data to be verified according to the verification information.
13. The method of claim 12, before receiving the authentication information query request sent by the terminal device of the first user, further comprising:
receiving a second data storage request sent by the terminal equipment; the second data storage request comprises a first hash value and a second hash value, the first hash value is a hash value calculated by the first block chain node based on the service data and additional data when the first user stores the service data to be stored to the first block chain in advance through the first block chain node in the first block chain, and the second hash value is a hash value calculated by the terminal device based on the service data to be stored;
calculating a third hash value according to the first hash value and the second hash value;
storing the first hash value, the second hash value, and the third hash value association into the second blockchain; and the number of the first and second groups,
and sending the third hash value to the terminal equipment.
14. The method of claim 13, wherein the first and second light sources are selected from the group consisting of,
the index information includes the third hash value, and the querying the associated verification information from the second block chain according to the index information includes:
inquiring the related first hash value and the second hash value from a second block chain according to the third hash value to obtain verification information;
alternatively, the first and second electrodes may be,
the index information includes the first hash value, and the querying the associated verification information from the second block chain according to the index information includes:
inquiring the associated second hash value from a second block chain according to the first hash value to obtain verification information;
alternatively, the first and second electrodes may be,
the index information includes the first hash value and the third hash value, and the querying the associated verification information from the second block chain according to the index information includes:
and inquiring the associated second hash value from a second block chain according to the first hash value and the third hash value to obtain verification information.
15. The method according to claim 12, wherein the index information includes a first hash value, and the first hash value is a hash value stored in a first block chain, and calculated by a second user based on the service data and additional data when the service data to be stored is saved to the first block chain in advance through a first block link point in the first block chain;
the querying the associated verification information from the second blockchain according to the index information includes:
inquiring the associated second hash value from a second block chain according to the first hash value to obtain verification information; the second hash value is a hash value calculated by the terminal device of the second user based on the service data saved in the first block chain.
16. A verification device of block chain data is applied to terminal equipment of a first user and comprises:
the first acquisition module acquires service data to be verified from the first block chain; the first block chain is used for storing service data of a user;
the second acquisition module acquires the verification information of the service data from a second block chain; the second block chain is used for storing the verification information of the service data in the first block chain;
and the verification module verifies the service data according to the verification information.
17. The apparatus of claim 16, wherein the first and second electrodes are disposed in a common plane,
the first acquisition module sends a service data query request to a first block link point in the first block chain; wherein the service data query request comprises a first hash value, so that the first block link point queries the associated service data from the first block chain according to the first hash value; the first hash value is a hash value calculated by the first block link point based on the service data and additional data when the first user stores the service data to be stored to the first block chain through the first block link point in advance; and the number of the first and second groups,
and receiving the service data sent by the first blockchain node.
18. The apparatus of claim 16 or 17, wherein,
the second obtaining module is configured to send a verification information query request to a second block link point in a second block chain, where the verification information query request includes index information of verification information to be queried, so that the second block link point queries, according to the index information, associated verification information from the second block chain; and the number of the first and second groups,
and receiving the verification information sent by the second blockchain node.
19. A verification device of block chain data is applied to a first block chain node and comprises:
the system comprises a receiving module, a sending module and a receiving module, wherein the receiving module receives a service data query request sent by terminal equipment of a first user, and the service data query request comprises a first hash value;
the query module is used for querying the associated service data from the first block chain according to the first hash value;
and the sending module is used for sending the inquired business data to the terminal equipment so as to ensure that the terminal equipment verifies the business data.
20. A verification device of block chain data is applied to a second block chain node and comprises:
the system comprises a receiving module, a sending module and a receiving module, wherein the receiving module receives a verification information inquiry request sent by terminal equipment of a first user, and the verification information inquiry request comprises index information;
the query module is used for querying the associated verification information from the second block chain according to the index information;
and the sending module is used for sending the inquired verification information to the terminal equipment so as to verify the service data to be verified by the terminal equipment according to the verification information.
21. An apparatus for verifying blockchain data, comprising:
a processor; and the number of the first and second groups,
a memory arranged to store computer executable instructions that, when executed, cause the processor to:
acquiring service data to be verified from a first block chain; the second block chain is used for storing the verification information of the service data in the first block chain;
acquiring verification information of the service data from a second block chain; the second block chain is used for storing the verification information of the service data in the first block chain;
and verifying the service data according to the verification information.
22. An apparatus for verifying blockchain data, comprising:
a processor; and the number of the first and second groups,
a memory arranged to store computer executable instructions that, when executed, cause the processor to:
receiving a service data query request sent by terminal equipment of a first user, wherein the service data query request comprises a first hash value;
inquiring related service data from a first block chain according to the first hash value;
and sending the inquired service data to the terminal equipment so that the terminal equipment verifies the service data.
23. An apparatus for verifying blockchain data, comprising:
a processor; and the number of the first and second groups,
a memory arranged to store computer executable instructions that, when executed, cause the processor to:
receiving a verification information query request sent by terminal equipment of a first user, wherein the verification information query request comprises index information;
inquiring related verification information from a second block chain according to the index information;
and sending the inquired verification information to the terminal equipment so that the terminal equipment verifies the service data to be verified according to the verification information.
24. A storage medium storing computer-executable instructions that when executed implement the following:
acquiring service data to be verified from a first block chain; the first block chain is used for storing service data of a user;
acquiring verification information of the service data from a second block chain; the second block chain is used for storing the verification information of the service data in the first block chain;
and verifying the service data according to the verification information.
25. A storage medium storing computer-executable instructions that when executed implement the following:
receiving a service data query request sent by terminal equipment of a first user, wherein the service data query request comprises a first hash value;
inquiring related service data from a first block chain according to the first hash value;
and sending the inquired service data to the terminal equipment so that the terminal equipment verifies the service data.
26. A storage medium storing computer-executable instructions that when executed implement the following:
receiving a verification information query request sent by terminal equipment of a first user, wherein the verification information query request comprises index information;
inquiring related verification information from a second block chain according to the index information;
and sending the inquired verification information to the terminal equipment so that the terminal equipment verifies the service data to be verified according to the verification information.
CN201911044952.2A 2019-10-30 2019-10-30 Verification method, device and equipment of block chain data Active CN110781192B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911044952.2A CN110781192B (en) 2019-10-30 2019-10-30 Verification method, device and equipment of block chain data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911044952.2A CN110781192B (en) 2019-10-30 2019-10-30 Verification method, device and equipment of block chain data

Publications (2)

Publication Number Publication Date
CN110781192A true CN110781192A (en) 2020-02-11
CN110781192B CN110781192B (en) 2021-11-30

Family

ID=69387648

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911044952.2A Active CN110781192B (en) 2019-10-30 2019-10-30 Verification method, device and equipment of block chain data

Country Status (1)

Country Link
CN (1) CN110781192B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111292093A (en) * 2020-05-09 2020-06-16 支付宝(杭州)信息技术有限公司 Risk control method and system based on double block chains
CN111488616A (en) * 2020-04-08 2020-08-04 北京瑞策科技有限公司 Method and device for realizing preplan machine of service data block chain
CN111737707A (en) * 2020-05-14 2020-10-02 云南云烁巴克云科技有限公司 Verification packet generation and verification method based on block chain, server and electronic equipment
US20210326469A1 (en) * 2020-09-15 2021-10-21 Alipay (Hangzhou) Information Technology Co., Ltd. Data processing methods, apparatuses, and devices

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107196900A (en) * 2017-03-24 2017-09-22 阿里巴巴集团控股有限公司 A kind of method and device for verification of knowing together
CN107341702A (en) * 2017-03-08 2017-11-10 阿里巴巴集团控股有限公司 A kind of method and device of business processing
CN108961052A (en) * 2018-06-25 2018-12-07 百度在线网络技术(北京)有限公司 Verification method, storage method, device, equipment and the medium of block chain data

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107341702A (en) * 2017-03-08 2017-11-10 阿里巴巴集团控股有限公司 A kind of method and device of business processing
CN107196900A (en) * 2017-03-24 2017-09-22 阿里巴巴集团控股有限公司 A kind of method and device for verification of knowing together
CN108961052A (en) * 2018-06-25 2018-12-07 百度在线网络技术(北京)有限公司 Verification method, storage method, device, equipment and the medium of block chain data

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111488616A (en) * 2020-04-08 2020-08-04 北京瑞策科技有限公司 Method and device for realizing preplan machine of service data block chain
CN111292093A (en) * 2020-05-09 2020-06-16 支付宝(杭州)信息技术有限公司 Risk control method and system based on double block chains
CN111737707A (en) * 2020-05-14 2020-10-02 云南云烁巴克云科技有限公司 Verification packet generation and verification method based on block chain, server and electronic equipment
CN111737707B (en) * 2020-05-14 2022-09-27 云南云烁巴克云科技有限公司 Block chain based verification package generation and verification method, server and electronic equipment
US20210326469A1 (en) * 2020-09-15 2021-10-21 Alipay (Hangzhou) Information Technology Co., Ltd. Data processing methods, apparatuses, and devices
US11494511B2 (en) * 2020-09-15 2022-11-08 Alipay (Hangzhou) Information Technology Co., Ltd. Data processing methods, apparatuses, and devices

Also Published As

Publication number Publication date
CN110781192B (en) 2021-11-30

Similar Documents

Publication Publication Date Title
CN111680274B (en) Resource access method, device and equipment
CN110781192B (en) Verification method, device and equipment of block chain data
CN109614823B (en) Data processing method, device and equipment
CN107450981B (en) Block chain consensus method and equipment
CN112671769B (en) Electronic contract signing method, device and equipment
CN107426169B (en) Service processing method and device based on permission
CN110555296B (en) Identity verification method, device and equipment based on block chain
CN106899666B (en) Data processing method and device for service identification
CN109669709B (en) Data migration method and data migration system for block chain upgrading
CN111008840B (en) Service processing system, service processing method, device and equipment
CN115935428A (en) Information desensitization method, device and system
CN113079200A (en) Data processing method, device and system
CN112434348B (en) Data verification processing method, device and equipment
CN111008841A (en) Service processing system, service processing method, device and equipment
CN107070871B (en) Identity verification method and device
CN110995521B (en) Service providing method, device, equipment and system
CN108616361B (en) Method and device for identifying uniqueness of equipment
CN111651467B (en) Block chain node interface issuing and calling method and device
CN111753270B (en) Application program login verification method, device, equipment and storage medium
CN111737304A (en) Processing method, device and equipment of block chain data
CN113254163B (en) Processing method and device of block chain data
CN115129728A (en) File checking method and device
CN113946260A (en) Data processing method, device and equipment
CN111796864A (en) Data verification method and device
CN111163113A (en) Registration processing method, device, equipment and 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
REG Reference to a national code

Ref country code: HK

Ref legal event code: DE

Ref document number: 40023133

Country of ref document: HK

GR01 Patent grant
GR01 Patent grant