Vehicle Network Security and Key management Method
By distributing encryption key fragments among ECUs using a vehicle internal blockchain and backup storage, the method addresses the single point of failure in HSMs, enhancing vehicle network security and maintaining responsiveness.
Patent Information
- Application Number
- KR1020250060006
- Authority / Receiving Office
- KR · KR
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2025-05-08
- Publication Date
- 2026-11-17
AI Technical Summary
Existing vehicle network security systems face vulnerabilities due to a single point of failure in Hardware Security Module (HSM) key storage, making key recovery difficult, and reliance on external networks can compromise real-time responsiveness and security.
Distribute and store encryption key fragments generated by the HSM across multiple ECUs using a vehicle internal blockchain, employing Shamir's secret sharing method, with backup storage in a private blockchain or cloud Key Management System (KMS) for redundancy and security.
Solves the single point of failure issue and enables secure key verification without external network connectivity, ensuring robust vehicle network security and real-time responsiveness.
Smart Images

Figure PAT00005_ABST
Abstract
Description
Technology Field
[0001] The present invention relates to vehicle network security, and more specifically, to a method for managing keys of a hardware security module (HSM) that reduces dependency on an external network for vehicle network security. Background Technology
[0003] The automotive industry has recently been rapidly digitizing alongside advancements in connected car and autonomous vehicle technologies. While the internet connectivity of vehicles has improved driver convenience, it has simultaneously increased security threats. Multiple electronic control units (ECUs) exist within vehicles and exchange data via networks such as the Controller Area Network (CAN). However, existing vehicle networks were developed without sufficient consideration for security, posing a significant risk of hacking.
[0004] In particular, with the activation of V2X (Vehicle-to-Everything) communication, the frequency with which vehicles exchange data with surrounding infrastructure and other vehicles is increasing. If a hacker transmits fake data during this process, the vehicle may make incorrect decisions, which could lead to serious traffic accidents. Furthermore, while technology for wirelessly updating vehicle software via OTA (Over-the-Air) updates has become commonplace, the risk of the entire vehicle being hacked increases if the update files are tampered with or forged.
[0005] To address these security issues, a Hardware Security Module (HSM) is embedded in automotive network System on Chip (SoC) to enhance security. The HSM performs functions such as cryptographic key generation, storage, and authentication, and is responsible for the security of internal and external vehicle communications.
[0006] However, existing HSM-based security methods have limitations. Storing keys solely within the HSM can lead to a single point of failure problem, making key recovery difficult in the event of an HSM failure. Additionally, storing keys in the HSM's internal storage can make it vulnerable to physical attacks.
[0007] Meanwhile, if the existing blockchain method is to be used to solve the aforementioned problems, key authentication may become difficult if the vehicle is not connected to an external network. Additionally, if a public blockchain is utilized, there is a possibility that real-time responsiveness may be degraded due to issues with the consensus algorithm and transaction processing speed. The problem to be solved
[0009] The present invention provides a method to solve the single point of failure problem in a security system using a vehicle HSM by distributing and storing keys generated by the HSM in a vehicle internal blockchain formed in a network connecting multiple ECUs, thereby enabling key verification even when the vehicle is not connected to an external network.
[0010] The technical problems intended to be solved in this document are not limited to those mentioned above, and other technical problems not mentioned will be clearly understood by those skilled in the art to which this disclosure belongs from the description below. means of solving the problem
[0012] According to various embodiments, an electronic control unit equipped in a vehicle comprises a storage unit, a processor, and a hardware security module (HSM) having a key storage unit capable of securely storing data, wherein the HSM generates an encryption key and generates a plurality of key fragments capable of recovering the generated encryption key, stores some of the plurality of key fragments in the storage unit or the key storage unit, and distributes and stores the remaining key fragments among the plurality of key fragments in a plurality of other electronic control units connected to a vehicle network.
[0013] According to one embodiment, the HSM can block-code the encryption key so that the encryption key can be recovered even if only some key fragment data is collected, and can divide the block-coded encryption key into a plurality of key fragments to generate the plurality of key fragments.
[0014] According to one embodiment, the HSM can generate the plurality of key fragments based on the generated encryption key according to Shamir's secret sharing method.
[0015] According to one embodiment, the HSM can store the remaining pieces in a private blockchain formed by a plurality of electronic control units connected to a vehicle network.
[0016] According to one embodiment, the HSM may store a portion of the remaining piece by distributing it among some of the multiple electronic control units connected to the vehicle network, and store the remaining piece excluding the portion of the remaining piece in a private blockchain formed by some of the multiple electronic control units connected to the vehicle network.
[0017] According to one embodiment, if the HSM is connected to an external network, it may store key fragments stored in the private blockchain in a cloud KMS (Key Management System) or a public blockchain.
[0018] According to one embodiment, the HSM can collect some of the plurality of key fragments stored in the storage unit or the key storage unit, collect the remaining fragments of the plurality of key fragments distributed and stored in a plurality of other electronic control units connected to the vehicle network, and recover the encryption key based on the collected plurality of key fragments.
[0019] According to one embodiment, the HSM can collect the remaining pieces from a private blockchain formed by a plurality of electronic control units connected to a vehicle network.
[0020] According to one embodiment, the HSM can collect a portion of the remaining piece stored in a distributed manner among some electronic control units connected to a vehicle network, and collect the remaining piece excluding the portion of the remaining piece stored in a private blockchain formed by some electronic control units among the plurality of electronic control units connected to the vehicle network.
[0021] According to one embodiment, when the HSM is connected to an external network, it can collect key fragments stored in the private blockchain in cooperation with a cloud KMS (Key Management System) or a public blockchain.
[0022] According to one embodiment, when the encryption key is divided into a plurality of key fragments after block coding, the HSM can recover the encryption key by block decoding based on the collected plurality of key fragments.
[0023] According to one embodiment, if the key fragments are generated according to Shamir's secret sharing method, the HSM can recover the encryption key according to Shamir's secret sharing method based on the collected key fragments.
[0024] According to various other embodiments, an electronic control unit equipped in a vehicle may, in a method for operating an encryption key for vehicle network security, include the operation of generating an encryption key, the operation of generating a plurality of key fragments capable of recovering the generated encryption key, the operation of storing some of the plurality of key fragments in a storage unit or secure storage of the electronic control unit, and the operation of distributing and storing the remaining key fragments among the plurality of key fragments in a plurality of other electronic control units connected to the vehicle network.
[0025] According to one embodiment, the operation of generating the encryption key can block-code the encryption key so that the encryption key can be recovered even if only some key fragment data is collected.
[0026] According to one embodiment, the operation of generating a plurality of key fragments that enable the recovery of the generated encryption key can generate the plurality of key fragments according to Shamir's secret sharing method based on the generated encryption key.
[0027] According to one embodiment, the operation of distributing and storing the remaining key fragments among the plurality of key fragments in a plurality of other electronic control units connected to a vehicle network may include the operation of storing the remaining fragments in a private blockchain formed by the plurality of electronic control units connected to the vehicle network.
[0028] According to one embodiment, the operation of distributing and storing the remaining key fragments among the plurality of key fragments in a plurality of other electronic control units connected to a vehicle network may include the operation of distributing and storing one fragment of the remaining fragments in each of the electronic control units among the plurality of electronic control units connected to the vehicle network, and the operation of storing the remaining fragments, excluding the said fragments, in a private blockchain formed by some of the electronic control units among the plurality of electronic control units connected to the vehicle network.
[0029] According to one embodiment, the encryption key manipulation method may further include the operation of storing a key fragment stored in the private blockchain in a cloud KMS (Key Management System) or a public blockchain when connected to an external network.
[0030] According to one embodiment, the encryption key manipulation method may further include the operation of collecting some of the plurality of key fragments stored in the storage unit or key storage unit, the operation of collecting the remaining fragments among the plurality of key fragments distributed and stored in a plurality of other electronic control units connected to the vehicle network, and the operation of recovering the encryption key based on the collected plurality of key fragments.
[0031] According to one embodiment, the operation of collecting the remaining pieces among the plurality of key pieces distributed and stored in a plurality of other electronic control units connected to the vehicle network may include the operation of collecting the remaining pieces from a private blockchain formed by a plurality of electronic control units connected to the vehicle network.
[0032] According to one embodiment, the operation of collecting the remaining pieces among the plurality of key pieces distributed and stored in a plurality of other electronic control units connected to the vehicle network may include the operation of collecting a portion of the remaining pieces distributed and stored in some of the electronic control units connected to the vehicle network, and the operation of collecting the remaining pieces excluding the portion of the remaining pieces stored in a private blockchain formed by some of the electronic control units connected to the vehicle network.
[0033] According to one embodiment, the encryption key manipulation method may further include, when connected to an external network, an operation to collect key fragments stored in the private blockchain in cooperation with a cloud KMS (Key Management System) or a public blockchain.
[0034] According to one embodiment, the operation of recovering the encryption key based on the collected plurality of key fragments may include, when the encryption key is divided into a plurality of key fragments after block coding, the operation of recovering the encryption key by block decoding based on the collected plurality of key fragments.
[0035] According to one embodiment, the operation of recovering the encryption key based on the plurality of collected key fragments may include, if the key fragments are generated according to Shamir's secret sharing method, the operation of recovering the encryption key according to Shamir's secret sharing method based on the collected key fragments. Effects of the invention
[0037] The vehicle network security and key management method of the present invention can solve the single point of failure problem with a security system using a vehicle HSM and provide a method for verifying keys even when the vehicle is not connected to an external network through a private blockchain.
[0038] The effects obtainable from the present disclosure are not limited to those mentioned above, and other unmentioned effects will be clearly understood by those skilled in the art to which the present disclosure pertains from the description below. Brief explanation of the drawing
[0040] FIG. 1 is a diagram illustrating the configuration of an HSM according to one embodiment. FIG. 2 is a diagram briefly illustrating the configuration of an ECU according to one embodiment. Figure 3 is a diagram illustrating multiple ECUs within a vehicle connected by an internal network. Figure 4 is a diagram illustrating the system of Figure 3 connected to an external network and connected to an external cloud KMS or public blockchain. FIG. 5 is a flowchart illustrating a key management method in a vehicle according to various embodiments of the present invention. FIG. 6 is a flowchart illustrating a key generation operation according to various embodiments of the present invention. FIG. 7 is a flowchart illustrating a key recovery operation according to various embodiments of the present invention. Specific details for implementing the invention
[0041] The advantages and features of the present disclosure and the methods for achieving them will become clear by referring to the embodiments described below in detail together with the accompanying drawings. However, the present disclosure is not limited to the embodiments disclosed below but may be implemented in various different forms. These embodiments are provided merely to ensure that the disclosure of the present disclosure is complete and to fully inform those skilled in the art of the scope of the disclosure, and the present disclosure is defined only by the scope of the claims. Throughout the specification, like reference numerals refer to like components.
[0042] When one component is referred to as being "connected to" or "coupled to" another component, it includes cases where it is directly connected or coupled to the other component, or cases where another component is interposed. Conversely, when one component is referred to as being "directly connected to" or "directly coupled to" another component, it indicates that no other component is interposed. "And / or" includes each of the mentioned items and all combinations of one or more of them.
[0043] The terms used herein are for describing embodiments and are not intended to limit the disclosure. In this specification, the singular form includes the plural form unless specifically stated otherwise in the text. As used herein, "comprises" and / or "comprising" do not exclude the presence or addition of one or more other components, steps, actions, and / or elements to the mentioned components, steps, actions, and / or elements.
[0044] Although terms such as "first," "second," etc., are used to describe various components, it goes without saying that these components are not limited by these terms. These terms are used merely to distinguish one component from another.
[0045] Therefore, it is obvious that the first component mentioned below may be the second component within the technical scope of this disclosure. Unless otherwise defined, all terms used in this specification (including technical and scientific terms) may be used in a meaning that is commonly understood by those skilled in the art to which this disclosure pertains. Furthermore, terms defined in commonly used dictionaries are not to be interpreted ideally or excessively unless explicitly and specifically defined otherwise.
[0046] The terms 'part' or 'module' as used in this embodiment refer to software or hardware components such as FPGAs or ASICs, and the 'part' or 'module' performs certain roles. However, the meaning of 'part' or 'module' is not limited to software or hardware. The 'part' or 'module' may be configured to reside in an addressable storage medium or configured to run one or more processors. Thus, as an example, the 'part' or 'module' may include components such as software components, object-oriented software components, class components, and task components, as well as processes, functions, attributes, procedures, subroutines, segments of program code, drivers, firmware, microcode, circuits, data, databases, data structures, tables, arrays, and variables. The components and functions provided within the 'part' or 'module' may be combined into a smaller number of components and 'part' or 'module', or further separated into additional components and 'part' or 'module'.
[0047] Steps of a method or algorithm described in connection with some embodiments of the present disclosure may be directly implemented in hardware, software modules, or a combination of both, executed by a processor. Software modules may reside in RAM memory, flash memory, ROM memory, EPROM memory, EEPROM memory, registers, hard disks, removable disks, CD-ROMs, or any other form of recording medium known in the art. An exemplary recording medium is coupled to a processor, and the processor can read information from the recording medium and write information to the storage medium. Alternatively, the recording medium may be integral with the processor. The processor and the recording medium may reside within an Application-Specific Integrated Circuit (ASIC). The ASIC may reside within a user terminal.
[0048] Hereinafter, embodiments of the present invention are described in detail with reference to the attached drawings so that those skilled in the art can easily implement the present invention. However, the present invention may be embodied in various different forms and is not limited to the embodiments described herein.
[0049] Blockchain is a technology that stores data in blocks within a distributed network and links them to prevent tampering. A block contains a certain amount of data and the hash value of the previous block, and these can form a chain as they are continuously connected. The most significant characteristics of a blockchain are transparency, reliability, and immutability; because information recorded once is extremely difficult to alter, the integrity and reliability of the data can be guaranteed.
[0050] Blockchain can be broadly divided into public blockchain and private blockchain.
[0051] A public blockchain is a fully open blockchain where anyone can join the network to participate in block creation and verification. While public blockchains maximize decentralization and can operate without a trusted authority, they may have disadvantages such as slow processing speeds and high energy consumption because all participants are involved in block verification. Additionally, their use may be limited in industries where real-time performance is critical.
[0052] In contrast, a private blockchain can be a closed network where a specific organization or governing body controls access rights. Since both participants and block creators are limited to predefined entities, transaction speeds are fast, and data processing and management are easy. It is a form primarily used by corporations or government agencies to enhance the security and transparency of internal systems. However, it is not completely decentralized, and because it relies on certain trusted entities, its transparency may be lower compared to public blockchains.
[0053] Such blockchain technology can be useful in security-critical fields, such as vehicle network security and digital certificate management. Currently, vehicle networks operate based on protocols such as CAN (controller area network), Ethernet, and C-V2X (cellular vehicle to everything); however, existing network security systems often lack significant security considerations during the design phase, making them vulnerable to hacking and data tampering. During the process of vehicles exchanging data via wireless communication, hackers can attempt man-in-the-middle attacks, reply attacks, and identity spoofing. This can disrupt normal vehicle operation or even pose a threat of remote vehicle hijacking, allowing the vehicle to be controlled without the driver's intent. Therefore, to address security issues in vehicles that have evolved into intelligent network devices, such as connected cars and autonomous vehicles, utilizing the decentralization and reliability of blockchain can prevent the tampering of sensitive information and ensure the automation and transparency of the authentication process.
[0054] A Hardware Security Module (HSM) is an essential component for vehicle network security, capable of performing functions such as the generation, storage, and management of encryption keys, as well as hash operations. In particular, since automotive HSMs require real-time processing, a lightweight design and fast response speed are critical. Furthermore, they can be utilized to build robust vehicle security systems by combining with technologies such as blockchain, V2X, and OTA (over-the-air) security updates.
[0055] FIG. 1 is a diagram illustrating the configuration of an HSM according to one embodiment.
[0056] Referring to FIG. 1, the HSM (13) may include a crypto CPU (1), a true random number generator (TRNG) (2), a secure key storage (3), a hash engine (4), and a crypto accelerator (5).
[0057] The cryptographic processor (1) may be a dedicated processor that performs cryptographic operations (key generation, encryption / decryption, digital signature, hashing, etc.). The cryptographic processor (1) operates separately from the general CPU, and its internal architecture may be designed to be closed to enhance security. Additionally, it supports specific security instructions to process fast and secure cryptographic operations.
[0058] The random number generator (2) is a module that generates completely random numbers and can be used in the key generation and encryption process. According to one embodiment, the random number generator (20) can generate unpredictable random numbers by utilizing physical noise (voltage fluctuations, semiconductor thermal noise, etc.). The random number generator (2) is essential for enhancing security and can minimize the risk of key leakage.
[0059] The secure key storage unit (3) is a non-volatile memory, so the stored data is continuously preserved even when the power is turned off, and the generated encryption key can be safely stored. The secure key storage unit (3) is located in an area inaccessible from the outside, so key leakage and hacking can be prevented. In addition, the stored key can be further encrypted using a key wrapping technique for key protection.
[0060] Key wrapping is a technique used in security systems to encrypt cryptographic keys with another key for secure storage or transmission; it can mean protecting a key by wrapping it with yet another key.
[0061] The hash operation unit (4) is an operation module that supports a hash algorithm and can be used to verify data integrity and generate a digital signature. In addition, when combined with blockchain technology, it can play an essential role in ensuring the integrity of block data.
[0062] The hash operation unit (4) can convert an input data value into a unique encrypted value of a fixed length using a hash algorithm. Representative hash algorithms include SHA-256, SHA-384, SHA-512, etc.
[0063] A blockchain is fundamentally a structure in which multiple blocks are linked together like a chain. Each block can contain data values. For example, blocks are linked to one another via hash values, including the hash value of the previous block, the transaction data of the current block, and the hash value of the current block; thus, the structure can be such that if even one block is tampered with, the integrity of the entire chain is compromised.
[0064] The hash operation unit (4) can perform operations necessary for hash calculation of the blockchain, digital signature verification, integrity verification, and blockchain creation. According to one embodiment, the integrity of security logs within a vehicle can be secured. When the vehicle's ECU or gateway intends to record an event, the cryptographic processor (1) can prevent tampering with the log by hashing each log and storing it in a blockchain manner. At this time, the hash operation unit (4) can calculate a hash value in real time and provide it to the cryptographic processor (1). In addition, the hash operation unit (4) can calculate a hash value in real time and provide it to the cryptographic processor (1) even during post-verification, and the cryptographic processor (10) can guarantee the integrity of the log by checking for tampering based on the provided hash value.
[0065] According to one embodiment, the integrity of software code obtained through an OTA (Over-the-Air) update can also be verified. The hash value of the update file is registered in the blockchain in advance, the hash operation unit (4) inside the HSM calculates the hash value of the downloaded file, and the cryptographic processor (1) compares the value stored in the blockchain with the value calculated by the hash operation unit (4) to determine whether the update has been tampered with and to verify the integrity of the update.
[0066] According to one embodiment, security can be enhanced even during V2X (Vehicle-to-Everything) communication between vehicles. A communication message is recorded on a blockchain after hash processing, and a hash operation unit (4) calculates and provides the hash value of the communication message in real time, and a cryptographic processor (1) can quickly check whether the communication message has been tampered with or forged based on the provided hash value. By guaranteeing the reliability and immutability of the communication history, the blockchain can ensure vehicle authentication and the consistency of the communication history.
[0067] The encryption accelerator (5) may be separately provided to reduce the burden on the encryption processor (1) and increase the speed of security operations by rapidly performing encryption algorithm operations that encrypt data based on the generated encryption key, but it may not be an essential component.
[0068] FIG. 2 is a diagram briefly illustrating the configuration of an ECU according to one embodiment.
[0069] The ECU (101) is an electronic device that controls specific functions within a vehicle. Multiple ECUs (101) are provided in the vehicle to operate independently for each function, such as engine control, battery control, brake system, and driver assistance system, or can be used by being connected to other ECUs via a network.
[0070] Referring to FIG. 2, the ECU (101) may be equipped with a processor (11), a storage unit (12), and an HSM (13).
[0071] The processor (11) is a central processing unit within the ECU (101) that collects various data through the vehicle's sensors, communication modules, user input, etc., and can execute necessary control commands by interpreting this data. The processor (11) can control other systems within the vehicle by reading software code and configuration information stored in the storage unit (12), executing a program, and generating output signals according to operation logic. Additionally, the processor (11) can cooperate with the HSM (13) to perform integrity verification, encryption, and decryption of communication data with other ECUs or the outside, and can also perform the role of maintaining system security by verifying consistency during the booting of the ECU.
[0072] The storage unit (12) can serve as a data storage device to store software code, setting values, logs, and security-related data required for the operation of the ECU (101). Generally, non-volatile memory can be used so that data is retained even when the power is turned off.
[0073] The storage unit (12) can store software (firmware) that the processor (11) needs to execute and parameters required for operation, and can also store event data or diagnostic information that occurs during driving.
[0074] According to one embodiment, when the processor (11) obtains new software code through an OTA update, it can store the obtained software code in a storage unit (12). Subsequently, when the ECU (101) reboots, the processor (11) can load the new software code stored in the storage unit (12) and operate according to the new software code.
[0075] The HSM (13) may be an independent hardware module dedicated to security functions within the ECU (101). The HSM (13) can securely store encryption keys, encrypt and decrypt data using the encryption keys during data communication, and perform integrity and authentication of communication messages. It can also play an important role in verifying whether the software has been tampered with during the booting of the ECU (101) or verifying the digital signature of the software code obtained through an OTA update. The HSM (13) provides a foundation of trust to ensure that the ECU (101) operates safely without being exposed to external threats, and can quickly and securely process key management, signature generation and verification, and encryption / decryption operations.
[0076] Figure 3 is a diagram illustrating multiple ECUs within a vehicle connected by an internal network.
[0077] Referring to FIG. 3, a vehicle (1000) may include a plurality of ECUs (101, 102, ..., 10n), and the plurality of ECUs (101, 102, ..., 10n) may be connected to each other via an internal vehicle communication network (200), such as a CAN (controller area network) or a LIN (local interconnection network). The plurality of ECUs (101, 102, ..., 10n) may exchange data and authentication information through the internal vehicle communication network (200). The plurality of ECUs (101, 102, ..., 10n) may use an HSM (13, 23, ..., n3) to ensure data integrity and authentication even during communication between ECUs, thereby significantly improving vehicle security performance.
[0078] Figure 4 is a diagram illustrating the system of Figure 3 connected to an external network and connected to an external cloud KMS or public blockchain.
[0079] Referring to FIG. 4, a vehicle (1000) including a plurality of ECUs (101, 102, ..., 10n) of FIG. 3 can be connected to a cloud key management system (KMS) (300) or a public blockchain (400) through an external network.
[0080] According to one embodiment, the vehicle (1000) and the cloud KMS (300) or public blockchain (400) can be connected to an external network such as a cellular network (5G, 6G), Wi-Fi, or C-V2X (cellular-vehicle to everything).
[0081] FIG. 5 is a flowchart illustrating a key management method in a vehicle according to various embodiments of the present invention.
[0082] Referring to FIG. 5, the vehicle network security and key management method (S100) of the present invention may include a key generation operation (S200) and a key recovery operation (S300). The key generation operation (S200) may mean that an HSM generates an encryption key, divides the generated key to create a plurality of key fragments, and stores them in a distributed manner across a plurality of ECUs. The key recovery operation (S300) may mean that the encryption key is recovered by collecting the fragment keys distributed across a plurality of ECUs.
[0083] The vehicle network security and key management method (S100) can distribute and store encryption keys across multiple ECUs to eliminate single points of failure and enhance security. Additionally, the vehicle network security and key management method (S100) is designed to enable private blockchain-based storage in a network between ECUs within the vehicle, allowing it to operate even when the vehicle is not connected to an external network.
[0084] FIG. 6 is a flowchart illustrating a key generation operation according to various embodiments of the present invention.
[0085] The operations illustrated in FIG. 6 can be performed by one of the multiple ECUs connected to the vehicle network or by an HSM within the ECU. In this case, each ECU can independently generate and use the encryption key required by itself.
[0086] According to another embodiment, the operations illustrated in FIG. 6 may be performed by a specific ECU designated to perform encryption key generation among a plurality of ECUs connected to a network within the vehicle. In this case, the specific ECU may generate the necessary encryption keys for each of the ECUs equipped in the vehicle and provide them to each ECU.
[0087] Referring to FIG. 6, the key generation operation (S200) may include an encryption key generation operation (S210), an operation of dividing the generated encryption key into a plurality of pieces (S220), an operation of storing some of the plurality of pieces in internal memory (S230), and an operation of storing the remaining pieces of the plurality of pieces in a plurality of ECUs connected to a vehicle network (S240). According to one embodiment, the operation of storing the remaining pieces of the plurality of pieces in a plurality of ECUs connected to a vehicle network (S240) may store the remaining pieces of the plurality of pieces in a plurality of ECUs connected to a vehicle network according to a private blockchain technique.
[0088] In operation S210, the ECU can generate an encryption key. According to one embodiment, a true random number generator (TRNG) (2) of an internal HSM (13, 23, ..., n3) of the ECU can generate a key to be used for encryption of communication messages. The encryption key can be used as a root key or a session key and can be utilized as basic encryption information for secure communication within the vehicle.
[0089] A root key is a key used to generate or encrypt other cryptographic keys, and it can serve as the root of an underlying security system. For example, an HSM (13, 23, ..., n3) can encrypt a session key using the root key when generating it. Alternatively, the master key of a blockchain wallet can also be considered a type of root key. Because root keys are highly sensitive from a security standpoint, their exposure can endanger the entire system. A session key refers to a temporary key that is valid only for a specific period of time or during a session.
[0090] In operation S220, the ECU can generate multiple key fragments that enable the recovery of the generated encryption key.
[0091] According to one embodiment, the ECU can generate multiple key fragments capable of recovering an encryption key generated using Shamir's secret sharing technique. To use Shamir's secret sharing technique, the ECU can set the number of key fragments to be generated (n) and the number of key fragments required to recover the encryption key (k) as parameters. In this case, the relationship 1 ≤ k ≤ n must always be satisfied.
[0092] Shamir's secret sharing method features a structure that generates multiple secret fragments capable of recovering a single piece of secret data (e.g., an encryption key) and distributes them to different users. Each fragment is designed so that the original secret data cannot be inferred from it on its own, and the original secret data can be restored only when at least a predetermined threshold of k fragments is collected.
[0093] The parameters n and k used in Shamir's secret sharing method can be designed in various ways by the designer depending on the purpose. For example, in the case of (k=1, n=5), it is a design that does not heavily consider security; although security is weak because the secret can be recovered even if only one of the five fragments is present, the single point of failure problem can be resolved if the five fragments are stored in different locations. In the case of (k=3, n=5), it can be a balanced structure that considers both security and recoverability. It is a structure where recovery is possible if three or more of the five fragments are obtained. In the case of (k=5, n=5), it is a design that emphasizes extreme security, where recovery is impossible if even a single fragment is missing.
[0094] According to one embodiment, in operation S220, the ECU can generate n key fragments that enable the generated encryption key to be recovered according to Shamir's secret sharing method.
[0095] According to another embodiment, the ECU can block-code the generated encryption key to enable error detection and recovery. For example, the ECU can generate a code capable of error detection and recovery, such as a Hamming code or a cyclic redundancy code (CRC), through block-coding and add it to the encryption key to generate a coded encryption key. Then, the coded encryption key can be divided into multiple key fragments to generate key fragments that enable the encryption key to be recovered. By using the aforementioned code, the encryption key can be recovered even if only some of the multiple key fragments are collected.
[0096] Multiple key fragments generated to resolve the single point of failure problem can be distributed and stored in multiple ECUs present in the vehicle.
[0097] In operation S230, the ECU that generated the encryption key may store some of the generated key fragments in internal memory. Here, the internal memory may be a storage unit (12), but according to another embodiment, it may be a secure key storage unit (3) inside the HSM (13). When the key fragments are stored in the secure key storage unit (3) inside the HSM (13), direct exposure of the key fragments to external attacks can be prevented.
[0098] In operation S240, the ECU can store the remaining key piece among the multiple key pieces in another ECU connected to the network within the vehicle.
[0099] According to one embodiment, a private blockchain may be formed with some ECUs within a vehicle, and the remaining key fragments may be stored in the private blockchain based on a blockchain technique. In this case, a specific ECU (hereinafter referred to as BECU) that manages the private blockchain may be provided. The ECU that generated the encryption key may transmit the remaining key fragments to the BECU, and the BECU may generate a block containing the remaining key fragments and allow the block to be stored in the ECU participating in the private blockchain.
[0100] According to another embodiment, some of the remaining key fragments among the plurality of key fragments may be stored one fragment at a time in some of the other network-connected ECUs within the vehicle (hereinafter referred to as OECU). In this case, the ECUs to store the key fragments may be determined according to a pre-set algorithm, and each ECU may use the same algorithm or different algorithms. Additionally, among the plurality of key fragments, the remaining key fragments, excluding the ECU that generated the encryption key and the key fragments stored in the OECU, may be stored in a private blockchain formed by some of the ECUs within the vehicle based on a blockchain technique. According to one embodiment, the key fragments stored in the private blockchain are not used during encryption key recovery, but may be used to verify whether the recovered encryption key has been tampered with.
[0101] For example, an encryption key can be recovered using the remaining key fragments excluding the key fragment stored in the private blockchain, and multiple key fragments can be generated in the same manner based on the recovered encryption key. Then, by comparing the key fragment stored in the private blockchain with the corresponding key fragment among the multiple key fragments generated based on the recovered encryption key, it can be determined that there is no tampering if they are identical, and if they are not identical, it can be determined that the recovered encryption key has been tampered with.
[0102] According to one embodiment, when connecting to an external network, key fragments stored in a private blockchain can be uploaded to a cloud KMS or a public blockchain. As illustrated in FIG. 4, when a vehicle is connected to an external network such as a cellular network, some key fragments can be synchronized to a cloud KMS or recorded on a public blockchain and stored in the external network.
[0103] FIG. 7 is a flowchart illustrating a key recovery operation according to various embodiments of the present invention.
[0104] The operations illustrated in FIG. 7 can be performed by one of the multiple ECUs connected to the vehicle network or by an HSM within the ECU. In this case, each ECU can independently recover and use the encryption key required by itself.
[0105] According to another embodiment, the operations illustrated in FIG. 7 may be performed by a specific ECU designated to perform encryption key generation among a plurality of ECUs connected to a network within the vehicle. In this case, the specific ECU may recover the necessary encryption keys from each of the ECUs equipped in the vehicle and provide them to each ECU.
[0106] Referring to FIG. 7, the key recovery operation (S300) may include an operation (S310) of collecting key fragments stored in internal memory, an operation (S320) of collecting the remaining key fragments among a plurality of key fragments that enable the recovery of the encryption key, and an operation (S330) of recovering the encryption key based on the collected key fragments.
[0107] In operation S310, the ECU that intends to recover the encryption key may collect the key fragment stored in internal memory. Here, the internal memory may be a storage unit (120), but according to another embodiment, it may be a secure key storage unit (3) inside the HSM (13).
[0108] In operation S320, the ECU that intends to recover the encryption key can collect the remaining key fragments among the multiple key fragments from another ECU according to the method of storing the remaining key fragments among the multiple key fragments.
[0109] According to one embodiment, if all remaining key fragments among a plurality of key fragments have been stored in a private blockchain, the remaining key fragments may be requested from the private blockchain manager. For example, an ECU that wishes to recover an encryption key may provide the transaction ID and / or password used when storing the remaining key fragments in the private blockchain to the private blockchain manager and collect the corresponding remaining key fragments. According to one embodiment, the private blockchain manager may provide the key fragments to the ECU only when the integrity of the key fragments stored in the private blockchain has been authenticated.
[0110] According to another embodiment, if some of the multiple key fragments are stored in the OECU and the remaining key fragments are stored in the private blockchain, an ECU that wants to recover the encryption key can collect the key fragments stored in each OECU and collect the remaining key fragments from the private blockchain.
[0111] Using Shamir's secret sharing method, it is possible to collect the remaining key fragments of a divided encryption key from other networked ECUs within the vehicle. In this process, rather than simply requesting and receiving fragments, an authentication procedure can be implemented to ensure that only accurate and trustworthy fragments are collected.
[0112] First, the ECU requesting collection can verify the integrity and consistency of each key fragment using the Merkle Root value recorded in the blockchain in advance. Other ECUs holding key fragments can provide a Merkle Proof that proves the authenticity of the fragment, along with their own fragment.
[0113] The receiving ECU uses this Merkle authentication path to calculate whether the hash of the fragment matches the entire Merkle root, and can verify that the fragment is one of the originally split key fragments.
[0114] According to one embodiment, when a vehicle is connected to an external network such as a cellular network as illustrated in FIG. 4, an ECU that wishes to recover an encryption key may collect key fragments from a cloud KMS or a public blockchain. The method of collecting key fragments from a cloud KMS or a public blockchain may be the same as the method of collecting key fragments from a private blockchain, and the key fragments stored in the cloud KMS or a public blockchain may be the same as the key fragments stored in a private blockchain.
[0115] In operation S330, the ECU can recover the encryption key based on multiple collected key fragments.
[0116] According to one embodiment, if the ECU has generated n key fragments according to Shamir's secret sharing method, the encryption key can be recovered if the number of collected key fragments is k or more. Accordingly, the encryption key can be recovered even if key fragments stored from a single ECU cannot be collected due to hacking or failure, thereby preventing the single point of failure problem. Furthermore, security can be guaranteed because the encryption key cannot be recovered even if one of the key fragments is exposed due to hacking, etc.
[0117] According to another embodiment, if the ECU codes an encryption key according to a block coding method and generates multiple key fragments, it can recover the encryption key from the collected key according to a block decoding method. In this case, since the encryption key can be recovered even if some key fragments are not collected, the single point of failure problem can be prevented, and security can be guaranteed because the encryption key cannot be recovered using only some key fragments.
[0118] According to one embodiment, the key fragment collected from the blockchain is not used when recovering the encryption key, but can be used to verify whether the recovered encryption key has been tampered with.
[0119] For example, an encryption key can be recovered using the remaining key fragments excluding the key fragment stored in the blockchain, and multiple key fragments can be generated in the same manner based on the recovered encryption key. Then, by comparing the key fragment stored in the blockchain with the corresponding key fragment among the multiple key fragments generated based on the recovered encryption key, it can be determined that there is no tampering if they are identical, and if they are not identical, it can be determined that the recovered encryption key has been tampered with.
[0120] The present invention can provide a method that solves the single point of failure problem by distributing and storing keys generated by a vehicle HSM among the ECUs inside the vehicle, and enables key verification even when the vehicle is not connected to an external network.
[0121] As described above, the present invention has been explained by limited embodiments and drawings, but the present invention is not limited to the above embodiments and modifications or variations of the described matters are possible. Therefore, the scope of the invention is not limited to the described embodiments but should be defined by the claims set forth below as well as equivalents thereof.
[0122] Those skilled in the art related to the embodiments described above will understand that they may be implemented in modified forms without departing from the essential characteristics of the description. Therefore, the disclosed methods should be considered in an illustrative rather than a limiting sense. The scope of the invention is defined by the claims, not by the foregoing description, and all variations within the scope of equivalence should be interpreted as being included in the invention. Explanation of the symbols
[0124] 13: HSM (hardware security module) 101: ECU (electronic control unit) 200: CAN (control area network) 300: Cloud KMS (key management system) 400: Public blockchain 1000: Car
Claims
Claim 1 An electronic control unit equipped in a vehicle comprises a storage unit; a processor; and a hardware security module (HSM) having a key storage unit capable of securely storing data, wherein the HSM generates an encryption key and generates a plurality of key fragments capable of recovering the generated encryption key, stores some of the plurality of key fragments in the storage unit or the key storage unit, and distributes and stores the remaining key fragments among the plurality of key fragments in a plurality of other electronic control units connected to a vehicle network. Claim 2 An electronic control device according to claim 1, wherein the HSM blocks-codes the encryption key so that the encryption key can be recovered even if only some key fragment data is collected, and divides the block-coded encryption key into a plurality of key fragments to generate the plurality of key fragments. Claim 3 In claim 1, the electronic control device wherein the HSM generates the plurality of key fragments according to Shamir's secret sharing method based on the generated encryption key. Claim 4 In claim 1, the HSM is an electronic control unit that stores the remaining pieces in a private blockchain formed by a plurality of electronic control units connected to a vehicle network. Claim 5 An electronic control device according to claim 1, wherein the HSM stores a portion of the remaining piece by distributing it among some of the multiple electronic control devices connected to a vehicle network, and stores the remaining piece excluding the portion of the remaining piece in a private blockchain formed by some of the multiple electronic control devices connected to the vehicle network. Claim 6 An electronic control device according to claim 4 or 5, wherein the HSM stores key fragments stored in the private blockchain in a cloud KMS (Key Management System) or a public blockchain when connected to an external network. Claim 7 An electronic control unit according to claim 1, wherein the HSM collects some of the plurality of key fragments stored in the storage unit or the key storage unit, collects the remaining fragments of the plurality of key fragments distributed and stored in a plurality of other electronic control units connected to the vehicle network, and recovers the encryption key based on the collected plurality of key fragments. Claim 8 In claim 7, the HSM is an electronic control unit that collects the remaining pieces from a private blockchain formed of a plurality of electronic control units connected to a vehicle network. Claim 9 In claim 7, the HSM collects a portion of the remaining piece stored distributedly in some of the electronic control units among the plurality of electronic control units connected to the vehicle network, and collects the remaining piece excluding the portion of the remaining piece stored in a private blockchain formed by some of the electronic control units among the plurality of electronic control units connected to the vehicle network. Claim 10 An electronic control device according to claim 8 or 9, wherein the HSM, when connected to an external network, collects key fragments stored in the private blockchain in cooperation with a cloud KMS (Key Management System) or a public blockchain. Claim 11 In claim 7, the electronic control device wherein the HSM recovers the encryption key by block decoding based on the collected multiple key fragments when the encryption key is divided into multiple key fragments after block coding. Claim 12 In claim 7, the electronic control device wherein the HSM recovers the encryption key according to Shamir's secret sharing method based on the collected key fragments when the key fragments are generated according to Shamir's secret sharing method. Claim 13 An electronic control unit equipped in a vehicle, in a method for encrypting a key for vehicle network security, comprises: an operation of generating an encryption key; an operation of generating a plurality of key fragments capable of recovering the generated encryption key; an operation of storing some of the plurality of key fragments in a storage unit or secure storage of the electronic control unit; and an operation of distributing and storing the remaining key fragments among the plurality of key fragments in a plurality of other electronic control units connected to the vehicle network. Claim 14 In claim 13, the operation of generating the encryption key includes the operation of block coding the encryption key so that the encryption key can be recovered even if only some key fragment data is collected. Claim 15 In claim 13, the operation of generating a plurality of key fragments capable of recovering the generated encryption key includes the operation of generating the plurality of key fragments according to Shamir's secret sharing method based on the generated encryption key, , encryption key manipulation method. Claim 16 In claim 13, the operation of distributing and storing the remaining key fragments among the plurality of key fragments in a plurality of other electronic control units connected to a vehicle network includes the operation of storing the remaining fragments in a private blockchain formed by the plurality of electronic control units connected to the vehicle network. Claim 17 In claim 13, the operation of distributing and storing the remaining key fragments among the plurality of key fragments in a plurality of other electronic control units connected to a vehicle network comprises: the operation of distributing and storing one fragment of the remaining fragment in each of the electronic control units among the plurality of electronic control units connected to the vehicle network; and the operation of storing the remaining fragments, excluding the said fragments, in a private blockchain formed by some of the electronic control units among the plurality of electronic control units connected to the vehicle network. Claim 18 In claim 17, the encryption key manipulation method further includes the operation of storing a key fragment stored in the private blockchain in a cloud KMS (Key Management System) or a public blockchain when connected to an external network. Claim 19 In claim 13, the encryption key manipulation method further comprises: an operation of collecting some of the plurality of key fragments stored in the storage unit or key storage unit; an operation of collecting the remaining fragments of the plurality of key fragments distributed and stored in a plurality of other electronic control units connected to the vehicle network; and an operation of recovering the encryption key based on the collected plurality of key fragments. Claim 20 In claim 19, the operation of collecting the remaining pieces among the plurality of key pieces distributed and stored in a plurality of other electronic control units connected to the vehicle network comprises the operation of collecting the remaining pieces from a private blockchain formed by the plurality of electronic control units connected to the vehicle network. Claim 21 In claim 19, the operation of collecting the remaining pieces among the plurality of key pieces distributed and stored in a plurality of other electronic control units connected to the vehicle network comprises: the operation of collecting a portion of the remaining pieces distributed and stored in some of the electronic control units among the plurality of electronic control units connected to the vehicle network; and the operation of collecting the remaining pieces excluding the portion of the remaining pieces stored in a private blockchain formed by some of the electronic control units among the plurality of electronic control units connected to the vehicle network. Claim 22 In claim 20, the encryption key manipulation method further comprises, when connected to an external network, an operation of collecting key fragments stored in the private blockchain in cooperation with a cloud KMS (Key Management System) or a public blockchain. Claim 23 In claim 19, the operation of recovering the encryption key based on the collected plurality of key fragments includes, when the encryption key is divided into a plurality of key fragments after block coding, the operation of block decoding based on the collected plurality of key fragments to recover the encryption key, an encryption key manipulation method. Claim 24 In claim 19, the operation of recovering the encryption key based on the plurality of collected key fragments includes, when the key fragments are generated according to Shamir's secret sharing method, the operation of recovering the encryption key according to Shamir's secret sharing method based on the collected key fragments, an encryption key manipulation method.
