Tamper-proof and damage-proof office file backup method

By adopting a file backup method using servers and off-site storage nodes in small and medium-sized enterprises, and using binary XOR operations to form file association information, the high hardware cost, data redundancy, and security issues of file backup for small and medium-sized enterprises are solved, achieving efficient and secure file backup.

CN115712525BActive Publication Date: 2025-11-11CHANGXUN COMM SERVICE CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202211453157.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-11-21
Publication Date
2025-11-11
Estimated Expiration
2042-11-21

AI Technical Summary

Technical Problem

Small and medium-sized enterprises face problems such as high hardware costs, data redundancy, network overload, and high operation and maintenance costs in file backup, and lack effective anti-tampering mechanisms.

Method used

A file backup method that prevents tampering and damage is adopted. Files are backed up through servers and storage nodes, binary XOR operations are performed to form file association information, and the files are stored in rotation on three off-site storage nodes to achieve hot backup and fast recovery.

Benefits of technology

It reduces storage space requirements, improves backup speed and security, prevents file tampering and corruption, and ensures that files can still be recovered if any storage node is damaged.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115712525B_ABST
    Figure CN115712525B_ABST
Patent Text Reader

Abstract

The application discloses an anti-tampering and anti-damage office file backup method, which comprises the following steps: backing up files through a server and a storage node; acquiring file related record information and reading and comparing the record information; and recovering damaged files. The method can improve the disk utilization rate, the additional space required for backup is only one third of the total file space in the non-compressed case, improve the data read-write performance, achieve read-write separation and parallel read-write, and does not need to occupy a large number of encryption and synchronization calculation resources, improve the security, and achieve the verification and repair of any file, and the backup node can be rebuilt after being completely destroyed.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of document protection technology, and in particular to a method for preventing tampering and damage to important backup files within an enterprise. Background Technology

[0002] In daily operations, companies accumulate an increasing number of documents that do not require modification but need to be preserved long-term, such as expense vouchers and contracts. To ensure absolute security and facilitate auditing, these documents are typically stored using a combination of offline and online methods, i.e., preserving paper documents and inputting their content into information systems. Paper documents have limited shelf life, consume significant warehouse resources, and are easily destroyed due to various accidents. Therefore, online backups often become unique copies, requiring focused protection. For small and medium-sized enterprises (SMEs), traditional multi-disk, multi-node backup methods are costly in terms of hardware and lack effective anti-tampering mechanisms, while innovative blockchain technology requires even higher maintenance costs. SMEs need a file backup method that balances high efficiency, low storage requirements, and high security.

[0003] Technical solutions of existing technologies

[0004] A relatively new file backup technology is based on blockchain. The general steps are: setting up a backup directory; encrypting and sending file data, and submitting the filename, size, permissions, directory, and MD5 value to the computing nodes; the computing nodes record this information and distribute it in blocks to different storage nodes; the storage nodes receive and store the files; when recovery is needed, a request is sent to the computing nodes, which, based on the records, retrieve and merge the decrypted data, ultimately achieving data recovery.

[0005] The shortcomings of existing technologies:

[0006] (1) A large amount of block information is repeated, resulting in data redundancy;

[0007] (2) The nodes where the files are located need to be constantly synchronized with each other, which can easily overload the internal network of the enterprise.

[0008] (3) It requires a lot of computing resources, and the cost of software and hardware is high, as is the cost of operation and maintenance. Summary of the Invention

[0009] To address the aforementioned technical problems, the purpose of this invention is to provide a high-performance, low-storage file backup method that is tamper-proof and damage-proof. This method aims to improve hardware resource utilization; in the uncompressed case, the backup file requires only 33% of the total disk space. It also improves data read / write performance, enabling read / write separation and parallel read / write without requiring significant encryption and synchronization computing resources. Furthermore, it enhances security, allowing for the verification and repair of any file, and enabling reconstruction even if any backup node is completely destroyed.

[0010] The objective of this invention is achieved through the following technical solution:

[0011] A method for backing up office documents to prevent tampering and damage includes:

[0012] Step A involves backing up the files using servers and storage nodes;

[0013] Step B involves obtaining file-related record information and reading and comparing the record information.

[0014] Step C is to recover the damaged file.

[0015] Compared with the prior art, one or more embodiments of the present invention may have the following advantages:

[0016] (1) Low capacity consumption: After saving two files, a binary XOR operation is performed on the files to form a file association information. This file association information can be used for data anti-tampering verification and data backup. Ideally, the file association information only occupies 33% of the total backup file size. In contrast, file backups based on traditional copying are 100% of the total backup file size without compression, and file backups based on blockchain technology are more than 300% of the total backup file size. Therefore, the method of this invention consumes less space.

[0017] (2) Fast backup speed: It is equivalent to performing hot backup of files at all times. The hot backup granularity is two files, and the backup content is evenly distributed in three storage nodes, which can improve the file writing speed by 100% compared to the traditional backup method.

[0018] (3) High security: Any file in the same group can be recovered or verified through the other two, thus preventing file data from being corrupted or tampered with. The bin file stored on the storage node also undergoes a salted XOR operation and does not contain file recovery information, so even if a malicious actor obtains the bin file, they cannot recover its contents. Moreover, it would take breaching two remotely deployed storage nodes to destroy the file. Similarly, in the event of an unforeseen disaster, at least two storage nodes must be damaged to corrupt the file. Attached Figure Description

[0019] Figure 1 This is a flowchart illustrating a method for backing up office documents to prevent tampering and damage.

[0020] Figure 2 This is a system topology diagram of a method for backing up office documents to prevent tampering and damage.

[0021] Figure 3 This is a flowchart of file backup;

[0022] Figure 4 This is a flowchart of the file reading process. Detailed Implementation

[0023] To make the objectives, technical solutions, and advantages of the present invention clearer, the present invention will be described in further detail below with reference to the embodiments and accompanying drawings.

[0024] like Figure 1 The following steps are shown as a method for backing up office documents to prevent tampering and damage:

[0025] Step 10: Back up the files using the server and storage nodes;

[0026] Step 20: Obtain file-related record information, and read and compare the record information;

[0027] Step 30 involves recovering the damaged files.

[0028] Step 10 above specifically includes the following steps:

[0029] Step 101: Set up at least one server and three storage nodes for file backup;

[0030] Step 102: The user logs into the server, submits the backed-up file, and the server caches the file;

[0031] Step 103: Write the file content information into the time series database;

[0032] Step 104 performs binary conversion on two backup files that are sequentially adjacent to each other to obtain byte streams a and b;

[0033] Step 105 aligns a and b, then XORs them with salt to obtain two bin files, a′ and b′.

[0034] Step 106: Perform an XOR operation on a′ and b′ to obtain the bin file c′, and write the information into the time series database;

[0035] Step 107: Group a′, b′, and c′ together and store them sequentially on the three file backup nodes.

[0036] The storage nodes mentioned in step 101 above are three geographically deployed NAS storage devices. The encrypted binary BIN file and the BIN file obtained by XORing are stored alternately by the three storage nodes. The storage node numbers for each group alternate between 123, 231, and 312. Assuming the set of files to be backed up is {A, B, C, D, ...}, they are stored in groups of two files and one XOR result, starting from storage node 1. The order of each group also alternates, as shown in Table 1.

[0037] Table 1

[0038] Storage Node 1 Storage Node 2 Storage Node 3 A's bin file a' B's bin file b' The XOR file ab' of a′ and b′ The XOR file cd' of c' and d' C's bin file c' D's bin file d'

[0039] The time-series database mentioned in step 103 above stores information such as file ID, group ID, original file name, original file extension, actual storage path, and random encryption salt, as shown in Table 2:

[0040] Table 2

[0041] ID Group ID name suffix path Salt state 1 1 xxx framework contract .pdf node_1: / / namel 10010011 normal 2 1 xxx protocol .doc node_2: / / name2 11010011 normal 3 1 Backup redundant files null node_3: / / name3 10101011 normal 4 2 xxx Research Report .pdf node_2: / / name4 11011101 normal 5 2 xxx Cooperation Contract .jpg node_3: / / name5 11001100 normal 6 2 Backup redundant files null node_l: / / name6 10111011 normal

[0042] Assuming that the content of each file in the set of files to be backed up, {A, B, C, D}, is {'this', 'is', 'a', 'demo'}, then their corresponding binary streams, aligned binary streams, salted XOR encryption, and XOR results are shown in Table 3:

[0043] Table 3

[0044]

[0045] The contents of the bin files stored on the storage node for the file set {A, B, C, D} are shown in Table 4:

[0046] Table 4

[0047] Storage Node 1 Storage Node 2 Storage Node 3 01110100 01101000 01101001 11100000 01101001 01110011 00000000 11010011 0001 1101 0001 1011 0110 1001 0011 0011 0000 0101 0110 0101 0110 1101 0111 1110 01100001 00000000 00000000 11011101 01100100 01100101 01101101 10100011

[0048] like Figure 3 As shown, the specific process of obtaining file-related record information and reading and comparing the record information in step 20 above includes:

[0049] Step 21: Log in to the server and retrieve file A from the database to obtain file-related record information;

[0050] Step 22: Based on the recorded information, read and obtain the corresponding bin file a′ and the same group files b′ and c′;

[0051] Step 23: Perform an XOR operation on b′ and c′ to obtain a″, and compare a″ with a′;

[0052] If the comparison is consistent in step 24, then perform XOR decryption on a′ using salt to obtain a, and then generate file A;

[0053] If the comparison in step 25 is inconsistent, then file A has been tampered with or corrupted; record this and return an error message.

[0054] Assuming file A is obtained from Table 3, according to step 21 above, information about file A and the other two files in the same group is obtained, including ID, group ID name, suffix, path, salt, etc., as shown in Table 5 below:

[0055] Table 5

[0056] ID Group ID name suffix path Salt state 1 1 xxx framework contract .pdf node_1: / / namel 10010011 normal 2 1 xxx protocol .doc node_2: / / name2 11010011 normal 3 1 Backup redundant files null node_3: / / name3 10101011 normal

[0057] In steps 22-24 above, a′, b′, and c′ are obtained based on the path information. A bitwise XOR operation is performed on b′ and c′ to obtain a″, which is then compared with a′. The contents of a′, b′, c′, and a″ are shown in Table 6.

[0058] Table 6

[0059] document content a′ 01110100011010000110100111100000 b′ 01101001011100110000000011010011 c′ 00011101000110110110100100110011 a″ 01110100011010000110100111100000

[0060] The comparison shows that a′ = a″, indicating that the file is not corrupted or tampered with. a′ can be decrypted. The decryption process involves XORing a′ with the salt to obtain a. The salt value of a′ can be found in Table 6, and the process is shown in Table 7.

[0061] Table 7

[0062] document content Salt a is obtained by XOR. a′ 01110100011010000110100111100000 10010011 0111 0100 0110 1000 0110 1001 0111 0011

[0063] Perform a binary inverse operation on 'a' to obtain the original file A. Restore the filename and extension according to Table 6 to obtain the file "xxx framework contract.pdf". Return the file to the user; the file reading operation is now complete.

[0064] The specific process for recovering the damaged file in step 30 above includes:

[0065] If file a′ is corrupted, it is replaced by performing an XOR operation on files b′ and c′ in the same group. The formula is shown below, where XOR is an abbreviation for the exclusive OR operation. XOR This represents the XOR operation.

[0066] a′=f XOR (b′,c′)

[0067] If storage node 1 is completely damaged, then all bin files of the damaged node are regenerated by XORing the bin files of the other two storage nodes according to their group, as shown in Table 8:

[0068] Table 8

[0069]

[0070]

[0071] While the embodiments disclosed in this invention are as described above, the content is merely for the purpose of facilitating understanding of the invention and is not intended to limit the invention. Any person skilled in the art to which this invention pertains may make any modifications and variations in form and detail of the implementation without departing from the spirit and scope disclosed herein; however, the scope of patent protection for this invention shall still be determined by the scope defined in the appended claims.

Claims

1. A method for backing up office documents to prevent tampering and damage, characterized in that, Includes the following steps: Step A involves backing up the files using servers and storage nodes; Step B involves obtaining file-related record information and reading and comparing the record information. Step C: Recover the damaged files; Step A specifically includes: Step A1 requires at least one server and three storage nodes for file backup; Step A2: Log in to the server, submit the files to be backed up, and cache the files; Step A3 writes the file content information into the time series database; Step A4 performs binary conversion on two backup files that are sequentially adjacent, obtaining byte streams a and b; Step A5 aligns a and b, then XORs them with salt to obtain two bin files, a' and b'. Step A6 performs an XOR operation on a' and b' to obtain the bin file c', which is then written to the time series database; Step A7 groups a', b', and c' together and stores them sequentially in the three file backup nodes; The storage nodes are three NAS storage devices deployed in different locations, and the encrypted binary bin file and the bin file obtained by XORing are stored in turn by the three storage nodes. The file content information written to the time-series database includes file ID, group ID, original file name, original file extension, actual storage path, and random encryption salt; The alternating storage is performed by grouping two files and an XOR result together, starting from storage node 1. The order of each group is also changed alternately, alternating between storage node numbers 123, 231, and 312. Step B specifically includes Step B1: Log in to the server and retrieve file A from the database to obtain file-related record information; Step B2 reads the corresponding bin file a' and its group members b' and c' based on the recorded information; Step B3 performs an XOR operation on b' and c' to obtain a", and compares a" with a'; If the comparison in step B4 is consistent, then the salt is XORed to decrypt a' to obtain a, and then file A is generated; If the comparison in step B5 is inconsistent, then file A has been tampered with or corrupted, and an error message is recorded and returned.

2. The method for backing up office documents against tampering and damage as described in claim 1, characterized in that, Step C specifically includes: If file a' is corrupted, it is replaced by XORing file b' and c' in the same group; If the entire storage node is damaged, all bin files of the damaged node are regenerated by XORing the bin files of the other two storage nodes in the same group.

3. The method for backing up office documents against tampering and damage as described in claim 1, characterized in that, In file reading and recovery, the XOR comparison between the same group is used to detect whether the file has been modified, and the data is recovered by XOR operation of the other two data in the same group; when a storage node is damaged or crashes, the data is recovered by performing an overall XOR operation from the other two storage nodes.

Citation Information

Patent Citations

  • High-performance low-storage system log tamper-proofing method

    CN114186289A