Chip locking method and device based on programmable device, equipment and storage medium
By using the customer information key and the customer key for dual encryption and decryption processing in programmable devices, the problem of low reliability in the chip market is solved, effective chip locking and security of customer profiles are achieved, and the The market is stable.
Patent Information
- Application Number
- CN202411040350.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-31
- Publication Date
- 2024-12-06
AI Technical Summary
The existing technology has problems of low reliability and easy to solve in the chip market, which makes it difficult to effectively achieve product and customer channel lock-in, affecting market order and product quality and safety.
By setting the customer information key and customer key in the programmable device, and using non-volatile storage media for double encryption and decryption processing, it ensures that only authorized customers can access and use the chip configuration file, realizing effective locking of the chip.
It improves the security of customer profiles, prevents unauthorized access and theft, ensures the confidentiality and integrity of project files, avoids illegal use and tampering, and maintains the stability of the chip market.
Smart Images

Figure CN119089458A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of integrated circuits, and in particular to a chip locking method, device, equipment and storage medium based on programmable devices. Background Art
[0002] Programmable devices are a type of highly flexible chip that customers can program to achieve specific functions. Driven by fields such as artificial intelligence, the Internet of Things, and cloud computing, the application areas of programmable devices continue to expand. However, in market promotion, although diversified formal sales channels have been able to meet the needs of most customers in the market, there are still some violations, such as cross-selling and low-end products passing off as high-end products, which seriously affect market order and product quality and safety. In order to solve these problems, it is crucial to lock in product and customer channels for programmable devices.
[0003] At present, the common methods of locking products and customer channels in the market are mainly the following: First, use RFID radio frequency identification technology to track and manage products by attaching RFID tags on the packaging; second, use QR code or barcode technology to achieve traceability by uniquely identifying the products; third, use encryption technology to encrypt product information to ensure that only legitimate customers can access and use it.
[0004] However, for special products such as chips, existing methods have limitations, such as low reliability and easy cracking. Therefore, how to effectively lock in products and customer channels while ensuring the stability of the chip market is a technical problem that urgently needs to be solved. Summary of the invention
[0005] The technical problem to be solved by the present invention is: to provide a chip locking method, device, equipment and storage medium based on a programmable device, which effectively locks the chip through a customer information key and a customer key, thereby improving the security of the customer configuration file while ensuring the stability of the chip market.
[0006] In order to solve the above technical problems, the present invention provides a chip locking method based on a programmable device, comprising:
[0007] Setting a customer information key for the customer, and storing the customer information key in a first non-volatile storage medium of the programmable device and the matching target software;
[0008] When it is detected that a project file is generated in the target software, a customer key input by a customer is obtained, and the customer information key is obtained from the target software, and the project file is double-encrypted based on the customer key and the customer information key to obtain an encrypted project file;
[0009] storing the client key in a second non-volatile storage medium of the programmable device;
[0010] When the encrypted project file input is detected in the programmable device, the customer information key is obtained from the first non-volatile storage medium, and the customer key is obtained from the second non-volatile storage medium, the encrypted project file is doubly decrypted based on the customer information key and the customer key to obtain a decrypted project file, and the programmable device is configured based on the decrypted project file.
[0011] In a possible implementation, the project file is double encrypted based on the customer key and the customer information key to obtain an encrypted project file, specifically including:
[0012] Performing a primary encryption process on the project file based on the client key to obtain a first encrypted project file;
[0013] Perform secondary encryption on the first encrypted project file based on the customer information key to obtain an encrypted project file; or,
[0014] Performing a primary encryption process on the project file based on the customer information key to obtain a first encrypted project file;
[0015] The first encrypted project file is encrypted again based on the client key to obtain an encrypted project file.
[0016] In a possible implementation, the project file is double encrypted based on the customer key and the customer information key to obtain an encrypted project file, specifically including:
[0017] Concatenate the client key and the client information key to obtain a first concatenated key;
[0018] The project file is double encrypted based on the first splicing key to obtain an encrypted project file.
[0019] In a possible implementation, the project file is double encrypted based on the customer key and the customer information key to obtain an encrypted project file, specifically including:
[0020] Performing a primary encryption process on the project file based on the client key to obtain a first encrypted project file;
[0021] Concatenate the client key and the client information key to obtain a first concatenated key;
[0022] Perform secondary encryption processing on the first encrypted project file based on the first concatenated key to obtain an encrypted project file; or,
[0023] Concatenate the client key and the client information key to obtain a first concatenated key;
[0024] Performing a primary encryption process on the project file based on the first concatenation key to obtain a first encrypted project file;
[0025] The first encrypted project file is encrypted again based on the client key to obtain an encrypted project file.
[0026] In a possible implementation, the client key and the client information key are concatenated to obtain a first concatenated key, specifically including:
[0027] Obtain a first length of the customer key and a second length of the customer information key, determine whether the first length and the second length are the same, and if so, perform logical operations on corresponding bits between the customer key and the customer information key based on a preset logical operation combination method to generate a first bit value corresponding to each corresponding bit, integrate the first bit values to obtain a first splicing key, otherwise, directly splice the customer key and the customer information key to obtain a first splicing key.
[0028] In a possible implementation, the encrypted project file is double-decrypted based on the customer information key and the customer key to obtain the decrypted project file, specifically including:
[0029] Decrypting the encrypted project file once based on the customer information key, and obtaining a first decrypted project file after the decryption succeeds once;
[0030] Perform secondary decryption processing on the first decryption project file based on the client key, and obtain the decryption project file after the secondary decryption is successful; or,
[0031] Decrypting the encrypted project file once based on the client key, and obtaining a first decrypted project file after the decryption succeeds once;
[0032] The first decryption project file is decrypted twice based on the customer information key, and after the second decryption is successful, a decryption project file is obtained.
[0033] In a possible implementation, the encrypted project file is double-decrypted based on the customer information key and the customer key to obtain the decrypted project file, specifically including:
[0034] Concatenating the customer information key and the customer key to obtain a second concatenated key;
[0035] The encrypted project file is double-decrypted based on the second splicing key, and after the double decryption is successful, a decrypted project file is obtained.
[0036] In a possible implementation, the encrypted project file is double-decrypted based on the customer information key and the customer key to obtain the decrypted project file, specifically including:
[0037] Concatenating the customer information key and the customer key to obtain a second concatenated key;
[0038] Decrypting the encrypted project file once based on the second concatenated key, and obtaining a first decrypted project file after the decryption succeeds once;
[0039] Performing secondary decryption processing on the first decryption project file based on the client key, and obtaining a decryption project file after the secondary decryption is successful; or
[0040] Decrypting the encrypted project file once based on the client key, and obtaining a first decrypted project file after the decryption succeeds once;
[0041] Concatenating the customer information key and the customer key to obtain a second concatenated key;
[0042] The first decrypted engineering file is decrypted twice based on the second splicing key, and after the second decryption is successful, a decrypted engineering file is obtained.
[0043] In a possible implementation, setting a customer information key for a customer and storing the customer information key in a first non-volatile storage medium of a programmable device and a matching target software specifically includes:
[0044] Obtaining a unique identification code corresponding to the customer, and setting a customer information key corresponding to the customer based on the unique identification code;
[0045] Determine the programmable device and target software delivered to the customer, and write the customer information key into the target software based on a preset software data writing method;
[0046] Encrypting the customer information key in the target software based on a preset encryption algorithm to obtain the encrypted customer information key;
[0047] Based on a preset chip data writing method, the customer information key is written into a first non-volatile storage medium of the programmable device.
[0048] The present invention also provides a chip locking device based on a programmable device, comprising: a customer information key storage module, a project file double encryption module, a customer key storage module and a project file double decryption module;
[0049] Wherein, the customer information key storage module is used to set a customer information key for the customer and store the customer information key in the first non-volatile storage medium of the programmable device and the matching target software;
[0050] The project file double encryption module is used to obtain the customer key input by the customer when detecting that the project file is generated in the target software, and obtain the customer information key from the target software, and perform double encryption processing on the project file based on the customer key and the customer information key to obtain an encrypted project file;
[0051] The client key storage module is used to store the client key in a second non-volatile storage medium of the programmable device;
[0052] The engineering file double decryption module is used to obtain the customer information key from the first non-volatile storage medium and the customer key from the second non-volatile storage medium when it is detected that the encrypted engineering file exists in the programmable device, double decrypt the encrypted engineering file based on the customer information key and the customer key to obtain a decrypted engineering file, and configure the programmable device based on the decrypted engineering file.
[0053] In a possible implementation, the project file double encryption module is used to perform double encryption processing on the project file based on the customer key and the customer information key to obtain an encrypted project file, specifically including:
[0054] Performing a primary encryption process on the project file based on the client key to obtain a first encrypted project file;
[0055] Perform secondary encryption on the first encrypted project file based on the customer information key to obtain an encrypted project file; or,
[0056] Performing a primary encryption process on the project file based on the customer information key to obtain a first encrypted project file;
[0057] The first encrypted project file is encrypted again based on the client key to obtain an encrypted project file.
[0058] In a possible implementation, the project file double encryption module is used to perform double encryption processing on the project file based on the customer key and the customer information key to obtain an encrypted project file, specifically including:
[0059] Concatenate the client key and the client information key to obtain a first concatenated key;
[0060] The project file is double encrypted based on the first splicing key to obtain an encrypted project file.
[0061] In a possible implementation, the project file double encryption module is used to perform double encryption processing on the project file based on the customer key and the customer information key to obtain an encrypted project file, specifically including:
[0062] Performing a primary encryption process on the project file based on the client key to obtain a first encrypted project file;
[0063] Concatenate the client key and the client information key to obtain a first concatenated key;
[0064] Perform secondary encryption processing on the first encrypted project file based on the first concatenated key to obtain an encrypted project file; or,
[0065] Concatenate the client key and the client information key to obtain a first concatenated key;
[0066] Performing a primary encryption process on the project file based on the first concatenation key to obtain a first encrypted project file;
[0067] The first encrypted project file is encrypted again based on the client key to obtain an encrypted project file.
[0068] In a possible implementation, the engineering file dual encryption module is used to perform splicing processing on the customer key and the customer information key to obtain a first splicing key, specifically including:
[0069] Obtain a first length of the customer key and a second length of the customer information key, determine whether the first length and the second length are the same, and if so, perform logical operations on corresponding bits between the customer key and the customer information key based on a preset logical operation combination method to generate a first bit value corresponding to each corresponding bit, integrate the first bit values to obtain a first splicing key, otherwise, directly splice the customer key and the customer information key to obtain a first splicing key.
[0070] In a possible implementation, the engineering file double decryption module is used to double decrypt the encrypted engineering file based on the customer information key and the customer key to obtain the decrypted engineering file, specifically including:
[0071] Decrypting the encrypted project file once based on the customer information key, and obtaining a first decrypted project file after the decryption succeeds once;
[0072] Perform secondary decryption processing on the first decryption project file based on the client key, and obtain the decryption project file after the secondary decryption is successful; or,
[0073] Decrypting the encrypted project file once based on the client key, and obtaining a first decrypted project file after the decryption succeeds once;
[0074] The first decryption project file is decrypted twice based on the customer information key, and after the second decryption is successful, a decryption project file is obtained.
[0075] In a possible implementation, the engineering file double decryption module is used to double decrypt the encrypted engineering file based on the customer information key and the customer key to obtain the decrypted engineering file, specifically including:
[0076] Concatenating the customer information key and the customer key to obtain a second concatenated key;
[0077] The encrypted project file is double-decrypted based on the second splicing key, and after the double decryption is successful, a decrypted project file is obtained.
[0078] In a possible implementation, the engineering file double decryption module is used to double decrypt the encrypted engineering file based on the customer information key and the customer key to obtain the decrypted engineering file, specifically including:
[0079] Concatenating the customer information key and the customer key to obtain a second concatenated key;
[0080] Decrypting the encrypted project file once based on the second concatenated key, and obtaining a first decrypted project file after the decryption succeeds once;
[0081] Performing secondary decryption processing on the first decryption project file based on the client key, and obtaining a decryption project file after the secondary decryption is successful; or
[0082] Decrypting the encrypted project file once based on the client key, and obtaining a first decrypted project file after the decryption succeeds once;
[0083] Concatenating the customer information key and the customer key to obtain a second concatenated key;
[0084] The first decrypted engineering file is decrypted twice based on the second splicing key, and after the second decryption is successful, a decrypted engineering file is obtained.
[0085] In a possible implementation, the customer information key storage module is used to set a customer information key for a customer and store the customer information key in a first non-volatile storage medium of a programmable device and a matching target software, specifically including:
[0086] Obtaining a unique identification code corresponding to the customer, and setting a customer information key corresponding to the customer based on the unique identification code;
[0087] Determine the programmable device and target software delivered to the customer, and write the customer information key into the target software based on a preset software data writing method;
[0088] Encrypting the customer information key in the target software based on a preset encryption algorithm to obtain the encrypted customer information key;
[0089] Based on a preset chip data writing method, the customer information key is written into a first non-volatile storage medium of the programmable device.
[0090] The present invention also provides a terminal device, comprising a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein the processor implements the chip locking method based on a programmable device as described in any one of the above when executing the computer program.
[0091] The present invention also provides a computer-readable storage medium, which includes a stored computer program, wherein when the computer program is running, the device where the computer-readable storage medium is located is controlled to execute any one of the above-mentioned chip locking methods based on programmable devices.
[0092] The embodiments of the present invention provide a chip locking method, device, equipment and storage medium based on a programmable device, which have the following beneficial effects compared with the prior art:
[0093] By storing the customer information key in the first non-volatile storage medium of the programmable device and the matching target software, and storing the customer key in the second non-volatile storage medium of the programmable device, the non-volatility of non-volatile storage is utilized to support only one-time writing, so as to prevent the cloning and tampering of the customer information key in the chip, and realize the hierarchical storage and double protection of the customer's key information, and improve the security of the system; because the customer information key is stored in the target software, the engineering file is double encrypted based on the customer key and the customer information key stored in the target software to obtain the encrypted engineering file, which effectively enhances the data protection measures, prevents unauthorized access and theft, and ensures the confidentiality and integrity of the engineering file. In the decryption process, the customer information key and the customer key need to be obtained from different non-volatile storage media of the programmable device. Only when they are consistent can the encrypted engineering file be double decrypted, so that only authorized customers can decrypt the engineering file, thereby achieving the effect of chip locking and specifying customers, avoiding illegal use and tampering, and improving the security of customer configuration files while ensuring the stability of the chip market. BRIEF DESCRIPTION OF THE DRAWINGS
[0094] Figure 1 It is a flow chart of an embodiment of a chip locking method based on a programmable device provided by the present invention;
[0095] Figure 2 It is a structural schematic diagram of an embodiment of a chip locking device based on a programmable device provided by the present invention;
[0096] Figure 3 It is a flow chart of another embodiment of a chip locking method based on a programmable device provided by the present invention;
[0097] Figure 4 It is a flow chart of another embodiment of a chip locking method based on a programmable device provided by the present invention;
[0098] Figure 5 A schematic structural diagram of a terminal device provided by the present invention. DETAILED DESCRIPTION
[0099] The following will be combined with the accompanying drawings in the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0100] Example 1, see Figure 1 , Figure 1FIG. 1 is a flow chart of an embodiment of a chip locking method based on a programmable device provided by the present invention. Figure 1 As shown, the method includes steps 101 to 104, which are specifically as follows:
[0101] Step 101: Set a customer information key for the customer, and store the customer information key in a first non-volatile storage medium of a programmable device and a matching target software.
[0102] In one embodiment, a unique identification code corresponding to a customer is obtained, and based on the unique identification code, a customer information key corresponding to the customer is set.
[0103] Specifically, the unique identification code is a customer ID; preferably, the unique identification code may also be other identifiable customer information.
[0104] Specifically, the customers are end customers who purchase chips through sales channels designated by the original manufacturer and its authorized dealers.
[0105] Specifically, the unique identification code is directly used as the customer information key corresponding to the customer; wherein the customer information key cannot be obtained by the customer.
[0106] Specifically, when a customer purchases chips through the sales channels designated by the original manufacturer and its authorized dealers, a unique customer ID is assigned to the customer, and based on the customer ID, a unique identification code corresponding to the customer is generated, and then a corresponding customer information key is set for the customer based on the unique identification code; this ensures that each customer has its own unique customer information key, and only customers who purchase through formal channels can obtain the corresponding customer information key. This can effectively prevent cross-selling and other illegal behaviors, while maintaining the legitimacy of product sales channels, which is conducive to maintaining market order.
[0107] In one embodiment, a programmable device and target software to be delivered to the customer are determined.
[0108] Specifically, since programmable devices usually need to be programmed according to the customer's specific application requirements to achieve specific logical functions or process specific data; therefore, after customers purchase programmable devices through 3 channels, they also need to customize the programmable devices based on the target software to meet their specific design requirements; therefore, during the customer delivery stage, programmable devices and supporting target software need to be delivered to users.
[0109] Specifically, the target software is EDA design software, that is, an electronic design automation tool for programmable devices.
[0110] Specifically, a programmable logic device is a chip that can be programmed by the user to implement specific functions, covering all devices that can be programmed by software, such as PLD, FPGA, CPLD, etc.
[0111] Specifically, a non-volatile storage medium is provided in the programmable logic device, wherein the non-volatile storage medium may be a common non-volatile storage such as eFuse, EEPROM, Flash Memory, etc.
[0112] In this embodiment, a first non-volatile storage medium and a second non-volatile storage medium are provided in the programmable logic device.
[0113] In one embodiment, based on a preset software data writing method, the customer information key is written into the target software, and based on a preset encryption algorithm, the customer information key in the target software is encrypted to obtain the encrypted customer information key, and based on a preset chip data writing method, the customer information key is written into the first non-volatile storage medium of the programmable device.
[0114] Specifically, the preset software data writing method includes but is not limited to an activation code writing method and a program code writing method.
[0115] The activation code writing method is to start the target software through the activation code, and write the customer information key into the target software during the activation process.
[0116] The program code writing method is to directly encode the customer information key in the program code of the target software, so that when the target software is compiled and built, the customer information key is directly written into the target software.
[0117] Preferably, the customer information key may also be written into the target software through other commonly used software genuine restriction methods.
[0118] Specifically, the preset chip data writing method is that during the test and debugging phase after chip production, the manufacturer uses special equipment or tools to write the customer information key into the first non-volatile storage medium of the programmable device, thereby realizing that the customer information key is written into the first non-volatile storage medium of the programmable device in advance before delivery.
[0119] Specifically, after the customer information key is written into the target software, the target software will automatically convert the customer information key into an encrypted customer information key based on a preset encryption algorithm to prevent it from being cracked and read by a third party, thereby enhancing the security of the overall software; even if the customer information key is maliciously obtained or leaked, the encrypted customer information key can provide additional protection to ensure that only authorized customers can decrypt and use this information.
[0120] Preferably, the preset encryption algorithm is an encryption algorithm commonly used in the prior art, such as the SHA256 encryption algorithm; the specific encryption algorithm selected to encrypt the customer information key depends on the software requirements of the chip design manufacturer.
[0121] Step 102: When it is detected that a project file is generated in the target software, a customer key input by the customer is obtained, and the customer information key is obtained from the target software, and the project file is double-encrypted based on the customer key and the customer information key to obtain an encrypted project file.
[0122] In one embodiment, when performing chip settings on a programmable device, it is usually necessary to generate a corresponding engineering file in the target software, wherein the engineering file contains chip configuration information, chip design parameters and data that needs to be burned into the programmable device in order to realize specific functions or logic.
[0123] In one embodiment, when a customer uses target software to design an engineering file for a programmable device, the customer will also input the customer key set by the customer into the target software and store the customer key in the target software; wherein the customer key is a key set by the customer himself for encrypting and decrypting engineering files.
[0124] In one embodiment, during the process of encrypting the generated project file, in addition to using the customer key set by the customer in the target software, the target software will also automatically obtain the customer information key written in advance into the target software, and perform double encryption on the project file based on the customer key and the customer information key.
[0125] In one embodiment, the project file is doubly encrypted based on the customer key and the customer information key to obtain an encrypted project file. The project file can be encrypted once based on the customer key to obtain a first encrypted project file; the customer key and the customer information key are concatenated to obtain a first concatenated key; and the first encrypted project file is encrypted twice based on the first concatenated key to obtain an encrypted project file.
[0126] In one embodiment, based on the customer key, the project file is encrypted once using the EDA software encryption algorithm to obtain a first encrypted project file, wherein the EDA software encryption algorithm can be a high-complexity algorithm, such as AES, or an encryption algorithm of different complexity.
[0127] When the EDA software encryption algorithm is the AES algorithm, the encryption project of the project file is specifically described: obtaining a first length of the customer key, performing file segmentation processing on the project file based on the first length to obtain multiple file data blocks, encrypting each file data block based on the AES algorithm to obtain an encrypted file data block, integrating the encrypted file data blocks to obtain a first encrypted project file.
[0128] In one embodiment, when the customer key and the customer information key are concatenated to obtain a first concatenated key, a first length of the customer key and a second length of the customer information key are obtained to determine whether the first length and the second length are the same. If so, a logical operation is performed on corresponding bits between the customer key and the customer information key based on a preset logical operation combination method to generate a first bit value corresponding to each corresponding bit, and the first bit values are integrated to obtain a first concatenated key. Otherwise, the customer key and the customer information key are directly concatenated to obtain a first concatenated key.
[0129] Specifically, the preset logic operation combination method includes but is not limited to an XOR operation, an AND operation, an OR operation, an NAND budget, and an NOR operation.
[0130] When the preset logical operation combination is an exclusive OR operation, bit alignment is performed on the customer key and the customer information key to determine whether the two bit values in each corresponding bit are the same. If so, the first bit value is output as 0; otherwise, the first bit value is output as 1. When the first bit value corresponding to each corresponding bit is obtained, all first bit values are integrated to obtain a first splicing key.
[0131] When the preset logical operation combination mode is an AND operation, bit alignment processing is performed on the customer key and the customer information key to determine whether the two bit values in each corresponding bit position are both 1. If so, the first bit value is output as 1; otherwise, the first bit value is output as 0. When the first bit value corresponding to each corresponding bit position is obtained, all first bit values are integrated to obtain a first splicing key.
[0132] When the preset logical operation combination mode is an OR operation, bit alignment processing is performed on the customer key and the customer information key to determine whether there is a bit value of 1 in the two bit values in each corresponding bit position. If so, the first bit value is output as 1; otherwise, the first bit value is output as 0. When the first bit value corresponding to each corresponding bit position is obtained, all first bit values are integrated to obtain a first splicing key.
[0133] When the preset logical operation combination is an AND-NOT operation, bit alignment is performed on the customer key and the customer information key to determine whether the two bit values in each corresponding bit are both 1. If so, the first bit value is output as 0; otherwise, the first bit value is output as 1. When the first bit value corresponding to each corresponding bit is obtained, all first bit values are integrated to obtain a first splicing key.
[0134] When the preset logical operation combination is an OR-NOT operation, bit alignment is performed on the customer key and the customer information key to determine whether the two bit values in each corresponding bit position are both 0. If so, the first bit value is output as 1; otherwise, the first bit value is output as 0. When the first bit value corresponding to each corresponding bit position is obtained, all first bit values are integrated to obtain a first splicing key.
[0135] Specifically, directly concatenating the customer key and the customer information key refers to merging them in the form of customer key + customer information key to obtain a first concatenated key; by way of example, if both the customer key and the customer information key are 128-bit keys, directly merging them means merging the two groups of 128-bit keys into a 256-bit key.
[0136] In one embodiment, based on the first splicing key, the first encrypted project file is re-encrypted using an EDA software encryption algorithm to obtain an encrypted project file, wherein the EDA software encryption algorithm can be a high-complexity algorithm, such as AES, or an encryption algorithm of different complexity.
[0137] Preferably, in the secondary encryption process, the selected EDA software encryption algorithm may be consistent with the encryption algorithm selected in the primary encryption process, or a different encryption algorithm may be selected.
[0138] As another preferred scheme in this implementation, the project file is doubly encrypted based on the customer key and the customer information key to obtain an encrypted project file. Alternatively, the project file can be encrypted once based on the customer key to obtain a first encrypted project file; and the first encrypted project file can be encrypted twice based on the customer information key to obtain an encrypted project file.
[0139] Specifically, the first encrypted project file is encrypted twice based on the customer information key to obtain the encrypted project file, and then the first encrypted project file is encrypted twice based on the customer information key using the EDA software encryption algorithm to obtain the encrypted project file, wherein the EDA software encryption algorithm can be a high-complexity algorithm, such as AES, or an encryption algorithm of different complexity.
[0140] As another preferred scheme in this implementation, the project file is doubly encrypted based on the customer key and the customer information key to obtain the encrypted project file. The customer key and the customer information key can also be spliced to obtain a first splicing key; the project file is doubly encrypted based on the first splicing key to obtain an encrypted project file.
[0141] As another preferred scheme in this implementation, the project file is doubly encrypted based on the customer key and the customer information key to obtain the encrypted project file. The customer key and the customer information key can also be spliced to obtain a first splicing key; the project file is doubly encrypted based on the first splicing key to obtain an encrypted project file.
[0142] Specifically, the method of concatenating the customer key and the customer information key is as described above and will not be described in detail here.
[0143] Specifically, the project file is double encrypted based on the first splicing key to obtain an encrypted project file, and then the encrypted project file is double encrypted based on the first splicing key using an EDA software encryption algorithm to obtain an encrypted project file, wherein the EDA software encryption algorithm can be a high-complexity algorithm, such as AES, or an encryption algorithm of different complexity.
[0144] As a preferred solution in this embodiment, when the project file is encrypted based on the customer information key and the customer key, the order of use of the two can be adjusted based on demand, that is, the software can be encrypted once with the customer key and then encrypted twice with the customer information key; or the software can be encrypted once with the customer information key and then encrypted twice with the customer key, and the decryption circuit on the corresponding chip needs to be adjusted accordingly.
[0145] Specifically, the project file is doubly encrypted based on the customer key and the customer information key to obtain an encrypted project file. The project file can also be encrypted once based on the customer information key to obtain a first encrypted project file; the first encrypted project file is encrypted twice based on the customer key to obtain an encrypted project file.
[0146] Specifically, the project file is doubly encrypted based on the customer key and the customer information key. When the encrypted project file is obtained, the customer key and the customer information key are concatenated to obtain a first concatenated key; the project file is encrypted once based on the first concatenated key to obtain a first encrypted project file; the first encrypted project file is encrypted twice based on the customer key to obtain an encrypted project file.
[0147] Step 103: Store the client key in a second non-volatile storage medium of the programmable device.
[0148] In one embodiment, before using the chip, the customer will write the customer key set by the customer into the second non-volatile storage medium of the programmable device in advance.
[0149] In one embodiment, the second non-volatile storage medium and the first non-volatile storage medium storing the client information key are different non-volatile storage media.
[0150] Step 104: When it is detected that the encrypted project file input exists in the programmable device, the customer information key is obtained from the first non-volatile storage medium, and the customer key is obtained from the second non-volatile storage medium, the encrypted project file is doubly decrypted based on the customer information key and the customer key to obtain a decrypted project file, and the programmable device is configured based on the decrypted project file.
[0151] In one embodiment, after the engineering file is double encrypted based on the target software, the encrypted engineering file is sent to the programmable device so that the programmable device can decrypt the encrypted engineering file and perform chip settings on the programmable device based on the decrypted engineering file obtained after decryption.
[0152] In one embodiment, the programmable device also includes a decryption circuit module, wherein the decryption circuit module includes a first decryption circuit module A and a second decryption circuit module B; the first decryption circuit module is used to obtain a customer information key from the first non-volatile storage medium; the second decryption circuit module is used to obtain a customer key from the second non-volatile storage medium.
[0153] Specifically, the customer information key on the programmable device has been written into the chip before leaving the factory; when the encrypted project file is loaded into the programmable device, the decryption circuit module will read the customer key and customer information key that have been written into the non-volatile storage medium in advance, and based on the two keys, perform corresponding algorithm decryption in the decryption circuit module to obtain a project file that the programmable device can recognize and program.
[0154] In one embodiment, in step 202, the project file is encrypted once based on the customer key to obtain a first encrypted project file; the customer key and the customer information key are concatenated to obtain a first concatenated key; the first encrypted project file is encrypted twice based on the first concatenated key to obtain an encrypted project file. Therefore, in this embodiment, the encrypted project file is doubly decrypted based on the customer information key and the customer key to obtain a decrypted project file, and the customer information key and the customer key are concatenated to obtain a second concatenated key; the encrypted project file is decrypted once based on the second concatenated key, and after the first decryption is successful, a first decrypted project file is obtained; the first decrypted project file is decrypted twice based on the customer key, and after the second decryption is successful, a decrypted project file is obtained.
[0155] As another preferred scheme in this embodiment, since in step 202, the customer key and the customer information key can also be spliced to obtain a first spliced key; the project file is encrypted once based on the first spliced key to obtain a first encrypted project file; the first encrypted project file is encrypted twice based on the customer key to obtain an encrypted project file, therefore, in this embodiment, the encrypted project file is doubly decrypted based on the customer information key and the customer key to obtain a decrypted project file, the encrypted project file is decrypted once based on the customer key, and after the first decryption is successful, the first decrypted project file is obtained; the customer information key and the customer key are spliced to obtain a second spliced key; the first decrypted project file is decrypted twice based on the second spliced key, and after the second decryption is successful, the decrypted project file is obtained.
[0156] Specifically, based on the second splicing key, the EDA software encryption algorithm is used to perform a decryption process on the encrypted project file. During the decryption process, the system will try to use the second splicing key to decrypt the encrypted project file. If the second splicing key does not match the first splicing key used for encryption or other problems occur, the decryption process will fail; that is, during a decryption process, it is determined whether the first splicing key and the second splicing key match. If they do not match, it is determined that the decryption has failed; otherwise, it is determined that the decryption is successful and the first decrypted project file is obtained.
[0157] Specifically, based on the customer key, the EDA software encryption algorithm is used to perform a secondary decryption process on the first decrypted project file. During the decryption process, the system will try to use the customer key stored in the programmable device to decrypt the encrypted project file. If the customer key stored in the programmable device does not match the customer key in the target software used during encryption or other problems occur, the decryption process will fail; that is, during the secondary decryption process, it is determined whether the customer key stored in the programmable device and the customer key in the target software match. If they do not match, it is determined that the secondary decryption has failed; otherwise, it is determined that the secondary decryption is successful and the decrypted project file is obtained.
[0158] As another preferred solution in this embodiment, since in step 202, the project file is double-encrypted based on the customer key and the customer information key to obtain the encrypted project file, the project file can also be encrypted by encrypting the project file once based on the customer key to obtain a first encrypted project file; and the first encrypted project file is encrypted twice based on the customer information key to obtain the encrypted project file. Therefore, in this embodiment, the encrypted project file is double-decrypted based on the customer information key and the customer key to obtain the decrypted project file. The encrypted project file is decrypted once based on the customer information key, and the first decrypted project file is obtained after the first decryption is successful; the first decrypted project file is decrypted twice based on the customer key, and the decrypted project file is obtained after the second decryption is successful. Figure 3 As shown, Figure 3 The flowchart of another embodiment of a chip locking method based on a programmable device is shown in FIG.
[0159] As another preferred scheme in this embodiment, since in step 202, the project file is double encrypted based on the customer key and the customer information key, when the encrypted project file is obtained, the project file can also be encrypted once based on the customer information key to obtain a first encrypted project file; the first encrypted project file is encrypted twice based on the customer key to obtain an encrypted project file. Therefore, in this embodiment, the encrypted project file is double decrypted based on the customer information key and the customer key to obtain a decrypted project file. The encrypted project file is decrypted once based on the customer key, and after the first decryption is successful, the first decrypted project file is obtained; the first decrypted project file is decrypted twice based on the customer information key, and after the second decryption is successful, the decrypted project file is obtained.
[0160] Specifically, based on the customer information key, the EDA software encryption algorithm is used to perform a decryption process on the encrypted project file. During the decryption process, the system will try to use the customer information key in the programmable device to decrypt the encrypted project file. If the customer information key in the programmable device does not match the customer information key in the target software used for encryption or other problems occur, the decryption process will fail; that is, during a decryption process, it is determined whether the customer information key in the programmable device and the customer information key in the target software match. If they do not match, it is determined that the decryption has failed; otherwise, it is determined that the decryption is successful and the first decrypted project file is obtained.
[0161] Specifically, based on the customer key, the EDA software encryption algorithm is used to perform a secondary decryption process on the first decrypted project file. During the decryption process, the system will try to use the customer key in the programmable device to decrypt the encrypted project file. If the customer key in the programmable device does not match the customer key in the target software used for encryption or other problems occur, the decryption process will fail; that is, during the secondary decryption process, it is determined whether the customer key in the programmable device matches the customer key in the target software. If they do not match, it is determined that the secondary decryption has failed; otherwise, it is determined that the secondary decryption is successful and the decrypted project file is obtained.
[0162] As another preferred solution in this embodiment, since the project file is double encrypted based on the customer key and the customer information key in step 202, when the encrypted project file is obtained, the customer key and the customer information key can also be spliced to obtain a first splicing key; the project file is double encrypted based on the first splicing key to obtain the encrypted project file; at this time, in this embodiment, the encrypted project file is double decrypted based on the customer information key and the customer key to obtain the decrypted project file, and the second splicing key is obtained by splicing the customer information key and the customer key; the encrypted project file is double decrypted based on the second splicing key, and after the double decryption is successful, the decrypted project file is obtained; Figure 4 As shown, Figure 4 The flowchart of another embodiment of the chip locking method based on programmable devices is shown in FIG.
[0163] Specifically, based on the second splicing key, the EDA software encryption algorithm is used to perform a decryption process on the encrypted project file. During the decryption process, the system will try to use the second splicing key to decrypt the encrypted project file. If the second splicing key does not match the first splicing key used for encryption or other problems occur, the decryption process will fail; that is, during a decryption process, it is determined whether the first splicing key and the second splicing key match. If they do not match, it is determined that the decryption has failed; otherwise, it is determined that the decryption is successful and the first decrypted project file is obtained.
[0164] In one embodiment, the EDA software encryption algorithm may be a highly complex algorithm, such as AES, or an encryption algorithm of varying complexity.
[0165] In summary, the chip locking method based on programmable devices provided in this embodiment utilizes the non-volatility of non-volatile storage in the chip to store the customer's customer information key information, which can effectively prevent the chip from being cloned or illegally tampered with; secondly, relying on the characteristics of software and hardware collaboration of programmable devices, by setting the customer's unique customer information key in the software and chip, only the two are consistent can the programming chip be decrypted, ensuring that only legitimate channel users can use the programming chip; while ensuring the stability of the chip market, the security of customer configuration files is improved.
[0166] Example 2, see Figure 2 , Figure 2 : is a schematic diagram of a structure of an embodiment of a chip locking device based on a programmable device provided by the present invention, such as Figure 2 As shown, the device includes a customer information key storage module 201, a project file double encryption module 202, a customer key storage module 203 and a project file double decryption module 204, which are as follows:
[0167] The customer information key storage module 201 is used to set a customer information key for a customer and store the customer information key in a first non-volatile storage medium of a programmable device and a matching target software.
[0168] The project file double encryption module 202 is used to obtain the customer key input by the customer when it is detected that the project file is generated in the target software, and obtain the customer information key from the target software, and double encrypt the project file based on the customer key and the customer information key to obtain an encrypted project file.
[0169] The client key storage module 203 is used to store the client key in a second non-volatile storage medium of the programmable device.
[0170] The engineering file double decryption module 204 is used to obtain the customer information key from the first non-volatile storage medium and the customer key from the second non-volatile storage medium when it is detected that the encrypted engineering file exists in the programmable device, double decrypt the encrypted engineering file based on the customer information key and the customer key to obtain a decrypted engineering file, and configure the programmable device based on the decrypted engineering file.
[0171] In one embodiment, the project file double encryption module 202 is used to perform double encryption processing on the project file based on the customer key and the customer information key to obtain an encrypted project file, specifically including: performing a primary encryption processing on the project file based on the customer key to obtain a first encrypted project file; performing a secondary encryption processing on the first encrypted project file based on the customer information key to obtain an encrypted project file.
[0172] In one embodiment, the project file double encryption module 202 is used to perform double encryption processing on the project file based on the customer key and the customer information key to obtain an encrypted project file, specifically including performing a primary encryption processing on the project file based on the customer information key to obtain a first encrypted project file; and performing a secondary encryption processing on the first encrypted project file based on the customer key to obtain an encrypted project file.
[0173] In one embodiment, the project file double encryption module 202 is used to perform double encryption processing on the project file based on the customer key and the customer information key to obtain an encrypted project file, specifically including: splicing the customer key and the customer information key to obtain a first splicing key; performing double encryption processing on the project file based on the first splicing key to obtain an encrypted project file.
[0174] In one embodiment, the project file double encryption module 202 is used to perform double encryption processing on the project file based on the customer key and the customer information key to obtain an encrypted project file, specifically including: performing a primary encryption processing on the project file based on the customer key to obtain a first encrypted project file; concatenating the customer key and the customer information key to obtain a first concatenated key; and performing a secondary encryption processing on the first encrypted project file based on the first concatenated key to obtain an encrypted project file.
[0175] In one embodiment, the project file double encryption module 202 is used to perform double encryption processing on the project file based on the customer key and the customer information key to obtain an encrypted project file, specifically including: splicing the customer key and the customer information key to obtain a first splicing key; encrypting the project file once based on the first splicing key to obtain a first encrypted project file; and performing secondary encryption processing on the first encrypted project file based on the customer key to obtain an encrypted project file.
[0176] In one embodiment, the engineering file dual encryption module 202 is used to concatenate the customer key and the customer information key to obtain a first concatenated key, specifically including: obtaining a first length of the customer key and a second length of the customer information key, determining whether the first length and the second length are the same, and if so, performing logical operations on corresponding bits between the customer key and the customer information key based on a preset logical operation combination method to generate a first bit value corresponding to each corresponding bit, integrating the first bit values to obtain a first concatenated key, otherwise, directly concatenating the customer key and the customer information key to obtain a first concatenated key.
[0177] In one embodiment, the project file double decryption module 204 is used to double decrypt the encrypted project file based on the customer information key and the customer key to obtain a decrypted project file, specifically including: decrypting the encrypted project file once based on the customer information key, and obtaining a first decrypted project file after the first decryption is successful; decrypting the first decrypted project file twice based on the customer key, and obtaining a decrypted project file after the second decryption is successful.
[0178] In one embodiment, the project file double decryption module 204 is used to double decrypt the encrypted project file based on the customer information key and the customer key to obtain a decrypted project file, specifically including: decrypting the encrypted project file once based on the customer key, and obtaining a first decrypted project file after the first decryption is successful; decrypting the first decrypted project file twice based on the customer information key, and obtaining a decrypted project file after the second decryption is successful.
[0179] In one embodiment, the project file double decryption module 204 is used to double decrypt the encrypted project file based on the customer information key and the customer key to obtain a decrypted project file, specifically including: splicing the customer information key and the customer key to obtain a second splicing key; double decrypting the encrypted project file based on the second splicing key, and obtaining a decrypted project file after the double decryption is successful.
[0180] In one embodiment, the project file double decryption module 204 is used to double decrypt the encrypted project file based on the customer information key and the customer key to obtain a decrypted project file, specifically including: splicing the customer information key and the customer key to obtain a second splicing key; decrypting the encrypted project file once based on the second splicing key, and obtaining a first decrypted project file after the first decryption is successful; decrypting the first decrypted project file twice based on the customer key, and obtaining a decrypted project file after the second decryption is successful.
[0181] In one embodiment, the project file double decryption module 204 is used to double decrypt the encrypted project file based on the customer information key and the customer key to obtain a decrypted project file, specifically including: decrypting the encrypted project file once based on the customer key, and obtaining a first decrypted project file after the first decryption is successful; splicing the customer information key and the customer key to obtain a second splicing key; decrypting the first decrypted project file twice based on the second splicing key, and obtaining a decrypted project file after the second decryption is successful.
[0182] In one embodiment, the customer information key storage module 201 is used to set a customer information key for a customer and store the customer information key in a first non-volatile storage medium of a programmable device and a matching target software, specifically including: obtaining a unique identification code corresponding to the customer, and setting a customer information key corresponding to the customer based on the unique identification code; determining a programmable device and target software to be delivered to the customer, and writing the customer information key into the target software based on a preset software data writing method; encrypting the customer information key in the target software based on a preset encryption algorithm to obtain the encrypted customer information key; and writing the customer information key into the first non-volatile storage medium of the programmable device based on a preset chip data writing method.
[0183] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the device described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0184] It should be noted that the above-mentioned embodiment of the chip-locked data transmission device based on programmable devices is merely illustrative, wherein the modules described as separate components may or may not be physically separated, and the components displayed as modules may or may not be physical units, that is, they may be located in one place, or may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0185] Figure 5 A schematic diagram of the structure of a terminal device. Figure 5 As shown, the terminal device 5 of this embodiment includes: at least one processor 501 ( Figure 5 Only one is shown in the figure) a processor, a memory 502, and a computer program 503 stored in the memory 502 and executable on at least one processor 501, and when the processor 501 executes the computer program 503, the steps in any of the above method embodiments are implemented.
[0186] The terminal device 5 may be a computing device such as a smart phone, a laptop, a tablet computer, and a desktop computer. The terminal device may include but is not limited to a processor 501 and a memory 502. Those skilled in the art will appreciate that Figure 5 It is only an example of the terminal device 5 and does not constitute a limitation on the terminal device 5. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, it may also include input and output devices, network access devices, etc.
[0187] The processor 501 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.
[0188] In some embodiments, the memory 502 may be an internal storage unit of the terminal device 5, such as a hard disk or memory of the terminal device 5. In other embodiments, the memory 502 may also be an external storage device of the terminal device 5, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. equipped on the terminal device 5. Further, the memory 502 may also include both an internal storage unit and an external storage device of the terminal device 5. The memory 502 is used to store an operating system, an application program, a boot loader (BootLoader), data, and other programs, such as program codes of a computer program. The memory 502 may also be used to temporarily store data that has been output or is to be output.
[0189] In addition, an embodiment of the present application further provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the steps in any of the above method embodiments are implemented.
[0190] An embodiment of the present application provides a computer program product. When the computer program product is run on a terminal device, the terminal device implements the steps in the above-mentioned method embodiments when executing the computer program product.
[0191] In several embodiments provided in the present application, it is understood that each box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and a module, a program segment or a part of a code includes one or more executable instructions for realizing a specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from that marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes also be executed in the opposite order, depending on the functions involved.
[0192] If the function is implemented in the form of a software function module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for a terminal device to execute all or part of the steps of each embodiment method of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program code.
[0193] In summary, the present invention provides a chip locking method, device, equipment and storage medium based on a programmable device, which stores a customer information key in a first non-volatile storage medium of a programmable device and a matching target software; when a project file is detected to be generated in the target software, the project file is double-encrypted based on a customer key input by a customer and a customer information key to obtain an encrypted project file; the customer key is stored in a second non-volatile storage medium of the programmable device; when an encrypted project file input is detected in the programmable device, the encrypted project file is double-decrypted based on the customer information key and the customer key to obtain a decrypted project file for configuring the programmable device; compared with the prior art, the technical solution of the present invention realizes effective chip locking through a customer information key and a customer key, thereby improving the security of customer configuration files while ensuring the stability of the chip market.
[0194] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and substitutions can be made without departing from the technical principles of the present invention. These improvements and substitutions should also be regarded as the scope of protection of the present invention.
Claims
1. A chip locking method based on a programmable device, characterized in that: include: Setting a customer information key for the customer, and storing the customer information key in a first non-volatile storage medium of the programmable device and the matching target software; When it is detected that a project file is generated in the target software, a customer key input by a customer is obtained, and the customer information key is obtained from the target software, and the project file is double-encrypted based on the customer key and the customer information key to obtain an encrypted project file; storing the client key in a second non-volatile storage medium of the programmable device; When the encrypted project file input is detected in the programmable device, the customer information key is obtained from the first non-volatile storage medium, and the customer key is obtained from the second non-volatile storage medium, the encrypted project file is doubly decrypted based on the customer information key and the customer key to obtain a decrypted project file, and the programmable device is configured based on the decrypted project file.
2. A chip locking method based on a programmable device as claimed in claim 1, characterized in that: The project file is double encrypted based on the customer key and the customer information key to obtain an encrypted project file, specifically including: Performing a primary encryption process on the project file based on the client key to obtain a first encrypted project file; Perform secondary encryption on the first encrypted project file based on the customer information key to obtain an encrypted project file; or, Performing a primary encryption process on the project file based on the customer information key to obtain a first encrypted project file; The first encrypted project file is encrypted again based on the client key to obtain an encrypted project file.
3. A chip locking method based on a programmable device as claimed in claim 1, characterized in that: The project file is double encrypted based on the customer key and the customer information key to obtain an encrypted project file, specifically including: Concatenate the client key and the client information key to obtain a first concatenated key; The project file is double encrypted based on the first splicing key to obtain an encrypted project file.
4. A chip locking method based on a programmable device as claimed in claim 1, characterized in that: The project file is double encrypted based on the customer key and the customer information key to obtain an encrypted project file, specifically including: Performing a primary encryption process on the project file based on the client key to obtain a first encrypted project file; Concatenate the client key and the client information key to obtain a first concatenated key; Perform secondary encryption processing on the first encrypted project file based on the first concatenated key to obtain an encrypted project file; or, Concatenate the client key and the client information key to obtain a first concatenated key; Performing a primary encryption process on the project file based on the first concatenation key to obtain a first encrypted project file; The first encrypted project file is encrypted again based on the client key to obtain an encrypted project file.
5. A chip locking method based on a programmable device as claimed in claim 4, characterized in that: The client key and the client information key are concatenated to obtain a first concatenated key, specifically comprising: Obtain a first length of the customer key and a second length of the customer information key, determine whether the first length and the second length are the same, and if so, perform logical operations on corresponding bits between the customer key and the customer information key based on a preset logical operation combination method to generate a first bit value corresponding to each corresponding bit, integrate the first bit values to obtain a first splicing key, otherwise, directly splice the customer key and the customer information key to obtain a first splicing key.
6. A chip locking method based on a programmable device as claimed in claim 2, characterized in that: The encrypted project file is double-decrypted based on the customer information key and the customer key to obtain a decrypted project file, specifically including: Decrypting the encrypted project file once based on the customer information key, and obtaining a first decrypted project file after the decryption succeeds once; Perform secondary decryption processing on the first decryption project file based on the client key, and obtain the decryption project file after the secondary decryption is successful; or, Decrypting the encrypted project file once based on the client key, and obtaining a first decrypted project file after the decryption succeeds once; The first decryption project file is decrypted twice based on the customer information key, and after the second decryption is successful, a decryption project file is obtained.
7. A chip locking method based on a programmable device as claimed in claim 3, characterized in that: The encrypted project file is double-decrypted based on the customer information key and the customer key to obtain a decrypted project file, specifically including: Concatenating the customer information key and the customer key to obtain a second concatenated key; The encrypted project file is double-decrypted based on the second splicing key, and after the double decryption is successful, a decrypted project file is obtained.
8. A chip locking method based on a programmable device as claimed in claim 4, characterized in that: The encrypted project file is double-decrypted based on the customer information key and the customer key to obtain a decrypted project file, specifically including: Concatenating the customer information key and the customer key to obtain a second concatenated key; Decrypting the encrypted project file once based on the second concatenated key, and obtaining a first decrypted project file after the decryption succeeds once; Performing secondary decryption processing on the first decryption project file based on the client key, and obtaining a decryption project file after the secondary decryption is successful; or Decrypting the encrypted project file once based on the client key, and obtaining a first decrypted project file after the decryption succeeds once; Concatenating the customer information key and the customer key to obtain a second concatenated key; The first decrypted engineering file is decrypted twice based on the second splicing key, and after the second decryption is successful, a decrypted engineering file is obtained.
9. A chip locking method based on a programmable device as claimed in claim 1, characterized in that: Setting a customer information key for the customer and storing the customer information key in a first non-volatile storage medium of the programmable device and the matching target software specifically includes: Obtaining a unique identification code corresponding to the customer, and setting a customer information key corresponding to the customer based on the unique identification code; Determine the programmable device and target software delivered to the customer, and write the customer information key into the target software based on a preset software data writing method; Encrypting the customer information key in the target software based on a preset encryption algorithm to obtain the encrypted customer information key; Based on a preset chip data writing method, the customer information key is written into a first non-volatile storage medium of the programmable device.
10. A chip locking device based on a programmable device, characterized in that: include: Customer information key storage module, engineering file double encryption module, customer key storage module and engineering file double decryption module; Wherein, the customer information key storage module is used to set a customer information key for the customer and store the customer information key in the first non-volatile storage medium of the programmable device and the matching target software; The project file double encryption module is used to obtain the customer key input by the customer when detecting that the project file is generated in the target software, and obtain the customer information key from the target software, and perform double encryption processing on the project file based on the customer key and the customer information key to obtain an encrypted project file; The client key storage module is used to store the client key in a second non-volatile storage medium of the programmable device; The engineering file double decryption module is used to obtain the customer information key from the first non-volatile storage medium and the customer key from the second non-volatile storage medium when it is detected that the encrypted engineering file exists in the programmable device, double decrypt the encrypted engineering file based on the customer information key and the customer key to obtain a decrypted engineering file, and configure the programmable device based on the decrypted engineering file.
11. A terminal device, characterized in that: The invention comprises a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein when the processor executes the computer program, the chip locking method based on a programmable device according to any one of claims 1 to 9 is implemented.
12. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored computer program, wherein when the computer program is executed, the device where the computer-readable storage medium is located is controlled to execute the chip locking method based on a programmable device according to any one of claims 1 to 9.
