Controller starting method and device, equipment, storage medium and vehicle

By extracting and verifying enabled code data in the controller's boot read-only memory and one-time programmable memory, the issue of enabling instruction legality verification before the controller is solved, and security verification is implemented for the controller's enabled to prevent malware loading and attacks.

CN119720167APending Publication Date: 2025-03-28BEIJING CO WHEELS TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311267834.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-09-27
Publication Date
2025-03-28

AI Technical Summary

Technical Problem

Before enabling the controller, the controller needs to verify the legality of the enabled instructions to prevent attackers from controlling the controller through the forged enable instructions, causing the normal operation of the controller to be compromised.

Method used

By extracting the first enable code data from the boot read-only memory of the controller, and extracting the key data from the one-time programmable memory based on the enable information of the boot read-only memory, the first enable code data is verified, and if the verification is passed, the controller is enabled.

Benefits of technology

Ensure that only authorized enable code can be verified, so that the verified code instructions can be loaded and executed, effectively preventing unauthorized software loading and malicious attacks, and improving the security and reliability of the system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119720167A_ABST
    Figure CN119720167A_ABST
Patent Text Reader

Abstract

The invention provides a controller starting method and device, equipment, a storage medium and a vehicle, and relates to the field of automatic control. The method comprises the following steps: in response to power-on information, extracting first enabling code data in a boot read-only memory of a controller; extracting key data from the one-time programmable memory according to the enabling information of the boot read-only memory; verifying the first enabling code data according to the key data; and if the verification is passed, starting the controller according to a first starting code corresponding to the first starting code data. By adopting the technical scheme of the embodiment, in order to ensure the starting security of the controller, security verification is performed on the first starting code data for controlling the starting of the controller before the controller is started, so that only the authorized first starting code can pass the verification, and the starting security of the controller is ensured. The code instruction of the first enabling code passing the verification can be loaded and executed, so that the code instruction can be effectively verified, and the safe use of the controller is ensured.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of automatic control, and in particular to a controller activation method, device, equipment, storage medium and vehicle. Background Art

[0002] Before enabling the controller used in various scenarios, it is necessary to input an enabling instruction to the controller's control chip and verify the integrity of the controller as a whole. After the controller is successfully verified, the controller can be enabled normally. In order to prevent attackers from maliciously controlling the controller, the enabling instruction of the controller needs to be verified to determine the legitimacy of the enabling instruction. Due to information leakage of the enabling instruction, attackers may use forged enabling instructions to control the controller's control chip, threatening the normal operation of the controller. Summary of the invention

[0003] In view of this, the present application provides a controller activation method, device, equipment, storage medium and vehicle, the main purpose of which is to prevent the controller from being controlled by activation instructions forged by an attacker, thereby causing the device controlled by the controller to be maliciously activated by the attacker.

[0004] To achieve the above object, the present application discloses, in a first aspect, a method for enabling a controller, the method comprising:

[0005] extracting first enabling code data in a boot read-only memory of the controller in response to power-on information;

[0006] extracting key data from a one-time programmable memory according to the enabling information of the boot read-only memory;

[0007] verifying the first enabling code data according to the key data;

[0008] If the verification is successful, the controller is enabled according to the first enabling code corresponding to the first enabling code data.

[0009] In a second aspect of the present application, an embodiment provides an enabling device for a controller, the device comprising:

[0010] an extraction module, configured to extract first enabling code data from a boot read-only memory of the controller in response to power-on information; and extract key data from a one-time programmable memory according to enabling information of the boot read-only memory;

[0011] a verification module, configured to verify the first enabling code data according to the key data;

[0012] The enabling module is configured to enable the controller according to a first enabling code corresponding to the first enabling code data if the verification is passed.

[0013] In a third aspect of the present application, an electronic device is provided, including:

[0014] At least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute any one of the methods disclosed in the first aspect.

[0015] In a fourth aspect of the present application, an embodiment provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method described in the first aspect is implemented.

[0016] In a fifth aspect embodiment of the present application, a vehicle is provided, in which an enabling device of the controller as described in the second aspect or an electronic device as described in the third aspect is mounted.

[0017] In summary, according to the technical solution disclosed in the present application, in order to prevent the controller from being controlled by the enablement instruction forged by the attacker, so that the device controlled by the controller is maliciously enabled by the attacker. The present application discloses a controller enabling method, device, equipment, storage medium and vehicle, which extracts the first enabling code data from the boot read-only memory of the controller in response to the power-on information; extracts the key data from the one-time programmable memory according to the enabling information of the boot read-only memory; verifies the first enabling code data according to the key data; if the verification passes, enables the controller according to the first enabling code corresponding to the first enabling code data. Using the technical solution of this embodiment, in order to ensure the enabling security of the controller, it is proposed to perform security verification on the first enabling code data of the controller enabling before enabling the controller, so as to ensure that only the authorized first enabling code can pass the verification, so that the code instructions of the verified first enabling code can be loaded and executed, so that the code instructions can be effectively verified. At the same time, in order to ensure the reliability of the first enabling code acquisition process, the credibility of the boot read-only memory entity and the unique editability of the one-time programmable memory are utilized to verify the first enabling code data stored in the boot read-only memory and the key data stored in the one-time programmable memory. Only after the verification is passed is the first enabling code used to enable the controller to ensure the safe use of the controller.

[0018] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0020] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0021] Figure 1 A flow chart of a controller activation method provided by an embodiment of the present application is shown;

[0022] Figure 2 A schematic diagram of generating activation code data provided by an embodiment of the present application is shown;

[0023] Figure 3 A structural diagram of an enabling device of a controller provided in an embodiment of the present application is shown. DETAILED DESCRIPTION

[0024] In order to more clearly understand the above-mentioned purposes, features and advantages of the present application, the scheme of the present application will be further described below. It should be noted that the embodiments of the present application and the features in the embodiments can be combined with each other without conflict.

[0025] In order to prevent the controller from being controlled by an activation instruction forged by an attacker, thereby causing the device controlled by the controller to be maliciously activated by the attacker, the present application provides the following embodiments to solve the above problem:

[0026] This embodiment provides a method for enabling a controller, such as Figure 1 FIG. 1 is a flowchart of the method of this embodiment, and the method of this embodiment may specifically include the following steps:

[0027] Step 101: In response to power-on information, extract first enabling code data from a boot read-only memory of a controller.

[0028] After obtaining external power support, the first enabling code data is extracted from the boot read-only memory BootROM of the controller. The first enabling code data is stored in the BootROM, which is a trusted hardware entity with an unchangeable nature and physical security and protection measures to protect the confidentiality and integrity of the first enabling code data.

[0029] Step 102: extract key data from the one-time programmable memory according to the enabling information of the boot read-only memory.

[0030] After the boot read-only memory BootROM is enabled, the one-time programmable memory OTP is further enabled according to its enabling information. OTP is a non-volatile memory that can only be programmed once. It can store key security data and configuration information to support the verification and protection mechanism during the security enabling process. OTP reserves fuse bits for security configuration on the device production line, which are used to store key data hashes related to security enabling, security enabling control bits, and version numbers to prevent version rollback. Key data is the basis for signature verification, key derivation, and secure communication, and it needs to have a high degree of confidentiality and integrity. Since OTP is a one-time programmable memory, the public key hash in the key data cannot be modified after writing, thereby protecting the root key from unauthorized tampering. At the same time, more key data related to security enabling can be reserved in OTP, supporting the revocation and update of key data with multiple levels of different algorithms and key lengths to ensure system security and flexibility.

[0031] Step 103: verify the first enabling code data according to the key data.

[0032] Using the first enabling code data extracted from the BootROM and the key data extracted from the OTP, verification of the first enabling code data is performed to confirm that the first enabling code data and the key data correspond to each other. This step can confirm whether data such as the source and content of the first enabling code data is legal, and subsequent work can be performed based on the verification results.

[0033] Step 104: If the verification is successful, enable the controller according to the first enabling code corresponding to the first enabling code data.

[0034] If the verification is successful, the first enabling code data is determined to be legal, and the controller can be enabled normally according to the first enabling code corresponding to the first enabling code data. The technical solution of this embodiment is adopted to ensure the enabling security of the controller, and it is proposed to perform security verification on the first enabling code data of the controller before enabling the controller, so as to ensure that only the authorized first enabling code can pass the verification, and compare the data in the fixed BootROM and OTP, so that the code instructions of the first enabling code that pass the verification can be loaded and executed, so that the code instructions can be effectively verified, and the safe use of the controller is ensured.

[0035] In the content of this embodiment, by implementing effective verification of the controller code instructions, unauthorized software loading can be prevented, and only verified and authorized software can be loaded and executed. This helps prevent malicious software or unauthorized code from entering the controller, thereby improving the security and reliability of the system. And the controller is protected from attack, and the risk of malicious attacks can be reduced by verifying the secure boot scheme. It can prevent attackers from exploiting vulnerabilities or tampering with software to control the vehicle system or destroy its normal function. At the same time, the confidentiality and integrity of the controller data are ensured, and sensitive data in the controller, such as vehicle diagnostic information, user privacy data, etc., are protected. Through digital signature verification and integrity checking, it can be ensured that the data is not tampered with or leaked during transmission and storage. Before implementing the verification process, the controller's enabling method can also be equipped with a preloading and caching mechanism to load and verify a portion of key data and code in advance during the startup process to speed up the startup speed. This can reduce the delay in startup time while ensuring security.

[0036] In a possible embodiment, in order to ensure accurate comparison between the first enabling code data in the boot read-only memory and the key data in the one-time programmable memory, this embodiment further proposes that before extracting the key data from the one-time programmable memory according to the enabling information of the boot read-only memory, the method includes:

[0037] The first enabling code is signed by using a signature server to generate first enabling code data; and the first enabling code data is stored in a boot read-only memory.

[0038] In the content of this embodiment, a pre-storage content is proposed to accurately compare the first enabling code data and the key data, that is, the signature server of a third-party server is used to realize the generation and storage of the key data of the first enabling code data, and a trusted environment is provided for the comparison of the first enabling code data and the key data. At the same time, the content of this embodiment proposes that the key data corresponds to the first enabling code data, and is a signed first enabling code, that is, the code is authorized or allowed to be used, therefore, through the verification between the first enabling code data and the key data, unauthorized, malicious or tampered code data can be found, thereby further ensuring the security of the controller activation.

[0039] In a possible embodiment, using a signing server to sign the first enabling code to generate first enabling code data includes:

[0040] Use the signing server to create a signing key and send the signing key to the hardware security module;

[0041] Control the hardware security module to encrypt the signature key and generate a private key;

[0042] In response to the signing instruction of the signing server, control the hardware security module to generate key data using the private key, and return the key data to the signing server;

[0043] The first enabling code is signed by the signing server using the key data to generate first enabling code data.

[0044] In the present embodiment, specific steps are proposed for signing the first enabling code and generating the first enabling code data, that is, the generation of the first enabling code data is the result of the joint action of the signature server and the hardware security module (Hardware Security Module) HSM. The hardware security module HSM stores a private key generated by the signature key input by the signature server. The private key is generated and stored within the security boundary of the hardware security module and cannot be accessed by other devices. At the same time, in one example, the private key is generated by a random number generator. After the signature instruction of the signature server sends a signature instruction to the hardware security module, the hardware security module uses the private key to sign and generate key data. The specific key data generation process is as follows. Figure 2 The signature server then signs the first enabling code using the key data to generate first enabling code data.

[0045] In the content of this embodiment, HSM is a specially designed hardware device for generating, storing and managing keys to provide advanced key security and operation protection. HSM communicates with the signature server separately through a secure communication channel to prevent other software or hardware devices from reading its content. It can be a physical interface or an encrypted network connection with the signature server. In this way, the private key protected by HSM is not eavesdropped or tampered by attackers. At the same time, HSM supports backup and disaster recovery mechanisms for private keys. Backup copies can be stored in secure offline media and measures are taken to protect them from damage, loss or theft. In the event of a catastrophic event, backup copies can be used to restore private keys and system operations. At the same time, HSM records and monitors all operations on private keys. This includes the generation, storage and use of private keys. Through the operation audit and monitoring functions, any abnormal operations or security events can be detected and responded to, protecting private keys from unauthorized use.

[0046] In the process of controller security enablement, the root of trust is a key concept, which provides the basis for establishing a trusted environment during the secure boot process. The root of trust is a trusted entity or component whose security is trusted and is used to verify and ensure the credibility of the boot code and firmware. In this solution, the hardened BootROM, together with the HSM and OTP modules with higher security levels, constitute an efficient, secure and reliable secure boot root of trust. OTP is responsible for storing secure key data, such as the secure boot primary root key hash, secure boot enable flag, secure debug enable flag, etc.; HSM is responsible for accelerating the cryptographic-related calculation process during the secure boot process. In addition, it is an important security practice to regularly update the key data generation method to prevent the leakage and abuse of the same key data used for a long time. By regularly generating new key data generation strategies and updating them to the system using appropriate mechanisms, the security of the system can be maintained and the risk of key data being cracked or abused can be reduced.

[0047] In order to achieve confidentiality when the HSM communicates with the signature server separately through a secure communication channel, in one possible embodiment, in response to a signature instruction from the signature server, controlling the hardware security module to generate key data using a private key and returning the key data to the signature server includes:

[0048] In response to the signing instruction of the signing server, the hardware security module is controlled to generate key data using the private key, and the encrypted key data is returned to the signing server.

[0049] An encryption step is further introduced in the hardware security module to further encrypt the key data, where the encryption method can be mask technology, randomization or low-power algorithm, which is used to select resistance to side channel attacks and reduce the possibility of attackers obtaining sensitive information through side channel attacks. At the same time, at the physical level, shielding technology is used to reduce electromagnetic leakage, low-power design is used to reduce the effect of power side channel attacks, and randomization technology is used to cover up related physical characteristics.

[0050] In a possible embodiment, verifying the first enabling code data according to the key data includes:

[0051] The first enabling code data is verified using a hash function based on the key data.

[0052] Hash functions are widely used in cryptography, they can convert input data into a fixed-length hash value. Using strong hash functions, such as SHA-3 (Secure Hash Algorithm 3), the integrity of the data can be verified. In secure boot scenarios, hash functions can be used to verify the integrity of the first enabled code data to prevent tampering and malicious code injection.

[0053] In a possible embodiment, if the verification is successful, enabling the controller according to the first enabling code corresponding to the first enabling code data includes:

[0054] If the verification is successful, extract the subordinate enabling code data corresponding to the first enabling code data in the subordinate enabling code module according to the first enabling code; extract the subordinate key data corresponding to the subordinate enabling code data from the one-time programmable memory according to the enabling information for guiding the subordinate enabling code module; verify the subordinate enabling code data according to the subordinate key data; loop through the above steps until all enabling code data are verified and all enabling code data are chained subordinate enabling code data; enable the controller according to the first enabling code corresponding to the first enabling code data and all enabling codes corresponding to all enabling code data.

[0055] In order to achieve the safe activation of the controller, this embodiment further proposes the relevant content of chain verification activation. Chain verification startup can be divided into multiple stages and multiple system startups. The focus is on combining the cryptographic signature mechanism, secure transmission and expanding the scope of trust. The safe startup is divided into the following stages:

[0056] Startup phase 1: When the system is powered on, it starts executing from the BootROM that constitutes the root of trust. The secure boot refers to the secure boot information in the OTP to verify the signature and integrity of the primary root key and the first-level boot code SPL. If the verification passes, the root of trust will pass control to the first-level boot code SPL and start the first-level execution environment.

[0057] Boot phase 2: The first-level boot code SPL will verify the signature and integrity of the second-level boot code U-Boot. If the verification passes, the first-level boot code will pass control to the second-level boot code and start the second-level execution environment.

[0058] Boot phase 3: The second-level boot code U-Boot will verify the signature and integrity of the operating system. If the verification passes, the second-level boot code will pass control to the operating system code and start the operating system kernel image;

[0059] Chain verification continues: The above process can continue until all levels of boot code are verified and control is passed. Each level of boot code is responsible for verifying the signature and integrity of the next level of boot code, ensuring the continuous credibility of the entire boot process.

[0060] Through chain boot, the chip establishes a layer-by-layer verification of the secure boot process. Each level of boot code verifies the credibility of the next level of code, ensuring that only verified code is loaded and executed. This chain boot design prevents unauthorized code execution and firmware tampering, improving the security and reliability of the system.

[0061] In the existing controller activation scheme, there may be safety hazards. For example, when the controller is an automotive electronic control unit (ECU), the startup process may have the following safety hazards during design and implementation:

[0062] 1. Secure boot root of trust. There is a risk that unauthorized configurations may be loaded or illegally modified in secure boot configurations. Secure boot root of trust requires OEMs to combine their own protection solutions and solidify the primary root key in the controller or vehicle assembly line according to the signature algorithm. If the primary root key is not solidified, the ECU cannot perform effective security verification, resulting in malware or unauthorized software being loaded and executed.

[0063] 2. Secure boot is at risk of being physically attacked. A side-channel attack is an attack that exploits the physical implementation characteristics or side information of a system to obtain sensitive data. A side-channel attack can deduce key information by observing the physical side information such as power consumption, electromagnetic radiation, and clock frequency of the chip during secure boot. This may lead to key leakage, allowing attackers to bypass security verification or decrypt encrypted data. Attackers can also observe the execution time and power consumption pattern of the chip during secure boot to infer information about sensitive operations or keys. This may lead to attackers understanding the internal mechanisms and algorithms of the system and discovering possible vulnerabilities.

[0064] 3. Secure boot lacks security monitoring and reporting mechanisms. If there is a lack of monitoring for the use of security signature services, there may be a risk of impersonating the release of authorized software. The same lack of such a mechanism may cause potential vulnerabilities to exist for a long time without being discovered, providing attackers with opportunities to exploit. If this mechanism is lacking, the ability to respond to security incidents or vulnerabilities in the chip will be limited. This may lead to delayed responses and the inability to quickly control or fix security issues, giving attackers more time to conduct potential malicious activities. Over time, new threats and attack techniques continue to emerge, and the lack of monitoring and reporting mechanisms will limit the ability to detect and respond to these new threats. This will continue to expose the chip to risks, which may lead to long-term data leaks, system paralysis, or other security issues.

[0065] In response to the above-mentioned potential safety hazards, the contents of the embodiments of the present application can solve the above-mentioned safety issues.

[0066] In response to question 1, in the enabling method of this embodiment, a root of trust is established. The root of trust is the trust basis for mutual verification during the entire startup process. The content of this embodiment uses a solidified BootROM, plus a higher security level HSM and OTP module to form an efficient, safe and reliable secure boot root of trust. OTP is responsible for storing secure key data, such as the secure boot first-level root key hash, secure boot enable flag, secure debug enable flag, etc.; HSM is responsible for accelerating cryptographic-related calculation processes during the secure boot process. ECU can perform effective security verification to prevent malware or unauthorized software from being loaded and executed.

[0067] In response to question 2, in the enabling method of this embodiment, at the beginning of the design of the integrated chip of the enabling device of the controller, physical protection measures are taken to reduce the risk of side channel attacks. Shielding technology is used to reduce electromagnetic leakage, low-power design is adopted to reduce the effect of power consumption side channel attacks, and randomization technology is used to cover up related physical features. Selecting an encryption algorithm that resists side channel attacks is the first line of defense. Algorithms that resist side channel attacks use masking technology, randomization, or low-power algorithms to reduce the information leaked by the side channel. Such algorithms can reduce the possibility of attackers obtaining sensitive information through side channel attacks. In addition, randomization and masking techniques are introduced to increase the difficulty of side channel attacks. Randomization can make it difficult for attackers to repeat side channel analysis, and masking technology can confuse the information leaked by the side channel, making it impossible to accurately infer sensitive data.

[0068] In response to question 2, in the activation method of this embodiment, in order to effectively monitor the server that performs the signature function, the one-time programmable memory OTP that stores the signature configuration information is provided with a function that supports the revocation and update of security root keys with multiple levels of different algorithms and key lengths, so that the security strength of the secure boot function can be improved when needed in the future. For example, if a certain signature algorithm is at risk of being hacked in the future, it can be possible to flexibly increase the algorithm security by using another signature algorithm or a longer key. On this basis, regularly updating the signature key is an important security practice to prevent the leakage and abuse of long-term keys. By regularly generating new signature keys and updating them to the OTP using a suitable mechanism, the security of the OTP can be maintained and the risk of the key being cracked or abused can be reduced.

[0069] This embodiment provides an enabling device of a controller, such as Figure 3 As shown, it is a structural diagram of the device of this embodiment, including:

[0070] The extraction module 31 is used to extract the first enabling code data in the boot read-only memory of the controller in response to the power-on information; and extract the key data from the one-time programmable memory according to the enabling information of the boot read-only memory;

[0071] a verification module 32, configured to verify the first enabling code data according to the key data;

[0072] The enabling module 33 is configured to enable the controller according to a first enabling code corresponding to the first enabling code data if the verification is successful.

[0073] In a possible embodiment, the extraction module 31 is specifically configured to:

[0074] Signing the first enabling code using a signature server to generate the first enabling code data;

[0075] The first enabling code data is stored in the boot read-only memory.

[0076] In a possible embodiment, the extraction module 31 is specifically configured to:

[0077] Creating a signing key using a signing server, and sending the signing key to a hardware security module;

[0078] Controlling the hardware security module to encrypt the signature key to generate a private key;

[0079] In response to a signing instruction from a signing server, controlling the hardware security module to generate key data using the private key, and returning the key data to the signing server;

[0080] The first enabling code is signed by the signing server using key data to generate first enabling code data.

[0081] In a possible embodiment, the extraction module 31 is specifically configured to:

[0082] In response to a signing instruction from the signing server, the hardware security module is controlled to generate key data using the private key, and the encrypted key data is returned to the signing server.

[0083] In a possible embodiment, the verification module 32 is used to:

[0084] The first enabling code data is verified using a hash function based on the key data.

[0085] In a possible embodiment, the enabling module 33 is specifically configured to:

[0086] If the verification is successful, extracting subordinate enabling code data corresponding to the first enabling code data in a subordinate enabling code module according to the first enabling code;

[0087] extracting subordinate key data corresponding to the subordinate enabling code data from a one-time programmable memory according to the enabling information of the booting subordinate enabling code module;

[0088] verifying the subordinate enabling code data based on the subordinate key data;

[0089] Execute the above steps in a loop until all the activation code data are verified, and all the activation code data are chained lower-level activation code data;

[0090] The controller is enabled according to a first enabling code corresponding to the first enabling code data and all enabling codes corresponding to the all enabling code data.

[0091] Based on this understanding, the technical solution of the present application can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, USB flash drive, mobile hard disk, etc.), including a number of instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to execute the methods of various implementation scenarios of the present application.

[0092] Based on the above Figure 1 The method shown, and Figure 3 In order to achieve the above-mentioned purpose, the embodiment of the present application further provides an electronic device that can be configured on the vehicle (such as a new energy vehicle) side, and the device includes at least one processor and a memory that is communicatively connected to the at least one processor; the memory is used to store instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor, and the processor is used to execute a computer program to implement the above-mentioned Figure 1 The method shown.

[0093] Optionally, the above-mentioned physical device may also include a user interface, a network interface, a camera, a radio frequency (RF) circuit, a sensor, an audio circuit, a WI-FI module, etc. The user interface may include a display, an input unit such as a keyboard, etc., and the optional user interface may also include a USB interface, a card reader interface, etc. The network interface may optionally include a standard wired interface, a wireless interface (such as a WI-FI interface), etc.

[0094] Those skilled in the art will appreciate that the above-mentioned physical device structure provided in this embodiment does not constitute a limitation on the physical device, and may include more or fewer components, or a combination of certain components, or different arrangements of components.

[0095] Based on the above Figure 1 The method shown, the embodiment of the present application also provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the method corresponding to any embodiment is implemented. The storage medium may also include an operating system and a network communication module. The operating system is a program that manages the hardware and software resources of the above-mentioned entity device, and supports the operation of information processing programs and other software and / or programs. The network communication module is used to realize communication between the components inside the storage medium, and communication with other hardware and software in the information processing entity device.

[0096] Based on the above electronic device, the embodiment of the present application further provides a vehicle, which may specifically include: Figure 3 The device shown in the figure or the electronic device as described above. The vehicle can be a new energy vehicle or a traditional vehicle.

[0097] Through the description of the above implementation, the technicians in this field can clearly understand that the present application can be implemented by means of software plus the necessary general hardware platform, or by hardware. By applying the scheme of this embodiment, compared with the current existing technology, this embodiment extracts the first enabling code data in the boot read-only memory of the controller in response to the power-on information; extracts the key data from the one-time programmable memory according to the enabling information of the boot read-only memory; verifies the first enabling code data according to the key data; if the verification is passed, the controller is enabled according to the first enabling code corresponding to the first enabling code data. Using the technical scheme of this embodiment, in order to ensure the enabling security of the controller, it is proposed to perform security verification on the first enabling code data enabled by the controller before enabling the controller, so as to ensure that only the authorized first enabling code can pass the verification, so that the code instructions of the first enabling code that passes the verification can be loaded and executed, so that the code instructions can be effectively verified. At the same time, in order to ensure the reliability of the first enabling code acquisition process, the credibility of the boot read-only memory entity and the unique editing of the one-time programmable memory are used to mutually verify the first enabling code data stored in the boot read-only memory and the key data stored in the one-time programmable memory, and the first enabling code is used to enable the controller only after the verification is passed, so as to ensure the safe use of the controller.

[0098] It should be noted that, in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the term "comprises" or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.

[0099] The above is only a specific implementation of the present application, so that those skilled in the art can understand or implement the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments described herein, but will conform to the widest scope consistent with the principles and novel features applied for herein.

Claims

1. A method for enabling a controller, characterized in that: include: extracting first enabling code data in a boot read-only memory of the controller in response to power-on information; extracting key data from a one-time programmable memory according to the enabling information of the boot read-only memory; verifying the first enabling code data according to the key data; If the verification is successful, the controller is enabled according to the first enabling code corresponding to the first enabling code data.

2. The method according to claim 1, characterized in that Before extracting key data from a one-time programmable memory according to the enabling information of the boot read-only memory, the method includes: Signing the first enabling code using a signature server to generate the first enabling code data; The first enabling code data is stored in the boot read-only memory.

3. The method according to claim 2, characterized in that The step of using a signature server to sign the first enabling code to generate the first enabling code data includes: Creating a signing key using a signing server, and sending the signing key to a hardware security module; Controlling the hardware security module to encrypt the signature key to generate a private key; In response to a signing instruction from a signing server, controlling the hardware security module to generate key data using the private key, and returning the key data to the signing server; The first enabling code is signed by the signing server using key data to generate first enabling code data.

4. The method according to claim 3, characterized in that: The step of responding to the signature instruction of the signature server, controlling the hardware security module to generate key data using the private key, and returning the key data to the signature server comprises: In response to a signing instruction from the signing server, the hardware security module is controlled to generate key data using the private key, and the encrypted key data is returned to the signing server.

5. The method according to claim 1, characterized in that The verifying the first enabling code data according to the key data comprises: The first enabling code data is verified using a hash function based on the key data.

6. The method according to claim 1, characterized in that If the verification is successful, enabling the controller according to the first enabling code corresponding to the first enabling code data includes: If the verification is successful, extracting subordinate enabling code data corresponding to the first enabling code data in a subordinate enabling code module according to the first enabling code; extracting subordinate key data corresponding to the subordinate enabling code data from a one-time programmable memory according to the enabling information of the booting subordinate enabling code module; verifying the subordinate enabling code data based on the subordinate key data; The above steps are executed cyclically until all activation code data are verified, wherein all activation code data are chained lower-level activation code data; The controller is enabled according to a first enabling code corresponding to the first enabling code data and all enabling codes corresponding to the all enabling code data.

7. A controller activation device, characterized in that: include: an extraction module, configured to extract first enabling code data in a boot read-only memory of the controller in response to power-on information; extracting key data from a one-time programmable memory according to the enabling information of the boot read-only memory; a verification module, configured to verify the first enabling code data according to the key data; The enabling module is configured to enable the controller according to a first enabling code corresponding to the first enabling code data if the verification is passed.

8. An electronic device, characterized in that: include: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 6.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.

10. A vehicle, characterized in that: The vehicle is equipped with the device according to claim 7 or the electronic device according to claim 8.