WO2022022457A1 - 基于区块链的数据管理方法、装置和系统 - Google Patents

基于区块链的数据管理方法、装置和系统 Download PDF

Info

Publication number
WO2022022457A1
WO2022022457A1 PCT/CN2021/108427 CN2021108427W WO2022022457A1 WO 2022022457 A1 WO2022022457 A1 WO 2022022457A1 CN 2021108427 W CN2021108427 W CN 2021108427W WO 2022022457 A1 WO2022022457 A1 WO 2022022457A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
pieces
complete
blockchain
verification
Prior art date
Application number
PCT/CN2021/108427
Other languages
English (en)
French (fr)
Inventor
赵君杰
Original Assignee
京东方科技集团股份有限公司
北京京东方技术开发有限公司
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 京东方科技集团股份有限公司, 北京京东方技术开发有限公司 filed Critical 京东方科技集团股份有限公司
Priority to EP21849628.9A priority Critical patent/EP4191973A1/en
Priority to US18/017,937 priority patent/US20230274271A1/en
Publication of WO2022022457A1 publication Critical patent/WO2022022457A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q20/00Payment architectures, schemes or protocols
    • G06Q20/38Payment protocols; Details thereof
    • G06Q20/389Keeping log of transactions for guaranteeing non-repudiation of a transaction
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1097Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q20/00Payment architectures, schemes or protocols
    • G06Q20/38Payment protocols; Details thereof
    • G06Q20/40Authorisation, e.g. identification of payer or payee, verification of customer or shop credentials; Review and approval of payers, e.g. check credit lines or negative lists
    • G06Q20/401Transaction verification
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange
    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16YINFORMATION AND COMMUNICATION TECHNOLOGY SPECIALLY ADAPTED FOR THE INTERNET OF THINGS [IoT]
    • G16Y10/00Economic sectors
    • G16Y10/25Manufacturing
    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16YINFORMATION AND COMMUNICATION TECHNOLOGY SPECIALLY ADAPTED FOR THE INTERNET OF THINGS [IoT]
    • G16Y40/00IoT characterised by the purpose of the information processing
    • G16Y40/60Positioning; Navigation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/12Applying verification of the received information
    • H04L63/123Applying verification of the received information received data contents, e.g. message integrity
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/12Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3236Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using cryptographic hash functions
    • H04L9/3239Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using cryptographic hash functions involving non-keyed hash functions, e.g. modification detection codes [MDCs], MD5, SHA or RIPEMD
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/50Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols using hash chains, e.g. blockchains or hash trees

Definitions

  • the present application relates to the technical field of data management, and more particularly, to a method, device and system for data management based on blockchain.
  • the current general IoT system framework is shown in Figure 1.
  • the IoT devices with limited capabilities such as sensors are connected to the IoT platform through the IoT gateway, and the full-featured IoT devices can be directly connected to the IoT platform or connected through the IoT gateway.
  • IoT platform centrally manages various devices and provides interfaces for upper-layer IoT applications. IoT applications access device data and control devices through the IoT platform.
  • a large number of industrial equipment are connected to the industrial Internet platform directly or through the Internet of Things gateway, reporting data in real time and receiving instructions sent by the platform.
  • the manufacturing industry is a typical heavy-asset enterprise, which needs to purchase a large amount of equipment, and has high capital requirements for the enterprise.
  • a shared equipment platform can be built, and the platform can "share" the surplus casting capacity or production lines (production equipment) of some enterprises online.
  • the enterprises in need are selected, they can realize the order production online, thereby solving the overcapacity of some foundry enterprises.
  • the problems of idle equipment, insufficient production capacity of some enterprises and backlog of orders are of great significance to promoting manufacturing enterprises (manufacturers) to accelerate resource optimization and industrial upgrading.
  • a blockchain-based data management method applied to a verification node, the method may include: acquiring transaction data, wherein the transaction data includes N pieces of summary data, and the N pieces of summary data are The summary data are respectively generated based on N pieces of data associated with the transaction data, where N is an integer greater than 1; M pieces of summary data to be used for verification are selected from the N pieces of summary data, where M is less than or equal to N and greater than or an integer equal to 1; obtain M pieces of stored data corresponding to the M pieces of summary data respectively; If the digests are the same, write the transaction data into the blockchain.
  • a blockchain-based data management method is also provided, applied to multiple verification nodes, the method includes: acquiring transaction data, wherein the transaction data includes N pieces of summary data, and the The N pieces of summary data are respectively based on the N pieces of data associated with the transaction data to generate pieces of data, where N is an integer greater than 1; M pieces of summary data to be used for verification are selected from the N pieces of summary data, and M is less than or an integer equal to N and greater than or equal to 1; wherein the digest data verified by the first type of verification nodes in the plurality of verification nodes includes a digest generated based on the shortest piece of data among the M pieces of data for generating the M pieces of digest data data; obtain M pieces of stored data respectively corresponding to the M pieces of summary data; calculate the respective digests of the M pieces of stored data, and when the M pieces of summary data and the respective digests of the M pieces of stored data are respectively the same In this case, write the transaction data to the blockchain.
  • a blockchain-based data management method applied to a using node, the method may include: obtaining transaction data included in a specific device and/or a time period M pieces of summary data in the N pieces of summary data, wherein the N pieces of summary data are respectively generated based on the N pieces of data associated with the transaction data, N is an integer greater than 1, and M is less than or equal to N and greater than or an integer equal to 1; obtain M pieces of stored data corresponding to the M pieces of summary data respectively; calculate the respective digests of the M pieces of stored data; When the digests are respectively the same, it is determined that the complete data associated with the transaction data has not been tampered with.
  • a blockchain-based data management method is also provided, applied to an intermediate device, the method may include: acquiring complete data of at least one sensor device; The complete data is divided into P pieces of data, and complete summary data is generated based on the complete data of the at least one sensor device and/or P pieces of summary data are respectively generated based on the P pieces of data, where P is an integer greater than 1; The pieces of data and/or the complete data are stored in the data server node; and the P pieces of summary data and/or N pieces of the complete summary data are included in the transaction data and sent to the verification node of the blockchain , N is equal to P or P+1; wherein, the M pieces of digest data in the N pieces of digest data calculated by the intermediate device of the verification node in the blockchain are the same as those calculated by the verification node.
  • the transaction data is generated into a block and written into the block chain, where M is an integer less than N
  • a blockchain-based data management apparatus comprising: a processor, and a memory having instructions stored thereon, the instructions, when executed, cause the processor to execute as above the method described.
  • a blockchain-based data management system comprising: at least one sensor device configured to generate complete data; a blockchain network, comprising: 25.
  • a blockchain-based A blockchain-based data management system comprising: at least one sensor device configured to generate complete data, and a blockchain network comprising: a data server node configured to store said complete data and/or P pieces of data divided by the complete data; a storage node configured to store complete summary data generated based on the complete data and/or at least one piece of digest data generated based on at least one piece of data in the P pieces of data divided by the complete data data; a validating node configured to perform the method performed at the validating node as described above; a usage node configured to perform the method performed at the usage node as described above; and an intermediary device configured To perform the method performed at the intermediary device as described above.
  • Figure 1 shows an IoT system framework.
  • Figure 2 shows the interaction flow between various subjects in an intelligent manufacturing application.
  • 3A-3B illustrate a blockchain network according to embodiments of the present disclosure.
  • 4A-4B illustrate a working process of a blockchain-based data management system according to an embodiment of the present disclosure.
  • 5A shows a flowchart of a blockchain-based data management method applied to a verification node according to an embodiment of the present disclosure.
  • FIG. 5B shows a flowchart of another blockchain-based data management method applied to a verification node according to an embodiment of the present disclosure.
  • FIG. 6 shows a flowchart of a blockchain-based data management method applied to using nodes according to an embodiment of the present disclosure.
  • FIG. 7 shows a flowchart of a blockchain-based data management method applied to an intermediate device according to an embodiment of the present disclosure.
  • FIG. 8 shows a structural block diagram of a blockchain-based data management apparatus applied to a verification node according to an embodiment of the present disclosure.
  • FIG. 9 shows a structural block diagram of a blockchain-based data management device using nodes according to an embodiment of the present disclosure.
  • FIG. 10 shows a block diagram of a block chain-based data management apparatus applied to an intermediate device according to an embodiment of the present disclosure.
  • These computer program instructions may be provided to a general-purpose computing device, a processor of a special-purpose computing device, and/or other programmable data processing apparatus, such that execution of the instructions via the computing device processor and/or other programmable data processing apparatus creates a methods of functions/acts specified in the block diagrams and/or flowchart blocks.
  • the present disclosure may also be implemented in hardware and/or software (including firmware, resident software, microcode, etc.). Still further, the present disclosure may take the form of a computer program product on a computer-usable or computer-readable storage medium having computer-usable or computer-readable program code embodied in the medium for use or by an instruction execution system. Used in conjunction with an instruction execution system.
  • a computer-usable or computer-readable medium can be any medium that can contain, store, communicate, transmit, or transmit a program for use by, or in connection with, an instruction execution system, apparatus, or device. device or equipment use.
  • the equipment provider is responsible for data collection related to the usage of the equipment, and charges the manufacturer after calculating the usage of the equipment.
  • the specific interaction process is shown in Figure 2.
  • the device provider server obtains the data uploaded by the device and calculates the device usage, and the manufacturer server obtains the device usage and pays for the data through platform interaction.
  • the non-business data (including usage data) of the equipment is collected and calculated by the equipment provider server, and the manufacturer server pays the fee according to the calculation result of the equipment provider server.
  • the manufacturer server pays the fee according to the calculation result of the equipment provider server.
  • other supply chain companies of the manufacturer also have the need to obtain equipment usage data, so that they can stock up in time according to the equipment usage.
  • blockchain technology As an emerging distributed data storage technology, blockchain technology has the following advantages:
  • the blockchain introduces the concept of "everyone keeps accounts”. Each participant joins the blockchain through client applications, for example, and has the right to keep accounts, which everyone can save.
  • Latest ledger and all history This highly redundant data storage method can improve the transparency of information between subjects who do not trust each other, realize that the ledger data cannot be tampered with and leave traces throughout the process, thereby promoting multi-party information sharing and collaborative operations.
  • the second is the equalization of participants.
  • the unified distributed ledger technology of the blockchain naturally solves the problem of "business sovereignty”, effectively realizes the equivalence of identity, power, responsibility, and interests of each participating subject. Real-time synchronous update of data makes cooperation more convenient and faster, and the enthusiasm of partners is improved.
  • the blockchain can realize the credibility of business data and the equalization of participating entities, promote multi-party information sharing and collaborative operation, and realize real-time synchronization and update of data among various participating entities, and ensure that the data is accurate and unmodifiable. , so as to build mutual trust between partners.
  • the participants mentioned in this article can be network nodes in the blockchain network, such as servers, computers, telephones, etc. connected through the network. For different types of blockchains, the way to become a node will be different.
  • each storage node on the blockchain needs to store complete historical transaction information, but the storage capacity of the node is limited. Moreover, when any participant in the blockchain wants to write new data into the blockchain, the verification process will be involved. How to improve the processing speed and save computing resources is also an urgent problem to be solved.
  • Data management includes various operations on data, including storing and retrieving data.
  • 3A-3B illustrate a blockchain network according to embodiments of the present disclosure.
  • the blockchain network is a decentralized network, which can also be regarded as a P2P network (Peer-to-Peer) network.
  • P2P network Peer-to-Peer
  • Each node based on the consensus mechanism is a peer node, and each node jointly provides network services.
  • nodes can be divided into different types according to the different functions provided by each node. For example, in the EOS public chain, 21 nodes are used as verification nodes, and the rest are ordinary nodes. In other blockchains, each node can act as a validator.
  • Verification nodes can be selected through competitive voting at regular intervals, and have the authority to verify transactions and add blocks to the blockchain, and can also be regarded as at least a part of super nodes and full nodes.
  • ordinary nodes in the blockchain network do not store ledger data or complete copies of the ledger, and only provide general computing power support.
  • Super nodes and full nodes are nodes with complete ledger data. They need to occupy memory to synchronize all blockchain data, and can independently verify all transactions on the blockchain and update the data in real time. They are mainly responsible for the broadcast and real-time data of blockchain transactions. verify.
  • the blockchain may also include storage nodes that store any data written to the blockchain (eg, the storage nodes may also be selected from at least a portion of supernodes capable of storing complete ledger data), as well as data from blocks The usage node that obtains data in the chain (this usage node is a common node).
  • the data management system shown in FIG. 3B can be used for data management in the intelligent manufacturing industry.
  • the non-business data (including usage data) of the equipment is collected and calculated by the equipment provider server, and the manufacturer server pays the fee according to the calculation result of the equipment provider server, if the equipment provider There are data modifications to the server, resulting in a difference in cost, and the manufacturer server is agnostic.
  • other supply chain companies of the manufacturer also have the need to obtain equipment usage data, so that they can stock up in time according to the equipment usage. Therefore, as shown in Figure 3B, the middle equipment, equipment provider servers, manufacturer servers and supply chain enterprise servers (not shown) involved in the smart manufacturing industry join the blockchain as blockchain nodes, more specifically , as a common node, and the intermediate device also communicates with the device provider server.
  • the intermediary device can be an industrial gateway between the blockchain network and the device. More generally, it can be an edge device (EDGE), which can be one or more in number, distributed near each device, with local computing, storage and networking. feature that can quickly process nearby data without returning the data to the data center and cloud service provider.
  • EDGE edge device
  • the multiple devices can be directly connected to the blockchain without intermediary devices as nodes of the blockchain, thereby omitting the intermediary devices.
  • the present disclosure has been described by taking the case of using an intermediate device as an example, but the present disclosure is not limited thereto.
  • the equipment provider server can be referred to as a data server node in the blockchain network, and the manufacturer server and the supply chain enterprise server (not shown) can be regarded as usage nodes.
  • multiple devices eg, sensor devices
  • the centralized architecture mode is still adopted for the communication connection of the intermediate device to the equipment provider server, that is, multiple devices report the complete equipment operation data to the intermediate equipment in their vicinity, and the (one or more) intermediate devices further report the equipment operation to the equipment provider server.
  • Complete data, and what is transmitted between the device and the intermediary device and between the intermediary device and the device provider server is the complete device operation complete data.
  • the equipment provider server, the manufacturer server, and the supply chain enterprise server (not shown) exchange information with each other in a decentralized architecture through the blockchain.
  • the device provider server can calculate the usage of the device based on the complete data of the device operation, and the device provider can charge the manufacturer based on this.
  • Device operation complete data is data associated with the usage of the device.
  • the multiple devices can directly access the blockchain without going through an intermediary device.
  • validator nodes there are multiple validator nodes in a blockchain, and for some types of blockchains, the number of validator nodes is relatively large. If all validating nodes are used to verify the data to be written and/or to verify the complete data, it will slow down the overall processing speed of the blockchain and increase the amount of computation.
  • embodiments of the present disclosure provide a blockchain-based data management method, device, and system.
  • the summary data generated based on the complete data is written into the blockchain, and the complete data is stored in the server, or further, only the complete summary data of the complete data or Validated with summary data generated from partial split data from the full data split.
  • the requirements for the storage capacity of the servers of the relevant nodes on the blockchain are reduced, and the unmodifiable characteristics of the blockchain are used to save the complete data and ensure that the complete data has not been modified, and on the other hand, the verification is improved.
  • the calculation amount and computing resources are reduced, and the processing speed of the server of the relevant node of the blockchain is reduced.
  • the data management system includes: at least one sensor device (hereinafter referred to as a device) configured to generate complete data; a blockchain network including: a data server node configured to store data; storage Nodes, which are configured to store digest data on the chain; validating nodes; using nodes; and intermediate devices (as mentioned earlier, if the computing processing power of the device is sufficient, the device can be directly connected to the blockchain and omit this intermediate equipment).
  • a blockchain network can also include any number of other types of nodes.
  • a data server eg, a device provider server
  • each node in the blockchain network may communicate with the data server to obtain the data stored therein. The data.
  • the data server node can be an equipment provider server node
  • the use node can be a manufacturer data server node and a supply chain enterprise data server node, all of which are common nodes.
  • the verification node and the storage node can be selected from a part of the super nodes in the blockchain network, and can overlap (only this part of the node chain stores the complete ledger data, including all transaction data that has been verified and written to the blockchain) .
  • each node joins the blockchain network (not shown).
  • the aforementioned intermediate equipment, equipment provider server, manufacturer server, and supply chain enterprise server join the blockchain network as ordinary nodes, wherein the blockchain network also includes storage nodes, verification nodes (storage nodes) and verification nodes are selected from at least a part of the super nodes).
  • the device sends a registration request to the middle device so that the device can upload data to the middle device, and the middle device sends a registration request to the data server node so that the middle device can upload data to the data server node.
  • the device After the device generates the data, the device sends a first information report request to the intermediate device, and the first information report request may include complete data of device operation (hereinafter referred to as complete data), and may also include device identification (ID) and/or or time information.
  • complete data complete data of device operation
  • ID device identification
  • time information is associated with the generated complete data for indicating the identity and time of the device that generated the complete data.
  • the device sends the first information reporting request to the intermediate device at predetermined intervals.
  • the data reported by a single device may be regarded as a complete piece of data.
  • the above-mentioned first information reporting request includes the device identifier.
  • multiple pieces of data reported by a single device in each time period can be used as a piece of time-combined complete data.
  • the above-mentioned first information reporting request includes the device identifier and optionally the time information, depending on the In the subsequent way of splitting the complete data.
  • multiple pieces of data reported by multiple devices in each time period can also be used as one piece of device combined complete data (for example, the initial complete data of all devices in the time period from 2:00 pm to 5:00 pm and from 8:00 pm to 11:00 pm
  • the data can be combined to obtain the complete data of the two devices), in this case, the above-mentioned first information reporting request includes time information, and optionally includes the device identifier of each device of the multiple devices, which depends on the subsequent the way to split the complete data.
  • the second information reporting request and the transaction creation request described in detail later selectively carry device identification and/or time information based on similar definitions.
  • the intermediate device After the intermediate device extracts the complete data and the device identification and/or time information from the first information reporting request, it performs the following operations: dividing the complete data into P pieces of data (that is, P pieces of divided data), and generating a complete summary based on the complete data data and/or P pieces of summary data are generated based on the P pieces of data respectively, where P is an integer greater than 1; the complete data and/or the P pieces of data are stored in the data server node, wherein the P pieces of data need to be stored in the data server node.
  • P pieces of data may be stored in the form of one complete piece of data, or may be stored as multiple pieces of stored data (2 to P pieces of stored data) in a separate form, and when the P pieces of data are stored When it is stored in the form of a complete piece of data or in the form of stored data less than P, when sending P pieces of data to the data server node, the intermediate device also sends the split information of the P pieces of data to the data server node, so that in the The stored data can be divided equally at the data server node to obtain the same P pieces of data (the complete data and/or the P pieces of data may be tampered with at the data server node, but the complete summary data and/or the P pieces of summary data are generated based on data that has not been tampered with), and then include the P pieces of summary data and/or N pieces of the complete summary data of the complete data in the transaction data and send it to the verification node of the blockchain, N Equal to P or P+1.
  • the operation of storing the complete data and/or the P pieces of data in the data server node includes: sending a second information reporting request to the data server node; the second information reporting request includes the complete data, the P pieces of data, and the generation of The device identifier corresponding to the device of the complete data and/or the time information corresponding to the complete data; receive an information reporting response from the data server node, and the information reporting response at least includes the address of the data server node, and each piece of data in the P pieces of data is in The storage location in this data server node.
  • the operation of including the N pieces of summary data in the transaction data and sending it to the verification node of the blockchain includes: sending to the verification node in the blockchain network (for example, packaging transaction-related data into blocks and broadcasting them through method) transaction creation request, the transaction creation request carries transaction data, the transaction data includes the complete summary data of the complete data and/or N pieces of summary data in the P pieces of summary data (that is, the N pieces of summary data are included in the In the transaction data, and N is equal to P or P+1, and based on which the complete data of N pieces of summary data and/or at least a part of the P pieces of data are also expressed as N pieces of data), and the transaction data also It may include the location information of the N pieces of data (the location information of the data server node that stores the N pieces of data and the location information of each piece of data in the N pieces of data in the data server node), the equipment corresponding to the N pieces of data identifier, and/or time information corresponding to the N pieces of data.
  • the intermediary device may segment the complete data in a sequence of preset proportions.
  • the complete data can be split into 5 split data in the order of 20%, 20%, 20%, 20% and 20% or in the order of 40%, 25%, 20%, 10% and 5%, and can
  • the relevant information of the predetermined proportion in order is carried in the transaction creation request together with the transaction data and notified (eg, by broadcasting) to each node in the blockchain.
  • the intermediate device may divide the complete data (as described above) for a piece of time combination of each device according to the above-mentioned preset ratio in sequence (that is, according to the amount of data), or may also divide the complete data by time based on time information to divide.
  • the complete data of equipment operation may be a piece of complete data of a combination of multiple devices in each time period. Therefore, it can also be divided according to the above-mentioned preset proportions in sequence (that is, according to the amount of data), and based on the device identification The device is divided, or divided by time period based on time information.
  • the manner of generating the digest of the data may include a hash operation, that is, it may include performing a hash operation on the data to obtain a hash value, and using the hash value as the digest of the data, so that as long as the data has a small amount of If it changes, the corresponding hash value will be completely different, so the digest of the data will be completely different.
  • a hash operation that is, it may include performing a hash operation on the data to obtain a hash value, and using the hash value as the digest of the data, so that as long as the data has a small amount of If it changes, the corresponding hash value will be completely different, so the digest of the data will be completely different.
  • an encryption process may be introduced in the process of generating the digest of the data, which may adopt the existing encryption technology, so it will not be described in detail here.
  • Table 1 provides a schematic description of the data processing process related to the intermediate device in the case where a complete piece of data is divided into two pieces of data, mainly including dividing the received complete data into first data and second data, generating The complete summary data of the complete data, the first summary data corresponding to the first data, the second summary data corresponding to the second data, and the complete summary data including the complete data and the first summary are sent to the blockchain network. data, and transaction data of at least a part of the second summary data (as shown in the following cases 1-4).
  • the complete data and/or the segmented first and second data are also sent to the data server node, and as previously described, the complete data, the first data and the second data may be sent to the data server node at the data server node. tampering, so that the complete data, the first data and the second data, which previously served as the basis for the computation at the intermediate device, may no longer be identical.
  • the verification node After extracting the transaction data from the transaction creation request, the verification node selects M pieces of summary data to be used for verification from the N pieces of summary data included in the transaction data, where M is an integer less than N and greater than or equal to 1 (for example, based on The split information received from the intermediate device in a predetermined proportion in sequence, for example, selecting 2 pieces of summary data corresponding to the fourth and fifth split data), wherein, as mentioned above, the intermediate device is based on the complete data and the The P pieces of data obtained from the division generate multiple pieces of summary data, and the N pieces of summary data among the pieces of summary data are included in the transaction data to be received by the verification node, and the N pieces of data based on which the N pieces of summary data are generated are received.
  • the verification node then obtains M pieces of stored data respectively corresponding to the M pieces of summary data; calculates the respective digests of the M pieces of stored data, and each of the M pieces of summary data is the same as the respective digests of the M pieces of stored data In the case of , write the transaction data into the blockchain. More specifically, based on the location information of the M pieces of data for generating the M pieces of summary data, a data acquisition request is sent to the data server node, the data acquisition request includes the location information, and the M pieces of the summary data corresponding to the M pieces of summary data are stored.
  • the location of the M pieces of stored data is the same as the location of the M pieces of data, and if the data has not been tampered with, the M pieces of stored data are the same as the M pieces of data, so in this paper, the M/P pieces of stored data can sometimes /P pieces of data exchange) data server node obtains M pieces of stored data, and calculates the digests of the M pieces of stored data in the same way as the intermediate device, each of the M pieces of summary data and the respective M pieces of stored data If the digests are the same, it is determined that the verification is passed, and the transaction data is written into the blockchain.
  • the N pieces of data are 1 piece of complete data and N-1 pieces of segmented data of the complete data
  • the M pieces of data based on which the M pieces of summary data are generated are 1 piece of complete data and M- of the complete data 1 piece of divided data, or M pieces of data are M pieces of divided data of complete data; or N pieces of data are N pieces of divided data of 1 complete data, and M pieces of data are M pieces of divided data of complete data.
  • the verification node When the M pieces of data are M pieces of split data including complete data or M-1 pieces of split data, the verification node only needs to obtain the split data, and does not need to obtain the complete data, and the data volume obtained by the verification node is small, thereby reducing the number of verification nodes.
  • the network bandwidth between the verification node and the data server also reduces the workload and calculation amount of the verification node and the data server.
  • the lengths of the P pieces of data divided by the intermediate device from the complete data may not be equal. Therefore, in order to further reduce the amount of calculation and save the computing resources, the shortest piece of summary data among the N pieces of summary data may be used as M pieces of summary data for verification.
  • the verification process is similar to the previously described process of using M pieces of summary data for verification, and will not be described in detail here.
  • the ratio of validating nodes to pass verification is set by the blockchain system, and administrators can set the ratio to adjust the speed of verification passing.
  • verification may also be performed in the following manner.
  • multiple verification nodes acquire transaction data, wherein the transaction data includes N pieces of summary data, the N pieces of summary data are respectively generated based on N pieces of data associated with the transaction data, and N is an integer greater than 1 .
  • the plurality of verification nodes may include a first type of verification node and a second type of verification node.
  • multiple verification nodes select M pieces of summary data to be used for verification from the N pieces of summary data, where M is an integer less than or equal to N and greater than or equal to 1, wherein the first type of verification nodes in the multiple verification nodes verifies
  • the summary data includes summary data generated based on a piece of data with the shortest length among the M pieces of data in which the M pieces of summary data are generated. For example, two pieces of summary data are selected from N pieces of summary data for verification, wherein the two pieces of summary data are generated based on the two pieces of data, and the first type of verification node verification is generated based on the shorter piece of the two pieces of data. summary data.
  • a plurality of verification nodes obtain M pieces of stored data corresponding to the M pieces of summary data respectively, and then calculate the respective digests of the M pieces of stored data, and the M pieces of summary data and the M pieces of stored data are respectively If the digests are the same, write the transaction data to the blockchain.
  • the M pieces of data may include 1 piece of complete data and M-1 pieces of split data of the complete data, so the second type of verification nodes in the plurality of nodes verify the digest data generated based on the complete data.
  • the M pieces of data include M pieces of split data of one complete piece of data, and the second type of verification nodes in the plurality of nodes verify the digest data that is not verified by the first type of verification nodes.
  • the number of verification nodes of the first type is greater than the number of verification nodes of the second type.
  • the digest data generated from the split data of the complete data can be verified using only a part of the verification nodes, and the complete digest data can be verified by another part of the verification nodes, and the number of the former is larger.
  • 80% of the validating nodes are used to verify the digest data generated by the split data, and 20% of the validating nodes are used to perform the verification of the complete digest data.
  • 80% of the validators are used to verify the digest data generated by the shortest split data, and 20% of the validators are used to perform the verification of the remaining M-1 pieces of digest data.
  • the consuming node wishes to obtain transaction data from the blockchain and determine whether the complete data of the device has been tampered with, the following operations can be performed at the consuming node.
  • the storage node is a part of the super node in the blockchain network, and the complete ledger data, that is, all transaction data, is stored at the super node, and the using node does not store the complete ledger data and thus does not have the transaction data it expects to obtain or does not store the data.
  • the consuming node needs to obtain transaction data from the storage node (super node) to further check whether the complete data of the device has been tampered with.
  • Figure 4B A corresponding schematic flow diagram is shown in Figure 4B.
  • the process of data acquisition may include: acquiring M pieces of summary data included in the N pieces of summary data included in the transaction data corresponding to a specific device and/or time period, wherein the N pieces of summary data are respectively based on N pieces of summary data associated with the transaction data.
  • N is an integer greater than 1
  • M is an integer less than or equal to N and greater than or equal to 1
  • obtain M pieces of stored data corresponding to the M pieces of summary data calculate the respective digests of the M pieces of stored data; and
  • the respective digests of the M pieces of summary data and the M pieces of stored data are respectively the same, it is determined that the complete data associated with the transaction data has not been tampered with, and optionally the transaction data is obtained from the storage node in the blockchain, and the transaction data is obtained from the storage node in the blockchain.
  • the data server node storing the N pieces of data associated with the transaction data acquires the N pieces of data associated with the transaction data.
  • the particular device and/or time period is the device and/or time period for which data is desired.
  • a digest data acquisition request is sent by the usage node to a storage node (eg, a super node) in the blockchain, the digest data acquisition request including at least a connection with the specific device and/or time period. corresponding device identification and/or time information, and receive a digest data acquisition response from the storage node, where the digest data acquisition response includes at least M pieces of digest data among the N pieces of digest data.
  • each piece of transaction data stored in the storage node may also include the location information of the N pieces of data that generated the N pieces of summary data (the data of the data server node that stores the N pieces of data). location information and location information of each of the N pieces of data in the data server node), a device identifier corresponding to the N pieces of data, and/or time information corresponding to the N pieces of data.
  • the summary data acquisition response also includes the address of the data server node that stores the N pieces of data, and the storage location of the M pieces of stored data in the data server node. Therefore, the node is used based on the above information included in the data acquisition response. , to obtain the M pieces of stored data from the data server node. Then, the respective digests of the M pieces of stored data are calculated, and under the condition that the M pieces of summary data are the same as the respective digests of the M pieces of stored data, it can be determined that the complete data associated with the transaction data has not been tampered with .
  • N pieces of data are 1 piece of complete data and N-1 pieces of split data of the complete data
  • M pieces of data based on which M pieces of summary data are generated are 1 piece of complete data and M-1 pieces of complete data.
  • data, or M pieces of data are M pieces of divided data of complete data; or N pieces of data are N pieces of divided data of 1 complete data, and M pieces of data are M pieces of divided data of complete data.
  • the M pieces of data are M pieces of divided data or M-1 pieces of divided data including the complete data
  • only the divided data needs to be obtained by using the node, and the complete data does not need to be obtained, and the data volume obtained by using the node is small, thereby reducing the usage
  • the network bandwidth between the node and the data server also reduces the workload and computing amount of the node and the data server.
  • the summary data generated based on the complete data is written into the blockchain, and the complete data (and its divided P pieces of data) are stored off-chain in the server, or more Further, the complete summary data of the complete data or the summary of a part of the data of the complete data is only verified by at least a part of the verification nodes, on the one hand, the requirements for the storage capacity of the relevant nodes on the blockchain are reduced, and the blockchain's storage capacity is reduced.
  • the unmodifiable feature is to save the complete data and ensure that the complete data has not been modified. On the other hand, it increases the accuracy of verification, reduces the amount of calculation and computing resources, and reduces the processing speed requirements for the relevant nodes on the blockchain. .
  • a blockchain-based data management method is provided, which is applied to a verification node.
  • 5A-5B illustrate blockchain-based data management methods 500A and 500B according to embodiments of the present disclosure.
  • the methods 500A and 500B are used to verify the data to be written into the blockchain, can be executed at at least a part of the verification nodes, and include the following steps.
  • step 510 transaction data is obtained, transaction data is obtained, wherein the transaction data includes N pieces of summary data, and the N pieces of summary data are respectively generated based on N pieces of data associated with the transaction data, N is an integer greater than 1.
  • the N pieces of data are 1 piece of complete data and N-1 pieces of divided data of the complete data, or the N pieces of data are N pieces of divided data of the complete data.
  • the N pieces of data can be obtained by dividing the data uploaded by the device as complete data.
  • step 520 M pieces of summary data to be used for verification are selected from the N pieces of summary data, where M is an integer less than or equal to N and greater than or equal to 1.
  • step 530 M pieces of stored data respectively corresponding to the M pieces of summary data are acquired.
  • the M pieces of data are 1 piece of complete data and M-1 pieces of divided data of the complete data, or the M pieces of data are M pieces of divided data of the complete data.
  • the transaction data further includes location information of the N pieces of data, wherein the M pieces of data can be acquired respectively according to the location information of the M pieces of stored data.
  • the transaction data further includes device identifiers corresponding to the N pieces of data, and/or time information corresponding to the N pieces of data
  • the location information of the N pieces of data includes: location information of the data server node that stores the N pieces of data and Location information of each piece of data in the data server node in the N pieces of data.
  • step 540 the respective digests of the M pieces of stored data are calculated.
  • step 550 when the respective digests of the M pieces of digest data and the M pieces of stored data are the same, the transaction data is written into the blockchain.
  • the transaction data Write to the blockchain.
  • step 5100 transaction data is acquired, wherein the transaction data includes N pieces of summary data, the N pieces of summary data are respectively generated based on N pieces of data associated with the transaction data, and N is an integer greater than 1.
  • M pieces of summary data to be used for verification are selected from N pieces of summary data, where M is an integer less than or equal to N and greater than or equal to 1; wherein the digests verified by the first type of verification nodes in the plurality of verification nodes
  • the data includes summary data generated based on a piece of data with the shortest length among the M pieces of data for generating the M pieces of summary data.
  • the M pieces of data include 1 piece of complete data and M-1 pieces of split data of the complete data, and a second type of verification node in the plurality of nodes verifies summary data generated based on the complete data.
  • the M pieces of data include M pieces of split data of one complete piece of data, and the second type of verification node in the plurality of nodes verifies the digest data that is not verified by the first type of verification node.
  • the number of verification nodes of the first type is greater than the number of verification nodes of the second type.
  • step 5300 M pieces of stored data respectively corresponding to the M pieces of summary data are acquired.
  • the respective digests of the M pieces of stored data are calculated.
  • step 5500 when the digests of the M pieces of summary data and the M pieces of stored data are respectively the same, write the transaction data into the blockchain.
  • the steps of obtaining summary data, obtaining stored data, and calculating the summary are similar to those described above, and thus will not be described in detail here.
  • FIG. 6 shows a blockchain-based data management method 600 according to an embodiment of the present disclosure.
  • the method 600 is used to obtain data from the blockchain and includes the following steps.
  • step S610 acquire M pieces of summary data included in the N pieces of summary data included in the transaction data corresponding to a specific device and/or time period, wherein the N pieces of summary data are respectively based on the data associated with the transaction data N pieces of data are generated, where N is an integer greater than 1, and M is an integer less than or equal to N and greater than or equal to 1.
  • the N pieces of data are 1 piece of complete data and N-1 pieces of divided data of the complete data, or the N pieces of data are N pieces of divided data of the complete data.
  • the M pieces of data are 1 piece of complete data and M-1 pieces of divided data of the complete data, or the M pieces of data are M pieces of divided data of the complete data.
  • the operation of acquiring M pieces of summary data may include: sending, by the using node, a request for obtaining summary data to a storage node in the blockchain, where the request for obtaining summary data at least includes a request corresponding to the specific device and/or time period.
  • device identification and/or time information receive a data acquisition response from the storage node, the data acquisition response may include M pieces of summary data in the N pieces of summary data, and may further include the N pieces of data.
  • step 620 M pieces of stored data respectively corresponding to the M pieces of summary data are acquired.
  • the operation of acquiring the M pieces of stored data may include: acquiring the M pieces of stored data from the data server node based on the address of the data server node and the storage location of the M pieces of stored data in the data server node. M pieces of storage data.
  • step 630 the respective digests of the M pieces of stored data are calculated.
  • step 640 in the case that the respective digests of the M pieces of summary data and the M pieces of stored data are respectively the same, it is determined that the complete data associated with the transaction data has not been tampered with.
  • FIG. 7 shows a blockchain-based data management method 700 according to an embodiment of the present disclosure.
  • the method 700 is used to obtain data from the blockchain and includes the following steps.
  • step 710 complete data for at least one sensor device is acquired.
  • the data uploaded by at least one sensor device further includes device identification and/or time information.
  • step 720 the complete data of the at least one sensor device is divided into P pieces of data, and complete summary data is generated based on the complete data of the at least one sensor device and/or P pieces of summary data are respectively generated based on the P pieces of data , and P is an integer greater than 1.
  • the complete data uploaded by a single sensor device can be regarded as a complete piece of data; multiple pieces of data uploaded by a single sensor device in each time period can be combined as a time combined complete data; or the data of each time period can be combined. Multiple initial complete data uploaded by multiple sensor devices are combined as one device combined complete data.
  • the operation of dividing the complete data of the at least one sensor device into P pieces of data may include: dividing the complete data, the time-combined complete data, or the device-combined complete data according to a preset ratio in sequence, or according to the time information.
  • the time combined complete data is divided by time; or the device combined complete data is divided in units of sensor devices based on device identification or time segments based on time information.
  • the P pieces of data and/or the complete data are stored in a data server node.
  • an information reporting request is sent to the data server node, and the information reporting request includes at least the complete data and/or the P pieces of data and the corresponding data of the device generating the P pieces of data.
  • the device identifier and/or the time information corresponding to the P pieces of data, and receive an information reporting response from the data server node, where the information reporting response at least includes the address of the data server node, the P pieces of data (that is, the P pieces of data). storage location of each piece of data in the data server node.
  • N pieces of summary data among the P pieces of summary data and/or the complete summary data of the complete data are included in the transaction data and sent to the verification node of the blockchain, where N is equal to P or P+1.
  • the verification node in the blockchain is the same as the respective digests of the M pieces of stored data corresponding to the M pieces of summary data calculated by the intermediate device in the N pieces of summary data calculated by the intermediate device, the transaction will be The data is generated into blocks and written into the blockchain, M is an integer less than N and greater than or equal to 1.
  • the M pieces of data are the complete data and M-1 pieces of divided data of the complete data; or, the M pieces of data are M pieces of divided data of the complete data.
  • the M pieces of summary data include summary data generated based on a piece of data with the shortest length among the P pieces of data.
  • M is equal to one.
  • the pieces of summary data are included together in the transaction data and sent to all or a portion of the validating nodes of the blockchain (eg, more than half, eg, 80% of the validating nodes).
  • a blockchain-based data management apparatus is also provided.
  • FIG. 8 shows a blockchain-based data management apparatus 800 according to an embodiment of the present disclosure, applied at a verification node.
  • the apparatus 800 may include a processor 801 and a memory 802 .
  • the processor 801 and the memory 802 may be connected by a bus 803 .
  • the processor 801 may perform various actions and processes according to instructions stored in the memory 802 .
  • the instructions in the memory when executed, may cause the processor to perform the steps of the blockchain-based data management method for a verification node described with reference to FIGS. 5A-5B in accordance with embodiments of the present disclosure.
  • the processor 801 may be an integrated circuit chip, which has signal processing capability.
  • the aforementioned processors may be general purpose processors, digital signal processors (DSPs), application specific integrated circuits (ASICs), off-the-shelf programmable gate arrays (FPGAs) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
  • the general-purpose processor may be a microprocessor or the processor may be any conventional processor, etc., and may be of an X87 architecture or an ARM architecture.
  • Memory 802 may be volatile memory or nonvolatile memory, or may include both volatile and nonvolatile memory.
  • the nonvolatile memory may be read only memory (ROM), programmable read only memory (PROM), erasable programmable read only memory (EPROM), electrically erasable programmable read only memory (EEPROM), or flash memory.
  • Volatile memory may be random access memory (RAM), which acts as an external cache.
  • RAM random access memory
  • SRAM static random access memory
  • DRAM dynamic random access memory
  • SDRAM synchronous dynamic random access memory
  • DDR SDRAM double data rate synchronous dynamic random access memory
  • ESDRAM enhanced synchronous dynamic random access memory
  • SLDRAM synchronous link dynamic random access memory
  • DR RAM direct memory bus random access memory
  • FIG. 9 shows a blockchain-based data management apparatus 900 according to an embodiment of the present disclosure, applied at a usage node.
  • the apparatus 900 may include a processor 901 and a memory 902 .
  • the processor 901 and the memory 902 may be connected by a bus 903 .
  • the processor 901, the memory 802, and the bus 903 may adopt a similar arrangement to that in FIG. 8, and when the instructions stored on the memory 902 are executed, cause the processor 901 to perform the functions described with reference to FIG. 6 in the embodiments of the present disclosure. Steps in a blockchain-based approach to data management using nodes.
  • FIG. 10 shows a blockchain-based data management apparatus 1000 according to an embodiment of the present disclosure, applied at a usage node.
  • the apparatus 1000 may include a processor 1001 and a memory 1002 .
  • the processor 1001 and the memory 1002 may be connected by a bus 1003 .
  • the processor 1001, the memory 1002, and the bus 1003 may adopt a similar arrangement to that in FIG. 8, and when the instructions stored on the memory 1002 are executed, cause the processor 1001 to perform the functions described with reference to FIG. 7 in the embodiments of the present disclosure. Steps of a blockchain-based data management method for an intermediary device.
  • the summary data generated based on the complete data is written into the blockchain, and the complete data (and its divided P pieces of data) are stored off-chain in the server, or more Further, the complete summary data of the complete data or the summary of a part of the data of the complete data is verified only by at least a part of the verification nodes, on the one hand, the requirements for the storage capacity of the servers of the relevant nodes on the blockchain are reduced, and the block chain is utilized.
  • the unmodifiable nature of the chain saves the complete data and ensures that the complete data is not modified, on the other hand, reduces the amount of calculation and computing resources, and reduces the processing speed requirements for the servers of the relevant nodes on the blockchain.
  • aspects of the present application may be illustrated and described in several patentable categories or situations, including any new and useful process, machine, product, or combination of matter, or any combination thereof New and useful improvements. Accordingly, various aspects of the present application may be performed entirely by hardware, entirely by software (including firmware, resident software, microcode, etc.), or by a combination of hardware and software.
  • the above hardware or software may be referred to as a "data block”, “module”, “engine”, “unit”, “component” or “system”.
  • aspects of the present application may be embodied as a computer product comprising computer readable program code embodied in one or more computer readable media.

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Computer Security & Cryptography (AREA)
  • Accounting & Taxation (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computing Systems (AREA)
  • General Business, Economics & Management (AREA)
  • Finance (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Strategic Management (AREA)
  • Physics & Mathematics (AREA)
  • Economics (AREA)
  • Development Economics (AREA)
  • Computer Hardware Design (AREA)
  • General Engineering & Computer Science (AREA)
  • Manufacturing & Machinery (AREA)
  • Radar, Positioning & Navigation (AREA)
  • Remote Sensing (AREA)
  • Technology Law (AREA)
  • Health & Medical Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Marketing (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

本公开的实施例提供了一种基于区块链的数据管理方法、装置和系统。一种基于区块链的数据管理方法,应用在验证节点,所述方法包括:获取交易数据,其中所述交易数据包括N条摘要数据,所述N条摘要数据分别基于与所述交易数据相关联的N条数据而生成,N为大于1的整数;从N条摘要数据中选择要用于验证的M条摘要数据,M为小于或等于N且大于或等于1的整数;获取分别与所述M条摘要数据对应的M条存储数据;计算所述M条存储数据各自的摘要,以及在所述M条摘要数据与所述M条存储数据各自的摘要分别相同的情况下,将所述交易数据写入区块链。

Description

基于区块链的数据管理方法、装置和系统
相关申请的交叉引用
本申请要求于2020年07月31日提交的中国专利申请第202010760397.X号的优先权。该中国专利申请的全文通过引用的方式结合于此以作为本申请的一部分。
技术领域
本申请涉及数据管理技术领域,更具体地,涉及一种基于区块链的数据管理方法、装置和系统。
背景技术
随着物联网的发展,越来越多的设备接入到物联网系统中。目前通用的物联网系统框架如图1所示,传感器等能力受限的物联网设备通过物联网网关接入到物联网平台,全功能物联网设备可以直接连接物联网平台或者通过物联网网关连接物联网平台。物联网平台集中管理各类设备,并且为上层的物联网应用提供接口。物联网应用通过物联网平台访问设备的数据,以及对设备进行控制。
以物联网的应用领域之一智能制造为例,大量的工业设备直接或者通过物联网网关连接到工业互联网平台上,实时上报数据以及接收平台发送的指令。制造业是典型的重资产型企业,需要购买大量的设备,对于企业的资金要求较高。
随着智能制造的发展,未来企业的发展模式也将发生改变,制造商不需要购买大量的设备,可以通过租赁设备的模式快速投入生产,按照设备的使用情况支付使用费。通过该租赁模式一方面降低企业的前期设备投资,可以快速投入生产,另一方面可以降低企业的设备维护成本。
这样,可以构建共享设备平台,平台可以将部分企业的富余铸造产能或生产线(生产设备)“线上共享”,有需求的企业选定后即可在线实现订单生产,从而解决部分铸造企业产能过剩、设备闲置,部分企业产能不足、订单积压的问题,对推动制造企业(制造商)加快资源优化与产业升级具有重 要意义。
发明内容
根据本公开的一方面,提供了一种基于区块链的数据管理方法,应用在验证节点,所述方法可以包括:获取交易数据,其中所述交易数据包括N条摘要数据,所述N条摘要数据分别基于与所述交易数据相关联的N条数据而生成,N为大于1的整数;从N条摘要数据中选择要用于验证的M条摘要数据,M为小于或等于N且大于或等于1的整数;获取分别与所述M条摘要数据对应的M条存储数据;计算所述M条存储数据各自的摘要,以及在所述M条摘要数据与所述M条存储数据各自的摘要分别相同的情况下,将所述交易数据写入区块链。
根据本公开的另一方面,还提供了一种基于区块链的数据管理方法,应用在多个验证节点,所述方法包括:获取交易数据,其中所述交易数据包括N条摘要数据,所述N条摘要数据分别基于与所述交易数据相关联的N条数据而生成条数据,N为大于1的整数;从N条摘要数据中选择要用于验证的M条摘要数据,M为小于或等于N且大于或等于1的整数;其中多个验证节点中的第一类验证节点验证的摘要数据包括基于生成所述M条摘要数据的M条数据中长度最短的一条数据而生成的摘要数据;获取分别与所述M条摘要数据对应的M条存储数据;计算所述M条存储数据各自的摘要,以及在所述M条摘要数据与所述M条存储数据各自的摘要分别相同的情况下,将所述交易数据写入区块链。
根据本公开的另一方面,还提供了一种基于区块链的数据管理方法,应用在使用节点,所述方法可以包括:获取被包括在与特定设备和/或时间段对应的交易数据中的N条摘要数据中的M条摘要数据,其中所述N条摘要数据分别基于与所述交易数据相关联的N条数据而生成,N为大于1的整数,M为小于或等于N且大于或等于1的整数;获取分别与所述M条摘要数据对应的M条存储数据;计算所述M条存储数据各自的摘要;以及在所述M条摘要数据与所述M条存储数据各自的摘要分别相同的情况下,确定与所述交易数据相关联的完整数据未被篡改。
根据本公开的另一方面,还提供了一种基于区块链的数据管理方法,应用在中间设备,所述方法可以包括:获取至少一个传感器设备的完整数据; 将所述至少一个传感器设备的完整数据分割为P条数据,并基于所述至少一个传感器设备的完整数据生成完整摘要数据和/或分别基于所述P条数据生成P条摘要数据,P为大于1的整数;将所述P条数据和/或所述完整数据存储在数据服务器节点中;以及将P条摘要数据和/或所述完整摘要数据中的N条摘要数据包括在交易数据中并向区块链的验证节点发送,N等于P或P+1;其中,所述区块链中的验证节点在由所述中间设备计算的所述N条摘要数据中的M条摘要数据与由所述验证节点计算的与所述M条摘要数据对应的M条存储数据各自的摘要相同时,将所述交易数据生成区块并写入所述区块链,M为小于N且大于或等于1的整数。
根据本公开的又一方面,还提供了一种基于区块链的数据管理装置,包括:处理器,和存储器,其上存储有指令,所述指令在被执行时使得所述处理器执行如上所述的方法。
根据本公开的又一方面,还提供了一种基于区块链的数据管理系统,包括:至少一个传感器设备,其被配置为生成完整数据;区块链网络,包括:25.一种基于区块链的数据管理系统,包括:至少一个传感器设备,其被配置为生成完整数据,还包括区块链网络,包括:数据服务器节点,其被配置为存储所述完整数据和/或由所述完整数据划分的P条数据;存储节点,其被配置为存储基于所述完整数据生成的完整摘要数据和/或基于由所述完整数据划分的P条数据中的至少一条数据生成的至少一条摘要数据;验证节点,其被配置为执行如上所述的在验证节点处执行的方法;使用节点,其被配置为执行如上所述的、在使用节点处执行的方法;和中间设备,其被配置为执行如上所述的在中间设备处执行的方法。
附图说明
为了解释本公开的原理,将结合附图结合来描述本公开的实施例。应理解,图中所示的要素可能被实现为各种形式的硬件、软件或它们的组合。可选地,在一个或多个适当地编程的通用计算机设备上的硬件和软件的组合中实现这些要素。
图1示出了一种物联网系统框架。
图2示出了智能制造应用中各主体之间的交互流程。
图3A-3B示出了根据本公开实施例的区块链网络。
图4A-4B示出了根据本公开实施例的基于区块链的数据管理系统的工作过程。
图5A示出了根据本公开实施例的应用于验证节点的、基于区块链的数据管理方法的流程图。
图5B示出了根据本公开实施例的应用于验证节点的、另一基于区块链的数据管理方法的流程图。
图6示出了根据本公开实施例的应用于使用节点的、基于区块链的数据管理方法的流程图。
图7示出了根据本公开实施例的应用于中间设备的、基于区块链的数据管理方法的流程图。
图8示出了根据本公开实施例的应用于验证节点的、基于区块链的数据管理装置的结构框图。
图9示出了根据本公开实施例的应用于使用节点的、基于区块链的数据管理装置的结构框图。
图10示出了根据本公开实施例的应用于中间设备的、基于区块链的数据管理装置的结构框图。
具体实施方式
以下将参照附图更充分地描述本公开实施例,在附图中示出了本公开实施例。然而,可以用很多不同形式来实施本公开,并且本公开不应理解为受限于在此所阐述的实施例。在全文中,使用相似的标号表示相似的元件。
在此所使用的术语仅用于描述特定实施例的目的,而并非意欲限制本公开。如在此所使用的那样,单数形式的“一个”、“这个”意欲同样包括复数形式,除非上下文清楚地另有所指。还应当理解,当在此使用时,术语“包括”指定出现所声明的特征、整体、步骤、操作、元件和/或组件,但并不排除出现或添加一个或多个其它特征、整体、步骤、操作、元件、组件和/或其群组。
除非另外定义,否则在此所使用的术语(包括技术术语和科学术语)具有与本公开所属领域的普通技术人员所共同理解的相同意义。在此所使用的术语应解释为具有与其在该说明书的上下文以及有关领域中的意义一致的意义,而不能以理想化的或过于正式的意义来解释,除非在此特意如此定义。 以下参照示出根据本公开实施例的方法、装置(系统)和/或计算机程序产品的框图和/或流程图描述本公开。应理解,可以通过计算机程序指令来实现框图和/或流程图示图的一个方框以及方框的组合。可以将这些计算机程序指令提供给通用计算设备、专用计算设备的处理器和/或其它可编程数据处理装置,使得经由计算设备处理器和/或其它可编程数据处理装置执行的指令创建用于实现框图和/或流程图块中所指定的功能/动作的方法。
相应地,还可以用硬件和/或软件(包括固件、驻留软件、微码等)来实施本公开。更进一步地,本公开可以采取计算机可使用或计算机可读存储介质上的计算机程序产品的形式,其具有在介质中实现的计算机可使用或计算机可读程序代码,以由指令执行系统来使用或结合指令执行系统而使用。在本公开上下文中,计算机可使用或计算机可读介质可以是任意介质,其可以包含、存储、通信、传输、或传送程序,以由指令执行系统、装置或设备使用,或结合指令执行系统、装置或设备使用。
如前文所述,设备共享的各方(例如设备提供商和制造商)之间存在合作关系,设备提供商根据设备的诸如使用率、使用量、使用时间等的因素的使用情况对使用其设备的制造商进行收费。为了准确计算设备的使用情况,设备提供商负责设备使用情况相关的数据收集,计算出设备的使用情况后向制造商收费。具体的交互流程如图2所示,设备提供商服务器获取设备上传的数据并计算设备使用情况,制造商服务器通过平台交互的方式获取设备使用情况并支付数据。
以智能制造为例,设备的非业务数据(包括使用情况数据)由设备提供商服务器收集并进行计算,制造商服务器根据设备提供商服务器的计算结果支付费用,如果设备提供商服务器存在数据修改的情况,则会导致费用的差别,并且制造商服务器不可知。另外制造商的其他供应链企业也有获取设备使用情况数据的需求,从而根据设备的使用情况可以及时备货。为了提升设备提供商和制造商、以及其他供应链企业之间的互信,需要提供一种新的机制,保证设备的数据准确、不可修改,从而建立合作方之间的互信。
区块链技术作为一种新兴的分布式数据存储技术,具有以下优势:
一是数据可信化。与传统分布式数据库有所不同,区块链引入了“人人记账”的理念,每个参与主体通过例如客户端应用等加入到区块链,并且都有权记账,大家各自可以保存最新账本和所有历史记录。这种数据高度冗余 的存储方式,可提升不互信主体之间的信息透明度,实现账本数据不可篡改和全程留痕,进而促进多方信息共享和协同操作。二是参与主体对等化。区块链的统一分布式账本技术,天然解决了“业务主权”问题,有效实现了每一个参与主体的身份对等、权力对等、责任对等、利益对等,并在所有参与主体之间实现数据的实时同步更新,使合作更加方便快捷,合作方的积极性得以提升。
即,区块链能够实现业务数据可信化以及参与主体对等化,能够促进多方信息共享和协同操作,并且能够在各个参与主体之间实现数据的实时同步更新,并保证数据准确、不可修改,从而建立合作方之间的互信。本文提及的参与主体可以是区块链网络中的网络节点,例如通过网络连接的服务器、计算机、电话等,针对不同性质的区块链,成为节点的方式也会有所不同。
然而,在目前基于区块链的数据管理方法中,在存储方面,区块链上的各个存储节点需要存储完整的历史交易信息,但是节点的存储量是有限的。并且,区块链中当任何一个参与主体要将新数据写入区块链时会涉及到验证过程,如何提高处理速度并且节省计算资源等也是一个亟待解决的问题。
基于此,本公开的实施例提供了一种基于区块链的数据管理方法、装置和系统,用于解决上述技术问题。数据管理包括针对数据的各种操作,包括存储数据以及获取数据等。
应注意,在本公开的一些实施例中,以将基于区块链的数据管理技术应用于智能制造行业为例进行了描述,但是,本领域技术人员将理解,可以将本公开实施例提供的基于区块链的数据管理技术应用于其他任何需要增加互信的数据共享场景,本公开对此不做限制。
首先介绍本公开的实施例所涉及的区块链网络。图3A-3B示出了根据本公开实施例的区块链网络。
如图3A所示,区块链网络是一种去中心化的网络,也可以被视为一个P2P网络(Peer-to-Peer)网络。区块链网络中不存在中心化的服务和层级结构,基于共识机制的每个节点都是对等的节点,各个节点共同提供网络服务。区块链网络中,根据各个节点所提供的功能不同,可以将节点分为不同的类型。例如,在EOS公有链中,21个节点作为验证节点,其余节点为普通节点。而在另外一些区块链中,每个节点都可以作为验证节点。验证节点可以每隔一段时间而通过竞争投票选出,有权限验证交易并添加区块到区块链上, 也可以视为超级节点、全节点中的至少一部分。此外,区块链网络中的普通节点并不会存储账本数据或者不会存储完整账本副本,只提供一般的算力支持。超级节点、全节点是拥有完整账本数据的节点,其需要占用内存同步所有的区块链数据,能够独立验证区块链上的所有交易并实时更新数据,主要负责区块链的交易的广播和验证。
此外,区块链中还可以包括存储被写入区块链的任何数据的存储节点(例如,该存储节点也可以选自能够存储位完整账本数据超级节点中的至少一部分),以及从区块链中获取数据的使用节点(该使用节点为普通节点)。
作为一种更具体的应用,在智能制造行业中可以采用如图3B所示数据管理系统来进行数据管理。
如前文所述,在智能制造行业中,设备的非业务数据(包括使用情况数据)由设备提供商服务器收集并进行计算,制造商服务器根据设备提供商服务器的计算结果支付费用,如果设备提供商服务器存在数据修改的情况,则会导致费用的差别,并且制造商服务器不可知。另外制造商的其他供应链企业也有获取设备使用情况数据的需求,从而根据设备的使用情况可以及时备货。因此,如图3B所示,智能制造行业中涉及的中间设备、设备提供商服务器、制造商服务器以及供应链企业服务器(未示出)等加入区块链,作为区块链节点,更具体地,作为普通节点,并且中间设备还与设备提供商服务器进行通信连接。中间设备可以为区块链网络与设备之间的工业网关,更通用的说法可以是边缘设备(EDGE),其数量可以为一个或多个,分布在各个设备附近,具备本地计算、存储和联网功能,能快速处理附近数据,而无需将数据返回数据中心和云服务商。此外,如果多个设备的计算处理能力足够,该多个设备可以不经过中间设备而直接接入到区块链中,作为区块链的节点,从而省略中间设备。本公开以使用中间设备的情况为例进行了说明,但是本公开不限于此。在该智能制造行业的应用场景中,设备提供商服务器可以被称为区块链网络中的数据服务器节点,制造商服务器以及供应链企业服务器(未示出)可以视为使用节点。
在图3B中,多个设备(例如传感器设备)连接到中间设备以向中间设备上报设备运营完整数据。中间设备通信连接到设备提供商服务器仍采用中心化的架构模式,即多个设备向各自附近的中间设备上报设备运营完整数据,(一个或多个)中间设备进一步向设备提供商服务器上报设备运营完整数据, 并且设备与中间设备之间以及中间设备与设备提供商服务器之间传送的是完整的设备运营完整数据。设备提供商服务器、制造商服务器以及供应链企业服务器(未示出)通过区块链以去中心化的架构而在相互之间进行信息传递。设备提供商服务器可以基于设备运营完整数据来计算得到设备的使用情况,并且设备提供商可以基于此向制造商收取费用。设备运营完整数据是与设备的使用情况相关联的数据。
此外,如果多个设备的处理能力足够,该多个设备可以不经过中间设备而直接接入到区块链中。
如前文所述,需要在设备提供商、制造商、以及其他供应链企业之间基于区块链而共享数据,但是由于设备运营完整数据的数据量十分庞大,如果要全部写入区块链以实现共享,将对区块链网络的节点处的存储容量有很高的要求。
此外,区块链中的验证节点有多个,并且对于某些类型的区块链,验证节点数量比较多。如果全部验证节点都用于对要写入的数据进行验证和/或对完整数据进行验证,将会降低区块链整体的处理速度并增大计算量。
基于此,本公开的实施例提供了一种基于区块链的数据管理方法、装置以及系统。在本公开的实施例中,将基于完整数据生成的摘要数据写入区块链中,且将完整数据存储在服务器中,或者更进一步,仅通过至少一部分验证节点对完整数据的完整摘要数据或由完整数据分割的部分分割数据生成的摘要数据进行验证。基于此,一方面降低了对于区块链上的相关节点的服务器的存储容量的要求,且利用区块链的不可修改特性以保存完整数据并确保完整数据未被修改,另一方面提高了验证的准确性并同时减少了计算量和计算资源,且降低了对于区块链的相关节点的服务器的处理速度的要求。
以下结合图4来描述根据本公开的实施例的基于区块链的数据管理系统以及工作过程。如图4所示,该数据管理系统包括:至少一个传感器设备(以下简称为设备),其被配置为生成完整数据;区块链网络,包括:数据服务器节点,其被配置为存储数据;存储节点,其被配置为在链上存储摘要数据;验证节点;使用节点;和中间设备(如前面所述,在设备计算处理能力足够的情况下,可以将设备直接接入区块链而省略该中间设备)。此外,区块链网络还可以包括任意数量的其他类型的节点。此外,在另外的一些实施例中,数据服务器(例如设备提供商服务器)可以不作为节点包括在区块链网络中, 区块链网络中的各个节点可以与该数据服务器进行通信而获取其中存储的数据。
以智能制造的具体应用场景为例,数据服务器节点可以为设备提供商服务器节点,使用节点可以为制造商数据服务器节点以及供应链企业数据服务器节点,均为普通节点。验证节点和存储节点可以选自区块链网络中的一部分超级节点,且可以重合(仅这部分节点链上存储了完整账本数据,包括已经过验证的、写入区块链的所有交易数据)。
首先,各个节点加入区块链网络(未示出)。例如如前面所述的中间设备、设备提供商服务器、制造商服务器、以及供应链企业服务器加入区块链网络,作为普通节点,其中该区块链网络中还包括存储节点、验证节点(存储节点和验证节点均选自超级节点中的至少一部分)。设备向中间设备发送注册请求,以便设备能向中间设备上传数据,并且中间设备向数据服务器节点发送注册请求,以便中间设备能向数据服务器节点上传数据。在设备生成数据之后,设备向中间设备发送第一信息上报请求,而该第一信息上报请求里可以包括设备运营完整数据(以下可简称完整数据),并且还可以包括设备标识(ID)和/或时间信息。可选地,设备标识(ID)和/或时间信息与所产生的完整数据相关联,用于指示生成该完整数据的设备的标识以及时间。
在一些实施例中,设备按照预定间隔向中间设备发送第一信息上报请求。可以将单个设备上报的数据作为一条完整数据,在这种情况下,上述第一信息上报请求中包括设备标识。或者,可以将每个时间段的单个设备上报的多条数据作为一条时间组合完整数据,在这种情况下,上述第一信息上报请求中包括设备标识,并可选地包括时间信息,这取决于后续的分割完整数据的方式。此外,也可以将每个时间段的多个设备上报的多条数据作为一条设备组合完整数据(例如将下午2点至5点时间段、下午8点到11点时间段的所有设备的初始完整数据进行组合能得到两条设备组合完整数据),在这种情况下,上述第一信息上报请求中包括时间信息,并可选地包括多个设备的每个设备的设备标识,这取决于后续的分割完整数据的方式。除了第一信息上报请求之外,后文详细描述的第二信息上报请求、交易创建请求中基于类似的限定而选择性地携带设备标识和/或时间信息。
中间设备从第一信息上报请求提取完整数据以及设备标识和/或时间信息之后,进行以下操作:将该完整数据分割为P条数据(即P条分割数据), 并基于该完整数据生成完整摘要数据和/或分别基于所述P条数据生成P条摘要数据,P为大于1的整数;将完整数据和/或P条数据存储在数据服务器节点中,其中,在需要将P条数据存储在数据服务器节点中的情况下,P条数据可以以一条完整数据的形式而被存储,或者可以以分离的形式而作为多条存储数据(2至P条存储数据)存储,并且在将P条数据以一条完整数据的形式或者少于P的数量的存储数据的形式存储时,中间设备在向数据服务器节点发送P条数据时,还向该数据服务器节点发送P条数据的分割信息,以使得在数据服务器节点处能对存储数据进行相同分割而得到相同的P条数据(该完整数据和/或P条数据可能会在数据服务器节点处被篡改,但是完整摘要数据和/或P条摘要数据是基于未被篡改的数据而生成的),然后将P条摘要数据和/或所述完整数据的完整摘要数据中的N条摘要数据包括在交易数据中并向区块链的验证节点发送,N等于P或P+1。
更具体地,将完整数据和/或P条数据存储在数据服务器节点中的操作包括:向数据服务器节点发送第二信息上报请求;该第二信息上报请求中包括完整数据、P条数据以及产生该完整数据的设备对应的设备标识和/或该完整数据对应的时间信息;从数据服务器节点接收信息上报响应,该信息上报响应至少包括数据服务器节点的地址、P条数据中的每条数据在该数据服务器节点中的存储位置。此外,将N条摘要数据包括在交易数据中并向区块链的验证节点发送的操作包括:向区块链网络中的验证节点发送(例如,将交易相关的数据打包成区块并通过广播的方式)交易创建请求,该交易创建请求中携带交易数据,该交易数据中包括该完整数据的完整摘要数据和/或P条摘要数据中的N条摘要数据(即N条摘要数据被包括在交易数据中,且N等于P或P+1,并且基于其生成N条摘要数据的完整数据和/或P条数据中的至少一部分数据也被表达为N条数据),并且该交易数据中还可以包括N条数据的位置信息(存储该N条数据的数据服务器节点的位置信息以及该N条数据中的每条数据在所述数据服务器节点中的位置信息)、该N条数据对应的设备标识,和/或该N条数据对应的时间信息。
在一些实施例中,中间设备可以按照按顺序的预设比例来对完整数据进行分割。例如,可以按照20%,20%,20%,20%和20%的顺序或者按照40%,25%,20%,10%和5%的顺序将完整数据分割为5份分割数据,并且可以将该按顺序的预设比例的相关信息与交易数据一起被携带于交易创建请求中而 通知(例如通过广播)到区块链中的各个节点。
在一些实施例中,中间设备可以针对每个设备的一条时间组合完整数据(如前面所述)按照上述按顺序的预设比例进行分割(即按数据量),或者也可以基于时间信息按照时间来进行分割。此外,设备运营完整数据可以是每个时间段的多个设备的一条设备组合完整数据,因此也可以按照上述按顺序的预设比例进行分割(即按数据量)进行分割,基于设备标识来按照设备进行分割,或者基于时间信息按照时间段来进行分割。
在一些实施例中,生成数据的摘要的方式可以包括哈希运算,即可以包括对数据进行哈希运算得到哈希值,并将该哈希值作为该数据的摘要,使得只要数据有微小的改变,其对应的哈希值就会完全不同,因此该数据的摘要就会完全不同。显然,其他生成数据的摘要的方法也是可行的,只要摘要数据能够随着数据的微小改变而显著改变。此外,为了增强安全性,在生成数据的摘要的过程中还可以引入加密过程,这可以采用现有的加密技术,因此此处不再详细描述。
表一给出了在一条完整数据被分割为2份数据的情况下与中间设备相关的数据处理过程的示意性描述,主要包括将接收到的完整数据分割为第一数据和第二数据,生成完整数据的完整摘要数据以及与第一数据相对应的第一摘要数据、与第二数据相对应的第二摘要数据,并向区块链网络中发送包括完整数据的完整摘要数据、第一摘要数据、以及第二摘要数据中的至少一部分的交易数据(如下面情况一-情况四所示)。此外,完整数据和/或所分割的第一数据和第二数据也被发送到数据服务器节点中,并且如前文所述,完整数据、第一数据和第二数据在数据服务器节点处可能会被篡改,从而可能与先前作为中间设备处的计算基础的所述完整数据、第一数据和第二数据不再相同。
Figure PCTCN2021108427-appb-000001
Figure PCTCN2021108427-appb-000002
验证节点在从交易创建请求中提取出交易数据之后,从交易数据包括的N条摘要数据当中选择要用于验证的M条摘要数据,M为小于N且大于或等于1的整数(例如,基于从中间设备接收的按顺序的预设比例的分割信息,例如选择第4条和第5条分割数据对应的2条摘要数据),其中,如前面所述,中间设备基于完整数据和由完整数据分割得到的P条数据生成多条摘要数据,并将该多条摘要数据当中的N条摘要数据包括在交易数据中被验证节点所接收,而基于其生成该N条摘要数据的N条数据被表达为与所述交易数据相关联。验证节点然后获取分别与所述M条摘要数据对应的M条存储数据;计算所述M条存储数据各自的摘要,以及在M条摘要数据中的每一条与M条存储数据各自的摘要分别相同的情况下,将所述交易数据写入区块链。更具体地,基于生成M条摘要数据的M条数据的位置信息,向数据服务器节点发送数据获取请求,数据获取请求中包括该位置信息,从存储了与M条摘要数据相对应的M条存储数据(M条存储数据的位置与M条数据的位置相同,且如果数据未被篡改,M条存储数据与M条数据是相同的,因此在本文中,M/P条存储数据有时可以与M/P条数据互换)的数据服务器节点获取M条存储数据,并且按照与中间设备相同的方式计算这M条存储数据的摘要,在M条摘要数据中的每一条与M条存储数据各自的摘要分别相同的情况下,则确定验证通过,并将所述交易数据写入区块链。
在一些实施例中,N条数据为1条完整数据和该完整数据的N-1条分割数据,且基于其而生成M条摘要数据的M条数据为1条完整数据和完整数据的M-1条分割数据,或M条数据为完整数据的M条分割数据;或者N条数据为1条完整数据的N条分割数据,且M条数据为完整数据的M条分割数据。
当M条数据为包括完整数据的M条分割数据时或M-1条分割数据,验证节点只需要获取分割数据,不需要获取完整数据,验证节点获取的数据体积较少,从而减少了验证节点和数据服务器之间的网络带宽,同时也降低了验证节点和数据服务器的工作负荷和计算量。
此外,如前面描述的,中间设备从完整数据分割的P条数据的长度可以不相等。因此,为了进一步减小计算量以及节省计算资源,可以将N条摘要数据当中最短的一条摘要数据作为M条摘要数据用于验证。验证过程与前面描述的将M条摘要数据用于验证的过程类似,这里不再详细描述。
验证节点通常包括多个,当大部分验证节点验证通过时交易内容被接收,例如柚子区块链系统中规定2/3验证节点验证通过则交易内容写入区块链。对于比特币区块链网络,由于所有全功能节点均可以参与验证,但是由于全功能节点的范围分布较广,无法在短时间内达成全网验证节点验证通过,因此只要一定比例的验证节点通过验证即可。验证节点验证通过的比例由区块链系统设置,管理员可以设置该比例以调整验证通过的速度。
因此,在另一实施例中,还可以采用如下方式来进行验证。
首先,多个验证节点均获取交易数据,其中所述交易数据包括N条摘要数据,所述N条摘要数据分别基于与所述交易数据相关联的N条数据而生成,N为大于1的整数。该过程与先前描述的过程类似,这里不再详细描述。可选地,多个验证节点可以包括第一类验证节点和第二类验证节点。
然后,多个验证节点从N条摘要数据中选择要用于验证的M条摘要数据,M为小于或等于N且大于或等于1的整数,其中多个验证节点中的第一类验证节点验证的摘要数据包括基于生成所述M条摘要数据的M条数据中长度最短的一条数据而生成的摘要数据。例如,从N条摘要数据中选择了两条摘要数据用于验证,其中这两条摘要数据基于两条数据而生成,第一类验证节点验证基于该两条数据中较短的一条数据而生成的摘要数据。
接着,多个验证节点获取分别与所述M条摘要数据对应的M条存储数据,然后计算所述M条存储数据各自的摘要,并且在所述M条摘要数据与所述M条存储数据各自的摘要分别相同的情况下,将所述交易数据写入区块链。
上述获取存储数据、计算存储数据的摘要的方式与先前描述的类似,这里也不再详细描述。
此外,M条数据可以包括1条完整数据和所述完整数据的M-1条分割数据,因此多个节点中的第二类验证节点验证基于所述完整数据生成的摘要数据。或者,M条数据包括1条完整数据的M条分割数据,多个节点中的第二类验证节点验证所述第一类验证节点未验证的摘要数据。
可选地,第一类验证节点的数量大于第二类验证节点的数量。
也就是说,可以仅使用一部分验证节点对由完整数据的分割数据生成的摘要数据进行验证,另外一部分验证节点对完整摘要数据进行验证,并且前者的数量更大。例如使用80%的验证节点来进行分割数据生成的摘要数据的验证,20%的验证节点来进行完整摘要数据的验证。例如,使用80%的验证节点来进行最短的分割数据生成的摘要数据的验证,而20%的验证节点来进行剩余M-1条摘要数据的验证。
这样,不必所有验证节点都验证完整数据,但是仍能保证验证完需要被验证的所有M条摘要数据,从而提高验证的准确性,同时也可以减少计算量以及节省计算资源并提高处理速度。
在使用节点希望从区块链获取交易数据,并确定设备的完整数据是否被篡改的情况下,在使用节点处可以进行如下操作。
在存储节点为区块链网络中的一部分超级节点,在该超级节点处存储了完整账本数据,即所有交易数据,并且使用节点没有存储完整账本数据从而不具有其期望获取的交易数据或者没有存储任何账本数据的情况下,使用节点需要从存储节点(超级节点)获取交易数据来进一步检查设备的完整数据是否被篡改。图4B中示出了对应的示意流程图。
数据获取的过程可以包括:获取被包括在与特定设备和/或时间段对应的交易数据中的N条摘要数据中的M条摘要数据,其中N条摘要数据分别基于与交易数据相关联的N条数据而生成,N为大于1的整数,M为小于或等于N且大于或等于1的整数;获取分别与M条摘要数据对应的M条存储数据;计算M条存储数据各自的摘要;以及在M条摘要数据与M条存储数据各自的摘要分别相同的情况下,确定与交易数据相关联的完整数据未被篡改,并可选地从区块链中的存储节点获取交易数据,并从存储与交易数据相关联的N条数据的数据服务器节点获取与交易数据相关联的N条数据。该特定设备和/或时间段是期望获取其数据的设备和/或时间段。
更具体地,如图4B中所示,由使用节点向区块链中的存储节点(例如, 超级节点)发送摘要数据获取请求,该摘要数据获取请求至少包括与该特定设备和/或时间段对应的设备标识和/或时间信息,并且从所述存储节点接收摘要数据获取响应,所述摘要数据获取响应至少包括所述N条摘要数据中的M条摘要数据。如前面所述的,存储节点中存储的每条交易数据除了包括N条摘要数据之外,还可以包括生成N条摘要数据的N条数据的位置信息(存储该N条数据的数据服务器节点的位置信息以及该N条数据中的每条数据在所述数据服务器节点中的位置信息)、该N条数据对应的设备标识,和/或该N条数据对应的时间信息。
此外,该摘要数据获取响应还包括存储该N条数据的数据服务器节点的地址、所述M条存储数据在所述数据服务器节点中的存储位置,因此使用节点基于数据获取响应中包括的上述信息,来从所述数据服务器节点获取所述M条存储数据。然后,计算所述M条存储数据各自的摘要,并且在所述M条摘要数据与所述M条存储数据各自的摘要分别相同的情况下,可以确定与交易数据相关联的完整数据未被篡改。
与前面类似的,N条数据为1条完整数据和完整数据的N-1条分割数据,且基于其生成M条摘要数据的M条数据为1条完整数据和完整数据的M-1条分割数据,或M条数据为完整数据的M条分割数据;或者N条数据为1条完整数据的N条分割数据,且M条数据为完整数据的M条分割数据。
当M条数据为包括所述完整数据的M条分割数据或M-1条分割数据,使用节点只需要获取分割数据,不需要获取完整数据,使用节点获取的数据体积较少,从而减少了使用节点和数据服务器之间的网络带宽,同时也降低了使用节点和数据服务器的工作负荷和计算量。
在上述基于区块链的数据管理系统中,通过将基于完整数据生成的摘要数据写入区块链中,且将完整数据(及其分割的P条数据)链下存储在服务器中,或者更进一步,仅通过至少一部分验证节点对完整数据的完整摘要数据或完整数据的一部分数据的摘要进行验证,一方面降低了对于区块链上的相关节点的存储容量的要求,且利用区块链的不可修改特性以保存完整数据并确保完整数据未被修改,另一方面增加了验证的准确性,同时减少了计算量和计算资源,且降低了对于区块链上的相关节点的处理速度的要求。
根据本公开的另一方面,提供了一种基于区块链的数据管理方法,应用在验证节点。图5A-5B示出了根据本公开实施例的基于区块链的数据管理方 法500A和500B。该方法500A和500B用于验证要写入区块链的数据,可以在验证节点中的至少一部分验证节点处执行,并包括以下步骤。
在方法500A中,在步骤510,获取交易数据,获取交易数据,其中所述交易数据包括N条摘要数据,所述N条摘要数据分别基于与所述交易数据相关联的N条数据而生成,N为大于1的整数。
可选地,所述N条数据为1条完整数据和该完整数据的N-1条分割数据,或者所述N条数据为完整数据的N条分割数据。
可选地,在上述智能制造的具体应用中,该N条数据可以通过将设备上传的数据作为完整数据进行分割而得到。
在步骤520,从N条摘要数据中选择要用于验证的M条摘要数据,M为小于或等于N且大于或等于1的整数。
在步骤530,获取分别与所述M条摘要数据对应的M条存储数据。
可选地,M条数据为1条完整数据和完整数据的M-1条分割数据,或者,M条数据为完整数据的M条分割数据。
可选地,所述N条数据中至少两条数据的长度不同,所述M条摘要数据包括基于所述N条数据中长度最短的一条数据生成的摘要数据。或者,更进一步,M=1。
可选地,交易数据还包括N条数据的位置信息,其中,可以根据M条存储数据的位置信息分别获取M条数据。
可选地,交易数据还包括N条数据对应的设备标识,和/或N条数据对应的时间信息,并且其中,N条数据的位置信息包括:存储N条数据的数据服务器节点的位置信息以及N条数据中的每条数据在数据服务器节点中的位置信息。
在步骤540,计算M条存储数据各自的摘要。
在步骤550,在M条摘要数据与M条存储数据各自的摘要相同的情况下,将交易数据写入区块链。
可选地,在所有验证节点或者一部分验证节点(例如超过半数,例如80%)处均确定M条摘要数据与N条数据当中用于验证的M条数据的摘要相同的情况下,将交易数据写入区块链。
此外,多个验证节点在对要写入区块链的数据进行验证时,所采用的操作如方法500B的各个步骤所述。
在步骤5100,获取交易数据,其中所述交易数据包括N条摘要数据,所述N条摘要数据分别基于与所述交易数据相关联的N条数据而生成,N为大于1的整数。
在步骤5200,从N条摘要数据中选择要用于验证的M条摘要数据,M为小于或等于N且大于或等于1的整数;其中多个验证节点中的第一类验证节点验证的摘要数据包括基于生成所述M条摘要数据的M条数据中长度最短的一条数据而生成的摘要数据。
可选地,所述M条数据包括1条完整数据和所述完整数据的M-1条分割数据,所述多个节点中的第二类验证节点验证基于所述完整数据生成的摘要数据。或者,所述M条数据包括1条完整数据的M条分割数据,所述多个节点中的第二类验证节点验证所述第一类验证节点未验证的摘要数据。
可选地,所述第一类验证节点数量大于所述第二类验证节点数量。
在步骤5300,获取分别与所述M条摘要数据对应的M条存储数据。
在步骤5400,计算所述M条存储数据各自的摘要。
在步骤5500,在所述M条摘要数据与所述M条存储数据各自的摘要分别相同的情况下,将所述交易数据写入区块链。在方法500B中,获取摘要数据、获取存储数据以及计算摘要的各个步骤与前面描述的内容类似,因此这里不再详细描述。
根据本公开的另一方面,提供了一种基于区块链的数据管理方法,应用在使用节点。图6示出了根据本公开实施例的一种基于区块链的数据管理方法600。该方法600用于从区块链获取数据,并包括以下步骤。
在步骤S610,获取被包括在与特定设备和/或时间段对应的交易数据中的N条摘要数据中的M条摘要数据,其中所述N条摘要数据分别基于与所述交易数据相关联的N条数据而生成,N为大于1的整数,M为小于或等于N且大于或等于1的整数。
可选地,所述N条数据为1条完整数据和该完整数据的N-1条分割数据,或者所述N条数据为完整数据的N条分割数据。M条数据为1条完整数据和完整数据的M-1条分割数据,或者,M条数据为完整数据的M条分割数据。
可选地,所述N条数据中至少两条数据的长度不同,所述M条摘要数据包括基于所述N条数据中长度最短的一条数据生成的摘要数据。或者,更进 一步,M=1。
可选地,获取M条摘要数据的操作可以包括:由使用节点向区块链中的存储节点发送摘要数据获取请求,所述摘要数据获取请求至少包括与所述特定设备和/或时间段对应的设备标识和/或时间信息,从所述存储节点接收数据获取响应,所述数据获取响应可以包括所述N条摘要数据中的M条摘要数据,还可以进一步包括存储N条数据的所述数据服务器节点的地址、所述M条存储数据在所述数据服务器节点中的存储位置。
在步骤620,获取分别与所述M条摘要数据对应的M条存储数据。
可选地,获取M条存储数据的操作可以包括:基于所述数据服务器节点的地址、所述M条存储数据在所述数据服务器节点中的存储位置,来从所述数据服务器节点获取所述M条存储数据。
在步骤630,计算所述M条存储数据各自的摘要。
在步骤640,在所述M条摘要数据与所述M条存储数据各自的摘要分别相同的情况下,确定与交易数据相关联的完整数据未被篡改。
根据本公开的另一方面,提供了一种基于区块链的数据管理方法,应用在使用节点。图7示出了根据本公开实施例的一种基于区块链的数据管理方法700。该方法700用于从区块链获取数据,并包括以下步骤。
在步骤710,获取至少一个传感器设备的完整数据。
可选地,至少一个传感器设备上传的数据除了所述完整数据之外,还包括设备标识,和/或时间信息。
在步骤720,将所述至少一个传感器设备的完整数据分割为P条数据,并基于所述至少一个传感器设备的完整数据生成完整摘要数据和/或分别基于所述P条数据生成P条摘要数据,P为大于1的整数。
可选地,可以将单个传感器设备上传的完整数据作为一条完整数据;可以将每个时间段的单个传感器设备上传的多条数据进行组合作为一条时间组合完整数据;或者可以将每个时间段的多个传感器设备上传的多条初始完整数据进行组合作为一条设备组合完整数据。
可选地,将至少一个传感器设备的完整数据分割为P条数据的操作可以包括:将完整数据、时间组合完整数据或设备组合完整数据按照按顺序的预设比例进行分割,或者基于时间信息按照时间来对时间组合完整数据进行分割;或者基于设备标识以传感器设备为单位或基于时间信息以时间段为单位 来对设备组合完整数据进行分割。
在步骤730,将所述P条数据和/或所述完整数据存储在数据服务器节点中。
可选地,在步骤S730中,向所述数据服务器节点发送信息上报请求,所述信息上报请求至少包括所述完整数据和/或所述P条数据以及产生所述P条数据的设备对应的设备标识和/或所述P条数据对应的时间信息,并且从所述数据服务器节点接收信息上报响应,所述信息上报响应至少包括所述数据服务器节点的地址、P条数据(也即P条存储数据)中的每条数据在所述数据服务器节点中的存储位置。
在步骤740,将P条摘要数据和/或完整数据的完整摘要数据中的N条摘要数据包括在交易数据中并向区块链的验证节点发送,N等于P或P+1。其中,区块链中的验证节点在由中间设备计算的N条摘要数据中的M条摘要数据与由验证节点计算的与M条摘要数据对应的M条存储数据各自的摘要相同时,将交易数据生成区块并写入区块链,M为小于N且大于或等于1的整数。
可选地,所述M条数据为所述完整数据和所述完整数据的M-1条分割数据;或,所述M条数据为所述完整数据的M条分割数据。
可选地,所述P条数据中至少两条数据的长度不同,所述M条摘要数据包括基于所述P条数据中长度最短的一条数据生成的摘要数据。可选地,M等于1。
可选地,将所述P条存储数据的位置信息、所述P条数据对应的设备标识,和/或所述P条数据对应的时间信息连同所述完整数据的摘要和/或所述N条摘要数据一起包括在交易数据中并向区块链的所有验证节点或一部分验证节点(例如,超过半数,例如80%的验证节点)发送。
在上述基于区块链的数据管理方法中,通过将基于完整数据生成的摘要数据写入区块链中,且将完整数据(及其分割的P条数据)存储在服务器中,或者更进一步,仅通过至少一部分验证节点对完整数据的完整摘要数据或完整数据的一部分数据的摘要进行验证,一方面降低了对于区块链上的相关节点的服务器的存储容量的要求,且利用区块链的不可修改特性以保存完整数据并确保完整数据未被修改,另一方面提高了验证准确性并同时减少了计算量和计算资源,且降低了对于区块链上的相关节点的服务器的处理速度的要 求。
根据本公开的又一方面,还提供了基于区块链的数据管理装置。
图8示出了根据本公开实施例的基于区块链的数据管理装置800,应用于验证节点处。该装置800可以包括处理器801和存储器802。处理器801和存储器802可以通过总线803相连。
处理器801可以根据存储在存储器802中的指令执行各种动作和处理。在存储器中的指令被执行时,可以使得处理器执行根据本公开的实施例中的参考图5A-5B所描述的用于验证节点的、基于区块链的数据管理方法的各步骤。
具体地,处理器801可以是一种集成电路芯片,具有信号的处理能力。上述处理器可以是通用处理器、数字信号处理器(DSP)、专用集成电路(ASIC)、现成可编程门阵列(FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等,可以是X87架构或ARM架构的。
存储器802可以是易失性存储器或非易失性存储器,或可包括易失性和非易失性存储器两者。非易失性存储器可以是只读存储器(ROM)、可编程只读存储器(PROM)、可擦除可编程只读存储器(EPROM)、电可擦除可编程只读存储器(EEPROM)或闪存。易失性存储器可以是随机存储存储器(RAM),其用作外部高速缓存。通过示例性但不是限制性说明,许多形式的RAM可用,例如静态随机存储存储器(SRAM)、动态随机存储存储器(DRAM)、同步动态随机存储存储器(SDRAM)、双倍数据速率同步动态随机存储存储器DDRSDRAM)、增强型同步动态随机存储存储器(ESDRAM)、同步连接动态随机存储存储器(SLDRAM)和直接内存总线随机存储存储器(DR RAM)。应注意,本公开描述的方法的存储器旨在包括但不限于这些和任意其它适合类型的存储器。
图9示出了根据本公开实施例的基于区块链的数据管理装置900,应用于使用节点处。该装置900可以包括处理器901和存储器902。处理器901和存储器902可以通过总线903相连。
处理器901、存储器802以及总线903可以采用与图8中的类似的布置,当存储器902上存储的指令被执行时,使得处理器901执行本公开的实施例中的参考图6所描述的用于使用节点的、基于区块链的数据管理方法的各步 骤。
图10示出了根据本公开实施例的基于区块链的数据管理装置1000,应用于使用节点处。该装置1000可以包括处理器1001和存储器1002。处理器1001和存储器1002可以通过总线1003相连。
处理器1001、存储器1002以及总线1003可以采用与图8中的类似的布置,当存储器1002上存储的指令被执行时,使得处理器1001执行本公开的实施例中的参考图7所描述的用于中间设备的、基于区块链的数据管理方法的各步骤。
在上述基于区块链的数据管理装置中,通过将基于完整数据生成的摘要数据写入区块链中,且将完整数据(及其分割的P条数据)链下存储在服务器中,或者更进一步,仅通过至少一部分验证节点对完整数据的完整摘要数据或完整数据的一部分数据的摘要进行验证,一方面降低了对于区块链上的相关节点的服务器的存储容量的要求,且利用区块链的不可修改特性以保存完整数据并确保完整数据未被修改,另一方面减少了计算量和计算资源,且降低了对于区块链上的相关节点的服务器的处理速度的要求。
虽然已经针对本公开的各种具体示例实施例详细描述了本公开,但是每个示例通过解释而不是限制本公开来提供。本领域技术人员在得到对上述内容的理解后,可以容易地做出这样的实施例的变更、变化和等同物。因此,本发明并不排除包括将对本领域普通技术人员显而易见的对本公开的这样的修改、变化和/或添加。例如,作为一个实施例的一部分图示或描述的特征可以与另一实施例一起使用,以产生又一实施例。因此,意图是本公开覆盖这样的变更、变化和等同物。
具体地,尽管本公开的附图出于图示和讨论的目的分别描述了以特定顺序执行的步骤,但是本公开的方法不限于特定图示的顺序或布置。在不偏离本公开的范围的情况下,上述方法的各个步骤可以以各种方式省略、重新布置、组合和/或调整。
本领域技术人员可以理解,本申请的各方面可以通过若干具有可专利性的种类或情况进行说明和描述,包括任何新的和有用的工序、机器、产品或物质的组合,或对他们的任何新的和有用的改进。相应地,本申请的各个方面可以完全由硬件执行、可以完全由软件(包括固件、常驻软件、微码等)执行、也可以由硬件和软件组合执行。以上硬件或软件均可被称为“数据块”、 “模块”、“引擎”、“单元”、“组件”或“系统”。此外,本申请的各方面可能表现为位于一个或多个计算机可读介质中的计算机产品,该产品包括计算机可读程序编码。
除非另有定义,这里使用的所有术语(包括技术和科学术语)具有与本公开所属领域的普通技术人员共同理解的相同含义。还应当理解,诸如在通常字典里定义的那些术语应当被解释为具有与它们在相关技术的上下文中的含义相一致的含义,而不应用理想化或极度形式化的意义来解释,除非这里明确地这样定义。
以上是对本公开的说明,而不应被认为是对其的限制。尽管描述了本公开的若干示例性实施例,但本领域技术人员将容易地理解,在不背离本公开的新颖教学和优点的前提下可以对示例性实施例进行许多修改。因此,所有这些修改都意图包含在权利要求书所限定的本公开范围内。应当理解,上面是对本公开的说明,而不应被认为是限于所公开的特定实施例,并且对所公开的实施例以及其他实施例的修改意图包含在所附权利要求书的范围内。本公开由权利要求书及其等效物限定。

Claims (25)

  1. 一种基于区块链的数据管理方法,应用在验证节点,所述方法包括:
    获取交易数据,其中所述交易数据包括N条摘要数据,所述N条摘要数据分别基于与所述交易数据相关联的N条数据而生成,N为大于1的整数;
    从N条摘要数据中选择要用于验证的M条摘要数据,M为小于或等于N且大于或等于1的整数;
    获取分别与所述M条摘要数据对应的M条存储数据;
    计算所述M条存储数据各自的摘要,以及
    在所述M条摘要数据与所述M条存储数据各自的摘要分别相同的情况下,将所述交易数据写入区块链。
  2. 根据权利要求1所述的方法,其中,
    所述N条数据为1条完整数据和所述完整数据的N-1条分割数据,且基于其生成所述M条摘要数据的M条数据为1条完整数据和所述完整数据的M-1条分割数据,或所述M条数据为所述完整数据的M条分割数据;或者所述N条数据为1条完整数据的N条分割数据,且所述M条数据为完整数据的M条分割数据。
  3. 根据权利要求1所述的方法,其中所述交易数据还包括所述N条数据的位置信息,其中,所述获取与所述M条摘要数据对应的M条存储数据包括:
    根据基于其生成所述M条摘要数据的M条数据的位置信息分别获取所述M条存储数据。
  4. 根据权利要求1所述的方法,其中,所述交易数据还包括所述N条数据对应的设备标识,和/或所述N条数据对应的时间信息。
  5. 根据权利要求3所述的方法,其中,所述N条数据的位置信息包括:
    存储N条数据的数据服务器节点的位置信息以及所述N条数据中的每条数据在所述数据服务器节点中的位置信息。
  6. 根据权利要求1所述的方法,其中,
    所述N条数据中至少两条数据的长度不同,所述M条摘要数据包括基于所述N条数据中长度最短的一条数据生成的摘要数据。
  7. 根据权利要求6所述的方法,其中,M=1。
  8. 一种基于区块链的数据管理方法,应用在多个验证节点,所述方法包括:
    获取交易数据,其中所述交易数据包括N条摘要数据,所述N条摘要数据分别基于与所述交易数据相关联的N条数据而生成,N为大于1的整数;
    从N条摘要数据中选择要用于验证的M条摘要数据,M为小于或等于N且大于或等于1的整数;其中多个验证节点中的第一类验证节点验证的摘要数据包括基于生成所述M条摘要数据的M条数据中长度最短的一条数据而生成的摘要数据;
    获取分别与所述M条摘要数据对应的M条存储数据;
    计算所述M条存储数据各自的摘要,以及
    在所述M条摘要数据与所述M条存储数据各自的摘要分别相同的情况下,将所述交易数据写入区块链。
  9. 如权利要求8所述的数据管理方法,其中所述M条数据包括1条完整数据和所述完整数据的M-1条分割数据,所述多个节点中的第二类验证节点验证基于所述完整数据生成的摘要数据。
  10. 如权利要求8所述的数据管理方法,其中所述M条数据包括1条完整数据的M条分割数据,所述多个节点中的第二类验证节点验证所述第一类验证节点未验证的摘要数据。
  11. 如权利要求9或10所述的数据管理方法,所述第一类验证节点数量大于所述第二类验证节点数量。
  12. 一种基于区块链的数据管理方法,应用在使用节点,所述方法包括:
    获取被包括在与特定设备和/或时间段对应的交易数据中的N条摘要数据中的M条摘要数据,其中所述N条摘要数据分别基于与所述交易数据相关联的N条数据而生成,N为大于1的整数,M为小于或等于N且大于或等于1的整数;
    获取分别与所述M条摘要数据对应的M条存储数据;
    计算所述M条存储数据各自的摘要;以及
    在所述M条摘要数据与所述M条存储数据各自的摘要分别相同的情况下,确定与所述交易数据相关联的完整数据未被篡改。
  13. 根据权利要求12所述的方法,
    所述N条数据为1条完整数据和所述完整数据的N-1条分割数据,并且基于其生成所述M条摘要数据的所述M条数据为1条完整数据和所述完整数据的M-1条分割数据,或,所述M条数据为所述完整数据的M条分割数据;或者
    所述N条数据为所述完整数据的N条分割数据,并且所述M条数据为所述完整数据的M条分割数据。
  14. 根据权利要求12所述的方法,其中,
    所述N条数据中至少两条数据的长度不同,所述M条摘要数据的摘要包括基于所述N条数据中长度最短的一条数据而生成的摘要数据。
  15. 根据权利要求14所述的方法,其中,M=1。
  16. 一种基于区块链的数据管理方法,应用在中间设备,所述方法包括:
    获取至少一个传感器设备的完整数据;
    将所述至少一个传感器设备的完整数据分割为P条数据,并基于所述至少一个传感器设备的完整数据生成完整摘要数据和/或分别基于所述P条数据生成P条摘要数据,P为大于1的整数;以及
    将所述P条数据和/或所述完整数据存储在数据服务器节点中,
    将P条摘要数据和/或所述完整摘要数据中的N条摘要数据包括在交易数据中并向区块链的验证节点发送,N等于P或P+1;
    其中,所述区块链中的验证节点在由所述中间设备计算的所述N条摘要数据中的M条摘要数据与由所述验证节点计算的与所述M条摘要数据对应的M条存储数据各自的摘要相同时,将所述交易数据生成区块并写入所述区块链,M为小于N且大于或等于1的整数。
  17. 根据权利要求16所述的方法,其中,
    基于其生成M条摘要数据的M条数据为所述完整数据和所述完整数据的M-1条分割数据;或,所述M条数据为所述完整数据的M条分割数据。
  18. 根据权利要求17所述的方法,其中,
    所述P条数据中至少两条数据的长度不同,所述M条摘要数据包括基于所述P条数据中长度最短的一条数据生成的摘要数据。
  19. 根据权利要求18所述的方法,其中,M=1。
  20. 根据权利要求17所述的方法,其中,
    所述至少一个传感器设备上传的数据除了所述完整数据之外,还包括设备标识,和/或时间信息。
  21. 根据权利要求20所述的方法,其中,将单个传感器设备上传的数据作为一条完整数据;或者将每个时间段的单个传感器设备上传的多条数据进行组合作为一条时间组合完整数据;或者将每个时间段的多个传感器设备上传的多条数据进行组合作为一条设备组合完整数据,
    其中,将所述至少一个传感器设备的完整数据分割为P条数据,包括:
    将所述完整数据、所述时间组合完整数据或所述设备组合完整数据按照按顺序的预设比例进行分割,
    或者基于时间信息按照时间来对所述时间组合完整数据进行分割;
    或者基于设备标识以传感器设备为单位或基于时间信息以时间段为单位来对所述设备组合完整数据进行分割。
  22. 根据权利要求16所述的方法,还包括:
    将所述P条数据的位置信息、所述P条数据对应的设备标识,和/或所述P条数据对应的时间信息连同所述完整摘要数据和/或所述P条摘要数据中的N条摘要数据一起包括在交易数据中并向区块链的验证节点发送。
  23. 根据权利要求22所述的方法,其中,所述P条数据的位置信息包括:
    存储P条数据的数据服务器节点的位置信息以及所述P条数据中的每条存储数据在所述数据服务器节点中的位置信息。
  24. 一种基于区块链的数据管理装置,包括:
    处理器,和
    存储器,其上存储有指令,所述指令在被执行时使得所述处理器执行如权利要求1-23任一项所述的方法。
  25. 一种基于区块链的数据管理系统,包括:
    至少一个传感器设备,其被配置为生成完整数据;
    区块链网络,包括:
    数据服务器节点,其被配置为存储所述完整数据和/或由所述完整数据划分的P条数据;
    存储节点,其被配置为存储基于所述完整数据生成的完整摘要数据和/或基于由所述完整数据划分的P条数据中的至少一条数据生成的至少一条摘要数据;
    验证节点,其被配置为执行如权利要求1-11任一项所述的方法;
    使用节点,其被配置为执行如权利要求12-15任一项所述的方法;以及
    中间设备,其被配置为执行如权利要求16-23任一项所述的方法。
PCT/CN2021/108427 2020-07-31 2021-07-26 基于区块链的数据管理方法、装置和系统 WO2022022457A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP21849628.9A EP4191973A1 (en) 2020-07-31 2021-07-26 Data management method, apparatus and system based on blockchain
US18/017,937 US20230274271A1 (en) 2020-07-31 2021-07-26 Data management method, apparatus and system based on blockchain

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010760397.X 2020-07-31
CN202010760397.XA CN114095515A (zh) 2020-07-31 2020-07-31 基于区块链的数据管理方法、装置和系统

Publications (1)

Publication Number Publication Date
WO2022022457A1 true WO2022022457A1 (zh) 2022-02-03

Family

ID=80037557

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/108427 WO2022022457A1 (zh) 2020-07-31 2021-07-26 基于区块链的数据管理方法、装置和系统

Country Status (4)

Country Link
US (1) US20230274271A1 (zh)
EP (1) EP4191973A1 (zh)
CN (1) CN114095515A (zh)
WO (1) WO2022022457A1 (zh)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101166190A (zh) * 2007-09-20 2008-04-23 腾讯科技(深圳)有限公司 影音文件的多源下载方法及装置
CN106790431A (zh) * 2016-12-05 2017-05-31 同济大学 基于区块链的云制造服务交易信息记录系统与方法
CN110275891A (zh) * 2018-03-15 2019-09-24 国际商业机器公司 人工智能软件市场
CN110930152A (zh) * 2019-12-04 2020-03-27 腾讯科技(深圳)有限公司 一种基于区块链的数据处理方法及相关设备
US10708068B2 (en) * 2019-02-28 2020-07-07 Alibaba Group Holding Limited System and method for implementing blockchain-based digital certificates

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101166190A (zh) * 2007-09-20 2008-04-23 腾讯科技(深圳)有限公司 影音文件的多源下载方法及装置
CN106790431A (zh) * 2016-12-05 2017-05-31 同济大学 基于区块链的云制造服务交易信息记录系统与方法
CN110275891A (zh) * 2018-03-15 2019-09-24 国际商业机器公司 人工智能软件市场
US10708068B2 (en) * 2019-02-28 2020-07-07 Alibaba Group Holding Limited System and method for implementing blockchain-based digital certificates
CN110930152A (zh) * 2019-12-04 2020-03-27 腾讯科技(深圳)有限公司 一种基于区块链的数据处理方法及相关设备

Also Published As

Publication number Publication date
EP4191973A1 (en) 2023-06-07
US20230274271A1 (en) 2023-08-31
CN114095515A (zh) 2022-02-25

Similar Documents

Publication Publication Date Title
CN109189962B (zh) 一种基于区块链的证照服务实现系统
Platt et al. The energy footprint of blockchain consensus mechanisms beyond proof-of-work
CN108737375B (zh) 一种区块链共识方法及系统
CN111028023B (zh) 基于区块链系统的税务管理方法、装置、介质及电子设备
CN110460590B (zh) 区块链系统的数据管理方法、装置、介质及电子设备
JP7169462B2 (ja) ブロックチェーンネットワークにおいてアイデンティティ証明書を取り換える方法、装置、記憶媒体及びコンピュータ機器
CN109165943A (zh) 关于电子票据的数据处理方法、装置、存储介质和设备
EP4318362A1 (en) Blockchain-based data processing method, apparatus and device, and storage medium
CN112231741B (zh) 基于区块链系统的数据处理方法、装置、介质及电子设备
JP2019200556A (ja) 利用管理方法、利用管理システム、および、ノード
WO2020134631A1 (zh) 基于区块链的数据处理方法和装置
Yadav et al. Blockchain-based digitization of land record through trust value-based consensus algorithm
Wang et al. Performance evaluation on blockchain systems: a case study on Ethereum, Fabric, Sawtooth and Fisco-Bcos
CN110851877B (zh) 一种数据处理方法、装置及区块链节点设备、存储介质
CN110599275A (zh) 一种基于区块链网络的数据处理方法、装置及存储介质
CN114493865A (zh) 基于区块链的去中心化互联网协同系统和数据交互方法
CN112053271B (zh) 基于区块链的公益平台数据存证管理方法及系统
US11044104B2 (en) Data certification as a service powered by permissioned blockchain network
Xu et al. Manufacturing industry supply chain management based on the ethereum blockchain
Nguyen et al. Analysis of distributed ledger technologies for industrial manufacturing
WO2018032817A1 (zh) 一种一致性数据累积协同组装方法
CN112532753B (zh) 区块链系统的数据同步方法、装置、介质及电子设备
CN114386096A (zh) 去中心化的交易数据存储方法、装置、设备及存储介质
WO2022022457A1 (zh) 基于区块链的数据管理方法、装置和系统
US11876861B2 (en) Data management method, data management device, blockchain network and system

Legal Events

Date Code Title Description
NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 2021849628

Country of ref document: EP

Effective date: 20230228