CN111711671A - Cloud storage method for efficient ciphertext file updating based on blind storage - Google Patents

Cloud storage method for efficient ciphertext file updating based on blind storage Download PDF

Info

Publication number
CN111711671A
CN111711671A CN202010486723.2A CN202010486723A CN111711671A CN 111711671 A CN111711671 A CN 111711671A CN 202010486723 A CN202010486723 A CN 202010486723A CN 111711671 A CN111711671 A CN 111711671A
Authority
CN
China
Prior art keywords
file
block
data blocks
client
random
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.)
Granted
Application number
CN202010486723.2A
Other languages
Chinese (zh)
Other versions
CN111711671B (en
Inventor
路松峰
刘奇
方欣
潘国阳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Huazhong University of Science and Technology Research Institute
Original Assignee
Shenzhen Huazhong University of Science and Technology Research Institute
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Shenzhen Huazhong University of Science and Technology Research Institute filed Critical Shenzhen Huazhong University of Science and Technology Research Institute
Priority to CN202010486723.2A priority Critical patent/CN111711671B/en
Publication of CN111711671A publication Critical patent/CN111711671A/en
Application granted granted Critical
Publication of CN111711671B publication Critical patent/CN111711671B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1097Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/04Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks
    • H04L63/0428Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks wherein the data content is protected, e.g. by encrypting or encapsulating the payload
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/104Peer-to-peer [P2P] networks
    • H04L67/1074Peer-to-peer [P2P] networks for supporting data block transmission mechanisms
    • H04L67/1078Resource delivery mechanisms
    • H04L67/108Resource delivery mechanisms characterised by resources being split in blocks or fragments
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/50Reducing energy consumption in communication networks in wire-line communication networks, e.g. low power modes or reduced link rate

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Hardware Design (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Storage Device Security (AREA)

Abstract

The invention discloses a cloud storage method for efficient ciphertext file updating based on blind storage. The invention improves the traditional blind storage method for resisting the access mode leakage in the cloud environment, so that the environment is suitable for efficient and frequent updating of files. The method comprises the following steps: a storage construction algorithm suitable for the method; a file upload protocol; an incremental encryption scheme, a decryption scheme, for the file; a file download protocol; file update protocol method. The method can effectively improve the efficiency of frequent file updating operation of the ciphertext cloud storage, ensures the safe storage of data, does not expose any information to the server, and can be used for a distributed storage scheme.

Description

Cloud storage method for efficient ciphertext file updating based on blind storage
Technical Field
The invention relates to the technical field of internet, in particular to a cloud storage method for efficient ciphertext file updating based on blind storage.
Background
With the development of cloud computing, the data generation speed and the data circulation speed are obviously increased, and a big data era has come. The data has the characteristics of large scale, multiple data types, high speed requirement, low value density and the like, and is not stored in a centralized manner like a traditional information system any more, and new modes such as cloud computing, distributed storage and the like are widely adopted. As a third-party platform, cloud storage is an untrusted storage service, and the security of data may not be guaranteed. Malicious third parties or system administrators can eavesdrop or acquire sensitive data, data leakage can be caused by access control bugs, and data leakage can be caused by the fact that physical storage equipment is stolen or lost. The best method for solving the data security in the cloud storage environment is to encrypt the data, and in order to enable a user to use the cloud storage service with confidence, a cloud service provider provides various schemes for protecting the data security, but at present, the data leakage event of the cloud storage is frequent, and the data security is guaranteed to become a problem which needs to be solved in the cloud storage.
The Blind storage (Blind storage) is a mechanism for storing user data at a cloud server side and ensuring that the cloud server cannot acquire user data information, and solves the problem that an access mode is leaked by a remote server in the file access process. When the client and the server interact, the server does not know the specific content of the document blocks and the document to which each block belongs, and only needs to upload and download the document blocks and a small amount of matching operation, and a large amount of encryption and decryption calculation tasks are performed locally, so that the risk of information leakage is reduced, and a strong safety foundation is laid.
However, uploading the real blocks and the obfuscated blocks to the server together tends to increase the storage space of the server, and in the existing ciphertext file storage scheme, basic modification operations on files include adding, deleting and querying. Modification of an encrypted file in an original blind storage scheme can cause an avalanche effect to exist in decryption and encryption operations of the whole file, namely tiny changes of a plaintext or a secret key can cause great changes of ciphertext binary contents, and file processing and synchronization efficiency is reduced. The existing method does not deal with how to improve the synchronous updating efficiency.
Disclosure of Invention
The invention aims to provide a cloud storage method for efficiently updating a ciphertext file based on blind storage, aiming at the defects in the prior art.
In order to achieve the above object, the present invention provides a cloud storage method for efficient ciphertext file update based on blind storage, which comprises the following steps:
step S1: the server side constructs a specific form of storage space to save all file sets,
step S2: the client carries out variable-length block processing and encryption on a file to be uploaded based on file content to generate ciphertext data blocks with different sizes and random sequences, and the ciphertext data blocks are indexed according to the random sequences and stored in the storage space;
step S3: the client side retrieves a random sequence generated by the file identification and reads the ciphertext data blocks for multiple times to obtain all the ciphertext data blocks of the file from the storage space, and decrypts the ciphertext data blocks in the client side to restore the ciphertext data blocks into a complete file;
step S4: and modifying the downloaded file and uploading the modified downloaded file to the server side again.
Further, the step S1 specifically includes:
step 1.1, sending application information for constructing a storage space to a server through a client;
step 1.2, the server constructs a group nSEach size is mSA storage space S composed of data blocks with bit sizes;
and step 1.3, initializing all the nodes to be 0, and returning a creating result to the client.
Further, the step S2 specifically includes:
step 2.1, carrying out content-based variable-length blocking processing on each file f to convert the file f into data blocks with different sizes, wherein the number of the data blocks is sizef
Step 2.2, constructing the unique identification id of the file f according to the information of the file ffAccording to the unique identification id of the filefGenerating seed sigma using a fully-defined-field pseudorandom functionfSeed σfInput pseudo-random generatorForming a random sequence;
step 2.3, based on the random sequence and the data block number sizefGenerating a random subset SfWherein the subset S is randomfBelonging to a storage space, will SfAs the first of the random sequences in step 2.2, the length is | SfAn integer set of | where,
Figure BDA0002519389660000021
kappa is the minimum data block number accessed in each time in the storage, and α is the expansion coefficient of the storage;
step 2.4, in random subset SfSize selectionfShortest prefixes of retrievable empty data blocks as subsets
Figure BDA0002519389660000031
Is the size of the data block number sizefClient follows subset for the first time
Figure BDA0002519389660000032
Establishing an index relationship between the increasing sequence of the retrieved numbers and the data blocks in step 2.1;
step 2.5, adding header information for each variable length block of the f of the file, generating a file key by using a pseudorandom function, and encrypting each data block by adopting an AES (advanced encryption Standard) symmetric encryption algorithm;
and 2.6, the client sends the encrypted data block to the server, and the server stores the encrypted data block into a storage position of the storage space according to the index relation established in the step 2.4.
Further, the step 2.1 specifically includes:
step 2.1.1, the client sets two integers d and r based on Rabin fingerprint algorithm, selects a fixed sliding window W, sets a size parameter of m bytes, and sets a maximum block length maxBMinimum block length minB
Step 2.1.2, reading the file f content of the client byte by byte into the sliding window W, and calculating the hash value R in the sliding window W according to the Rabin fingerprint algorithmbreakpoint(ii) a When R isbreakpointWhen mod d is equal to r, a breakpoint is reached, and a block is formed between two adjacent breakpoints;
step 2.1.3, the client records the block number i and the breakpoint position index of the current blockbSize of the block contentbAnd taking the hash value H (block) of the data in the block as the information of the current block, and repeating the step 2.1.2 until the whole file f is completely changed into data blocks with different sizes;
step 2.1.4, the client obtains the information of all the data blocks of the file f, and the size of the number of the data blocksfAnd finishing the storage pretreatment of the file f.
Further, the step S3 specifically includes:
step 3.1, the client acquires the unique identification id of the file f according to the file informationfAccording to the unique identification id of the file ffGenerating seed sigma using a fully-defined-field pseudorandom functionfSeed σfInputting a pseudo-random generator to obtain a random sequence;
step 3.2, the client generates a first integer set S with the length of kappa according to the random sequencef 0Initiating a first round of interaction to the server;
step 3.3, the server side returns the ciphertext data block corresponding to the index to the client side;
step 3.4, the client decrypts the returned data block to find the first unique mark as idfAs the first data block of the file f, and obtaining the block size of the file f from the header information of the first data blockf
Step 3.5, the client analyzes the result
Figure BDA0002519389660000033
S indicating that the content of this file has been returned in its entirety in the first interactionf 0]In the step (3), the second visit is not needed, and the step (3.8) is directly carried out, otherwise, the step (3.6) is carried out
Step 3.6, the client side performs size according to the random sequence and the number of the data blocksfGenerating a random set SfInitiating a second round of interaction to the server;
step 3.7, the server side returns the ciphertext data block corresponding to the index to the client side;
and 3.8, the client decrypts all the data blocks and integrates the data blocks into a complete file f according to the header information of the data blocks.
Further, the step S4 specifically includes the following steps:
step 4.1, the client modifies the file information of the downloaded and read file f into f';
step 4.2, for the modified file f ', the unique identifier of the file f' is still idfAnd repeating the variable-length blocking processing based on the file content in the step 2.1 to convert the variable-length blocking processing into updated data blocks with different sizes, wherein the number of the updated data blocks is sizef′
Step 4.3, the client side modifies the unique identification id of the file according to the modificationfAnd generating seed sigma by using a fully-defined-domain pseudo-random functionf′Inputting the seeds into a pseudo-random generator to obtain a new random sequence, and generating a new random sequence with a length of | Sf′Random subset S of integer set of |f′
Step 4.4, the client selects the random subset Sf′A random subset
Figure BDA0002519389660000041
The size is the updated data block number sizef′(ii) a In a random subset Sf′Size selectionf′Shortest prefixes of retrievable empty data blocks as subsets
Figure BDA0002519389660000042
Step 4.5, the client analyzes the data block quantity change of the variable-length block before and after updating the file, and compares the block information of the variable-length block algorithm based on the content of the file f and the modified file f' to form a corresponding table of the file block before and after the file block is updated;
step 4.6, forming the index information of the updated data block according to the new random sequence, updating the header information of all the updated data blocks, and re-encrypting the header information of all the updated data blocks;
and 4.7, sending and storing all updated ciphertext data blocks of the file to the server side according to the new index information.
Further, in the step 4.5:
if the number of the front data block and the rear data block is the same, a new available space set does not need to be searched
Figure BDA0002519389660000043
Replacing the updated inconsistent data blocks;
if the number of update data blocks increases, a new set of available space needs to be found
Figure BDA0002519389660000051
Replacing or storing the updated inconsistent data blocks into the new available space;
if the number of updated data blocks is reduced, a redundant set of available space is required
Figure BDA0002519389660000052
And clearing, namely replacing the updated inconsistent data blocks, and clearing redundant data blocks.
Has the advantages that: the invention improves the traditional blind storage method for resisting the access mode leakage in the cloud environment, so that the environment is suitable for efficient and frequent update of files, the efficiency of frequent update operation of the files by the ciphertext cloud storage can be effectively improved, the safe storage of data is ensured, no information is exposed to a server, and the method can be used for a distributed storage scheme.
Drawings
FIG. 1 is a schematic diagram of an architecture of a cloud storage method for efficient ciphertext file update based on blind storage;
FIG. 2 is a flowchart of the operation of a cloud storage method based on blind storage of efficient ciphertext file updates;
FIG. 3 is a flow diagram of a content-based variable length chunking process;
FIG. 4 is a flow diagram of selecting a file storage data block;
FIG. 5 is a flow diagram of encrypting and uploading a file;
FIG. 6 is a flow chart of a method of downloading a file;
FIG. 7 is a flow chart diagram of a method of updating a file.
Detailed Description
The present invention will be further illustrated with reference to the accompanying drawings and specific examples, which are carried out on the premise of the technical solution of the present invention, and it should be understood that these examples are only for illustrating the present invention and are not intended to limit the scope of the present invention.
As shown in fig. 1 and 2, the embodiment of the present invention comprises two parts of entities: one of the servers is a Client and the other is a Server or a cloud storage service provider. And the User stores the ciphertext file of the file f into the server through the client. The architecture diagram of the storage scheme of the present invention is shown in fig. 1, which shows the interaction relationship between the client and the server. Firstly, a user processes a file f through a client, then encrypts a processed file data block, stores the encrypted data block into a storage structure of a server, and can read a file block corresponding to a retrieved file from the server, combine the file blocks and read the file at the client. The protocol operations such as file uploading, file downloading, file updating and the like can be carried out between the client and the server.
The method comprises the following steps that firstly, a client processes a file f, each file is converted into a format of a plurality of variable-length data blocks, the data blocks have a header with a common length, the length of a data part is variable, and each data block is encrypted; storing all encrypted file data blocks on a storage structure, wherein the part only represents storage file blocks; thirdly, reading the file blocks corresponding to the retrieved files from the storage structure; fourthly, the read data blocks are decrypted and integrated to finally obtain complete file contents; fifthly, local updating operation is carried out on the original text file which is retrieved and downloaded by the user to generate a file, and a new ciphertext block is regenerated; and sixthly, incremental updating is carried out on the file before the storage updating of the server. Part of the program (r) represents the feature step S1, and a storage method is constructed. Representing an uploading protocol method of the file in the characteristic step S2; and fourthly, partially representing a downloading protocol method of the file in the characteristic step S3. Sixthly, part of the file update protocol method in the characteristic step S4 realizes the update protocol of the file in all the previous steps.
For convenience of the following description, the notation and system parameter settings used in the present invention are described herein:
h: a collision-tolerant hash function of the fully defined domain;
phi: a pseudo-random function;
Ψ: a pseudo-random function that fully defines a domain;
: a pseudo-random generator;
r: rabin fingerprint algorithm
nS: number of data blocks of storage space S
mS: size of each data block
d and r: determining two parameters of Rabin fingerprint
minB: minimum number of bytes for variable length block
maxB: maximum number of bytes of variable length block
α: the inflation parameter in storage;
kappa: the minimum data block number accessed in each time in the storage;
specifically, the embodiment of the invention provides a cloud storage method for efficient ciphertext file updating based on blind storage, which is characterized by comprising the following steps:
step S1: the server side constructs a storage space in a specific form so as to save all file sets.
Step S1 specifically includes:
step 1.1, sending application information for constructing a storage space to a server side through a client side.
Step 1.2, the server constructs a group nSEach size is mSA storage space S consisting of bit-sized data blocks. Here the data block size is setMaximum block size max of variable blocks based on content by fileBTogether with the file block header information size.
And step 1.3, initializing all the nodes to be 0, and returning a creating result to the client.
Step S2: the client carries out variable-length block processing and encryption on files to be uploaded based on file contents to generate ciphertext data blocks with different sizes and random sequences, and the ciphertext data blocks are indexed according to the random sequences and stored in a storage space.
With reference to fig. 3 to 5, step S2 specifically includes:
step 2.1, carrying out content-based variable-length blocking processing on each file f to convert the file f into data blocks with different sizes, wherein the number of the data blocks is sizef
Wherein, step 2.1 specifically includes:
step 2.1.1, the client sets two integers d and r based on Rabin fingerprint algorithm, selects a fixed sliding window W, sets a size parameter of m bytes, and sets a maximum block length maxBMinimum block length minB
Step 2.1.2, reading the file f content of the client byte by byte into the sliding window W, and calculating the hash value R in the sliding window W according to the Rabin fingerprint algorithmbreakpoint(ii) a When R isbreakpointWhen mod d is equal to r, a break point is reached, and a block is formed between two adjacent break points.
Step 2.1.3, the client records the block number i and the breakpoint position index of the current blockbSize of the block contentbAnd taking the hash value H (block) of the data in the block as the current block information, and repeating the step 2.1.2 until the whole file f is changed into the data blocks with different sizes.
Step 2.1.4, the client obtains the information of all the data blocks of the file f, and the size of the number of the data blocksfAnd finishing the storage pretreatment of the file f.
Specifically, as shown in fig. 3, the steps are as follows:
if the reading byte of file is over, then go to the word b.
Reading a byte to a sliding window W; the Rabin fingerprint in the sliding window W is updated using the Rabin fingerprint algorithm.
③ calculating whether the distance between the current position and the previous breakpoint position is less than minBIf yes, go to ①.
④ calculating whether the magnitude between the current position and the previous breakpoint position is greater than maxBIf yes, go to ⑦.
⑤ calculation of RbreakpointIf mod d is true, otherwise go to ①.
⑦ the last byte entering the sliding window is breakpoint, the current block is formed between the last byte and the previous breakpoint (the file byte start position 0 is the first breakpoint by default), the block number i and the breakpoint position index are used to index the current blockbSize of block content sizebThe hash value of the data in the block H (block) is taken as the current block information, and the sliding window is cleared and the process jumps to ①.
And (8) finishing reading the file, analyzing whether data exist in the current window, and otherwise, jumping to the capacitor (R).
And ninthly, forming a current block between the ending byte of the file and the previous breakpoint, namely the last block, and recording block information.
The reading of the file block in the r (r) is finished.
Step 2.2, the client constructs the unique identification id of the file according to the information of the file ffObtaining a hash value H (id) corresponding to a unique file according to a collision-resistant hash function H of a fully defined domainf) According to the unique identification id of the filefGenerating a seed σ using a fully-defined-domain pseudorandom function ΨfWherein:
σf=Ψ(idf)
mixing the seeds sigmafAnd inputting the sequence into a pseudo-random generator to obtain a random sequence.
Step 2.3, based on the random sequence and the data block number sizefGenerating a random subset SfWherein S isfBelonging to a storage space, will SfAs the first of the random sequences in step 2.2, the length is | SfInteger set of |。
Specifically, wherein: i Sf| represents a random subset SfThe calculation method is as follows:
Figure BDA0002519389660000084
where κ is the minimum number of data blocks accessed per time in storage, α is the expansion factor of storage, and S is calculated to overcome the conflict between probability of conflict and waste of storage spacefAs the sequence Λ [ sigma ]f,|Sf|]E.g. Λ [ sigma, l]The sequence of integers is obtained by the following analysis method: using seed sigma as input parameter of pseudo-random generator to obtain a sufficiently long output, then [ n ]S]In the range of (1), an integer sequence is analyzed; sfRefers to the first i long distinguishable parameter in this sequence of integers. Detecting a random subset SfSize of the number in the storage space SfWhether each data block is empty; detection of set S of size kappaf 0The number in (1) is at least one data block in the storage space S is empty; if either of the two detection conditions fails, the operation is terminated.
Step 2.4, in random subset SfSize selectionfShortest prefixes of retrievable empty data blocks as subsets
Figure BDA0002519389660000081
Is the size of the data block number sizefI.e. by
Figure BDA0002519389660000082
Client follows subset for the first time
Figure BDA0002519389660000083
The increasing order of the numbers retrieved in step 2.1 establishes an indexing relationship with the data blocks in step 2.1. Detection of
Figure BDA0002519389660000091
In the storage space SIf the detection condition is not passed, the operation is terminated; in a random subset SfSize selectionfShortest prefixes of retrievable empty data blocks as subsets
Figure BDA0002519389660000092
The specific flow of implementing the selection of the file storage block is shown in fig. 4.
And 2.5, adding header information to each variable-length block of the f of the file, generating a file key by using a pseudorandom function, and encrypting each data block by adopting an AES (advanced encryption Standard) symmetric encryption algorithm.
The header information specifically includes: unique file identifier id of filefHash value H (id) of file identificationf) The hash message identification code H (data) of the data content and the byte number of the last group; wherein:
the version number, initially 0, indicates that it has not been updated and is accumulated after updating. The number of the variable length blocks of the file, the first data block comprises the number of the data blocks after the file is converted, and the step of other blocks is always 0. The current block index, the next block index, and the client according to the subset
Figure BDA0002519389660000093
As index information of the data block, adding to the index of the current block and the index of the next block corresponding to the header of the block. And the hash message authentication code of the data content is used for verifying the integrity of the data. Last set of number of bytes: and for each variable-length block, encrypting by adopting a fixed packet symmetric encryption algorithm, filling the last group by adopting 0 byte, and recording the original byte number of the last group of the fixed packet at the head part so as to facilitate decryption and recovery.
The client user uses the pseudo-random function to generate a key to generate a unique key for the file, and the AES-256 symmetric encryption algorithm is adopted to encrypt each block of the file, wherein the ECB mode is adopted to facilitate concurrent computation of a plurality of blocks in the encryption and decryption processes, so that the encryption and decryption efficiency of the file is improved.
And 2.6, the client sends the encrypted data block to the server, and the server stores the encrypted data block into a storage position of the storage space according to the index relation established in the step 2.4. The specific flow is shown in fig. 5.
Step S3: the client side retrieves the random sequence generated by the file identification and reads the ciphertext data blocks for multiple times to obtain all the ciphertext data blocks of the file from the storage space, and decrypts the ciphertext data blocks in the client side to restore the ciphertext data blocks into the complete file. Specifically, as shown in fig. 6, step S3 specifically includes:
step 3.1, the client side obtains the unique identification id of the file f according to the information of the file ffAccording to the unique identification id of the file ffGenerating seed sigma using a fully-defined-field pseudorandom functionfSeed σfInput to a pseudo-random generator to obtain a random sequence, wherein,
Figure BDA0002519389660000101
step 3.2, the client generates an integer set S according to the random sequencef 0And initiating a first round of interaction to the server. Sf 0As the sequence Λ [ sigma ]f,κ]The method of analysis and step 2.3fThe same is true. And 3.3, the server returns the ciphertext data block corresponding to the index to the client. Step 3.4, the client decrypts the returned data block to find the first unique mark as idfAs the first data block of the file f, and obtaining the block size of the file f from the header information of the first data blockf
Specifically, a client user generates a unique key for a file by using a pseudo-random function generation key, and decrypts each block by adopting an AES-256 symmetric encryption algorithm.
Finding the unique file identifier id of the filefThe hash value of the file identifier is H (id)f) If the data block is not found, the server side does not have the file, and the interaction is directly finished;if such a data block is found, this data block is the first data block of the file, and the block size of the file can be obtained from its header informationf
Step 3.5, the client analyzes the result
Figure BDA0002519389660000102
S indicating that the content of this file has been returned in its entirety in the first interactionf 0]And (5) directly entering a step 3.8 without performing second access, otherwise entering a step 3.6.
Step 3.6, the client side performs size according to the random sequence and the number of the data blocksfGenerating a random set SfAnd initiating a second round of interaction to the server. So that the client can all obtain the ciphertext blocks S of the remaining filesf-Sf 0(the relative complement is denoted here as SfBut not to Sf 0). Step 3.7, the server side gathers the ciphertext data blocks (S [ S ]) corresponding to the indexesf-Sf 0]) And returning the data to the client. And 3.8, the client decrypts all the data blocks and integrates the data blocks into a complete file f according to the header information of the data blocks.
Specifically, a client user generates a unique key for a file by using a pseudo-random function generation key, and decrypts each data block of the file by using an AES-256 symmetric encryption algorithm. Then according to the file unique identification of the file in the header information as idfThe hash value of the file identifier is H (id)f) Verifying whether the file is a data block of the file f; and integrating the block sequence number, the data block index and the next data block index in the header information into a complete file in sequence.
Step S4: and modifying the downloaded file and uploading the modified downloaded file to the server side again. The file updating protocol is realized on the basis of the download file protocol, the download file is modified, an incremental updating algorithm is realized, and the efficiency of synchronous updating of the ciphertext is improved.
As shown in fig. 7, step S4 specifically includes the following steps:
step 4.1, the client modifies the file information of the downloaded and read file f into f';
step 4.2, for the modified file f ', the unique identifier of the file f' is still idfObtaining a hash value H (id) corresponding to a unique file according to a collision-resistant hash function H of a fully defined domainf) (ii) a The variable-length blocking processing based on the file content in the step 2.1 is carried out again to convert the variable-length blocking processing into updated data blocks with different sizes, and the number of the updated data blocks is sizef′
Step 4.3, the client side modifies the unique identification id of the file according to the modificationfAnd generating seed sigma by using a fully-defined-domain pseudo-random functionf′
Figure BDA0002519389660000111
Mixing the seeds sigmaf′Inputting into a pseudo-random generator to obtain a new random sequence, and generating a first random sequence with length | Sf′Random subset S of integer set of |f′(ii) a Will Sf′As the sequence Λ [ sigma ]f,|Sf′|]Is selected. The method of analysis and S in step 2.3fThe same; specifically, here | Sf′I always select the pseudo-random subset S of preceding and following filesf′And SfMaximum value of the aggregate size.
Step 4.4, the client selects the random subset Sf′A random subset
Figure BDA0002519389660000112
The size is the updated data block number sizef′I.e. by
Figure BDA0002519389660000113
In a random subset Sf′Size selectionf′Shortest prefixes of retrievable empty data blocks as subsets
Figure BDA0002519389660000114
A file storage block is selected. Here, it is not necessary to determine whether the signal is null, and a specific flow is shown in fig. 4.
And 4.5, the client analyzes the data block quantity change of the variable-length blocks before and after updating the file, and compares the block information of the variable-length block algorithm based on the content of the file f and the modified file f' to form a corresponding table of the file blocks before and after the file block is updated.
Specifically, the modification of the file by the user includes three operations of adding, deleting and modifying. When an original file f is modified at a certain position, the file length-variable blocks of the modified file f' are changed, only the left and right blocks of the modified block of the original file f are changed, and other blocks are not changed, which specifically includes the following steps:
step 4.5.1, displaying the blocking condition of the initial file f, such as [ B ]1,B2,B3,B4,B5];
Step 4.5.2, e.g. for Block B2The modification operation is carried out, and the result does not cause the break point breaking and is not less than the minimum length min of the variable-length blocksBAnd not larger than the maximum length max of the variable length blockBThe result of the modified re-blocking may be [ B ]1,B6,B3,B4,B5]Only block B2Has been changed to B6Other blocks are not changed;
step 4.5.3, e.g. for Block B4A modification operation is carried out, which results in the generation of a new breakpoint that is not less than the minimum length min of the variable-length partitionBAnd not larger than the maximum length max of the variable length blockBThe result of the modified re-blocking may be [ B ]1,B6,B3,B7,B8,B5]Only block B4Changed, newly added blocks become B7,B8Other blocks are not changed;
step 4.5.4, e.g., for block B3Performing a modification operation, resulting in destruction of the original B3Breakpoint and not less than minimum length min of variable length blockBAnd not larger than the maximum length max of the variable length blockBThe result of the modified re-blocking may be [ B ]1,B6,B9,B8,B5]Into blocks B3,B7Changes are made, reducing blocking to B9And other blocks are not changed.
In this way, the block information of the variable-length block algorithm based on the content of the source file and the new file is recorded, and the corresponding tables of the front file block and the rear file block are respectively recorded in the set of the unchanged blocks and the set of the changed blocks.
Specifically, if the number of the front and rear data blocks is the same, the size is obtainedf=sizef′Without the need to find new sets of available space
Figure BDA0002519389660000121
That is at this time | Sf′|=|SfAnd replacing the inconsistent blocks of the updated data.
The method comprises the following specific steps:
obtaining the block information of the source file and the new file based on the content variable length block algorithm according to the step 4.5, such as the original block [ B ]1,B2,B3,B4,B5]Modified block [ B ]1,B6,B3,B7,B5]. The index position is also a random subset of the source file f without finding new storage space
Figure BDA0002519389660000122
The client side counts out a set of changed blocks { B }2,B4Is replaced by { B }6,B7}. Updating the index of the current block at the head of all the blocks according to the corresponding table of the change information of the data blocks, and updating the head index of the next block index; establishing an index of a corresponding block; that is, the client of this example only needs to connect B6Encrypted and then replaced to B2Index position of B, will7Encrypted and then replaced to B4The index position of (2).
If the number of update blocks increases, i.e. sizef<sizef′It is necessary to find a new set of available space
Figure BDA0002519389660000123
That is at this time
Figure BDA0002519389660000125
A new data block storage space needs to be searched, and a block with inconsistent updated data is replaced or stored into a new available space.
The method comprises the following specific steps: obtaining the block information of the source file and the new file based on the content variable length block algorithm according to the step 4.5, such as the original block [ B ]1,B2,B3,B4,B5]Modified block [ B ]1,B6,B3,B7,B8,B5](ii) a New storage space needs to be found to store the newly added encrypted blocks, and the index position is a random subset S of the modified file ff′The client needs to randomly subset S from the serverf′(by definition at this time
Figure BDA0002519389660000126
) In the random sequence obtained from the seeds, find whether there is sizef′-sizefA null block added to the set of digital spaces
Figure BDA0002519389660000124
If the file is not found, the storage space is insufficient, and the storage space needs to be expanded to update the file; the client needs to count the set of changed blocks { B }2,B4Is replaced by { B }6,B7,B8}; updating the number of the variable-length blocks of the file, updating the indexes of the current blocks at the heads of all the blocks according to the data block change information corresponding table, and updating the head indexes of the next blocks; establishing an index of a corresponding block; i.e. in this example B6Alternative B2,B7Alternative B4,B8New data blocks found in the above are added.
If the number of updated data blocks is reduced, i.e. sizef>sizef′Requiring a redundant set of available space
Figure BDA0002519389660000132
Is emptied, i.e. at this time
Figure BDA0002519389660000131
And replacing the updated inconsistent data blocks, and emptying redundant data blocks.
The method comprises the following specific steps: obtaining the block information of the source file and the new file based on the content variable length block algorithm according to the step 4.5, such as the original block [ B ]1,B2,B3,B4,B5]Modified block [ B ]1,B2,B6,B5](ii) a Without finding new storage space, the index position is a random subset S of the modified file ff′The client needs to randomly subset S from the serverf(by definition at this time
Figure BDA0002519389660000133
) In the random sequence obtained by seed searchf-sizef′Redundant blocks, which are emptied; the client needs to count the set of changed blocks { B }3,B4Is replaced by { B }6}; updating the number of the variable-length blocks of the file, updating the indexes of the current blocks at the heads of all the blocks according to the data block change information corresponding table, and updating the head indexes of the next blocks; establishing an index of a corresponding block; i.e. in this example B6Alternative B3Clear B4A block of data.
And 4.6, forming index information of the updated data block according to the new random sequence, updating all updated data block header information (the header information size is far smaller than the data part size, so that updating the data block can be ignored only when updating the part), increasing the version number in the header information of all the data blocks, re-encrypting all the data block headers, and encrypting all the data blocks in the set of the changed blocks.
And 4.7, sending and storing all updated ciphertext data blocks of the file to the server side according to the new index information.
The foregoing is only a preferred embodiment of the present invention, and it should be noted that other parts not specifically described are within the prior art or common general knowledge to those of ordinary skill in the art. Without departing from the principle of the invention, several improvements and modifications can be made, and these improvements and modifications should also be construed as the scope of the invention.

Claims (7)

1. A cloud storage method for efficient ciphertext file updating based on blind storage is characterized by comprising the following steps:
step S1: the server side constructs a specific form of storage space to save all file sets,
step S2: the client carries out variable-length block processing and encryption on a file to be uploaded based on file content to generate ciphertext data blocks with different sizes and random sequences, and the ciphertext data blocks are indexed according to the random sequences and stored in the storage space;
step S3: the client side retrieves a random sequence generated by the file identification and reads the ciphertext data blocks for multiple times to obtain all the ciphertext data blocks of the file from the storage space, and decrypts the ciphertext data blocks in the client side to restore the ciphertext data blocks into a complete file;
step S4: and modifying the downloaded file and uploading the modified downloaded file to the server side again.
2. The cloud storage method for efficient ciphertext file update based on blind storage according to claim 1, wherein the step S1 specifically includes:
step 1.1, sending application information for constructing a storage space to a server through a client;
step 1.2, the server constructs a group nSEach size is mSA storage space S composed of data blocks with bit sizes;
and step 1.3, initializing all the nodes to be 0, and returning a creating result to the client.
3. The cloud storage method for efficient ciphertext file update based on blind storage according to claim 1, wherein the step S2 specifically includes:
step 2.1, forEach file f is subjected to variable-length blocking processing based on content to be converted into data blocks with different sizes, and the number of the data blocks is sizef
Step 2.2, constructing the unique identification id of the file f according to the information of the file ffAccording to the unique identification id of the filefGenerating seed sigma using a fully-defined-field pseudorandom functionfSeed σfInputting a pseudo-random generator to obtain a random sequence;
step 2.3, based on the random sequence and the data block number sizefGenerating a random subset SfWherein the subset S is randomfBelonging to a storage space, will SfAs the first of the random sequences in step 2.2, the length is | SfAn integer set of | where,
Figure FDA0002519389650000011
kappa is the minimum data block number accessed in each time in the storage, and α is the expansion coefficient of the storage;
step 2.4, in random subset SfSize selectionfShortest prefixes of retrievable empty data blocks as subsets
Figure FDA0002519389650000021
Figure FDA0002519389650000022
Is the size of the data block number sizefClient follows subset for the first time
Figure FDA0002519389650000023
Establishing an index relationship between the increasing sequence of the retrieved numbers and the data blocks in step 2.1;
step 2.5, adding header information for each variable length block of the f of the file, generating a file key by using a pseudorandom function, and encrypting each data block by adopting an AES (advanced encryption Standard) symmetric encryption algorithm;
and 2.6, the client sends the encrypted data block to the server, and the server stores the encrypted data block into a storage position of the storage space according to the index relation established in the step 2.4.
4. The cloud storage method for efficient ciphertext file update based on blind storage according to claim 3, wherein the step 2.1 specifically comprises:
step 2.1.1, the client sets two integers d and r based on Rabin fingerprint algorithm, selects a fixed sliding window W, sets a size parameter of m bytes, and sets a maximum block length maxBMinimum block length minB
Step 2.1.2, reading the file f content of the client byte by byte into the sliding window W, and calculating the hash value R in the sliding window W according to the Rabin fingerprint algorithmbreakpoint(ii) a When R isbreakpointWhen mod d is equal to r, a breakpoint is reached, and a block is formed between two adjacent breakpoints;
step 2.1.3, the client records the block number i and the breakpoint position index of the current blockbSize of the block contentbAnd taking the hash value H (block) of the data in the block as the information of the current block, and repeating the step 2.1.2 until the whole file f is completely changed into data blocks with different sizes;
step 2.1.4, the client obtains the information of all the data blocks of the file f, and the size of the number of the data blocksfAnd finishing the storage pretreatment of the file f.
5. The cloud storage method for efficient ciphertext file update based on blind storage according to claim 1, wherein the step S3 specifically includes:
step 3.1, the client acquires the unique identification id of the file f according to the file informationfAccording to the unique identification id of the file ffGenerating seed sigma using a fully-defined-field pseudorandom functionfSeed σfInputting a pseudo-random generator to obtain a random sequence;
step 3.2, the client generates a first integer set S with the length of kappa according to the random sequencef 0Initiating a first round of interaction to the server;
step 3.3, the server side returns the ciphertext data block corresponding to the index to the client side;
step 3.4, the client decrypts the returned data block to find the first unique mark as idfAs the first data block of the file f, and obtaining the block size of the file f from the header information of the first data blockf
Step 3.5, the client analyzes the result
Figure FDA0002519389650000033
S indicating that the content of this file has been returned in its entirety in the first interactionf 0]In the step (3), the second visit is not needed, and the step (3.8) is directly carried out, otherwise, the step (3.6) is carried out
Step 3.6, the client side performs size according to the random sequence and the number of the data blocksfGenerating a random set SfInitiating a second round of interaction to the server;
step 3.7, the server side returns the ciphertext data block corresponding to the index to the client side;
and 3.8, the client decrypts all the data blocks and integrates the data blocks into a complete file f according to the header information of the data blocks.
6. The cloud storage method for efficient ciphertext file update based on blind storage according to claim 5, wherein the step S4 specifically comprises the following steps:
step 4.1, the client modifies the file information of the downloaded and read file f into f';
step 4.2, for the modified file f ', the unique identifier of the file f' is still idfAnd repeating the variable-length blocking processing based on the file content in the step 2.1 to convert the variable-length blocking processing into updated data blocks with different sizes, wherein the number of the updated data blocks is sizef′
Step 4.3, the client side modifies the unique identification id of the file according to the modificationfAnd generating seed sigma by using a fully-defined-domain pseudo-random functionf′Inputting the seed into a pseudo-random generatorObtaining a new random sequence, generating a new random sequence with a length of | Sf′Random subset S of integer set of |f′
Step 4.4, the client selects the random subset Sf′A random subset
Figure FDA0002519389650000031
The size is the updated data block number sizef′(ii) a In a random subset Sf′Size selectionf′Shortest prefixes of retrievable empty data blocks as subsets
Figure FDA0002519389650000032
Step 4.5, the client analyzes the data block quantity change of the variable-length block before and after updating the file, and compares the block information of the variable-length block algorithm based on the content of the file f and the modified file f' to form a corresponding table of the file block before and after the file block is updated;
step 4.6, forming the index information of the updated data block according to the new random sequence, updating the header information of all the updated data blocks, and re-encrypting the header information of all the updated data blocks;
and 4.7, sending and storing all updated ciphertext data blocks of the file to the server side according to the new index information.
7. The cloud storage method based on efficient ciphertext file update of blind storage according to claim 6, wherein in the step 4.5:
if the number of the front data block and the rear data block is the same, a new available space set does not need to be searched
Figure FDA0002519389650000041
Replacing the updated inconsistent data blocks;
if the number of update data blocks increases, a new set of available space needs to be found
Figure FDA0002519389650000042
Replacing or storing the updated inconsistent data blocks into the new available space;
if the number of updated data blocks is reduced, a redundant set of available space is required
Figure FDA0002519389650000043
And clearing, namely replacing the updated inconsistent data blocks, and clearing redundant data blocks.
CN202010486723.2A 2020-06-01 2020-06-01 Cloud storage method for updating efficient ciphertext file based on blind storage Active CN111711671B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010486723.2A CN111711671B (en) 2020-06-01 2020-06-01 Cloud storage method for updating efficient ciphertext file based on blind storage

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010486723.2A CN111711671B (en) 2020-06-01 2020-06-01 Cloud storage method for updating efficient ciphertext file based on blind storage

Publications (2)

Publication Number Publication Date
CN111711671A true CN111711671A (en) 2020-09-25
CN111711671B CN111711671B (en) 2023-07-25

Family

ID=72538535

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010486723.2A Active CN111711671B (en) 2020-06-01 2020-06-01 Cloud storage method for updating efficient ciphertext file based on blind storage

Country Status (1)

Country Link
CN (1) CN111711671B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113810363A (en) * 2021-07-29 2021-12-17 蜂巢能源科技有限公司 Message encryption and decryption method and electronic equipment
CN113868682A (en) * 2021-09-28 2021-12-31 山东云缦智能科技有限公司 Multimedia file encryption and decryption method based on RSA

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101788976A (en) * 2010-02-10 2010-07-28 北京播思软件技术有限公司 File splitting method based on contents
CN103595730A (en) * 2013-11-28 2014-02-19 中国科学院信息工程研究所 Ciphertext cloud storage method and system
CN103729225A (en) * 2014-01-22 2014-04-16 中国人民解放军国防科学技术大学 Content-defined chunking remote file real-time updating method
CN106127075A (en) * 2016-06-27 2016-11-16 湖南大学 The encryption method of can search for based on secret protection under a kind of cloud storage environment
CN107995299A (en) * 2017-12-08 2018-05-04 东北大学 The blind storage method of anti-access module leakage under a kind of cloud environment
CN109189995A (en) * 2018-07-16 2019-01-11 哈尔滨理工大学 Data disappear superfluous method in cloud storage based on MPI

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101788976A (en) * 2010-02-10 2010-07-28 北京播思软件技术有限公司 File splitting method based on contents
CN103595730A (en) * 2013-11-28 2014-02-19 中国科学院信息工程研究所 Ciphertext cloud storage method and system
CN103729225A (en) * 2014-01-22 2014-04-16 中国人民解放军国防科学技术大学 Content-defined chunking remote file real-time updating method
CN106127075A (en) * 2016-06-27 2016-11-16 湖南大学 The encryption method of can search for based on secret protection under a kind of cloud storage environment
CN107995299A (en) * 2017-12-08 2018-05-04 东北大学 The blind storage method of anti-access module leakage under a kind of cloud environment
CN109189995A (en) * 2018-07-16 2019-01-11 哈尔滨理工大学 Data disappear superfluous method in cloud storage based on MPI

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113810363A (en) * 2021-07-29 2021-12-17 蜂巢能源科技有限公司 Message encryption and decryption method and electronic equipment
CN113868682A (en) * 2021-09-28 2021-12-31 山东云缦智能科技有限公司 Multimedia file encryption and decryption method based on RSA

Also Published As

Publication number Publication date
CN111711671B (en) 2023-07-25

Similar Documents

Publication Publication Date Title
Cash et al. Dynamic proofs of retrievability via oblivious RAM
US9977918B2 (en) Method and system for verifiable searchable symmetric encryption
CN106776904B (en) The fuzzy query encryption method of dynamic authentication is supported in a kind of insincere cloud computing environment
US9275250B2 (en) Searchable encryption processing system
US7346160B2 (en) Randomization-based encryption apparatus and method
Chen et al. Onion ring ORAM: Efficient constant bandwidth oblivious RAM from (leveled) TFHE
US7783046B1 (en) Probabilistic cryptographic key identification with deterministic result
CN112800445B (en) Boolean query method for forward and backward security and verifiability of ciphertext data
CN113221155B (en) Multi-level and multi-level encrypted cloud storage system
CN113206736A (en) Encryption method based on AES encryption algorithm
CN110008755B (en) Cloud storage revocable dynamic data integrity verification system and method
CN111310222A (en) File encryption method
CN107995299A (en) The blind storage method of anti-access module leakage under a kind of cloud environment
CN111711671A (en) Cloud storage method for efficient ciphertext file updating based on blind storage
CN112804050A (en) Multi-source data query system and method
CN115905238A (en) Method and device for hiding query, electronic equipment and storage medium
CN110222520B (en) Keyword query method for supporting graph encrypted data in cloud environment
CN116015767A (en) Data processing method, device, equipment and medium
CN110188545B (en) Data encryption method and device based on chained database
Škorić A trivial debiasing scheme for helper data systems
Hoang et al. A multi-server oblivious dynamic searchable encryption framework
KR101232385B1 (en) Searchable Symmetric Encryption Method and System
US8862893B2 (en) Techniques for performing symmetric cryptography
CN108259606A (en) Cloud computing public cloud file stores and search method
KR100951034B1 (en) Method of producing searchable keyword encryption based on public key for minimizing data size of searchable keyword encryption and method of searching data based on public key through that

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