WO2019033751A1 - 一种用于对数据文件进行安全处理的方法及系统 - Google Patents
一种用于对数据文件进行安全处理的方法及系统 Download PDFInfo
- Publication number
- WO2019033751A1 WO2019033751A1 PCT/CN2018/079160 CN2018079160W WO2019033751A1 WO 2019033751 A1 WO2019033751 A1 WO 2019033751A1 CN 2018079160 W CN2018079160 W CN 2018079160W WO 2019033751 A1 WO2019033751 A1 WO 2019033751A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- file
- data
- order
- blocks
- data file
- 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.)
- Ceased
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/04—Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks
- H04L63/0428—Network 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
- H04L63/0435—Network 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 wherein the sending and receiving network entities apply symmetric encryption, i.e. same key used for encryption and decryption
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/06—Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
Definitions
- the present invention relates to the field of information technology, and more particularly to a method and system for secure processing of data files.
- the download channel is often provided by the service provider, and the service party wants to push the data of the modified application to the user.
- the download request of the popular application data is hijacked. After the general hijacker identifies the download request of the user to the application, the modified application data is provided to the user, and therefore, the user obtains the modified by the service party. application.
- the user requests to download the data file of the APK of the application through a third-party browser
- the third-party browser utilizes the feature of the HPPT segment download
- the third-party browser samples a part of the file in the APK data file requested by the user, and The content of the sampled file is matched with the APK data file of the browser side.
- the download of the application APK data file is switched to the browser's own service platform, and the user's download request is directed to the browser side of the APK. data file.
- the user downloads the APK data file from the browser side since the APK data file has been modified by the third-party browser, it is not the APK file that the user actually requests to download.
- the APK data file or the modified APK file may not be used normally, posing a threat to the user's system and data security.
- the present invention provides a method and system for secure processing of data files to solve the problem of how to securely process data files.
- the present invention provides a method for securely processing a data file, the method comprising:
- the multiple file blocks of the data file according to the security parameter in the security processing information At least part of the file blocks in the reordering
- a method for secure processing of a data file comprising:
- the security identifier in the security processing information indicates that the data file needs to be securely processed before responding to the data access request, adding a plurality of random file blocks at a plurality of random locations of the data file, according to the The security parameter in the security processing information reorders at least part of the file blocks in the current file block of the data file;
- a system for secure processing of data files comprising:
- a receiving unit configured to receive an encrypted data access request for a data file, where the data file includes a plurality of file blocks;
- a decryption unit that decrypts the encrypted data access request to obtain a link address associated with the data file requested to be accessed, wherein the link address includes security processing information
- the data file is more At least some of the file blocks in the file block are reordered;
- a sending unit configured to generate a data access response for the data access request based on the securely processed data file.
- a mobile terminal comprising or for performing the system of any of the above.
- the present invention provides a system for secure processing of data files, the system comprising:
- a receiving unit configured to receive an encrypted data access request for a data file, where the data file includes a plurality of file blocks and a file directory;
- a decryption unit that decrypts the encrypted data access request to obtain a link address associated with the data file requested to be accessed, wherein the link address includes security processing information
- a processing unit when the security identifier in the security processing information indicates that the data file needs to be securely processed before responding to the data access request, adding a plurality of random file blocks at a plurality of random locations of the data file, Reordering at least part of the file blocks in the current file block of the data file according to the security parameter in the security processing information;
- Updating unit generating an updated file directory for the data file reordered by the file block according to the current order of the current file block, to obtain a securely processed data file;
- a sending unit configured to generate a data access response for the data access request based on the securely processed data file.
- a mobile terminal comprising or for performing the system of any of the above.
- a computing device comprising a processor; and a memory storing computer readable code, when the computer readable code is executed by the processor, causing the computing device to execute A method for securely processing a data file.
- the technical solution of the present application scrambles the file blocks in the data file requested by the user, and the data files are reordered for each download request of the user.
- the technical solution of the present application avoids that the data hijacker can obtain a matching file by obtaining a partial file and obtaining a matching of the data file by extracting features of the partial file, and providing the user with the downloaded file.
- FIG. 1 is a flow chart of a method for securely processing a data file in accordance with a preferred embodiment of the present invention
- FIG. 2 is a schematic structural diagram of a data file according to a preferred embodiment of the present invention.
- FIG. 3 is a schematic diagram of reordering file blocks in a data file according to a preferred embodiment of the present invention.
- FIG. 4 is a flow chart of a method for securely processing a data file in accordance with a preferred embodiment of the present invention
- FIG. 5 is a flowchart of a method for performing security processing on a data file according to a preferred embodiment of the present invention
- FIG. 6 is a system structure for performing security processing on a data file according to a preferred embodiment of the present invention
- Figure 7 shows a block diagram of a computing device for performing a method for secure processing of data files in accordance with the present invention
- Figure 8 illustrates a storage unit for maintaining or carrying program code that implements a method for secure processing of data files in accordance with the present invention.
- the data access request for encrypting the data file is initiated by the service party, and the service party may be a browser, an APP, a channel, a broadband service provider, etc., and the data file may be an APK data file, etc., and the embodiment of the present application
- the browser is used as a server for illustration, but the service party that initiates the request for the data file in the embodiment of the present application is not limited to the browser.
- the browser device initiates an access request to the data file, and the data file is stored on the server side.
- the data file includes multiple file blocks and file directories.
- the file block and the file directory in the data file can be matched, and the data file can be regarded as a legal file, that is,
- the order of multiple file blocks in the data file can be adjusted by simply updating the position of the file blocks in the file directory in the order in which the file blocks are updated, so that the file blocks and file directories can be matched to each other, and the data files are still legal files.
- the link address associated with the data file requested to be accessed is obtained, wherein the link address includes security processing information.
- step 101 receiving an encrypted data access request for a data file, the data file comprising a plurality of file blocks and a file directory.
- the user initiates an access request to the data file on the server through the browser, and the access request is an encrypted request.
- the access request uses a symmetric encryption algorithm, and the service party encrypts the access request and stores the data.
- the data file server side decrypts the access request.
- the encrypted data file access request includes the original address of the APK data file to be downloaded, the security identifier to be scheduled, the security parameter, the installation serial number, and the like.
- each of the plurality of file blocks includes: a file header, file data, and additional data (not shown in FIG. 1, see FIG. 2).
- each file block record is used to record the start position of the file block and the end position of the file block.
- the data file includes a plurality of file blocks, each file block includes a file header, file data, and additional data, and the data file includes a plurality of file blocks, a file directory, and a file directory record, and each file directory is used for each file directory.
- the start position of the file block and the end position of the file block are recorded, and the file directory record is used to record the start position and end position of the file directory.
- the data file includes multiple file blocks, and the position order of each file block can be adjusted. Only the information in the protected file directory and the file directory record needs to be updated accordingly, so that the order of the file blocks can be matched with the file directory and the file directory record. .
- step 102 decrypting the encrypted data access request to obtain a link address associated with the data file requesting access, wherein the link address includes secure processing information.
- the server side decrypts the encrypted request, obtains the address of the APK data file to be downloaded, the security identifier to be scheduled, the security parameter, the installation serial number, and the like.
- step 103 when the security identifier in the security processing information indicates that the data file needs to be securely processed before responding to the data access request, according to the security parameter in the security processing information, the data file is in multiple file blocks. At least part of the file block is reordered. According to the embodiment of the present invention, whether the data file is securely processed is determined according to the indication of the security identifier obtained after decrypting the data file access request. When the security identifier indicates that the server side performs secure processing on the data file, the data file is reordered.
- the method further includes: determining the order of the first square matrix according to the file block number L of the plurality of file blocks. N, wherein L is less than N 2 and greater than (N-1) 2 .
- the number L of file blocks is 95, so that L is satisfied, L is smaller than N 2 and larger than (N-1) 2 , and N is 10, that is, the divisor of the first square matrix is N, the first The square matrix is an N*N-order matrix.
- N*N-order matrix starting from the first row, fill the sequence numbers of the five file blocks to the first square matrix in order from left to right, and the N*N-order matrix The elements from the 96th to the 100th are filled with zero.
- reordering at least part of the plurality of file blocks of the data file according to the security parameter in the security processing information comprises: constructing a second square matrix of the Nth order, and determining a remainder of the remainder of the security parameter for the N operation K, starting from the column K of the first square matrix to the K-1th column, sequentially filling the sequence numbers of the plurality of file blocks into the second square matrix in order from top to bottom in the column.
- filling the second square matrix in order comprises: sequentially ordering the numbers of the plurality of file blocks into the second square matrix on a row order basis and in an order from left to right in the row.
- the second square matrix of the Nth order is constructed, and the remainder calculation is performed on the N according to the security parameter to obtain the remainder K.
- the Kth column of the first square matrix is selected to start from the column order to the K-1th column, and the sequence numbers of the plurality of file blocks are pressed in the order from top to bottom in the column.
- the sequence is filled to the second square matrix.
- the sequence numbers of the plurality of file blocks are sequentially padded to the second square matrix in the order of the rows in the second square matrix and in the order from left to right in the row.
- step 104 an updated file directory is generated for the data files reordered by the file block according to the current order of the plurality of file blocks to obtain the securely processed data file.
- generating the updated file directory for the data file reordered by the file block according to the current order of the plurality of file blocks comprises: reordering the data through the file block according to the current order of the plurality of file blocks recorded in the second square matrix The file generates an updated file directory.
- An embodiment of the present invention in order to match the location of the file block in the data file with the information recorded in the file directory and the file directory, it is necessary to record the file directory and the file directory.
- the information and the location information of the file block are updated in real time, so that the data file is a legal file.
- a data access response to the data access request is generated based on the securely processed data file.
- generating a data access response for the data access request based on the securely processed data file comprises: treating a portion of the securely processed data file or the securely processed data file involved in the data access request as a data access response.
- a part of the data file or the data file that has undergone security processing is used as a data access response, which can effectively prevent the hijacker from acquiring a part of the data file, so that the hijacker can extract the characteristics of the data file.
- the hijacker confirms the data file that the user needs to download, the user is recommended to download the address, so that the user accesses the maliciously processed data file, which affects the user's data security.
- the data file includes a plurality of file blocks, each of which includes a file header, file data, and additional data.
- the data file includes a plurality of file blocks, a file directory, and a file directory record, and each file directory is used for recording.
- the start position of the file block and the end position of the file block which is used to record the start and end positions of the file directory.
- the data file includes multiple file blocks, and the position order of each file block can be adjusted. Only the information in the protected file directory and the file directory record needs to be updated accordingly, so that the order of the file blocks can be matched with the file directory and the file directory record. .
- Random file blocks can be inserted into multiple file blocks at random, just ensure that the file directory and file directory record updates match the location information in multiple file blocks, and the data files are still legal.
- FIG. 3 is a schematic diagram of reordering file blocks in a data file in accordance with a preferred embodiment of the present invention.
- 301 is a data file in the original order
- FIG. 302 is a data file sorted by security processing, and the sorting of the file blocks in the data file is processed out of order, while maintaining the file directory and file directory records and files. Update of the block location. By changing the location of the file block in the data file.
- FIG. 4 is a flow chart of a method for securely processing a data file in accordance with a preferred embodiment of the present invention.
- the APK file is manually published by 360, a data file is generated, and the data file is distributed to the CDN server.
- the user obtains the download URL address through the web browser of the browser, and sends a data file access request including the download URL address to the CDN server.
- the CDN server decrypts the data file access request to obtain the decrypted URL of the APK data file to be downloaded. Address, security ID to be scheduled, security parameters, installation serial number, etc.
- the data file is reordered, and the sorted data file is reconstructed for output.
- the identity of the server is not recognized, and whether the data file is processed securely is determined and determined by the server that provides the service.
- the data access request for encrypting the data file is initiated by the service party, and the service party may be a browser, an APP, a channel, a broadband service provider, etc., and the data file may be an APK data file, etc., and the embodiment of the present application
- the browser is used as a server for illustration, but the service party that initiates the request for the data file in the embodiment of the present application is not limited to the browser.
- the browser device initiates an access request to the data file, and the data file is stored on the server side.
- the data file includes multiple file blocks and file directories.
- the file block and the file directory in the data file can be matched, and the data file can be regarded as a legal file, that is,
- the order of multiple file blocks in the data file can be adjusted by simply updating the position of the file blocks in the file directory in the order in which the file blocks are updated, so that the file blocks and file directories can be matched to each other, and the data files are still legal files.
- the link address associated with the data file requested to be accessed is obtained, wherein the link address includes security processing information.
- the server side may, according to the security identifier indication in the security processing information, perform security processing on the data file before responding to the data, may add multiple random file blocks in multiple random locations, and use the security parameters in the security processing information to the data file. At least some of the file blocks in the plurality of file blocks are reordered. By adding random file blocks, the number of file blocks and the sorting of files in the original data file are changed more, and it is more difficult to match the data files after the hijacker hijacks some data files and extracts the data features.
- a method for securely processing a data file begins at step 501:
- step 501 receiving an encrypted data access request for a data file, the data file comprising a plurality of file blocks and a file directory.
- the user initiates an access request to the data file on the server through the browser, and the access request is an encrypted request.
- the access request uses a symmetric encryption algorithm, and the service party encrypts the access request and stores the data.
- the data file server side decrypts the access request.
- the encrypted data file access request includes the original address of the APK data file to be downloaded, the security identifier to be scheduled, the security parameter, the installation serial number, and the like.
- each of the plurality of file blocks includes: a file header, file data, and additional data (not shown in FIG. 5, see FIG. 2).
- each of the plurality of file blocks includes: a file header, file data and additional data, and a random file block, the random file block including a file header and random data, wherein the random data is independent of the content of the data file. data.
- the random file block is mainly used to increase the data characteristics of the random file block when the data file is securely processed, and it is more difficult to extract the data feature and ensure the security of the data file access.
- each file block record is used to record the start position of the file block and the end position of the file block.
- the data file further includes file directory location information for identifying a start location and an end location of the file directory.
- the data file includes a plurality of file blocks, each file block includes a file header, file data, and additional data, and the data file includes a plurality of file blocks, a file directory, and a file directory record, and each file directory is used for each file directory.
- the start position of the file block and the end position of the file block are recorded, and the file directory record is used to record the start position and end position of the file directory.
- the data file includes multiple file blocks, and the position order of each file block can be adjusted. Only the information in the protected file directory and the file directory record needs to be updated accordingly, so that the order of the file blocks can be matched with the file directory and the file directory record. .
- step 502 decrypting the encrypted data access request to obtain a link address associated with the data file requesting access, wherein the link address includes secure processing information.
- the server side decrypts the encrypted request, obtains the address of the APK data file to be downloaded, the security identifier to be scheduled, the security parameter, the installation serial number, and the like.
- step 503 when the security identifier in the security processing information indicates that the data file needs to be securely processed before responding to the data access request, adding a plurality of random file blocks at a plurality of random locations of the data file, according to security
- the security parameters in the processing information reorder at least some of the plurality of file blocks of the data file.
- whether the data file is securely processed is determined according to the indication of the security identifier obtained after decrypting the data file access request.
- the security identifier indicates that the server side performs security processing on the data file
- the data file is reordered, and the random file block is added at a random location to increase the degree of disorder of the file block, so that the hijacker has difficulty extracting the characteristics of the data file. , increase the security of data files.
- the method further includes: determining the order of the first square matrix according to the file block number L of the plurality of file blocks. N, wherein L is less than N 2 and greater than (N-1) 2 .
- the method further comprises constructing a first square matrix of Nth order, based on the row order and sequentially filling the sequence numbers of the plurality of file blocks to the first square matrix in an order from left to right in the row, and L+1 The elements up to N 2 are filled to zero.
- the number L of file blocks is 95, so that L is satisfied, L is smaller than N 2 and larger than (N-1) 2 , and N is 10, that is, the divisor of the first square matrix is N, the first The square matrix is an N*N-order matrix.
- N*N-order matrix starting from the first row, fill the sequence numbers of the five file blocks to the first square matrix in order from left to right, and the N*N-order matrix The elements from the 96th to the 100th are filled with zero.
- reordering at least part of the plurality of file blocks of the data file according to the security parameter in the security processing information comprises: constructing a second square matrix of the Nth order, and determining a remainder of the remainder of the security parameter for the N operation K, starting from the column K of the first square matrix to the K-1th column, sequentially filling the sequence numbers of the plurality of file blocks into the second square matrix in order from top to bottom in the column.
- filling the second square matrix in order comprises: sequentially ordering the numbers of the plurality of file blocks into the second square matrix on a row order basis and in an order from left to right in the row.
- the second square matrix of the Nth order is constructed, and the remainder calculation is performed on the N according to the security parameter to obtain the remainder K.
- the Kth column of the first square matrix is selected to start from the column order to the K-1th column, and the sequence numbers of the plurality of file blocks are pressed in the order from top to bottom in the column.
- the sequence is filled to the second square matrix.
- the sequence numbers of the plurality of file blocks are sequentially padded to the second square matrix in the order of the rows in the second square matrix and in the order from left to right in the row.
- step 504 an updated file directory is generated for the data files reordered by the file block according to the current order of the plurality of file blocks to obtain the securely processed data file.
- generating the updated file directory for the data file reordered by the file block according to the current order of the plurality of file blocks comprises: reordering the data through the file block according to the current order of the plurality of file blocks recorded in the second square matrix The file generates an updated file directory.
- An embodiment of the present invention in order to match the location of the file block in the data file with the information recorded in the file directory and the file directory, it is required in the file directory and the file directory record.
- the information and the location information of the file block are updated in real time, so that the data file is a legal file.
- a data access response to the data access request is generated based on the securely processed data file.
- generating a data access response for the data access request based on the securely processed data file comprises: treating a portion of the securely processed data file or the securely processed data file involved in the data access request as a data access response.
- a part of the data file or the data file that has undergone security processing is used as a data access response, which can effectively prevent the hijacker from acquiring a part of the data file, so that the hijacker can extract the characteristics of the data file.
- the hijacker confirms the data file that the user needs to download, the user is recommended to download the address, so that the user accesses the maliciously processed data file, which affects the user's data security.
- the data access request for encrypting the data file is initiated by the service party, and the service party may be a browser, an APP, a channel, a broadband service provider, etc., and the data file may be an APK data file, etc., and the embodiment of the present application
- the browser is used as a server for illustration, but the service party that initiates the request for the data file in the embodiment of the present application is not limited to the browser.
- the browser device initiates an access request to the data file, and the data file is stored on the server side.
- the data file includes multiple file blocks and file directories.
- the file block and the file directory in the data file can be matched, and the data file can be regarded as a legal file, that is,
- the order of multiple file blocks in the data file can be adjusted by simply updating the position of the file blocks in the file directory in the order in which the file blocks are updated, so that the file blocks and file directories can be matched to each other, and the data files are still legal files.
- the link address associated with the data file requested to be accessed is obtained, wherein the link address includes security processing information.
- the server side performs security processing on the data file before responding to the data according to the security identifier indication in the security processing information, and performs at least part of the file blocks in the plurality of file blocks in the data file according to the security parameter in the security processing information. rearrange. Generating an updated file directory for the data files reordered by the file block according to the current order of the plurality of file blocks, converting the data file into a securely processed data file, and the server provides the request for the data file through the securely processed data file square.
- at least part of the file blocks in the data file in the data file are reordered according to the security parameter in the security processing information to prevent the hijacker from extracting. To the characteristics of the data file, complete the matching of the data file.
- a system 600 for securely processing data files includes:
- the receiving unit 601 receives an encrypted data access request for a data file, where the data file includes a plurality of file blocks and a file directory.
- the receiving unit 601 is configured to receive a request for the user to initiate an access to the data file on the server through the browser, and the access request is an encrypted request.
- the access request in the embodiment of the present invention uses a symmetric encryption algorithm, and the service party accesses the access request. The request is subjected to encryption processing, and the storage data file server side decrypts the access request.
- the encrypted data file access request includes the original address of the APK data file to be downloaded, the security identifier to be scheduled, the security parameter, the installation serial number, and the like.
- each of the plurality of file blocks includes: a file header, file data, and additional data (not shown in FIG. 6, see FIG. 2).
- each of the plurality of file blocks includes: a file header, file data and additional data, and a random file block, the random file block including a file header and random data, wherein the random data is independent of the content of the data file. data.
- the random file block is mainly used to increase the data characteristics of the random file block when the data file is securely processed, and it is more difficult to extract the data feature and ensure the security of the data file access.
- each file block record is used to record the start position of the file block and the end position of the file block.
- the data file further includes file directory location information for identifying a start location and an end location of the file directory.
- the data file includes a plurality of file blocks, each file block includes a file header, file data, and additional data, and the data file includes a plurality of file blocks, a file directory, and a file directory record, and each file directory is used for each file directory.
- the start position of the file block and the end position of the file block are recorded, and the file directory record is used to record the start position and end position of the file directory.
- the data file includes multiple file blocks, and the position order of each file block can be adjusted. Only the information in the protected file directory and the file directory record needs to be updated accordingly, so that the order of the file blocks can be matched with the file directory and the file directory record. .
- the decryption unit 602 decrypts the encrypted data access request to obtain a link address associated with the data file requested to be accessed, wherein the link address includes security processing information.
- the decryption unit 602 is configured to decrypt the encrypted request after receiving the data access request, obtain the address of the APK data file to be downloaded, the security identifier to be scheduled, and the security parameter. Install the serial number, etc.
- the processing unit 603 when the security identifier in the security processing information indicates that the data file needs to be securely processed before responding to the data access request, at least part of the plurality of file blocks of the data file according to the security parameter in the security processing information File blocks are reordered.
- the processing unit 603 is configured to determine whether to perform security processing on the data file according to the indication of the security identifier acquired after the data file access request is decrypted. When the security identifier indicates that the server side performs secure processing on the data file, the data file is reordered.
- the processing unit 603 when the security identifier in the security processing information indicates that the data file needs to be securely processed before responding to the data access request, adding a plurality of random file blocks at a plurality of random locations of the data file, according to The security parameter in the security processing information reorders at least some of the plurality of file blocks of the data file.
- the processing unit 603 determines whether to perform security processing on the data file according to the indication of the security identifier acquired after decrypting the data file access request.
- the security identifier indicates that the server side performs security processing on the data file
- the data file is reordered, and the random file block is added at a random location to increase the degree of disorder of the file block, so that the hijacker has difficulty extracting the characteristics of the data file. , increase the security of data files.
- the method further includes: determining the order of the first square matrix according to the file block number L of the plurality of file blocks. N, wherein L is less than N 2 and greater than (N-1) 2 .
- the method further comprises constructing a first square matrix of Nth order, based on the row order and sequentially filling the sequence numbers of the plurality of file blocks to the first square matrix in an order from left to right in the row, and L+1 The elements up to N 2 are filled to zero.
- the number L of file blocks is 95, so that L is satisfied, L is smaller than N 2 and larger than (N-1) 2 , and N is 10, that is, the divisor of the first square matrix is N, the first The square matrix is an N*N-order matrix.
- N*N-order matrix starting from the first row, fill the sequence numbers of the five file blocks to the first square matrix in order from left to right, and the N*N-order matrix The elements from the 96th to the 100th are filled with zero.
- reordering at least part of the plurality of file blocks of the data file according to the security parameter in the security processing information comprises: constructing a second square matrix of the Nth order, and determining a remainder of the remainder of the security parameter for the N operation K, starting from the column K of the first square matrix to the K-1th column, sequentially filling the sequence numbers of the plurality of file blocks into the second square matrix in order from top to bottom in the column.
- filling the second square matrix in order comprises: sequentially ordering the numbers of the plurality of file blocks into the second square matrix on a row order basis and in an order from left to right in the row.
- the second square matrix of the Nth order is constructed, and the remainder calculation is performed on the N according to the security parameter to obtain the remainder K.
- the Kth column of the first square matrix is selected to start from the column order to the K-1th column, and the sequence numbers of the plurality of file blocks are pressed in the order from top to bottom in the column.
- the sequence is filled to the second square matrix.
- the sequence numbers of the plurality of file blocks are sequentially padded to the second square matrix in the order of the rows in the second square matrix and in the order from left to right in the row.
- the updating unit 604 generates an updated file directory for the data files reordered by the file block according to the current order of the plurality of file blocks to obtain the securely processed data file.
- generating the updated file directory for the data file reordered by the file block according to the current order of the plurality of file blocks comprises: reordering the data through the file block according to the current order of the plurality of file blocks recorded in the second square matrix The file generates an updated file directory.
- the updating unit 604 needs to match the file directory and the file directory to the file directory and the file directory record information in the data file.
- the information in the record is updated in real time with the location information of the file block, making the data file a legal file.
- the sending unit 605 generates a data access response for the data access request based on the securely processed data file.
- generating the data access response for the data access request based on the securely processed data file comprises: the sending unit 605 as the data of the securely processed data file or the securely processed data file involved in the data access request Access the response.
- system 600 as described above may be included in or executed by the mobile terminal in accordance with a preferred embodiment of the present invention.
- a part of the data file or the data file that has undergone security processing is used as a data access response, which can effectively prevent the hijacker from acquiring a part of the data file, so that the hijacker can extract the characteristics of the data file.
- the hijacker confirms the data file that the user needs to download, the user is recommended to download the address, so that the user accesses the maliciously processed data file, which affects the user's data security.
- modules in the devices of the embodiments can be adaptively changed and placed in one or more devices different from the embodiment.
- the modules or units or components of the embodiments may be combined into one module or unit or component, and further they may be divided into a plurality of sub-modules or sub-units or sub-components.
- any combination of the features disclosed in the specification, including the accompanying claims, the abstract and the drawings, and any methods so disclosed, or All processes or units of the device are combined.
- Each feature disclosed in this specification (including the accompanying claims, the abstract and the drawings) may be replaced by alternative features that provide the same, equivalent or similar purpose.
- the various component embodiments of the present invention may be implemented in hardware, or in a software module running on one or more processors, or in a combination thereof.
- a microprocessor or digital signal processor may be used in practice to implement some or some of the components of a secure processing system for data files in accordance with embodiments of the present invention. All features.
- the invention can also be implemented as a device or device program (e.g., a computer program and a computer program product) for performing some or all of the methods described herein.
- Such a program implementing the invention may be stored on a computer readable medium or may be in 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.
- Figure 7 illustrates a block diagram of a computing device that can implement secure processing of data files in accordance with the present invention.
- the computing device conventionally includes a processor 710 and a computer program product or computer readable medium in the form of a memory 720.
- Memory 720 can be an electronic memory such as a flash memory, EEPROM (Electrically Erasable Programmable Read Only Memory), EPROM, hard disk, or ROM.
- Memory 720 has a storage space 730 that stores program code 731 for performing any of the method steps described above.
- storage space 730 storing program code may store respective program code 731 for implementing various steps in the above methods, respectively.
- the program code can be read from or written to one or more computer program products.
- These computer program products include program code carriers such as hard disks, compact disks (CDs), memory cards or floppy disks. Such computer program products are typically portable or fixed storage units as shown in FIG.
- the storage unit may have storage segments, storage spaces, and the like that are similarly arranged to memory 720 in the computing device of FIG.
- the program code can be compressed, for example, in an appropriate form.
- the storage unit comprises computer readable program code 731' storing program steps for performing the method according to the invention, ie program code readable by a processor such as 710, when the program code is run by the computing device Causing the computing device to perform the various steps in the methods described above.
Landscapes
- Engineering & Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer Hardware Design (AREA)
- Computing Systems (AREA)
- General Engineering & Computer Science (AREA)
- Storage Device Security (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
本发明公开了一种用于对数据文件进行安全处理的方法,方法包括:接收针对数据文件的经过加密的数据访问请求,数据文件包括多个文件块;对经过加密的数据访问请求进行解密,获取与请求访问的数据文件相关的链接地址,其中链接地址包括安全处理信息;当安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对数据文件进行安全处理时,根据安全处理信息中的安全参数对数据文件的多个文件块中的至少部分文件块进行重新排序,获得经过安全处理的数据文件;以及以经过安全处理的数据文件为基础生成针对数据访问请求的数据访问响应。
Description
本发明涉及信息技术领域,更具体地,涉及一种用于对数据文件进行安全处理的方法及系统。
越来越多的用户通过网络进行数据文件的下载,在对热门应用的数据文件下载过程中,经常是由业务服务方提供下载链接渠道,服务方由于想向用户推送经过修改过的应用的数据,通常会对热门的应用数据的下载请求进行劫持,一般劫持方在识别到用户对应用的下载请求后,会将修改后的应用数据提供给用户,因此,用户会获得经过服务方修改后的应用。
例如,用户通过第三方浏览器请求下载应用的APK的数据文件,第三方浏览器利用HPPT分段下载的特征,第三方浏览器对用户请求下载的APK数据文件中的部分文件进行取样,并将取样的文件部分内容与浏览器方的APK数据文件进行匹配,在匹配成功后,将该应用APK数据文件的下载切换至浏览器方自己的服务平台,将用户的下载请求指向浏览器方的APK数据文件。用户从浏览器方下载APK数据文件后,由于APK数据文件已经经过了第三方浏览器的修改,并非为用户真正请求下载的APK文件。用户在下载被修改APK文件后,可能不能正常使用该APK数据文件,或修改后的APK文件,对用户的系统及数据安全造成威胁。
因此,需要一种技术,以实现对数据文件进行安全处理。
发明内容
本发明提供了一种用于对数据文件进行安全处理的方法及系统,以解决如何对数据文件进行安全处理的问题。
为了解决上述问题,本发明提供一种用于对数据文件进行安全处理的方法,所述方法包括:
接收针对数据文件的经过加密的数据访问请求,所述数据文件包括多个文件块;
对所述经过加密的数据访问请求进行解密,获取与请求访问的数据文件相关的链接地址,其中所述链接地址包括安全处理信息;
当所述安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对所述数据文件进行安全处理时,根据所述安全处理信息中的安全参数对所述数据文件的多个文件块中的至少部分文件块进行重新排序;
获得经过安全处理的数据文件;以及
以所述经过安全处理的数据文件为基础生成针对所述数据访问请求的数据访问响应。
基于本发明的另一方面,提供一种用于对数据文件进行安全处理的方法,所述方法包括:
接收针对数据文件的经过加密的数据访问请求,所述数据文件包括多个文件块和文件目录;
对所述经过加密的数据访问请求进行解密,获取与请求访问的数据文件相关的链接地址,其中所述链接地址包括安全处理信息;
当所述安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对所述数据文件进行安全处理时,在所述数据文件的多个随机位置增加多个随机文件块,根据所述安全处理信息中的安全参数对所述数据文件的当前文件块中的至少部分文件块进行重新排序;
根据所述当前文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录,以获得经过安全处理的数据文件;以及
以所述经过安全处理的数据文件为基础生成针对所述数据访问请求的数据访问响应。
基于本发明的另一方面,提供一种用于对数据文件进行安全处理的系统,所述系统包括:
接收单元,接收针对数据文件的经过加密的数据访问请求,所述数据文件包括多个文件块;
解密单元,对所述经过加密的数据访问请求进行解密,获取与请求访问的数据文件相关的链接地址,其中所述链接地址包括安全处理信息;
处理单元,当所述安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对所述数据文件进行安全处理时,根据所述安全处理信息中的安全参数对所述数据文件的多个文件块中的至少部分文件块进行重新排序;
更新单元,获得经过安全处理的数据文件;以及
发送单元,以所述经过安全处理的数据文件为基础生成针对所述数据访问请求的数据访问响应。
基于本发明的另一方面,提供一种移动终端,包括或用于执行上述中任意一项所述的系统。
基于本发明的另一方面,本发明提供一种用于对数据文件进行安全处理的系统,所述系统包括:
接收单元,接收针对数据文件的经过加密的数据访问请求,所述数据文件包括多个文件块和文件目录;
解密单元,对所述经过加密的数据访问请求进行解密,获取与请求访问的数据文件相关的链接地址,其中所述链接地址包括安全处理信息;
处理单元,当所述安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对所述数据文件进行安全处理时,在所述数据文件的多个随机位置增加多 个随机文件块,根据所述安全处理信息中的安全参数对所述数据文件的当前文件块中的至少部分文件块进行重新排序;
更新单元,根据所述当前文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录,以获得经过安全处理的数据文件;以及
发送单元,以所述经过安全处理的数据文件为基础生成针对所述数据访问请求的数据访问响应。
基于本发明的另一方面,提供一种移动终端,包括或用于执行上述中任意一项所述的系统。
根据本发明的又一个方面,提供了一种计算机可读介质,其中存储了计算机可读代码,当所述计算机可读代码在计算设备上运行时,导致所述计算设备执行所述用于对数据文件进行安全处理的方法。
根据本发明的再一个方面,提供了一种计算设备,包括处理器;以及存储了计算机可读代码的存储器,所述计算机可读代码被所述处理器运行时,导致所述计算设备执行所述用于对数据文件进行安全处理的方法。
本申请的技术方案通过将用户请求下载的数据文件中文件块排序进行打乱,对于用户的每次下载请求,数据文件都会进行重新排序。本申请的技术方案避免了数据劫持者可以通过获取部分文件,以及通过提取部分文件的特征而获得对数据文件的匹配,为用户提供下载文件。
通过参考下面的附图,可以更为完整地理解本发明的示例性实施方式:
图1为根据本发明优选实施方式的对数据文件进行安全处理的方法流程图;
图2为根据本发明优选实施方式的数据文件结构示意图;
图3为根据本发明优选实施方式的对数据文件中文件块进行重新排序示意图;
图4为根据本发明优选实施方式的对数据文件进行安全处理的方法流程图;
图5为根据本发明优选实施方式的对数据文件进行安全处理的方法流程图;图6为根据本发明优选实施方式的对数据文件进行安全处理的系统结构;
图7示出了用于执行根据本发明的用于对数据文件进行安全处理的方法的计算设备的框图;以及
图8示出了用于保持或者携带实现根据本发明的用于对数据文件进行安全处理的方法的程序代码的存储单元。
现在参考附图介绍本发明的示例性实施方式,然而,本发明可以用许多不同的形式来实施,并且不局限于此处描述的实施例,提供这些实施例是为了详尽地且完全地公开本发明,并且向所属技术领域的技术人员充分传达本发明的范围。对于表 示在附图中的示例性实施方式中的术语并不是对本发明的限定。在附图中,相同的单元/元件使用相同的附图标记。
除非另有说明,此处使用的术语(包括科技术语)对所属技术领域的技术人员具有通常的理解含义。另外,可以理解的是,以通常使用的词典限定的术语,应当被理解为与其相关领域的语境具有一致的含义,而不应该被理解为理想化的或过于正式的意义。
图1为根据本发明优选实施方式的对数据文件进行安全处理的方法流程图。本申请的实施方式,通过服务方发起对数据文件的加密的数据访问请求,服务方可以为浏览器、APP、渠道、宽带服务商等,数据文件可以为APK数据文件等,本申请的实施方式以浏览器作为服务方进行举例说明,但本申请的实施方式中发起对数据文件请求的服务方不仅限于浏览器。通过浏览器方发起对数据文件的访问请求,数据文件存储在服务器端,数据文件包括多个文件块和文件目录,数据文件中文件块和文件目录能够匹配,即可认为是合法的文件,即数据文件中多个文件块的顺序可以调整,只需按文件块更新的顺序更新文件目录中文件块的位置等,使文件块和文件目录能够保持相互匹配,数据文件仍然是合法的文件。通过服务器对加密的数据访问请求进行解密后,获取与请求访问的数据文件相关的链接地址,其中链接地址包括安全处理信息。服务器方根据安全处理信息中的安全标识指示在对数据进行响应之前需要对数据文件进行安全处理时,根据安全处理信息中的安全参数对数据文件中的多个文件块中的至少部分文件块进行重新排序。根据多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录,将数据文件转化为经过安全处理的数据文件,服务器方将经过安全处理的数据文件提供给数据文件的请求方。本申请的实施方式,对服务方发起的每次数据文件访问请求,都会根据安全处理信息中的安全参数对数据文件中的多个文件块中的至少部分文件块进行重新排序,防止劫持者提取到数据文件的特征,完成对数据文件的匹配。如图1所示,一种用于对数据文件进行安全处理的方法从步骤101开始:
优选地,在步骤101:接收针对数据文件的经过加密的数据访问请求,数据文件包括多个文件块和文件目录。本发明的实施方式,用户通过浏览器方发起对服务器上数据文件的访问请求,访问请求为加密的请求,本发明实施方式访问请求采用对称的加密算法,服务方对访问请求进行加密处理,存储数据文件服务器方对访问请求进行解密处理。加密的数据文件访问请求包括需要下载的APK数据文件的原始地址、是否要进行安排处理的安全标识,安全参数,安装序列号等。
优选地,多个文件块中每个文件块均包括:文件头、文件数据和附加数据(图1未示出,详见图2)。
优选地,其中文件目录包括多个文件块记录,每个文件块记录用于记载文件块的起始位置和文件块的结束位置。
优选地,其中数据文件还包括文件目录位置信息,用于标识文件目录的起始位 置和结束位置。
本发明的实施方式中,数据文件包括若干个文件块,每个文件块包括文件头、文件数据和附加数据,数据文件包括多个文件块、文件目录和文件目录记录,每个文件目录用于记录文件块的起始位置和文件块的结束位置,文件目录记录用于记录文件目录的起始位置和结束位置。数据文件中包括多个文件块,每个文件块的位置顺序可以调整,只需要相应更新保护文件目录和文件目录记录中的信息,即可实现文件块的顺序与文件目录和文件目录记录的匹配。
优选地,在步骤102:对经过加密的数据访问请求进行解密,获取与请求访问的数据文件相关的链接地址,其中链接地址包括安全处理信息。本发明的实施方式,服务器方在接收到数据访问请求后,对加密的请求进行解密,获取需要下载的APK数据文件的地址、是否要进行安排处理的安全标识,安全参数,安装序列号等。
优选地,在步骤103:当安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对数据文件进行安全处理时,根据安全处理信息中的安全参数对数据文件的多个文件块中的至少部分文件块进行重新排序。本发明的实施方式,根据对数据文件访问请求解密后获取的安全标识的指示,来确定是否对数据文件进行安全处理。当安全标识指示服务器方对数据文件进行安全处理时,对数据文件进行重新排序处理。
优选地,其中当安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对数据文件进行安全处理时还包括:根据多个文件块的文件块数量L确定第一方阵的阶数N,其中L小于N
2并且大于(N-1)
2。
优选地,还包括构建N阶的第一方阵,以行序为基础并且按照行内从左至右的次序,将多个文件块的序号按顺序填充至第一方阵,以及将L+1至N
2的元素填充为零。
本发明的实施方式中,例如文件块数量L为95,为使L满足,L小于N
2并且大于(N-1)
2,取N为10,即第一方阵的除数为N,第一方阵为N*N阶矩阵,在N*N阶矩阵中,从第一行开始,按照从左至右的次序,填写5个文件块的序号至第一方阵,将N*N阶矩阵中第96至第100的元素填充为零。
优选地,根据安全处理信息中的安全参数对数据文件的多个文件块中的至少部分文件块进行重新排序包括:构建N阶的第二方阵,确定安全参数对N进行取余运算的余数K,从第一方阵的第K列开始以列序为基础至第K-1列为止,按照列内从上至下的次序将多个文件块的序号按顺序填充至第二方阵。
优选地,其中按顺序填充至第二方阵包括:以行序为基础并且按照行内从左至右的次序,将多个文件块的序号按顺序填充至第二方阵。
本发明的实施方式中,构建N阶的第二方阵,根据安全参数对N进行取余计算,获取余数K。在对数据文件顺序进行重新排序时,选取第一方阵的第K列开始以列序为基础至第K-1列为止,按照列内从上至下的次序将多个文件块的序号按顺序填 充至第二方阵。在第二方阵中以行序为基础并且按照行内从左至右的次序,将多个文件块的序号按顺序填充至第二方阵。
优选地,在步骤104:根据多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录,以获得经过安全处理的数据文件。
优选地,根据多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录包括:根据第二方阵中记录的多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录。
本发明的实施方式(图1未示出,详见图3),为使数据文件中的文件块的位置与文件目录和文件目录记录的信息相匹配,需要对文件目录和文件目录记录中的信息与文件块的位置信息进行实时更新,使数据文件为合法文件。
优选地,在步骤105:以经过安全处理的数据文件为基础生成针对数据访问请求的数据访问响应。
优选地,以经过安全处理的数据文件为基础生成针对数据访问请求的数据访问响应包括:将数据访问请求所涉及的经过安全处理的数据文件或经过安全处理的数据文件的一部分作为数据访问响应。
本发明的实施方式,将经过安全处理,即重新排序后的数据文件或数据文件中的一部分作为数据访问响应,能够有效避免劫持方通过获取部分数据文件,使得劫持方能够提取到数据文件的特征。避免劫持方在确认用户需要下载的数据文件后,通过为用户推荐下载地址,使用户访问到经过恶意处理的数据文件,影响用户的数据使用安全。
图2为根据本发明优选实施方式的数据文件结构示意图。如图2所示,数据文件包括若干个文件块,每个文件块包括文件头、文件数据和附加数据,数据文件包括多个文件块、文件目录和文件目录记录,每个文件目录用于记录文件块的起始位置和文件块的结束位置,文件目录记录用于记录文件目录的起始位置和结束位置。数据文件中包括多个文件块,每个文件块的位置顺序可以调整,只需要相应更新保护文件目录和文件目录记录中的信息,即可实现文件块的顺序与文件目录和文件目录记录的匹配。多个文件块中可以随意插入随机文件块,只需保证文件目录和文件目录记录更新与多个文件块中位置信息相匹配,数据文件仍然是合法的。
图3为根据本发明优选实施方式的对数据文件中文件块进行重新排序示意图。如图3所示,301为原始顺序的数据文件,图302为进行安全处理排序后的数据文件,将数据文件中的文件块的排序进行乱序处理,同时保持文件目录和文件目录记录与文件块位置的更新。通过变更数据文件中文件块的位置。
图4为根据本发明优选实施方式的对数据文件进行安全处理的方法流程图。如图4所示,通过360用手发布APK文件,生成数据文件,将数据文件发布至CDN服务器。用户通过浏览器Web端获取下载URL地址,将包括下载URL地址的数据文件访问请求发送至CDN端服务器,CDN服务器通过对数据文件访问请求进行解 密,获取需要下载的APK数据文件的解密后的URL地址、是否要进行安排处理的安全标识,安全参数,安装序列号等。当通过安全标识判断出需要对数据文件进行安全处理时,对数据文件进行重新排序处理,重新构造排序后的数据文件进行输出。本发明的实施方式,不对服务端的身份进行识别,是否对数据文件进行安全处理,由提供业务的服务端进行判断和确定。
图5为根据本发明优选实施方式的对数据文件进行安全处理的方法流程图。本申请的实施方式,通过服务方发起对数据文件的加密的数据访问请求,服务方可以为浏览器、APP、渠道、宽带服务商等,数据文件可以为APK数据文件等,本申请的实施方式以浏览器作为服务方进行举例说明,但本申请的实施方式中发起对数据文件请求的服务方不仅限于浏览器。通过浏览器方发起对数据文件的访问请求,数据文件存储在服务器端,数据文件包括多个文件块和文件目录,数据文件中文件块和文件目录能够匹配,即可认为是合法的文件,即数据文件中多个文件块的顺序可以调整,只需按文件块更新的顺序更新文件目录中文件块的位置等,使文件块和文件目录能够保持相互匹配,数据文件仍然是合法的文件。通过服务器对加密的数据访问请求进行解密后,获取与请求访问的数据文件相关的链接地址,其中链接地址包括安全处理信息。服务器方根据安全处理信息中的安全标识指示在对数据进行响应之前需要对数据文件进行安全处理时,可以在多个随机位置增加多个随机文件块,根据安全处理信息中的安全参数对数据文件中的多个文件块中的至少部分文件块进行重新排序。通过增加随机文件块,使原数据文件中的文件块数量和文件的排序进行较多的改变,增加劫持者在劫持部分数据文件并提取数据特征后对数据文件进行匹配的难度。根据多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录,将数据文件转化为经过安全处理的数据文件,服务器方将经过安全处理的数据文件提供给数据文件的请求方。本申请的实施方式,对服务方发起的每次数据文件访问请求,都会根据安全处理信息中的安全参数对数据文件中的多个文件块中的至少部分文件块进行重新排序,以及在随机位置增加随机文件块,防止劫持者提取到数据文件的特征,完成对数据文件的匹配。如图5所示,一种用于对数据文件进行安全处理的方法从步骤501开始:
优选地,在步骤501:接收针对数据文件的经过加密的数据访问请求,数据文件包括多个文件块和文件目录。本发明的实施方式,用户通过浏览器方发起对服务器上数据文件的访问请求,访问请求为加密的请求,本发明实施方式访问请求采用对称的加密算法,服务方对访问请求进行加密处理,存储数据文件服务器方对访问请求进行解密处理。加密的数据文件访问请求包括需要下载的APK数据文件的原始地址、是否要进行安排处理的安全标识,安全参数,安装序列号等。
优选地,多个文件块中每个文件块均包括:文件头、文件数据和附加数据(图5未示出,详见图2)。
优选地,多个文件块中每个文件块均包括:文件头、文件数据和附加数据,以 及随机文件块,随机文件块包括文件头和随机数据,其中随机数据是与数据文件的内容无关的数据。随机文件块,主要用于在对数据文件进行安全处理时,增加了随机文件块的数据文件更难被提取出数据特征,保证数据文件访问的安全性。
优选地,其中文件目录包括多个文件块记录,每个文件块记录用于记载文件块的起始位置和文件块的结束位置。
优选地,其中数据文件还包括文件目录位置信息,用于标识文件目录的起始位置和结束位置。
本发明的实施方式中,数据文件包括若干个文件块,每个文件块包括文件头、文件数据和附加数据,数据文件包括多个文件块、文件目录和文件目录记录,每个文件目录用于记录文件块的起始位置和文件块的结束位置,文件目录记录用于记录文件目录的起始位置和结束位置。数据文件中包括多个文件块,每个文件块的位置顺序可以调整,只需要相应更新保护文件目录和文件目录记录中的信息,即可实现文件块的顺序与文件目录和文件目录记录的匹配。
优选地,在步骤502:对经过加密的数据访问请求进行解密,获取与请求访问的数据文件相关的链接地址,其中链接地址包括安全处理信息。本发明的实施方式,服务器方在接收到数据访问请求后,对加密的请求进行解密,获取需要下载的APK数据文件的地址、是否要进行安排处理的安全标识,安全参数,安装序列号等。
优选地,在步骤503:当安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对数据文件进行安全处理时,在数据文件的多个随机位置增加多个随机文件块,根据安全处理信息中的安全参数对数据文件的多个文件块中的至少部分文件块进行重新排序。本发明的实施方式,根据对数据文件访问请求解密后获取的安全标识的指示,来确定是否对数据文件进行安全处理。当安全标识指示服务器方对数据文件进行安全处理时,对数据文件进行重新排序处理,并且通过在随机位置增加随机文件块,增加文件块乱序的程度,使劫持者难以提取出数据文件的特征,增加数据文件的安全性。
优选地,其中当安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对数据文件进行安全处理时还包括:根据多个文件块的文件块数量L确定第一方阵的阶数N,其中L小于N
2并且大于(N-1)
2。
优选地,还包括构建N阶的第一方阵,以行序为基础并且按照行内从左至右的次序,将多个文件块的序号按顺序填充至第一方阵,以及将L+1至N
2的元素填充为零。
本发明的实施方式中,例如文件块数量L为95,为使L满足,L小于N
2并且大于(N-1)
2,取N为10,即第一方阵的除数为N,第一方阵为N*N阶矩阵,在N*N阶矩阵中,从第一行开始,按照从左至右的次序,填写5个文件块的序号至第一方阵,将N*N阶矩阵中第96至第100的元素填充为零。
优选地,根据安全处理信息中的安全参数对数据文件的多个文件块中的至少部 分文件块进行重新排序包括:构建N阶的第二方阵,确定安全参数对N进行取余运算的余数K,从第一方阵的第K列开始以列序为基础至第K-1列为止,按照列内从上至下的次序将多个文件块的序号按顺序填充至第二方阵。
优选地,其中按顺序填充至第二方阵包括:以行序为基础并且按照行内从左至右的次序,将多个文件块的序号按顺序填充至第二方阵。
本发明的实施方式中,构建N阶的第二方阵,根据安全参数对N进行取余计算,获取余数K。在对数据文件顺序进行重新排序时,选取第一方阵的第K列开始以列序为基础至第K-1列为止,按照列内从上至下的次序将多个文件块的序号按顺序填充至第二方阵。在第二方阵中以行序为基础并且按照行内从左至右的次序,将多个文件块的序号按顺序填充至第二方阵。
优选地,在步骤504:根据多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录,以获得经过安全处理的数据文件。
优选地,根据多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录包括:根据第二方阵中记录的多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录。
本发明的实施方式(图5未示出,详见图3),为使数据文件中的文件块的位置与文件目录和文件目录记录的信息相匹配,需要对文件目录和文件目录记录中的信息与文件块的位置信息进行实时更新,使数据文件为合法文件。
优选地,在步骤505:以经过安全处理的数据文件为基础生成针对数据访问请求的数据访问响应。
优选地,以经过安全处理的数据文件为基础生成针对数据访问请求的数据访问响应包括:将数据访问请求所涉及的经过安全处理的数据文件或经过安全处理的数据文件的一部分作为数据访问响应。
本发明的实施方式,将经过安全处理,即重新排序后的数据文件或数据文件中的一部分作为数据访问响应,能够有效避免劫持方通过获取部分数据文件,使得劫持方能够提取到数据文件的特征。避免劫持方在确认用户需要下载的数据文件后,通过为用户推荐下载地址,使用户访问到经过恶意处理的数据文件,影响用户的数据使用安全。
图6为根据本发明优选实施方式的对数据文件进行安全处理的系统结构。本申请的实施方式,通过服务方发起对数据文件的加密的数据访问请求,服务方可以为浏览器、APP、渠道、宽带服务商等,数据文件可以为APK数据文件等,本申请的实施方式以浏览器作为服务方进行举例说明,但本申请的实施方式中发起对数据文件请求的服务方不仅限于浏览器。通过浏览器方发起对数据文件的访问请求,数据文件存储在服务器端,数据文件包括多个文件块和文件目录,数据文件中文件块和文件目录能够匹配,即可认为是合法的文件,即数据文件中多个文件块的顺序可以调整,只需按文件块更新的顺序更新文件目录中文件块的位置等,使文件块和文件 目录能够保持相互匹配,数据文件仍然是合法的文件。通过服务器对加密的数据访问请求进行解密后,获取与请求访问的数据文件相关的链接地址,其中链接地址包括安全处理信息。服务器方根据安全处理信息中的安全标识指示在对数据进行响应之前需要对数据文件进行安全处理时,根据安全处理信息中的安全参数对数据文件中的多个文件块中的至少部分文件块进行重新排序。根据多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录,将数据文件转化为经过安全处理的数据文件,服务器方将经过安全处理的数据文件提供给数据文件的请求方。本申请的实施方式,对服务方发起的每次数据文件访问请求,都会根据安全处理信息中的安全参数对数据文件中的多个文件块中的至少部分文件块进行重新排序,防止劫持者提取到数据文件的特征,完成对数据文件的匹配。如图6所示,一种用于对数据文件进行安全处理的系统600包括:
接收单元601,接收针对数据文件的经过加密的数据访问请求,数据文件包括多个文件块和文件目录。本发明的实施方式,接收单元601用于接收用户通过浏览器方发起对服务器上数据文件的访问请求,访问请求为加密的请求,本发明实施方式访问请求采用对称的加密算法,服务方对访问请求进行加密处理,存储数据文件服务器方对访问请求进行解密处理。加密的数据文件访问请求包括需要下载的APK数据文件的原始地址、是否要进行安排处理的安全标识,安全参数,安装序列号等。
优选地,多个文件块中每个文件块均包括:文件头、文件数据和附加数据(图6未示出,详见图2)。
优选地,多个文件块中每个文件块均包括:文件头、文件数据和附加数据,以及随机文件块,随机文件块包括文件头和随机数据,其中随机数据是与数据文件的内容无关的数据。随机文件块,主要用于在对数据文件进行安全处理时,增加了随机文件块的数据文件更难被提取出数据特征,保证数据文件访问的安全性。
优选地,其中文件目录包括多个文件块记录,每个文件块记录用于记载文件块的起始位置和文件块的结束位置。
优选地,其中数据文件还包括文件目录位置信息,用于标识文件目录的起始位置和结束位置。
本发明的实施方式中,数据文件包括若干个文件块,每个文件块包括文件头、文件数据和附加数据,数据文件包括多个文件块、文件目录和文件目录记录,每个文件目录用于记录文件块的起始位置和文件块的结束位置,文件目录记录用于记录文件目录的起始位置和结束位置。数据文件中包括多个文件块,每个文件块的位置顺序可以调整,只需要相应更新保护文件目录和文件目录记录中的信息,即可实现文件块的顺序与文件目录和文件目录记录的匹配。
解密单元602,对经过加密的数据访问请求进行解密,获取与请求访问的数据文件相关的链接地址,其中链接地址包括安全处理信息。
本发明的实施方式,解密单元602用于服务器方在接收到数据访问请求后,对 加密的请求进行解密,获取需要下载的APK数据文件的地址、是否要进行安排处理的安全标识,安全参数,安装序列号等。
处理单元603,当安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对数据文件进行安全处理时,根据安全处理信息中的安全参数对数据文件的多个文件块中的至少部分文件块进行重新排序。本发明的实施方式,处理单元603用于根据对数据文件访问请求解密后获取的安全标识的指示,来确定是否对数据文件进行安全处理。当安全标识指示服务器方对数据文件进行安全处理时,对数据文件进行重新排序处理。
可替换地,处理单元603:当安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对数据文件进行安全处理时,在数据文件的多个随机位置增加多个随机文件块,根据安全处理信息中的安全参数对数据文件的多个文件块中的至少部分文件块进行重新排序。本发明的实施方式,处理单元603根据对数据文件访问请求解密后获取的安全标识的指示,来确定是否对数据文件进行安全处理。当安全标识指示服务器方对数据文件进行安全处理时,对数据文件进行重新排序处理,并且通过在随机位置增加随机文件块,增加文件块乱序的程度,使劫持者难以提取出数据文件的特征,增加数据文件的安全性。
优选地,其中当安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对数据文件进行安全处理时还包括:根据多个文件块的文件块数量L确定第一方阵的阶数N,其中L小于N
2并且大于(N-1)
2。
优选地,还包括构建N阶的第一方阵,以行序为基础并且按照行内从左至右的次序,将多个文件块的序号按顺序填充至第一方阵,以及将L+1至N
2的元素填充为零。
本发明的实施方式中,例如文件块数量L为95,为使L满足,L小于N
2并且大于(N-1)
2,取N为10,即第一方阵的除数为N,第一方阵为N*N阶矩阵,在N*N阶矩阵中,从第一行开始,按照从左至右的次序,填写5个文件块的序号至第一方阵,将N*N阶矩阵中第96至第100的元素填充为零。
优选地,根据安全处理信息中的安全参数对数据文件的多个文件块中的至少部分文件块进行重新排序包括:构建N阶的第二方阵,确定安全参数对N进行取余运算的余数K,从第一方阵的第K列开始以列序为基础至第K-1列为止,按照列内从上至下的次序将多个文件块的序号按顺序填充至第二方阵。
优选地,其中按顺序填充至第二方阵包括:以行序为基础并且按照行内从左至右的次序,将多个文件块的序号按顺序填充至第二方阵。
本发明的实施方式中,构建N阶的第二方阵,根据安全参数对N进行取余计算,获取余数K。在对数据文件顺序进行重新排序时,选取第一方阵的第K列开始以列序为基础至第K-1列为止,按照列内从上至下的次序将多个文件块的序号按顺序填充至第二方阵。在第二方阵中以行序为基础并且按照行内从左至右的次序,将多个 文件块的序号按顺序填充至第二方阵。
更新单元604,根据多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录,以获得经过安全处理的数据文件。
优选地,根据多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录包括:根据第二方阵中记录的多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录。
本发明的实施方式(图6未示出,详见图3),更新单元604为使数据文件中的文件块的位置与文件目录和文件目录记录的信息相匹配,需要对文件目录和文件目录记录中的信息与文件块的位置信息进行实时更新,使数据文件为合法文件。
发送单元605,以经过安全处理的数据文件为基础生成针对数据访问请求的数据访问响应。优选地,以经过安全处理的数据文件为基础生成针对数据访问请求的数据访问响应包括:发送单元605将数据访问请求所涉及的经过安全处理的数据文件或经过安全处理的数据文件的一部分作为数据访问响应。优选地,根据本发明的优选实施方式,如上所述的系统600可以被包括在移动终端中,或由移动终端来执行。
本发明的实施方式,将经过安全处理,即重新排序后的数据文件或数据文件中的一部分作为数据访问响应,能够有效避免劫持方通过获取部分数据文件,使得劫持方能够提取到数据文件的特征。避免劫持方在确认用户需要下载的数据文件后,通过为用户推荐下载地址,使用户访问到经过恶意处理的数据文件,影响用户的数据使用安全。
类似地,应当理解,为了精简本公开并帮助理解各个发明方面中的一个或多个,在上面对本发明的示例性实施例的描述中,本发明的各个特征有时被一起分组到单个实施例、图、或者对其的描述中。然而,并不应将该公开的方法解释成反映如下意图:即所要求保护的本发明要求比在每个权利要求中所明确记载的特征更多的特征。更确切地说,如下面的权利要求书所反映的那样,发明方面在于少于前面公开的单个实施例的所有特征。因此,遵循具体实施方式的权利要求书由此明确地并入该具体实施方式,其中每个权利要求本身都作为本发明的单独实施例。
本领域那些技术人员可以理解,可以对实施例中的设备中的模块进行自适应性地改变并且把它们设置在与该实施例不同的一个或多个设备中。可以把实施例中的模块或单元或组件组合成一个模块或单元或组件,以及此外可以把它们分成多个子模块或子单元或子组件。除了这样的特征和/或过程或者单元中的至少一些是相互排斥之外,可以采用任何组合对本说明书(包括伴随的权利要求、摘要和附图)中公开的所有特征以及如此公开的任何方法或者设备的所有过程或单元进行组合。除非另外明确陈述,本说明书(包括伴随的权利要求、摘要和附图)中公开的每个特征可以由提供相同、等同或相似目的的替代特征来代替。
此外,本领域的技术人员能够理解,尽管在此所述的一些实施例包括其它实施例中所包括的某些特征而不是其它特征,但是不同实施例的特征的组合意味着处于 本发明的范围之内并且形成不同的实施例。例如,在下面的权利要求书中,所要求保护的实施例的任意之一都可以以任意的组合方式来使用。
本发明的各个部件实施例可以以硬件实现,或者以在一个或者多个处理器上运行的软件模块实现,或者以它们的组合实现。本领域的技术人员应当理解,可以在实践中使用微处理器或者数字信号处理器(DSP)来实现根据本发明实施例的用于对数据文件进行安全处理系统中的一些或者全部部件的一些或者全部功能。本发明还可以实现为用于执行这里所描述的方法的一部分或者全部的设备或者装置程序(例如,计算机程序和计算机程序产品)。这样的实现本发明的程序可以存储在计算机可读介质上,或者可以具有一个或者多个信号的形式。这样的信号可以从因特网网站上下载得到,或者在载体信号上提供,或者以任何其他形式提供。
例如,图7示出了可以实现根据本发明的用于对数据文件进行安全处理的计算设备的框图。该计算设备传统上包括处理器710和以存储器720形式的计算机程序产品或者计算机可读介质。存储器720可以是诸如闪存、EEPROM(电可擦除可编程只读存储器)、EPROM、硬盘或者ROM之类的电子存储器。存储器720具有存储用于执行上述方法中的任何方法步骤的程序代码731的存储空间730。例如,存储程序代码的存储空间730可以存储分别用于实现上面的方法中的各种步骤的各个程序代码731。这些程序代码可以从一个或者多个计算机程序产品中读出或者写入到这一个或者多个计算机程序产品中。这些计算机程序产品包括诸如硬盘,紧致盘(CD)、存储卡或者软盘之类的程序代码载体。这样的计算机程序产品通常为如图8所示的便携式或者固定存储单元。该存储单元可以具有与图7的计算设备中的存储器720类似布置的存储段、存储空间等。程序代码可以例如以适当形式进行压缩。通常,存储单元包括存储有用于执行根据本发明的方法步骤的计算机可读程序代码731’,即可以由例如诸如710之类的处理器读取的程序代码,当这些程序代码由计算设备运行时,导致该计算设备执行上面所描述的方法中的各个步骤。
已经通过参考少量实施方式描述了本发明。然而,本领域技术人员所公知的,正如附带的专利权利要求所限定的,除了本发明以上公开的其他的实施例等同地落在本发明的范围内。
通常地,在权利要求中使用的所有术语都根据他们在技术领域的通常含义被解释,除非在其中被另外明确地定义。所有的参考“一个/所述/该[装置、组件等]”都被开放地解释为所述装置、组件等中的至少一个实例,除非另外明确地说明。这里公开的任何方法的步骤都没必要以公开的准确的顺序运行,除非明确地说明。
此外,还应当注意,本说明书中使用的语言主要是为了可读性和教导的目的而选择的,而不是为了解释或者限定本发明的主题而选择的。因此,在不偏离所附权利要求书的范围和精神的情况下,对于本技术领域的普通技术人员来说许多修改和变更都是显而易见的。对于本发明的范围,对本发明所做的公开是说明性的,而非限制性的,本发明的范围由所附权利要求书限定。
Claims (46)
- 一种用于对数据文件进行安全处理的方法,所述方法包括:接收针对数据文件的经过加密的数据访问请求,所述数据文件包括多个文件块;对所述经过加密的数据访问请求进行解密,获取与请求访问的数据文件相关的链接地址,其中所述链接地址包括安全处理信息;当所述安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对所述数据文件进行安全处理时,根据所述安全处理信息中的安全参数对所述数据文件的多个文件块中的至少部分文件块进行重新排序,获得经过安全处理的数据文件;以及以所述经过安全处理的数据文件为基础生成针对所述数据访问请求的数据访问响应。
- 根据权利要求1所述的方法,其中所述数据文件还包括文件目录,所述获得经过安全处理的数据文件之前还包括:根据所述多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录。
- 根据权利要求2所述的方法,所述多个文件块中每个文件块均包括:文件头、文件数据和附加数据。
- 根据权利要求3所述的方法,其中所述文件目录包括多个文件块记录,每个文件块记录用于记载文件块的起始位置和文件块的结束位置。
- 根据权利要求4所述的方法,其中所述数据文件还包括文件目录位置信息,用于标识所述文件目录的起始位置和结束位置。
- 根据权利要求2所述的方法,其中所述当所述安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对所述数据文件进行安全处理时还包括:根据所述多个文件块的文件块数量L确定第一方阵的阶数N,其中L小于N 2并且大于(N-1) 2。
- 根据权利要求6所述的方法,还包括构建N阶的第一方阵,以行序为基础并且按照行内从左至右的次序,将所述多个文件块的序号按顺序填充至所述第一方阵,以及将L+1至N 2的元素填充为零。
- 根据权利要求7所述的方法,所述根据所述安全处理信息中的安全参数对所述数据文件的多个文件块中的至少部分文件块进行重新排序包括:构建N阶的第二方阵,确定安全参数对N进行取余运算的余数K,从所述第一方阵的第K列开始以列序为基础至第K-1列为止,按照列内从上至下的次序将所述多个文件块的序号按顺序填充至所述第二方阵。
- 根据权利要求8所述的方法,其中所述按顺序填充至所述第二方阵包括:以行序为基础并且按照行内从左至右的次序,将所述多个文件块的序号按顺序填充至所述第二方阵。
- 根据权利要求9所述的方法,所述根据所述多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录包括:根据所述第二方阵中记录的 所述多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录。
- 根据权利要求2所述的方法,所述以所述经过安全处理的数据文件为基础生成针对所述数据访问请求的数据访问响应包括:将所述数据访问请求所涉及的经过安全处理的数据文件或经过安全处理的数据文件的一部分作为数据访问响应。
- 一种用于对数据文件进行安全处理的方法,所述方法包括:接收针对数据文件的经过加密的数据访问请求,所述数据文件包括多个文件块和文件目录;对所述经过加密的数据访问请求进行解密,获取与请求访问的数据文件相关的链接地址,其中所述链接地址包括安全处理信息;当所述安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对所述数据文件进行安全处理时,在所述数据文件的多个随机位置增加多个随机文件块,根据所述安全处理信息中的安全参数对所述数据文件的当前文件块中的至少部分文件块进行重新排序;根据所述当前文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录,以获得经过安全处理的数据文件;以及以所述经过安全处理的数据文件为基础生成针对所述数据访问请求的数据访问响应。
- 根据权利要求12所述的方法,其中每个文件块包括:文件头、文件数据和附加数据,并且所述多个随机文件块中每个随机文件块包括:文件头和随机数据,其中所述随机数据是与所述数据文件的内容无关的数据。
- 根据权利要求13所述的方法,其中所述文件目录包括多个文件块记录,每个文件块记录用于记载文件块的起始位置和文件块的结束位置,其中所述数据文件还包括文件目录位置信息,用于标识所述文件目录的起始位置和结束位置。
- 根据权利要求14所述的方法,所述多个随机位置中的每个随机位置是所述数据文件的多个文件块中两个相邻文件块之间的位置。
- 根据权利要求12所述的方法,其中所述当所述安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对所述数据文件进行安全处理时还包括:根据所述当前文件块的文件块数量L确定第一方阵的阶数N,其中L小于N 2并且大于(N-1) 2。
- 根据权利要求16所述的方法,还包括构建N阶的第一方阵,以行序为基础并且按照行内从左至右的次序,将所述当前文件块的序号按顺序填充至所述第一方阵,以及将L+1至N 2的元素填充为零。
- 根据权利要求17所述的方法,所述根据所述安全处理信息中的安全参数对所述数据文件的当前文件块中的至少部分文件块进行重新排序包括:构建N阶的第二方阵,确定安全参数对N进行取余运算的余数K,从所述第一方阵的第K列开始 以列序为基础至第K-1列为止,按照列内从上至下的次序将所述当前文件块的序号按顺序填充至所述第二方阵。
- 根据权利要求18所述的方法,其中所述按顺序填充至所述第二方阵包括:以行序为基础并且按照行内从左至右的次序,将所述当前文件块的序号按顺序填充至所述第二方阵。
- 根据权利要求19所述的方法,所述根据所述当前文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录包括:根据所述第二方阵中记录的所述当前文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录。
- 根据权利要求12所述的方法,所述以所述经过安全处理的数据文件为基础生成针对所述数据访问请求的数据访问响应包括:将所述数据访问请求所涉及的经过安全处理的数据文件或经过安全处理的数据文件的一部分作为数据访问响应。
- 一种用于对数据文件进行安全处理的系统,所述系统包括:接收单元,接收针对数据文件的经过加密的数据访问请求,所述数据文件包括多个文件块;解密单元,对所述经过加密的数据访问请求进行解密,获取与请求访问的数据文件相关的链接地址,其中所述链接地址包括安全处理信息;处理单元,当所述安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对所述数据文件进行安全处理时,根据所述安全处理信息中的安全参数对所述数据文件的多个文件块中的至少部分文件块进行重新排序;更新单元,获得经过安全处理的数据文件;以及发送单元,以所述经过安全处理的数据文件为基础生成针对所述数据访问请求的数据访问响应。
- 根据权利要求22所述的系统,其中所述数据文件还包括文件目录,所述更新单元具体用于:根据所述多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录,以获得经过安全处理的数据文件。
- 根据权利要求23所述的系统,所述多个文件块中每个文件块均包括:文件头、文件数据和附加数据。
- 根据权利要求24所述的系统,其中,所述文件目录包括多个文件块记录,每个文件块记录用于记载文件块的起始位置和文件块的结束位置。
- 根据权利要求25所述的系统,其中,所述数据文件还包括文件目录位置信息,用于标识所述文件目录的起始位置和结束位置。
- 根据权利要求23所述的系统,其中,所述处理单元根据所述多个文件块的文件块数量L确定第一方阵的阶数N,其中L小于N 2并且大于(N-1) 2。
- 根据权利要求27所述的系统,所述处理单元构建N阶的第一方阵,以行序为基础并且按照行内从左至右的次序,将所述多个文件块的序号按顺序填充至所述 第一方阵,以及将L+1至N 2的元素填充为零。
- 根据权利要求28所述的系统,所述处理单元构建N阶的第二方阵,确定安全参数对N进行取余运算的余数K,从所述第一方阵的第K列开始以列序为基础至第K-1列为止,按照列内从上至下的次序将所述多个文件块的序号按顺序填充至所述第二方阵。
- 根据权利要求29所述的系统,所述处理单元:以行序为基础并且按照行内从左至右的次序,将所述多个文件块的序号按顺序填充至所述第二方阵。
- 根据权利要求30所述的系统,所述更新单元根据所述第二方阵中记录的所述多个文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录。
- 根据权利要求23所述的系统,所述发送单元将所述数据访问请求所涉及的经过安全处理的数据文件或经过安全处理的数据文件的一部分作为数据访问响应。
- 一种移动终端,包括或用于执行如权利要求22-32中任意一项所述的系统。
- 一种用于对数据文件进行安全处理的系统,所述系统包括:接收单元,接收针对数据文件的经过加密的数据访问请求,所述数据文件包括多个文件块和文件目录;解密单元,对所述经过加密的数据访问请求进行解密,获取与请求访问的数据文件相关的链接地址,其中所述链接地址包括安全处理信息;处理单元,当所述安全处理信息中的安全标识指示在对数据访问请求进行响应之前需要对所述数据文件进行安全处理时,在所述数据文件的多个随机位置增加多个随机文件块,根据所述安全处理信息中的安全参数对所述数据文件的当前文件块中的至少部分文件块进行重新排序;更新单元,根据所述当前文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录,以获得经过安全处理的数据文件;以及发送单元,以所述经过安全处理的数据文件为基础生成针对所述数据访问请求的数据访问响应。
- 根据权利要求34所述的系统,其中每个文件块包括:文件头、文件数据和附加数据,并且所述多个随机文件块中每个随机文件块包括:文件头和随机数据,其中所述随机数据是与所述数据文件的内容无关的数据。
- 根据权利要求35所述的系统,其中所述文件目录包括多个文件块记录,每个文件块记录用于记载文件块的起始位置和文件块的结束位置,其中所述数据文件还包括文件目录位置信息,用于标识所述文件目录的起始位置和结束位置。
- 根据权利要求36所述的系统,所述多个随机位置中的每个随机位置是所述数据文件的多个文件块中两个相邻文件块之间的位置。
- 根据权利要求34所述的系统,其中,所述处理单元根据所述当前文件块的文件块数量L确定第一方阵的阶数N,其中L小于N 2并且大于(N-1) 2。
- 根据权利要求38所述的系统,所述处理单元构建N阶的第一方阵,以行序 为基础并且按照行内从左至右的次序,将所述当前文件块的序号按顺序填充至所述第一方阵,以及将L+1至N 2的元素填充为零。
- 根据权利要求39所述的系统,所述处理单元构建N阶的第二方阵,确定安全参数对N进行取余运算的余数K,从所述第一方阵的第K列开始以列序为基础至第K-1列为止,按照列内从上至下的次序将所述当前文件块的序号按顺序填充至所述第二方阵。
- 根据权利要求40所述的系统,所述处理单元以行序为基础并且按照行内从左至右的次序,将所述当前文件块的序号按顺序填充至所述第二方阵。
- 根据权利要求41所述的系统,所述更新单元根据所述第二方阵中记录的所述当前文件块的当前顺序为经过文件块重新排序的数据文件生成更新的文件目录。
- 根据权利要求34所述的系统,所述发送单元将所述数据访问请求所涉及的经过安全处理的数据文件或经过安全处理的数据文件的一部分作为数据访问响应。
- 一种移动终端,包括或用于执行如权利要求34-43中任意一项所述的系统。
- 一种计算机可读介质,其中存储了计算机可读代码,当所述计算机可读代码在计算设备上运行时,导致所述计算设备执行根据权利要求1-21任一个所述的用于对数据文件进行安全处理的方法。
- 一种计算设备,包括:处理器;以及存储了计算机可读代码的存储器,所述计算机可读代码被所述处理器运行时,导致所述计算设备执行根据权利要求1-21任一个所述的用于对数据文件进行安全处理的方法。
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201710693187.1A CN107395616B (zh) | 2017-08-14 | 2017-08-14 | 一种用于对数据文件进行安全处理的方法及系统 |
| CN201710693187.1 | 2017-08-14 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2019033751A1 true WO2019033751A1 (zh) | 2019-02-21 |
Family
ID=60354504
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2018/079160 Ceased WO2019033751A1 (zh) | 2017-08-14 | 2018-03-15 | 一种用于对数据文件进行安全处理的方法及系统 |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN107395616B (zh) |
| WO (1) | WO2019033751A1 (zh) |
Families Citing this family (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN107395616B (zh) * | 2017-08-14 | 2020-10-27 | 北京奇虎科技有限公司 | 一种用于对数据文件进行安全处理的方法及系统 |
| CN111049870B (zh) * | 2018-10-15 | 2022-07-22 | 华为技术有限公司 | 应用下载和发送的方法、装置及系统 |
Citations (7)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US6134584A (en) * | 1997-11-21 | 2000-10-17 | International Business Machines Corporation | Method for accessing and retrieving information from a source maintained by a network server |
| CN104135503A (zh) * | 2013-07-10 | 2014-11-05 | 腾讯科技(深圳)有限公司 | 数据下载的方法、装置及系统 |
| CN104156225A (zh) * | 2013-05-14 | 2014-11-19 | 腾讯科技(深圳)有限公司 | 一种安装包的下载方法、系统及服务器 |
| CN104657629A (zh) * | 2013-11-22 | 2015-05-27 | 中国移动通信集团公司 | 一种文件版权保护方法和设备 |
| CN105227673A (zh) * | 2015-10-16 | 2016-01-06 | 北京奇虎科技有限公司 | 防劫持的数据下载方法、客户端、服务器及系统 |
| CN105718276A (zh) * | 2014-12-02 | 2016-06-29 | 北京奇虎科技有限公司 | 提供apk下载的方法和装置以及nginx服务器 |
| CN107395616A (zh) * | 2017-08-14 | 2017-11-24 | 北京奇虎科技有限公司 | 一种用于对数据文件进行安全处理的方法及系统 |
Family Cites Families (7)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US8429643B2 (en) * | 2007-09-05 | 2013-04-23 | Microsoft Corporation | Secure upgrade of firmware update in constrained memory |
| US8839374B1 (en) * | 2011-12-15 | 2014-09-16 | Symantec Corporation | Systems and methods for identifying security risks in downloads |
| CN103248650B (zh) * | 2012-02-09 | 2016-12-14 | 中兴通讯股份有限公司 | 一种文件下载方法及系统 |
| CN102981879B (zh) * | 2012-12-03 | 2016-04-06 | 中国联合网络通信集团有限公司 | 应用软件安装包提供方法、获取方法、设备及处理系统 |
| CN104123163B (zh) * | 2014-07-30 | 2017-08-04 | 珠海市君天电子科技有限公司 | 一种应用程序的下载请求的处理方法及装置 |
| CN105760781B (zh) * | 2016-03-02 | 2018-05-08 | 四川师范大学 | 有序可推演大数据文件的存储方法、恢复方法和操作方法 |
| CN106789909A (zh) * | 2016-11-22 | 2017-05-31 | 北京奇虎科技有限公司 | 应用程序的网络数据传输方法、装置及系统 |
-
2017
- 2017-08-14 CN CN201710693187.1A patent/CN107395616B/zh not_active Expired - Fee Related
-
2018
- 2018-03-15 WO PCT/CN2018/079160 patent/WO2019033751A1/zh not_active Ceased
Patent Citations (7)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US6134584A (en) * | 1997-11-21 | 2000-10-17 | International Business Machines Corporation | Method for accessing and retrieving information from a source maintained by a network server |
| CN104156225A (zh) * | 2013-05-14 | 2014-11-19 | 腾讯科技(深圳)有限公司 | 一种安装包的下载方法、系统及服务器 |
| CN104135503A (zh) * | 2013-07-10 | 2014-11-05 | 腾讯科技(深圳)有限公司 | 数据下载的方法、装置及系统 |
| CN104657629A (zh) * | 2013-11-22 | 2015-05-27 | 中国移动通信集团公司 | 一种文件版权保护方法和设备 |
| CN105718276A (zh) * | 2014-12-02 | 2016-06-29 | 北京奇虎科技有限公司 | 提供apk下载的方法和装置以及nginx服务器 |
| CN105227673A (zh) * | 2015-10-16 | 2016-01-06 | 北京奇虎科技有限公司 | 防劫持的数据下载方法、客户端、服务器及系统 |
| CN107395616A (zh) * | 2017-08-14 | 2017-11-24 | 北京奇虎科技有限公司 | 一种用于对数据文件进行安全处理的方法及系统 |
Also Published As
| Publication number | Publication date |
|---|---|
| CN107395616A (zh) | 2017-11-24 |
| CN107395616B (zh) | 2020-10-27 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US10037330B1 (en) | Security via dynamic data movement in a cloud-based environment | |
| CN105794173B (zh) | 数据传送优化 | |
| US9292700B2 (en) | Method and system for securing data | |
| US9253164B2 (en) | Distribution of portions of content | |
| CN105357191B (zh) | 用户数据的加密方法及装置 | |
| US10608813B1 (en) | Layered encryption for long-lived data | |
| CN104391974B (zh) | 浏览器及其收藏夹数据的处理方法 | |
| CN115225409B (zh) | 基于多备份联合验证的云数据安全去重方法 | |
| US20180336209A1 (en) | Security via dynamic data movement in a cloud-based environment | |
| US11455103B2 (en) | Cloud secured storage system utilizing multiple cloud servers with processes of file segmentation, encryption and generation of data chunks | |
| US10476663B1 (en) | Layered encryption of short-lived data | |
| US9008305B2 (en) | Video data delivery protection | |
| US12032493B2 (en) | Obfuscating cryptographic material in memory | |
| US12355865B2 (en) | Hybrid cloud-based security service method and apparatus for security of confidential data | |
| WO2020101979A2 (en) | Systems and methods for managing data based on secret sharing | |
| CN114726560A (zh) | 数据保护方法、计算机装置及可读存储介质 | |
| CN116346508B (zh) | 基于分片加密存储的信息传输方法、装置、设备及介质 | |
| CN107395616B (zh) | 一种用于对数据文件进行安全处理的方法及系统 | |
| US11356254B1 (en) | Encryption using indexed data from large data pads | |
| CN111988262A (zh) | 认证方法、装置及服务器、存储介质 | |
| CN111338841A (zh) | 数据处理方法、装置、设备和存储介质 | |
| CN109871698A (zh) | 数据处理方法、装置、计算机设备和存储介质 | |
| CN106611130A (zh) | 一种文件处理方法和装置 | |
| WO2015078252A1 (en) | Method and device for processing a file | |
| CN108259609A (zh) | 一种家庭云端数据的管理方法及云服务器 |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 18847038 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 32PN | Ep: public notification in the ep bulletin as address of the adressee cannot be established |
Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC , EPO FORM 1205A DATED 03.08.2020. |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 18847038 Country of ref document: EP Kind code of ref document: A1 |