Data management methods, devices and storage media
By using a hash algorithm to generate blockchain nodes in the cloud management platform, the problem of incomplete information in cloud resource lifecycle management is solved, and effective management of resource lifecycle data and reliable information assurance are achieved.
Patent Information
- Application Number
- CN202211682729.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-27
- Publication Date
- 2026-11-17
- Estimated Expiration
- 2042-12-27
AI Technical Summary
Existing cloud management platforms lack dedicated resource lifecycle management functions, making it impossible to record in detail the changes in the state and attributes of resources before and after operations, resulting in chaotic management and difficulty in ensuring the effectiveness of cloud resource lifecycle information.
Blockchain nodes are generated using a hash algorithm. By calculating the hash values of event information and device information, a blockchain is established to monitor and verify the integrity of information in real time, ensuring the validity of resource lifecycle data.
It enables effective management of cloud resource lifecycle data, timely detection of blockchain content tampering, and ensures the integrity and trustworthiness of information.
Smart Images

Figure CN116167098B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of communications, and more particularly to a data management method, apparatus, and storage medium. Background Technology
[0002] With the cloud-based deployment of 5G core networks and the continuous growth in the number of users, users will apply for and use various computing, storage, and network resources. As a result, the scale of the cloud resource pool providing services to users is also growing, the operating environment is becoming more complex, and a large amount of cloud resource data is generated during the lifecycle.
[0003] Current cloud management platforms lack dedicated resource lifecycle management functions or modules. They typically record operation logs for resources, but these logs only record the operator, operation type, and time, failing to detail the resource's state before and after the operation, changes in resource attribute values, or the entire lifecycle of a resource from creation to destruction. This lack of a reliable system for later problem localization and accountability leads to management chaos. Therefore, managing data throughout the resource lifecycle and ensuring the validity of information generated during the cloud resource lifecycle remains an unresolved technical problem. Summary of the Invention
[0004] This application provides a data management method, apparatus, and storage medium. These are used to manage data throughout the lifecycle of device resources and ensure the validity of information generated during the lifecycle of cloud resources.
[0005] To achieve the above objectives, this application adopts the following technical solution:
[0006] In a first aspect, this application provides a data management method in which a data management device acquires first event information of a target device; the first event information is event information occurring during the lifecycle management of the target device; the data management device calculates the first event information according to a preset hash algorithm to determine a first hash value of the first event information; the data management device acquires a second hash value of the target device; the second hash value is either the hash value of the previous event information of the first event information or the hash value of the device information of the target device; and the data management device generates a first blockchain node based on the first event information, the first hash value, and the second hash value.
[0007] In conjunction with the first aspect above, in one possible implementation, the method further includes: when the first event information is the event information that occurs for the first time during the target device lifecycle management process, the second hash value is the hash value of the device information of the target device; when the first event information is the event information that occurs for the Nth time during the target device lifecycle management process, the second hash value is the hash value of the event information that occurs for the (N-1)th time during the target device lifecycle management process; N is a positive integer greater than 2.
[0008] In conjunction with the first aspect mentioned above, in one possible implementation, the method further includes: a data management device acquiring device information of the target device; the data management device calculating a hash value of the device information according to a preset hash algorithm to determine a second hash value of the target device; and the data management device generating a second blockchain node based on the device information and the second hash value.
[0009] In conjunction with the first aspect described above, in one possible implementation, the method further includes: a data management device acquiring a second hash value from a first blockchain node; the data management device acquiring event information or device information from a third blockchain node; wherein the third blockchain is the blockchain preceding the first blockchain; the data management device calculating the event information or device information from the third blockchain node according to a preset hash algorithm to determine a third hash value; the data management device determining whether the second hash value and the third hash value are consistent; if they are inconsistent, the data management device determining that the event information or device information from the third blockchain node has been tampered with.
[0010] Secondly, embodiments of this application provide a data management device, which includes: an acquisition unit, configured to acquire first event information of a target device; the first event information being event information occurring during the lifecycle management of the target device; a processing unit, configured to calculate the first event information according to a preset hash algorithm and determine a first hash value of the first event information; the acquisition unit is further configured to acquire a second hash value of the target device; the second hash value being the hash value of the preceding event information of the first event information, or the second hash value being the hash value of device information of the target device; the processing unit is further configured to generate a first blockchain node based on the first event information, the first hash value, and the second hash value.
[0011] In conjunction with the second aspect above, in one possible implementation, when the first event information is the event information that occurs for the first time during the target device lifecycle management process, the second hash value is the hash value of the target device's device information; when the first event information is the event information that occurs for the Nth time during the target device lifecycle management process, the second hash value is the hash value of the event information that occurs for the (N-1)th time during the target device lifecycle management process; N is a positive integer greater than 2.
[0012] In conjunction with the second aspect above, in one possible implementation, the acquisition unit is further configured to acquire device information of the target device; the processing unit is further configured to calculate the hash value of the device information according to a preset hash algorithm to determine the second hash value of the target device; and the processing unit is further configured to generate a second blockchain node based on the device information and the second hash value.
[0013] In conjunction with the second aspect above, in one possible implementation, the acquisition unit is further configured to acquire a second hash value from the first blockchain node; the acquisition unit is further configured to acquire event information or device information from the third blockchain node; wherein the third blockchain is the blockchain preceding the first blockchain; the processing unit is further configured to calculate the event information or device information from the third blockchain node according to a preset hash algorithm, and determine a third hash value; the processing unit is further configured to determine whether the second hash value and the third hash value are consistent; the processing unit is further configured to determine, if they are inconsistent, that the event information or device information from the third blockchain node has been tampered with.
[0014] Thirdly, embodiments of this application provide a data management device, which includes a processor and a memory; wherein the memory is used to store computer execution instructions, and when the data management device is running, the processor executes the computer execution instructions stored in the memory to cause the data management device to perform the data management method as described in any possible implementation of the first aspect.
[0015] Fourthly, embodiments of this application provide a computer-readable storage medium storing instructions that, when executed by a processor of a data management device, enable the data management device to perform the data management method described in any possible implementation of the first aspect.
[0016] These or other aspects of this application will become more readily apparent in the following description.
[0017] The above solution offers at least the following advantages: In this embodiment, the data management device generates a first hash value based on the first event information occurring during the target device's lifecycle management. The data management device then generates a first blockchain node based on the first event information, the first hash value, and a second hash value. Since the second hash value is either the hash value of the event preceding the first event information, or the hash value of the target device's device information, the first blockchain node can store the second hash value of information from the preceding blockchain. When information in the preceding blockchain is tampered with, its corresponding hash value will necessarily differ from the second hash value stored in the first blockchain. Therefore, this embodiment can promptly detect whether the content in the blockchain has been tampered with, thereby enabling the management of data throughout the lifecycle of device resources and ensuring the validity of information generated during the cloud resource lifecycle. Attached Figure Description
[0018] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0019] Figure 1 This is a schematic diagram of the structure of a data management device provided in an embodiment of this application;
[0020] Figure 2 A flowchart illustrating a data management method provided in an embodiment of this application;
[0021] Figure 3 A flowchart illustrating yet another data management method provided in this application embodiment;
[0022] Figure 4 A flowchart illustrating yet another data management method provided in this application embodiment;
[0023] Figure 5 A schematic diagram of a data management system provided in an embodiment of this application;
[0024] Figure 6 This is a schematic diagram of another data management device provided in an embodiment of this application. Detailed Implementation
[0025] In this article, the term "and / or" is merely a description of the relationship between related objects, indicating that there can be three relationships. For example, A and / or B can represent three situations: A exists alone, A and B exist simultaneously, and B exists alone.
[0026] The terms "first" and "second," etc., used in the specification and drawings of this application are used to distinguish different objects or to distinguish different treatments of the same object, rather than to describe a specific order of objects.
[0027] Furthermore, the terms "comprising" and "having," and any variations thereof, used in the description 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 steps or units listed, but may optionally include other steps or units not listed, or may optionally include other steps or units inherent to such process, method, product, or apparatus.
[0028] It should be noted that in the embodiments of this application, the words "exemplary" or "for example" are used to indicate examples, illustrations, or explanations. Any embodiment or design scheme described as "exemplary" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or design schemes. Specifically, the use of the words "exemplary" or "for example" is intended to present the relevant concepts in a specific manner.
[0029] In the description of this application, unless otherwise stated, "a plurality of" means two or more.
[0030] The technical solutions of this application embodiment can be used in various communication systems, including third-generation partnership project (3GPP) communication systems, such as long-term evolution (LTE) systems, 5G mobile communication systems, NR systems, vehicle-to-everything (NR V2X) systems, LTE and 5G hybrid networking systems, device-to-device (D2D) communication systems, machine-to-machine (M2M) communication systems, Internet of Things (IoT) systems, and other next-generation communication systems. They can also be non-3GPP communication systems, without limitation.
[0031] The technical solutions of this application embodiment can be applied to various communication scenarios, such as one or more of the following communication scenarios: enhanced mobile broadband (eMBB), ultra-reliable low latency communication (URLLC), machine type communication (MTC), massive machine type communications (mMTC), SA, D2D, V2X, and IoT communication scenarios.
[0032] The communication systems and scenarios applicable to this application mentioned above are merely illustrative examples, and are not limited to these examples. This will be explained uniformly here and will not be repeated below.
[0033] In some embodiments, the terminal device involved in this application can be a device for implementing communication functions. The terminal device can also be referred to as user equipment (UE), terminal, access terminal, user unit, user station, mobile station (MS), remote station, remote terminal, mobile terminal (MT), user terminal, wireless communication device, user agent, or user device, etc. The terminal device can be, for example, a wireless terminal or wired terminal in IoT, V2X, D2D, M2M, 5G networks, or future evolved public land mobile networks (PLMNs). A wireless terminal can refer to a device with wireless transceiver capabilities, which can be deployed on land, including indoors or outdoors, handheld or vehicle-mounted; it can also be deployed on water (such as on ships); and it can also be deployed in the air (such as on airplanes, balloons, and satellites).
[0034] For example, terminal devices can be drones, IoT devices (e.g., sensors, electricity meters, water meters, etc.), V2X devices, stations (STs) in wireless local area networks (WLANs), cellular phones, cordless phones, session initiation protocol (SIP) phones, wireless local loop (WLL) stations, personal digital assistant (PDA) devices, handheld devices with wireless communication capabilities, computing devices or other processing devices connected to a wireless modem, in-vehicle devices, wearable devices (also known as wearable smart devices), tablets or computers with wireless transceiver capabilities, virtual reality (VR) terminals, wireless terminals in industrial control, wireless terminals in self-driving, wireless terminals in remote medical care, wireless terminals in smart grids, wireless terminals in transportation safety, wireless terminals in smart cities, and wireless terminals in smart homes. The terminal can be a wireless terminal in the home, an in-vehicle terminal, a vehicle with vehicle-to-vehicle (V2V) communication capability, an intelligent connected vehicle, or a drone with drone-to-UAV (U2U) communication capability, etc. The terminal can be mobile or fixed; this application does not specifically limit its location.
[0035] To implement the data management method provided in the embodiments of this application, this application provides a data management device for executing the data management method provided in the embodiments of this application. Figure 1 This is a schematic diagram of the structure of a data management device provided in an embodiment of this application. Figure 1 As shown, the data management device 100 includes at least one processor 101, a communication line 102, and at least one communication interface 104, and may also include a memory 103. The processor 101, memory 103, and communication interface 104 are connected via the communication line 102.
[0036] The processor 101 may be a central processing unit (CPU), an application-specific integrated circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of this application, such as one or more digital signal processors (DSPs), or one or more field-programmable gate arrays (FPGAs).
[0037] Communication line 102 may include a path for transmitting information between the aforementioned components.
[0038] The communication interface 104 is used to communicate with other devices or communication networks. It can use any transceiver-like device, such as Ethernet, radio access network (RAN), WLAN, etc.
[0039] The memory 103 may be a read-only memory (ROM) or other type of static storage device capable of storing static information and instructions, random access memory (RAM) or other type of dynamic storage device capable of storing information and instructions, or electrically erasable programmable read-only memory (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compressed optical discs, laser discs, optical discs, digital universal optical discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium capable of including or storing desired program code having the form of instructions or data structures and accessible by a computer, but not limited thereto.
[0040] In one possible design, the memory 103 can exist independently of the processor 101, meaning the memory 103 can be an external memory of the processor 101. In this case, the memory 103 can be connected to the processor 101 via a communication line 102 to store execution instructions or application code, and its execution is controlled by the processor 101 to implement the data management method provided in the following embodiments of this application. In another possible design, the memory 103 can also be integrated with the processor 101, meaning the memory 103 can be an internal memory of the processor 101. For example, the memory 103 can be a cache, which can be used to temporarily store some data and instruction information.
[0041] As one possible implementation, processor 101 may include one or more CPUs, for example Figure 1 CPU0 and CPU1 in the example. Alternatively, the data management device 100 may include multiple processors, such as CPU0 and CPU1. Figure 1 The processors 101 and 107 are included. Alternatively, the data management device 100 may also include an output device 105 and an input device 106.
[0042] In existing technologies, with the cloud-based deployment of 5G core networks and the continuous growth in the number of users, users will apply for and use various computing, storage, and network resources. As a result, the scale of the cloud resource pool providing services to users is also increasing, the operating environment is becoming more complex, and a large amount of cloud resource data is generated during the lifecycle.
[0043] Current cloud management platforms lack dedicated resource lifecycle management functions or modules. They typically record operation logs for resources, but these logs only record the operator, operation type, and time, failing to detail the resource's state before and after the operation, changes in resource attribute values, or the entire lifecycle of a resource from creation to destruction. This lack of a reliable system for later problem localization and accountability leads to management chaos. Therefore, managing data throughout the resource lifecycle and ensuring the validity of information generated during the cloud resource lifecycle remains an unresolved technical problem.
[0044] To address the technical problems existing in related technologies, this application provides a data management method. A data management device generates a first hash value based on first event information occurring during the lifecycle management of a target device. The data management device generates a first blockchain node based on the first event information, the first hash value, and a second hash value. Since the second hash value is either the hash value of the event preceding the first event information, or the hash value of the target device's device information, the first blockchain node can store the second hash value of information from the preceding blockchain. When information in the preceding blockchain is tampered with, its corresponding hash value will necessarily be different from the second hash value stored in the first blockchain. Therefore, this application can promptly detect whether the content in the blockchain has been tampered with, thereby achieving data management during the lifecycle of device resources and ensuring the validity of information generated during the cloud resource lifecycle. The following, in conjunction with the appendix... Figure 2 The data management method provided in the embodiments of this application will be described in detail, such as... Figure 2 As shown, the data management method includes:
[0045] S201, The data management device acquires the first event information of the target device.
[0046] The first event information refers to the event information that occurs during the lifecycle management of the target device.
[0047] Optional target devices include: servers, centralized storage, distributed storage, switches, firewalls, and routers.
[0048] Optionally, the first event information includes the event type, the time of occurrence, and the resource to which it belongs. Event types include: equipment uploading, equipment removal, equipment failure, and equipment alarm.
[0049] S202. The data management device calculates the first event information according to the preset hash algorithm and determines the first hash value of the first event information.
[0050] Optionally, the default hash algorithm includes the Advanced Encryption Standard (AES) encryption algorithm.
[0051] In one possible implementation, the data management device generates a plaintext string corresponding to the first event information based on the first event information, encrypts the plaintext string using the AES encryption algorithm, and determines the hash value of the encrypted string as the first hash value.
[0052] S203, The data management device obtains the second hash value of the target device.
[0053] The second hash value is either the hash value of the previous event information of the first event information, or the hash value of the device information of the target device.
[0054] In one possible implementation, if the first event information is the event information that occurs for the first time during the lifecycle management of the target device, the second hash value is the hash value of the device information of the target device.
[0055] In another possible implementation, if the first event information is the Nth event information occurring during the target device lifecycle management process, the second hash value is the hash value of the (N-1)th event information occurring during the target device lifecycle management process. Here, N is a positive integer greater than 2.
[0056] S204. The data management device generates a first blockchain node based on the first event information, the first hash value, and the second hash value.
[0057] In one possible implementation, the data management device sends a first hash value and a second hash value to a first blockchain node. The first blockchain node then receives and stores the first hash value and the second hash value.
[0058] The above solution offers at least the following advantages: In this embodiment, the data management device generates a first hash value based on the first event information occurring during the target device's lifecycle management. The data management device then generates a first blockchain node based on the first event information, the first hash value, and a second hash value. Since the second hash value is either the hash value of the event preceding the first event information, or the hash value of the target device's device information, the first blockchain node can store the second hash value of information from the preceding blockchain. When information in the preceding blockchain is tampered with, its corresponding hash value will necessarily differ from the second hash value stored in the first blockchain. Therefore, this embodiment can promptly detect whether the content in the blockchain has been tampered with, thereby enabling the management of data throughout the lifecycle of device resources and ensuring the validity of information generated during the cloud resource lifecycle.
[0059] In one possible implementation, prior to S203 above, the data management device generates a blockchain node corresponding to the target device. The process of the data management device generating the blockchain node corresponding to the target device is described below.
[0060] Combination Figure 2 ,like Figure 3 As shown, the process by which the data management device generates the blockchain node corresponding to the target device can be specifically implemented through the following steps S301-S303.
[0061] S301, The data management device acquires the device information of the target device.
[0062] Optional equipment information includes: equipment serial number, equipment manufacturer, and equipment installation date.
[0063] S302. The data management device calculates the hash value of the device information according to the preset hash algorithm and determines the second hash value of the target device.
[0064] In one possible implementation, the data management device generates a plaintext string corresponding to the device information of the target device based on the device information of the target device, encrypts the plaintext string using the AES encryption algorithm, and determines the hash value of the encrypted string as a second hash value.
[0065] S303, the data management device generates a second blockchain node based on the device information and the second hash value.
[0066] In one possible implementation, the data management device sends the second hash value to the second blockchain node. The second blockchain node then receives and stores the second hash value.
[0067] The above solution brings at least the following beneficial effects: In this embodiment of the application, the data management device generates a second blockchain node based on the device information and the second hash value. In this way, the data management device can establish a corresponding blockchain node based on the event information of the target device, thereby realizing the management of the life cycle of the target device.
[0068] In one possible implementation, after S204 above, the data management device monitors whether the information in the blockchain nodes has been tampered with. The process of the data management device monitoring whether the information in the blockchain nodes has been tampered with is described below.
[0069] Combination Figure 2 ,like Figure 4 As shown, the process by which the above-mentioned data management device monitors whether the information in the blockchain node has been tampered with can be specifically implemented through the following S401-S405.
[0070] S401, The data management device obtains the second hash value from the first blockchain node.
[0071] In one possible implementation, the information verification module in the data management device sends a first request message to the first blockchain node, the first request message being used to request the acquisition of a second hash value. The first blockchain node then sends a first response message to the information verification module, the first response message including the second hash value.
[0072] S402, The data management device obtains event information or device information from the third blockchain node.
[0073] The third blockchain is the blockchain preceding the first blockchain.
[0074] In one possible implementation, the information verification module in the data management device sends a second request message to the third blockchain node, the second request message being used to request the acquisition of event information or device information from the third blockchain node. The third blockchain node then sends a second response message to the information verification module, the second response message including the event information or device information from the third blockchain node.
[0075] S403. The data management device calculates the event information or device information in the third blockchain node according to the preset hash algorithm and determines the third hash value.
[0076] In one possible implementation, the data management device generates a plaintext string corresponding to the event information or device information in the third blockchain node based on the event information or device information in the third blockchain node, encrypts the plaintext string using the AES encryption algorithm, and determines the hash value of the encrypted string as a third hash value.
[0077] It needs to be explained that the data management device sends a third hash value to the third blockchain node, and the third blockchain node updates the third hash value to its own hash value.
[0078] S404, The data management device determines whether the second hash value and the third hash value are consistent.
[0079] In one possible implementation, the information verification module in the data management device determines whether the second hash value and the third hash value are consistent.
[0080] S405. If there is a discrepancy, the data management device determines that the event information or device information in the third blockchain node has been tampered with.
[0081] In one possible implementation, if there is a discrepancy, the alarm module in the data management device issues an alarm message, which is used to indicate that the event information or device information in the third blockchain node has been tampered with.
[0082] The above solution offers at least the following advantages: In this embodiment, the data management device calculates the event information or device information in the node of the preceding blockchain (third blockchain) of the first blockchain using a preset hash algorithm to determine the third hash value. Then, the data management device determines whether the second hash value and the third hash value in the first blockchain are consistent, thereby determining whether the information in the third blockchain has been tampered with. Thus, monitoring of the information in the blockchain nodes is achieved.
[0083] The following, in conjunction with the appendix Figure 5The data management system provided in the embodiments of this application will be described in detail, such as... Figure 5 As shown, the data management system includes: an uploading module 501, a monitoring module 502, an orchestration module 503, a maintenance module 504, a modification module 505, a scrapping module 506, a block generation module 507, an information storage module 508, an information verification module 509, an information query module 510, a node management module 511, a platform supervision module 512, and an alarm module 513.
[0084] The uploading module 501 is configured to: establish a blockchain node for the target device and save the device information of the target device to the blockchain node. It sends a first message to the blockchain node, which includes: the target device's arrival date, the target device's operating system type, the target device's serial number (SN), and the target device's component information, including the size, capacity, and manufacturer of the CPU, memory, and hard drive components.
[0085] Monitoring module 502 is configured to record cloud resource data from target devices deployed in the production phase to form monitoring event information. This monitoring information includes: status entry time and status change records.
[0086] The orchestration module 503 is configured to: save the event information of the target device to the corresponding blockchain node; and send a second message to the blockchain node, which includes: system name, system user, and system usage start and end times.
[0087] Maintenance module 504 is configured to generate maintenance event information from maintenance records of the target device. The maintenance information includes: maintenance record, maintenance personnel, and maintenance time.
[0088] Module 505 is configured to generate maintenance event information from change records of the target device. The change information includes: change type, person making the change, change time, and change details.
[0089] The scrapping module 506 is configured to generate maintenance event information for the scrapping records of the target equipment. The scrapping information includes: scrapping date, approval record, and handling measures.
[0090] The block generation module 507 is configured to generate blockchain nodes according to the instructions from the target modules. The target modules include: the listing module 501, the monitoring module 502, the maintenance module 504, the modification module 505, and the scrapping module 506.
[0091] The information storage module 508 is configured to receive instructions from the orchestration module 503 and save the device information or event information of the target device according to the instructions from the orchestration module 503.
[0092] The information verification module 509 is configured to: calculate the event information or device information in the third blockchain node according to the preset hash algorithm, determine the third hash value, and determine whether the second hash value and the third hash value are consistent.
[0093] The information query module 510 is configured to query the lifecycle of cloud resources of the target device in a visual manner.
[0094] Node management module 511 is configured to manage blockchain nodes.
[0095] The platform monitoring module 512 is configured to include transaction monitoring 5121, storage monitoring 5122, contract monitoring 5123, and network node monitoring 5124; if there are problems in the entire cloud resource lifecycle of the target device, an alarm instruction is sent to the alarm module 513.
[0096] Alarm module 513 is configured to generate alarm information based on the alarm instructions from platform monitoring module 512.
[0097] Transaction monitoring 5121 is configured to: view basic information about transaction execution based on smart contracts.
[0098] Storage monitoring 5122 is configured to monitor the storage ledger information of each node in the system and display a summary of the stored information.
[0099] Contract monitoring 5123 is configured to monitor smart contracts.
[0100] Network node monitoring 5124 is configured to display the real-time status information of each node on the platform and the network topology.
[0101] As can be seen, the above mainly describes the technical solutions provided by the embodiments of this application from a methodological perspective. To achieve the above functions, it includes hardware structures and / or software modules corresponding to the execution of each function. Those skilled in the art should readily recognize that, in conjunction with the modules and algorithm steps of the various examples described in the embodiments disclosed herein, the embodiments of this application can be implemented in hardware or a combination of hardware and computer software. Whether a function is executed in hardware or by computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this invention.
[0102] This application embodiment can divide the data management device into functional modules according to the above method example. For example, each function can be divided into its own functional modules, or two or more functions can be integrated into one processing module. The integrated module can be implemented in hardware or as a software functional module. Optionally, the module division in this application embodiment is illustrative and only represents one logical functional division; other division methods may be used in actual implementation.
[0103] like Figure 6 The diagram shown is a structural schematic of a data management device 60 provided in an embodiment of this application. The data management device 60 includes an acquisition unit 601 and a processing unit 602.
[0104] The acquisition unit 601 is used to acquire first event information of the target device; the first event information is event information that occurs during the lifecycle management of the target device; the processing unit 602 is used to calculate the first event information according to a preset hash algorithm and determine the first hash value of the first event information; the acquisition unit 601 is also used to acquire the second hash value of the target device; the second hash value is the hash value of the previous event information of the first event information, or the second hash value is the hash value of the device information of the target device; the processing unit 602 is also used to generate a first blockchain node according to the first event information, the first hash value, and the second hash value.
[0105] Optionally, if the first event information is the event information that occurs for the first time during the target device lifecycle management process, the second hash value is the hash value of the target device's device information; if the first event information is the event information that occurs for the Nth time during the target device lifecycle management process, the second hash value is the hash value of the event information that occurs for the (N-1)th time during the target device lifecycle management process; N is a positive integer greater than 2.
[0106] Optionally, the acquisition unit 601 is further configured to acquire device information of the target device; the processing unit 602 is further configured to calculate the hash value of the device information according to a preset hash algorithm, and determine the second hash value of the target device; the processing unit 602 is further configured to generate a second blockchain node according to the device information and the second hash value.
[0107] Optionally, the acquisition unit 601 is further configured to acquire the second hash value in the first blockchain node; the acquisition unit 601 is further configured to acquire event information or device information in the third blockchain node; wherein, the third blockchain is the blockchain preceding the first blockchain; the processing unit 602 is further configured to calculate the event information or device information in the third blockchain node according to a preset hash algorithm and determine the third hash value; the processing unit 602 is further configured to determine whether the second hash value and the third hash value are consistent; the processing unit 602 is further configured to determine that the event information or device information in the third blockchain node has been tampered with if they are inconsistent.
[0108] The processing unit can be a processor or a controller. It can implement or execute various exemplary logic blocks, modules, and circuits described in conjunction with the disclosure of this application. The processor can also be a combination of functions, such as a combination of one or more microprocessors, a combination of a DSP and a microprocessor, etc. The communication unit can be a transceiver circuit or a communication interface, etc. The storage module can be a memory. When the processing unit is a processor, the communication unit is a communication interface, and the storage module is a memory, the data management device involved in the embodiments of this application can be... Figure 1 The data management device shown.
[0109] Through the above description of the implementation methods, those skilled in the art will clearly understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In practical applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the network node can be divided into different functional modules to complete all or part of the functions described above. The specific working process of the system, modules, and network nodes described above can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0110] This application also provides a computer-readable storage medium storing instructions. When a computer executes these instructions, the computer performs each step of the method flow shown in the above-described method embodiments.
[0111] This application also provides a chip, which includes a processor and a communication interface. The communication interface and the processor are coupled together. The processor is used to run computer programs or instructions to implement the data management method described in the above method embodiments.
[0112] Embodiments of this application provide a computer program product containing instructions that, when executed on a computer, cause the computer to perform the data management method described in the above method embodiments.
[0113] The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of computer-readable storage media (a non-exhaustive list) include: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM), registers, hard disks, optical fibers, compact disc read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing, or any other form of computer-readable storage medium in the art. An exemplary storage medium is coupled to a processor, enabling the processor to read information from and write information to the storage medium. Of course, the storage medium may also be a component of the processor. The processor and the storage medium may reside in an application-specific integrated circuit (ASIC). In embodiments of the present invention, a computer-readable storage medium may be any tangible medium that contains or stores a program that may be used by or in conjunction with an instruction execution system, apparatus, or device.
[0114] Since the apparatus, device, computer-readable storage medium, and computer program product in the embodiments of the present invention can be applied to the above methods, the technical effects that can be obtained can also be referred to the above method embodiments. The embodiments of this application will not be repeated here.
[0115] The above are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A data management method, characterized in that, The method includes: Acquire first event information of the target device; the first event information is event information that occurs during the lifecycle management of the target device. The first event information is calculated according to a preset hash algorithm, and the first hash value of the first event information is determined. Obtain the second hash value of the target device; the second hash value is the hash value of the previous event information of the first event information, or the second hash value is the hash value of the device information of the target device; Based on the first event information, the first hash value, and the second hash value, a first blockchain node is generated; Wherein, the first event information is the event information that occurs for the first time during the lifecycle management of the target device, and before obtaining the second hash value of the target device, the method further includes: Obtain device information for the target device; Calculate the hash value of the device information according to the preset hash algorithm, and determine the second hash value of the target device; A second blockchain node is generated based on the device information and the second hash value; Wherein, if the first event information is the event information that occurs for the first time during the lifecycle management of the target device, the second hash value is the hash value of the device information of the target device; If the first event information is the Nth event information that occurs during the lifecycle management of the target device, the second hash value is the hash value of the (N-1)th event information that occurs during the lifecycle management of the target device; N is a positive integer greater than 2.
2. The method according to claim 1, characterized in that, The method further includes: Obtain the second hash value from the first blockchain node; Obtain event information or device information from a third blockchain node; wherein, the third blockchain is the blockchain preceding the first blockchain; The event information or device information in the third blockchain node is calculated according to the preset hash algorithm to determine the third hash value; Determine whether the second hash value and the third hash value are consistent; If there is a discrepancy, it is determined that the event information or device information in the third blockchain node has been tampered with.
3. A data management device, characterized in that, The device includes an acquisition unit and a processing unit: The acquisition unit is used to acquire first event information of the target device; the first event information is event information that occurs during the lifecycle management of the target device; The processing unit is configured to calculate the first event information according to a preset hash algorithm and determine the first hash value of the first event information. The acquisition unit is further configured to acquire a second hash value of the target device; The second hash value is the hash value of the previous event information of the first event information, or the second hash value is the hash value of the device information of the target device; The processing unit is further configured to generate a first blockchain node based on the first event information, the first hash value, and the second hash value; The acquisition unit is also used to acquire device information of the target device; The processing unit is further configured to calculate the hash value of the device information according to the preset hash algorithm, and determine the second hash value of the target device; The processing unit is further configured to generate a second blockchain node based on the device information and the second hash value; If the first event information is the event information that occurs for the first time during the lifecycle management of the target device, the second hash value is the hash value of the device information of the target device; If the first event information is the Nth event information that occurs during the lifecycle management of the target device, the second hash value is the hash value of the (N-1)th event information that occurs during the lifecycle management of the target device; N is a positive integer greater than 2.
4. The apparatus according to claim 3, characterized in that, The device further includes: The acquisition unit is further configured to acquire the second hash value in the first blockchain node; The acquisition unit is further configured to acquire event information or device information from a third blockchain node; wherein the third blockchain is the blockchain preceding the first blockchain; The processing unit is further configured to calculate the event information or device information in the third blockchain node according to the preset hash algorithm, and determine the third hash value; The processing unit is further configured to determine whether the second hash value and the third hash value are consistent; The processing unit is further configured to determine, if inconsistent, that the event information or device information in the third blockchain node has been tampered with.
5. A data management device, characterized in that, include: A processor and a memory; wherein the memory is used to store computer execution instructions, and when the data management device is running, the processor executes the computer execution instructions stored in the memory to cause the data management device to perform the data management method according to claim 1 or 2.
6. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes instructions that, when executed by a data management device, cause the computer to perform the data management method as described in claim 1 or 2.
Citation Information
Patent Citations
Method and system for validating a succession of events experienced by a device
CN102077177A
Method and device for supervising drug quality testing data
CN108629205A
Log management method based on block chain and related equipment
CN112989404A
