A data management system and method based on water resources blockchain
Through a data management system based on the water resource blockchain, water resource data can be collected and encrypted in real time, and partitioned and encrypted storage is performed on the blockchain, the security problem of data leakage in the water resource data management system is solved and the data is realized Strict protection and efficient management.
Patent Information
- Application Number
- CN202411346246.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-26
- Publication Date
- 2025-01-07
- Estimated Expiration
- 2044-09-26
AI Technical Summary
Existing water resource data management systems are difficult to ensure strict protection of data, resulting in data leakage that may pose a serious threat to national development and people's lives.
Adopt a data management system based on water resources blockchain, and use real-time collection of data from multiple sources for preprocessing and encryption, and partition encrypted storage on the blockchain. Combined with distributed ledger and key security management, dynamically adjusting the database in real time to ensure the security and integrity of the data.
Effectively prevent data leakage, ensure the confidentiality and integrity of water resource data, improve the security and efficiency of data management, and ensure the safety of national development and people's lives.
Smart Images

Figure CN118862133B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data management technology, and in particular to a data management system and method based on water resources blockchain. Background Art
[0002] Water resources are an important material resource for national development and people's lives, and my country is a country with relatively scarce water resources. Therefore, it is crucial to effectively manage water resource data. In traditional water resource data management systems, although data is usually encrypted and stored on the blockchain, ordinary encryption methods cannot ensure the strict protection of important data. Once these data are leaked, they may pose a serious threat to my country's future development and people's lives.
[0003] The present invention collects data from multiple sources in real time and performs preprocessing to obtain preprocessed data, which is then encrypted and uploaded to the blockchain for storage to obtain a database, thereby determining the direction of the next experimental operation.
[0004] The database is then supervised in sections to obtain supervision data; multiple block data are dynamically adjusted in real time based on the supervision data to update the database.
[0005] To sum up, how to strictly store and supervise water resource data is an issue that needs to be urgently solved and optimized in the data management system based on the water resource blockchain. Summary of the invention
[0006] The present invention provides a data management system and method based on water resources blockchain to solve the technical problem of how to strictly store and supervise water resources data in related technologies.
[0007] In order to solve the above technical problems, the present invention provides a data management system and method based on water resources blockchain. The specific technical solutions are as follows:
[0008] In the first aspect, a data management method based on water resources blockchain comprises the following steps:
[0009] Collect data from multiple sources in real time and pre-process them to obtain pre-processed data;
[0010] The pre-processed data is encrypted and uploaded to the blockchain for storage to obtain the database, which specifically includes: generating a key pair, encrypting the pre-processed data with the public key, and generating ciphertext data C T , and use the private key to encrypt the ciphertext data C T Decrypt to get the plaintext data M I; Then, transmit the encrypted preprocessed data to the blockchain for storage, further partition and encrypt the block data on the blockchain, and simultaneously perform key security management on the key;
[0011] Conduct partial supervision on the database to obtain supervision data;
[0012] Dynamically adjust multiple block data in real time according to the supervision data to update the database.
[0013] As a further optimization scheme of the present invention, collect various source data in real time and perform preprocessing to obtain preprocessed data, including:
[0014] Obtain water resource data from different sources through multiple channels, and set the collection frequency or collection conditions to obtain water resource data in real time;
[0015] Denoise the real-time obtained water resource data, remove data foreign object interference and pores to obtain complete data;
[0016] Standardize the complete data to obtain unified data.
[0017] As a further optimization scheme of the present invention, upload the encrypted preprocessed data to the blockchain for storage to obtain a database, including:
[0018] Construct a polynomial of the integer ring Z with coefficient q based on the collected preprocessed data as ; In the formula, n is the quadratic power of the polynomial ring, set the plaintext space as , and the ciphertext space as , where q is a prime number satisfying q = 1 mod 2n, t is the reduced plaintext polynomial coefficient, and t < q, x is a discrete Gaussian distribution number set, σ is the standard deviation, specifically including:
[0019] Randomly generate a private key s = sk ← x, sk ∈ R from the discrete Gaussian distribution t , and store the private key in the blockchain through key management for decrypting the ciphertext data C T to obtain the plaintext data M, respectively randomly sample from R q and the discrete Gaussian distribution to generate p 1 ∈R q , e ← x to generate the public key , where p 0 = -(p 1 ·sk + te), to generate a public-private key pair (sk, pk);
[0020] Encrypt the preprocessed data using the public key pk to obtain the ciphertext data C T as ; In the formula, m, u, g, f ∈ Rq ←x, and is the sampling base generated by random sampling in discrete Gaussian distribution;
[0021] Decrypt the plaintext data M using the private key sk I for ; In the formula, ; ; ; Among them, ct is the ciphertext factor, [0], [1] are the decryption digits;
[0022] The encrypted pre-processed data is uploaded to the blockchain for storage, and the pre-processed data is synchronously stored on multiple nodes using the distributed ledger in the blockchain, and distributed in the form of blocks, with each block associated with the previous block;
[0023] The data stored on the blockchain is further partitioned and encrypted to obtain partitioned encrypted data.
[0024] As a further optimization scheme of the present invention, the data stored on the blockchain is further encrypted in partitions to obtain partition encrypted data, including:
[0025] Based on sk∈R t , the plaintext space is , the ciphertext space is , then sk i ∈Sk,sk i For each group of subkeys, the mapping of its partition password is described as ; Among them, E and D are both F 2 n At the same time, E and D are inverse permutations of each other. E and D are also called subkey sk 1 The encryption and decryption functions below divide the data uploaded to the blockchain into N blocks, which are encrypted one by one through the encryption function E and iterated multiple times to obtain the key sk for each round. i , specifically including:
[0026] Set the number of rounds i = 1, 2, ..., r. When the input after i rounds of iterations is the output L of the previous round, i−1 and R i−1 ,pass: ; In the formula, T is the intermediate variable, L i and R i is the output of the i-th round, sk i is the iterative subkey, f is the round function ;
[0027] Based on the m sub-keys of N partitioned data after i rounds of iteration, key security management is further performed on the partition encryption.
[0028] As a further optimization scheme of the present invention, based on the m subkeys of N block data after i rounds of iteration, key security management is further performed on the partition encryption, including:
[0029] Pre-process the user identity, identity identifier HID and signature information to form an authentication set;
[0030] Read the user ID and identity identifier hid for the data to be obtained, through:
[0031] ; In the formula, ID is the user identity, Sign_Info is the signature information, when R=0, the private key needs to be regenerated; when R=sk, the private key is generated;
[0032] After the private key sk based on the user identity ID is verified, the signature information of the user identity ID is obtained, and the signature result is generated accordingly to perform signature verification on the signature information to output the signature result.
[0033] As a further optimization scheme of the present invention, after the private key sk of the user identity ID is verified, the signature information of the user identity ID is obtained, and the signature result is generated accordingly to perform signature verification on the signature information to output the signature result, including:
[0034] Generate a name or identity digital watermark based on the acquired user ID information;
[0035] Display individual disassembled strokes based on name or identity digital watermark;
[0036] When the user signs to verify his / her identity, he / she needs to match the given visible strokes when signing;
[0037] When each visible stroke corresponds to the user's signature, the identity verification is successful. Conversely, when one of the visible strokes cannot correspond to the user's signature, the identity verification fails.
[0038] As a further optimization scheme of the present invention, the database is supervised in sections to obtain supervision data, including:
[0039] Regulate each block of the blockchain database one by one and formulate a regulatory strategy;
[0040] Real-time monitoring of data collection and encrypted storage from various sources through regulatory strategies;
[0041] The encrypted stored data is then decrypted for verification and review.
[0042] As a further optimization scheme of the present invention, multiple block data are dynamically adjusted in real time according to the supervision data to update the database, including:
[0043] Migrate data from busy blocks to less loaded blocks to optimize data distribution;
[0044] Adjust the data source index structure according to the supervision results, and replace the original data in the database according to the real-time data obtained;
[0045] De-redundancy is performed on data storage locations, and the space occupied by data is rationally planned.
[0046] In a second aspect, the system provides an electronic device including a memory, a processor, and a data management method program based on the water resources blockchain stored in the memory and executable on the processor, wherein the data management method program based on the water resources blockchain implements the steps of the data management method based on the water resources blockchain when executed by the processor.
[0047] In the third aspect, a data management system based on water resources blockchain includes:
[0048] Data acquisition module: It is used to collect data from multiple sources in real time and perform preprocessing to obtain preprocessed data;
[0049] Blockchain storage module: It is used to encrypt the pre-processed data and upload it to the blockchain for storage to obtain the database;
[0050] Monitoring management module: It is used to monitor the database in sections to obtain monitoring data;
[0051] Dynamic adjustment module: It is used to dynamically adjust multiple block data in real time according to regulatory data to update the database.
[0052] The present invention has at least the following beneficial effects: the present invention collects data from multiple sources in real time and performs preprocessing to obtain preprocessed data, and then encrypts the preprocessed data and uploads it to the blockchain for storage to obtain a database. First, the collected water resource data is encrypted overall, and then the encrypted data is uploaded to the blockchain. Subsequently, the data of each block is encrypted one by one, and then multiple subkeys are generated after several rounds of iterations. Each subkey corresponds to a block of ciphertext data. At the same time, the key is securely managed, and an individual user-specific private key is generated through the user identity ID and identity information. The exclusive private key is owned by the main management personnel to view important data, and the user identity is further verified through the signature. After multi-level data encryption, the data of each block can be encrypted and protected, making my country's water resource data not easy to leak and more secure, thereby ensuring my country's future development and people's lives;
[0053] By conducting partial supervision on the database, supervision data can be obtained; multiple block data can be adjusted dynamically in real time according to the supervision data to update the database, so that the database can store various water resource data in an orderly manner, ensure efficient storage utilization, and facilitate real-time updating of water resource data, thereby improving the database's operating efficiency and data management capabilities. BRIEF DESCRIPTION OF THE DRAWINGS
[0054] Figure 1 It is a flow chart of a data management method based on water resources blockchain provided by an embodiment of the present invention;
[0055] Figure 2 This is a schematic diagram of a data management system based on water resources blockchain provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0056] The present application is further described in detail below in conjunction with the accompanying drawings. It is necessary to point out here that the following specific implementation methods are only used to further illustrate the present application and cannot be understood as limiting the scope of protection of the present application. Technical personnel in this field can make some non-essential improvements and adjustments to the present application based on the above application content.
[0057] A data management system and method based on water resources blockchain, the specific implementation is as follows:
[0058] like Figure 1 As shown, a data management method based on water resources blockchain includes the following steps:
[0059] Step 1, real-time collection of data from multiple sources and preprocessing to obtain preprocessed data;
[0060] Step 2: Encrypt the preprocessed data and upload it to the blockchain for storage to obtain the database, which specifically includes: generating a key pair, encrypting the preprocessed data with the public key, and generating ciphertext data C T , and use the private key to encrypt the ciphertext data C T Decrypt to get the plaintext data M I ; The encrypted pre-processed data is then transferred to the blockchain for storage, and the block data on the blockchain is further partitioned and encrypted, while the key is securely managed;
[0061] Step 3, conduct partial supervision on the database to obtain supervision data;
[0062] Step 4: Dynamically adjust multiple block data in real time based on regulatory data to update the database.
[0063] In a preferred embodiment of the present invention, in step 1, data related to water resources are collected in real time by means of sensors, remote sensing technology, monitoring equipment, manual sampling, etc. These data may include water quality monitoring, water volume measurement, water temperature changes, etc. When the collected data may contain noise, outliers or missing values, it is necessary to improve the quality of the data through preprocessing operations such as data cleaning, normalization, and standardization. Preprocessing ensures that the data is complete and accurate, removes interference factors, and makes subsequent encryption and storage more efficient. Through preprocessing, noise and anomalies in the data are eliminated, ensuring that the subsequently processed data has high accuracy and consistency, and the quality of the preprocessed data is higher. Subsequent encryption and storage operations can reduce the processing time of low-quality data and improve overall performance. Redundant or useless data can be removed during the preprocessing process, reducing the storage space occupied, while improving data processing efficiency.
[0064] Based on step 1, the preprocessed data is used in step 2 to generate a public key and a private key using an encryption algorithm. The public key is used to encrypt the data, and the private key is used to decrypt the data. This process ensures that the data remains confidential during transmission and storage. The preprocessed data is encrypted using the public key to generate ciphertext data (CT). This means that even if the data is intercepted, the attacker cannot obtain its content. When the data needs to be read, the ciphertext data is decrypted using the private key and restored to plaintext data (MI), ensuring that only authorized users can access the data. The encrypted data is uploaded to the blockchain for distributed storage. The blockchain uses a decentralized approach to ensure that data storage cannot be tampered with. The data on the blockchain is further encrypted in partitions to ensure the independence and security of data in different blocks. The key security management system is responsible for managing, distributing and storing the keys required for encryption and decryption to prevent the keys from being leaked or abused. Through encryption, the confidentiality of data during transmission and storage is ensured to prevent unauthorized access. At the same time, the distributed storage and tamper-proof characteristics of blockchain are utilized to ensure the integrity of data and prevent data from being tampered with during storage. Partitioning and encrypting block data increases the independence of each block data. Even if a block is attacked, the data of other blocks can still remain safe.
[0065] Based on the database formed in step 2, the block data on the database blockchain is defined according to the type and source of the data in step 3. Each block is supervised by a specific regulatory policy, and the access and storage of data are monitored in real time. Each block data in the database blockchain is independently supervised by using database firewalls, audit log systems, and automated compliance inspection tools. The tool automatically records all operations and detects abnormal behaviors. Through automated audit tools, data usage and operation logs of each partition are collected regularly or in real time, and regulatory reports are generated for subsequent analysis and adjustment. Through divisional supervision, data operations in each partition are strictly monitored to ensure that data operations comply with industry standards and regulatory requirements. Real-time monitoring and automated auditing can promptly detect and prevent illegal operations and reduce the risk of data leakage or illegal access. Data operations in different partitions have clear division of regulatory responsibilities, and management can understand the data usage of each partition in real time.
[0066] Finally, in step 4, the regulatory data is analyzed by the data analysis engine to identify performance bottlenecks, abnormal operations or changes in data requirements in the database. Based on the analysis results, the system generates a dynamic adjustment strategy. The adjustment strategy may include data migration, index optimization, and permission adjustment to cope with the dynamic needs of the database, automatically execute the adjustment strategy, and optimize and adjust the block data in the database in real time. This includes operations such as data migration from blocks with excessive load to blocks with lower load, index optimization, and data permission modification. After the adjustment, the database is evaluated and feedback is given. If further optimization needs are found, a new round of adjustments will be initiated to ensure that the database remains in the best state. Through dynamic adjustment, it can automatically optimize data distribution and query performance, reduce latency, and improve throughput, so that the database structure can be adjusted according to real-time needs to adapt to different loads and demand changes, ensuring that the database is always in an efficient state. During the dynamic adjustment process, the system ensures the consistency and integrity of the data through concurrency control and consistency checks to avoid data damage or loss caused by adjustments.
[0067] In a preferred embodiment of the present invention, the above step 1 further includes:
[0068] Step 11, obtaining water resource data from different sources through multiple channels, and setting the collection frequency or collection conditions to obtain water resource data in real time;
[0069] Step 12, denoising the water resources data acquired in real time and removing foreign interference and pores from the data to obtain complete data;
[0070] Step 13, standardize the complete data to obtain unified data.
[0071] In the embodiment of the present invention, water resources related data are obtained through multiple channels in step 11. These channels may include:
[0072] Sensor network: Sensors deployed in different water bodies such as reservoirs, rivers, and groundwater wells to monitor water quality (chemical composition of water), water quantity (water level, flow rate), temperature, and other indicators.
[0073] Remote sensing technology: Obtain relevant data on large areas of water, such as water changes, water surface temperature, etc., through satellites, drones or other remote sensors.
[0074] Manual sampling: Water samples are collected by professional technicians, especially for laboratory analysis for water quality monitoring, supplemented by historical records or existing database data provided by governments, scientific research institutions, etc.
[0075] Then, according to the specific monitoring needs and environmental conditions, set the collection frequency of different data types. When water quality monitoring needs to be carried out once an hour, and water level changes need to be collected at intervals of five minutes, under specific conditions (such as sudden weather events or abnormal changes), the collection frequency can be dynamically adjusted. Multi-channel data collection ensures multi-dimensional and all-round coverage of water resource data, and the data is more complete. Setting a suitable collection frequency ensures real-time update of data, which is suitable for monitoring needs in dynamic environments. The dynamic adjustment of collection conditions enables the system to increase the frequency of data collection in emergencies and ensure rapid response at critical moments.
[0076] During the data collection process in step 11, the sensor data may contain noise due to environmental and equipment reasons. Therefore, it is necessary to denoise the collected data in step 12 to reduce these interferences and make the data smoother and more realistic. By filtering out high-frequency noise, effective low-frequency signals (such as water level changes) are retained, and short-term fluctuations are smoothed by the average value of multiple data points to highlight long-term trends. Water resource monitoring equipment may sometimes be interfered by foreign objects (such as silt, floating objects) or sensor errors, resulting in abnormal spikes or abnormal readings in the data. These abnormal values are filtered out by setting reasonable upper and lower data thresholds and anomaly detection algorithms. Data may be discontinuous or missing due to sensor failures, communication interruptions, etc. Use interpolation algorithms (such as linear interpolation, spline interpolation) or historical data to fill in these missing data to ensure the integrity of the data. Infer the missing values through the linear changes of adjacent data points, and fit the curve through multiple data points to more accurately fill in the missing data. After removing noise and abnormal interference, the data is more accurate and reliable and can truly reflect the status of water resources. By filling in the missing data, the integrity of the data set is ensured, which helps the accuracy of subsequent analysis and prediction models, reduces erroneous data caused by outliers or equipment failures, and prevents misleading analysis and decision-making.
[0077] Finally, through step 13, data from different sensors or sources may have different formats, units, and structures. The standardization process first unifies the data format to ensure that all data has a consistent structure. For example, unifying the unit of water volume to cubic meters, the temperature to degrees Celsius, etc., mapping data of different scales to the range between 0 and 1, so that data from different sources has the same dimension, facilitating subsequent analysis and modeling. Then, perform mean zeroing and variance normalization on the data to ensure that data from different sources can be compared and processed under the same standard, especially suitable for scenarios requiring further statistical analysis. The timestamps of data collection may come from different time zones or devices. The standardization process will align the timestamps of all data to ensure that all data is analyzed in the same time dimension. For example, synchronize the time of sensors and remote sensing devices to accurately analyze the water resource status at a certain moment. Through the standardization process, data from different sources can be seamlessly combined, improving the consistency and comparability of the data. After normalization, the data is suitable for multi-dimensional analysis and modeling. Especially when using machine learning or prediction models, standardized data can improve the stability and accuracy of the models. Standardization ensures that all data uses the same unit and scale, reducing errors that may occur during the data conversion process.
[0078] In a preferred embodiment of the present invention, step 2 may include:
[0079] Step 21, construct a polynomial of the integer ring Z with coefficient q according to the preprocessed data collected, which is ; where n is the quadratic power of the polynomial ring, set the plaintext space as , and the ciphertext space is , where q is a prime number satisfying q = 1 mod 2n, t is the reduced plaintext polynomial coefficient, and t < q, x is a set of discrete Gaussian distribution numbers, and σ is the standard deviation;
[0080] Step 22, upload the preprocessed data after encryption operation to the blockchain for storage, and use the distributed ledger in the blockchain to synchronously store the preprocessed data on multiple nodes, and distribute it in the form of blocks, and each block is associated with the previous block;
[0081] Step 23, further partition and encrypt the data stored on the blockchain to obtain partition-encrypted data.
[0082] In the embodiment of the invention, encrypt the preprocessed data through step 21, specifically including:
[0083] Step 211, randomly generate a private key s = sk ← x, sk ∈ R from the discrete Gaussian distribution t , and store the private key in the blockchain through key management for decrypting the ciphertext data C T to obtain the plaintext data M, from R qAnd randomly sample from discrete Gaussian distribution to generate p 1 ∈R q ,e←x generates a public key , where p 0 =-(p 1 sk+te) to generate a public-private key pair (sk,pk);
[0084] Step 212: Encrypt the pre-processed data using the public key pk to obtain the ciphertext data C T for ; Where m,u,g,f∈R q ←x, and is the sampling base generated by random sampling in discrete Gaussian distribution;
[0085] Step 213, decrypt using the private key sk to obtain the plaintext data M I for ; In the formula, ; ; ; Among them, ct is the ciphertext factor, [0], [1] are the decryption digits.
[0086] Then, in step 22, the preprocessed data after the encryption operation in step 21 is uploaded to the blockchain for storage, and the preprocessed data is synchronously stored on multiple nodes using the distributed ledger in the blockchain, and distributed in the form of blocks, each block is associated with the previous block. Before uploading the preprocessed data to the blockchain, the data is first encrypted to ensure that the data remains confidential during the upload and storage process and prevent unauthorized access. The encrypted data is packaged into a transaction and uploaded to the blockchain network. In the blockchain network, data is packaged into a block. Each block usually contains multiple transactions (including encrypted data, timestamps, transaction hashes, etc.). The blockchain uses distributed ledger technology, that is, each node in the blockchain network saves a complete copy of the ledger. Whenever new data (i.e., new transactions) is added, all nodes will verify it through a consensus algorithm (such as PoW, PoS, etc.) to ensure the legitimacy and consistency of the data. After confirmation by the consensus mechanism, the data is synchronized to all nodes to ensure that each node stores the same copy of the data. Each block in the blockchain is associated with the previous block through a hash value to form a chain structure. The hash value in the block not only records the data of the current block, but also references the hash value of the previous block. This structure ensures the immutability of the data, because any data modification of the block will change the hash value of the entire chain, which will be detected by other nodes in the network. The chain structure and distributed storage of the blockchain ensure the security and immutability of the data. Once the data is stored in the blockchain, any attempt to tamper with the data will be immediately detected by other nodes, ensuring the integrity and credibility of the data. The distributed ledger stores the same copy of the data on multiple nodes, which enhances the fault tolerance and reliability of the system. Even if individual nodes fail, the data can still be fully retained in other nodes. Through encryption operations, even if the data on the blockchain is public, unauthorized people cannot read the data content, further improving the security of the data.
[0087] When the data on the blockchain is already encrypted, in order to further enhance the security of the data, especially to prevent the data from being leaked by some nodes under certain conditions, the stored data can be encrypted in partitions through step 23. Partition encryption refers to dividing the data in the blockchain into multiple blocks according to logical or physical characteristics, and applying different encryption keys to each block data. For example, each block data is encrypted using a unique symmetric key. The key is dynamically generated by the system and stored in a secure key management system. A pair of public and private keys can be assigned to each data group. The public key is used to encrypt the data, and the private key is used by the authorized party for decryption. Different keys are assigned to each block data, and the keys are securely stored and distributed through encryption key management. The use rights and life cycle of the key are strictly controlled to ensure that only authorized nodes or users can access and decrypt specific block data, and obtaining a block data key can only access and query the data of the corresponding block, while the others are encrypted. If more than two block keys are applied for access at the same time, the user identity needs to be verified and reviewed through the regulatory mechanism.
[0088] In order to prevent key leakage or cracking, the key management system can set up a regular rotation mechanism. Key rotation ensures that the encryption key will not be exposed to risks for a long time, and does not affect the access and use of data. The partitioned encrypted data continues to be stored in the blockchain, and each block of data has an independent key to decrypt and obtain the plaintext. Even if a block key is leaked, the data of other blocks remains safe, and the leakage of only one block is not enough to threaten the data of the entire water resources database, ensuring the segmented confidentiality of the data. Partition encryption can effectively prevent the overall data leakage risk caused by single-point key leakage. Through partition encryption, different access rights and encryption standards can be set for different data groups, thereby supporting more refined permission management and ensuring that only specific users or nodes can access specific data. Partition encryption effectively reduces the risk of centralized exposure of data by using independent keys. Especially in blockchain systems where multiple parties share data, this protection method is very applicable. The multi-level encryption and key management mechanism greatly reduces the risk of data leakage. Even if some blocks are attacked or leaked, the data of the overall system remains confidential.
[0089] In a preferred embodiment of the present invention, the above step 23 specifically includes: step 231, based on sk∈R t , the plaintext space is , the ciphertext space is , then sk i ∈Sk,sk i For each group of subkeys, the mapping of its partition password is described as ; Among them, E and D are both F 2 nAt the same time, E and D are inverse permutations of each other. E and D are also called subkey sk 1 The encryption and decryption functions below divide the data uploaded to the blockchain into N blocks, which are encrypted one by one through the encryption function E and iterated multiple times to obtain the key sk for each round. i , specifically including:
[0090] Step 232, set the number of rounds i = 1, 2, ..., r, when the input after i rounds of iterations is the output L of the previous round i−1 and R i−1 ,pass: ; In the formula, T is the intermediate variable, L i and R i is the output of the i-th round, sk i is the iterative subkey, f is the round function ;
[0091] Step 233: Based on the m subkeys of the N block data obtained after i rounds of iterations, key security management is further performed on the partition encryption.
[0092] In the embodiment of the invention, the possible existence of malicious users colluding with the server through false identity information to steal water resource plaintext data and corresponding ciphertext information specifically includes the following:
[0093] First, generate the master key K, which is responsible for protecting the security of sensitive data. After the master key K is generated, use: , where K(x) is a polynomial representing the key sharding, a 0 The key K is a constant term, a 1 , a 2 , …, a t-1 is a random coefficient, ensuring that only e shards can reconstruct the complete key, x is the node number corresponding to the shard, and t is a large prime number used for modular operations to ensure encryption security. The system uses threshold cryptography to divide it into n shards, denoted by K 1 , K 2 , …, K n , and set the minimum number of shards e required to recover the key, that is, only e shards are needed to reconstruct the complete key, and then the key shards distributed to each node are: ,where xi is the unique identifier assigned to node ,i;
[0094] To prevent the risk of long-term exposure of keys, the system uses a periodic key update mechanism. At regular intervals or under certain conditions, the system generates a new master key sk' and redistributes key shards:
[0095] ; sk' is the updated key, kseed ' is the new seed key, r' is the new random number.
[0096] In a preferred embodiment of the present invention, the above step 233 specifically includes:
[0097] Step 2331, pre-set the user identity, identity identifier hid and signature information to form an identity authentication set;
[0098] Step 2332, read the user ID and identity identifier hid for which data needs to be obtained, by: ; In the formula, ID is the user identity, Sign_Info is the signature information, when R=0, the private key needs to be regenerated; when R=sk, the private key is generated;
[0099] Step 2333, after verification based on the private key sk of the user identity ID, the signature information of the user identity ID is obtained, and the signature result is generated accordingly to perform signature verification on the signature information to output the signature result.
[0100] In the embodiment of the invention, identity information is collected from the user in advance through step 23331, which usually includes the user's identity ID (such as identity card number, social security number, account ID) and the unique identifier HID related to the identity. HID is a unique identifier, which may be the user's username, mobile phone number, or identity ID processed by a hash function. To ensure the uniqueness and privacy of the user's identity, the user is also required to provide signature information. This can be the user's digital signature key, behavioral signature (such as handwritten signature or biometrics) or a signature generated by a cryptographic digital signature algorithm (such as RSA or ECDSA). The signature information will serve as an important basis for subsequent identity authentication. The identity authentication set includes the user's identity ID, the identity identifier HID and the corresponding signature information. The system ensures that fast matching and verification can be performed during identity authentication by securely storing this information in the identity authentication set; through the combination of the HID identifier and the signature information, the system ensures the uniqueness of each user's identity, prevents forgery and identity fraud, and the user's signature information is generated by a digital signature algorithm, which provides an additional security layer to ensure that only authorized users can pass the identity authentication. The pre-generation of the identity authentication set enables the system to quickly extract and match user information in the subsequent identity authentication process, thereby improving the efficiency of identity authentication.
[0101] Then, in step 2332, when the user attempts to obtain data, the user's identity ID and identity identifier hid are read first. This information will be matched with the pre-stored identity authentication set to ensure that the requester is a legitimate user. Condition determination:
[0102] When R=0: r is a conditional variable used to control the private key generation process. When R=0, it may represent some abnormal situation or indicate that the private key has expired and will require the private key to be regenerated. At this time, the system will generate a new private key sk based on the user's identity ID or other security information. i ;
[0103] When R=sk: r is the current user's private key sk. When the user identity verification passes and R=sk, the system will continue to use the current private key, sk, for signature verification to avoid generating a new private key;
[0104] Private key generation: When r=0, the system generates a new private key sk through an encryption algorithm i ′. The generation formula can be expressed as: ; r′ is a new random number, Generate_Key is a private key generation algorithm, which generates a private key based on the user's identity ID and the new random number.
[0105] In a preferred embodiment of the present invention, the above step 2333 specifically includes:
[0106] Step 23331, generating a name or identity digital watermark based on the acquired user ID information;
[0107] Step 23332, displaying individual disassembled strokes according to the name or identity digital watermark;
[0108] Step 23333: When the user signs to verify his / her identity, he / she needs to match the given visible strokes when signing;
[0109] Step 23334: when each visible stroke corresponds to the user's signature, the identity verification is successful; otherwise, when one of the visible strokes cannot correspond to the user's signature, the identity verification fails.
[0110] In the embodiment of the invention, the unique ID of the user is obtained from the user identity database through step 23331. The ID is usually the user's personal information, such as an ID number, social security number or account ID. The user's ID is processed through an encryption algorithm or a hash function (such as SHA-256, etc.) to generate a unique digital watermark. The watermark is a special encrypted identifier based on the user's identity information, ensuring that each user corresponds to a unique watermark and will not disclose the user's specific identity information. The digital watermark is further converted into a visual representation of the user's name or the last six digits of the ID card, which will be used as part of the identity authentication. This mapping process may use a hash table or a specific encoding rule to make the digital watermark generated by each user unique, ensuring the uniqueness and accuracy of the identity authentication. The digital watermark generation process is based on an encryption algorithm to prevent the user's identity information from being directly exposed, thereby improving the security of the system. The watermark is generated based on the user's identity information and is associated with the user to ensure the personalization of the verification process and prevent identity forgery.
[0111] The name or identity feature generated in step 23331 is decomposed into strokes through step 23332. The last six digits of each user name or ID card are decomposed into independent strokes or elements (such as Chinese strokes, Latin letter lines and circles). These strokes or elements are converted into graphics or visual symbols, and these strokes or graphic symbols are matched with the identity information displayed in the digital watermark through specific mapping rules. Then the key watermark information is embedded in the stroke combination to ensure that these strokes have a logical association with the digital watermark, so as to become the basis for verification. When the verification information seen by the user is multiple strokes or symbols, these symbols are dynamically generated by the system and correspond to the digital watermark. These strokes have a certain degree of randomness and variability, so that the stroke combination may be different during each identity verification, which increases the security of the verification process. The decomposed strokes are dynamically generated based on the watermark, and the stroke combination displayed for each verification may be different, which increases the complexity and flexibility of identity verification and avoids the security risks caused by repeated use. The identity information and digital watermark are hidden in the strokes, so that the verification process has multiple security levels, which not only depends on the user's signature, but also depends on the accurate matching of the strokes.
[0112] Then, during the identity verification process in step 23333, the system requires the user to sign. The signature process is not only the user's free handwriting, but also requires the combination of the stroke symbols displayed by the system to integrate these strokes into the user's signature. When the user signs, he must accurately integrate these strokes into his signature according to the specific stroke combination displayed by the system. Each stroke displayed has a specific position and order, requiring the user to match according to the prompts of the system. If the user can correctly integrate all the strokes displayed by the system into the signature, the verification may pass. While the user is signing, the system uses image processing or handwriting recognition technology to detect in real time whether the strokes in the signature match the strokes displayed by the system. Then use the pattern recognition algorithm to identify the specific stroke shape and order in the signature to ensure that it is consistent with the strokes preset in the watermark. The user is required to integrate the verification method of the visible strokes into the signature, which increases the difficulty of signing, makes it more difficult to forge a signature, and improves the anti-counterfeiting of identity verification. Combined with the matching operation of the signature and the visible strokes, a double verification mechanism is provided, which further improves the security of identity verification. Through image recognition and stroke matching, the risk of simple signatures being misidentified or used is reduced, ensuring the accuracy of identity verification.
[0113] Finally, step 23334 is used to check each stroke that is displayed one by one to see if it is accurately matched in the user's signature. The matching algorithm determines its accuracy by comparing the shape, order, starting and ending positions of the strokes. The verification is considered successful only when all strokes match the user's signature. If all strokes are correctly matched, the system will feedback that the identity authentication is successful, allowing the user to continue with subsequent operations. If any stroke cannot be accurately matched to the user's signature, the system will immediately determine that the verification has failed, reject the user's access request, and require a retry. When the verification fails, the system can provide the user with an opportunity to retry, but the number of times is limited. The system may also initiate additional security measures after multiple failures, such as locking the account and requiring offline verification of identity by professionals to prevent malicious attacks or forgeries. Only when all strokes are correctly matched can the verification be passed, ensuring the strictness and accuracy of identity authentication and preventing impersonation or forgery. Due to the randomness and diversity of stroke combinations, even if an attacker knows some of the strokes, it is difficult to pass the verification through brute force or guessing. By verifying stroke by stroke, even if there are slight changes in the signature (such as differences in handwriting style), as long as the key strokes match, the verification can still be ensured to pass, providing a certain degree of fault tolerance.
[0114] In a preferred embodiment of the present invention, the above step 3 may include:
[0115] Step 31, supervise each block of the blockchain database one by one and formulate a supervision strategy;
[0116] Step 32, real-time monitoring of data collection information from various sources and encrypted storage through supervision strategies;
[0117] Step 33, verify and review by decrypting the encrypted stored data.
[0118] In an embodiment of the present invention, the blockchain database in step 2 is composed of multiple blocks, each of which contains several transactions or data records. In order to ensure the security and compliance of the data, each block is monitored and audited one by one through step 3. The supervision module checks the security of the block one by one by reading the metadata of the block (such as timestamp, hash value, number of transactions, etc.) and the specific data content in the block. According to the data type, source and sensitivity of different blocks, the system will formulate targeted supervision strategies. Supervision strategies may include data storage duration, encryption level, data access permission settings, smart contract rules on the blockchain, etc. These strategies are dynamic and can be adjusted according to the addition of new data, changes in data sensitivity, or updates to external regulations. Supervision strategies can be automatically generated and optimized by analyzing historical supervision data and trends using machine learning algorithms. These policies may be adjusted in real time based on the data usage patterns and security assessment results. Supervising blocks one by one makes data management more refined and can ensure that the data in each block meets the predetermined security and compliance requirements. Targeted supervision strategies can be formulated based on the type and source of the data to ensure stricter supervision of sensitive data, while appropriately relaxing requirements for non-sensitive data to improve management efficiency. As the amount of data increases or the external environment changes, the supervision strategy can be dynamically adjusted to ensure that the supervision process always meets the latest security and compliance standards.
[0119] According to the supervision strategy formulated in step 31, step 32 will monitor the data from different sources in real time. The data may come from sensors, manual input, remote monitoring equipment, etc. The monitoring system not only records the time, location and equipment of each data collection, but also detects the quality, completeness and accuracy of the data. An alarm will be issued immediately for data anomalies (such as sudden value jumps, data loss). After the data collection is completed and pre-processed, the data will be encrypted and stored in the blockchain. During the data encryption and storage process, the system checks in real time whether the encryption process meets the policy requirements, such as whether the encrypted data can be decrypted to obtain plain text and whether there are security risks in the management of encryption keys. After the encrypted data is uploaded to the blockchain, the system continues to monitor the data storage of each block in the blockchain to ensure that the data has not been tampered with. When any illegal operation or abnormal behavior is detected during the data collection or encryption process (such as data encryption failure, encrypted data cannot be decrypted normally, and the subkey corresponding to the block can decrypt multiple blocks at the same time), the administrator will be notified immediately and corresponding measures will be automatically taken, such as stopping data transmission or re-encrypting. Through real-time monitoring of the data collection process, the authenticity of the data source can be ensured and the risk of human error or malicious tampering can be reduced. Real-time monitoring of encrypted storage ensures that the data is encrypted before storage and follows the predetermined encryption standards to prevent data leakage or tampering during transmission. The system can promptly detect any anomalies or loopholes in the data collection and encryption process and automatically take remedial measures to ensure data security and integrity.
[0120] Finally, in step 33, when the data needs to be reviewed or verified, the system will use the private key stored in the secure key management system to decrypt the encrypted data stored in the blockchain. The decryption process is strictly managed according to permissions. Only authorized users or systems can obtain the key for decryption operations. The decrypted data needs to undergo multi-level verification and review. The review content includes:
[0121] Data integrity check: Use hash values to verify the decrypted data to ensure that the data has not been tampered with during storage.
[0122] Data consistency verification: Compare the decrypted data with the original collected data to ensure that the data remains consistent in each link of encryption, transmission, storage, and decryption, and is not lost or modified.
[0123] Compliance audit: Check whether the decrypted data complies with storage and usage specifications based on preset regulations and internal policies. For example, some sensitive data may require a specific confidentiality period or storage encryption standards, and the system will verify these standards.
[0124] Audit records: Each data decryption operation is recorded in the audit log, which records in detail the operation time, decryption personnel or system, decryption data type and other information to ensure that all decryption operations can be traced. Through hash verification and consistency check after decryption, the data is ensured to remain intact and not tampered with throughout the life cycle. Decryption audit ensures that the data meets regulatory and compliance requirements during storage and use, especially when processing sensitive data, to ensure that the system does not violate legal regulations. The audit log records all decryption and audit operations to ensure the transparency of data use and prevent unauthorized access or abuse.
[0125] In another preferred embodiment of the present invention, the above step 4 may include:
[0126] Step 41, migrate data from busy blocks to blocks with lower loads to optimize data distribution;
[0127] Step 42, adjusting the data source index structure according to the supervision results, and replacing the original data in the database according to the data obtained in real time;
[0128] Step 43, remove redundancy from the data storage location and rationally plan the space occupied by data.
[0129] In an embodiment of the present invention, the load of each block on the blockchain is monitored based on the supervision strategy of step 3, and the monitored indicators include the data storage capacity, access frequency (number of read and write operations), response time, etc. in the block. Blocks with excessive load may cause performance bottlenecks and affect the overall efficiency of the system. According to the monitoring data, it is determined which blocks are in a busy state (i.e., the data storage capacity is too large or the access frequency is too high) and which blocks are in a low-load state. In order to improve the performance of the system, it is necessary to migrate the data from the busy blocks to the blocks with lower loads. The data is migrated through step 41. During the migration process, part of the data in the busy blocks will be copied or moved to the low-load blocks through the scheduling mechanism. The migration process involves copying and transmitting the data and ensuring the consistency of the data during the migration process. In order to avoid affecting the normal operation of the system, the migration process is usually run in the background and carried out in batches to reduce the impact on the real-time operation of the system. In order to ensure data consistency, the system adopts a distributed transaction or lock mechanism to prevent data conflicts or losses during the migration process. After the migration is completed, the system will verify the data in the new location to ensure data integrity. By migrating data from busy blocks to blocks with lower loads, the load pressure on busy blocks is reduced, and the response speed and overall performance of the system are improved. The migration operation effectively avoids performance bottlenecks caused by excessive loads on some blocks, maintains the smooth operation of the system, and reasonably allocates data storage locations, so that the storage resources of the blockchain are used more evenly and the waste of storage space is reduced.
[0130] Through step 3, the data stored in the blockchain is continuously supervised and monitored, and statistical information on data access frequency, query patterns, and data changes is collected to obtain supervision results. The supervision results provide useful information about which data is frequently accessed and which data access patterns have changed. Based on the analysis of the supervision results, the index structure in the blockchain is optimized through step 42. Indexes are used to speed up data retrieval, and frequently accessed data usually requires a more efficient index structure. The system can select appropriate index types based on access patterns, such as B-tree indexes, hash indexes, inverted indexes, etc., and dynamically adjust the index hierarchy and structure according to data changes. When the real-time collected data changes the original data in the database, the system will replace or update the old data according to the latest data. For example, new sensor data will replace previous old data. The system uses transaction control to ensure that no data loss or conflict occurs during data replacement, while ensuring data consistency and integrity. As data is replaced, the system will regenerate or adjust indexes based on new data to ensure that new data can be quickly retrieved and maintain database efficiency. By dynamically adjusting the index structure based on data usage, the speed of data retrieval can be significantly improved, database performance can be optimized, and old data can be replaced in real time to ensure that the database always stores the latest and most accurate water resources data, supporting more accurate analysis and decision-making. Through automated index adjustment and data replacement, the system can adaptively optimize the data structure without manual intervention, reducing maintenance costs.
[0131] Finally, in step 43, redundant data in blockchain storage is identified by using a data deduplication algorithm or redundancy detection tool. Redundant data usually refers to duplicate copies of the same data, old versions of data that have not been cleaned up in time, or unnecessary log files. Once redundant data is detected, the system will take deduplication operations. This can reduce the waste of storage space by deleting completely duplicate copies of data, or optimize storage through methods such as data compression and data deduplication technology (such as MD5 or SHA-256 checksum comparison). According to the deduplication data, the system will reasonably plan the storage space of the data. By analyzing the access frequency and size of the data, the system can store frequently used data on faster storage media (such as SSD), and store infrequently accessed data on slower but larger capacity media (such as HDD). The system can also adopt a tiered storage strategy to ensure efficient use of storage resources. The system will regularly perform storage cleanup work, delete or archive data that has not been accessed for a long time, and reduce storage space occupancy. For some infrequently accessed data, the system can compress and store it to further save space. By removing redundant data and rationally planning data storage locations, the storage space occupancy is significantly reduced, and hardware costs are reduced. The optimized storage space improves data access speed, especially through tiered storage. Frequently accessed data can respond to query requests more quickly. By rationally planning data storage space, the system can better cope with the growth of data volume, enhancing the system's scalability and sustainable operation capabilities.
[0132] like Figure 2 As shown, a data management system based on water resources blockchain includes:
[0133] Data collection module 201: Data collection module: It is used to collect data from multiple sources in real time and perform preprocessing to obtain preprocessed data;
[0134] Blockchain storage module 202: used to encrypt the pre-processed data and upload it to the blockchain for storage to obtain a database;
[0135] Monitoring management module 203: used to monitor the database in sections to obtain monitoring data;
[0136] Dynamic adjustment module 204: It is used to dynamically adjust multiple block data in real time according to the supervision data to update the database.
[0137] An embodiment of the present invention further provides an electronic device according to a data management system and method based on water resources blockchain, including a memory, a processor, and a data management method program based on water resources blockchain stored in the memory and executable on the processor. When the data management method program based on water resources blockchain is executed by the processor, the steps of the data management method based on water resources blockchain are implemented. All implementation methods in the above method embodiments are applicable to this embodiment and can achieve the same technical effect.
[0138] Those skilled in the art will also appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the present invention.
[0139] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0140] In the embodiments provided by the present invention, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0141] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0142] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0143] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as USB flash drives, mobile hard disks, ROM, RAM, magnetic disks, or optical disks.
[0144] In addition, it should be pointed out that in the apparatus and method of the present invention, it is obvious that each component or each step can be decomposed and / or recombined. These decompositions and / or recombinations should be regarded as equivalent schemes of the present invention. Moreover, the steps of performing the above series of processing can naturally be performed in chronological order according to the order of description, but it is not necessary to perform them in chronological order, and some steps can be performed in parallel or independently of each other. For those of ordinary skill in the art, it can be understood that all or any steps or components of the method and apparatus of the present invention can be implemented in hardware, firmware, software or a combination thereof in any computing device (including processors, storage media, etc.) or a network of computing devices, which can be achieved by those of ordinary skill in the art using basic programming skills after reading the description of the present invention.
[0145] Therefore, the purpose of the present invention can also be achieved by running a program or a group of programs on any computing device. The computing device can be a well-known general device. Therefore, the purpose of the present invention can also be achieved by simply providing a program product containing a program code that implements the method or device. That is to say, such a program product also constitutes the present invention, and the storage medium storing such a program product also constitutes the present invention. Obviously, the storage medium can be any well-known storage medium or any storage medium developed in the future. It should also be pointed out that in the device and method of the present invention, it is obvious that each component or each step can be decomposed and / or recombined. These decompositions and / or recombinations should be regarded as equivalent schemes of the present invention. In addition, the steps of performing the above-mentioned series of processing can naturally be performed in chronological order according to the order of description, but it is not necessary to perform them in chronological order. Some steps can be performed in parallel or independently of each other.
[0146] The above describes an embodiment of the present invention, but this embodiment is not limited to the above-mentioned specific implementation mode. The above-mentioned specific implementation mode is merely illustrative and not restrictive. Under the guidance of this embodiment, ordinary technicians in this field can also make more forms of equivalent embodiments, all of which are within the protection of this embodiment.
[0147] The above-mentioned embodiments only express several implementation methods of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the scope of the present invention. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, which all belong to the protection scope of the present invention.
Claims
1. A data management method based on water resources blockchain, characterized in that: The following steps are involved: Collect data from multiple sources in real time and pre-process them to obtain pre-processed data; Encrypt the preprocessed data and upload it to the blockchain for storage to obtain a database; generate a key pair F2 n Encrypt the preprocessed data to generate ciphertext data, and decrypt the ciphertext data using the private key sk to obtain plaintext data; among them, the polynomial of the integer ring Z with coefficient Q is constructed according to the collected preprocessed data as ; in the formula, n is the quadratic power of the polynomial ring, Z Q is the integer ring with Q coefficient, and the plaintext space is set as , the ciphertext space is , to encrypt the preprocessed data, where q is a prime number satisfying q = 1 mod 2n, t is the reduced plaintext polynomial coefficient, and t < q, x is a discrete Gaussian distribution number set, Z t is the integer ring of the reduced plaintext polynomial coefficient, F q is the ciphertext base ring F with q coefficient in the ciphertext space, and [] is the number set index symbol; The encrypted pre-processed data is transferred to the blockchain for storage, and the block data on the blockchain is further partitioned and encrypted; the pre-processed data uploaded to the blockchain is divided into N block data, which are encrypted one by one through the encryption function E and undergo multiple rounds of iterations to obtain the sub-keys sk of multiple decryption functions D. i , based on the plaintext space , the ciphertext space is , set the total key Sk∈R t , then sk i ∈Sk,sk i is the partition subkey, and its partition password mapping is described as ; Among them, E and D are both key pairs F2 n permutation on, and E and D are inverse permutations of each other, and E and D are subkeys sk i The encryption and decryption functions below; Among them, the pre-processed data is encrypted and uploaded to the blockchain for storage to obtain the database, which also includes: The pre-processed data after encryption is uploaded to the blockchain for storage, and the pre-processed data is synchronously stored on multiple nodes using the distributed ledger in the blockchain, and distributed in the form of blocks, each block is associated with the previous block to obtain multiple partitioned data; Further partition-encrypting the plurality of partition data to obtain partition-encrypted data; The step of further partition-encrypting the plurality of partition data to obtain partition-encrypted data includes: Set the number of iterations i = 1, 2, ..., r. When the input after i iterations is the output of the previous round, and ,pass: ; To obtain the sub-key after multiple rounds of iterations, where T is the intermediate variable, L i and R i is the output of the i-th round, sk i is the subkey, f is the round function ; Based on the m sub-keys of the N block data after i rounds of iteration, key security management is performed for partition encryption; Among them, based on the m subkeys of the N block data after i rounds of iterations, the partition encryption key security management is performed, including: The user identity, identity identifier HID and signature information are pre-assembled to form an authentication set; Read the user ID and identity identifier hid for the data to be obtained, through: ; In the formula, ID is the user identity, Sign_Info is the signature information, and R is the conditional variable used to control the private key generation process. When R=0, it means that one of the data items in the conditional variable has an abnormal situation or the private key has expired, and the private key needs to be regenerated; when R=sk, the private key is generated; After the user ID is verified by the private key sk, the signature information of the user ID is obtained, and the signature information is verified with the corresponding generated signature result, and the signature result is output; Among them, after the user identity ID is verified by the private key sk, the user identity ID signature information is obtained, and the signature information is signed and verified according to the corresponding generated signature result, and the signature result is output, including: Generate a name or identity digital watermark based on the acquired user ID information; Displaying individual disassembled strokes according to the name or identity digital watermark; When the user signs to verify his / her identity, he / she needs to match the given visible strokes when signing; When each visible stroke corresponds to the user's signature, the identity verification is successful. Conversely, when one of the visible strokes cannot correspond to the user's signature, the identity verification fails. Conducting segmented supervision of databases to obtain regulatory data; The data of multiple blocks are dynamically adjusted in real time according to the regulatory data to update the database.
2. According to a data management method based on water resources blockchain according to claim 1, it is characterized in that: Collect data from multiple sources in real time and pre-process them to obtain pre-processed data, including: Obtain water resource data from different sources through multiple channels and set the collection frequency or collection conditions to obtain water resource data in real time; De-noise the water resources data acquired in real time and remove foreign interference and pores in the data to obtain complete data; The complete data is standardized to obtain uniform data.
3. According to a data management method based on water resources blockchain according to claim 2, it is characterized in that: Conduct segmented supervision of the database to obtain regulatory data, including: Regulate each block of the blockchain database one by one and formulate a regulatory strategy; Real-time monitoring of data collection and encrypted storage from various sources through regulatory strategies; Verify and audit by decrypting encrypted stored data.
4. According to a data management method based on water resources blockchain according to claim 3, it is characterized in that: Dynamically adjust multiple block data in real time based on regulatory data to update the database, including: Migrate data from busy blocks to less loaded blocks to optimize data distribution; Adjust the data source index structure according to the supervision results, and replace the original data in the database according to the real-time data obtained; De-redundancy is performed on data storage locations, and the space occupied by data is rationally planned.
5. A data management system based on water resources blockchain, characterized in that: The system sets up an electronic device including a memory, a processor, and a data management method program based on water resources blockchain stored in the memory and executable on the processor. When the data management method program based on water resources blockchain is executed by the processor, the steps of the data management method based on water resources blockchain as described in any one of claims 1-4 are implemented.
6. A data management system based on water resources blockchain according to claim 5, characterized in that: The system includes: Data acquisition module: It is used to collect data from multiple sources in real time and perform preprocessing to obtain preprocessed data; Blockchain storage module: It is used to encrypt the pre-processed data and upload it to the blockchain for storage to obtain the database; Monitoring management module: It is used to monitor the database in sections to obtain monitoring data; Dynamic adjustment module: It is used to dynamically adjust multiple block data in real time according to regulatory data to update the database.
Citation Information
Patent Citations
Internet of things block chain authentication method and system based on ring signature consensus mechanism
CN115811406A
Intelligent safety water meter encryption method and system based on homomorphic encryption
CN116566578A