A blockchain file distribution system and method based on copy-proof storage media

The combination of the AES-128 encryption algorithm and the anti-copy storage medium module solves the problems of full-process encryption and unauthorized copying and dissemination of file distribution, achieving file security and copyright protection.

CN118944852BActive Publication Date: 2025-09-19BEIJING INST OF TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410809224.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-21
Publication Date
2025-09-19
Estimated Expiration
2044-06-21

AI Technical Summary

Technical Problem

Existing technologies cannot effectively ensure encryption throughout the entire file distribution process, which may lead to unauthorized copying and dissemination of files after they are received, infringing the legitimate rights and interests of copyright owners.

Method used

Files are encrypted using the AES-128 encryption algorithm and cipher block chaining mode, and the anti-copy storage medium module monitors and blocks the reading rate of file recipients, ensuring that file recipients can only read but not copy.

Benefits of technology

It realizes encryption protection of the entire file distribution process, prevents unauthorized copying and dissemination, and ensures file security and copyright protection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118944852B_ABST
    Figure CN118944852B_ABST
Patent Text Reader

Abstract

The present invention relates to a blockchain file distribution system and method based on an anti-copy storage medium, belonging to the field of blockchain technology. The present invention includes the following steps: 1. uploading an initial file to be distributed; 2. encrypting the initial file to be distributed to form an encrypted block storage file; 3. downloading by a file recipient; 4. exchanging the file for an available download quota through a recharge payment method; 5. verifying the matching of the file recipient's identity and serial number; 6. decrypting the file; 7. placing the downloaded encrypted block storage file in an anti-copy storage medium module; 8. the anti-copy storage medium module cyclically monitors its own reading rate to block the copying operation of the file recipient. The present invention utilizes the difference in the reading rate of the storage medium module when reading and copying files, and prevents the unauthorized copying and dissemination of the file recipient through the coordinated work of the serial number storage area, monitoring area, blocking area, decryption area, and file storage area.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a blockchain file distribution system and method based on a copy-proof storage medium, belonging to the technical field of blockchain. Background Art

[0002] With the continuous development of the internet, file distribution has become a crucial application. The file distribution process involves not only sending and receiving, but also storage and management. At any stage, files may be exposed to the risk of information leakage. Unauthorized copying and dissemination is another significant concern. Once a file reaches the recipient, they may make unauthorized copies and redistribute it, leading to widespread illegal distribution of the file's contents. Existing technologies designed to ensure smooth file distribution often only guarantee security during file transmission, without addressing the potential for unauthorized copying and dissemination by recipients after receiving the file.

[0003] The following defects of the existing technology are addressed: (1) File distribution is widely used, but there are problems such as information leakage and unauthorized copying and dissemination. (2) The inability to encrypt the entire file distribution process will lead to the illegal copying and dissemination of files that require copyright protection, resulting in infringement of the legitimate rights and interests of copyright owners. (3) Traditional file distribution protection measures only focus on ensuring the encryption of the communication channel between the file distributor and the recipient or the authentication of the identity, ignoring the possible unauthorized copying and dissemination of the file by the file recipient after receiving it, resulting in the leakage of private files.

[0004] Therefore, how to ensure the full encryption of blockchain file distribution and prevent unauthorized copying and dissemination of file recipients has become an urgent problem to be solved. Summary of the Invention

[0005] The purpose of the present invention is to solve the technical problems of full-process encryption of blockchain file distribution and preventing unauthorized copying and dissemination of file recipients, and to propose a blockchain file distribution system and method based on copy-proof storage media.

[0006] This invention discloses a blockchain file distribution system and method based on a copy-protected storage medium. Its operating principle is as follows: By designing and implementing the entire file distribution process, from file upload, file storage, file encryption, file download, file decryption, and copy protection mechanisms, an encryption algorithm is used to ensure file privacy. Furthermore, a copy-protected storage medium module is provided that allows reading but prohibits copying, achieving full-process encryption protection for file distribution operations. This provides a new approach to data privacy protection and file distribution encryption.

[0007] The purpose of the present invention is achieved through the following technical solutions:

[0008] In one aspect, a blockchain file distribution method based on a copy-proof storage medium of the present invention is applied to member nodes of a peer-to-peer network file distribution, wherein the member nodes of the file distribution include a file distributor and a file receiver, and comprises the following steps:

[0009] Step 1: The file distributor uploads the initial file to be distributed to the block of the blockchain.

[0010] Step 2: Encrypt the initial file to be distributed described in step 1 using the encryption method and encryption mode of the existing technology to form an encrypted block storage file.

[0011] Step 2.1: The encryption method described in step 2 includes a symmetric encryption method and an asymmetric encryption method. Preferably, the present invention is implemented using the AES-128 encryption algorithm.

[0012] Step 2.2: The encryption mode described in step 2 is Cipher Block Chaining (CBC).

[0013] Step 2.3: Generate a 128-bit Initialization Vector (IV) using a random method based on the cipher block chaining mode in step 2.2.

[0014] Step 2.4: Split the file to be encrypted into multiples of 128 bits of the file size to obtain the divided plaintext blocks and the number of plaintext blocks.

[0015] Step 2.4.1: If the file size is an integer multiple of 128 bits, add 16 0x10 bytes to the end of the file.

[0016] Step 2.4.2: If the file size is not an integer multiple of 128 bits, subtract the size of the last plaintext block from 16 to get the result t, then add t 0xt bytes to the end of the file.

[0017] Step 2.5: XOR the initialization vector generated in step 2.3 with the first plaintext block obtained in step 2.4 to obtain the result temp. Then, encrypt temp using the encryption algorithm used in step 2.1 to obtain the first ciphertext block. Next, XOR the previous ciphertext block with the plaintext block to be encrypted. Finally, encrypt the result using the encryption algorithm used in step 2.1 to obtain the ciphertext block.

[0018] Step 2.6: Repeat step 2.2 with the number of plaintext blocks described in step 2.4 as the number of cycles to obtain the ciphertext block.

[0019] Step 2.7: Concatenate the ciphertext blocks sequentially, starting with the head and ending with the tail.

[0020] Step 2.8: Place the initialization vector generated in step 2.3 before the sequentially concatenated ciphertext blocks to form a ciphertext file.

[0021] Step 3: The file recipient uses the download quota and serial number to download the encrypted block storage file.

[0022] Step 3.1: The serial number described in step 3 is the serial number of the copy-protected storage medium module that can be input. The serial number is an identification code assigned by the manufacturer.

[0023] Step 3.2: The download limit described in step 3 is the download limit that can be entered, that is, the size of the file to be downloaded.

[0024] Step 3.3: If the available download quota is less than the size of the file to be downloaded, go to Step 4.

[0025] Step 3.4: When the available download quota is equal to or greater than the size of the file to be downloaded, the encrypted block file download is complete and proceed to step 6.

[0026] Step 4: The file recipient redeems the available download quota through a recharge payment method based on the inputtable copy-protected storage medium module serial number and the inputtable download quota.

[0027] Step 4.1: After the file recipient makes the recharge payment, a recharge code is generated.

[0028] Step 4.2: The file recipient redeems the top-up code from Step 4.1 for available download credit. Go to Step 3.

[0029] Step 5: The blockchain file distribution system is used to verify the identity of the file recipient and the matching of the serial number in step 3.

[0030] Step 5.1: When the file recipient downloads the file, he / she needs to enter his / her account information and the serial number of the copy-protected storage medium module in the blockchain file distribution system.

[0031] Step 5.2: After receiving the input information from the file recipient, the blockchain file distribution system will confirm the identity information entered by the file recipient and the serial number of the anti-copy storage medium module.

[0032] Step 5.2.1: When the identity information and serial number information entered by the file recipient are verified to be consistent, it proves that the recipient is a legitimate identity and proceeds to step 4.

[0033] Step 5.2.2: If the identity information and serial number information entered by the recipient are inconsistent, it is considered that the recipient is illegal and the process goes to step 5.

[0034] Step 6: Decrypt the downloaded encrypted block storage file using the decryption method and decryption mode to form a readable plaintext file.

[0035] Step 6.1: Decrypt the encrypted block storage file through the inverse process of the AES-128 encryption algorithm.

[0036] Step 6.2: Define the decryption mode described in step 6 as cipher block chaining mode.

[0037] Step 6.3: Read the first 128 bits of the downloaded encrypted block storage file and extract the initialization vector.

[0038] Step 6.4: Divide the remaining portion of the encrypted block storage file after removing the first 128 bits into ciphertext blocks according to multiples of 128 bits to obtain the ciphertext blocks and the number of ciphertext blocks.

[0039] Step 6.5: Decrypt the first ciphertext block obtained in step 6.4 using the decryption method in step 6.1. XOR the result with the initialization vector to obtain the first plaintext block. The next ciphertext block to be decrypted is decrypted using the decryption method in step 6.1 and XORed with the previous ciphertext block to obtain the plaintext block.

[0040] Step 6.6: Repeat step 6.5 with the number of ciphertext blocks described in step 6.4 as the number of cycles to obtain the plaintext block.

[0041] Step 6.7: Read the last byte t of the last plaintext block and remove the last t bytes.

[0042] Step 6.8: Concatenate all plaintext blocks in order from beginning to end to obtain the plaintext file.

[0043] Step 7: The encrypted block storage file downloaded in step 3 is placed in the copy-protected storage medium module, and decrypted using the decryption module of the copy-protected storage medium module.

[0044] Step 7.1: The blockchain file distribution system detects the serial number of the anti-copy storage medium module. When the serial number is detected, go to step 7.2; when the serial number does not exist, go to step 7.

[0045] Step 7.2: Decrypt the downloaded encrypted block storage file according to the decryption method and decryption mode described in step 6 and place it in the copy-protected storage medium module to obtain a readable plaintext file.

[0046] Step 7.3: The file receiver reads the plaintext file and proceeds to step 8.

[0047] Step 8: The copy-protected storage medium module cyclically monitors its own reading rate to block the copying operation of the file recipient, thereby sealing the decrypted plaintext file in the copy-protected storage medium module.

[0048] Step 8.1: Set a predetermined threshold value for the reading rate of the copy-protected storage medium module.

[0049] Step 8.2: When the file receiver is performing a read operation, monitor the read rate in a loop.

[0050] Step 8.2.1: When the reading rate is greater than or equal to the preset threshold, go to step 8.3.

[0051] Step 8.2.2: When the reading rate is less than the set threshold, go to step 8.2.

[0052] Step 8.3: Execute the blocking operation to terminate the file receiver's reading behavior and stop monitoring.

[0053] On the other hand, in order to achieve the purpose of the present invention, based on the above method, the present invention further proposes a blockchain file distribution system for implementing the above method, including a file upload module, an encryption module, a recharge payment module, a file download module, and an anti-copy storage medium module.

[0054] The file upload module is used to upload the file to be encrypted to the block of the blockchain for storage, and use the stored file as the input of the encryption module;

[0055] The encryption module is used to encrypt the block storage file to form an encrypted block storage file; the encrypted block storage file is used as the input of the recharge payment module;

[0056] The recharge payment module is used to generate a recharge code after the file recipient completes the recharge payment, and redeem the recharge code for available download credit; the available download credit is used as input to the file download module;

[0057] The file download module is used to download the file to be downloaded and store it in the copy-protected storage medium module;

[0058] The anti-copy storage medium module is used to monitor and block the copying behavior of file downloaders and seal the decrypted plain text files in the anti-copy storage medium module. The anti-copy storage medium module includes a serial number storage area, a monitoring area, a blocking area, a decryption area, and a file storage area;

[0059] The serial number storage area is used to store and access the identity of the copy-protected storage medium module. This identity is a unique serial number assigned by the manufacturer during manufacture. The file distributor identifies the file recipient by reading the assigned unique serial number. This serial number is used to verify the authenticity of the file recipient. When the file recipient requests a file download, the blockchain file distribution system verifies the recipient's legitimacy by reading the serial number they enter.

[0060] Monitoring Zone: This zone is used to cyclically monitor the actual read rate of the file storage area to see if it reaches a pre-set threshold. This means that when a file recipient reads a plaintext file, the monitoring zone will cyclically record the actual read rate. During a single cycle of monitoring, if the actual read rate falls below the threshold, the monitoring zone will continue to cyclically monitor the read rate. If the actual read rate exceeds the threshold, the blockchain file distribution system will immediately jump to the blocking zone for blocking.

[0061] Blocking zone: When the monitoring zone detects that the actual reading rate exceeds the set threshold, the blocking zone blocks the copying operation of the file receiver.

[0062] Decryption Area: After encrypted block storage files are placed in the copy-protected storage media module, they must be decrypted in the decryption area. This area uses the inverse process of the encryption algorithm to decrypt the encrypted file, converting it into plaintext for the recipient to read and view. The plaintext file is then placed in the file storage area.

[0063] File Storage Area: This area stores plaintext files decrypted by the Decryption Area. These plaintext files are accessible only on the copy-protected storage medium. Specifically, the Monitoring Area monitors the recipient's copying attempts and further blocks them using the Blocking Area. Consequently, any plaintext files downloaded by the recipient are sealed in the copy-protected storage medium.

[0064] Beneficial effects:

[0065] 1. This invention discloses a blockchain file distribution system and method based on a copy-protected storage medium. It incorporates blockchain technology to store files to be distributed and encrypts them using the AES-128 algorithm, ensuring security during file upload, storage, and transmission.

[0066] 2. Decryption of encrypted files is achieved through the anti-copy storage medium module. The difference in the reading rate of the storage medium module when reading files and copying files is utilized. Through the coordinated work of the serial number storage area, monitoring area, blocking area, decryption area, and file storage area, the file security is maximized and the unauthorized copying and dissemination of the file recipient is prevented.

[0067] 3. The entire file distribution process was tested and verified. The test showed that the proposed file distribution system can ensure the entire process of file distribution and improve the encryption of file distribution. BRIEF DESCRIPTION OF THE DRAWINGS

[0068] Figure 1 Schematic diagram of the method flow of the present invention;

[0069] Figure 2 Schematic diagram of the system flow of the present invention;

[0070] Figure 3 This is a flowchart of file decryption by the copy-protected storage medium module of the present invention;

[0071] Figure 4 A test chart showing the difference in the read and copy rates when monitoring a file.

[0072] Figure 5 This is a test chart of the storage medium blocking copy operations for files of different sizes. DETAILED DESCRIPTION

[0073] In order to better illustrate the purpose and advantages of the present invention, the following is a further description of the invention in conjunction with the accompanying drawings and examples. It should be noted that the implementation of the present invention is not limited to the following embodiments, and any form of modification or change made to the present invention will fall within the scope of protection of the present invention.

[0074] Example

[0075] like Figure 1 As shown, the blockchain file distribution method based on the copy-proof storage medium of the present invention is specifically implemented as follows:

[0076] Step 1: The file distributor uploads the initial file to be distributed to the block of the blockchain.

[0077] Step 2: Encrypt the initial file to be distributed described in step 1 using the encryption method and encryption mode of the existing technology to form an encrypted block storage file.

[0078] Step 2.1: The encryption method described in step 2 includes a symmetric encryption method and an asymmetric encryption method. Preferably, the present invention is implemented using the AES-128 encryption algorithm.

[0079] Step 2.2: The encryption mode described in step 2 is Cipher Block Chaining (CBC).

[0080] Step 2.3: Generate a 128-bit Initialization Vector (IV) using a random method based on the cipher block chaining mode in step 2.2.

[0081] Step 2.4: Split the file to be encrypted into multiples of 128 bits of the file size to obtain the divided plaintext blocks and the number of plaintext blocks.

[0082] Step 2.4.1: If the file size is an integer multiple of 128 bits, add 16 0x10 bytes to the end of the file.

[0083] Step 2.4.2: If the file size is not an integer multiple of 128 bits, subtract the size of the last plaintext block from 16 to get the result t, then add t 0xt bytes to the end of the file.

[0084] Step 2.5: XOR the initialization vector generated in step 2.3 with the first plaintext block obtained in step 2.4 to obtain the result temp. Then, encrypt temp using the encryption algorithm used in step 2.1 to obtain the first ciphertext block. Next, XOR the previous ciphertext block with the plaintext block to be encrypted. Finally, encrypt the result using the encryption algorithm used in step 2.1 to obtain the ciphertext block.

[0085] Step 2.6: Repeat step 2.2 with the number of plaintext blocks described in step 2.4 as the number of cycles to obtain the ciphertext block.

[0086] Step 2.7: Concatenate the ciphertext blocks sequentially, starting with the head and ending with the tail.

[0087] Step 2.8: Place the initialization vector generated in step 2.3 before the sequentially concatenated ciphertext blocks to form a ciphertext file.

[0088] In the embodiment, the file distributor uploads a demo.mp4 file with a file size of 756MB (793,457,187 bytes) to a block on the blockchain.

[0089] Step 3: The file recipient uses the download quota and serial number to download the encrypted block storage file.

[0090] Step 3.1: The serial number described in step 3 is the serial number of the copy-protected storage medium module that can be input. The serial number is an identification code assigned by the manufacturer.

[0091] Step 3.2: The download limit described in step 3 is the download limit that can be entered, that is, the size of the file to be downloaded.

[0092] Step 3.3: If the available download quota is less than the size of the file to be downloaded, go to Step 4.

[0093] Step 3.4: When the available download quota is equal to or greater than the size of the file to be downloaded, the encrypted block file download is complete and proceed to step 6.

[0094] Step 4: The file recipient redeems the available download quota through a recharge payment method based on the inputtable copy-protected storage medium module serial number and the inputtable download quota.

[0095] Step 4.1: After the file recipient makes the recharge payment, a recharge code is generated.

[0096] Step 4.2: The file recipient redeems the top-up code from Step 4.1 for available download credit. Go to Step 3.

[0097] In the embodiment, the file recipient enters the storage medium serial number "2LSP4CJT" and a download quota of 800MB, completes the recharge payment, obtains a recharge code, and redeems 800MB of available download quota.

[0098] Step 5: The blockchain file distribution system is used to verify the identity of the file recipient and the matching of the serial number in step 3.

[0099] Step 5.1: When the file recipient downloads the file, he / she needs to enter his / her account information and the serial number of the copy-protected storage medium module in the blockchain file distribution system.

[0100] Step 5.2: After receiving the input information from the file recipient, the blockchain file distribution system will confirm the identity information entered by the file recipient and the serial number of the anti-copy storage medium module.

[0101] Step 5.2.1: When the identity information and serial number information entered by the file recipient are verified to be consistent, it proves that the recipient is a legitimate identity and proceeds to step 4.

[0102] Step 5.2.2: If the identity information and serial number information entered by the recipient are inconsistent, it is considered that the recipient is illegal and the process goes to step 5.

[0103] In the embodiment, the file recipient enters his / her own identity information, including name XXX, phone number XXX, etc., and the assigned storage medium serial number "2LSP4CJT".

[0104] Step 6: Decrypt the downloaded encrypted block storage file using the decryption method and decryption mode to form a readable plaintext file.

[0105] Step 6.1: Decrypt the encrypted block storage file through the inverse process of the AES-128 encryption algorithm.

[0106] Step 6.2: Define the decryption mode described in step 6 as cipher block chaining mode.

[0107] Step 6.3: Read the first 128 bits of the downloaded encrypted block storage file and extract the initialization vector.

[0108] Step 6.4: Divide the remaining portion of the encrypted block storage file after removing the first 128 bits into ciphertext blocks according to multiples of 128 bits to obtain the ciphertext blocks and the number of ciphertext blocks.

[0109] Step 6.5: Decrypt the first ciphertext block obtained in step 6.4 using the decryption method in step 6.1. XOR the result with the initialization vector to obtain the first plaintext block. The next ciphertext block to be decrypted is decrypted using the decryption method in step 6.1 and XORed with the previous ciphertext block to obtain the plaintext block.

[0110] Step 6.6: Repeat step 6.5 with the number of ciphertext blocks described in step 6.4 as the number of cycles to obtain the plaintext block.

[0111] Step 6.7: Read the last byte t of the last plaintext block and remove the last t bytes.

[0112] Step 6.8: Concatenate all plaintext blocks in order from beginning to end to obtain the plaintext file.

[0113] Step 7: The encrypted block storage file downloaded in step 3 is placed in the copy-protected storage medium module, and decrypted using the decryption module of the copy-protected storage medium module.

[0114] Step 7.1: The blockchain file distribution system detects the serial number of the anti-copy storage medium module. When the serial number is detected, go to step 7.2; when the serial number does not exist, go to step 7.

[0115] Step 7.2: Decrypt the downloaded encrypted block storage file according to the decryption method and decryption mode described in step 6 and place it in the copy-protected storage medium module to obtain a readable plaintext file.

[0116] Step 7.3: The file receiver reads the plaintext file and proceeds to step 8.

[0117] Step 8: The copy-protected storage medium module cyclically monitors its own reading rate to block the copying operation of the file recipient, thereby sealing the decrypted plaintext file in the copy-protected storage medium module.

[0118] Step 8.1: Set a predetermined threshold value for the reading rate of the copy-protected storage medium module.

[0119] Step 8.2: When the file receiver is performing a read operation, monitor the read rate in a loop.

[0120] Step 8.2.1: When the reading rate is greater than or equal to the preset threshold, go to step 8.3.

[0121] Step 8.2.2: When the reading rate is less than the set threshold, go to step 8.2.

[0122] Step 8.3: Execute the blocking operation to terminate the file receiver's reading behavior and stop monitoring.

[0123] In the embodiment, a USB flash drive carrying a T620 chip is used as a dedicated storage medium, and a threshold for executing a scsi_read command, ie, a read command, is set to 50 times / s.

[0124] On the other hand, to achieve the purpose of the present invention, according to the above method, Figure 2 As shown, the present invention further proposes a blockchain file distribution system for implementing the above method, including a file upload module, an encryption module, a recharge payment module, a file download module, and an anti-copy storage medium module.

[0125] The file upload module is used to upload the file to be encrypted to the block of the blockchain for storage, and use the stored file as the input of the encryption module;

[0126] The encryption module is used to encrypt the block storage file to form an encrypted block storage file; the encrypted block storage file is used as the input of the recharge payment module;

[0127] The recharge payment module is used to generate a recharge code after the file recipient completes the recharge payment, and redeem the recharge code for available download credit; the available download credit is used as input to the file download module;

[0128] The file download module is used to download the file to be downloaded and store it in the copy-protected storage medium module;

[0129] like Figure 3 As shown, the anti-copy storage medium module is used to monitor and block the copying behavior of file downloaders and seal the decrypted plain text files in the anti-copy storage medium module. The anti-copy storage medium module includes a serial number storage area, a monitoring area, a blocking area, a decryption area, and a file storage area;

[0130] The serial number storage area is used to store and access the identity of the copy-protected storage medium module. This identity is a unique serial number assigned by the manufacturer during manufacture. The file distributor identifies the file recipient by reading the assigned unique serial number. This serial number is used to verify the authenticity of the file recipient. When the file recipient requests a file download, the blockchain file distribution system verifies the recipient's legitimacy by reading the serial number they enter.

[0131] Monitoring Zone: This zone is used to cyclically monitor the actual read rate of the file storage area to see if it reaches a pre-set threshold. This means that when a file recipient reads a plaintext file, the monitoring zone will cyclically record the actual read rate. During a single cycle of monitoring, if the actual read rate falls below the threshold, the monitoring zone will continue to cyclically monitor the read rate. If the actual read rate exceeds the threshold, the blockchain file distribution system will immediately jump to the blocking zone for blocking.

[0132] Blocking zone: When the monitoring zone detects that the actual reading rate exceeds the set threshold, the blocking zone blocks the copying operation of the file receiver.

[0133] Decryption Area: After encrypted block storage files are placed in the copy-protected storage media module, they must be decrypted in the decryption area. This area uses the inverse process of the encryption algorithm to decrypt the encrypted file, converting it into plaintext for the recipient to read and view. The plaintext file is then placed in the file storage area.

[0134] File Storage Area: This area stores plaintext files decrypted by the Decryption Area. These plaintext files are accessible only on the copy-protected storage medium. Specifically, the Monitoring Area monitors the recipient's copying attempts and further blocks them using the Blocking Area. Consequently, any plaintext files downloaded by the recipient are sealed in the copy-protected storage medium.

[0135] In order to further illustrate the advantages of the present invention, the following description is given in combination with experimental data.

[0136] Table 1 The number of times the experimental USB flash drive executes the scsi_read command per second when copying a 756MB file

[0137]

[0138] As shown in Table 1, when copying a 756MB file, the number of scsi_read commands executed per second is generally above 50. Using 50 times / s as the threshold for monitoring and blocking copy operations is reasonable and effective. Figure 4 As shown in Figure 2, the rate difference test of the read and copy operations when monitoring files shows that the rate difference is very significant when performing copy operations and read operations, so it is reasonable to block the file copy operation based on this. Figure 5 As shown, the storage medium is tested for blocking copy operations for files of different sizes. The storage medium is able to block copy operations for files of different sizes, thereby achieving the requirement of preventing illegal copying by file recipients.

[0139] The results show that the blockchain file distribution system and method based on copy-proof storage medium proposed in the present invention can ensure the encryption of the entire file distribution process and prevent unauthorized copying and dissemination of file recipients, and has strong feasibility and practical value.

Claims

1. A blockchain file distribution method based on a copy-proof storage medium, characterized by: The following steps are included: Step 1: The file distributor uploads the initial file to be distributed to the block of the blockchain; Step 2: Encrypt the initial file to be distributed described in step 1 using an encryption method and encryption mode of existing technology to form an encrypted block storage file; Step 3: The file recipient uses the download quota and serial number to download the encrypted block storage file; Step 4: The file recipient redeems the available download quota using a top-up payment method based on the inputtable copy-protected storage medium module serial number and the inputtable download quota; Step 5: The blockchain file distribution system is used to verify the identity of the file recipient and the match of the serial number in step 3; Step 6: Decrypt the downloaded encrypted block storage file using the decryption method and decryption mode to form a readable plaintext file; Step 7: Place the encrypted block storage file downloaded in step 3 into the copy-protected storage medium module, and use the decryption module of the copy-protected storage medium module to decrypt it; The implementation method of step 7 is: Step 7.1: The blockchain file distribution system detects the serial number of the copy-protected storage medium module. If the serial number is detected, go to step 7.2; if the serial number does not exist, go to step 7. Step 7.2: Decrypt the downloaded encrypted block storage file according to the decryption method and decryption mode described in Step 6 and place it in the copy-protected storage medium module to obtain a readable plaintext file; Step 7.3: The file receiver reads the plaintext file and goes to step 8; Step 8: The copy-protected storage medium module cyclically monitors its own reading rate to block the copying operation of the file recipient, thereby sealing the decrypted plaintext file in the copy-protected storage medium module; The implementation method of step 8 is: Step 8.1: Setting a predetermined threshold value for the reading rate of the copy-protected storage medium module; Step 8.2: When the file receiver performs a read operation, the read rate is monitored in a loop; Step 8.2.1: When the reading rate is greater than or equal to the preset threshold, go to step 8.3; Step 8.2.2: When the reading rate is less than the set threshold, go to step 8.2; Step 8.3: Execute the blocking operation to terminate the file receiver's reading behavior and stop monitoring.

2. A blockchain file distribution method based on a copy-protected storage medium according to claim 1, characterized in that: Step 2 is implemented as follows: Step 2.1: The encryption method described in step 2 includes a symmetric encryption method and an asymmetric encryption method. Preferably, the present invention is implemented using the AES-128 encryption algorithm; Step 2.2: The encryption mode described in step 2 is Cipher Block Chaining (CBC). Step 2.3: Generate a 128-bit Initialization Vector (IV) using a random method based on the cipher block chaining mode in step 2.

2. Step 2.4: Split the file to be encrypted into multiples of 128 bits of the file size to obtain the plaintext blocks and the number of plaintext blocks; Step 2.4.1: If the file size is an integer multiple of 128 bits, add 16 0x10 bytes to the end of the file; Step 2.4.2: If the file size is not an integer multiple of 128 bits, subtract the size of the last plaintext block from 16 to get the result t, then add t 0xt bytes to the end of the file; Step 2.5: XOR the initialization vector generated in step 2.3 with the first plaintext block obtained in step 2.4 to obtain the result temp. Then, encrypt temp according to the encryption algorithm used in step 2.1 to obtain the first ciphertext block. Then, perform an XOR operation on the previous ciphertext block and the plaintext block to be encrypted. The result of the operation is encrypted using the encryption algorithm used in step 2.1 to obtain the ciphertext block. Step 2.6: Repeat step 2.2 with the number of plaintext blocks described in step 2.4 as the number of cycles to obtain the ciphertext block; Step 2.7: Concatenate the ciphertext blocks head to tail and sequentially; Step 2.8: Place the initialization vector generated in step 2.3 before the sequentially concatenated ciphertext blocks to form a ciphertext file.

3. The blockchain file distribution method based on the copy-protected storage medium according to claim 1, characterized in that: Step 3 is implemented as follows: Step 3.1: The serial number mentioned in step 3 is the serial number of the copy-protected storage medium module that can be input. This serial number is an identification code assigned by the manufacturer. Step 3.2: The download limit mentioned in step 3 is the download limit that can be entered, i.e. the size of the file to be downloaded; Step 3.3: When the available download quota is less than the size of the file to be downloaded, go to step 4; Step 3.4: When the available download quota is equal to or greater than the size of the file to be downloaded, the encrypted block file download is complete and proceed to step 6.

4. The blockchain file distribution method based on the copy-protected storage medium according to claim 1, characterized in that: Step 4 is implemented as follows: Step 4.1: After the file recipient makes a top-up payment, a top-up code is generated; Step 4.2: The file recipient redeems the recharge code described in Step 4.1 for available download credit; proceed to Step 3.

5. The blockchain file distribution method based on the copy-protected storage medium according to claim 1, characterized in that: The implementation method of step 5 is: Step 5.1: When the file recipient downloads the file, he / she needs to enter his / her account information and the serial number of the copy-protected storage medium module in the blockchain file distribution system; Step 5.2: After receiving the input information from the file recipient, the blockchain file distribution system will confirm the identity information entered by the file recipient and the serial number of the copy-protected storage medium module; Step 5.2.1: When the identity information and serial number information entered by the file recipient are verified to be consistent, the recipient is proven to be legitimate and the process goes to Step 4; Step 5.2.2: If the identity information and serial number information entered by the recipient are inconsistent, it is considered that the recipient is illegal and the process goes to step 5.

6. The blockchain file distribution method based on the copy-protected storage medium according to claim 1, characterized in that: Step 6 is implemented as follows: Step 6.1: Decrypt the encrypted block storage file using the inverse process of the AES-128 encryption algorithm; Step 6.2: Define the decryption mode described in step 6 as cipher block chaining mode; Step 6.3: Read the first 128 bits of the downloaded encrypted block storage file and extract the initialization vector; Step 6.4: Divide the remaining portion of the encrypted block storage file after removing the first 128 bits into ciphertext blocks according to multiples of 128 bits, and obtain the ciphertext blocks and the number of ciphertext blocks; Step 6.5: Decrypt the first ciphertext block obtained in step 6.4 using the decryption method in step 6.

1. XOR the result with the initialization vector to obtain the first plaintext block. In the subsequent process, decrypt the next ciphertext block using the decryption method in step 6.1 and XOR it with the previous ciphertext block to obtain the plaintext block. Step 6.6: Repeat step 6.5 with the number of ciphertext blocks described in step 6.4 as the number of cycles to obtain the plaintext block; Step 6.7: Read the last byte t of the last plaintext block and remove the last t bytes; Step 6.8: Concatenate all plaintext blocks in order from beginning to end to obtain the plaintext file.

7. A blockchain file distribution system for implementing the method according to any one of claims 1 to 6, characterized in that: Including file upload module, encryption module, recharge payment module, file download module, and anti-copy storage medium module; The file upload module is used to upload the file to be encrypted to the block of the blockchain for storage, and use the stored file as the input of the encryption module; The encryption module is used to encrypt the block storage file to form an encrypted block storage file; the encrypted block storage file is used as the input of the recharge payment module; The recharge payment module is used to generate a recharge code after the file recipient completes the recharge payment, and redeem the recharge code for available download credit; the available download credit is used as input to the file download module; The file download module is used to download the file to be downloaded and store it in the copy-protected storage medium module; The anti-copy storage medium module is used to monitor and block the copying behavior of the file downloader and seal the decrypted plaintext file in the anti-copy storage medium module.

8. A blockchain file distribution system for implementing the method according to any one of claims 1 to 6 according to claim 7, characterized in that: The anti-copy storage medium module includes a serial number storage area, a monitoring area, a blocking area, a decryption area, and a file storage area; wherein, Serial number storage area: The serial number storage area is used to store and access the identity of the copy-protected storage medium module. This identity is the unique serial number assigned by the manufacturer during the manufacture of the copy-protected storage medium module. The file distributor identifies the file recipient by reading the assigned unique serial number. This serial number is used to verify whether the file recipient is a legitimate user. When the file recipient makes a file download request, the blockchain file distribution system will ensure the legitimate identity of the file recipient by reading the serial number entered by the file recipient. Monitoring area: The monitoring area is used to cyclically monitor whether the actual reading rate of the file storage area reaches a pre-set threshold. That is, when the file recipient reads the plaintext file, the monitoring area will cyclically record the actual reading rate. In a single cycle of monitoring, when the actual reading rate is lower than the threshold, the monitoring will continue in the monitoring area. When the actual reading rate exceeds the threshold, the blockchain file distribution system will immediately jump to the blocking area for blocking. Blocking zone: When the monitoring zone detects that the actual reading rate exceeds the set threshold, the blocking zone blocks the copying operation of the file receiver; Decryption area: After the encrypted block storage files are placed in the copy-protected storage medium module, they need to be decrypted in the decryption area. The decryption area is equipped with the inverse process of the encryption algorithm to decrypt, converting the encrypted files into plaintext files, allowing the file recipient to read and view them, and then placing the plaintext files in the file storage area. File storage area: The file storage area is used to store plaintext files decrypted by the decryption area. Such plaintext files are only accessible on the anti-copy storage medium module. That is, the monitoring area monitors the copying operation of the file recipient and further blocks it using the blocking area to prevent the copying behavior of the file recipient. Thus, the plaintext files downloaded by the file recipient are sealed in the anti-copy storage medium module.

Citation Information

Patent Citations

  • Process threading-based copy-protection system and copy-protection storage medium

    CN102495982A

  • File management method, device and equipment and readable storage medium

    CN110851795A