Authentication system
By setting a separate encryption key (MAC key) for each electronic control device (ECU) and storing this information in the server device, the problem of difficulty in determining the source of leakage after public key leakage is solved, and the authentication security between the ECU and the server is improved.
Patent Information
- Application Number
- CN202110245955.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2020-03-11
- Filing Date
- 2021-03-05
- Publication Date
- 2025-04-04
- Estimated Expiration
- 2041-03-05
AI Technical Summary
In the prior art, when using public keys for multiple ECUs to verify the legitimacy of ECUs, it is difficult to determine the source of the leakage when the public key is leaked, which may lead to illegal access to the server device.
Each electronic control device (ECU) has a separate encryption key (MAC key) for data authentication between ECUs. The server device stores the identification information and MAC key information of each ECU and authenticates it with these keys.
By using a separate MAC key, the source of key leakage can be determined without reducing security, preventing illegal access, and improving the security of authentication.
Smart Images

Figure CN113392401B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to an authentication system for authenticating an electronic control device mounted on a vehicle and a server device communicating with the electronic control device. Background Art
[0002] In the past, there is a known device in which a server device uses a common key shared by multiple ECUs (electronic control units) mounted on a vehicle to verify the legitimacy of each ECU (see, for example, Patent Document 1). The device described in Patent Document 1 is configured to allow the update of firmware, etc., to be performed on the ECU authenticated by the server device.
[0003] However, as in the device described in Patent Document 1, when a common key shared by multiple ECUs is used to verify the legitimacy of an ECU, if the common key is leaked, it is difficult to identify the source of the leak, and there is a possibility of illegally accessing a server device using the leaked common key.
[0004] Prior art literature
[0005] Patent Document 1: Japanese Patent Application Publication No. 2017-017616 (JP 2017-017616A). Summary of the invention
[0006] An authentication system of a technical solution of the present invention comprises: a plurality of electronic control devices, which constitute an in-vehicle network mounted on a vehicle; and a server device, which communicates with each of the plurality of electronic control devices. Each of the plurality of electronic control devices has a storage unit for storing an encryption key that is individually set to generate a code for data authentication when data is transferred between the electronic control devices. The server device has a storage unit for storing information about identification information and encryption keys of each of the plurality of electronic control devices. Each of the plurality of electronic control devices also has a data generation unit for generating authentication data for authenticating the electronic control device, a code generation unit for encrypting the authentication data generated by the data generation unit with an encryption key to generate an authentication code, and an output unit for sending the identification information, the authentication data, and the authentication code to the server device. The server device also has a retrieval unit for retrieving the encryption key of the corresponding electronic control device based on the identification information obtained when the identification information sent by the output unit is obtained, and an authentication unit for authenticating the electronic control device using the encryption key retrieved by the retrieval unit when the authentication data and the authentication code sent by the output unit are obtained. BRIEF DESCRIPTION OF THE DRAWINGS
[0007] The objects, features and advantages of the present invention will be further clarified through the following description of the embodiments in conjunction with the accompanying drawings.
[0008] Figure 1This is a diagram schematically showing an example of the configuration of an authentication system according to an embodiment of the present invention.
[0009] Figure 2 It is schematically shown Figure 1 A block diagram of the main components of an electronic control device.
[0010] Figure 3 It is schematically shown Figure 1 A block diagram showing the main components of a server device.
[0011] Figure 4 It is shown by Figure 1 A sequence diagram of an example of authentication processing of an electronic control device and a server device performed by an authentication system. DETAILED DESCRIPTION
[0012] The following reference Figure 1 to Figure 4 An embodiment of the present invention will be described. Figure 1 Schematically shows an example of the configuration of the authentication system 100 according to the embodiment of the present invention. Figure 1 As shown, the authentication system 100 includes a plurality of electronic control units (ECUs) 11 mounted on the vehicle 1 and controlling the operation of the vehicle 1 , and a server device 2 capable of communicating with each of the plurality of electronic control units 11 .
[0013] The plurality of electronic control devices 11 are composed of a plurality of ECUs having different functions, such as an engine control ECU 11a, a transmission control ECU 11b, and a steering control ECU 11c. The plurality of electronic control devices 11 are connected to each other via a serial communication line 12 such as a CAN (Controller Area Network) communication line so as to be able to communicate with each other, thereby forming an in-vehicle network 10. The server device 2 is connected to the in-vehicle network 10 via a network 3 including a public wireless communication network represented by the Internet and a mobile phone network so as to be able to communicate with each other.
[0014] The vehicle manufacturer releases the updated program of the electronic control device 11 through a sales store or the like in response to a request for an upgrade or quality improvement of the control program of the electronic control device 11 of the vehicle 1. At the sales store or the like, it is checked whether there is an updated program for the electronic control device 11 corresponding to the vehicle 1 of the customer who comes to the store, and when there is an updated program, the electronic control device 11 is connected to the server device 2 of the vehicle manufacturer to update the control program of the electronic control device 11. For example, the control program of the electronic control device 11 is updated via an update device or the like.
[0015] In order to prevent a malicious third party from illegally obtaining data by posing as an illegal hardware or software, the server device 2 only allows the electronic control device 11 authenticated by the server device 2 of the vehicle manufacturer to update the control program. In the case of authenticating the electronic control device 11 using a common key shared by a plurality of electronic control devices 11, when the common key is leaked from any of the plurality of electronic control devices, it may be difficult to identify the source of the leak. As a result, it is possible to illegally obtain an update program using the leaked common key. Therefore, in order to authenticate the electronic control device without reducing security, the authentication system 100 of the embodiment of the present invention is constructed as follows.
[0016] Figure 2 It is schematically shown Figure 1 The electronic control device 11 is a block diagram showing the main parts of the electronic control device 11. The electronic control device 11 is composed of a computer including a computing unit 13 such as a CPU (central processing unit), a ROM (read only memory), a RAM (random access memory), a storage unit 14 such as a hard disk, and other peripheral circuits, and can be connected to the network 3 via a communication unit 15.
[0017] The operation unit 13 has a seed generation unit 131, a MAC generation unit 132, an output unit 133, a key generation unit 134, a MAC decryption unit 135, a first determination unit 136, a second determination unit 137, and an authentication unit 138 as functional components. The seed generation unit 131 constitutes a data generation unit, and the MAC generation unit 132 constitutes a code generation unit.
[0018] The storage unit 14 has, as functional components, an identification information storage unit 141 , a MAC key storage unit 142 , a public key storage unit 143 , a seed storage unit 144 , and a key storage unit 145 . The MAC key storage unit 142 and the public key storage unit 143 are stored in an HSM (Hardware Security Module) 16 included in the electronic control device 11 .
[0019] When the seed generation unit 131 receives the identification information request signal to be described later transmitted from the server device 2 via the communication unit 15, it generates a seed (seed value, authentication data) composed of a random number by a known method. The seed is authentication data used for authentication of each electronic control device 11 between each of the plurality of electronic control devices 11 and the server device 2. The seed generated by the seed generation unit 131 is temporarily stored in the seed storage unit 144 together with a preset validity period (e.g., 10 minutes).
[0020] The MAC generation unit 132 encrypts the seed generated by the seed generation unit 131 using the MAC key (encryption key) stored in the MAC key storage unit 142, and generates a message authentication code (hereinafter also referred to as "MAC (Message Authentication Code)") with the seed as the original data. The MAC generated by the MAC generation unit 132 constitutes the authentication code, and the MAC generation unit 132 generates the first MAC (first authentication code) for sending to the server device 2.
[0021] Furthermore, the MAC generation unit 132 generates a MAC that encrypts the data exchanged with the MAC key when data (message) is exchanged between the electronic control devices 11. This MAC is a code for authenticating the data exchanged between the electronic control devices 11. That is, the MAC generation unit 132 generates a first MAC for authenticating the seed exchanged between the electronic control device 11 and the server device 2, and a MAC for authenticating the data exchanged between the electronic control devices 11.
[0022] The first MAC and MAC generated by the MAC generation unit 132 are generated using a known MAC algorithm. Known MAC algorithms include a method using a hash function (HMAC), a method using a block cipher algorithm (OMAC / CMAC, CBC-MAC, PMAC), etc. The MAC generation unit 132 uses these to encrypt and decrypt the seed and data using a MAC key.
[0023] When the output unit 133 receives the identification information request (identification information request signal) transmitted from the server device 2 via the communication unit 15, the output unit 133 transmits the identification information (identification information signal) of the vehicle 1 stored in the identification information storage unit 141 to the server device 2 via the communication unit 15. In addition, when the MAC generation unit 132 generates the first MAC, the output unit 133 transmits the seed generated by the seed generation unit 131 and the first MAC generated by the MAC generation unit 132 to the server device 2 via the communication unit 15.
[0024] The key generation unit 134 encrypts the seed generated by the seed generation unit 131 using the public key stored in the public key storage unit 143 to generate the first key. The first key generated by the key generation unit 134 is generated using a known public key encryption method (AES). The first key generated by the key generation unit 134 is stored in the key storage unit 145 together with a preset validity period (e.g., 10 minutes).
[0025] The MAC decryption unit 135 uses the MAC key stored in the MAC key storage unit 142 to decrypt the second MAC sent from the server device 2, which will be described later, and returns the second MAC to the original data before encryption. That is, the MAC decryption unit 135 decrypts the second MAC and returns it to the original data, that is, the second key described later. The MAC decryption unit 135 decrypts the second MAC using the same encryption method of the MAC algorithm as that of the server device 2. Therefore, the method of the MAC algorithm used for encryption and decryption is pre-set in the electronic control unit 11 and the server device 2.
[0026] The first determination unit 136 compares the second key sent from the server device 2 with the second key decrypted by the MAC decryption unit 135 to determine whether they are consistent. The second determination unit 137 compares the first key encrypted by the key generation unit 134 using the public key with the second key sent from the server device 2 to determine whether the first key and the second key are consistent. That is, the first determination unit 136 and the second determination unit 137 verify the legitimacy of the server device 2.
[0027] The authentication unit 138 authenticates the server device 2 when the first judgment unit 136 determines that the transmitted second key is consistent with the decrypted second key and the second judgment unit 137 determines that the first key is consistent with the second key. When authenticating the server device, the authentication unit 138 releases the security protection of the server device 2 and enters a state in which data communication with the server device 2 is possible. For example, the state in which the control program of the electronic control device 11 can be updated. On the other hand, when the first judgment unit 136 determines that the transmitted second key is inconsistent with the decrypted second key or when the second judgment unit 137 determines that the first key is inconsistent with the second key, the authentication unit 138 does not authenticate the server device 2. In this case, the authentication unit 138 controls the communication unit 15 to cut off the connection with the server device 2.
[0028] The identification information storage unit 141 stores identification information of each vehicle 1 assigned by the vehicle manufacturer. The identification information of the vehicle 1 includes, for example, a vehicle ID assigned by the vehicle manufacturer to each vehicle 1 and an ECUID assigned to each of a plurality of electronic control devices mounted on the vehicle 1.
[0029] The MAC key storage unit 142 stores a MAC key used for generating the MAC generated by the MAC generation unit 132 and the first MAC. The MAC key is a key that is individually set for each of the plurality of electronic control units 11, and is a different key for each electronic control unit 11. Therefore, even if the MAC key is leaked, for example, it is easy to confirm which electronic control unit 11 the leaked MAC key is set for, and it is easy to identify the source of the leak and the destination of the leak. As a result, it is possible to prevent impersonation of the electronic control unit 11 whose MAC key has been leaked, illegal acquisition of data, etc., etc.
[0030] The public key storage unit 143 stores public keys that can be used in common by each of the plurality of electronic control devices 11. The public key is a key that is common to each of the electronic control devices 11 and corresponds to a private key that is registered in the server device 2 and will be described later. Encryption using the public key uses a public key encryption method (AES), in which a pair of public and private keys that are different from each other are generated and shared in advance by the sender and receiver of various data.
[0031] The seed storage unit 144 temporarily stores the seed generated by the seed generation unit 131. When a preset validity period (e.g., 10 minutes) has passed, the seed storage unit 144 deletes the seed information. The key storage unit 145 temporarily stores the first key generated by the key generation unit 134. When a preset validity period (e.g., 10 minutes) has passed, the key storage unit 145 deletes the first key information.
[0032] The server device 2 is composed of a computer including a CPU or other computing unit 20, a ROM, RAM, a storage unit 21 such as a hard disk, and other peripheral circuits, and can be connected to the network 3 via a communication unit 22. The computing unit 20 includes a search unit 201, a MAC decryption unit 202, a determination unit 203, an authentication unit 204, a key generation unit 205, a MAC generation unit 206, and an output unit 207 as functional components. The storage unit 21 includes a vehicle database 211, a private key storage unit 212, a seed storage unit 213, and a key storage unit 214 as functional components.
[0033] When the search unit 201 receives the identification information (identification information signal) transmitted from the electronic control unit 11 via the communication unit 22, the search unit 201 searches the vehicle information stored in the vehicle database 211 for the inherent MAC key set for the electronic control unit 11 that transmitted the identification information based on the received identification information. For example, the search unit 201 identifies the corresponding vehicle 1 from a plurality of vehicles based on the vehicle ID transmitted from the electronic control unit 11, and identifies the corresponding electronic control unit 11 from a plurality of electronic control units based on the ECUID. When the search unit 201 identifies the electronic control unit 11, it extracts the MAC key information from the identification information of the electronic control unit 11.
[0034] The MAC decryption unit 202 decrypts the first MAC sent from the electronic control unit 11 using the MAC key retrieved by the search unit 201, and returns the first MAC to the original data before encryption. That is, the MAC decryption unit 202 decrypts the first MAC and returns it to the seed that is the original data. The MAC decryption unit 202 decrypts the first MAC using the same MAC algorithm encryption method as the MAC generation unit 132 of the electronic control unit 11.
[0035] The determination unit 203 compares the seed sent from the electronic control unit 11 with the seed decrypted by the MAC decryption unit 202 to determine whether the sent seed and the decrypted seed are consistent. That is, the legitimacy of the electronic control unit 11 is verified.
[0036] When the determination unit 203 determines that the transmitted seed and the decrypted seed are consistent, the authentication unit 204 authenticates the electronic control device 11. On the other hand, when the determination unit 203 determines that the transmitted seed and the decrypted seed are inconsistent, the authentication unit 204 does not authenticate the electronic control device 11. In this case, the authentication unit 204 controls the communication unit 22 to cut off the connection with the electronic control device 11.
[0037] The key generation unit 205 encrypts the seed sent from the electronic control device 11 using the private key stored in the private key storage unit 212 to generate the second key. The second key generated by the key generation unit 205 is generated using a known public encryption method (AES). The second key generated by the key generation unit 205 is stored in the key storage unit 214 together with a preset validity period (e.g., 10 minutes).
[0038] The MAC generation unit 206 encrypts the second key generated by the key generation unit 205 using the MAC key retrieved by the search unit 201 to generate a second MAC (second authentication code) using the second key as source data. The MAC generation unit 206 generates the second MAC using the same MAC algorithm encryption method as the electronic control unit 11.
[0039] When the output unit 207 receives the authentication request via the communication unit 22, it transmits an identification information request signal requesting identification information of the vehicle 1 to the electronic control unit 11 via the communication unit 22. Furthermore, when the MAC generation unit 206 generates the second MAC, the output unit 207 transmits the second key, which is the original data of the second MAC, and the second MAC generated by the MAC generation unit 206 to the electronic control unit 11 via the communication unit 22.
[0040] The vehicle database 211 stores information on a plurality of vehicles 1 managed by the server device 2. The information on the vehicle 1 includes, for example, a vehicle ID assigned to each vehicle 1 by a vehicle manufacturer, an ECUID assigned to each of a plurality of electronic control devices 11 mounted on the vehicle 1, and the information on the electronic control device 11 to which the ECUID is assigned includes information on a MAC key individually set for each electronic control device 11.
[0041] The private key storage unit 212 stores private keys corresponding to the public keys shared by the plurality of electronic control units 11. The seed storage unit 213 temporarily stores the seeds sent from the electronic control unit 11. When a preset validity period (e.g., 10 minutes) has passed, the seed storage unit 213 deletes the seed information. The key storage unit 214 temporarily stores the second key generated by the key generation unit 205. When a preset validity period (e.g., 10 minutes) has passed, the key storage unit 214 deletes the second key information.
[0042] Figure 4 It is shown by Figure 1 The sequence diagram of an example of authentication processing of the electronic control device 11 and the server device 2 performed by the authentication system 100 shows an example of authentication processing performed by the operation unit 13 of the electronic control device 11 and the operation unit 20 of the server device 2 according to a pre-stored program. Figure 4 The processing shown in the sequence diagram starts, for example, when the electronic control device 11 is connected to the server device 2 via the network 3 and an authentication request signal from the user is input to the server device 2 via the electronic control device 11 or an update device interposed between the electronic control device 11 and the server device 2.
[0043] When the authentication request signal from the user is input to the server device 2, in S1 (S: processing step), the output unit 207 of the server device 2 outputs an identification information request signal requesting identification information of the vehicle 1 to the electronic control device 11. When the identification information request signal is input to the electronic control device 11, in S2, the output unit 133 of the electronic control device 11 outputs the identification information signal of the electronic control device 11 to the server device 2. When the identification information signal of the electronic control device 11 is input to the server device 2, in S3, the search unit 201 of the server device 2 searches for the MAC key of the electronic control device 11 based on the input identification information signal.
[0044] Furthermore, when the identification information request signal is input to the electronic control device 11, in S4, the seed generation unit 131 of the electronic control device 11 generates a seed consisting of a random number. It should be noted that S4 can also be executed before executing S3. Next, the MAC generation unit 132 of the electronic control device 11 encrypts the seed generated by the seed generation unit 131 with the MAC key stored in the MAC key storage unit 142 to generate the first MAC (S5). Next, the output unit 133 of the electronic control device 11 outputs the seed generated by the seed generation unit 131 and the first MAC generated by the MAC generation unit 132 to the server device 2 (S6).
[0045] Next, when the seed and the first MAC are input to the server device 2, in S7, the MAC decryption unit 202 of the server device 2 decrypts the sent first MAC. Next, in S8, the determination unit 203 of the server device 2 compares the seed sent from the electronic control device 11 and the seed decrypted by the MAC decryption unit 202 to determine whether the sent seed and the decrypted seed are consistent. When S8 is negative (S8: No), in S9, the connection with the electronic control device 11 is cut off through the processing of the authentication unit 204. On the other hand, when S8 is positive (S8: Yes), in S10, the electronic control device 11 is authenticated through the processing of the authentication unit 204.
[0046] Next, in S11, the key generation unit 205 of the server device 2 encrypts the seed sent from the electronic control unit 11 using the private key stored in the private key storage unit 212 to generate the second key. Next, in S12, the MAC generation unit 206 encrypts the second key generated by the key generation unit 205 using the MAC key retrieved by the retrieval unit 201 to generate a second MAC (second authentication code) with the second key as the original data.
[0047] Next, in S13, the output unit 207 of the server device 2 sends the second key and the second MAC to the electronic control device 11. Next, in S14, the key generation unit 134 of the electronic control device 11 encrypts the seed generated by the seed generation unit 131 using the public key stored in the public key storage unit 143 to generate the first key. It should be noted that S14 can also be executed before or during the execution of S7 to S13.
[0048] Next, in S15, the MAC decryption unit 135 of the electronic control unit 11 decrypts the second MAC sent from the server device 2 using the MAC key stored in the MAC key storage unit 142. Next, in S16, the first determination unit 136 determines whether the second key sent from the server device 2 and the second key decrypted by the MAC decryption unit 135 are consistent. When S16 is negative (S16: No), in S17, the connection with the server device 2 is disconnected by the processing of the authentication unit 138. On the other hand, when S16 is positive (S16: Yes), in S18, the second determination unit 137 determines whether the first key and the second key are consistent. When S18 (S18: No) is negative, in S17, the connection with the server device 2 is disconnected by the processing of the authentication unit 138. On the other hand, when S18 is positive (S18: Yes), in S19, the server device 2 is authenticated by the processing of the authentication unit 138, and the processing ends.
[0049] The main operation of the authentication system 100 of this embodiment is described. When the electronic control device 11 of the vehicle 1 makes an authentication request to the server device 2 of the vehicle manufacturer, the electronic control device 11 sends the identification information of the vehicle 1 via the network 3 (S2), and the server device 2 retrieves the MAC key of the electronic control device 11 based on the sent identification information (S3). The MAC key of the electronic control device 11 is a key registered with the relevant information of the vehicle 1 in the server device 2 of the vehicle manufacturer when the vehicle manufacturer registers the manufactured vehicle 1.
[0050] The electronic control device 11 encrypts the seed using the MAC key to generate the first MAC (S5), and the server device 2 decrypts the first MAC using the MAC key (S7). That is, the server device 2 verifies the legitimacy of the electronic control device 11 using the MAC key, authenticates the electronic control device 11, and disconnects the electronic control device 11 as needed (S8-S10).
[0051] Similarly, the server device 2 generates the second MAC using the MAC key (S12), and the electronic control device 11 decrypts the second MAC using the MAC key (S15). That is, the electronic control device 11 verifies the legitimacy of the server device 2 using the MAC key, authenticates the server device 2, and disconnects the connection with the server device 2 as needed (S16 to S19).
[0052] The present embodiment can achieve the following effects.
[0053] (1) The authentication system 100 includes: a plurality of electronic control devices 11 constituting an in-vehicle network 10 mounted on a vehicle 1; and a server device 2 communicating with each of the electronic control devices 11 ( Figure 1 Each of the plurality of electronic control devices 11 includes a MAC key storage unit 142 that stores a MAC key ( Figure 2 The server device 2 has a vehicle database 211 (which stores identification information and MAC key information of each of the plurality of electronic control devices 11). Figure 3 Each of the plurality of electronic control devices 11 further comprises: a seed generation unit 131 that generates a seed for authenticating the electronic control device 11; a MAC generation unit 132 that encrypts the seed generated by the seed generation unit 131 using the MAC key to generate a first MAC; and an output unit 133 that outputs the identification information, the authentication data, and the first MAC to the server device 2 ( Figure 2 The server device 2 further includes: a search unit 201, which, when obtaining the identification information sent by the output unit 133, searches for the MAC key of the corresponding electronic control device 11 based on the obtained identification information; and an authentication unit 204, which, when obtaining the seed and the first MAC sent by the output unit 133, uses the MAC key retrieved by the search unit 201 to authenticate the electronic control device 11 ( Figure 3 ).
[0054] With this configuration, since the server device 2 authenticates the electronic control device 11 using a MAC key that is individually set for the electronic control device 11 and is used for authentication between the electronic control devices 11, the security during authentication can be improved. For example, even if the authentication key (MAC key) is leaked, it is easy to determine the source and destination of the leak, and illegal access using the leaked key can be prevented. In addition, the MAC key is a key that the electronic control device 11 and the server device 2 have in advance, so there is no need to set a new authentication key, and the key management becomes easy.
[0055] (2) The server device 2 further includes: a MAC generation unit 206 that encrypts the seed using the obtained seed and the retrieved MAC key to generate a second MAC; and an output unit 207 that sends the seed and the second MAC to the electronic control device 11 ( Figure 3 The electronic control device 11 further includes an authentication unit 138, which, upon receiving the seed and the second MAC sent by the server device 2, uses the MAC key to authenticate the server device 2 ( Figure 2 ). Thus, the electronic control device 11 can authenticate the server device 2 using the MAC key. In addition, there is no need to newly set a key for authentication in the authentication of the electronic control device 11, so key management becomes easy.
[0056] (3) When the server device 2 obtains the seed and the first MAC, it uses the MAC key to decrypt the first MAC or encrypt the seed, thereby authenticating the electronic control device 11. When the electronic control device 11 obtains the seed and the second MAC, it uses the MAC key to decrypt the second MAC or encrypt the seed, thereby authenticating the server device 2. Figure 4 ). Thus, since authentication of the server device 2 and the electronic control device 11 is performed by encryption or decryption using the MAC key, security during authentication can be improved.
[0057] (4) A different MAC key is set for each of the plurality of electronic control devices 11. Thus, even if the MAC key is leaked, the leak source and leak destination can be easily identified, and unauthorized access using the leaked key can be prevented.
[0058] In the above embodiment, the server device 2 decrypts the first MAC with the MAC key to verify the legitimacy of the electronic control device 11, but the MAC key may be used to encrypt the seed to verify the legitimacy of the electronic control device 11. Similarly, the electronic control device 11 decrypts the second MAC with the MAC key to verify the legitimacy of the server device 2, but the MAC key may be used to encrypt the second key to verify the legitimacy of the server device 2.
[0059] In the above-mentioned embodiment, the second key obtained by encrypting the seed with the private key is encrypted with the MAC key to generate the second MAC, and the electronic control unit 11 decrypts the second MAC with the MAC key to verify the legitimacy of the server device 2. However, the seed may be encrypted with the MAC key to generate the second MAC, and the electronic control unit 11 decrypts the second MAC with the MAC key to verify the legitimacy of the server device 2. That is, the electronic control unit 11 and the server device 2 may be authenticated (verified legitimacy) only with the MAC key without using the private key and the public key.
[0060] In the above embodiment, the electronic control device 11 and the server device 2 are connected via the network 3, and the electronic control device 11 and the server device 2 are authenticated. However, an update device authenticated by the server device 2 and updating the control program of the electronic control device 11 of the vehicle 1 may be interposed between the electronic control device 11 and the server device 2 to perform the above authentication. In this case, the update device may attach a MAC encrypted with a MAC key to the update data and send it to the electronic control device 11 authenticated by the server device 2, and the electronic control device 11 may encrypt or decrypt the update data with the MAC key to authenticate the update data. By authenticating the update data using the MAC key, the control program can be updated more securely.
[0061] One or more of the above-described embodiments and modifications may be arbitrarily combined, and modifications may be combined with each other.
[0062] According to the present invention, it is possible to improve the security during authentication of an electronic control device and a server device communicating with the electronic control device.
[0063] The present invention has been described above in conjunction with preferred embodiments. It should be understood by those skilled in the art that various modifications and changes can be made without departing from the scope of the disclosure of the claims set forth below.
Claims
1. An authentication system (100), characterized in that: have: A plurality of electronic control devices (11) constituting an on-vehicle network (10) mounted on a vehicle (1); and A server device (2) that communicates with each of the plurality of electronic control devices (11). Each of the plurality of electronic control devices (11) includes a storage unit (142) for storing an encryption key that is individually set to generate a code for authenticating data when data is exchanged between the electronic control devices (11). The server device (2) includes a storage unit (21) for storing identification information of each of the plurality of electronic control devices (11) and information of the encryption key. Each of the plurality of electronic control devices (11) further comprises a data generation unit (131) for generating authentication data for authenticating the electronic control device (11), a code generation unit (132) for encrypting the authentication data generated by the data generation unit (131) with the encryption key to generate an authentication code, and an output unit (133) for transmitting the identification information, the authentication data and the authentication code to the server device. The server device (2) further comprises a retrieval unit (201) for retrieving the encryption key of the corresponding electronic control device (11) based on the obtained identification information when the identification information sent by the output unit (133) is obtained, and an authentication unit (204) for authenticating the electronic control device (11) using the encryption key retrieved by the retrieval unit (201) when the authentication data and the authentication code sent by the output unit (133) are obtained. A validity period is set for authentication data used to authenticate the electronic control device (11).
2. The authentication system (100) according to claim 1, characterized in that: The authentication code is the first authentication code, The server device (2) further comprises a code generating unit (206) for generating a second authentication code by encrypting the authentication data using the acquired authentication data and the retrieved encryption key, and an output unit (207) for transmitting the authentication data and the second authentication code to the electronic control device (11). The electronic control device (11) further includes an authentication unit (138) for authenticating the server device (2) using the encryption key when receiving the authentication data and the second authentication code transmitted by the server device (2).
3. The authentication system (100) according to claim 2, characterized in that: When the server device (2) obtains the authentication data or the first authentication code, it uses the encryption key to decrypt the first authentication code or encrypt the authentication data to authenticate the electronic control device (11). When the electronic control device (11) obtains the authentication data and the second authentication code, it uses the encryption key to decrypt the second authentication code or encrypt the authentication data to authenticate the server device (2).
4. The authentication system (100) according to any one of claims 1 to 3, characterized in that: The encryption key that is different for each of the plurality of electronic control devices (11) is set.
5. The authentication system (100) according to any one of claims 1 to 3, characterized in that: When the electronic control devices (11) exchange data with each other, the code used to authenticate the data is a message authentication code. The authentication data used for authenticating the electronic control device (11) is a seed value composed of a random number.
6. The authentication system (100) according to claim 4, characterized in that: When the electronic control devices (11) exchange data with each other, the code used to authenticate the data is a message authentication code. The authentication data used for authenticating the electronic control device (11) is a seed value composed of a random number.
Citation Information
Patent Citations
Software distribution processing unit, vehicle, software distribution processing method and computer program
JP2017017616A
In-Vehicle Information Communication System And Authentication Method
CN107683583A