CN113449321B - Ciphertext retrieval method, device and system - Google Patents
Ciphertext retrieval method, device and system Download PDFInfo
- Publication number
- CN113449321B CN113449321B CN202110747763.2A CN202110747763A CN113449321B CN 113449321 B CN113449321 B CN 113449321B CN 202110747763 A CN202110747763 A CN 202110747763A CN 113449321 B CN113449321 B CN 113449321B
- Authority
- CN
- China
- Prior art keywords
- ciphertext
- original data
- keyword
- target
- abstract
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 51
- 230000000977 initiatory effect Effects 0.000 claims description 13
- 238000004891 communication Methods 0.000 claims description 12
- 230000004044 response Effects 0.000 claims description 11
- 238000012545 processing Methods 0.000 abstract description 11
- 230000008901 benefit Effects 0.000 description 7
- 230000008569 process Effects 0.000 description 7
- 238000010586 diagram Methods 0.000 description 5
- 238000010276 construction Methods 0.000 description 3
- 239000000284 extract Substances 0.000 description 3
- 238000004590 computer program Methods 0.000 description 2
- 238000013507 mapping Methods 0.000 description 2
- 230000008859 change Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000006870 function Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/60—Protecting data
- G06F21/602—Providing cryptographic facilities or services
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/60—Protecting data
- G06F21/62—Protecting access to data via a platform, e.g. using keys or access control rules
- G06F21/6218—Protecting access to data via a platform, e.g. using keys or access control rules to a system of files or objects, e.g. local or distributed file system or database
- G06F21/6227—Protecting access to data via a platform, e.g. using keys or access control rules to a system of files or objects, e.g. local or distributed file system or database where protection concerns the structure of data, e.g. records, types, queries
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Software Systems (AREA)
- General Health & Medical Sciences (AREA)
- Computer Hardware Design (AREA)
- Computer Security & Cryptography (AREA)
- Health & Medical Sciences (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Bioethics (AREA)
- Databases & Information Systems (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Storage Device Security (AREA)
Abstract
The embodiment of the invention provides a ciphertext retrieval method, a device and a system, wherein the method stores an original data ciphertext, the original data ciphertext abstract and a keyword ciphertext abstract of the original data in a server in advance according to an association relation, so that when the original data of a target is required to be obtained, only a target keyword corresponding to the original data of the target is required to be encrypted, a corresponding target keyword ciphertext abstract is generated according to a text similarity algorithm and sent to the server, the server can accurately retrieve the corresponding target original data ciphertext according to the association relation and send the target original data ciphertext to a terminal, the terminal can quickly and accurately acquire the target original data only by downloading and decrypting the target original data ciphertext, and the problems of network resources and excessively long processing time caused by the fact that the cloud ciphertext data are required to be downloaded in full quantity and then the ciphertext data are decrypted in full quantity in the prior art are avoided.
Description
Technical Field
The present invention relates to the field of cloud storage technologies, and in particular, to a ciphertext retrieval downloading method, device, and system.
Background
Along with the continuous and deep development of informatization and digital construction in China, more and more enterprises store important data into public clouds, so that the informatization operation cost of the enterprises can be reduced, and the use requirements of staff can be met.
In the prior art, in order to prevent important data from leaking in the cloud, the data needs to be encrypted locally before the terminal uploads the data, and ciphertext data is uploaded to the cloud, so that the safety of the important data stored in the cloud can be effectively guaranteed.
However, after the data is encrypted and then uploaded to the cloud, when the terminal uses the cloud data, the cloud ciphertext data needs to be downloaded in full, and then the ciphertext data needs to be decrypted in full, so that the required data can be obtained. When the data volume is large, the downloading process needs to consume a large amount of network resources, and needs to consume a long downloading time, and the decrypting process also needs to consume a large amount of terminal resources and is too long in decryption, so that the enterprise cost is increased and the working efficiency is reduced.
Disclosure of Invention
In view of the foregoing, the present invention has been made to provide a ciphertext retrieval method, apparatus, and system that solve, or at least partially solve, the foregoing problems.
According to a first aspect of the present invention, a ciphertext retrieval method is provided, and the ciphertext retrieval method is applied to a terminal, wherein the terminal is in communication connection with a server, the server stores an original data ciphertext, the original data ciphertext abstract and a keyword ciphertext abstract of original data according to an association relationship, and the original data is the original data corresponding to the original data ciphertext; the method comprises the following steps:
acquiring a target keyword corresponding to target original data;
encrypting the target keyword by adopting an encryption algorithm to generate a target keyword ciphertext;
generating the target keyword ciphertext abstract by adopting a text similarity algorithm;
initiating a search operation to the server, wherein the search operation carries the target keyword ciphertext abstract so that the server can search a target original data ciphertext corresponding to the target keyword ciphertext abstract according to the association relation;
and when the target original data ciphertext fed back by the server in response to the retrieval operation is received, decrypting the target original data ciphertext according to a decryption algorithm corresponding to the encryption algorithm to obtain target original data.
Optionally, in the method, the terminal stores a keyword list, where the keyword list includes keywords corresponding to different original data;
The obtaining the target keywords corresponding to the target original data comprises the following steps:
and acquiring target keywords corresponding to the target original data from the keyword list.
Optionally, before obtaining the target keyword corresponding to the target original data, the method further includes:
acquiring original data to be stored;
encrypting the original data to be stored by adopting the encryption algorithm to obtain an original data ciphertext;
generating the original data ciphertext abstract according to the original data ciphertext by adopting the text similarity algorithm;
acquiring a search keyword in the original data;
adding the search keyword to the keyword list;
encrypting the search keyword by adopting the encryption algorithm to generate the keyword ciphertext;
generating a keyword ciphertext abstract according to the keyword ciphertext by adopting the text similarity algorithm;
uploading the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract to the server so that the server can store the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data according to the association relation.
Optionally, in the method, the text similarity algorithm is simHASH algorithm.
According to a second aspect of the present invention, there is provided a ciphertext retrieval apparatus, applied to a terminal, where the terminal is in communication connection with a server, and the server stores an original data ciphertext, the original data ciphertext abstract, and a keyword ciphertext abstract of the original data according to an association relationship, where the original data is the original data corresponding to the original data ciphertext; the device comprises:
the first acquisition module is used for acquiring target keywords corresponding to target original data;
the first encryption module is used for encrypting the target keyword by adopting an encryption algorithm to generate a target keyword ciphertext;
the first abstract generation module is used for generating the target keyword ciphertext abstract by adopting a text similarity algorithm;
the search initiating module is used for initiating search operation to the server, wherein the search operation carries the target keyword ciphertext abstract so that the server can search the target original data ciphertext corresponding to the target keyword ciphertext abstract according to the association relation;
and the first receiving module is used for decrypting the target original data ciphertext according to a decryption algorithm corresponding to the encryption algorithm when receiving the target original data ciphertext fed back by the server in response to the retrieval operation, so as to obtain target original data.
Optionally, the apparatus further comprises:
the second acquisition module is used for acquiring the original data to be stored before acquiring the target keywords corresponding to the target original data;
the second encryption module is used for encrypting the original data to be stored by adopting the encryption algorithm to obtain an original data ciphertext;
the second abstract generating module is used for generating the original data ciphertext abstract according to the original data ciphertext by adopting the text similarity algorithm;
a third obtaining module, configured to obtain a search keyword in the original data;
an updating module, configured to add the search keyword to the keyword list;
the third encryption module is used for encrypting the search keyword by adopting the encryption algorithm to generate the keyword ciphertext;
the third abstract generating module is used for generating the keyword ciphertext abstract according to the keyword ciphertext by adopting the text similarity algorithm;
and the uploading module is used for uploading the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract to the server so that the server can store the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data according to the association relation.
Compared with the prior art, the embodiment of the invention has the following advantages:
according to the embodiment of the invention, the ciphertext retrieval method and the ciphertext retrieval device comprise the following steps: acquiring a target keyword corresponding to target original data; encrypting the target keyword by adopting an encryption algorithm to generate a target keyword ciphertext; generating the target keyword ciphertext abstract by adopting a text similarity algorithm; initiating a search operation to the server, wherein the search operation carries the target keyword ciphertext abstract so that the server can search a target original data ciphertext corresponding to the target keyword ciphertext abstract according to the association relation; and when the target original data ciphertext fed back by the server in response to the retrieval operation is received, decrypting the target original data ciphertext according to a decryption algorithm corresponding to the encryption algorithm to obtain target original data. Because the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data are stored in the server according to the association relation in advance, when the original data of the target is required to be obtained, the corresponding target keyword ciphertext abstract of the original data of the target is only required to be encrypted, the corresponding target keyword ciphertext abstract is generated according to a text similarity algorithm and sent to the server, the corresponding target original data ciphertext can be accurately searched out by the server according to the association relation and sent to the terminal, the terminal only needs to download and decrypt the target original data ciphertext, the target original data can be quickly and accurately obtained, and the problems that network resources, terminal resources are occupied in a large amount and processing time is overlong due to the fact that the ciphertext data are required to be decrypted in a large amount in the prior art are avoided.
According to a third aspect of the present invention, another ciphertext retrieval method is provided and applied to a server, where the server is in communication connection with a terminal, and the server stores an original data ciphertext, the original data ciphertext abstract, and a keyword ciphertext abstract of original data according to an association relationship, where the original data is corresponding to the original data ciphertext; the method comprises the following steps:
when a search operation initiated by the terminal is received, searching a target original data ciphertext corresponding to the target keyword ciphertext abstract according to a target keyword ciphertext abstract carried by the search operation and the association relation;
under the condition that a first keyword ciphertext abstract matched with the target keyword ciphertext abstract exists in the server, determining an original data ciphertext corresponding to the first keyword ciphertext abstract as the target original data ciphertext, and transmitting the target original data ciphertext to the terminal;
and under the condition that a first keyword ciphertext abstract matched with the target keyword ciphertext abstract does not exist in the server, if a first original data ciphertext abstract matched with the target keyword ciphertext abstract exists in the server, determining a second keyword ciphertext corresponding to the first original data ciphertext abstract, determining an original data ciphertext corresponding to the second keyword ciphertext as the target original data ciphertext, and issuing the target original data ciphertext to the terminal.
Optionally, the method further comprises:
and if the first keyword ciphertext abstract matched with the target keyword ciphertext abstract does not exist in the server and the first original data ciphertext abstract matched with the target keyword ciphertext abstract does not exist in the server, a notice without a matching item is fed back to the terminal.
According to a fourth aspect of the present invention, another ciphertext retrieval apparatus is further provided, and the ciphertext retrieval apparatus is applied to a server, where the server is in communication connection with a terminal, and the server stores an original data ciphertext, the original data ciphertext abstract, and a keyword ciphertext abstract of the original data according to an association relationship, where the original data is the original data corresponding to the original data ciphertext; the device comprises:
the second receiving module is used for searching a target original data ciphertext corresponding to the target keyword ciphertext abstract according to the target keyword ciphertext abstract carried by the searching operation and the association relation when receiving the searching operation initiated by the terminal;
the first retrieval module is used for determining an original data ciphertext corresponding to the first keyword ciphertext abstract as the target original data ciphertext and transmitting the target original data ciphertext to the terminal under the condition that a first keyword ciphertext abstract matched with the target keyword ciphertext abstract exists in the server;
And the second retrieval module is used for determining a second keyword ciphertext corresponding to the first original data ciphertext abstract and determining an original data ciphertext corresponding to the second keyword ciphertext as the target original data ciphertext and issuing the target original data ciphertext to the terminal if the first original data ciphertext abstract matched with the target keyword ciphertext abstract does not exist in the server.
Compared with the prior art, the embodiment of the invention has the following advantages:
according to the ciphertext retrieval method and system provided by the embodiment of the invention, the original data ciphertext abstract and the keyword ciphertext abstract of the original data are stored in the server in advance according to the association relation, so that when the terminal needs to obtain the target original data, only the target keyword corresponding to the target original data is required to be encrypted, the corresponding target keyword ciphertext abstract is generated according to the text similarity algorithm and sent to the server, the server can accurately retrieve the corresponding target original data ciphertext according to the association relation and send the target original data ciphertext to the terminal, and the terminal only needs to download and decrypt the target original data ciphertext, so that the target original data can be quickly and accurately obtained, and the problems of network resources, terminal resources occupation and overlong processing time caused by the fact that the terminal needs to fully download cloud ciphertext data and fully decrypt ciphertext data in the prior art are avoided.
According to a fourth aspect of the present invention, there is further provided a ciphertext retrieval system, wherein the ciphertext retrieval system comprises a server and a terminal, the terminal is in communication connection with the server, the server stores an original data ciphertext, the original data ciphertext abstract, and a keyword ciphertext abstract of the original data according to an association relationship, and the original data is the original data corresponding to the original data ciphertext;
the terminal acquires a target keyword corresponding to target original data;
the terminal encrypts the target keyword by adopting an encryption algorithm to generate a target keyword ciphertext;
the terminal generates the target keyword ciphertext abstract by adopting a text similarity algorithm;
the terminal initiates a search operation to the server, wherein the search operation carries the target keyword ciphertext abstract;
when receiving a retrieval operation initiated by the terminal, the server retrieves a target original data ciphertext corresponding to the target keyword ciphertext abstract according to a target keyword ciphertext abstract carried by the retrieval operation and the association relation;
under the condition that a first keyword ciphertext abstract matched with the target keyword ciphertext abstract exists in the server, the server determines an original data ciphertext corresponding to the first keyword ciphertext abstract as the target original data ciphertext, and issues the target original data ciphertext to the terminal;
If a first keyword ciphertext summary matched with the target keyword ciphertext summary does not exist in the server, determining a second keyword ciphertext corresponding to the first original data ciphertext summary by the server if the first original data ciphertext summary matched with the target keyword ciphertext summary exists in the server, determining an original data ciphertext corresponding to the second keyword ciphertext as the target original data ciphertext, and issuing the target original data ciphertext to the terminal;
and when receiving the target original data ciphertext fed back by the server in response to the retrieval operation, the terminal decrypts the target original data ciphertext according to a decryption algorithm corresponding to the encryption algorithm to obtain target original data.
The system has the same advantages as the ciphertext retrieval method and the ciphertext retrieval device compared with the prior art, and the advantages are not repeated here.
The foregoing description is only an overview of the present invention, and is intended to be implemented in accordance with the teachings of the present invention in order that the same may be more clearly understood and to make the same and other objects, features and advantages of the present invention more readily apparent.
Drawings
Various other advantages and benefits will become apparent to those of ordinary skill in the art upon reading the following detailed description of the preferred embodiments. The drawings are only for purposes of illustrating the preferred embodiments and are not to be construed as limiting the invention. Also, like reference numerals are used to designate like parts throughout the figures. In the drawings:
FIG. 1 shows a flowchart of the steps of a first ciphertext retrieval embodiment in accordance with the invention;
FIG. 2 is a flowchart showing steps of a second embodiment of a ciphertext retrieval method in accordance with the present invention;
FIG. 3 illustrates an implementation schematic of an embodiment of the present application;
fig. 4 is a flowchart illustrating a step of encrypting data and uploading a cloud end by a terminal in an embodiment of the present application;
FIG. 5 is a flowchart illustrating steps of a terminal initiating ciphertext retrieval in an embodiment of the present application;
FIG. 6 is a flowchart illustrating steps of retrieving ciphertext data by a cloud end in an embodiment of the present application;
fig. 7 is a block diagram showing the construction of a third embodiment of a ciphertext retrieval apparatus according to the present invention;
fig. 8 is a block diagram showing a constitution of a fourth embodiment of a ciphertext retrieval apparatus according to the present invention.
Detailed Description
Exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
Example 1
Referring to fig. 1, a flowchart of a step of an embodiment of a ciphertext retrieval method according to the present invention is shown, where the terminal is communicatively connected to a server, and the server stores an original data ciphertext, the original data ciphertext abstract, and a keyword ciphertext abstract of the original data according to an association relationship, where the original data is original data corresponding to the original data ciphertext; specifically, steps 101 to 105 may be included.
The embodiment of the invention is applied to a terminal, the terminal can be a mobile terminal, a computer and the like, the server can be a remote server for providing service, for example, a background server corresponding to an application program, and the server is used for storing file data. The server and the terminal are in communication connection through a wireless network, a wired network and the like.
The server stores an original data ciphertext, an original data ciphertext abstract and a keyword ciphertext abstract of the original data according to the association relation, wherein the original data is the original data corresponding to the original data ciphertext, namely the original data is encrypted to obtain the original data ciphertext, the server stores the original data ciphertext, the original data ciphertext abstract corresponding to the original data ciphertext and the keyword ciphertext abstract of the original data, and the association relation among the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract.
The encryption algorithm of the original data ciphertext obtained after the original data is encrypted and the keyword ciphertext generated by the keyword encryption of the original data is the same, and specifically, the terminal generates a key for encrypting and decrypting the data through PKI. If an asymmetric cryptographic algorithm SM2 is adopted, a public-private key pair is generated, and when encryption is carried out, the data is encrypted by adopting a private key and decrypted by adopting a public key; if the symmetric cryptographic algorithm SM4 is adopted, a master key is generated, and the data is encrypted and decrypted by using the master key.
The original data ciphertext abstract is generated by the original data ciphertext through a text similarity algorithm, the search key words are obtained by extracting representative key words from the original data, the key word ciphertext abstract is generated by the search key words through the text similarity algorithm, and the text similarity algorithm can be particularly a simHASH algorithm.
In practical application, the terminal establishes an association relationship among the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data, and uploads the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data to the server for storage according to the association relationship.
Step 101, obtaining a target keyword corresponding to target original data.
The target original data refers to original data to be acquired, and the target keywords are keywords contained in the target original data.
In a specific embodiment, the terminal stores a keyword list, where the keyword list includes keywords corresponding to different original data, and the step 101 specifically includes:
and acquiring target keywords corresponding to the target original data from the keyword list.
In this embodiment, when the user needs to obtain the target original data from the server, the keywords of the target original data, that is, the target keywords, are first found out from the local keyword list.
And 102, encrypting the target keyword by adopting an encryption algorithm to generate a target keyword ciphertext.
The encryption algorithm is the same as the encryption algorithm for encrypting the original data to generate the original data ciphertext, and encrypts the target keyword to generate the ciphertext corresponding to the target keyword, namely the target keyword ciphertext.
And step 103, generating the ciphertext abstract of the target keyword by adopting a text similarity algorithm.
And processing the target keyword by adopting the text similarity algorithm which is the same as that for generating the keyword ciphertext abstract from the search keyword, and generating the target keyword ciphertext abstract.
And 104, initiating a search operation to the server, wherein the search operation carries the target keyword ciphertext abstract so that the server can search the target original data ciphertext corresponding to the target keyword ciphertext abstract according to the association relation.
When a user needs to retrieve and acquire target original data through a server, a retrieval instruction is sent to a terminal, and when the terminal receives the retrieval instruction, the terminal initiates a ciphertext abstract carrying a target keyword corresponding to the target keyword to the server; after receiving the search operation, the server searches whether the original data ciphertext corresponding to the target keyword ciphertext abstract exists or not, namely the target original data ciphertext, according to the target keyword ciphertext abstract and the association relation; and when the target original data ciphertext corresponding to the target keyword ciphertext abstract exists, the server sends the target original data ciphertext back to the terminal initiating the search instruction.
And 105, decrypting the target original data ciphertext according to a decryption algorithm corresponding to the encryption algorithm when receiving the target original data ciphertext fed back by the server in response to the retrieval operation, so as to obtain target original data.
Under the condition that the target original data ciphertext sent by the server in response to the search operation is received, the target original data ciphertext is indicated to be the original data ciphertext corresponding to the target keyword selected by the user in the step, so that the terminal decrypts the target original data ciphertext according to a decryption algorithm corresponding to the encryption algorithm, and corresponding target original data, namely, the original data required by the user can be obtained.
For example, if the encryption algorithm is an asymmetric cryptographic algorithm SM2, decrypting the target original data ciphertext digest using a public key of a public-private key pair; and if the encryption algorithm adopts a symmetric encryption algorithm SM4, decrypting the target original data ciphertext abstract by using a master key.
According to the ciphertext retrieval method and system, the original data ciphertext abstract and the keyword ciphertext abstract of the original data are stored in the server in advance according to the association relation, so that when the original data of the target are required to be obtained, only the target keyword corresponding to the original data of the target is required to be encrypted, the corresponding target keyword ciphertext abstract is generated according to the text similarity algorithm and sent to the server, the corresponding original data ciphertext of the target can be accurately retrieved according to the association relation by the server, the original data ciphertext of the target is sent to the terminal, the original data ciphertext of the target can be quickly and accurately obtained by the terminal only by downloading and decrypting the original data ciphertext of the target, and then the problem that network resources and terminal resources occupy a large amount and the processing time is overlong due to the fact that the ciphertext data of the whole amount are required to be decrypted in the prior art is avoided.
Optionally, in an implementation manner, the ciphertext retrieval method provided by the embodiment of the present invention further includes steps 001 to 008 before the step 101.
The steps 001 to 008 are the processes of storing the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data in the server according to the association relation.
And 001, acquiring the original data to be stored.
The original data to be stored is the original data to be uploaded to the server for storage.
And step 002, encrypting the original data to be stored by adopting the encryption algorithm to obtain an original data ciphertext.
And processing the original data to be stored by adopting the same encryption algorithm as that in the previous step to obtain a ciphertext corresponding to the original data to be stored.
And step 003, generating the original data ciphertext abstract according to the original data ciphertext by adopting the text similarity algorithm.
And processing the original data ciphertext by adopting the text similarity algorithm which is the same as that in the previous step, and obtaining summary data corresponding to the ciphertext, namely the original data ciphertext summary.
Step 004, obtaining the search keywords in the original data.
The terminal extracts representative search keywords from the original data, and performs association mapping on the search keywords and the original data.
And step 005, adding the search keywords to the keyword list.
The terminal establishes a related word list of each original data, and adds a search keyword corresponding to the original data into the keyword list as the search keyword of the original data when uploading the new original data to the server for storage.
Step 006, encrypting the search keyword by adopting the encryption algorithm to generate the keyword ciphertext.
And encrypting the search keyword corresponding to the original data to be stored by adopting the same encryption algorithm as the steps to generate a corresponding keyword ciphertext.
And step 007, generating the keyword ciphertext abstract according to the keyword ciphertext by adopting the text similarity algorithm.
And processing the keyword ciphertext corresponding to the original data to be stored by adopting a text similarity algorithm which is the same as that of the previous steps, and generating a corresponding keyword ciphertext abstract.
And 008, uploading the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract to the server so that the server can store the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data according to the association relation.
The terminal uploads an original data ciphertext corresponding to original data to be stored, an original data ciphertext abstract and a keyword ciphertext abstract to the server according to the association relationship, and the server correspondingly stores the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data according to the association relationship, so that the encryption storage according to the original data can be realized, and after a search keyword corresponding to the original data is determined, the corresponding original data ciphertext is accurately determined according to the keyword ciphertext abstract corresponding to the keyword and the association relationship, and then the original data ciphertext is issued to the terminal for decryption, so that the terminal side obtains the required original data.
Example two
Referring to fig. 2, a flowchart of a step of a second embodiment of a ciphertext retrieval method according to the present invention is applied to a server, where the server is communicatively connected to a terminal, and the server stores, according to an association relationship, an original data ciphertext abstract, and a keyword ciphertext abstract of original data, where the original data is original data corresponding to the original data ciphertext; specifically, the method comprises the following steps 201 to 203:
Step 201, when a search operation initiated by the terminal is received, searching a target original data ciphertext corresponding to the target keyword ciphertext abstract according to a target keyword ciphertext abstract carried by the search operation and the association relation.
When receiving a search operation initiated by a terminal, the terminal indicates that a target original data ciphertext needs to be searched and obtains the target keyword ciphertext abstract corresponding to the target original data to be searched, and when initiating the search operation, the server stores the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data according to the association relation, so that whether the target original data ciphertext corresponding to the target keyword ciphertext abstract exists or not can be searched.
Step 202, determining an original data ciphertext corresponding to the first keyword ciphertext abstract as the target original data ciphertext and issuing the target original data ciphertext to the terminal when the first keyword ciphertext abstract matched with the target keyword ciphertext abstract exists in the server.
And if the matched first keyword ciphertext digest is compared with the stored keyword ciphertext digest, namely the first keyword ciphertext digest which is the same as the target keyword ciphertext digest is stored in the server, searching and determining a target original data ciphertext corresponding to the first keyword ciphertext digest according to the association relation, and sending the target original data ciphertext to the terminal, wherein the terminal can quickly obtain target original data after decrypting.
Step 203, if there is no first keyword ciphertext summary matching with the target keyword ciphertext summary in the server, determining a second keyword ciphertext corresponding to the first original data ciphertext summary if there is a first original data ciphertext summary matching with the target keyword ciphertext summary in the server, determining an original data ciphertext corresponding to the second keyword ciphertext as the target original data ciphertext, and issuing the target original data ciphertext to the terminal.
After comparing the target keyword ciphertext digest with the stored keyword ciphertext digest, if the first keyword ciphertext digest is not matched, that is, if the first keyword ciphertext digest which is the same as the target keyword ciphertext digest is not stored in the server, comparing the target keyword ciphertext digest with the original data ciphertext digest stored in the server, if the matched first original data ciphertext digest is compared, that is, if the first original data ciphertext digest which is the same as the target keyword ciphertext digest is stored in the server, determining a second keyword ciphertext digest corresponding to the first original data ciphertext digest, further determining that the original data ciphertext corresponding to the second keyword ciphertext digest is the target original data ciphertext according to the association relationship, and sending the target original data ciphertext to the terminal.
According to the ciphertext retrieval method, the original data ciphertext abstract and the keyword ciphertext abstract of the original data are stored in the server in advance according to the association relation, so that when a retrieval operation initiated by a terminal is received, the target keyword ciphertext abstract corresponding to the target original data ciphertext can be accurately retrieved according to the target keyword ciphertext abstract and the association relation carried by the retrieval operation, only the matched target original data ciphertext is required to be issued to the terminal, the terminal only needs to download and decrypt the target original data ciphertext, the target original data can be quickly and accurately obtained, and the problems that in the prior art, cloud ciphertext data are required to be downloaded in full quantity, ciphertext data are decrypted in full quantity, and network resources and terminal resources are occupied in large quantity and processing time are excessively long are avoided.
Optionally, in an implementation manner, the ciphertext retrieval method provided in the embodiment of the present application further includes step 204 after the step 201.
And 204, if the first keyword ciphertext abstract matched with the target keyword ciphertext abstract does not exist in the server and the first original data ciphertext abstract matched with the target keyword ciphertext abstract does not exist in the server, feeding back a notice of no matching item to the terminal.
In this embodiment, when there is no first keyword ciphertext digest matching the target keyword ciphertext digest in the server and there is no first original data ciphertext digest matching the target keyword ciphertext digest in the server, it is indicated that there is no original data ciphertext corresponding to the target keyword ciphertext digest, and therefore, a notification without a matching item is issued to the terminal to remind the user to change the search keyword.
In practical application, please refer to fig. 3, which shows an implementation schematic diagram of an embodiment of the present application.
As shown in fig. 3, in step 301, local data is encrypted by a terminal;
in step 302, uploading encrypted ciphertext data to a server by a terminal for cloud storage;
in step 303, the server stores the ciphertext data uploaded by the terminal;
in step 304, the terminal generates a search keyword ciphertext;
in step 305, the terminal sends the keyword ciphertext to the server for cloud storage;
in step 306, the cloud performs ciphertext data retrieval using the keyword ciphertext;
in step 307, the terminal downloads the matched ciphertext data;
in step 308, the terminal decrypts the downloaded partial secret data, thereby obtaining corresponding plaintext data.
Referring to fig. 4, a flowchart of steps for encrypting data and uploading cloud end by a terminal in an embodiment of the present application is shown.
As shown in fig. 4, in step 401, the terminal generates a key for encrypting and decrypting data through (Public Key Infrastructure, PKI), and then encrypts locally stored original data by adopting an asymmetric cryptographic algorithm SM2 or a symmetric cryptographic algorithm SM4 to generate an original data ciphertext;
in step 402, the terminal processes the original data ciphertext by adopting a simHASH algorithm to generate summary data of the original data ciphertext;
in step 403, the terminal extracts the keywords of the original data, specifically, extracts representative keywords from the original data, and performs association mapping on the keywords and the original file to establish an original data association word list;
in step 404, the terminal encrypts the search keyword by using the key to generate a keyword ciphertext;
in step 405, the terminal processes the keyword ciphertext by adopting a simHASH algorithm to generate summary data of the search keyword ciphertext; and uploading the original data ciphertext, the summary data of the original data ciphertext and the summary data of the search keyword ciphertext to the cloud end by the terminal, and establishing an association relation between the original data ciphertext summary and the keyword ciphertext summary.
Referring to fig. 5, a flowchart of a step of a terminal initiating ciphertext retrieval in an embodiment of the present application is shown.
As shown in fig. 5, in step 501, when the terminal needs to retrieve ciphertext data stored in the cloud, a target keyword is found from a retrieval keyword list;
in step 502, a terminal encrypts a search keyword and adopts a simHASH algorithm to generate abstract data of a search keyword ciphertext;
in step 503, the terminal uploads the summary data of the keyword ciphertext to the cloud, and initiates a search operation.
Referring to fig. 6, a flowchart of steps for retrieving ciphertext data by a cloud end in an embodiment of the present application is shown.
As shown in fig. 6, in step 601, the cloud receives summary data of a search keyword ciphertext sent by a terminal;
in step 602, the cloud terminal firstly searches the digest data of the search keyword ciphertext stored in the cloud terminal, if the comparison is successful, the step 604 is entered, otherwise, the step 603 is entered;
in step 603, comparing the ciphertext abstract of the search keyword with the stored ciphertext abstract data of the original data, if the comparison is successful, entering step 604, otherwise, entering step 606;
In step 604, the original data ciphertext corresponding to the keyword ciphertext abstract is retrieved;
in step 605, the original data ciphertext is sent to the terminal;
in step 606, the terminal is informed that there is no match.
Example III
Referring to fig. 7, there is shown a block diagram of a third embodiment of a ciphertext retrieval apparatus according to the present invention, the apparatus being applied to a terminal, the terminal being communicatively connected to a server, the server storing, in association, an original data ciphertext digest, and a keyword ciphertext digest of original data, the original data being original data corresponding to the original data ciphertext; the device comprises:
a first obtaining module 71, configured to obtain a target keyword corresponding to the target original data;
a first encryption module 72, configured to encrypt the target keyword by using an encryption algorithm, and generate a target keyword ciphertext;
a first digest generation module 73, configured to generate a ciphertext digest of the target keyword using a text similarity algorithm;
the search initiating module 74 is configured to initiate a search operation to the server, where the search operation carries the target keyword ciphertext abstract, so that the server searches, according to the association relationship, a target original data ciphertext corresponding to the target keyword ciphertext abstract;
And the first receiving module 75 is configured to decrypt the target original data ciphertext according to a decryption algorithm corresponding to the encryption algorithm when the target original data ciphertext fed back by the server in response to the retrieval operation is received, so as to obtain target original data.
According to the ciphertext retrieval device, the original data ciphertext abstract and the keyword ciphertext abstract of the original data are stored in the server in advance according to the association relation, so that when the original data of the target are required to be obtained, only the target keyword corresponding to the original data of the target is required to be encrypted, the corresponding target keyword ciphertext abstract is generated according to the text similarity algorithm and sent to the server, the corresponding original data ciphertext of the target can be accurately retrieved by the server according to the association relation, the original data ciphertext of the target is sent to the terminal, the terminal only needs to download and decrypt the original data ciphertext of the target, the original data of the target can be quickly and accurately obtained, and the problems that in the prior art, the cloud ciphertext data are required to be downloaded in full quantity, and network resources and terminal resources are occupied in large quantity and the processing time is overlong are avoided.
Optionally, the apparatus further comprises:
the second acquisition module is used for acquiring the original data to be stored before acquiring the target keywords corresponding to the target original data;
the second encryption module is used for encrypting the original data to be stored by adopting the encryption algorithm to obtain an original data ciphertext;
the second abstract generating module is used for generating the original data ciphertext abstract according to the original data ciphertext by adopting the text similarity algorithm;
a third obtaining module, configured to obtain a search keyword in the original data;
an updating module, configured to add the search keyword to the keyword list;
the third encryption module is used for encrypting the search keyword by adopting the encryption algorithm to generate the keyword ciphertext;
the third abstract generating module is used for generating the keyword ciphertext abstract according to the keyword ciphertext by adopting the text similarity algorithm;
and the uploading module is used for uploading the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract to the server so that the server can store the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data according to the association relation.
Optionally, in the device, the terminal stores a keyword list, where the keyword list includes keywords corresponding to different original data;
the first obtaining module 71 is specifically configured to obtain, from the keyword list, a target keyword corresponding to the target original data.
Optionally, in the device, the text similarity algorithm is a simHASH algorithm.
Example IV
Referring to fig. 8, a block diagram of a ciphertext retrieval apparatus according to a fourth embodiment of the present invention is shown, and applied to a server, where the server is communicatively connected to a terminal, and the server stores, in association, an original data ciphertext abstract, and a keyword ciphertext abstract of original data, where the original data is original data corresponding to the original data ciphertext; the device comprises:
the second receiving module 81 is configured to, when receiving a search operation initiated by the terminal, search, according to a target keyword ciphertext abstract carried by the search operation and the association relationship, a target original data ciphertext corresponding to the target keyword ciphertext abstract;
the first retrieving module 82 is configured to determine, when a first keyword ciphertext digest matching the target keyword ciphertext digest exists in the server, an original data ciphertext corresponding to the first keyword ciphertext digest as the target original data ciphertext, and send the target original data ciphertext to the terminal;
And the second retrieving module 83 is configured to determine, if the first keyword ciphertext summary matched with the target keyword ciphertext summary does not exist in the server, a second keyword ciphertext corresponding to the first original data ciphertext summary, determine an original data ciphertext corresponding to the second keyword ciphertext as the target original data ciphertext, and send the target original data ciphertext to the terminal.
Optionally, in an embodiment of the present invention, the apparatus further includes:
and the third retrieval module is used for feeding back the notification of no matching item to the terminal when the first keyword ciphertext abstract matched with the target keyword ciphertext abstract does not exist in the server and the first original data ciphertext abstract matched with the target keyword ciphertext abstract does not exist in the server.
According to the ciphertext retrieval device, the original data ciphertext abstract and the keyword ciphertext abstract of the original data are stored in the server in advance according to the association relation, so that when a retrieval operation initiated by a terminal is received, the target keyword ciphertext abstract corresponding to the target original data ciphertext can be accurately retrieved according to the target keyword ciphertext abstract and the association relation carried by the retrieval operation, only the matched target original data ciphertext is required to be issued to the terminal, the terminal only needs to download and decrypt the target original data ciphertext, the target original data can be quickly and accurately obtained, and the problems that in the prior art, cloud ciphertext data are required to be downloaded in full quantity, ciphertext data are decrypted in full quantity, and network resources and terminal resources are occupied in large quantity and processing time are excessively long are avoided.
Example five
The invention also provides a ciphertext retrieval system, which comprises a server and a terminal, wherein the terminal is in communication connection with the server, the server stores an original data ciphertext, the original data ciphertext abstract and a keyword ciphertext abstract of the original data according to an association relation, and the original data is the original data corresponding to the original data ciphertext;
the terminal acquires a target keyword corresponding to target original data;
the terminal encrypts the target keyword by adopting an encryption algorithm to generate a target keyword ciphertext;
the terminal generates the target keyword ciphertext abstract by adopting a text similarity algorithm;
the terminal initiates a search operation to the server, wherein the search operation carries the target keyword ciphertext abstract;
when receiving a retrieval operation initiated by the terminal, the server retrieves a target original data ciphertext corresponding to the target keyword ciphertext abstract according to a target keyword ciphertext abstract carried by the retrieval operation and the association relation;
under the condition that a first keyword ciphertext abstract matched with the target keyword ciphertext abstract exists in the server, the server determines an original data ciphertext corresponding to the first keyword ciphertext abstract as the target original data ciphertext, and issues the target original data ciphertext to the terminal;
If a first keyword ciphertext summary matched with the target keyword ciphertext summary does not exist in the server, determining a second keyword ciphertext corresponding to the first original data ciphertext summary by the server if the first original data ciphertext summary matched with the target keyword ciphertext summary exists in the server, determining an original data ciphertext corresponding to the second keyword ciphertext as the target original data ciphertext, and issuing the target original data ciphertext to the terminal;
and when receiving the target original data ciphertext fed back by the server in response to the retrieval operation, the terminal decrypts the target original data ciphertext according to a decryption algorithm corresponding to the encryption algorithm to obtain target original data.
For the device and system embodiments, the description is relatively simple as it is substantially similar to the method embodiments, and reference should be made to the description of the method embodiments for relevant points.
The algorithms and displays presented herein are not inherently related to any particular computer, virtual system, or other apparatus. Various general-purpose systems may also be used with the teachings herein. The required structure for a construction of such a system is apparent from the description above. In addition, the present invention is not directed to any particular programming language. It will be appreciated that the teachings of the present invention described herein may be implemented in a variety of programming languages, and the above description of specific languages is provided for disclosure of enablement and best mode of the present invention.
In the description provided herein, numerous specific details are set forth. However, it is understood that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.
Similarly, it should be appreciated that in the foregoing description of exemplary embodiments of the invention, various features of the invention are sometimes grouped together in a single embodiment, figure, or description thereof for the purpose of streamlining the disclosure and aiding in the understanding of one or more of the various inventive aspects. However, the disclosed method should not be construed as reflecting the intention that: i.e., the claimed invention requires more features than are expressly recited in each claim. Rather, as the following claims reflect, inventive aspects lie in less than all features of a single foregoing disclosed embodiment. Thus, the claims following the detailed description are hereby expressly incorporated into this detailed description, with each claim standing on its own as a separate embodiment of this invention.
Those skilled in the art will appreciate that the modules in the apparatus of the embodiments may be adaptively changed and disposed in one or more apparatuses different from the embodiments. The modules or units or components of the embodiments may be combined into one module or unit or component and, furthermore, they may be divided into a plurality of sub-modules or sub-units or sub-components. Any combination of all features disclosed in this specification (including any accompanying claims, abstract and drawings), and all of the processes or units of any method or apparatus so disclosed, may be used in combination, except insofar as at least some of such features and/or processes or units are mutually exclusive. Each feature disclosed in this specification (including any accompanying claims, abstract and drawings), may be replaced by alternative features serving the same, equivalent or similar purpose, unless expressly stated otherwise.
Furthermore, those skilled in the art will appreciate that while some embodiments described herein include some features but not others included in other embodiments, combinations of features of different embodiments are meant to be within the scope of the invention and form different embodiments. For example, in the following claims, any of the claimed embodiments can be used in any combination.
Various component embodiments of the invention may be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. Those skilled in the art will appreciate that some or all of the functions of some or all of the components in a file downloading device according to embodiments of the present invention may be implemented in practice using a microprocessor or Digital Signal Processor (DSP). The present invention can also be implemented as an apparatus or device program (e.g., a computer program and a computer program product) for performing a portion or all of the methods described herein. Such a program embodying the present invention may be stored on a computer readable medium, or may have the form of one or more signals. Such signals may be downloaded from an internet website, provided on a carrier signal, or provided in any other form.
It should be noted that the above-mentioned embodiments illustrate rather than limit the invention, and that those skilled in the art will be able to design alternative embodiments without departing from the scope of the appended claims. In the claims, any reference signs placed between parentheses shall not be construed as limiting the claim. The word "comprising" does not exclude the presence of elements or steps not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention may be implemented by means of hardware comprising several distinct elements, and by means of a suitably programmed computer. In the unit claims enumerating several means, several of these means may be embodied by one and the same item of hardware. The use of the words first, second, third, etc. do not denote any order. These words may be interpreted as names.
Claims (8)
1. The ciphertext retrieval method is applied to a terminal, the terminal is in communication connection with a server, the server stores an original data ciphertext, an original data ciphertext abstract and a keyword ciphertext abstract of the original data according to an association relation, and the original data is the original data corresponding to the original data ciphertext; characterized in that the method comprises:
Acquiring a target keyword corresponding to target original data;
encrypting the target keyword by adopting an encryption algorithm to generate a target keyword ciphertext;
generating a target keyword ciphertext abstract by adopting a text similarity algorithm;
initiating a search operation to the server, wherein the search operation carries the target keyword ciphertext abstract so that the server can search a target original data ciphertext corresponding to the target keyword ciphertext abstract according to the association relation;
when the target original data ciphertext fed back by the server in response to the retrieval operation is received, decrypting the target original data ciphertext according to a decryption algorithm corresponding to the encryption algorithm to obtain target original data;
before the target keywords corresponding to the target original data are acquired, the method further comprises the following steps:
acquiring original data to be stored;
encrypting the original data to be stored by adopting the encryption algorithm to obtain an original data ciphertext;
generating the original data ciphertext abstract according to the original data ciphertext by adopting the text similarity algorithm;
acquiring a search keyword in the original data;
adding the search keywords to a keyword list;
Encrypting the search keyword by adopting the encryption algorithm to generate a keyword ciphertext;
generating a keyword ciphertext abstract according to the keyword ciphertext by adopting the text similarity algorithm;
uploading the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract to the server so that the server can store the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data according to the association relation.
2. The method according to claim 1, wherein the terminal stores the keyword list, and the keyword list includes keywords corresponding to different original data;
the obtaining the target keywords corresponding to the target original data further comprises:
and acquiring target keywords corresponding to the target original data from the keyword list.
3. The method of claim 1, wherein the text similarity algorithm is a simHASH algorithm.
4. The ciphertext retrieval method is applied to a server, the server is in communication connection with a terminal, the server stores an original data ciphertext, an original data ciphertext abstract and a keyword ciphertext abstract of the original data according to an association relation, and the original data is the original data corresponding to the original data ciphertext; characterized in that the method comprises:
When a search operation initiated by the terminal is received, searching a target original data ciphertext corresponding to the target keyword ciphertext abstract according to a target keyword ciphertext abstract carried by the search operation and the association relation;
under the condition that a first keyword ciphertext abstract matched with the target keyword ciphertext abstract exists in the server, determining an original data ciphertext corresponding to the first keyword ciphertext abstract as the target original data ciphertext, and transmitting the target original data ciphertext to the terminal;
if a first keyword ciphertext summary matched with the target keyword ciphertext summary does not exist in the server, determining a second keyword ciphertext corresponding to the first original data ciphertext summary, determining an original data ciphertext corresponding to the second keyword ciphertext as the target original data ciphertext, and issuing the target original data ciphertext to the terminal;
the server acquires an original data ciphertext, the original data ciphertext abstract and a keyword ciphertext abstract of the original data from the terminal, and the method comprises the following steps: the terminal acquires a search keyword in the original data; the terminal adds the search keywords to a keyword list; the terminal encrypts the search keyword by adopting an encryption algorithm to generate a keyword ciphertext; the terminal adopts a text similarity algorithm, and generates a keyword ciphertext abstract according to the keyword ciphertext; uploading the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract to the server so that the server can store the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data according to the association relation.
5. The method according to claim 4, wherein the method further comprises:
and if the first keyword ciphertext abstract matched with the target keyword ciphertext abstract does not exist in the server and the first original data ciphertext abstract matched with the target keyword ciphertext abstract does not exist in the server, a notice without a matching item is fed back to the terminal.
6. The ciphertext retrieval device is applied to a terminal, the terminal is in communication connection with a server, the server stores an original data ciphertext, an original data ciphertext abstract and a keyword ciphertext abstract of the original data according to an association relation, and the original data is the original data corresponding to the original data ciphertext; characterized in that the device comprises:
the first acquisition module is used for acquiring target keywords corresponding to target original data;
the first encryption module is used for encrypting the target keyword by adopting an encryption algorithm to generate a target keyword ciphertext;
the first abstract generation module is used for generating a target keyword ciphertext abstract by adopting a text similarity algorithm;
the search initiating module is used for initiating search operation to the server, wherein the search operation carries the target keyword ciphertext abstract so that the server can search the target original data ciphertext corresponding to the target keyword ciphertext abstract according to the association relation;
The first receiving module is used for decrypting the target original data ciphertext according to a decryption algorithm corresponding to the encryption algorithm when receiving the target original data ciphertext fed back by the server in response to the retrieval operation, so as to obtain target original data;
wherein the apparatus further comprises:
the second acquisition module is used for acquiring the original data to be stored before acquiring the target keywords corresponding to the target original data;
the second encryption module is used for encrypting the original data to be stored by adopting the encryption algorithm to obtain an original data ciphertext;
the second abstract generating module is used for generating the original data ciphertext abstract according to the original data ciphertext by adopting the text similarity algorithm;
a third obtaining module, configured to obtain a search keyword in the original data;
an updating module, configured to add the search keyword to a keyword list;
the third encryption module is used for encrypting the search keyword by adopting the encryption algorithm to generate a keyword ciphertext;
the third abstract generating module is used for generating the keyword ciphertext abstract according to the keyword ciphertext by adopting the text similarity algorithm;
And the uploading module is used for uploading the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract to the server so that the server can store the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data according to the association relation.
7. The ciphertext retrieval device is applied to a server, the server is in communication connection with a terminal, the server stores an original data ciphertext, an original data ciphertext abstract and a keyword ciphertext abstract of the original data according to an association relation, and the original data is the original data corresponding to the original data ciphertext; characterized in that the device comprises:
the second receiving module is used for searching a target original data ciphertext corresponding to the target keyword ciphertext abstract according to the target keyword ciphertext abstract carried by the searching operation and the association relation when receiving the searching operation initiated by the terminal;
the first retrieval module is used for determining an original data ciphertext corresponding to the first keyword ciphertext abstract as the target original data ciphertext and transmitting the target original data ciphertext to the terminal under the condition that a first keyword ciphertext abstract matched with the target keyword ciphertext abstract exists in the server;
The second search module is configured to determine, if a first keyword ciphertext digest that matches the target keyword ciphertext digest does not exist in the server, a second keyword ciphertext corresponding to the first original data ciphertext digest, determine an original data ciphertext corresponding to the second keyword ciphertext as the target original data ciphertext, and send the target original data ciphertext to the terminal;
the server acquires an original data ciphertext, the original data ciphertext abstract and a keyword ciphertext abstract of the original data from the terminal, and the method comprises the following steps: the terminal acquires a search keyword in the original data; the terminal adds the search keywords to a keyword list; the terminal encrypts the search keyword by adopting an encryption algorithm to generate a keyword ciphertext; the terminal adopts a text similarity algorithm, and generates a keyword ciphertext abstract according to the keyword ciphertext; uploading the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract to the server so that the server can store the original data ciphertext, the original data ciphertext abstract and the keyword ciphertext abstract of the original data according to the association relation.
8. The ciphertext retrieval system is characterized by comprising a server and a terminal, wherein the terminal is in communication connection with the server, the server stores an original data ciphertext, an original data ciphertext abstract and a keyword ciphertext abstract of the original data according to an association relation, and the original data is the original data corresponding to the original data ciphertext;
the terminal acquires a target keyword corresponding to target original data;
the terminal encrypts the target keyword by adopting an encryption algorithm to generate a target keyword ciphertext;
the terminal generates a target keyword ciphertext abstract by adopting a text similarity algorithm;
the terminal initiates a search operation to the server, wherein the search operation carries the target keyword ciphertext abstract;
when receiving a retrieval operation initiated by the terminal, the server retrieves a target original data ciphertext corresponding to the target keyword ciphertext abstract according to a target keyword ciphertext abstract carried by the retrieval operation and the association relation;
under the condition that a first keyword ciphertext abstract matched with the target keyword ciphertext abstract exists in the server, the server determines an original data ciphertext corresponding to the first keyword ciphertext abstract as the target original data ciphertext, and issues the target original data ciphertext to the terminal;
If a first keyword ciphertext summary matched with the target keyword ciphertext summary does not exist in the server, determining a second keyword ciphertext corresponding to the first original data ciphertext summary by the server if the first original data ciphertext summary matched with the target keyword ciphertext summary exists in the server, determining an original data ciphertext corresponding to the second keyword ciphertext as the target original data ciphertext, and issuing the target original data ciphertext to the terminal;
and when receiving the target original data ciphertext fed back by the server in response to the retrieval operation, the terminal decrypts the target original data ciphertext according to a decryption algorithm corresponding to the encryption algorithm to obtain target original data.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110747763.2A CN113449321B (en) | 2021-07-01 | 2021-07-01 | Ciphertext retrieval method, device and system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110747763.2A CN113449321B (en) | 2021-07-01 | 2021-07-01 | Ciphertext retrieval method, device and system |
Publications (2)
Publication Number | Publication Date |
---|---|
CN113449321A CN113449321A (en) | 2021-09-28 |
CN113449321B true CN113449321B (en) | 2024-04-05 |
Family
ID=77814803
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110747763.2A Active CN113449321B (en) | 2021-07-01 | 2021-07-01 | Ciphertext retrieval method, device and system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113449321B (en) |
Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2002123692A (en) * | 2000-10-16 | 2002-04-26 | Canon Inc | Electronic data providing system and electronic data providing method |
CN101561815A (en) * | 2009-05-19 | 2009-10-21 | 华中科技大学 | Distributed cryptograph full-text retrieval system |
JP2011234050A (en) * | 2010-04-26 | 2011-11-17 | Mitsubishi Electric Corp | Information processing unit and program |
CN102664739A (en) * | 2012-04-26 | 2012-09-12 | 杜丽萍 | PKI (Public Key Infrastructure) implementation method based on safety certificate |
CN104967693A (en) * | 2015-07-15 | 2015-10-07 | 中南民族大学 | Document similarity calculation method facing cloud storage based on fully homomorphic password technology |
CN105743888A (en) * | 2016-01-22 | 2016-07-06 | 河南理工大学 | Agent re-encryption scheme based on keyword research |
CN106407447A (en) * | 2016-09-30 | 2017-02-15 | 福州大学 | Simhash-based fuzzy sequencing searching method for encrypted cloud data |
CN111726363A (en) * | 2020-06-24 | 2020-09-29 | 暨南大学 | Attribute-based multi-user connection keyword searchable encryption method |
CN112233666A (en) * | 2020-10-22 | 2021-01-15 | 中国科学院信息工程研究所 | Method and system for storing and retrieving Chinese voice ciphertext in cloud storage environment |
-
2021
- 2021-07-01 CN CN202110747763.2A patent/CN113449321B/en active Active
Patent Citations (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2002123692A (en) * | 2000-10-16 | 2002-04-26 | Canon Inc | Electronic data providing system and electronic data providing method |
CN101561815A (en) * | 2009-05-19 | 2009-10-21 | 华中科技大学 | Distributed cryptograph full-text retrieval system |
JP2011234050A (en) * | 2010-04-26 | 2011-11-17 | Mitsubishi Electric Corp | Information processing unit and program |
CN102664739A (en) * | 2012-04-26 | 2012-09-12 | 杜丽萍 | PKI (Public Key Infrastructure) implementation method based on safety certificate |
CN104967693A (en) * | 2015-07-15 | 2015-10-07 | 中南民族大学 | Document similarity calculation method facing cloud storage based on fully homomorphic password technology |
CN105743888A (en) * | 2016-01-22 | 2016-07-06 | 河南理工大学 | Agent re-encryption scheme based on keyword research |
CN106407447A (en) * | 2016-09-30 | 2017-02-15 | 福州大学 | Simhash-based fuzzy sequencing searching method for encrypted cloud data |
CN111726363A (en) * | 2020-06-24 | 2020-09-29 | 暨南大学 | Attribute-based multi-user connection keyword searchable encryption method |
CN112233666A (en) * | 2020-10-22 | 2021-01-15 | 中国科学院信息工程研究所 | Method and system for storing and retrieving Chinese voice ciphertext in cloud storage environment |
Also Published As
Publication number | Publication date |
---|---|
CN113449321A (en) | 2021-09-28 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11706026B2 (en) | Location aware cryptography | |
CN108123800B (en) | Key management method, key management device, computer equipment and storage medium | |
US9197613B2 (en) | Document processing method and system | |
CA2517209A1 (en) | Providing certificate matching in a system and method for searching and retrieving certificates | |
CN108038128B (en) | Retrieval method, system, terminal equipment and storage medium of encrypted file | |
US10698940B2 (en) | Method for searching for multimedia file, terminal device, and server | |
CN111258602B (en) | Information updating method and device | |
US11038692B2 (en) | Digital data locker system providing enhanced security and protection for data storage and retrieval | |
KR101623742B1 (en) | Method and system for sharing file related messages | |
CN113254982B (en) | Secret track query method and system supporting keyword query | |
CN115225409B (en) | Cloud data safety duplicate removal method based on multi-backup joint verification | |
CN106789008B (en) | Method, device and system for decrypting sharable encrypted data | |
CN111339206B (en) | Block chain-based data sharing method and device | |
JP2013235465A (en) | File processing system | |
CN111767550B (en) | Data storage method and device | |
JP6585192B2 (en) | Retrieval and retrieval of keyed data maintained using a keyed database | |
CN113449321B (en) | Ciphertext retrieval method, device and system | |
CN103138922B (en) | A kind of method, system and device of digital content transmissions | |
US10296760B2 (en) | System of shared secure data storage and management | |
JP2019505009A5 (en) | ||
CN110851794A (en) | Media file uplink method and device, storage medium and electronic device | |
CN115510490A (en) | Method, device, system and equipment for inquiring encrypted data shared by non-secret keys | |
CN110351262B (en) | Data interaction method and device and electronic equipment | |
EP3998790A1 (en) | Systems and methods for protecting data | |
CN106533674B (en) | The sharing method of encryption data, apparatus and system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |