Abnormality detection device and abnormality detection method
Patent Information
- Application Number
- JP2023573958
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Priority Date
- 2022-12-26
- Filing Date
- 2022-12-26
- Publication Date
- 2024-09-25
AI Technical Summary
In-vehicle network systems face challenges in detecting anomalies due to changes in communication trends caused by updates or attacks, where existing methods require frequent updates of detection rules to maintain accuracy, and there is no mechanism to authenticate senders in service-oriented communication protocols like SOME/IP, leading to potential unauthorized communication.
An anomaly detection device and method that utilize ECU attributes to classify communication, determining whether unusual communication is abnormal by referencing the attributes of electronic control units, including their functions and information types, to improve vehicle safety by distinguishing between normal and abnormal communication patterns.
The solution effectively detects abnormal communication by classifying ECU attributes, enhancing vehicle safety by distinguishing between changes due to updates or attacks, and reducing false positives over time, thereby improving the overall security of the in-vehicle network system.
Abstract
Description
Anomaly detection device and anomaly detection method
[0001] The present disclosure relates to an abnormality detection device and an abnormality detection method for detecting an abnormality in an in-vehicle network system.
[0002] Non-patent document 1 discloses a technology that can pre-set the destination IP address and source IP address corresponding to the service ID for SOME / IP frames as normal rules, monitor the frames, and detect frames that do not follow the normal rules as abnormal frames.
[0003] N. Herold, et al., “Anomaly Detection for SOME / IPusing Complex Event Processing”, NOMS3016, IEEE / IFIP Network Operations and Management Symposium, 2016
[0004] The present disclosure aims to provide an anomaly detection device and an anomaly detection method that can detect abnormal communications by distinguishing whether unusual communication content is from an attacker or not, thereby improving the safety of the entire vehicle.
[0005] An abnormality detection device according to one aspect of the present disclosure is an abnormality detection device that detects abnormalities in an in-vehicle network system composed of two or more electronic control units and one or more networks, and includes an ECU attribute memory unit that stores attributes possessed by the electronic control units set in each of the two or more electronic control units, a communication unit that sends and receives messages on the one or more networks, and an abnormality detection unit that detects abnormal communication using an attribute possessed by an electronic control unit that is the sender or destination of the message, among the attributes stored in the ECU attribute memory unit, and the attribute stored in the ECU attribute memory unit indicates the function of the electronic control unit that has that attribute, or the type of information handled by the electronic control unit that has that attribute.
[0006] An anomaly detection method according to one aspect of the present disclosure is an anomaly detection method for detecting an anomaly in an in-vehicle network system composed of two or more electronic control units and one or more networks, which sends and receives messages on the one or more networks, and detects abnormal communication using an attribute possessed by an electronic control unit that is the sender or destination of the message, among attributes possessed by electronic control units set in each of the two or more electronic control units, wherein the attribute indicates the function of the electronic control unit having the attribute or the type of information handled by the electronic control unit having the attribute.
[0007] These comprehensive or specific aspects may be realized by a system, a method, an integrated circuit, a computer program, or a non-transitory recording medium such as a computer-readable CD-ROM, or may be realized by any combination of a system, a method, an integrated circuit, a computer program, and a non-transitory recording medium.
[0008] According to the present disclosure, abnormal communications can be detected by distinguishing whether unusual communication content is from an attacker or not, thereby improving the safety of the entire vehicle.
[0009] FIG. 1 is a diagram illustrating an example of the overall configuration of an in-vehicle network system according to the first embodiment. FIG. 2 is a diagram illustrating an example of the configuration of a TCU according to the first embodiment. FIG. 3 is a diagram illustrating an example of the configuration of a central ECU according to the first embodiment. FIG. 4 is a diagram illustrating an example of the configuration of a user interface ECU according to the first embodiment. FIG. 5 is a diagram illustrating an example of the configuration of an abnormality detection ECU according to the first embodiment. FIG. 6 is a diagram illustrating an example of the configuration of a zone ECU according to the first embodiment. FIG. 7 is a diagram illustrating an example of the configuration of a brake control ECU according to the first embodiment. FIG. 8 is a diagram illustrating an example of a message format of a SOME / IP SD according to the first embodiment. FIG. 9 is a diagram illustrating an example of a message of a SOME / IP SD according to the first embodiment. FIG. 10 is a diagram illustrating an example of a communication log stored in a communication log storage unit according to the first embodiment. FIG. 11 is a diagram illustrating an example of ECU attribute information according to the first embodiment. FIG. 12 is a diagram illustrating an example of an abnormality detection rule using ECU attributes according to the first embodiment. FIG. 13 is a diagram illustrating an example of a sequence for changing ECU attributes according to the first embodiment. FIG. 14 is a diagram showing an example of a flowchart related to the operation of the abnormality detection ECU when receiving a frame in the first embodiment. FIG. 15 is a diagram showing an example of a flowchart related to ECU attribute setting in the first embodiment. FIG. 16 is a diagram showing an example of a flowchart related to ECU role attribute setting in the first embodiment. FIG. 17 is a diagram showing an example of a flowchart related to ECU domain attribute setting in the first embodiment. FIG. 18 is a diagram showing an example of a sequence related to abnormality detection using ECU attributes in the first embodiment. FIG. 19 is a diagram showing an example of a flowchart related to abnormality detection using ECU attributes in the first embodiment. FIG. 20 is a diagram showing an example of an abnormality detection rule based on ECU attributes in a first modification of the first embodiment. FIG. 21 is a diagram showing an example of a flowchart related to abnormality detection using a source ECU attribute and a frame in the first modification of the first embodiment. FIG. 22 is a diagram showing an example of a flowchart related to abnormality detection using ECU attributes in a second modification of the first embodiment.FIG. 23 is a diagram showing an example of a sequence related to adding an attribute of an ECU in Modification 3 of Embodiment 1. FIG. 24 is a diagram showing an example of ECU attribute information in Modification 3 of Embodiment 1. FIG. 25 is a diagram showing an example of a flowchart related to setting a domain attribute of an ECU in Modification 3 of Embodiment 1. FIG. 26 is a diagram showing an example of a flowchart related to abnormality detection using ECU attributes in Modification 3 of Embodiment 1. FIG. 27 is a diagram showing an example of a log notified when an abnormality is detected in another modification. FIG. 28 is a diagram showing an example of displaying an abnormality detection result on a graphical user interface in another modification.
[0010] (Knowledge forming the basis of the present disclosure) In recent years, systems within automobiles have been equipped with a large number of devices called electronic control units (ECUs), and the network connecting these ECUs is called an in-vehicle network.
[0011] There are many standards for in-vehicle networks. For example, there are in-vehicle networks that use Ethernet (registered trademark) defined by IEEE 802.3. Advanced driver assistance systems and autonomous driving systems require processing of huge amounts of information, and Ethernet, which has a high data transmission speed, is increasingly being introduced.
[0012] SOME / IP (Scalable Service-Oriented Middleware over IP) is a standard for Ethernet communication protocols. SOME / IP is called service-oriented communication because each ECU connected to the Ethernet determines the communication content based on a service ID written in the header.
[0013] SOME / IP can dynamically acquire and communicate with the IP address and MAC address of the ECU to communicate with, as long as the service ID of the service you want to use or the service ID of the service you can provide is stored in advance. This means that developers do not need to set information such as IP addresses and MAC addresses that depend on the system environment in advance, making it easy to design software with excellent portability.
[0014] In addition, online updates via OTA (Over The Air) are becoming increasingly common for in-vehicle network systems, making it easier to update in-vehicle applications and updates to the vehicle, and it is expected that communication trends in in-vehicle networks will change even more dynamically.
[0015] In service-oriented communications such as SOME / IP, there is no mechanism for authenticating the sender, so if an ECU is hijacked illegally, not only will it be possible to send and receive unauthorized communications using the service ID sent and received by the hijacked ECU, but there is also the threat that the hijacked ECU may be able to masquerade as another ECU to enable unauthorized communications or stop communications containing service IDs sent by other ECUs other than the hijacked ECU.
[0016] To counter these threats, as disclosed in Non-Patent Document 1, it is known that for SOME / IP frames, the destination IP address and source IP address corresponding to the service ID can be set in advance as normal rules, the frames can be monitored, and frames that do not conform to the normal rules can be detected as abnormal frames.
[0017] However, installing an in-vehicle application, an ECU update program, etc., in a vehicle via OTA causes changes in the communication trends of the in-vehicle network. Specifically, these changes are thought to include (i) the addition of a new function, which causes communication between two ECUs that did not previously exist, and (ii) the deletion of a previously existing function, which causes new communication between two ECUs or the cessation of communication that previously existed between two ECUs.
[0018] In such cases, if a method of pre-setting a normal communication connection from the IP address or MAC address of the source ECU or destination ECU, as disclosed in Non-Patent Document 1, is used, it becomes necessary to update the detection rules every time an in-vehicle application, ECU update program, etc. is installed in the vehicle via OTA, and maintaining high accuracy in anomaly detection becomes a challenge.
[0019] The present disclosure aims to provide a safer in-vehicle network system by classifying the communication tendencies and communication contents of ECUs in accordance with changes in the in-vehicle network, and by using an anomaly detection ECU with an anomaly detection function that uses the classification results.
[0020] An abnormality detection device according to a first aspect of the present disclosure is an abnormality detection device that detects abnormalities in an in-vehicle network system composed of two or more electronic control units and one or more networks, and includes an ECU attribute memory unit that stores attributes possessed by the electronic control units set in each of the two or more electronic control units, a communication unit that sends and receives messages on the one or more networks, and an abnormality detection unit that detects abnormal communication using an attribute possessed by an electronic control unit that is the sender or destination of the message, among the attributes stored in the ECU attribute memory unit, and the attribute stored in the ECU attribute memory unit indicates the function of the electronic control unit that has that attribute, or the type of information handled by the electronic control unit that has that attribute.
[0021] This makes it possible to determine whether an abnormal message exchange is occurring when a message is exchanged between electronic control units by referring to the attributes that indicate the function of each electronic control unit and the type of information handled by the electronic control unit, thereby improving vehicle safety.
[0022] An anomaly detection device according to a second aspect of the present disclosure is the anomaly detection device according to the first aspect, wherein the attributes stored in the ECU attribute memory unit indicate the functions of an electronic control unit operating in the in-vehicle network system and include one of a sensor attribute indicating that the electronic control unit has a function of sensing information inside and outside the vehicle, a brain attribute indicating that the electronic control unit has a function of processing the sensed information and issuing control instructions, and an actuator attribute indicating that the electronic control unit has a function of performing control in accordance with control instructions.
[0023] This makes it possible to determine whether or not communication is abnormal based on the functional relationships between electronic control units, thereby improving vehicle safety.
[0024] An abnormality detection device according to a third aspect of the present disclosure is the abnormality detection device according to the first aspect, wherein the attributes stored in the ECU attribute storage unit indicate the type of information handled by an electronic control unit in the in-vehicle network system, and include any one of a powertrain attribute indicating that the electronic control unit handles control information related to vehicle driving, an infotainment attribute indicating that the electronic control unit handles information related to notifying the driver of the vehicle's status, a body attribute indicating that the electronic control unit handles control information for the vehicle's body systems, an ADAS attribute indicating that the electronic control unit handles information related to an advanced driving assistance function that assists or replaces the driver in operating the vehicle, and a connectivity attribute indicating that the electronic control unit handles information obtained from outside the one or more networks.
[0025] This makes it possible to determine whether or not communication is abnormal based on the relationship between the types of information handled by the electronic control units, thereby improving vehicle safety.
[0026] An abnormality detection device according to a fourth aspect of the present disclosure is an abnormality detection device according to the first aspect, wherein the abnormality detection unit determines whether the message received by the communication unit is abnormal based on a combination of the attributes of the electronic control unit that sent the message and the attributes of the electronic control unit that is the destination of the message.
[0027] This makes it possible to determine whether or not communication is abnormal based on the combination of attributes between the source and destination electronic control units of the message, thereby improving vehicle safety.
[0028] An abnormality detection device according to a fifth aspect of the present disclosure is an abnormality detection device according to the first aspect, wherein the abnormality detection unit determines whether the message received by the communication unit is abnormal based on the relationship between the attributes of the electronic control unit that sent the message or the attributes of the electronic control unit that is the destination of the message and the information contained in the message received from the communication unit.
[0029] This makes it possible to determine whether the communication is abnormal, even in the case of an attack that sends a tampered message, thereby improving vehicle safety.
[0030] An anomaly detection device according to a sixth aspect of the present disclosure is the anomaly detection device according to the fifth aspect, wherein the in-vehicle network system exchanges messages via service-oriented communication, and the information contained in the message received from the communication unit is information stored in a message format for SOME / IP communication.
[0031] This makes it possible to determine abnormal communication from the relationship between the information stored in the message format of SOME / IP communication and the attributes of the electronic control unit, thereby improving vehicle safety.
[0032] An abnormality detection device according to a seventh aspect of the present disclosure is the abnormality detection device according to the fourth aspect, further comprising a communication log memory unit that stores messages received by the communication unit, and the abnormality detection unit refers to the messages stored in the communication log memory unit and the ECU attribute memory unit to identify a relationship indicating the combination of attributes of the source and destination electronic control units in which message exchange is occurring, and for newly received messages, determines that messages between electronic control units having attributes of a combination in which message exchange is occurring in the relationship are normal, and determines that messages between electronic control units having attributes of a combination in which message exchange is not occurring in the relationship are abnormal.
[0033] This makes it possible to mechanically generate a definition of abnormal communication using the attributes of the electronic control unit from the communication log, and to automatically update the definition of abnormal communication.
[0034] An anomaly detection device according to an eighth aspect of the present disclosure is the anomaly detection device according to the second or third aspect, wherein the in-vehicle network system exchanges messages via service-oriented communication, and the anomaly detection device further includes a communication log memory unit that stores messages received by the communication unit, and an ECU attribute setting unit that sets the attributes of the electronic control unit stored in the ECU attribute memory unit, and the ECU attribute setting unit refers to the message stored in the communication log memory unit and determines whether the electronic control unit is on the server side or the client side from the message type included in the message, and determines the attributes of the electronic control unit based on the ratio of server communication to client communication.
[0035] This makes it possible to define the attributes of the electronic control unit from the communication log, and to automatically update the attributes of the electronic control unit.
[0036] An abnormality detection device according to a ninth aspect of the present disclosure is an abnormality detection device according to the second or third aspect, further comprising a communication log memory unit that stores messages received by the communication unit, and an ECU attribute setting unit that sets attributes of the electronic control unit stored in the ECU attribute memory unit by referring to the messages stored in the communication log memory unit, and the ECU attribute setting unit determines the attributes of the first electronic control unit according to the frequency of occurrence of the attributes of the electronic control unit with which the first electronic control unit communicates by referring to the messages stored in the communication log memory unit and the ECU attribute memory unit.
[0037] This makes it possible to define the attributes of the electronic control unit from the communication log, and to automatically update the attributes of the electronic control unit.
[0038] An abnormality detection device according to a tenth aspect of the present disclosure is an abnormality detection device according to the eighth or ninth aspect, wherein the ECU attribute setting unit determines the attribute of the electronic control unit when the following conditions are met: a predetermined time has elapsed since the attribute of the electronic control unit was determined, or the communication unit has received a message that causes a change in the communication trends of the one or more networks.
[0039] This makes it possible to detect anomalies according to the state of the latest in-vehicle network, preventing the problem of false positives increasing over time and improving vehicle safety.
[0040] An anomaly detection device according to an eleventh aspect of the present disclosure is the anomaly detection device according to the tenth aspect, wherein the message that causes a change in the communication trends of the one or more networks is a message that occurs when data is obtained and installed from a network or server different from the in-vehicle network system, or a message that occurs when function settings of the in-vehicle network system are changed, deleted, or updated.
[0041] This makes it possible to detect changes in the in-vehicle network, such as acquiring and installing data from an external source or changing the in-vehicle system's function settings, and to reconfigure the attributes of the electronic control unit, thereby reducing false positives in abnormality detection.
[0042] An abnormality detection device according to a twelfth aspect of the present disclosure is the abnormality detection device according to the ninth aspect, wherein the abnormality detection unit calculates the frequency of occurrence of the attributes of the electronic control unit with which the first electronic control unit communicates from the messages stored in the communication log memory unit, and, when referring to the frequency of occurrence of the attributes of the first electronic control unit stored in the ECU attribute memory unit and the frequency deviates by more than a certain standard, judges that the communication of the first electronic control unit is abnormal.
[0043] This makes it possible to detect abnormal communications by capturing trends in the attributes of electronic control units across the entire in-vehicle network, making it possible to detect abnormalities such as a sudden increase in communication volume from a specific electronic control unit.
[0044] An abnormality detection method according to a thirteenth aspect of the present disclosure is an abnormality detection method for detecting an abnormality in an in-vehicle network system composed of two or more electronic control units and one or more networks, which sends and receives messages on the one or more networks, and detects abnormal communication using an attribute possessed by an electronic control unit that is the sender or destination of the message, among attributes possessed by electronic control units set in each of the two or more electronic control units, wherein the attribute indicates the function of the electronic control unit that has the attribute, or the type of information handled by the electronic control unit that has the attribute.
[0045] This makes it possible to incorporate an abnormality detection mechanism into multiple devices, improving vehicle safety.
[0046] An anomaly detection device according to an embodiment of the present disclosure will be described below with reference to the drawings. Each of the embodiments described below represents a preferred specific example of the present disclosure. In other words, the numerical values, shapes, materials, components, component arrangements and connection configurations, steps, and step order shown in the following embodiments are examples of the present disclosure and are not intended to limit the present disclosure. The present disclosure is defined by the claims. Therefore, among the components in the following embodiments, components that are not recited in the independent claims that represent the superordinate concept of the present disclosure are not necessarily required to achieve the objectives of the present disclosure, but are described as components that constitute a more preferred embodiment.
[0047] First Embodiment Hereinafter, a method for detecting an abnormality in an in-vehicle network system in which a plurality of ECUs perform service-oriented communication via Ethernet (registered trademark) will be described.
[0048] 1. Overall Configuration of In-Vehicle Network System Fig. 1 is a diagram showing an example of the overall configuration of an in-vehicle network system according to the present embodiment. In Fig. 1, the in-vehicle network system is mounted on a vehicle 10 and is configured to be able to communicate with an OTA server 30 via an external network 20.
[0049] The in-vehicle network system includes a TCU (Telematics Control Unit) 100, a central ECU 200, a user interface ECU 300, an abnormality detection ECU 400, a zone ECU 500a, a zone ECU 500b, a brake control ECU 600a, a vehicle speed detection ECU 600b, an electric lock control ECU 600c, an electric lock opening / closing ECU 600d, and a camera ECU 600e.
[0050] Although not shown in FIG. 1, the vehicle 10 may include many other ECUs.
[0051] The central ECU 200 is communicably connected to the TCU 100, the user interface ECU 300, the abnormality detection ECU 400, the zone ECU 500a, the zone ECU 500b, and the camera ECU 600e via Ethernet.
[0052] The zone ECU 500a is communicably connected to a brake control ECU 600a and a vehicle speed detection ECU 600b via a controller area network (CAN) 1.
[0053] The zone ECU 500b is communicably connected to the electric lock control ECU 600c and the electric lock opening / closing ECU 600d via the CAN2.
[0054] The network to which the zone ECUs 500a and 500b are connected is not limited to a CAN, and may be other networks such as FlexRay, a dedicated communication line, or wireless communication.
[0055] The OTA server 30 distributes system update files for the vehicle 10 and also has a platform function for in-vehicle applications.
[0056] The TCU 100 includes a communication interface for communicating with the external network 20. The TCU 100 transmits a frame transmitted from the central ECU 200 to the OTA server 30 via the external network 20. The TCU 100 also receives a frame transmitted from the OTA server 30 and transmits the frame to the central ECU 200.
[0057] The central ECU 200 is an ECU that plays a central role in the in-vehicle network system, and various applications run on it to realize various functions of the vehicle 10. The central ECU 200 has a switching function and transfers frames received via Ethernet to the appropriate ECU.
[0058] Furthermore, the central ECU 200 uses a switch function to transfer the received frame to the abnormality detection ECU 400. Furthermore, upon receiving the detection result frame from the abnormality detection ECU 400, the central ECU 200 transfers the notification result to the user interface ECU 300.
[0059] Furthermore, the central ECU 200 transmits and receives frames to and from the TCU 100 regarding the acquisition of in-vehicle applications, update programs, and the like.
[0060] In addition, the central ECU 200 can execute applications that perform advanced processing such as autonomous driving, and communicates information necessary for performing the advanced processing, or control information for performing the advanced processing, with other ECUs via Ethernet or CAN.
[0061] The user interface ECU 300 provides a user interface for controlling the vehicle 10. Specifically, the user interface ECU 300 is communicably connected to devices such as a controller for controlling steering, a controller for controlling acceleration / deceleration, switches, input devices such as a touch panel, a USB port, and a Wi-Fi module. The user interface ECU accepts user operations via these devices and notifies the central ECU 200 of the contents of the user operations.
[0062] The abnormality detection ECU 400 is communicatively connected to the central ECU 200, acquires frames received from the central ECU 200, and detects whether or not an abnormality exists in the frames. The abnormality detection ECU 400 transmits the detection result of the abnormality detection to the central ECU 200.
[0063] The zone ECU 500a uses its switch function to forward received frames to the appropriate ECU. Furthermore, the zone ECU 500a converts CAN frames received via CAN1 into Ethernet frames when forwarding the frames to the appropriate ECU via Ethernet. Furthermore, the zone ECU 500a converts Ethernet frames received via Ethernet into CAN frames when forwarding the frames to the appropriate ECU on CAN1. The zone ECU 500b has a similar configuration to the zone ECU 500a, and therefore its description will be omitted. If the network to which the zone ECUs 500a and 500b are connected is one of FlexRay, dedicated communication line, and wireless communication networks instead of CAN, the zone ECUs 500a and 500b can convert frames of the one of the FlexRay, dedicated communication line, and wireless communication networks into Ethernet frames in the same way as CAN. In other words, if the zone ECUs 500a and 500b are communicatively connected to two different types of networks, they can convert frames from one of the two different types to the other.
[0064] The brake control ECU 600 a controls the brakes provided in the vehicle 10 .
[0065] The vehicle speed detection ECU 600b measures the speed of the vehicle 10 using a sensor.
[0066] The electric lock control ECU 600c controls the opening and closing of the electric lock provided in the vehicle 10.
[0067] The electric lock ECU 600d opens and closes the electric lock provided in the vehicle 10.
[0068] The camera ECU 600e acquires images from a camera equipped in the vehicle 10.
[0069] 2. Configuration of TCU 100 Fig. 2 is a diagram showing an example of the configuration of the TCU in this embodiment. In Fig. 2, the TCU 100 includes an external communication unit 101, a conversion unit 102, and an internal communication unit 103.
[0070] The external communication unit 101 is a communication interface that communicates with the external network 20, and communicates with the OTA server 30 via the external network 20. The external communication unit 101 exchanges information with the conversion unit 102.
[0071] The internal communication unit 103 is a communication interface and communicates with the central ECU 200 via Ethernet. The internal communication unit 103 notifies the conversion unit 102 of a frame received from the central ECU 200, and transmits the frame via Ethernet upon receiving a frame transmission request from the conversion unit 102.
[0072] The conversion unit 102 converts data that requires the transfer of a message received from either the internal communication unit 103 or the external communication unit 101 into a predetermined format via the internal communication unit 103 and the external communication unit 101, and transmits it to the other unit.
[0073] 3 is a diagram showing an example of the configuration of the central ECU 200 according to the present embodiment. In FIG. 3, the central ECU 200 includes a communication unit 201, a host OS unit 202, and a guest OS unit 203.
[0074] The communication unit 201 is communicably connected to the TCU 100, the user interface ECU 300, the abnormality detection ECU 400, the zone ECU 500a, the zone ECU 500b, and the camera ECU 600e via Ethernet, and transfers frames using a switch function depending on the content of the received frame. The communication unit 201 also transfers received frames to the abnormality detection ECU 400 to monitor the received frames. The communication unit 201 also transmits and receives information to and from the host OS unit 202.
[0075] The host OS unit 202 is a main operating system (OS) of the central ECU 200. The host OS unit 202 exchanges information with the communication unit 201 and notifies the guest OS unit 203 of the contents of the communication.
[0076] The host OS unit 202 also has the authority to change the system settings of the guest OS unit 203. The host OS unit 202 acquires operation information indicating a user operation accepted by the user interface ECU 300 via the communication unit 201, and transmits a message to the TCU 100 to download an in-vehicle application that has been instructed to be downloaded based on the operation information from the OTA server 30 to the guest OS unit 203. The host OS unit 202 also acquires operation information indicating a user operation accepted by the user interface ECU 300 via the communication unit 201, and erases a guest OS that has been instructed to be deleted based on the operation information, and installs another guest OS. In this way, the host OS unit 202 can perform system management.
[0077] Furthermore, in order to realize a secure host OS unit 202, changes to the functions of the host OS unit 202 from the user interface ECU 300 are restricted, except for system updates via OTA.
[0078] The guest OS unit 203 is an OS on which applications of the central ECU 200 run. The guest OS unit 203 has, as an example of an application, a function of acquiring video data from the camera ECU 600e via the communication unit 201, and requesting the brake control ECU 600a to decelerate the vehicle 10 if the vehicle 10 is within a certain distance from an object recognized as a person in the video data.
[0079] Although the first embodiment of the present disclosure illustrates an example in which one guest OS unit 203 is provided on the host OS unit 202, there may be two or more guest OS units 203. The guest OS unit 203 may be host-type virtualization software or hypervisor-type virtualization software.
[0080] 4. Configuration of the User Interface ECU 300 Fig. 4 shows an example of the configuration of the user interface ECU in this embodiment. In Fig. 4, the user interface ECU 300 includes a communication unit 301 and an external device connection unit 302.
[0081] The communication unit 301 is communicably connected to the central ECU 200, and exchanges information with the central ECU 200. The communication unit 301 mainly serves to notify the central ECU 200 of information received from the external device connection unit 302.
[0082] The external device connection unit 302 is communicably connected to a device operated by a user or an interface of an externally connected device, and notifies the communication unit 301 of information acquired from these devices.
[0083] The externally connected device may be, for example, a controller for controlling steering, a controller for controlling acceleration / deceleration, an input device such as a switch, a touch panel, etc. Furthermore, the externally connected device may be, for example, a communication interface device such as a USB port, a Wi-Fi module, a diagnostic port, or Bluetooth.
[0084] 5. Configuration of the abnormality detection ECU 400 Fig. 5 is a diagram showing an example of the configuration of the abnormality detection ECU in this embodiment. In Fig. 5, the abnormality detection ECU 400 includes a communication unit 401, an abnormality detection unit 402, a communication log generation unit 403, a communication log storage unit 404, an ECU attribute setting unit 405, an ECU attribute storage unit 406, and an abnormality detection rule storage unit 407.
[0085] The communication unit 401 is communicatively connected to the central ECU 200, and exchanges information with the central ECU 200. The communication unit 401 receives frames transmitted from the central ECU 200, and transfers the received frames to the abnormality detection unit 402 and the communication log generation unit 403.
[0086] Furthermore, when the communication unit 401 is notified of the abnormality determination result of the frame by the abnormality detection unit 402, the communication unit 401 transmits the frame including the abnormality determination result to the central ECU 200.
[0087] The anomaly detection unit 402 receives a frame transferred from the communication unit 401, and if the received frame complies with a service-oriented communication protocol, performs anomaly detection on the received frame.
[0088] When an abnormality is detected, the abnormality detection unit 402 creates a frame that stores the detection result, notifies the communication unit 401 , and transmits the frame to the central ECU 200 .
[0089] In an anomaly detection process, the anomaly detection unit 402 acquires an ECU attribute corresponding to an IP address (source IP address or destination IP address) included in a received frame by referencing the ECU attribute storage unit 406. In addition, in an anomaly detection process, the anomaly detection unit 402 acquires an anomaly detection rule to be used for the anomaly detection from the anomaly detection rule storage unit 407. The method of anomaly detection by the anomaly detection unit 402 will be described later.
[0090] Furthermore, the anomaly detection unit 402 determines whether the frame transferred from the communication unit 401 includes information that will cause a change in the communication tendency of the in-vehicle network. If the transferred frame includes information that will cause a change in the communication tendency of the in-vehicle network, the anomaly detection unit 402 references the destination IP address (destination IP address) of the frame and turns on an attribute setting flag corresponding to the IP address in the ECU attribute storage unit 406. Here, a frame that includes information that will cause a change in the communication tendency of the in-vehicle network is a frame that is generated when an application is downloaded to the guest OS unit 203, a frame that is generated when an update file is sent to the ECU, or the like. In other words, a frame (message) that includes information that will cause a change in the communication tendency of the in-vehicle network is a message that is generated when data is acquired and installed from a network or server other than the in-vehicle network, or a message that is generated when a function setting of the in-vehicle system is changed, deleted, or updated.
[0091] The communication log generation unit 403 receives frames transferred from the communication unit 401, extracts some information contained in the received frames to create a communication log, and adds the created communication log to the communication log storage unit 404. The communication log generation unit 403 also has a function of measuring time in order to add a timestamp to the communication log indicating the time when the communication log was created.
[0092] The communication log storage unit 404 stores the communication logs transferred from the communication log generation unit 403. Details of the communication logs stored in the communication log storage unit will be described later.
[0093] The ECU attribute setting unit 405 acquires the communication log from the communication log storage unit 404, and for each IP address, infers what communication tendencies are observed and what role attributes the ECU has, or what information is handled and what domain attributes the ECU has, and stores the inferred results in the ECU attribute storage unit 406.
[0094] The communication tendency of the ECU may change due to factors such as an OTA system update, termination of an in-vehicle subscription service, or a change in vehicle settings by the driver, so the role attributes and domain attributes of the ECU at a specific timing are verified. Here, the specific timing may be when the abnormality detection unit 402 receives a system shutdown notification, or any timing during the night when the user is not operating the vehicle 10. A detailed method for setting the role attributes and domain attributes of the ECU will be described later.
[0095] The ECU attribute storage unit 406 stores the ECU attribute for each IP address estimated by the ECU attribute setting unit 405. Here, the ECU attribute represents both the role attribute of the ECU and the domain attribute of the ECU.
[0096] The role attribute of an ECU is an attribute that indicates the function of the ECU operating in the in-vehicle network system from the perspective of the role that the ECU plays in the vehicle 10. The role attribute of an ECU is classified into three types: a sensor attribute (sensor) that indicates that the ECU has a function of sensing information inside and outside the vehicle, a brain attribute (brain) that indicates that the ECU has a function of processing the sensed information and giving control instructions, and an actuator attribute (actuator) that indicates that the ECU has a function of performing control in accordance with control instructions.
[0097] The domain attribute of an ECU indicates the type of information handled by the ECU in the in-vehicle network system from the perspective of the role of data transmitted to the in-vehicle network. The domain attributes of an ECU are classified into five categories: a powertrain attribute (powertrain) indicating that the ECU handles control information related to driving of the vehicle 10, such as driving, turning, and stopping; an infotainment attribute (infotainment) indicating that the ECU handles information related to notifying the driver (operator) of the vehicle 10's status; a body attribute (body) indicating that the ECU handles control information related to the body system of the vehicle 10; an ADAS attribute (ADAS) indicating that the ECU handles information related to advanced driving assistance functions that assist or replace the driver (operator) in operating the vehicle, such as camera images and sensing information; and a connectivity attribute (connectivity) indicating that the ECU handles information obtained from one or more networks outside the in-vehicle network, i.e., from an external network 20. Details of the ECU attribute information will be described later.
[0098] The anomaly detection rule storage unit 407 stores anomaly determination rules required when the anomaly detection unit 402 determines whether a frame is anomaly. Details of the anomaly determination rules stored in the anomaly determination rule storage unit 407 will be described later.
[0099] 6 is a diagram showing an example of the configuration of a zone ECU in this embodiment. The zone ECU 500a includes a host unit 501 and a communication unit 502. The zone ECU 500b is connected to a different ECU, but has the same configuration as the zone ECU 500a, and therefore its description will be omitted.
[0100] The host unit 501 is the main part of the zone ECU 500a and is realized by a CPU and memory, and executes processing in accordance with the content of communication received from the communication unit 502. For example, when a user of the vehicle 10 backs up (parks backwards), the zone ECU 500a receives frames notified from the camera ECU 600e and the vehicle speed detection sensor ECU 600b. Based on the image of the area behind the vehicle 10 and the speed of the vehicle 10 obtained from the received frames, the zone ECU 500a transmits a control message to the brake control ECU 600a to avoid contact with an obstacle.
[0101] The communication unit 502 is communicatively connected to the central ECU 200 via Ethernet, and is communicatively connected to the brake control ECU 600a and the vehicle speed detection ECU 600b via CAN 1. The communication unit 502 has a switch function that forwards frames according to the contents of the received frames.
[0102] The communication unit 502 also has a function of converting a CAN frame into an Ethernet frame and an Ethernet frame into a CAN frame.
[0103] 7. Configuration of the Brake Control ECU 600a Fig. 7 is a diagram showing an example of the configuration of the brake control ECU in this embodiment. The vehicle speed detection ECU 600b, the electric lock control ECU 600c, the electric lock opening / closing ECU 600d, and the camera ECU 600e have the same configuration as the brake ECU 600a, so their description will be omitted.
[0104] In FIG. 7, the brake ECU 600 a includes a communication unit 601 , a host unit 602 , and an external device connection unit 603 .
[0105] The communication unit 601 is a communication interface that communicates with a network (CAN1) and is communicatively connected to the CAN 1. The communication unit 601 receives frames flowing through the network, notifies the host unit 602 of the received frames, and transmits frames to the CAN 1 upon receiving a transmission request from the host unit 602.
[0106] The host unit 602 generates a frame including information acquired from an externally connected device such as a sensor or an actuator, and requests the communication unit 601 to transmit the generated frame. The host unit 602 also performs control processing of the externally connected device based on the information in the frame notified from the communication unit 601.
[0107] The external device connection unit 603 performs control operations on the external device based on the control information notified from the host unit 602, or converts the control operations on the external device into control information and notifies the host unit 602 of the control information.
[0108] 8. SOME / IP Message Format SOME / IP defines four communication methods: Request / Response, Fire / Forget, Events, and Get / Set / Notifier, and service-oriented communication is realized by combining these methods. SOME / IP provides a method for establishing a session with a communication partner, called Service Discovery (SD).
[0109] 8 is a diagram showing an example of a format of a SOME / IP SD message in this embodiment. The message format is stored in the payload section of the Ethernet.
[0110] In FIG. 8, the message format is made up of a SOME / IP header and a SOME / IP SD, and each line is 32 bits long.
[0111] The SOME / IP header includes a Message ID, a Length, a Request ID, a Protocol Version, an Interface Version, a Message Type, and a Return Code.
[0112] The Message ID is 0xFFFF8100.
[0113] The Length field stores the number of bytes of data following the Length field.
[0114] The Request ID stores a numeric value that is a combination of the Client ID and the Session ID.
[0115] The Protocol Version is 0x01, the Interface Version is 0x01, the Message Type is 0x02, and the Return Code is 0x00.
[0116] The SOME / IP SD includes Flags, Reserved, Length of Entries Array in Bytes, Entries Array, Length of Options Array in Bytes, and Options Array. The Length of Entries Array in Bytes stores the number of bytes in the Entry Array. The Length of Options Array in Bytes stores the number of bytes in the Options Array.
[0117] FIG. 9 is a diagram showing an example of a SOME / IP SD message in this embodiment.
[0118] The Entry Array includes Index 1st Options, Index 2nd options, # of op1, # of op2, Service ID, Instance ID, Major Version, TTL, and Minor Version.
[0119] The Options Array includes Length, Type, Reserved, IPv4 Address, Reserved, L4-Proto, and Port Number.
[0120] In FIG. 9, SOME / IP SD is a message indicating that the Service ID is 0x1000 and that the service with the Service ID of 0x1000 can be provided.
[0121] The Flags field is set to 0x80, which indicates the Reboot Flag. The Reserved field is set to 0.
[0122] The Length of Entries Array in Bytes is set to 16 bytes.
[0123] Type can be set to 0x00 or 0x01, where 0x00 means "Find" and 0x01 means "Offer." "Find" is used when a client ECU receiving a service requests the provision of a required service, and "Offer" is used when a server ECU providing a service notifies the server of the services it can provide. In FIG. 9, Type is set to 0x01.
[0124] Index 1st options indicates the position of the first option, and is set to 0 in FIG. 9, which indicates the beginning of the option area.
[0125] Index 2nd options indicates the position of the second option, and is set to 0 in FIG.
[0126] #of opt1 is a field indicating the number of option 1s, and is set to 1 in FIG.
[0127] #of opt2 is a field indicating the number of option 2, and in FIG. 9, 0 is set, indicating that option 2 is not used.
[0128] The Service ID is a field that indicates an ID that indicates the type of service, and in FIG. 9, 0x1000 is set.
[0129] The Instance ID is an ID indicating the instance of the service, and is shown to be an instance of 0x0001 in FIG.
[0130] The Major Version is used for version management of the service, and is set to 0x01 in FIG.
[0131] TTL is a field for setting the expiration date (seconds) of the service, and is set to 0xFFFF in Fig. 9. 0xFFFF means that the service is valid until the next startup timing of the ECU.
[0132] The Minor Version is used for version management of the service, and is set to 0x00000002 in FIG.
[0133] Next, in the Option area, the length of the Option area is set in Length of Options Array in Byte, and in FIG. 9, 12 bytes is set.
[0134] The value set for Length is determined depending on the type of option. Fig. 9 shows an example of communication using IPv4, with Length set to 9, Type set to 0x04, and Reserved set to 0x00.
[0135] The IPv4 address is the IP address of the server, and in FIG. 9, 192.168.0.1 is set.
[0136] The Reserved field is set to 0. The L4-Proto field is set to 0x11, which indicates that User Datagram Protocol (UDP) is used.
[0137] Finally, the port number is set, and in FIG. 9, it is shown to be port number 35000.
[0138] 9. Example of a communication log stored in the communication log storage unit Fig. 10 is a diagram showing an example of a communication log stored in the communication log storage unit. In Fig. 10, the communication log includes a timestamp, a source IP address, a destination IP address, a source port, a destination port, a transport protocol, a service ID, a method ID, a message type, and a message size. Each line in Fig. 10 represents one of the SOME / IP messages transferred from the communication unit 401 to the communication log generation unit 403.
[0139] The timestamp included in the communication log is the time acquired when the communication log is generated by the communication log generation unit 403. Information other than the timestamp included in the communication log is part of the information extracted by the communication log generation unit 403 from the Ethernet frame received.
[0140] The source IP address is extracted from the source IP address field contained in the Ethernet frame. The destination IP address is extracted from the destination IP address field contained in the Ethernet frame. The source port is extracted from the source port contained in the Ethernet frame. The destination port is extracted from the destination port contained in the Ethernet frame. The transport protocol is extracted from the protocol contained in the Ethernet frame. The service ID is extracted from Service ID of the SOME / IP message format contained in the Ethernet frame. The merit ID is extracted from Method ID of the SOME / IP message format contained in the Ethernet frame. The message type is extracted from Message Type of the SOME / IP message format contained in the Ethernet frame. The message size is extracted from Length of the SOME / IP message format contained in the Ethernet frame.
[0141] 10. Example of ECU attribute information stored in the ECU attribute storage unit Figure 11 is a diagram showing an example of ECU attribute information stored in the ECU attribute storage unit. In Figure 11, the ECU attribute information includes an IP address, an ECU attribute, an attribute setting flag, a date and time when the flag was set to OFF, and a date and time when the flag was set to ON. Furthermore, the ECU attribute includes two items: an ECU role attribute and an ECU domain attribute. The ECU role attribute includes three attributes: sensor, brain, and actuator, and the ECU domain attribute includes five attributes: connectivity, powertrain, ADAS, body, and infotainment.
[0142] The IP address is a source IP address included in a frame received by the abnormality detection unit 402. When the abnormality detection unit 402 receives a frame including an IP address that is not recorded in the ECU attribute storage unit 406, the abnormality detection unit 402 adds a row of the new IP address to the ECU attribute information. At this time, in the added row, as initial values, all 0 is recorded for the ECU attribute and the date and time when the flag OFF was set, ON is recorded for the attribute setting flag, and the timestamp included in the received frame is recorded for the date and time when the flag ON was set.
[0143] The ECU attributes are set by the ECU attribute setting unit 405. The method of setting the ECU attributes by the ECU attribute setting unit 405 will be described later. The ECU attributes are used by the abnormality detection unit 402 to refer to the attributes of the ECU when detecting an abnormality.
[0144] The attribute setting flag is a flag used by the ECU attribute setting unit 405 to determine whether or not to reset the ECU attributes. When the attribute setting flag is ON, it indicates that the ECU attribute setting unit 405 will reset the ECU attributes at the next opportunity, and when the attribute setting flag is OFF, it indicates that the ECU attribute setting unit 405 will not reset the ECU attributes at the next opportunity.
[0145] The ECU attribute setting unit 405 sets the attribute setting flag to OFF when the ECU attribute setting process is completed. When the ECU attribute setting unit 405 detects that a predetermined time has elapsed since the flag was set to OFF, the ECU attribute setting unit 405 sets the attribute setting flag to ON. Alternatively, when the abnormality detection unit 402 detects a frame including information that will cause a change in the communication tendency of the ECU, the ECU attribute setting unit 405 sets the attribute setting flag to ON.
[0146] The date and time when the flag is set to OFF is set in UNIX time by the ECU attribute setting unit 405. If a value has already been recorded as the date and time when the flag is set to OFF, a value with a larger UNIX time is set. This value is referenced by the ECU attribute setting unit 405 at a specific timing and is used to determine whether a predetermined time or more has passed since the recorded UNIX time.
[0147] The flag ON setting date and time is set in UNIX time as the time when the attribute setting flag was set to ON by the ECU attribute setting unit 405. If a value has already been recorded as the flag ON setting date and time, a value with a larger UNIX time is set. This value is referenced by the ECU attribute setting unit 405 when setting the ECU attribute, and is used to obtain the communication log required for attribute setting from the communication log storage unit 404.
[0148] 11. Abnormality Detection Rules Based on ECU Attributes Figure 12 is a diagram showing an example of an abnormality detection rule using ECU attributes stored in the abnormality detection rule storage unit. In Figure 12, the abnormality detection rule is used to determine whether communication of a target frame is normal or abnormal. The abnormality detection rule indicates whether the combination of the ECU attribute of the source ECU and the ECU attribute of the destination ECU is OK or NG. In the abnormality detection rule, an OK indication indicates that communication between a combination of a source ECU and a destination ECU is normal, and an NG indication indicates that communication between a combination of a source ECU and a destination ECU is abnormal. In the abnormality detection rule, if communication with an OK combination occurs, the communication is determined to be normal, and if communication with an NG combination occurs, the communication is determined to be abnormal.
[0149] In Figure 12, for example, if the domain attribute of the source ECU is connectivity and the domain attribute of the destination ECU is connectivity, the target frame is determined to be normal in the following combinations: the role attribute of the source ECU is sensor and the role attribute of the destination ECU is brain; the role attribute of the source ECU is brain and the role attributes of the destination ECU are sensor, brain, and actuator; and the role attribute of the source ECU is actuator and the role attribute of the destination ECU is brain.
[0150] 12, when the domain attribute of the destination ECU is Body and the role attribute is Actuator, the target frame is determined to be normal when the source ECU's domain attribute is ADAS and the role attribute is Brain, and when the source ECU's domain attribute is Body and the role attribute is Brain. This is because when an ECU with a domain attribute of Body and a role attribute of Actuator receives a control command, such as opening and closing an electric lock or opening and closing an airbag, there are cases where the ECU that detects the operation of the car key and controls the electric lock sends the control command, and cases where the ECU that controls autonomous driving detects danger to the driver and sends a control command to open the airbag.
[0151] 12, a frame in which the domain attribute of the source ECU is connectivity and the domain attribute of the destination ECU is powertrain is defined as an abnormal communication because there is a risk that the vehicle may be remotely controlled if the connectivity ECU, which handles external communication information, communicates with the powertrain ECU, which handles vehicle driving control information.
[0152] 12. Sequence for Changing ECU Attributes Figure 13 is a diagram showing an example of a sequence for changing ECU attributes in this embodiment. In Figure 13, when a user of vehicle 10 operates the touch panel of user interface ECU 300 to uninstall an ADAS-related application installed in guest OS unit 203 of central ECU 200 and then install an infotainment-related application, abnormality detection ECU 400 detects a change in the in-vehicle network and resets ECU attribute information used for abnormality detection.
[0153] (S101) The user interface ECU 300 receives an operation from the user and requests the guest OS unit 203 of the central ECU 200 to uninstall the ADAS-related application that has been installed therein and install the infotainment-related application.
[0154] (S102) The central ECU 200 uninstalls the ADAS-related application (ADAS app) from the guest OS unit 203.
[0155] (S103) The central ECU 200 requests the OTA server 30 to transmit an installer for an infotainment-related application (infotainment app) to the guest OS unit 203.
[0156] (S104) The OTA server 30 transmits a frame including an installer to the guest OS unit 203 of the central ECU 200.
[0157] (S105) The central ECU 200 transfers the frame received in step S104 to the abnormality detection ECU 400.
[0158] (S106) The abnormality detection unit 402 of the abnormality detection ECU 400 extracts the IP address of the central ECU stored in the transferred frame. Furthermore, the abnormality detection unit 402 references the IP addresses stored in the ECU attribute storage unit 406, and if the extracted IP address is included, sets the attribute setting flag corresponding to the IP address to ON.
[0159] (S107) The central ECU 200 installs the infotainment application using the received installer.
[0160] 13. Flowchart of Operation of Abnormality Detection ECU 400 When Receiving a Frame FIG. 14 is a diagram showing an example of a flowchart of operation of abnormality detection ECU 400 when receiving a frame in this embodiment.
[0161] (S201) The communication unit 401 receives a frame transferred from the central ECU 200.
[0162] (S202) The ECU attribute setting unit 405 determines whether the source IP address and the destination IP address stored in the frame received in step S201 are stored in the ECU attribute storage unit 406. If at least one of the source IP address and the destination IP address is not stored in the ECU attribute storage unit 406 (No in S202), the ECU attribute setting unit 405 executes the process of step S203. If both the source IP address and the destination IP address are stored in the ECU attribute storage unit 406 (Yes in S202), the ECU attribute setting unit 405 executes the process of step S204.
[0163] (S203) The ECU attribute setting unit 405 newly stores in the ECU attribute storage unit 406 the source IP address and destination IP address of the received frame that are not stored in the ECU attribute storage unit 406, and sets the attribute setting flag to ON. Furthermore, the ECU attribute setting unit 405 acquires the date and time in UNIX time, and stores the acquired UNIX time in the ECU attribute storage unit 406 as the time when the attribute setting flag was set to ON.
[0164] (S204) The ECU attribute setting unit 405 determines whether the source IP address of the received frame is a specific IP address. If the source IP address of the received frame is a specific IP address (Yes in S204), the ECU attribute setting unit 405 executes the process of step S205. If the source IP address of the received frame is not a specific IP address (No in S204), the ECU attribute setting unit 405 executes the process of step S206. A frame transmitted from a specific IP address is a frame that includes information that causes a change in the communication trend of the in-vehicle network. Specifically, this is a frame that is generated when an application is downloaded to the guest OS unit 203 or a frame that is generated when an update file is transmitted to the ECU.
[0165] (S205) For the destination IP address of the received frame, the ECU attribute setting unit 405 turns ON the attribute setting flag of the corresponding IP address in the ECU attribute storage unit 406. Furthermore, the ECU attribute setting unit 405 acquires the date and time in UNIX time, and stores the acquired UNIX time in the ECU attribute storage unit 406 as the time when the attribute setting flag was turned ON.
[0166] (S206) The abnormality detection unit 402 determines whether the received frame is abnormal using the ECU attributes. Details of the abnormality detection process using the ECU attributes will be described later.
[0167] (S207) The abnormality detection unit 402 stores the received frame in the communication log storage unit 404.
[0168] 14. Flowchart of ECU Attribute Setting Process Figure 15 is an example of a flowchart related to ECU attribute setting in this embodiment. The ECU attribute setting unit 405 sets attributes for each ECU IP address. The ECU attribute setting process is performed at specific times, such as when the vehicle system is shut down or at any time during the night when the vehicle is not being driven, and updates the ECU attribute information used in the anomaly detection process, making it possible to distinguish between normal communication that occurs due to changes in communication trends in the in-vehicle network and anomalous communication by an attacker.
[0169] (S301) When starting processing, the ECU attribute setting unit 405 acquires a start date and time in UNIX time. For each IP address stored in the ECU attribute storage unit 406 whose attribute setting flag is set to OFF, the ECU attribute setting unit 405 references the date and time when the flag was set to OFF and calculates the difference between the recorded UNIX time and the start date and time. If the calculated difference is equal to or greater than a predetermined time (i.e., if more than a predetermined time has passed), the ECU attribute setting unit 405 sets the attribute setting flag of the target IP address to ON, acquires the date and time in UNIX time, and stores the date and time acquired when the flag was set to ON in the ECU attribute storage unit 406.
[0170] (S302) The ECU attribute setting unit 405 determines whether or not there is an IP address whose attribute setting flag is ON among the IP addresses stored in the ECU attribute storage unit 406. If there is an IP address whose attribute setting flag is ON (Yes in S302), the ECU attribute setting unit 405 executes step S303. If there is no IP address whose attribute setting flag is ON (No in S302), the ECU attribute setting unit 405 ends the ECU attribute setting process.
[0171] (S303) The ECU attribute setting unit 405 acquires ECU attribute information of the IP address for which the attribute setting flag in the ECU attribute storage unit 406 is set to ON.
[0172] (S304) The ECU attribute setting unit 405 sequentially selects one IP address from the ECU attribute information of the acquired IP addresses.
[0173] (S305) The ECU attribute setting unit 405 acquires the date and time when the flag of the selected IP address was set to ON.
[0174] (S306) ECU attribute setting unit 405 acquires a set of communication logs for the selected IP address from communication log storage unit 404. The set of communication logs is a set of communication logs that, among the communication logs stored in communication log storage unit 404, include the selected IP address in the source IP address or destination IP address and have a timestamp recorded after the date and time when the flag for the selected IP address was set to ON.
[0175] (S307) The ECU attribute setting unit 405 determines whether the acquired set of communication logs includes a predetermined number or more of communication logs. If the acquired set of communication logs includes a predetermined number or more of communication logs (Yes in S307), the ECU attribute setting unit 405 executes the process of step S308. If the acquired set of communication logs does not include a predetermined number or more of communication logs (No in S307), the ECU attribute setting unit 405 executes the process of step S311.
[0176] (S308) The ECU attribute setting unit 405 sets the role attribute of the ECU using the selected IP address and the set of acquired communication logs. Details will be described later.
[0177] (S309) The ECU attribute setting unit 405 sets the domain attribute of the ECU using the selected IP address and the set of acquired communication logs. Details will be described later.
[0178] (S310) The ECU attribute setting unit 405 turns OFF the attribute setting flag for the selected IP address in the ECU attribute storage unit 406. The ECU attribute setting unit 405 acquires the date and time in UNIX time, and stores the acquired date and time as the date and time when the attribute setting flag was turned OFF.
[0179] (S311) The ECU attribute setting unit 405 determines whether or not all of the target ECU attribute information has been selected. If all of the target ECU attribute information has been selected (Yes in S311), the ECU attribute setting unit 405 ends the processing. If all of the target ECU attribute information has not been selected (No in S311), the ECU attribute setting unit 405 executes the processing of step S304.
[0180] 15. Flowchart of ECU Role Attribute Setting Fig. 16 is an example of a flowchart relating to the setting of the role attributes of an ECU by the ECU attribute setting unit 405 in this embodiment.
[0181] (S401) The ECU attribute setting unit 405 checks, for the set of acquired communication logs, whether the selected IP address is included in the source IP address or the destination IP address, and what the message type is. If the message type is Notification, the ECU attribute setting unit 405 determines that the source IP address is on the server side and the destination IP address is on the client side. If the message type is Request, the ECU attribute setting unit 405 determines that the source IP address is on the client side and the destination IP address is on the server side. If the message type is Response, the ECU attribute setting unit 405 determines that the source IP address is on the server side and the destination IP address is on the client side.
[0182] Then, the ECU attribute setting unit 405 calculates the ratio of the communication logs on the server side to the communication logs on the client side for the selected IP address in the set of acquired communication logs, and further counts the number of times a message with a message type of Request has been received and the number of times a message with a message type of Response has been sent for the selected IP address.
[0183] (S402) The ECU attribute setting unit 405 determines whether or not 90% or more of the acquired set of communication logs are server-side communication logs. If 90% or more of the communication logs are server-side communication logs (Yes in S402), the ECU attribute setting unit 405 executes the process of step S403. If 90% or more of the communication logs are server-side communication logs (No in S402), the ECU attribute setting unit 405 executes the process of step S405.
[0184] (S403) The ECU attribute setting unit 405 determines whether the number of times a request message was received and the number of times a response message was transmitted match for the selected IP address in the acquired set of communication logs. If the number of times a request message was received and the number of times a response message was transmitted match (Yes in S403), the ECU attribute setting unit 405 executes the process of step S404. If the number of times a request message was received and the number of times a response message was transmitted do not match (No in S403), the ECU attribute setting unit 405 executes the process of step S406.
[0185] (S404) The ECU attribute setting unit 405 determines that the ECU of the selected IP address has the role of a sensor, and sets 1 to the sensor of the ECU role attribute of the selected IP address in the ECU attribute storage unit 406.
[0186] (S405) The ECU attribute setting unit 405 determines whether or not 70% or more of the communications are client-side in the acquired set of communication logs. If 70% or more of the communications are client-side (Yes in S405), the ECU attribute setting unit 405 executes the process of step S407. If 70% or more of the communications are not client-side (No in S405), the ECU attribute setting unit 405 executes the process of step S406.
[0187] (S406) The ECU attribute setting unit 405 determines that the ECU of the selected IP address has the role of actuator, and sets 1 to actuator in the ECU role attribute of the selected IP address in the ECU attribute storage unit 406.
[0188] (S407) The ECU attribute setting unit 405 determines that the ECU of the selected IP address has the role of brain, and sets 1 to the brain of the ECU role attribute of the selected IP address in the ECU attribute storage unit 406.
[0189] In the process of step S402, it is determined whether or not 90% or more of the acquired set of communication logs are server-side communication logs, and in the process of step S405, it is determined whether or not 70% or more of the acquired set of communication logs are client-side communications, but the percentages used as thresholds in steps S402 and S405 are not limited to 90% and 70%, respectively. These percentages as thresholds may be appropriately adjusted depending on the communication tendency of the vehicle model.
[0190] 16. Flowchart of ECU Domain Attribute Setting Fig. 17 is an example of a flowchart relating to the setting of ECU domain attributes by the ECU attribute setting unit in this embodiment.
[0191] (S501) The ECU attribute setting unit 405 obtains the domain attributes of the IP addresses of the communication destinations of the selected IP addresses from the ECU attribute storage unit 406 for the set of obtained communication logs, counts the number of occurrences of each domain attribute, specifically, the five domain attributes of connectivity, powertrain, ADAS, body, and infotainment, and extracts the domain attribute that appears most frequently.
[0192] (S502) The ECU attribute setting unit 405 excludes from the acquired set of communication logs any communication log for which the attribute setting flag of the IP address of the communication destination of the selected IP address is ON, and, similar to step S501, counts the number of occurrences of each domain attribute and extracts the domain attribute with the highest number of occurrences. Note that the IP address of the communication destination of the selected IP address is the IP address of the destination that is paired with the IP address of the source when the ECU of the selected IP address is the IP address of the sender, and is the IP address of the source that is paired with the IP address of the destination when the ECU of the selected IP address is the IP address of the destination.
[0193] (S503) The ECU attribute setting unit 405 determines whether the domain attribute extracted in step S501 is the same as the domain attribute extracted in step S502. If they match (Yes in S503), the ECU attribute setting unit 405 executes step S504. If they do not match (No in S503), the ECU attribute setting unit 405 executes step S505.
[0194] (S504) The ECU attribute setting unit 405 sets the domain attribute extracted in step S501 as the domain attribute of the selected IP address, and sets the domain attribute extracted in step S501 among the ECU domain attributes of the selected IP address to 1 in the ECU attribute storage unit 406.
[0195] (S505) The ECU attribute setting unit 405 refers to the ECU attribute storage unit 406 and acquires the domain attribute of the selected IP address.
[0196] (S506) The ECU attribute setting unit 405 determines whether the domain attribute extracted in step S501 is the same as the domain attribute acquired in step S505. If the domain attribute extracted in step S501 is the same as the domain attribute acquired in step S505 (Yes in S506), the ECU attribute setting unit 405 executes step S504. If the domain attribute extracted in step S501 is not the same as the domain attribute acquired in step S505 (No in S506), the ECU attribute setting unit 405 executes step S507.
[0197] (S507) The ECU attribute setting unit 405 sets the domain attribute extracted in step S502 as the domain attribute of the selected IP address, and sets the domain attribute extracted in step S502 among the ECU domain attributes of the selected IP address to 1 in the ECU attribute storage unit 406.
[0198] 17. Sequence of Abnormality Detection Using ECU Attributes Figure 18 shows an example of a sequence of abnormality detection using ECU attributes by the abnormality detection ECU according to this embodiment. It is assumed that an attacker has seized operation authority by exploiting a vulnerability in the camera ECU 600e.
[0199] (S601) The vehicle speed detection ECU 600b transmits a SOME / IP message frame containing vehicle speed information to the electric lock control ECU 600c. The frame is transmitted to the central ECU 200 via the zone ECU 500a.
[0200] (S602) The central ECU 200 transfers the frame (communication frame) received from the vehicle speed detection ECU 600b to the abnormality detection ECU 400.
[0201] (S603) The abnormality detection ECU 400 checks whether the frame (communication frame) transferred from the central ECU 200 complies with the service-oriented communication protocol, and performs abnormality detection by determining whether the frame is abnormal using the ECU attributes. Details of the abnormality detection process performed by the abnormality detection ECU 400 will be described later.
[0202] (S604) As a result of the abnormality detection, the abnormality detection ECU 400 determines that the frame is normal.
[0203] (S605) The camera ECU 600e transmits a SOME / IP message frame requesting the electric lock unlocking ECU 600d to unlock the electric lock.
[0204] (S606) The central ECU 200 transfers the frame (communication frame) acquired from the camera ECU 600e to the abnormality detection ECU 400.
[0205] (S607) As a result of the abnormality detection, abnormality detection ECU 400 determines that the frame is abnormal, and transmits a frame notifying an alert to user interface ECU 300.
[0206] (S608) When the user interface ECU 300 receives the frame notifying the alert, it notifies (displays) the driver of the alert via an external device such as a monitor.
[0207] 18. Flowchart of Abnormality Detection Using ECU Attributes Fig. 19 is an example of a flowchart related to an abnormality detection process using ECU attributes by the abnormality detection unit 402 in this embodiment to determine whether a SOME / IP communication frame is performing abnormal communication.
[0208] (S701) The abnormality detection unit 402 acquires the source IP address and destination IP address contained in the frame of the received SOME / IP message, and refers to the ECU attribute memory unit 406 to acquire the ECU attributes of the source IP address and destination IP address, respectively.
[0209] (S702) The abnormality detection unit 402 uses the abnormality detection rules stored in the abnormality detection rule storage unit 407 to determine whether the combination of the ECU attribute of the acquired source IP address and the ECU attribute of the acquired destination IP address is correct.
[0210] Specifically, for example, in the case of communication from the vehicle speed detection ECU 600b to the electric lock control ECU 600c described in Fig. 18, by referring to the ECU attribute information stored in the ECU attribute storage unit 406 in Fig. 11, it can be seen that the vehicle speed detection ECU 600b having the source IP address has an ECU role attribute of sensor and an ECU domain attribute of powertrain, and that the electric lock control ECU 600c having the destination IP address has an ECU role attribute of brain and an ECU domain attribute of body. This combination of ECU attributes is defined as OK in the abnormality detection rule stored in the abnormality detection rule storage unit 407 in Fig. 12. Therefore, the abnormality detection unit 402 determines that the frame communicated from the vehicle speed detection ECU 600b to the electric lock control ECU 600c is a normal frame.
[0211] Furthermore, in the case of communication from the camera ECU 600e to the electric lock ECU 600d described in Fig. 18, by referring to the ECU attribute information stored in the ECU attribute storage unit 406 in Fig. 11, it can be seen that the camera ECU 600e having the source IP address has the ECU role attribute of sensor and ADAS, and the electric lock ECU 600d having the destination IP address has the ECU role attribute of actuator and body. This combination of ECU attributes is defined as NG in the abnormality detection rule stored in the abnormality detection rule storage unit 407 in Fig. 12. Therefore, the abnormality detection unit 402 determines that the frame communicated from the camera ECU 600e to the electric lock ECU 600d is an abnormal frame.
[0212] If the abnormality detection unit 402 determines that the combination of the ECU attribute of the acquired source IP address and the ECU attribute of the destination IP address is correct (Yes in S702), it executes the process of step S703. If the abnormality detection unit 402 determines that the combination of the ECU attribute of the acquired source IP address and the ECU attribute of the destination IP address is incorrect (abnormal) (No in S702), it executes the process of step S704.
[0213] (S703) The abnormality detection unit 402 determines that the received frame is normal.
[0214] (S704) Abnormality detection unit 402 determines that the received frame is abnormal, and transmits a frame to user interface ECU 300 to display an alert.
[0215] Furthermore, if the attribute setting flag in the ECU attribute storage unit 406 is set to ON for the source IP address and the destination IP address when the frame is determined to be an abnormal communication, there is a possibility that normal communication was mistakenly detected as an abnormal communication in the abnormality detection before the ECU attribute was reset. For this reason, in step S704, the abnormality detection unit 402 may output information indicating whether the attribute setting flag is ON.
[0216] Effect of First Embodiment In the in-vehicle network system described in the first embodiment, the anomaly detection ECU 400 labels each ECU with its function and the information it handles as an ECU attribute, and further defines which ECU attributes constitute an anomaly in communication, thereby detecting an anomaly in communication. As a result, regardless of which ECUs are communicating with each other, as long as the attributes of the ECUs with the source IP address and the destination IP address are known, it becomes possible to distinguish between normal and abnormal communication, thereby improving security.
[0217] Furthermore, the anomaly detection ECU 400 detects changes in the communication trends of the in-vehicle network, such as when the driver changes the vehicle system settings or when an ECU system update occurs via OTA, and labels the ECU attributes at specific times. This makes it possible to detect abnormal communications while distinguishing between unusual communications caused by OTA or a change to the vehicle system and unusual communications caused by an attacker, thereby improving vehicle safety.
[0218] As described above, the anomaly detection ECU 400 (anomaly detection device) according to this embodiment is an anomaly detection device that detects an anomaly in an in-vehicle network system configured with two or more ECUs and one or more networks. The anomaly detection ECU 400 includes an ECU attribute storage unit 406, a communication unit 401, and an anomaly detection unit 402. The ECU attribute storage unit 406 stores attributes set for each of the two or more ECUs. The communication unit 401 transmits and receives messages on one or more networks. The anomaly detection unit 402 detects an abnormal communication using attributes of the ECU that is the source (source IP address) or destination (destination IP address) of a message, among the attributes stored in the ECU attribute storage unit 406. The attributes stored in the ECU attribute storage unit 406 indicate the function of the ECU having the attribute or the type of information handled by the ECU having the attribute.
[0219] This makes it possible to determine whether an abnormal message exchange is occurring when a message is exchanged between ECUs by referring to the attributes indicating the function of each ECU and the type of information handled by the ECU, thereby improving the safety of the vehicle 10.
[0220] In the abnormality detection ECU 400 according to this embodiment, the attributes stored in the ECU attribute storage unit 406 indicate the functions of the ECU operating in the in-vehicle network system. The attributes include one of a sensor attribute, a brain attribute, and an actuator attribute. The sensor attribute indicates that the ECU has the function of sensing information inside and outside the vehicle. The brain attribute indicates that the ECU has the function of processing the sensed information and issuing control instructions. The actuator attribute indicates that the ECU has the function of performing control in accordance with the control instructions.
[0221] This makes it possible to determine whether or not communication is abnormal based on the functional relationships between the ECUs, thereby improving vehicle safety.
[0222] In the abnormality detection ECU 400 according to this embodiment, the attributes stored in the ECU attribute storage unit indicate the type of information handled by the ECU in the in-vehicle network system. The attributes include any one of a powertrain attribute, an infotainment attribute, a body attribute, an ADAS attribute, and a connectivity attribute. The powertrain attribute indicates that the ECU handles control information related to vehicle driving. The infotainment attribute indicates that the ECU handles information related to notifying the driver of the vehicle's status. The body attribute indicates that the ECU handles control information related to the vehicle's body systems. The ADAS attribute indicates that the ECU handles information related to advanced driving assistance functions that assist or replace the driver in operating the vehicle. The connectivity attribute indicates that the ECU handles information obtained from outside one or more networks.
[0223] This makes it possible to determine whether or not communication is abnormal based on the relationship between the types of information handled by the ECUs, thereby improving vehicle safety.
[0224] In the abnormality detection ECU 400 according to this embodiment, the abnormality detection unit 402 determines whether the message received by the communication unit 401 is abnormal based on a combination of the attributes of the ECU that sent the frame (message) and the attributes of the ECU that is the destination of the frame.
[0225] This makes it possible to determine whether or not communication is abnormal based on the combination of attributes between the ECUs of the frame's sender and destination, thereby improving the safety of the vehicle 10.
[0226] In the abnormality detection ECU 400 according to this embodiment, the abnormality detection unit 402 determines whether the frame received by the communication unit 401 is abnormal based on the relationship between the attributes of the ECU that sent the frame (message) or the attributes of the ECU that is the destination of the frame, and the information contained in the frame received from the communication unit.
[0227] This makes it possible to determine whether the communication is abnormal, even in the case of an attack that sends a tampered message, thereby improving vehicle safety.
[0228] In the abnormality detection ECU 400 according to this embodiment, the in-vehicle network system exchanges messages using service-oriented communication. Information contained in a message received from the communication unit 401 is information stored in a message format for SOME / IP communication.
[0229] This makes it possible to determine abnormal communication from the relationship between the information stored in the message format of SOME / IP communication and the attributes of the ECU, thereby improving vehicle safety.
[0230] The abnormality detection ECU 400 according to the present embodiment further includes a communication log storage unit 404. The communication log storage unit 404 stores frames (messages) received by the communication unit 401. The abnormality detection unit 402 references the frames (messages) stored in the communication log storage unit 404 and the ECU attribute storage unit 406 to identify a relationship indicating a combination of attributes of source and destination ECUs in which frame (message) exchange has occurred. With regard to newly received frames (messages), the abnormality detection unit 402 determines that a message between ECUs having an attribute corresponding to a combination in which frame (message) exchange has occurred in the relationship is normal, and determines that a message between ECUs having an attribute corresponding to a combination in which frame (message) exchange has not occurred in the relationship is abnormal.
[0231] This makes it possible to mechanically generate a definition of abnormal communication using ECU attributes from the communication log, and to automatically update the definition of abnormal communication.
[0232] In the abnormality detection ECU 400 according to this embodiment, the in-vehicle network system exchanges messages using service-oriented communication. The abnormality detection ECU 400 further includes a communication log storage unit 404 and an ECU attribute setting unit 405. The communication log storage unit 404 stores frames (messages) received by the communication unit 401. The ECU attribute setting unit 405 sets the attributes of the ECU to be stored in the ECU attribute storage unit 406. The ECU attribute setting unit 405 references the frames (messages) stored in the communication log storage unit 404, determines whether the ECU is on the server side or the client side based on the message type included in the frame (message), and determines the attributes of the ECU based on the ratio of server communication to client communication.
[0233] This makes it possible to define the attributes of the ECU from the communication log, and to automatically update the attributes of the ECU.
[0234] The abnormality detection ECU 400 according to the present embodiment further includes a communication log storage unit 404 and an ECU attribute setting unit 405. The communication log storage unit 404 stores frames (messages) received by the communication unit 401. The ECU attribute setting unit 405 references the frames (messages) stored in the communication log storage unit 404 and sets the attributes of the ECUs stored in the ECU attribute storage unit 406. The ECU attribute setting unit 406 references the frames (messages) stored in the communication log storage unit 404 and the ECU attribute storage unit 406 and determines the attributes of the first ECU according to the frequency of appearance of the attributes of the ECUs with which the first ECU communicates.
[0235] This makes it possible to define the attributes of the ECU from the communication log, and to automatically update the attributes of the ECU.
[0236] In the abnormality detection ECU 400 according to this embodiment, the ECU attribute setting unit 405 determines the attributes of the ECU when the following conditions are met: a predetermined time has elapsed since the ECU attributes were determined, or the communication unit 401 has received a frame (message) that causes a change in the communication trends of one or more networks.
[0237] This makes it possible to detect anomalies according to the state of the latest in-vehicle network, preventing the problem of false positives increasing over time and improving vehicle safety.
[0238] In the abnormality detection ECU 400 according to this embodiment, frames (messages) that cause a change in the communication trends of one or more networks are messages that occur when data is acquired and installed from a network or server other than the in-vehicle network, or messages that occur when the function settings of the in-vehicle system are changed, deleted, or updated.
[0239] This makes it possible to detect changes in the in-vehicle network, such as acquiring and installing data from an external source or changing the function settings of the in-vehicle system, and to reset the attributes of the ECU, thereby reducing false positives in abnormality detection.
[0240] In the abnormality detection ECU 400 according to this embodiment, the abnormality detection unit 402 calculates the frequency of occurrence of the attributes of the ECU with which the first ECU communicates from the frames (messages) stored in the communication log memory unit 404, and, when referring to the frequency of occurrence of the attributes of the first ECU stored in the ECU attribute memory unit 406, determines that the communication of the first ECU is abnormal if it deviates beyond a certain standard.
[0241] This makes it possible to detect abnormal communications by capturing trends in the attributes of ECUs across the entire in-vehicle network, making it possible to detect abnormalities such as a sudden increase in communication volume from a specific ECU.
[0242] (Variant 1 of Embodiment 1) In the anomaly detection ECU 400 in the in-vehicle network system shown in Embodiment 1, an example has been shown in which anomaly detection rules are predefined in the anomaly detection rule memory unit 407 based on the relationship between the ECU attributes of the source IP address and the ECU attributes of the destination IP address, but anomaly detection rules may also be predefined based on the relationship between the ECU attributes of the source IP address and the features of the communication frame.
[0243] In this modification, explanations of the same figures as in the first embodiment will be omitted, and therefore only an example of an anomaly detection rule stored in the anomaly detection rule storage unit 407 and how a frame is determined to be abnormal using the anomaly detection rule will be explained.
[0244] 19. Anomaly Detection Based on ECU Attributes of Source ECU and Communication Contents FIG. 20 is a diagram showing an example of anomaly detection rules stored in the anomaly detection rule storage unit, which use the ECU attributes of the ECU of the source IP address and a frame conforming to the service-oriented communication protocol.
[0245] As shown in the figure, maximum and minimum values for frame message size are stored for each combination of the role attribute and domain attribute of the ECU of the source IP address. For example, it is shown that an ECU whose domain attribute is connectivity and whose role attribute is sensor transmits frames with a minimum message size of 500 bytes and a maximum message size of 600 bytes. These values may be set in advance by investigating the in-vehicle network, or they may be set by extracting communication logs for a predetermined period of time from the communication log storage unit 404 at a specific time and storing information on the maximum and minimum values identified by referring to the message size.
[0246] FIG. 21 shows an example in which the processing flow relating to step S603 in FIG. 18 is changed to a processing flow for detecting an abnormality based on the ECU attribute of the ECU of the source IP address and the message size of the frame.
[0247] (S801) The abnormality detection unit 402 acquires the source IP address included in the frame of the received SOME / IP communication message, and acquires the ECU attribute by referring to the ECU attribute storage unit 406. Furthermore, the abnormality detection unit 402 acquires the message size by referring to the Length in the SOME / IP message format of the frame.
[0248] (S802) The anomaly detection unit 402 references the minimum and maximum message size values corresponding to the ECU attribute of the acquired source IP address from the anomaly detection rule storage unit 407, and determines whether the message size of the acquired message is between the minimum and maximum values. If the size of the acquired message is between the minimum and maximum values (Yes in S802), the anomaly detection unit 402 performs the processing of step S803. If the size of the acquired message is not between the minimum and maximum values (No in S802), the anomaly detection unit 402 performs the processing of step S804.
[0249] (S803) The abnormality detection unit 402 determines that the received frame is normal.
[0250] (S804) Abnormality detection unit 402 determines that the received frame is abnormal, and transmits a frame to user interface ECU 300 to display an alert.
[0251] Although the anomaly detection unit 402 has shown an example in which the maximum and minimum message sizes are used to detect an anomaly, other evaluation indicators may be used, such as determining that an anomaly exists if the difference from the average or median message size is greater than or equal to a threshold value.
[0252] In addition, in the anomaly detection rules, an anomaly is defined based on the relationship between the message size of the frame and the ECU attributes of the ECU of the source IP address, but an anomaly may also be defined based on the relationship between the message size of the frame and the ECU attributes of the ECU of the destination IP address, or based on the message size of the frame and the ECU attributes of the ECU of the source IP address and the ECU of the destination IP address.
[0253] Furthermore, in the anomaly detection rule, an anomaly may be defined not based on the message size of the frame, but based on the message ID, service ID, or message type stored in the frame and the relationship between the ECU attribute. For example, an anomaly detection rule may be defined by specifying the message ID of a frame transmitted when the ECU attribute of the ECU of the source IP address is a body and an actuator, and the anomaly detection unit 402 may determine that a frame containing an undefined message ID is abnormal when the frame is transmitted.
[0254] (Effects of Variant 1 of Embodiment 1) The anomaly detection method in an in-vehicle network system shown in Variant 1 of Embodiment 1 enables the anomaly detection ECU 400 to detect an abnormal frame when an attacker tampers with information in the frame and transmits an abnormal frame, thereby improving security.
[0255] (Second Modification of First Embodiment) In the anomaly detection ECU 400 in the in-vehicle network system shown in the first embodiment, an example has been shown in which anomaly detection rules are defined in advance in the anomaly detection rule storage unit 407, but an anomaly may be determined by referring to past communication logs stored in the communication log storage unit 404 without referring to the anomaly detection rule storage unit 407. Note that, in order to omit explanations of the same drawings as those in the first embodiment, an example of an anomaly detection flowchart with a different configuration will be shown, and only frame anomaly detection will be explained.
[0256] 20. Abnormality Detection Using ECU Attributes of Source IP Address and Communication Logs FIG. 22 shows an example of the processing flow for step S603 in FIG. 18 , which is modified to a processing flow for detecting abnormalities using the communication logs stored in the communication log storage unit 404.
[0257] (S901) The abnormality detection unit 402 acquires the source IP address and destination IP address contained in the frame of the received SOME / IP message, and refers to the ECU attribute storage unit 406 to acquire the ECU attributes of each of the source IP address and destination IP address.
[0258] (S902) The abnormality detection unit 402 refers to the ECU attribute storage unit 406 and acquires the ECU attribute of the acquired source IP address and a set of IP addresses having the same ECU attribute.
[0259] (S903) The abnormality detection unit 402 acquires communication logs stored in the communication log storage unit 404 for a predetermined period of time, and for communication logs in which the acquired source IP address is the source, refers to the ECU attributes of the destination IP address and acquires a set of ECU attributes of the destination IP address.
[0260] (S904) The abnormality detection unit 402 determines whether the ECU attribute of the acquired destination IP address is included in the set of ECU attributes of the acquired destination IP address. If the ECU attribute of the acquired destination IP address is included in the set of ECU attributes of the acquired destination IP address (Yes in S904), the abnormality detection unit 402 executes the process of step S905. If the ECU attribute of the acquired destination IP address is not included in the set of ECU attributes of the acquired destination IP address (No in S904), the abnormality detection unit 402 executes the process of step S906.
[0261] (S905) The abnormality detection unit 402 determines that the received frame is normal.
[0262] (S906) Abnormality detection unit 402 determines that the received frame is abnormal, and transmits a frame to user interface ECU 300 to display an alert.
[0263] Furthermore, in this modification, the focus is on the ECU attribute of the source IP address, and the ECU attribute included in the destination IP address is checked using the past communication log in the communication log storage unit 404. However, the focus may be on the ECU attribute of the destination IP address, and the ECU attribute included in the source IP address may be checked using the past communication log in the communication log storage unit 404. Alternatively, both of these checks may be combined.
[0264] (Effects of Variant 2 of Embodiment 1) The anomaly detection method in an in-vehicle network system shown in Variant 2 of Embodiment 1 does not require the definition of anomaly detection rules in advance, and performs anomaly detection by capturing the communication trends of the in-vehicle network from collected past communication logs. Therefore, anomaly detection rules can be created according to the communication trends of each vehicle, thereby improving the accuracy of anomaly detection.
[0265] 17 , the anomaly detection ECU 400 in the in-vehicle network system shown in the first embodiment selects one domain attribute of an IP address and stores it in the ECU attribute storage unit 406. However, the IP address may have multiple domain attributes, and the domain attribute of the IP address may be set. Note that, since explanations of the same drawings as those in the first embodiment will be omitted, only how a frame is determined to be abnormal when a new function is added to an IP address and the ECU has multiple domain attributes will be described here using a sequence for adding an attribute of an IP address, a flowchart for setting the domain attribute of an IP address, an example of ECU attribute information stored in the ECU attribute storage unit 406, and a flowchart for anomaly detection using an ECU attribute, which have different configurations.
[0266] 21. Example of Sequence Related to Addition of ECU Attributes Figure 23 shows an example of a sequence in which the abnormality detection ECU 400 detects a change in the in-vehicle network and resets the ECU attribute information used for abnormality detection when the driver operates the touch panel of the user interface ECU 300 to install an infotainment-related application in addition to the ADAS-related application installed in the guest OS unit 203 of the central ECU 200.
[0267] (S1001) The user interface ECU 300 accepts an operation from the user and requests the guest OS unit 203 of the central ECU 200 to newly install an infotainment-related application (infotainment app).
[0268] (S1002) The central ECU 200 requests the OTA server 30 to transmit an installer for an infotainment-related application (infotainment app) to the guest OS unit 203.
[0269] (S1003) The OTA server 30 transmits an installer for an infotainment-related application (infotainment app) to the guest OS unit 203 of the central ECU 200.
[0270] (S1004) The central ECU 200 transfers the received frame to the abnormality detection ECU 400.
[0271] (S1005) The abnormality detection unit 402 of the abnormality detection ECU 400 receives a frame that transmits an installer from the OTA server 30 to the guest OS unit 203, and acquires the destination IP address stored in the frame. Furthermore, the abnormality detection unit 402 references the IP addresses stored in the ECU attribute storage unit 406, and if the acquired IP address is included, sets the attribute setting flag corresponding to the IP address to ON.
[0272] (S1006) The central ECU 200 installs an infotainment application.
[0273] 22. Example of Sequence Related to Setting ECU Attributes Figure 24 shows an example of ECU attribute information stored in the ECU attribute storage unit 406 when an IP address has multiple domain attributes. As in Figure 11, each line is represented by a set of the IP address, ECU attribute, attribute setting flag, date and time when the flag was set to OFF, and date and time when the flag was set to ON. Compared to the example of ECU attribute information shown in Figure 11, the brake control ECU has three domain attributes, with 0.8 stored in the powertrain attribute, 0.1 in the ADAS attribute, and 0.1 in the body attribute. The stored values represent the ratio of the domain attributes, and the larger the value, the more communication related to that domain attribute occurs.
[0274] Fig. 25 shows the process flow for setting the domain attribute of an IP address in Fig. 17, where an IP address can have multiple domain attributes instead of selecting one. Note that the same process steps as those in the first embodiment are given the same numbers, and their explanations will be omitted.
[0275] (S1104) If the answer to step S503 is Yes, the ECU attribute setting unit 405 calculates the occurrence rate of the domain attribute by dividing the number of occurrences of the domain attribute extracted in step S501 by the total number of occurrences of the domain attribute of the IP address of the communication destination in step S501, and sets the calculated occurrence rate of the domain attribute extracted in step S501 to the ECU attribute memory unit 406.
[0276] (S1107) If the result of step S506 is No, the ECU attribute setting unit 405 calculates the occurrence rate of the domain attribute by dividing the number of occurrences of the domain attribute extracted in step S502 by the total number of occurrences of the domain attributes of the IP address of the communication destination excluding the attribute setting flag ON in step S502, and sets the calculated occurrence rate of the domain attribute extracted in step S502 to the ECU attribute memory unit 406.
[0277] 23. Example of Flowchart for Anomaly Detection Using ECU Attributes Fig. 26 shows an example of the processing flow for step S603 in Fig. 18, which is modified to a processing flow for the case where an IP address has multiple domain attributes.
[0278] (S1201) The abnormality detection unit 402 acquires the source IP address and the destination IP address contained in the received frame, and refers to the ECU attribute storage unit 406 to acquire the ECU attributes of each of the acquired IP addresses.
[0279] (S1202) The anomaly detection unit 402 refers to the values of each of the ECU attributes of the acquired IP address, extracts the attributes that store the maximum values for the role attribute and domain attribute of the ECU of the source IP address, and the attributes that store the maximum values for the role attribute and domain attribute of the ECU of the destination IP address, and creates a combination of ECU attributes of the source IP address and destination IP address.
[0280] For example, in Figure 24, if the ECU of the source IP address is a vehicle speed detection ECU, the role attribute of the ECU has a maximum value of 1, which is sensor, and the domain attribute of the ECU has a maximum value of 0.7, which is powertrain, so sensor is extracted as the role attribute of the ECU of the source IP address and powertrain is extracted as the domain attribute of the ECU.
[0281] In addition, in FIG. 24, when the ECU of the destination IP address is a brake control ECU, brain is extracted as the ECU role attribute of the ECU of the destination IP address, and powertrain is extracted as the ECU domain attribute.
[0282] (S1203) The anomaly detection unit 402 determines whether the extracted combination of ECU attributes is abnormal communication using the anomaly detection rules stored in the anomaly detection rule storage unit 407. If the anomaly detection unit 402 determines that the extracted combination of ECU attributes is abnormal (Yes in S1203), the anomaly detection unit 402 executes the process of step S1204. If the anomaly detection unit 402 determines that the extracted combination of ECU attributes is normal (No in S1203), the anomaly detection unit 402 executes the process of step S1212.
[0283] (S1204) The anomaly detection unit 402 determines whether at least one of the source IP address and the destination IP address has multiple domain attributes. If neither the source IP address nor the destination IP address has multiple domain attributes (No in S1204), the anomaly detection unit 402 executes the process of S1205. If either the source IP address or the destination IP address has multiple domain attributes (Yes in S1204), the anomaly detection unit 402 executes the process of step S1206.
[0284] (S1205) Abnormality detection unit 402 determines that the received frame is abnormal, and transmits a frame to user interface ECU 300 to instruct it to display an alert.
[0285] (S1206) The abnormality detection unit 402 creates a combination of ECU attributes other than the combination of ECU attributes created in step S1202.
[0286] For example, in Figure 24, if the ECU with the source IP address is a vehicle speed detection ECU, there are three combinations of the role attribute of the ECU with the source IP address and the domain attribute of the ECU: sensor and powertrain, sensor and ADAS, and sensor and body.
[0287] Also, in FIG. 24, when the ECU at the destination IP address is a brake control ECU, there are two combinations of the role attribute of the ECU at the destination IP address and the domain attribute of the ECU: brain and powertrain, and brain and ADAS.
[0288] Therefore, there are six combinations of source IP addresses and destination IP addresses and ECU attributes, and the anomaly detection unit 402 extracts five combinations, excluding the combination of ECU attributes extracted in step S1202, as a list.
[0289] (S1207) The abnormality detection unit 402 selects one combination from the list of extracted combinations of ECU attributes.
[0290] (S1208) The anomaly detection unit 402 determines whether the communication is abnormal based on the detection rules stored in the anomaly detection rule storage unit 407 for the combination of ECU attributes selected in step S1207. If it is determined to be abnormal (Yes in S1208), step S1209 is executed. If it is determined to be normal (No in S1208), step S1210 is executed.
[0291] (S1209) The abnormality detection unit 402 determines whether all of the ECU attribute combinations in the extracted list have been selected. If all of the ECU attribute combinations in the extracted list have been selected (Yes in S1209), the abnormality detection unit 402 executes the process of step S1205. If all of the ECU attribute combinations in the extracted list have not been selected (No in S1209), the abnormality detection unit 402 executes the process of step S1207.
[0292] (S1210) The anomaly detection unit 402 references the communication log storage unit 404, acquires a predetermined number of communication logs in descending order of timestamp value, i.e., in order of most recently recorded communication logs, and calculates how frequently the source IP address acquired in step S1201 has transmitted to which IP addresses in the past. Furthermore, a weighted average is calculated, where the ECU attribute of the destination IP address is used as a weight and the total number of occurrences of the destination IP address is used as the sum of the weights. Furthermore, the absolute value of the difference between the acquired weighted average and the ECU attribute of the source IP address is calculated for each element of the domain attribute.
[0293] For example, when the source IP address in step S1201 is 192.168.1.1, and the communication log memory unit 404 stores eight data transmissions from 192.168.1.1 to 192.168.1.2 and two data transmissions from 192.168.1.1 to 192.168.1.11, the weighted average of the ECU attributes of the destination ECU can be calculated as the sum of the value obtained by multiplying the ECU attribute of 192.168.1.2 by 0.8 and the value obtained by multiplying the ECU attribute of 192.168.1.11 by 0.2, with the number of data transmissions used as the weight. 24, the weighted average of the domain attributes of the destination ECU of 192.168.1.1 is connectivity (0), powertrain (0.58), ADAS (0.16), body (0.26), and infotainment (0). Here, since the ECU attributes of 192.168.1.1 are connectivity (0), powertrain (0.8), ADAS (0.1), body (0.1), and infotainment (0), the absolute values of the differences between the elements of the domain attributes are connectivity (0), powertrain (0.22), ADAS (0.06), body (0.16), and infotainment (0).
[0294] (S1211) The abnormality detection unit 402 references the absolute value of the domain attribute calculated in step S1210, which corresponds to the domain attribute of the destination ECU of the combination selected in step S1207, and determines whether the absolute value is within a threshold. If the calculated absolute value is within the threshold (Yes in S1211), the abnormality detection unit 402 executes the process of step S1212. If the calculated absolute value exceeds the threshold (No in S1211), the abnormality detection unit 402 executes the process of step S1209.
[0295] (S1212) The abnormality detection unit 402 determines that the received frame is normal.
[0296] (Effects of Modification 3 of Embodiment 1) The anomaly detection method in the in-vehicle network system shown in Modification 3 of Embodiment 1 can apply anomaly detection rules assuming multiple communication patterns when an ECU has multiple domain attributes and communicates frames. As a result, even if another domain attribute is added to the ECU later via OTA, the anomaly detection ECU can determine an anomaly by taking into account that the ECU has multiple domain attributes.
[0297] 24. Other Modifications Although the present disclosure has been described based on the above-described embodiments, it goes without saying that the present disclosure is not limited to the above-described embodiments. The following cases are also included in the present disclosure.
[0298] (1) In the above embodiment, Ethernet and CAN protocols are used as the in-vehicle network, but this is not limiting. For example, CAN-FD (CAN with Flexible Data Rate), LIN (Local Interconnect Network), MOST (Media Oriented Systems Transport), etc. may also be used. Alternatively, a network configuration may be used in which these networks are combined as subnetworks.
[0299] (2) In the above embodiment, the role attributes of the three ECUs, sensor, brain, and actuator, are defined based on the ratio of client communication to server communication and whether a response message is always returned when a request message is received, and each ECU is labeled to indicate which role attribute it belongs to. However, this is not limited to this. For example, instead of the ratio of client communication to server communication, multiple labels may be defined based on the ratio of message types sent using the three message types, Notification, Request, and Response.
[0300] (3) In the above embodiment, the role attributes of the three ECUs, sensor, brain, and actuator, are determined based on the ratio of client communication to server communication based on the message type of SOME / IP communication, but this is not limited to this. The ratio of client communication to server communication may be calculated by referring to SOME / IP-SD messages and determining whether an Offer message or a Subscribe message is being sent.
[0301] (4) In the above embodiment, five ECU domain attributes, namely, powertrain, infotainment, body, ADAS, and connectivity, are defined and labeled for each ECU, but this is not limitative. Among ADAS attributes, domain attributes may be defined for two ECUs: one for ECUs that communicate during fully autonomous driving, and one for ECUs that communicate when assisting the driver in driving.
[0302] (5) In the above embodiment, the anomaly detection ECU 400 determines whether a communication frame is abnormal by examining the combination of the ECU attributes of the source IP address and the ECU attributes of the destination IP address from a single communication frame. However, it may also be possible to determine whether abnormal communication is occurring from multiple communication frames. For example, the anomaly detection ECU may monitor communication frames generated at regular time intervals, calculate the occurrence rate of the ECU attributes involved in communication, and determine an abnormality if the occurrence rate of the ECU attributes changes suddenly. This anomaly detection method allows for confirmation of time-series changes, such as a sudden decrease in the communication rate of ECUs with powertrain and ADAS attributes and a sudden increase in the communication rate of ECUs with connectivity attributes, when a vehicle is subjected to a DoS attack from an external network while autonomously driving. This makes it possible to detect an abnormality in the in-vehicle network and enhance security.
[0303] (6) In the above embodiment, the anomaly detection ECU 400 determines whether a communication frame is abnormal by examining the combination of the attributes of the ECU of the source IP address and the attributes of the ECU of the destination IP address from a single communication frame. However, it is also possible to store the ratio of the attributes of the ECU of the communication destination IP address for each attribute combination and determine an abnormality if communication that significantly differs from the stored ratio is detected. For example, if an ECU has sensor and body attributes, instead of storing that communication with two types of ECUs, that is, ECUs with brain and body attributes and ECUs with brain and powertrain attributes, is normal, it stores that 90% of frames occur with ECUs with brain and body attributes and the remaining 10% occur with ECUs with brain and powertrain attributes. By doing so, when multiple frames are monitored over a certain time span, if an ECU with sensor and body attributes sends frames only to ECUs with brain and powertrain attributes, the anomaly detection ECU can determine that an abnormality has occurred, thereby improving security.
[0304] (7) In the above embodiment, the IP address and the attribute information of the ECU are linked and stored, and are used for anomaly detection. However, the attribute information may be linked and stored using other identification information. For example, the attribute information may be labeled on a MAC address basis by including information corresponding to the MAC address of the ECU in the frame.
[0305] (8) In the above embodiment, role attributes and domain attributes of ECUs are defined, and a communication frame is determined to be abnormal by examining the combination of the attribute of the ECU of the source IP address and the attribute of the ECU of the destination IP address. However, anomaly detection may be performed by defining only role attributes and labeling, or by defining only domain attributes and labeling. For example, three ECU role attributes (sensor / brain / actuator) may be defined for each ECU, and a combination of the attribute of the ECU of the source IP address and the attribute of the destination ECU may be defined to determine which combination is normal. Because the calculation cost of anomaly detection increases when multiple attributes are used, it is possible to switch between determining anomaly based on a simple attribute combination depending on the situation.
[0306] (9) In the above embodiment, a frame that causes a change in the in-vehicle network is detected and the attributes of the ECU are reset. However, the attributes of the ECU may be reset for reasons other than frame detection. For example, an input interface such as a button that allows the driver to actively reset the attributes may be provided so that the attributes can be reset at any time. Alternatively, location information may be obtained from a GPS function installed in the in-vehicle system, and the ECU attributes may be reset when it is detected that the driver is moving from an area where the V2X function can be used to an area where the V2X function cannot be used.
[0307] (10) In the above embodiment, an example was shown in which the attribute information of the ECU was overwritten and stored when the attributes were reset. However, multiple pieces of attribute information for each ECU may be stored without being overwritten, linked to the time of setting the attribute information. It is possible that false detection may occur due to insufficient data in the reset attribute information of the ECU. However, by performing anomaly detection using the attribute information before resetting, it is possible to use the information as an index for determining whether the result of the anomaly detection is correct.
[0308] (11) In the above embodiment, an example was shown in which frames transmitted and received by the central ECU are forwarded to the anomaly detection ECU to perform anomaly detection, but this is not limited to this. An anomaly detection function using ECU attributes may be incorporated into the central ECU, or multiple central ECUs may be installed by dividing the in-vehicle network into certain units.
[0309] (12) In the above embodiment, when the abnormality detection ECU detects an abnormal frame, it sends a frame to notify the user interface ECU 300 of an alert. However, the alert may also be sent to an OTA server 30 outside the vehicle managed by a security monitor via the TCU 100, or a log related to the abnormality detection may also be sent.
[0310] FIG. 27 shows an example of a log related to anomaly detection notified to an OTA server outside the vehicle. FIG. 27 shows that the log ID, which is the serial ID of the anomaly detection log, is 10001, and the anomaly code indicating the type of anomaly is 0x01 (violation of communication rules between ECU attributes). The detection details indicate that the ECU attributes of the source ECU are sensor and ADAS, and the ECU attributes of the destination ECU are actuator and body, indicating that an abnormal combination of ECU attributes has been detected. The IP addresses and ECU attributes of the source ECU and destination ECU are also shown. The log also shows a timestamp for the frame in which the anomaly was detected, the message size, and the fact that the original packet is included.
[0311] Furthermore, to facilitate analysis of the anomaly detection log notified to the OTA server, the anomaly detection results may be displayed on a graphical user interface connected to the OTA server. Figure 28 shows an example of an anomaly detection result displayed on a graphical user interface. Figure 28 shows that an anomaly detection result occurred in a vehicle with vehicle ID 101, where an anomaly detection unit in the vehicle detected the anomaly and sent the detection result to the OTA server. The vehicle ID is a number identifying the vehicle from which the data is being sent and is set on the OTA server side using vehicle-specific information contained in the data sent from the TCU. The display results are composed of three elements. The upper part of the screen highlights with bold arrows which communication paths in the in-vehicle network the anomaly was detected on. Thin lines indicate communication paths that the camera ECU, which is the source of the anomaly, can connect based on the anomaly detection rules, while dotted lines indicate communication paths that cannot be connected. The center part of the screen displays details of the anomaly detection results, visualizing the anomaly detection log as shown in Figure 27. To indicate the basis for determining an abnormality, a portion of the diagram is highlighted by bolding the lines or bolding the text depending on the content of the abnormality code. In Figure 28, the ECU attribute is highlighted because it violates the rules for communication between ECU attributes. At the bottom of the screen, the abnormality detection log received from the vehicle with vehicle ID 101 is displayed in a table format. The first row of the table contains the elements of the abnormality detection log, and the second row and subsequent rows contain the values of the abnormality detection log.
[0312] (13) Some or all of the components constituting each device in the above embodiments may be configured as a single system LSI (Large Scale Integration). A system LSI is an ultra-multifunctional LSI manufactured by integrating multiple components on a single chip. Specifically, it is a computer system including a microprocessor, ROM, RAM, etc. A computer program is stored in the RAM. The system LSI achieves its functions when the microprocessor operates in accordance with the computer program. Furthermore, each component constituting each device may be individually integrated into a single chip, or a single chip may include some or all of the components. Although the term system LSI is used here, it may also be referred to as an IC, LSI, super LSI, or ultra LSI depending on the level of integration. Furthermore, the method of integration is not limited to LSI, and may be realized using a dedicated circuit or a general-purpose processor. It is also possible to use a field programmable gate array (FPGA), which can be programmed after LSI manufacturing, or a reconfigurable processor, which allows the connections and settings of circuit cells inside the LSI to be reconfigured. Furthermore, if an integrated circuit technology that can replace LSI emerges due to advances in semiconductor technology or a derivative technology, that technology may naturally be used to integrate functional blocks. The application of biotechnology, etc., is also a possibility.
[0313] (14) Some or all of the components constituting each of the above devices may be configured as an IC card or a standalone module that can be attached to each device. The IC card or module is a computer system composed of a microprocessor, ROM, RAM, etc. The IC card or module may include the above-mentioned ultra-multifunctional LSI. The IC card or module achieves its functions when the microprocessor operates according to a computer program. This IC card or module may be tamper-resistant.
[0314] (15) In one aspect of the present disclosure, the anomaly detection method may be a program (computer program) that is implemented by a computer, or a digital signal comprising the computer program. In another aspect of the present disclosure, the computer program or digital signal may be recorded on a computer-readable recording medium, such as a flexible disk, hard disk, CD-ROM, MO, DVD, DVD-ROM, DVD-RAM, BD (Blu-ray (registered trademark) Disc), semiconductor memory, etc. Alternatively, the method may be a digital signal recorded on such a recording medium. In another aspect of the present disclosure, the computer program or digital signal may be transmitted via a telecommunications line, a wireless or wired communication line, a network such as the Internet, data broadcasting, etc. In another aspect of the present disclosure, a computer system including a microprocessor and a memory may be configured, in which the memory stores the computer program and the microprocessor operates in accordance with the computer program. The program or digital signal may also be recorded on a recording medium and transferred, or the program or digital signal may be transferred via a network or the like, so that the program or digital signal may be implemented by another independent computer system.
[0315] (16) The scope of the present disclosure also includes configurations that are realized by arbitrarily combining the components and functions shown in the above embodiments and modifications.
[0316] The present disclosure enables detection of abnormal communications in an in-vehicle network system in response to changes in the in-vehicle network due to system updates or additions and modifications of functions, thereby improving vehicle safety.
[0317] 1, 2 CAN 10 Vehicle 20 External network 30 OTA server 100 TCU 101 External communication unit 102 Conversion unit 103 Internal communication unit 200 Central ECU 201 Communication unit 202 Host OS unit 203 Guest OS unit 300 User interface ECU 301, 401, 601 Communication unit 302, 603 External device connection unit 400 Abnormality detection ECU 402 Abnormality detection unit 403 Communication log generation unit 404 Communication log storage unit 405 ECU attribute setting unit 406 ECU attribute storage unit 407 Abnormality detection rule storage unit 500a, 500b Zone ECU 501, 602 Host unit 502 Communication unit 600a Brake control ECU 600b Vehicle speed detection ECU 600c Electric lock control ECU 600d Electric lock opening / closing ECU 600e Camera ECU
Claims
1. An abnormality detection device that detects abnormalities in an in-vehicle network system composed of two or more electronic control units and one or more networks, comprising: an ECU attribute storage unit that stores attributes of the electronic control units set in each of the two or more electronic control units; a communication unit that sends and receives messages on the one or more networks; and an abnormality detection unit that detects abnormal communications using attributes of the electronic control units that are the sender or destination of the messages, from among the attributes stored in the ECU attribute storage unit, wherein the attributes stored in the ECU attribute storage unit indicate the function of the electronic control unit that has the attribute, or the type of information handled by the electronic control unit that has the attribute.
2. The anomaly detection device described in claim 1, wherein the attributes stored in the ECU attribute memory unit indicate the functions of the electronic control units operating in the in-vehicle network system, and include one of the following: a sensor attribute indicating that the electronic control unit has the function of sensing information inside and outside the vehicle; a brain attribute indicating that the electronic control unit has the function of processing the sensed information and issuing control instructions; and an actuator attribute indicating that the electronic control unit has the function of performing control in accordance with control instructions.
3. The anomaly detection device described in claim 1, wherein the attributes stored in the ECU attribute memory unit indicate the type of information handled by the electronic control unit in the in-vehicle network system, and include any one of the following: a powertrain attribute indicating that the electronic control unit handles control information related to vehicle driving; an infotainment attribute indicating that the electronic control unit handles information related to notifying the driver of the vehicle's status; a body attribute indicating that the electronic control unit handles control information for the vehicle's body systems; an ADAS attribute indicating that the electronic control unit handles information related to advanced driver assistance functions that assist or replace the driver in operating the vehicle; and a connectivity attribute indicating that the electronic control unit handles information obtained from outside the one or more networks.
4. The anomaly detection device according to claim 1, wherein the anomaly detection unit determines whether a message received by the communication unit is anomaly based on a combination of the attributes of the electronic control unit that sent the message and the attributes of the electronic control unit that is the destination of the message.
5. The anomaly detection device according to claim 1, wherein the anomaly detection unit determines whether the message received by the communication unit is anomaly based on the relationship between the attributes of the electronic control unit that sent the message or the attributes of the electronic control unit that is the destination of the message and the information contained in the message received from the communication unit.
6. The anomaly detection device according to claim 5, wherein the in-vehicle network system sends and receives messages using service-oriented communication, and the information contained in the message received from the communication unit is information stored in a message format for SOME / IP communication.
7. The anomaly detection device according to claim 4, further comprising a communication log memory unit that stores messages received by the communication unit, wherein the anomaly detection unit refers to the messages stored in the communication log memory unit and the ECU attribute memory unit to identify a relationship indicating a combination of attributes of source and destination electronic control units in which message exchange is occurring, and determines, for newly received messages, that a message between electronic control units having an attribute of a combination in which message exchange is occurring in the relationship is normal, and determines that a message between electronic control units having an attribute of a combination in which message exchange is not occurring in the relationship is abnormal.
8. The anomaly detection device according to claim 2 or 3, wherein the in-vehicle network system exchanges messages via service-oriented communication, and the anomaly detection device further comprises: a communication log storage unit that stores messages received by the communication unit; and an ECU attribute setting unit that sets the attributes of the electronic control unit stored in the ECU attribute storage unit, and the ECU attribute setting unit references the messages stored in the communication log storage unit, determines whether the electronic control unit is on the server side or the client side from the message type included in the message, and determines the attributes of the electronic control unit based on the ratio of server communication to client communication.
9. The abnormality detection device according to claim 2 or 3, further comprising: a communication log memory unit that stores messages received by the communication unit; and an ECU attribute setting unit that sets attributes of the electronic control unit stored in the ECU attribute memory unit by referring to the messages stored in the communication log memory unit, wherein the ECU attribute setting unit determines the attributes of the first electronic control unit according to the frequency of appearance of the attributes of the electronic control unit with which the first electronic control unit communicates by referring to the messages stored in the communication log memory unit and the ECU attribute memory unit.
10. The anomaly detection device described in claim 8, wherein the ECU attribute setting unit determines the attribute of the electronic control unit when the following conditions are met: a predetermined time has elapsed since the attribute of the electronic control unit was determined; or the communication unit has received a message indicating a change in the communication tendency of the one or more networks.
11. The anomaly detection device according to claim 10, wherein the message that causes a change in the communication trends of the one or more networks is a message that occurs when data is acquired and installed from a network or server different from the in-vehicle network system, or a message that occurs when function settings of the in-vehicle network system are changed, deleted, or updated.
12. The anomaly detection device according to claim 9, wherein the anomaly detection unit calculates the frequency of occurrence of the attributes of the electronic control units with which the first electronic control unit communicates from the messages stored in the communication log memory unit, and, when referring to the frequency of occurrence of the attributes of the first electronic control unit stored in the ECU attribute memory unit and the frequency deviates beyond a certain standard, judges that the communication of the first electronic control unit is abnormal.
13. An abnormality detection method for detecting an abnormality in an in-vehicle network system composed of two or more electronic control units and one or more networks, comprising: sending and receiving messages on the one or more networks; detecting abnormal communication using an attribute of an electronic control unit that is the sender or destination of the message, among attributes of the electronic control units set in each of the two or more electronic control units; wherein the attribute indicates the function of the electronic control unit that has the attribute, or the type of information handled by the electronic control unit that has the attribute.
