Intelligent electronic seal anti-counterfeiting method, system and storage medium

By optimizing the division of hash encryption domains and retransmission data processing, the problem of high time and resource consumption in the electronic seal encryption process is solved, and efficient and secure data transmission is achieved.

CN118656852BActive Publication Date: 2024-10-29龙采科技集团有限责任公司
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411147267.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-21
Publication Date
2024-10-29
Estimated Expiration
2044-08-21

AI Technical Summary

Technical Problem

The use of electronic seals for encryption will greatly increase pre-processing time, resource consumption, and corresponding error repair issues, especially when processing large and complex data such as medical records.

Method used

By determining the necessity and retransmission of multiple hash encryption fields, merging similar paragraphs, calculating the difference and weight of hash values, optimizing the division of hash encryption fields and retransmitting data, thereby achieving efficient encrypted transmission.

Benefits of technology

It reduces the bandwidth consumption of encrypted transmission, improves the credibility and efficiency of encryption verification, reduces resource consumption, and improves the security and effectiveness of data transmission.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118656852B_ABST
    Figure CN118656852B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of data processing technology, and in particular to an intelligent electronic seal anti-counterfeiting method, system and storage medium, the method comprising: obtaining record data to be stamped; determining multiple matching hash encryption domains based on multiple document types of the record data; determining the necessity of retransmission of the multiple hash encryption domains; retransmitting the data to be retransmitted in the record data based on the necessity of retransmission of the multiple hash encryption domains to obtain a verification result; and encrypting and transmitting the record data with an electronic seal based on the verification result. The method can reduce the bandwidth consumed by encrypting and transmitting the record data, that is, it reduces resource consumption and improves the credibility and efficiency of encryption verification.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of data processing, and in particular to an intelligent electronic seal anti-counterfeiting method, system and storage medium in the technical field of data processing. Background Art

[0002] The concept of smart electronic seal anti-counterfeiting involves combining traditional physical seals with modern electronic technology to provide a highly secure verification and identity confirmation tool. In this system, the main function of the smart electronic seal is to use electronic technology to ensure the authenticity and integrity of documents or transactions. Among them, the smart electronic seal can use digital signature technology to ensure the integrity and non-repudiation of data. Digital signature is an encryption technology that generates a signature through a private key and can be verified with the corresponding public key. Any tampering with the data will cause the signature verification to fail, thereby revealing the tampering behavior. Therefore, the anti-counterfeiting technology of the smart electronic seal can not only effectively resist external attacks, but also prevent improper behavior of internal personnel, improve the security of documents and transactions, and is an important security tool in the modern digital environment. It is widely used in a series of scenarios to ensure data integrity and confidentiality.

[0003] The digital signature and encryption of electronic seals are usually used in situations where data integrity, authenticity, and non-compensation need to be ensured. These situations include the transmission and storage of sensitive information such as financial records, legal documents, and medical records. For example, taking the transmission of medical records as a specific scenario for analysis, such data needs to ensure its high security and integrity, and the document data to be encrypted is the document data to be anti-counterfeited using electronic seals; because these records include medical records, surgical records, examination results, drug prescriptions and other types of documents, which are relatively complicated and have a large amount of data. In the process of digitally signing and encrypting such documents to ensure their security, the pre-processing time (hash encryption time), resource consumption (bandwidth), and corresponding error repair (large file volume, many transmission times, and severe noise interference) will be greatly increased. Summary of the invention

[0004] In order to solve the technical problem that the pre-processing time, resource consumption and corresponding error repair will be greatly increased in the process of using electronic seals for encryption, the purpose of the present invention is to provide an intelligent electronic seal anti-counterfeiting method, system and storage medium, and the technical scheme adopted is as follows:

[0005] In a first aspect, an embodiment of the present invention provides an intelligent electronic seal anti-counterfeiting method, the method comprising:

[0006] Get the record data to be stamped;

[0007] Based on the multiple document types of the recorded data, determining multiple matching hash encryption domains;

[0008] determining a necessity for retransmission of the plurality of hashed encrypted fields;

[0009] Based on the necessity of retransmission of the multiple hash encryption fields, retransmit the data to be retransmitted in the recorded data to obtain a verification result;

[0010] Based on the verification result, the recorded data is encrypted and transmitted with an electronic seal.

[0011] In combination with the first aspect above, in some possible implementations, determining multiple matching hash encryption domains based on multiple document types of the recorded data includes:

[0012] Based on the multiple document types, determining necessity of merging each paragraph in the record data;

[0013] Based on the necessity of merging corresponding to the multiple paragraphs in the record data and a preset range, the hash encryption domains of the multiple paragraphs are determined.

[0014] In the above manner, by calculating the necessity of merging each paragraph in the recorded data and then judging whether the necessity of merging satisfies a preset range, the hash encryption domains of multiple paragraphs can be obtained quickly and accurately.

[0015] In combination with the first aspect, in some possible implementations, determining the necessity of merging the paragraphs in the record data based on the multiple document types includes:

[0016] For the u-th paragraph corresponding to the multiple document types, respectively determine a first similarity between the u-th paragraph and the u+1-th paragraph, and a second similarity between the u+1-th paragraph and the u+2-th paragraph; wherein u is an integer greater than 0;

[0017] The necessity of merging the u-th paragraph is determined based on a difference between the first similarity and the second similarity.

[0018] In the above manner, by analyzing the similarities between adjacent paragraphs, the necessity of merging any paragraph can be accurately analyzed, so that the hash encryption domains of multiple paragraphs can be determined based on the necessity of merging.

[0019] In combination with the first aspect, in some possible implementations, determining hash encryption domains of the multiple paragraphs based on the necessity of merging the multiple paragraphs in the recorded data and a preset range includes:

[0020] If the merging necessity corresponding to the multiple paragraphs is within the preset range, the multiple paragraphs are merged to obtain hash encryption domains of the multiple paragraphs.

[0021] In the above manner, by judging the necessity of merging corresponding to a plurality of paragraphs, it is possible to accurately analyze whether to merge the plurality of paragraphs to obtain the hash encryption domains of the plurality of paragraphs.

[0022] In combination with the first aspect, in some possible implementations, determining the necessity of retransmitting the multiple hash encryption fields includes:

[0023] Performing a hash operation on any hash encryption field of the multiple hash encryption fields to obtain a hash value;

[0024] In the same position of any one of the hash encryption domains, obtaining a first hash value corresponding to the transmission result of the hash value and a second hash value of the transmission result of the original recorded data;

[0025] Necessity of retransmission of any one of the hash encryption fields is determined based on the first hash value and the second hash value.

[0026] In the above manner, by calculating the difference between the hash value corresponding to the transmission result after hash encryption and the hash value of the original hash encryption result, the necessity of retransmission of each hash encryption domain can be accurately obtained.

[0027] In combination with the first aspect, in some possible implementations, determining the necessity of retransmitting any hash encryption field based on the first hash value and the second hash value includes:

[0028] determining a difference between the first hash value and the second hash value;

[0029] Based on the difference and the weight corresponding to the first Hash value, the necessity of retransmitting any one of the Hash encryption fields is determined.

[0030] In the above manner, by combining the difference between the first hash value and the second hash value with the corresponding weight, the necessity of retransmission of each hash encryption domain can be accurately analyzed.

[0031] In combination with the first aspect above, in some possible implementations, the method further includes:

[0032] Determine, among the plurality of paragraphs of the recorded data, a candidate paragraph for constructing a hash encryption domain to which the first hash value belongs;

[0033] Based on the necessity of merging the candidate paragraphs and the number of the candidate paragraphs, a weight corresponding to the first Hash value is determined.

[0034] In the above manner, different weights are set for the first hash values ​​of different hash encryption domains, so that more important first hash values ​​can be highlighted, which is beneficial to improve the accuracy of determining the necessity of retransmission.

[0035] In combination with the first aspect above, in some possible implementations, the necessity of retransmission of the multiple hash encryption fields, retransmitting the data to be retransmitted in the recorded data to obtain a verification result, includes:

[0036] Determining the data to be retransmitted in the recorded data based on the necessity of retransmission of the multiple hash encryption fields and a preset retransmission value;

[0037] The data to be retransmitted is verified to obtain the verification result.

[0038] In the above manner, the data to be retransmitted is determined in the recorded data by the necessity of retransmission, and then the data to be retransmitted is verified, so that the purpose of encryption and anti-counterfeiting is achieved through the verification result.

[0039] In a second aspect, an intelligent electronic seal anti-counterfeiting system is provided, the system comprising:

[0040] An acquisition module, used to acquire the record data to be stamped;

[0041] A first determination module, configured to determine a plurality of matching hash encryption domains based on a plurality of document types of the record data;

[0042] A second determination module, configured to determine the necessity of retransmission of the plurality of hash encryption fields;

[0043] A retransmission module, configured to retransmit the data to be retransmitted in the recorded data based on the necessity of retransmission of the multiple hash encryption domains, and obtain a verification result;

[0044] The encryption module is used to perform electronic seal encryption and transmission on the record data based on the verification result.

[0045] In a third aspect, an electronic device is provided, comprising: a memory for storing executable program code; and a processor for calling and running the executable program code from the memory, so that the device-oriented network security protection device executes the method in the above-mentioned first aspect or any possible implementation of the first aspect.

[0046] In a fourth aspect, a computer program product is provided, comprising: a computer program code, which, when executed on a computer, enables the computer to execute the method in the first aspect or any possible implementation of the first aspect.

[0047] In a fifth aspect, a computer-readable storage medium is provided, which stores a computer program code. When the computer program code runs on a computer, the computer executes the method in the above-mentioned first aspect or any possible implementation manner of the first aspect.

[0048] The present invention has the following beneficial effects: after obtaining the record data to be stamped, multiple matching hash encryption domains are determined based on multiple document types of the record data; in this way, when electronic seals are stamped and transmitted for record data with more data types and files with more complex data, different hash encryption domains can be determined according to the document types in the files. Afterwards, by determining the necessity of retransmission of multiple hash encryption domains, and based on the necessity of retransmission of the multiple hash encryption domains, the data to be retransmitted in the record data is retransmitted to obtain a verification result; finally, based on the verification result, the record data is encrypted and transmitted with an electronic seal. In this way, since different hash encryption domains have different transmission costs, matching different hash encryption domains for different document types can reduce the bandwidth consumed for encrypted transmission of record data, thereby reducing resource consumption, improving the degree of error repair, and improving the credibility and efficiency of encryption verification. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] In order to more clearly illustrate the technical solutions and advantages in the embodiments of the present invention or the prior art, the drawings required for use in the embodiments or the prior art descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0050] Figure 1 It is a schematic diagram of the implementation process of an intelligent electronic seal anti-counterfeiting method provided by an embodiment of the present invention;

[0051] Figure 2 It is another implementation flow diagram of an intelligent electronic seal anti-counterfeiting method provided by an embodiment of the present invention;

[0052] Figure 3 It is another implementation flow diagram of an intelligent electronic seal anti-counterfeiting method provided by an embodiment of the present invention;

[0053] Figure 4 It is another implementation flow diagram of an intelligent electronic seal anti-counterfeiting method provided by an embodiment of the present invention;

[0054] Figure 5 It is a schematic diagram of the composition structure of an intelligent electronic seal anti-counterfeiting system provided by an embodiment of the present invention;

[0055] Figure 6 It is a structural schematic diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0056] In order to further explain the technical means and effects adopted by the present invention to achieve the predetermined invention purpose, the following is a detailed description of the intelligent electronic seal anti-counterfeiting method proposed by the present invention, its specific implementation method, structure, characteristics and effects, in combination with the accompanying drawings and preferred embodiments. In the following description, different "one embodiment" or "another embodiment" does not necessarily refer to the same embodiment. In addition, specific features, structures or characteristics in one or more embodiments may be combined in any suitable form.

[0057] Among them, in the description of the embodiments of the present invention, unless otherwise specified, " / " means or, for example, A / B can mean A or B: "and / or" in the text is only a description of the association relationship of associated objects, indicating that there may be three relationships, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in the description of the embodiments of the present invention, "multiple" refers to two or more than two.

[0058] In the following, the terms "first" and "second" are used for descriptive purposes only and are not to be understood as suggesting or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features.

[0059] Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs.

[0060] The following is a detailed description of a specific scheme of the intelligent electronic seal anti-counterfeiting method provided by the present invention in conjunction with the accompanying drawings. Figure 1 , which shows a flow chart of an intelligent electronic seal anti-counterfeiting method provided by an embodiment of the present invention, the method comprising:

[0061] 101, obtaining the record data to be stamped.

[0062] Here, the record data to be stamped is large-scale record data, that is, the data volume of the record data is large. By stamping and transmitting the document with the digitally signed electronic seal, the data can be prevented from being tampered with or interfered with by noise during the transmission process. Therefore, before stamping the electronic seal, the corresponding record data needs to be obtained; for example, a large hospital system needs to transmit the complete electronic health record of a patient from one regional medical center to another. This type of record data may include but is not limited to various types of documents such as medical records, surgical records, test results, and drug prescriptions, and the total data volume of the record data is large.

[0063] 102. Determine a plurality of matching hash encryption domains based on a plurality of document types of the recorded data.

[0064] Here, multiple document types are obtained by classifying the document types of the recorded data; for each document type, a hash encryption domain that matches the document type is determined, thereby obtaining multiple hash encryption domains.

[0065] In some possible implementations, the above step 102 can be performed by Figure 2 The steps shown achieve:

[0066] 201 : Determine necessity of merging each paragraph in the record data based on the multiple document types.

[0067] Here, the necessity of merging is used to indicate the degree of necessity of the merging operation of the paragraph. For each document type, the necessity of merging each paragraph under the document type is determined respectively. In some possible implementations, for the u-th paragraph corresponding to the multiple document types, the first similarity between the u-th paragraph and the u+1-th paragraph, and the second similarity between the u+1-th paragraph and the u+2-th paragraph are determined respectively; wherein u is an integer greater than 0, and the u-th paragraph is any paragraph; the first similarity and the second similarity can be cosine similarity. Afterwards, based on the difference between the first similarity and the second similarity, the necessity of merging the u-th paragraph is determined. Here, for the u-th paragraph, multiple first similarities and multiple second similarities can be obtained, thereby obtaining multiple differences, and the multiple differences are summed to obtain the necessity of merging the u-th paragraph. In this way, by analyzing the similarity between adjacent paragraphs, the necessity of merging any paragraph can be accurately analyzed, so that the hash encryption domains of multiple paragraphs can be determined by the necessity of merging.

[0068] In some possible implementations, in the medical record scenario, obtain the electronic health record documents (medical records, surgical records, etc.) to be encrypted and transmitted, and use Sentence Boundary Detection (SBD), that is, Natural Language Processing (NLP) tools to detect the end of sentences, such as periods, question marks and other punctuation marks, as the basis for segmentation. And use word vector (Word2Vec) embedding to numerically represent the text of each paragraph to obtain the feature vector corresponding to the document. That is, in the record document to be transmitted, different paragraphs or sentences have a specific feature vector, which is a numerical result. The more similar the specific values ​​​​between the vectors, the more similar the document content represented, and the more likely it is to be used as a hash encryption domain, because it represents the same type of semantic content, such as patient medical record information. Calculate the corresponding hash encryption domain to obtain the distributed encryption result. Paragraphs and Necessity of merging distributed encryption domains corresponding to paragraphs , as shown in formula (1):

[0069] (1);

[0070] Among them, With The cosine similarity between adjacent paragraphs (i.e. the first similarity) and Pass Cosine similarity between adjacent paragraphs The difference between the two (i.e. the second similarity) is normalized to negative correlation; Indicates normalization.

[0071] Among them, by comparing the residual similarity differences corresponding to different paragraphs of the document content to be transmitted, the distributed encryption domain of the document is obtained. The patient's electronic health record table has classification distribution results of different dimensions. For example, the first n paragraphs describe the patient's medical history. Such text descriptions are relatively similar, such as the patient's medical record results and treatment results within a certain period of time at a time node. The closer the corresponding feature vector results are, the similarity difference result of the segment is. The closer they are, that is, paragraphs representing the same content can be assigned together through the above method. Similarly, other types of text content, such as patient drug prescriptions, also have relatively similar results, so the corresponding necessity of merging is higher.

[0072] 202 : Determine hash encryption domains of the multiple paragraphs based on the necessity of merging the multiple paragraphs in the record data and a preset range.

[0073] Here, the preset range can be a custom numerical range, for example, the preset range is (0.8, 1). First, determine whether the necessity of merging the multiple paragraphs is within the preset range. If the necessity of merging the multiple paragraphs is within the preset range, then merge the paragraphs to obtain a hash encryption domain. In this way, by calculating the necessity of merging each paragraph in the recorded data, and then determining whether the necessity of merging satisfies the preset range, the hash encryption domains of the multiple paragraphs can be obtained quickly and accurately.

[0074] In some possible implementations, if the necessity of merging the multiple paragraphs is within a preset range, the multiple paragraphs are merged to obtain the hash encryption domains of the multiple paragraphs. The result values ​​obtained in the segment are all in Within the range of , it is considered that the corresponding distributed encryption domain has a high necessity to be merged, and a merge operation is performed to obtain the previous The hash encryption domain of the segment. The hash encryption domain is a distributed encryption result that combines the main features of the text to be transmitted and performs distributed hash encryption on it, which ensures low encryption latency while reducing the bandwidth occupied by the data during transmission, that is, increasing the security and effectiveness of the patient's electronic health record text during the transfer and transmission process. In this way, by judging the size of the necessity of merging corresponding to multiple paragraphs, it is possible to accurately analyze whether to merge these multiple paragraphs to obtain the hash encryption domains of these multiple paragraphs.

[0075] 103. Determine the necessity of retransmitting the multiple hash encryption fields.

[0076] Here, the retransmission necessity of each hash encryption field is calculated, and the retransmission necessity is used to characterize the necessity degree of the to-be-retransmitted data corresponding to the hash encryption field.

[0077] In some possible implementations, the above step 103 can be performed by Figure 3 The steps shown achieve:

[0078] 301. Perform a hash operation on any hash encryption field of the multiple hash encryption fields to obtain a hash value.

[0079] Here, a hash encryption domain is obtained, and a hash function is calculated on different hash encryption domains to obtain corresponding hash values.

[0080] 302. In the same position of any hash encryption domain, obtain a first hash value corresponding to the transmission result of the hash value and a second hash value corresponding to the transmission result of the original recorded data.

[0081] Here, the hash value is transmitted with the original text (i.e., the original recorded data) to obtain the transmission result. Due to the existence of the distributed hash encryption domain, the inconsistency of the text data length during the transmission of the domain text and the original text (in the digital signature, the original text also needs to be transmitted) will increase the risk of interference and error detection. In order to avoid the occurrence of this risk, the encrypted domain after verification comparison is selected for retransmission. In order to ensure that the transmitted content has not been tampered with, the hash value (i.e., the first hash value) and the hash value (i.e., the second hash value) of the hash encryption result of the corresponding original text are compared at the receiving end to determine its security; if a large error occurs after the comparison, it proves that the original healthy electronic text data of the patient has been tampered with or that noise and other factors interfere with it during the transmission process, and retransmission is required. Therefore, in the scenario of distributed encrypted transmission, in order to prevent noise or multiple rounds of encryption, the risk of interference is large, and the verification of the comparison domain is required to obtain the necessity of retransmission. In summary, the greater the difference in the comparison result corresponding to the retransmission encryption domain (i.e., the difference between the first hash value and the second hash value), the higher the necessity of retransmission.

[0082] 303: Determine necessity of retransmission of any hash encryption domain based on the first hash value and the second hash value.

[0083] Here, by calculating the difference between the first hash value and the second hash value, multiplying the difference with the weight of the response, and summing the multiplication results, the necessity of retransmission of any hash encryption field is obtained. In this way, by calculating the difference between the hash value corresponding to the hash encryption transmission result and the hash value of the original hash encryption result, the necessity of retransmission of each hash encryption field can be accurately obtained.

[0084] In some possible implementations, first, the difference between the first hash value and the second hash value is determined; then, based on the difference and the weight corresponding to the first hash value, the necessity of retransmission of any hash encryption field is determined. In this way, by combining the difference between the first hash value and the second hash value with the corresponding weight, the necessity of retransmission of each hash encryption field can be accurately analyzed.

[0085] In some possible implementations, after obtaining the hash encryption domain, the hash function is calculated for different hash encryption domains to obtain the corresponding hash value. The hash value and the original text are transmitted to obtain the transmission result. The difference of the hash value at the receiving end is analyzed to obtain the comparison result. Necessity of retransmission of hashed fields As shown in formula (2):

[0086] (2);

[0087] in, Indicates the first A hash value (in this case, the part that is transmitted after hash encryption); Indicates the hash value difference between the hash value at the same position (in this case, the encrypted result after the original text is transmitted) and the hash encryption result of the original text; 128 means a total of 128 hash values.

[0088] Among them, by comparing the hash values ​​in different hash encryption domains, the corresponding encryption accuracy is obtained. Different electronic health text contents, such as medical records, treatment results, etc., are transmitted through digital signatures. In this process, the closer the hash encryption results in different paragraphs are, the smaller the corresponding differences are, the smaller the sum of the difference results is, and the lower the necessity of corresponding retransmission is.

[0089] In some possible implementations, the weight corresponding to the first hash value may be determined by the following process:

[0090] First, among the multiple paragraphs of the recorded data, candidate paragraphs for constructing the hash encryption domain to which the first hash value belongs are determined.

[0091] Then, based on the necessity of merging the candidate paragraphs and the number of the candidate paragraphs, a weight corresponding to the first Hash value is determined.

[0092] Here, as the number of transmission batches increases, the corresponding noise content will also increase. During the transmission process, no tampering occurs, but because of the existence of noise, some hash values ​​are affected, so the corresponding necessity of retransmission will produce errors. In order to eliminate this error, the weight of the sum of the calculated differences is determined. (i.e., the weight corresponding to the first hash value), as shown in formula (3):

[0093] (3);

[0094] in, Indicates The weight of a hash value in the process of calculating the necessity of retransmission; Indicates the first Necessity of merging paragraphs; Indicates the number of candidate paragraphs, that is, how many paragraphs are involved in constructing a hash encryption domain. The necessity of merging aims to characterize and quantify the similarity of the content of the paragraph during transmission, such as the transmission of patient medical records. The higher the similarity, that is, the more the transmitted content belongs to the same concept, the lower the probability of tampering or abnormality in its transmission. Because the similarity is relatively high after hash encryption, the lower the degree of change of the hash value, the lower the probability of abnormality in the transmission process, and the corresponding retransmission necessity is lower, so the weight value is lower at this time. Furthermore, Indicates the order of paragraphs participating in encrypted transmission, that is, the number of paragraphs participating in encrypted transmission. When the original recorded data is transmitted, there is no priority, that is, the same text is transmitted at the same time, which leads to adverse effects such as bandwidth occupation. According to the logic of distributed encrypted transmission, the lower the order of transmission, the greater the possibility of noise influence, so at this time the hash encryption domain The larger the value, the higher the corresponding noise impact, and the more it is necessary to reduce its impact, so the weight value and order Inversely proportional, the purpose is to reduce the interference of distributed transmission noise on the necessity of retransmission. In this way, different weights are set for the first hash values ​​of different hash encryption domains, so that more important first hash values ​​can be highlighted, which is conducive to improving the accuracy of determining the necessity of retransmission.

[0095] 104. Based on the necessity of retransmission of the multiple hash encryption fields, retransmit the data to be retransmitted in the recorded data to obtain a verification result.

[0096] Here, after obtaining the necessity of retransmission corresponding to each hash encryption domain, the data to be retransmitted is further determined, so that the data to be retransmitted is retransmitted and data verification is performed to obtain the verification result.

[0097] In some possible implementations, the above step 104 can be performed by Figure 4 The steps shown achieve:

[0098] 401. Determine the data to be retransmitted in the recorded data based on the necessity of retransmission of the multiple hash encryption fields and a preset retransmission value.

[0099] Here, the preset retransmission value may be a custom setting, for example, the preset retransmission value may be set to 0.5. If the necessity of retransmission of the hash encryption domain is greater than the preset retransmission value (for example, 0.5), it indicates that the paragraph corresponding to the hash encryption domain needs to be retransmitted with a digital signature, and thus the data corresponding to the hash encryption domain is determined to be the data to be retransmitted.

[0100] 402: Verify the data to be retransmitted to obtain the verification result.

[0101] Here, after obtaining the data to be retransmitted, the data to be retransmitted is re-hashed and retransmitted, and the corresponding retransmission result value is recalculated. If the result value still meets the preset retransmission value, it is considered that the content has been tampered with; if the result does not meet the preset retransmission value, it is considered that the content has not been tampered with, that is, encrypted transmission is achieved. In this way, the data to be retransmitted is determined in the recorded data through the necessity of retransmission, so that the data to be retransmitted is verified, so that the purpose of encryption and anti-counterfeiting is achieved through the verification result.

[0102] 105. Based on the verification result, the record data is encrypted and transmitted with an electronic seal.

[0103] Here, after obtaining the verification result, the electronic seal is encrypted and transmitted. In some possible implementations, the hash encryption result after each segmentation is transmitted together with the digital signature; to ensure that the transmission channel is secure, an encryption protocol can be used to encrypt the entire transmission process to ensure that the data is not tampered with or stolen during transmission. After the receiving end receives the transmitted data, it first verifies the validity of the digital signature. For example, use the public key to decrypt the digital signature to obtain the original hash value, and compare it with the decrypted hash value; decrypt the hash value of each paragraph and compare it with the corresponding part in the original recorded data to ensure the integrity of the data and that it has not been tampered with.

[0104] In an embodiment of the present invention, after obtaining the record data to be stamped, multiple matching hash encryption domains are determined based on multiple document types of the record data; in this way, when electronic seals are stamped and transmitted for record data with more data types and files with more complex data, different hash encryption domains can be determined according to the document types in the files. Afterwards, by determining the necessity of retransmission of multiple hash encryption domains, and based on the necessity of retransmission of the multiple hash encryption domains, the data to be retransmitted in the record data is retransmitted to obtain a verification result; finally, based on the verification result, the record data is encrypted and transmitted with an electronic seal. In this way, since different hash encryption domains have different transmission costs, matching different hash encryption domains for different document types can reduce the consumption of bandwidth after the encrypted transmission of the record data, reduce resource consumption, and improve the credibility and efficiency of encryption verification.

[0105] The embodiment of the present invention provides an intelligent electronic seal anti-counterfeiting system, such as Figure 5 As shown, the system 500 includes:

[0106] The acquisition module 501 is used to acquire the record data to be stamped;

[0107] A first determination module 502, configured to determine a plurality of matching hash encryption domains based on a plurality of document types of the recorded data;

[0108] A second determination module 503, configured to determine the necessity of retransmission of the plurality of hash encryption fields;

[0109] A retransmission module 504, configured to retransmit the data to be retransmitted in the recorded data based on the necessity of retransmission of the multiple hash encryption fields, and obtain a verification result;

[0110] The encryption module 505 is used to perform electronic seal encryption and transmission on the record data based on the verification result.

[0111] In some possible implementations, the first determination module 502 is further used to determine the necessity of merging each paragraph in the record data based on the multiple document types; and determine the hash encryption domain of the multiple paragraphs based on the necessity of merging corresponding to the multiple paragraphs in the record data and a preset range.

[0112] In some possible implementations, the first determination module 502 is further used to determine, for the u-th paragraph corresponding to the multiple document types, a first similarity between the u-th paragraph and the u+1-th paragraph, and a second similarity between the u+1-th paragraph and the u+2-th paragraph; wherein u is an integer greater than 0; and determine the necessity of merging the u-th paragraph based on the difference between the first similarity and the second similarity.

[0113] In some possible implementations, the first determining module 502 is further configured to merge the multiple paragraphs to obtain hash encryption domains of the multiple paragraphs if the merging necessity corresponding to the multiple paragraphs is within the preset range.

[0114] In some possible implementations, the second determination module 503 is further configured to perform a hash operation on any hash encryption domain of the multiple hash encryption domains to obtain a hash value; and obtain, in the same position of any hash encryption domain, a first hash value corresponding to a transmission result of the hash value and a second hash value of a transmission result of the original recorded data;

[0115] Necessity of retransmission of any one of the hash encryption fields is determined based on the first hash value and the second hash value.

[0116] In some possible implementations, the second determination module 503 is further used to determine the difference between the first hash value and the second hash value; and determine the necessity of retransmission of any hash encryption domain based on the difference and the weight corresponding to the first hash value.

[0117] In some possible implementations, the second determination module 503 is further used to determine, from among the multiple paragraphs of the recorded data, candidate paragraphs for constructing the hash encryption domain to which the first hash value belongs; and determine the weight corresponding to the first hash value based on the necessity of merging the candidate paragraphs and the number of the candidate paragraphs.

[0118] In some possible implementations, the retransmission module 504 is further used to determine the data to be retransmitted in the recorded data based on the necessity of retransmission of the multiple hash encryption domains and a preset retransmission value; and to verify the data to be retransmitted to obtain the verification result.

[0119] Optionally, the transmission medium can be a wired link (such as but not limited to coaxial cable, optical fiber and digital subscriber line (DSL)) or a wireless link (such as but not limited to wireless Fidelity (WIFI), Bluetooth and mobile device network).

[0120] It should be noted that: the device provided in the above embodiment is only illustrated by the division of the above functional modules. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the computer device is divided into different functional modules to complete all or part of the functions described above. In addition, the shopping guide device provided in the above embodiment and the image extension method embodiment belong to the same concept. The specific implementation process is detailed in the method embodiment and will not be repeated here.

[0121] Figure 6 is a schematic diagram of the structure of an electronic device provided by an embodiment of the present invention. Figure 6 As shown, the electronic device 600 includes: a memory 601, a processor 602, and a computer program 603 stored in the memory 601 and running on the processor 602, wherein when the processor 602 executes the computer program 603, the device can execute any one of the aforementioned intelligent electronic seal anti-counterfeiting methods. In addition, the embodiment of the present invention also protects a device, which may include a memory and a processor, wherein the memory stores an executable program code, and the processor is used to call and execute the executable program code to execute an intelligent electronic seal anti-counterfeiting method provided by the embodiment of the present invention.

[0122] This embodiment can divide the functional modules of the device according to the above method example. For example, it can correspond to each functional module, or two or more functions can be integrated into one processing module. The above integrated module can be implemented in the form of hardware. It should be noted that the division of modules in this embodiment is schematic and is only a logical function division. There may be other division methods in actual implementation. In the case of dividing each module corresponding to each function, the device may also include a signal uploading module, a determination module, an adjustment module, etc. It should be noted that all relevant contents of each step involved in the above method embodiment can be referred to the functional description of the corresponding functional module, which will not be repeated here.

[0123] It should be understood that the device provided in this embodiment is used to execute the above-mentioned intelligent electronic seal anti-counterfeiting method, so the same effect as the above-mentioned implementation method can be achieved. In the case of an integrated unit, the device may include a processing module and a storage module. Among them, when the device is applied to a device, the processing module can be used to control and manage the actions of the device. The storage module can be used to support the device to execute mutual program codes, etc. Among them, the processing module can be a processor or a controller, which can implement or execute various exemplary logical boxes, modules and circuits described in conjunction with the disclosure of the present invention. The processor can also be a combination that implements a computing function, such as a combination of one or more microprocessors, a combination of digital signal processing (DSP) and a microprocessor, etc., and the storage module can be a memory.

[0124] In addition, the device provided in the embodiment of the present invention may be a chip, a component or a module, and the chip may include a connected processor and a memory; wherein the memory is used to store instructions, and when the processor calls and executes the instructions, the chip can execute a smart electronic seal anti-counterfeiting method provided in the above embodiment. This embodiment also provides a computer-readable storage medium, in which a computer program code is stored, and when the computer program code is run on a computer, the computer executes the above-mentioned related method steps to implement a smart electronic seal anti-counterfeiting method provided in the above embodiment.

[0125] This embodiment also provides a computer program product, when the computer program product is run on a computer, the computer executes the above-mentioned related steps to implement a smart electronic seal anti-counterfeiting method provided by the above embodiment. Among them, the device, computer-readable storage medium, computer program product or chip provided in this embodiment are all used to execute the corresponding method provided above, so the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding method provided above, and will not be repeated here. Through the description of the above implementation mode, the technicians in the relevant field can understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example. In practical applications, the above-mentioned function allocation can be completed by different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In the embodiments provided by the present invention, it should be understood that the disclosed device and method can be implemented in other ways. For example, the device embodiment described above is only schematic, for example, the division of modules or units is only a logical function division, and there can be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, 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 may be an indirect coupling or communication connection through some interface, device or unit, which may be electrical, mechanical or other forms.

[0126] It should be noted that the sequence of the above-mentioned embodiments of the present invention is only for description and does not represent the advantages and disadvantages of the embodiments. The process depicted in the accompanying drawings does not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multi-tasking and parallel processing are also possible or may be advantageous. The various embodiments in this specification are described in a progressive manner, and the same and similar parts between the various embodiments can be referenced to each other, and each embodiment focuses on the differences from other embodiments. The above content is only a specific implementation method of the present invention, but the protection scope of the present invention is not limited to this. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed by the present invention, which should be covered within the protection scope of the present invention.

Claims

1. An intelligent electronic seal anti-counterfeiting method, characterized in that: The method comprises: Get the record data to be stamped; Based on the multiple document types of the recorded data, determining multiple matching hash encryption domains; determining a necessity for retransmission of the plurality of hashed encrypted fields; Based on the necessity of retransmission of the multiple hash encryption fields, retransmit the data to be retransmitted in the recorded data to obtain a verification result; Based on the verification result, the recorded data is encrypted and transmitted with an electronic seal; The determining the necessity of retransmitting the plurality of hash encryption fields comprises: Performing a hash operation on any hash encryption field of the multiple hash encryption fields to obtain a hash value; In the same position of any one of the hash encryption domains, obtaining a first hash value corresponding to the transmission result of the hash value and a second hash value of the transmission result of the original recorded data; Determining necessity of retransmission of any one of the hash encryption fields based on the first hash value and the second hash value; The determining, based on the first hash value and the second hash value, necessity of retransmission of any hash encryption field comprises: determining a difference between the first hash value and the second hash value; Determining necessity of retransmission of any one of the hash encryption fields based on the difference and a weight corresponding to the first hash value; The determining of a plurality of matching hash encryption domains based on the plurality of document types of the recorded data comprises: Based on the multiple document types, determining the necessity of merging each paragraph in the record data; Determining hash encryption domains of the plurality of paragraphs based on the necessity of merging corresponding to the plurality of paragraphs in the recorded data and a preset range; The determining, based on the multiple document types, the necessity of merging each paragraph in the record data includes: For the u-th paragraph corresponding to the multiple document types, respectively determine a first similarity between the u-th paragraph and the u+1-th paragraph, and a second similarity between the u+1-th paragraph and the u+2-th paragraph; wherein u is an integer greater than 0; Determining necessity of merging the u-th paragraph based on a difference between the first similarity and the second similarity; Determining hash encryption domains of the plurality of paragraphs based on the necessity of merging corresponding to the plurality of paragraphs in the record data and a preset range includes: If the merging necessity corresponding to the multiple paragraphs is within the preset range, the multiple paragraphs are merged to obtain hash encryption domains of the multiple paragraphs.

2. The intelligent electronic seal anti-counterfeiting method according to claim 1, characterized in that: The method further comprises: Determine, among the plurality of paragraphs of the recorded data, a candidate paragraph for constructing a hash encryption domain to which the first hash value belongs; Based on the necessity of merging the candidate paragraphs and the number of the candidate paragraphs, a weight corresponding to the first Hash value is determined.

3. The intelligent electronic seal anti-counterfeiting method according to claim 1, characterized in that: The necessity of retransmission based on the multiple hash encryption domains, retransmitting the data to be retransmitted in the recorded data to obtain a verification result, including: Determining the data to be retransmitted in the recorded data based on the necessity of retransmission of the multiple hash encryption fields and a preset retransmission value; The data to be retransmitted is verified to obtain the verification result.

4. An intelligent electronic seal anti-counterfeiting system, characterized in that: The system comprises: An acquisition module, used to acquire the record data to be stamped; A first determination module, configured to determine a plurality of matching hash encryption domains based on a plurality of document types of the recorded data; A second determination module, configured to determine the necessity of retransmission of the plurality of hash encryption fields; A retransmission module, configured to retransmit the data to be retransmitted in the recorded data based on the necessity of retransmission of the multiple hash encryption domains, and obtain a verification result; An encryption module, used for performing electronic seal encryption and transmission of the recorded data based on the verification result; The determining the necessity of retransmitting the plurality of hash encryption fields comprises: Performing a hash operation on any hash encryption field of the multiple hash encryption fields to obtain a hash value; In the same position of any one of the hash encryption domains, obtaining a first hash value corresponding to the transmission result of the hash value and a second hash value of the transmission result of the original recorded data; Determining necessity of retransmission of any one of the hash encryption fields based on the first hash value and the second hash value; The determining, based on the first hash value and the second hash value, necessity of retransmission of any hash encryption field comprises: determining a difference between the first hash value and the second hash value; Determining necessity of retransmission of any one of the hash encryption fields based on the difference and a weight corresponding to the first hash value; The determining of a plurality of matching hash encryption domains based on the plurality of document types of the recorded data comprises: Based on the multiple document types, determining the necessity of merging each paragraph in the record data; Determining hash encryption domains of the plurality of paragraphs based on the necessity of merging corresponding to the plurality of paragraphs in the recorded data and a preset range; The determining, based on the multiple document types, the necessity of merging each paragraph in the record data includes: For the u-th paragraph corresponding to the multiple document types, respectively determine a first similarity between the u-th paragraph and the u+1-th paragraph, and a second similarity between the u+1-th paragraph and the u+2-th paragraph; wherein u is an integer greater than 0; Determining necessity of merging the u-th paragraph based on a difference between the first similarity and the second similarity; Determining hash encryption domains of the plurality of paragraphs based on the necessity of merging corresponding to the plurality of paragraphs in the record data and a preset range includes: If the merging necessity corresponding to the multiple paragraphs is within the preset range, the multiple paragraphs are merged to obtain hash encryption domains of the multiple paragraphs.

5. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed, the method according to any one of claims 1 to 3 is implemented.

Citation Information

Patent Citations

  • Electronic document signature method and device, storage medium and electronic equipment

    CN111177801A

  • Electronic file evidence storage method and system based on trusted timestamp, terminal and medium

    CN116318717A