High-credibility data filtering method
Through the combined technology of hash tree and digital signature, it solves the hash collision problem, provides powerful data integrity verification, ensures the security and reliability of data transmission, responds to hash collision attacks and reduces the risk of tampering.
Patent Information
- Application Number
- CN202410733593.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-07
- Publication Date
- 2024-10-11
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Modern hash functions may collide, and attackers can create malicious data with the same hash value, affecting the integrity verification of the data. It is difficult for existing technology to effectively deal with hash collision attacks.
Using the combined technology of hash tree and digital signature, the hash value is generated by dividing the data into multiple blocks, the hash tree is constructed, and the root hash value of the hash tree is digitally signed using the sender's private key, and the transmission is encrypted , the receiver uses the public key to verify the signature and recalculate the hash value to ensure data integrity.
Provides a powerful data integrity verification mechanism, which can effectively deal with hash collision attacks and ensure the security and reliability of data during transmission. Even if the attacker modifies the data and the signature verification fails, the tampering behavior can be immediately discovered, reducing hash collisions. risks and improve the security of data transmission.
Smart Images

Figure CN118764223A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of data processing, and in particular to a high-credibility data filtering method. Background Art
[0002] High-credibility data filtering refers to the screening and filtering of various forms of data such as text, images, videos, audio, etc. uploaded and transmitted on the Internet through various technical means and algorithms to ensure the credibility and authenticity of the data. This filtering can help users avoid receiving false information, bad content or fraudulent information, protect personal privacy and security, and maintain the health and order of the network environment. Through high-credibility data filtering, users' trust in Internet content can be effectively improved, the spread of false and harmful information can be reduced, and a safer and healthier network environment can be provided for users. In the filtering process of high-credibility data, hash functions are used to generate unique fingerprints of data, and hash values are compared at the receiving end to verify whether the data is complete. However, modern hash functions may collide (different input data generates the same hash value). If an attacker can create malicious data with the same hash value, this will affect the integrity verification of the data. Summary of the invention
[0003] In order to solve the above problems, the present invention provides a high-confidence data filtering method.
[0004] To achieve the above purpose, the technical solution adopted by the present invention is as follows:
[0005] The high-confidence data filtering method comprises the following steps:
[0006] Step 1: Divide the data into multiple data blocks;
[0007] Step 2: Generate a hash value for each data block and build a hash tree;
[0008] Step 3: Digitally sign the root hash value of the hash tree using the sender’s private key to ensure the authenticity and integrity of the data source;
[0009] Step 4: The data block, hash tree and digital signature are formed into a data packet and encrypted for transmission;
[0010] Step 5: The receiver decrypts the received data packet and extracts the data block, hash tree and signature value;
[0011] Step 6: Verify the signature of the root hash value using the sender’s public key;
[0012] Step 7: Recalculate the hash value of the received data block, build a hash tree, and compare it with the root hash value obtained by decryption to ensure data integrity. If they are equal, the data integrity verification passes.
[0013] Further: Step 1 comprises:
[0014] According to the total size of the data |D|, calculate the number of blocks n that need to be divided to determine the size B of each data block:
[0015]
[0016] in, Indicates rounding up;
[0017] Divide the data D into n data blocks according to the determined data block size B, each data block is denoted as d i , where i = 1, 2, ..., n:
[0018] D={d1,d2,...d n}
[0019] Among them, d i =D[(i-1)×B:i×B];
[0020] Each data block is numbered and metadata of the block number and total number of data blocks is added to ensure data block order and integrity:
[0021] d i ′ =(i,n,d i )
[0022] Among them, d i ′ It is a data block with number and total number information;
[0023] Store the divided data blocks in an array in order:
[0024] D ′ ={d ′ 1,d ′ 2,...,d ′ n}
[0025] Further: Step 2 comprises:
[0026] For each data block d with number and total information i ′ Generate hash value h i :
[0027] h i =H(d i ′ )
[0028] Where H represents the hash function, d i ′is a data block with number and total information, h i is the generated hash value;
[0029] The hash values of all data blocks are used as leaf nodes of the hash tree:
[0030] L={h1,h2,...,h n}
[0031] Among them, L represents the set of leaf nodes, h i For data block d i ′ The hash value of
[0032] Construct the non-leaf nodes of the hash tree layer by layer, and each layer of nodes is the hash value of the connection of the hash values of its child nodes; for each pair of adjacent hash values h i and h i+1 , calculate the hash value h of its parent node i,j :
[0033] h i,j =H(h i ‖h j )
[0034] Among them, || represents the connection operation, h i,j The parent node hash value generated by the hash values of the two child nodes;
[0035] If the number of nodes in the current layer is odd, the last node is copied once to ensure that the number of nodes in each layer is even:
[0036] If |L| is an odd number, then L←L∪{L |L|}
[0037] Repeat the construction of non-leaf nodes layer by layer until the root hash value h is finally generated. root :
[0038]
[0039] Among them, L new Represents the node set of the previous layer;
[0040] The root hash value h of the hash tree root It is the only node at the top level;
[0041] h root =L final [1]
[0042] Among them, L final is the node set of the final layer.
[0043] Further: Step 3 comprises:
[0044] The root hash value h of the hash tree root Generate summary:
[0045] Digest(h root )=H(h root )
[0046] Where H represents the summary hash function;
[0047] Prepare the sender's private key K private For digital signature, the private key K private Only the sender can access it;
[0048] Use the sender's private key K private Digitally sign the summary of the root hash value to generate signature S:
[0049]
[0050] in, Indicates the use of private key K private Perform digital signature operations;
[0051] Compare the generated digital signature S with the root hash value h root Package together and prepare for data transmission;
[0052] In the packaged data, the sender's public key K is attached public , so that the recipient can use the public key for signature verification.
[0053] Further: Step 4 includes:
[0054] The data block D' and the root hash value h of the hash tree root , digital signature S is packaged together;
[0055] Generate a symmetric key K sym Used to encrypt data packets to be transmitted;
[0056] Using the symmetric key K sym Symmetrically encrypt the data Data_to_Encrypt to generate ciphertext C:
[0057]
[0058] in, Indicates the use of symmetric key K sym Perform encryption operations;
[0059] Use the recipient's public key K recv_public For the symmetric key K sym Encrypt and generate the encrypted symmetric key K sym_enc :
[0060]
[0061] in, Indicates the use of the recipient's public key K recv_public Perform encryption operations;
[0062] The encrypted data packet C and the encrypted symmetric key K sym_enc Combined together to form the final data packet to be transmitted;
[0063] The final data packet is transmitted to the receiver through a secure channel.
[0064] Further: Step 5 comprises:
[0065] The receiver receives the transmitted data packet;
[0066] Use the recipient's private key K recv_private Decrypt the encrypted symmetric key K sym_enc , get the symmetric key K sym :
[0067]
[0068] in, Indicates the use of the recipient's private key K recv_private Perform decryption operations;
[0069] Use the decrypted symmetric key K sym Decrypt the encrypted data packet C and extract the original data packet Data_to_Encrypt:
[0070]
[0071] in, Indicates the use of symmetric key K sym Perform decryption operations;
[0072] Extract the data block D' and the root hash value h of the hash tree from the decrypted data packet Data_to_Encrypt root , digital signature S and sender's public key K public .
[0073] Further: Step 6 comprises:
[0074] Extract the sender's digital signature S and the sender's public key K from the decrypted data packet public :
[0075]
[0076] The root hash value h of the hash tree root Generate a digest to facilitate signature verification:
[0077] Digest(h root )=H(h root )
[0078] Where H represents the summary hash function;
[0079] Use the sender's public key K public Perform digital signature verification on the summary of the root hash value to confirm the legitimacy of the signature S:
[0080]
[0081] in, Indicates using the sender's public key K public Perform signature verification operation. True indicates that the signature verification is successful.
[0082] If the signature verification is successful, the authenticity of the data source is confirmed and the verification result is recorded:
[0083]
[0084] Otherwise, mark the data as untrustworthy:
[0085] Else authentic←False
[0086] Further: Step 7 comprises:
[0087] For each received data block d′ i Recalculate the hash value to get h′ i :
[0088] h′ i =H(d′ i )
[0089] Where H represents a hash function;
[0090] Use the recalculated hash value h′ i Build a hash tree, repeat the previous steps, and build the hash tree layer by layer until the root node:
[0091]
[0092] Where L′ represents the set of hash values of the recalculated data blocks;
[0093] Get the recalculated root hash value h′ from the constructed hash tree root :
[0094] h′ root=L′ final [1]
[0095] Among them, L′ final Represents the final layer node set of the constructed hash tree;
[0096] The root hash value h′ will be recalculated root And the root hash value h obtained by decryption root Make comparisons;
[0097] If the two are equal, the data integrity is verified and the data has not been tampered with:
[0098] Ifh′ root =h root than integrity←True
[0099] Otherwise, mark the data as incomplete:
[0100] Else integrity←False
[0101] Compared with the prior art, the present invention has the following technical advances:
[0102] The present invention uses a hash tree and a digital signature, and the method provides a powerful data integrity verification mechanism. Even if an attacker can create malicious data with the same hash value, due to the existence of the digital signature, the receiver can still confirm the authenticity and integrity of the data by verifying the signature of the sender, thereby effectively responding to hash collision attacks. The present invention uses a digital signature to sign the root hash value of the hash tree, which can prevent the data from being tampered with during transmission. Even if the attacker can modify the data, due to the failure of signature verification, the receiver can immediately discover the tampering behavior of the data, ensuring the integrity and security of the data. The present invention can reduce the risk of hash collision by using block processing and encrypted transmission when constructing the hash tree. Even if the attacker can create malicious data with the same hash value, since the data has been processed in blocks and encrypted transmission, it is difficult for the attacker to tamper with the entire data, thereby reducing the possibility of hash collision attacks. The present invention transmits data by encrypting, and even if the data is intercepted during transmission, the content of the data cannot be obtained, thereby improving the security of data transmission. At the same time, the method of using public key encryption symmetric key ensures the security of the key, further enhancing the security of data transmission.
[0103] In summary, the present invention effectively solves the hash collision problem by comprehensively using technical means such as hash trees, digital signatures and encrypted transmission, and provides a powerful data integrity verification mechanism, thereby ensuring the security and reliability of data transmission. BRIEF DESCRIPTION OF THE DRAWINGS
[0104] The accompanying drawings are used to provide further understanding of the present invention and constitute a part of the specification. They are used to explain the present invention together with the embodiments of the present invention and do not constitute a limitation of the present invention.
[0105] In the attached picture:
[0106] Figure 1 It is a flow chart of the present invention. DETAILED DESCRIPTION
[0107] The following specific embodiments may be combined with each other, and the same or similar concepts or processes may not be described in detail in some embodiments. The embodiments of the present invention will be described below in conjunction with the accompanying drawings.
[0108] like Figure 1 As shown, the present invention discloses a high-confidence data filtering method, comprising:
[0109] Step 1: Divide the data into multiple data blocks.
[0110] Divide the data into multiple small pieces (data blocks), and process each small piece independently to facilitate subsequent verification, considering the size of the data, the size of the blocks, and how to number and store the blocks.
[0111] 1.1 Determine the block size:
[0112] First, determine the size B of each block (for example, 1MB), and calculate the number of blocks n that need to be divided according to the total size of the data |D|:
[0113]
[0114] in, Indicates rounding up.
[0115] 1.2 Data Blocking:
[0116] Divide the data D into n small blocks according to the determined block size B, each small block is denoted as d i (where i = 1, 2, ..., n):
[0117] D={d1,d2,...d n}
[0118] Among them, d i =D[(i-1)×B:i×B].
[0119] 1.3 Numbering and marking:
[0120] Each data block is numbered and metadata of the block number and total number of data blocks is added to ensure data block order and integrity:
[0121] di ′ =(i,n,d i )
[0122] Among them, d i ′ It is a data block with number and total number information.
[0123] 1.4 Block data storage:
[0124] Store the divided data blocks in an array or list to ensure that the divided data is stored in order for subsequent processing:
[0125] D ′ ={d ′ 1,d ′ 2,...,d ′ n}
[0126] Through the above steps, the data D can be divided into n small blocks d according to the block size B i , and add number and total number information to each small block to ensure that each small block can be processed independently, and lay the foundation for subsequent hash tree construction and data integrity verification.
[0127] Step 2: Generate a hash value for each data block and build a hash tree.
[0128] 2.1 Generate the hash value of the data block:
[0129] For each data block d with number and total information i ′ Generate hash value h i :
[0130] h i =H(d i ′ )
[0131] Where H represents the hash function, d i ′ is a data block with number and total information, h i The generated hash value.
[0132] 2.2 Construct the leaf nodes of the hash tree:
[0133] The hash values of all data blocks are used as leaf nodes of the hash tree:
[0134] L={h1,h2,...,h n}
[0135] Among them, L represents the set of leaf nodes, h i For data block d i′ The hash value of .
[0136] 2.3 Construct non-leaf nodes of the hash tree:
[0137] Construct the non-leaf nodes of the hash tree layer by layer. Each layer of nodes is the hash value of the connection of the hash values of its child nodes. For each pair of adjacent hash values h i and h i+1 , calculate the hash value h of its parent node i,j :
[0138] h i,j =H(h i ||h j )
[0139] Among them, || represents the connection operation, h i,j The parent node hash value generated by the hash values of the two child nodes.
[0140] 4. Processing an odd number of leaf nodes:
[0141] If the number of nodes in the current layer is odd, the last node is copied once to ensure that the number of nodes in each layer is even:
[0142] If |L| is an odd number, then L←L∪{L |L|}
[0143] 2.5 Iterate to generate upper nodes:
[0144] Repeat the construction of non-leaf nodes layer by layer until the root hash value h is finally generated. root :
[0145]
[0146] Among them, L new Represents the node set of the previous layer.
[0147] 2.6 Get the root hash value:
[0148] Finally, the root hash value of the hash tree is h root is the only node at the top level:
[0149] h root =L final [1]
[0150] Among them, L final It is the node set of the final layer, usually containing only one node.
[0151] Through the above steps, the hash value of the data block can be generated and the hash tree can be constructed. The root hash value of the hash tree is h rootIt can be used to efficiently verify the integrity of data and ensure that each data block has not been tampered with during transmission.
[0152] Step 3: The root hash value of the hash tree is digitally signed using the sender’s private key to ensure the authenticity and integrity of the data source.
[0153] The root hash value h of the hash tree root Digitally sign using the sender's private key to ensure the authenticity and integrity of the data source.
[0154] 3.1 Summary of generating root hash value:
[0155] The root hash value h of the hash tree root Generate a digest to ensure the signing process is efficient and secure:
[0156] Digest(h root )=H(h root )
[0157] Here, H represents the digest hash function.
[0158] 3.2 Signature key preparation:
[0159] Prepare the sender's private key K private For digital signature, private key K private It should be stored securely and accessible only to the sender.
[0160] 3.3 Generate digital signature:
[0161] Use the sender's private key K private Digitally sign the summary of the root hash value to generate signature S:
[0162]
[0163] in, Indicates the use of private key K private Perform digital signature operations.
[0164] 3.4 Signature and data packaging:
[0165] Compare the generated digital signature S with the root hash value h root Packaged together and ready for data transfer:
[0166] 3.5 Verification information additional:
[0167] In the packaged data, the sender's public key K is attached public , so that the recipient can use the public key for signature verification.
[0168] Through the above steps, the sender's private key can be used to calculate the root hash value h of the hash tree.root Digital signature S and the sender's public key K public They are packaged together for transmission to ensure the authenticity and integrity of the data source and prevent the data from being tampered with during transmission.
[0169] Step 4: The data block, hash tree and digital signature are formed into a data packet and encrypted for transmission.
[0170] 4.1 Prepare data to be encrypted:
[0171] The data block D' and the root hash value h of the hash tree root , digital signature S is packaged together.
[0172] 4.2 Generate symmetric key:
[0173] Generate a symmetric key K sym Used to encrypt the data packet to be transmitted, the symmetric key K sym Generated using a secure random number generator.
[0174] 4.3 Symmetrically encrypt the data packet:
[0175] Use symmetric key\K sym Symmetrically encrypt the data Data_to_Encrypt to generate ciphertext C:
[0176]
[0177] in, Indicates the use of symmetric key K sym Perform encryption operations.
[0178] 4.4 Symmetric Key Encryption:
[0179] Use the recipient's public key K recv_public For the symmetric key K sym Encrypt and generate the encrypted symmetric key K sym_enc :
[0180]
[0181] in, Indicates the use of the recipient's public key K recv_public Perform encryption operations.
[0182] 4.5 Prepare the final data package:
[0183] The encrypted data packet C and the encrypted symmetric key K sym_enc Combined together to form the final data packet to be transmitted.
[0184] 4.6 Data Packet Transmission:
[0185] The final data packet is transmitted to the recipient through a secure channel to ensure that the data is not tampered with during transmission.
[0186] Through the above steps, the block data, the root hash value of the hash tree, the digital signature and other metadata can be encrypted and transmitted. First, the data packet is encrypted using symmetric encryption, and then the symmetric key is encrypted using the public key of the recipient to ensure the security and integrity of the data during transmission.
[0187] Step 5: The receiver decrypts the received data packet and extracts the data block, hash tree and signature value.
[0188] 5.1 Receiving data packets:
[0189] The receiver receives the transmitted data packet, which contains the encrypted data packet C and the encrypted symmetric key K sym_enc :
[0190] 5.2 Decrypt the symmetric key:
[0191] Use the recipient's private key K recv_private Decrypt the encrypted symmetric key K sym_enc , get the symmetric key K sym :
[0192]
[0193] in, Indicates the use of the recipient's private key K recv_private Perform decryption operations.
[0194] 5.3 Decrypted data packet:
[0195] Use the decrypted symmetric key K sym Decrypt the encrypted data packet C and extract the original data packet Data_to_Encrypt:
[0196]
[0197] in, Indicates the use of symmetric key K sym Perform decryption operations.
[0198] 5.4 Extract data:
[0199] Extract the block data D' and the root hash value h of the hash tree from the decrypted data packet Data_to_Encrypt root , digital signature S and sender's public key K public .
[0200] Through the above steps, the receiver effectively decrypts the received data packet and extracts the block data, the root hash value of the hash tree, the digital signature and the sender's public key. This process ensures that the data has not been tampered with during transmission, laying the foundation for subsequent data integrity and authenticity verification.
[0201] Step 6: Verify the signature of the root hash using the sender’s public key.
[0202] 6.1 Extract signature and public key:
[0203] Extract the sender's digital signature S and the sender's public key K from the decrypted data packet public :
[0204]
[0205] 6.2 Generate a summary of the root hash value:
[0206] The root hash value h of the hash tree root Generate a digest to facilitate signature verification:
[0207] Digest(h root )=H(h root )
[0208] Here, H represents the digest hash function.
[0209] 6.3 Verify digital signature:
[0210] Use the sender's public key K public Perform digital signature verification on the summary of the root hash value to confirm the legitimacy of the signature S:
[0211]
[0212] in, Indicates using the sender's public key K public Perform signature verification. True indicates that the signature verification is successful.
[0213] 6.4 Verification result processing:
[0214]
[0215] Otherwise, mark the data as untrustworthy:
[0216] Else authentic←False
[0217] Through the above steps, the receiver uses the sender's public key K public The root hash value h of the hash tree rootThe digital signature S is verified. If the verification is successful, the authenticity of the data source is confirmed and it is ensured that the data has not been tampered with during transmission.
[0218] Step 7: Recalculate the hash value of the received data block, build a hash tree, and compare it with the root hash value obtained by decryption to ensure data integrity. If they are equal, the data integrity verification passes.
[0219] 7.1 Recalculate the hash value of the block data:
[0220] For each received block data d′ i Recalculate the hash value to get h′ i :
[0221] h′ i =H(d′ i )
[0222] Here, H represents a hash function.
[0223] 7.2 Building a hash tree:
[0224] Use the recalculated hash value h′ i Build a hash tree, repeat the previous steps, and build the hash tree layer by layer until the root node:
[0225]
[0226] Wherein, L′ represents the set of hash values of the recalculated data blocks.
[0227] 7.3 Get the recalculated root hash value:
[0228] Get the recalculated root hash value h′ from the constructed hash tree root :
[0229] h′ root =L′ final [1]
[0230] Among them, L′ final Represents the final layer node set of the constructed hash tree, usually containing only one node.
[0231] 7.4 Compare with the decrypted root hash value:
[0232] The root hash value h′ will be recalculated root And the root hash value h obtained by decryption root Make a comparison.
[0233] If the two are equal, the data integrity is verified and the data has not been tampered with:
[0234] If h′root =h root than integrity←True
[0235] Otherwise, mark the data as incomplete:
[0236] Else integrity←False
[0237] Through the above steps, the receiver recalculates the hash value of the block data and builds a hash tree. root And the root hash value h obtained by decryption root Compare to ensure data integrity.
[0238] Finally, it should be noted that the above is only a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art can still modify the technical solutions described in the aforementioned embodiments or replace some of the technical features therein with equivalents. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the scope of protection of the claims of the present invention.
Claims
1. A high-confidence data filtering method, characterized in that: The steps include: Step 1: Divide the data into multiple data blocks; Step 2: Generate a hash value for each data block and build a hash tree; Step 3: Digitally sign the root hash value of the hash tree using the sender’s private key to ensure the authenticity and integrity of the data source; Step 4: The data block, hash tree and digital signature are formed into a data packet and encrypted for transmission; Step 5: The receiver decrypts the received data packet and extracts the data block, hash tree and signature value; Step 6: Verify the signature of the root hash value using the sender’s public key; Step 7: Recalculate the hash value of the received data block, build a hash tree, and compare it with the root hash value obtained by decryption to ensure data integrity. If they are equal, the data integrity verification passes.
2. The high-confidence data filtering method according to claim 1, characterized in that: The step 1 comprises: According to the total size of the data |D|, calculate the number of blocks n that need to be divided to determine the size B of each data block: in, Indicates rounding up; Divide the data D into n data blocks according to the determined data block size B, each data block is denoted as d i , where i = 1, 2, ..., n: D={d1,d2,...d n } Among them, d i =D[(i-1)×B:i×B]; Each data block is numbered and metadata of the block number and total number of data blocks is added to ensure data block order and integrity: d′ i =(i,n,d i ) Among them, d′ i It is a data block with number and total number information; Store the divided data blocks in an array in order: D′={d′1,d′2,...,d′ n }。 3. The high-confidence data filtering method according to claim 2, characterized in that: The step 2 comprises: For each data block d′ with number and total information i Generate hash value h i : h i =H(d′ i ) Where H represents the hash function, d′ i is a data block with number and total information, h i is the generated hash value; The hash values of all data blocks are used as leaf nodes of the hash tree: L={h1,h2,...,h n } Among them, L represents the set of leaf nodes, h i is the data block d′ i The hash value of Construct the non-leaf nodes of the hash tree layer by layer, and each layer of nodes is the hash value of the connection of the hash values of its child nodes; for each pair of adjacent hash values h i and h i+1 , calculate the hash value h of its parent node i,j : h i,j =H(h i ‖h j ) Among them, || represents the connection operation, h i,j The parent node hash value generated by the hash values of the two child nodes; If the number of nodes in the current layer is odd, the last node is copied once to ensure that the number of nodes in each layer is even: If |L| is an odd number, then L←L∪{L |L| } Repeat the construction of non-leaf nodes layer by layer until the root hash value h is finally generated. root : Among them, L new Represents the node set of the previous layer; The root hash value h of the hash tree root It is the only node at the top level; h root =L final [1] Among them, L final is the node set of the final layer.
4. The high-confidence data filtering method according to claim 3, characterized in that: The step 3 comprises: The root hash value h of the hash tree root Generate summary: Digest(h root )=H(h root ) Where H represents the summary hash function; Prepare the sender's private key K private For digital signature, the private key K private Only the sender can access it; Use the sender's private key K private Digitally sign the summary of the root hash value to generate signature S: in, Indicates the use of private key K private Perform digital signature operations; Compare the generated digital signature S with the root hash value h root Package together and prepare for data transmission; In the packaged data, the sender's public key K is attached public , so that the recipient can use the public key for signature verification.
5. The high-confidence data filtering method according to claim 4, characterized in that: The step 4 comprises: The data block D' and the root hash value h of the hash tree root , digital signature S is packaged together; Generate a symmetric key K sym Used to encrypt data packets to be transmitted; Using the symmetric key K sym Symmetrically encrypt the data Data_to_Encrypt to generate ciphertext C: in, Indicates the use of symmetric key K sym Perform encryption operations; Use the recipient's public key K recv_public For the symmetric key K sym Encrypt and generate the encrypted symmetric key K sym_enc : in, Indicates the use of the recipient's public key K recv_public Perform encryption operations; The encrypted data packet C and the encrypted symmetric key K sym_ebc Combined together to form the final data packet to be transmitted; The final data packet is transmitted to the receiver through a secure channel.
6. The high-confidence data filtering method according to claim 5, characterized in that: The step 5 comprises: The receiver receives the transmitted data packet; Use the recipient's private key K recv_private Decrypt the encrypted symmetric key K sym_enc , get the symmetric key K sym : in, Indicates the use of the recipient's private key K recv_private Perform decryption operations; Use the decrypted symmetric key K sym Decrypt the encrypted data packet C and extract the original data packet Data_to_Encrypt: in, Indicates the use of symmetric key K sym Perform decryption operations; Extract the data block D' and the root hash value h of the hash tree from the decrypted data packet Data_to_Encrypt root , digital signature S and sender's public key K public .
7. The high-confidence data filtering method according to claim 6, characterized in that: The step 6 comprises: Extract the sender's digital signature S and the sender's public key K from the decrypted data packet public : The root hash value h of the hash tree root Generate a digest to facilitate signature verification: Digest(h root )=H(h root ) Where H represents the summary hash function; Use the sender's public key K public Perform digital signature verification on the summary of the root hash value to confirm the legitimacy of the signature S: in, Indicates the use of the sender's public key K public Perform signature verification operation. True indicates that the signature verification is successful. If the signature verification is successful, the authenticity of the data source is confirmed and the verification result is recorded: Otherwise, mark the data as untrustworthy: Else authentic←False.
8. The high-confidence data filtering method according to claim 7, characterized in that: The step 7 comprises: For each received data block d′ i Recalculate the hash value to get h′ i : h′ i =H(d′ i ) Where H represents a hash function; Use the recalculated hash value h′ i Build a hash tree, repeat the previous steps, and build the hash tree layer by layer until the root node: Where L′ represents the set of hash values of the recalculated data blocks; Get the recalculated root hash value h′ from the constructed hash tree root : h' root =L′ final [1] Among them, L′ final Represents the final layer node set of the constructed hash tree; The root hash value h′ will be recalculated root And the root hash value h obtained by decryption root Make comparisons; If the two are equal, the data integrity is verified and the data has not been tampered with: If h′ root =h root than integrity←True Otherwise, mark the data as incomplete: Else integrity←False.
Citation Information
Patent Citations
Data encryption method and device
CN113067816A
Intelligent power distribution network data secure transmission method and system and storage medium
CN113259345A
Digital signature method, signature information verification method, related device and electronic equipment
CN113407976A
Tree-based document batch signature and signature verification method and system
CN114781007A
ADS-B data security authentication method based on tree chain mixing
CN116055065A
Cited By
Bill data integrity verification system and method
CN119030789A
Information interaction method based on deep learning
CN120455470A
Data integrity verification method and system based on label embedding and homomorphic encryption
CN120602238A
