Data protection method, device and equipment and computer readable storage medium

By verifying the legitimacy of building operation data from the smart building system and uploading it to the blockchain, the problems of data theft and tampering are solved, data security and efficient exchange are achieved, and the security and efficiency of the system are improved.

CN120979735APending Publication Date: 2025-11-18THREE GORGES HI TECH INFORMATION TECH CO LTD
View PDF 7 Cites 0 Cited by

Patent Information

Application Number
CN202511162079.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-19
Publication Date
2025-11-18

AI Technical Summary

Technical Problem

In smart building systems, the building operation data collected by sensors is at risk of being stolen and tampered with, leading to the leakage of privacy data or abnormal building operation.

Method used

By performing a first legitimacy check on the building operation data, generating a data fingerprint, and then having multiple consensus nodes sign the fingerprints and aggregate them, a second legitimacy check is performed before uploading it to the blockchain. The decentralized and tamper-proof characteristics of the blockchain are used to ensure data security.

Benefits of technology

It effectively prevents the theft and tampering of building operation data, ensures data security and integrity, improves communication efficiency and energy consumption management, reduces storage costs, and achieves efficient data exchange and secure data sharing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120979735A_ABST
    Figure CN120979735A_ABST
Patent Text Reader

Abstract

The invention discloses a data protection method, device and equipment and a computer readable storage medium. The method comprises the following steps: for each area in a building, obtaining building operation data, and carrying out first legality verification on the building operation data; if the first legality verification is passed, preprocessing the building operation data to obtain a data fingerprint; obtaining a plurality of digital signatures obtained by signing the data fingerprint by a plurality of consensus nodes participating in consensus; aggregating the plurality of digital signatures to obtain an aggregated signature; performing second legality verification on the aggregated signature; and if the second validity verification is passed, uploading the data fingerprint to a target block chain. According to the invention, the safety of the building operation data is ensured.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of information security technology, specifically to a data protection method, apparatus, device, and computer-readable storage medium. Background Technology

[0002] Smart building systems are based on sensors to collect building operation data, including environmental data, equipment operation data, and personnel flow data. Combined with relevant data processing technologies, they can effectively improve safety, comfort, energy efficiency, and management convenience, and have good development prospects.

[0003] However, the building operation data collected by sensors is at risk of being stolen and tampered with, which could lead to privacy data leaks or abnormal building operation. Therefore, how to provide data protection for building operation data is an urgent technical problem to be solved. Summary of the Invention

[0004] This application provides a data protection method, apparatus, device, and computer-readable storage medium, which can solve the technical problem that building operation data is easily stolen and tampered with in the prior art.

[0005] In a first aspect, embodiments of this application provide a data protection method, the data protection method comprising: For each area within the building, acquire building operation data and perform a first-level validity check on the building operation data; If the first validity check passes, the building operation data is preprocessed to obtain the data fingerprint; Multiple digital signatures are obtained by having multiple consensus nodes participating in the consensus process sign the data fingerprint respectively; The multiple digital signatures are aggregated to obtain an aggregated signature; Perform a second validity check on the aggregated signature; If the second validity check passes, the data fingerprint is uploaded to the target blockchain.

[0006] In conjunction with the first aspect, in one implementation, the first legality check includes: Check whether the format of building operation data is compliant; Check the validity of the digital certificates of the sensors that collect building operation data; Detect whether building operation data is duplicated; If the building operation data is in a compliant format, the digital certificates of the sensors that collect the building operation data are valid, and the building operation data is not duplicated, then the first validity check passes.

[0007] In conjunction with the first aspect, in one implementation, the second legality check includes: Check whether the format of the aggregated signature is compliant; The aggregated signature is restored to obtain the digital signature corresponding to each consensus node; The digital signature corresponding to each consensus node is verified using the public key of each consensus node. If the format of the aggregated signatures is compliant and all signatures are successfully verified, then the second legality check is passed.

[0008] In conjunction with the first aspect, in one implementation, the building comprises multiple zones, and the data protection method further includes: For each zone in the building, obtain the random number reported by each secondary node within that zone; The secondary node corresponding to the random number that differs from the preset value the smallest is selected as the consensus node. This process continues until multiple consensus nodes are obtained.

[0009] In conjunction with the first aspect, in one implementation, the data protection method further includes: Several target areas are randomly selected at preset intervals; For each target region, obtain the random number reported by each secondary node within the target region; The secondary node corresponding to the random number that differs from the preset value the smallest is selected as the consensus node.

[0010] In conjunction with the first aspect, in one implementation, after uploading the data fingerprint to the target blockchain, the method further includes: When a data acquisition request is received, verify whether the requester that triggered the data acquisition request has the necessary access permission. If the necessary permissions are granted, the target data fingerprint corresponding to the data acquisition request will be searched on the target blockchain. The target data fingerprint is encrypted and then transmitted to the requester.

[0011] In conjunction with the first aspect, in one implementation, after transmitting the encrypted target data fingerprint to the requester, the method further includes: The transaction information for generating the target data fingerprint is stored in the target blockchain. The transaction information includes a timestamp of receiving the data acquisition request, the identity of the requester, and a timestamp of transmitting the encrypted target data fingerprint to the requester.

[0012] Secondly, embodiments of this application provide a data protection device, the data protection device comprising: The first acquisition module is used to acquire building operation data for each area in the building and to perform the first legality verification on the building operation data; The preprocessing module is used to preprocess the building operation data to obtain a data fingerprint if the first validity check passes. The second acquisition module is used to acquire multiple digital signatures obtained by multiple consensus nodes participating in the consensus signing the data fingerprint respectively. The aggregation module is used to aggregate the multiple digital signatures to obtain an aggregated signature; The verification module is used to perform a second validity verification on the aggregated signature; The upload module is used to upload the data fingerprint to the target blockchain if the second legality verification passes.

[0013] Thirdly, embodiments of this application provide a data protection device, which includes a processor, a memory, and a data protection program stored in the memory and executable by the processor, wherein when the data protection program is executed by the processor, it implements the steps of the data protection method as described in the first aspect.

[0014] Fourthly, embodiments of this application provide a computer-readable storage medium storing a data protection program, wherein when the data protection program is executed by a processor, it implements the steps of the data protection method as described in the first aspect.

[0015] The beneficial effects of the technical solutions provided in this application include: In this embodiment, for each area within a building, building operation data is acquired, and a first validity check is performed on the building operation data. If the first validity check passes, the building operation data is preprocessed to obtain a data fingerprint. Multiple digital signatures are obtained by multiple consensus nodes participating in the consensus process, each signing the data fingerprint. The multiple digital signatures are aggregated to obtain an aggregate signature. A second validity check is performed on the aggregate signature. If the second validity check passes, the data fingerprint is uploaded to the target blockchain. In this embodiment, the first validity check ensures that the data fingerprint is obtained from correct building operation data, and the second validity check ensures that the data fingerprint uploaded to the target blockchain has not been tampered with. Furthermore, the decentralized and immutable characteristics of the blockchain ensure the security of the data fingerprint, thereby guaranteeing the security of the building operation data. Attached Figure Description

[0016] Figure 1 This is a flowchart illustrating an embodiment of the data protection method of this application; Figure 2This is a schematic diagram of the functional modules of an embodiment of the data protection device of this application; Figure 3 This is a schematic diagram of the hardware structure of the data protection device involved in the embodiments of this application. Detailed Implementation

[0017] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of the present application.

[0018] To make the objectives, technical solutions, and advantages of this application clearer, the embodiments of this application will be described in further detail below with reference to the accompanying drawings.

[0019] In a first aspect, embodiments of this application provide a data protection method.

[0020] In one embodiment, reference is made to Figure 1 , Figure 1 This is a flowchart illustrating an embodiment of the data protection method of this application. Figure 1 As shown, data protection methods include: Step S10: For each area in the building, obtain the building operation data and perform the first legality verification on the building operation data; In this embodiment, the building space can be divided into multiple zones according to floors or functional areas. For each zone, building operation data collected by various sensors within the zone can be obtained through secondary nodes, and the building operation data is subjected to a first legality verification. This primarily verifies whether the building operation data has been tampered with.

[0021] It should be noted that the building contains multiple nodes, and at least one core node and multiple secondary nodes can be determined based on computing power. There is at least one secondary node in each area.

[0022] For each area, secondary nodes continuously acquire building operation data collected by sensors. When a small number of sensors experience response delays, those sensors can be ignored to prevent the overall task from stalling.

[0023] Furthermore, in one embodiment, the first legality check includes: Check whether the format of building operation data is compliant; Check the validity of the digital certificates of the sensors that collect building operation data; Detect whether building operation data is duplicated; If the building operation data is in a compliant format, the digital certificates of the sensors that collect the building operation data are valid, and the building operation data is not duplicated, then the first validity check passes.

[0024] Step S20: If the first validity check passes, the building operation data is preprocessed to obtain the data fingerprint; In this embodiment, if the first legality check passes, it means that the building operation data is correct and has not been tampered with. Then, it is cleaned, compressed, and hashed to obtain the data fingerprint.

[0025] Of course, it can also be cleaned, compressed, and then encrypted, and the encrypted data can be stored on the core node.

[0026] Step S30: Obtain multiple digital signatures obtained by the multiple consensus nodes participating in the consensus signing the data fingerprint respectively; In this embodiment, the multiple consensus nodes participating in the consensus can be determined manually. For each consensus node, it signs the data fingerprint using its own private key. The signing process employs an efficient encryption algorithm (such as Elliptic Curve Digital Signature Algorithm, ECDSA) to generate a digital signature. The signature generation process ensures the integrity and immutability of the data. The generated digital signature is formatted into a specific structure for subsequent aggregation processing.

[0027] Step S40: Aggregate the multiple digital signatures to obtain an aggregated signature; In this embodiment, threshold signature technology can be used to aggregate the signatures of multiple nodes into a short signature. The specific process is as follows: Signature collection: The system collects the digital signatures of the N consensus nodes participating in the consensus process. Signature aggregation: Using a threshold signature algorithm, digital signatures from N nodes are aggregated according to specific mathematical rules to generate a short signature (i.e., aggregated signature). The core of the aggregation process lies in leveraging the characteristics of cryptographic algorithms to map multiple independent digital signatures into the same mathematical space, thereby achieving efficient signature aggregation.

[0028] Signature optimization: Aggregate signatures have been further optimized to ensure that their length and complexity are as small as possible, in order to reduce storage and transmission overhead.

[0029] This aggregation method significantly reduces the total length of the aggregated signature while preserving its integrity and credibility.

[0030] Step S50: Perform a second validity check on the aggregated signature; In this embodiment, the second validity check of the aggregated signature can be performed by the core node. The aggregated signature needs to be verified to ensure its validity. The second validity check includes the following steps: Signature parsing: First, parse the aggregate signature and extract the signature information of all nodes contained therein.

[0031] Signature verification: The aggregate signature is verified using the public keys of the nodes participating in the consensus. The verification process includes: Check whether the aggregated signature meets the requirements of the threshold signature algorithm.

[0032] Verify whether the aggregated signature can correctly reconstruct the signature of each node.

[0033] Ensure that the signature generation process meets the system's security and consistency requirements.

[0034] Validity verification: If the aggregated signature passes the above verification, its validity is confirmed; otherwise, the system will reject the signature and trigger the corresponding error handling mechanism.

[0035] Furthermore, in one embodiment, the second legality check includes: Check whether the format of the aggregated signature is compliant; The aggregated signature is restored to obtain the digital signature corresponding to each consensus node; The digital signature corresponding to each consensus node is verified using the public key of each consensus node. If the format of the aggregated signatures is compliant and all signatures are successfully verified, then the second legality check is passed.

[0036] Step S60: If the second legality verification passes, the data fingerprint is uploaded to the target blockchain.

[0037] In this embodiment, if the second legality verification passes, it means that the data fingerprint has not been tampered with, and then it is uploaded to the target blockchain.

[0038] This application's embodiments achieve a breakthrough performance improvement through a three-layer innovative architecture. In terms of communication efficiency, addressing the pain point of the traditional PBFT algorithm's O(N²) level communication complexity, it adopts a "sharding network + threshold signature + data fingerprint" approach: reducing the communication volume in a 100-node scenario from 9900 times to 225 times, compressing the size of a single message to less than 1KB, and reducing the measured block confirmation communication volume from 15MB to 120KB (a reduction of 99.2%). For energy management, a dynamic energy-saving system is constructed: by keeping terminal devices in "sleep mode" 90% of the time, distributing light tasks such as SHA3 verification to secondary nodes (e.g., network management), and centrally handling heavy computations such as ECC encryption by core nodes (e.g., edge servers), coupled with TEE trusted hardware acceleration (signature verification speed reaching 3000 times / second), the overall energy efficiency is improved by 5-8 times. The breakthrough in real-time response stems from process refactoring and architecture optimization: the three-stage consensus of PBFT is compressed into a two-stage Propose-Vote, reducing latency from 800ms to 280ms; the three-level pipeline architecture of "verification-consensus-storage" brings a high throughput of 1200TPS, which is sufficient to cope with the peak of thousands of data points per second in building scenarios; the edge buffer established for critical data such as fire alarms further suppresses the response latency to within 50ms.

[0039] Simplifying the block structure and storage content, retaining only essential data digests and transaction information (discussed below), reduces storage space consumption. For example, raw data collected by IoT devices (such as temperature sensors), including device ID, timestamps, temperature values, etc., is preprocessed at the edge computing layer, including data cleaning, format conversion, and compression to reduce data volume. Subsequently, a hash function (such as SHA-3) is used to generate a unique data digest for the preprocessed data; for example, compressing a 1KB raw data into a 64-byte hash value. These data digests and related transaction information (such as identifiers of data providers and recipients, timestamps, etc.) are stored in the blockchain block body, while the raw data is encrypted and stored at the edge nodes. In this way, the storage space requirements of the blockchain are significantly reduced while ensuring data security and integrity. This simplified block structure design not only improves data processing efficiency but also significantly reduces storage costs, providing reliable technical support for efficient data exchange in smart buildings.

[0040] In this embodiment, for each area within a building, building operation data is acquired, and a first validity check is performed on the building operation data. If the first validity check passes, the building operation data is preprocessed to obtain a data fingerprint. Multiple digital signatures are obtained by multiple consensus nodes participating in the consensus process, each signing the data fingerprint. The multiple digital signatures are aggregated to obtain an aggregate signature. A second validity check is performed on the aggregate signature. If the second validity check passes, the data fingerprint is uploaded to the target blockchain. In this embodiment, the first validity check ensures that the data fingerprint is obtained from correct building operation data, and the second validity check ensures that the data fingerprint uploaded to the target blockchain has not been tampered with. Furthermore, the decentralized and immutable characteristics of the blockchain ensure the security of the data fingerprint, thereby guaranteeing the security of the building operation data.

[0041] Furthermore, in one embodiment, the building comprises multiple zones, and the data protection method further includes: For each zone in the building, obtain the random number reported by each secondary node within that zone; The secondary node corresponding to the random number that differs from the preset value the smallest is selected as the consensus node. This process continues until multiple consensus nodes are obtained.

[0042] In this embodiment, there are generally multiple secondary nodes in each region. One is selected as the consensus node in a random manner. Assuming there are 10 regions, 10 consensus nodes can be determined.

[0043] Furthermore, in one embodiment, the data protection method further includes: Several target areas are randomly selected at preset intervals; For each target region, obtain the random number reported by each secondary node within the target region; The secondary node corresponding to the random number that differs from the preset value the smallest is selected as the consensus node.

[0044] In this embodiment, to prevent malicious nodes from acting as consensus nodes for an extended period, consensus nodes can be reselected from a subset of regions at preset intervals.

[0045] Furthermore, in one embodiment, after step S60, the method further includes: Step S70: When a data acquisition request is received, verify whether the requester that triggered the data acquisition request has the right to acquire the data. Step S80: If the user has the necessary permissions, search for the target data fingerprint corresponding to the data acquisition request on the target blockchain. Step S90 involves encrypting the target data fingerprint and transmitting it to the requester.

[0046] Furthermore, in one embodiment, after step S90, the method further includes: The transaction information for generating the target data fingerprint is stored in the target blockchain. The transaction information includes a timestamp of receiving the data acquisition request, the identity of the requester, and a timestamp of transmitting the encrypted target data fingerprint to the requester.

[0047] In this embodiment, smart contracts are deployed at the blockchain network layer to define the rules, conditions, and processes for data exchange. The smart contracts include authentication of the data requester and provider, data permission verification, and transaction settlement. Smart contract-driven data exchange ensures security, efficiency, and automation through predefined rules, conditions, and processes. First, the smart contracts define authentication rules for the data requester and provider at the blockchain network layer, ensuring that only authorized users can participate in data exchange. Second, the contracts set the conditions for data exchange, including data format, encryption methods, and access permissions, ensuring the integrity and security of data during transmission. During the data exchange process, when the data requester initiates a request, the smart contract automatically triggers a verification process, including authentication and permission checks. After successful verification, the smart contract queries the data digest on the target blockchain to ensure the authenticity and integrity of the data. Subsequently, the smart contract executes encrypted data transmission and settles the transaction after completion. The entire process is automated, reducing the possibility of human intervention and improving transaction efficiency and reliability. Simultaneously, the smart contracts integrate privacy protection mechanisms, such as encryption technology and access control, ensuring that data is used only within authorized scope, further enhancing data security. This intelligent data exchange process not only enhances system security but also provides efficient technical support for data sharing and collaboration in smart buildings.

[0048] When a data request occurs, the smart contract automatically triggers and executes the data exchange process. This includes steps such as verifying the requester's identity and permissions, querying the data digest on the target blockchain, verifying the integrity and authenticity of the data, and executing transaction settlement.

[0049] During smart contract execution, encryption technology and access control mechanisms are used to protect data privacy and security, ensuring that only authorized users can access and use the data.

[0050] Furthermore, a cross-chain protocol is designed and implemented to support interoperability between this platform (including sensors, secondary nodes, and core nodes) and other blockchains or traditional data exchange systems. The cross-chain protocol includes cross-chain message passing, cross-chain asset transfer, and cross-chain smart contract invocation. Specifically, the cross-chain protocol defines the format and transmission rules of cross-chain messages, supporting cross-chain asset transfer and cross-chain smart contract invocation. For example, when data from a smart building needs to be exchanged with an external blockchain system, the cross-chain protocol automatically packages the data summary and related transaction information into a standardized message format and transmits it to the external blockchain through a dedicated communication channel. Simultaneously, the protocol also supports cross-chain asset transfer, for example, by using cross-chain atomic swap technology to ensure the security and consistency of assets during the transfer process. In addition, the cross-chain smart contract invocation mechanism allows smart contracts on different blockchains to call each other, achieving seamless integration of business logic. In this way, the cross-chain protocol not only breaks down the technical barriers between different blockchains but also provides a bridge for traditional data exchange systems to interface with blockchain platforms, thereby achieving efficient collaboration and data sharing among multiple systems. This design not only enhances the system's flexibility and scalability, but also provides a wider range of application scenarios and technical support for secure data exchange in smart buildings.

[0051] It provides standardized interoperability interfaces, facilitating access to and invocation of the platform's data exchange services by other systems. Simultaneously, it also supports access to data and resources from other systems.

[0052] Establishing a cross-chain governance mechanism resolves conflicts and disputes during cross-chain interoperability. This mechanism ensures smooth and reliable interoperability between different blockchains and traditional data exchange systems by establishing a consensus mechanism, arbitration institutions, and a credit system. The consensus mechanism enables systems to reach agreement on data and transaction processing, reducing conflicts caused by information asymmetry. When disputes arise, arbitration institutions, acting as neutral third parties, quickly intervene to provide impartial solutions and prevent escalation. The credit system assesses the reputation of participating parties, incentivizing rule compliance and reducing malicious behavior. These mechanisms work synergistically to effectively reduce conflict and promote trust and collaboration within the cross-chain ecosystem.

[0053] Secondly, embodiments of this application also provide a data protection device.

[0054] In one embodiment, reference is made to Figure 2 , Figure 2 This is a functional module diagram of an embodiment of the data protection device of this application. Figure 2 As shown, the data protection device includes: The first acquisition module 10 is used to acquire building operation data for each area in the building and perform a first legality check on the building operation data; The preprocessing module 20 is used to preprocess the building operation data to obtain a data fingerprint if the first validity check passes. The second acquisition module 30 is used to acquire multiple digital signatures obtained by multiple consensus nodes participating in the consensus signing the data fingerprint respectively. Aggregation module 40 is used to aggregate the multiple digital signatures to obtain an aggregated signature; Verification module 50 is used to perform a second validity verification on the aggregated signature; Upload module 60 is used to upload the data fingerprint to the target blockchain if the second legality verification passes.

[0055] Furthermore, in one embodiment, the first legality check includes: Check whether the format of building operation data is compliant; Check the validity of the digital certificates of the sensors that collect building operation data; Detect whether building operation data is duplicated; If the building operation data is in a compliant format, the digital certificates of the sensors that collect the building operation data are valid, and the building operation data is not duplicated, then the first validity check passes.

[0056] Furthermore, in one embodiment, the second legality check includes: Check whether the format of the aggregated signature is compliant; The aggregated signature is restored to obtain the digital signature corresponding to each consensus node; The digital signature corresponding to each consensus node is verified using the public key of each consensus node. If the format of the aggregated signatures is compliant and all signatures are successfully verified, then the second legality check is passed.

[0057] Furthermore, in one embodiment, the building comprises multiple zones, and the data protection device further includes an election module for: For each zone in the building, obtain the random number reported by each secondary node within that zone; The secondary node corresponding to the random number that differs from the preset value the smallest is selected as the consensus node. This process continues until multiple consensus nodes are obtained.

[0058] Furthermore, in one embodiment, the election module is also used for: Several target areas are randomly selected at preset intervals; For each target region, obtain the random number reported by each secondary node within the target region; The secondary node corresponding to the random number that differs from the preset value the smallest is selected as the consensus node.

[0059] Furthermore, in one embodiment, the data protection device further includes a switching module for: When a data acquisition request is received, verify whether the requester that triggered the data acquisition request has the necessary access permission. If the necessary permissions are granted, the target data fingerprint corresponding to the data acquisition request will be searched on the target blockchain. The target data fingerprint is encrypted and then transmitted to the requester.

[0060] Furthermore, in one embodiment, the data protection device further includes a recording module for: The transaction information for generating the target data fingerprint is stored in the target blockchain. The transaction information includes a timestamp of receiving the data acquisition request, the identity of the requester, and a timestamp of transmitting the encrypted target data fingerprint to the requester.

[0061] The functions of each module in the above-mentioned data protection device correspond to the steps in the above-mentioned data protection method embodiments, and their functions and implementation processes will not be described in detail here.

[0062] Thirdly, embodiments of this application provide a data protection device, which can be a personal computer (PC), laptop computer, server, or other device with data processing capabilities.

[0063] Reference Figure 3 , Figure 3 This is a schematic diagram of the hardware structure of the data protection device involved in the embodiments of this application. In the embodiments of this application, the data protection device may include a processor, a memory, a communication interface, and a communication bus.

[0064] The communication bus can be of any type and is used to interconnect the processor, memory, and communication interface.

[0065] Communication interfaces include input / output (I / O) interfaces, physical interfaces, and logical interfaces used for interconnecting devices within the data protection equipment, as well as interfaces used for interconnecting the data protection equipment with other devices (such as other computing devices or user equipment). Physical interfaces can be Ethernet interfaces, fiber optic interfaces, ATM interfaces, etc.; user equipment can be displays, keyboards, etc.

[0066] Memory can be various types of storage media, such as random access memory (RAM), read-only memory (ROM), non-volatile RAM (NVRAM), flash memory, optical storage, hard disk, programmable ROM (PROM), erasable PROM (EPROM), electrically erasable PROM (EEPROM), etc.

[0067] The processor can be a general-purpose processor, which can call a data protection program stored in memory and execute the data protection method provided in the embodiments of this application. For example, the general-purpose processor can be a central processing unit (CPU). The method executed when the data protection program is called can be referred to in the various embodiments of the data protection method of this application, and will not be repeated here.

[0068] Those skilled in the art will understand that Figure 3 The hardware structure shown does not constitute a limitation of this application and may include more or fewer components than shown, or combine certain components, or have different component arrangements.

[0069] Fourthly, embodiments of this application also provide a computer-readable storage medium.

[0070] The present application has a data protection program stored on a computer-readable storage medium, wherein when the data protection program is executed by a processor, it implements the steps of the data protection method described above.

[0071] The methods implemented when the data protection procedure is executed can be referred to in various embodiments of the data protection method of this application, and will not be repeated here.

[0072] It should be noted that the sequence numbers of the embodiments in this application are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.

[0073] The terms "comprising" and "having," and any variations thereof, in the specification, claims, and accompanying drawings of this application are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or apparatus that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to such process, method, product, or apparatus. The terms "first," "second," and "third," etc., are used to distinguish different objects, etc., and do not indicate a sequence, nor do they limit "first," "second," and "third" to different types.

[0074] In the description of the embodiments of this application, terms such as "exemplary," "for example," or "for instance" are used to indicate examples, illustrations, or explanations. Any embodiment or design described as "exemplary," "for example," or "for instance" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or designs. Specifically, the use of terms such as "exemplary," "for example," or "for instance" is intended to present the relevant concepts in a concrete manner.

[0075] In the description of the embodiments of this application, unless otherwise stated, " / " means "or". For example, A / B can mean A or B. The "and / or" in the text is merely a description of the relationship between related objects, indicating that there can be three relationships. For example, A and / or B can mean: A exists alone, A and B exist simultaneously, and B exists alone. In addition, in the description of the embodiments of this application, "multiple" means two or more.

[0076] In some processes described in the embodiments of this application, multiple operations or steps are included in a specific order. However, it should be understood that these operations or steps may not be executed in the order they appear in the embodiments of this application, or they may be executed in parallel. The sequence number of the operation is only used to distinguish different operations, and the sequence number itself does not represent any execution order. In addition, these processes may include more or fewer operations, and these operations or steps may be executed sequentially or in parallel, and these operations or steps may be combined.

[0077] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) as described above, and includes several instructions to cause a terminal device to execute the methods described in the various embodiments of this application.

[0078] The above are merely preferred embodiments of this application and do not limit the patent scope of this application. Any equivalent structural or procedural transformations made using the content of this application's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of this application.

Claims

1. A data protection method, characterized in that, The data protection method includes: For each area within the building, acquire building operation data and perform a first-level validity check on the building operation data; If the first validity check passes, the building operation data is preprocessed to obtain the data fingerprint; Multiple digital signatures are obtained by having multiple consensus nodes participating in the consensus process sign the data fingerprint respectively; The multiple digital signatures are aggregated to obtain an aggregated signature; Perform a second validity check on the aggregated signature; If the second validity check passes, the data fingerprint is uploaded to the target blockchain.

2. The data protection method as described in claim 1, characterized in that, The first validity check includes: Check whether the format of building operation data is compliant; Check the validity of the digital certificates of the sensors that collect building operation data; Detect whether building operation data is duplicated; If the building operation data is in a compliant format, the digital certificates of the sensors that collect the building operation data are valid, and the building operation data is not duplicated, then the first validity check passes.

3. The data protection method as described in claim 1, characterized in that, The second validity check includes: Check whether the format of the aggregated signature is compliant; The aggregated signature is restored to obtain the digital signature corresponding to each consensus node; The digital signature corresponding to each consensus node is verified using the public key of each consensus node. If the format of the aggregated signatures is compliant and all signatures are successfully verified, then the second legality check is passed.

4. The data protection method as described in claim 1, characterized in that, The building comprises multiple zones, and the data protection method further includes: For each zone in the building, obtain the random number reported by each secondary node within that zone; The secondary node corresponding to the random number that differs from the preset value the smallest is selected as the consensus node. This process continues until multiple consensus nodes are obtained.

5. The data protection method as described in claim 4, characterized in that, The data protection method further includes: Several target areas are randomly selected at preset intervals; For each target region, obtain the random number reported by each secondary node within the target region; The secondary node corresponding to the random number that differs from the preset value the smallest is selected as the consensus node.

6. The data protection method according to any one of claims 1 to 5, characterized in that, After uploading the data fingerprint to the target blockchain, the process also includes: When a data acquisition request is received, verify whether the requester that triggered the data acquisition request has the necessary access permission. If the necessary permissions are granted, the target data fingerprint corresponding to the data acquisition request will be searched on the target blockchain. The target data fingerprint is encrypted and then transmitted to the requester.

7. The data protection method as described in claim 6, characterized in that, After encrypting the target data fingerprint and transmitting it to the requester, the method further includes: The transaction information for generating the target data fingerprint is stored in the target blockchain. The transaction information includes a timestamp of receiving the data acquisition request, the identity of the requester, and a timestamp of transmitting the encrypted target data fingerprint to the requester.

8. A data protection device, characterized in that, The data protection device includes: The first acquisition module is used to acquire building operation data for each area in the building and to perform the first legality verification on the building operation data; The preprocessing module is used to preprocess the building operation data to obtain a data fingerprint if the first validity check passes. The second acquisition module is used to acquire multiple digital signatures obtained by multiple consensus nodes participating in the consensus signing the data fingerprint respectively. The aggregation module is used to aggregate the multiple digital signatures to obtain an aggregated signature; The verification module is used to perform a second validity verification on the aggregated signature; The upload module is used to upload the data fingerprint to the target blockchain if the second legality verification passes.

9. A data protection device, characterized in that, The data protection device includes a processor, a memory, and a data protection program stored in the memory and executable by the processor, wherein when the data protection program is executed by the processor, it implements the steps of the data protection method as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a data protection program, wherein when the data protection program is executed by a processor, it implements the steps of the data protection method as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Block chain one-dimensional random number consensus recommendation method

    CN107347009A

  • Consensus method of block chain data and related equipment

    CN110300172A

  • Signature method and system for block chain

    CN110798308A

  • Random number generation method and device, terminal equipment and storage medium

    CN112182612A

  • Internet of Things data storage method based on block chain and NB-IoT chip

    CN114499876A